1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,96086,(e,t,n)=>{t.exports=e.r(9187)},40066,e=>{e.v({header:"index-module-scss-module__68q3RW__header","header--black":"index-module-scss-module__68q3RW__header--black","header--bold":"index-module-scss-module__68q3RW__header--bold","header--opened-menu":"index-module-scss-module__68q3RW__header--opened-menu","header--opened-search":"index-module-scss-module__68q3RW__header--opened-search","header--primary":"index-module-scss-module__68q3RW__header--primary","header--quaternary":"index-module-scss-module__68q3RW__header--quaternary","header--quinary":"index-module-scss-module__68q3RW__header--quinary","header--regular":"index-module-scss-module__68q3RW__header--regular","header--secondary":"index-module-scss-module__68q3RW__header--secondary","header--semibold":"index-module-scss-module__68q3RW__header--semibold","header--senary":"index-module-scss-module__68q3RW__header--senary","header--shadow":"index-module-scss-module__68q3RW__header--shadow","header--tertiary":"index-module-scss-module__68q3RW__header--tertiary","header--white":"index-module-scss-module__68q3RW__header--white",header__container:"index-module-scss-module__68q3RW__header__container","header__lang-select":"index-module-scss-module__68q3RW__header__lang-select",header__logo:"index-module-scss-module__68q3RW__header__logo","header__mobile-lang-select":"index-module-scss-module__68q3RW__header__mobile-lang-select","header__mobile-menu":"index-module-scss-module__68q3RW__header__mobile-menu","header__mobile-menu--black":"index-module-scss-module__68q3RW__header__mobile-menu--black","header__mobile-menu--primary":"index-module-scss-module__68q3RW__header__mobile-menu--primary","header__mobile-menu--quaternary":"index-module-scss-module__68q3RW__header__mobile-menu--quaternary","header__mobile-menu--quinary":"index-module-scss-module__68q3RW__header__mobile-menu--quinary","header__mobile-menu--secondary":"index-module-scss-module__68q3RW__header__mobile-menu--secondary","header__mobile-menu--senary":"index-module-scss-module__68q3RW__header__mobile-menu--senary","header__mobile-menu--tertiary":"index-module-scss-module__68q3RW__header__mobile-menu--tertiary","header__mobile-menu--white":"index-module-scss-module__68q3RW__header__mobile-menu--white","header__mobile-menu-btn":"index-module-scss-module__68q3RW__header__mobile-menu-btn","header__mobile-menu-divider":"index-module-scss-module__68q3RW__header__mobile-menu-divider","header__mobile-menu-list":"index-module-scss-module__68q3RW__header__mobile-menu-list",header__nav:"index-module-scss-module__68q3RW__header__nav","header__nav-link":"index-module-scss-module__68q3RW__header__nav-link","header__nav-link--active":"index-module-scss-module__68q3RW__header__nav-link--active","header__submenu-link--active":"index-module-scss-module__68q3RW__header__submenu-link--active",search:"index-module-scss-module__68q3RW__search","search--opened":"index-module-scss-module__68q3RW__search--opened",search__container:"index-module-scss-module__68q3RW__search__container","search__container--black":"index-module-scss-module__68q3RW__search__container--black","search__container--primary":"index-module-scss-module__68q3RW__search__container--primary","search__container--quaternary":"index-module-scss-module__68q3RW__search__container--quaternary","search__container--quinary":"index-module-scss-module__68q3RW__search__container--quinary","search__container--secondary":"index-module-scss-module__68q3RW__search__container--secondary","search__container--senary":"index-module-scss-module__68q3RW__search__container--senary","search__container--tertiary":"index-module-scss-module__68q3RW__search__container--tertiary","search__container--white":"index-module-scss-module__68q3RW__search__container--white",search__icon:"index-module-scss-module__68q3RW__search__icon",search__wrapper:"index-module-scss-module__68q3RW__search__wrapper"})},46804,e=>{"use strict";function t(e,t){let n=e;for(;(n=n.parentElement)&&!n.matches(t););return n}e.s(["findElementAncestor",()=>t])},50230,292,87716,32990,43982,88994,80606,e=>{"use strict";var t=e.i(46804);function n(e,n,i){return i?Array.from((0,t.findElementAncestor)(i,n)?.querySelectorAll(e)||[]).findIndex(e=>e===i):null}e.s(["getContextItemIndex",()=>n],50230);var i=e.i(30668);function r({open:e,close:t,openDelay:n,closeDelay:r}){let o=(0,i.useRef)(-1),a=(0,i.useRef)(-1),s=()=>{window.clearTimeout(o.current),window.clearTimeout(a.current)};return(0,i.useEffect)(()=>s,[]),{openDropdown:()=>{s(),0===n||void 0===n?e():o.current=window.setTimeout(e,n)},closeDropdown:()=>{s(),0===r||void 0===r?t():a.current=window.setTimeout(t,r)}}}e.s(["useDelayedHover",()=>r],292);var o=e.i(20826),a=e.i(48277);e.i(99325);let[s,l]=(0,o.createSafeContext)("Menu component was not found in the tree");e.s(["MenuContextProvider",()=>s,"useMenuContext",()=>l],87716);var d={dropdown:"m_dc9b7c9f",label:"m_9bfac126",divider:"m_efdf90cb",item:"m_99ac2aa1",itemLabel:"m_5476e0d3",itemSection:"m_8b75e504",chevron:"m_b85b0bed"};e.s(["default",()=>d],32990);var u=e.i(1584),c=e.i(56297),h=e.i(77219);let p=(0,h.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:s,...d}=(0,u.useProps)("MenuDivider",null,e),h=l();return(0,a.jsx)(c.Box,{ref:t,...h.getStyles("divider",{className:i,style:r,styles:o,classNames:n}
1),...d})});p.classes=d,p.displayName="@mantine/core/MenuDivider",e.s(["MenuDivider",()=>p],43982);var f=e.i(12824);function g(e,t){return n=>{e?.(n),t?.(n)}}e.s(["createEventHandler",()=>g],88994);var m=e.i(14845);let v=(0,h.factory)((e,t)=>{let{classNames:n,className:r,style:o,styles:s,vars:d,onMouseEnter:c,onMouseLeave:h,onKeyDown:p,children:v,...y}=(0,u.useProps)("MenuDropdown",null,e),b=(0,i.useRef)(null),x=l(),w=g(p,e=>{("ArrowUp"===e.key||"ArrowDown"===e.key)&&(e.preventDefault(),b.current?.querySelectorAll("[data-menu-item]:not(:disabled)")[0]?.focus())}),C=g(c,()=>("hover"===x.trigger||"click-hover"===x.trigger)&&x.openDropdown()),S=g(h,()=>("hover"===x.trigger||"click-hover"===x.trigger)&&x.closeDropdown());return(0,a.jsxs)(m.Popover.Dropdown,{...y,onMouseEnter:C,onMouseLeave:S,role:"menu","aria-orientation":"vertical",ref:(0,f.useMergedRef)(t,b),...x.getStyles("dropdown",{className:r,style:o,styles:s,classNames:n,withStaticClass:!1}),tabIndex:-1,"data-menu-dropdown":!0,onKeyDown:w,children:[x.withInitialFocusPlaceholder&&(0,a.jsx)("div",{tabIndex:-1,"data-autofocus":!0,"data-mantine-stop-propagation":!0,style:{outline:0}}),v]})});v.classes=d,v.displayName="@mantine/core/MenuDropdown",e.s(["MenuDropdown",()=>v],80606)},57922,e=>{"use strict";var t=e.i(46804);function n({parentSelector:e,siblingSelector:n,onKeyDown:i,loop:r=!0,activateOnFocus:o=!1,dir:a="rtl",orientation:s}){return l=>{i?.(l);let d=Array.from((0,t.findElementAncestor)(l.currentTarget,e)?.querySelectorAll(n)||[]).filter(n=>{var i;return i=l.currentTarget,(0,t.findElementAncestor)(i,e)===(0,t.findElementAncestor)(n,e)}),u=d.findIndex(e=>l.currentTarget===e),c=function(e,t,n){for(let n=e+1;n<t.length;n+=1)if(!t[n].disabled)return n;if(n){for(let e=0;e<t.length;e+=1)if(!t[e].disabled)return e}return e}(u,d,r),h=function(e,t,n){for(let n=e-1;n>=0;n-=1)if(!t[n].disabled)return n;if(n){for(let e=t.length-1;e>-1;e-=1)if(!t[e].disabled)return e}return e}(u,d,r),p="rtl"===a?h:c,f="rtl"===a?c:h;switch(l.key){case"ArrowRight":"horizontal"===s&&(l.stopPropagation(),l.preventDefault(),d[p].focus(),o&&d[p].click());break;case"ArrowLeft":"horizontal"===s&&(l.stopPropagation(),l.preventDefault(),d[f].focus(),o&&d[f].click());break;case"ArrowUp":"vertical"===s&&(l.stopPropagation(),l.preventDefault(),d[h].focus(),o&&d[h].click());break;case"ArrowDown":"vertical"===s&&(l.stopPropagation(),l.preventDefault(),d[c].focus(),o&&d[c].click());break;case"Home":l.stopPropagation(),l.preventDefault(),d[0].disabled||d[0].focus();break;case"End":{l.stopPropagation(),l.preventDefault();let e=d.length-1;d[e].disabled||d[e].focus()}}}}e.s(["createScopedKeydownHandler",()=>n])},76163,41433,10504,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(12824),r=e.i(57922),o=e.i(88994);e.i(99325);var a=e.i(44733),s=e.i(11920),l=e.i(1584),d=e.i(90905),u=e.i(58960),c=e.i(20425),h=e.i(87716),p=e.i(32990);let[f,g]=(0,e.i(58525).createOptionalContext)();e.s(["SubMenuProvider",()=>f,"useSubMenuContext",()=>g],41433);let m=(0,d.polymorphicFactory)((e,d)=>{let{classNames:p,className:f,style:m,styles:v,vars:y,color:b,closeMenuOnClick:x,leftSection:w,rightSection:C,children:S,disabled:_,"data-disabled":k,...M}=(0,l.useProps)("MenuItem",null,e),T=(0,h.useMenuContext)(),D=g(),R=(0,s.useMantineTheme)(),{dir:I}=(0,u.useDirection)(),A=(0,n.useRef)(null),P=(0,o.createEventHandler)(M.onClick,()=>{!k&&("boolean"==typeof x?x&&T.closeDropdownImmediately():T.closeOnItemClick&&T.closeDropdownImmediately())}),E=b?R.variantColorResolver({color:b,theme:R,variant:"light"}):void 0,L=b?(0,a.parseThemeColor)({color:b,theme:R}):null,F=(0,o.createEventHandler)(M.onKeyDown,e=>{"ArrowLeft"===e.key&&D&&(D.close(),D.focusParentItem())});return(0,t.jsxs)(c.UnstyledButton,{onMouseDown:e=>e.preventDefault(),...M,unstyled:T.unstyled,tabIndex:T.menuItemTabIndex,...T.getStyles("item",{className:f,style:m,styles:v,classNames:p}),ref:(0,i.useMergedRef)(A,d),role:"menuitem",disabled:_,"data-menu-item":!0,"data-disabled":_||k||void 0,"data-mantine-stop-propagation":!0,onClick:P,onKeyDown:(0,r.createScopedKeydownHandler)({siblingSelector:"[data-menu-item]:not([data-disabled])",parentSelector:"[data-menu-dropdown]",activateOnFocus:!1,loop:T.loop,dir:I,orientation:"vertical",onKeyDown:F}),__vars:{"--menu-item-color":L?.isThemeColor&&L?.shade===void 0?`var(--mantine-color-${L.color}-6)`:E?.color,"--menu-item-hover":E?.hover},children:[w&&(0,t.jsx)("div",{...T.getStyles("itemSection",{styles:v,classNames:p}),"data-position":"left",children:w}),S&&(0,t.jsx)("div",{...T.getStyles("itemLabel",{styles:v,classNames:p}),children:S}),C&&(0,t.jsx)("div",{...T.getStyles("itemSection",{styles:v,classNames:p}),"data-position":"right",children:C})]})});m.classes=p.default,m.displayName="@mantine/core/MenuItem",e.s(["MenuItem",()=>m],76163);var v=e.i(56297);let y=(0,e.i(77219).factory)((e,n)=>{let{classNames:i,className:r,style:o,styles:a,vars:s,...d}=(0,l.useProps)("MenuLabel",null,e),u=(0,h.useMenuContext)();return(0,t.jsx)(v.Box,{ref:n,...u.getStyles("label",{className:r,style:o,styles:a,classNames:i}),...d})});y.classes=p.default,y.displayName="@mantine/core/MenuLabel",e.s(["MenuLabel",()=>y],10504)},36676,e=>{"use strict";var t=e.i(30668);function n(e=!1,i={}){let[r,o]=(0,t.useState)(e),a=(0,t.useCallback)(()=>{o(e=>e||(i.onOpen?.(),!0))},[i.onOpen]),s=(0,t.useCallback)(()=>{o(e=>e?(i.onClose?.(),!1):e)},[i.onClose]),l=(0,t.useCallback)(()=>{r?s():a()},[s,a,r]);return[r,{open:a,close:s,toggle:l}]}e.s(["useDisclosure",()=>n])},53674,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(12824),r=e.i(88994);e.i(99325);var o=e.i(1584),a=e.i(77219),s=e.i(14845),l=e.i(87716),d=e.i(32990),u=e.i(41433);let c=(0,a.factory)((e,a)=>{let{classNames:d,className:c,style:h,styles:p,vars:f,onMouseEnter:g,onMouseLeave:m,onKeyDown:v,children:y,...b}=(0,o.useProps)("MenuSubDropdown",null,e),x=(0,n.useRef)(null),w=(0,l.useMenuContext)(),C=(0,u.useSubMenuContext)(),S=(0,r.createEventHandler)(g,C?.open),_=(0,r.createEventHandler)(m,C?.close);return(0,t.jsx)(s.Popover.Dropdown,{...b,onMouseEnter:S,onMouseLeave:_,role:"menu","aria-orientation":"vertical",ref:(0,i.useMergedRef)(a,x),...w.getStyles("dropdown",{className:c,style:h,styles:p,classNames:d,withStaticClass:!1}),tabIndex:-1,"data-menu-dropdown":!0,children:y})});c.classes=d.default,c.displayName="@mantine/core/MenuSubDropdown",e.s(["MenuSubDropdown",()=>c])},23414,e=>{"use strict";var t=e.i(48277),n=e.i(15502);function i({style:e,size:i=16,...r}){return(0,t.jsx)("svg",{viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{...e,width:(0,n.rem)(i),height:(0,n.rem)(i),display:"block"},...r,children:(0,t.jsx)("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.564
164L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"})})}e.i(30668),e.i(99325),i.displayName="@mantine/core/AccordionChevron",e.s(["AccordionChevron",()=>i])},31719,e=>{e.v({"lang-select":"index-module-scss-module__7Hzehq__lang-select","lang-select--opened":"index-module-scss-module__7Hzehq__lang-select--opened","lang-select__dropdown":"index-module-scss-module__7Hzehq__lang-select__dropdown","lang-select__dropdown-item":"index-module-scss-module__7Hzehq__lang-select__dropdown-item"})},62509,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(45530),r=e.i(99850),o=e.i(50230);e.i(99325);var a=e.i(36546),s=e.i(24133),l=e.i(1584),d=e.i(77219),u=e.i(292),c=e.i(14845),h=e.i(87716),p=e.i(32990),f=e.i(43982),g=e.i(80606),m=e.i(76163),v=e.i(10504),y=e.i(57472),b=e.i(36676),x=e.i(53674),w=e.i(12824),C=e.i(57922),S=e.i(88994),_=e.i(44733),k=e.i(11920),M=e.i(90905),T=e.i(58960),D=e.i(23414),R=e.i(20425),I=e.i(41433);let A=(0,M.polymorphicFactory)((e,i)=>{let{classNames:r,className:o,style:a,styles:s,vars:d,color:u,leftSection:c,rightSection:p,children:f,disabled:g,"data-disabled":m,closeMenuOnClick:v,...y}=(0,l.useProps)("MenuSubItem",null,e),b=(0,h.useMenuContext)(),x=(0,I.useSubMenuContext)(),M=(0,k.useMantineTheme)(),{dir:A}=(0,T.useDirection)(),P=(0,n.useRef)(null),E=u?M.variantColorResolver({color:u,theme:M,variant:"light"}):void 0,L=u?(0,_.parseThemeColor)({color:u,theme:M}):null,F=(0,S.createEventHandler)(y.onKeyDown,e=>{"ArrowRight"===e.key&&(x?.open(),x?.focusFirstItem()),"ArrowLeft"===e.key&&x?.parentContext&&(x.parentContext.close(),x.parentContext.focusParentItem())}),O=(0,S.createEventHandler)(y.onClick,()=>{!m&&v&&b.closeDropdownImmediately()}),N=(0,S.createEventHandler)(y.onMouseEnter,x?.open),B=(0,S.createEventHandler)(y.onMouseLeave,x?.close);return(0,t.jsxs)(R.UnstyledButton,{onMouseDown:e=>e.preventDefault(),...y,unstyled:b.unstyled,tabIndex:b.menuItemTabIndex,...b.getStyles("item",{className:o,style:a,styles:s,classNames:r}),ref:(0,w.useMergedRef)(P,i),role:"menuitem",disabled:g,"data-menu-item":!0,"data-sub-menu-item":!0,"data-disabled":g||m||void 0,"data-mantine-stop-propagation":!0,onMouseEnter:N,onMouseLeave:B,onClick:O,onKeyDown:(0,C.createScopedKeydownHandler)({siblingSelector:"[data-menu-item]:not([data-disabled])",parentSelector:"[data-menu-dropdown]",activateOnFocus:!1,loop:b.loop,dir:A,orientation:"vertical",onKeyDown:F}),__vars:{"--menu-item-color":L?.isThemeColor&&L?.shade===void 0?`var(--mantine-color-${L.color}-6)`:E?.color,"--menu-item-hover":E?.hover},children:[c&&(0,t.jsx)("div",{...b.getStyles("itemSection",{styles:s,classNames:r}),"data-position":"left",children:c}),f&&(0,t.jsx)("div",{...b.getStyles("itemLabel",{styles:s,classNames:r}),children:f}),(0,t.jsx)("div",{...b.getStyles("itemSection",{styles:s,classNames:r}),"data-position":"right",children:p||(0,t.jsx)(D.AccordionChevron,{...b.getStyles("chevron"),size:14})})]})});A.classes=p.default,A.displayName="@mantine/core/MenuSubItem";var P=e.i(10172);function E({children:e,refProp:n}){if(!(0,P.isElement)(e))throw Error("Menu.Sub.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");return(0,h.useMenuContext)(),(0,t.jsx)(c.Popover.Target,{refProp:n,popupType:"menu",children:e})}E.displayName="@mantine/core/MenuSubTarget";let L={offset:0,position:"right-start",transitionProps:{duration:0},openDelay:0,middlewares:{shift:{crossAxis:!0}}};function F(e){let{children:n,closeDelay:i,openDelay:r,...o}=(0,l.useProps)("MenuSub",L,e),a=(0,y.useId)(),[s,{open:d,close:h}]=(0,b.useDisclosure)(!1),p=(0,I.useSubMenuContext)(),{openDropdown:f,closeDropdown:g}=(0,u.useDelayedHover)({open:d,close:h,closeDelay:i,openDelay:r});return(0,t.jsx)(I.SubMenuProvider,{value:{opened:s,close:g,open:f,focusFirstItem:()=>window.setTimeout(()=>{document.getElementById(`${a}-dropdown`)?.querySelectorAll("[data-menu-item]:not([data-disabled])")[0]?.focu
1s()},16),focusParentItem:()=>window.setTimeout(()=>{document.getElementById(`${a}-target`)?.focus()},16),parentContext:p},children:(0,t.jsx)(c.Popover,{opened:s,withinPortal:!1,withArrow:!1,id:a,...o,children:n})})}F.extend=e=>e,F.displayName="@mantine/core/MenuSub",F.Target=E,F.Dropdown=x.MenuSubDropdown,F.Item=A;var O=e.i(33217);let N={refProp:"ref"},B=(0,n.forwardRef)((e,i)=>{let{children:r,refProp:o,...a}=(0,l.useProps)("MenuTarget",N,e),s=(0,O.getSingleElementChild)(r);if(!s)throw Error("Menu.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");let d=(0,h.useMenuContext)(),u=s.props,p=(0,S.createEventHandler)(u.onClick,()=>{"click"===d.trigger?d.toggleDropdown():"click-hover"===d.trigger&&(d.setOpenedViaClick(!0),d.opened||d.openDropdown())}),f=(0,S.createEventHandler)(u.onMouseEnter,()=>("hover"===d.trigger||"click-hover"===d.trigger)&&d.openDropdown()),g=(0,S.createEventHandler)(u.onMouseLeave,()=>{"hover"===d.trigger?d.closeDropdown():"click-hover"!==d.trigger||d.openedViaClick||d.closeDropdown()});return(0,t.jsx)(c.Popover.Target,{refProp:o,popupType:"menu",ref:i,...a,children:(0,n.cloneElement)(s,{onClick:p,onMouseEnter:f,onMouseLeave:g,"data-expanded":!!d.opened||void 0})})});B.displayName="@mantine/core/MenuTarget";let z={trapFocus:!0,closeOnItemClick:!0,withInitialFocusPlaceholder:!0,clickOutsideEvents:["mousedown","touchstart","keydown"],loop:!0,trigger:"click",openDelay:0,closeDelay:100,menuItemTabIndex:-1};function j(e){let i=(0,l.useProps)("Menu",z,e),{children:d,onOpen:f,onClose:g,opened:m,defaultOpened:v,trapFocus:y,onChange:b,closeOnItemClick:x,loop:w,closeOnEscape:C,trigger:S,openDelay:_,closeDelay:k,classNames:M,styles:T,unstyled:D,variant:R,vars:I,menuItemTabIndex:A,keepMounted:P,withInitialFocusPlaceholder:E,attributes:L,...F}=i,O=(0,s.useStyles)({name:"Menu",classes:p.default,props:i,classNames:M,styles:T,unstyled:D,attributes:L}
1),[N,B]=(0,r.useUncontrolled)({value:m,defaultValue:v,finalValue:!1,onChange:b}),[j,V]=(0,n.useState)(!1),H=()=>{B(!1),V(!1),N&&g?.()},G=()=>{B(!0),N||f?.()},W=()=>{N?H():G()},{openDropdown:$,closeDropdown:U}=(0,u.useDelayedHover)({open:G,close:H,closeDelay:k,openDelay:_}),{resolvedClassNames:q,resolvedStyles:K}=(0,a.useResolvedStylesApi)({classNames:M,styles:T,props:i});return(0,t.jsx)(h.MenuContextProvider,{value:{getStyles:O,opened:N,toggleDropdown:W,getItemIndex:e=>(0,o.getContextItemIndex)("[data-menu-item]","[data-menu-dropdown]",e),openedViaClick:j,setOpenedViaClick:V,closeOnItemClick:x,closeDropdown:"click"===S?H:U,openDropdown:"click"===S?G:$,closeDropdownImmediately:H,loop:w,trigger:S,unstyled:D,menuItemTabIndex:A,withInitialFocusPlaceholder:E},children:(0,t.jsx)(c.Popover,{returnFocus:!0,...F,opened:N,onChange:W,defaultOpened:v,trapFocus:!P&&y,closeOnEscape:C,__staticSelector:"Menu",classNames:q,styles:K,unstyled:D,variant:R,keepMounted:P,children:d})})}j.extend=e=>e,j.withProps=(0,d.getWithProps)(j),j.classes=p.default,j.displayName="@mantine/core/Menu",j.Item=m.MenuItem,
1j.Label=v.MenuLabel,j.Dropdown=g.MenuDropdown,j.Target=B,j.Divider=f.MenuDivider,j.Sub=F;var V=e.i(52265),H=e.i(31719),G=e.i(95317),W=e.i(90388);e.s(["MultiLanguageSelector",0,e=>{let{className:r,languages:o}=e,{currentLang:a,setCurrentLang:s}=(0,G.useLanguage)(),{tenant:l}=(0,W.useTenant)();(0,n.useEffect)(()=>{let e=new URL(window.location.href),t=e.searchParams.get("locale");t&&(s(t),e.searchParams.delete("locale"),window.history.replaceState({},"",e.toString()))},[s]);let d={nl:"ð³ð±",en:"ð¬ð§",de:"ð©ðª",es:"ðªð¸",it:"ð®ð¹",fr:"ð«ð·",ma:"ð²ð¦",pt:"ðµð¹",tr:"ð¹ð·",zh:"ð¨ð³"},[u,c]=(0,n.useState)(!1),h=o.data.map(e=>({value:e,label:`${d[e]} ${e}`})).filter(e=>e.value!=a).map(e=>(0,t.jsx)(j.Item,{className:H.default["lang-select__dropdown-item"],onClick:()=>{s(e.value??o.default),window.location.reload()},children:e.label},e.value));return(0,t.jsx)(i.MantineProvider,{children:(0,t.jsxs)(j,{onOpen:()=>c(!0),onClose:()=>c(!1),radius:"md",width:71,withinPortal:!0,classNames:{dropdown:[H.default["lang-select__dropdown"]].filter(Boolean).join(" "),item:H.default["lang-select__dropdown-item"]},zIndex:999,offset:2,children:[(0,t.jsx)(j.Target,{children:(0,t.jsxs)(R.UnstyledButton,{className:[H.default["lang-select"],u?H.default["lang-select--opened"]:"",r].filter(Boolean).join(" "),"data-expanded":u||void 0,children:[(0,t.jsx)(V.Icon,{icon:"map"}),(0,t.jsx)("span",{className:H.default.label,children:a})]})}),(0,t.jsx)(j.Dropdown,{children:h})]})})}],62509)},63797,e=>{"use strict";var t=e.i(48277);e.i(30668),e.i(99325);var n=e.i(1584),i=e.i(77219),r=e.i(91805);let o=(0,i.factory)((e,i)=>{let o=(0,n.useProps)("TextInput",null,e);return(0,t.jsx)(r.InputBase,{component:"input",ref:i,...o,__staticSelector:"TextInput"})});o.classes=r.InputBase.classes,o.displayName="@mantine/core/TextInput",e.s(["TextInput",()=>o])},97320,e=>{e.v({search:"index-module-scss-module__7Hsj6G__search",search__section:"index-module-scss-module__7Hsj6G__search__section"})},42633,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(63797),r=e.i(97320),o=e.i(52265),a=e.i(76466),s=e.i(79908);function l({className:e}){let{searchQuery:l,setSearchQuery:d,activeSearch:u}=(0,a.useSearch)(),{t:c}=(0,s.useTranslations)(),[h,p]=(0,n.useState)(l),[f]=function(e,t,i={leading:!1}){let[r,o]=(0,n.useState)(e),a=(0,n.useRef)(!1),s=(0,n.useRef)(null),l=(0,n.useRef)(!1),d=(0,n.useCallback)(()=>window.clearTimeout(s.current),[]);return(0,n.useEffect)(()=>{a.current&&(!l.current&&i.leading?(l.current=!0,o(e)):(d(),s.current=window.setTimeout(()=>{l.current=!1,o(e)},500)))},[e,i.leading,500]),(0,n.useEffect)(()=>
1(a.current=!0,d),[]),[r,d]}(h,0),g=(0,n.useRef)(null);return(0,n.useEffect)(()=>{p(l)},[l]),(0,n.useEffect)(()=>{d(f)},[f,d]),(0,n.useEffect)(()=>{u&&g.current&&g.current.focus()},[u]),(0,t.jsx)(i.TextInput,{ref:g,enterKeyHint:"search",name:"query",radius:"xl",classNames:{input:r.default.search,wrapper:e,section:r.default.search__section},placeholder:c("search"),leftSection:(0,t.jsx)(o.Icon,{icon:"search"}),value:h,onChange:e=>p(e.currentTarget.value)})}e.s(["Search",()=>l],42633)},19285,e=>{"use strict";var t=e.i(96086),n=e.i(85451);e.s(["useIsLinkActive",0,()=>{let e=(0,t.usePathname)();return t=>{if(!e||!t||"reference"!==t.type)return!1;let i=(0,n.buildLinkPath)(t.reference);return!!i&&e===i}}])},66369,e=>{e.v({footer:"index-module-scss-module__tarSMG__footer","footer--black":"index-module-scss-module__tarSMG__footer--black","footer--primary":"index-module-scss-module__tarSMG__footer--primary","footer--quaternary":"index-module-scss-module__tarSMG__footer--quaternary","footer--quinary":"index-module-scss-module__tarSMG__footer--quinary","footer--secondary":"index-module-scss-module__tarSMG__footer--secondary","footer--senary":"index-module-scss-module__tarSMG__footer--senary","footer--tertiary":"index-module-scss-module__tarSMG__footer--tertiary","footer--white":"index-module-scss-module__tarSMG__footer--white",footer__container:"index-module-scss-module__tarSMG__footer__container",footer__logo:"index-module-scss-module__tarSMG__footer__logo",footer__logos:"index-module-scss-module__tarSMG__footer__logos",footer__nav:"index-module-scss-module__tarSMG__footer__nav","footer__nav-column":"index-module-scss-module__tarSMG__footer__nav-column","footer__nav-column-blocks":"index-module-scss-module__tarSMG__footer__nav-column-blocks","footer__nav-column-links":"index-module-scss-module__tarSMG__footer__nav-column-links","footer__nav-column-title":"index-module-scss-module__tarSMG__footer__nav-column-title","footer__nav-column-title--withAppearance":"index-module-scss-module__tarSMG__footer__nav-column-title--withAppearance","footer__nav-link":"index-module-scss-module__tarSMG__footer__nav-link","footer__nav-link--active":"index-module-scss-module__tarSMG__footer__nav-link--active","footer__nav-link-block":"index-module-scss-module__tarSMG__footer__nav-link-block","footer__nav-link-title":"index-module-scss-module__tarSMG__footer__nav-link-title"})},23951,e=>{e.v({Branding:"index-module-scss-module__n7nAUa__Branding",Wrapper:"index-module-scss-module__n7nAUa__Wrapper",heartbeat:"index-module-scss-module__n7nAUa__heartbeat",modalContent:"index-module-scss-module__n7nAUa__modalContent"})},41851,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});var i={callServer:function(){return o.callServer},createServerReference:function(){return s.createServerReference},findSourceMapURL:function(){return a.findSourceMapURL}};for(var r in i)Object.defineProperty(n,r,{enumerable:!0,get:i[r]});let o=e.r(59295),a=e.r(85045),s=e.r(30545)},81330,31930,54433,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(29987),r=e.i(86577),o=e.i(52265),a=e.i(40066),s=e.i(17444),l=e.i(62509),d=e.i(20425),u=e.i(42633),c=e.i(90388),h=e.i(76466),p=e.i(19285);e.s(["Header",0,({links:e})=>{let{tenant:f}=(0,c.useTenant)(),{activeSearch:g,setActiveSearch:m,setSearchQuery:v}=(0,h.useSearch)(),y=(0,p.useIsLinkActive)(),b=f.Header,x={data:f.languages,default:f.defaultLanguage},w=b?.navItems||[],C=b?.withSearch,[S,_]=n.default.useState(!1),k=b?.backgroundColor,M=b?.colorTypography,T=`var(--c-${M})`,D=b?.fontWeight,R=[a.default.header,...!k?[a.default["header--shadow"]]:[],...k?[a.default[`header--${k}`]]:[a.default["header--white"]],...D?[a.default[`header--${D}`]]:[],...g?[a.default["header--opened-search"]]:[],...S?[a.default["header--opened-menu"]]:[]].join(" ");return(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("header",{"data-block":"header",style:{"--header-text-color":T},className:R,children:[(0,t.jsxs)("div",{className:a.default.header__container,children:[(0,t.jsx)("a",{href:"/",children:(0,t.jsx)(s.Media,{className:a.default.header__logo,resource:b?.logo??void 0})}),w.length>0&&!g&&(0,t.jsx)("ul",{className:a.default.header__nav,children:w.map(({link:e},n)=>{let i=e?.appearance&&e?.appearance!="default"?e.appearance:void 0;return(0,t.jsx)("li",{children:(0,t.jsx)(r.CMSLink,{className:[!i?a.default["header__nav-link"]:"",y(e)&&!i?a.default["header__nav-link--active"]:""].filter(
1Boolean).join(" "),...e,appearance:i})},n)})}),(0,t.jsxs)("div",{className:[a.default.search,g?a.default["search--opened"]:""].filter(Boolean).join(" "),children:[(0,t.jsx)("div",{id:"header-search",className:[a.default.search__container,a.default[`search__container--${k}`],!k?a.default["search__container--shadow"]:""].filter(Boolean).join(" "),style:{display:g&&!S?"block":"none"},children:(0,t.jsx)(u.Search,{className:a.default.search__wrapper})}),C&&(0,t.jsx)(d.UnstyledButton,{"aria-label":"Search","aria-expanded":g,"aria-controls":"header-search",onClick:()=>{g&&v(""),m(!g)},className:[a.default.search__btn].filter(Boolean).join(" "),c:T,children:(0,t.jsx)(o.Icon,{icon:g?"searchClose":"search",className:a.default.search__icon})})]}),w.length>0&&(0,t.jsx)("div",{onClick:()=>{document.querySelector("body")?.classList.toggle("noscroll"),_(!S)},className:a.default["header__mobile-menu-btn"],children:(0,t.jsx)(o.Icon,{icon:S?"cross":"burger"})}),x.data.length>1&&(0,t.jsx)("div",{className:a.default["header__lang-select"],children:(0,t.jsx)(l.MultiLanguageSelector,{languages:x})})]}),w.length>0&&S&&(0,t.jsx)("div",{className:[a.default["header__mobile-menu"],a.default[`${k?`header__mobile-menu--${k}`:"header__mobile-menu--white"}`]].filter(Boolean).join(" "),children:(0,t.jsxs)(i.Gutter,{children:[(0,t.jsxs)("ul",{className:a.default["header__mobile-menu-list"],children:[w.map(({link:e},n)=>{let i=e?.appearance&&e?.appearance!="default"?e.appearance:void 0;return(0,t.jsx)("li",{children:(0,t.jsx)(r.CMSLink,{className:[!i?a.default["header__nav-link"]:"",y(e)?a.default["header__nav-link--active"]:""].filter(Boolean).join(" "),...e,appearance:i})},n)}),e&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("li",{className:a.default["header__mobile-menu-divider"]}),e.map(({link:e},n)=>(0,t.jsx)("li",{children:(0,t.jsx)(r.CMSLink,{className:[a.default["header__submenu-link"],a.default["header__nav-link"],y(e)?a.default["header__submenu-link--active"]:""].filter(Boolean).join(" "),...e})},n))]})]}),x.data.length>1&&(0,t.jsx)("div",{className:a.default["header__mobile-lang-select"],children:(0,t.jsx)(l.MultiLanguageSelector,{languages:x})})]})})]})})}],81330);var f=e.i(41851);let g=(0,f.createServerReference)("7f47d18198bb34221753a8d4c1d557cc7e7337a2b0",f.callServer,void 0,f.findSourceMapURL,"fetchSettings");var m=e.i(85595);let v=async()=>{let e=await g();return{supplierUrl:e.supplier.supplierUrl,supplierEmail:e.supplier.supplierEmail,supplierName:e.supplier.supplierName,supplierLogo:e.supplier.supplierLogo}},y=async()=>{let{supplierUrl:e,supplierEmail:t,supplierName:n,supplierLogo:i}=await v(),r=i?(0,m.getMediaUrl)(i.filename,i.prefix):"";return` 2<h2>Proudly created by</h2> 3<a href="https://${e}" target="_blank" rel="noopener noreferrer"><img 4src="${r}" 5alt="${n} logo" 6/></a> 7<p>Would you like a website as awesome as this one?</p> 8<p>Contact us at: <a href="mailto:${t}">${t}</a></p>`};e.s(["getBrandingContent",0,y],31930),e.i(39057);var b=e.i(98661);(0,e.i(69693).LINK_FIELDS)({disableAppearance:!0}),b.MEDIA_BLOCK,b.RICH_TEXT_BLOCK;let x=` 9 Setting { 10 supplier { 11 supplierName 12 supplierEmail 13 supplierUrl 14 supplierContactUrl 15 supplierLogo { 16 url 17 filename 18 prefix 19 } 20 supplierFavicon { 21 url 22 filename 23 prefix 24 } 25 logoColor 26 supplierCity 27 supplierCountryCode 28 } 29 } 30`,w=` 31query GetSettings { 32 ${x} 33} 34`;var C=e.i(80202);e.s(["useSettings",0,()=>{let[e,t]=(0,n.useState)(null),[i,r]=(0,n.useState)(!0);return(0,n.useEffect)(()=>{(0,C.fetchWithRetry)("https://app.axio-cms.com/api/graphql",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({query:w})}).then(e=>e.json()).then(e=>{if(e.errors)throw Error(e.errors?.[0]?.message??"Error fetching settings");let n=e?.data?.Setting;t(n?.supplier||null),r(!1)}).catch(()=>{t(null),r(!1)})},[]),{supplier:e,loading:i}}],54433)},19250,e=>{"use strict";var t=e.i(90388);function n(e){let t=parseInt(e.slice(1,3),16)/255,n=parseInt(e.slice(3,5),16)/255,i=parseInt(e.slice(5,7),16)/255;return .2126*(t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4))+.7152*(n<=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4))+.0722*(i<=.03928?i/12.92:Math.pow((i+.055)/1.055,2.4))}function i(e,t){let i=n(e),r=n(t);return(Math.max(i,r)+.05)/(Math.min(i,r)+.05)}function r(e,t,n=3){return i(e,t)>=n}function o(e){return i(e,"#FFFFFF")>i(e,"#000000")?"#FFFFFF":"#000000"}function a(e,t){if(!e)return"#000000";let n=l(e,t);return n?o(n):"#000000"}function s(e){let{tenant:n}=(0,t.useTenant)();return a(e,n)}function l(e,t){return({primary:t.Theme?.cPrimary,secondary:t.Theme?.cSecondary,tertiary:t.Theme?.cTertiary,quaternary:t.Theme?.cQuaternary,quinary:t.Theme?.cQuinary,senary:t.Theme?.cSenary,white:t.Theme?.cWhite,black:t.Theme?.cBlack})[e]||void 0}e.s(["getContrastingTextColor",()=>o,"getContrastingTextColorFromTheme",()=>a,"hasGoodContrast",()=>r,"mapColorToHex",()=>l,"useContrastingTextColor",()=>s])},82696,e=>{e.v({link:"index-module-scss-module__8_zBZW__link"})},18756,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(11116),r=e.i(23951),o=e.i(31930),a=e.i(90388),s=e.i(54433),l=e.i(19250),d=e.i(85595),u=e.i(38102),c=e.i(79908),h=e.i(82696);let p=()=>
34{let[e,i]=(0,n.useState)(!1),{tenant:r}=(0,a.useTenant)(),{t:o}=(0,c.useTranslations)();return r.cookieConsent?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("button",{className:h.default.link,onClick:()=>i(!0),"aria-label":o("cookieSettings"),children:"ðª"}),(0,t.jsx)(u.CookieSettingsModal,{isOpen:e,onClose:()=>i(!1)})]}):null};e.s(["Branding",0,({bgColor:e})=>{let[u,c]=(0,n.useState)(!1),[h,f]=(0,n.useState)(""),{tenant:g}=(0,a.useTenant)(),{supplier:m}=(0,s.useSettings)(),v=m?.supplierFavicon,y=v?.filename?(0,d.getMediaUrl)(v.filename,v.prefix):null;(0,n.useEffect)(()=>{(0,o.getBrandingContent)().then(f)},[]);let b=m?.logoColor||"#2C3CF9",x=!1;if(e){let t=(0,l.mapColorToHex)(e,g);t&&(x=!(0,l.hasGoodContrast)(t,b))}let w=x?"brightness(0) invert(1)":"none";return(0,t.jsxs)("div",{className:r.default.Wrapper,children:[(0,t.jsx)("button",{className:r.default.Branding,onClick:()=>c(!0),"aria-label":`Created by ${m?.supplierName||"AXIO"}`,style:{"--logo-filter":w},children:y&&(0,t.jsx)("img",{src:y,alt:`${m?.supplierName||"AXIO"} logo`})}),(0,t.jsx)(p,{}),(0,t.jsx)(i.Modal,{className:r.default.modalContent,isOpen:u,onClose:()=>c(!1),children:(0,t.jsx)("div",{dangerouslySetInnerHTML:{__html:h}})})]})}],18756)},89343,e=>{e.v({bodyWrapper:"index-module-scss-module__WPl_NG__bodyWrapper",card:"index-module-scss-module__WPl_NG__card","card--black":"index-module-scss-module__WPl_NG__card--black","card--border":"index-module-scss-module__WPl_NG__card--border","card--border-light":"index-module-scss-module__WPl_NG__card--border-light","card--primary":"index-module-scss-module__WPl_NG__card--primary","card--quaternary":"index-module-scss-module__WPl_NG__card--quaternary","card--quinary":"index-module-scss-module__WPl_NG__card--quinary","card--secondary":"index-module-scss-module__WPl_NG__card--secondary","card--senary":"index-module-scss-module__WPl_NG__card--senary","card--shadow":"index-module-scss-module__WPl_NG__card--shadow","card--tertiary":"index-module-scss-module__WPl_NG__card--tertiary","card--textOnHover":"index-module-scss-module__WPl_NG__card--textOnHover","card--white":"index-module-scss-module__WPl_NG__card--white","card-link":"index-module-scss-module__WPl_NG__card-link",categories:"index-module-scss-module__WPl_NG__categories",content:"index-module-scss-module__WPl_NG__content","content--with-text":"index-module-scss-module__WPl_NG__content--with-text",date:"index-module-scss-module__WPl_NG__date",img:"index-module-scss-module__WPl_NG__img",img_caption:"index-module-scss-module__WPl_NG__img_caption","img_caption--center":"index-module-scss-module__WPl_NG__img_caption--center","img_caption--hidden":"index-module-scss-module__WPl_NG__img_caption--hidden","img_caption--left":"index-module-scss-module__WPl_NG__img_caption--left","img_caption--right":"index-module-scss-module__WPl_NG__img_caption--right",link:"index-module-scss-module__WPl_NG__link","link--arrow":"index-module-scss-module__WPl_NG__link--arrow","link-wrapper":"index-module-scss-module__WPl_NG__link-wrapper","link-wrapper--center":"index-module-scss-module__WPl_NG__link-wrapper--center","link-wrapper--left":"index-module-scss-module__WPl_NG__link-wrapper--left","link-wrapper--right":"index-module-scss-module__WPl_NG__link-wrapper--right",media:"index-module-scss-module__WPl_NG__media","media--round":"index-module-scss-module__WPl_NG__media--round","media--withBorder":"index-module-scss-module__WPl_NG__media--withBorder",meta:"index-module-scss-module__WPl_NG__meta",text:"index-module-scss-module__WPl_NG__text","text--center":"index-module-scss-module__WPl_NG__text--center","text--left":"index-module-scss-module__WPl_NG__text--left","text--right":"index-module-scss-module__WPl_NG__text--right",title:"index-module-scss-module__WPl_NG__title","title--center":"index-module-scss-module__WPl_NG__title--center","title--left":"index-module-scss-module__WPl_NG__title--left","title--right":"index-module-scss-module__WPl_NG__title--right"})},38498,e=>{e.v({"icon--instagram":"index-module-scss-module__Xin2WG__icon--instagram",socialLinks:"index-module-scss-module__Xin2WG__socialLinks"})},78100,(e,t,n)=>{function i(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}t.exports=function(e,t){t=t||{};var n,r,o=typeof e;if("string"===o&&e.length>0){var a=e;if(!((a=String(a)).length>100)){var s=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(a);if(s){var l=parseFloat(s[1]);switch((s[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*l;case"days":case"day":case"d":return 864e5*l;case"hours":case"hour":case"hrs":case"hr":case"h":return 36e5*l;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*l;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*l;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:break}}}return}if("number"===o&&!1===isNaN(e)){return t.long?i(n=e,864e5,"day")||i(n,36e5,"hour")||i(n,6e4,"minute")||i(n,1e3,"second")||n+" ms":(r=e)>=864e5?Math.round(r/864e5)+"d":r>=36e5?Math.round(r/36e5)+"h":r>=6e4?Math.round(r/6e4)+"m":r>=1e3?Math.round(r/1e3)+"s":r+"ms"}throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},16333,(e,t,n)=>{var i;function r(e){function t(){if(t.enabled){var e=+new Date;t.diff=e-(i||e),t.prev=i,t.curr=e,i=e;for(var r=Array(arguments.length),o=0;o<r.length;o++)r[o]=arguments[o];r[0]=n.coerce(r[0]),"string"!=typeof r[0]&&r.unshift("%O");var a=0;r[0]=r[0].replace(/%([a-zA-Z%])/g,function(e,i){if("%%"===e)return e;a++;var o=n.formatters[i];if("function"==typeof o){var s=r[a];e=o.call(t,s),r.splice(a,1),a--}return e}),n.formatArgs.call(t,r),(t.log||n.log||console.log.bind(console)).apply(t,r)}}return t.namespace=e,t.enabled=n.enabled(e),t.useColors=n.useColors(),t.color=function(e){var t,i=0;for(t in e)i=(i<<5)-i+e.charCodeAt(t)|0;return n.colors[Math.abs(i)%n.colors.length]}(e),"function"==typeof n.init&&n.init(t),t}(n=t.exports=r.debug=r.default=r).coerce=function(e){return e instanceof Error?e.stack||e.message:e},n.disable=function(){n.enable("")},n.enable=function(e){n.save(e),n.names=[],n.skips=[];
34for(var t=("string"==typeof e?e:"").split(/[\s,]+/),i=t.length,r=0;r<i;r++)t[r]&&("-"===(e=t[r].replace(/\*/g,".*?"))[0]?n.skips.push(RegExp("^"+e.substr(1)+"$")):n.names.push(RegExp("^"+e+"$")))},n.enabled=function(e){var t,i;for(t=0,i=n.skips.length;t<i;t++)if(n.skips[t].test(e))return!1;for(t=0,i=n.names.length;t<i;t++)if(n.names[t].test(e))return!0;return!1},n.humanize=e.r(78100),n.names=[],n.skips=[],n.formatters={}},84293,(e,t,n)=>{var i=e.i(39057);function r(){var e;try{e=n.storage.debug}catch(e){}return!e&&void 0!==i.default&&"env"in i.default&&(e=i.default.env.DEBUG),e}(n=t.exports=e.r(16333)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},n.formatArgs=function(e){var t=this.useColors;if(e[0]=(t?"%c":"")+this.namespace+(t?" %c":" ")+e[0]+(t?"%c ":" ")+"+"+n.humanize(this.diff),t){var i="color: "+this.color;e.splice(1,0,i,"color: inherit");var r=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(o=r))}),e.splice(o,0,i)}},n.save=function(e){try{null==e?n.storage.removeItem("debug"):n.storage.debug=e}catch(e){}},n.load=r,n.useColors=function(){return"u">typeof window&&!!window.process&&"renderer"===window.process.type||"u">typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"u">typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"u">typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"u">typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},n.storage="u">typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),n.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],n.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},n.enable(r())},29197,(e,t,n)=>{var i=e.r(84293)("jsonp");t.exports=function(e,t,n){"function"==typeof t&&(n=t,t={}),t||(t={});var a,s,l=t.prefix||"__jp",d=t.name||l+r++,u=t.param||"callback",c=null!=t.timeout?t.timeout:6e4,h=encodeURIComponent,p=document.getElementsByTagName("script")[0]||document.head;function f(){a.parentNode&&a.parentNode.removeChild(a),window[d]=o,s&&clearTimeout(s)}return c&&(s=setTimeout(function(){f(),n&&n(Error("Timeout"))},c)),window[d]=function(e){i("jsonp got",e),f(),n&&n(null,e)},e+=(~e.indexOf("?")?"&":"?")+u+"="+h(d),i('jsonp req "%s"',e=e.replace("?&","?")),(a=document.createElement("script")).src=e,p.parentNode.insertBefore(a,p),function(){window[d]&&f()}};var r=0;function o(){}},46388,65457,48159,58165,47973,25445,28157,81315,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(90112),r=e.i(73596);e.i(99325);var o=e.i(1584),a=e.i(24133),s=e.i(90905),l=e.i(3218);let[d,u]=(0,e.i(20826).createSafeContext)("Card component was not found in tree");var c={root:"m_e615b15f",section:"m_599a2148"},h=e.i(56297);let p=(0,s.polymorphicFactory)((e,n)=>{let{classNames:i,className:r,style:a,styles:s,vars:l,withBorder:d,inheritPadding:c,mod:p,...f}=(0,o.useProps)("CardSection",null,e),g=u();return(0,t.jsx)(h.Box,{ref:n,mod:[{"with-border":d,"inherit-padding":c},p],...g.getStyles("section",{className:r,style:a,styles:s,classNames:i}),...f})});p.classes=c,p.displayName="@mantine/core/CardSection";let f=(0,r.createVarsResolver)((e,{padding:t})=>({root:{"--card-padding":(0,i.getSpacing)(t)}})),g=(0,s.polymorphicFactory)((e,i)=>{let r=(0,o.useProps)("Card",null,e),{classNames:s,className:u,style:h,styles:g,unstyled:m,vars:v,children:y,padding:b,attributes:x,...w}=r,C=(0,a.useStyles)({name:"Card",props:r,classes:c,className:u,style:h,classNames:s,styles:g,unstyled:m,attributes:x,vars:v,varsResolver:f}),S=n.Children.toArray(y),_=S.map((e,t)=>"object"==typeof e&&e&&"type"in e&&e.type===p?(0,n.cloneElement)(e,{"data-first-section":0===t||void 0,"data-last-section":t===S.length-1||void 0}):e);return(0,t.jsx)(d,{value:{getStyles:C},children:(0,t.jsx)(l.Paper,{ref:i,unstyled:m,...C("root"),...w,children:_})})});
34g.classes=c,g.displayName="@mantine/core/Card",g.Section=p,e.s(["Card",()=>g],46388);var m=e.i(77219),v=e.i(1199),y=e.i(58525);let[b,x]=(0,y.createOptionalContext)();e.s(["PillsInputProvider",()=>b,"usePillsInputContext",()=>x],65457);var w={root:"m_7cda1cd6","root--default":"m_44da308b","root--contrast":"m_e3a01f8",label:"m_1e0e6180",remove:"m_ae386778",group:"m_1dcfd90b"};let[C,S]=(0,y.createOptionalContext)(),_=(0,r.createVarsResolver)((e,{gap:t},{size:n})=>({group:{"--pg-gap":void 0!==t?(0,i.getSize)(t):(0,i.getSize)(n,"pg-gap")}})),k=(0,m.factory)((e,n)=>{let i=(0,o.useProps)("PillGroup",null,e),{classNames:r,className:s,style:l,styles:d,unstyled:u,vars:c,size:p,disabled:f,attributes:g,...m}=i,v=x(),y=v?.size||p||void 0,b=(0,a.useStyles)({name:"PillGroup",classes:w,props:i,className:s,style:l,classNames:r,styles:d,unstyled:u,attributes:g,vars:c,varsResolver:_,stylesCtx:{size:y},rootSelector:"group"});return(0,t.jsx)(C,{value:{size:y,disabled:f},children:(0,t.jsx)(h.Box,{ref:n,size:y,...b("group"),...m})})});k.classes=w,k.displayName="@mantine/core/PillGroup";let M={variant:"default"},T=(0,r.createVarsResolver)((e,{radius:t},{size:n})=>({root:{"--pill-fz":(0,i.getSize)(n,"pill-fz"),"--pill-height":(0,i.getSize)(n,"pill-height"),"--pill-radius":void 0===t?void 0:(0,i.getRadius)(t)}})),D=(0,m.factory)((e,n)=>{let i=(0,o.useProps)("Pill",M,e),{classNames:r,className:s,style:l,styles:d,unstyled:u,vars:c,variant:p,children:f,withRemoveButton:g,onRemove:m,removeButtonProps:y,radius:b,size:C,disabled:_,mod:k,attributes:D,...R}=i,I=S(),A=x(),P=C||I?.size||void 0,E=A?.variant==="filled"?"contrast":p||"default",L=(0,a.useStyles)({name:"Pill",classes:w,props:i,className:s,style:l,classNames:r,styles:d,unstyled:u,attributes:D,vars:c,varsResolver:T,stylesCtx:{size:P}});return(0,t.jsxs)(h.Box,{component:"span",ref:n,variant:E,size:P,...L("root",{variant:E}),mod:[{"with-remove":g&&!_,disabled:_||I?.disabled},k],...R,children:[(0,t.jsx)("span",{...L("label"),children:f}),g&&(0,t.jsx)(v.CloseButton,{variant:"transparent",radius:b,tabIndex:-1,"aria-hidden":!0,unstyled:u,...y,...L("remove",{className:y?.className,style:y?.style}),onMouseDown:e=>{e.preventDefault(),e.stopPropagation(),y?.onMouseDown?.(e)},onClick:e=>{e.stopPropagation(),m?.(),y?.onClick?.(e)}})]})});D.classes=w,D.displayName="@mantine/core/Pill",D.Group=k,e.s(["Pill",()=>D],48159);var R=e.i(63584);let I=(e,t)=>{let n=new Date;e&&(n=new Date(e));let i=n.getMonth(),r=n.getDate(),o=i+1<10?`0${i+1}`:i+1,a=r<10?`0${r}`:r,s=n.getFullYear(),l=(0,R.getLang)();if(t&&"month-word"===t){let e={nl:["januari","februari","maart","april","mei","juni","juli","augustus","september","oktober","november","december"],en:["january","february","march","april","may","june","july","august","september","october","november","december"],de:["januar","februar","märz","april","mai","juni","juli","august","september","oktober","november","dezember"],es:["enero","febrero","marzo","abril","mayo","junio","julio","agosto","septiembre","octubre","noviembre","diciembre"],it:["gennaio","febbraio","marzo","aprile","maggio","giugno","luglio","agosto","settembre","ottobre","novembre","dicembre"],fr:["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"],ma:["ÙÙØ§Ùر","ÙØ¨Ø±Ø§Ùر","Ù
ارس","أبرÙÙ","Ù
اÙÙ","ÙÙÙÙÙ","ÙÙÙÙÙ","أغسطس","سبتÙ
بر","Ø£ÙØªÙبر","ÙÙÙÙ
بر","Ø¯ÙØ³Ù
بر"],pt:["janeiro","fevereiro","março","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro"],tr:["ocak","Åubat","mart","nisan","mayıs","haziran","temmuz","aÄustos","eylül","ekim","kasım","aralık"],zh:["䏿","äºæ","䏿","åæ","äºæ","å
æ","䏿","å
«æ","乿","åæ","å䏿","åäºæ"]},t=e[l||"en"]?.[i]||e.en[i];return`${r} ${t} ${s}`}return t&&"reversed"===t?`${s}-${o}-${a}`:`${o}/${a}/${s}`};var A=e.i(1920);e.s(["Date",0,e=>{let{className:i}=e,[r,o]=(0,n.useState)(e.date),[a,s]=(0,n.useState)(e.date);return(0,n.useEffect)(()=>{o(I(e.date,"month-word")),s(I(e.date,"reversed"))},[e.date]),(0,t.jsxs)("time",{className:i,dateTime:a,children:[(0,t.jsx)(A.default,{}),(0,t.jsx)("span",{children:r})]})}],58165),e.s(["getEmbedUrl",0,({url:e,autoplay:t=!1,mute:n=!1,loop:i=!1,controls:r=!1,disableKeyboard:o=!1,playsinline:a=!1})=>{if(e.includes("youtube.com/watch")){let s=new URL(e).searchParams.get("v")?.split("?")[0];return`https://www.youtube.com/embed/${s}?autoplay=${Number(t)}&controls=${Number(r)}&mute=${Number(n)}&loop=${Number(i)}&disablekb=${Number(o)}&playsinline=${Number(a)}&rel=0${i?`&playlist=${s}`:""}`}if(e.includes("youtu.be/")){let s=e.split("youtu.be/")[1].split("?")[0];return`https://www.youtube.com/embed/${s}?autoplay=${Number(t)}&controls=${Number(r)}&mute=${Number(n)}&loop=${Number(i)}&disablekb=${Number(o)}&playsinline=${Number(a)}&rel=0${i?`&playlist=${s}`:""}`}if(e.includes("youtube.com/playlist")){let s=new URL(e).searchParams.get("list")?.split("?")[0];return`https://www.youtube.com/embed/videoseries?autoplay=${Number(t)}&controls=${Number(r)}&mute=${Number(n)}&loop=${Number(i)}&disablekb=${Number(o)}&playsinline=${Number(a)}&list=${s}`}if(e.includes("vimeo.com/")){let o=new URL(e),a=(o.pathname.split("/video/")[1]||o.pathname.split("/")[1])?.split("?")[0],s=o.searchParams.get("h");return`https://player.vimeo.com/video/${a}?${s?`h=${s}&`:""}autoplay=${Number(t)}&controls=${Number(r)}&muted=${Number(n)}&loop=${Number(i)}`}return e}],47973);var P=e.i(38498);let E=({className:e})=>(0,t.jsx)("svg",{className:e,xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 20 16",children:(0,t.jsx)("path",{fill:"currentColor",d:"M18,0H2A2,2,0,0,0,.01,2L0,14a2.006,2.006,0,0,0,2,2H18a2.006,2.006,0,0,0,2-2V2A2.006,2.006,0,0,0,18,0Zm0,14H2V4l8,5,8-5ZM10,7,2,2H18Z"})});e.s(["default",0,E],25445);var L=e.i(57710),F=e.i(29197),O=Object.defineProperty,N=Object.defineProperties,B=Object.getOwnPropertyDescriptors,z=Object.getOwnPropertySymbols,j=Object.prototype.hasOwnProperty,V=Object.prototype.propertyIsEnumerable,H=(e,t,n)=>t in e?O(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,G=(e,t)=>{for(var n in t||(t={}))j.call(t,n)&&H(e,n,t[n]);if(z)for(var n of z(t))V.call(t,n)&&H(e,n,t[n]);return e},W=(e,t)=>{var n={};for(var i in e)j.call(e,i)&&0>t.indexOf(i)&&(n[i]=e[i]);if(null!=e&&z)for(var i of z(e))0>t.indexOf(i)&&V.call(e,i)&&(n[i]=e[i]);return n};function $(e){var{bgStyle:i={}
34,borderRadius:r=0,children:o,color:a,iconFillColor:s="white",round:l=!1,size:d=64}=e,u=W(e,["bgStyle","borderRadius","children","color","iconFillColor","round","size"]);let c=n.Children.map(o,e=>(0,n.isValidElement)(e)&&void 0===e.props.fill?(0,n.cloneElement)(e,{fill:s}):e);return(0,t.jsxs)("svg",N(G({viewBox:"0 0 64 64",width:d,height:d},u),B({children:[l?(0,t.jsx)("circle",{cx:"32",cy:"32",r:"32",fill:a,style:i}):(0,t.jsx)("rect",{width:"64",height:"64",rx:r,ry:r,fill:a,style:i}),c]})))}class U extends Error{constructor(e){super(e),this.name="AssertionError"}}function q(e,t){if(!e)throw new U(t)}function K(e){let t=Object.entries(e).filter(([,e])=>null!=e).map(([e,t])=>`${encodeURIComponent(e)}=${encodeURIComponent(String(t))}`);return t.length>0?`?${t.join("&")}`:""}let Y={bluesky:"Share on Bluesky",email:"Share by email",facebook:"Share on Facebook",facebookmessenger:"Share in Messenger",gab:"Share on Gab",hatena:"Share on Hatena",instapaper:"Save to Instapaper",line:"Share on Line",linkedin:"Share on LinkedIn",livejournal:"Share on LiveJournal",mailru:"Share on Mail.ru",ok:"Share on OK",pinterest:"Pin on Pinterest",pocket:"Save to Pocket",reddit:"Share on Reddit",telegram:"Share on Telegram",threads:"Share on Threads",tumblr:"Share on Tumblr",twitter:"Share on X",viber:"Share on Viber",vk:"Share on VK",weibo:"Share on Weibo",whatsapp:"Share on WhatsApp",workplace:"Share on Workplace"};function Z(e){let i,r;var{"aria-label":o,"aria-labelledby":a,beforeOnClick:s,children:l,className:d,disabled:u,disabledStyle:c={opacity:.6},forwardedRef:h,htmlTitle:p,networkLink:f,networkName:g,onClick:m,onShareWindowClose:v,openShareDialogOnClick:y=!0,opts:b,resetButtonStyle:x=!0,style:w,title:C,type:S="button",url:_,windowHeight:k=400,windowPosition:M="windowCenter",windowWidth:T=550}=e,D=W(e,["aria-label","aria-labelledby","beforeOnClick","children","className","disabled","disabledStyle","forwardedRef","htmlTitle","networkLink","networkName","onClick","onShareWindowClose","openShareDialogOnClick","opts","resetButtonStyle","style","title","type","url","windowHeight","windowPosition","windowWidth"]);let R=function(e){var t;let i=n.Children.toArray(e);if(1!==i.length)return;let[r]=i;if((0,n.isValidElement)(r))return r.props.round?"50%":null!=(t=r.props.borderRadius)?t:0}(l),I=o||a||function e(t){return n.Children.toArray(t).some(t=>"string"==typeof t?t.trim().length>0:"number"==typeof t||!!(0,n.isValidElement)(t)&&e(t.props.children))}(l)?void 0:Y[g],A=async e=>{if(u)return;let t=f(_,b);if(e.preventDefault(),s){let e=s();e&&("object"==typeof e||"function"==typeof e)&&"then"in e&&"function"==typeof e.then&&await e}y&&!function(e,t,n){var{height:i,width:r}=t;let o=G({height:i,width:r,location:"no",toolbar:"no",status:"no",directories:"no",menubar:"no",scrollbars:"yes",resizable:"no",centerscreen:"yes",chrome:"yes"},W(t,["height","width"])),a=window.open(e,"",Object.keys(o).map(e=>`${e}=${o[e]}`).join(", "));if(n){let e=window.setInterval(()=>{try{(null===a||a.closed)&&(window.clearInterval(e),n(a))}catch(e){console.error(e)}},1e3)}}(t,G({height:k,width:T},"windowCenter"===M?{left:window.outerWidth/2+(window.screenX||window.screenLeft||0)-T/2,top:window.outerHeight/2+(window.screenY||window.screenTop||0)-k/2}:{top:(window.screen.height-k)/2,left:(window.screen.width-T)/2}),v);m&&m(e,t)},P=(0,L.default)("react-share__ShareButton",{"react-share__ShareButton--disabled":!!u,disabled:!!u},d),E=x?G(G({backgroundColor:"transparent",border:"none",padding:0,display:"inline-flex",borderRadius:R,outlineOffset:2,font:"inherit",color:"inherit",cursor:"pointer"},w),u&&c):G(G({},w),u&&c);return(0,t.jsx)("button",(i=G({},D),r={"aria-label":o||I,"aria-labelledby":a,className:P,disabled:u,onClick:A,ref:h,style:E,title:p,type:S,children:l},N(i,B(r))))}function X(e,{title:t,separator:n}){return q(e,"bluesky.url"),"https://bsky.app/intent/compose"+K({text:t?t+n+e:e})}function J(e,{subject:t,body:n,separator:i}){return"mailto:"+K({subject:t,body:n?n+i+e:e})}function Q(e){return(0,t.jsx)($,N(G({color:"#0866FF"},e),B({children:(0,t.jsx)("path",{d:"M34.1,47V33.3h4.6l0.7-5.3h-5.3v-3.4c0-1.5,0.4-2.6,2.6-2.6l2.8,0v-4.8c-0.5-0.1-2.2-0.2-4.1-0.2 c-4.1,0-6.9,2.5-6.9,7V28H24v5.3h4.6V47H34.1z"})})))}function ee(e,{appId:t,redirectUri:n,to:i}){return"https://www.facebook.com/dialog/send"+K({link:e,redirect_uri:n||e,app_id:t,to:i})}function et(e,{hashtag:t}){return q(e,"facebook.url"),"https://www.facebook.com/sharer/sharer.php"+K({u:e,hashtag:t})}(0,n.forwardRef)((e,n)=>{var{separator:i,title:r}=e,o=W(e,["separator","title"]);return(0,t.jsx)(Z,N(G({},o),B({forwardedRef:n,networkName:"bluesky",networkLink:X,opts:{title:r,separator:i||" "},windowHeight:460,windowPosition:"windowCenter",windowWidth:660})))}).displayName="BlueskyShareButton",(0,n.forwardRef)((e,n)=>{var{body:i,separator:r,subject:o}=e,a=W(e,["body","separator","subject"]);return(0,t.jsx)(Z,N(G({},a),B({forwardedRef:n,networkName:"email",networkLink:J,onClick:(e,t)=>{window.location.href=t},openShareDialogOnClick:!1,opts:{subject:o,body:i,separator:r||" "}}
34)))}).displayName="EmailShareButton",(0,n.forwardRef)((e,n)=>{var{appId:i,redirectUri:r,to:o}=e,a=W(e,["appId","redirectUri","to"]);return(0,t.jsx)(Z,N(G({},a),B({forwardedRef:n,networkName:"facebookmessenger",networkLink:ee,opts:{appId:i,redirectUri:r,to:o},windowHeight:820,windowWidth:1e3})))}).displayName="FacebookMessengerShareButton";let en=(0,n.forwardRef)((e,n)=>{var{hashtag:i}=e,r=W(e,["hashtag"]);return(0,t.jsx)(Z,N(G({},r),B({forwardedRef:n,networkName:"facebook",networkLink:et,opts:{hashtag:i},windowHeight:400,windowWidth:550})))});function ei(e){let i;var{children:r=e=>e,className:o,getCount:a,url:s}=e,l=W(e,["children","className","getCount","url"]);let d=(i=(0,n.useRef)(!1),(0,n.useEffect)(()=>(i.current=!0,()=>{i.current=!1}),[]),(0,n.useCallback)(()=>i.current,[])),[u,c]=(0,n.useState)(void 0),[h,p]=(0,n.useState)(!1);return(0,n.useEffect)(()=>{p(!0),a(s,e=>{d()&&(c(e),p(!1))})},[s]),(0,t.jsx)("span",N(G({className:(0,L.default)("react-share__ShareCount",o)},l),B({children:!h&&void 0!==u&&r(u)})))}function er(e){let n=n=>(0,t.jsx)(ei,G({getCount:e},n));return n.displayName=`ShareCount(${e.name})`,n}function eo(e,{title:t}){return q(e,"hatena.url"),`http://b.hatena.ne.jp/add?mode=confirm&url=${e}&title=${t}`}function ea(e,{title:t,description:n}){return q(e,"instapaper.url"),"http://www.instapaper.com/hello2"+K({url:e,title:t,description:n})}function es(e,{title:t}){return q(e,"line.url"),"https://social-plugins.line.me/lineit/share"+K({url:e,text:t})}function el(e){return(0,t.jsx)($,N(G({color:"#0077B5"},e),B({children:(0,t.jsx)("path",{d:"M20.4,44h5.4V26.6h-5.4V44z M23.1,18c-1.7,0-3.1,1.4-3.1,3.1c0,1.7,1.4,3.1,3.1,3.1 c1.7,0,3.1-1.4,3.1-3.1C26.2,19.4,24.8,18,23.1,18z M39.5,26.2c-2.6,0-4.4,1.4-5.1,2.8h-0.1v-2.4h-5.2V44h5.4v-8.6 c0-2.3,0.4-4.5,3.2-4.5c2.8,0,2.8,2.6,2.8,4.6V44H46v-9.5C46,29.8,45,26.2,39.5,26.2z"})})))}function ed(e,{title:t,summary:n,source:i}){return q(e,"linkedin.url"),"https://linkedin.com/shareArticle"+K({url:e,mini:"true",title:t,summary:n,source:i})}en.displayName="FacebookShareButton",er(function(e,t){let n=`https://graph.facebook.com/?id=${e}&fields=og_object{engagement}`;(0,F.default)(n,(e,n)=>{t(!e&&n&&n.og_object&&n.og_object.engagement?n.og_object.engagement.count:void 0)})}),(0,n.forwardRef)((e,n)=>{var{title:i}=e,r=W(e,["title"]);return(0,t.jsx)(Z,N(G({},r),B({forwardedRef:n,networkName:"hatena",networkLink:eo,opts:{title:i},windowHeight:460,windowPosition:"windowCenter",windowWidth:660})))}).displayName="HatenaShareButton",er(function(e,t){(0,F.default)("https://bookmark.hatenaapis.com/count/entry"+K({url:e}),(e,n)=>{t(null!=n?n:void 0)})}),(0,n.forwardRef)((e,n)=>{var{description:i,title:r}=e,o=W(e,["description","title"]);return(0,t.jsx)(Z,N(G({},o),B({forwardedRef:n,networkName:"instapaper",networkLink:ea,opts:{title:r,description:i},windowHeight:500,windowPosition:"windowCenter",windowWidth:500})))}).displayName="InstapaperShareButton",(0,n.forwardRef)((e,n)=>{var{title:i}=e,r=W(e,["title"]);return(0,t.jsx)(Z,N(G({},r),B({forwardedRef:n,networkName:"line",networkLink:es,opts:{title:i},windowHeight:500,windowWidth:500})))}).displayName="LineShareButton";let eu=(0,n.forwardRef)((e,n)=>{var{source:i,summary:r,title:o}=e,a=W(e,["source","summary","title"]);return(0,t.jsx)(Z,N(G({},a),B({forwardedRef:n,networkName:"linkedin",networkLink:ed,opts:{title:o,summary:r,source:i},windowHeight:600,windowWidth:750})))});function ec(e,{title:t,description:n}){return q(e,"livejournal.url"),"https://www.livejournal.com/update.bml"+K({subject:t,event:n})}function eh(e,{title:t,description:n,imageUrl:i}){return q(e,"mailru.url"),"https://connect.mail.ru/share"+K({url:e,title:t,description:n,image_url:i})}function ep(e,{title:t,description:n,image:i}){return q(e,"ok.url"),"https://connect.ok.ru/offer"+K({url:e,title:t,description:n,imageUrl:i})}function ef(e,{media:t,description:n,pinId:i}){return i?`https://pinterest.com/pin/${i}/repin/x/`:(q(e,"pinterest.url"),q(t,"pinterest.media"),"https://pinterest.com/pin/create/button/"+K({url:e,media:t,description:n}))}function eg(e,{title:t}){return q(e,"pocket.url"),"https://getpocket.com/save"+K({url:e,title:t})}function em(e){return(0,t.jsx)($,N(G({color:"#FF4500"},e),B({children:(0,t.jsx)("path",{d:"M 53.34375 32 C 53.277344 30.160156 52.136719 28.53125 50.429688 27.839844 C 48.722656 27.148438 46.769531 27.523438 45.441406 28.8
3400781 C 41.800781 26.324219 37.519531 24.957031 33.121094 24.863281 L 35.199219 14.878906 L 42.046875 16.320312 C 42.214844 17.882812 43.496094 19.09375 45.066406 19.171875 C 46.636719 19.253906 48.03125 18.183594 48.359375 16.644531 C 48.6875 15.105469 47.847656 13.558594 46.382812 12.992188 C 44.914062 12.425781 43.253906 13.007812 42.464844 14.367188 L 34.625 12.800781 C 34.363281 12.742188 34.09375 12.792969 33.871094 12.9375 C 33.648438 13.082031 33.492188 13.308594 33.441406 13.566406 L 31.070312 24.671875 C 26.617188 24.738281 22.277344 26.105469 18.59375 28.609375 C 17.242188 27.339844 15.273438 26.988281 13.570312 27.707031 C 11.863281 28.429688 10.746094 30.089844 10.71875 31.941406 C 10.691406 33.789062 11.757812 35.484375 13.441406 36.257812 C 13.402344 36.726562 13.402344 37.195312 13.441406 37.664062 C 13.441406 44.832031 21.792969 50.65625 32.097656 50.65625 C 42.398438 50.65625 50.753906 44.832031 50.753906 37.664062 C 50.789062 37.195312 50.789062 36.726562 50.753906 36.257812 C 52.363281 35.453125 53.371094 33.800781 53.34375 32 Z M 21.34375 35.199219 C 21.34375 33.433594 22.777344 32 24.542969 32 C 26.3125 32 27.742188 33.433594 27.742188 35.199219 C 27.742188 36.96875 26.3125 38.398438 24.542969 38.398438 C 22.777344 38.398438 21.34375 36.96875 21.34375 35.199219 Z M 39.9375 44 C 37.664062 45.710938 34.871094 46.582031 32.03125 46.464844 C 29.191406 46.582031 26.398438 45.710938 24.128906 44 C 23.847656 43.65625 23.871094 43.15625 24.183594 42.839844 C 24.5 42.527344 25 42.503906 25.34375 42.785156 C 27.269531 44.195312 29.617188 44.90625 32 44.800781 C 34.386719 44.929688 36.746094 44.242188 38.6875 42.847656 C 39.042969 42.503906 39.605469 42.511719 39.953125 42.863281 C 40.296875 43.21875 40.289062 43.785156 39.9375 44.128906 Z M 39.359375 38.527344 C 37.59375 38.527344 36.160156 37.09375 36.160156 35.328125 C 36.160156 33.5625 37.59375 32.128906 39.359375 32.128906 C 41.128906 32.128906 42.558594 33.5625 42.558594 35.328125 C 42.59375 36.203125 42.269531 37.054688 41.65625 37.6875 C 41.046875 38.316406 40.203125 38.664062 39.328125 38.65625 Z M 39.359375 38.527344"})})))}function ev(e,{title:t}){return q(e,"reddit.url"),"https://www.reddit.com/submit"+K({url:e,title:t})}eu.displayName="LinkedinShareButton",(0,n.forwardRef)((e,n)=>{var{description:i,title:r}=e,o=W(e,["description","title"]);return(0,t.jsx)(Z,N(G({},o),B({forwardedRef:n,networkName:"livejournal",networkLink:ec,opts:{title:r,description:i},windowHeight:460,windowWidth:660})))}).displayName="LivejournalShareButton",(0,n.forwardRef)((e,n)=>{var{description:i,imageUrl:r,title:o}=e,a=W(e,["description","imageUrl","title"]);return(0,t.jsx)(Z,N(G({},a),B({forwardedRef:n,networkName:"mailru",networkLink:eh,opts:{title:o,description:i,imageUrl:r},windowHeight:460,windowWidth:660})))}).displayName="MailruShareButton",(0,n.forwardRef)((e,n)=>{var{description:i,image:r,title:o}=e,a=W(e,["description","image","title"]);return(0,t.jsx)(Z,N(G({},a),B({forwardedRef:n,networkName:"ok",networkLink:ep,opts:{title:o,description:i,image:r},windowHeight:480,windowPosition:"screenCenter",windowWidth:588})))}).displayName="OKShareButton",er(function(e,t){window.OK||(window.OK={Share:{count:function(e,t){var n,i;null==(i=(n=window.OK.callbacks)[e])||i.call(n,t)}},callbacks:[]});let n=window.OK.callbacks.length;return window.ODKL={updateCount(e,t){var n,i;let r=""===e?0:parseInt(e.replace("react-share-",""),10);null==(i=(n=window.OK.callbacks)[r])||i.call(n,""===t?void 0:parseInt(t,10))}},window.OK.callbacks.push(t),(0,F.default)("https://connect.ok.ru/dk"+K({"st.cmd":"extLike",uid:`react-share-${n}`,ref:e}))}),(0,n.forwardRef)((e,n)=>{var{description:i,media:r,pinId:o}=e,a=W(e,["description","media","pinId"]);return(0,t.jsx)(Z,N(G({},a),B({forwardedRef:n,networkName:"pinterest",networkLink:ef,opts:{media:r,description:i,pinId:o},windowHeight:730,windowWidth:1e3})))}).displayName="PinterestShareButton",er(function(e,t){(0,F.default)("https://api.pinterest.com/v1/urls/count.json"+K({url:e}),(e,n)=>{t(n?n.count:void 0)})}),(0,n.forwardRef)((e,n)=>{var{title:i}=e,r=W(e,["title"]);return(0,t.jsx)(Z,N(G({},r),B({forwardedRef:n,networkName:"pocket",networkLink:eg,opts:{title:i},windowHeight:500,windowWidth:500})))}).displayName="PocketShareButton";let ey=(0,n.forwardRef)((e,n)=>{var{title:i}=e,r=W(e,["title"]);return(0,t.jsx)(Z,N(G({},r),B({forwardedRef:n,networkName:"reddit",networkLink:ev,opts:{title:i},windowHeight:460,windowPosition:"windowCenter",windowWidth:660})))});function eb(e,{title:t}){return q(e,"gab.url"),"https://gab.com/compose"+K({url:e,text:t})}function ex(e,{title:t}){return q(e,"telegram.url"),"https://telegram.me/share/url"+K({url:e,text:t})}function ew(e){return(0,t.jsx)($,N(G({color:"#000000"},e),B({children:(0,t.jsx)("path",{d:"M41.4569 31.0027C41.2867 30.9181 41.1138 30.8366 40.9386 30.7586C40.6336 24.9274 37.5624 21.5891 32.4055 21.5549C32.3821 21.5548 32.3589 21.5548 32.3355 21.5548C29.251 21.5548 26.6857 22.9207 25.1067 25.4063L27.9429 27.4247C29.1224 25.5681 30.9736 25.1723 32.3369 25.1723C32.3526 25.1723 32.3684 25.1723 32.384 25.1724C34.082 25.1837 35.3633 25.6958 36.1926 26.6947C36.7961 27.4218 37.1997 28.4267 37.3996 29.6949C35.8941 29.4294 34.266 29.3478 32.5255 29.4513C27.6225 29.7443 24.4705 32.711 24.6822 36.8332C24.7896 38.9242 25.7937 40.7231 27.5094 41.8982C28.96 42.8916 30.8282 43.3774 32.7699 43.2674C35.3341 43.1216 37.3456 42.1066 38.749 40.2507C39.8148 38.8413 40.4889 37.
340149 40.7865 34.7136C42.0085 35.4787 42.9142 36.4855 43.4144 37.6959C44.2649 39.7534 44.3145 43.1344 41.6553 45.8908C39.3255 48.3055 36.525 49.3501 32.2926 49.3824C27.5977 49.3463 24.0471 47.7842 21.7385 44.7396C19.5768 41.8886 18.4595 37.7706 18.4179 32.5C18.4595 27.2293 19.5768 23.1113 21.7385 20.2604C24.0471 17.2157 27.5977 15.6537 32.2925 15.6175C37.0215 15.654 40.634 17.2235 43.0309 20.2829C44.2062 21.7831 45.0923 23.6698 45.6764 25.8696L49 24.9496C48.2919 22.2419 47.1778 19.9087 45.6616 17.9736C42.5888 14.0514 38.0947 12.0417 32.3041 12H32.2809C26.5022 12.0415 22.0584 14.0589 19.073 17.9961C16.4165 21.4997 15.0462 26.3747 15.0001 32.4856L15 32.5L15.0001 32.5144C15.0462 38.6252 16.4165 43.5004 19.073 47.004C22.0584 50.941 26.5022 52.9586 32.2809 53H32.3041C37.4418 52.9631 41.0632 51.5676 44.0465 48.4753C47.9496 44.4297 47.8321 39.3587 46.5457 36.2457C45.6227 34.0134 43.8631 32.2002 41.4569 31.0027ZM32.5863 39.6551C30.4374 39.7807 28.205 38.78 28.0949 36.6367C28.0133 35.0476 29.185 33.2743 32.7182 33.0631C33.1228 33.0389 33.5199 33.027 33.9099 33.027C35.1933 33.027 36.3939 33.1564 37.4854 33.4039C37.0783 38.6788 34.6902 39.5353 32.5863 39.6551Z"})})))}function eC(e,{title:t}){return q(e,"threads.url"),"https://threads.net/intent/post"+K({url:e,text:t})}ey.displayName="RedditShareButton",(0,n.forwardRef)((e,n)=>{var{title:i}=e,r=W(e,["title"]);return(0,t.jsx)(Z,N(G({},r),B({forwardedRef:n,networkName:"gab",networkLink:eb,opts:{title:i},windowHeight:640,windowPosition:"windowCenter",windowWidth:660})))}).displayName="GabShareButton",er(function(e,t){let n=`https://www.reddit.com/api/info.json?limit=1&url=${e}`;(0,F.default)(n,{param:"jsonp"},(e,n)=>{t(!e&&n&&n.data&&n.data.children.length>0&&n.data.children[0].data.score?n.data.children[0].data.score:void 0)})}),(0,n.forwardRef)((e,n)=>{var{title:i}=e,r=W(e,["title"]);return(0,t.jsx)(Z,N(G({},r),B({forwardedRef:n,networkName:"telegram",networkLink:ex,opts:{title:i},windowHeight:400,windowWidth:550})))}).displayName="TelegramShareButton";let eS=(0,n.forwardRef)((e,n)=>{var{hashtags:i,related:r,title:o,via:a}=e,s=W(e,["hashtags","related","title","via"]);return(0,t.jsx)(Z,N(G({},s),B({forwardedRef:n,networkName:"threads",networkLink:eC,opts:{title:o},windowHeight:600,windowWidth:550})))});function e_(e){return(0,t.jsx)($,N(G({color:"#36465D"},e),B({children:(0,t.jsx)("path",{d:"M39.2,41c-0.6,0.3-1.6,0.5-2.4,0.5c-2.4,0.1-2.9-1.7-2.9-3v-9.3h6v-4.5h-6V17c0,0-4.3,0-4.4,0 c-0.1,0-0.2,0.1-0.2,0.2c-0.3,2.3-1.4,6.4-5.9,8.1v3.9h3V39c0,3.4,2.5,8.1,9,8c2.2,0,4.7-1,5.2-1.8L39.2,41z"})})))}function ek(e,{title:t,caption:n,tags:i,posttype:r}){return q(e,"tumblr.url"),"https://www.tumblr.com/widgets/share/tool"+K({canonicalUrl:e,title:t,caption:n,tags:i,posttype:r})}eS.displayName="ThreadsShareButton";let eM=(0,n.forwardRef)((e,n)=>{var{caption:i,posttype:r,tags:o,title:a}=e,s=W(e,["caption","posttype","tags","title"]);return(0,t.jsx)(Z,N(G({},s),B({forwardedRef:n,networkName:"tumblr",networkLink:ek,opts:{title:a,tags:(o||[]).join(","),caption:i,posttype:r||"link"},windowHeight:460,windowWidth:660})))});function eT(e,{title:t,via:n,hashtags:i=[],related:r=[]}){return q(e,"x.url"),q(Array.isArray(i),"x.hashtags is not an array"),q(Array.isArray(r),"x.related is not an array"),"https://twitter.com/intent/tweet"+K({url:e,text:t,via:n,hashtags:i.length>0?i.join(","):void 0,related:r.length>0?r.join(","):void 0})}eM.displayName="TumblrShareButton",er(function(e,t){return(0,F.default)("https://api.tumblr.com/v2/share/stats"+K({url:e}),(e,n)=>{t(!e&&n&&n.response?n.response.note_count:void 0)})});let eD=(0,n.forwardRef)((e,n)=>{var{hashtags:i,related:r,title:o,via:a}=e,s=W(e,["hashtags","related","title","via"]);return(0,t.jsx)(Z,N(G({},s),B({forwardedRef:n,networkName:"twitter",networkLink:eT,opts:{hashtags:i,title:o,via:a,related:r},windowHeight:400,windowWidth:550})))});eD.displayName="XShareButton";let eR=(0,n.forwardRef)((e,n)=>(0,t.jsx)(eD,N(G({},e),B({ref:n}))));function eI(e,{title:t,separator:n}){return q(e,"viber.url"),"viber://forward"+K({text:t?t+n+e:e})}function eA(e,{title:t,image:n,noParse:i,noVkLinks:r}){return q(e,"vk.url"),"https://vk.com/share.php"+K({url:e,title:t,image:n,noparse:+!!i,no_vk_links:+!!r})}function eP(e,{title:t,image:n}){return q(e,"weibo.url"),"http://service.weibo.com/share/share.php"+K({url:e,title:t,pic:n})}function eE(e){return(0,t.jsx)($,N(G({color:"#25D366"},e),B({children:(0,t.jsx)("path",{d:"m42.32286,33.93287c-0.5178,-0.2589 -3.04726,-1.49644 -3.52105,-1.66732c-0.4712,-0.17346 -0.81554,-0.2589 -1.15987,0.2589c-0.34175,0.51004 -1.33075,1.66474 -1.63108,2.00648c-0.30032,0.33658 -0.60064,0.36247 -1.11327,
340.12945c-0.5178,-0.2589 -2.17994,-0.80259 -4.14759,-2.56312c-1.53269,-1.37217 -2.56312,-3.05503 -2.86603,-3.57283c-0.30033,-0.5178 -0.03366,-0.80259 0.22524,-1.06149c0.23301,-0.23301 0.5178,-0.59547 0.7767,-0.90616c0.25372,-0.31068 0.33657,-0.5178 0.51262,-0.85437c0.17088,-0.36246 0.08544,-0.64725 -0.04402,-0.90615c-0.12945,-0.2589 -1.15987,-2.79613 -1.58964,-3.80584c-0.41424,-1.00971 -0.84142,-0.88027 -1.15987,-0.88027c-0.29773,-0.02588 -0.64208,-0.02588 -0.98382,-0.02588c-0.34693,0 -0.90616,0.12945 -1.37736,0.62136c-0.4712,0.5178 -1.80194,1.76053 -1.80194,4.27186c0,2.51134 1.84596,4.945 2.10227,5.30747c0.2589,0.33657 3.63497,5.51458 8.80262,7.74113c1.23237,0.5178 2.1903,0.82848 2.94111,1.08738c1.23237,0.38836 2.35599,0.33657 3.24402,0.20712c0.99159,-0.15534 3.04985,-1.24272 3.47963,-2.45956c0.44013,-1.21683 0.44013,-2.22654 0.31068,-2.45955c-0.12945,-0.23301 -0.46601,-0.36247 -0.98382,-0.59548m-9.40068,12.84407l-0.02589,0c-3.05503,0 -6.08417,-0.82849 -8.72495,-2.38189l-0.62136,-0.37023l-6.47252,1.68286l1.73463,-6.29129l-0.41424,-0.64725c-1.70875,-2.71846 -2.6149,-5.85116 -2.6149,-9.07706c0,-9.39809 7.68934,-17.06155 17.15993,-17.06155c4.58253,0 8.88029,1.78642 12.11655,5.02268c3.23625,3.21036 5.02267,7.50812 5.02267,12.06476c-0.0078,9.3981 -7.69712,17.06155 -17.14699,17.06155m14.58906,-31.58846c-3.93529,-3.80584 -9.1133,-5.95471 -14.62789,-5.95471c-11.36055,0 -20.60848,9.2065 -20.61625,20.52564c0,3.61684 0.94757,7.14565 2.75211,10.26282l-2.92557,10.63564l10.93337,-2.85309c3.0136,1.63108 6.4052,2.4958 9.85634,2.49839l0.01037,0c11.36574,0 20.61884,-9.2091 20.62403,-20.53082c0,-5.48093 -2.14111,-10.64081 -6.03239,-14.51915"})})))}function eL(e,{title:t,separator:n}){return q(e,"whatsapp.url"),"https://api.whatsapp.com/send"+K({text:t?t+n+e:e})}eR.displayName="TwitterShareButton",(0,n.forwardRef)((e,n)=>{var{separator:i,title:r}=e,o=W(e,["separator","title"]);return(0,t.jsx)(Z,N(G({},o),B({forwardedRef:n,networkName:"viber",networkLink:eI,opts:{title:r,separator:i||" "},windowHeight:460,windowWidth:660})))}).displayName="ViberShareButton",(0,n.forwardRef)((e,n)=>{var{image:i,noParse:r,noVkLinks:o,title:a}=e,s=W(e,["image","noParse","noVkLinks","title"]);return(0,t.jsx)(Z,N(G({},s),B({forwardedRef:n,networkName:"vk",networkLink:eA,opts:{title:a,image:i,noParse:r,noVkLinks:o},windowHeight:460,windowWidth:660})))}).displayName="VKShareButton",er(function(e,t){window.VK||(window.VK={}),window.VK.Share={count:(e,t)=>{var n,i;return null==(i=null==(n=window.VK.callbacks)?void 0:n[e])?void 0:i.call(n,t)}},window.VK.callbacks=[];let n=window.VK.callbacks.length;return window.VK.callbacks.push(t),(0,F.default)("https://vk.com/share.php"+K({act:"count",index:n,url:e}))}),(0,n.forwardRef)((e,n)=>{var{image:i,title:r}=e,o=W(e,["image","title"]);return(0,t.jsx)(Z,N(G({},o),B({forwardedRef:n,networkName:"weibo",networkLink:eP,opts:{title:r,image:i},windowHeight:550,windowPosition:"screenCenter",windowWidth:660})))}).displayName="WeiboShareButton";let eF=(0,n.forwardRef)((e,n)=>{var{separator:i,title:r}=e,o=W(e,["separator","title"]);return(0,t.jsx)(Z,N(G({},o),B({forwardedRef:n,networkName:"whatsapp",networkLink:eL,opts:{title:r,separator:i||" "},windowHeight:400,windowWidth:550})))});function eO(e,{quote:t,hashtag:n}){return q(e,"workplace.url"),"https://work.facebook.com/sharer.php"+K({u:e,quote:t,hashtag:n})}function eN(e){return(0,t.jsx)($,N(G({color:"#000000"},e),B({children:(0,t.jsx)("path",{d:"M 41.116 18.375 h 4.962 l -10.8405 12.39 l 12.753 16.86 H 38.005 l -7.821 -10.2255 L 21.235 47.625 H 16.27 l 11.595 -13.2525 L 15.631 18.375 H 25.87 l 7.0695 9.3465 z m -1.7415 26.28 h 2.7495 L 24.376 21.189 H 21.4255 z"})})))}eF.displayName="WhatsappShareButton",(0,n.forwardRef)((e,n)=>{var{hashtag:i,quote:r}=e,o=W(e,["hashtag","quote"]);return(0,t.jsx)(Z,N(G({},o),B({forwardedRef:n,networkName:"workplace",networkLink:eO,opts:{quote:r,hashtag:i},windowHeight:400,windowWidth:550})))}).displayName="WorkplaceShareButton",e.s(["FacebookIcon",()=>Q,"FacebookShareButton",()=>en,"LinkedinIcon",()=>el,"LinkedinShareButton",()=>eu,"RedditIcon",()=>em,"RedditShareButton",()=>ey,"ThreadsIcon",()=>ew,"ThreadsShareButton",()=>eS,"TumblrIcon",()=>e_,"TumblrShareButton",()=>eM,"TwitterShareButton",()=>eR,"WhatsappIcon",()=>eE,"WhatsappShareButton",()=>eF,"XIcon",()=>eN],28157);let eB={facebook:Q,instagram:({className:e})=>(0,t.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",height:"56.7px",id:"Layer_1",version:"1.1",viewBox:"3 3 51 51",width:"56.7px",className:e,children:(0,t.jsxs)("g",{children:[(0,t.jsx)("circle",{cx:"28.1",cy:"30",r:"4.4",fill:"
34currentColor"}),(0,t.jsx)("path",{d:"M33.6,19.2h-11c-1.6,0-3,0.5-3.9,1.4c-0.9,0.9-1.4,2.3-1.4,3.9v11c0,1.6,0.5,3,1.5,4c1,0.9,2.3,1.4,3.9,1.4h10.9 c1.6,0,3-0.5,3.9-1.4c1-0.9,1.5-2.3,1.5-3.9v-11c0-1.6-0.5-2.9-1.4-3.9C36.6,19.7,35.3,19.2,33.6,19.2z M28.1,36.8 c-3.8,0-6.8-3.1-6.8-6.8c0-3.8,3.1-6.8,6.8-6.8S35,26.2,35,30C35,33.8,31.9,36.8,28.1,36.8z M35.2,24.5c-0.9,0-1.6-0.7-1.6-1.6 s0.7-1.6,1.6-1.6s1.6,0.7,1.6,1.6S36.1,24.5,35.2,24.5z",fill:"currentColor"}),(0,t.jsx)("path",{d:"M28.3,5.2c-13.6,0-24.6,11-24.6,24.6c0,13.6,11,24.6,24.6,24.6c13.6,0,24.6-11,24.6-24.6C53,16.2,41.9,5.2,28.3,5.2z M41.4,35.6c0,2.3-0.8,4.3-2.2,5.7c-1.4,1.4-3.4,2.1-5.6,2.1H22.7c-2.2,0-4.2-0.7-5.6-2.1c-1.5-1.4-2.2-3.4-2.2-5.7v-11 c0-4.6,3.1-7.8,7.8-7.8h11c2.3,0,4.2,0.8,5.6,2.2c1.4,1.4,2.1,3.3,2.1,5.6V35.6z",fill:"currentColor"})]})}),linkedin:el,whatsapp:eE,xTwitter:eN,email:E,internet:({className:e})=>(0,t.jsx)("svg",{className:e,xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",width:"1em",height:"1em",id:"Layer_1",version:"1.1",viewBox:"0 0 512 512",children:(0,t.jsx)("path",{fill:"currentColor",d:"M352 256c0 22.2-1.2 43.6-3.3 64l-185.3 0c-2.2-20.4-3.3-41.8-3.3-64s1.2-43.6 3.3-64l185.3 0c2.2 20.4 3.3 41.8 3.3 64zm28.8-64l123.1 0c5.3 20.5 8.1 41.9 8.1 64s-2.8 43.5-8.1 64l-123.1 0c2.1-20.6 3.2-42 3.2-64s-1.1-43.4-3.2-64zm112.6-32l-116.7 0c-10-63.9-29.8-117.4-55.3-151.6c78.3 20.7 142 77.5 171.9 151.6zm-149.1 0l-176.6 0c6.1-36.4 15.5-68.6 27-94.7c10.5-23.6 22.2-40.7 33.5-51.5C239.4 3.2 248.7 0 256 0s16.6 3.2 27.8 13.8c11.3 10.8 23 27.9 33.5 51.5c11.6 26 20.9 58.2 27 94.7zm-209 0L18.6 160C48.6 85.9 112.2 29.1 190.6 8.4C165.1 42.6 145.3 96.1 135.3 160zM8.1 192l123.1 0c-2.1 20.6-3.2 42-3.2 64s1.1 43.4 3.2 64L8.1 320C2.8 299.5 0 278.1 0 256s2.8-43.5 8.1-64zM194.7 446.6c-11.6-26-20.9-58.2-27-94.6l176.6 0c-6.1 36.4-15.5 68.6-27 94.6c-10.5 23.6-22.2 40.7-33.5 51.5C272.6 508.8 263.3 512 256 512s-16.6-3.2-27.8-13.8c-11.3-10.8-23-27.9-33.5-51.5zM135.3 352c10 63.9 29.8 117.4 55.3 151.6C112.2 482.9 48.6 426.1 18.6 352l116.7 0zm358.1 0c-30 74.1-93.6 130.9-171.9 151.6c25.5-34.2 45.2-87.7 55.3-151.6l116.7 0z"})})};e.s(["SocialLinks",0,({links:e,className:n,iconClassName:i})=>e?(0,t.jsx)("div",{className:[P.default.socialLinks,n].filter(Boolean).join(" "),children:(0,t.jsx)(()=>e.map((e,n)=>{let{selectSocialLink:r,linkValue:o}=e,a=eB[r]??null;return(0,t.jsx)("span",{className:P.default.socialLink,style:{cursor:"pointer"},title:`Open ${r} â`,onClick:e=>{e.preventDefault(),e.stopPropagation(),window.open(o,"_blank","noopener,noreferrer")},children:a&&(0,t.jsx)(a,{className:[P.default.icon,i,P.default[`icon--${r}`]].filter(Boolean).join(" "),round:!0,size:32})},n)}),{})}):null],81315)},46707,e=>{e.v({content:"index-module-scss-module__RHC46a__content",divider:"index-module-scss-module__RHC46a__divider",hyperlink:"index-module-scss-module__RHC46a__hyperlink",pageRange:"index-module-scss-module__RHC46a__pageRange"})},30750,e=>{e.v({active:"index-module-scss-module__yOWhuq__active",ellipsis:"index-module-scss-module__yOWhuq__ellipsis",label:"index-module-scss-module__yOWhuq__label",navButton:"index-module-scss-module__yOWhuq__navButton",pageButton:"index-module-scss-module__yOWhuq__pageButton",pageNumbers:"index-module-scss-module__yOWhuq__pageNumbers",pagination:"index-module-scss-module__yOWhuq__pagination"})},97132,e=>{e.v({"archive-error":"index-module-scss-module__-UcvXG__archive-error",column:"index-module-scss-module__-UcvXG__column",grid:"index-module-scss-module__-UcvXG__grid",introContent:"index-module-scss-module__-UcvXG__introContent",list:"index-module-scss-module__-UcvXG__list",paginationContainer:"index-module-scss-module__-UcvXG__paginationContainer",resultCountWrapper:"index-module-scss-module__-UcvXG__resultCountWrapper",scrollRef:"index-module-scss-module__-UcvXG__scrollRef"})},38325,e=>{e.v({submenu:"index-module-scss-module__0QPyLG__submenu","submenu--left":"index-module-scss-module__0QPyLG__submenu--left","submenu--right":"index-module-scss-module__0QPyLG__submenu--right",submenu__item:"index-module-scss-module__0QPyLG__submenu__item",submenu__link:"index-module-scss-module__0QPyLG__submenu__link","submenu__link--active":"index-module-scss-module__0QPyLG__submenu__link--active",submenu__list:"index-module-scss-module__0QPyLG__submenu__list"})},16292,98583,69363,16069,4160,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(46388),r=e.i(3218),o=e.i(48159),a=e.i(17444),s=e.i(86577),l=e.i(86957),d=e.i(58165),u=e.i(90388),c=e.i(60872),h=e.i(47973),p=e.i(89343),f=e.i(81315),g=e.i(19250),m=e.i(5298);e.s(["SmartCard",0,({className:e,mediaType:v,mediaStyle:y,media:b,imageFit:x="cover",caption:w,video:C,textRich:S,titleRich:_,date:k,enableLink:M,cardLink:T,style:D,contentBackgroun
34dColor:R,categories:I,socialLinks:A,imageSizes:P,overlayHeight:E})=>{let{tenant:L}=(0,u.useTenant)(),F="hover"===D||"default"===D&&L.Theme?.defaultcardStyle==="hover",O=e=>[p.default[e]].filter(Boolean).join(" "),N=(0,n.useRef)(null),B=(0,m.hasRichTextContent)(S),z=(0,m.hasRichTextContent)(_),j=(0,m.hasRichTextContent)(w),V=C?(0,h.getEmbedUrl)({url:C,autoplay:!1,loop:!0,mute:!1,disableKeyboard:!0}):"",H=M&&T?.cardLink,G=w&&!F&&"media"==v,W=I?.length||A?.length||k;return(0,t.jsx)(({children:e})=>H?(0,t.jsx)(s.CMSLink,{...T,appearance:null,wrapperLink:T?.cardLink,className:p.default["card-link"],children:e}):(0,t.jsx)(t.Fragment,{children:e}),{children:(0,t.jsxs)(i.Card,{radius:(0,c.getRadius)(L.Theme?.borderRadius),padding:0,style:E?{"--card-overlay-height":`${E}rem`}:void 0,className:[e,p.default.card,F?p.default["card--border"]:p.default["card--border-light"],F?p.default["card--textOnHover"]:"",R?p.default[`card--${R}`]:""].filter(Boolean).join(" "),children:[(b||C)&&(0,t.jsx)(i.Card.Section,{className:[p.default.mediaSection,"withBorder"===y&&p.default["media--withBorder"]].filter(Boolean).join(" "),children:(0,t.jsxs)(r.Paper,{radius:"withBorder"===y?(0,c.getRadius)(L.Theme?.borderRadius):"round"===y?"50%":0,bg:"transparent",shadow:"none",className:[(b||C)&&p.default.media,"round"===y&&p.default["media--round"]].filter(Boolean).join(" "),children:["media"===v&&b&&(0,t.jsx)(a.Media,{className:p.default.img,resource:b,mediaFit:x,sizes:P??"100vw"}),"video"===v&&C&&(0,t.jsx)("div",{className:p.default.videoBlock,children:(0,t.jsx)("iframe",{className:p.default.iframe,src:V,title:"Embedded Video",frameBorder:"0",allow:"accelerometer; clipboard-write; encrypted-media; gyroscope; picture-in-picture"})})]})}),(B||k||z||M||w&&"media"==v&&j)&&(0,t.jsxs)("div",{className:[p.default.content,B?p.default["content--with-text"]:""].filter(Boolean).join(" "),children:[G&&(0,t.jsx)("div",{ref:N,className:[p.default.img_caption,!j?p.default["img_caption--hidden"]:""].filter(Boolean).join(" "),children:(0,t.jsx)(l.default,{content:w,excludeFromToc:!0})}),W&&(0,t.jsxs)("div",{className:O("meta"),children:[k&&(0,t.jsx)(d.Date,{date:k,className:p.default.date}),I?.length?(0,t.jsx)("div",{className:p.default.categories,children:I?.map((e,n)=>{let{title:i,label:r,color:a}=e,s=(0,g.getContrastingTextColor)(a||"")||"var(--c-primary)";return(0,t.jsx)(o.Pill,{styles:{root:{backgroundColor:a??void 0,border:a?void 0:"1px solid var(--c-secondary)"},label:{color:s}},children:r??(i||"")},n)})}):"",A&&A.length>0&&(0,t.jsx)(f.SocialLinks,{links:A,className:p.default.cardLinks,iconClassName:p.default.cardLinks__icon})]}),z&&(0,t.jsx)("div",{className:O("title"),children:(0,t.jsx)(l.default,{content:_,excludeFromToc:!0})}),(0,t.jsxs)("div",{className:p.default.bodyWrapper,children:[B&&(0,t.jsx)("div",{className:O("text"),children:(0,t.jsx)(l.default,{content:S,excludeFromToc:!0})}),M&&!T?.cardLink&&(0,t.jsx)("div",{className:[p.default["link-wrapper"]].filter(Boolean).join(" "),children:(0,t.jsx)(s.CMSLink,{className:[p.default.link,T?.appearance==="arrow"?p.default["link--arrow"]:""].filter(Boolean).join(" "),...T})})]})]})]})})}],16292);var v=e.i(46707);e.s(["PageRange",0,e=>{let{className:n,currentPage:i,limit:r,totalDocs:o=0}=e,a=(i?i-1:1)*(r||1)+1;o&&a>o&&(a=0);let s=(i||1)*(r||1);return o&&s>o&&(s=o),(0,t.jsx)("p",{className:[v.default.pageRange,n].join(" "),children:void 0===o||0===o?"...":`Item ${a}..${s} / ${o}`})}],98583);var y=e.i(30750);e.s(["Pagination",0,e=>{let{page:n,totalPages:i,onClick:r,className:o}=e;return(0,t.jsxs)("div",{className:[y.default.pagination,o].filter(Boolean).join(" "),children:[(0,t.jsx)("button",{type:"button",className:y.default.navButton,disabled:1===n,onClick:()=>r(1),children:"âª"}),(0,t.jsx)("button",{type:"button",className:y.default.navButton,disabled:1===n,onClick:()=>r(n-1),children:"â¨"}),(0,t.jsx)("div",{className:y.default.pageNumbers,children:(i<=5?Array.from({length:i},(e,t)=>t+1):n<=2?[1,2,"â¦",i]:n>=i-1?[1,"â¦",i-1,i]:[1,"â¦",n,"â¦",i]).map((e,i)=>"â¦"===e?(0,t.jsx)("span",{className:y.default.ellipsis,children:"â¦"},`ellipsis-${i}`):(0,t.jsx)("button",{type:"button",className:`${y.default.pageButton} ${e===n?y.default.active:""}`,onClick:()=>r(e),children:e},e))}),(0,t.jsx)("button",{type:"button",className:y.default.navButton,disabled:n===i,onClick:()=>r(n+1),children:"â©"}),(0,t.jsx)("button",{type:"button",className:y.default.navButton,disabled:n===i,onClick:()=>r(i),children:"â«"})]})}],69363);let b={src:e.i(48488).default,width:512,height:512,blurWidth:0,blurHeight:0};e.s(["default",0,b],16069);let x=` 35 tenant { 36 domain 37 } 38 mimeType 39 filename 40 prefix 41 width 42 height 43 alt 44 focalX 45 focalY 46 sizes { 47 card { 48 filename 49 width 50 height 51 } 52 } 53`,w=` 54 query PostsArchive($where: Post_where, $limit: Int, $page: Int, $sort: String, $locale: LocaleInputType, $fallbackLocale: FallbackLocaleInputType) { 55 Posts(where: $where, limit: $limit, page: $page, sort: $sort, locale: $locale, fallbackLocale: $fallbackLocale) { 56 docs { 57 id 58 slug 59 title 60 summary 61 publishedAt 62 eventDate 63 categories { 64 id 65 title 66 label 67 color 68 } 69 meta { 70 image { 71 ${x} 72 } 73 } 74 hero { 75 heroImage { 76 ${x} 77 } 78 } 79 postType (locale: $locale, fallbackLocale: $fallbackLocale) { 80 id 81 isEventType 82 showDate 83 } 84 } 85 totalDocs 86 totalPages 87 page 88 hasNextPage 89 hasPrevPage 90 nextPage 91 prevPage 92 } 93 } 94`,C=` 95 query DirectoryArchive($where: Directory_where, $limit: Int, $page: Int, $sort: String, $locale: LocaleInputType, $fallbackLocale: FallbackLocaleInputType) { 96 Directories(where: $where, limit: $limit, page: $page, sort: $sort, locale: $locale, fallbackLocale: $fallbackLocale) { 97 docs { 98 id 99 name 100 website 101 type 102 updatedAt 103 ggzProfiel { 104 locatie 105 extraTaal 106 extraTaalRaw 107 zorgdomein 108 } 109 ggzAanbod { 110 typeZorg 111 zorgsetting 112 zorgvorm 113 diagnostiek 114 doelgroepLeeftijd 115 klachtenDiagnoses 116 behandelmethode 117 expertise 118 exclusiecriteria 119 primaireBehandelkader 120 lastCheckedAt 121 lastCheckOutcome 122 lastCheckPublicSummary 123 } 124 ggzWachttijd { 125 wachttijdBggz 126 wachttijdBggzWeken 127 wachttijdBggzStatus 128 wachttijdSggz 129 wachttijdSggzWeken 130 wachttijdSggzStatus 131 wachttijdKind 132 wachttijdKindWeken 133 wachttijdKindStatus 134 lastCheckedAt 135 lastCheckOutcome 136 lastCheckPublicSummary 137 } 138 verzekeringen { 139 insurerStatuses { 140 status 141 note 142 insurer { 143 id 144 name 145 } 146 } 147 contractJeugdzorgGemeente 148 lastCheckedAt 149 lastCheckOutcome 150 lastCheckPublicSummary 151 } 152 begeleidingProfiel { 153 locatie 154 extraTaal 155 } 156 begeleidingAanbod { 157 leeftijd 158 doelgroep 159 hulpvragenThemas 160 typeBegeleiding 161 zorgvorm 162 begeleidingsmethode 163 setting 164 } 165 financiering { 166 financiering 167 } 168 begeleidingWachttijd { 169 wachttijd 170 } 171 zelfhulpAanbod { 172 thema 173 specifiekeDoelgroep 174 welkMiddel 175 wat 176 } 177 } 178 totalDocs 179 totalPages 180 page 181 hasNextPage 182 hasPrevPage 183 nextPage 184 prevPage 185 } 186 } 187`,S=` 188 query DirectoryStats($whereTotaal: Directory_where) { 189 totaal: Directories(where: $whereTotaal, limit: 1) { 190 totalDocs 191 } 192 } 193`,_=` 194 query DirectoryTextOptions($where: Directory_where, $limit: Int) { 195 Directories(where: $where, limit: $limit) { 196 docs { 197 ggzAanbod { 198 expertise 199 primaireBehandelkader 200 } 201 } 202 } 203 } 204`,k=` 205 query TeamsArchive($where: Team_where, $limit: Int, $page: Int, $sort: String, $locale: LocaleInputType, $fallbackLocale: FallbackLocaleInputType) { 206 Teams(where: $where, limit: $limit, page: $page, sort: $sort, locale: $locale, fallbackLocale: $fallbackLocale) { 207 docs { 208 id 209 slug 210 fullName 211 position 212 media { 213 ${x} 214 } 215 socialLinks { 216 id 217 selectSocialLink 218 linkValue 219 } 220 } 221 totalDocs 222 totalPages 223 page 224 hasNextPage 225 hasPrevPage 226 nextPage 227 prevPage 228 } 229 } 230`;e.s(["DIRECTORY_ARCHIVE",0,C,"DIRECTORY_STATS",0,S,"DIRECTORY_TEXT_OPTIONS_QUERY",0,_,"POSTS_ARCHIVE",0,w,"TEAMS_ARCHIVE",0,
230k],4160)},19686,e=>{e.v({archiveBlock:"index-module-scss-module__cgwYGG__archiveBlock",introContent:"index-module-scss-module__cgwYGG__introContent",link:"index-module-scss-module__cgwYGG__link",link__container:"index-module-scss-module__cgwYGG__link__container"})},94059,e=>{e.v({"carouselblock-wrapper":"index-module-scss-module__ozFy2W__carouselblock-wrapper"})},11948,e=>{e.v({"carousel-wrapper":"index-module-scss-module__Ju9JFa__carousel-wrapper","carousel-wrapper--withOverflow":"index-module-scss-module__Ju9JFa__carousel-wrapper--withOverflow",carouselBlock:"index-module-scss-module__Ju9JFa__carouselBlock",carousel__container:"index-module-scss-module__Ju9JFa__carousel__container",carousel__control:"index-module-scss-module__Ju9JFa__carousel__control","carousel__control-left":"index-module-scss-module__Ju9JFa__carousel__control-left","carousel__control-right":"index-module-scss-module__Ju9JFa__carousel__control-right",carousel__controls:"index-module-scss-module__Ju9JFa__carousel__controls",carousel__indicator:"index-module-scss-module__Ju9JFa__carousel__indicator",carousel__indicators:"index-module-scss-module__Ju9JFa__carousel__indicators",carousel__root:"index-module-scss-module__Ju9JFa__carousel__root","carousel__slide-media":"index-module-scss-module__Ju9JFa__carousel__slide-media","carousel__slide-overlay":"index-module-scss-module__Ju9JFa__carousel__slide-overlay",carousel__title:"index-module-scss-module__Ju9JFa__carousel__title",carousel__viewport:"index-module-scss-module__Ju9JFa__carousel__viewport",overVideo:"index-module-scss-module__Ju9JFa__overVideo",withoutBg:"index-module-scss-module__Ju9JFa__withoutBg"})},15332,63315,31734,e=>{"use strict";var t=e.i(48277),n=e.i(30668),i=e.i(16292),r=e.i(98583),o=e.i(69363),a=e.i(86577),s=e.i(92448),l=e.i(97132),d=e.i(38325),u=e.i(63584),c=e.i(90388),h=e.i(79908),p=e.i(16069),f=e.i(96268),g=e.i(3218),m=e.i(80202),v=e.i(4160),y=e.i(19285);let b=e=>{let{categories:b,limit:x=12,populateBy:w,paginationPosition:C="bottom",relationTo:S,postTypes:_,selectedDocs:k,showPageRange:M,sort:T="date",sortOrder:D="desc",dateFilter:R,switchPagination:I,display:A="grid",position:P="left",cardStyle:E="default",cardMediaStyle:L,overlayHeight:F,imageFit:O="cover",pageLocale:N}=e,[B,z]=(0,n.useState)({docs:(k||[]).map(e=>e),hasNextPage:!1,hasPrevPage:!1,nextPage:1,page:1,prevPage:1,totalPages:1}),{tenant:j}=(0,c.useTenant)(),V=(0,y.useIsLinkActive)(),{t:H}=(0,h.useTranslations)(),[G,W]=(0,n.useState)(!1),[$,U]=(0,n.useState)(void 0),q=(0,n.useRef)(null),K=(0,n.useRef)(!1),Y=(0,n.useRef)(!1),[Z,X]=(0,n.useState)(1),J=(b||[]).map(e=>"object"==typeof e?e.id:e).join(","),Q=(_||[]).map(e=>"object"==typeof e?e.id:e).join(","),ee="date"===T?_?.some(e=>"object"==typeof e&&e?.isEventType)?"posts"===S?"eventDate":"publishedAt":"posts"===S?"publishedAt":"createdAt":"a_z"===T?"title":T;(0,n.useEffect)(()=>{let e=null;if("collection"===w&&!Y.current){Y.current=!0,e=setTimeout(()=>{K.current&&W(!0)},500);let t=new URLSearchParams(window.location.search),n=_?.some(e=>"object"==typeof e&&e?.isEventType),i={};if("teams"!==S&&(i.suppressForLocale={not_equals:!0}),J&&(i.categories={in:J.split(",")}),Q&&(i.postType={in:Q.split(",")}),R&&"all"!==R&&n){let e=new Date().toISOString();"past"===R?i.eventDate={less_than:e}:i.eventDate={greater_than_equal:e}}let r=N||t.get("locale")||(0,u.getLang)()||j.defaultLanguage,o="teams"===S?v.TEAMS_ARCHIVE:v.POSTS_ARCHIVE,a="desc"===D?`-${ee}`:ee;(async()=>{try{let t=await (0,m.fetchWithRetry)(`${(0,s.getGraphqlApiUrl)()}/api/graphql`,{method:"POST",headers:{...await (0,s.getTenantHeaders)(),"Content-Type":"application/json"},body:JSON.stringify({query:o,variables:{where:Object.keys(i).length>0?i:void 0,limit:x,page:Z,sort:a,locale:r,fallbackLocale:j.defaultLanguage}})}),n=await t.json();if(e&&clearTimeout(e),n.errors)throw Error(n.errors[0]?.message??"GraphQL error");let l="teams"===S?"Teams":"Posts",d=n.data?.[l];d?.docs&&Array.isArray(d.docs)&&(z({docs:d.docs,hasNextPage:d.hasNextPage,hasPrevPage:d.hasPrevPage,nextPage:d.nextPage,page:d.page,prevPage:d.prevPage,totalPages:d.totalPages}),W(!1))}catch(e){console.warn(`Unable to load ${S} archive`,e),W(!1),U(H("unableToLoad",{collection:S||"posts"}))}Y.current=!1,K.current=!0})()}return()=>{e&&clearTimeout(e)}},[Z,J,S,_,T,D,ee,x,w,Q,R,j.defaultLanguage,N]);let et=j.Theme?.defaultcardStyle||"hover",en="default"===E?et:E,ei=j.Theme?.posts?.postsShowPublishDate,er=()=>"paginationShow"!==I||B.totalPages<=1?null:(0,t.jsxs)("div",{className:l.default.paginationContainer,children:[!1!==M&&"selection"!==w&&(0,t.jsx)("div",{children:(0,t.jsx)("div",{className:l.default.pageRange,children:(0,t.jsx)(r.PageRange,{collection:S??"posts",currentPage:B.page,limit:x??12,totalDocs:B?.docs?.length})})}),"selection"!==w&&(0,t.jsx)(o.Pagination,{className:l.default.pagination,onClick:X,page:B.page,totalPages:B.totalPages})]});return"list"===A?(0,t.jsx)("div",{className:d.default[`submenu--${P}`],children:(0,t.jsx)("div",{className:d.default.submenu,children:(0,t.jsxs)("ul",{className:d.default.submenu__list,children:[("top"===C||"both"===C)&&B.totalPages>
2301&&(0,t.jsx)("li",{className:[d.default.submenu__link].filter(Boolean).join(" "),children:(0,t.jsx)(o.Pagination,{className:l.default.pagination,onClick:X,page:B.page,totalPages:B.totalPages})}),B.docs?.map((e,n)=>{if("object"==typeof e&&null!==e){let i="selection"===w?e.value:e,r=V({...e,type:"reference",reference:{relationTo:"selection"===w?e.relationTo:S||"posts",value:i}});return(0,t.jsx)("li",{children:(0,t.jsx)(g.Paper,{bg:"transparent",radius:j?.Theme?.borderRadius||"md",className:[d.default.submenu__item,r&&d.default["submenu__item--active"]].filter(Boolean).join(" "),children:(0,t.jsx)(a.CMSLink,{className:[d.default.submenu__link,r&&d.default["submenu__link--active"]].filter(Boolean).join(" "),type:"reference",reference:{relationTo:"selection"===w?e.relationTo:S||"posts",value:i},label:i.title,appearance:"default"})})},n)}return null}),("bottom"===C||"both"===C)&&B.totalPages>1&&(0,t.jsx)("li",{className:[d.default.submenu__link].filter(Boolean).join(" "),children:(0,t.jsx)(o.Pagination,{className:l.default.pagination,onClick:X,page:B.page,totalPages:B.totalPages})})]})})}):(0,t.jsxs)("div",{className:l.default.collectionArchive,children:[(0,t.jsx)("div",{className:l.default.scrollRef,ref:q}
230),!G&&$&&(0,t.jsx)("div",{className:l.default["archive-error"],children:$}),(0,t.jsx)(n.Fragment,{children:(0,t.jsxs)("div",{children:[("top"===C||"both"===C)&&er(),(0,t.jsx)("div",{className:l.default.grid,children:B.docs?.map((e,n)=>{if("object"==typeof e&&null!==e){let r="selection"===w?e.value:e,o=r.meta?.image||r.media||r.hero?.heroImage||("teams"===S?p.default.src:f.default);return(0,t.jsx)("div",{className:l.default.column,children:(0,t.jsx)(i.SmartCard,{mediaStyle:L,overlayHeight:F,style:en,categories:r.categories,mediaType:"media",media:o,imageFit:O,imageSizes:"(min-width: 1200px) 33vw, (min-width: 768px) 50vw, 100vw",titleRich:{root:{type:"root",children:[{type:"heading",tag:"h3",version:1,children:[{type:"text",format:"",version:1,text:r.title||r.fullName||H("missingTitle")}]}],direction:"ltr",format:"",indent:0,version:1}},textRich:r.summary||r.position?{root:{type:"root",children:[{type:"paragraph",version:1,children:[{type:"text",version:1,text:r.summary||r.position}]}],direction:"ltr",format:"",indent:0,version:1}}:null,date:"posts"===S&&ei&&r.postType?.showDate?r.postType?.isEventType?r.eventDate:r.publishedAt:null,enableLink:!0,cardLink:{cardLink:!0,type:"reference",reference:{relationTo:S??"posts",value:r}},socialLinks:r.socialLinks})},n)}return null})}),("bottom"===C||"both"===C)&&er()]})})]})};e.s(["CollectionArchive",0,b],63315);var x=e.i(86957),w=e.i(19686);function C(e){return"[object Object]"===Object.prototype.toString.call(e)||Array.isArray(e)}function S(e,t){let n=Object.keys(e),i=Object.keys(t);return n.length===i.length&&JSON.stringify(Object.keys(e.breakpoints||{}))===JSON.stringify(Object.keys(t.breakpoints||{}))&&n.every(n=>{let i=e[n],r=t[n];return"function"==typeof i?`${i}`==`${r}`:C(i)&&C(r)?S(i,r):i===r})}function _(e){return e.concat().sort((e,t)=>e.name>t.name?1:-1).map(e=>e.options)}function k(e){return"number"==typeof e}function M(e){return"string"==typeof e}function T(e){return"boolean"==typeof e}function D(e){return"[object Object]"===Object.prototype.toString.call(e)}function R(e){return Math.abs(e)}function I(e){return Math.sign(e)}e.s(["ArchiveBlock",0,e=>{let{introContent:n,link:i,id:r,relationTo:o,populateBy:s,sortBy:l,sortOrder:d,dateFilter:u,limit:c,selectedDocs:h,categories:p,postTypes:f,switchPagination:g,paginationPosition:m,itemStyle:v,cardStyle:y,cardMediaStyle:C,cardImageFit:S,cardOverlayHeight:_,pageLocale:k}=e;return(0,t.jsxs)("div",{id:`block-${r}`,className:w.default.archiveBlock,"data-block":"archive",...e.blockDataId?{"data-block-id":e.blockDataId}:{},children:[n&&(0,t.jsx)("div",{className:w.default.introContent,children:(0,t.jsx)(x.default,{content:n})}),(0,t.jsx)(b,{display:v,cardStyle:y??"default",imageFit:S??"cover",cardMediaStyle:C??"square",overlayHeight:_,populateBy:s??void 0,relationTo:o??void 0,selectedDocs:h,postTypes:f,categories:p,limit:c??void 0,sort:"a_z"===l?"posts"===o?"title":"fullName":"publishedAt",sortOrder:d??"desc",dateFilter:u??"all",switchPagination:g??void 0,paginationPosition:m??"bottom",showPageRange:!1,pageLocale:k}),(0,t.jsx)("div",{className:w.default.link__container,children:"buttonShow"===g&&i&&(0,t.jsx)(a.CMSLink,{...i,className:w.default.link})})]})}],15332);function A(e){return F(e).map(Number)}function P(e){return e[E(e)]}function E(e){return Math.max(0,e.length-1)}function L(e,t=0){return Array.from(Array(e),(e,n)=>t+n)}function F(e){return Object.keys(e)}function O(e,t){return void 0!==t.MouseEvent&&e instanceof t.MouseEvent}function N(){let e=[],t={add:function(n,i,r,o={passive:!0}){let a;return"addEventListener"in n?(n.addEventListener(i,r,o),a=()=>n.removeEventListener(i,r,o)):(n.addListener(r),a=()=>n.removeListener(r)),e.push(a),t},clear:function(){e=e.filter(e=>e())}};return t}function B(e=0,t=0){let n=R(e-t);function i(n){return n<e||n>t}return{length:n,max:t,min:e,constrain:function(n){return i(n)?n<e?e:t:n},reachedAny:i,reachedMax:function(e){return e>t},reachedMin:function(t){return t<e},removeOffset:function(e){return n?e-n*Math.ceil((e-t)/n):e}}}function z(e){let t=e;function n(e){return k(e)?e:e.get()}return{get:function(){return t},set:function(e){t=n(e)},add:function(e){t+=n(e)},subtract:function(e){t-=n(e)}}}function j(e,t){let n="x"===e.scroll?function(e){return`translate3d(${e}px,0px,0px)`}:function(e){return`translate3d(0px,${e}px,0px)`},i=t.style,r=null,o=!1;return{clear:function(){!o&&(i.transform="",t.getAttribute("style")||t.removeAttribute("style"))},to:function(t){if(o)return;let a=Math.round(100*e.direction(t))/100;
230a!==r&&(i.transform=n(a),r=a)},toggleActive:function(e){o=!e}}}let V={align:"center",axis:"x",container:null,slides:null,containScroll:"trimSnaps",direction:"ltr",slidesToScroll:1,inViewThreshold:0,breakpoints:{},dragFree:!1,dragThreshold:10,loop:!1,skipSnaps:!1,duration:25,startIndex:0,active:!0,watchDrag:!0,watchResize:!0,watchSlides:!0,watchFocus:!0};function H(e,t,n){let i,r,o,a,s,l,d,u,c=e.ownerDocument,h=c.defaultView,p=function(e){function t(e,t){return function e(t,n){return[t,n].reduce((t,n)=>(F(n).forEach(i=>{let r=t[i],o=n[i],a=D(r)&&D(o);t[i]=a?e(r,o):o}),t),{})}(e,t||{})}return{mergeOptions:t,optionsAtMedia:function(n){let i=n.breakpoints||{},r=F(i).filter(t=>e.matchMedia(t).matches).map(e=>i[e]).reduce((e,n)=>t(e,n),{});return t(n,r)},optionsMediaQueries:function(t){return t.map(e=>F(e.breakpoints||{})).reduce((e,t)=>e.concat(t),[]).map(e.matchMedia)}}}(h),f=(u=[],{init:function(e,t){return(u=t.filter(({options:e})=>!1!==p.optionsAtMedia(e).active)).forEach(t=>t.init(e,p)),t.reduce((e,t)=>Object.assign(e,{[t.name]:t}),{})},destroy:function(){u=u.filter(e=>e.destroy())}}),g=N(),m=(r={},o={init:function(e){i=e},emit:function(e){return(r[e]||[]).forEach(t=>t(i,e)),o},off:function(e,t){return r[e]=(r[e]||[]).filter(e=>e!==t),o},on:function(e,t){return r[e]=(r[e]||[]).concat([t]),o},clear:function(){r={}}}),{mergeOptions:v,optionsAtMedia:y,optionsMediaQueries:b}=p,{on:x,off:w,emit:C}=m,S=!1,_=v(V,H.globalOptions),G=v(_),W=[];function $(t,n){S||(G=y(_=v(_,t)),W=n||W,function(){let{container:t,slides:n}=G;l=(M(t)?e.querySelector(t):t)||e.children[0];let i=M(n)?l.querySelectorAll(n):n;d=[].slice.call(i||l.children)}(),a=function t(n){let i=function(e,t,n,i,r,o,a){var s,l;let d,u,c,h,p,f,g,m,v,y,b,x,w,C,{align:S,axis:_,direction:D,startIndex:V,loop:H,duration:G,dragFree:W,dragThreshold:$,inViewThreshold:U,slidesToScroll:q,skipSnaps:K,containScroll:Y,watchResize:Z,watchSlides:X,watchDrag:J,watchFocus:Q}=o,ee={measure:function(e){let{offsetTop:t,offsetLeft:n,offsetWidth:i,offsetHeight:r}=e;return{top:t,right:n+i,bottom:t+r,left:n,width:i,height:r}}},et=ee.measure(t),en=n.map(ee.measure),ei=(u="rtl"===D,h=(c="y"===_)||!u?1:-1,p=c?"top":u?"right":"left",f=c?"bottom":u?"left":"right",{scroll:c?"y":"x",cross:c?"x":"y",startEdge:p,endEdge:f,measureSize:function(e){let{height:t,width:n}=e;return c?t:n},direction:function(e){return e*h}}),er=ei.measureSize(et),eo={measure:function(e){return e/100*er}},ea=(s=S,l=er,d={start:function(){return 0},center:function(e){return(l-e)/2},end:function(e){return l-e}},{measure:function(e,t){return M(s)?d[s](e):s(l,e,t)}}),es=!H&&!!Y,{slideSizes:el,slideSizesWithGaps:ed,startGap:eu,endGap:ec}=function(e,t,n,i,r,o){let{measureSize:a,startEdge:s,endEdge:l}=e,d=n[0]&&r,u=function(){if(!d)return 0;let e=n[0];return R(t[s]-e[s])}(),c=d?parseFloat(o.getComputedStyle(P(i)).getPropertyValue(`margin-${l}`)):0,h=n.map(a),p=n.map((e,t,n)=>{let i=t===E(n);return t?i?h[t]+c:n[t+1][s]-e[s]:h[t]+u}).map(R);return{slideSizes:h,slideSizesWithGaps:p,startGap:u,endGap:c}}(ei,et,en,n,H||!!Y,r),eh=function(e,t,n,i,r,o,a,s,l){let{startEdge:d,endEdge:u,direction:c}=e,h=k(n);return{groupSlides:function(e){return h?A(e).filter(e=>e%n==0).map(t=>e.slice(t,t+n)):e.length?A(e).reduce((n,l,h)=>{let p=P(n)||0,f=l===E(e),g=r[d]-o[p][d],m=r[d]-o[l][u],v=i||0!==p?0:c(a),y=R(m-(!i&&f?c(s):0)-(g+v));return h&&y>t+2&&n.push(l),f&&n.push(e.length),n},[]).map((t,n,i)=>{let r=Math.max(i[n-1]||0);return e.slice(r,t)}):[]}}}(ei,er,q,H,et,en,eu,ec,0),{snaps:ep,snapsAligned:ef}=function(e,t,n,i,r){let{startEdge:o,endEdge:a}=e,{groupSlides:s}=r,l=s(i).map(e=>P(e)[a]-e[0][o]).map(R).map(t.measure),d=i.map(e=>n[o]-e[o]).map(e=>-R(e)),u=s(d).map(e=>e[0]).map((e,t)=>e+l[t]);return{snaps:d,snapsAligned:u}}(ei,ea,et,en,eh),eg=-P(ep)+P(ed),{snapsContained:em,scrollContainLimit:ev}=function(e,t,n,i,r){let o,a,s=B(-t+e,0),l=n.map((e,t)=>{let{min:i,max:r}=s,o=s.constrain(e),a=t===E(n);return t?a||function(e,t){return 1>=R(e-t)}(i,o)?i:function(e,t){return 1>=R(e-t)}(r,o)?r:o:r}).map(e=>parseFloat(e.toFixed(3))),d=(o=l[0],a=P(l),B(l.lastIndexOf(o),l.
230indexOf(a)+1));return{snapsContained:function(){if(t<=e+2)return[s.max];if("keepSnaps"===i)return l;let{min:n,max:r}=d;return l.slice(n,r)}(),scrollContainLimit:d}}(er,eg,ef,Y,0),ey=es?em:ef,{limit:eb}=(g=ey[0],{limit:B(H?g-eg:P(ey),g)}),ex=function e(t,n,i){let{constrain:r}=B(0,t),o=t+1,a=s(n);function s(e){return i?R((o+e)%o):r(e)}function l(){return e(t,a,i)}let d={get:function(){return a},set:function(e){return a=s(e),d},add:function(e){return l().set(a+e)},clone:l};return d}(E(ey),V,H),ew=ex.clone(),eC=A(n),eS=function(e,t,n,i){let r=N(),o=1e3/60,a=null,s=0,l=0;function d(e){if(!l)return;a||(a=e,n(),n());let r=e-a;for(a=e,s+=r;s>=o;)n(),s-=o;i(s/o),l&&(l=t.requestAnimationFrame(d))}function u(){t.cancelAnimationFrame(l),a=null,s=0,l=0}return{init:function(){r.add(e,"visibilitychange",()=>{e.hidden&&(a=null,s=0)})},destroy:function(){u(),r.clear()},start:function(){l||(l=t.requestAnimationFrame(d))},stop:u,update:n,render:i}}(i,r,()=>(({dragHandler:e,scrollBody:t,scrollBounds:n,options:{loop:i}})=>{i||n.constrain(e.pointerDown()),t.seek()})(eN),e=>(({scrollBody:e,translate:t,location:n,offsetLocation:i,previousLocation:r,scrollLooper:o,slideLooper:a,dragHandler:s,animation:l,eventHandler:d,scrollBounds:u,options:{loop:c}},h)=>{let p=e.settled(),f=!u.shouldConstrain(),g=c?p:p&&f,m=g&&!s.pointerDown();m&&l.stop();let v=n.get()*h+r.get()*(1-h);i.set(v),c&&(o.loop(e.direction()),a.loop()),t.to(i.get()),m&&d.emit("settle"),g||d.emit("scroll")})(eN,e)),e_=ey[ex.get()],ek=z(e_),eM=z(e_),eT=z(e_),eD=z(e_),eR=function(e,t,n,i,r,o){let a=0,s=0,l=r,d=.68,u=e.get(),c=0;function h(e){return l=e,f}function p(e){return d=e,f}let f={direction:function(){return s},duration:function(){return l},velocity:function(){return a},seek:function(){let t=i.get()-e.get(),r=0;return l?(n.set(e),a+=t/l,a*=d,u+=a,e.add(a),r=u-c):(a=0,n.set(i),e.set(i),r=t),s=I(r),c=u,f},settled:function(){return .001>R(i.get()-t.get())},useBaseFriction:function(){return p(.68)},useBaseDuration:function(){return h(r)},useFriction:p,useDuration:h};return f}(ek,eT,eM,eD,G,0),eI=function(e,t,n,i,r){let{reachedAny:o,removeOffset:a,constrain:s}=i;function l(e){return e.concat().sort((e,t)=>R(e)-R(t))[0]}function d(t,i){let r=[t,t+n,t-n];if(!e)return t;if(!i)return l(r);let o=r.filter(e=>I(e)===i);return o.length?l(o):P(r)-n}return{byDistance:function(n,i){let l=r.get()+n,{index:u,distance:c}=function(n){let i=e?a(n):s(n),{index:r}=t.map((e,t)=>({diff:d(e-i,0),index:t})).sort((e,t)=>R(e.diff)-R(t.diff))[0];return{index:r,distance:i}}(l),h=!e&&o(l);if(!i||h)return{index:u,distance:n};let p=n+d(t[u]-c,0);return{index:u,distance:p}},byIndex:function(e,n){let i=d(t[e]-r.get(),n);return{index:e,distance:i}},shortcut:d}}(H,ey,eg,eb,eD),eA=function(e,t,n,i,r,o,a){function s(r){let s=r.distance,l=r.index!==t.get();
230o.add(s),s&&(i.duration()?e.start():(e.update(),e.render(1),e.update())),l&&(n.set(t.get()),t.set(r.index),a.emit("select"))}return{distance:function(e,t){s(r.byDistance(e,t))},index:function(e,n){let i=t.clone().set(e);s(r.byIndex(i.get(),n))}}}(eS,ex,ew,eR,eI,eD,a),eP=function(e){let{max:t,length:n}=e;return{get:function(e){return n?-((e-t)/n):0}}}(eb),eE=N(),eL=(v={},y=null,b=null,x=!1,{init:function(){m=new IntersectionObserver(e=>{x||(e.forEach(e=>{v[n.indexOf(e.target)]=e}),y=null,b=null,a.emit("slidesInView"))},{root:t.parentElement,threshold:U}),n.forEach(e=>m.observe(e))},destroy:function(){m&&m.disconnect(),x=!0},get:function(e=!0){if(e&&y)return y;if(!e&&b)return b;let t=F(v).reduce((t,n)=>{let i=parseInt(n),{isIntersecting:r}=v[i];return(e&&r||!e&&!r)&&t.push(i),t},[]);return e&&(y=t),e||(b=t),t}}),{slideRegistry:eF}=function(e,t,n,i,r,o){let a,{groupSlides:s}=r,{min:l,max:d}=i;return{slideRegistry:(a=s(o),1===n.length?[o]:e&&"keepSnaps"!==t?a.slice(l,d).map((e,t,n)=>{let i=t===E(n);return t?i?L(E(o)-P(n)[0]+1,P(n)[0]):e:L(P(n[0])+1)}):a)}}(es,Y,ey,ev,eh,eC),eO=function(e,t,n,i,r,o,a,s){let l={passive:!0,capture:!0},d=0;function u(e){"Tab"===e.code&&(d=new Date().getTime())}return{init:function(c){s&&(o.add(document,"keydown",u,!1),t.forEach((t,u)=>{o.add(t,"focus",t=>{(T(s)||s(c,t))&&function(t){if(new Date().getTime()-d>10)return;a.emit("slideFocusStart"),e.scrollLeft=0;let o=n.findIndex(e=>e.includes(t));k(o)&&(r.useDuration(0),i.index(o,0),a.emit("slideFocus"))}(u)},l)}))}}}(e,n,eF,eA,eR,eE,a,Q),eN={ownerDocument:i,ownerWindow:r,eventHandler:a,containerRect:et,slideRects:en,animation:eS,axis:ei,dragHandler:function(e,t,n,i,r,o,a,s,l,d,u,c,h,p,f,g,m,v,y){let{cross:b,direction:x}=e,w=["INPUT","SELECT","TEXTAREA"],C={passive:!1},S=N(),_=N(),k=B(50,225).constrain(p.measure(20)),M={mouse:300,touch:400},D={mouse:500,touch:600},A=f?43:25,P=!1,E=0,L=0,F=!1,z=!1,j=!1,V=!1;function H(e){if(!O(e,i)&&e.touches.length>=2)return G(e);let t=o.readPoint(e),n=o.readPoint(e,b),a=R(t-E),l=R(n-L);if(!z&&!V&&(!e.cancelable||!(z=a>l)))return G(e);let u=o.pointerMove(e);a>g&&(j=!0),d.useFriction(.3).useDuration(.75),s.start(),r.add(x(u)),e.preventDefault()}function G(e){var t;let n,i,r=u.byDistance(0,!1).index!==c.get(),a=o.pointerUp(e)*(f?D:M)[V?"mouse":"touch"],s=(t=x(a),n=c.add(-1*I(t)),i=u.byDistance(t,!f).distance,f||R(t)<k?i:m&&r?.5*i:u.byIndex(n.get(),0).distance),p=function(e,t){var n,i;if(0===e||0===t||R(e)<=R(t))return 0;let r=(n=R(e),i=R(t),R(n-i));return R(r/e)}(a,s);z=!1,F=!1,_.clear(),d.useDuration(A-10*p).useFriction(.68+p/50),l.distance(s,!f),V=!1,h.emit("pointerUp")}function W(e){j&&(e.stopPropagation(),e.preventDefault(),j=!1)}return{init:function(e){y&&S.add(t,"dragstart",e=>e.preventDefault(),C).add(t,"touchmove",()=>void 0,C).add(t,"touchend",()=>void 0).add(t,"touchstart",s).add(t,"mousedown",s).add(t,"touchcancel",G).add(t,"contextmenu",G).add(t,"click",W,!0);function s(s){(T(y)||y(e,s))&&function(e){let s,l=O(e,i);if((V=l,j=f&&l&&!e.buttons&&P,P=R(r.get()-a.get())>=2,!l||0===e.button)&&(s=e.target.nodeName||"",!w.includes(s))){let i;F=!0,o.pointerDown(e),d.useFriction(0).useDuration(0),r.set(a),i=V?n:t,_.add(i,"touchmove",H,C).add(i,"touchend",G).add(i,"mousemove",H,C).add(i,"mouseup",G),E=o.readPoint(e),L=o.readPoint(e,b),h.emit("pointerDown")}}(s)}},destroy:function(){S.clear(),_.clear()},pointerDown:function(){return F}}}(ei,e,i,r,eD,function(e,t){let n,i;function r(e){return e.timeStamp}function o(n,i){let r=i||e.scroll,o=`client${"x"===r?"X":"Y"}`;return(O(n,t)?n:n.touches[0])[o]}return{pointerDown:function(e){return n=e,i=e,o(e)},pointerMove:function(e){let t=o(e)-o(i),a=r(e)-r(n)>170;return i=e,a&&(n=e),t},pointerUp:function(e){if(!n||!i)return 0;let t=o(i)-o(n),a=r(e)-r(n),s=r(e)-r(i)>170,l=t/a;return a&&!s&&R(l)>.1?l:0},readPoint:o}}(ei,r),ek,eS,eA,eR,eI,ex,a,eo,W,$,K,0,J),eventStore:eE,percentOfView:eo,index:ex,indexPrevious:ew,limit:eb,location:ek,offsetLocation:eT,previousLocation:eM,options:o,resizeHandler:function(e,t,n,i,r,o,a){let s,l,d=[e].concat(i),u=[],c=!1;function h(e){return r.measureSize(a.measure(e))}return{init:function(r){o&&(l=h(e),u=i.map(h),s=new ResizeObserver(n=>{(T(o)||o(r,n))&&function(n){for(let o of n){if(c)return;let n=o.target===e,a=i.indexOf(o.target),s=n?l:u[a];if(R(h(n?e:i[a])-s)>=.5){r.reInit(),t.emit("resize");break}}}(n)}),n.requestAnimationFrame(()=>
230{d.forEach(e=>s.observe(e))}))},destroy:function(){c=!0,s&&s.disconnect()}}}(t,a,r,n,ei,Z,ee),scrollBody:eR,scrollBounds:function(e,t,n,i,r){let o=r.measure(10),a=r.measure(50),s=B(.1,.99),l=!1;function d(){return!l&&!!e.reachedAny(n.get())&&!!e.reachedAny(t.get())}return{shouldConstrain:d,constrain:function(r){if(!d())return;let l=e.reachedMin(t.get())?"min":"max",u=R(e[l]-t.get()),c=n.get()-t.get(),h=s.constrain(u/a);n.subtract(c*h),!r&&R(c)<o&&(n.set(e.constrain(n.get())),i.useDuration(25).useBaseFriction())},toggleActive:function(e){l=!e}}}(eb,eT,eD,eR,eo),scrollLooper:function(e,t,n,i){let{reachedMin:r,reachedMax:o}=B(t.min+.1,t.max+.1);return{loop:function(t){if(!(1===t?o(n.get()):-1===t&&r(n.get())))return;let a=-1*t*e;i.forEach(e=>e.add(a))}}}(eg,eb,eT,[ek,eT,eM,eD]),scrollProgress:eP,scrollSnapList:ey.map(eP.get),scrollSnaps:ey,scrollTarget:eI,scrollTo:eA,slideLooper:function(e,t,n,i,r,o,a,s,l){let d=A(r),u=A(r).reverse(),c=f(p(u,a[0]),n,!1).concat(f(p(d,t-a[0]-1),-n,!0));function h(e,t){return e.reduce((e,t)=>e-r[t],t)}function p(e,t){return e.reduce((e,n)=>h(e,t)>0?e.concat([n]):e,[])}function f(r,a,d){let u=o.map((e,n)=>({start:e-i[n]+.5+a,end:e+t-.5+a}));return r.map(t=>{let i=d?0:-n,r=d?n:0,o=u[t][d?"end":"start"];return{index:t,loopPoint:o,slideLocation:z(-1),translate:j(e,l[t]),target:()=>s.get()>o?i:r}})}return{canLoop:function(){return c.every(({index:e})=>.1>=h(d.filter(t=>t!==e),t))},clear:function(){c.forEach(e=>e.translate.clear())},loop:function(){c.forEach(e=>{let{target:t,translate:n,slideLocation:i}=e,r=t();r!==i.get()&&(n.to(r),i.set(r))})},loopPoints:c}}(ei,er,eg,el,ed,ep,ey,eT,n),slideFocus:eO,slidesHandler:(C=!1,{init:function(e){X&&(w=new MutationObserver(t=>{!C&&(T(X)||X(e,t))&&function(t){for(let n of t)if("childList"===n.type){e.reInit(),a.emit("slidesChanged");break}}(t)})).observe(t,{childList:!0})},destroy:function(){w&&w.disconnect(),C=!0}}),slidesInView:eL,slideIndexes:eC,slideRegistry:eF,slidesToScroll:eh,target:eD,translate:j(ei,t)};return eN}(e,l,d,c,h,n,m);return n.loop&&!i.slideLooper.canLoop()?t(Object.assign({},n,{loop:!1})):i}(G),b([_,...W.map(({options:e})=>e)]).forEach(e=>g.add(e,"change",U)),G.active&&(a.translate.to(a.location.get()),a.animation.init(),a.slidesInView.init(),a.slideFocus.init(Z),a.eventHandler.init(Z),a.resizeHandler.init(Z),a.slidesHandler.init(Z),a.options.loop&&a.slideLooper.loop(),l.offsetParent&&d.length&&a.dragHandler.init(Z),s=f.init(Z,W)))}function U(e,t){let n=Y();q(),$(v({startIndex:n},e),t),m.emit("reInit")}function q(){a.dragHandler.destroy(),a.eventStore.clear(),a.translate.clear(),a.slideLooper.clear(),a.resizeHandler.destroy(),a.slidesHandler.destroy(),a.slidesInView.destroy(),a.animation.destroy(),f.destroy(),g.clear()}function K(e,t,n){G.active&&!S&&(a.scrollBody.useBaseFriction().useDuration(!0===t?0:G.duration),a.scrollTo.index(e,n||0))}function Y(){return a.index.get()}let Z={canScrollNext:function(){return a.index.add(1).get()!==Y()},canScrollPrev:function(){return a.index.add(-1).get()!==Y()},containerNode:function(){return l},internalEngine:function(){return a},destroy:function(){S||(S=!0,g.clear(),q(),m.emit("destroy"),m.clear())},off:w,on:x,emit:C,plugins:function(){return s},previousScrollSnap:function(){return a.indexPrevious.get()},reInit:U,rootNode:function(){return e},scrollNext:function(e){K(a.index.add(1).get(),e,-1)},scrollPrev:function(e){K(a.index.add(-1).get(),e,1)},scrollProgress:function(){return a.scrollProgress.get(a.offsetLocation.get())},scrollSnapList:function(){return a.scrollSnapList},scrollTo:K,selectedScrollSnap:Y,slideNodes:function(){return d},slidesInView:function(){return a.slidesInView.get()},slidesNotInView:function(){return a.slidesInView.get(!1)}};return $(t,n),setTimeout(()=>m.emit("init"),0),Z}function G(e={},t=[]){let i=(0,n.useRef)(e),r=(0,n.useRef)(t),[o,a]=(0,n.useState)(),[s,l]=(0,n.use
230State)(),d=(0,n.useCallback)(()=>{o&&o.reInit(i.current,r.current)},[o]);return(0,n.useEffect)(()=>{S(i.current,e)||(i.current=e,d())},[e,d]),(0,n.useEffect)(()=>{!function(e,t){if(e.length!==t.length)return!1;let n=_(e),i=_(t);return n.every((e,t)=>S(e,i[t]))}(r.current,t)&&(r.current=t,d())},[t,d]),(0,n.useEffect)(()=>{if("u">typeof window&&window.document&&window.document.createElement&&s){H.globalOptions=G.globalOptions;let e=H(s,i.current,r.current);return a(e),()=>e.destroy()}a(void 0)},[s,a]),[l,o]}H.globalOptions=void 0,G.globalOptions=void 0,e.s(["default",()=>G],31734)},64491,e=>{e.v({"border-radius--lg":"index-module-scss-module__Nucx-G__border-radius--lg","border-radius--md":"index-module-scss-module__Nucx-G__border-radius--md","border-radius--none":"index-module-scss-module__Nucx-G__border-radius--none","border-radius--sm":"index-module-scss-module__Nucx-G__border-radius--sm","border-radius--xl":"index-module-scss-module__Nucx-G__border-radius--xl",overlay__container:"index-module-scss-module__Nucx-G__overlay__container",semiTransparentBg:"index-module-scss-module__Nucx-G__semiTransparentBg",softEdges:"index-module-scss-module__Nucx-G__softEdges",whiteBg:"index-module-scss-module__Nucx-G__whiteBg",withShadow:"index-module-scss-module__Nucx-G__withShadow"})},62218,e=>{e.v({center:"index-module-scss-module__lTB7oW__center",left:"index-module-scss-module__lTB7oW__left",linkWrapper:"index-module-scss-module__lTB7oW__linkWrapper",mediaBlock:"index-module-scss-module__lTB7oW__mediaBlock",mediaBlock__caption:"index-module-scss-module__lTB7oW__mediaBlock__caption","mediaBlock__caption--black":"index-module-scss-module__lTB7oW__mediaBlock__caption--black","mediaBlock__caption--primary":"index-module-scss-module__lTB7oW__mediaBlock__caption--primary","mediaBlock__caption--quaternary":"index-module-scss-module__lTB7oW__mediaBlock__caption--quaternary","mediaBlock__caption--quinary":"index-module-scss-module__lTB7oW__mediaBlock__caption--quinary","mediaBlock__caption--secondary":"index-module-scss-module__lTB7oW__mediaBlock__caption--secondary","mediaBlock__caption--senary":"index-module-scss-module__lTB7oW__mediaBlock__caption--senary","mediaBlock__caption--tertiary":"index-module-scss-module__lTB7oW__mediaBlock__caption--tertiary","mediaBlock__caption--white":"index-module-scss-module__lTB7oW__mediaBlock__caption--white","mediaBlock__caption--withBg":"index-module-scss-module__lTB7oW__mediaBlock__caption--withBg",mediaBlock__captionText:"index-module-scss-module__lTB7oW__mediaBlock__captionText",mediaBlock__image:"index-module-scss-module__lTB7oW__mediaBlock__image",mediaBlock__lightbox:"index-module-scss-module__lTB7oW__mediaBlock__lightbox",mediaBlock__paper:"index-module-scss-module__lTB7oW__mediaBlock__paper",right:"index-module-scss-module__lTB7oW__right"})},74709,e=>{e.v({lightboxIcon:"Lightbox-module-scss-module__jA8Y3G__lightboxIcon",lightboxIconSvg:"Lightbox-module-scss-module__jA8Y3G__lightboxIconSvg",lightboxWrapper:"Lightbox-module-scss-module__jA8Y3G__lightboxWrapper",modalCaption:"Lightbox-module-scss-module__jA8Y3G__modalCaption",modalCaption__text:"Lightbox-module-scss-module__jA8Y3G__modalCaption__text",modalContent:"Lightbox-module-scss-module__jA8Y3G__modalContent"})},10966,e=>{e.v({block:"index-module-scss-module__dxujda__block","block--primary":"index-module-scss-module__dxujda__block--primary","block--quaternary":"index-module-scss-module__dxujda__block--quaternary","block--secondary":"index-module-scss-module__dxujda__block--secondary","block--tertiary":"index-module-scss-module__dxujda__block--tertiary","block--with-background":"index-module-scss-module__dxujda__block--with-background",content:"index-module-scss-module__dxujda__content",control:"index-module-scss-module__dxujda__control",icon:"index-module-scss-module__dxujda__icon",item:"index-module-scss-module__dxujda__item",itemContainer:"index-module-scss-module__dxujda__itemContainer",label:"index-module-scss-module__dxujda__label","slide-down":"index-module-scss-module__dxujda__slide-down"})},94118,e=>{e.v({block:"index-module-scss-module__ZPrFjG__block",buttons:"index-module-scss-module__ZPrFjG__buttons",fieldWrap:"index-module-scss-module__ZPrFjG__fieldWrap",form:"index-module-scss-module__ZPrFjG__form","form--black":"index-module-scss-module__ZPrFjG__form--black","form--primary":"index-module-scss-module__ZPrFjG__form--primary","form--quaternary":"index-module-scss-module__ZPrFjG__form--quaternary","form--quinary":"index-module-scss-module__ZPrFjG__form--quinary","form--secondary":"index-module-scss-module__ZPrFjG__form--secondary","form--senary":"index-module-scss-module__ZPrFjG__form--senary","form--tertiary":"index-module-scss-module__ZPrFjG__form--tertiary","form--white":"index-module-scss-module__ZPrFjG__form--white"})},69316,e=>
230{e.v({hidden:"index-module-scss-module__dQCuma__hidden",width:"index-module-scss-module__dQCuma__width"})},22374,e=>{e.v({asterisk:"index-module-scss-module__z-Bx3a__asterisk",label:"index-module-scss-module__z-Bx3a__label"})},10322,e=>{e.v({icon:"index-module-scss-module__7un2UW__icon"})},21381,(e,t,n)=>{e.e,t.exports=function(){"use strict";var e="millisecond",t="second",n="minute",i="hour",r="week",o="month",a="quarter",s="year",l="date",d="Invalid Date",u=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,c=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,h=function(e,t,n){var i=String(e);return!i||i.length>=t?e:""+Array(t+1-i.length).join(n)+e},p="en",f={};f[p]={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(e){var t=["th","st","nd","rd"],n=e%100;return"["+e+(t[(n-20)%10]||t[n]||t[0])+"]"}};var g="$isDayjsObject",m=function(e){return e instanceof x||!(!e||!e[g])},v=function e(t,n,i){var r;if(!t)return p;if("string"==typeof t){var o=t.toLowerCase();f[o]&&(r=o),n&&(f[o]=n,r=o);var a=t.split("-");if(!r&&a.length>1)return e(a[0])}else{var s=t.name;f[s]=t,r=s}return!i&&r&&(p=r),r||!i&&p},y=function(e,t){if(m(e))return e.clone();var n="object"==typeof t?t:{};return n.date=e,n.args=arguments,new x(n)},b={s:h,z:function(e){var t=-e.utcOffset(),n=Math.abs(t);return(t<=0?"+":"-")+h(Math.floor(n/60),2,"0")+":"+h(n%60,2,"0")},m:function e(t,n){if(t.date()<n.date())return-e(n,t);var i=12*(n.year()-t.year())+(n.month()-t.month()),r=t.clone().add(i,o),a=n-r<0,s=t.clone().add(i+(a?-1:1),o);return+(-(i+(n-r)/(a?r-s:s-r))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(d){return({M:o,y:s,w:r,d:"day",D:l,h:i,m:n,s:t,ms:e,Q:a})[d]||String(d||"").toLowerCase().replace(/s$/,"")},u:function(e){return void 0===e}};b.l=v,b.i=m,b.w=function(e,t){return y(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var x=function(){function h(e){this.$L=v(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[g]=!0}var p=h.prototype;return p.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(null===t)return new Date(NaN);if(b.u(t))return new Date;if(t instanceof Date)return new Date(t);if("string"==typeof t&&!/Z$/i.test(t)){var i=t.match(u);if(i){var r=i[2]-1||0,o=(i[7]||"0").substring(0,3);return n?new Date(Date.UTC(i[1],r,i[3]||1,i[4]||0,i[5]||0,i[6]||0,o)):new Date(i[1],r,i[3]||1,i[4]||0,i[5]||0,i[6]||0,o)}}return new Date(t)}(e),this.init()},p.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},p.$utils=function(){return b},p.isValid=function(){return this.$d.toString()!==d},p.isSame=function(e,t){var n=y(e);return this.startOf(t)<=n&&n<=this.endOf(t)},p.isAfter=function(e,t){return y(e)<this.startOf(t)},p.isBefore=function(e,t){return this.endOf(t)<y(e)},p.$g=function(e,t,n){return b.u(e)?this[t]:this.set(n,e)},p.unix=function(){return Math.floor(this.valueOf()/1e3)},p.valueOf=function(){return this.$d.getTime()},p.startOf=function(e,a){var d=this,u=!!b.u(a)||a,c=b.p(e),h=function(e,t){var n=b.w(d.$u?Date.UTC(d.$y,t,e):new Date(d.$y,t,e),d);return u?n:n.endOf("day")},p=function(e,t){return b.w(d.toDate()[e].apply(d.toDate("s"),(u?[0,0,0,0]:[23,59,59,999]).slice(t)),d)},f=this.$W,g=this.$M,m=this.$D,v="set"+(this.$u?"UTC":"");switch(c){case s:return u?h(1,0):h(31,11);case o:return u?h(1,g):h(0,g+1);case r:var y=this.$locale().weekStart||0,x=(f<y?f+7:f)-y;return h(u?m-x:m+(6-x),g);case"day":case l:return p(v+"Hours",0);case i:return p(v+"Minutes",1);case n:return p(v+"Seconds",2);case t:return p(v+"Milliseconds",3);default:return this.clone()}},p.endOf=function(e){return this.startOf(e,!1)},p.$set=function(r,a){var d,u=b.p(r),c="set"+(this.$u?"UTC":""),h=((d={}).day=c+"Date",d[l]=c+"Date",d[o]=c+"Month",d[s]=c+"FullYear",d[i]=c+"Hours",d[n]=c+"Minutes",d[t]=c+"Seconds",d[e]=c+"Milliseconds",d)[u],p="day"===u?this.$D+(a-this.$W):a;if(u===o||u===s){var f=this.clone().set(l,1);f.$d[h](p),f.init(),this.$d=f.set(l,Math.min(this.$D,f.daysInMonth())).$d}else h&&this.$d[h](p);return this.init(),this},p.set=function(e,t){return this.clone().$set(e,t)},p.get=function(e){return this[b.p(e)]()},p.add=function(e,a){var l,d=this;e=Number(e);var u=b.p(a),c=function(t){var n=y(d);return b.w(n.date(n.date()+Math.round(t*e)),d)};if(u===o)return this.set(o,this.$M+e);if(u===s)return this.set(s,this.$y+e);if("day"===u)return c(1);if(u===r)return c(7);var h=((l={})[n]=6e4,l[i]=36e5,l[t]=1e3,l)[u]||1,p=this.$d.getTime()+e*h;return b.w(p,this)},p.subtract=function(e,t){return this.add(-1*e,t)},p.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return n.invalidDate||d;var i=e||"YYYY-MM-DDTHH:mm:ssZ",r=b.z(this),o=this.$H,a=this.$m,s=this.$M,l=n.weekdays,u=n.months,h=n.meridiem,p=function(e,n,r,o){return e&&(e[
230n]||e(t,i))||r[n].slice(0,o)},f=function(e){return b.s(o%12||12,e,"0")},g=h||function(e,t,n){var i=e<12?"AM":"PM";return n?i.toLowerCase():i};return i.replace(c,function(e,i){return i||function(e){switch(e){case"YY":return String(t.$y).slice(-2);case"YYYY":return b.s(t.$y,4,"0");case"M":return s+1;case"MM":return b.s(s+1,2,"0");case"MMM":return p(n.monthsShort,s,u,3);case"MMMM":return p(u,s);case"D":return t.$D;case"DD":return b.s(t.$D,2,"0");case"d":return String(t.$W);case"dd":return p(n.weekdaysMin,t.$W,l,2);case"ddd":return p(n.weekdaysShort,t.$W,l,3);case"dddd":return l[t.$W];case"H":return String(o);case"HH":return b.s(o,2,"0");case"h":return f(1);case"hh":return f(2);case"a":return g(o,a,!0);case"A":return g(o,a,!1);case"m":return String(a);case"mm":return b.s(a,2,"0");case"s":return String(t.$s);case"ss":return b.s(t.$s,2,"0");case"SSS":return b.s(t.$ms,3,"0");case"Z":return r}return null}(e)||r.replace(":","")})},p.utcOffset=function(){return-(15*Math.round(this.$d.getTimezoneOffset()/15))},p.diff=function(e,l,d){var u,c=this,h=b.p(l),p=y(e),f=(p.utcOffset()-this.utcOffset())*6e4,g=this-p,m=function(){return b.m(c,p)};switch(h){case s:u=m()/12;break;case o:u=m();break;case a:u=m()/3;break;case r:u=(g-f)/6048e5;break;case"day":u=(g-f)/864e5;break;case i:u=g/36e5;break;case n:u=g/6e4;break;case t:u=g/1e3;break;default:u=g}return d?u:b.a(u)},p.daysInMonth=function(){return this.endOf(o).$D},p.$locale=function(){return f[this.$L]},p.locale=function(e,t){if(!e)return this.$L;var n=this.clone(),i=v(e,t,!0);return i&&(n.$L=i),n},p.clone=function(){return b.w(this.$d,this)},p.toDate=function(){return new Date(this.valueOf())},p.toJSON=function(){return this.isValid()?this.toISOString():null},p.toISOString=function(){return this.$d.toISOString()},p.toString=function(){return this.$d.toUTCString()},h}(),w=x.prototype;return y.prototype=w,[["$ms",e],["$s",t],["$m",n],["$H",i],["$W","day"],["$M",o],["$y",s],["$D",l]].forEach(function(e){w[e[1]]=function(t){return this.$g(t,e[0],e[1])}}),y.extend=function(e,t){return e.$i||(e(t,x,y),e.$i=!0),y},y.locale=v,y.isDayjs=m,y.unix=function(e){return y(1e3*e)},y.en=f[p],y.Ls=f,y.p={},y}()},92558,(e,t,n)=>{e.e,t.exports=function(e,t,n){var i=function(e){return e.add(4-e.isoWeekday(),"day")},r=t.prototype;r.isoWeekYear=function(){return i(this).year()},r.isoWeek=function(e){if(!this.$utils().u(e))return this.add(7*(e-this.isoWeek()),"day");var t,r,o,a=i(this),s=(t=this.isoWeekYear(),o=4-(r=(this.$u?n.utc:n)().year(t).startOf("year")).isoWeekday(),r.isoWeekday()>4&&(o+=7),r.add(o,"day"));return a.diff(s,"week")+1},r.isoWeekday=function(e){return this.$utils().u(e)?this.day()||7:this.day(this.day()%7?e:e-7)};var o=r.startOf;r.startOf=function(e,t){var n=this.$utils(),i=!!n.u(t)||t;return"isoweek"===n.p(e)?i?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):o.bind(this)(e,t)}}},68033,29,55227,85250,94957,29915,69152,70920,20633,14128,62612,29690,46471,42993,59678,76554,60436,44249,93297,86824,56370,565,91395,20790,24831,90370,39344,52052,61426,83742,e=>{"use strict";var t,n,i,r,o,a,s,l=e.i(48277),d=e.i(94059),u=e.i(30668),c=e.i(11948),h=e.i(31734),p=e.i(73596),f=e.i(90112),g=e.i(15502),m=e.i(77219),v=e.i(1584),y=e.i(24133),b=e.i(52487),x=e.i(58960),w=e.i(20425),C=e.i(56297),S=e.i(23414);function _(e,t,n){return void 0===t&&void 0===n?e:void 0!==t&&void 0===n?Math.max(e,t):void 0===t&&void 0!==n?Math.min(e,n):Math.min(Math.max(e,t),n)}e.s(["clamp",()=>_],29);var k=e.i(20826);let[M,T]=(0,k.createSafeContext)("Carousel component was not found in tree");var D={root:"m_17884d0f",viewport:"m_a2dae653",container:"m_fcd81474",controls:"m_39bc3463",control:"m_64f58e10",indicators:"m_71ea3ab1",indicator:"m_eae68602",slide:"m_d98df724"};let R=(0,m.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,mod:s,...d}=(0,v.useProps)("CarouselSlide",null,e),u=T();return(0,l.jsx)(C.Box,{ref:t,mod:[{orientation:u.orientation},s],...u.getStyles("slide",{className:i,style:r,classNames:n,styles:o}),...d})});R.classes=D,R.displayName="@mantine/carousel/CarouselSlide";
230var I=e.i(78720);function A(e){return"object"==typeof e&&null!==e?"base"in e?e.base:void 0:e}e.s(["getBaseValue",()=>A],55227);var P=e.i(12493),E=e.i(11920),L=e.i(87481),F=e.i(27395);function O(e,t){let n=e.map(e=>({value:e,px:e in t?(0,F.px)(t[e]):(0,F.px)(e)}));return n.sort((e,t)=>e.px-t.px),n}function N({slideGap:e,slideSize:t,selector:n}){let i=(0,E.useMantineTheme)(),r=(0,I.filterProps)({"--carousel-slide-gap":(0,f.getSpacing)(A(e)),"--carousel-slide-size":(0,g.rem)(A(t))}),o=(0,L.keys)(i.breakpoints).reduce((n,i)=>(n[i]||(n[i]={}),"object"==typeof e&&void 0!==e[i]&&(n[i]["--carousel-slide-gap"]=(0,f.getSpacing)(e[i])),"object"==typeof t&&void 0!==t[i]&&(n[i]["--carousel-slide-size"]=(0,f.getSpacing)(t[i])),n),{}),a=O((0,L.keys)(o),i.breakpoints).filter(e=>(0,L.keys)(o[e.value]).length>0).map(e=>({query:`(min-width: ${i.breakpoints[e.value]})`,styles:o[e.value]}));return(0,l.jsx)(P.InlineStyles,{styles:r,media:a,selector:n})}function B(e){return"object"==typeof e&&null!==e?(0,L.keys)(e):[]}function z({slideGap:e,slideSize:t,selector:n}){let i=(0,I.filterProps)({"--carousel-slide-gap":(0,f.getSpacing)(A(e)),"--carousel-slide-size":(0,g.rem)(A(t))}),r=(function({slideGap:e,slideSize:t}){return Array.from(new Set([...B(e),...B(t)])).sort((e,t)=>(0,F.px)(e)-(0,F.px)(t))})({slideGap:e,slideSize:t}).reduce((n,i)=>(n[i]||(n[i]={}),"object"==typeof e&&void 0!==e[i]&&(n[i]["--carousel-slide-gap"]=(0,f.getSpacing)(e[i])),"object"==typeof t&&void 0!==t[i]&&(n[i]["--carousel-slide-size"]=(0,f.getSpacing)(t[i])),n),{}),o=Object.keys(r).map(e=>({query:`carousel (min-width: ${e})`,styles:r[e]}));return(0,l.jsx)(P.InlineStyles,{styles:i,container:o,selector:n})}function j({dir:e,orientation:t,direction:n}){return"previous"===n?"horizontal"===t?90*("ltr"===e?1:-1):-180:"horizontal"===t?90*("ltr"===e?-1:1):0}e.s(["getSortedBreakpoints",()=>O],85250);let V={controlSize:26,controlsOffset:"sm",slideSize:"100%",slideGap:0,orientation:"horizontal",includeGapInSize:!0,initialSlide:0,withControls:!0,withIndicators:!1,withKeyboardEvents:!0,type:"media"},H={align:"center",loop:!1,slidesToScroll:1,dragFree:!1,inViewThreshold:0,skipSnaps:!1,containScroll:"trimSnaps"},G=(0,p.createVarsResolver)((e,{height:t,controlSize:n,controlsOffset:i})=>({root:{"--carousel-height":(0,g.rem)(t),"--carousel-control-size":(0,g.rem)(n),"--carousel-controls-offset":(0,f.getSpacing)(i)}})),W=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("Carousel",V,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,children:c,getEmblaApi:p,onNextSlide:f,onPreviousSlide:g,onSlideChange:m,nextControlProps:k,previousControlProps:T,controlSize:R,controlsOffset:I,slideSize:A,slideGap:P,orientation:E,height:L,includeGapInSize:F,draggable:O,initialSlide:B,withControls:W,withIndicators:$,plugins:U,nextControlIcon:q,previousControlIcon:K,withKeyboardEvents:Y,mod:Z,type:X,emblaOptions:J,attributes:Q,...ee}=n,et=(0,y.useStyles)({name:"Carousel",classes:D,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:Q,vars:d,varsResolver:G}),en=(0,b.useRandomClassName)(),{dir:ei}=(0,x.useDirection)(),[er,eo]=(0,h.default)({axis:"horizontal"===E?"x":"y",direction:"horizontal"===E?ei:void 0,startIndex:B,...H,...J},U),[ea,es]=(0,u.useState)(0),[el,ed]=(0,u.useState)(0),eu=(0,u.useCallback)(e=>eo&&eo.scrollTo(e),[eo]),ec=(0,u.useCallback)(()=>{if(!eo)return;let e=eo.selectedScrollSnap();es(e),e!==ea&&m?.(e)},[eo,es,m,ea]),eh=(0,u.useCallback)(()=>{eo?.scrollPrev(),g?.()},[eo]),ep=(0,u.useCallback)(()=>{eo?.scrollNext(),f?.()},[eo]),ef=(0,u.useCallback)(e=>{Y&&("ArrowRight"===e.key&&(e.preventDefault(),ep()),"ArrowLeft"===e.key&&(e.preventDefault(),eh()))},[eo]);(0,u.useEffect)(()=>{if(eo)return p?.(eo),ec(),ed(eo.scrollSnapList().length),eo.on("select",ec),()=>{eo.off("select",ec)}},[eo,J?.slidesToScroll,ec]),(0,u.useEffect)(()=>{eo&&(eo.reInit(),ed(eo.scrollSnapList().length),es(e=>_(e,0,u.Children.toArray(c).length-1)))},[u.Children.toArray(c).length,J?.slidesToScroll]);let eg=eo?.canScrollPrev()||!1,em=eo?.canScrollNext()||!1,ev=Array(el).fill(0).map((e,t)=>(0,u.createElement)(w.UnstyledButton,{...et("indicator"),key:t,"data-active":t===ea||void 0,"aria-hidden":!0,tabIndex:-1,onClick:()=>eu(t),"data-orientation":E,onMouseDown:e=>e.preventDefault()}));return(0,l.jsxs)(M,{value:{getStyles:et,orientation:E},children:["container"===X?(0,l.jsx)(z,{...n,selector:`.${en}`}):(0,l.jsx)(N,{...n,selector:`.${en}`}),(0,l.jsxs)(C.Box,{ref:t,...et("root",{className:"responsiveClassName"}),...ee,mod:[{orientation:E,"include-gap-in-size":F},Z],onKeyDownCapture:ef,children:[W&&(0,l.jsxs)("div",{...et("controls"),"data-orientation":E,children:[(0,l.jsx)(w.UnstyledButton,{...T,...et("control",{className:T?.className,style:T?.style}),onClick:e=>{eh(),T?.onClick?.(e)},"data-inactive":!eg||void 0,"data-type":"previous",tabIndex:eg?0:-1,children:void 0!==K?K:(0,l.jsx)(S.AccordionChevron,{style:{transform:`rotate(${j({dir:ei,orientation:E,direction:"previous"})}deg)`}})}),(0,l.jsx)(w.UnstyledButton,{...et("control",{className:k?.className,style:k?.style}),...k,onClick:e=>{ep(),k?.onClick?.(e)},"data-inactive":!em||void 0,"data-type":"next",tabIndex:em?0:-1,children:void 0!==q?q:(0,l.jsx)(S.AccordionChevron,{style:{transform:`rotate(${j({dir:ei,orientation:E,direction:"next"})}deg)`}})})]}),(0,l.jsx)("div",{...et("viewport"),ref:er,"data-type":X,children:(0,l.jsx)("div",{...et("container",{className:en}),"data-orientation":E,children:c})}),$&&(0,l.jsx)("div",{...et("indicators"),"data-orientation":E,children:ev})]})]})});W.classes=D,W.displayName="@mantine/carousel/Carousel",W.Slide=R;var $=e.i(52265),U=e.i(90388),q=e.i(10395),K=e.i(84395),Y=e.i(64491),Z=e.i(86577),X=e.i(86957),J=e.i(5298);let Q=({overlayText:e,links:t,className:n="",softEdges:i=!1,backgroundColor:r="none",withShadow:o=!1})=>{let{tenant:a}=(0,U.useTenant)();return(0,J.hasRichTextContent)(e)||t?.length?(0,l.jsxs)("div",{className:[Y.default.overlay__container,n,"white"===r?Y.default.whiteBg:"semiTransparent"===r?Y.default.semiTransparentBg:"",i?Y.default.softEdges:"",Y.default[`border-radius--${a.Theme?.borderRadius}
230`],o?Y.default.withShadow:""].filter(Boolean).join(" "),children:[(0,J.hasRichTextContent)(e)&&(0,l.jsx)(X.default,{content:e,withRadius:!1,excludeFromToc:!0}),Array.isArray(t)&&t.length>0&&(0,l.jsx)(K.Flex,{gap:"md",justify:"flex-start",align:"center",children:t.map(({link:e},t)=>e?(0,l.jsx)("div",{children:(0,l.jsx)(Z.CMSLink,{...e})},t):null)})]}):null};e.s(["Overlay",0,Q],94957);var ee=e.i(16292);let et=e=>{let{style:t,...n}=e;return(0,l.jsx)(ee.SmartCard,{...n,style:t||void 0,imageSizes:"(min-width: 1200px) 50vw, (min-width: 768px) 75vw, 100vw"})};e.s(["Card",0,et],29915);var en=e.i(17444),ei=e.i(62218),er=e.i(60872),eo=e.i(3218),ea=e.i(78598),es=e.i(99325),el={root:"m_9df02822",content:"m_54c44539",inner:"m_1f958f16",header:"m_d0e2b9cd"};let[ed,eu]=(0,k.createSafeContext)("ModalBase component was not found in tree"),ec=(0,u.forwardRef)(({className:e,...t},n)=>{let i,r=(i=eu(),(0,u.useEffect)(()=>(i.setBodyMounted(!0),()=>i.setBodyMounted(!1)),[]),i.getBodyId()),o=eu();return(0,l.jsx)(C.Box,{ref:n,...t,id:r,className:(0,es.default)({m_5df29311:!o.unstyled},e)})});ec.displayName="@mantine/core/ModalBaseBody";let[eh,ep]=(0,k.createSafeContext)("Modal component was not found in tree"),ef=(0,m.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,...s}=(0,v.useProps)("ModalBody",null,e),d=ep();return(0,l.jsx)(ec,{ref:t,...d.getStyles("body",{classNames:n,style:r,styles:o,className:i}),...s})});ef.classes=el,ef.displayName="@mantine/core/ModalBody";var eg=e.i(1199);let em=(0,u.forwardRef)(({className:e,onClick:t,...n},i)=>{let r=eu();return(0,l.jsx)(eg.CloseButton,{ref:i,...n,onClick:e=>{r.onClose(),t?.(e)},className:(0,es.default)({m_606cb269:!r.unstyled},e),unstyled:r.unstyled})});em.displayName="@mantine/core/ModalBaseCloseButton";let ev=(0,m.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,...s}=(0,v.useProps)("ModalCloseButton",null,e),d=ep();return(0,l.jsx)(em,{ref:t,...d.getStyles("close",{classNames:n,style:r,styles:o,className:i}),...s})});ev.classes=el,ev.displayName="@mantine/core/ModalCloseButton";var ey=e.i(74982),eb=e.i(26460);let ex=(0,u.forwardRef)(({transitionProps:e,className:t,innerProps:n,onKeyDown:i,style:r,...o},a)=>{let s=eu();return(0,l.jsx)(eb.Transition,{mounted:s.opened,transition:"pop",...s.transitionProps,onExited:()=>{s.onExitTransitionEnd?.(),s.transitionProps?.onExited?.()},onEntered:()=>{s.onEnterTransitionEnd?.(),s.transitionProps?.onEntered?.()},...e,children:e=>(0,l.jsx)("div",{...n,className:(0,es.default)({m_60c222c7:!s.unstyled},n.className),children:(0,l.jsx)(ey.FocusTrap,{active:s.opened&&s.trapFocus,innerRef:a,children:(0,l.jsx)(eo.Paper,{...o,component:"section",role:"dialog",tabIndex:-1,"aria-modal":!0,"aria-describedby":s.bodyMounted?s.getBodyId():void 0,"aria-labelledby":s.titleMounted?s.getTitleId():void 0,style:[r,e],className:(0,es.default)({m_fd1ab0aa:!s.unstyled},t),unstyled:s.unstyled,children:o.children})})})})});function ew({children:e}){return(0,l.jsx)(l.Fragment,{children:e})}ex.displayName="@mantine/core/ModalBaseContent";let eC=(0,m.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,children:s,__hidden:d,...u}=(0,v.useProps)("ModalContent",null,e),c=ep(),h=c.scrollAreaComponent||ew;return(0,l.jsx)(ex,{...c.getStyles("content",{className:i,style:r,styles:o,classNames:n}),innerProps:c.getStyles("inner",{className:i,style:r,styles:o,classNames:n}),"data-full-screen":c.fullScreen||void 0,"data-modal-content":!0,"data-hidden":d||void 0,ref:t,...u,children:(0,l.jsx)(h,{style:{maxHeight:c.fullScreen?"100dvh":`calc(100dvh - (${(0,g.rem)(c.yOffset)} * 2))`},children:s})})});eC.classes=el,eC.displayName="@mantine/core/ModalContent";let eS=(0,u.forwardRef)(({className:e,...t},n)=>{let i=eu();return(0,l.jsx)(C.Box,{component:"header",ref:n,className:(0,es.default)({m_b5489c3c:!i.unstyled},e),...t})});eS.displayName="@mantine/core/ModalBaseHeader";let e_=(0,m.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,...s}=(0,v.useProps)("ModalHeader",null,e),d=ep();return(0,l.jsx)(eS,{ref:t,...d.getStyles("header",{classNames:n,style:r,styles:o,className:i}),...s})});e_.classes=el,e_.displayName="@mantine/core/ModalHeader";var ek=e.i(28915);let eM={duration:200,timingFunction:"ease",transition:"fade"},eT=(0,u.forwardRef)(({onClick:e,transitionProps:t,style:n,visible:i,...r},o)=>{let a,s=eu(),d=(a=eu(),{...eM,...a.transitionProps,...t});return(0,l.jsx)(eb.Transition,{mounted:void 0!==i?i:s.opened,...d,transition:"fade",children:t=>(0,l.jsx)(ek.Overlay,{ref:o,fixed:!0,style:[n,t],zIndex:s.zIndex,unstyled:s.unstyled,onClick:t=>{e?.(t),s.closeOnClickOutside&&s.onClose()},...r})})});eT.displayName="@mantine/core/ModalBaseOverlay";let eD=(0,m.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,...s}=(0,v.useProps)("ModalOverlay",null,e),d=ep();return(0,l.jsx)(eT,{ref:t,...d.getStyles("overlay",{classNames:n,style:r,styles:o,className:i}),...s})});eD.classes=el,eD.displayName="@mantine/core/ModalOverlay";
230var eR=function(e,t){return(eR=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function eI(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}eR(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var eA=function(){return(eA=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)};function eP(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&0>t.indexOf(i)&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var r=0,i=Object.getOwnPropertySymbols(e);r<i.length;r++)0>t.indexOf(i[r])&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]]);return n}function eE(e,t,n,i){return new(n||(n=Promise))(function(r,o){function a(e){try{l(i.next(e))}catch(e){o(e)}}function s(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?r(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(a,s)}l((i=i.apply(e,t||[])).next())})}function eL(e,t){var n,i,r,o,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){var l=[o,s];if(n)throw TypeError("Generator is already executing.");for(;a;)try{if(n=1,i&&(r=2&l[0]?i.return:l[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,l[1])).done)return r;switch(i=0,r&&(l=[2&l[0],r.value]),l[0]){case 0:case 1:r=l;break;case 4:return a.label++,{value:l[1],done:!1};case 5:a.label++,i=l[1],l=[0];continue;case 7:l=a.ops.pop(),a.trys.pop();continue;default:if(!(r=(r=a.trys).length>0&&r[r.length-1])&&(6===l[0]||2===l[0])){a=0;continue}if(3===l[0]&&(!r||l[1]>r[0]&&l[1]<r[3])){a.label=l[1];break}if(6===l[0]&&a.label<r[1]){a.label=r[1],r=l;break}if(r&&a.label<r[2]){a.label=r[2],a.ops.push(l);break}r[2]&&a.ops.pop(),a.trys.pop();continue}l=t.call(e,a)}catch(e){l=[6,e],i=0}finally{n=r=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}function eF(e,t,n){if(n||2==arguments.length)for(var i,r=0,o=t.length;r<o;r++)!i&&r in t||(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||t)}e.s(["__assign",()=>eA,"__awaiter",()=>eE,"__extends",()=>eI,"__generator",()=>eL,"__rest",()=>eP,"__spreadArray",()=>eF],69152);var eO="right-scroll-bar-position",eN="width-before-scroll-bar";function eB(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var ez="u">typeof window?u.useLayoutEffect:u.useEffect,ej=new WeakMap,eV=(void 0===t&&(t={}),(void 0===n&&(n=function(e){return e}),i=[],r=!1,o={read:function(){if(r)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return i.length?i[i.length-1]:null},useMedium:function(e){var t=n(e,r);return i.push(t),function(){i=i.filter(function(e){return e!==t})}},assignSyncMedium:function(e){for(r=!0;i.length;){var t=i;i=[],t.forEach(e)}i={push:function(t){return e(t)},filter:function(){return i}}},assignMedium:function(e){r=!0;var t=[];if(i.length){var n=i;i=[],n.forEach(e),t=i}var o=function(){var n=t;t=[],n.forEach(e)},a=function(){return Promise.resolve().then(o)};a(),i={push:function(e){t.push(e),a()},filter:function(e){return t=t.filter(e),i}}}}).options=eA({async:!0,ssr:!1},t),o),eH=function(){},eG=u.forwardRef(function(e,t){var n,i,r,o,a=u.useRef(null),s=u.useState({onScrollCapture:eH,onWheelCapture:eH,onTouchMoveCapture:eH}),l=s[0],d=s[1],c=e.forwardProps,h=e.children,p=e.className,f=e.removeScrollBar,g=e.enabled,m=e.shards,v=e.sideCar,y=e.noRelative,b=e.noIsolation,x=e.inert,w=e.allowPinchZoom,C=e.as,S=e.gapMode,_=eP(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),k=(n=[a,t],i=function(e){return n.forEac
230h(function(t){return eB(t,e)})},(r=(0,u.useState)(function(){return{value:null,callback:i,facade:{get current(){return r.value},set current(value){var e=r.value;e!==value&&(r.value=value,r.callback(value,e))}}}})[0]).callback=i,o=r.facade,ez(function(){var e=ej.get(o);if(e){var t=new Set(e),i=new Set(n),r=o.current;t.forEach(function(e){i.has(e)||eB(e,null)}),i.forEach(function(e){t.has(e)||eB(e,r)})}ej.set(o,n)},[n]),o),M=eA(eA({},_),l);return u.createElement(u.Fragment,null,g&&u.createElement(v,{sideCar:eV,removeScrollBar:f,shards:m,noRelative:y,noIsolation:b,inert:x,setCallbacks:d,allowPinchZoom:!!w,lockRef:a,gapMode:S}),c?u.cloneElement(u.Children.only(h),eA(eA({},M),{ref:k})):u.createElement(void 0===C?"div":C,eA({},M,{className:p,ref:k}),h))});eG.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},eG.classNames={fullWidth:eN,zeroRight:eO};var eW=function(e){var t=e.sideCar,n=eP(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var i=t.read();if(!i)throw Error("Sidecar medium not found");return u.createElement(i,eA({},n))};eW.isSideCarExport=!0;var e$=function(){var e=0,t=null;return{add:function(n){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=s||("u">typeof __webpack_nonce__?__webpack_nonce__:void 0);return t&&e.setAttribute("nonce",t),e}())){var i,r;(i=t).styleSheet?i.styleSheet.cssText=n:i.appendChild(document.createTextNode(n)),r=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(r)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},eU=function(){var e=e$();return function(t,n){u.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},eq=function(){var e=eU();return function(t){return e(t.styles,t.dynamic),null}},eK={left:0,top:0,right:0,gap:0},eY=function(e){return parseInt(e||"",10)||0},eZ=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],i=t["padding"===e?"paddingTop":"marginTop"],r=t["padding"===e?"paddingRight":"marginRight"];return[eY(n),eY(i),eY(r)]},eX=function(e){if(void 0===e&&(e="margin"),"u"<typeof window)return eK;var t=eZ(e),n=document.documentElement.clientWidth,i=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,i-n+t[2]-t[0])}},eJ=eq(),eQ="data-scroll-locked",e0=function(e,t,n,i){var r=e.left,o=e.top,a=e.right,s=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(i,";\n padding-right: ").concat(s,"px ").concat(i,";\n }\n body[").concat(eQ,"] {\n overflow: hidden ").concat(i,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(i,";"),"margin"===n&&"\n padding-left: ".concat(r,"px;\n padding-top: ").concat(o,"px;\n padding-right: ").concat(a,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(i,";\n "),"padding"===n&&"padding-right: ".concat(s,"px ").concat(i,";")].filter(Boolean).join(""),"\n }\n \n .").concat(eO," {\n right: ").concat(s,"px ").concat(i,";\n }\n \n .").concat(eN," {\n margin-right: ").concat(s,"px ").concat(i,";\n }\n \n .").concat(eO," .").concat(eO," {\n right: 0 ").concat(i,";\n }\n \n .").concat(eN," .").concat(eN," {\n margin-right: 0 ").concat(i,";\n }\n \n body[").concat(eQ,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},e1=function(){var e=parseInt(document.body.getAttribute(eQ)||"0",10);return isFinite(e)?e:0},e2=function(){u.useEffect(function(){return document.body.setAttribute(eQ,(e1()+1).toString()),function(){var e=e1()-1;e<=0?document.body.removeAttribute(eQ):document.body.setAttribute(eQ,e.toString())}},[])},e3=function(e){var t=e.noRelative,n=e.noImportant,i=e.gapMode,r=void 0===i?"margin":i;e2();var o=u.useMemo(function(){return eX(r)},[r]);return u.createElement(eJ,{styles:e0(o,!t,r,n?"":"!important")})},e5=!1;if("u">typeof window)try{var e4=Object.defineProperty({},"passive",{get:function(){return e5=!0,!0}});window.addEventListener("test",e4,e4),window.removeEventListener("test",e4,e4)}catch(e){e5=!1}var e6=!!e5&&{passive:!1},e8=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&(n.overflowY!==n.overflowX||"TEXTAREA"===e.tagName||"visible"!==n[t])},e7=function(e,t){var n=t.ownerDocument,i=t;do{if("u">typeof ShadowRoot&&i instanceof ShadowRoot&&(i=i.host),e9(e,i)){var r=te(e,i);if(r[1]>r[2])return!0}i=i.parentNode}while(i&&i!==n.body)return!1},e9=function(e,t){return"v"===e?e8(t,"overflowY"):e8(t,"overflowX")},te=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},tt=function(e,t,n,i,r){var o,a=(o=window.getComputedStyle(t).direction,"h"===e&&"rtl"===o?-1:1),s=a*i,l=n.target,d=t.contains(l),u=!1,c=s>0,h=0,p=0;
230do{if(!l)break;var f=te(e,l),g=f[0],m=f[1]-f[2]-a*g;(g||m)&&e9(e,l)&&(h+=m,p+=g);var v=l.parentNode;l=v&&v.nodeType===Node.DOCUMENT_FRAGMENT_NODE?v.host:v}while(!d&&l!==document.body||d&&(t.contains(l)||t===l))return c&&(r&&1>Math.abs(h)||!r&&s>h)?u=!0:!c&&(r&&1>Math.abs(p)||!r&&-s>p)&&(u=!0),u},tn=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},ti=function(e){return[e.deltaX,e.deltaY]},tr=function(e){return e&&"current"in e?e.current:e},to=0,ta=[];let ts=(a=function(e){var t=u.useRef([]),n=u.useRef([0,0]),i=u.useRef(),r=u.useState(to++)[0],o=u.useState(eq)[0],a=u.useRef(e);u.useEffect(function(){a.current=e},[e]),u.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(r));var t=eF([e.lockRef.current],(e.shards||[]).map(tr),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add("allow-interactivity-".concat(r))}),function(){document.body.classList.remove("block-interactivity-".concat(r)),t.forEach(function(e){return e.classList.remove("allow-interactivity-".concat(r))})}}},[e.inert,e.lockRef.current,e.shards]);var s=u.useCallback(function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!a.current.allowPinchZoom;var r,o=tn(e),s=n.current,l="deltaX"in e?e.deltaX:s[0]-o[0],d="deltaY"in e?e.deltaY:s[1]-o[1],u=e.target,c=Math.abs(l)>Math.abs(d)?"h":"v";if("touches"in e&&"h"===c&&"range"===u.type)return!1;var h=window.getSelection(),p=h&&h.anchorNode;if(p&&(p===u||p.contains(u)))return!1;var f=e7(c,u);if(!f)return!0;if(f?r=c:(r="v"===c?"h":"v",f=e7(c,u)),!f)return!1;if(!i.current&&"changedTouches"in e&&(l||d)&&(i.current=r),!r)return!0;var g=i.current||r;return tt(g,t,e,"h"===g?l:d,!0)},[]),l=u.useCallback(function(e){if(ta.length&&ta[ta.length-1]===o){var n="deltaY"in e?ti(e):tn(e),i=t.current.filter(function(t){var i;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(i=t.delta,i[0]===n[0]&&i[1]===n[1])})[0];if(i&&i.should){e.cancelable&&e.preventDefault();return}if(!i){var r=(a.current.shards||[]).map(tr).filter(Boolean).filter(function(t){return t.contains(e.target)});(r.length>0?s(e,r[0]):!a.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),d=u.useCallback(function(e,n,i,r){var o={name:e,delta:n,target:i,should:r,shadowParent:function(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}(i)};t.current.push(o),setTimeout(function(){t.current=t.current.filter(function(e){return e!==o})},1)},[]),c=u.useCallback(function(e){n.current=tn(e),i.current=void 0},[]),h=u.useCallback(function(t){d(t.type,ti(t),t.target,s(t,e.lockRef.current))},[]),p=u.useCallback(function(t){d(t.type,tn(t),t.target,s(t,e.lockRef.current))},[]);u.useEffect(function(){return ta.push(o),e.setCallbacks({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:p}),document.addEventListener("wheel",l,e6),document.addEventListener("touchmove",l,e6),document.addEventListener("touchstart",c,e6),function(){ta=ta.filter(function(e){return e!==o}),document.removeEventListener("wheel",l,e6),document.removeEventListener("touchmove",l,e6),document.removeEventListener("touchstart",c,e6)}},[]);var f=e.removeScrollBar,g=e.inert;return u.createElement(u.Fragment,null,g?u.createElement(o,{styles:"\n .block-interactivity-".concat(r," {pointer-events: none;}\n .allow-interactivity-").concat(r," {pointer-events: all;}\n")}):null,f?u.createElement(e3,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},eV.useMedium(a),eW);var tl=u.forwardRef(function(e,t){return u.createElement(eG,eA({},e,{ref:t,sideCar:ts}))});tl.classNames=eG.classNames;var td=e.i(5565),tu=e.i(57472),tc=e.i(43819),th=e.i(76354),tp=e.i(7223);let tf=(0,u.forwardRef)(({keepMounted:e,opened:t,onClose:n,id:i,transitionProps:r,onExitTransitionEnd:o,onEnterTransitionEnd:a,trapFocus:s,closeOnEscape:d,returnFocus:c,closeOnClickOutside:h,withinPortal:p,portalProps:g,lockScroll:m,children:v,zIndex:y,shadow:b,padding:x,__vars:w,unstyled:S,removeScrollProps:_,...k},M)=>{let{_id:T,titleMounted:D,bodyMounted:R,shouldLockScroll:I,setTitleMounted:A,setBodyMounted:P}=function({id:e,transitionProps:t,opened:n,trapFocus:i,closeOnEscape:r,onClose:o,returnFocus:a}){let s=(0,tu.useId)(e),[l,d]=(0,u.useState)(!1),[c,h]=(0,u.useState)(!1),p=function({opened:e,transitionDuration:t}){let[n,i]=(0,u.useState)(e),r=(0,u.useRef)(-1),o=(0,tp.useReducedMotion)()?0:t;return(0,u.useEffect)(()=>(e?(i(!0),window.clearTimeout(r.current)):0===o?i(!1):r.current=window.setTimeout(()=>i(!1),o),()=>window.clearTimeout(r.current)),[e,o]),n}({opened:n,transitionDuration:"number"==typeof t?.duration?t?.duration:200});return(0,tc.useWindowEvent)("keydown",e=>{"Escape"===e.key&&r&&!e.isComposing&&n&&e.target?.getAttribute("data-mantine-stop-propagation")!=="true"&&o()},{capture:!0}),(0,th.useFocusReturn)({opened:n,shouldReturnFocus:i&&a}),{_id:s,titleMounted:l,bodyMounted:c,shouldLockScroll:p,setTitleMounted:d,setBodyMounted:h}}({id:i,transitionProps:r,opened:t,trapFocus:s,closeOnEscape:d,onClose:n,returnFocus:c}),{key:E,...L}=_||{};return(0,l.jsx)(td.OptionalPortal,{...g,withinPortal:p,children:(0,l.jsx)(ed,{value:{opened:t,onClose:n,closeOnClickOutside:h,onExitTransitionEnd:o,onEnterTransitionEnd:a,transitionProps:{...r,keepMounted:e},getTitleId:()=>`${T}-title`,getBodyId:()=>`${T}-body`,titleMounted:D,bodyMounted:R,setTitleMounted:A,setBodyMounted:P,trapFocus:s,closeOnEscape:d,zIndex:y,unstyled:S},children:(0,l.jsx)(tl,{enabled:I&&m,...L,children:(0,l.jsx)(C.Box,{ref:M,...k,__vars:{...w,"--mb-z-index":(y||(0,ea.getDefaultZIndex)("modal")).toString(),"--mb-shadow":(0,f.getShadow)(b),"--mb-padding":(0,f.getSpacing)(x)},children:v})},E)})})});tf.displayName="@mantine/core/ModalBase";var tg=e.i(78941);let tm={__staticSelector:"Modal",closeOnClickOutside:!0,withinPortal:!0,lockScroll:!0,trapFocus:!0,returnFocus:!0,closeOnEscape:!0,keepMounted:!1,zIndex:(0,ea.getDefaultZIndex)("modal"),transitionProps:{duration:200,transition:"fade-down"},yOffset:"5dvh"},tv=(0,p.createVarsResolver)((e,{radius:t,size:n,yOffset:i,xOffset:r})=>({root:{"--modal-radius":void 0===t?void 0:(0,f.getRadius)(t),"--modal-size":(0,f.getSize)(n,"modal-size"),"--modal-y-offset":(0,g.rem)(i),"--modal-x-offset":(0,g.rem)(r)}})),ty=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("ModalRoot",tm,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,yOffset:u,scrollAreaComponent:c,radius:h,fullScreen:p,centered:f,xOffset:g,__staticSelector:m,attributes:b,...x}=n,w=(0,y.useStyles)({name:m,classes:el,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:b,vars:d,varsResolver:tv});return(0,l.jsx)(eh,{value:{yOffset:u,scrollAreaComponent:c,getStyles:w,fullScreen:p},children:(0,l.jsx)(tf,{ref:t,...w("root"),"data-full-screen":p||void 0,"data-centered":f||void 0,"data-offset-scrollbars":c===tg.ScrollArea.Autosize||void 0,unstyled:s,...x})})});ty.classes=el,ty.displayName="@mantine/core/ModalRoot";var tb=e.i(58525);let[tx,tw]=(0,tb.createOptionalContext)();function tC({children:e}){let[t,n]=(0,u.useState)([]),[i,r]=(0,u.useState)((0,ea.getDefaultZIndex)("modal"));return(0,l.jsx)(tx,{value:{stack:t,addModal:(e,t)=>{n(t=>[...new Set([...t,e])]),r(e=>"number"==typeof t&&"number"==typeof e?Math.max(e,t):e)},removeModal:e=>n(t=>t.filter(t=>t!==e)),getZIndex:e=>`calc(${i} + ${t.indexOf(e)} + 1)`,currentId:t[t.length-1],maxZIndex:i},children:e})}tC.displayName="@mantine/core/ModalStack";let tS=(0,u.forwardRef)(({className:e,...t},n)=>{let i,r=(i=eu(),(0,u.useEffect)(()=>(i.setTitleMounted(!0),()=>i.setTitleMounted(!1)),[]),i.getTitleId()),o=eu();return(0,l.jsx)(C.Box,{component:"h2",ref:n,className:(0,es.default)({m_615af6c9:!o.unstyled},e),...t,id:r})});tS.displayName="@mantine/core/ModalBaseTitle";let t_=(0,m.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,...s}=(0,v.useProps)("ModalTitle",null,e),d=ep();return(0,l.jsx)(tS,{ref:t,...d.getStyles("title",{classNames:n,style:r,styles:o,className:i}),...s})});t_.classes=el,t_.displayName="@mantine/core/ModalTitle";let tk={closeOnClickOutside:!0,withinPortal:!0,lockScroll:!0,trapFocus:!0,returnFocus:!0,closeOnEscape:!0,keepMounted:!1,zIndex:(0,ea.getDefaultZIndex)("modal"),transitionProps:{duration:200,transition:"fade-down"},withOverlay:!0,withCloseButton:!0},tM=(0,m.factory)((e,t)=>{let{title:n,withOverlay:i,overlayProps:r,withCloseButton:o,closeButtonProps:a,children:s,radius:d,opened:c,stackId:h,zIndex:p,...f}=(0,v.useProps)("Modal",tk,e),g=tw(),m=!!n||o,y=g&&h?{closeOnEscape:g.currentId===h,trapFocus:g.currentId===h,zIndex:g.getZIndex(h)}:{},b=!1!==i&&(h&&g?g.currentId===h:c);return(0,u.useEffect)(()=>{g&&h&&(c?g.addModal(h,p||(0,ea.getDefaultZIndex)("modal")):g.removeModal(h))},[c,h,p]),(0,l.jsxs)(ty,{ref:t,radius:d,opened:c,zIndex:g&&h?g.getZIndex(h):p,...f,...y,children:[i&&(0,l.jsx)(eD,{visible:b,transitionProps:g&&h?{duration:0}:void 0,...r}),(0,l.jsxs)(eC,{radius:d,__hidden:!!g&&!!h&&!!c&&h!==g.currentId,children:[m&&(0,l.jsxs)(e_,{children:[n&&(0,l.jsx)(t_,{children:n}),o&&(0,l.jsx)(ev,{...a})]}),(0,l.jsx)(ef,{children:s})]})]})});tM.classes=el,tM.displayName="@mantine/core/Modal",tM.Root=ty,tM.Overlay=eD,tM.Content=eC,tM.Body=ef,tM.Header=e_,tM.Title=t_,tM.CloseButton=ev,tM.Stack=tC,e.s(["Modal",()=>tM],70920);let tT=({className:e})=>(0,l.jsx)("svg",{className:e,xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",children:(0,l.jsx)("path",{d:"M9 9L4 4M4 4V8M4 4H8M15 9L20 4M20 4V8M20 4H16M9 15L4 20M4 20V16M4 20H8M15 15L20 20M2
2300 20V16M20 20H16",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})});var tD=e.i(74709);let tR=({thumbnail:e,children:t,active:n=!1,thumbnailClickable:i=!1,caption:r,link:o,wrapperClassName:a})=>{let[s,d]=(0,u.useState)(!1),c=o&&!n?(0,l.jsx)(Z.CMSLink,{...o,appearance:null,cardLink:!0,children:e}):(0,l.jsxs)("div",{onClick:()=>{n&&i&&d(!0)},className:`${n?tD.default.lightboxWrapper:""} ${a||""}`,style:{cursor:n&&i?"pointer":"default"},children:[e,n&&(0,l.jsx)("div",{className:tD.default.lightboxIcon,onClick:e=>{e.stopPropagation(),n&&d(!0)},children:(0,l.jsx)(tT,{className:tD.default.lightboxIconSvg})})]});return(0,l.jsxs)(l.Fragment,{children:[c,n&&(0,l.jsxs)(tM,{opened:s,onClose:()=>d(!1),size:"auto",centered:!0,padding:0,classNames:{content:tD.default.modalContent},styles:{header:{display:"none"}},children:[t,r&&(0,l.jsx)("div",{className:tD.default.modalCaption,children:(0,l.jsx)(X.default,{className:tD.default.modalCaption__text,content:r,excludeFromToc:!0})})]})]})},tI=e=>{let{tenant:t}=(0,U.useTenant)(),{media:n,mediaFit:i,thumbnail:r,mediaBlockPosition:o,mediaBlockAlignment:a="left",width:s=100,staticImage:d,caption:u,captionBackgroundColor:c,thumbnailCaption:h,withRadius:p=!0,mediaLink:f,enableLink:g=!1}=e,m=[ei.default.mediaBlock,"default"===o&&ei.default.default,"default"===o&&"left"===a&&ei.default.left,"default"===o&&"center"===a&&ei.default.center,"default"===o&&"right"===a&&ei.default.right].filter(Boolean).join(" "),v=[ei.default.mediaBlock__caption,c?`${ei.default[`mediaBlock__caption--${c}`]} ${ei.default["mediaBlock__caption--withBg"]}`:""].filter(Boolean).join(" "),y=!!r,b=y?h:u,x=u&&(0,J.hasRichTextContent)(u)?u:h&&(0,J.hasRichTextContent)(h)?h:null,w=(0,l.jsx)(en.Media,{resource:r||n,src:d,className:ei.default.mediaBlock__image,mediaFit:i,sizes:"fullscreen"===o?"100vw":s>=75?`(min-width: 1200px) ${s}vw, (min-width: 768px) ${Math.min(1.2*s,100)}vw, 100vw`:s>=50?`(min-width: 768px) ${s}vw, 100vw`:`${s}vw`}),C=y?(0,l.jsx)(en.Media,{resource:n,src:d,className:ei.default.mediaBlock__image,mediaFit:i,sizes:"100vw"}):null;return(0,l.jsx)(l.Fragment,{children:(0,l.jsxs)("div",{className:m,style:{width:`${s}%`},children:[(0,l.jsx)(eo.Paper,{radius:p?(0,er.getRadius)(t.Theme?.borderRadius):0,className:ei.default.mediaBlock__paper,bg:"transparent",children:(0,l.jsx)(tR,{wrapperClassName:ei.default.mediaBlock__lightbox,thumbnail:w,active:y,thumbnailClickable:!0,caption:x,link:f&&g?f:void 0,children:C})}),b&&(0,J.hasRichTextContent)(b)&&(0,l.jsx)("div",{className:v,children:(0,l.jsx)(X.default,{className:ei.default.mediaBlock__captionText,content:b,excludeFromToc:!0})})]})})};e.s(["MediaBlock",0,tI],20633);var tA=e.i(29987);let tP={active:!0,breakpoints:{},delay:4e3,jump:!1,playOnInit:!0,stopOnFocusIn:!0,stopOnInteraction:!0,stopOnMouseEnter:!1,stopOnLastSnap:!1,rootNode:null};function tE(e={}){let t,n,i,r,o=null,a=0,s=!1,l=!1,d=!1,u=!1;function c(){if(!i){if(f()){d=!0;return}s||n.emit("autoplay:play"),function(){let{ownerWindow:e}=n.internalEngine();e.clearTimeout(a),a=e.setTimeout(b,r[n.selectedScrollSnap()]),o=new Date().getTime(),n.emit("autoplay:timerset")}(),s=!0}}function h(){i||(s&&n.emit("autoplay:stop"),function(){let{ownerWindow:e}=n.internalEngine();e.clearTimeout(a),a=0,o=null,n.emit("autoplay:timerstopped")}(),s=!1)}function p(){if(f())return d=s,h();d&&c()}function f(){let{ownerDocument:e}=n.internalEngine();return"hidden"===e.visibilityState}function g(){l||h()}function m(){l||c()}function v(){l=!0,h()}function y(){l=!1,c()}function b(){let{index:e}=n.internalEngine(),i=e.clone().add(1).get(),r=n.scrollSnapList().length-1,o=t.stopOnLastSnap&&i===r;if(n.canScrollNext()?n.scrollNext(u):n.scrollTo(0,u),n.emit("autoplay:select"),o)return h();c()}return{name:"autoplay",options:e,init:function(o,a){var s,l,d,f;let b,x;n=o;let{mergeOptions:w,optionsAtMedia:C}=a,S=w(tP,tE.globalOptions);if(t=C(w(S,e)),n.scrollSnapList().length<=1)return;u=t.jump,i=!1,s=n,l=t.delay,b=s.scrollSnapList(),r="number"==typeof l?b.map(()=>l):l(b,s);let{eventStore:_,ownerDocument:k}=n.internalEngine(),M=!!n.internalEngine().options.watchDrag,T=(d=n,f=t.rootNode,x=d.rootNode(),f&&f(x)||x);_.add(k,"visibilitychange",p),M&&n.on("pointerDown",g),M&&!t.stopOn
230Interaction&&n.on("pointerUp",m),t.stopOnMouseEnter&&_.add(T,"mouseenter",v),t.stopOnMouseEnter&&!t.stopOnInteraction&&_.add(T,"mouseleave",y),t.stopOnFocusIn&&n.on("slideFocusStart",h),t.stopOnFocusIn&&!t.stopOnInteraction&&_.add(n.containerNode(),"focusout",c),t.playOnInit&&c()},destroy:function(){n.off("pointerDown",g).off("pointerUp",m).off("slideFocusStart",h),h(),i=!0,s=!1},play:function(e){void 0!==e&&(u=e),c()},stop:function(){s&&h()},reset:function(){s&&c()},isPlaying:function(){return s},timeUntilNext:function(){return o?r[n.selectedScrollSnap()]-(new Date().getTime()-o):null}}}function tL(e,t,n){return Math.min(Math.max(e,t),n)}function tF(e){return"number"==typeof e&&!isNaN(e)}function tO(e={}){let t,n,i,r,o=[],a=0,s=0,l=0,d=!1;function u(){f(t.selectedScrollSnap(),1)}function c(){d=!1}function h(){d=!1,a=0,s=0}function p(){let e=t.internalEngine().scrollBody.duration();s=+!e,d=!0,e||u()}function f(e,n){t.scrollSnapList().forEach((i,r)=>{let s=Math.abs(n),u=o[r],c=r===e,h=tL(c?u+s:u-s,0,1);o[r]=h;let p=c&&d,f=t.previousScrollSnap();p&&(o[f]=1-h),c&&function(e,n){let{index:i,dragHandler:r,scrollSnaps:o}=t.internalEngine(),s=r.pointerDown(),d=1/(o.length-1),u=e,c=s?t.selectedScrollSnap():t.previousScrollSnap();if(s&&u===c){let e=-1*Math.sign(a);u=c,c=i.clone().set(c).add(e).get()}l=c*d+(u-c)*d*n}(e,h),function(e){let n=t.internalEngine().slideRegistry[e],{scrollSnaps:i,containerRect:r}=t.internalEngine(),a=o[e];n.forEach(n=>{let o=t.slideNodes()[n].style,s=parseFloat(a.toFixed(2)),l=s>0,d=function(e){let{axis:n}=t.internalEngine(),i=n.scroll.toUpperCase();return`translate${i}(${n.direction(e)}px)`}(l?i[e]:r.width+2);l&&(o.transform=d),o.opacity=s.toString(),o.pointerEvents=a>.5?"auto":"none",l||(o.transform=d)})}(r)})}function g(){let{dragHandler:e,index:n,scrollBody:i}=t.internalEngine(),r=t.selectedScrollSnap();if(!e.pointerDown())return r;let o=Math.sign(i.velocity()),s=Math.sign(a),l=n.clone().set(r).add(-1*o).get();return o&&s?s===o?l:r:null}function m(){let{target:e,location:i}=t.internalEngine(),r=Math.abs(e.get()-i.get())>=1,l=g(),d=!tF(l);return!function(e){let{dragHandler:i,scrollBody:r}=e.internalEngine(),l=i.pointerDown(),d=r.velocity(),u=r.duration(),c=g(),h=!tF(c);if(l){if(!d)return;a+=d,s=Math.abs(d/n),function(e){let{scrollSnaps:n,location:i,target:r}=t.internalEngine();tF(e)&&!(o[e]<.5)&&(i.set(n[e]),r.set(i))}(c)}if(!l){if(!u||h)return;s+=(1-o[c])/u,s*=.68}h||f(c,s)}(t),!d&&!r&&o[l]>.999}function v(){return l}return{name:"fade",options:e,init:function(e){let a=(t=e).selectedScrollSnap(),{scrollBody:s,containerRect:l,axis:f}=t.internalEngine();n=tL(.75*f.measureSize(l),200,500),d=!1,o=t.scrollSnapList().map((e,t)=>+(t===a)),i=s.settled,r=t.scrollProgress,s.settled=m,t.scrollProgress=v,t.on("select",p).on("slideFocus",u).on("pointerDown",h).on("pointerUp",c),function(){let{translate:e,slideLooper:n}=t.internalEngine();e.clear(),e.toggleActive(!1),n.loopPoints.forEach(({translate:e})=>{e.clear(),e.toggleActive(!1)})}(),u()},destroy:function(){let{scrollBody:e}=t.internalEngine();e.settled=i,t.scrollProgress=r,t.off("select",p).off("slideFocus",u).off("pointerDown",h).off("pointerUp",c),t.slideNodes().forEach(e=>{let t=e.style;t.opacity="",t.transform="",t.pointerEvents="",e.getAttribute("style")||e.removeAttribute("style")})}}}tE.globalOptions=void 0,tO.globalOptions=void 0;let tN=({radius:e="0",title:t,slides:n,visibleSlides:i=1,loop:r=!1,autoplay:o=!1,autoplayTimer:a=3,transition:s="slide",slideGap:d="xs",CTAstyle:h="withControls"})=>{let{tenant:p}=(0,U.useTenant)(),f=(0,q.useMediaQuery)("(max-width: 768px)"),g=(0,u.useRef)(tE({delay:1e3*a})),m=(0,u.useRef)(tO()),v="fade"===s&&1===i,y=[...o?[g.current]:[],...v?[m.current]:[]];if(!n||0===n.length)return null;let{Theme:b}=p,x=b?.Hero?.softEdges,w="withOverflow"===h?f?"90%":`${100/i-5}%`:f?"100%":`${100/i}%`;return(0,l.jsxs)(l.Fragment,{children:[t&&(0,l.jsx)("h2",{className:c.default.carousel__title,children:t}),(0,l.jsx)(eo.Paper,{radius:e,bg:"transparent",className:[c.default["carousel-wrapper"],"withOverflow"===h?c.default["carousel-wrapper--withOverflow"]:""].filter(
230Boolean).join(" "),children:(0,l.jsx)(W,{emblaOptions:{loop:r,align:"start",containScroll:!v&&"trimSnaps"},slideSize:w,slideGap:d,plugins:y,onMouseEnter:o?g.current.stop:void 0,onMouseLeave:o?()=>g.current.play():void 0,withIndicators:"withControls"===h&&n.length>i,withControls:"withControls"===h,controlSize:24,nextControlIcon:(0,l.jsx)($.Icon,{icon:"arrowDown",className:c.default["carousel__control-right"]}),previousControlIcon:(0,l.jsx)($.Icon,{icon:"arrowDown",className:c.default["carousel__control-left"]}),className:c.default.carousel,classNames:{container:c.default.carousel__container,controls:c.default.carousel__controls,control:c.default.carousel__control,viewport:c.default.carousel__viewport,indicator:c.default.carousel__indicator,indicators:c.default.carousel__indicators,slide:c.default.carousel__slide,root:c.default.carousel__root},children:n.map((e,t)=>(0,l.jsx)(W.Slide,{children:e.layout.map((t,n)=>"mediaBlock"===t.blockType?(0,l.jsxs)(u.default.Fragment,{children:[(0,l.jsx)("div",{className:c.default["carousel__slide-media"],children:(0,l.jsx)(tI,{...t,mediaBlockPosition:"fullscreen",withRadius:!1,mediaLink:t.mediaLink,enableLink:t.enableLink})}),(e.overlayText||e.links)&&(0,l.jsx)(tA.Gutter,{children:(0,l.jsx)(Q,{overlayText:e.overlayText,links:e.links,className:c.default["carousel__slide-overlay"],softEdges:x,backgroundColor:"semiTransparent",withShadow:!f})})]},n):"card"===t.blockType?(0,l.jsx)(et,{...t},n):null)},t))})})]})};e.s(["Carousel",0,tN],14128),e.s(["CarouselBlock",0,e=>{let{slides:t,title:n,visibleSlides:i,slideGap:r,autoplay:o,autoplayTimer:a,transition:s,CTAstyle:u}=e,{tenant:c}=(0,U.useTenant)(),h=c?.Theme?.borderRadius;return t&&0!==t.length?(0,l.jsx)("div",{className:d.default["carouselblock-wrapper"],children:(0,l.jsx)(tN,{radius:h??void 0,title:n,slides:t??[],visibleSlides:i??1,loop:e.loop??!1,autoplay:o??!1,autoplayTimer:a??3,transition:s??"slide",slideGap:r??"xs",CTAstyle:u??"withControls"})}):null}],68033),e.s(["CollapsibleBlock",()=>tH],29690);var tB=e.i(10966),tz=e.i(4694),tj=e.i(14932);let tV=(e,t="block")=>({primary:e[`${t}--primary`],secondary:e[`${t}--secondary`],tertiary:e[`${t}--tertiary`],quaternary:e[`${t}--quaternary`],quinary:e[`${t}--quinary`],sextiary:e[`${t}--sextiary`],senary:e[`${t}--senary`],white:e[`${t}--white`],black:e[`${t}--black`]});e.s(["getColorClasses",0,tV],62612);let tH=e=>{let{width:t,itemBorders:n,itemShadow:i,items:r}=e,{tenant:o}=(0,U.useTenant)(),a=tV(tB.default,"block");return r?(0,l.jsx)(eo.Paper,{bg:"transparent",radius:o?.Theme?.borderRadius||"md",className:tB.default.container,style:{width:`${t}%`},"data-block":"collapsible",children:r.map((e,t)=>(0,l.jsx)(eo.Paper,{radius:o?.Theme?.borderRadius||"md",className:tB.default.itemContainer,withBorder:n||!1,shadow:i?"sm":"none",children:(0,l.jsxs)("details",{className:tB.default.item,children:[(0,l.jsxs)("summary",{className:tB.default.control,children:[(0,l.jsx)("span",{className:tB.default.label,children:e.title}),(0,l.jsx)("span",{className:tB.default.icon,children:(0,l.jsx)(tz.default,{})})]}),(0,l.jsx)("div",{className:tB.default.content,children:e.layout.map((e,t)=>{let{blockType:n}=e,i=(0,tj.getBlockBackgroundColor)(e),r=i&&a[i]?[a[i],tB.default.block,tB.default["block--with-background"]].join(" ").trim():tB.default.block;if(n&&n in tj.blockComponents){let i=tj.blockComponents[n];if(i){let o=n.replace(/Block$/,"").replace(/([A-Z])/g,"-$1").toLowerCase().replace(/^-/,"");return(0,l.jsx)("div",{className:r,children:(0,l.jsx)("div",{"data-block":o,...e.blockDataId?{"data-block-id":e.blockDataId}:{},children:(0,l.jsx)(i,{...e})})},t)}}return null})})]},t)}))}):(0,l.jsx)(l.Fragment,{})};var tG=e=>e instanceof Date,tW=e=>null==e,t$=e=>!tW(e)&&!Array.isArray(e)&&"object"==typeof e&&!tG(e),tU=e=>t$(e)&&e.target?"checkbox"===e.target.type?e.target.checked:e.target.value:e,tq=(e,t)=>t.split(".").some((t,n,i)=>!isNaN(Number(t))&&e.has(i.slice(0,n).join("."))),tK=e=>{let t=e.constructor&&e.constructor.prototype;return t$(t)&&t.hasOwnProperty("isPrototypeOf")},tY="u">typeof window&&void 0!==window.HTMLElement&&"u">typeof document;function tZ(e){if(e instanceof Date)return new Date(e);let t="u">typeof FileList&&e instanceof FileList;if(tY&&(e instanceof Blob||t))return e;let n=Array.isArray(e);if(!n&&!(t$(e)&&tK(e)))return e;let i=n?[]:Object.create(Object.getPrototypeOf(e));for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(i[t]=tZ(e[t]));return i}let tX="blur",tJ="trigger",tQ="onChange",t0="onSubmit",t1="maxLength",t2="minLength",t3="pattern",t5="required",t4="validate",t6="root",t8=["__proto__","constructor","prototype"],t7=/^\w*$/;var t9=e=>void 0===e;let ne=/[.[\]'"]/;var nt=e=>
230e.split(ne).filter(Boolean),nn=(e,t,n)=>{if(!t||!t$(e))return n;let i=t7.test(t)?[t]:nt(t);if(i.some(e=>t8.includes(e)))return n;let r=i.reduce((e,t)=>tW(e)?void 0:e[t],e);return t9(r)||r===e?t9(e[t])?n:e[t]:r},ni=e=>"function"==typeof e,nr=(e,t,n)=>{let i=-1,r=t7.test(t)?[t]:nt(t),o=r.length,a=o-1;for(;++i<o;){let t=r[i],o=n;if(i!==a){let n=e[t];o=t$(n)||Array.isArray(n)?n:isNaN(+r[i+1])?{}:[]}if(t8.includes(t))return;e[t]=o,e=e[t]}};let no=u.default.createContext(null);no.displayName="HookFormControlContext";var na=(e,t,n,i=!0)=>{let r={};for(let o in e)Object.defineProperty(r,o,{get:()=>("all"!==t._proxyFormState[o]&&(t._proxyFormState[o]=!i||"all"),n&&(n[o]=!0),e[o])});return r};let ns=tY?u.default.useLayoutEffect:u.default.useEffect;var nl=e=>"string"==typeof e,nd=(e,t,n,i,r)=>nl(e)?(i&&t.watch.add(e),nn(n,e,r)):Array.isArray(e)?e.map(e=>(i&&t.watch.add(e),nn(n,e))):(i&&(t.watchAll=!0),n),nu=e=>tW(e)||"object"!=typeof e;let nc=(e,t)=>0===t.length&&!Array.isArray(e)&&!tK(e);function nh(e,t,n=new WeakMap){if(e===t)return!0;if(nu(e)||nu(t))return Object.is(e,t);if(tG(e)&&tG(t))return Object.is(e.getTime(),t.getTime());let i=Object.keys(e),r=Object.keys(t);if(i.length!==r.length)return!1;if(nc(e,i)||nc(t,r))return Object.is(e,t);if(!i.length&&Array.isArray(e)!==Array.isArray(t))return!1;let o=n.get(e);if(o&&o.has(t))return!0;if(o)o.add(t);else{let i=new WeakSet;i.add(t),n.set(e,i)}for(let r of i){let i=e[r];if(!(r in t))return!1;if("ref"!==r){let e=t[r];if(tG(i)&&tG(e)||(t$(i)||Array.isArray(i))&&(t$(e)||Array.isArray(e))?!nh(i,e,n):!Object.is(i,e))return!1}}return!0}let np=e=>e.render(function(e){let t=u.default.useContext(no),{name:n,disabled:i,control:r=t,shouldUnregister:o,defaultValue:a,exact:s=!0}=e,l=tq(r._names.array,n),d=u.default.useMemo(()=>nn(r._formValues,n,nn(r._defaultValues,n,a)),[r,n,a]),c=function(e){let t=u.default.useContext(no),{control:n=t,name:i,defaultValue:r,disabled:o,exact:a,compute:s}=e||{},l=u.default.useRef(r),d=u.default.useRef(s),c=u.default.useRef(void 0),h=u.default.useRef(n),p=u.default.useRef(i);d.current=s;let[f,g]=u.default.useState(()=>{let e=n._getWatch(i,l.current);return d.current?d.current(e):e}),m=u.default.useCallback(e=>{let t=nd(i,n._names,e||n._formValues,!1,l.current);return d.current?d.current(t):t},[n._formValues,n._names,i]),v=u.default.useCallback(e=>{if(!o){let t=nd(i,n._names,e||n._formValues,!1,l.current);if(d.current){let e=d.current(t);nh(e,c.current)||(g(e),c.current=e)}else g(t)}},[n._formValues,n._names,o,i]);ns(()=>(h.current===n&&nh(p.current,i)||(h.current=n,p.current=i,v()),n._subscribe({name:i,formState:{values:!0},exact:a,callback:e=>{v(e.values)}})),[n,a,i,v]),u.default.useEffect(()=>n._removeUnmounted());let y=h.current!==n,b=p.current,x=u.default.useMemo(()=>{if(o)return null;let e=!y&&!nh(b,i);return y||e?m():null},[o,y,i,b,m]);return null!==x?x:f}({control:r,name:n,defaultValue:d,exact:s}),h=function(e){let t=u.default.useContext(no),{control:n=t,disabled:i,name:r,exact:o}=e||{},[a,s]=u.default.useState(()=>({...n._formState,defaultValues:n._defaultValues})),l=u.default.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return ns(()=>n._subscribe({name:r,formState:l.current,exact:o,callback:e=>{i||s({...n._formState,...e,defaultValues:n._defaultValues})}}),[r,i,o]),u.default.useEffect(()=>{l.current.isValid&&n._setValid(!0)},[n]),u.default.useMemo(()=>na(a,n,l.current,!1),[a,n])}({control:r,name:n,exact:s}),p=u.default.useRef(e),f=u.default.useRef(null),g=u.default.useRef(r.register(n,{...e.rules,value:c,..."boolean"==typeof e.disabled?{disabled:e.disabled}:{}}));p.current=e;let m=u.default.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!nn(h.errors,n)},isDirty:{enumerable:!0,get:()=>!!nn(h.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!nn(h.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!nn(h.validatingFields,n)},error:{enumerable:!0,get:()=>nn(h.errors,n)}}),[h,n]),v=u.default.useCallback(e=>{let t=tU(e);return nn(r._fields,n)||(g.current=r.register(n,{...p.current.rules,value:t})),g.current.onChange({target:{value:tU(e),name:n},type:"change"})},[n,r]),y=u.default.useCallback(()=>g.current.onBlur({target:{value:nn(r._formValues,n),name:n},type:tX}),[n,r._formValues]),b=u.default.useCallback(e=>{e&&(f.current={focus:()=>ni(e.focus)&&e.focus(),select:()=>ni(e.select)&&e.select(),setCustomValidity:t=>ni(e.setCustomValidity)&&e.setCustomValidity(t),reportValidity:()=>ni(e.reportValidity)&&e.reportValidity()});let t=nn(r._fields,n);t&&t._f&&e&&(t._f.ref=f.current)},[r._fields,n]),x=u.default.useMemo(()=>({name:n,value:c,..."boolean"==typeof i||h.disabled?{disabled:h.disabled||i}:{},onChange:v,onBlur:y,ref:b}),[n,i,h.disabled,v,y,b,c]);return u.default.useEffect(()=>{let e=r._options.shouldUnregister||o;r.register(n,{...p.current.rules,..."boolean"==typeof p.current.disabled?{disabled:p.current.disabled}:{}});let t=(e,t)=>{let n=nn(r._fields,e);n&&n._f&&(n._f.mount=t)};if(t(n,!0),e){let e=tZ(nn(o?r._defaultValues:r._options.values||r._defaultValues,n,nn(r._options.defaultValues,n,p.current.defaultValue)));nr(r._defaultValues,n,e),t9(nn(r._formValues,n))&&nr(r._formValues,n,e)}if(l||r.register(n),f.current){let e=nn(r._fields,n);e&&e._f&&(e._f.ref=f.current)}return()=>{(l?e&&!r._state.action:e)?r.unregister(n):t(n,!1)}},[n,r,l,o]),u.default.useEffect(()=>{r._setDisabledField({disabled:i,name:n})},[i,n,r]),u.default.useMemo(()=>({field:x,formState:h,fieldState:m}),[x,h,m])}(e));u.default.createContext(null).displayName="HookFormContext";var nf=(e,t,n,i,r)=>t?{...n[e],types:{...n[e]&&n[e].types?n[e].types:{},[i]:r||!0}}:{},ng=e=>Array.isArray(e)?e.filter(Boolean):[],nm=e=>Array.isArray(e)?e:[e],nv=()=>{let e=[];return{get observers(){return e},next:t=>{for(let n of e)n.next&&n.next(t)},subscribe:t=>(e.push(t),{unsubscribe:()=>{e=e.filter(e=>e!==t)}}),unsubscribe:()=>{e=[]}}},ny=e=>t$(e)&&!Object.keys(e).length,nb=e=>{if(!tY)return!1;let t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},nx=e=>nb(e)&&e.isConnected;function nw(e,t){if(nl(t)&&Object.prototype.hasOwnProperty.call(e,t))return delete e[t],e;let n=Array.isArray(t)?t:t7.test(t)?[t]:nt(t),i=1===n.length?e:function(e,t){let n=t.slice(0,-1).length,i=0;for(;i<n;){if(tW(e)){e=void 0;break}e=e[t[i]],i++}return e}(e,n),r=n.length-1,o=n[r];return i&&delete i[o],0!==r&&(t$(i)&&ny(i)||Array.isArray(i)&&function(e){for(let t in e)if(e.hasOwnProperty(t)&&!t9(e[t]))return!1;return!0}(i))&&nw(e,n.slice(0,-1)),e}function nC(e){return Array.isArray(e)||t$(e)&&!(e=>{for(let t in e)if(ni(e[t]))return!0;return!1})(e)}function nS(e,t={}){for(let n in e){let i=e[n];nC(i)?(t[n]=Array.isArray(i)?[]:{},nS(i,t[n])):t9(i)||(t[n]=!0)}return t}function n_(e,t,n){for(let i in n||(n=nS(t)),e){let r=e[i];if(nC(r))t9(t)||nu(n[i])?n[i]=nS(r,Array.isArray(r)?[]:{}):n_(r,tW(t)?{}:t[i],n[i]);else{let e=t[i];n[i]=!nh(r,e)}}return function e(t){if(!1!==t){if(!0===t)return!0;
230if(Array.isArray(t)){let n=t.map(t=>e(t));return n.some(e=>void 0!==e)?n:void 0}if(t$(t)){let n={};for(let i in t){let r=e(t[i]);t9(r)||(n[i]=r)}return Object.keys(n).length?n:void 0}}}(n)||{}}let nk={value:!1,isValid:!1},nM={value:!0,isValid:!0};var nT=e=>{if(Array.isArray(e)){if(e.length>1){let t=e.filter(e=>e&&e.checked&&!e.disabled).map(e=>e.value);return{value:t,isValid:!!t.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!t9(e[0].attributes.value)?t9(e[0].value)||""===e[0].value?nM:{value:e[0].value,isValid:!0}:nM:nk}return nk},nD=(e,{valueAsNumber:t,valueAsDate:n,setValueAs:i})=>t9(e)?e:t?""===e?NaN:e?+e:e:n&&nl(e)?new Date(e):i?i(e):e;let nR={isValid:!1,value:null};var nI=e=>Array.isArray(e)?e.reduce((e,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:e,nR):nR;function nA(e){let t=e.ref;return"file"===t.type?t.files:"radio"===t.type?nI(e.refs).value:"select-multiple"===t.type?[...t.selectedOptions].map(({value:e})=>e):"checkbox"===t.type?nT(e.refs).value:nD(t9(t.value)?e.ref.value:t.value,e)}var nP=e=>t9(e)?e:e instanceof RegExp?e.source:t$(e)?e.value instanceof RegExp?e.value.source:e.value:e,nE=e=>({isOnSubmit:!e||e===t0,isOnBlur:"onBlur"===e,isOnChange:e===tQ,isOnAll:"all"===e,isOnTouch:"onTouched"===e});let nL="AsyncFunction";var nF=e=>{if(!e||!e.validate)return!1;if(ni(e.validate))return e.validate.constructor.name===nL;if(t$(e.validate)){for(let t in e.validate)if(e.validate[t].constructor.name===nL)return!0}return!1},nO=(e,t,n)=>{if(n)return!1;if(t.watchAll||t.watch.has(e))return!0;for(let n of t.watch)if(e.startsWith(n)&&"."===e.charAt(n.length))return!0;return!1};let nN=(e,t,n,i)=>{for(let r of n||Object.keys(e)){let n=nn(e,r);if(n){let{_f:e,...o}=n;if(e){if(e.refs&&e.refs[0]&&t(e.refs[0],r)&&!i)return!0;else if(e.ref&&t(e.ref,e.name)&&!i)return!0;else if(nN(o,t))break}else if(t$(o)&&nN(o,t))break}}};function nB(e,t,n){let i=nn(e,n);if(i||t7.test(n))return{error:i,name:n};let r=n.split(".");for(;r.length;){let i=r.join("."),o=nn(t,i),a=nn(e,i);if(o&&!Array.isArray(o)&&n!==i)break;if(a&&a.type)return{name:i,error:a};if(a&&a.root&&a.root.type)return{name:`${i}.root`,error:a.root};r.pop()}return{name:n}}var nz=(e,t,n)=>{let i=nn(e,n),r=Array.isArray(i)?i:[];return nr(r,t6,t[n]),nr(e,n,r),e};function nj(e,t,n="validate"){if(nl(e)||Array.isArray(e)&&e.every(nl)||"boolean"==typeof e&&!e)return{type:n,message:nl(e)?e:"",ref:t}}var nV=e=>!t$(e)||e instanceof RegExp?{value:e,message:""}:e,nH=async(e,t,n,i,r,o)=>{let{ref:a,refs:s,required:l,maxLength:d,minLength:u,min:c,max:h,pattern:p,validate:f,name:g,valueAsNumber:m,mount:v}=e._f,y=nn(n,g);if(!v||t.has(g))return{};let b=s?s[0]:a,x=e=>{if(r&&b.reportValidity){let t="boolean"==typeof e?"":e||"";s?s.forEach(e=>e.setCustomValidity(t)):b.setCustomValidity(t),b.reportValidity()}},w={},C="radio"===a.type,S="checkbox"===a.type,_=(m||"file"===a.type)&&t9(a.value)&&t9(y)||nb(a)&&""===a.value||""===y||Array.isArray(y)&&!y.length,k=nf.bind(null,g,i,w),M=(e,t,n,i=t1,r=t2)=>{let o=e?t:n;w[g]={type:e?i:r,message:o,ref:a,...k(e?i:r,o)}};if(o?!Array.isArray(y)||!y.length:l&&(!(C||S)&&(_||tW(y))||"boolean"==typeof y&&!y||S&&!nT(s).isValid||C&&!nI(s).isValid)){let{value:e,message:t}=nl(l)?{value:!!l,message:l}:nV(l);if(e&&(w[g]={type:t5,message:t,ref:b,...k(t5,t)},!i))return x(t),w}if(!_&&(!tW(c)||!tW(h))){let e,t,n=nV(h),r=nV(c);if(tW(y)||isNaN(y)){let i=a.valueAsDate||new Date(y),o=e=>new Date(new Date().toDateString()+" "+e),s="time"==a.type,l="week"==a.type;nl(n.value)&&y&&(e=s?o(y)>o(n.value):l?y>n.value:i>new Date(n.value)),nl(r.value)&&y&&(t=s?o(y)<o(r.value):l?y<r.value:i<new Date(r.value))}else{let i=a.valueAsNumber||(y?+y:y);tW(n.value)||(e=i>n.value),tW(r.value)||(t=i<r.value)}if((e||t)&&(M(!!e,n.message,r.message,"max","min"),!i))return x(w[g].message),w}if((d||u)&&!_&&(nl(y)||o&&Array.isArray(y))){let e=nV(d),t=nV(u),n=!tW(e.value)&&y.length>+e.value,r=!tW(t.value)&&y.length<+t.value;if((n||r)&&(M(n,e.message,t.message),!i))return x(w[g].message),w}if(p&&!_&&nl(y)){let{value:e,message:t}=nV(p);if(e instanceof RegExp&&!y.match(e)&&(w[g]={type:t3,message:t,ref:a,...k(t3,t)},!i))return x(t),w}if(f){if(ni(f)){let e=nj(await f(y,n),b);if(e&&(w[g]={...e,...k(t4,e.message)},!i))return x(e.message),w}else if(t$(f)){let e={};for(let t in f){if(!ny(e)&&!i)break;let r=nj(await f[t](y,n),b,t);r&&(e={...r,...k(t,r.message)},x(r.message),i&&(w[g]=e))}if(!ny(e)&&(w[g]={ref:b,...e},!i))return w}}return x(!0),w};let nG={mode:t0,reValidateMode:tQ,shouldFocusError:!0},nW="form",n$={submitCount:0,isDirty:!1,isReady:!1,isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{}};function nU(e={}){let t=u.default.useRef(void 0),n=u.default.useRef(void 0),i=u.default.useRef(e.formControl),[r,o]=u.default.useState(()=>({...tZ(n$),isLoading:ni(e.defaultValues),errors:e.errors||{},disabled:e.disabled||!1,defaultValues:ni(e.defaultValues)?void 0:e.defaultValues}));if(!t.current||e.formControl&&i.current!==e.formControl)if(i.current=e.formControl,e.formControl)t.current={...e.formControl,formState:r},e.defaultValues&&!ni(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{let{formControl:n,...i}=function(e={}){let t,n={...nG,...e},i={...tZ(n$),isLoading:ni(n.defaultValues),errors:n.errors||{},disabled:n.disabled||!1}
230,r={},o=(t$(n.defaultValues)||t$(n.values))&&tZ(n.defaultValues||n.values)||{},a=n.shouldUnregister?{}:tZ(o),s={action:!1,mount:!1,watch:!1,keepIsValid:!1},l={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set,registerName:new Set},d=0,u=0,c=nE(n.mode),h=nE(n.reValidateMode),p={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},f={...p},g={...f},m={array:nv(),state:nv()},v="all"===n.criteriaMode,y=async e=>{if(!s.keepIsValid&&!n.disabled&&(f.isValid||g.isValid||e)){let e;n.resolver?(e=ny((await S()).errors),b()):e=await M({fields:r,onlyCheckValid:!0,eventType:"valid"}),e!==i.isValid&&m.state.next({isValid:e})}},b=(e,t)=>{!n.disabled&&(f.isValidating||f.validatingFields||g.isValidating||g.validatingFields)&&((e||Array.from(l.mount)).forEach(e=>{e&&(t?nr(i.validatingFields,e,t):nw(i.validatingFields,e))}),m.state.next({validatingFields:i.validatingFields,isValidating:!ny(i.validatingFields)}))},x=()=>{i.dirtyFields=n_(o,a)},w=(t,n,d,u)=>{let c=nn(r,t);if(c){if((e=>{let t=t7.test(e)?[e]:nt(e),n=a,i=o;for(let e=0;e<t.length-1;e++){let r=t[e];if(n=tW(n)?n:n[r],i=tW(i)?i:i[r],null===n&&null!==i)return!0}return!1})(t))return;let r=t9(nn(a,t)),h=nn(a,t,t9(d)?nn(o,t):d);t9(h)||u&&u.defaultChecked||n?nr(a,t,n?h:nA(c._f)):R(t,h),s.mount&&!s.action&&(y(),r&&i.isDirty&&(f.isDirty||g.isDirty)&&(T()||(i.isDirty=!1,m.state.next({...i}))),e.shouldUnregister&&r&&!t9(nn(a,t))&&nO(t,l)&&(s.watch=!0))}},C=(e,t,r,s,l)=>{let d=!1,u=!1,c={name:e};if(!n.disabled){if(!r||s){let n=nh(nn(o,e),t);(f.isDirty||g.isDirty)&&(u=i.isDirty,i.isDirty=c.isDirty=!n||T(),d=u!==c.isDirty),u=!!nn(i.dirtyFields,e),n!==i.isDirty?i.dirtyFields=n_(o,a):n?nw(i.dirtyFields,e):nr(i.dirtyFields,e,!0),c.dirtyFields=i.dirtyFields,d=d||(f.dirtyFields||g.dirtyFields)&&!n!==u}if(r){let t=nn(i.touchedFields,e);t||(nr(i.touchedFields,e,r),c.touchedFields=i.touchedFields,d=d||(f.touchedFields||g.touchedFields)&&t!==r)}d&&l&&m.state.next(c)}return d?c:{}},S=async e=>(b(e,!0),await n.resolver(a,n.context,((e,t,n,i)=>{let r={};for(let n of e){let e=nn(t,n);e&&nr(r,n,e._f)}return{criteriaMode:n,names:[...e],fields:r,shouldUseNativeValidation:i}})(e||l.mount,r,n.criteriaMode,n.shouldUseNativeValidation))),_=async e=>{let{errors:t}=await S(e);if(b(e),e){for(let n of e){let e=nn(t,n);e?l.array.has(n)&&t$(e)&&!Object.keys(e).some(e=>!Number.isNaN(Number(e)))?nz(i.errors,{[n]:e},n):nr(i.errors,n,e):nw(i.errors,n)}i.errors={...i.errors}}else i.errors=t;return t},k=async({name:t,eventType:n})=>{if(e.validate){let r=await e.validate({formValues:a,formState:i,name:t,eventType:n});if(t$(r))for(let e in r){let t=r[e];t&&B(`${nW}.${e}`,{message:nl(t.message)?t.message:"",type:t.type||t4})}else nl(r)||!r?B(nW,{message:r||"",type:t4}):N(nW);return r}return!0},M=async({fields:t,onlyCheckValid:r,name:o,eventType:s,context:d={valid:!0,runRootValidation:!1}})=>{if(e.validate&&(d.runRootValidation=!0,!await k({name:o,eventType:s}))&&(d.valid=!1,r))return d.valid;for(let o in t){let u=t[o];if(u){let{_f:t,...c}=u;if(t){let o=l.array.has(t.name),s=u._f&&nF(u._f),c=f.validatingFields||f.isValidating||g.validatingFields||g.isValidating;s&&c&&b([t.name],!0);let h=await nH(u,l.disabled,a,v,n.shouldUseNativeValidation&&!r,o);if(s&&c&&b([t.name]),h[t.name]&&(d.valid=!1,r)||(r||(nn(h,t.name)?o?nz(i.errors,h,t.name):nr(i.errors,t.name,h[t.name]):nw(i.errors,t.name)),e.shouldUseNativeValidation&&h[t.name]))break}ny(c)||await M({context:d,onlyCheckValid:r,fields:c,name:o,eventType:s})}}return d.valid},T=(e,t)=>!n.disabled&&(e&&t&&nr(a,e,t),!nh(s.mount?a:o,o)),D=(e,t,n)=>nd(e,l,{...s.mount?a:t9(t)?o:nl(e)?{[e]:t}:t},n,t),R=(e,t,n={},i=!1,o=!1)=>{let s=nn(r,e),l=t;if(s){let n=s._f;n&&(n.disabled||nr(a,e,nD(t,n)),l=nb(n.ref)&&tW(t)?"":t,"select-multiple"===n.ref.type?[...n.ref.options].forEach(e=>e.selected=l.includes(e.value)):n.refs?"checkbox"===n.ref.type?n.refs.forEach(e=>{e.defaultChecked&&e.disabled||(Array.isArray(l)?e.checked=!!l.find(t=>t===e.value):e.checked=l===e.value||!!l)}):n.refs.forEach(e=>e.checked=e.value===l):"file"===n.ref.type?n.ref.value="":(n.ref.value=l,n.ref.type||o||m.state.next({name:e,values:i?a:tZ(a)})))}(n.shouldDirty||n.shouldTouch)&&C(e,l,n.shouldTouch,n.shouldDirty,!o),n.shouldValidate&&F(e)},I=(e,t,n,i=!1,o=!1)=>{for(let a in t){if(!t.hasOwnProperty(a))return;let s=t[a],d=e+"."+a,u=nn(r,d);(l.array.has(e)||t$(s)||u&&!u._f)&&!tG(s)?I(d,s,n,i,o):R(d,s,n,i,o)}},A=(e,t,n,o,d=!1)=>{let u=nn(r,e),c=l.array.has(e),h=o?t:tZ(t),p=nh(nn(a,e),h);if(p||nr(a,e,h),c)m.array.next({name:e,values:o?a:tZ(a)}),(f.isDirty||f.dirtyFields||g.isDirty||g.dirtyFields)&&n.shouldDirty&&(x(),d||m.state.next({name:e,dirtyFields:i.dirtyFields,isDirty:T(e,h)}));else{let t=Array.isArray(h)&&!h.length||ny(h);!u||u._f||tW(h)||t?R(e,h,n,o,d):I(e,h,n,o,d)}if(!p&&!d){let t=nO(e,l),n=o?a:tZ(a);m.state.next({...t&&i,name:s.mount||t?e:void 0,values:n})}},P=(e,t,n={})=>A(e,t,n,!1),E=async o=>{s.mount=!0;
230let p=o.target,x=p.name,w=!0,_=nn(r,x),T=e=>{w=Number.isNaN(e)||tG(e)&&isNaN(e.getTime())||nh(e,nn(a,x,e))};if(_){var D,R,I,A,P;let s,N,B,z=p.type?nA(_._f):tU(o),j=o.type===tX||"focusout"===o.type,V=!((B=_._f).mount&&(B.required||B.min||B.max||B.maxLength||B.minLength||B.pattern||B.validate))&&!e.validate&&!n.resolver&&!nn(i.errors,x)&&!_._f.deps,H=V||(D=j,R=nn(i.touchedFields,x),I=i.isSubmitted,A=h,!(P=c).isOnAll&&(!I&&P.isOnTouch?!(R||D):(I?A.isOnBlur:P.isOnBlur)?!D:(I?!A.isOnChange:!P.isOnChange)||D)),G=nO(x,l,j);nr(a,x,z),j?p&&p.readOnly||(_._f.onBlur&&_._f.onBlur(o),t&&t(0)):_._f.onChange&&_._f.onChange(o);let W=C(x,z,j),$=!ny(W)||G;if(j||m.state.next({name:x,type:o.type,...u?{values:tZ(a)}:{}}),H)return(!V||!i.isValid)&&(f.isValid||g.isValid)&&("onBlur"===n.mode?j&&y():j||y()),$&&m.state.next({name:x,...G?{}:W});if(!n.resolver&&e.validate&&await k({name:x,eventType:o.type}),!j&&G&&m.state.next({...i}),n.resolver){let{errors:e}=await S([x]);if(b([x]),T(z),!w){ny(W)||m.state.next(W);return}let t=nB(i.errors,r,x),n=nB(e,r,t.name||x);s=n.error,x=n.name,N=ny(e)}else b([x],!0),s=(await nH(_,l.disabled,a,v,n.shouldUseNativeValidation))[x],b([x]),T(z),w&&(s?N=!1:(f.isValid||g.isValid)&&(N=await M({fields:r,onlyCheckValid:!0,name:x,eventType:o.type})));if(w){_._f.deps&&(!Array.isArray(_._f.deps)||_._f.deps.length>0)&&F(_._f.deps);var E=x,L=N,O=s;let e=nn(i.errors,E),r=(f.isValid||g.isValid)&&"boolean"==typeof L&&i.isValid!==L;if(n.delayError&&O){let e;e=()=>{nr(i.errors,E,O),i.errors={...i.errors},m.state.next({errors:i.errors})},(t=t=>{clearTimeout(d),d=setTimeout(e,t)})(n.delayError)}else clearTimeout(d),t=null,O?nr(i.errors,E,O):nw(i.errors,E),i.errors={...i.errors};if((O?!nh(e,O):e)||!ny(W)||r){let e={...W,...r&&"boolean"==typeof L?{isValid:L}:{},errors:i.errors,name:E};i={...i,...e},m.state.next(e)}}}},L=(e,t)=>{if(nn(i.errors,t)&&e.focus)return e.focus(),1},F=async(e,t={})=>{let o,a,s=nm(e);if(n.resolver){let t=await _(t9(e)?e:s);o=ny(t),a=e?!s.some(e=>nn(t,e)):o}else e?((a=(await Promise.all(s.map(async e=>{let t=nn(r,e);return await M({fields:t&&t._f?{[e]:t}:t,eventType:tJ})}))).every(Boolean))||i.isValid)&&y():a=o=await M({fields:r,name:e,eventType:tJ});return m.state.next({...!nl(e)||(f.isValid||g.isValid)&&o!==i.isValid?{}:{name:e},...n.resolver||!e?{isValid:o}:{},errors:i.errors}),t.shouldFocus&&!a&&nN(r,L,e?s:l.mount),a},O=(e,t)=>({invalid:!!nn((t||i).errors,e),isDirty:!!nn((t||i).dirtyFields,e),error:nn((t||i).errors,e),isValidating:!!nn(i.validatingFields,e),isTouched:!!nn((t||i).touchedFields,e)}),N=e=>{let t=e?nm(e):void 0;null==t||t.forEach(e=>nw(i.errors,e)),t?t.forEach(e=>{m.state.next({name:e,errors:i.errors})}):m.state.next({errors:{}})},B=(e,t,n)=>{let o=(nn(r,e,{_f:{}})._f||{}).ref,{ref:a,message:s,type:l,...d}=nn(i.errors,e)||{};nr(i.errors,e,{...d,...t,ref:o}),m.state.next({name:e,errors:i.errors,isValid:!1}),n&&n.shouldFocus&&o&&o.focus&&o.focus()},z=e=>{var t;let n=!!(null==(t=e.formState)?void 0:t.values);n&&u++;let{unsubscribe:r}=m.state.subscribe({next:t=>{let n,r,s;if(n=e.name,r=t.name,s=e.exact,(!n||!r||n===r||nm(n).some(e=>e&&(s?e===r:e.startsWith(r)||r.startsWith(e))))&&((e,t,n,i)=>{n(e);let{name:r,...o}=e,a=Object.keys(o);return!a.length||i&&a.length>=Object.keys(t).length||a.find(e=>t[e]===(!i||"all"))})(t,e.formState||f,q,e.reRenderRoot)){let n={...a};e.callback({values:n,...i,...t,defaultValues:o})}}});if(!n)return r;let s=!1;return()=>{s||(s=!0,u--,r())}},j=(e,t={})=>{for(let s of e?nm(e):l.mount)l.mount.delete(s),l.array.delete(s),t.keepValue||(nw(r,s),nw(a,s)),t.keepError||nw(i.errors,s),t.keepDirty||nw(i.dirtyFields,s),t.keepTouched||nw(i.touchedFields,s),t.keepIsValidating||nw(i.validatingFields,s),n.shouldUnregister||t.keepDefaultValue||nw(o,s);m.state.next({values:tZ(a)}),m.state.next({...i,...!t.keepDirty?{}:{isDirty:T()}}),t.keepIsValid||y()},V=({disabled:e,name:t})=>{if("boolean"==typeof e&&s.mount||e||l.disabled.has(t)){let n=l.disabled.has(t);e?l.disabled.add(t):l.disabled.delete(t),!!e!==n&&s.mount&&!s.action&&y()}},H=(e,t={})=>{let i=nn(r,e),a="boolean"==typeof t.disabled||"boolean"==typeof n.disabled,d=!l.registerName.has(e)&&i&&i._f&&!i._f.mount;return(nr(r,e,{...i||{},_f:{...i&&i._f?i._f:{ref:{name:e}},name:e,mount:!0,...t}}),l.mount.add(e),i&&!d)?V({disabled:"boolean"==typeof t.disabled?t.disabled:n.disabled,name:e}):w(e,!0,t.value),{...a?{disabled:t.disabled||n.disabled}:{},...n.progressive?{required:!!t.required,min:nP(t.min),max:nP(t.max),minLength:nP(t.minLength),maxLength:nP(t.maxLength),pattern:nP(t.pattern)}:{}
230,name:e,onChange:E,onBlur:E,ref:a=>{if(a){let n;l.registerName.add(e),H(e,t),l.registerName.delete(e),i=nn(r,e);let s=t9(a.value)&&a.querySelectorAll&&a.querySelectorAll("input,select,textarea")[0]||a,d="radio"===(n=s).type||"checkbox"===n.type,u=i._f.refs||[];(d?u.find(e=>e===s):s===i._f.ref)||(nr(r,e,{_f:{...i._f,...d?{refs:[...u.filter(nx),s,...Array.isArray(nn(o,e))?[{}]:[]],ref:{type:s.type,name:e}}:{ref:s}}}),w(e,!1,void 0,s))}else(i=nn(r,e,{}))._f&&(i._f.mount=!1),(n.shouldUnregister||t.shouldUnregister)&&!(tq(l.array,e)&&s.action)&&l.unMount.add(e)}}},G=()=>n.shouldFocusError&&!n.shouldUseNativeValidation&&nN(r,L,l.mount),W=(e,t)=>async o=>{let s;o&&(o.preventDefault&&o.preventDefault(),o.persist&&o.persist());let d=tZ(a);if(m.state.next({isSubmitting:!0}),n.resolver){let{errors:e,values:t}=await S();b(),i.errors=e,d=tZ(t)}else await M({fields:r,eventType:"submit"});if(l.disabled.size)for(let e of l.disabled)nw(d,e);if(nw(i.errors,t6),ny(i.errors)){m.state.next({errors:{}});try{await e(d,o)}catch(e){s=e}}else t&&await t({...i.errors},o),G(),setTimeout(G);if(m.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:ny(i.errors)&&!s,submitCount:i.submitCount+1,errors:i.errors}),s)throw s},$=(e,t={})=>{let d=e?tZ(e):o,u=tZ(d),c=ny(e);if(t.keepDefaultValues||(o=d),!t.keepValues){if(t.keepDirtyValues)for(let e of Array.from(new Set([...l.mount,...Object.keys(n_(o,a))]))){let t=nn(i.dirtyFields,e),n=nn(a,e),r=nn(u,e);t&&!t9(n)?nr(u,e,n):t||t9(r)||P(e,r)}else{if(tY&&t9(e))for(let e of l.mount){let t=nn(r,e);if(t&&t._f){let e=Array.isArray(t._f.refs)?t._f.refs[0]:t._f.ref;if(nb(e)){let t=e.closest("form");if(t){t.reset();break}}}}if(t.keepFieldsRef)for(let e of l.mount)P(e,nn(u,e));else r={}}if(n.shouldUnregister){if(a=t.keepDefaultValues?tZ(o):{},t.keepFieldsRef)for(let e of l.mount)nr(a,e,nn(u,e))}else a=tZ(u);m.array.next({values:{...u}}),m.state.next({values:{...u}})}l={mount:t.keepDirtyValues?l.mount:new Set,unMount:new Set,array:new Set,registerName:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},s.mount=!f.isValid||!!t.keepIsValid||!!t.keepDirtyValues||!n.shouldUnregister&&!ny(u),s.watch=!!n.shouldUnregister,s.keepIsValid=!!t.keepIsValid,s.action=!1,t.keepErrors||(i.errors={}),m.state.next({submitCount:t.keepSubmitCount?i.submitCount:0,isDirty:!c&&(t.keepDirty?i.isDirty:t.keepValues?T():!!(t.keepDefaultValues&&!nh(e,o))),isSubmitted:!!t.keepIsSubmitted&&i.isSubmitted,dirtyFields:c?{}:t.keepDirtyValues?t.keepDefaultValues&&a?n_(o,a):i.dirtyFields:t.keepDefaultValues&&e?n_(o,e):t.keepDirty?i.dirtyFields:{},touchedFields:t.keepTouched?i.touchedFields:{},errors:t.keepErrors?i.errors:{},isSubmitSuccessful:!!t.keepIsSubmitSuccessful&&i.isSubmitSuccessful,isSubmitting:!1,defaultValues:o})},U=(e,t)=>$(ni(e)?e(a):e,{...n.resetOptions,...t}),q=e=>{i={...i,...e}},K={control:{register:H,unregister:j,getFieldState:O,handleSubmit:W,setError:B,_subscribe:z,_runSchema:S,_updateIsValidating:b,_focusError:G,_getWatch:D,_getDirty:T,_setValid:y,_setFieldArray:(e,t=[],o,l,d=!0,u=!0)=>{if(l&&o&&!n.disabled){if(s.action=!0,u&&Array.isArray(nn(r,e))){let t=
230o(nn(r,e),l.argA,l.argB);d&&nr(r,e,t)}if(u&&Array.isArray(nn(i.errors,e))){let t,n=o(nn(i.errors,e),l.argA,l.argB);d&&nr(i.errors,e,n),ng(nn(t=i.errors,e)).length||nw(t,e)}if((f.touchedFields||g.touchedFields)&&u&&Array.isArray(nn(i.touchedFields,e))){let t=o(nn(i.touchedFields,e),l.argA,l.argB);d&&nr(i.touchedFields,e,t)}(f.dirtyFields||g.dirtyFields)&&x(),m.state.next({name:e,isDirty:T(e,t),dirtyFields:i.dirtyFields,errors:i.errors,isValid:i.isValid})}else nr(a,e,t)},_setDisabledField:V,_setErrors:e=>{i.errors=e,m.state.next({errors:i.errors,isValid:!1})},_getFieldArray:e=>ng(nn(s.mount?a:o,e,n.shouldUnregister?nn(o,e,[]):[])),_reset:$,_resetDefaultValues:()=>ni(n.defaultValues)&&n.defaultValues().then(e=>{U(e,n.resetOptions),m.state.next({isLoading:!1})}),_removeUnmounted:()=>{for(let e of l.unMount){let t=nn(r,e);t&&(t._f.refs?t._f.refs.every(e=>!nx(e)):!nx(t._f.ref))&&j(e)}l.unMount=new Set},_disableForm:e=>{"boolean"==typeof e&&(m.state.next({disabled:e}),nN(r,(t,n)=>{let i=nn(r,n);i&&(t.disabled=i._f.disabled||e,Array.isArray(i._f.refs)&&i._f.refs.forEach(t=>{t.disabled=i._f.disabled||e}))},0,!1))},_subjects:m,_proxyFormState:f,get _fields(){return r},get _formValues(){return a},get _state(){return s},set _state(value){s=value},get _defaultValues(){return o},get _names(){return l},set _names(value){l=value},get _formState(){return i},get _options(){return n},set _options(value){c=nE((n={...n,...value}).mode),h=nE(n.reValidateMode)}},subscribe:e=>(s.mount=!0,g={...g,...e.formState},z({...e,formState:{...p,...e.formState}})),trigger:F,register:H,handleSubmit:W,watch:(e,t)=>{if(ni(e)){u++;let{unsubscribe:n}=m.state.subscribe({next:n=>"values"in n&&e(n.values||D(void 0,t),n)}),i=!1;return{unsubscribe:()=>{i||(i=!0,u--,n())}}}return D(e,t,!0)},setValue:P,setValues:(e,t={})=>{let n=ni(e)?e(a):e;if(!nh(a,n)){for(let e of(a={...a,...n},l.mount))A(e,nn(n,e),t,!0,!0);m.state.next({...i,name:void 0,type:void 0,...u?{values:a}:{}}),t.shouldValidate&&y()}},getValues:(e,t)=>{let n={...s.mount?a:o};return t&&(n=function e(t,n){let i={};for(let r in t)if(t.hasOwnProperty(r)){let o=t[r],a=n[r];if(o&&t$(o)&&a){let t=e(o,a);t$(t)&&(i[r]=t)}else t[r]&&(i[r]=a)}return i}(t.dirtyFields?i.dirtyFields:i.touchedFields,n)),t9(e)?n:nl(e)?nn(n,e):e.map(e=>nn(n,e))},reset:U,resetField:(e,t={})=>{nn(r,e)&&(t9(t.defaultValue)?P(e,tZ(nn(o,e))):(P(e,t.defaultValue),nr(o,e,tZ(t.defaultValue))),t.keepTouched||nw(i.touchedFields,e),t.keepDirty||(nw(i.dirtyFields,e),i.isDirty=t.defaultValue?T(e,tZ(nn(o,e))):T()),!t.keepError&&(nw(i.errors,e),f.isValid&&y()),m.state.next({...i}))},resetDefaultValues:(e,t={})=>{if(o=tZ(e),!t.keepDirty){let e=n_(o,a);i.dirtyFields=e,i.isDirty=!ny(e)}t.keepIsValid||y(),m.state.next({...i,defaultValues:o})},clearErrors:N,unregister:j,setError:B,setFocus:(e,t={})=>{let n=nn(r,e),i=n&&n._f;if(i){let e=i.refs?i.refs[0]:i.ref;e.focus&&setTimeout(()=>{e.focus(),t.shouldSelect&&ni(e.select)&&e.select()})}},getFieldState:O};return{...K,formControl:K}}(e);t.current={...i,formState:r}}let a=t.current.control;return a._options=e,ns(()=>{let e=a._subscribe({formState:a._proxyFormState,callback:()=>o({...a._formState,defaultValues:a._defaultValues}),reRenderRoot:!0});return o(e=>({...e,isReady:!0})),a._formState.isReady=!0,e},[a]),u.default.useEffect(()=>a._disableForm(e.disabled),[a,e.disabled]),u.default.useEffect(()=>{e.mode&&(a._options.mode=e.mode),e.reValidateMode&&(a._options.reValidateMode=e.reValidateMode)},[a,e.mode,e.reValidateMode]),u.default.useEffect(()=>{e.errors&&(a._setErrors(e.errors),a._focusError())},[a,e.errors]),u.default.useEffect(()=>{e.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,e.shouldUnregister]),u.default.useEffect(()=>{if(a._proxyFormState.isDirty){let e=a._getDirty();e!==r.isDirty&&a._subjects.state.next({isDirty:e})}},[a,r.isDirty]),u.default.useEffect(()=>{var t;e.values&&!nh(e.values,n.current)?(a._reset(e.values,{keepFieldsRef:!0,...a._options.resetOptions}),(null==(t=a._options.resetOptions)?void 0:t.keepIsValid)||a._setValid(),n.current=e.values,o(e=>({...e}))):a._resetDefaultValues()},[a,e.values]),u.default.useEffect(()=>{a._state.mount||(a._setValid(),a._state.mount=!0),a._state.watch&&(a._state.watch=!1,a._subjects.state.next({...a._formState})),a._removeUnmounted()}),t.current.formState=u.default.useMemo(()=>na(r,a),[a,r]),t.current}e.s(["Controller",()=>np,"useForm",()=>nU],46471);var nq=e.i(69316);let nK=({width:e=100,hide:t,children:n})=>{let i={"--input-width":`${e}%`};return(0,l.jsx)("div",{className:`${nq.default.width} ${t?nq.default.hidden:""}`,style:i,children:n})};e.s(["Width",0,nK],42993);var nY=e.i(44733),nZ=e.i(12112),nX=e.i(1483);function nJ(e,t){return"boolean"==typeof e?e:t.autoContrast}e.s(["getAutoContrastValue",()=>nJ],59678);var nQ=e.i(90323),n0=e.i(44969),n1={root:"m_5f75b09e",body:"m_5f6e695e",labelWrapper:"m_d3ea56bb",label:"m_8ee546b8",description:"m_328f68c0",error:"m_8e8a99cc"};let n2=(0,u.forwardRef)(({__staticSelector:e,__stylesApiProps:t,className:n,classNames:i,styles:r,unstyled:o,children:a,label:s,description:d,id:u,disabled:c,error:h,size:p,labelPosition:g="left",bodyElement:m="div",labelElement:v="label",variant:b,style:x,vars:w,mod:S,attributes:_,...k},M)=>{let T=(0,y.useStyles)({name:e,props:t,className:n,style:x,classes:n1,classNames:i,styles:r,unstyled:o,attributes:_});return(0,l.jsx)(C.Box,{...T("root"),ref:M,__vars:{"--label-fz":(0,f.getFontSize)(p),"--label-lh":(0,f.getSize)(p,"label-lh")},mod:[{"label-position":g},S],variant:b,size:p,...k,children:(0,l.jsxs)(C.Box,{component:m,htmlFor:"label"===m?u:void 0,...T("body"),children:[a,(0,l.jsxs)("div",{...T("labelWrapper"),"data-disabled":c||void 0,children:[s&&(0,l.jsx)(C.Box,{component:v,htmlFor:"label"===v?u:void 0,...T("label"),"data-disabled":c||void 0,children:s}),d&&(0,l.jsx)(n0.Input.Description,{size:p,__inheritStyles:!1,...T("description"),children:d}),h&&"boolean"!=typeof h&&(0,l.jsx)(n0.Input.Error,{size:p,__inheritStyles:!1,...T("error"),children:h})]})]})})});n2.displayName="@mantine/core/InlineInput",e.s(["InlineInput",()=>n2,"InlineInputClasses",()=>n1],76554);var n3={root:"m_bf2d988c",inner:"m_26062bec",input:"m_26063560",icon:"m_bf295423","
230input--outline":"m_215c4542"},n5=e.i(99850);let n4=(0,u.createContext)(null),n6=n4.Provider,n8=()=>(0,u.useContext)(n4),[n7,n9]=(0,tb.createOptionalContext)();var ie={card:"m_26775b0a"};let it={withBorder:!0},ii=(0,p.createVarsResolver)((e,{radius:t})=>({card:{"--card-radius":(0,f.getRadius)(t)}})),ir=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("CheckboxCard",it,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,checked:u,mod:c,withBorder:h,value:p,onClick:f,defaultChecked:g,onChange:m,attributes:b,...x}=n,C=(0,y.useStyles)({name:"CheckboxCard",classes:ie,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:b,vars:d,varsResolver:ii,rootSelector:"card"}),S=n8(),_="boolean"==typeof u?u:S?S.value.includes(p||""):void 0,[k,M]=(0,n5.useUncontrolled)({value:_,defaultValue:g,finalValue:!1,onChange:m});return(0,l.jsx)(n7,{value:{checked:k},children:(0,l.jsx)(w.UnstyledButton,{ref:t,mod:[{"with-border":h,checked:k},c],...C("card"),...x,role:"checkbox","aria-checked":k,onClick:e=>{f?.(e),S?.onChange(p||""),M(!k)}})})});ir.displayName="@mantine/core/CheckboxCard",ir.classes=ie;var io=e.i(60062);function ia({children:e,role:t}){let n=(0,io.useInputWrapperContext)();return n?(0,l.jsx)("div",{role:t,"aria-labelledby":n.labelId,"aria-describedby":n.describedBy,children:e}):(0,l.jsx)(l.Fragment,{children:e})}e.s(["InputsGroupFieldset",()=>ia],60436);let is=(0,m.factory)((e,t)=>{let{value:n,defaultValue:i,onChange:r,size:o,wrapperProps:a,children:s,readOnly:d,disabled:u,...c}=(0,v.useProps)("CheckboxGroup",null,e),[h,p]=(0,n5.useUncontrolled)({value:n,defaultValue:i,finalValue:[],onChange:r});return(0,l.jsx)(n6,{value:{value:h,onChange:e=>{let t="string"==typeof e?e:e.currentTarget.value;d||p(h.includes(t)?h.filter(e=>e!==t):[...h,t])},size:o,disabled:u},children:(0,l.jsx)(n0.Input.Wrapper,{size:o,ref:t,...a,...c,labelElement:"div",__staticSelector:"CheckboxGroup",children:(0,l.jsx)(ia,{role:"group",children:s})})})});is.classes=n0.Input.Wrapper.classes,is.displayName="@mantine/core/CheckboxGroup";var il=e.i(88146),id={indicator:"m_5e5256ee",icon:"m_1b1c543a","indicator--outline":"m_76e20374"};let iu={icon:il.CheckboxIcon,variant:"filled"},ic=(0,p.createVarsResolver)((e,{radius:t,color:n,size:i,iconColor:r,variant:o,autoContrast:a})=>{let s=(0,nY.parseThemeColor)({color:n||e.primaryColor,theme:e}),l=s.isThemeColor&&void 0===s.shade?`var(--mantine-color-${s.color}-outline)`:s.color;return{indicator:{"--checkbox-size":(0,f.getSize)(i,"checkbox-size"),"--checkbox-radius":void 0===t?void 0:(0,f.getRadius)(t),"--checkbox-color":"outline"===o?l:(0,nZ.getThemeColor)(n,e),"--checkbox-icon-color":r?(0,nZ.getThemeColor)(r,e):nJ(a,e)?(0,nX.getContrastColor)({color:n,theme:e,autoContrast:a}):void 0}}}),ih=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("CheckboxIndicator",iu,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,icon:u,indeterminate:c,radius:h,color:p,iconColor:f,autoContrast:g,checked:m,mod:b,variant:x,disabled:w,attributes:S,..._}=n,k=(0,y.useStyles)({name:"CheckboxIndicator",classes:id,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:S,vars:d,varsResolver:ic,rootSelector:"indicator"}),M=n9(),T="boolean"==typeof m||"boolean"==typeof c?m||c:M?.checked||!1;return(0,l.jsx)(C.Box,{ref:t,...k("indicator",{variant:x}),variant:x,mod:[{checked:T,disabled:w},b],..._,children:(0,l.jsx)(u,{indeterminate:c,...k("icon")})})});ih.displayName="@mantine/core/CheckboxIndicator",ih.classes=id;let ip={labelPosition:"right",icon:il.CheckboxIcon,variant:"filled"},ig=(0,p.createVarsResolver)((e,{radius:t,color:n,size:i,iconColor:r,variant:o,autoContrast:a})=>{let s=(0,nY.parseThemeColor)({color:n||e.primaryColor,theme:e}),l=s.isThemeColor&&void 0===s.shade?`var(--mantine-color-${s.color}-outline)`:s.color;return{root:{"--checkbox-size":(0,f.getSize)(i,"checkbox-size"),"--checkbox-radius":void 0===t?void 0:(0,f.getRadius)(t),"--checkbox-color":"outline"===o?l:(0,nZ.getThemeColor)(n,e),"--checkbox-icon-color":r?(0,nZ.getThemeColor)(r,e):nJ(a,e)?(0,nX.getContrastColor)({color:n,theme:e,autoContrast:a}):void 0}}}),im=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("Checkbox",ip,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,color:c,label:h,id:p,size:f,radius:g,wrapperProps:m,checked:b,labelPosition:x,description:w,error:S,disabled:_,variant:k,indeterminate:M,icon:T,rootRef:D,iconColor:R,onChange:I,autoContrast:A,mod:P,attributes:E,...L}=n,F=n8(),O=f||F?.size,N=(0,y.useStyles)({name:"Checkbox",props:n,classes:n3,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:E,vars:d,varsResolver:ig}),{styleProps:B,rest:z}=(0,nQ.extractStyleProps)(L),j=(0,tu.useId)(p),V={checked:F?.value.includes(z.value)??b,onChange:e=>
230{F?.onChange(e),I?.(e)},disabled:F?.disabled??_},H=(0,u.useRef)(null),G=t||H;return(0,u.useEffect)(()=>{G&&"current"in G&&G.current&&(G.current.indeterminate=M||!1,M?G.current.setAttribute("data-indeterminate","true"):G.current.removeAttribute("data-indeterminate"))},[M,G]),(0,l.jsx)(n2,{...N("root"),__staticSelector:"Checkbox",__stylesApiProps:n,id:j,size:O,labelPosition:x,label:h,description:w,error:S,disabled:V.disabled,classNames:i,styles:a,unstyled:s,"data-checked":V.checked||b||void 0,variant:k,ref:D,mod:P,inert:z.inert,...B,...m,children:(0,l.jsxs)(C.Box,{...N("inner"),mod:{"data-label-position":x},children:[(0,l.jsx)(C.Box,{component:"input",id:j,ref:G,mod:{error:!!S},...N("input",{focusable:!0,variant:k}),...z,...V,inert:z.inert,type:"checkbox"}),(0,l.jsx)(T,{indeterminate:M,...N("icon")})]})})});im.classes={...n3,...n1},im.displayName="@mantine/core/Checkbox",im.Group=is,im.Indicator=ih,im.Card=ir;var iv=e.i(22374),iy=e.i(12824),ib=e.i(89710),ix=e.i(33217),iw=e.i(60018),iC=e.i(32357);let iS={duration:100,transition:"fade"};function i_(e,t){return{...iS,...t,...e}}var ik={tooltip:"m_1b3c8819",arrow:"m_f898399f"};function iM(e,t){return Array.isArray(e)?[...e].reduce((e,n)=>({...e,...iM(n,t)}),{}):"function"==typeof e?e(t):null==e?{}:e}e.s(["getStyleObject",()=>iM],44249);var iT=e.i(52897),iD=e.i(25526),iR=e.i(2886);let iI={refProp:"ref",withinPortal:!0,offset:10,position:"right",zIndex:(0,ea.getDefaultZIndex)("popover")},iA=(0,p.createVarsResolver)((e,{radius:t,color:n})=>({tooltip:{"--tooltip-radius":void 0===t?void 0:(0,f.getRadius)(t),"--tooltip-bg":n?(0,nZ.getThemeColor)(n,e):void 0,"--tooltip-color":n?"var(--mantine-color-white)":void 0}})),iP=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("TooltipFloating",iI,e),{children:i,refProp:r,withinPortal:o,style:a,className:s,classNames:d,styles:c,unstyled:h,radius:p,color:f,label:g,offset:m,position:b,multiline:x,zIndex:w,disabled:S,defaultOpened:_,variant:k,vars:M,portalProps:T,attributes:D,...R}=n,I=(0,E.useMantineTheme)(),A=(0,y.useStyles)({name:"TooltipFloating",props:n,classes:ik,className:s,style:a,classNames:d,styles:c,unstyled:h,attributes:D,rootSelector:"tooltip",vars:M,varsResolver:iA}),{handleMouseMove:P,x:L,y:F,opened:O,boundaryRef:N,floating:B,setOpened:z}=function({offset:e,position:t,defaultOpened:n}){let[i,r]=(0,u.useState)(n),o=(0,u.useRef)(null),{x:a,y:s,elements:l,refs:d,update:c,placement:h}=(0,iT.useFloating)({placement:t,middleware:[(0,iD.shift)({crossAxis:!0,padding:5,rootBoundary:"document"})]}),p=h.includes("right")?e:t.includes("left")?-1*e:0,f=h.includes("bottom")?e:t.includes("top")?-1*e:0,g=(0,u.useCallback)(({clientX:e,clientY:t})=>{d.setPositionReference({getBoundingClientRect:()=>({width:0,height:0,x:e,y:t,left:e+p,top:t+f,right:e,bottom:t})})},[l.reference]);return(0,u.useEffect)(()=>{if(d.floating.current){let e=o.current;e.addEventListener("mousemove",g);let t=(0,iR.getOverflowAncestors)(d.floating.current);return t.forEach(e=>{e.addEventListener("scroll",c)}),()=>{e.removeEventListener("mousemove",g),t.forEach(e=>{e.removeEventListener("scroll",c)})}}},[l.reference,d.floating.current,c,g,i]),{handleMouseMove:g,x:a,y:s,opened:i,setOpened:r,boundaryRef:o,floating:d.setFloating}}({offset:m,position:b,defaultOpened:_}),j=(0,ix.getSingleElementChild)(i);if(!j)throw Error("[@mantine/core] Tooltip.Floating component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported");let V=(0,iy.useMergedRef)(N,(0,ib.getRefProp)(j),t),H=j.props;return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(td.OptionalPortal,{...T,withinPortal:o,children:(0,l.jsx)(C.Box,{...R,...A("tooltip",{style:{...iM(a,I),zIndex:w,display:!S&&O?"block":"none",top:(F&&Math.round(F))??"",left:(L&&Math.round(L))??""}}),variant:k,ref:B,mod:{multiline:x},children:g})}),(0,u.cloneElement)(j,{...H,[r]:V,onMouseEnter:e=>{H.onMouseEnter?.(e),P(e),z(!0)},onMouseLeave:e=>{H.onMouseLeave?.(e),z(!1)}})]})});iP.classes=ik,iP.displayName="@mantine/core/TooltipFloating";let iE=(0,u.createContext)(!1),iL=iE.Provider,iF={openDelay:0,closeDelay:0};function iO(e){let{openDelay:t,closeDelay:n,children:i}=(0,v.useProps)("TooltipGroup",iF,e);return(0,l.jsx)(iL,{value:!0,children:(0,l.jsx)(iT.FloatingDelayGroup,{delay:{open:t,close:n},children:i})})}iO.displayName="@mantine/core/TooltipGroup",iO.extend=e=>e;var iN=e.i(95539),iB=e.i(79352);let iz={position:"top",refProp:"ref",withinPortal:!0,arrowSize:4,arrowOffset:5,arrowRadius:0,arrowPosition:"side",offset:5,transitionProps:{duration:100,transition:"fade"},events:{hover:!0,focus:!1,touch:!1},zIndex:(0,ea.getDefaultZIndex)("popover"),positionDependencies:[],middlewares:{flip:!0,shift:!0,inline:!1}},ij=(0,p.createVarsResolver)((e,{radius:t,color:n,variant:i,autoContrast:r})=>{let o=e.variantColorResolver({theme:e,color:n||e.primaryColor,autoContrast:r,variant:i||"filled"});return{tooltip:{"--tooltip-radius":void 0===t?void 0:(0,f.getRadius)(t),"--tooltip-bg":n?o.background:void 0,"--tooltip-color":n?o.color:void 0}}}),iV=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("Tooltip",iz,e),{children:i,position:r,refProp:o,label:a,openDelay:s,closeDelay:d,onPositionChange:c,opened:h,defaultOpened:p,withinPortal:f,radius:g,color:m,classNames:b,styles:w,unstyled:S,style:_,className:k,withArrow:M,arrowSize:T,arrowOffset:D,arrowRadius:R,arrowPosition:I,offset:A,transitionProps:P,multiline:E,events:L,zIndex:F,disabled:O,positionDependencies:N,onClick:B,onMouseEnter:z,onMouseLeave:j,inline:V,variant:H,keepMounted:G,vars:W,portalProps:$,mod:U,floatingStrategy:q,middlewares:K,autoContrast:Y,attributes:Z,target:X,...J}=(0,v.useProps)("Tooltip",iz,n),{dir:Q}=(0,x.useDirection)(),ee=(0,u.useRef)(null),et=function(e){let t,n,[i,r]=(0,u.useState)(e.defaultOpened),o="boolean"==typeof e.o
230pened?e.opened:i,a=(0,u.useContext)(iE),s=(0,tu.useId)(),l=(0,u.useCallback)(e=>{r(e),e&&b(s)},[s]),{x:d,y:c,context:h,refs:p,placement:f,middlewareData:{arrow:{x:g,y:m}={}}}=(0,iT.useFloating)({strategy:e.strategy,placement:e.position,open:o,onOpenChange:l,middleware:(t=function(e){if(void 0===e)return{shift:!0,flip:!0};let t={...e};return void 0===e.shift&&(t.shift=!0),void 0===e.flip&&(t.flip=!0),t}(e.middlewares),n=[(0,iD.offset)(e.offset)],t.shift&&n.push((0,iD.shift)("boolean"==typeof t.shift?{padding:8}:{padding:8,...t.shift})),t.flip&&n.push("boolean"==typeof t.flip?(0,iD.flip)():(0,iD.flip)(t.flip)),n.push((0,iD.arrow)({element:e.arrowRef,padding:e.arrowOffset})),t.inline?n.push("boolean"==typeof t.inline?(0,iD.inline)():(0,iD.inline)(t.inline)):e.inline&&n.push((0,iD.inline)()),n),whileElementsMounted:iN.autoUpdate}),{delay:v,currentId:y,setCurrentId:b}=(0,iT.useDelayGroup)(h,{id:s}),{getReferenceProps:x,getFloatingProps:w}=(0,iT.useInteractions)([(0,iT.useHover)(h,{enabled:e.events?.hover,delay:a?v:{open:e.openDelay,close:e.closeDelay},mouseOnly:!e.events?.touch}),(0,iT.useFocus)(h,{enabled:e.events?.focus,visibleOnly:!0}),(0,iT.useRole)(h,{role:"tooltip"}),(0,iT.useDismiss)(h,{enabled:void 0===e.opened})]);(0,iB.useDidUpdate)(()=>{e.onPositionChange?.(f)},[f]);let C=o&&y&&y!==s;return{x:d,y:c,arrowX:g,arrowY:m,reference:p.setReference,floating:p.setFloating,getFloatingProps:w,getReferenceProps:x,isGroupPhase:C,opened:o,placement:f}}({position:(0,iC.getFloatingPosition)(Q,r),closeDelay:d,openDelay:s,onPositionChange:c,opened:h,defaultOpened:p,events:L,arrowRef:ee,arrowOffset:D,offset:"number"==typeof A?A+(M?T/2:0):A,positionDependencies:[...N,X??i],inline:V,strategy:q,middlewares:K});(0,u.useEffect)(()=>{let e=X instanceof HTMLElement?X:"string"==typeof X?document.querySelector(X):X?.current||null;e&&et.reference(e)},[X,et]);let en=(0,y.useStyles)({name:"Tooltip",props:n,classes:ik,className:k,style:_,classNames:b,styles:w,unstyled:S,attributes:Z,rootSelector:"tooltip",vars:W,varsResolver:ij}),ei=(0,ix.getSingleElementChild)(i);if(!X&&!ei)throw Error("[@mantine/core] Tooltip component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported");if(X){let e=i_(P,{duration:100,transition:"fade"});return(0,l.jsx)(l.Fragment,{children:(0,l.jsx)(td.OptionalPortal,{...$,withinPortal:f,children:(0,l.jsx)(eb.Transition,{...e,keepMounted:G,mounted:!O&&!!et.opened,duration:et.isGroupPhase?10:e.duration,children:e=>(0,l.jsxs)(C.Box,{...J,"data-fixed":"fixed"===q||void 0,variant:H,mod:[{multiline:E},U],...et.getFloatingProps({ref:et.floating,className:en("tooltip").className,style:{...en("tooltip").style,...e,zIndex:F,top:et.y??0,left:et.x??0}}),children:[a,(0,l.jsx)(iw.FloatingArrow,{ref:ee,arrowX:et.arrowX,arrowY:et.arrowY,visible:M,position:et.placement,arrowSize:T,arrowOffset:D,arrowRadius:R,arrowPosition:I,...en("arrow")})]})})})})}let er=ei.props,eo=(0,iy.useMergedRef)(et.reference,(0,ib.getRefProp)(ei),t),ea=i_(P,{duration:100,transition:"fade"});return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(td.OptionalPortal,{...$,withinPortal:f,children:(0,l.jsx)(eb.Transition,{...ea,keepMounted:G,mounted:!O&&!!et.opened,duration:et.isGroupPhase?10:ea.duration,children:e=>(0,l.jsxs)(C.Box,{...J,"data-fixed":"fixed"===q||void 0,variant:H,mod:[{multiline:E},U],...et.getFloatingProps({ref:et.floating,className:en("tooltip").className,style:{...en("tooltip").style,...e,zIndex:F,top:et.y??0,left:et.x??0}}),children:[a,(0,l.jsx)(iw.FloatingArrow,{ref:ee,arrowX:et.arrowX,arrowY:et.arrowY,visible:M,position:et.placement,arrowSize:T,arrowOffset:D,arrowRadius:R,arrowPosition:I,...en("arrow")})]})})}),(0,u.cloneElement)(ei,et.getReferenceProps({onClick:B,onMouseEnter:z,onMouseLeave:j,onMouseMove:n.onMouseMove,onPointerDown:n.onPointerDown,onPointerEnter:n.onPointerEnter,...er,className:(0,es.default)(k,er.className),[o]:eo}))]})});iV.classes=ik,iV.displayName="@mantine/core/Tooltip",iV.Floating=iP,iV.Group=iO,e.s(["Tooltip",()=>iV],93297);var iH=e.i(10322);let iG=({tooltip:e})=>e?(0,l.jsx)(iV,{label:e,withArrow:!0,children:(0,l.jsx)("span",{className:iH.default.icon,children:"â"})}):null;e.s(["FieldTooltip",0,iG],86824);var iW=e.i(79908);e.s(["Checkbox",0,({name:e,label:t,title:n,width:i,required:r,errors:o,control:a,getValues:s,setValue:d,checkboxDefaultValue:c,tooltip:h})=>{let{t:p}=(0,iW.useTranslations)();return u.default.useEffect(()=>{c&&!s(e)&&d(e,c)},[e,c,d,s]),(0,l.jsxs)(nK,{width:i,children:[n&&(0,l.jsxs)("label",{className:iv.default.label,htmlFor:e,children:[n,r&&(0,l.jsx)("span",{className:iv.default.asterisk,children:" *"}),(0,l.jsx)(iG,{tooltip:h})]}),(0,l.jsx)(np,{control:a,rules:{required:r}
230,name:e,defaultValue:"",render:({field:{onChange:n,value:i}})=>(0,l.jsx)(im,{checked:i,size:"md",onChange:()=>{n(!i)},label:t,error:r&&o[e]&&p("fieldRequired")})})]})}],56370);var i$=e.i(21381),iU=e.i(1075),iq=e.i(14845),iK=e.i(48789);function iY(e){return null==e||""===e?e:(0,i$.default)(e).format("YYYY-MM-DD")}function iZ(e){return null==e||""===e?e:(0,i$.default)(e).format("YYYY-MM-DD HH:mm:ss")}e.s(["toDateString",()=>iY,"toDateTimeString",()=>iZ],565);let iX=e=>"range"===e?[null,null]:"multiple"===e?[]:null,iJ=(e,t)=>{let n=t?iZ:iY;return Array.isArray(e)?e.map(n):n(e)};function iQ({type:e,value:t,defaultValue:n,onChange:i,withTime:r=!1}){let o=(0,u.useRef)(e),[a,s,l]=(0,n5.useUncontrolled)({value:iJ(t,r),defaultValue:iJ(n,r),finalValue:iX(e),onChange:i}),d=a;return o.current!==e&&(o.current=e,void 0===t&&s(d=void 0!==n?n:iX(e))),[d,s,l]}e.s(["useUncontrolledDates",()=>iQ],91395);let i0=(0,u.createContext)({locale:"en",firstDayOfWeek:1,weekendDays:[0,6],labelSeparator:"â",consistentWeeks:!1});function i1(){let e=(0,u.useContext)(i0),t=(0,u.useCallback)(t=>t||e.locale,[e.locale]),n=(0,u.useCallback)(t=>"number"==typeof t?t:e.firstDayOfWeek,[e.firstDayOfWeek]),i=(0,u.useCallback)(t=>Array.isArray(t)?t:e.weekendDays,[e.weekendDays]),r=(0,u.useCallback)(t=>"string"==typeof t?t:e.labelSeparator,[e.labelSeparator]);return{...e,getLocale:t,getFirstDayOfWeek:n,getWeekendDays:i,getLabelSeparator:r}}e.s(["useDatesContext",()=>i1],20790);var i2=e.i(36546);function i3({controlsRef:e,levelIndex:t,rowIndex:n,cellIndex:i,event:r}){let o=function(e){switch(e){case"ArrowDown":return"down";case"ArrowUp":return"up";case"ArrowRight":return"right";case"ArrowLeft":return"left";default:return null}}(r.key);if(o){r.preventDefault();let a=e.current?.map(e=>e.map(e=>e.length));!function e({controlsRef:t,direction:n,levelIndex:i,rowIndex:r,cellIndex:o,size:a}){let s=function({direction:e,levelIndex:t,rowIndex:n,cellIndex:i,size:r}){switch(e){case"up":if(0===t&&0===n)return null;if(0===n)return{levelIndex:t-1,rowIndex:i<=r[t-1][r[t-1].length-1]-1?r[t-1].length-1:r[t-1].length-2,cellIndex:i};return{levelIndex:t,rowIndex:n-1,cellIndex:i};case"down":if(n===r[t].length-1||n===r[t].length-2&&i>=r[t][r[t].length-1])return{levelIndex:t+1,rowIndex:0,cellIndex:i};return{levelIndex:t,rowIndex:n+1,cellIndex:i};case"left":if(0===t&&0===n&&0===i)return null;if(0===n&&0===i)return{levelIndex:t-1,rowIndex:r[t-1].length-1,cellIndex:r[t-1][r[t-1].length-1]-1};if(0===i)return{levelIndex:t,rowIndex:n-1,cellIndex:r[t][n-1]-1};return{levelIndex:t,rowIndex:n,cellIndex:i-1};case"right":if(n===r[t].length-1&&i===r[t][n]-1)return{levelIndex:t+1,rowIndex:0,cellIndex:0};if(i===r[t][n]-1)return{levelIndex:t,rowIndex:n+1,cellIndex:0};return{levelIndex:t,rowIndex:n,cellIndex:i+1};default:return{levelIndex:t,rowIndex:n,cellIndex:i}}}({direction:n,size:a,rowIndex:r,cellIndex:o,levelIndex:i});if(!s)return;let l=t.current?.[s.levelIndex]?.[s.rowIndex]?.[s.cellIndex];l&&(l.disabled||l.getAttribute("data-hidden")||l.getAttribute("data-outside")?e({controlsRef:t,direction:n,levelIndex:s.levelIndex,cellIndex:s.cellIndex,rowIndex:s.rowIndex,size:a}):l.focus())}({controlsRef:e,direction:o,levelIndex:t,rowIndex:n,cellIndex:i,size:a})}}var i5={calendarHeader:"m_730a79ed",calendarHeaderLevel:"m_f6645d97",calendarHeaderControl:"m_2351eeb0",calendarHeaderControlIcon:"m_367dc749"};let i4={hasNextLevel:!0,withNext:!0,withPrevious:!0,headerControlsOrder:["previous","level","next"]},i6=(0,p.createVarsResolver)((e,{size:t})=>({calendarHeader:{"--dch-control-size":(0,f.getSize)(t,"dch-control-size"),"--dch-fz":(0,f.getFontSize)(t)}})),i8=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("CalendarHeader",i4,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,nextIcon:c,previousIcon:h,nextLabel:p,previousLabel:f,onNext:g,onPrevious:m,onLevelClick:b,label:x,nextDisabled:_,previousDisabled:k,hasNextLevel:M,levelControlAriaLabel:T,withNext:D,withPrevious:R,headerControlsOrder:I,__staticSelector:A,__preventFocus:P,__stopPropagation:E,attributes:L,...F}=n,O=(0,y.useStyles)({name:A||"CalendarHeader",classes:i5,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:L,vars:d,varsResolver:i6,rootSelector:"calendarHeader"}),N=P?e=>e.preventDefault():void 0,B=R&&(0,u.createElement)(w.UnstyledButton,{...O("
230calendarHeaderControl"),key:"previous","data-direction":"previous","aria-label":f,onClick:m,unstyled:s,onMouseDown:N,disabled:k,"data-disabled":k||void 0,tabIndex:P||k?-1:0,"data-mantine-stop-propagation":E||void 0},h||(0,l.jsx)(S.AccordionChevron,{...O("calendarHeaderControlIcon"),"data-direction":"previous",size:"45%"})),z=(0,u.createElement)(w.UnstyledButton,{component:M?"button":"div",...O("calendarHeaderLevel"),key:"level",onClick:M?b:void 0,unstyled:s,onMouseDown:M?N:void 0,disabled:!M,"data-static":!M||void 0,"aria-label":T,tabIndex:P||!M?-1:0,"data-mantine-stop-propagation":E||void 0},x),j=D&&(0,u.createElement)(w.UnstyledButton,{...O("calendarHeaderControl"),key:"next","data-direction":"next","aria-label":p,onClick:g,unstyled:s,onMouseDown:N,disabled:_,"data-disabled":_||void 0,tabIndex:P||_?-1:0,"data-mantine-stop-propagation":E||void 0},c||(0,l.jsx)(S.AccordionChevron,{...O("calendarHeaderControlIcon"),"data-direction":"next",size:"45%"})),V=I.map(e=>"previous"===e?B:"level"===e?z:"next"===e?j:null);return(0,l.jsx)(C.Box,{...O("calendarHeader"),ref:t,...F,children:V})});
230i8.classes=i5,i8.displayName="@mantine/dates/CalendarHeader";var i7={pickerControl:"m_dc6a3c71"};let i9=(0,p.createVarsResolver)((e,{size:t})=>({pickerControl:{"--dpc-fz":(0,f.getFontSize)(t),"--dpc-size":(0,f.getSize)(t,"dpc-size")}})),re=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("PickerControl",null,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,firstInRange:u,lastInRange:c,inRange:h,__staticSelector:p,selected:f,disabled:g,attributes:m,...b}=n,x=(0,y.useStyles)({name:p||"PickerControl",classes:i7,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:m,vars:d,varsResolver:i9,rootSelector:"pickerControl"});return(0,l.jsx)(w.UnstyledButton,{...x("pickerControl"),ref:t,unstyled:s,"data-picker-control":!0,"data-selected":f&&!g||void 0,"data-disabled":g||void 0,"data-in-range":h&&!g&&!f||void 0,"data-first-in-range":u&&!g||void 0,"data-last-in-range":c&&!g||void 0,disabled:g,...b})});function rt({year:e,minDate:t,maxDate:n}){return(!!t||!!n)&&!!(t&&(0,i$.default)(e).isBefore(t,"year")||n&&(0,i$.default)(e).isAfter(n,"year"))}function rn(e){let t=(0,i$.default)(e).year(),n=t-t%10,i=0,r=[[],[],[],[]];for(let e=0;e<4;e+=1){let t=3===e?1:3;for(let o=0;o<t;o+=1)r[e].push((0,i$.default)(new Date(n+i,0)).format("YYYY-MM-DD")),i+=1}return r}re.classes=i7,re.displayName="@mantine/dates/PickerControl";var ri={yearsList:"m_9206547b",yearsListCell:"m_c5a19c7d"};let rr={yearsListFormat:"YYYY",withCellSpacing:!0},ro=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("YearsList",rr,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,decade:u,yearsListFormat:c,locale:h,minDate:p,maxDate:f,getYearControlProps:g,__staticSelector:m,__getControlRef:b,__onControlKeyDown:x,__onControlClick:w,__onControlMouseEnter:S,__preventFocus:_,__stopPropagation:k,withCellSpacing:M,size:T,attributes:D,...R}=n,I=(0,y.useStyles)({name:m||"YearsList",classes:ri,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:D,vars:d,rootSelector:"yearsList"}),A=i1(),P=rn(u),E=function({years:e,minDate:t,maxDate:n,getYearControlProps:i}){let r=e.flat().filter(e=>!rt({year:e,minDate:t,maxDate:n})&&!i?.(e)?.disabled),o=r.find(e=>i?.(e)?.selected);if(o)return o;let a=r.find(e=>(0,i$.default)().isSame(e,"year"));return a||r[0]}({years:P,minDate:p,maxDate:f,getYearControlProps:g}),L=P.map((e,t)=>{let n=e.map((e,n)=>{let i=g?.(e),r=(0,i$.default)(e).isSame(E,"year");return(0,l.jsx)("td",{...I("yearsListCell"),"data-with-spacing":M||void 0,children:(0,l.jsx)(re,{...I("yearsListControl"),size:T,unstyled:s,"data-mantine-stop-propagation":k||void 0,disabled:rt({year:e,minDate:p,maxDate:f}),ref:e=>{e&&b?.(t,n,e)},...i,onKeyDown:r=>{i?.onKeyDown?.(r),x?.(r,{rowIndex:t,cellIndex:n,date:e})},onClick:t=>{i?.onClick?.(t),w?.(t,e)},onMouseEnter:t=>{i?.onMouseEnter?.(t),S?.(t,e)},onMouseDown:e=>{i?.onMouseDown?.(e),_&&e.preventDefault()},tabIndex:_||!r?-1:0,children:i?.children??(0,i$.default)(e).locale(A.getLocale(h)).format(c)})},n)});return(0,l.jsx)("tr",{...I("yearsListRow"),children:n},t)});return(0,l.jsx)(C.Box,{component:"table",ref:t,size:T,...I("yearsList"),...R,children:(0,l.jsx)("tbody",{children:L})})});ro.classes=ri,ro.displayName="@mantine/dates/YearsList";let ra={decadeLabelFormat:"YYYY"},rs=(0,m.factory)((e,t)=>{let n,{decade:i,locale:r,minDate:o,maxDate:a,yearsListFormat:s,getYearControlProps:d,__getControlRef:u,__onControlKeyDown:c,__onControlClick:h,__onControlMouseEnter:p,withCellSpacing:f,__preventFocus:g,nextIcon:m,previousIcon:y,nextLabel:b,previousLabel:x,onNext:w,onPrevious:S,nextDisabled:_,previousDisabled:k,levelControlAriaLabel:M,withNext:T,withPrevious:D,headerControlsOrder:R,decadeLabelFormat:I,classNames:A,styles:P,unstyled:E,__staticSelector:L,__stopPropagation:F,size:O,attributes:N,...B}=(0,v.useProps)("DecadeLevel",ra,e),z=i1(),[j,V]=[(n=rn(i))[0][0],n[3][0]],H={__staticSelector:L||"DecadeLevel",classNames:A,styles:P,unstyled:E,size:O,attributes:N},G="boolean"==typeof _?_:!!a&&!(0,i$.default)(V).endOf("year").isBefore(a),W="boolean"==typeof k?k:!!o&&!(0,i$.default)(j).startOf("year").isAfter(o),$=(e,t)=>(0,i$.default)(e).locale(r||z.locale).format(t);return(0,l.jsxs)(C.Box,{"data-decade-level":!0,size:O,ref:t,...B,children:[(0,l.jsx)(i8,{label:"function"==typeof I?I(j,V):`${$(j,I)} \u2013 ${$(V,I)}`,__preventFocus:g,__stopPropagation:F,nextIcon:m,previousIcon:y,nextLabel:b,previousLabel:x,onNext:w,onPrevious:S,nextDisabled:G,previousDisabled:W,hasNextLevel:!1,levelControlAriaLabel:M,withNext:T,withPrevious:D,headerControlsOrder:R,...H}),(0,l.jsx)(ro,{decade:i,locale:r,minDate:o,maxDate:a,yearsListFormat:s,getYearControlProps:d,__getControlRef:u,__onControlKeyDown:c,__onControlClick:h,__onControlMouseEnter:p,__preventFocus:g,__stopPropagation:F,withCellSpacing:f,...H})]})});rs.classes={...ro.classes,...i8.classes},rs.displayName="@mantine/dates/DecadeLevel";var rl={levelsGroup:"m_30b26e33"};let rd=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("LevelsGroup",null,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,__staticSelector:u,attributes:c,...h}=n,p=(0,y.useStyles)({name:u||"LevelsGroup",classes:rl,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:c,vars:d,rootSelector:"levelsGroup"});return(0,l.jsx)(C.Box,{ref:t,...p("levelsGroup"),...h})});rd.classes=rl,rd.displayName="@mantine/dates/LevelsGroup";let ru={numberOfColumns:1},rc=(0,m.factory)((e,t)=>{let{decade:n,locale:i,minDate:r,maxDate:o,yearsListFormat:a,getYearControlProps:s,__onControlClick:d,__onControlMouseEnter:c,withCellSpacing:h,__preventFocus:p,nextIcon:f,previousIcon:g,nextLabel:m,previousLabel:y,onNext:b,onPrevious:x,nextDisabled:w,previousDisabled:C,headerControlsOrder:S,classNames:_,styles:k,unstyled:M,__staticSelector:T,__stopPropagation:D,numberOfColumns:R,levelControlAriaLabel:I,decadeLabelFormat:A,size:P,vars:E,attributes:L,...F}=(0,v.useProps)("DecadeLevelGroup",ru,e),O=(0,u.useRef)([]),N=Array(R).fill(0).map((e,t)=>{let u=(0,i$.default)(n).add(10*t,"years").format("YYYY-MM-DD");return(0,l.jsx)(rs,{size:P,yearsListFormat:a,decade:u,withNext:t===R-1,withPrevious:0===t,decadeLabelFormat:A,__onControlClick:d,__onControlMouseEnter:c,__onControlKeyDown:(e,n)=>i3({levelIndex:t,rowIndex:n.rowIndex,cellIndex:n.cellIndex,event:e,controlsRef:O}),__getControlRef:(e,n,i)=>{Array.isArray(O.current[t])||(O.current[t]=[]),Array.isArray(O.current[t][e])||(O.current[t][e]=[]),O.current[t][e][n]=i},levelControlAriaLabel:"function"==typeof I?I(u):I,locale:i,minDate:r,maxDate:o,__preventFocus:p,__stopPropagation:D,nextIcon:f,previousIcon:g,nextLabel:m,previousLabel:y,onNext:b,onPrevious:x,nextDisabled:w,previousDisabled:C,getYearControlProps:s,__staticSelector:T||"DecadeLevelGroup",classNames:_,styles:k,unstyled:M,withCellSpacing:h,headerControlsOrder:S,attributes:L},t)});return(0,l.jsx)(rd,{classNames:_,styles:k,__staticSelector:T||"DecadeLevelGroup",ref:t,size:P,unstyled:M,attributes:L,...F,children:N})});rc.classes={...rd.classes,...rs.classes},rc.displayName="@mantine/dates/DecadeLevelGroup";var rh={day:"m_396ce5cb"};let rp=(0,p.createVarsResolver)((e,{size:t})=>({day:{"--day-size":(0,f.getSize)(t,"day-size")}})),rf=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("Day",null,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,date:u,disabled:c,__staticSelector:h,weekend:p,outside:f,selected:g,renderDay:m,inRange:b,firstInRange:x,lastInRange:C,hidden:S,static:_,highlightToday:k,attributes:M,...T}=n,D=(0,y.useStyles)({name:h||"Day",classes:rh,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:M,vars:d,varsResolver:rp,rootSelector:"day"});return(0,l.jsx)(w.UnstyledButton,{...D("day",{style:S?{display:"none"}:void 0}),component:_?"div":"button",ref:t,disabled:c,"data-today":(0,i$.default)(u).isSame(new Date,"day")||void 0,"data-hidden":S||void 0,"data-highlight-today":k||void 0,"data-disabled":c||void 0,"data-weekend":!c&&!f&&p||void 0,"data-outside":!c&&f||void 0,"data-selected":!c&&g||void 0,"data-in-range":b&&!c||void 0,"data-first-in-range":x&&!c||void 0,"data-last-in-range":C&&!c||void 0,"data-static":_||void 0,unstyled:s,...T,children:m?.(u)||(0,i$.default)(u).date()})});rf.classes=rh,rf.displayName="@mantine/dates/Day";
230var rg={weekday:"m_18a3eca"};let rm=(0,p.createVarsResolver)((e,{size:t})=>({weekdaysRow:{"--wr-fz":(0,f.getFontSize)(t),"--wr-spacing":(0,f.getSpacing)(t)}})),rv=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("WeekdaysRow",null,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,locale:u,firstDayOfWeek:c,weekdayFormat:h,cellComponent:p="th",__staticSelector:f,withWeekNumbers:g,attributes:m,...b}=n,x=(0,y.useStyles)({name:f||"WeekdaysRow",classes:rg,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:m,vars:d,varsResolver:rm,rootSelector:"weekdaysRow"}),w=i1(),S=(function({locale:e,format:t="dd",firstDayOfWeek:n=1}){let i=(0,i$.default)().day(n),r=[];for(let n=0;n<7;n+=1)"string"==typeof t?r.push((0,i$.default)(i).add(n,"days").locale(e).format(t)):r.push(t((0,i$.default)(i).add(n,"days").format("YYYY-MM-DD")));return r})({locale:w.getLocale(u),format:h,firstDayOfWeek:w.getFirstDayOfWeek(c)}).map((e,t)=>(0,l.jsx)(p,{...x("weekday"),children:e},t));return(0,l.jsxs)(C.Box,{component:"tr",ref:t,...x("weekdaysRow"),...b,children:[g&&(0,l.jsx)(p,{...x("weekday"),children:"#"}),S]})});function ry(e,t){return!t||(0,i$.default)(e).isAfter((0,i$.default)(t).subtract(1,"day"),"day")}function rb(e,t){return!t||(0,i$.default)(e).isBefore((0,i$.default)(t).add(1,"day"),"day")}function rx(e,t){return(0,i$.default)(e).format("YYYY-MM")===(0,i$.default)(t).format("YYYY-MM")}rv.classes=rg,rv.displayName="@mantine/dates/WeekdaysRow",e.s(["isSameMonth",()=>rx],24831);var rw=e.i(92558);i$.default.extend(rw.default);var rC={month:"m_cc9820d3",monthCell:"m_8f457cd5",weekNumber:"m_6cff9dea"};let rS={withCellSpacing:!0},r_=(0,p.createVarsResolver)((e,{size:t})=>({weekNumber:{"--wn-fz":(0,f.getFontSize)(t),"--wn-size":(0,f.getSize)(t,"wn-size")}})),rk=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("Month",rS,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,__staticSelector:u,locale:c,firstDayOfWeek:h,weekdayFormat:p,month:f,weekendDays:g,getDayProps:m,excludeDate:b,minDate:x,maxDate:w,renderDay:S,hideOutsideDates:_,hideWeekdays:k,getDayAriaLabel:M,static:T,__getDayRef:D,__onDayKeyDown:R,__onDayClick:I,__onDayMouseEnter:A,__preventFocus:P,__stopPropagation:E,withCellSpacing:L,size:F,highlightToday:O,withWeekNumbers:N,attributes:B,...z}=n,j=(0,y.useStyles)({name:u||"Month",classes:rC,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:B,vars:d,varsResolver:r_,rootSelector:"month"}),V=i1(),H=function({month:e,firstDayOfWeek:t=1,consistentWeeks:n}){let i=(0,i$.default)(e).subtract((0,i$.default)(e).date()-1,"day"),r=(0,i$.default)(i.format("YYYY-M-D")),o=r.format("YYYY-MM-DD"),a=function(e,t=1){let n=(0,i$.default)(e);if(!n.isValid())return n;let i=0===t?6:t-1;for(;n.day()!==i;)n=n.add(1,"day");return n.format("YYYY-MM-DD")}(r.add(r.daysInMonth()-1,"day").format("YYYY-MM-DD"),t),s=[],l=(0,i$.default)(function(e,t=1){let n=(0,i$.default)(e);for(;n.day()!==t;)n=n.subtract(1,"day");return n.format("YYYY-MM-DD")}(o,t));for(;(0,i$.default)(l).isBefore(a,"day");){let e=[];for(let t=0;t<7;t+=1)e.push(l.format("YYYY-MM-DD")),l=l.add(1,"day");s.push(e)}if(n&&s.length<6){let e=s[s.length-1],t=e[e.length-1],n=(0,i$.default)(t).add(1,"day");for(;s.length<6;){let e=[];for(let t=0;t<7;t+=1)e.push(n.format("YYYY-MM-DD")),n=n.add(1,"day");s.push(e)}}return s}({month:f,firstDayOfWeek:V.getFirstDayOfWeek(h),consistentWeeks:V.consistentWeeks}),G=function({dates:e,minDate:t,maxDate:n,getDayProps:i,excludeDate:r,hideOutsideDates:o,month:a}){let s=e.flat().filter(e=>rb(e,n)&&ry(e,t)&&!r?.(e)&&!i?.(e)?.disabled&&(!o||rx(e,a))),l=s.find(e=>i?.(e)?.selected);if(l)return l;let d=s.find(e=>(0,i$.default)().isSame(e,"date"));return d||s[0]}({dates:H,minDate:iY(x),maxDate:iY(w),getDayProps:m,excludeDate:b,hideOutsideDates:_,month:f}),{resolvedClassNames:W,resolvedStyles:$}=(0,i2.useResolvedStylesApi)({classNames:i,styles:a,props:n}),U=H.map((e,t)=>{let n,i=e.map((e,n)=>{let i=!rx(e,f),r=M?.(e)||(0,i$.default)(e).locale(c||V.locale).format("D MMMM YYYY"),o=m?.(e),a=(0,i$.default)(e).isSame(G,"date");return(0,l.jsx)("td",{...j("monthCell"),"data-with-spacing":L||void 0,children:(0,l.jsx)(rf,{__staticSelector:u||"Month",classNames:W,styles:$,unstyled:s,"data-mantine-stop-propagation":E||void 0,highlightToday:O,renderDay:S,date:e,size:F,weekend:V.getWeekendDays(g).includes((0,i$.default)(e).get("day")),outside:i,hidden:!!_&&i,"aria-label":r,static:T,disabled:b?.(e)||!rb(e,iY(w))||!ry(e,iY(x)),ref:e=>{e&&D?.(t,n,e)},...o,onKeyDown:i=>{o?.onKeyDown?.(i),R?.(i,{rowIndex:t,cellIndex:n,date:e})},onMouseEnter:t=>{o?.onMouseEnter?.(t),A?.(t,e)},onClick:t=>{o?.onClick?.(t),I?.(t,e)},onMouseDown:e=>{o?.onMouseDown?.(e),P&&e.preventDefault()},tabIndex:P||!a?-1:0})},e.toString())});return(0,l.jsxs)("tr",{...j("monthRow"),children:[N&&(0,l.jsx)("td",{...j("weekNumber"),children:(n=e.find(e=>1===(0,i$.default)(e).day()),(0,i$.default)(n).isoWeek())}),i]},t)});return(0,l.jsxs)(C.Box,{component:"table",...j("month"),size:F,ref:t,...z,children:[!k&&(0,l.jsx)("thead",{...j("monthThead"),children:(0,l.jsx)(rv,{__staticSelector:u||"Month",locale:c,firstDayOfWeek:h,weekdayFormat:p,size:F,classNames:W,styles:$,unstyled:s,withWeekNumbers:N})}),(0,l.jsx)("tbody",{...j("monthTbody"),children:U})]})});rk.classes=rC,rk.displayName="@mantine/dates/Month";let rM={monthLabelFormat:"MMMM YYYY"},rT=(0,m.factory)((e,t)=>{let{month:n,locale:i,firstDayOfWeek:r,weekdayFormat:o,weekendDays:a,getDayProps:s,excludeDate:d,minDate:u,maxDate:c,renderDay:h,hideOutsideDates:p,hideWeekdays:f,getDayAriaLabel:g,__getDayRef:m,__onDayKeyDown:y,__onDayCl
230ick:b,__onDayMouseEnter:x,withCellSpacing:w,highlightToday:S,withWeekNumbers:_,__preventFocus:k,__stopPropagation:M,nextIcon:T,previousIcon:D,nextLabel:R,previousLabel:I,onNext:A,onPrevious:P,onLevelClick:E,nextDisabled:L,previousDisabled:F,hasNextLevel:O,levelControlAriaLabel:N,withNext:B,withPrevious:z,headerControlsOrder:j,monthLabelFormat:V,classNames:H,styles:G,unstyled:W,__staticSelector:$,size:U,static:q,attributes:K,...Y}=(0,v.useProps)("MonthLevel",rM,e),Z=i1(),X={__staticSelector:$||"MonthLevel",classNames:H,styles:G,unstyled:W,size:U,attributes:K},J="boolean"==typeof L?L:!!c&&!(0,i$.default)(n).endOf("month").isBefore(c),Q="boolean"==typeof F?F:!!u&&!(0,i$.default)(n).startOf("month").isAfter(u);return(0,l.jsxs)(C.Box,{"data-month-level":!0,size:U,ref:t,...Y,children:[(0,l.jsx)(i8,{label:"function"==typeof V?V(n):(0,i$.default)(n).locale(i||Z.locale).format(V),__preventFocus:k,__stopPropagation:M,nextIcon:T,previousIcon:D,nextLabel:R,previousLabel:I,onNext:A,onPrevious:P,onLevelClick:E,nextDisabled:J,previousDisabled:Q,hasNextLevel:O,levelControlAriaLabel:N,withNext:B,withPrevious:z,headerControlsOrder:j,...X}),(0,l.jsx)(rk,{month:n,locale:i,firstDayOfWeek:r,weekdayFormat:o,weekendDays:a,getDayProps:s,excludeDate:d,minDate:u,maxDate:c,renderDay:h,hideOutsideDates:p,hideWeekdays:f,getDayAriaLabel:g,__getDayRef:m,__onDayKeyDown:y,__onDayClick:b,__onDayMouseEnter:x,__preventFocus:k,__stopPropagation:M,static:q,withCellSpacing:w,highlightToday:S,withWeekNumbers:_,...X})]})});rT.classes={...rk.classes,...i8.classes},rT.displayName="@mantine/dates/MonthLevel";let rD={numberOfColumns:1},rR=(0,m.factory)((e,t)=>{let{month:n,locale:i,firstDayOfWeek:r,weekdayFormat:o,weekendDays:a,getDayProps:s,excludeDate:d,minDate:c,maxDate:h,renderDay:p,hideOutsideDates:f,hideWeekdays:g,getDayAriaLabel:m,__onDayClick:y,__onDayMouseEnter:b,withCellSpacing:x,highlightToday:w,withWeekNumbers:C,__preventFocus:S,nextIcon:_,previousIcon:k,nextLabel:M,previousLabel:T,onNext:D,onPrevious:R,onLevelClick:I,nextDisabled:A,previousDisabled:P,hasNextLevel:E,headerControlsOrder:L,classNames:F,styles:O,unstyled:N,numberOfColumns:B,levelControlAriaLabel:z,monthLabelFormat:j,__staticSelector:V,__stopPropagation:H,size:G,static:W,vars:$,attributes:U,...q}=(0,v.useProps)("MonthLevelGroup",rD,e),K=(0,u.useRef)([]),Y=Array(B).fill(0).map((e,t)=>{let u=(0,i$.default)(n).add(t,"months").format("YYYY-MM-DD");return(0,l.jsx)(rT,{month:u,withNext:t===B-1,withPrevious:0===t,monthLabelFormat:j,__stopPropagation:H,__onDayClick:y,__onDayMouseEnter:b,__onDayKeyDown:(e,n)=>i3({levelIndex:t,rowIndex:n.rowIndex,cellIndex:n.cellIndex,event:e,controlsRef:K}),__getDayRef:(e,n,i)=>{Array.isArray(K.current[t])||(K.current[t]=[]),Array.isArray(K.current[t][e])||(K.current[t][e]=[]),K.current[t][e][n]=i},levelControlAriaLabel:"function"==typeof z?z(u):z,locale:i,firstDayOfWeek:r,weekdayFormat:o,weekendDays:a,getDayProps:s,excludeDate:d,minDate:c,maxDate:h,renderDay:p,hideOutsideDates:f,hideWeekdays:g,getDayAriaLabel:m,__preventFocus:S,nextIcon:_,previousIcon:k,nextLabel:M,previousLabel:T,onNext:D,onPrevious:R,onLevelClick:I,nextDisabled:A,previousDisabled:P,hasNextLevel:E,classNames:F,styles:O,unstyled:N,__staticSelector:V||"MonthLevelGroup",size:G,static:W,withCellSpacing:x,highlightToday:w,withWeekNumbers:C,headerControlsOrder:L,attributes:U},t)});return(0,l.jsx)(rd,{classNames:F,styles:O,__staticSelector:V||"MonthLevelGroup",ref:t,size:G,attributes:U,...q,children:Y})});function rI({month:e,minDate:t,maxDate:n}){return(!!t||!!n)&&!!(t&&(0,i$.default)(e).isBefore(t,"month")||n&&(0,i$.default)(e).isAfter(n,"month"))}rR.classes={...rd.classes,...rT.classes},rR.displayName="@mantine/dates/MonthLevelGroup";var rA={monthsList:"m_2a6c32d",monthsListCell:"m_fe27622f"};let rP={monthsListFormat:"MMM",withCellSpacing:!0},rE=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("MonthsList",rP,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:d,__staticSelector:u,year:c,monthsListFormat:h,locale:p,minDate:f,maxDate:g,getMonthControlProps:m,__getControlRef:b,__onControlKeyDown:x,__onControlClick:w,__onControlMouseEnter:S,__preventFocus:_,__stopPropagation:k,withCellSpacing:M,size:T,attributes:D,...R}=n,I=(0,y.useStyles)({name:u||"MonthsList",classes:rA,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:D,vars:d,rootSelector:"monthsList"}),A=i1(),P=function(e){let t=(0,i$.default)(e).startOf("year").toDate(),n=[[],[],[],[]],i=0;for(let e=0;e<4;e+=1)for(let r=0;r<3;r+=1)n[e].push((0,i$.default)(t).add(i,"months").format("YYYY-MM-DD")),i+=1;return n}(c),E=function({months:e,minDate:t,maxDate:n,getMonthControlProps:i}){let r=e.flat().filter(e=>!rI({month:e,minDate:t,maxDate:n})&&!i?.(e)?.disabled),o=r.find(e=>i?.(e)?.selected);if(o)return o;let a=r.find(e=>(0,i$.default)().isSame(e,"month"));return a||r[0]}({months:P,minDate:iY(f),maxDate:iY(g),getMonthControlProps:m}),L=P.map((e,t)=>{let n=e.map((e,n)=>{let i=m?.(e),r=(0,i$.default)(e).isSame(E,"month");return(0,l.jsx)("td",{...I("monthsListCell"),"data-with-spacing":M||void 0,children:(0,l.jsx)(re,{...I("monthsListControl"),size:T,unstyled:s,__staticSelector:u||"MonthsList","data-mantine-stop-propagation":k||void 0,disabled:rI({month:e,minDate:iY(f),maxDate:iY(g)}),ref:e=>{e&&b?.(t,n,e)},...i,onKeyDown:r=>{i?.onKeyDown?.(r),x?.(r,{rowIndex:t,cellIndex:n,date:e})},onClick:t=>{i?.onClick?.(t),w?.(t,e)},onMouseEnter:t=>{i?.onMouseEnter?.(t),S?.(t,e)},onMouseDown:e=>{i?.onMouseDown?.(e),_&&e.preventDefault()},tabIndex:_||!r?-1:0,children:i?.children??(0,i$.default)(e).locale(A.getLocale(p)).format(h)})},n)});
230return(0,l.jsx)("tr",{...I("monthsListRow"),children:n},t)});return(0,l.jsx)(C.Box,{component:"table",ref:t,size:T,...I("monthsList"),...R,children:(0,l.jsx)("tbody",{children:L})})});rE.classes=rA,rE.displayName="@mantine/dates/MonthsList";let rL={yearLabelFormat:"YYYY"},rF=(0,m.factory)((e,t)=>{let{year:n,locale:i,minDate:r,maxDate:o,monthsListFormat:a,getMonthControlProps:s,__getControlRef:d,__onControlKeyDown:u,__onControlClick:c,__onControlMouseEnter:h,withCellSpacing:p,__preventFocus:f,nextIcon:g,previousIcon:m,nextLabel:y,previousLabel:b,onNext:x,onPrevious:w,onLevelClick:S,nextDisabled:_,previousDisabled:k,hasNextLevel:M,levelControlAriaLabel:T,withNext:D,withPrevious:R,headerControlsOrder:I,yearLabelFormat:A,__staticSelector:P,__stopPropagation:E,size:L,classNames:F,styles:O,unstyled:N,attributes:B,...z}=(0,v.useProps)("YearLevel",rL,e),j=i1(),V={__staticSelector:P||"YearLevel",classNames:F,styles:O,unstyled:N,size:L,attributes:B},H="boolean"==typeof _?_:!!o&&!(0,i$.default)(n).endOf("year").isBefore(o),G="boolean"==typeof k?k:!!r&&!(0,i$.default)(n).startOf("year").isAfter(r);return(0,l.jsxs)(C.Box,{"data-year-level":!0,size:L,ref:t,...z,children:[(0,l.jsx)(i8,{label:"function"==typeof A?A(n):(0,i$.default)(n).locale(i||j.locale).format(A),__preventFocus:f,__stopPropagation:E,nextIcon:g,previousIcon:m,nextLabel:y,previousLabel:b,onNext:x,onPrevious:w,onLevelClick:S,nextDisabled:H,previousDisabled:G,hasNextLevel:M,levelControlAriaLabel:T,withNext:D,withPrevious:R,headerControlsOrder:I,...V}),(0,l.jsx)(rE,{year:n,locale:i,minDate:r,maxDate:o,monthsListFormat:a,getMonthControlProps:s,__getControlRef:d,__onControlKeyDown:u,__onControlClick:c,__onControlMouseEnter:h,__preventFocus:f,__stopPropagation:E,withCellSpacing:p,...V})]})});rF.classes={...i8.classes,...rE.classes},rF.displayName="@mantine/dates/YearLevel";let rO={numberOfColumns:1},rN=(0,m.factory)((e,t)=>{let{year:n,locale:i,minDate:r,maxDate:o,monthsListFormat:a,getMonthControlProps:s,__onControlClick:d,__onControlMouseEnter:c,withCellSpacing:h,__preventFocus:p,nextIcon:f,previousIcon:g,nextLabel:m,previousLabel:y,onNext:b,onPrevious:x,onLevelClick:w,nextDisabled:C,previousDisabled:S,hasNextLevel:_,headerControlsOrder:k,classNames:M,styles:T,unstyled:D,__staticSelector:R,__stopPropagation:I,numberOfColumns:A,levelControlAriaLabel:P,yearLabelFormat:E,size:L,vars:F,attributes:O,...N}=(0,v.useProps)("YearLevelGroup",rO,e),B=(0,u.useRef)([]),z=Array(A).fill(0).map((e,t)=>{let u=(0,i$.default)(n).add(t,"years").format("YYYY-MM-DD");return(0,l.jsx)(rF,{size:L,monthsListFormat:a,year:u,withNext:t===A-1,withPrevious:0===t,yearLabelFormat:E,__stopPropagation:I,__onControlClick:d,__onControlMouseEnter:c,__onControlKeyDown:(e,n)=>i3({levelIndex:t,rowIndex:n.rowIndex,cellIndex:n.cellIndex,event:e,controlsRef:B}),__getControlRef:(e,n,i)=>{Array.isArray(B.current[t])||(B.current[t]=[]),Array.isArray(B.current[t][e])||(B.current[t][e]=[]),B.current[t][e][n]=i},levelControlAriaLabel:"function"==typeof P?P(u):P,locale:i,minDate:r,maxDate:o,__preventFocus:p,nextIcon:f,previousIcon:g,nextLabel:m,previousLabel:y,onNext:b,onPrevious:x,onLevelClick:w,nextDisabled:C,previousDisabled:S,hasNextLevel:_,getMonthControlProps:s,classNames:M,styles:T,unstyled:D,__staticSelector:R||"YearLevelGroup",withCellSpacing:h,headerControlsOrder:k,attributes:O},t)});return(0,l.jsx)(rd,{classNames:M,styles:T,__staticSelector:R||"YearLevelGroup",ref:t,size:L,unstyled:D,attributes:O,...N,children:z})});function rB(e,t){return e?"month"===e?0:"year"===e?1:2:t||0}function rz(e,t,n){var i;return 0===(i=_(rB(e,0),rB(t,0),rB(n,2)))?"month":1===i?"year":"decade"}rN.classes={...rF.classes,...rd.classes},rN.displayName="@mantine/dates/YearLevelGroup";let rj={maxLevel:"decade",minLevel:"month",__updateDateOnYearSelect:!0,__updateDateOnMonthSelect:!0,enableKeyboardNavigation:!0},rV=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("Calendar",rj,e),{vars:i,maxLevel:r,minLevel:o,defaultLevel:a,level:s,onLevelChange:d,date:c,defaultDate:h,onDateChange:p,numberOfColumns:f,columnsToScroll:g,ariaLabels:m,nextLabel:y,previousLabel:b,onYearSelect:x,onMonthSelect:w,onYearMouseEnter:S,onMonthMouseEnter:_,headerControlsOrder:k,__updateDateOnYearSelect:M,__updateDateOnMonthSelect:T,__setDateRef:D,__setLevelRef:R,firstDayOfWeek:I,weekdayFormat:A,weekendDays:P,getDayProps:E,excludeDate:L,renderDay:F,hideOutsideDates:O,hideWeekdays:N,getDayAriaLabel:B,monthLabelFormat:z,nextIcon:j,previousIcon:V,__onDayCl
230ick:H,__onDayMouseEnter:G,withCellSpacing:W,highlightToday:$,withWeekNumbers:U,monthsListFormat:q,getMonthControlProps:K,yearLabelFormat:Y,yearsListFormat:Z,getYearControlProps:X,decadeLabelFormat:J,classNames:Q,styles:ee,unstyled:et,minDate:en,maxDate:ei,locale:er,__staticSelector:eo,size:ea,__preventFocus:es,__stopPropagation:el,onNextDecade:ed,onPreviousDecade:eu,onNextYear:ec,onPreviousYear:eh,onNextMonth:ep,onPreviousMonth:ef,static:eg,enableKeyboardNavigation:em,attributes:ev,...ey}=n,{resolvedClassNames:eb,resolvedStyles:ex}=(0,i2.useResolvedStylesApi)({classNames:Q,styles:ee,props:n}),[ew,eC]=(0,n5.useUncontrolled)({value:s?rz(s,o,r):void 0,defaultValue:a?rz(a,o,r):void 0,finalValue:rz(void 0,o,r),onChange:d}),[eS,e_]=iQ({type:"default",value:iY(c),defaultValue:iY(h),onChange:p});(0,u.useImperativeHandle)(D,()=>e=>{e_(e)}),(0,u.useImperativeHandle)(R,()=>e=>{eC(e)});let ek={__staticSelector:eo||"Calendar",styles:ex,classNames:eb,unstyled:et,size:ea,attributes:ev},eM=g||f||1,eT=new Date,eD=en&&(0,i$.default)(eT).isAfter(en)?en:(0,i$.default)(eT).format("YYYY-MM-DD"),eR=eS||eD,eI=()=>{let e=(0,i$.default)(eR).add(eM,"year").format("YYYY-MM-DD");ec?.(e),e_(e)},eA=()=>{let e=(0,i$.default)(eR).subtract(eM,"year").format("YYYY-MM-DD");eh?.(e),e_(e)},eP=()=>{let e=(0,i$.default)(eR).add(10*eM,"year").format("YYYY-MM-DD");ed?.(e),e_(e)},eE=()=>{let e=(0,i$.default)(eR).subtract(10*eM,"year").format("YYYY-MM-DD");eu?.(e),e_(e)},eL=(0,u.useRef)(null);return(0,u.useEffect)(()=>{if(!em||eg)return;let e=e=>{if(!eL.current?.contains(document.activeElement))return;let t=e.ctrlKey||e.metaKey,n=e.shiftKey;switch(e.key){case"ArrowUp":t&&n?(e.preventDefault(),eE()):t&&(e.preventDefault(),eA());break;case"ArrowDown":t&&n?(e.preventDefault(),eP()):t&&(e.preventDefault(),eI());break;case"y":case"Y":"month"===ew&&(e.preventDefault(),eC("year"))}};return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)}},[em,eg,ew,eI,eA,eP,eE]),(0,l.jsxs)(C.Box,{ref:e=>{eL.current=e,"function"==typeof t?t(e):t&&(t.current=e)},size:ea,"data-calendar":!0,...ey,children:["month"===ew&&(0,l.jsx)(rR,{month:eR,minDate:en,maxDate:ei,firstDayOfWeek:I,weekdayFormat:A,weekendDays:P,getDayProps:E,excludeDate:L,renderDay:F,hideOutsideDates:O,hideWeekdays:N,getDayAriaLabel:B,onNext:()=>{let e=(0,i$.default)(eR).add(eM,"month").format("YYYY-MM-DD");ep?.(e),e_(e)},onPrevious:()=>{let e=(0,i$.default)(eR).subtract(eM,"month").format("YYYY-MM-DD");ef?.(e),e_(e)},hasNextLevel:"month"!==r,onLevelClick:()=>eC("year"),numberOfColumns:f,locale:er,levelControlAriaLabel:m?.monthLevelControl,nextLabel:m?.nextMonth??y,nextIcon:j,previousLabel:m?.previousMonth??b,previousIcon:V,monthLabelFormat:z,__onDayClick:H,__onDayMouseEnter:G,__preventFocus:es,__stopPropagation:el,static:eg,withCellSpacing:W,highlightToday:$,withWeekNumbers:U,headerControlsOrder:k,...ek}),"year"===ew&&(0,l.jsx)(rN,{year:eR,numberOfColumns:f,minDate:en,maxDate:ei,monthsListFormat:q,getMonthControlProps:K,locale:er,onNext:eI,onPrevious:eA,hasNextLevel:"month"!==r&&"year"!==r,onLevelClick:()=>eC("decade"),levelControlAriaLabel:m?.yearLevelControl,nextLabel:m?.nextYear??y,nextIcon:j,previousLabel:m?.previousYear??b,previousIcon:V,yearLabelFormat:Y,__onControlMouseEnter:_,__onControlClick:(e,t)=>{T&&e_(t),eC(rz("month",o,r)),w?.(t)},__preventFocus:es,__stopPropagation:el,withCellSpacing:W,headerControlsOrder:k,...ek}),"decade"===ew&&(0,l.jsx)(rc,{decade:eR,minDate:en,maxDate:ei,yearsListFormat:Z,getYearControlProps:X,locale:er,onNext:eP,onPrevious:eE,numberOfColumns:f,nextLabel:m?.nextDecade??y,nextIcon:j,previousLabel:m?.previousDecade??b,previousIcon:V,decadeLabelFormat:J,__onControlMouseEnter:S,__onControlClick:(e,t)=>{M&&e_(t),eC(rz("year",o,r)),x?.(t)},__preventFocus:es,__stopPropagation:el,withCellSpacing:W,headerControlsOrder:k,...ek})]})});function rH(e){let{maxLevel:t,minLevel:n,defaultLevel:i,level:r,onLevelChange:o,nextIcon:a,previousIcon:s,date:l,defaultDate:d,onDateChange:u,numberOfColumns:c,columnsToScroll:h,ariaLabels:p,nextLabel:f,previousLabel:g,onYearSelect:m,onMonthSelect:v,onYearMouseEnter:y,onMonthMouseEnter:b,onNextMonth:x,onPreviousMonth:w,onNextYear:C,onPreviousYear:S,onNextDecade:_,onPreviousDecade:k,withCellSpacing:M,highlightToday:T,__updateDateOnYearSelect:D,__updateDateOnMonthSelect:R,__setDateRef:I,__setLevelRef:A,withWeekNumbers:P,headerControlsOrder:E,firstDayOfWeek:L,weekdayFormat:F,weekendDays:O,getDayProps:N,excludeDate:B,renderDay:z,hideOutsideDates:j,hideWeekdays:V,getDayAriaLabel:H,monthLabelFormat:G,monthsListFormat:W,getMonthControlProps:$,yearLabelFormat:U,yearsListFormat:q,getYearControlProps:K,decadeLabelFormat:Y,allowSingleDateInRange:Z,allowDeselect:X,minDate:J,maxDate:Q,locale:ee,...et}=e;return{calendarProps:{maxLevel:t,minLevel:n,defaultLevel:i,level:r,onLevelChange:o,nextIcon:a,previousIcon:s,date:l,defaultDate:d,onDateChange:u,numberOfColumns:c,
230columnsToScroll:h,ariaLabels:p,nextLabel:f,previousLabel:g,onYearSelect:m,onMonthSelect:v,onYearMouseEnter:y,onMonthMouseEnter:b,onNextMonth:x,onPreviousMonth:w,onNextYear:C,onPreviousYear:S,onNextDecade:_,onPreviousDecade:k,withCellSpacing:M,highlightToday:T,__updateDateOnYearSelect:D,__updateDateOnMonthSelect:R,__setDateRef:I,withWeekNumbers:P,headerControlsOrder:E,firstDayOfWeek:L,weekdayFormat:F,weekendDays:O,getDayProps:N,excludeDate:B,renderDay:z,hideOutsideDates:j,hideWeekdays:V,getDayAriaLabel:H,monthLabelFormat:G,monthsListFormat:W,getMonthControlProps:$,yearLabelFormat:U,yearsListFormat:q,getYearControlProps:K,decadeLabelFormat:Y,allowSingleDateInRange:Z,allowDeselect:X,minDate:J,maxDate:Q,locale:ee},others:et}}function rG({value:e,type:t,name:n,form:i,withTime:r=!1}){return(0,l.jsx)("input",{type:"hidden",value:function({value:e,type:t,withTime:n}){let i=n?iZ:iY;if("range"===t&&Array.isArray(e)){let t=i(e[0]),n=i(e[1]);return t?n?`${t} \u2013 ${n}`:`${t} \u2013`:""}return"multiple"===t&&Array.isArray(e)?e.filter(Boolean).join(", "):!Array.isArray(e)&&e?i(e):""}({value:e,type:t,withTime:r}),name:n,form:i})}rV.classes={...rc.classes,...rN.classes,...rR.classes},rV.displayName="@mantine/dates/Calendar",e.s(["Calendar",()=>rV],90370),e.s(["pickCalendarProps",()=>rH],39344),rG.displayName="@mantine/dates/HiddenDatesInput",e.s(["HiddenDatesInput",()=>rG],52052);let rW={valueFormat:"MMMM D, YYYY",fixOnBlur:!0,size:"sm"},r$=(0,m.factory)((e,t)=>{let{inputProps:n,wrapperProps:i,value:r,defaultValue:o,onChange:a,clearable:s,clearButtonProps:d,popoverProps:c,getDayProps:h,locale:p,valueFormat:f,dateParser:g,minDate:m,maxDate:v,fixOnBlur:y,onFocus:b,onBlur:x,onClick:w,onKeyDown:C,readOnly:S,name:_,form:k,rightSection:M,unstyled:T,classNames:D,styles:R,allowDeselect:I,date:A,defaultDate:P,onDateChange:E,getMonthControlProps:L,getYearControlProps:F,disabled:O,...N}=(0,iU.useInputProps)("DateInput",rW,e),B=(0,u.useRef)(null),z=(0,u.useRef)(null),[j,V]=(0,u.useState)(!1),{calendarProps:H,others:G}=rH(N),W=i1(),$=g||(e=>{let t=(0,i$.default)(e,f,W.getLocale(p)).toDate();return Number.isNaN(t.getTime())?function(e){if(null===e)return null;let t=new Date(e);return Number.isNaN(t.getTime())||!e?null:(0,i$.default)(t).format("YYYY-MM-DD")}(e):(0,i$.default)(t).format("YYYY-MM-DD")}),U=void 0!==I?I:s,q=e=>e?(0,i$.default)(e).locale(W.getLocale(p)).format(f):"",[K,Y,Z]=iQ({type:"default",value:r,defaultValue:o,onChange:a}),[X,J]=iQ({type:"default",value:A,defaultValue:o||P,onChange:E});(0,u.useEffect)(()=>{Z&&null!==r&&J(r)},[Z,r]);let[Q,ee]=(0,u.useState)(q(K));(0,u.useEffect)(()=>{ee(q(K))},[W.getLocale(p)]);let et=(0,l.jsx)(n0.Input.ClearButton,{onClick:()=>{Y(null),Z||ee(""),V(!1)},unstyled:T,...d}),en=s&&!!K&&!S&&!O;return(0,iB.useDidUpdate)(()=>{void 0===K||j||ee(q(K))},[K]),(0,iK.useClickOutside)(()=>V(!1),void 0,[B.current,z.current]),(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(n0.Input.Wrapper,{...i,__staticSelector:"DateInput",ref:B,children:(0,l.jsxs)(iq.Popover,{opened:j,trapFocus:!1,position:"bottom-start",disabled:S||O,withRoles:!1,unstyled:T,...c,children:[(0,l.jsx)(iq.Popover.Target,{children:(0,l.jsx)(n0.Input,{"data-dates-input":!0,"data-read-only":S||void 0,autoComplete:"off",ref:t,value:Q,onChange:e=>{let t=e.currentTarget.value;if(ee(t),V(!0),""===t.trim()&&(I||s))Y(null);else{let e=$(t);e&&function({date:e,maxDate:t,minDate:n}){return!(null==e||Number.isNaN(new Date(e).getTime())||t&&(0,i$.default)(e).isAfter(t,"date")||n&&(0,i$.default)(e).isBefore(n,"date"))}({date:e,minDate:m,maxDate:v})&&(Y(e),J(e))}},onBlur:e=>{x?.(e),V(!1),y&&ee(q(K))},onFocus:e=>{b?.(e),V(!0)},onClick:e=>{w?.(e),V(!0)},onKeyDown:e=>{"Escape"===e.key&&V(!1),C?.(e)},readOnly:S,rightSection:M,__clearSection:et,__clearable:en,...n,...G,disabled:O,__staticSelector:"DateInput"})}),(0,l.jsx)(iq.Popover.Dropdown,{onMouseDown:e=>e.preventDefault(),"data-dates-dropdown":!0,ref:z,children:(0,l.jsx)(rV,{__staticSelector:"DateInput",...H,classNames:D,styles:R,unstyled:T,__preventFocus:!0,minDate:m,maxDate:v,locale:p,getDayProps:e=>({...h?.(e),selected:(0,i$.default)(K).isSame(e,"day"),onClick:t=>{h?.(e).onClick?.(t);let n=U&&(0,i$.default)(K).isSame(e,"day")?null:e;Y(n),!Z&&n&&ee(q(n)),V(!1)}}),size:n.size,date:X,onDateChange:J,getMonthControlProps:e=>({selected:"string"==typeof K&&rx(e,K),...L?.(e)}),getYearControlProps:e=>({selected:"string"==typeof K&&(0,i$.default)(e).isSame(K,"year"),...F?.(e)}),attributes:i.attributes})})]})}),(0,l.jsx)(rG,{name:_,form:k,value:K,type:"default"})]})});r$.classes={...n0.Input.classes,...rV.classes},r$.displayName="@mantine/dates/DateInput",e.s(["DateInput",()=>r$],61426);var rU=e.i(90905),rq=e.i(84584),rK={root:"m_8d3f4000",icon:"m_8d3afb97",loader:"m_302b9fb1",group:"m_1a0f1b21",groupSection:"m_437b6484"};let rY={orientation:"horizontal"},rZ=(0,p.createVarsResolver)((e,{borderWidth:t})=>({group:{"--ai-border-width":(0,g.rem)(t)}})),rX=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("ActionIconGroup",rY,e),{className:i,style:r,classNames:o,styles:a,unstyled:s,orientation:d,vars:u,borderWidth:c,variant:h,mod:p,attributes:f,...g}=(0,v.useProps)("ActionIconGroup",rY,e),m=(0,y.useStyles)({name:"ActionIconGroup",props:n,classes:rK,className:i,style:r,classNames:o,styles:a,unstyled:s,attributes:f,vars:u,varsResolver:rZ,rootSelector:"group"});return(0,l.jsx)(C.Box,{...m("group"),ref:t,variant:h,mod:[{"data-orientation":d},p],role:"group",...g})});rX.classes=rK,rX.displayName="@mantine/core/ActionIconGroup";let rJ=(0,p.createVarsResolver)((e,{radius:t,color:n,gradient:i,variant:r,autoContrast:o,size:a})=>{let s=e.variantColorResolver({color:n||e.primaryColor,theme:e,gradient:i,variant:r||"filled",autoContrast:o});return{groupSection:{"--section-height":(0,f.getSize)(a,"section-height"),"--section-padding-x":(0,f.getSize)(a,"section-padding-x"),"--section-fz":(0,f.getFontSize)(a),"--section-radius":void 0===t?void 0:(0,f.getRadius)(t),"--section-bg":n||r?s.background:void 0,"--section-color":s.color,"--section-bd":n||r?s.border:void 0}}}),rQ=(0,m.factory)((e,t)=>{let n=(0,v.useProps)("ActionIconGroupSection",null,e),{className:i,style:r,classNames:o,styles:a,unstyled:s,vars:d,variant:u,gradient:c,radius:h,autoContrast:p,attributes:f,...g}=n,m=(0,y.useStyles)({name:"ActionIconGroupSection",props:n,classes:rK,className:i,style:r,classNames:o,styles:a,unstyled:s,attributes:f,vars:d,varsResolver:rJ,rootSelector:"groupSection"});return(0,l.jsx)(C.Box,{...m("groupSection"),ref:t,variant:u,...g})});rQ.classes=rK,rQ.displayName="@mantine/core/ActionIconGroupSection";let r0=(0,p.createVarsResolver)((e,{size:t,radius:n,variant:i,gradient:r,color:o,autoContrast:a})=>{let s=e.variantColorResolver({color:o||e.primaryColor,theme:e,gradient:r,variant:i||"filled",autoContrast:a});return{root:{"--ai-size":(0,f.getSize)(t,"ai-size"),"--ai-radius":void 0===n?void 0:(0,f.getRadius)(n),"--ai-bg":o||i?s.background:void 0,"--ai-hover":o||i?s.hover:void 0,"--ai-hover-color":o||i?s.hoverColor:void 0,"--ai-color":s.color,"--ai-bd":o||i?s.border:void 0}}}),r1=(0,rU.polymorphicFactory)((e,t)=>{let n=(0,v.useProps)("ActionIcon",null,e),{className:i,unstyled:r,variant:o,classNames:a,styles:s,style:d,loading:u,loaderProps:c,size:h,color:p,radius:f,__staticSelector:g,gradient:m,vars:b,children:x,disabled:S,"data-disabled":_,autoContrast:k,mod:M,attributes:T,...D}=n,R=(0,y.useStyles)({name:["ActionIcon",g],props:n,className:i,style:d,classes:rK,classNames:a,styles:s,unstyled:r,attributes:T,vars:b,varsResolver:r0});return(0,l.jsxs)(w.UnstyledButton,{...R("root",{active:!S&&!u&&!_}),...D,unstyled:r,variant:o,size:h,disabled:S||u,ref:t,mod:[{loading:u,disabled:S||_},M],children:["boolean"==typeof u&&(0,l.jsx)(eb.Transition,{mounted:u,transition:"slide-down",duration:150,children:e=>(0,l.jsx)(C.Box,{component:"span",...R("loader",{style:e}
230),"aria-hidden":!0,children:(0,l.jsx)(rq.Loader,{color:"var(--ai-color)",size:"calc(var(--ai-size) * 0.55)",...c})})}),(0,l.jsx)(C.Box,{component:"span",mod:{loading:u},...R("icon"),children:x})]})});r1.classes=rK,r1.displayName="@mantine/core/ActionIcon",r1.Group=rX,r1.GroupSection=rQ,e.s(["ActionIcon",()=>r1],83742)},62686,e=>{e.v({label:"index-module-scss-module__4QcxNq__label"})},28935,17236,e=>{"use strict";var t=e.i(48277),n=e.i(46471),i=e.i(61426),r=e.i(21381),o=e.i(30668),a=e.i(77219),s=e.i(1584),l=e.i(24133),d=e.i(36546),u=e.i(83742),c=e.i(88146),h=e.i(12824),p=e.i(36676),f=e.i(79352),g=e.i(91395),m=e.i(20790);function v(e,t){let n=e?(0,r.default)(e):(0,r.default)();if(""===t)return n.format("YYYY-MM-DD HH:mm:ss");let[i,o,a=0]=t.split(":").map(Number);return(n=(n=(n=(n=n.set("hour",i)).set("minute",o)).set("second",a)).set("millisecond",0)).format("YYYY-MM-DD HH:mm:ss")}var y=e.i(565);function b({minDate:e,maxDate:t}){let n=(0,r.default)();return e||t?e&&(0,r.default)(n).isBefore(e)?(0,y.toDateString)(e):t&&(0,r.default)(n).isAfter(t)?(0,y.toDateString)(t):(0,y.toDateString)(n):(0,y.toDateString)(n)}function x(e,t,n){return e||t?e&&(0,r.default)(n).isBefore(e)?(0,y.toDateTimeString)(e):t&&(0,r.default)(n).isAfter(t)?(0,y.toDateTimeString)(t):(0,y.toDateTimeString)(n):(0,y.toDateTimeString)(n)}var w=e.i(39344),C=e.i(73596),S=e.i(90112),_=e.i(20425),k=e.i(56297);function M(e,t){let n=[...t].sort((e,t)=>(0,r.default)(e).isAfter((0,r.default)(t))?1:-1);return(0,r.default)(n[0]).startOf("day").subtract(1,"ms").isBefore(e)&&(0,r.default)(n[1]).endOf("day").add(1,"ms").isAfter(e)}function T({type:e,level:t,value:n,defaultValue:i,onChange:a,allowSingleDateInRange:s,allowDeselect:l,onMouseLeave:d}){let[u,c]=(0,g.useUncontrolledDates)({type:e,value:n,defaultValue:i,onChange:a}),[h,p]=(0,o.useState)("range"===e&&u[0]&&!u[1]?u[0]:null),[f,m]=(0,o.useState)(null),v="range"===e?e=>{d?.(e),m(null)}:d,y="range"===e&&h?m:()=>{};return(0,o.useEffect)(()=>{if("range"===e)if(u[0]&&!u[1])p(u[0]);else{let e=null==u[0]&&null==u[1],t=null!=u[0]&&null!=u[1];(e||t)&&(p(null),m(null))}},[u]),{onDateChange:n=>{if("range"===e){if(h&&!u[1]){if((0,r.default)(n).isSame(h,t)&&!s){p(null),m(null),c([null,null]);return}let e=[n,h];e.sort((e,t)=>(0,r.default)(e).isAfter((0,r.default)(t))?1:-1),c(e),m(null),p(null);return}if(u[0]&&!u[1]&&(0,r.default)(n).isSame(u[0],t)&&!s){p(null),m(null),c([null,null]);return}c([n,null]),m(null),p(n);return}"multiple"===e?u.some(e=>(0,r.default)(e).isSame(n,t))?c(u.filter(e=>!(0,r.default)(e).isSame(n,t))):c([...u,n]):u&&l&&(0,r.default)(n).isSame(u,t)?c(null):c(n)},onRootMouseLeave:v,onHoveredDateChange:y,getControlProps:n=>{if("range"===e)return{selected:u.some(e=>e&&(0,r.default)(e).isSame(n,t)),inRange:h&&f?M(n,[f,h]):!!u[0]&&!!u[1]&&M(n,u),firstInRange:!!u[0]&&!!(0,r.default)(n).isSame(u[0],t)&&!(f&&(0,r.default)(f).isBefore(u[0])),lastInRange:u[1]?(0,r.default)(n).isSame(u[1],t):!!u[0]&&!!f&&(0,r.default)(f).isBefore(u[0])&&(0,r.default)(n).isSame(u[0],t),"data-autofocus":!!u[0]&&(0,r.default)(u[0]).isSame(n,t)||void 0};if("multiple"===e)return{selected:u.some(e=>e&&(0,r.default)(e).isSame(n,t)),"data-autofocus":!!u[0]&&(0,r.default)(u[0]).isSame(n,t)||void 0};let i=(0,r.default)(u).isSame(n,t);return{selected:i,"data-autofocus":i||void 0}},_value:u,setValue:c}}var D=e.i(90370),R=e.i(24831),I={datePickerRoot:"m_765a40cf",presetsList:"m_d6a681e1",presetButton:"m_acd30b22"};let A=(0,C.createVarsResolver)((e,{size:t})=>({datePickerRoot:{"--preset-font-size":(0,S.getFontSize)(t)}})),P={type:"default",defaultLevel:"month",numberOfColumns:1,size:"sm"},E=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("DatePicker",P,e),{allowDeselect:a,allowSingleDateInRange:u,value:c,defaultValue:h,onChange:p,onMouseLeave:f,classNames:g,styles:m,__staticSelector:v,__onDayClick:y,__onDayMouseEnter:b,__onPresetSelect:x,__stopPropagation:C,presets:S,className:M,style:E,unstyled:L,size:F,vars:O,attributes:N,...B}=i,{calendarProps:z,others:j}=(0,w.pickCalendarProps)(B),V=(0,o.useRef)(null),H=(0,o.useRef)(null),G=(0,l.useStyles)({name:v||"DatePicker",classes:I,props:i,className:M,style:E,classNames:g,styles:m,unstyled:L,attributes:N,rootSelector:S?"datePickerRoot":void 0,varsResolver:A,vars:O}),{onDateChange:W,onRootMouseLeave:$,onHoveredDateChange:U,getControlProps:q,_value:K,setValue:Y}=T({type:j.type,level:"day",allowDeselect:a,allowSingleDateInRange:u,value:c,defaultValue:h,onChange:p,onMouseLeave:f}),{resolvedClassNames:Z,resolvedStyles:X}=(0,d.useResolvedStylesApi)({classNames:g,styles:m,props:i}),J=(0,t.jsx)(D.Calendar,{ref:n,classNames:Z,styles:X,__staticSelector:v||"DatePicker",onMouseLeave:$,size:F,...z,...!S?j:{}
230,__stopPropagation:C,__setDateRef:V,__setLevelRef:H,minLevel:z.minLevel||"month",__onDayMouseEnter:(e,t)=>{U(t),b?.(e,t)},__onDayClick:(e,t)=>{W(t),y?.(e,t)},getDayProps:e=>({...q(e),...z.getDayProps?.(e)}),getMonthControlProps:e=>({selected:"string"==typeof K&&(0,R.isSameMonth)(e,K),...z.getMonthControlProps?.(e)}),getYearControlProps:e=>({selected:"string"==typeof K&&(0,r.default)(e).isSame(K,"year"),...z.getYearControlProps?.(e)}),hideOutsideDates:z.hideOutsideDates??1!==z.numberOfColumns,...!S?{className:M,style:E,attributes:N}:{}});if(!S)return J;let Q=S.map((e,n)=>(0,t.jsx)(_.UnstyledButton,{...G("presetButton"),onClick:()=>{var t;let n;void 0!==(n=Array.isArray(t=e.value)?t[0]:t)&&(V.current?.(n),H.current?.("month"),x?x(n):Y(t))},onMouseDown:e=>e.preventDefault(),"data-mantine-stop-propagation":C||void 0,children:e.label},n));return(0,t.jsxs)(k.Box,{...G("datePickerRoot"),size:F,...j,children:[(0,t.jsx)("div",{...G("presetsList"),children:Q}),J]})});E.classes=D.Calendar.classes,E.displayName="@mantine/dates/DatePicker";var L=e.i(99325),F=e.i(1075),O=e.i(44969),N=e.i(70920),B=e.i(14845),z=e.i(52052),j={input:"m_6fa5e2aa"};let V=(0,a.factory)((e,n)=>{let{inputProps:i,wrapperProps:r,placeholder:o,classNames:a,styles:s,unstyled:l,popoverProps:d,modalProps:u,dropdownType:c,children:h,formattedValue:p,dropdownHandlers:f,dropdownOpened:g,onClick:m,clearable:v,onClear:y,clearButtonProps:b,rightSection:x,shouldClear:w,readOnly:C,disabled:S,value:_,name:k,form:M,type:T,onDropdownClose:D,withTime:R,...I}=(0,F.useInputProps)("PickerInputBase",{size:"sm"},e),A=(0,t.jsx)(O.Input.ClearButton,{onClick:y,unstyled:l,...b}),P=()=>{"range"===T&&Array.isArray(_)&&_[0]&&!_[1]&&y(),f.close()};return(0,t.jsxs)(t.Fragment,{children:["modal"===c&&!C&&(0,t.jsx)(N.Modal,{opened:g,onClose:P,withCloseButton:!1,size:"auto","data-dates-modal":!0,unstyled:l,...u,children:h}),(0,t.jsx)(O.Input.Wrapper,{...r,children:(0,t.jsxs)(B.Popover,{position:"bottom-start",opened:g,trapFocus:!0,returnFocus:!1,unstyled:l,onClose:D,...d,disabled:d?.disabled||"modal"===c||C,onChange:e=>{e||(d?.onClose?.(),P())},children:[(0,t.jsx)(B.Popover.Target,{children:(0,t.jsx)(O.Input,{"data-dates-input":!0,"data-read-only":C||void 0,disabled:S,component:"button",type:"button",multiline:!0,onClick:e=>{m?.(e),f.toggle()},__clearSection:A,__clearable:v&&w&&!C&&!S,rightSection:x,...i,ref:n,classNames:{...a,input:(0,L.default)(j.input,a?.input)},...I,children:p||(0,t.jsx)(O.Input.Placeholder,{error:i.error,unstyled:l,classNames:a,styles:s,__staticSelector:i.__staticSelector,children:o})})}),(0,t.jsx)(B.Popover.Dropdown,{"data-dates-dropdown":!0,children:h})]})}),(0,t.jsx)(z.HiddenDatesInput,{value:_,name:k,form:M,type:T,withTime:R})]})});V.classes=j,V.displayName="@mantine/dates/PickerInputBase";var H=e.i(91805),G=e.i(1199),W=e.i(57472),$=e.i(29);function U(e){return e<10?`0${e}`:`${e}`}let q=(0,o.forwardRef)(({value:e,min:n,max:i,onChange:r,focusable:o,step:a,onNextInput:s,onPreviousInput:l,onFocus:d,readOnly:u,allowTemporaryZero:c=!1,placeholder:h="--",...p},f)=>{let g=Number(i.toFixed(0)[0]),m=i+1-a;return(0,t.jsx)("input",{ref:f,type:"text",role:"spinbutton","aria-valuemin":n,"aria-valuemax":i,"aria-valuenow":null===e?0:e,"data-empty":null===e||void 0,inputMode:"numeric",placeholder:h,value:null===e?"":U(e),onChange:e=>(e=>{if(u)return;let t=e.replace(/\D/g,"");if(""!==t){let o=parseInt(t,10),a=c&&0===o&&n>0?0:(0,$.clamp)(o,n,i);r(a),(a>g||e.startsWith("00"))&&s?.()}})(e.currentTarget.value),onKeyDown:t=>{u||(("0"===t.key||"Num0"===t.key)&&0===e&&(t.preventDefault(),s?.()),"Home"===t.key&&(t.preventDefault(),r(n)),"End"===t.key&&(t.preventDefault(),r(i)),("Backspace"===t.key||"Delete"===t.key)&&(t.preventDefault(),null!==e?r(null):l?.()),"ArrowRight"===t.key&&(t.preventDefault(),s?.()),"ArrowLeft"===t.key&&(t.preventDefault(),l?.()),"ArrowUp"===t.key&&(t.preventDefault(),r(null===e?n:(0,$.clamp)(e+a,n,m))),"ArrowDown"===t.key&&(t.preventDefault(),r(null===e?m:(0,$.clamp)(e-a,n,m))))},onFocus:e=>{e.currentTarget.select(),d?.(e)},onClick:e=>{e.stopPropagation(),e.currentTarget.select()},onMouseDown:e=>e.stopPropagation(),...p})});q.displayName="@mantine/dates/SpinInput";let[K,Y]=(0,e.i(20826).createSafeContext)("TimeInput component was not found in the component tree"),Z=(0,o.forwardRef)(({labels:e,value:n,onChange:i,className:r,style:o,onPreviousInput:a,readOnly:s,onMouseDown:l,onTouchStart:d,inputType:u,...c},h)=>{let p=Y(),f=t=>{s||("Home"===t.key&&(t.preventDefault(),i(e.am)),"End"===t.key&&(t.preventDefault(),i(e.pm)),("Backspace"===t.key||"Delete"===t.key)&&(t.preventDefault(),null===n?a?.():i(null)),"ArrowLeft"===t.key&&(t.preventDefault(),a?.()),("ArrowUp"===t.key||"ArrowDown"===t.key)&&(t.preventDefault(),i(n===e.am?e.pm:e.am)),"KeyA"===t.code&&(t.preventDefault(),i(e.am)),"KeyP"===t.code&&(t.preventDefault(),i(e.pm)))};if("input"===u){let e=n||"--",i=e.length+1;return(0,t.jsx)("input",{...p.getStyles("field",{className:r,style:o}),ref:h,value:e,size:i,readOnly:!0,onChange:()=>{},onClick:e=>e.stopPropagation(),onKeyDown:f,onMouseDown:e=>{e.stopPropagation(),l?.(e)},"data-am-pm":!0,...c})}return(0,t.jsxs)("select",{...p.getStyles("field",{className:r,style:o}),ref:h,value:n||"",onChange:e=>!s&&i(e.target.value||null),onClick:e=>e.stopPropagation(),onKeyDown:f,onMouseDown:e=>{e.stopPropagation(),l?.(e)},"data-am-pm":!0,...c,children:[(0,t.jsx)("option",{value:"",children:"--"}),(0,t.jsx)("option",{value:e.am,children:e.am}),(0,t.jsx)("option",{value:e.pm,children:e.pm})]})});function X({value:e,active:n,onSelect:i}){let r=Y();return(0,t.jsx)(_.UnstyledButton,{mod:{active:n},onClick:()=>i(e),onMouseDown:e=>e.preventDefault(),"data-value":e,tabIndex:-1,...r.getStyles("control"),children:"number"==typeof e?U(e):e})}function J({labels:e,value:n,onSelect:i}){let r=Y(),o=[e.am,e.pm].map(e=>(0,t.jsx)(X,{value:e,active:n===e,onSelect:i},e));return(0,t.jsx)("div",{...r.getStyles("controlsList"),children:o})}Z.displayName="@mantine/dates/AmPmInput",X.displayName="@mantine/dates/TimeControl",J.displayName="@mantine/dates/AmPmControlsList";var Q=e.i(78941);function ee({min:e,max:n,step:i,value:r,onSelect:a,reversed:s}){let l=Y(),d=(0,o.useRef)(null),u=function(e,t,n){let i=[];for(let r=e;r<=t;r+=n)i.push(r);return i}(e,n,i),c=(s?u.reverse():u).map(e=>(0,t.jsx)(X,{value:e,active:r===e,onSelect:a},e));return(0,o.useEffect)(()=>{null!==r&&requestAnimationFrame(()=>{let e=d.current?.querySelector(`[data-value="${r}"]`);!function(e,t){if(!e||!t)return!1;let n=e.getBoundingClientRect(),i=t.getBoundingClientRect();return n.top>=i.top&&n.bottom<=i.bottom&&n.left>=i.left&&n.right<=i.right}(e,d.current)&&e?.scrollIntoView({block:"nearest"})})},[r]),(0,t.jsx)(Q.ScrollArea,{h:l.maxDropdownContentHeight,type:"never",viewportRef:d,...l.getStyles("scrollarea"),...l.scrollAreaProps,children:(0,t.jsx)("div",{...l.getStyles("controlsList"),children:c})})}ee.displayName="@mantine/dates/TimeControlsList";var et={fieldsRoot:"m_7a8f1e6d",fieldsGroup:"m_d6bb0a54",controlsList:"m_b97ecb26",controlsListGroup:"m_31fe42f9",dropdown:"m_9c4817c3",control:"m_154c536b",presetControl:"m_7be09d0c",presetsGroup:"m_7d00001d",presetsGroupLabel:"m_d8d918d7",field:"m_6b43ba88"},en=e.i(52487),ei={container:"m_925c2d2c",root:"m_2415a157"}
230,er=e.i(87481),eo=e.i(27395),ea=e.i(78720),es=e.i(85250),el=e.i(55227),ed=e.i(11920),eu=e.i(12493);function ec({spacing:e,verticalSpacing:n,cols:i,selector:r}){let o=(0,ed.useMantineTheme)(),a=void 0===n?e:n,s=(0,ea.filterProps)({"--sg-spacing-x":(0,S.getSpacing)((0,el.getBaseValue)(e)),"--sg-spacing-y":(0,S.getSpacing)((0,el.getBaseValue)(a)),"--sg-cols":(0,el.getBaseValue)(i)?.toString()}),l=(0,er.keys)(o.breakpoints).reduce((t,n)=>(t[n]||(t[n]={}),"object"==typeof e&&void 0!==e[n]&&(t[n]["--sg-spacing-x"]=(0,S.getSpacing)(e[n])),"object"==typeof a&&void 0!==a[n]&&(t[n]["--sg-spacing-y"]=(0,S.getSpacing)(a[n])),"object"==typeof i&&void 0!==i[n]&&(t[n]["--sg-cols"]=i[n]),t),{}),d=(0,es.getSortedBreakpoints)((0,er.keys)(l),o.breakpoints).filter(e=>(0,er.keys)(l[e.value]).length>0).map(e=>({query:`(min-width: ${o.breakpoints[e.value]})`,styles:l[e.value]}));return(0,t.jsx)(eu.InlineStyles,{styles:s,media:d,selector:r})}function eh(e){return"object"==typeof e&&null!==e?(0,er.keys)(e):[]}function ep({spacing:e,verticalSpacing:n,cols:i,selector:r}){let o=void 0===n?e:n,a=(0,ea.filterProps)({"--sg-spacing-x":(0,S.getSpacing)((0,el.getBaseValue)(e)),"--sg-spacing-y":(0,S.getSpacing)((0,el.getBaseValue)(o)),"--sg-cols":(0,el.getBaseValue)(i)?.toString()}),s=function({spacing:e,verticalSpacing:t,cols:n}){return Array.from(new Set([...eh(e),...eh(t),...eh(n)])).sort((e,t)=>(0,eo.px)(e)-(0,eo.px)(t))}({spacing:e,verticalSpacing:n,cols:i}),l=s.reduce((t,n)=>(t[n]||(t[n]={}),"object"==typeof e&&void 0!==e[n]&&(t[n]["--sg-spacing-x"]=(0,S.getSpacing)(e[n])),"object"==typeof o&&void 0!==o[n]&&(t[n]["--sg-spacing-y"]=(0,S.getSpacing)(o[n])),"object"==typeof i&&void 0!==i[n]&&(t[n]["--sg-cols"]=i[n]),t),{}),d=s.map(e=>({query:`simple-grid (min-width: ${e})`,styles:l[e]}));return(0,t.jsx)(eu.InlineStyles,{styles:a,container:d,selector:r})}let ef={cols:1,spacing:"md",type:"media"},eg=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("SimpleGrid",ef,e),{classNames:r,className:o,style:a,styles:d,unstyled:u,vars:c,cols:h,verticalSpacing:p,spacing:f,type:g,attributes:m,...v}=i,y=(0,l.useStyles)({name:"SimpleGrid",classes:ei,props:i,className:o,style:a,classNames:r,styles:d,unstyled:u,attributes:m,vars:c}),b=(0,en.useRandomClassName)();return"container"===g?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(ep,{...i,selector:`.${b}`}),(0,t.jsx)("div",{...y("container"),children:(0,t.jsx)(k.Box,{ref:n,...y("root",{className:b}),...v})})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(ec,{...i,selector:`.${b}`}),(0,t.jsx)(k.Box,{ref:n,...y("root",{className:b}),...v})]})});function em(e){let[t=null,n=null,i=null]=e.split(":").map(Number);return{hours:t,minutes:n,seconds:i}}function ev({time:e,compare:t,withSeconds:n}){let i=em(e),r=em(t);return n?i.hours===r.hours&&i.minutes===r.minutes&&i.seconds===r.seconds:i.hours===r.hours&&i.minutes===r.minutes}function ey({value:e,format:n="24h",amPmLabels:i={am:"AM",pm:"PM"},withSeconds:r=!1}){return(0,t.jsx)(t.Fragment,{children:function({value:e,format:t,amPmLabels:n,withSeconds:i}){let r=em("string"==typeof e?e:`${e.getHours()}:${e.getMinutes()}${i?`:${e.getSeconds()}`:""}`);if(null===r.hours||null===r.minutes)return null;if("24h"===t)return`${U(r.hours)}:${U(r.minutes)}${i?`:${U(r.seconds||0)}`:""}`;let o=r.hours>=12,a=r.hours%12==0?12:r.hours%12;return`${a}:${U(r.minutes)}${i?`:${U(r.seconds||0)}`:""} ${o?n.pm:n.am}`}({value:e,format:n,amPmLabels:i,withSeconds:r})})}function eb({value:e,active:n,onChange:i,format:r,amPmLabels:o,withSeconds:a}){let s=Y();return(0,t.jsx)(_.UnstyledButton,{mod:{active:n},onClick:()=>i(e),...s.getStyles("presetControl"),children:(0,t.jsx)(ey,{withSeconds:a,value:e,format:r,amPmLabels:o})})}function ex({value:e,data:n,onChange:i,format:r,amPmLabels:o,withSeconds:a}){let s=Y(),l=n.values.map(n=>(0,t.jsx)(eb,{value:n,format:r,amPmLabels:o,withSeconds:a,active:ev({time:n,compare:e,withSeconds:a}),onChange:i},n));return(0,t.jsxs)("div",{...s.getStyles("presetsGroup"),children:[(0,t.jsx)("div",{...s.getStyles("presetsGroupLabel"),children:n.label}),(0,t.jsx)(eg,{cols:a?2:3,spacing:4,children:l})]})}function ew({presets:e,format:n,amPmLabels:i,withSeconds:r,value:o,onChange:a}){let s=Y();if(0===e.length)return null;if("string"==typeof e[0]){let l=e.map(e=>(0,t.jsx)(eb,{value:e,format:n,amPmLabels:i,withSeconds:r,active:ev({time:e,compare:o,withSeconds:r}),onChange:a},e));return(0,t.jsx)(Q.ScrollArea.Autosize,{mah:s.maxDropdownContentHeight,type:"never",...s.getStyles("scrollarea"),...s.scrollAreaProps,children:(0,t.jsx)("div",{...s.getStyles("presetsRoot"),children:(0,t.jsx)(eg,{c
230ols:r?2:3,spacing:4,children:l})})})}let l=e.map((e,s)=>(0,t.jsx)(ex,{data:e,value:o,format:n,amPmLabels:i,withSeconds:r,onChange:a},s));return(0,t.jsx)(Q.ScrollArea.Autosize,{mah:s.maxDropdownContentHeight,type:"never",...s.getStyles("scrollarea"),...s.scrollAreaProps,children:(0,t.jsx)("div",{...s.getStyles("presetsRoot"),children:l})})}function eC(e){let[t=0,n=0,i=0]=e.split(":").map(Number);return 3600*t+60*n+i}function eS(e,t,n){var i;let r,o,a,s=eC(e);return r=Math.floor((i=Math.max(t?eC(t):-1/0,Math.min(s,n?eC(n):1/0)))/3600),o=Math.floor(i%3600/60),a=i%60,{timeString:`${U(r)}:${U(o)}:${U(a)}`,hours:r,minutes:o,seconds:a}}function e_({time:e,format:t,amPmLabels:n}){if(""===e)return{hours:null,minutes:null,seconds:null,amPm:null};let{hours:i,minutes:r,seconds:o}=em(e),a={hours:i,minutes:r,seconds:o};return"12h"===t?function({hours:e,minutes:t,seconds:n,amPmLabels:i}){if(null===e)return{hours:null,minutes:null,seconds:null,amPm:null};let r=e>=12?i.pm:i.am;return{hours:e%12==0?12:e%12,minutes:"number"==typeof t?t:null,seconds:"number"==typeof n?n:null,amPm:r}}({...a,amPmLabels:n}):{...a,amPm:null}}function ek({hours:e,minutes:t,seconds:n,format:i,withSeconds:r,amPm:o,amPmLabels:a}){return null===e||null===t||r&&null===n?{valid:!1,value:""}:"24h"===i?{valid:!0,value:`${U(e)}:${U(t)}${r?`:${U(n)}`:""}`}:null===o?{valid:!1,value:""}:{valid:!0,value:function({hours:e,minutes:t,seconds:n,amPm:i,amPmLabels:r,withSeconds:o}){let a=e;return i===r.pm&&12!==e?a+=12:i===r.am&&12===e&&(a=0),`${U(a)}:${U(t)}${o?`:${U(n||0)}`:""}`}({hours:e,minutes:t,seconds:n,amPm:o,amPmLabels:a,withSeconds:r})}}eg.classes=ei,eg.displayName="@mantine/core/SimpleGrid",e.s(["SimpleGrid",()=>eg],17236),ey.displayName="@mantine/dates/TimeValue",eb.displayName="@mantine/dates/TimePresetControl",ex.displayName="@mantine/dates/TimePresetGroup",ew.displayName="@mantine/dates/TimePresets";let eM={hoursStep:1,minutesStep:1,secondsStep:1,format:"24h",amPmLabels:{am:"AM",pm:"PM"},pasteSplit:e_,maxDropdownContentHeight:200,hoursPlaceholder:"--",minutesPlaceholder:"--",secondsPlaceholder:"--"},eT=(0,C.createVarsResolver)((e,{size:t})=>({dropdown:{"--control-font-size":(0,S.getFontSize)(t)}})),eD=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("TimePicker",eM,e),{classNames:r,className:a,style:u,styles:c,unstyled:p,vars:g,onClick:m,format:v,value:y,defaultValue:b,onChange:x,hoursStep:w,minutesStep:C,secondsStep:S,withSeconds:_,hoursInputLabel:k,minutesInputLabel:M,secondsInputLabel:T,amPmInputLabel:D,amPmLabels:R,clearable:I,onMouseDown:A,onFocusCapture:P,onBlurCapture:E,min:L,max:F,popoverProps:O,withDropdown:N,rightSection:z,onFocus:j,onBlur:V,clearButtonProps:$,hoursInputProps:U,minutesInputProps:Y,secondsInputProps:X,amPmSelectProps:Q,readOnly:en,disabled:ei,size:er,name:eo,form:ea,hiddenInputProps:es,labelProps:el,pasteSplit:ed,hoursRef:eu,minutesRef:ec,secondsRef:eh,amPmRef:ep,presets:ef,maxDropdownContentHeight:eg,scrollAreaProps:em,attributes:ev,reverseTimeControlsList:ey,hoursPlaceholder:eb,minutesPlaceholder:ex,secondsPlaceholder:eC,...eD}=i,{resolvedClassNames:eR,resolvedStyles:eI}=(0,d.useResolvedStylesApi)({classNames:r,styles:c,props:i}),eA=(0,l.useStyles)({name:"TimePicker",classes:et,props:i,className:a,style:u,classNames:r,styles:c,unstyled:p,attributes:ev,vars:g,varsResolver:eT}),eP=function({value:e,defaultValue:t,onChange:n,format:i,amPmLabels:r,withSeconds:a=!1,min:s,max:l,clearable:d,readOnly:u,disabled:c,pasteSplit:h}){let p=e_({time:e||t||"",amPmLabels:r,format:i}),g=ek({hours:p.hours,minutes:p.minutes,seconds:p.seconds,format:i,withSeconds:a,amPm:p.amPm,amPmLabels:r}),m=(0,o.useRef)(!0),v=(0,o.useRef)(!g.valid),[y,b]=(0,o.useState)(p.hours),[x,w]=(0,o.useState)(p.minutes),[C,S]=(0,o.useState)(p.seconds),[_,k]=(0,o.useState)(p.amPm),M=d&&!u&&!c&&(null!==y||null!==x||null!==C||null!==_),T=(0,o.useRef)(null),D=(0,o.useRef)(null),R=(0,o.useRef)(null),I=(0,o.useRef)(null),A=e=>{"hours"===e&&T.current?.focus(),"minutes"===e&&D.current?.focus(),"seconds"===e&&R.current?.focus(),"amPm"===e&&I.current?.focus()},P=(e,t)=>{let o=ek({...{hours:y,minutes:x,seconds:C,amPm:_,[e]:t},format:i,withSeconds:a,amPmLabels:r});o.valid?(m.current=!1,v.current=!1,"hours"===e&&b(t),"minutes"===e&&w(t),"seconds"===e&&S(t),"amPm"===e&&k(t),n?.(o.value)):(m.current=!1,v.current||(n?.(""),v.current=!0))},E=ek({hours:y,minutes:x,seconds:C,format:i,withSeconds:a,amPm:_,amPmLabels:r});return(0,f.useDidUpdate)(()=>
230{if(""===e){m.current=!1,b(null),w(null),S(null),k(null),m.current=!0;return}if(m.current&&"string"==typeof e){let t=e_({time:e||"",amPmLabels:r,format:i});b(t.hours),w(t.minutes),S(t.seconds),k(t.amPm)}m.current=!0},[e]),{refs:{hours:T,minutes:D,seconds:R,amPm:I},values:{hours:y,minutes:x,seconds:C,amPm:_},setHours:e=>{let t=e;"12h"===i&&"number"==typeof e&&e>12&&(t=(e-1)%12+1),b(t),P("hours",t),A("hours")},setMinutes:e=>{w(e),P("minutes",e),A("minutes")},setSeconds:e=>{S(e),P("seconds",e),A("seconds")},setAmPm:e=>{k(e),P("amPm",e),A("amPm")},focus:A,clear:()=>{m.current=!1,b(null),w(null),S(null),k(null),n?.(""),v.current=!0,A("hours")},onPaste:e=>{e.preventDefault();let t=(h||e_)({time:e.clipboardData.getData("text"),format:i,amPmLabels:r}),o=ek({...t,format:i,withSeconds:a,amPmLabels:r});if(o.valid){m.current=!1;let e=eS(o.value,s||"00:00:00",l||"23:59:59");n?.(e.timeString),b(t.hours),w(t.minutes),S(t.seconds),k(t.amPm)}},setTimeString:e=>{m.current=!1;let t=e_({time:e,amPmLabels:r,format:i});b(t.hours),w(t.minutes),S(t.seconds),k(t.amPm),v.current=!ek({...t,format:i,withSeconds:a,amPmLabels:r}).valid,n?.(e)},isClearable:M,hiddenInputValue:E.value}}({value:y,defaultValue:b,onChange:x,format:v,amPmLabels:R,withSeconds:_,min:L,max:F,clearable:I,disabled:ei,readOnly:en,pasteSplit:ed}),eE=(0,h.useMergedRef)(eP.refs.hours,eu),eL=(0,h.useMergedRef)(eP.refs.minutes,ec),eF=(0,h.useMergedRef)(eP.refs.seconds,eh),eO=(0,h.useMergedRef)(eP.refs.amPm,ep),eN=(0,W.useId)(),eB=(0,o.useRef)(!1),[ez,ej]=(0,o.useState)(!1),eV=e=>{eB.current||(eB.current=!0,j?.(e))};return(0,t.jsx)(K,{value:{getStyles:eA,scrollAreaProps:em,maxDropdownContentHeight:eg},children:(0,t.jsxs)(B.Popover,{opened:ez,transitionProps:{duration:0},position:"bottom-start",withRoles:!1,disabled:ei||en||!N,...O,children:[(0,t.jsx)(B.Popover.Target,{children:(0,t.jsxs)(H.InputBase,{component:"div",size:er,disabled:ei,ref:n,onClick:e=>{m?.(e),eP.focus("hours")},onMouseDown:e=>{e.preventDefault(),A?.(e)},onFocusCapture:e=>{ej(!0),P?.(e)},onBlurCapture:e=>{ej(!1),E?.(e)},rightSection:z||eP.isClearable&&(0,t.jsx)(G.CloseButton,{...$,size:er,onClick:e=>{eP.clear(),$?.onClick?.(e)},onMouseDown:e=>{e.preventDefault(),$?.onMouseDown?.(e)}}),labelProps:{htmlFor:eN,...el},style:u,className:a,classNames:eR,styles:eI,__staticSelector:"TimePicker",...eD,children:[(0,t.jsx)("div",{...eA("fieldsRoot"),dir:"ltr",children:(0,t.jsxs)("div",{...eA("fieldsGroup"),onBlur:e=>{if(!e.currentTarget.contains(e.relatedTarget)){let t=ek({...eP.values,format:v,amPmLabels:R,withSeconds:!!_});if(t.valid&&(L||F)){let e=eS(t.value,L,F);e.timeString!==t.value&&eP.setTimeString(e.timeString)}eB.current=!1,V?.(e)}},children:[(0,t.jsx)(q,{id:eN,...U,...eA("field",{className:U?.className,style:U?.style}),value:eP.values.hours,onChange:eP.setHours,onNextInput:()=>eP.focus("minutes"),min:+("12h"===v),max:"12h"===v?12:23,allowTemporaryZero:"12h"===v,focusable:!0,step:w,ref:eE,"aria-label":k,readOnly:en,disabled:ei,onPaste:eP.onPaste,onFocus:e=>{eV(e),U?.onFocus?.(e)},onBlur:e=>{let t=e.currentTarget.value,n=t?parseInt(t,10):null;"12h"===v&&0===n&&eP.setHours(12),U?.onBlur?.(e)},placeholder:eb}),(0,t.jsx)("span",{children:":"}),(0,t.jsx)(q,{...Y,...eA("field",{className:Y?.className,style:Y?.style}),value:eP.values.minutes,onChange:eP.setMinutes,min:0,max:59,focusable:!0,step:C,ref:eL,onPreviousInput:()=>eP.focus("hours"),onNextInput:()=>_?eP.focus("seconds"):eP.focus("amPm"),"aria-label":M,tabIndex:-1,readOnly:en,disabled:ei,onPaste:eP.onPaste,onFocus:e=>{eV(e),Y?.onFocus?.(e)},placeholder:ex}),_&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("span",{children:":"}),(0,t.jsx)(q,{...X,...eA("field",{className:X?.className,style:X?.style}),value:eP.values.seconds,onChange:eP.setSeconds,min:0,max:59,focusable:!0,step:S,ref:eF,onPreviousInput:()=>eP.focus("minutes"),onNextInput:()=>eP.focus("amPm"),"aria-label":T,tabIndex:-1,readOnly:en,disabled:ei,onPaste:eP.onPaste,onFocus:e=>{eV(e),X?.onFocus?.(e)},placeholder:eC})]}),"12h"===v&&(0,t.jsx)(Z,{...Q,inputType:N?"input":"select",labels:R,value:eP.values.amPm,onChange:eP.setAmPm,ref:eO,"aria-label":D,onPreviousInput:()=>_?eP.focus("seconds"):eP.focus("minutes"),readOnly:en,disabled:ei,tabIndex:-1,onPaste:eP.onPaste,onFocus:e=>{eV(e),Q?.onFocus?.(e)}})]})}),(0,t.jsx)("input",{type:"hidden",name:eo,form:ea,value:eP.hiddenInputValue,...es})]})}),(0,t.jsx)(B.Popover.Dropdown,{...eA("dropdown"),onMouseDown:e=>e.preventDefault(),children:ef?(0,t.jsx)(ew,{value:eP.hiddenInputValue,onChange:eP.setTimeString,format:v,presets:ef,amPmLabels:R,withSeconds:_||!1}):(0,t.jsxs)("div",{...eA("controlsListGroup"),children:[(0,t.jsx)(ee,{min:+("12h"===v),max:"12h"===v?12:23,step:w,value:eP.values.hours,onSelect:eP.setHours,reversed:ey}),(0,t.jsx)(ee,{min:0,max:59,step:C,value:eP.values.minutes,onSelect:eP.setMinutes,reversed:ey}),_&&(0,t.jsx)(ee,{min:0,max:59,step:S,value:eP.values.seconds,onSelect:eP.setSeconds,reversed:ey}),"12h"===v&&(0,t.jsx)(J,{labels:R,value:eP.values.amPm,onSelect:eP.setAmPm})]})})]})})});eD.displayName="@mantine/dates/TimePicker",eD.classes=et;var eR={timeWrapper:"m_208d2562",timeInput:"m_62ee059"};let eI={dropdownType:"popover",size:"sm"},eA=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("DateTimePicker",eI,e),{value:a,defaultValue:y,onChange:C,valueFormat:S,locale:_,classNames:k,styles:M,unstyled:T,timePickerProps:D,submitButtonProps:R,withSeconds:I,level:A,defaultLevel:P,size:L,variant:F,dropdownType:O,vars:N,minDate:B,maxDate:z,defaultDate:j,defaultTimeValue:H,presets:G,attributes:W,onDropdownClose:$,...U}=i,q=(0,l.useStyles)({name:"DateTimePicker",classes:eR,props:i,classNames:k,styles:M,unstyled:T,attributes:W,vars:N}),{resolvedClassNames:K,resolvedStyles:Y}=(0,d.useResolvedStylesApi)({classNames:k,styles:M,props:i}),Z=(0,o.useRef)(null),X=(0,h.useMergedRef)(Z,D?.hoursRef),{calendarProps:{allowSingleDateInRange:J,...Q},others:ee}=(0,w.pickCalendarProps)(U),et=(0,m.useDatesContext)(),[en,ei]=(0,g.useUncontrolledDates)({type:"default",value:a,defaultValue:y,onChange:C,withTime:!0}),er=j||en,eo=e=>e?(0,r.default)(e).format(I?"HH:mm:ss":"HH:mm"):"",[ea,es]=(0,o.useState)(H||eo(en)),[el,ed]=(0,o.useState)(A||P||"month"),[eu,ec]=(0,p.useDisclosure)(!1),eh=en?(0,r.default)(en).locale(et.getLocale(_)).format(S||(I?"DD/MM/YYYY HH:mm:ss":"DD/MM/YYYY HH:mm")):"";(0,f.useDidUpdate)(()=>{eu||es(eo(en))},[en,eu]),(0,f.useDidUpdate)(()=>{eu&&ed("month")},[eu]);let ep="popover"===O,ef=()=>{let e=x(B,z,en);en&&en!==e&&ei(x(B,z,en)),$?.()};return(0,t.jsxs)(V,{formattedValue:eh,dropdownOpened:!U.disabled&&eu,dropdownHandlers:ec,classNames:K,styles:Y,unstyled:T,ref:n,onClear:()=>ei(null),shouldClear:!!en,value:en,size:L,variant:F,dropdownType:O,...ee,type:"default",__staticSelector:"DateTimePicker",onDropdownClose:ef,withTime:!0,attributes:W,children:[(0,t.jsx)(E,{...Q,maxDate:z,minDate:B,size:L,variant:F,type:"default",value:en,defaultDate:er||b({maxDate:z,minDate:B}),onChange:e=>{e&&ei(v(x(B,z,e),ea||H||"")),Z.current?.focus()},locale:_,classNames:K,styles:Y,unstyled:T,__staticSelector:"DateTimePicker",__stopPropagation:ep,level:A,defaultLevel:P,onLevelChange:e=>{ed(e),Q.onLevelChange?.(e)},presets:G,__onPresetSelect:e=>{ei(e),e&&es(eo(e))},attributes:W}),"month"===el&&(0,t.jsxs)("div",{...q("timeWrapper"),children:[(0,t.jsx)(eD,{value:ea,withSeconds:I,unstyled:T,min:function({minDate:e,value:t}){let n=e?(0,r.default)(e).format("HH:mm:ss"):null;return t&&e&&t===e&&null!=n?n:void 0}({minDate:B,value:en}),max:function({maxDate:e,value:t}){let n=e?(0,r.default)(e).format("HH:mm:ss"):null;return t&&e&&t===e&&null!=n?n:void 0}({maxDate:z,value:en}),...D,...q("timeInput",{className:D?.className,style:D?.style}),onChange:e=>{D?.onChange?.(e),es(e),e&&ei(v(en,e))},onKeyDown:e=>{"Enter"===e.key&&(e.preventDefault(),ec.close())},size:L,"data-mantine-stop-propagation":ep||void 0,hoursRef:X,attributes:W}),(0,t.jsx)(u.ActionIcon,{variant:"default",size:`input-${L||"sm"}`,...q("submitButton",{className:R?.className,style:R?.style}),unstyled:T,"data-mantine-stop-propagation":ep||void 0,children:(0,t.jsx)(c.CheckIcon,{size:"30%"}),...R,onClick:e=>{R?.onClick?.(e),ec.close(),ef()}})]})]})});function eP({type:e,value:t,defaultValue:n,onChange:i,locale:o,format:a,closeOnChange:s,sortDates:l,labelSeparator:d,valueFormatter:u}){let c=(0,m.useDatesContext)(),[h,f]=(0,p.useDisclosure)(!1),[v,y]=(0,g.useUncontrolledDates)({type:e,value:t,defaultValue:n,onChange:i}),b=function({formatter:e,...t}){return(e||function({type:e,date:t,locale:n,format:i,labelSeparator:o}){let a=e=>(0,r.default)(e).locale(n).format(i);if("default"===e)return null===t?"":a(t);if("multiple"===e)return t.map(a).join(", ");
230if("range"===e&&Array.isArray(t)){if(t[0]&&t[1])return`${a(t[0])} ${o} ${a(t[1])}`;if(t[0])return`${a(t[0])} ${o} `}return""})(t)}({type:e,date:v,locale:c.getLocale(o),format:a,labelSeparator:c.getLabelSeparator(d),formatter:u}),x=t=>{s&&("default"===e&&f.close(),"range"===e&&t[0]&&t[1]&&f.close()),l&&"multiple"===e?y([...t].sort((e,t)=>(0,r.default)(e).isAfter((0,r.default)(t))?1:-1)):y(t)},w="range"===e?!!v[0]:"multiple"===e?v.length>0:null!==v;return{_value:v,setValue:x,onClear:()=>x("range"===e?[null,null]:"multiple"===e?[]:null),shouldClear:w,formattedValue:b,dropdownOpened:h,dropdownHandlers:f}}eA.classes={...eR,...V.classes,...E.classes},eA.displayName="@mantine/dates/DateTimePicker";let eE={type:"default"},eL=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("MonthPicker",eE,e),{classNames:r,styles:o,vars:a,type:l,defaultValue:u,value:c,onChange:h,__staticSelector:p,getMonthControlProps:f,allowSingleDateInRange:g,allowDeselect:m,onMouseLeave:v,onMonthSelect:y,__updateDateOnMonthSelect:b,onLevelChange:x,...w}=i,{onDateChange:C,onRootMouseLeave:S,onHoveredDateChange:_,getControlProps:k}=T({type:l,level:"month",allowDeselect:m,allowSingleDateInRange:g,value:c,defaultValue:u,onChange:h,onMouseLeave:v}),{resolvedClassNames:M,resolvedStyles:R}=(0,d.useResolvedStylesApi)({classNames:r,styles:o,props:i});return(0,t.jsx)(D.Calendar,{ref:n,minLevel:"year",__updateDateOnMonthSelect:b??!1,__staticSelector:p||"MonthPicker",onMouseLeave:S,onMonthMouseEnter:(e,t)=>_(t),onMonthSelect:e=>{C(e),y?.(e)},getMonthControlProps:e=>({...k(e),...f?.(e)}),classNames:M,styles:R,onLevelChange:x,...w})});eL.classes=D.Calendar.classes,eL.displayName="@mantine/dates/MonthPicker";let eF={type:"default",valueFormat:"MMMM YYYY",closeOnChange:!0,sortDates:!0,dropdownType:"popover"},eO=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("MonthPickerInput",eF,e),{type:r,value:o,defaultValue:a,onChange:l,valueFormat:u,labelSeparator:c,locale:h,classNames:p,styles:f,unstyled:g,closeOnChange:m,size:v,variant:y,dropdownType:x,sortDates:C,minDate:S,maxDate:_,vars:k,valueFormatter:M,attributes:T,...D}=i,{resolvedClassNames:R,resolvedStyles:I}=(0,d.useResolvedStylesApi)({classNames:p,styles:f,props:i}),{calendarProps:A,others:P}=(0,w.pickCalendarProps)(D),{_value:E,setValue:L,formattedValue:F,dropdownHandlers:O,dropdownOpened:N,onClear:B,shouldClear:z}=eP({type:r,value:o,defaultValue:a,onChange:l,locale:h,format:u,labelSeparator:c,closeOnChange:m,sortDates:C,valueFormatter:M});return(0,t.jsx)(V,{formattedValue:F,dropdownOpened:N,dropdownHandlers:O,classNames:R,styles:I,unstyled:g,ref:n,onClear:B,shouldClear:z,value:E,size:v,variant:y,dropdownType:x,...P,attributes:T,type:r,__staticSelector:"MonthPickerInput",children:(0,t.jsx)(eL,{...A,size:v,variant:y,type:r,value:E,defaultDate:A.defaultDate||(Array.isArray(E)?E[0]||b({maxDate:_,minDate:S}):E||b({maxDate:_,minDate:S})),onChange:L,locale:h,classNames:R,styles:I,unstyled:g,__staticSelector:"MonthPickerInput",__stopPropagation:"popover"===x,minDate:S,maxDate:_,attributes:T})})});eO.classes={...V.classes,...eL.classes},eO.displayName="@mantine/dates/MonthPickerInput";let eN={type:"default"},eB=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("YearPicker",eN,e),{classNames:r,styles:o,vars:a,type:l,defaultValue:u,value:c,onChange:h,__staticSelector:p,getYearControlProps:f,allowSingleDateInRange:g,allowDeselect:m,onMouseLeave:v,onYearSelect:y,__updateDateOnYearSelect:b,...x}=i,{onDateChange:w,onRootMouseLeave:C,onHoveredDateChange:S,getControlProps:_}=T({type:l,level:"year",allowDeselect:m,allowSingleDateInRange:g,value:c,defaultValue:u,onChange:h,onMouseLeave:v}),{resolvedClassNames:k,resolvedStyles:M}=(0,d.useResolvedStylesApi)({classNames:r,styles:o,props:i});return(0,t.jsx)(D.Calendar,{ref:n,minLevel:"decade",__updateDateOnYearSelect:b??!1,__staticSelector:p||"YearPicker",onMouseLeave:C,onYearMouseEnter:(e,t)=>S(t),onYearSelect:e=>{w(e),y?.(e)},getYearControlProps:e=>({..._(e),...f?.(e)}),classNames:k,styles:M,...x})});eB.classes=D.Calendar.classes,eB.displayName="@mantine/dates/YearPicker";let ez={type:"default",valueFormat:"YYYY",closeOnChange:!0,sortDates:!0,dropdownType:"popover"},ej=(0,a.factory)((e,n)=>{let i=(0,s.useProps)("YearPickerInput",ez,e),{type:r,value:o,defaultValue:a,onChange:l,valueFormat:u,labelSeparator:c,locale:h,classNames:p,styles:f,unstyled:g,closeOnChange:m,size:v,variant:y,dropdownType:x,sortDates:C,minDate:S,maxDate:_,vars:k,valueFormatter:M,attributes:T,...D}=i,{resolvedClassNames:R,resolvedStyles:I}=(0,d.useResolvedStylesApi)({classNames:p,styles:f,props:i}),{calendarProps:A,others:P}=(0,w.pickCalendarProps)(D),{_value:E,setValue:L,formattedValue:F,dropdownHandlers:O,dropdownOpened:N,onClear:B,shouldClear:z}=eP({type:r,value:o,defaultValue:a,onChange:l,locale:h,format:u,labelSeparator:c,closeOnChange:m,sortDates:C,valueFormatter:M});return(0,t.jsx)(V,{formattedValue:F,dropdownOpened:N,dropdownHandlers:O,classNames:R,styles:I,unstyled:g,ref:n,onClear:B,shouldClear:z,value:E,size:v,variant:y,dropdownType:x,...P,type:r,__staticSelector:"YearPickerInput",attributes:T,children:(0,t.jsx)(eB,{...A,size:v,variant:y,type:r,value:E,defaultDate:A.defaultDate||(Array.isArray(E)?E[0]||b({maxDate:_,minDate:S}):E||b({maxDate:_,minDate:S})),onChange:L,locale:h,classNames:R,styles:I,unstyled:g,__staticSelector:"YearPickerInput",__stopPropagation:"popover"===x,minDate:S,maxDate:_,attributes:T})})});ej.classes={...V.classes,...eB.classes},ej.displayName="@mantine/dates/YearPickerInput";var eV=e.i(90388),eH=e.i(60872),eG=e.i(79908),eW=e.i(62686),e$=e.i(42993),eU=e.i(86824),eq=e.i(1920);e.s(["Date",0,({name:e,label:r,required:o,errors:a,width:s,readonly:l,control:d,withTime:u,selectLevel:c,placeholder:h,tooltip:p})=>{let{tenant:f}=(0,eV.useTenant)(),{t:g}=(0,eG.useTranslations)();return(0,t.jsx)(e$.Width,{width:s,children:(0,t.jsx)(n.Controller,{name:e,control:d,rules:{required:o},render:({field:n})=>{let s=n.value?new globalThis.Date(n.value):null,d=c||(u?"time":"day"),m={readOnly:l,withAsterisk:o,classNames:{label:eW.default.label},rightSection:(0,t.jsx)(eq.default,{}),size:"md",highlightToday:!0,radius:(0,eH.getRadius)(f.Theme?.borderRadius),popoverProps:{radius:(0,eH.getRadius)(f.Theme?.borderRadius)},label:(0,t.jsxs)(t.Fragment,{children:[r,(0,t.jsx)(eU.FieldTooltip,{tooltip:p})]}),error:o&&a[e]&&g("fieldRequired"),placeholder:h||("year"===d?g("selectYear"):"month"===d?g("selectMonth"):"time"===d||u?g("selectDateTime"):g("selectDate")),value:s,onChange:e=>{e?n.onChange(new globalThis.Date(e).toISOString()):n.onChange("")}};return"time"===d||u?(0,t.jsx)(eA,{...m,valueFormat:"DD-MM-YYYY HH:mm",onChange:e=>{e?n.onChange(new globalThis.Date(e).toISOString()):n.onChange("")}}):"year"===d?(0,t.jsx)(ej,{...m,valueFormat:"YYYY",onChange:e=>{e?n.onChange(new globalThis.Date(e).toISOString()):n.onChange("")}}):"month"===d?(0,t.jsx)(eO,{...m,valueFormat:"MM-YYYY",onChange:e=>{e?n.onChange(new globalThis.Date(e).toISOString()):n.onChange("")}}):(0,t.jsx)(i.DateInput,{...m,valueFormat:"DD-MM-YYYY",dateParser:e=>{let t=e.split(/[-\/\.]/);if(3===t.length){let e=parseInt(t[0],10),n=parseInt(t[1],10)-1;return new globalThis.Date(parseInt(t[2],10),n,e)}return new globalThis.Date(e)},onChange:e=>{e?n.onChange(new globalThis.Date(e).toISOString()):n.onChange("")}})}})})}],28935)},89789,e=>{e.v({label:"index-module-scss-module__xAAHwG__label"})},64145,e=>{e.v({block:"index-module-scss-module__lUrUqa__block",group:"index-module-scss-module__lUrUqa__group",items:"index-module-scss-module__lUrUqa__items"})},46460,e=>{e.v({grid:"index-module-scss-module__gKeZ_q__grid"})},9559,e=>{e.v({label:"index-module-scss-module__A21zgW__label"})},69271,e=>{e.v({error:"index-module-scss-module__nYtwbG__error",group:"index-module-scss-module__nYtwbG__group",label:"index-module-scss-module__nYtwbG__label",radioLabel:"index-module-scss-module__nYtwbG__radioLabel"})},35729,e=>{e.v({"backgroundColor--black":"index-module-scss-module__vFsM7W__backgroundColor--black","backgroundColor--primary":"index-module-scss-module__vFsM7W__backgroundColor--primary","backgroundColor--quaternary":"index-module-scss-module__vFsM7W__backgroundColor--quaternary","backgroundColor--quinary":"index-module-scss-module__vFsM7W__backgroundColor--quinary","backgroundColor--secondary":"index-module-scss-module__vFsM7W__backgroundColor--secondary","backgroundColor--senary":"index-module-scss-module__vFsM7W__backgroundColor--senary","backgroundColor--tertiary":"index-module-scss-module__vFsM7W__backgroundColor--tertiary","backgroundColor--white":"index-module-scss-module__vFsM7W__backgroundColor--white",column:"index-module-scss-module__vFsM7W__column"})},64927,(e,t,n)=>{"use strict";var i=e.r(30668),r="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},o=i.useState,a=i.useEffect,s=i.useLayoutEffect,l=i.useDebugValue;function d(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!r(e,n)}catch(e){return!0}}var u="u"<typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),i=o({inst:{value:n,getSnapshot:t}}),r=i[0].inst,u=i[1];return s(function(){r.value=n,r.getSnapshot=t,d(r)&&u({inst:r})},[e,n,t]),a(function(){return d(r)&&u({inst:r}),e(function(){d(r)&&u({inst:r})})},[e]),l(n),n};n.useSyncExternalStore=void 0!==i.useSyncExternalStore?i.useSyncExternalStore:u},1021,(e,t,n)=>{"use strict";
230t.exports=e.r(64927)},21714,(e,t,n)=>{"use strict";var i=e.r(30668),r=e.r(1021),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},a=r.useSyncExternalStore,s=i.useRef,l=i.useEffect,d=i.useMemo,u=i.useDebugValue;n.useSyncExternalStoreWithSelector=function(e,t,n,i,r){var c=s(null);if(null===c.current){var h={hasValue:!1,value:null};c.current=h}else h=c.current;var p=a(e,(c=d(function(){function e(e){if(!l){if(l=!0,a=e,e=i(e),void 0!==r&&h.hasValue){var t=h.value;if(r(t,e))return s=t}return s=e}if(t=s,o(a,e))return t;var n=i(e);return void 0!==r&&r(t,n)?(a=e,t):(a=e,s=n)}var a,s,l=!1,d=void 0===n?null:n;return[function(){return e(t())},null===d?void 0:function(){return e(d())}]},[t,n,i,r]))[0],c[1]);return l(function(){h.hasValue=!0,h.value=p},[p]),u(p),p}},35686,(e,t,n)=>{"use strict";t.exports=e.r(21714)},17363,e=>{e.v({label:"index-module-scss-module__nJqviW__label",richTextWrapper:"index-module-scss-module__nJqviW__richTextWrapper"})},46310,e=>{e.v({label:"index-module-scss-module__-fD-2a__label"})},26369,e=>{e.v({label:"index-module-scss-module__ltyBna__label"})},13872,e=>{e.v({label:"index-module-scss-module__CN9WsG__label",paper:"index-module-scss-module__CN9WsG__paper",select:"index-module-scss-module__CN9WsG__select",select__buttons:"index-module-scss-module__CN9WsG__select__buttons",wrap:"index-module-scss-module__CN9WsG__wrap"})},28259,e=>{e.v({block:"index-module-scss-module__dbKNKW__block",buttonGroup:"index-module-scss-module__dbKNKW__buttonGroup","color--black":"index-module-scss-module__dbKNKW__color--black","color--primary":"index-module-scss-module__dbKNKW__color--primary","color--quaternary":"index-module-scss-module__dbKNKW__color--quaternary","color--quinary":"index-module-scss-module__dbKNKW__color--quinary","color--secondary":"index-module-scss-module__dbKNKW__color--secondary","color--senary":"index-module-scss-module__dbKNKW__color--senary","color--tertiary":"index-module-scss-module__dbKNKW__color--tertiary","color--white":"index-module-scss-module__dbKNKW__color--white",errorTab:"index-module-scss-module__dbKNKW__errorTab",group:"index-module-scss-module__dbKNKW__group",items:"index-module-scss-module__dbKNKW__items",tab:"index-module-scss-module__dbKNKW__tab"})},44412,11427,98551,50096,54407,76603,95567,2551,98604,44505,8812,40867,2390,19858,37012,46769,88431,499,19361,56418,55191,61901,e=>{"use strict";var t,n,i,r,o,a=e.i(48277),s=e.i(63797),l=e.i(90388),d=e.i(60872),u=e.i(89789),c=e.i(42993),h=e.i(86824),p=e.i(79908);e.s(["Email",0,({name:e,label:t,register:n,required:i,errors:r,width:o,readonly:f,placeholder:g,tooltip:m})=>{let{tenant:v}=(0,l.useTenant)(),{t:y}=(0,p.useTranslations)();return(0,a.jsx)(c.Width,{width:o,children:(0,a.jsx)(s.TextInput,{readOnly:f,classNames:{label:u.default.label},size:"md",radius:(0,d.getRadius)(v.Theme?.borderRadius),label:(0,a.jsxs)(a.Fragment,{children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:m})]}),withAsterisk:i,placeholder:g||"Your email",error:i&&r[e]&&y("fieldRequired"),...n(e,{required:i})})})}],44412),e.s(["FormGroup",()=>I],11427);var f=e.i(30668),g=e.i(99564),m=e.i(64145),v=e.i(73596),y=e.i(99325),b=e.i(1584),x=e.i(24133),w=e.i(56297),C=e.i(77219),S=e.i(15502);let _=["h1","h2","h3","h4","h5","h6"],k=["xs","sm","md","lg","xl"];var M={root:"m_8a5d1357"};let T={order:1},D=(0,v.createVarsResolver)((e,{order:t,size:n,lineClamp:i,textWrap:r})=>{var o;let a,s=(o=t||1,a=void 0!==n?n:`h${o}`,_.includes(a)?{fontSize:`var(--mantine-${a}-font-size)`,fontWeight:`var(--mantine-${a}-font-weight)`,lineHeight:`var(--mantine-${a}-line-height)`}:k.includes(a)?{fontSize:`var(--mantine-font-size-${a})`,fontWeight:`var(--mantine-h${o}-font-weight)`,lineHeight:`var(--mantine-h${o}-line-height)`}:{fontSize:(0,S.rem)(a),fontWeight:`var(--mantine-h${o}-font-weight)`,lineHeight:`var(--mantine-h${o}-line-height)`});return{root:{"--title-fw":s.fontWeight,"--title-lh":s.lineHeight,"--title-fz":s.fontSize,"--title-line-clamp":"number"==typeof i?i.toString():void 0,"--title-text-wrap":r}}}),R=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("Title",T,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,order:d,vars:u,size:c,variant:h,lineClamp:p,textWrap:f,mod:g,attributes:m,...v}=n,y=(0,x.useStyles)({name:"Title",props:n,classes:M,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:m,vars:u,varsResolver:D});return[1,2,3,4,5,6].includes(d)?(0,a.jsx)(w.Box,{...y("root"),component:`h${d}`,variant:h,ref:t,mod:[{order:d,"data-line-clamp":"number"==typeof p},g],size:c,...v}):null});R.classes=M,R.displayName="@mantine/core/Title";let I=e=>{let{title:t,fields:n,form:i,register:r,errors:o,control:s,...l}=e;return(0,a.jsxs)("div",{className:m.default.group,children:[t&&(0,a.jsx)(R,{order:4,children:t}),n&&(0,a.jsx)("div",{className:m.default.items,children:n.map((e,t)=>{let n=g.formFields?.[e.blockType];return n?(0,a.jsx)(f.default.Fragment,{children:(0,a.jsx)(n,{form:i,...e,register:r,errors:o,control:s,...l})},t):null})})]})};e.s(["FormGrid",()=>P],98551);var A=e.i(46460);let P=e=>{let{maxColumns:t=2,fields:n,form:i,register:r,errors:o,control:s,...l}=e;return(0,a.jsx)("div",{className:A.default.grid,style:{"--max-columns":t},children:n?.map((e,t)=>{let n=g.formFields?.[e.blockType];return n?(0,a.jsx)(n,{form:i,...e,register:r,errors:o,control:s,...l},t):null})})};var E=e.i(46471),L=e.i(9559);function F(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&0>t.indexOf(i)&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var r=0,i=Object.getOwnPropertySymbols(e);r<i.length;r++)0>t.indexOf(i[r])&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]]);return n}function O(){}function N(e){return!!(e||"").match(/\d/)}function B(e){return null==e}function z(e){return B(e)||"number"==typeof e&&isNaN(e)||"number"==typeof e&&!isFinite(e)}function j(e){return e.replace(/[-[\]/{}()*+?.\\^$|]/g,"\\$&")}function V(e){var t=(0,f.useRef)(e);return t.current=e,(0,f.useRef)(function(){for(var e=[],n=arguments.length;n--;)e[n]=arguments[n];return t.current.apply(t,e)}).current}function H(e,t){void 0===t&&(t=!0);var n="-"===e[0],i=n&&t,r=(e=e.replace("-","")).split(".");
230return{beforeDecimal:r[0],afterDecimal:r[1]||"",hasNegation:n,addNegation:i}}function G(e,t,n){for(var i="",r=n?"0":"",o=0;o<=t-1;o++)i+=e[o]||r;return i}function W(e,t){return Array(t+1).join(e)}function $(e){var t=e+"",n="-"===t[0]?"-":"";n&&(t=t.substring(1));var i=t.split(/[eE]/g),r=i[0],o=i[1];if(!(o=Number(o)))return n+r;r=r.replace(".","");var a=1+o,s=r.length;return a<0?r="0."+W("0",Math.abs(a))+r:a>=s?r+=W("0",a-s):r=(r.substring(0,a)||"0")+"."+r.substring(a),n+r}function U(e,t,n){if(-1!==["","-"].indexOf(e))return e;var i=(-1!==e.indexOf(".")||n)&&t,r=H(e),o=r.beforeDecimal,a=r.afterDecimal,s=r.hasNegation,l=parseFloat("0."+(a||"0")),d=(a.length<=t?"0."+a:l.toFixed(t)).split("."),u=o;return o&&Number(d[0])&&(u=o.split("").reverse().reduce(function(e,t,n){return e.length>n?(Number(e[0])+Number(t)).toString()+e.substring(1,e.length):t+e},d[0])),(s?"-":"")+u+(i?".":"")+G(d[1]||"",t,n)}function q(e,t){if(e.value=e.value,null!==e){if(e.createTextRange){var n=e.createTextRange();return n.move("character",t),n.select(),!0}return e.selectionStart||0===e.selectionStart?(e.focus(),e.setSelectionRange(t,t),!0):(e.focus(),!1)}}(t=o||(o={})).event="event",t.props="prop";var K=(n=function(e,t){for(var n=0,i=0,r=e.length,o=t.length;e[n]===t[n]&&n<r;)n++;for(;e[r-1-i]===t[o-1-i]&&o-i>n&&r-i>n;)i++;return{from:{start:n,end:r-i},to:{start:n,end:o-i}}},r=void 0,function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];return i&&e.length===i.length&&e.every(function(e,t){return e===i[t]})?r:(i=e,r=n.apply(void 0,e))}),Y=function(e,t){var n=Math.min(e.selectionStart,t);return{from:{start:n,end:e.selectionEnd},to:{start:n,end:t}}};function Z(e){return Math.max(e.selectionStart,e.selectionEnd)}function X(e){var t=e.currentValue,n=e.formattedValue,i=e.currentValueIndex,r=e.formattedValueIndex;return t[i]===n[r]}function J(e,t,n,i){var r=e.length;if(t=Math.min(Math.max(t,0),r),"left"===i){for(;t>=0&&!n[t];)t--;-1===t&&(t=n.indexOf(!0))}else{for(;t<=r&&!n[t];)t++;t>r&&(t=n.lastIndexOf(!0))}return -1===t&&(t=r),t}function Q(e){for(var t=Array.from({length:e.length+1}).map(function(){return!0}),n=0,i=t.length;n<i;n++)t[n]=!!(N(e[n])||N(e[n-1]));return t}function ee(e,t,n,i,r,a){void 0===a&&(a=O);var s=V(function(e,t){var n,o;return z(e)?(o="",n=""):n="number"==typeof e||t?i(o="number"==typeof e?$(e):e):i(o=r(e,void 0)),{formattedValue:n,numAsString:o}}),l=(0,f.useState)(function(){return s(B(e)?t:e,n)}),d=l[0],u=l[1],c=V(function(e,t){e.formattedValue!==d.formattedValue&&u({formattedValue:e.formattedValue,numAsString:e.value}),a(e,t)}),h=e,p=n;B(e)&&(h=d.numAsString,p=!0);var g=s(h,p);return(0,f.useMemo)(function(){u(g)},[g.formattedValue]),(0,f.useEffect)(function(){if(!B(t)&&B(e)&&""!==d.formattedValue){var n=parseFloat(d.numAsString);c({formattedValue:d.formattedValue,value:d.numAsString,floatValue:isNaN(n)?void 0:n},{event:void 0,source:o.props})}},[]),[d,c]}function et(e){return e.replace(/[^0-9]/g,"")}function en(e){return e}function ei(e){var t=e.type;void 0===t&&(t="text");var n=e.displayType;void 0===n&&(n="input");var i=e.customInput,r=e.renderText,a=e.getInputRef,s=e.format;void 0===s&&(s=en);var l=e.removeFormatting;void 0===l&&(l=et);var d=e.defaultValue,u=e.valueIsNumericString,c=e.onValueChange,h=e.isAllowed,p=e.onChange;void 0===p&&(p=O);var g=e.onKeyDown;void 0===g&&(g=O);var m=e.onMouseUp;void 0===m&&(m=O);var v=e.onFocus;void 0===v&&(v=O);var y=e.onBlur;void 0===y&&(y=O);var b=e.value,x=e.getCaretBoundary;void 0===x&&(x=Q);var w=e.isValidInputCharacter;void 0===w&&(w=N);var C=e.isCharacterSame,S=F(e,["type","displayType","customInput","renderText","getInputRef","format","removeFormatting","defaultValue","valueIsNumericString","onValueChange","isAllowed","onChange","onKeyDown","onMouseUp","onFocus","onBlur","value","getCaretBoundary","isValidInputCharacter","isCharacterSame"]),_=ee(b,d,!!u,s,l,c),k=_[0],M=k.formattedValue,T=k.numAsString,D=_[1],R=(0,f.useRef)(),I=(0,f.useRef)({formattedValue:M,numAsString:T}),A=function(e,t){I.current={formattedValue:e.formattedValue,numAsString:e.value},D(e,t)},P=(0,f.useState)(!1),E=P[0],L=P[1],B=(0,f.useRef)(null),z=(0,f.useRef)({setCaretTimeout:null,focusTimeout:null});(0,f.useEffect)(function(){return L(!0),function(){clearTimeout(z.current.setCaretTimeout),clearTimeout(z.current.focusTimeout)}},[]);var j=s,V=function(e,t){var n=parseFloat(t);return{formattedValue:e,value:t,floatValue:isNaN(n)?void 0:n}},H=function(e,t,n){(0!==e.selectionStart||e.selectionEnd!==e.value.length)&&(q(e,t),z.current.setCaretTimeout=setTimeout(function(){e.value===n&&e.selectionStart!==t&&q(e,t)},0))},G=function(e,t,n){return J(e,t,x(e),n)},W=function(e,t,n){var i=x(t),r=function(e,t,n,i,r,o,a){void 0===a&&(a=X);var s=r.findIndex(function(e){return e}),l=e.slice(0,s);t||n.startsWith(l)||(t=l,n=l+n,i+=l.length);for(var d=n.length,u=e.length,c={},h=Array(d),p=0;p<d;p++){h[p]=-1;for(var f=0;f<u;f++)if(a({currentValue:n,lastValue:t,formattedValue:e,currentValueIndex:p,formattedValueIndex:f})&&!0!==c[f]){h[p]=f,c[f]=!0;break}}for(var g=i;g<d&&(-1===h[g]||!o(n[g]));)g++;var m=g===d||-1===h[g]?u:h[g];for(g=i-1;g>0&&-1===h[g];)g--;var v=-1===g||-1===h[g]?0:h[g]+1;return v>m?m:i-v<m-i?v:m}(t,M,e,n,i,w,C);return J(t,r,i)},$=function(e){var t,n=e.formattedValue;void 0===n&&(n="");var i=e.input,r=e.source,o=e.event,a=e.numAsString;if(i){var s=e.inputValue||i.value,l=Z(i);i.value=n,void 0!==(t=W(s,n,l))&&H(i,t,n)}n!==M&&A(V(n,a),{event:o,source:r})};(0,f.useEffect)(function(){var e=I.current,t=e.formattedValue,n=e.numAsString;(M!==t||T!==n)&&A(V(M,T),{event:void 0,source:o.props})},[M,T]);var U=B.current?Z(B.current):void 0;("u">typeof window?f.useLayoutEffect:f.useEffect)(function(){var e=B.current;if(M!==I.current.formattedValue&&e){var t=W(I.current.formattedValue,M,U);e.value=M,H(e,t,M)}},[M]);var ei=function(e,t,n){var i=t.target,r=Object.assign(Object.assign({}
230,R.current?Y(R.current,i.selectionEnd):K(M,e)),{lastValue:M}),o=l(e,r),a=j(o);if(o=l(a,void 0),h&&!h(V(a,o))){var s=t.target,d=W(e,M,Z(s));return s.value=M,H(s,d,M),!1}return $({formattedValue:a,numAsString:o,inputValue:e,event:t,source:n,input:t.target}),!0},er=function(e,t){void 0===t&&(t=0),R.current={selectionStart:e.selectionStart,selectionEnd:e.selectionEnd+t}},eo=Object.assign({inputMode:E&&"u">typeof navigator&&!(navigator.platform&&/iPhone|iPod/.test(navigator.platform))?"numeric":void 0},S,{type:t,value:M,onChange:function(e){ei(e.target.value,e,o.event)&&p(e),R.current=void 0},onKeyDown:function(e){var t,n=e.target,i=e.key,r=n.selectionStart,o=n.selectionEnd,a=n.value;void 0===a&&(a=""),"ArrowLeft"===i||"Backspace"===i?t=Math.max(r-1,0):"ArrowRight"===i?t=Math.min(r+1,a.length):"Delete"===i&&(t=r);var s=0;"Delete"===i&&r===o&&(s=1);var l="ArrowLeft"===i||"ArrowRight"===i;if(void 0===t||r!==o&&!l){g(e),er(n,s);return}var d=t;l?(d=G(a,t,"ArrowLeft"===i?"left":"right"))!==t&&e.preventDefault():"Delete"!==i||w(a[t])?"Backspace"!==i||w(a[t])||(d=G(a,t,"left")):d=G(a,t,"right"),d!==t&&H(n,d,a),g(e),er(n,s)},onMouseUp:function(e){var t=e.target,n=function(){var e=t.selectionStart,n=t.selectionEnd,i=t.value;if(void 0===i&&(i=""),e===n){var r=G(i,e);r!==e&&H(t,r,i)}};n(),requestAnimationFrame(function(){n()}),m(e),er(t)},onFocus:function(e){e.persist&&e.persist();var t=e.target,n=e.currentTarget;B.current=t,z.current.focusTimeout=setTimeout(function(){var i=t.selectionStart,r=t.selectionEnd,o=t.value;void 0===o&&(o="");var a=G(o,i);a!==i&&(0!==i||r!==o.length)&&H(t,a,o),v(Object.assign(Object.assign({},e),{currentTarget:n}))},0)},onBlur:function(e){B.current=null,clearTimeout(z.current.focusTimeout),clearTimeout(z.current.setCaretTimeout),y(e)}});return"text"===n?r?f.default.createElement(f.default.Fragment,null,r(M,S)||null):f.default.createElement("span",Object.assign({},S,{ref:a}),M):i?f.default.createElement(i,Object.assign({},eo,{ref:a})):f.default.createElement("input",Object.assign({},eo,{ref:a}))}function er(e,t){var n,i,r,o=t.decimalScale,a=t.fixedDecimalScale,s=t.prefix;void 0===s&&(s="");var l=t.suffix;void 0===l&&(l="");var d=t.allowNegative,u=t.thousandsGroupStyle;if(void 0===u&&(u="thousand"),""===e||"-"===e)return e;var c=eo(t),h=c.thousandSeparator,p=c.decimalSeparator,f=0!==o&&-1!==e.indexOf(".")||o&&a,g=H(e,d),m=g.beforeDecimal,v=g.afterDecimal,y=g.addNegation;return void 0!==o&&(v=G(v,o,!!a)),h&&(n=m,i=function(e){switch(e){case"lakh":return/(\d+?)(?=(\d\d)+(\d)(?!\d))(\.\d+)?/g;case"wan":return/(\d)(?=(\d{4})+(?!\d))/g;default:return/(\d)(?=(\d{3})+(?!\d))/g}}(u),r=-1===(r=n.search(/[1-9]/))?n.length:r,m=n.substring(0,r)+n.substring(r,n.length).replace(i,"$1"+h)),s&&(m=s+m),l&&(v+=l),y&&(m="-"+m),e=m+(f&&p||"")+v}function eo(e){var t=e.decimalSeparator;void 0===t&&(t=".");var n=e.thousandSeparator,i=e.allowedDecimalSeparators;return!0===n&&(n=","),i||(i=[t,"."]),{decimalSeparator:t,thousandSeparator:n,allowedDecimalSeparators:i}}function ea(e){var t,n,i,r,a,s,l,d,u,c,h,p,g,m,v,y,b,x,w,C,S,_,k,M,T,D,R,I,A,P=((t=function(e){var t=eo(e),n=t.thousandSeparator,i=t.decimalSeparator,r=e.prefix;void 0===r&&(r="");var o=e.allowNegative;if(void 0===o&&(o=!0),n===i)throw Error("\n Decimal separator can't be same as thousand separator.\n thousandSeparator: "+n+' (thousandSeparator = {true} is same as thousandSeparator = ",")\n decimalSeparator: '+i+" (default value for decimalSeparator is .)\n ");return r.startsWith("-")&&o&&(console.error("\n Prefix can't start with '-' when allowNegative is true.\n prefix: "+r+"\n allowNegative: "+o+"\n "),o=!1),Object.assign(Object.assign({},e),{allowNegative:o})}(t=e)).decimalSeparator,t.allowedDecimalSeparators,t.thousandsGroupStyle,n=t.suffix,i=t.allowNegative,r=t.allowLeadingZeros,void 0===(a=t.onKeyDown)&&(a=O),void 0===(s=t.onBlur)&&(s=O),l=t.thousandSeparator,d=t.decimalScale,u=t.fixedDecimalScale,void 0===(c=t.prefix)&&(c=""),h=t.defaultValue,p=t.value,g=t.valueIsNumericString,m=t.onValueChange,v=F(t,["decimalSeparator","allowedDecimalSeparators","thousandsGroupStyle","suffix","allowNegative","allowLeadingZeros","onKeyDown","onBlur","thous
230andSeparator","decimalScale","fixedDecimalScale","prefix","defaultValue","value","valueIsNumericString","onValueChange"]),b=(y=eo(t)).decimalSeparator,x=y.allowedDecimalSeparators,w=function(e){return er(e,t)},C=function(e,n){return function(e,t,n){void 0===t&&(t={from:{start:0,end:0},to:{start:0,end:e.length},lastValue:""});var i,r,o,a,s=n.allowNegative,l=n.prefix;void 0===l&&(l="");var d=n.suffix;void 0===d&&(d="");var u=n.decimalScale,c=t.from,h=t.to,p=h.start,f=h.end,g=eo(n),m=g.allowedDecimalSeparators,v=g.decimalSeparator,y=e[f]===v;if(N(e)&&(e===l||e===d)&&""===t.lastValue)return e;if(f-p==1&&-1!==m.indexOf(e[p])){var b=0===u?"":v;e=e.substring(0,p)+b+e.substring(p+1,e.length)}var x=function(e,t,n){var i=!1,r=!1;l.startsWith("-")?i=!1:e.startsWith("--")?(i=!1,r=!0):d.startsWith("-")&&e.length===d.length?i=!1:"-"===e[0]&&(i=!0);var o=+!!i;return r&&(o=2),o&&(e=e.substring(o),t-=o,n-=o),{value:e,start:t,end:n,hasNegation:i}},w=x(e,p,f),C=w.hasNegation;e=w.value,p=w.start,f=w.end;var S=x(t.lastValue,c.start,c.end),_=S.start,k=S.end,M=S.value,T=e.substring(p,f);e.length&&M.length&&(_>M.length-d.length||k<l.length)&&!(T&&d.startsWith(T))&&(e=M);var D=0;e.startsWith(l)?D+=l.length:p<l.length&&(D=p),e=e.substring(D),f-=D;var R=e.length,I=e.length-d.length;e.endsWith(d)?R=I:f>I?R=f:f>e.length-d.length&&(R=f),e=e.substring(0,R),void 0===(i=C?"-"+e:e)&&(i=""),r=RegExp("(-)(.)*(-)"),o=/(-)/.test(i),a=r.test(i),i=i.replace(/-/g,""),o&&!a&&s&&(i="-"+i);var A=(e=((e=i).match(RegExp("(^-)|[0-9]|"+j(v),"g"))||[]).join("")).indexOf(v),P=H(e=e.replace(RegExp(j(v),"g"),function(e,t){return t===A?".":""}),s),E=P.beforeDecimal,L=P.afterDecimal,F=P.addNegation;return h.end-h.start<c.end-c.start&&""===E&&y&&!parseFloat(L)&&(e=F?"-":""),e}(e,n,t)},S=B(p)?h:p,k=null!=g?g:(_=c,""===S||!(null==_?void 0:_.match(/\d/))&&!(null==n?void 0:n.match(/\d/))&&"string"==typeof S&&!isNaN(Number(S))),B(p)?B(h)||(k=k||"number"==typeof h):k=k||"number"==typeof p,R=(D=(T=ee((M=function(e){return z(e)?e:("number"==typeof e&&(e=$(e)),k&&"number"==typeof d)?U(e,d,!!u):e})(p),M(h),!!k,w,C,m))[0]).numAsString,I=D.formattedValue,A=T[1],Object.assign(Object.assign({}
230,v),{value:I,valueIsNumericString:!1,isValidInputCharacter:function(e){return e===b||N(e)},isCharacterSame:function(e){var t=e.currentValue,n=e.lastValue,i=e.formattedValue,r=e.currentValueIndex,o=e.formattedValueIndex,a=t[r],s=i[o],l=K(n,t).to,h=function(e){return C(e).indexOf(".")+c.length};return!(0===p&&u&&d&&t[l.start]===b&&h(t)<r&&h(i)>o)&&(!!(r>=l.start&&r<l.end&&x&&x.includes(a))&&s===b||a===s)},onValueChange:A,format:w,removeFormatting:C,getCaretBoundary:function(e){var n,i,r,o,a,s;return void 0===(i=(n=t).prefix)&&(i=""),void 0===(r=n.suffix)&&(r=""),o=Array.from({length:e.length+1}).map(function(){return!0}),a="-"===e[0],o.fill(!1,0,Math.min(i.length+ +!!a,e.length)),s=e.length,o.fill(!1,s-r.length+1,s+1),o},onKeyDown:function(e){var t=e.target,n=e.key,r=t.selectionStart,o=t.selectionEnd,s=t.value;if(void 0===s&&(s=""),("Backspace"===n||"Delete"===n)&&o<c.length&&"-"!==s)return void e.preventDefault();if(r!==o)return void a(e);"Backspace"===n&&"-"===s[0]&&r===c.length+1&&i&&q(t,1),d&&u&&("Backspace"===n&&s[r-1]===b?(q(t,r-1),e.preventDefault()):"Delete"===n&&s[r]===b&&e.preventDefault()),(null==x?void 0:x.includes(n))&&s[r]===b&&q(t,r+1);var h=!0===l?",":l;"Backspace"===n&&s[r-1]===h&&q(t,r-1),"Delete"===n&&s[r]===h&&q(t,r+1),a(e)},onBlur:function(e){var n=R;n.match(/\d/g)||(n=""),r||(n=function(e){if(!e)return e;var t="-"===e[0];t&&(e=e.substring(1,e.length));var n=e.split("."),i=n[0].replace(/^0+/,"")||"0",r=n[1]||"";return(t?"-":"")+i+(r?"."+r:"")}(n)),u&&d&&(n=U(n,d,u)),n!==R&&A({formattedValue:er(n,t),value:n,floatValue:parseFloat(n)},{event:e,source:o.event}),s(e)}}));return f.default.createElement(ei,Object.assign({},P))}var es=e.i(99850),el=e.i(29),ed=e.i(12824),eu=e.i(34096),ec=e.i(90112),eh=e.i(36546),ep=e.i(91805),ef=e.i(20425),eg={root:"m_e2f5cd4e",controls:"m_95e17d22",control:"m_80b4b171"};function em({direction:e,style:t,...n}){return(0,a.jsx)("svg",{style:{width:"var(--ni-chevron-size)",height:"var(--ni-chevron-size)",transform:"up"===e?"rotate(180deg)":void 0,...t},viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n,children:(0,a.jsx)("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"})})}let ev=/^(0\.0*|-0(\.0*)?)$/,ey=/^-?0\d+(\.\d+)?\.?$/,eb=/\.\d*0$/,ex=/^-?\d+\.$/;function ew(e){return"string"==typeof e&&""!==e&&!Number.isNaN(Number(e))}function eC(e){return"number"==typeof e?e<Number.MAX_SAFE_INTEGER:""===e||ew(e)&&Number(e)<Number.MAX_SAFE_INTEGER}function eS(e,t,n){return void 0===e||(void 0===t||e>=t)&&(void 0===n||e<=n)}let e_={step:1,clampBehavior:"blur",allowDecimal:!0,allowNegative:!0,withKeyboardEvents:!0,allowLeadingZeros:!0,trimLeadingZeroesOnBlur:!0,startValue:0,allowedDecimalSeparators:[".",","]},ek=(0,v.createVarsResolver)((e,{size:t})=>({controls:{"--ni-chevron-size":(0,ec.getSize)(t,"ni-chevron-size")}})),eM=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("NumberInput",e_,e),{className:i,classNames:r,styles:o,unstyled:s,vars:l,onChange:d,onValueChange:u,value:c,defaultValue:h,max:p,min:g,step:m,hideControls:v,rightSection:w,isAllowed:C,clampBehavior:S,onBlur:_,allowDecimal:k,decimalScale:M,onKeyDown:T,onKeyDownCapture:D,handlersRef:R,startValue:I,disabled:A,rightSectionPointerEvents:P,allowNegative:E,readOnly:L,size:F,rightSectionWidth:O,stepHoldInterval:N,stepHoldDelay:B,allowLeadingZeros:z,withKeyboardEvents:j,trimLeadingZeroesOnBlur:V,allowedDecimalSeparators:H,attributes:G,...W}=n,$=(0,x.useStyles)({name:"NumberInput",classes:eg,props:n,classNames:r,styles:o,unstyled:s,attributes:G,vars:l,varsResolver:ek}),{resolvedClassNames:U,resolvedStyles:q}=(0,eh.useResolvedStylesApi)({classNames:r,styles:o,props:n}),[K,Y]=(0,es.useUncontrolled)({value:c,defaultValue:h,finalValue:"",onChange:d}),Z=void 0!==B&&void 0!==N,X=(0,f.useRef)(null),J=(0,f.useRef)(null),Q=(0,f.useRef)(0),ee=e=>{let t=String(e).match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return t?Math.max(0,(t[1]?t[1].length:0)-(t[2]?+t[2]:0)):0},et=e=>{X.current&&void 0!==e&&X.current.setSelectionRange(e,e)},en=(0,f.useRef)(eu.noop);en.current=()=>{let e;if(!eC(K))return;let t=Math.max(ee(K),ee(m)),n=10**t;if(!ew(K)&&("number"!=typeof K||Number.isNaN(K)))e=(0,el.clamp)(I,g,p);else if(void 0!==p){let t=(Math.round(Number(K)*n)+Math.round(m*n))/n;e=t<=p?t:p}else e=(Math.round(Number(K)*n)+Math.round(m*n))/n;let i=e.toFixed(t);Y(parseFloat(i)),u?.({floatValue:parseFloat(i),formattedValue:i,value:i},{source:"increment"}),setTimeout(()=>et(X.current?.value.length),0)};let ei=(0,f.useRef)(eu.noop);ei.current=()=>{let e;if(!eC(K))return;let t=void 0!==g?g:E?Number.MIN_SAFE_INTEGER:0,n=Math.max(ee(K),ee(m)),i=10**n;if(!ew(K)&&"number"!=typeof K||Number.isNaN(K))e=(0,el.clamp)(I,t,p);else{let n=(Math.round(Number(K)*i)-Math.round(m*i))/i;e=void 0!==t&&n<t?t:n}let r=e.toFixed(n);Y(parseFloat(r)),u?.({floatValue:parseFloat(r),formattedValue:r,value:r},{source:"decrement"}),setTimeout(()=>et(X.current?.value.length),0)},(0,ed.assignRef)(R,{increment:en.current,decrement:ei.current});let er=e=>{e?en.current?.():ei.current?.(),Q.current+=1},eo=e=>{if(er(e),Z){let t="number"==typeof N?N:N(Q.current);J.current=window.setTimeout(()=>eo(e),t)}},ec=(e,t)=>{e.preventDefault(),X.current?.focus(),er(t),Z&&(J.current=window.setTimeout(()=>eo(t),B))},eM=()=>{J.current&&window.clearTimeout(J.current),J.current=null,Q.current=0},eT=(0,a.jsxs)("div",{...$("controls"),children:[(0,a.jsx)(ef.UnstyledButton,{...$("control"),tabIndex:-1,"aria-hidden":!0,disabled:A||"number"==typeof K&&void 0!==p&&K>=p,mod:{direction:"up"},onMouseDown:e=>e.preventDefault(),onPointerDown:e=>{ec(e,!0)},onPointerUp:eM,onPointerLeave:eM,children:(0,a.jsx)(em,{direction:"up"})}),(0,a.jsx)(ef.UnstyledButton,{...$("control"),tabIndex:-1,"aria-hidden":!0,disabled:A||"number"==typeof K&&void 0!==g&&K<=g,mod:{direction:"down"},onMouseDown:e=>e.preventDefault(),onPointerDown:e=>{ec(e,!1)},onPointerUp:eM,onPointerLeave:eM,children:(0,a.jsx)(em,{direction:"down"})})]});return(0,a.jsx)(ep.InputBase,{component:ea,allowNegative:E,className:(0,y.default)(eg.root,i),size:F,inputMode:"decimal",...W,readOnly:L,disabled:A,value:K,getInputRef:(0,ed.useMergedRef)(t,X),onValueChange:(e,t)=>
230{var n,i;"event"===t.source&&Y((n=e.floatValue,i=e.value,("number"==typeof n?!(n<Number.MAX_SAFE_INTEGER):!!Number.isNaN(Number(n)))||Number.isNaN(n)||!(14>i.toString().replace(".","").length)||""===i||ev.test(e.value)||z&&ey.test(e.value)||eb.test(e.value)||ex.test(e.value))?e.value:e.floatValue),u?.(e,t)},rightSection:v||L||!eC(K)?w:w||eT,classNames:U,styles:q,unstyled:s,__staticSelector:"NumberInput",decimalScale:k?M:0,onPaste:e=>{let t=e.clipboardData.getData("text"),n=W.decimalSeparator||".",i=(H||[".",","]).filter(e=>e!==n);if(i.some(e=>t.includes(e))){e.preventDefault();let r=t;i.forEach(e=>{r=r.split(e).join(n)});let o=X.current;if(o){let e=o.selectionStart??0,t=o.selectionEnd??0,n=o.value,i=n.substring(0,e)+r+n.substring(t),a=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value")?.set;a?.call(o,i),o.dispatchEvent(new Event("change",{bubbles:!0}));let s=e+r.length;setTimeout(()=>et(s),0)}}W.onPaste?.(e)},onKeyDown:e=>{T?.(e),!L&&j&&("ArrowUp"===e.key&&(e.preventDefault(),en.current?.()),"ArrowDown"===e.key&&(e.preventDefault(),ei.current?.()))},onKeyDownCapture:e=>{if(D?.(e),"Backspace"===e.key){let t=X.current;t&&0===t.selectionStart&&t.selectionStart===t.selectionEnd&&(e.preventDefault(),window.setTimeout(()=>et(0),0))}},rightSectionPointerEvents:P??(A?"none":void 0),rightSectionWidth:O??`var(--ni-right-section-width-${F||"sm"})`,allowLeadingZeros:z,allowedDecimalSeparators:H,onBlur:e=>{let t=K;"blur"===S&&"number"==typeof t&&(t=(0,el.clamp)(t,g,p)),V&&"string"==typeof t&&15>ee(t)&&(t=function(e,t,n){let i=e.toString(),r=ex.test(i),o=i.replace(/^0+(?=\d)/,""),a=parseFloat(o);if(Number.isNaN(a))return o;if(a>Number.MAX_SAFE_INTEGER)return void 0!==t?t:o;let s=(0,el.clamp)(a,n,t);if(r){let e=s.toString().replace(/^0+(?=\d)/,"");return`${e}.`}return s}(t,p,g)),K!==t&&Y(t),_?.(e)},attributes:G,isAllowed:e=>"strict"===S?C?C(e)&&eS(e.floatValue,g,p):eS(e.floatValue,g,p):!C||C(e)})});eM.classes={...ep.InputBase.classes,...eg},eM.displayName="@mantine/core/NumberInput",e.s(["NumberInput",()=>eM],50096),e.s(["Number",0,({name:e,label:t,width:n,required:i,errors:r,control:o,readonly:s,setValue:u,getValues:g,numberDefaultValue:m,placeholder:v,tooltip:y})=>{let b,{tenant:x}=(0,l.useTenant)(),{t:w}=(0,p.useTranslations)(),{decimalSep:C,thousandSep:S}={decimalSep:(b=1234.5.toLocaleString()).charAt(5),thousandSep:b.charAt(1)};return f.default.useEffect(()=>{m&&!g(e)&&u(e,m)},[e,m,u,g]),(0,a.jsx)(c.Width,{width:n,children:(0,a.jsx)(E.Controller,{control:o,rules:{required:i},name:e,defaultValue:"",render:({field:{onChange:n,value:o}})=>(0,a.jsx)(eM,{readOnly:s,value:o,classNames:{label:L.default.label},size:"md",radius:(0,d.getRadius)(x.Theme?.borderRadius),label:(0,a.jsxs)(a.Fragment,{children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:y})]}),withAsterisk:i,placeholder:v||"Enter a number",error:i&&r[e]&&w("fieldRequired"),onChange:e=>n(e),decimalSeparator:C,thousandSeparator:S})})})}],54407);var eT=e.i(57472),eD=e.i(44733),eR=e.i(12112),eI=e.i(1483),eA=e.i(59678),eP=e.i(90323),eE=e.i(76554),eL={root:"m_f3f1af94",inner:"m_89c4f5e4",icon:"m_f3ed6b2b",radio:"m_8a3dbb89","radio--outline":"m_1bfe9d39"},eF=e.i(58960),eO=e.i(58525);let[eN,eB]=(0,eO.createOptionalContext)(),[ez,ej]=(0,eO.createOptionalContext)();var eV={card:"m_9dc8ae12"};let eH={withBorder:!0},eG=(0,v.createVarsResolver)((e,{radius:t})=>({card:{"--card-radius":(0,ec.getRadius)(t)}})),eW=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("RadioCard",eH,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,checked:u,mod:c,withBorder:h,value:p,onClick:f,name:g,onKeyDown:m,attributes:v,...y}=n,w=(0,x.useStyles)({name:"RadioCard",classes:eV,props:n,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:v,vars:d,varsResolver:eG,rootSelector:"card"}),{dir:C}=(0,eF.useDirection)(),S=eB(),_="boolean"==typeof u?u:S?.value===p,k=g||S?.name;return(0,a.jsx)(ez,{value:{checked:_},children:(0,a.jsx)(ef.UnstyledButton,{ref:t,mod:[{"with-border":h,checked:_},c],...w("card"),...y,role:"radio","aria-checked":_,name:k,onClick:e=>{f?.(e),S?.onChange(p||"")},onKeyDown:e=>{if(m?.(e),["ArrowDown","ArrowUp","ArrowLeft","ArrowRight"].includes(e.nativeEvent.code)){e.preventDefault();let t=Array.from(document.querySelectorAll(`[role="radio"][name="${k||"__mantine"}"]`)),n=t.findIndex(t=>t===e.target),i=n+1>=t.length?0:n+1,r=n-1<0?t.length-1:n-1;"ArrowDown"===e.nativeEvent.code&&(t[i].focus(),t[i].click()),"ArrowUp"===e.nativeEvent.code&&(t[r].focus(),t[r].click()),"ArrowLeft"===e.nativeEvent.code&&(t["ltr"===C?r:i].focus(),t["ltr"===C?r:i].click()),"ArrowRight"===e.nativeEvent.code&&(t["ltr"===C?i:r].focus(),t["ltr"===C?i:r].
230click())}}})})});eW.displayName="@mantine/core/RadioCard",eW.classes=eV;var e$=e.i(60436),eU=e.i(44969);let eq=(0,C.factory)((e,t)=>{let{value:n,defaultValue:i,onChange:r,size:o,wrapperProps:s,children:l,name:d,readOnly:u,disabled:c,...h}=(0,b.useProps)("RadioGroup",null,e),p=(0,eT.useId)(d),[f,g]=(0,es.useUncontrolled)({value:n,defaultValue:i,finalValue:"",onChange:r});return(0,a.jsx)(eN,{value:{value:f,onChange:e=>!u&&g("string"==typeof e?e:e.currentTarget.value),size:o,name:p,disabled:c},children:(0,a.jsx)(eU.Input.Wrapper,{size:o,ref:t,...s,...h,labelElement:"div",__staticSelector:"RadioGroup",children:(0,a.jsx)(e$.InputsGroupFieldset,{role:"radiogroup",children:l})})})});function eK({size:e,style:t,...n}){return(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 5 5",style:{width:(0,S.rem)(e),height:(0,S.rem)(e),...t},"aria-hidden":!0,...n,children:(0,a.jsx)("circle",{cx:"2.5",cy:"2.5",r:"2.5",fill:"currentColor"})})}eq.classes=eU.Input.Wrapper.classes,eq.displayName="@mantine/core/RadioGroup",e.s(["RadioGroup",()=>eq],76603);var eY={indicator:"m_717d7ff6",icon:"m_3e4da632","indicator--outline":"m_2980836c"};let eZ={icon:eK},eX=(0,v.createVarsResolver)((e,{radius:t,color:n,size:i,iconColor:r,variant:o,autoContrast:a})=>{let s=(0,eD.parseThemeColor)({color:n||e.primaryColor,theme:e}),l=s.isThemeColor&&void 0===s.shade?`var(--mantine-color-${s.color}-outline)`:s.color;return{indicator:{"--radio-size":(0,ec.getSize)(i,"radio-size"),"--radio-radius":void 0===t?void 0:(0,ec.getRadius)(t),"--radio-color":"outline"===o?l:(0,eR.getThemeColor)(n,e),"--radio-icon-size":(0,ec.getSize)(i,"radio-icon-size"),"--radio-icon-color":r?(0,eR.getThemeColor)(r,e):(0,eA.getAutoContrastValue)(a,e)?(0,eI.getContrastColor)({color:n,theme:e,autoContrast:a}):void 0}}}),eJ=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("RadioIndicator",eZ,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,icon:u,radius:c,color:h,iconColor:p,autoContrast:f,checked:g,mod:m,variant:v,disabled:y,attributes:C,...S}=n,_=(0,x.useStyles)({name:"RadioIndicator",classes:eY,props:n,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:C,vars:d,varsResolver:eX,rootSelector:"indicator"}),k=ej(),M="boolean"==typeof g?g:k?.checked||!1;return(0,a.jsx)(w.Box,{ref:t,..._("indicator",{variant:v}),variant:v,mod:[{checked:M,disabled:y},m],...S,children:(0,a.jsx)(u,{..._("icon")})})});eJ.displayName="@mantine/core/RadioIndicator",eJ.classes=eY;let eQ={labelPosition:"right"},e0=(0,v.createVarsResolver)((e,{size:t,radius:n,color:i,iconColor:r,variant:o,autoContrast:a})=>{let s=(0,eD.parseThemeColor)({color:i||e.primaryColor,theme:e}),l=s.isThemeColor&&void 0===s.shade?`var(--mantine-color-${s.color}-outline)`:s.color;return{root:{"--radio-size":(0,ec.getSize)(t,"radio-size"),"--radio-radius":void 0===n?void 0:(0,ec.getRadius)(n),"--radio-color":"outline"===o?l:(0,eR.getThemeColor)(i,e),"--radio-icon-color":r?(0,eR.getThemeColor)(r,e):(0,eA.getAutoContrastValue)(a,e)?(0,eI.getContrastColor)({color:i,theme:e,autoContrast:a}):void 0,"--radio-icon-size":(0,ec.getSize)(t,"radio-icon-size")}}}),e1=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("Radio",eQ,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,id:u,size:c,label:h,labelPosition:p,description:f,error:g,radius:m,color:v,variant:y,disabled:C,wrapperProps:S,icon:_=eK,rootRef:k,iconColor:M,onChange:T,mod:D,attributes:R,checked:I,...A}=n,P=(0,x.useStyles)({name:"Radio",classes:eL,props:n,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:R,vars:d,varsResolver:e0}),E=eB(),L=E?.size??c,F=n.size?c:L,{styleProps:O,rest:N}=(0,eP.extractStyleProps)(A),B=(0,eT.useId)(u),z=E?E.value===N.value:void 0,j={checked:z??I,name:E?.name??N.name,onChange:e=>{E?.onChange(e),T?.(e)},disabled:E?.disabled??C};return(0,a.jsx)(eE.InlineInput,{...P("root"),__staticSelector:"Radio",__stylesApiProps:n,id:B,size:F,labelPosition:p,label:h,description:f,error:g,disabled:j.disabled,classNames:i,styles:s,unstyled:l,"data-checked":(z??I)||void 0,variant:y,ref:k,mod:D,...O,...S,children:(0,a.jsxs)(w.Box,{...P("inner"),mod:{"label-position":p},children:[(0,a.jsx)(w.Box,{...P("radio",{focusable:!0,variant:y}),...N,...j,component:"input",mod:{error:!!g},ref:t,id:B,type:"radio"}),(0,a.jsx)(_,{...P("icon"),"aria-hidden":!0})]})})});e1.classes=eL,e1.displayName="@mantine/core/Radio",e1.Group=eq,e1.Card=eW,e1.Indicator=eJ,e.
230s(["Radio",()=>e1],95567);var e2=e.i(40775),e3=e.i(69271);e.s(["Radio",0,({name:e,items:t,label:n,required:i,errors:r,control:o,setValue:s,getValues:l,defaultValue:d,readonly:u,radioDefaultValue:g,tooltip:m})=>{let{t:v}=(0,p.useTranslations)();return f.default.useEffect(()=>{g&&!l(e)&&s(e,g)},[e,g,s,l]),(0,a.jsx)(c.Width,{children:(0,a.jsx)(E.Controller,{control:o,rules:{required:i??void 0},name:e,defaultValue:d,render:({field:{onChange:o,value:s}})=>(0,a.jsx)(e1.Group,{readOnly:u,classNames:{label:e3.default.label,error:e3.default.error},label:(0,a.jsxs)(a.Fragment,{children:[n,(0,a.jsx)(h.FieldTooltip,{tooltip:m})]}),withAsterisk:i??void 0,value:s,onChange:e=>o(e),error:i&&r[e]&&v("fieldRequired"),children:(0,a.jsx)(e2.Group,{className:e3.default.group,children:t?.map(e=>(0,a.jsx)(e1,{classNames:{label:e3.default.radioLabel},value:e.value,label:e.label},e.value))})})})})}],2551);var e5=e.i(86957),e4=e.i(35729);e.s(["RichTextBlock",0,e=>{let{richText:t,bgColor:n}=e;return(0,a.jsx)(e5.default,{...e,content:t,className:[e4.default.column,e4.default["column--full"],e4.default[`backgroundColor--${n}`]].filter(Boolean).join(" ")})}],98604);let e6={linkControlLabel:"Link",colorPickerControlLabel:"Text color",highlightControlLabel:"Highlight text",colorControlLabel:e=>`Set text color ${e}`,boldControlLabel:"Bold",italicControlLabel:"Italic",underlineControlLabel:"Underline",strikeControlLabel:"Strikethrough",clearFormattingControlLabel:"Clear formatting",unlinkControlLabel:"Remove link",bulletListControlLabel:"Bullet list",orderedListControlLabel:"Ordered list",sourceCodeControlLabel:"Switch between text/source code",h1ControlLabel:"Heading 1",h2ControlLabel:"Heading 2",h3ControlLabel:"Heading 3",h4ControlLabel:"Heading 4",h5ControlLabel:"Heading 5",h6ControlLabel:"Heading 6",blockquoteControlLabel:"Blockquote",alignLeftControlLabel:"Align text: left",alignCenterControlLabel:"Align text: center",alignRightControlLabel:"Align text: right",alignJustifyControlLabel:"Align text: justify",codeControlLabel:"Code",codeBlockControlLabel:"Code block",subscriptControlLabel:"Subscript",superscriptControlLabel:"Superscript",unsetColorControlLabel:"Unset color",hrControlLabel:"Horizontal line",undoControlLabel:"Undo",redoControlLabel:"Redo",tasksControlLabel:"Task list",tasksSinkLabel:"Decrease task level",tasksLiftLabel:"Increase task level",linkEditorInputLabel:"Enter URL",linkEditorInputPlaceholder:"https://example.com/",linkEditorExternalLink:"Open link in a new tab",linkEditorInternalLink:"Open link in the same tab",linkEditorSave:"Save",colorPickerCancel:"Cancel",colorPickerClear:"Clear color",colorPickerColorPicker:"Color picker",colorPickerPalette:"Color palette",colorPickerSave:"Save",colorPickerColorLabel:e=>`Set text color ${e}`};var e8=e.i(20826);let[e7,e9]=(0,e8.createSafeContext)("RichTextEditor component was not found in tree");var te={root:"m_dd3f7539",Typography:"m_f2016866",content:"m_c2204cc2",linkEditorDropdown:"m_8a991b4f",control:"m_c2207da6",controlIcon:"m_9cdfeb3f",controlsGroup:"m_2ab47ef2",linkEditor:"m_b67b711e",linkEditorInput:"m_296cf94c",linkEditorExternalControl:"m_cfef614",linkEditorSave:"m_3b28e7bb",toolbar:"m_4574a3c4",taskList:"m_8b44009a"},tt=e.i(39057),tn=f,ti=e.i(69941),tr=e.i(1021);function to(e){this.content=e}function ta(e){return e>=56320&&e<57344}function ts(e){return e>=55296&&e<56320}to.prototype={constructor:to,find:function(e){for(var t=0;t<this.content.length;t+=2)if(this.content[t]===e)return t;return -1},get:function(e){var t=this.find(e);return -1==t?void 0:this.content[t+1]},update:function(e,t,n){var i=n&&n!=e?this.remove(n):this,r=i.find(e),o=i.content.slice();return -1==r?o.push(n||e,t):(o[r+1]=t,n&&(o[r]=n)),new to(o)},remove:function(e){var t=this.find(e);if(-1==t)return this;var n=this.content.slice();return n.splice(t,2),new to(n)},addToStart:function(e,t){return new to([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var n=this.remove(e).content.slice();return n.push(e,t),new to(n)},addBefore:function(e,t,n){var i=this.remove(t),r=i.content.slice(),o=i.find(e);return r.splice(-1==o?r.length:o,0,t,n),new to(r)}
vendor: 6,812 bytes, line 230
230,forEach:function(e){for(var t=0;t<this.content.length;t+=2)e(this.content[t],this.content[t+1])},prepend:function(e){return(e=to.from(e)).size?new to(e.content.concat(this.subtract(e).content)):this},append:function(e){return(e=to.from(e)).size?new to(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=to.from(e);for(var n=0;n<e.content.length;n+=2)t=t.remove(e.content[n]);return t},toObject:function(){var e={};return this.forEach(function(t,n){e[t]=n}),e},get size(){return this.content.length>>1}},to.from=function(e){if(e instanceof to)return e;var t=[];if(e)for(var n in e)t.push(n,e[n]);return new to(t)};class tl{constructor(e,t){if(this.content=e,this.size=t||0,null==t)for(let t=0;t<e.length;t++)this.size+=e[t].nodeSize}nodesBetween(e,t,n,i=0,r){for(let o=0,a=0;a<t;o++){let s=this.content[o],l=a+s.nodeSize;if(l>e&&!1!==n(s,i+a,r||null,o)&&s.content.size){let r=a+1;s.nodesBetween(Math.max(0,e-r),Math.min(s.content.size,t-r),n,i+r)}a=l}}descendants(e){this.nodesBetween(0,this.size,e)}textBetween(e,t,n,i){let r="",o=!0;return this.nodesBetween(e,t,(a,s)=>{let l=a.isText?a.text.slice(Math.max(e,s)-s,t-s):a.isLeaf?i?"function"==typeof i?i(a):i:a.type.spec.leafText?a.type.spec.leafText(a):"":"";a.isBlock&&(a.isLeaf&&l||a.isTextblock)&&n&&(o?o=!1:r+=n),r+=l},0),r}append(e){if(!e.size)return this;if(!this.size)return e;let t=this.lastChild,n=e.firstChild,i=this.content.slice(),r=0;for(t.isText&&t.sameMarkup(n)&&(i[i.length-1]=t.withText(t.text+n.text),r=1);r<e.content.length;r++)i.push(e.content[r]);return new tl(i,this.size+e.size)}cut(e,t=this.size){if(0==e&&t==this.size)return this;let n=[],i=0;if(t>e)for(let r=0,o=0;o<t;r++){let a=this.content[r],s=o+a.nodeSize;s>e&&((o<e||s>t)&&(a=a.isText?a.cut(Math.max(0,e-o),Math.min(a.text.length,t-o)):a.cut(Math.max(0,e-o-1),Math.min(a.content.size,t-o-1))),n.push(a),i+=a.nodeSize),o=s}return new tl(n,i)}cutByIndex(e,t){return e==t?tl.empty:0==e&&t==this.content.length?this:new tl(this.content.slice(e,t))}replaceChild(e,t){let n=this.content[e];if(n==t)return this;let i=this.content.slice(),r=this.size+t.nodeSize-n.nodeSize;return i[e]=t,new tl(i,r)}addToStart(e){return new tl([e].concat(this.content),this.size+e.nodeSize)}addToEnd(e){return new tl(this.content.concat(e),this.size+e.nodeSize)}eq(e){if(this.content.length!=e.content.length)return!1;for(let t=0;t<this.content.length;t++)if(!this.content[t].eq(e.content[t]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(e){let t=this.content[e];if(!t)throw RangeError("Index "+e+" out of range for "+this);return t}maybeChild(e){return this.content[e]||null}forEach(e){for(let t=0,n=0;t<this.content.length;t++){let i=this.content[t];e(i,n,t),n+=i.nodeSize}}findDiffStart(e,t=0){return function e(t,n,i){for(let r=0;;r++){if(r==t.childCount||r==n.childCount)return t.childCount==n.childCount?null:i;let o=t.child(r),a=n.child(r);if(o==a){i+=o.nodeSize;continue}if(!o.sameMarkup(a))return i;if(o.isText&&o.text!=a.text){let e=o.text,t=a.text,n=0;for(;e[n]==t[n];n++)i++;return n&&n<e.length&&n<t.length&&ts(e.charCodeAt(n-1))&&ta(e.charCodeAt(n))&&i--,i}if(o.content.size||a.content.size){let t=e(o.content,a.content,i+1);if(null!=t)return t}i+=o.nodeSize}}(this,e,t)}findDiffEnd(e,t=this.size,n=e.size){return function e(t,n,i,r){for(let o=t.childCount,a=n.childCount;;){if(0==o||0==a)return o==a?null:{a:i,b:r};let s=t.child(--o),l=n.child(--a),d=s.nodeSize;if(s==l){i-=d,r-=d;continue}if(!s.sameMarkup(l))return{a:i,b:r};if(s.isText&&s.text!=l.text){let e=s.text,t=l.text,n=e.length,o=t.length;for(;n>0&&o>0&&e[n-1]==t[o-1];)n--,o--,i--,r--;return n&&o&&n<e.length&&ts(e.charCodeAt(n-1))&&ta(e.charCodeAt(n))&&(i++,r++),{a:i,b:r}}if(s.content.size||l.content.size){let t=e(s.content,l.content,i-1,r-1);if(t)return t}i-=d,r-=d}}(this,e,t,n)}findIndex(e){if(0==e)return tu(0,e);if(e==this.size)return tu(this.content.length,e);if(e>this.size||e<0)throw RangeError(`Position ${e} outside of fragment (${this})`);for(let t=0,n=0;;t++){let i=n+this.child(t).nodeSize;if(i>=e){if(i==e)return tu(t+1,i);return tu(t,n)}n=i}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(e=>e.toJSON()):null}static fromJSON(e,t){if(!t)return tl.empty;if(!Array.isArray(t))throw RangeError("Invalid input for Fragment.fromJSON");return tl.fromArray(t.map(e.nodeFromJSON))}static fromArray(e){if(!e.length)return tl.empty;let t,n=0;for(let i=0;i<e.length;i++){let r=e[i];n+=r.nodeSize,i&&r.isText&&e[i-1].sameMarkup(r)?(t||(t=e.slice(0,i)),t[t.length-1]=r.withText(t[t.length-1].text+r.text)):t&&t.push(r)}return new tl(t||e,n)}static from(e){if(!e)return tl.empty;if(e instanceof tl)return e;if(Array.isArray(e))return this.fromArray(e);if(e.attrs)return new tl([e],e.nodeSize);throw RangeError("Can not convert "+e+" to a Fragment"+(e.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}tl.empty=new tl([],0);let td={index:0,offset:0};function tu(e,t){return td.index=e,td.offset=t,td}function tc(e,t){if(e===t)return!0;if(!(e&&"object"==typeof e)||!(t&&"object"==typeof t))return!1;let n=Array.isArray(e);if(Array.isArray(t)!=n)return!1;if(n){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!tc(e[n],t[n]))return!1}else{for(let n in e)if(!(n in t)||!tc(e[n],t[n]))return!1;for(let n in t)if(!(n in e))return!1}return!0}class th{constructor(e,t){this.type=e,this.attrs=t}addToSet(e){let t,n=!1;for(let i=0;i<e.length;i++){let r=e[i];if(this.eq(r))return e;if(this.type.excludes(r.type))t||(t=e.slice(0,i));else{if(r.type.excludes(this.type))return e;!n&&r.type.rank>this.type.rank&&(t||(t=e.slice(0,i)),t.push(this),n=!0),t&&t.push(r)}}return t||(t=e.slice()),n||t.push(this),t}removeFromSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return e.slice(0,t).concat(e.slice(t+1));return e}isInSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return!0;return!1}eq(e){return this==e||this.type==e.type&&tc(this.attrs,e.attrs)}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return e}static fromJSON(e,t){if(!t)throw RangeError("Invalid input for Mark.fromJSON");let n=e.marks[t.type];if(!n)throw RangeError(`There is no mark type ${t.type} in this schema`);let i=n.create(t.attrs);return n.checkAttrs(i.attrs),i}static sameSet(e,t){if(e==t)return!0;if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].eq(t[n]))return!1;return!0}static setFrom(e){if(!e||Array.isArray(e)&&0==e.length)return th.none;if(e instanceof th)return[e];let t=e.slice();return t.sort((e,t)=>e.type.rank-t.type.rank),t}}th.none=[];
vendor: 5,486 bytes, line 230
230class tp extends Error{}class tf{constructor(e,t,n){this.content=e,this.openStart=t,this.openEnd=n}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(e,t){let n=function e(t,n,i,r,o,a){let{index:s,offset:l}=t.findIndex(n),d=t.maybeChild(s);if(l==n||d.isText)return a&&r<=0&&o<=0&&!a.canReplace(s,s,i)?null:t.cut(0,n).append(i).append(t.cut(n));let u=e(d.content,n-l-1,i,0==s?r-1:0,s==t.childCount-1?o-1:0,d);return u&&t.replaceChild(s,d.copy(u))}(this.content,e+this.openStart,t,this.openStart+1,this.openEnd+1);return n&&new tf(n,this.openStart,this.openEnd)}removeBetween(e,t){return new tf(function e(t,n,i){let{index:r,offset:o}=t.findIndex(n),a=t.maybeChild(r),{index:s,offset:l}=t.findIndex(i);if(o==n||a.isText){if(l!=i&&!t.child(s).isText)throw RangeError("Removing non-flat range");return t.cut(0,n).append(t.cut(i))}if(r!=s)throw RangeError("Removing non-flat range");return t.replaceChild(r,a.copy(e(a.content,n-o-1,i-o-1)))}(this.content,e+this.openStart,t+this.openStart),this.openStart,this.openEnd)}eq(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e}static fromJSON(e,t){if(!t)return tf.empty;let n=t.openStart||0,i=t.openEnd||0;if("number"!=typeof n||"number"!=typeof i)throw RangeError("Invalid input for Slice.fromJSON");return new tf(tl.fromJSON(e,t.content),n,i)}static maxOpen(e,t=!0){let n=0,i=0;for(let i=e.firstChild;i&&!i.isLeaf&&(t||!i.type.spec.isolating);i=i.firstChild)n++;for(let n=e.lastChild;n&&!n.isLeaf&&(t||!n.type.spec.isolating);n=n.lastChild)i++;return new tf(e,n,i)}}function tg(e,t){if(!t.type.compatibleContent(e.type))throw new tp("Cannot join "+t.type.name+" onto "+e.type.name)}function tm(e,t,n){let i=e.node(n);return tg(i,t.node(n)),i}function tv(e,t){let n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function ty(e,t,n,i){let r=(t||e).node(n),o=0,a=t?t.index(n):r.childCount;e&&(o=e.index(n),e.depth>n?o++:e.textOffset&&(tv(e.nodeAfter,i),o++));for(let e=o;e<a;e++)tv(r.child(e),i);t&&t.depth==n&&t.textOffset&&tv(t.nodeBefore,i)}function tb(e,t){if(!e.type.validContent(t))throw new tp("Invalid content for node "+e.type.name);return e.copy(t)}function tx(e,t,n){let i=[];return ty(null,e,n,i),e.depth>n&&tv(tb(tm(e,t,n+1),tx(e,t,n+1)),i),ty(t,null,n,i),new tl(i)}tf.empty=new tf(tl.empty,0,0);class tw{constructor(e,t,n){this.pos=e,this.path=t,this.parentOffset=n,this.depth=t.length/3-1}resolveDepth(e){return null==e?this.depth:e<0?this.depth+e:e}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(e){return this.path[3*this.resolveDepth(e)]}index(e){return this.path[3*this.resolveDepth(e)+1]}indexAfter(e){return e=this.resolveDepth(e),this.index(e)+(e!=this.depth||this.textOffset?1:0)}start(e){return 0==(e=this.resolveDepth(e))?0:this.path[3*e-1]+1}end(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size}before(e){if(!(e=this.resolveDepth(e)))throw RangeError("There is no position before the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]}after(e){if(!(e=this.resolveDepth(e)))throw RangeError("There is no position after the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]+this.path[3*e].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let e=this.parent,t=this.index(this.depth);if(t==e.childCount)return null;let n=this.pos-this.path[this.path.length-1],i=e.child(t);return n?e.child(t).cut(n):i}get nodeBefore(){let e=this.index(this.depth),t=this.pos-this.path[this.path.length-1];return t?this.parent.child(e).cut(0,t):0==e?null:this.parent.child(e-1)}posAtIndex(e,t){t=this.resolveDepth(t);let n=this.path[3*t],i=0==t?0:this.path[3*t-1]+1;for(let t=0;t<e;t++)i+=n.child(t).nodeSize;return i}marks(){let e=this.parent,t=this.index();if(0==e.content.size)return th.none;if(this.textOffset)return e.child(t).marks;let n=e.maybeChild(t-1),i=e.maybeChild(t);if(!n){let e=n;n=i,i=e}let r=n.marks;for(var o=0;o<r.length;o++)!1!==r[o].type.spec.inclusive||i&&r[o].isInSet(i.marks)||(r=r[o--].removeFromSet(r));return r}marksAcross(e){let t=this.parent.maybeChild(this.index());if(!t||!t.isInline)return null;let n=t.marks,i=e.parent.maybeChild(e.index());for(var r=0;r<n.length;r++)!1!==n[r].type.spec.inclusive||i&&n[r].isInSet(i.marks)||(n=n[r--].removeFromSet(n));return n}sharedDepth(e){for(let t=this.depth;t>0;t--)if(this.start(t)<=e&&this.end(t)>=e)return t;return 0}blockRange(e=this,t){if(e.pos<this.pos)return e.blockRange(this);for(let n=this.depth-(this.parent.inlineContent||this.pos==e.pos?1:0);n>=0;n--)if(e.pos<=this.end(n)&&(!t||t(this.node(n))))return new tk(this,e,n);return null}sameParent(e){return this.pos-this.parentOffset==e.pos-e.parentOffset}max(e){return e.pos>this.pos?e:this}min(e){return e.pos<this.pos?e:this}toString(){let e="";for(let t=1;t<=this.depth;t++)e+=(e?"/":"")+this.node(t).type.name+"_"+this.index(t-1);return e+":"+this.parentOffset}static resolve(e,t){if(!(t>=0&&t<=e.content.size))throw RangeError("Position "+t+" out of range");let n=[],i=0,r=t;for(let t=e;;){let{index:e,offset:o}=t.content.findIndex(r),a=r-o;if(n.push(t,e,i+o),!a||(t=t.child(e)).isText)break;r=a-1,i+=o+1}return new tw(t,n,r)}
230static resolveCached(e,t){let n=t_.get(e);if(n)for(let e=0;e<n.elts.length;e++){let i=n.elts[e];if(i.pos==t)return i}else t_.set(e,n=new tC);let i=n.elts[n.i]=tw.resolve(e,t);return n.i=(n.i+1)%tS,i}}class tC{constructor(){this.elts=[],this.i=0}}let tS=12,t_=new WeakMap;class tk{constructor(e,t,n){this.$from=e,this.$to=t,this.depth=n}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}let tM=Object.create(null);class tT{constructor(e,t,n,i=th.none){this.type=e,this.attrs=t,this.marks=i,this.content=n||tl.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(e){return this.content.child(e)}maybeChild(e){return this.content.maybeChild(e)}forEach(e){this.content.forEach(e)}nodesBetween(e,t,n,i=0){this.content.nodesBetween(e,t,n,i,this)}descendants(e){this.nodesBetween(0,this.content.size,e)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(e,t,n,i){return this.content.textBetween(e,t,n,i)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)}sameMarkup(e){return this.hasMarkup(e.type,e.attrs,e.marks)}hasMarkup(e,t,n){return this.type==e&&tc(this.attrs,t||e.defaultAttrs||tM)&&th.sameSet(this.marks,n||th.none)}copy(e=null){return e==this.content?this:new tT(this.type,this.attrs,e,this.marks)}mark(e){return e==this.marks?this:new tT(this.type,this.attrs,this.content,e)}cut(e,t=this.content.size){return 0==e&&t==this.content.size?this:this.copy(this.content.cut(e,t))}slice(e,t=this.content.size,n=!1){if(e==t)return tf.empty;let i=this.resolve(e),r=this.resolve(t),o=n?0:i.sharedDepth(t),a=i.start(o);return new tf(i.node(o).content.cut(i.pos-a,r.pos-a),i.depth-o,r.depth-o)}replace(e,t,n){var i=this.resolve(e),r=this.resolve(t);if(n.openStart>i.depth)throw new tp("Inserted content deeper than insertion position");if(i.depth-n.openStart!=r.depth-n.openEnd)throw new tp("Inconsistent open depths");return function e(t,n,i,r){let o=t.index(r),a=t.node(r);if(o==n.index(r)&&r<t.depth-i.openStart){let s=e(t,n,i,r+1);return a.copy(a.content.replaceChild(o,s))}if(!i.content.size)return tb(a,tx(t,n,r));if(i.openStart||i.openEnd||t.depth!=r||n.depth!=r){let{start:e,end:o}=function(e,t){let n=t.depth-e.openStart,i=t.node(n).copy(e.content);for(let e=n-1;e>=0;e--)i=t.node(e).copy(tl.from(i));return{start:i.resolveNoCache(e.openStart+n),end:i.resolveNoCache(i.content.size-e.openEnd-n)}}(i,t);return tb(a,function e(t,n,i,r,o){let a=t.depth>o&&tm(t,n,o+1),s=r.depth>o&&tm(i,r,o+1),l=[];return ty(null,t,o,l),a&&s&&n.index(o)==i.index(o)?(tg(a,s),tv(tb(a,e(t,n,i,r,o+1)),l)):(a&&tv(tb(a,tx(t,n,o+1)),l),ty(n,i,o,l),s&&tv(tb(s,tx(i,r,o+1)),l)),ty(r,null,o,l),new tl(l)}(t,e,o,n,r))}{let e=t.parent,r=e.content;return tb(e,r.cut(0,t.parentOffset).append(i.content).append(r.cut(n.parentOffset)))}}(i,r,n,0)}nodeAt(e){for(let t=this;;){let{index:n,offset:i}=t.content.findIndex(e);if(!(t=t.maybeChild(n)))return null;if(i==e||t.isText)return t;e-=i+1}}childAfter(e){let{index:t,offset:n}=this.content.findIndex(e);return{node:this.content.maybeChild(t),index:t,offset:n}}childBefore(e){if(0==e)return{node:null,index:0,offset:0};let{index:t,offset:n}=this.content.findIndex(e);if(n<e)return{node:this.content.child(t),index:t,offset:n};let i=this.content.child(t-1);return{node:i,index:t-1,offset:n-i.nodeSize}}resolve(e){return tw.resolveCached(this,e)}resolveNoCache(e){return tw.resolve(this,e)}rangeHasMark(e,t,n){let i=!1;return t>e&&this.nodesBetween(e,t,e=>(n.isInSet(e.marks)&&(i=!0),!i)),i}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}
230toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let e=this.type.name;return this.content.size&&(e+="("+this.content.toStringInner()+")"),tR(this.marks,e)}contentMatchAt(e){let t=this.type.contentMatch.matchFragment(this.content,0,e);if(!t)throw Error("Called contentMatchAt on a node with invalid content");return t}canReplace(e,t,n=tl.empty,i=0,r=n.childCount){let o=this.contentMatchAt(e).matchFragment(n,i,r),a=o&&o.matchFragment(this.content,t);if(!a||!a.validEnd)return!1;for(let e=i;e<r;e++)if(!this.type.allowsMarks(n.child(e).marks))return!1;return!0}canReplaceWith(e,t,n,i){if(i&&!this.type.allowsMarks(i))return!1;let r=this.contentMatchAt(e).matchType(n),o=r&&r.matchFragment(this.content,t);return!!o&&o.validEnd}canAppend(e){return e.content.size?this.canReplace(this.childCount,this.childCount,e.content):this.type.compatibleContent(e.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let e=th.none;for(let t=0;t<this.marks.length;t++){let n=this.marks[t];n.type.checkAttrs(n.attrs),e=n.addToSet(e)}if(!th.sameSet(e,this.marks))throw RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(e=>e.type.name)}`);this.content.forEach(e=>e.check())}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return this.content.size&&(e.content=this.content.toJSON()),this.marks.length&&(e.marks=this.marks.map(e=>e.toJSON())),e}static fromJSON(e,t){let n;if(!t)throw RangeError("Invalid input for Node.fromJSON");if(t.marks){if(!Array.isArray(t.marks))throw RangeError("Invalid mark data for Node.fromJSON");n=t.marks.map(e.markFromJSON)}if("text"==t.type){if("string"!=typeof t.text)throw RangeError("Invalid text node in JSON");return e.text(t.text,n)}let i=tl.fromJSON(e,t.content),r=e.nodeType(t.type).create(t.attrs,i,n);return r.type.checkAttrs(r.attrs),r}}tT.prototype.text=void 0;class tD extends tT{constructor(e,t,n,i){if(super(e,t,null,i),!n)throw RangeError("Empty text nodes are not allowed");this.text=n}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):tR(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(e,t){return this.text.slice(e,t)}get nodeSize(){return this.text.length}mark(e){return e==this.marks?this:new tD(this.type,this.attrs,this.text,e)}withText(e){return e==this.text?this:new tD(this.type,this.attrs,e,this.marks)}cut(e=0,t=this.text.length){return 0==e&&t==this.text.length?this:this.withText(this.text.slice(e,t))}eq(e){return this.sameMarkup(e)&&this.text==e.text}toJSON(){let e=super.toJSON();return e.text=this.text,e}}function tR(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+"("+t+")";return t}class tI{constructor(e){this.validEnd=e,this.next=[],this.wrapCache=[]}static parse(e,t){var n;let i,r=new tA(e,t);if(null==r.next)return tI.empty;let o=function e(t){let n=[];do n.push(function(t){let n=[];do n.push(function(t){let n=function(t){if(t.eat("(")){let n=e(t);return t.eat(")")||t.err("Missing closing paren"),n}if(/\W/.test(t.next))t.err("Unexpected token '"+t.next+"'");else{let e=(function(e,t){let n=e.nodeTypes,i=n[t];if(i)return[i];let r=[];for(let e in n){let i=n[e];i.isInGroup(t)&&r.push(i)}return 0==r.length&&e.err("No node type or group '"+t+"' found"),r})(t,t.next).map(e=>(null==t.inline?t.inline=e.isInline:t.inline!=e.isInline&&t.err("Mixing inline and block content"),{type:"name",value:e}));return t.pos++,1==e.length?e[0]:{type:"choice",exprs:e}}}(t);for(;;)if(t.eat("+"))n={type:"plus",expr:n};else if(t.eat("*"))n={type:"star",expr:n};else if(t.eat("?"))n={type:"opt",expr:n};else if(t.eat("{"))n=function(e,t){let n=tP(e),i=n;return e.eat(",")&&(i="}"!=e.next?tP(e):-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:n,max:i,expr:t}}(t,n);else break;return n}(t));while(t.next&&")"!=t.next&&"|"!=t.next)return 1==n.length?n[0]:{type:"seq",exprs:n}}(t));while(t.eat("|"))return 1==n.length?n[0]:{type:"choice",exprs:n}}(r);r.next&&r.err("Unexpected trailing text");let a=(n=function(e){let t=[[]];return r(function e(t,o){if("choice"==t.type)return t.exprs.reduce((t,n)=>t.concat(e(n,o)),[]);if("seq"==t.type)for(let i=0;;i++){let a=e(t.exprs[i],o);if(i==t.exprs.length-1)return a;r(a,o=n())}else if("star"==t.type){let a=n();return i(o,a),r(e(t.expr,a),a),[i(a)]}else if("plus"==t.type){let a=n();return r(e(t.expr,o),a),r(e(t.expr,a),a),[i(a)]}else if("opt"==t.type)return[i(o)].concat(e(t.expr,o));else if("range"==t.type){let a=o;for(let i=0;i<t.min;i++){let i=n();r(e(t.expr,a),i),a=i}if(-1==t.max)r(e(t.expr,a),a);else for(let o=t.min;o<t.max;o++){let o=n();i(a,o),r(e(t.expr,a),o),a=o}return[i(a)]}else if("name"==t.type)return[i(o,void 0,t.value)];else throw Error("Unknown expr type")}(e,0),n()),t;function n(){return t.push([])-1}function i(e,n,i){let r={term:i,to:n};return t[e].push(r),r}
vendor: 5,572 bytes, line 230
230function r(e,t){e.forEach(e=>e.to=t)}}(o),i=Object.create(null),function e(t){let r=[];t.forEach(e=>{n[e].forEach(({term:e,to:t})=>{let i;if(e){for(let t=0;t<r.length;t++)r[t][0]==e&&(i=r[t][1]);tL(n,t).forEach(t=>{i||r.push([e,i=[]]),-1==i.indexOf(t)&&i.push(t)})}})});let o=i[t.join(",")]=new tI(t.indexOf(n.length-1)>-1);for(let t=0;t<r.length;t++){let n=r[t][1].sort(tE);o.next.push({type:r[t][0],next:i[n.join(",")]||e(n)})}return o}(tL(n,0)));return function(e,t){for(let n=0,i=[e];n<i.length;n++){let e=i[n],r=!e.validEnd,o=[];for(let t=0;t<e.next.length;t++){let{type:n,next:a}=e.next[t];o.push(n.name),r&&!(n.isText||n.hasRequiredAttrs())&&(r=!1),-1==i.indexOf(a)&&i.push(a)}r&&t.err("Only non-generatable nodes ("+o.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}(a,r),a}matchType(e){for(let t=0;t<this.next.length;t++)if(this.next[t].type==e)return this.next[t].next;return null}matchFragment(e,t=0,n=e.childCount){let i=this;for(let r=t;i&&r<n;r++)i=i.matchType(e.child(r).type);return i}get inlineContent(){return 0!=this.next.length&&this.next[0].type.isInline}get defaultType(){for(let e=0;e<this.next.length;e++){let{type:t}=this.next[e];if(!(t.isText||t.hasRequiredAttrs()))return t}return null}compatible(e){for(let t=0;t<this.next.length;t++)for(let n=0;n<e.next.length;n++)if(this.next[t].type==e.next[n].type)return!0;return!1}fillBefore(e,t=!1,n=0){let i=[this];return function r(o,a){let s=o.matchFragment(e,n);if(s&&(!t||s.validEnd))return tl.from(a.map(e=>e.createAndFill()));for(let e=0;e<o.next.length;e++){let{type:t,next:n}=o.next[e];if(!(t.isText||t.hasRequiredAttrs())&&-1==i.indexOf(n)){i.push(n);let e=r(n,a.concat(t));if(e)return e}}return null}(this,[])}findWrapping(e){for(let t=0;t<this.wrapCache.length;t+=2)if(this.wrapCache[t]==e)return this.wrapCache[t+1];let t=this.computeWrapping(e);return this.wrapCache.push(e,t),t}computeWrapping(e){let t=Object.create(null),n=[{match:this,type:null,via:null}];for(;n.length;){let i=n.shift(),r=i.match;if(r.matchType(e)){let e=[];for(let t=i;t.type;t=t.via)e.push(t.type);return e.reverse()}for(let e=0;e<r.next.length;e++){let{type:o,next:a}=r.next[e];o.isLeaf||o.hasRequiredAttrs()||o.name in t||i.type&&!a.validEnd||(n.push({match:o.contentMatch,type:o,via:i}),t[o.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(e){if(e>=this.next.length)throw RangeError(`There's no ${e}th edge in this content match`);return this.next[e]}toString(){let e=[];return!function t(n){e.push(n);for(let i=0;i<n.next.length;i++)-1==e.indexOf(n.next[i].next)&&t(n.next[i].next)}(this),e.map((t,n)=>{let i=n+(t.validEnd?"*":" ")+" ";for(let n=0;n<t.next.length;n++)i+=(n?", ":"")+t.next[n].type.name+"->"+e.indexOf(t.next[n].next);return i}).join("\n")}}tI.empty=new tI(!0);class tA{constructor(e,t){this.string=e,this.nodeTypes=t,this.inline=null,this.pos=0,this.tokens=e.split(/\s*(?=\b|\W|$)/),""==this.tokens[this.tokens.length-1]&&this.tokens.pop(),""==this.tokens[0]&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(e){return this.next==e&&(this.pos++||!0)}err(e){throw SyntaxError(e+" (in content expression '"+this.string+"')")}}function tP(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");let t=Number(e.next);return e.pos++,t}function tE(e,t){return t-e}function tL(e,t){let n=[];return function t(i){let r=e[i];if(1==r.length&&!r[0].term)return t(r[0].to);n.push(i);for(let e=0;e<r.length;e++){let{term:i,to:o}=r[e];i||-1!=n.indexOf(o)||t(o)}}(t),n.sort(tE)}function tF(e){let t=Object.create(null);for(let n in e){let i=e[n];if(!i.hasDefault)return null;t[n]=i.default}return t}function tO(e,t){let n=Object.create(null);for(let i in e){let r=t&&t[i];if(void 0===r){let t=e[i];if(t.hasDefault)r=t.default;else throw RangeError("No value supplied for attribute "+i)}n[i]=r}return n}function tN(e,t,n,i){for(let r in t)if(!(r in e))throw RangeError(`Unsupported attribute ${r} for ${n} of type ${i}`);for(let n in e)e[n].validate&&e[n].validate(t[n])}function tB(e,t){let n=Object.create(null);if(t)for(let i in t)n[i]=new tj(e,i,t[i]);return n}class tz{constructor(e,t,n){this.name=e,this.schema=t,this.spec=n,this.markSet=null,this.groups=n.group?n.group.split(" "):[],this.attrs=tB(e,n.attrs),this.defaultAttrs=tF(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(n.inline||"text"==e),this.isText="text"==e}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==tI.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(e){return this.groups.indexOf(e)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let e in this.attrs)if(this.attrs[e].isRequired)return!0;return!1}compatibleContent(e){return this==e||this.contentMatch.compatible(e.contentMatch)}computeAttrs(e){return!e&&this.defaultAttrs?this.defaultAttrs:tO(this.attrs,e)}create(e=null,t,n){if(this.isText)throw Error("NodeType.create can't construct text nodes");return new tT(this,this.computeAttrs(e),tl.from(t),th.setFrom(n))}createChecked(e=null,t,n){return t=tl.from(t),this.checkContent(t),new tT(this,this.computeAttrs(e),t,th.setFrom(n))}createAndFill(e=null,t,n){if(e=this.computeAttrs(e),(t=tl.from(t)).size){let e=this.contentMatch.fillBefore(t);if(!e)return null;t=e.append(t)}let i=this.contentMatch.matchFragment(t),r=i&&i.fillBefore(tl.empty,!0);return r?new tT(this,e,t.append(r),th.setFrom(n)):null}validContent(e){let t=this.contentMatch.matchFragment(e);
230if(!t||!t.validEnd)return!1;for(let t=0;t<e.childCount;t++)if(!this.allowsMarks(e.child(t).marks))return!1;return!0}checkContent(e){if(!this.validContent(e))throw RangeError(`Invalid content for node ${this.name}: ${e.toString().slice(0,50)}`)}checkAttrs(e){tN(this.attrs,e,"node",this.name)}allowsMarkType(e){return null==this.markSet||this.markSet.indexOf(e)>-1}allowsMarks(e){if(null==this.markSet)return!0;for(let t=0;t<e.length;t++)if(!this.allowsMarkType(e[t].type))return!1;return!0}allowedMarks(e){let t;if(null==this.markSet)return e;for(let n=0;n<e.length;n++)this.allowsMarkType(e[n].type)?t&&t.push(e[n]):t||(t=e.slice(0,n));return t?t.length?t:th.none:e}static compile(e,t){let n=Object.create(null);e.forEach((e,i)=>n[e]=new tz(e,t,i));let i=t.spec.topNode||"doc";if(!n[i])throw RangeError("Schema is missing its top node type ('"+i+"')");if(!n.text)throw RangeError("Every schema needs a 'text' type");for(let e in n.text.attrs)throw RangeError("The text node type should not have attributes");return n}}class tj{constructor(e,t,n){this.hasDefault=Object.prototype.hasOwnProperty.call(n,"default"),this.default=n.default,this.validate="string"==typeof n.validate?function(e,t,n){let i=n.split("|");return n=>{let r=null===n?"null":typeof n;if(0>i.indexOf(r))throw RangeError(`Expected value of type ${i} for attribute ${t} on type ${e}, got ${r}`)}}(e,t,n.validate):n.validate}get isRequired(){return!this.hasDefault}}class tV{constructor(e,t,n,i){this.name=e,this.rank=t,this.schema=n,this.spec=i,this.attrs=tB(e,i.attrs),this.excluded=null;let r=tF(this.attrs);this.instance=r?new th(this,r):null}create(e=null){return!e&&this.instance?this.instance:new th(this,tO(this.attrs,e))}static compile(e,t){let n=Object.create(null),i=0;return e.forEach((e,r)=>n[e]=new tV(e,i++,t,r)),n}removeFromSet(e){for(var t=0;t<e.length;t++)e[t].type==this&&(e=e.slice(0,t).concat(e.slice(t+1)),t--);return e}isInSet(e){for(let t=0;t<e.length;t++)if(e[t].type==this)return e[t]}checkAttrs(e){tN(this.attrs,e,"mark",this.name)}excludes(e){return this.excluded.indexOf(e)>-1}}class tH{constructor(e){this.linebreakReplacement=null,this.cached=Object.create(null);let t=this.spec={};for(let n in e)t[n]=e[n];t.nodes=to.from(e.nodes),t.marks=to.from(e.marks||{}),this.nodes=tz.compile(this.spec.nodes,this),this.marks=tV.compile(this.spec.marks,this);let n=Object.create(null);for(let e in this.nodes){if(e in this.marks)throw RangeError(e+" can not be both a node and a mark");let t=this.nodes[e],i=t.spec.content||"",r=t.spec.marks;if(t.contentMatch=n[i]||(n[i]=tI.parse(i,this.nodes)),t.inlineContent=t.contentMatch.inlineContent,t.spec.linebreakReplacement){if(this.linebreakReplacement)throw RangeError("Multiple linebreak nodes defined");if(!t.isInline||!t.isLeaf)throw RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=t}t.markSet="_"==r?null:r?tG(this,r.split(" ")):""!=r&&t.inlineContent?null:[]}for(let e in this.marks){let t=this.marks[e],n=t.spec.excludes;t.excluded=null==n?[t]:""==n?[]:tG(this,n.split(" "))}this.nodeFromJSON=e=>tT.fromJSON(this,e),this.markFromJSON=e=>th.fromJSON(this,e),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(e,t=null,n,i){if("string"==typeof e)e=this.nodeType(e);else if(e instanceof tz){if(e.schema!=this)throw RangeError("Node type from different schema used ("+e.name+")")}else throw RangeError("Invalid node type: "+e);return e.createChecked(t,n,i)}text(e,t){let n=this.nodes.text;return new tD(n,n.defaultAttrs,e,th.setFrom(t))}mark(e,t){return"string"==typeof e&&(e=this.marks[e]),e.create(t)}nodeType(e){let t=this.nodes[e];if(!t)throw RangeError("Unknown node type: "+e);return t}}function tG(e,t){let n=[];for(let i=0;i<t.length;i++){let r=t[i],o=e.marks[r],a=o;if(o)n.push(o);else for(let t in e.marks){let i=e.marks[t];("_"==r||i.spec.group&&i.spec.group.split(" ").indexOf(r)>-1)&&n.push(a=i)}if(!a)throw SyntaxError("Unknown mark type: '"+t[i]+"'")}return n}class tW{constructor(e,t){this.schema=e,this.rules=t,this.tags=[],this.styles=[];let n=this.matchedStyles=[];
230t.forEach(e=>{if(null!=e.tag)this.tags.push(e);else if(null!=e.style){let t=/[^=]*/.exec(e.style)[0];0>n.indexOf(t)&&n.push(t),this.styles.push(e)}}),this.normalizeLists=!this.tags.some(t=>{if(!/^(ul|ol)\b/.test(t.tag)||!t.node)return!1;let n=e.nodes[t.node];return n.contentMatch.matchType(n)})}parse(e,t={}){let n=new tZ(this,t,!1);return n.addAll(e,th.none,t.from,t.to),n.finish()}parseSlice(e,t={}){let n=new tZ(this,t,!0);return n.addAll(e,th.none,t.from,t.to),tf.maxOpen(n.finish())}matchTag(e,t,n){for(let o=n?this.tags.indexOf(n)+1:0;o<this.tags.length;o++){var i,r;let n=this.tags[o];if(i=e,r=n.tag,(i.matches||i.msMatchesSelector||i.webkitMatchesSelector||i.mozMatchesSelector).call(i,r)&&(void 0===n.namespace||e.namespaceURI==n.namespace)&&(!n.context||t.matchesContext(n.context))){if(n.getAttrs){let t=n.getAttrs(e);if(!1===t)continue;n.attrs=t||void 0}return n}}}matchStyle(e,t,n,i){for(let r=i?this.styles.indexOf(i)+1:0;r<this.styles.length;r++){let i=this.styles[r],o=i.style;if(0==o.indexOf(e)&&(!i.context||n.matchesContext(i.context))&&(!(o.length>e.length)||61==o.charCodeAt(e.length)&&o.slice(e.length+1)==t)){if(i.getAttrs){let e=i.getAttrs(t);if(!1===e)continue;i.attrs=e||void 0}return i}}}static schemaRules(e){let t=[];function n(e){let n=null==e.priority?50:e.priority,i=0;for(;i<t.length;i++){let e=t[i];if((null==e.priority?50:e.priority)<n)break}t.splice(i,0,e)}for(let t in e.marks){let i=e.marks[t].spec.parseDOM;i&&i.forEach(e=>{n(e=tX(e)),e.mark||e.ignore||e.clearMark||(e.mark=t)})}for(let t in e.nodes){let i=e.nodes[t].spec.parseDOM;i&&i.forEach(e=>{n(e=tX(e)),e.node||e.ignore||e.mark||(e.node=t)})}return t}static fromSchema(e){return e.cached.domParser||(e.cached.domParser=new tW(e,tW.schemaRules(e)))}}let t$={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},tU={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},tq={ol:!0,ul:!0};function tK(e,t,n){return null!=t?!!t|2*("full"===t):e&&"pre"==e.whitespace?3:-5&n}class tY{constructor(e,t,n,i,r,o){this.type=e,this.attrs=t,this.marks=n,this.solid=i,this.options=o,this.content=[],this.activeMarks=th.none,this.match=r||(4&o?null:e.contentMatch)}findWrapping(e){if(!this.match){if(!this.type)return[];let t=this.type.contentMatch.fillBefore(tl.from(e));if(t)this.match=this.type.contentMatch.matchFragment(t);else{let t=this.type.contentMatch,n;return(n=t.findWrapping(e.type))?(this.match=t,n):null}}return this.match.findWrapping(e.type)}finish(e){if(!(1&this.options)){let e=this.content[this.content.length-1],t;e&&e.isText&&(t=/[ \t\r\n\u000c]+$/.exec(e.text))&&(e.text.length==t[0].length?this.content.pop():this.content[this.content.length-1]=e.withText(e.text.slice(0,e.text.length-t[0].length)))}let t=tl.from(this.content);return!e&&this.match&&(t=t.append(this.match.fillBefore(tl.empty,!0))),this.type?this.type.create(this.attrs,t,this.marks):t}inlineContext(e){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:e.parentNode&&!t$.hasOwnProperty(e.parentNode.nodeName.toLowerCase())}}class tZ{constructor(e,t,n){this.parser=e,this.options=t,this.isOpen=n,this.open=0,this.localPreserveWS=!1;let i=t.topNode,r,o=tK(null,t.preserveWhitespace,0)|4*!!n;r=i?new tY(i.type,i.attrs,th.none,!0,t.topMatch||i.type.contentMatch,o):n?new tY(null,null,th.none,!0,null,o):new tY(e.schema.topNodeType,null,th.none,!0,null,o),this.nodes=[r],this.find=t.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(e,t){3==e.nodeType?this.addTextNode(e,t):1==e.nodeType&&this.addElement(e,t)}addTextNode(e,t){let n=e.nodeValue,i=this.top,r=2&i.options?"full":this.localPreserveWS||(1&i.options)>0,{schema:o}=this.parser;if("full"===r||i.inlineContext(e)||/[^ \t\r\n\u000c]/.test(n)){if(r)if("full"===r)n=n.replace(/\r\n?/g,"\n");else if(o.linebreakReplacement&&/[\r\n]/.test(n)&&this.top.findWrapping(o.linebreakReplacement.create())){let e=n.split(/\r?\n|\r/);for(let n=0;n<e.length;n++)n&&this.insertNode(o.linebreakReplacement.create(),t,!0),e[n]&&this.insertNode(o.text(e[n]),t,!/\S/.test(e[n]));n=""}else n=n.replace(/\r?\n|\r/g," ");else if(n=n.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(n)&&this.open==this.nodes.length-1){let t=i.content[i.content.length-1],r=e.previousSibling;
vendor: 6,001 bytes, line 230
230(!t||r&&"BR"==r.nodeName||t.isText&&/[ \t\r\n\u000c]$/.test(t.text))&&(n=n.slice(1))}n&&this.insertNode(o.text(n),t,!/\S/.test(n)),this.findInText(e)}else this.findInside(e)}addElement(e,t,n){let i=this.localPreserveWS,r=this.top;("PRE"==e.tagName||/pre/.test(e.style&&e.style.whiteSpace))&&(this.localPreserveWS=!0);let o=e.nodeName.toLowerCase(),a;tq.hasOwnProperty(o)&&this.parser.normalizeLists&&function(e){for(let t=e.firstChild,n=null;t;t=t.nextSibling){let e=1==t.nodeType?t.nodeName.toLowerCase():null;e&&tq.hasOwnProperty(e)&&n?(n.appendChild(t),t=n):"li"==e?n=t:e&&(n=null)}}(e);let s=this.options.ruleFromNode&&this.options.ruleFromNode(e)||(a=this.parser.matchTag(e,this,n));e:if(s?s.ignore:tU.hasOwnProperty(o))this.findInside(e),this.ignoreFallback(e,t);else if(!s||s.skip||s.closeParent){s&&s.closeParent?this.open=Math.max(0,this.open-1):s&&s.skip.nodeType&&(e=s.skip);let n,i=this.needsBlock;if(t$.hasOwnProperty(o))r.content.length&&r.content[0].isInline&&this.open&&(this.open--,r=this.top),n=!0,r.type||(this.needsBlock=!0);else if(!e.firstChild){this.leafFallback(e,t);break e}let a=s&&s.skip?t:this.readStyles(e,t);a&&this.addAll(e,a),n&&this.sync(r),this.needsBlock=i}else{let n=this.readStyles(e,t);n&&this.addElementByRule(e,s,n,!1===s.consuming?a:void 0)}this.localPreserveWS=i}leafFallback(e,t){"BR"==e.nodeName&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(e.ownerDocument.createTextNode("\n"),t)}ignoreFallback(e,t){"BR"!=e.nodeName||this.top.type&&this.top.type.inlineContent||this.findPlace(this.parser.schema.text("-"),t,!0)}readStyles(e,t){let n=e.style;if(n&&n.length)for(let e=0;e<this.parser.matchedStyles.length;e++){let i=this.parser.matchedStyles[e],r=n.getPropertyValue(i);if(r)for(let e;;){let n=this.parser.matchStyle(i,r,this,e);if(!n)break;if(n.ignore)return null;if(t=n.clearMark?t.filter(e=>!n.clearMark(e)):t.concat(this.parser.schema.marks[n.mark].create(n.attrs)),!1===n.consuming)e=n;else break}}return t}addElementByRule(e,t,n,i){let r,o;if(t.node)if((o=this.parser.schema.nodes[t.node]).isLeaf)this.insertNode(o.create(t.attrs),n,"BR"==e.nodeName)||this.leafFallback(e,n);else{let e=this.enter(o,t.attrs||null,n,t.preserveWhitespace);e&&(r=!0,n=e)}else{let e=this.parser.schema.marks[t.mark];n=n.concat(e.create(t.attrs))}let a=this.top;if(o&&o.isLeaf)this.findInside(e);else if(i)this.addElement(e,n,i);else if(t.getContent)this.findInside(e),t.getContent(e,this.parser.schema).forEach(e=>this.insertNode(e,n,!1));else{let i=e;"string"==typeof t.contentElement?i=e.querySelector(t.contentElement):"function"==typeof t.contentElement?i=t.contentElement(e):t.contentElement&&(i=t.contentElement),this.findAround(e,i,!0),this.addAll(i,n),this.findAround(e,i,!1)}r&&this.sync(a)&&this.open--}addAll(e,t,n,i){let r=n||0;for(let o=n?e.childNodes[n]:e.firstChild,a=null==i?null:e.childNodes[i];o!=a;o=o.nextSibling,++r)this.findAtPoint(e,r),this.addDOM(o,t);this.findAtPoint(e,r)}findPlace(e,t,n){let i,r;for(let t=this.open,o=0;t>=0;t--){let a=this.nodes[t],s=a.findWrapping(e);if(s&&(!i||i.length>s.length+o)&&(i=s,r=a,!s.length))break;if(a.solid){if(n)break;o+=2}}if(!i)return null;this.sync(r);for(let e=0;e<i.length;e++)t=this.enterInner(i[e],null,t,!1);return t}insertNode(e,t,n){if(e.isInline&&this.needsBlock&&!this.top.type){let e=this.textblockFromContext();e&&(t=this.enterInner(e,null,t))}let i=this.findPlace(e,t,n);if(i){this.closeExtra();let t=this.top;t.match&&(t.match=t.match.matchType(e.type));let n=th.none;for(let r of i.concat(e.marks))(t.type?t.type.allowsMarkType(r.type):tJ(r.type,e.type))&&(n=r.addToSet(n));return t.content.push(e.mark(n)),!0}return!1}enter(e,t,n,i){let r=this.findPlace(e.create(t),n,!1);return r&&(r=this.enterInner(e,t,n,!0,i)),r}enterInner(e,t,n,i=!1,r){this.closeExtra();let o=this.top;o.match=o.match&&o.match.matchType(e);let a=tK(e,r,o.options);4&o.options&&0==o.content.length&&(a|=4);let s=th.none;return n=n.filter(t=>(o.type?!o.type.allowsMarkType(t.type):!tJ(t.type,e))||(s=t.addToSet(s),!1)),this.nodes.push(new tY(e,t,s,i,null,a)),this.open++,n}closeExtra(e=!1){let t=this.nodes.length-1;if(t>this.open){for(;t>this.open;t--)this.nodes[t-1].content.push(this.nodes[t].finish(e));this.nodes.length=this.open+1}}finish(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(!!(this.isOpen||this.options.topOpen))}sync(e){for(let t=this.open;t>=0;t--)if(this.nodes[t]==e)return this.open=t,!0;else this.localPreserveWS&&(this.nodes[t].options|=1);return!1}get currentPos(){this.closeExtra();let e=0;for(let t=this.open;t>=0;t--){let n=this.nodes[t].content;for(let t=n.length-1;t>=0;t--)e+=n[t].nodeSize;t&&e++}return e}findAtPoint(e,t){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].node==e&&this.find[n].offset==t&&(this.find[n].pos=this.currentPos)}findInside(e){if(this.find)for(let t=0;t<this.find.length;t++)null==this.find[t].pos&&1==e.nodeType&&e.contains(this.find[t].node)&&(this.find[t].pos=this.currentPos)}findAround(e,t,n){if(e!=t&&this.find)for(let i=0;i<this.find.length;i++)null==this.find[i].pos&&1==e.nodeType&&e.contains(this.find[i].node)&&t.compareDocumentPosition(this.find[i].node)&(n?2:4)&&(this.find[i].pos=this.currentPos)}findInText(e){if(this.find)for(let t=0;t<this.find.length;t++)this.find[t].node==e&&(this.find[t].pos=this.currentPos-(e.nodeValue.length-this.find[t].offset))}matchesContext(e){if(e.indexOf("|")>-1)return e.split(/\s*\|\s*/).some(this.matchesContext,this);let t=e.split("/"),n=this.options.context,i=!this.isOpen&&(!n||n.parent.type==this.nodes[0].type),r=-(n?n.depth+1:0)+ +!i,o=(e,a)=>{for(;e>=0;e--){let s=t[e];if(""==s){if(e==t.length-1||0==e)continue;for(;a>=r;a--)if(o(e-1,a))return!0;return!1}{let e=a>0||0==a&&i?this.nodes[a].type:n&&a>=r?n.node(a-r).type:null;if(!e||e.name!=s&&!e.isInGroup(s))return!1;a--}}return!0};return o(t.length-1,this.open)}textblockFromContext(){let e=this.options.context;if(e)for(let t=e.depth;t>=0;t--){let n=e.node(t).contentMatchAt(e.indexAfter(t)).defaultType;
230if(n&&n.isTextblock&&n.defaultAttrs)return n}for(let e in this.parser.schema.nodes){let t=this.parser.schema.nodes[e];if(t.isTextblock&&t.defaultAttrs)return t}}}function tX(e){let t={};for(let n in e)t[n]=e[n];return t}function tJ(e,t){let n=t.schema.nodes;for(let i in n){let r=n[i];if(!r.allowsMarkType(e))continue;let o=[],a=e=>{o.push(e);for(let n=0;n<e.edgeCount;n++){let{type:i,next:r}=e.edge(n);if(i==t||0>o.indexOf(r)&&a(r))return!0}};if(a(r.contentMatch))return!0}}class tQ{constructor(e,t){this.nodes=e,this.marks=t}serializeFragment(e,t={},n){n||(n=t1(t).createDocumentFragment());let i=n,r=[];return e.forEach(e=>{if(r.length||e.marks.length){let n=0,o=0;for(;n<r.length&&o<e.marks.length;){let t=e.marks[o];if(!this.marks[t.type.name]){o++;continue}if(!t.eq(r[n][0])||!1===t.type.spec.spanning)break;n++,o++}for(;n<r.length;)i=r.pop()[1];for(;o<e.marks.length;){let n=e.marks[o++],a=this.serializeMark(n,e.isInline,t);a&&(r.push([n,i]),i.appendChild(a.dom),i=a.contentDOM||a.dom)}}i.appendChild(this.serializeNodeInner(e,t))}),n}serializeNodeInner(e,t){if(e.isText)return t1(t).createTextNode(e.text);let{dom:n,contentDOM:i}=t3(t1(t),this.nodes[e.type.name](e),null,e.attrs);if(i){if(e.isLeaf)throw RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(e.content,t,i)}return n}serializeNode(e,t={}){let n=this.serializeNodeInner(e,t);for(let i=e.marks.length-1;i>=0;i--){let r=this.serializeMark(e.marks[i],e.isInline,t);r&&((r.contentDOM||r.dom).appendChild(n),n=r.dom)}return n}serializeMark(e,t,n={}){let i=this.marks[e.type.name];return i&&t3(t1(n),i(e,t),null,e.attrs)}static renderSpec(e,t,n=null,i){return"string"==typeof t?{dom:e.createTextNode(t)}:t3(e,t,n,i)}static fromSchema(e){return e.cached.domSerializer||(e.cached.domSerializer=new tQ(this.nodesFromSchema(e),this.marksFromSchema(e)))}static nodesFromSchema(e){let t=t0(e.nodes);return t.text||(t.text=e=>e.text),t}static marksFromSchema(e){return t0(e.marks)}}function t0(e){let t={};for(let n in e){let i=e[n].spec.toDOM;i&&(t[n]=i)}return t}function t1(e){return e.document||window.document}let t2=new WeakMap;function t3(e,t,n,i){let r,o,a;if(1==t.nodeType)return{dom:t};if(t.dom&&1==t.dom.nodeType)return t;let s=t[0],l;if("string"!=typeof s)throw RangeError("Invalid array passed to renderSpec");if(i&&(void 0===(o=t2.get(i))&&t2.set(i,(a=null,!function e(t){if(t&&"object"==typeof t)if(Array.isArray(t))if("string"==typeof t[0])a||(a=[]),a.push(t);else for(let n=0;n<t.length;n++)e(t[n]);else for(let n in t)e(t[n])}(i),o=a)),l=o)&&l.indexOf(t)>-1)throw RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");let d=s.indexOf(" ");d>0&&(n=s.slice(0,d),s=s.slice(d+1));let u=n?e.createElementNS(n,s):e.createElement(s),c=t[1],h=1;if(c&&"object"==typeof c&&null==c.nodeType&&!Array.isArray(c)){for(let e in h=2,c)if(null!=c[e]){let t=e.indexOf(" ");t>0?u.setAttributeNS(e.slice(0,t),e.slice(t+1),c[e]):"style"==e&&u.style?u.style.cssText=c[e]:u.setAttribute(e,c[e])}}for(let o=h;o<t.length;o++){let a=t[o];if(0===a){if(o<t.length-1||o>h)throw RangeError("Content hole must be the only child of its parent node");return{dom:u,contentDOM:u}}if("string"==typeof a)u.appendChild(e.createTextNode(a));else{let{dom:t,contentDOM:o}=t3(e,a,n,i);if(u.appendChild(t),o){if(r)throw RangeError("Multiple content holes");r=o}}}return{dom:u,contentDOM:r}}class t5{constructor(e,t,n){this.pos=e,this.delInfo=t,this.recover=n}get deleted(){return(8&this.delInfo)>0}get deletedBefore(){return(5&this.delInfo)>0}get deletedAfter(){return(6&this.delInfo)>0}get deletedAcross(){return(4&this.delInfo)>0}}class t4{constructor(e,t=!1){if(this.ranges=e,this.inverted=t,!e.length&&t4.empty)return t4.empty}recover(e){let t=0,n=65535&e;if(!this.inverted)for(let e=0;e<n;e++)t+=this.ranges[3*e+2]-this.ranges[3*e+1];return this.ranges[3*n]+t+(e-(65535&e))/65536}mapResult(e,t=1){return this._map(e,t,!1)}map(e,t=1){return this._map(e,t,!0)}_map(e,t,n){let i=0,r=this.inverted?2:1,o=this.inverted?1:2;for(let a=0;a<this.ranges.length;a+=3){let s=this.ranges[a]-(this.inverted?i:0);if(s>e)break;let l=this.ranges[a+r],d=this.ranges[a+o],u=s+l;if(e<=u){let r=l?e==s?-1:e==u?1:t:t,o=s+i+(r<0?0:d);if(n)return o;
vendor: 4,155 bytes, line 230
230let c=e==(t<0?s:u)?null:a/3+(e-s)*65536,h=e==s?2:e==u?1:4;return(t<0?e!=s:e!=u)&&(h|=8),new t5(o,h,c)}i+=d-l}return n?e+i:new t5(e+i,0,null)}touches(e,t){let n=0,i=65535&t,r=this.inverted?2:1,o=this.inverted?1:2;for(let t=0;t<this.ranges.length;t+=3){let a=this.ranges[t]-(this.inverted?n:0);if(a>e)break;let s=this.ranges[t+r];if(e<=a+s&&t==3*i)return!0;n+=this.ranges[t+o]-s}return!1}forEach(e){let t=this.inverted?2:1,n=this.inverted?1:2;for(let i=0,r=0;i<this.ranges.length;i+=3){let o=this.ranges[i],a=o-(this.inverted?r:0),s=o+(this.inverted?0:r),l=this.ranges[i+t],d=this.ranges[i+n];e(a,a+l,s,s+d),r+=d-l}}invert(){return new t4(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(e){return 0==e?t4.empty:new t4(e<0?[0,-e,0]:[0,0,e])}}t4.empty=new t4([]);class t6{constructor(e,t,n=0,i=e?e.length:0){this.mirror=t,this.from=n,this.to=i,this._maps=e||[],this.ownData=!(e||t)}get maps(){return this._maps}slice(e=0,t=this.maps.length){return new t6(this._maps,this.mirror,e,t)}appendMap(e,t){this.ownData||(this._maps=this._maps.slice(),this.mirror=this.mirror&&this.mirror.slice(),this.ownData=!0),this.to=this._maps.push(e),null!=t&&this.setMirror(this._maps.length-1,t)}appendMapping(e){for(let t=0,n=this._maps.length;t<e._maps.length;t++){let i=e.getMirror(t);this.appendMap(e._maps[t],null!=i&&i<t?n+i:void 0)}}getMirror(e){if(this.mirror){for(let t=0;t<this.mirror.length;t++)if(this.mirror[t]==e)return this.mirror[t+(t%2?-1:1)]}}setMirror(e,t){this.mirror||(this.mirror=[]),this.mirror.push(e,t)}appendMappingInverted(e){for(let t=e.maps.length-1,n=this._maps.length+e._maps.length;t>=0;t--){let i=e.getMirror(t);this.appendMap(e._maps[t].invert(),null!=i&&i>t?n-i-1:void 0)}}invert(){let e=new t6;return e.appendMappingInverted(this),e}map(e,t=1){if(this.mirror)return this._map(e,t,!0);for(let n=this.from;n<this.to;n++)e=this._maps[n].map(e,t);return e}mapResult(e,t=1){return this._map(e,t,!1)}_map(e,t,n){let i=0;for(let n=this.from;n<this.to;n++){let r=this._maps[n].mapResult(e,t);if(null!=r.recover){let t=this.getMirror(n);if(null!=t&&t>n&&t<this.to){n=t,e=this._maps[t].recover(r.recover);continue}}i|=r.delInfo,e=r.pos}return n?e:new t5(e,i,null)}}let t8=Object.create(null);class t7{getMap(){return t4.empty}merge(e){return null}static fromJSON(e,t){if(!t||!t.stepType)throw RangeError("Invalid input for Step.fromJSON");let n=t8[t.stepType];if(!n)throw RangeError(`No step type ${t.stepType} defined`);return n.fromJSON(e,t)}static jsonID(e,t){if(e in t8)throw RangeError("Duplicate use of step JSON ID "+e);return t8[e]=t,t.prototype.jsonID=e,t}}class t9{constructor(e,t){this.doc=e,this.failed=t}static ok(e){return new t9(e,null)}static fail(e){return new t9(null,e)}static fromReplace(e,t,n,i){try{return t9.ok(e.replace(t,n,i))}catch(e){if(e instanceof tp)return t9.fail(e.message);throw e}}}function ne(e,t,n){let i=[];for(let r=0;r<e.childCount;r++){let o=e.child(r);o.content.size&&(o=o.copy(ne(o.content,t,o))),o.isInline&&(o=t(o,n,r)),i.push(o)}return tl.fromArray(i)}class nt extends t7{constructor(e,t,n){super(),this.from=e,this.to=t,this.mark=n}apply(e){let t=e.slice(this.from,this.to),n=e.resolve(this.from),i=n.node(n.sharedDepth(this.to)),r=new tf(ne(t.content,(e,t)=>e.isAtom&&t.type.allowsMarkType(this.mark.type)?e.mark(this.mark.addToSet(e.marks)):e,i),t.openStart,t.openEnd);return t9.fromReplace(e,this.from,this.to,r)}invert(){return new nn(this.from,this.to,this.mark)}map(e){let t=e.mapResult(this.from,1),n=e.mapResult(this.to,-1);return t.deleted&&n.deleted||t.pos>=n.pos?null:new nt(t.pos,n.pos,this.mark)}merge(e){return e instanceof nt&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from?new nt(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to)throw RangeError("Invalid input for AddMarkStep.fromJSON");return new nt(t.from,t.to,e.markFromJSON(t.mark))}}t7.jsonID("addMark",nt);class nn extends t7{constructor(e,t,n){super(),this.from=e,this.to=t,this.mark=n}
vendor: 13,145 bytes, line 230
230apply(e){let t=e.slice(this.from,this.to),n=new tf(ne(t.content,e=>e.mark(this.mark.removeFromSet(e.marks)),e),t.openStart,t.openEnd);return t9.fromReplace(e,this.from,this.to,n)}invert(){return new nt(this.from,this.to,this.mark)}map(e){let t=e.mapResult(this.from,1),n=e.mapResult(this.to,-1);return t.deleted&&n.deleted||t.pos>=n.pos?null:new nn(t.pos,n.pos,this.mark)}merge(e){return e instanceof nn&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from?new nn(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to)throw RangeError("Invalid input for RemoveMarkStep.fromJSON");return new nn(t.from,t.to,e.markFromJSON(t.mark))}}t7.jsonID("removeMark",nn);class ni extends t7{constructor(e,t){super(),this.pos=e,this.mark=t}apply(e){let t=e.nodeAt(this.pos);if(!t)return t9.fail("No node at mark step's position");let n=t.type.create(t.attrs,null,this.mark.addToSet(t.marks));return t9.fromReplace(e,this.pos,this.pos+1,new tf(tl.from(n),0,+!t.isLeaf))}invert(e){let t=e.nodeAt(this.pos);if(t){let e=this.mark.addToSet(t.marks);if(e.length==t.marks.length){for(let n=0;n<t.marks.length;n++)if(!t.marks[n].isInSet(e))return new ni(this.pos,t.marks[n]);return new ni(this.pos,this.mark)}}return new nr(this.pos,this.mark)}map(e){let t=e.mapResult(this.pos,1);return t.deletedAfter?null:new ni(t.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(e,t){if("number"!=typeof t.pos)throw RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new ni(t.pos,e.markFromJSON(t.mark))}}t7.jsonID("addNodeMark",ni);class nr extends t7{constructor(e,t){super(),this.pos=e,this.mark=t}apply(e){let t=e.nodeAt(this.pos);if(!t)return t9.fail("No node at mark step's position");let n=t.type.create(t.attrs,null,this.mark.removeFromSet(t.marks));return t9.fromReplace(e,this.pos,this.pos+1,new tf(tl.from(n),0,+!t.isLeaf))}invert(e){let t=e.nodeAt(this.pos);return t&&this.mark.isInSet(t.marks)?new ni(this.pos,this.mark):this}map(e){let t=e.mapResult(this.pos,1);return t.deletedAfter?null:new nr(t.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(e,t){if("number"!=typeof t.pos)throw RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new nr(t.pos,e.markFromJSON(t.mark))}}t7.jsonID("removeNodeMark",nr);class no extends t7{constructor(e,t,n,i=!1){super(),this.from=e,this.to=t,this.slice=n,this.structure=i}apply(e){return this.structure&&ns(e,this.from,this.to)?t9.fail("Structure replace would overwrite content"):t9.fromReplace(e,this.from,this.to,this.slice)}getMap(){return new t4([this.from,this.to-this.from,this.slice.size])}invert(e){return new no(this.from,this.from+this.slice.size,e.slice(this.from,this.to))}map(e){let t=e.mapResult(this.to,-1),n=this.from==this.to&&no.MAP_BIAS<0?t:e.mapResult(this.from,1);return n.deletedAcross&&t.deletedAcross?null:new no(n.pos,Math.max(n.pos,t.pos),this.slice,this.structure)}merge(e){if(!(e instanceof no)||e.structure||this.structure)return null;if(this.from+this.slice.size!=e.from||this.slice.openEnd||e.slice.openStart)if(e.to!=this.from||this.slice.openStart||e.slice.openEnd)return null;else{let t=this.slice.size+e.slice.size==0?tf.empty:new tf(e.slice.content.append(this.slice.content),e.slice.openStart,this.slice.openEnd);return new no(e.from,this.to,t,this.structure)}{let t=this.slice.size+e.slice.size==0?tf.empty:new tf(this.slice.content.append(e.slice.content),this.slice.openStart,e.slice.openEnd);return new no(this.from,this.to+(e.to-e.from),t,this.structure)}}toJSON(){let e={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to)throw RangeError("Invalid input for ReplaceStep.fromJSON");return new no(t.from,t.to,tf.fromJSON(e,t.slice),!!t.structure)}}no.MAP_BIAS=1,t7.jsonID("replace",no);class na extends t7{constructor(e,t,n,i,r,o,a=!1){super(),this.from=e,this.to=t,this.gapFrom=n,this.gapTo=i,this.slice=r,this.insert=o,this.structure=a}apply(e){if(this.structure&&(ns(e,this.from,this.gapFrom)||ns(e,this.gapTo,this.to)))return t9.fail("Structure gap-replace would overwrite content");let t=e.slice(this.gapFrom,this.gapTo);if(t.openStart||t.openEnd)return t9.fail("Gap is not a flat range");let n=this.slice.insertAt(this.insert,t.content);return n?t9.fromReplace(e,this.from,this.to,n):t9.fail("Content does not fit in gap")}getMap(){return new t4([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(e){let t=this.gapTo-this.gapFrom;return new na(this.from,this.from+this.slice.size+t,this.from+this.insert,this.from+this.insert+t,e.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(e){let t=e.mapResult(this.from,1),n=e.mapResult(this.to,-1),i=this.from==this.gapFrom?t.pos:e.map(this.gapFrom,-1),r=this.to==this.gapTo?n.pos:e.map(this.gapTo,1);return t.deletedAcross&&n.deletedAcross||i<t.pos||r>n.pos?null:new na(t.pos,n.pos,i,r,this.slice,this.insert,this.structure)}toJSON(){let e={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to||"number"!=typeof t.gapFrom||"number"!=typeof t.gapTo||"number"!=typeof t.insert)throw RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new na(t.from,t.to,t.gapFrom,t.gapTo,tf.fromJSON(e,t.slice),t.insert,!!t.structure)}}function ns(e,t,n){let i=e.resolve(t),r=n-t,o=i.depth;for(;r>0&&o>0&&i.indexAfter(o)==i.node(o).childCount;)o--,r--;if(r>0){let e=i.node(o).maybeChild(i.indexAfter(o));for(;r>0;){if(!e||e.isLeaf)return!0;e=e.firstChild,r--}}return!1}function nl(e,t,n,i=n.contentMatch,r=!0){let o=e.doc.nodeAt(t),a=[],s=t+1;for(let t=0;t<o.childCount;t++){let l=o.child(t),d=s+l.nodeSize,u=i.matchType(l.type);if(u){i=u;for(let t=0;t<l.marks.length;t++)n.allowsMarkType(l.marks[t].type)||e.step(new nn(s,d,l.marks[t]));if(r&&l.isText&&"pre"!=n.whitespace){let e,t=/\r?\n|\r/g,i;for(;e=t.exec(l.text);)i||(i=new tf(tl.from(n.schema.text(" ",n.allowedMarks(l.marks))),0,0)),a.push(new no(s+e.index,s+e.index+e[0].length,i))}}else a.push(new no(s,d,tf.empty));s=d}if(!i.validEnd){let t=i.fillBefore(tl.empty,!0);e.replace(s,s,new tf(t,0,0))}for(let t=a.length-1;t>=0;t--)e.step(a[t])}function nd(e){let t=e.parent.content.cutByIndex(e.startIndex,e.endIndex);for(let n=e.depth,i=0,r=0;;--n){let o=e.$from.node(n),a=e.$from.index(n)+i,s=e.$to.indexAfter(n)-r;if(n<e.depth&&o.canReplace(a,s,t))return n;if(0==n||o.type.spec.isolating||!((0==a||o.canReplace(a,o.childCount))&&(s==o.childCount||o.canReplace(0,s))))break;a&&(i=1),s<o.childCount&&(r=1)}return null}function nu(e,t,n=null,i=e){let r=function(e,t){let{parent:n,startIndex:i,endIndex:r}=e,o=n.contentMatchAt(i).findWrapping(t);if(!o)return null;let a=o.length?o[0]:t;return n.canReplaceWith(i,r,a)?o:null}(e,t),o=r&&function(e,t){let{parent:n,startIndex:i,endIndex:r}=e,o=n.child(i),a=t.contentMatch.findWrapping(o.type);if(!a)return null;let s=(a.length?a[a.length-1]:t).contentMatch;for(let e=i;s&&e<r;e++)s=s.matchType(n.child(e).type);return s&&s.validEnd?a:null}(i,t);return o?r.map(nc).concat({type:t,attrs:n}).concat(o.map(nc)):null}function nc(e){return{type:e,attrs:null}}function nh(e,t,n,i){t.forEach((r,o)=>{if(r.isText){let a,s=/\r?\n|\r/g;for(;a=s.exec(r.text);){let r=e.mapping.slice(i).map(n+1+o+a.index);e.replaceWith(r,r+1,t.type.schema.linebreakReplacement.create())}}})}function np(e,t,n,i){t.forEach((r,o)=>{if(r.type==r.type.schema.linebreakReplacement){let r=e.mapping.slice(i).map(n+1+o);e.replaceWith(r,r+1,t.type.schema.text("\n"))}})}function nf(e,t,n=1,i){let r=e.resolve(t),o=r.depth-n,a=i&&i[i.length-1]||r.parent;if(o<0||r.parent.type.spec.isolating||!r.parent.canReplace(r.index(),r.parent.childCount)||!a.type.validContent(r.parent.content.cutByIndex(r.index(),r.parent.childCount)))return!1;for(let e=r.depth-1,t=n-2;e>o;e--,t--){let n=r.node(e),o=r.index(e);if(n.type.spec.isolating)return!1;let a=n.content.cutByIndex(o,n.childCount),s=i&&i[t+1];s&&(a=a.replaceChild(0,s.type.create(s.attrs)));let l=i&&i[t]||n;if(!n.canReplace(o+1,n.childCount)||!l.type.validContent(a))return!1}let s=r.indexAfter(o),l=i&&i[0];return r.node(o).canReplaceWith(s,s,l?l.type:r.node(o+1).type)}function ng(e,t){let n=e.resolve(t),i=n.index();return nm(n.nodeBefore,n.nodeAfter)&&n.parent.canReplace(i,i+1)}function nm(e,t){return!!(e&&t&&!e.isLeaf&&function(e,t){t.content.size||e.type.compatibleContent(t.type);let n=e.contentMatchAt(e.childCount),{linebreakReplacement:i}=e.type.schema;for(let r=0;r<t.childCount;r++){let o=t.child(r),a=o.type==i?e.type.schema.nodes.text:o.type;if(!(n=n.matchType(a))||!e.type.allowsMarks(o.marks))return!1}return n.validEnd}(e,t))}function nv(e,t,n=-1){let i=e.resolve(t);for(let e=i.depth;;e--){let r,o,a=i.index(e);if(e==i.depth?(r=i.nodeBefore,o=i.nodeAfter):n>0?(r=i.node(e+1),a++,o=i.node(e).maybeChild(a)):(r=i.node(e).maybeChild(a-1),o=i.node(e+1)),r&&!r.isTextblock&&nm(r,o)&&i.node(e).canReplace(a,a+1))return t;if(0==e)break;t=n<0?i.before(e):i.after(e)}}function ny(e,t,n){let i=e.resolve(t);if(!n.content.size)return t;let r=n.content;for(let e=0;e<n.openStart;e++)r=r.firstChild.content;for(let e=1;e<=(0==n.openStart&&n.size?2:1);e++)for(let t=i.depth;t>=0;t--){let n=t==i.depth?0:i.pos<=(i.start(t+1)+i.end(t+1))/2?-1:1,o=i.index(t)+ +(n>0),a=i.node(t),s=!1;if(1==e)s=a.canReplace(o,o,r);else{let e=a.contentMatchAt(o).findWrapping(r.firstChild.type);s=e&&a.canReplaceWith(o,o,e[0])}if(s)return 0==n?i.pos:n<0?i.before(t+1):i.after(t+1)}return null}function nb(e,t,n=t,i=tf.empty){if(t==n&&!i.size)return null;let r=e.resolve(t),o=e.resolve(n);return nx(r,o,i)?new no(t,n,i):new nw(r,o,i).fit()}function nx(e,t,n){return!n.openStart&&!n.openEnd&&e.start()==t.start()&&e.parent.canReplace(e.index(),t.index(),n.content)}t7.jsonID("replaceAround",na);class nw{constructor(e,t,n){this.$from=e,this.$to=t,this.unplaced=n,this.frontier=[],this.placed=tl.empty;for(let t=0;t<=e.depth;t++){let n=e.node(t);this.frontier.push({type:n.type,match:n.contentMatchAt(e.indexAfter(t))})}for(let t=e.depth;t>0;t--)this.placed=tl.from(e.node(t).copy(this.placed))}get depth(){return this.frontier.length-1}fit(){for(;this.unplaced.size;){let e=this.findFittable();e?this.placeNodes(e):this.openMore()||this.dropNode()}let e=this.mustMoveInline(),t=this.placed.size-this.depth-this.$from.depth,n=this.$from,i=this.close(e<0?this.$to:n.doc.resolve(e));if(!i)return null;let r=this.placed,o=n.depth,a=i.depth;for(;o&&a&&1==r.childCount;)r=r.firstChild.content,o--,a--;let s=new tf(r,o,a);return e>-1?new na(n.pos,e,this.$to.pos,this.$to.end(),s,t):s.size||n.pos!=this.$to.pos?new no(n.pos,i.pos,s):null}findFittable(){let e=this.unplaced.openStart;for(let t=this.unplaced.content,n=0,i=this.unplaced.openEnd;n<e;n++){let r=t.firstChild;if(t.childCount>1&&(i=0),r.type.spec.isolating&&i<=n){e=n;break}t=r.content}for(let t=1;t<=2;t++)for(let n=1==t?e:this.unplaced.openStart;n>=0;n--){let e=null,i=(n?(e=n_(this.unplaced.content,n-1).firstChild).content:this.unplaced.content).firstChild;for(let r=this.depth;r>=0;r--){let{type:o,match:a}=this.frontier[r],s,l=null;if(1==t&&(i?a.matchType(i.type)||(l=a.fillBefore(tl.from(i),!1)):e&&o.compatibleContent(e.type)))return{sliceDepth:n,frontierDepth:r,parent:e,inject:l};if(2==t&&i&&(s=a.findWrapping(i.type)))return{sliceDepth:n,frontierDepth:r,parent:e,wrap:s};if(e&&a.matchType(e.type))break}}}openMore(){let{content:e,openStart:t,openEnd:n}=this.unplaced,i=n_(e,t);return!!i.childCount&&!i.firstChild.isLeaf&&(this.unplaced=new tf(e,t+1,Math.max(n,i.size+t>=e.size-n?t+1:0)),!0)}dropNode(){let{content:e,openStart:t,openEnd:n}=this.unplaced,i=n_(e,t);if(i.childCount<=1&&t>0){let r=e.size-t<=t+i.size;this.unplaced=new tf(nC(e,t-1,1),t-1,r?t-1:n)}else this.unplaced=new tf(nC(e,t,1),t,n)}placeNodes({sliceDepth:e,frontierDepth:t,parent:n,inject:i,wrap:r}){for(;this.depth>t;)this.closeFrontierNode();if(r)for(let e=0;e<r.length;e++)this.openFrontierNode(r[e]);let o=this.unplaced,a=n?n.content:o.content,s=o.openStart-e,l=0,d=[],{match:u,type:c}=this.frontier[t];if(i){for(let e=0;e<i.childCount;e++)d.push(i.child(e));u=u.matchFragment(i)}let h=a.size+e-(o.content.size-o.openEnd);for(;l<a.childCount;){let e=a.child(l),t=u.matchType(e.type);if(!t)break;(++l>1||0==s||e.content.size)&&(u=t,d.push(function e(t,n,i){if(n<=0)return t;let r=t.content;return n>1&&(r=r.replaceChild(0,e(r.firstChild,n-1,1==r.childCount?i-1:0))),n>0&&(r=t.type.contentMatch.fillBefore(r).append(r),i<=0&&(r=r.append(t.type.contentMatch.matchFragment(r).fillBefore(tl.empty,!0)))),t.copy(r)}(e.mark(c.allowedMarks(e.marks)),1==l?s:0,l==a.childCount?h:-1)))}
vendor: 2,143 bytes, line 230
230let p=l==a.childCount;p||(h=-1),this.placed=nS(this.placed,t,tl.from(d)),this.frontier[t].match=u,p&&h<0&&n&&n.type==this.frontier[this.depth].type&&this.frontier.length>1&&this.closeFrontierNode();for(let e=0,t=a;e<h;e++){let e=t.lastChild;this.frontier.push({type:e.type,match:e.contentMatchAt(e.childCount)}),t=e.content}this.unplaced=p?0==e?tf.empty:new tf(nC(o.content,e-1,1),e-1,h<0?o.openEnd:e-1):new tf(nC(o.content,e,l),o.openStart,o.openEnd)}mustMoveInline(){if(!this.$to.parent.isTextblock)return -1;let e=this.frontier[this.depth],t;if(!e.type.isTextblock||!nk(this.$to,this.$to.depth,e.type,e.match,!1)||this.$to.depth==this.depth&&(t=this.findCloseLevel(this.$to))&&t.depth==this.depth)return -1;let{depth:n}=this.$to,i=this.$to.after(n);for(;n>1&&i==this.$to.end(--n);)++i;return i}findCloseLevel(e){t:for(let t=Math.min(this.depth,e.depth);t>=0;t--){let{match:n,type:i}=this.frontier[t],r=t<e.depth&&e.end(t+1)==e.pos+(e.depth-(t+1)),o=nk(e,t,i,n,r);if(o){for(let n=t-1;n>=0;n--){let{match:t,type:i}=this.frontier[n],r=nk(e,n,i,t,!0);if(!r||r.childCount)continue t}return{depth:t,fit:o,move:r?e.doc.resolve(e.after(t+1)):e}}}}close(e){let t=this.findCloseLevel(e);if(!t)return null;for(;this.depth>t.depth;)this.closeFrontierNode();t.fit.childCount&&(this.placed=nS(this.placed,t.depth,t.fit)),e=t.move;for(let n=t.depth+1;n<=e.depth;n++){let t=e.node(n),i=t.type.contentMatch.fillBefore(t.content,!0,e.index(n));this.openFrontierNode(t.type,t.attrs,i)}return e}openFrontierNode(e,t=null,n){let i=this.frontier[this.depth];i.match=i.match.matchType(e),this.placed=nS(this.placed,this.depth,tl.from(e.create(t,n))),this.frontier.push({type:e,match:e.contentMatch})}closeFrontierNode(){let e=this.frontier.pop().match.fillBefore(tl.empty,!0);e.childCount&&(this.placed=nS(this.placed,this.frontier.length,e))}}function nC(e,t,n){return 0==t?e.cutByIndex(n,e.childCount):e.replaceChild(0,e.firstChild.copy(nC(e.firstChild.content,t-1,n)))}function nS(e,t,n){return 0==t?e.append(n):e.replaceChild(e.childCount-1,e.lastChild.copy(nS(e.lastChild.content,t-1,n)))}function n_(e,t){for(let n=0;n<t;n++)e=e.firstChild.content;return e}
230function nk(e,t,n,i,r){let o=e.node(t),a=r?e.indexAfter(t):e.index(t);if(a==o.childCount&&!n.compatibleContent(o.type))return null;let s=i.fillBefore(o.content,!0,a);return s&&!function(e,t,n){for(let i=n;i<t.childCount;i++)if(!e.allowsMarks(t.child(i).marks))return!0;return!1}(n,o.content,a)?s:null}function nM(e,t){let n=[],i=Math.min(e.depth,t.depth);for(let r=i;r>=0;r--){let i=e.start(r);if(i<e.pos-(e.depth-r)||t.end(r)>t.pos+(t.depth-r)||e.node(r).type.spec.isolating||t.node(r).type.spec.isolating)break;(i==t.start(r)||r==e.depth&&r==t.depth&&e.parent.inlineContent&&t.parent.inlineContent&&r&&t.start(r-1)==i-1)&&n.push(r)}return n}class nT extends t7{constructor(e,t,n){super(),this.pos=e,this.attr=t,this.value=n}apply(e){let t=e.nodeAt(this.pos);if(!t)return t9.fail("No node at attribute step's position");let n=Object.create(null);for(let e in t.attrs)n[e]=t.attrs[e];n[this.attr]=this.value;let i=t.type.create(n,null,t.marks);return t9.fromReplace(e,this.pos,this.pos+1,new tf(tl.from(i),0,+!t.isLeaf))}getMap(){return t4.empty}invert(e){return new nT(this.pos,this.attr,e.nodeAt(this.pos).attrs[this.attr])}map(e){let t=e.mapResult(this.pos,1);return t.deletedAfter?null:new nT(t.pos,this.attr,this.value)}toJSON(){return{stepType:"attr",pos:this.pos,attr:this.attr,value:this.value}}static fromJSON(e,t){if("number"!=typeof t.pos||"string"!=typeof t.attr)throw RangeError("Invalid input for AttrStep.fromJSON");return new nT(t.pos,t.attr,t.value)}}t7.jsonID("attr",nT);class nD extends t7{constructor(e,t){super(),this.attr=e,this.value=t}apply(e){let t=Object.create(null);for(let n in e.attrs)t[n]=e.attrs[n];t[this.attr]=this.value;let n=e.type.create(t,e.content,e.marks);return t9.ok(n)}getMap(){return t4.empty}invert(e){return new nD(this.attr,e.attrs[this.attr])}map(e){return this}toJSON(){return{stepType:"docAttr",attr:this.attr,value:this.value}}static fromJSON(e,t){if("string"!=typeof t.attr)throw RangeError("Invalid input for DocAttrStep.fromJSON");return new nD(t.attr,t.value)}}t7.jsonID("docAttr",nD);let nR=class extends Error{};(nR=function e(t){let n=Error.call(this,t);return n.__proto__=e.prototype,n}).prototype=Object.create(Error.prototype),nR.prototype.constructor=nR,nR.prototype.name="TransformError";class nI{constructor(e){this.doc=e,this.steps=[],this.docs=[],this.mapping=new t6}get before(){return this.docs.length?this.docs[0]:this.doc}step(e){let t=this.maybeStep(e);if(t.failed)throw new nR(t.failed);return this}maybeStep(e){let t=e.apply(this.doc);return t.failed||this.addStep(e,t.doc),t}get docChanged(){return this.steps.length>0}changedRange(){let e=1e9,t=-1e9;for(let n=0;n<this.mapping.maps.length;n++){let i=this.mapping.maps[n];
230n&&(e=i.map(e,1),t=i.map(t,-1)),i.forEach((n,i,r,o)=>{e=Math.min(e,r),t=Math.max(t,o)})}return 1e9==e?null:{from:e,to:t}}addStep(e,t){this.docs.push(this.doc),this.steps.push(e),this.mapping.appendMap(e.getMap()),this.doc=t}replace(e,t=e,n=tf.empty){let i=nb(this.doc,e,t,n);return i&&this.step(i),this}replaceWith(e,t,n){return this.replace(e,t,new tf(tl.from(n),0,0))}delete(e,t){return this.replace(e,t,tf.empty)}insert(e,t){return this.replaceWith(e,e,t)}replaceRange(e,t,n){return!function(e,t,n,i){if(!i.size)return e.deleteRange(t,n);let r=e.doc.resolve(t),o=e.doc.resolve(n);if(nx(r,o,i))return e.step(new no(t,n,i));let a=nM(r,o);0==a[a.length-1]&&a.pop();let s=-(r.depth+1);a.unshift(s);for(let e=r.depth,t=r.pos-1;e>0;e--,t--){let n=r.node(e).type.spec;if(n.defining||n.definingAsContext||n.isolating)break;a.indexOf(e)>-1?s=e:r.before(e)==t&&a.splice(1,0,-e)}let l=a.indexOf(s),d=[],u=i.openStart;for(let e=i.content,t=0;;t++){let n=e.firstChild;if(d.push(n),t==i.openStart)break;e=n.content}for(let e=u-1;e>=0;e--){var c;let t=d[e],n=(c=t.type).spec.defining||c.spec.definingForContent;if(n&&!t.sameMarkup(r.node(Math.abs(s)-1)))u=e;else if(n||!t.type.isTextblock)break}for(let t=i.openStart;t>=0;t--){let s=(t+u+1)%(i.openStart+1),c=d[s];if(c)for(let t=0;t<a.length;t++){let d=a[(t+l)%a.length],u=!0;d<0&&(u=!1,d=-d);let h=r.node(d-1),p=r.index(d-1);if(h.canReplaceWith(p,p,c.type,c.marks))return e.replace(r.before(d),u?o.after(d):n,new tf(function e(t,n,i,r,o){if(n<i){let o=t.firstChild;t=t.replaceChild(0,o.copy(e(o.content,n+1,i,r,o)))}if(n>r){let e=o.contentMatchAt(0),n=e.fillBefore(t).append(t);t=n.append(e.matchFragment(n).fillBefore(tl.empty,!0))}return t}(i.content,0,i.openStart,s),s,i.openEnd))}}let h=e.steps.length;for(let s=a.length-1;s>=0&&(e.replace(t,n,i),!(e.steps.length>h));s--){let e=a[s];e<0||(t=r.before(e),n=o.after(e))}}(this,e,t,n),this}replaceRangeWith(e,t,n){var i=e,r=t;if(!n.isInline&&i==r&&this.doc.resolve(i).parent.content.size){let e=function(e,t,n){let i=e.resolve(t);if(i.parent.canReplaceWith(i.index(),i.index(),n))return t;if(0==i.parentOffset)for(let e=i.depth-1;e>=0;e--){let t=i.index(e);if(i.node(e).canReplaceWith(t,t,n))return i.before(e+1);if(t>0)return null}if(i.parentOffset==i.parent.content.size)for(let e=i.depth-1;e>=0;e--){let t=i.indexAfter(e);if(i.node(e).canReplaceWith(t,t,n))return i.after(e+1);if(t<i.node(e).childCount)break}return null}(this.doc,i,n.type);null!=e&&(i=r=e)}return this.replaceRange(i,r,new tf(tl.from(n),0,0)),this}deleteRange(e,t){return!function(e,t,n){let i=e.doc.resolve(t),r=e.doc.resolve(n);if(i.parent.isTextblock&&r.parent.isTextblock&&i.start()!=r.start()&&0==i.parentOffset&&0==r.parentOffset){let o=i.sharedDepth(n),a=!1;for(let e=i.depth;e>o;e--)i.node(e).type.spec.isolating&&(a=!0);for(let e=r.depth;e>o;e--)r.node(e).type.spec.isolating&&(a=!0);if(!a){for(let e=i.depth;e>0&&t==i.start(e);e--)t=i.before(e);for(let e=r.depth;e>0&&n==r.start(e);e--)n=r.before(e);i=e.doc.resolve(t),r=e.doc.resolve(n)}}let o=nM(i,r);for(let t=0;t<o.length;t++){let n=o[t],a=t==o.length-1;if(a&&0==n||i.node(n).type.contentMatch.validEnd)return e.delete(i.start(n),r.end(n));if(n>0&&(a||i.node(n-1).canReplace(i.index(n-1),r.indexAfter(n-1))))return e.delete(i.before(n),r.after(n))}for(let o=1;o<=i.depth&&o<=r.depth;o++)if(t-i.start(o)==i.depth-o&&n>i.end(o)&&r.end(o)-n!=r.depth-o&&i.start(o-1)==r.start(o-1)&&i.node(o-1).canReplace(i.index(o-1),r.index(o-1)))return e.delete(i.before(o),n);e.delete(t,n)}(this,e,t),this}lift(e,t){return!function(e,t,n){let{$from:i,$to:r,depth:o}=t,a=i.before(o+1),s=r.after(o+1),l=a,d=s,u=tl.empty,c=0;for(let e=o,t=!1;e>n;e--)t||i.index(e)>0?(t=!0,u=tl.from(i.node(e).copy(u)),c++):l--;let h=tl.empty,p=0;for(let e=o,t=!1;e>n;e--)t||r.after(e+1)<r.end(e)?(t=!0,h=tl.from(r.node(e).copy(h)),p++):d++;e.step(new na(l,d,a,s,new tf(u.append(h),c,p),u.size-c,!0))}(this,e,t),this}join(e,t=1){return!function(e,t,n){let i=null,{linebreakReplacement:r}=e.doc.type.schema,o=e.doc.resolve(t-n),a=o.node().type;if(r&&a.inlineContent){let e="pre"==a.whitespace,t=!!a.contentMatch.matchType(r);e&&!t?i=!1:!e&&t&&(i=!0)}let s=e.steps.length;if(!1===i){let i=e.doc.resolve(t+n);np(e,i.node(),i.before(),s)}a.inlineContent&&nl(e,t+n-1,a,o.node().contentMatchAt(o.index()),null==i);let l=e.mapping.slice(s),d=l.map(t-n);if(e.step(new no(d,l.map(t+n,-1),tf.empty,!0)),!0===i){let t=e.doc.resolve(d);nh(e,t.node(),t.before(),e.steps.length)}}(this,e,t),this}wrap(e,t){return!function(e,t,n){let i=tl.empty;for(let e=n.length-1;e>=0;e--){if(i.size){let t=n[e].type.contentMatch.matchFragment(i);if(!t||!t.validEnd)throw RangeError("Wrapper type given to Transform.wrap does not form valid content of its parent wrapper")}i=tl.from(n[e].type.create(n[e].attrs,i))}let r=t.start,o=t.end;e.step(new na(r,o,r,o,new tf(i,0,0),n.length,!0))}(this,e,t),this}setBlockType(e,t=e,n,i=null){var r=this;if(!n.isTextblock)throw RangeError("Type given to setBlockType should be a textblock");let o=r.steps.length;return r.doc.nodesBetween(e,t,(e,t)=>{var a,s,l;let d,u,c="function"==typeof i?i(e):i;if(e.isTextblock&&!e.hasMarkup(n,c)&&(a=r.doc,s=r.mapping.slice(o).map(t),l=n,u=(d=a.resolve(s)).index(),d.parent.canReplaceWith(u,u+1,l))){let i=null;if(n.schema.linebreakReplacement){let e="pre"==n.whitespace,t=!!n.contentMatch.matchType(n.schema.linebreakReplacement);e&&!t?i=!1:!e&&t&&(i=!0)}!1===i&&np(r,e,t,o),nl(r,r.mapping.slice(o).map(t,1),n,void 0,null===i);let a=r.mapping.slice(o),s=a.map(t,1),l=a.map(t+e.nodeSize,1);return r.step(new na(s,l,s+1,l-1,new tf(tl.from(n.create(c,null,e.marks)),0,0),1,!0)),!0===i&&nh(r,e,t,o),!1}}),this}setNodeMarkup(e,t,n=null,i){return!function(e,t,n,i,r){let o=e.doc.nodeAt(t);if(!o)throw RangeError("No node at given position");n||(n=o.type);let a=n.create(i,null,r||o.marks);if(o.isLeaf)return e.replaceWith(t,t+o.nodeSize,a);if(!n.validContent(o.content))throw RangeError("Invalid content for node type "+n.name);e.step(new na(t,t+o.nodeSize,t+1,t+o.nodeSize-1,new tf(tl.from(a),0,0),1,!0))}(this,e,t,n,i),this}setNodeAttribute(e,t,n){return this.step(new nT(e,t,n)),this}setDocAttribute(e,t){return this.step(new nD(e,t)),this}addNodeMark(e,t){return this.step(new ni(e,t)),this}
230removeNodeMark(e,t){let n=this.doc.nodeAt(e);if(!n)throw RangeError("No node at position "+e);if(t instanceof th)t.isInSet(n.marks)&&this.step(new nr(e,t));else{let i=n.marks,r,o=[];for(;r=t.isInSet(i);)o.push(new nr(e,r)),i=r.removeFromSet(i);for(let e=o.length-1;e>=0;e--)this.step(o[e])}return this}split(e,t=1,n){return!function(e,t,n=1,i){let r=e.doc.resolve(t),o=tl.empty,a=tl.empty;for(let e=r.depth,t=r.depth-n,s=n-1;e>t;e--,s--){o=tl.from(r.node(e).copy(o));let t=i&&i[s];a=tl.from(t?t.type.create(t.attrs,a):r.node(e).copy(a))}e.step(new no(t,t,new tf(o.append(a),n,n),!0))}(this,e,t,n),this}addMark(e,t,n){var i;let r,o,a,s;return i=this,a=[],s=[],i.doc.nodesBetween(e,t,(i,l,d)=>{if(!i.isInline)return;let u=i.marks;if(!n.isInSet(u)&&d.type.allowsMarkType(n.type)){let d=Math.max(l,e),c=Math.min(l+i.nodeSize,t),h=n.addToSet(u);for(let e=0;e<u.length;e++)u[e].isInSet(h)||(r&&r.to==d&&r.mark.eq(u[e])?r.to=c:a.push(r=new nn(d,c,u[e])));o&&o.to==d?o.to=c:s.push(o=new nt(d,c,n))}}),a.forEach(e=>i.step(e)),s.forEach(e=>i.step(e)),this}removeMark(e,t,n){var i;let r,o;return i=this,r=[],o=0,i.doc.nodesBetween(e,t,(i,a)=>{if(!i.isInline)return;o++;let s=null;if(n instanceof tV){let e=i.marks,t;for(;t=n.isInSet(e);)(s||(s=[])).push(t),e=t.removeFromSet(e)}else n?n.isInSet(i.marks)&&(s=[n]):s=i.marks;if(s&&s.length){let n=Math.min(a+i.nodeSize,t);for(let t=0;t<s.length;t++){let i=s[t],l;for(let e=0;e<r.length;e++){let t=r[e];t.step==o-1&&i.eq(r[e].style)&&(l=t)}l?(l.to=n,l.step=o):r.push({style:i,from:Math.max(a,e),to:n,step:o})}}}),r.forEach(e=>i.step(new nn(e.from,e.to,e.style))),this}clearIncompatible(e,t,n){return nl(this,e,t,n),this}}let nA=Object.create(null);class nP{constructor(e,t,n){this.$anchor=e,this.$head=t,this.ranges=n||[new nE(e.min(t),e.max(t))]}get anchor(){return this.$anchor.pos}get head(){return this.$head.pos}get from(){return this.$from.pos}get to(){return this.$to.pos}get $from(){return this.ranges[0].$from}get $to(){return this.ranges[0].$to}get empty(){let e=this.ranges;for(let t=0;t<e.length;t++)if(e[t].$from.pos!=e[t].$to.pos)return!1;return!0}content(){return this.$from.doc.slice(this.from,this.to,!0)}replace(e,t=tf.empty){let n=t.content.lastChild,i=null;for(let e=0;e<t.openEnd;e++)i=n,n=n.lastChild;let r=e.steps.length,o=this.ranges;for(let a=0;a<o.length;a++){let{$from:s,$to:l}=o[a],d=e.mapping.slice(r);e.replaceRange(d.map(s.pos),d.map(l.pos),a?tf.empty:t),0==a&&nG(e,r,(n?n.isInline:i&&i.isTextblock)?-1:1)}}replaceWith(e,t){let n=e.steps.length,i=this.ranges;for(let r=0;r<i.length;r++){let{$from:o,$to:a}=i[r],s=e.mapping.slice(n),l=s.map(o.pos),d=s.map(a.pos);r?e.deleteRange(l,d):(e.replaceRangeWith(l,d,t),nG(e,n,t.isInline?-1:1))}}static findFrom(e,t,n=!1){let i=e.parent.inlineContent?new nO(e):nH(e.node(0),e.parent,e.pos,e.index(),t,n);if(i)return i;for(let i=e.depth-1;i>=0;i--){let r=t<0?nH(e.node(0),e.node(i),e.before(i+1),e.index(i),t,n):nH(e.node(0),e.node(i),e.after(i+1),e.index(i)+1,t,n);if(r)return r}return null}
vendor: 6,447 bytes, line 230
230static near(e,t=1){return this.findFrom(e,t)||this.findFrom(e,-t)||new nj(e.node(0))}static atStart(e){return nH(e,e,0,0,1)||new nj(e)}static atEnd(e){return nH(e,e,e.content.size,e.childCount,-1)||new nj(e)}static fromJSON(e,t){if(!t||!t.type)throw RangeError("Invalid input for Selection.fromJSON");let n=nA[t.type];if(!n)throw RangeError(`No selection type ${t.type} defined`);return n.fromJSON(e,t)}static jsonID(e,t){if(e in nA)throw RangeError("Duplicate use of selection JSON ID "+e);return nA[e]=t,t.prototype.jsonID=e,t}getBookmark(){return nO.between(this.$anchor,this.$head).getBookmark()}}nP.prototype.visible=!0;class nE{constructor(e,t){this.$from=e,this.$to=t}}let nL=!1;function nF(e){nL||e.parent.inlineContent||(nL=!0,console.warn("TextSelection endpoint not pointing into a node with inline content ("+e.parent.type.name+")"))}class nO extends nP{constructor(e,t=e){nF(e),nF(t),super(e,t)}get $cursor(){return this.$anchor.pos==this.$head.pos?this.$head:null}map(e,t){let n=e.resolve(t.map(this.head));if(!n.parent.inlineContent)return nP.near(n);let i=e.resolve(t.map(this.anchor));return new nO(i.parent.inlineContent?i:n,n)}replace(e,t=tf.empty){if(super.replace(e,t),t==tf.empty){let t=this.$from.marksAcross(this.$to);t&&e.ensureMarks(t)}}eq(e){return e instanceof nO&&e.anchor==this.anchor&&e.head==this.head}getBookmark(){return new nN(this.anchor,this.head)}toJSON(){return{type:"text",anchor:this.anchor,head:this.head}}static fromJSON(e,t){if("number"!=typeof t.anchor||"number"!=typeof t.head)throw RangeError("Invalid input for TextSelection.fromJSON");return new nO(e.resolve(t.anchor),e.resolve(t.head))}static create(e,t,n=t){let i=e.resolve(t);return new this(i,n==t?i:e.resolve(n))}static between(e,t,n){let i=e.pos-t.pos;if((!n||i)&&(n=i>=0?1:-1),!t.parent.inlineContent){let e=nP.findFrom(t,n,!0)||nP.findFrom(t,-n,!0);if(!e)return nP.near(t,n);t=e.$head}return e.parent.inlineContent||(0==i?e=t:(e=(nP.findFrom(e,-n,!0)||nP.findFrom(e,n,!0)).$anchor).pos<t.pos!=i<0&&(e=t)),new nO(e,t)}}nP.jsonID("text",nO);class nN{constructor(e,t){this.anchor=e,this.head=t}map(e){return new nN(e.map(this.anchor),e.map(this.head))}resolve(e){return nO.between(e.resolve(this.anchor),e.resolve(this.head))}}class nB extends nP{constructor(e){let t=e.nodeAfter,n=e.node(0).resolve(e.pos+t.nodeSize);super(e,n),this.node=t}map(e,t){let{deleted:n,pos:i}=t.mapResult(this.anchor),r=e.resolve(i);return n?nP.near(r):new nB(r)}content(){return new tf(tl.from(this.node),0,0)}eq(e){return e instanceof nB&&e.anchor==this.anchor}toJSON(){return{type:"node",anchor:this.anchor}}getBookmark(){return new nz(this.anchor)}static fromJSON(e,t){if("number"!=typeof t.anchor)throw RangeError("Invalid input for NodeSelection.fromJSON");return new nB(e.resolve(t.anchor))}static create(e,t){return new nB(e.resolve(t))}static isSelectable(e){return!e.isText&&!1!==e.type.spec.selectable}}nB.prototype.visible=!1,nP.jsonID("node",nB);class nz{constructor(e){this.anchor=e}map(e){let{deleted:t,pos:n}=e.mapResult(this.anchor);return t?new nN(n,n):new nz(n)}resolve(e){let t=e.resolve(this.anchor),n=t.nodeAfter;return n&&nB.isSelectable(n)?new nB(t):nP.near(t)}}class nj extends nP{constructor(e){super(e.resolve(0),e.resolve(e.content.size))}replace(e,t=tf.empty){if(t==tf.empty){e.delete(0,e.doc.content.size);let t=nP.atStart(e.doc);t.eq(e.selection)||e.setSelection(t)}else super.replace(e,t)}toJSON(){return{type:"all"}}static fromJSON(e){return new nj(e)}map(e){return new nj(e)}eq(e){return e instanceof nj}getBookmark(){return nV}}nP.jsonID("all",nj);let nV={map(){return this},resolve:e=>new nj(e)};function nH(e,t,n,i,r,o=!1){if(t.inlineContent)return nO.create(e,n);for(let a=i-(r>0?0:1);r>0?a<t.childCount:a>=0;a+=r){let i=t.child(a);if(i.isAtom){if(!o&&nB.isSelectable(i))return nB.create(e,n-(r<0?i.nodeSize:0))}else{let t=nH(e,i,n+r,r<0?i.childCount:0,r,o);if(t)return t}n+=i.nodeSize*r}return null}function nG(e,t,n){let i,r=e.steps.length-1;if(r<t)return;let o=e.steps[r];(o instanceof no||o instanceof na)&&(e.mapping.maps[r].forEach((e,t,n,r)=>{null==i&&(i=r)}),e.setSelection(nP.near(e.doc.resolve(i),n)))}class nW extends nI{constructor(e){super(e.doc),this.curSelectionFor=0,this.updated=0,this.meta=Object.create(null),this.time=Date.now(),this.curSelection=e.selection,this.storedMarks=e.storedMarks}get selection(){return this.curSelectionFor<this.steps.length&&(this.curSelection=this.curSelection.map(this.doc,this.mapping.slice(this.curSelectionFor)),this.curSelectionFor=this.steps.length),this.curSelection}setSelection(e){if(e.$from.doc!=this.doc)throw RangeError("Selection passed to setSelection must point at the current document");return this.curSelection=e,this.curSelectionFor=this.steps.length,this.updated=(1|this.updated)&-3,this.storedMarks=null,this}get selectionSet(){return(1&this.updated)>0}setStoredMarks(e){return this.storedMarks=e,this.updated|=2,this}ensureMarks(e){return th.sameSet(this.storedMarks||this.selection.$from.marks(),e)||this.setStoredMarks(e),this}addStoredMark(e){return this.ensureMarks(e.addToSet(this.storedMarks||this.selection.$head.marks()))}removeStoredMark(e){return this.ensureMarks(e.removeFromSet(this.storedMarks||this.selection.$head.marks()))}get storedMarksSet(){return(2&this.updated)>0}addStep(e,t){super.addStep(e,t),this.updated=-3&this.updated,this.storedMarks=null}setTime(e){return this.time=e,this}replaceSelection(e){return this.selection.replace(this,e),this}replaceSelectionWith(e,t=!0){let n=this.selection;return t&&(e=e.mark(this.storedMarks||(n.empty?n.$from.marks():n.$from.marksAcross(n.$to)||th.none))),n.replaceWith(this,e),this}deleteSelection(){return this.selection.replace(this),this}insertText(e,t,n){let i=this.doc.type.schema;if(null==t)return e?this.replaceSelectionWith(i.text(e),!0):this.deleteSelection();{if(null==n&&(n=t),!e)return this.deleteRange(t,n);let r=this.storedMarks;if(!r){let e=this.doc.resolve(t);r=n==t?e.marks():e.marksAcross(this.doc.resolve(n))}return this.replaceRangeWith(t,n,i.text(e,r)),this.selection.empty||this.selection.to!=t+e.length||this.setSelection(nP.near(this.selection.$to)),this}}setMeta(e,t){return this.meta["string"==typeof e?e:e.key]=t,this}getMeta(e){return this.meta["string"==typeof e?e:e.key]}get isGeneric(){for(let e in this.meta)return!1;return!0}scrollIntoView(){return this.updated|=4,this}get scrolledIntoView(){return(4&this.updated)>0}}function n$(e,t){return t&&e?e.bind(t):e}
230class nU{constructor(e,t,n){this.name=e,this.init=n$(t.init,n),this.apply=n$(t.apply,n)}}let nq=[new nU("doc",{init:e=>e.doc||e.schema.topNodeType.createAndFill(),apply:e=>e.doc}),new nU("selection",{init:(e,t)=>e.selection||nP.atStart(t.doc),apply:e=>e.selection}),new nU("storedMarks",{init:e=>e.storedMarks||null,apply:(e,t,n,i)=>i.selection.$cursor?e.storedMarks:null}),new nU("scrollToSelection",{init:()=>0,apply:(e,t)=>e.scrolledIntoView?t+1:t})];class nK{constructor(e,t){this.schema=e,this.plugins=[],this.pluginsByKey=Object.create(null),this.fields=nq.slice(),t&&t.forEach(e=>{if(this.pluginsByKey[e.key])throw RangeError("Adding different instances of a keyed plugin ("+e.key+")");this.plugins.push(e),this.pluginsByKey[e.key]=e,e.spec.state&&this.fields.push(new nU(e.key,e.spec.state,e))})}}class nY{constructor(e){this.config=e}get schema(){return this.config.schema}get plugins(){return this.config.plugins}apply(e){return this.applyTransaction(e).state}filterTransaction(e,t=-1){for(let n=0;n<this.config.plugins.length;n++)if(n!=t){let t=this.config.plugins[n];if(t.spec.filterTransaction&&!t.spec.filterTransaction.call(t,e,this))return!1}return!0}applyTransaction(e){if(!this.filterTransaction(e))return{state:this,transactions:[]};let t=[e],n=this.applyInner(e),i=null;for(;;){let r=!1;for(let o=0;o<this.config.plugins.length;o++){let a=this.config.plugins[o];if(a.spec.appendTransaction){let s=i?i[o].n:0,l=i?i[o].state:this,d=s<t.length&&a.spec.appendTransaction.call(a,s?t.slice(s):t,l,n);if(d&&n.filterTransaction(d,o)){if(d.setMeta("appendedTransaction",e),!i){i=[];for(let e=0;e<this.config.plugins.length;e++)i.push(e<o?{state:n,n:t.length}:{state:this,n:0})}t.push(d),n=n.applyInner(d),r=!0}i&&(i[o]={state:n,n:t.length})}}if(!r)return{state:n,transactions:t}}}applyInner(e){if(!e.before.eq(this.doc))throw RangeError("Applying a mismatched transaction");let t=new nY(this.config),n=this.config.fields;for(let i=0;i<n.length;i++){let r=n[i];t[r.name]=r.apply(e,this[r.name],this,t)}return t}get tr(){return new nW(this)}static create(e){let t=new nK(e.doc?e.doc.type.schema:e.schema,e.plugins),n=new nY(t);for(let i=0;i<t.fields.length;i++)n[t.fields[i].name]=t.fields[i].init(e,n);return n}reconfigure(e){let t=new nK(this.schema,e.plugins),n=t.fields,i=new nY(t);for(let t=0;t<n.length;t++){let r=n[t].name;i[r]=this.hasOwnProperty(r)?this[r]:n[t].init(e,i)}return i}toJSON(e){let t={doc:this.doc.toJSON(),selection:this.selection.toJSON()};if(this.storedMarks&&(t.storedMarks=this.storedMarks.map(e=>e.toJSON())),e&&"object"==typeof e)for(let n in e){if("doc"==n||"selection"==n)throw RangeError("The JSON fields `doc` and `selection` are reserved");let i=e[n],r=i.spec.state;r&&r.toJSON&&(t[n]=r.toJSON.call(i,this[i.key]))}return t}static fromJSON(e,t,n){if(!t)throw RangeError("Invalid input for EditorState.fromJSON");if(!e.schema)throw RangeError("Required config field 'schema' missing");let i=new nK(e.schema,e.plugins),r=new nY(i);return i.fields.forEach(i=>{if("doc"==i.name)r.doc=tT.fromJSON(e.schema,t.doc);else if("selection"==i.name)r.selection=nP.fromJSON(r.doc,t.selection);else if("storedMarks"==i.name)t.storedMarks&&(r.storedMarks=t.storedMarks.map(e.schema.markFromJSON));else{if(n)for(let o in n){let a=n[o],s=a.spec.state;if(a.key==i.name&&s&&s.fromJSON&&Object.prototype.hasOwnProperty.call(t,o)){r[i.name]=s.fromJSON.call(a,e,t[o],r);return}}r[i.name]=i.init(e,r)}}),r}}class nZ{constructor(e){this.spec=e,this.props={},e.props&&function e(t,n,i){for(let r in t){let o=t[r];o instanceof Function?o=o.bind(n):"handleDOMEvents"==r&&(o=e(o,n,{})),i[r]=o}return i}(e.props,this,this.props),this.key=e.key?e.key.key:nJ("plugin")}getState(e){return e[this.key]}}let nX=Object.create(null);function nJ(e){return e in nX?e+"$"+ ++nX[e]:(nX[e]=0,e+"$")}class nQ{constructor(e="key"){this.key=nJ(e)}get(e){return e.config.pluginsByKey[this.key]}getState(e){return e[this.key]}}let n0=(e,t)=>!e.selection.empty&&(t&&t(e.tr.deleteSelection().scrollIntoView()),!0);function n1(e,t){let{$cursor:n}=e.selection;return n&&(t?t.endOfTextblock("backward",e):!(n.parentOffset>0))?n:null}
230let n2=(e,t,n)=>{let i=n1(e,n);if(!i)return!1;let r=n6(i);if(!r){let n=i.blockRange(),r=n&&nd(n);return null!=r&&(t&&t(e.tr.lift(n,r).scrollIntoView()),!0)}let o=r.nodeBefore;if(is(e,r,t,-1))return!0;if(0==i.parent.content.size&&(n5(o,"end")||nB.isSelectable(o)))for(let n=i.depth;;n--){let a=nb(e.doc,i.before(n),i.after(n),tf.empty);if(a&&a.slice.size<a.to-a.from){if(t){let n=e.tr.step(a);n.setSelection(n5(o,"end")?nP.findFrom(n.doc.resolve(n.mapping.map(r.pos,-1)),-1):nB.create(n.doc,r.pos-o.nodeSize)),t(n.scrollIntoView())}return!0}if(1==n||i.node(n-1).childCount>1)break}return!!o.isAtom&&r.depth==i.depth-1&&(t&&t(e.tr.delete(r.pos-o.nodeSize,r.pos).scrollIntoView()),!0)};function n3(e,t,n){let i=t.nodeBefore,r=t.pos-1;for(;!i.isTextblock;r--){if(i.type.spec.isolating)return!1;let e=i.lastChild;if(!e)return!1;i=e}let o=t.nodeAfter,a=t.pos+1;for(;!o.isTextblock;a++){if(o.type.spec.isolating)return!1;let e=o.firstChild;if(!e)return!1;o=e}let s=nb(e.doc,r,a,tf.empty);if(!s||s.from!=r||s instanceof no&&s.slice.size>=a-r)return!1;if(n){let t=e.tr.step(s);t.setSelection(nO.create(t.doc,r)),n(t.scrollIntoView())}return!0}function n5(e,t,n=!1){for(let i=e;i;i="start"==t?i.firstChild:i.lastChild){if(i.isTextblock)return!0;if(n&&1!=i.childCount)break}return!1}let n4=(e,t,n)=>{let{$head:i,empty:r}=e.selection,o=i;if(!r)return!1;if(i.parent.isTextblock){if(n?!n.endOfTextblock("backward",e):i.parentOffset>0)return!1;o=n6(i)}let a=o&&o.nodeBefore;return!!a&&!!nB.isSelectable(a)&&(t&&t(e.tr.setSelection(nB.create(e.doc,o.pos-a.nodeSize)).scrollIntoView()),!0)};function n6(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){if(e.index(t)>0)return e.doc.resolve(e.before(t+1));if(e.node(t).type.spec.isolating)break}return null}function n8(e,t){let{$cursor:n}=e.selection;return n&&(t?t.endOfTextblock("forward",e):!(n.parentOffset<n.parent.content.size))?n:null}let n7=(e,t,n)=>{let i=n8(e,n);if(!i)return!1;let r=ie(i);if(!r)return!1;let o=r.nodeAfter;if(is(e,r,t,1))return!0;if(0==i.parent.content.size&&(n5(o,"start")||nB.isSelectable(o))){let n=nb(e.doc,i.before(),i.after(),tf.empty);if(n&&n.slice.size<n.to-n.from){if(t){let i=e.tr.step(n);i.setSelection(n5(o,"start")?nP.findFrom(i.doc.resolve(i.mapping.map(r.pos)),1):nB.create(i.doc,i.mapping.map(r.pos))),t(i.scrollIntoView())}return!0}}return!!o.isAtom&&r.depth==i.depth-1&&(t&&t(e.tr.delete(r.pos,r.pos+o.nodeSize).scrollIntoView()),!0)},n9=(e,t,n)=>{let{$head:i,empty:r}=e.selection,o=i;if(!r)return!1;if(i.parent.isTextblock){if(n?!n.endOfTextblock("forward",e):i.parentOffset<i.parent.content.size)return!1;o=ie(i)}let a=o&&o.nodeAfter;return!!a&&!!nB.isSelectable(a)&&(t&&t(e.tr.setSelection(nB.create(e.doc,o.pos)).scrollIntoView()),!0)};function ie(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){let n=e.node(t);if(e.index(t)+1<n.childCount)return e.doc.resolve(e.after(t+1));if(n.type.spec.isolating)break}return null}let it=(e,t)=>{let{$head:n,$anchor:i}=e.selection;return!!n.parent.type.spec.code&&!!n.sameParent(i)&&(t&&t(e.tr.insertText("\n").scrollIntoView()),!0)};function ii(e){for(let t=0;t<e.edgeCount;t++){let{type:n}=e.edge(t);if(n.isTextblock&&!n.hasRequiredAttrs())return n}return null}let ir=(e,t)=>{let{$head:n,$anchor:i}=e.selection;if(!n.parent.type.spec.code||!n.sameParent(i))return!1;let r=n.node(-1),o=n.indexAfter(-1),a=ii(r.contentMatchAt(o));if(!a||!r.canReplaceWith(o,o,a))return!1;if(t){let i=n.after(),r=e.tr.replaceWith(i,i,a.createAndFill());r.setSelection(nP.near(r.doc.resolve(i),1)),t(r.scrollIntoView())}return!0},io=(e,t)=>{let n=e.selection,{$from:i,$to:r}=n;if(n instanceof nj||i.parent.inlineContent||r.parent.inlineContent)return!1;let o=ii(r.parent.contentMatchAt(r.indexAfter()));if(!o||!o.isTextblock)return!1;if(t){let n=(!i.parentOffset&&r.index()<r.parent.childCount?i:r).pos,a=e.tr.insert(n,o.createAndFill());a.setSelection(nO.create(a.doc,n+1)),t(a.scrollIntoView())}return!0},ia=(e,t)=>{let{$cursor:n}=e.selection;if(!n||n.parent.content.size)return!1;if(n.depth>1&&n.after()!=n.end(-1)){let i=n.before();if(nf(e.doc,i))return t&&t(e.tr.split(i).scrollIntoView()),!0}let i=n.blockRange(),r=i&&nd(i);return null!=r&&(t&&t(e.tr.lift(i,r).scrollIntoView()),!0)};function is(e,t,n,i){let r,o,a,s=t.nodeBefore,l=t.nodeAfter,d,u,c=s.type.spec.isolating||l.type.spec.isolating;if(!c&&(r=t.nodeBefore,o=t.nodeAfter,a=t.index(),r&&o&&r.type.compatibleContent(o.type)&&(!r.content.size&&t.parent.canReplace(a-1,a)?(n&&n(e.tr.delete(t.pos-r.nodeSize,t.pos).scrollIntoView()),!0):!!t.parent.canReplace(a,a+1)&&
230!!(o.isTextblock||ng(e.doc,t.pos))&&(n&&n(e.tr.join(t.pos).scrollIntoView()),!0))))return!0;let h=!c&&t.parent.canReplace(t.index(),t.index()+1);if(h&&(d=(u=s.contentMatchAt(s.childCount)).findWrapping(l.type))&&u.matchType(d[0]||l.type).validEnd){if(n){let i=t.pos+l.nodeSize,r=tl.empty;for(let e=d.length-1;e>=0;e--)r=tl.from(d[e].create(null,r));r=tl.from(s.copy(r));let o=e.tr.step(new na(t.pos-1,i,t.pos,i,new tf(r,1,0),d.length,!0)),a=o.doc.resolve(i+2*d.length);a.nodeAfter&&a.nodeAfter.type==s.type&&ng(o.doc,a.pos)&&o.join(a.pos),n(o.scrollIntoView())}return!0}let p=l.type.spec.isolating||i>0&&c?null:nP.findFrom(t,1),f=p&&p.$from.blockRange(p.$to),g=f&&nd(f);if(null!=g&&g>=t.depth)return n&&n(e.tr.lift(f,g).scrollIntoView()),!0;if(h&&n5(l,"start",!0)&&n5(s,"end")){let i=s,r=[];for(;r.push(i),!i.isTextblock;)i=i.lastChild;let o=l,a=1;for(;!o.isTextblock;o=o.firstChild)a++;if(i.canReplace(i.childCount,i.childCount,o.content)){if(n){let i=tl.empty;for(let e=r.length-1;e>=0;e--)i=tl.from(r[e].copy(i));n(e.tr.step(new na(t.pos-r.length,t.pos+l.nodeSize,t.pos+a,t.pos+l.nodeSize-a,new tf(i,r.length,0),0,!0)).scrollIntoView())}return!0}}return!1}function il(e){return function(t,n){let i=t.selection,r=e<0?i.$from:i.$to,o=r.depth;for(;r.node(o).isInline;){if(!o)return!1;o--}return!!r.node(o).isTextblock&&(n&&n(t.tr.setSelection(nO.create(t.doc,e<0?r.start(o):r.end(o)))),!0)}}let id=il(-1),iu=il(1);function ic(e,t=null){return function(n,i){let r=!1;for(let i=0;i<n.selection.ranges.length&&!r;i++){let{$from:{pos:o},$to:{pos:a}}=n.selection.ranges[i];n.doc.nodesBetween(o,a,(i,o)=>{if(r)return!1;if(!(!i.isTextblock||i.hasMarkup(e,t)))if(i.type==e)r=!0;else{let t=n.doc.resolve(o),i=t.index();r=t.parent.canReplaceWith(i,i+1,e)}})}if(!r)return!1;if(i){let r=n.tr;for(let i=0;i<n.selection.ranges.length;i++){let{$from:{pos:o},$to:{pos:a}}=n.selection.ranges[i];r.setBlockType(o,a,e,t)}i(r.scrollIntoView())}return!0}}function ih(...e){return function(t,n,i){for(let r=0;r<e.length;r++)if(e[r](t,n,i))return!0;return!1}}let ip=ih(n0,n2,n4),ig=ih(n0,n7,n9),im={Enter:ih(it,io,ia,(e,t)=>{let{$from:n,$to:i}=e.selection;if(e.selection instanceof nB&&e.selection.node.isBlock)return!!n.parentOffset&&!!nf(e.doc,n.pos)&&(t&&t(e.tr.split(n.pos).scrollIntoView()),!0);if(!n.depth)return!1;let r=[],o,a,s=!1,l=!1;for(let e=n.depth;;e--){if(n.node(e).isBlock){let t;s=n.end(e)==n.pos+(n.depth-e),l=n.start(e)==n.pos-(n.depth-e),a=ii(n.node(e-1).contentMatchAt(n.indexAfter(e-1)));r.unshift(t||(s&&a?{type:a}:null)),o=e;break}if(1==e)return!1;r.unshift(null)}let d=e.tr;(e.selection instanceof nO||e.selection instanceof nj)&&d.deleteSelection();let u=d.mapping.map(n.pos),c=nf(d.doc,u,r.length,r);if(c||(r[0]=a?{type:a}:null,c=nf(d.doc,u,r.length,r)),!c)return!1;if(d.split(u,r.length,r),!s&&l&&n.node(o).type!=a){let e=d.mapping.map(n.before(o)),t=d.doc.resolve(e);a&&n.node(o-1).canReplaceWith(t.index(),t.index()+1,a)&&d.setNodeMarkup(d.mapping.map(n.before(o)),a)}return t&&t(d.scrollIntoView()),!0}),"Mod-Enter":ir,Backspace:ip,"Mod-Backspace":ip,"Shift-Backspace":ip,Delete:ig,"Mod-Delete":ig,"Mod-a":(e,t)=>(t&&t(e.tr.setSelection(new nj(e.doc))),!0)},iv={"Ctrl-h":im.Backspace,"Alt-Backspace":im["Mod-Backspace"],"Ctrl-d":im.Delete,"Ctrl-Alt-Backspace":im["Mod-Delete"],"Alt-Delete":im["Mod-Delete"],"Alt-d":im["Mod-Delete"],"Ctrl-a":id,"Ctrl-e":iu};for(let e in im)iv[e]=im[e];"u">typeof navigator?/Mac|iP(hone|[oa]d)/.test(navigator.platform):"u">typeof os&&os.platform&&os.platform();let iy=function(e){for(var t=0;;t++)if(!(e=e.previousSibling))return t},ib=function(e){let t=e.assignedSlot||e.parentNode;return t&&11==t.nodeType?t.host:t},ix=null,iw=function(e,t,n){let i=ix||(ix=document.createRange());return i.setEnd(e,null==n?e.nodeValue.length:n),i.setStart(e,t||0),i},iC=function(){ix=null},iS=function(e,t,n,i){return n&&(ik(e,t,n,i,-1)||ik(e,t,n,i,1))},i_=/^(img|br|input|textarea|hr)$/i;function ik(e,t,n,i,r){for(var o;;){if(e==n&&t==i)return!0;if(t==(r<0?0:iM(e))){let n=e.parentNode;if(!n||1!=n.nodeType||iT(e)||i_.test(e.nodeName)||"false"==e.contentEditable)return!1;t=iy(e)+(r<0?0:1),e=n}
230else{if(1!=e.nodeType)return!1;let n=e.childNodes[t+(r<0?-1:0)];if(1==n.nodeType&&"false"==n.contentEditable)if(null==(o=n.pmViewDesc)||!o.ignoreForSelection)return!1;else t+=r;else e=n,t=r<0?iM(e):0}}}function iM(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}function iT(e){let t;for(let n=e;n&&!(t=n.pmViewDesc);n=n.parentNode);return t&&t.node&&t.node.isBlock&&(t.dom==e||t.contentDOM==e)}let iD=function(e){return e.focusNode&&iS(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)};function iR(e,t){let n=document.createEvent("Event");return n.initEvent("keydown",!0,!0),n.keyCode=e,n.key=n.code=t,n}let iI="u">typeof navigator?navigator:null,iA="u">typeof document?document:null,iP=iI&&iI.userAgent||"",iE=/Edge\/(\d+)/.exec(iP),iL=/MSIE \d/.exec(iP),iF=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(iP),iO=!!(iL||iF||iE),iN=iL?document.documentMode:iF?+iF[1]:iE?+iE[1]:0,iB=!iO&&/gecko\/(\d+)/i.test(iP);iB&&(/Firefox\/(\d+)/.exec(iP)||[0,0])[1];let iz=!iO&&/Chrome\/(\d+)/.exec(iP),ij=!!iz,iV=iz?+iz[1]:0,iH=!iO&&!!iI&&/Apple Computer/.test(iI.vendor),iG=iH&&(/Mobile\/\w+/.test(iP)||!!iI&&iI.maxTouchPoints>2),iW=iG||!!iI&&/Mac/.test(iI.platform),i$=!!iI&&/Win/.test(iI.platform),iU=/Android \d/.test(iP),iq=!!iA&&"webkitFontSmoothing"in iA.documentElement.style,iK=iq?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;function iY(e,t){return"number"==typeof e?e:e[t]}function iZ(e,t,n){let i=e.someProp("scrollThreshold")||0,r=e.someProp("scrollMargin")||5,o=e.dom.ownerDocument;for(let a=n||e.dom;a;){if(1!=a.nodeType){a=ib(a);continue}let e=a,n=e==o.body,s=n?function(e){let t=e.defaultView&&e.defaultView.visualViewport;return t?{left:0,right:t.width,top:0,bottom:t.height}:{left:0,right:e.documentElement.clientWidth,top:0,bottom:e.documentElement.clientHeight}}(o):function(e){let t=e.getBoundingClientRect(),n=t.width/e.offsetWidth||1,i=t.height/e.offsetHeight||1;return{left:t.left,right:t.left+e.clientWidth*n,top:t.top,bottom:t.top+e.clientHeight*i}}(e),l=0,d=0;if(t.top<s.top+iY(i,"top")?d=-(s.top-t.top+iY(r,"top")):t.bottom>s.bottom-iY(i,"bottom")&&(d=t.bottom-t.top>s.bottom-s.top?t.top+iY(r,"top")-s.top:t.bottom-s.bottom+iY(r,"bottom")),t.left<s.left+iY(i,"left")?l=-(s.left-t.left+iY(r,"left")):t.right>s.right-iY(i,"right")&&(l=t.right-s.right+iY(r,"right")),l||d)if(n)o.defaultView.scrollBy(l,d);else{let n=e.scrollLeft,i=e.scrollTop;d&&(e.scrollTop+=d),l&&(e.scrollLeft+=l);let r=e.scrollLeft-n,o=e.scrollTop-i;t={left:t.left-r,top:t.top-o,right:t.right-r,bottom:t.bottom-o}}let u=n?"fixed":getComputedStyle(a).position;if(/^(fixed|sticky)$/.test(u))break;a="absolute"==u?a.offsetParent:ib(a)}}function iX(e){let t=[],n=e.ownerDocument;for(let i=e;i&&(t.push({dom:i,top:i.scrollTop,left:i.scrollLeft}),e!=n);i=ib(i));return t}function iJ(e,t){for(let n=0;n<e.length;n++){let{dom:i,top:r,left:o}=e[n];i.scrollTop!=r+t&&(i.scrollTop=r+t),i.scrollLeft!=o&&(i.scrollLeft=o)}}let iQ=null;function i0(e,t){return e.left>=t.left-1&&e.left<=t.right+1&&e.top>=t.top-1&&e.top<=t.bottom+1}function i1(e){return e.top<e.bottom||e.left<e.right}function i2(e,t){let n=e.getClientRects();if(n.length){let e=n[t<0?0:n.length-1];if(i1(e))return e}return Array.prototype.find.call(n,i1)||e.getBoundingClientRect()}let i3=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;function i5(e,t,n){let{node:i,offset:r,atom:o}=e.docView.domFromPos(t,n<0?-1:1),a=iq||iB;if(3==i.nodeType)if(a&&(i3.test(i.nodeValue)||(n<0?!r:r==i.nodeValue.length))){let e=i2(iw(i,r,r),n);if(iB&&r&&/\s/.test(i.nodeValue[r-1])&&r<i.nodeValue.length){let t=i2(iw(i,r-1,r-1),-1);if(t.top==e.top){let n=i2(iw(i,r,r+1),-1);if(n.top!=e.top)return i4(n,n.left<t.left)}}return e}else{let e=r,t=r,o=n<0?1:-1;return n<0&&!r?(t++,o=-1):n>=0&&r==i.nodeValue.length?(e--,o=1):n<0?e--:t++,i4(i2(iw(i,e,t),o),o<0)}if(!e.state.doc.resolve(t-(o||0)).parent.inlineContent){if(null==o&&r&&(n<0||r==iM(i))){let e=i.childNodes[r-1];if(1==e.nodeType)return i6(e.getBoundingClientRect(),!1)}if(null==o&&r<iM(i)){let e=i.childNodes[r];if(1==e.nodeType)return i6(e.getBoundingClientRect(),!0)}return i6(i.getBoundingClientRect(),n>=0)}if(null==o&&r&&(n<0||r==iM(i))){let e=i.childNodes[r-1],t=3==e.nodeType?iw(e,iM(e)-!a):1!=e.nodeType||"BR"==e.nodeName&&e.nextSibling?null:e;if(t)return i4(i2(t,1),!1)}if(null==o&&r<iM(i)){let e=i.childNodes[r];for(;
230e.pmViewDesc&&e.pmViewDesc.ignoreForCoords;)e=e.nextSibling;let t=e?3==e.nodeType?iw(e,0,+!a):1==e.nodeType?e:null:null;if(t)return i4(i2(t,-1),!0)}return i4(i2(3==i.nodeType?iw(i):i,-n),n>=0)}function i4(e,t){if(0==e.width)return e;let n=t?e.left:e.right;return{top:e.top,bottom:e.bottom,left:n,right:n}}function i6(e,t){if(0==e.height)return e;let n=t?e.top:e.bottom;return{top:n,bottom:n,left:e.left,right:e.right}}function i8(e,t,n){let i=e.state,r=e.root.activeElement;i!=t&&e.updateState(t),r!=e.dom&&e.focus();try{return n()}finally{i!=t&&e.updateState(i),r!=e.dom&&r&&r.focus()}}let i7=/[\u0590-\u08ac]/,i9=null,re=null,rt=!1;class rn{constructor(e,t,n,i){this.parent=e,this.children=t,this.dom=n,this.contentDOM=i,this.dirty=0,n.pmViewDesc=this}matchesWidget(e){return!1}matchesMark(e){return!1}matchesNode(e,t,n){return!1}matchesHack(e){return!1}parseRule(){return null}stopEvent(e){return!1}get size(){let e=0;for(let t=0;t<this.children.length;t++)e+=this.children[t].size;return e}get border(){return 0}destroy(){this.parent=void 0,this.dom.pmViewDesc==this&&(this.dom.pmViewDesc=void 0);for(let e=0;e<this.children.length;e++)this.children[e].destroy()}posBeforeChild(e){for(let t=0,n=this.posAtStart;;t++){let i=this.children[t];if(i==e)return n;n+=i.size}}get posBefore(){return this.parent.posBeforeChild(this)}get posAtStart(){return this.parent?this.parent.posBeforeChild(this)+this.border:0}get posAfter(){return this.posBefore+this.size}get posAtEnd(){return this.posAtStart+this.size-2*this.border}localPosFromDOM(e,t,n){let i;if(this.contentDOM&&this.contentDOM.contains(1==e.nodeType?e:e.parentNode))if(n<0){let n,i;if(e==this.contentDOM)n=e.childNodes[t-1];else{for(;e.parentNode!=this.contentDOM;)e=e.parentNode;n=e.previousSibling}for(;n&&!((i=n.pmViewDesc)&&i.parent==this);)n=n.previousSibling;return n?this.posBeforeChild(i)+i.size:this.posAtStart}else{let n,i;if(e==this.contentDOM)n=e.childNodes[t];else{for(;e.parentNode!=this.contentDOM;)e=e.parentNode;n=e.nextSibling}for(;n&&!((i=n.pmViewDesc)&&i.parent==this);)n=n.nextSibling;return n?this.posBeforeChild(i):this.posAtEnd}if(e==this.dom&&this.contentDOM)i=t>iy(this.contentDOM);else if(this.contentDOM&&this.contentDOM!=this.dom&&this.dom.contains(this.contentDOM))i=2&e.compareDocumentPosition(this.contentDOM);else if(this.dom.firstChild){if(0==t)for(let t=e;;t=t.parentNode){if(t==this.dom){i=!1;break}if(t.previousSibling)break}if(null==i&&t==e.childNodes.length)for(let t=e;;t=t.parentNode){if(t==this.dom){i=!0;break}if(t.nextSibling)break}}return(null==i?n>0:i)?this.posAtEnd:this.posAtStart}nearestDesc(e,t=!1){for(let n=!0,i=e;i;i=i.parentNode){let r=this.getDesc(i),o;if(r&&(!t||r.node))if(!n||!(o=r.nodeDOM)||(1==o.nodeType?o.contains(1==e.nodeType?e:e.parentNode):o==e))return r;else n=!1}}getDesc(e){let t=e.pmViewDesc;for(let e=t;e;e=e.parent)if(e==this)return t}posFromDOM(e,t,n){for(let i=e;i;i=i.parentNode){let r=this.getDesc(i);if(r)return r.localPosFromDOM(e,t,n)}return -1}descAt(e){for(let t=0,n=0;t<this.children.length;t++){let i=this.children[t],r=n+i.size;if(n==e&&r!=n){for(;!i.border&&i.children.length;)for(let e=0;e<i.children.length;e++){let t=i.children[e];if(t.size){i=t;break}}return i}if(e<r)return i.descAt(e-n-i.border);n=r}}domFromPos(e,t){if(!this.contentDOM)return{node:this.dom,offset:0,atom:e+1};let n=0,i=0;for(let t=0;n<this.children.length;n++){let r=this.children[n],o=t+r.size;if(o>e||r instanceof rd){i=e-t;break}t=o}if(i)return this.children[n].domFromPos(i-this.children[n].border,t);for(let e;n&&!(e=this.children[n-1]).size&&e instanceof ri&&e.side>=0;n--);if(t<=0){let e,i=!0;for(;(e=n?this.children[n-1]:null)&&e.dom.parentNode!=this.contentDOM;n--,i=!1);return e&&t&&i&&!e.border&&!e.domAtom?e.domFromPos(e.size,t):{node:this.contentDOM,offset:e?iy(e.dom)+1:0}}{let e,i=!0;for(;(e=n<this.children.length?this.children[n]:null)&&e.dom.parentNode!=this.contentDOM;n++,i=!1);return e&&i&&!e.border&&!e.domAtom?e.domFromPos(0,t):{node:this.contentDOM,offset:e?iy(e.dom):this.contentDOM.childNodes.length}}}parseRange(e,t,n=0){if(0==this.children.length)return{node:this.contentDOM,from:e,to:t,fromOffset:0,toOffset:this.contentDOM.childNodes.length};let i=-1,r=-1;for(let o=n,a=0;;a++){let n=this.children[a],s=o+n.size;if(-1==i&&e<=s){let r=o+n.border;if(e>=r&&t<=s-n.border&&n.node&&n.contentDOM&&this.contentDOM.contains(n.contentDOM))return n.parseRange(e,t,r);e=o;for(let t=a;t>0;t--){let n=this.children[t-1];if(n.size&&n.dom.parentNode==this.contentDOM&&!n.emptyChildAt(1)){i=iy(n.dom)+1;break}e-=n.size}-1==i&&(i=0)}if(i>-1&&(s>t||a==this.children.length-1)){t=s;for(let e=a+1;e<this.children.length;e++){let n=this.children[e];if(n.size&&n.dom.parentNode==this.contentDOM&&!n.emptyChildAt(-1)){r=iy(n.dom);break}t+=n.size}-1==r&&(r=this.contentDOM.childNodes.length);break}o=s}return{node:this.contentDOM,from:e,to:t,fromOffset:i,toOffset:r}}emptyChildAt(e){if(this.border||!this.contentDOM||!this.children.length)return!1;let t=this.children[e<0?0:this.children.length-1];return 0==t.size||t.emptyChildAt(e)}domAfterPos(e){let{node:t,offset:n}=this.domFromPos(e,0);if(1!=t.nodeType||n==t.childNodes.length)throw RangeError("No node after pos "+e);return t.childNodes[n]}setSelection(e,t,n,i=!1){let r=Math.min(e,t),o=Math.max(e,t);for(let a=0,s=0;a<this.children.length;a++){let l=this.children[a],d=s+l.size;if(r>s&&o<d)return l.setSelection(e-s-l.border,t-s-l.border,n,i);s=d}let a=this.domFromPos(e,e?-1:1),s=t==e?a:this.domFromPos(t,t?-1:1),l=n.root.getSelection(),d=n.domSelectionRange(),u=!1;if((iB||iH)&&e==t){let{node:e,offset:t}=a;if(3==e.nodeType){if((u=!!(t&&"\n"==e.nodeValue[t-1]))&&t==e.nodeValue.length)for(let t=e,n;t;
230t=t.parentNode){if(n=t.nextSibling){"BR"==n.nodeName&&(a=s={node:n.parentNode,offset:iy(n)+1});break}let e=t.pmViewDesc;if(e&&e.node&&e.node.isBlock)break}}else{let n=e.childNodes[t-1];u=n&&("BR"==n.nodeName||"false"==n.contentEditable)}}if(iB&&d.focusNode&&d.focusNode!=s.node&&1==d.focusNode.nodeType){let e=d.focusNode.childNodes[d.focusOffset];e&&"false"==e.contentEditable&&(i=!0)}if(!(i||u&&iH)&&iS(a.node,a.offset,d.anchorNode,d.anchorOffset)&&iS(s.node,s.offset,d.focusNode,d.focusOffset))return;let c=!1;if((l.extend||e==t)&&!(u&&iB)){l.collapse(a.node,a.offset);try{e!=t&&l.extend(s.node,s.offset),c=!0}catch(e){}}if(!c){if(e>t){let e=a;a=s,s=e}let n=document.createRange();n.setEnd(s.node,s.offset),n.setStart(a.node,a.offset),l.removeAllRanges(),l.addRange(n)}}ignoreMutation(e){return!this.contentDOM&&"selection"!=e.type}get contentLost(){return this.contentDOM&&this.contentDOM!=this.dom&&!this.dom.contains(this.contentDOM)}markDirty(e,t){for(let n=0,i=0;i<this.children.length;i++){let r=this.children[i],o=n+r.size;if(n==o?e<=o&&t>=n:e<o&&t>n){let i=n+r.border,a=o-r.border;if(e>=i&&t<=a){this.dirty=e==n||t==o?2:1,e==i&&t==a&&(r.contentLost||r.dom.parentNode!=this.contentDOM)?r.dirty=3:r.markDirty(e-i,t-i);return}r.dirty=r.dom!=r.contentDOM||r.dom.parentNode!=this.contentDOM||r.children.length?3:2}n=o}this.dirty=2}markParentsDirty(){let e=1;for(let t=this.parent;t;t=t.parent,e++){let n=1==e?2:1;t.dirty<n&&(t.dirty=n)}}get domAtom(){return!1}get ignoreForCoords(){return!1}get ignoreForSelection(){return!1}isText(e){return!1}}class ri extends rn{constructor(e,t,n,i){let r,o=t.type.toDOM;if("function"==typeof o&&(o=o(n,()=>r?r.parent?r.parent.posBeforeChild(r):void 0:i)),!t.type.spec.raw){if(1!=o.nodeType){let e=document.createElement("span");e.appendChild(o),o=e}o.contentEditable="false",o.classList.add("ProseMirror-widget")}super(e,[],o,null),this.widget=t,this.widget=t,r=this}matchesWidget(e){return 0==this.dirty&&e.type.eq(this.widget.type)}parseRule(){return{ignore:!0}}stopEvent(e){let t=this.widget.spec.stopEvent;return!!t&&t(e)}ignoreMutation(e){return"selection"!=e.type||this.widget.spec.ignoreSelection}destroy(){this.widget.type.destroy(this.dom),super.destroy()}get domAtom(){return!0}get ignoreForSelection(){return!!this.widget.type.spec.relaxedSide}get side(){return this.widget.type.side}}class rr extends rn{constructor(e,t,n,i){super(e,[],t,null),this.textDOM=n,this.text=i}get size(){return this.text.length}localPosFromDOM(e,t){return e!=this.textDOM?this.posAtStart+(t?this.size:0):this.posAtStart+t}domFromPos(e){return{node:this.textDOM,offset:e}}ignoreMutation(e){return"characterData"===e.type&&e.target.nodeValue==e.oldValue}}class ro extends rn{constructor(e,t,n,i,r){super(e,[],n,i),this.mark=t,this.spec=r}static create(e,t,n,i){let r=i.nodeViews[t.type.name],o=r&&r(t,i,n);return o&&o.dom||(o=tQ.renderSpec(document,t.type.spec.toDOM(t,n),null,t.attrs)),new ro(e,t,o.dom,o.contentDOM||o.dom,o)}parseRule(){return 3&this.dirty||this.mark.type.spec.reparseInView?null:{mark:this.mark.type.name,attrs:this.mark.attrs,contentElement:this.contentDOM}}matchesMark(e){return 3!=this.dirty&&this.mark.eq(e)}markDirty(e,t){if(super.markDirty(e,t),0!=this.dirty){let e=this.parent;for(;!e.node;)e=e.parent;e.dirty<this.dirty&&(e.dirty=this.dirty),this.dirty=0}}slice(e,t,n){let i=ro.create(this.parent,this.mark,!0,n),r=this.children,o=this.size;t<o&&(r=rx(r,t,o,n)),e>0&&(r=rx(r,0,e,n));for(let e=0;e<r.length;e++)r[e].parent=i;return i.children=r,i}ignoreMutation(e){return this.spec.ignoreMutation?this.spec.ignoreMutation(e):super.ignoreMutation(e)}destroy(){this.spec.destroy&&this.spec.destroy(),super.destroy()}}class ra extends rn{constructor(e,t,n,i,r,o,a,s,l){super(e,[],r,o),this.node=t,this.outerDeco=n,this.innerDeco=i,this.nodeDOM=a}static create(e,t,n,i,r,o){let a=r.nodeViews[t.type.name],s,l=a&&a(t,r,()=>s?s.parent?s.parent.posBeforeChild(s):void 0:o,n,i),d=l&&l.dom,u=l&&l.contentDOM;if(t.isText)if(d){if(3!=d.nodeType)throw RangeError("Text must be rendered as a DOM text node")}else d=document.createTextNode(t.text);else if(!d){let e=tQ.renderSpec(document,t.type.spec.toDOM(t),null,t.attrs);({dom:d,contentDOM:u}=e)}u||t.isText||"BR"==d.nodeName||(d.hasAttribute("contenteditable")||(d.contentEditable="false"),t.type.spec.draggable&&(d.draggable=!0));let c=d;return(d=rg(d,n,t),l)?s=new ru(e,t,n,i,d,u||null,c,l,r,o+1):t.isText?new rl(e,t,n,i,d,c,r):new ra(e,t,n,i,d,u||null,c,r,o+1)}parseRule(){if(this.node.type.spec.reparseInView)return null;
vendor: 7,525 bytes, line 230
230let e={node:this.node.type.name,attrs:this.node.attrs};if("pre"==this.node.type.whitespace&&(e.preserveWhitespace="full"),this.contentDOM)if(this.contentLost){for(let t=this.children.length-1;t>=0;t--){let n=this.children[t];if(this.dom.contains(n.dom.parentNode)){e.contentElement=n.dom.parentNode;break}}e.contentElement||(e.getContent=()=>tl.empty)}else e.contentElement=this.contentDOM;else e.getContent=()=>this.node.content;return e}matchesNode(e,t,n){return 0==this.dirty&&e.eq(this.node)&&rm(t,this.outerDeco)&&n.eq(this.innerDeco)}get size(){return this.node.nodeSize}get border(){return+!this.node.isLeaf}updateChildren(e,t){let n=this.node.inlineContent,i=t,r=e.composing?this.localCompositionInfo(e,t):null,o=r&&r.pos>-1?r:null,a=r&&r.pos<0,s=new ry(this,o&&o.node,e);(function(e,t,n,i){let r=t.locals(e),o=0;if(0==r.length){for(let n=0;n<e.childCount;n++){let a=e.child(n);i(a,r,t.forChild(o,a),n),o+=a.nodeSize}return}let a=0,s=[],l=null;for(let d=0;;){let u,c,h,p;for(;a<r.length&&r[a].to==o;){let e=r[a++];e.widget&&(u?(c||(c=[u])).push(e):u=e)}if(u)if(c){c.sort(rb);for(let e=0;e<c.length;e++)n(c[e],d,!!l)}else n(u,d,!!l);if(l)p=-1,h=l,l=null;else if(d<e.childCount)p=d,h=e.child(d++);else break;for(let e=0;e<s.length;e++)s[e].to<=o&&s.splice(e--,1);for(;a<r.length&&r[a].from<=o&&r[a].to>o;)s.push(r[a++]);let f=o+h.nodeSize;if(h.isText){let e=f;a<r.length&&r[a].from<e&&(e=r[a].from);for(let t=0;t<s.length;t++)s[t].to<e&&(e=s[t].to);e<f&&(l=h.cut(e-o),h=h.cut(0,e-o),f=e,p=-1)}else for(;a<r.length&&r[a].to<f;)a++;let g=h.isInline&&!h.isLeaf?s.filter(e=>!e.inline):s.slice();i(h,g,t.forChild(o,h),p),o=f}})(this.node,this.innerDeco,(t,r,o)=>{t.spec.marks?s.syncToMarks(t.spec.marks,n,e,r):t.type.side>=0&&!o&&s.syncToMarks(r==this.node.childCount?th.none:this.node.child(r).marks,n,e,r),s.placeWidget(t,e,i)},(t,o,l,d)=>{let u;s.syncToMarks(t.marks,n,e,d),s.findNodeMatch(t,o,l,d)||a&&e.state.selection.from>i&&e.state.selection.to<i+t.nodeSize&&(u=s.findIndexWithChild(r.node))>-1&&s.updateNodeAt(t,o,l,u,e)||s.updateNextNode(t,o,l,e,d,i)||s.addNode(t,o,l,e,i),i+=t.nodeSize}),s.syncToMarks([],n,e,0),this.node.isTextblock&&s.addTextblockHacks(),s.destroyRest(),(s.changed||2==this.dirty)&&(o&&this.protectLocalComposition(e,o),function e(t,n,i){let r=t.firstChild,o=!1;for(let a=0;a<n.length;a++){let s=n[a],l=s.dom;if(l.parentNode==t){for(;l!=r;)r=rv(r),o=!0;r=r.nextSibling}else o=!0,t.insertBefore(l,r);if(s instanceof ro){let n=r?r.previousSibling:t.lastChild;e(s.contentDOM,s.children,i),r=n?n.nextSibling:t.firstChild}}for(;r;)r=rv(r),o=!0;o&&i.trackWrites==t&&(i.trackWrites=null)}(this.contentDOM,this.children,e),iG&&function(e){if("UL"==e.nodeName||"OL"==e.nodeName){let t=e.style.cssText;e.style.cssText=t+"; list-style: square !important",window.getComputedStyle(e).listStyle,e.style.cssText=t}}(this.dom))}localCompositionInfo(e,t){let{from:n,to:i}=e.state.selection;if(!(e.state.selection instanceof nO)||n<t||i>t+this.node.content.size)return null;let r=e.input.compositionNode;if(!r||!this.dom.contains(r.parentNode))return null;if(!this.node.inlineContent)return{node:r,pos:-1,text:""};{let e=r.nodeValue,o=function(e,t,n,i){for(let r=0,o=0;r<e.childCount&&o<=i;){let a=e.child(r++),s=o;if(o+=a.nodeSize,!a.isText)continue;let l=a.text;for(;r<e.childCount;){let t=e.child(r++);if(o+=t.nodeSize,!t.isText)break;l+=t.text}if(o>=n){if(o>=i&&l.slice(i-t.length-s,i-s)==t)return i-t.length;let e=s<i?l.lastIndexOf(t,i-s-1):-1;if(e>=0&&e+t.length+s>=n)return s+e;if(n==i&&l.length>=i+t.length-s&&l.slice(i-s,i-s+t.length)==t)return i}}return -1}(this.node.content,e,n-t,i-t);return o<0?null:{node:r,pos:o,text:e}}}protectLocalComposition(e,{node:t,pos:n,text:i}){if(this.getDesc(t))return;let r=t;for(;r.parentNode!=this.contentDOM;r=r.parentNode){for(;r.previousSibling;)r.parentNode.removeChild(r.previousSibling);for(;r.nextSibling;)r.parentNode.removeChild(r.nextSibling);r.pmViewDesc&&(r.pmViewDesc=void 0)}let o=new rr(this,r,t,i);e.input.compositionNodes.push(o),this.children=rx(this.children,n,n+i.length,e,o)}update(e,t,n,i){return 3!=this.dirty&&!!e.sameMarkup(this.node)&&(this.updateInner(e,t,n,i),!0)}updateInner(e,t,n,i){this.updateOuterDeco(t),this.node=e,this.innerDeco=n,this.contentDOM&&this.updateChildren(i,this.posAtStart),this.dirty=0}updateOuterDeco(e){if(rm(e,this.outerDeco))return;let t=1!=this.nodeDOM.nodeType,n=this.dom;this.dom=rf(this.dom,this.nodeDOM,rp(this.outerDeco,this.node,t),rp(e,this.node,t)),this.dom!=n&&(n.pmViewDesc=void 0,this.dom.pmViewDesc=this),this.outerDeco=e}selectNode(){1==this.nodeDOM.nodeType&&(this.nodeDOM.classList.add("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&(this.nodeDOM.draggable=!0))}deselectNode(){1==this.nodeDOM.nodeType&&(this.nodeDOM.classList.remove("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&this.nodeDOM.removeAttribute("draggable"))}get domAtom(){return this.node.isAtom}}function rs(e,t,n,i,r){rg(i,t,e);let o=new ra(void 0,e,t,n,i,i,i,r,0);return o.contentDOM&&o.updateChildren(r,0),o}class rl extends ra{constructor(e,t,n,i,r,o,a){super(e,t,n,i,r,null,o,a,0)}parseRule(){let e=this.nodeDOM.parentNode;for(;e&&e!=this.dom&&!e.pmIsDeco;)e=e.parentNode;return{skip:e||!0}}update(e,t,n,i){return 3!=this.dirty&&(0==this.dirty||!!this.inParent())&&!!e.sameMarkup(this.node)&&(this.updateOuterDeco(t),(0!=this.dirty||e.text!=this.node.text)&&e.text!=this.nodeDOM.nodeValue&&(this.nodeDOM.nodeValue=e.text,i.trackWrites==this.nodeDOM&&(i.trackWrites=null)),this.node=e,this.dirty=0,!0)}inParent(){let e=this.parent.contentDOM;for(let t=this.nodeDOM;t;t=t.parentNode)if(t==e)return!0;return!1}domFromPos(e){return{node:this.nodeDOM,offset:e}}localPosFromDOM(e,t,n){return e==this.nodeDOM?this.posAtStart+Math.min(t,this.node.text.length):super.localPosFromDOM(e,t,n)}ignoreMutation(e){return"characterData"!=e.type&&"selection"!=e.type}slice(e,t,n){let i=this.node.cut(e,t),r=document.createTextNode(i.text);return new rl(this.parent,i,this.outerDeco,this.innerDeco,r,r,n)}markDirty(e,t){super.markDirty(e,t),this.dom!=this.nodeDOM&&(0==e||t==this.nodeDOM.nodeValue.length)&&(this.dirty=3)}get domAtom(){return!1}isText(e){return this.node.text==e}}class rd extends rn{parseRule(){return{ignore:!0}}matchesHack(e){return 0==this.dirty&&this.dom.nodeName==e}get domAtom(){return!0}get ignoreForCoords(){return"IMG"==this.dom.nodeName}}class ru extends ra{constructor(e,t,n,i,r,o,a,s,l,d){super(e,t,n,i,r,o,a,l,d),this.spec=s}update(e,t,n,i){if(3==this.dirty)return!1;if(this.spec.update&&(this.node.type==e.type||this.spec.multiType)){let r=this.spec.update(e,t,n);return r&&this.updateInner(e,t,n,i),r}return(!!this.contentDOM||!!e.isLeaf)&&super.update(e,t,n,i)}selectNode(){this.spec.selectNode?this.spec.selectNode():super.selectNode()}deselectNode(){this.spec.deselectNode?this.spec.deselectNode():super.deselectNode()}setSelection(e,t,n,i){this.spec.setSelection?this.spec.setSelection(e,t,n.root):super.setSelection(e,t,n,i)}destroy(){this.spec.destroy&&this.spec.destroy(),super.destroy()}stopEvent(e){return!!this.spec.stopEvent&&this.spec.stopEvent(e)}ignoreMutation(e){return this.spec.ignoreMutation?this.spec.ignoreMutation(e):super.ignoreMutation(e)}}let rc=function(e){e&&(this.nodeName=e)};rc.prototype=Object.create(null);let rh=[new rc];function rp(e,t,n){if(0==e.length)return rh;let i=n?rh[0]:new rc,r=[i];for(let o=0;o<e.length;o++){let a=e[o].type.attrs;if(a)for(let e in a.nodeName&&r.push(i=new rc(a.nodeName)),a){let o=a[e];
230null!=o&&(n&&1==r.length&&r.push(i=new rc(t.isInline?"span":"div")),"class"==e?i.class=(i.class?i.class+" ":"")+o:"style"==e?i.style=(i.style?i.style+";":"")+o:"nodeName"!=e&&(i[e]=o))}}return r}function rf(e,t,n,i){if(n==rh&&i==rh)return t;let r=t;for(let t=0;t<i.length;t++){let o=i[t],a=n[t];if(t){let t;a&&a.nodeName==o.nodeName&&r!=e&&(t=r.parentNode)&&t.nodeName.toLowerCase()==o.nodeName||((t=document.createElement(o.nodeName)).pmIsDeco=!0,t.appendChild(r),a=rh[0]),r=t}!function(e,t,n){for(let i in t)"class"==i||"style"==i||"nodeName"==i||i in n||e.removeAttribute(i);for(let i in n)"class"!=i&&"style"!=i&&"nodeName"!=i&&n[i]!=t[i]&&e.setAttribute(i,n[i]);if(t.class!=n.class){let i=t.class?t.class.split(" ").filter(Boolean):[],r=n.class?n.class.split(" ").filter(Boolean):[];for(let t=0;t<i.length;t++)-1==r.indexOf(i[t])&&e.classList.remove(i[t]);for(let t=0;t<r.length;t++)-1==i.indexOf(r[t])&&e.classList.add(r[t]);0==e.classList.length&&e.removeAttribute("class")}if(t.style!=n.style){if(t.style){let n=/\s*([\w\-\xa1-\uffff]+)\s*:(?:"(?:\\.|[^"])*"|'(?:\\.|[^'])*'|\(.*?\)|[^;])*/g,i;for(;i=n.exec(t.style);)e.style.removeProperty(i[1])}n.style&&(e.style.cssText+=n.style)}}(r,a||rh[0],o)}return r}function rg(e,t,n){return rf(e,e,rh,rp(t,n,1!=e.nodeType))}function rm(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].type.eq(t[n].type))return!1;return!0}function rv(e){let t=e.nextSibling;return e.parentNode.removeChild(e),t}class ry{constructor(e,t,n){this.lock=t,this.view=n,this.index=0,this.stack=[],this.changed=!1,this.top=e,this.preMatch=function(e,t){let n=t,i=n.children.length,r=e.childCount,o=new Map,a=[];n:for(;r>0;){let s;for(;;)if(i){let e=n.children[i-1];if(e instanceof ro)n=e,i=e.children.length;else{s=e,i--;break}}else if(n==t)break n;else i=n.parent.children.indexOf(n),n=n.parent;let l=s.node;if(l){if(l!=e.child(r-1))break;--r,o.set(s,r),a.push(s)}}return{index:r,matched:o,matches:a.reverse()}}(e.node.content,e)}destroyBetween(e,t){if(e!=t){for(let n=e;n<t;n++)this.top.children[n].destroy();this.top.children.splice(e,t-e),this.changed=!0}}destroyRest(){this.destroyBetween(this.index,this.top.children.length)}syncToMarks(e,t,n,i){let r=0,o=this.stack.length>>1,a=Math.min(o,e.length);for(;r<a&&(r==o-1?this.top:this.stack[r+1<<1]).matchesMark(e[r])&&!1!==e[r].type.spec.spanning;)r++;for(;r<o;)this.destroyRest(),this.top.dirty=0,this.index=this.stack.pop(),this.top=this.stack.pop(),o--;for(;o<e.length;){this.stack.push(this.top,this.index+1);let r=-1,a=this.top.children.length;i<this.preMatch.index&&(a=Math.min(this.index+3,a));for(let t=this.index;t<a;t++){let n=this.top.children[t];if(n.matchesMark(e[o])&&!this.isLocked(n.dom)){r=t;break}}if(r>-1)r>this.index&&(this.changed=!0,this.destroyBetween(this.index,r)),this.top=this.top.children[this.index];else{let i=ro.create(this.top,e[o],t,n);this.top.children.splice(this.index,0,i),this.top=i,this.changed=!0}this.index=0,o++}}findNodeMatch(e,t,n,i){let r=-1,o;if(i>=this.preMatch.index&&(o=this.preMatch.matches[i-this.preMatch.index]).parent==this.top&&o.matchesNode(e,t,n))r=this.top.children.indexOf(o,this.index);else for(let i=this.index,o=Math.min(this.top.children.length,i+5);i<o;i++){let o=this.top.children[i];if(o.matchesNode(e,t,n)&&!this.preMatch.matched.has(o)){r=i;break}}return!(r<0)&&(this.destroyBetween(this.index,r),this.index++,!0)}updateNodeAt(e,t,n,i,r){let o=this.top.children[i];return 3==o.dirty&&o.dom==o.contentDOM&&(o.dirty=2),!!o.update(e,t,n,r)&&(this.destroyBetween(this.index,i),this.index++,!0)}findIndexWithChild(e){for(;;){let t=e.parentNode;if(!t)return -1;if(t==this.top.contentDOM){let t=e.pmViewDesc;if(t){for(let e=this.index;e<this.top.children.length;e++)if(this.top.children[e]==t)return e}return -1}e=t}}updateNextNode(e,t,n,i,r,o){for(let a=this.index;a<this.top.children.length;a++){let s=this.top.children[a];if(s instanceof ra){let l=this.preMatch.matched.get(s);if(null!=l&&l!=r)return!1;let d=s.dom,u,c=this.isLocked(d)&&!(e.isText&&s.node&&s.node.isText&&s.nodeDOM.nodeValue==e.text&&3!=s.dirty&&rm(t,s.outerDeco));if(!c&&s.update(e,t,n,i))return this.destroyBetween(this.index,a),s.dom!=d&&(this.changed=!0),this.index++,!0;if(!c&&(u=this.recreateWrapper(s,e,t,n,i,o)))return this.destroyBetween(this.index,a),this.top.children[this.index]=u,u.contentDOM&&(u.dirty=2,u.updateChildren(i,o+1),u.dirty=0),this.changed=!0,this.index++,!0;break}}return!1}recreateWrapper(e,t,n,i,r,o){if(e.dirty||t.isAtom||!e.children.length||!e.node.content.eq(t.content)||!rm(n,e.outerDeco)||!i.eq(e.innerDeco))return null;let a=ra.create(this.top,t,n,i,r,o);if(a.contentDOM)for(let t of(a.children=e.children,e.children=[],a.children))t.parent=a;return e.destroy(),a}addNode(e,t,n,i,r){let o=ra.create(this.top,e,t,n,i,r);o.contentDOM&&o.updateChildren(i,r+1),this.top.children.splice(this.index++,0,o),this.changed=!0}placeWidget(e,t,n){let i=this.index<this.top.children.length?this.top.children[this.index]:null;if(i&&i.matchesWidget(e)&&(e==i.widget||!i.widget.type.toDOM.parentNode))this.index++;else{let i=new ri(this.top,e,t,n);this.top.children.splice(this.index++,0,i),this.changed=!0}}addTextblockHacks(){let e=this.top.children[this.index-1],t=this.top;for(;e instanceof ro;)e=(t=e).children[t.children.length-1];(!e||!(e instanceof rl)||/\n$/.test(e.node.text)||this.view.requiresGeckoHackNode&&/\s$/.test(e.node.text))&&((iH||ij)&&e&&"false"==e.dom.contentEditable&&this.addHackNode("IMG",t),this.addHackNode("BR",this.top))}addHackNode(e,t){if(t==this.top&&this.index<t.children.length&&t.children[this.index].matchesHack(e))this.index++;else{let n=document.createElement(e);"IMG"==e&&(n.className="ProseMirror-separator",n.alt=""),"BR"==e&&(n.className="ProseMirror-trailingBreak");let i=new rd(this.top,[],n,null);t!=this.top?t.children.push(i):t.children.splice(this.index++,0,i),this.changed=!0}}
230isLocked(e){return this.lock&&(e==this.lock||1==e.nodeType&&e.contains(this.lock.parentNode))}}function rb(e,t){return e.type.side-t.type.side}function rx(e,t,n,i,r){let o=[];for(let a=0,s=0;a<e.length;a++){let l=e[a],d=s,u=s+=l.size;d>=n||u<=t?o.push(l):(d<t&&o.push(l.slice(0,t-d,i)),r&&(o.push(r),r=void 0),u>n&&o.push(l.slice(n-d,l.size,i)))}return o}function rw(e,t=null){let n=e.domSelectionRange(),i=e.state.doc;if(!n.focusNode)return null;let r=e.docView.nearestDesc(n.focusNode),o=r&&0==r.size,a=e.docView.posFromDOM(n.focusNode,n.focusOffset,1);if(a<0)return null;let s=i.resolve(a),l,d;if(iD(n)){for(l=a;r&&!r.node;)r=r.parent;let e=r.node;if(r&&e.isAtom&&nB.isSelectable(e)&&r.parent&&!(e.isInline&&function(e,t,n){for(let i=0==t,r=t==iM(e);i||r;){if(e==n)return!0;let t=iy(e);if(!(e=e.parentNode))return!1;i=i&&0==t,r=r&&t==iM(e)}}(n.focusNode,n.focusOffset,r.dom))){let e=r.posBefore;d=new nB(a==e?s:i.resolve(e))}}else{if(n instanceof e.dom.ownerDocument.defaultView.Selection&&n.rangeCount>1){let t=a,r=a;for(let i=0;i<n.rangeCount;i++){let o=n.getRangeAt(i);t=Math.min(t,e.docView.posFromDOM(o.startContainer,o.startOffset,1)),r=Math.max(r,e.docView.posFromDOM(o.endContainer,o.endOffset,-1))}if(t<0)return null;[l,a]=r==e.state.selection.anchor?[r,t]:[t,r],s=i.resolve(a)}else l=e.docView.posFromDOM(n.anchorNode,n.anchorOffset,1);if(l<0)return null}let u=i.resolve(l);if(!d){let n="pointer"==t||e.state.selection.head<s.pos&&!o?1:-1;d=rI(e,u,s,n)}return d}function rC(e){return e.editable?e.hasFocus():rP(e)&&document.activeElement&&document.activeElement.contains(e.dom)}function rS(e,t=!1){let n=e.state.selection;if(rD(e,n),!rC(e))return;let i=e.input.mouseDown;if(!t&&ij&&i){let t=e.domSelectionRange(),n=e.domObserver.currentSelection;if(t.anchorNode&&n.anchorNode&&iS(t.anchorNode,t.anchorOffset,n.anchorNode,n.anchorOffset)&&i.delaySelUpdate())return void e.domObserver.setCurSelection()}if(e.domObserver.disconnectSelection(),e.cursorWrapper)!function(e){let t=e.domSelection();if(!t)return;let n=e.cursorWrapper.dom,i="IMG"==n.nodeName;i?t.collapse(n.parentNode,iy(n)+1):t.collapse(n,0),!i&&!e.state.selection.visible&&iO&&iN<=11&&(n.disabled=!0,n.disabled=!1)}(e);else{var r;let i,o,a,s,{anchor:l,head:d}=n,u,c;r_&&!(n instanceof nO)&&(n.$from.parent.inlineContent||(u=rk(e,n.from)),n.empty||n.$from.parent.inlineContent||(c=rk(e,n.to))),e.docView.setSelection(l,d,e,t),r_&&(u&&rT(u),c&&rT(c)),n.visible?e.dom.classList.remove("ProseMirror-hideselection"):(e.dom.classList.add("ProseMirror-hideselection"),"onselectionchange"in document&&((i=(r=e).dom.ownerDocument).removeEventListener("selectionchange",r.input.hideSelectionGuard),a=(o=r.domSelectionRange()).anchorNode,s=o.anchorOffset,i.addEventListener("selectionchange",r.input.hideSelectionGuard=()=>{(o.anchorNode!=a||o.anchorOffset!=s)&&(i.removeEventListener("selectionchange",r.input.hideSelectionGuard),setTimeout(()=>{(!rC(r)||r.state.selection.visible)&&r.dom.classList.remove("ProseMirror-hideselection")},20))})))}e.domObserver.setCurSelection(),e.domObserver.connectSelection()}let r_=iH||ij&&iV<63;function rk(e,t){let{node:n,offset:i}=e.docView.domFromPos(t,0),r=i<n.childNodes.length?n.childNodes[i]:null,o=i?n.childNodes[i-1]:null;if(iH&&r&&"false"==r.contentEditable)return rM(r);if((!r||"false"==r.contentEditable)&&(!o||"false"==o.contentEditable)){if(r)return rM(r);else if(o)return rM(o)}}function rM(e){return e.contentEditable="true",iH&&e.draggable&&(e.draggable=!1,e.wasDraggable=!0),e}function rT(e){e.contentEditable="false",e.wasDraggable&&(e.draggable=!0,e.wasDraggable=null)}function rD(e,t){if(t instanceof nB){let n=e.docView.descAt(t.from);n!=e.lastSelectedViewDesc&&(rR(e),n&&n.selectNode(),e.lastSelectedViewDesc=n)}else rR(e)}function rR(e){e.lastSelectedViewDesc&&(e.lastSelectedViewDesc.parent&&e.lastSelectedViewDesc.deselectNode(),e.lastSelectedViewDesc=void 0)}function rI(e,t,n,i){return e.someProp("createSelectionBetween",i=>i(e,t,n))||nO.between(t,n,i)}function rA(e){return(!e.editable||!!e.hasFocus())&&rP(e)}function rP(e){let t=e.domSelectionRange();if(!t.anchorNode)return!1;try{return e.dom.contains(3==t.anchorNode.nodeType?t.anchorNode.parentNode:t.anchorNode)&&(e.editable||e.dom.contains(3==t.focusNode.nodeType?t.focu
230sNode.parentNode:t.focusNode))}catch(e){return!1}}function rE(e,t){let{$anchor:n,$head:i}=e.selection,r=t>0?n.max(i):n.min(i),o=r.parent.inlineContent?r.depth?e.doc.resolve(t>0?r.after():r.before()):null:r;return o&&nP.findFrom(o,t)}function rL(e,t){return e.dispatch(e.state.tr.setSelection(t).scrollIntoView()),!0}function rF(e,t,n){let i=e.state.selection;if(i instanceof nO){if(n.indexOf("s")>-1){let{$head:n}=i,r=n.textOffset?null:t<0?n.nodeBefore:n.nodeAfter;if(!r||r.isText||!r.isLeaf)return!1;let o=e.state.doc.resolve(n.pos+r.nodeSize*(t<0?-1:1));return rL(e,new nO(i.$anchor,o))}else if(!i.empty)return!1;else if(e.endOfTextblock(t>0?"forward":"backward")){let n=rE(e.state,t);return!!n&&n instanceof nB&&rL(e,n)}else if(!(iW&&n.indexOf("m")>-1)){let n=i.$head,r=n.textOffset?null:t<0?n.nodeBefore:n.nodeAfter,o;if(!r||r.isText)return!1;let a=t<0?n.pos-r.nodeSize:n.pos;return!!(r.isAtom||(o=e.docView.descAt(a))&&!o.contentDOM)&&(nB.isSelectable(r)?rL(e,new nB(t<0?e.state.doc.resolve(n.pos-r.nodeSize):n)):!!iq&&rL(e,new nO(e.state.doc.resolve(t<0?a:a+r.nodeSize))))}}else{if(i instanceof nB&&i.node.isInline)return rL(e,new nO(t>0?i.$to:i.$from));let n=rE(e.state,t);return!!n&&rL(e,n)}}function rO(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}function rN(e,t){let n=e.pmViewDesc;return n&&0==n.size&&(t<0||e.nextSibling||"BR"!=e.nodeName)}function rB(e,t){return t<0?function(e){let t=e.domSelectionRange(),n=t.focusNode,i=t.focusOffset;if(!n)return;let r,o,a=!1;for(iB&&1==n.nodeType&&i<rO(n)&&rN(n.childNodes[i],-1)&&(a=!0);;)if(i>0)if(1!=n.nodeType)break;else{let e=n.childNodes[i-1];if(rN(e,-1))r=n,o=--i;else if(3==e.nodeType)i=(n=e).nodeValue.length;else break}else if(rz(n))break;else{let t=n.previousSibling;for(;t&&rN(t,-1);)r=n.parentNode,o=iy(t),t=t.previousSibling;if(t)i=rO(n=t);else{if((n=n.parentNode)==e.dom)break;i=0}}a?rj(e,n,i):r&&rj(e,r,o)}(e):function(e){let t,n,i=e.domSelectionRange(),r=i.focusNode,o=i.focusOffset;if(!r)return;let a=rO(r);for(;;)if(o<a){if(1!=r.nodeType)break;if(rN(r.childNodes[o],1))t=r,n=++o;else break}else if(rz(r))break;else{let i=r.nextSibling;for(;i&&rN(i,1);)t=i.parentNode,n=iy(i)+1,i=i.nextSibling;if(i)o=0,a=rO(r=i);else{if((r=r.parentNode)==e.dom)break;o=a=0}}t&&rj(e,t,n)}(e)}function rz(e){let t=e.pmViewDesc;return t&&t.node&&t.node.isBlock}function rj(e,t,n){if(3!=t.nodeType){let e,i;(i=function(e,t){for(;e&&t==e.childNodes.length&&!iT(e);)t=iy(e)+1,e=e.parentNode;for(;e&&t<e.childNodes.length;){let n=e.childNodes[t];if(3==n.nodeType)return n;if(1==n.nodeType&&"false"==n.contentEditable)break;e=n,t=0}}(t,n))?(t=i,n=0):(e=function(e,t){for(;e&&!t&&!iT(e);)t=iy(e),e=e.parentNode;for(;e&&t;){let n=e.childNodes[t-1];if(3==n.nodeType)return n;if(1==n.nodeType&&"false"==n.contentEditable)break;t=(e=n).childNodes.length}}(t,n))&&(t=e,n=e.nodeValue.length)}let i=e.domSelection();if(!i)return;if(iD(i)){let e=document.createRange();e.setEnd(t,n),e.setStart(t,n),i.removeAllRanges(),i.addRange(e)}else i.extend&&i.extend(t,n);e.domObserver.setCurSelection();let{state:r}=e;setTimeout(()=>{e.state==r&&rS(e)},50)}function rV(e,t){let n=e.state.doc.resolve(t);if(!(ij||i$)&&n.parent.inlineContent){let i=e.coordsAtPos(t);if(t>n.start()){let n=e.coordsAtPos(t-1),r=(n.top+n.bottom)/2;if(r>i.top&&r<i.bottom&&Math.abs(n.left-i.left)>1)return n.left<i.left?"ltr":"rtl"}if(t<n.end()){let n=e.coordsAtPos(t+1),r=(n.top+n.bottom)/2;if(r>i.top&&r<i.bottom&&Math.abs(n.left-i.left)>1)return n.left>i.left?"ltr":"rtl"}}return"rtl"==getComputedStyle(e.dom).direction?"rtl":"ltr"}function rH(e,t,n){let i=e.state.selection;if(i instanceof nO&&!i.empty||n.indexOf("s")>-1||iW&&n.indexOf("m")>-1)return!1;let{$from:r,$to:o}=i;if(!r.parent.inlineContent||e.endOfTextblock(t<0?"up":"down")){let n=rE(e.state,t);if(n&&n instanceof nB)return rL(e,n)}if(!r.parent.inlineContent){let n=t<0?r:o,a=i instanceof nj?nP.near(n,t):nP.findFrom(n,t);return!!a&&rL(e,a)}return!1}function rG(e,t){if(!(e.state.selection instanceof nO))return!0;let{$head:n,$anchor:i,empty:r}=e.state.selection;if(!n.sameParent(i))return!0;if(!r)return!1;if(e.endOfTextblock(t>0?"forward":"backward"))return!0;let o=!n.textOffset&&(t<0?n.nodeBefore:n.nodeAfter);if(o&&!o.isText){let i=e.state.tr;return t<0?i.delete(n.pos-o.nodeSize,n.pos):i.delete(n.pos,n.pos+o.nodeSize),e.dispatch(i),!0}return!1}function rW(e,t,n){e.domObserver.stop(),t.contentEditable=n,e.domObserver.start()}function r$(e,t){e.someProp("transformCopied",n=>{t=n(t,e)});let n=[],{content:i,openStart:r,openEnd:o}=t;for(;r>1&&o>1&&1==i.childCount&&1==i.firstChild.childCount;){r--,o--;let e=i.firstChild;
230n.push(e.type.name,e.attrs!=e.type.defaultAttrs?e.attrs:null),i=e.content}let a=e.someProp("clipboardSerializer")||tQ.fromSchema(e.state.schema),s=rQ(),l=s.createElement("div");l.appendChild(a.serializeFragment(i,{document:s}));let d=l.firstChild,u,c=0;for(;d&&1==d.nodeType&&(u=rX[d.nodeName.toLowerCase()]);){for(let e=u.length-1;e>=0;e--){let t=s.createElement(u[e]);for(;l.firstChild;)t.appendChild(l.firstChild);l.appendChild(t),c++}d=l.firstChild}return d&&1==d.nodeType&&d.setAttribute("data-pm-slice",`${r} ${o}${c?` -${c}`:""} ${JSON.stringify(n)}`),{dom:l,text:e.someProp("clipboardTextSerializer",n=>n(t,e))||t.content.textBetween(0,t.content.size,"\n\n"),slice:t}}function rU(e,t,n,i,r){let o,a,s=r.parent.type.spec.code;if(!n&&!t)return null;let l=!!t&&(i||s||!n);if(l){if(e.someProp("transformPastedText",n=>{t=n(t,s||i,e)}),s)return a=new tf(tl.from(e.state.schema.text(t.replace(/\r\n?/g,"\n"))),0,0),e.someProp("transformPasted",t=>{a=t(a,e,!0)}),a;let n=e.someProp("clipboardTextParser",n=>n(t,r,i,e));if(n)a=n;else{let n=r.marks(),{schema:i}=e.state,a=tQ.fromSchema(i);o=document.createElement("div"),t.split(/(?:\r\n?|\n)+/).forEach(e=>{let t=o.appendChild(document.createElement("p"));e&&t.appendChild(a.serializeNode(i.text(e,n)))})}}else e.someProp("transformPastedHTML",t=>{n=t(n,e)}),o=function(e){var t;let n,i=/^(\s*<meta [^>]*>)*/.exec(e);i&&(e=e.slice(i[0].length));let r=rQ().createElement("div"),o=/<([a-z][^>\s]+)/i.exec(e),a;if((a=o&&rX[o[1].toLowerCase()])&&(e=a.map(e=>"<"+e+">").join("")+e+a.map(e=>"</"+e+">").reverse().join("")),r.innerHTML=(t=e,(n=window.trustedTypes)?(r0||(r0=n.defaultPolicy||n.createPolicy("ProseMirrorClipboard",{createHTML:e=>e})),r0.createHTML(t)):t),a)for(let e=0;e<a.length;e++)r=r.querySelector(a[e])||r;return r}(n),iq&&function(e){let t=e.querySelectorAll(ij?"span:not([class]):not([style])":"span.Apple-converted-space");for(let n=0;n<t.length;n++){let i=t[n];1==i.childNodes.length&&"Â "==i.textContent&&i.parentNode&&i.parentNode.replaceChild(e.ownerDocument.createTextNode(" "),i)}}(o);let d=o&&o.querySelector("[data-pm-slice]"),u=d&&/^(\d+) (\d+)(?: -(\d+))? (.*)/.exec(d.getAttribute("data-pm-slice")||"");if(u&&u[3])for(let e=+u[3];e>0;e--){let e=o.firstChild;for(;e&&1!=e.nodeType;)e=e.nextSibling;if(!e)break;o=e}if(a||(a=(e.someProp("clipboardParser")||e.someProp("domParser")||tW.fromSchema(e.state.schema)).parseSlice(o,{preserveWhitespace:!!(l||u),context:r,ruleFromNode:e=>"BR"!=e.nodeName||e.nextSibling||!e.parentNode||rq.test(e.parentNode.nodeName)?null:{ignore:!0}})),u)a=function(e,t){if(!e.size)return e;let n=e.content.firstChild.type.schema,i;try{i=JSON.parse(t)}catch(t){return e}let{content:r,openStart:o,openEnd:a}=e;for(let e=i.length-2;e>=0;e-=2){let t=n.nodes[i[e]];if(!t||t.hasRequiredAttrs())break;r=tl.from(t.create(i[e+1],r)),o++,a++}return new tf(r,o,a)}(rZ(a,+u[1],+u[2]),u[4]);else if((a=tf.maxOpen(function(e,t){if(e.childCount<2)return e;for(let n=t.depth;n>=0;n--){let i=t.node(n).contentMatchAt(t.index(n)),r,o=[];if(e.forEach(e=>{if(!o)return;let t=i.findWrapping(e.type),n;if(!t)return o=null;if(n=o.length&&r.length&&function e(t,n,i,r,o){if(o<t.length&&o<n.length&&t[o]==n[o]){let a=e(t,n,i,r.lastChild,o+1);if(a)return r.copy(r.content.replaceChild(r.childCount-1,a));if(r.contentMatchAt(r.childCount).matchType(o==t.length-1?i.type:t[o+1]))return r.copy(r.content.append(tl.from(rK(i,t,o+1))))}}(t,r,e,o[o.length-1],0))o[o.length-1]=n;else{o.length&&(o[o.length-1]=function e(t,n){if(0==n)return t;let i=t.content.replaceChild(t.childCount-1,e(t.lastChild,n-1)),r=t.contentMatchAt(t.childCount).fillBefore(tl.empty,!0);return t.copy(i.append(r))}(o[o.length-1],r.length));let n=rK(e,t);o.push(n),i=i.matchType(n.type),r=t}}),o)return tl.from(o)}return e}(a.content,r),!0)).openStart||a.openEnd){let e=0,t=0;for(let t=a.content.firstChild;e<a.openStart&&!t.type.spec.isolating;e++,t=t.firstChild);for(let e=a.content.lastChild;t<a.openEnd&&!e.type.spec.isolating;t++,e=e.lastChild);a=rZ(a,e,t)}return e.someProp("transformPasted",t=>{a=t(a,e,l)}),a}let rq=/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var)$/i;function rK(e,t,n=0){for(let i=t.length-1;i>=n;i--)e=t[i].create(null,tl.from(e));return e}
230function rY(e,t,n,i,r,o){let a=t<0?e.firstChild:e.lastChild,s=a.content;return e.childCount>1&&(o=0),r<i-1&&(s=rY(s,t,n,i,r+1,o)),r>=n&&(s=t<0?a.contentMatchAt(0).fillBefore(s,o<=r).append(s):s.append(a.contentMatchAt(a.childCount).fillBefore(tl.empty,!0))),e.replaceChild(t<0?0:e.childCount-1,a.copy(s))}function rZ(e,t,n){return t<e.openStart&&(e=new tf(rY(e.content,-1,t,e.openStart,0,e.openEnd),t,e.openEnd)),n<e.openEnd&&(e=new tf(rY(e.content,1,n,e.openEnd,0,0),e.openStart,n)),e}let rX={thead:["table"],tbody:["table"],tfoot:["table"],caption:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]},rJ=null;function rQ(){return rJ||(rJ=document.implementation.createHTMLDocument("title"))}let r0=null,r1={},r2={},r3={touchstart:!0,touchmove:!0};class r5{constructor(){this.shiftKey=!1,this.mouseDown=null,this.lastKeyCode=null,this.lastKeyCodeTime=0,this.lastClick={time:0,x:0,y:0,type:"",button:0},this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastIOSEnter=0,this.lastIOSEnterFallbackTimeout=-1,this.lastFocus=0,this.lastTouch=0,this.lastChromeDelete=0,this.composing=!1,this.compositionNode=null,this.composingTimeout=-1,this.compositionNodes=[],this.compositionEndedAt=-2e8,this.compositionID=1,this.badSafariComposition=!1,this.compositionPendingChanges=0,this.domChangeCount=0,this.eventHandlers=Object.create(null),this.hideSelectionGuard=null}}function r4(e,t){e.input.lastSelectionOrigin=t,e.input.lastSelectionTime=Date.now()}function r6(e){e.someProp("handleDOMEvents",t=>{for(let n in t)e.input.eventHandlers[n]||e.dom.addEventListener(n,e.input.eventHandlers[n]=t=>r8(e,t))})}function r8(e,t){return e.someProp("handleDOMEvents",n=>{let i=n[t.type];return!!i&&(i(e,t)||t.defaultPrevented)})}function r7(e){return{left:e.clientX,top:e.clientY}}function r9(e,t,n,i,r){if(-1==i)return!1;let o=e.state.doc.resolve(i);for(let i=o.depth+1;i>0;i--)if(e.someProp(t,t=>i>o.depth?t(e,n,o.nodeAfter,o.before(i),r,!0):t(e,n,o.node(i),o.before(i),r,!1)))return!0;return!1}function oe(e,t,n){if(e.focused||e.focus(),e.state.selection.eq(t))return;let i=e.state.tr.setSelection(t);"pointer"==n&&i.setMeta("pointer",!0),e.dispatch(i)}function ot(e,t,n){let i=e.state.doc;if(-1==t)return i.inlineContent?nO.create(i,0,i.content.size):null;let r=i.resolve(t);for(let e=r.depth+1;e>0;e--){let t=e>r.depth?r.nodeAfter:r.node(e),o=r.before(e);if(t.inlineContent)return nO.create(i,o+1,o+1+t.content.size);if(n&&nB.isSelectable(t))return nB.create(i,o)}return null}r2.keydown=(e,t)=>{if((e.input.shiftKey=16==t.keyCode||t.shiftKey,!oa(e))&&(e.input.lastKeyCode=t.keyCode,e.input.lastKeyCodeTime=Date.now(),!iU||!ij||13!=t.keyCode))if(229!=t.keyCode&&e.domObserver.forceFlush(),!iG||13!=t.keyCode||t.ctrlKey||t.altKey||t.metaKey)e.someProp("handleKeyDown",n=>n(e,t))||function(e,t){let n,i=t.keyCode,r=(n="",t.ctrlKey&&(n+="c"),t.metaKey&&(n+="m"),t.altKey&&(n+="a"),t.shiftKey&&(n+="s"),n);if(8==i||iW&&72==i&&"c"==r)return rG(e,-1)||rB(e,-1);if(46==i&&!t.shiftKey||iW&&68==i&&"c"==r)return rG(e,1)||rB(e,1);if(13==i||27==i)return!0;if(37==i||iW&&66==i&&"c"==r){let t=37==i?"ltr"==rV(e,e.state.selection.from)?-1:1:-1;return rF(e,t,r)||rB(e,t)}if(39==i||iW&&70==i&&"c"==r){let t=39==i?"ltr"==rV(e,e.state.selection.from)?1:-1:1;return rF(e,t,r)||rB(e,t)}else if(38==i||iW&&80==i&&"c"==r)return rH(e,-1,r)||rB(e,-1);else if(40==i||iW&&78==i&&"c"==r)return function(e){if(!iH||e.state.selection.$head.parentOffset>0)return!1;let{focusNode:t,focusOffset:n}=e.domSelectionRange();if(t&&1==t.nodeType&&0==n&&t.firstChild&&"false"==t.firstChild.contentEditable){let n=t.firstChild;rW(e,n,"true"),setTimeout(()=>rW(e,n,"false"),20)}return!1}(e)||rH(e,1,r)||rB(e,1);else if(r==(iW?"m":"c")&&(66==i||73==i||89==i||90==i))return!0;return!1}(e,t)?t.preventDefault():r4(e,"key");else{let t=Date.now();e.input.lastIOSEnter=t,e.input.lastIOSEnterFallbackTimeout=setTimeout(()=>{e.input.lastIOSEnter==t&&(e.someProp("handleKeyDown",t=>t(e,iR(13,"Enter"))),e.input.lastIOSEnter=0)},200)}},r2.keyup=(e,t)=>{16==t.keyCode&&(e.input.shiftKey=!1)},r2.keypress=(e,t)=>{if(oa(e)||!t.charCode||t.ctrlKey&&!t.altKey||iW&&t.metaKey)return;if(e.someProp("handleKeyPress",n=>n(e,t)))return void t.preventDefault();let n=e.state.selection;if(!(n instanceof nO)||!n.$from.sameParent(n.$to)){let i=String.fromCharCode(t.charCode),r=()=>e.state.tr.insertText(i).scrollIntoView();/[\r\n]/.test(i)||e.someProp("handleTextInput",t=>t(e,n.$from.pos,n.$to.pos,i,r))||e.dispatch(r()),t.preventDefault()}};let on=iW?"metaKey":"ctrlKey";r1.mousedown=(e,t)=>{var n;let i,r;e.input.shiftKey=t.shiftKey;let o=oc(e),a=Date.now(),s="singleClick";
230a-e.input.lastClick.time<500&&(i=(n=e.input.lastClick).x-t.clientX)*i+(r=n.y-t.clientY)*r<100&&!t[on]&&e.input.lastClick.button==t.button&&("singleClick"==e.input.lastClick.type?s="doubleClick":"doubleClick"==e.input.lastClick.type&&(s="tripleClick")),e.input.lastClick={time:a,x:t.clientX,y:t.clientY,type:s,button:t.button},e.input.mouseDown&&e.input.mouseDown.done();let l=e.posAtCoords(r7(t));l&&("singleClick"==s?e.input.mouseDown=new or(e,l,t,!!o):("doubleClick"==s?function(e,t,n,i){return r9(e,"handleDoubleClickOn",t,n,i)||e.someProp("handleDoubleClick",n=>n(e,t,i))}:function(e,t,n,i){return r9(e,"handleTripleClickOn",t,n,i)||e.someProp("handleTripleClick",n=>n(e,t,i))||function(e,t,n){if(0!=n.button)return!1;let i=ot(e,t,!0),r=e.state.doc;return!!i&&(oe(e,i,"pointer"),i instanceof nO&&r.eq(e.state.doc)&&(e.input.mouseDown=new oo(e,i)),!0)}(e,n,i)})(e,l.pos,l.inside,t)?t.preventDefault():r4(e,"pointer"))};class oi{constructor(e){this.view=e,this.mightDrag=null,e.root.addEventListener("mouseup",this.up=this.up.bind(this)),e.root.addEventListener("mousemove",this.move=this.move.bind(this))}up(e){this.done()}move(e){0==e.buttons&&this.done()}done(){this.view.root.removeEventListener("mouseup",this.up),this.view.root.removeEventListener("mousemove",this.move),this.view.input.mouseDown==this&&(this.view.input.mouseDown=null)}delaySelUpdate(){return!1}}class or extends oi{constructor(e,t,n,i){let r,o;if(super(e),this.pos=t,this.event=n,this.flushed=i,this.delayedSelectionSync=!1,this.startDoc=e.state.doc,this.selectNode=!!n[on],this.allowDefault=n.shiftKey,t.inside>-1)r=e.state.doc.nodeAt(t.inside),o=t.inside;else{let n=e.state.doc.resolve(t.pos);r=n.parent,o=n.depth?n.before():0}const a=i?null:n.target,s=a?e.docView.nearestDesc(a,!0):null;this.target=s&&1==s.nodeDOM.nodeType?s.nodeDOM:null;let{selection:l}=e.state;0==n.button&&(r.type.spec.draggable&&!1!==r.type.spec.selectable||l instanceof nB&&l.from<=o&&l.to>o)&&(this.mightDrag={node:r,pos:o,addAttr:!!(this.target&&!this.target.draggable),setUneditable:!!(this.target&&iB&&!this.target.hasAttribute("contentEditable"))}),this.target&&this.mightDrag&&(this.mightDrag.addAttr||this.mightDrag.setUneditable)&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&(this.target.draggable=!0),this.mightDrag.setUneditable&&setTimeout(()=>{this.view.input.mouseDown==this&&this.target.setAttribute("contentEditable","false")},20),this.view.domObserver.start()),r4(e,"pointer")}done(){super.done(),this.mightDrag&&this.target&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&this.target.removeAttribute("draggable"),this.mightDrag.setUneditable&&this.target.removeAttribute("contentEditable"),this.view.domObserver.start()),this.delayedSelectionSync&&setTimeout(()=>{this.view.isDestroyed||rS(this.view)})}up(e){if(this.done(),!this.view.dom.contains(e.target))return;let t=this.pos;if(this.view.state.doc!=this.startDoc&&(t=this.view.posAtCoords(r7(e))),this.updateAllowDefault(e),this.allowDefault||!t)r4(this.view,"pointer");else{var n,i,r,o;(n=this.view,i=t.pos,r=t.inside,o=this.selectNode,r9(n,"handleClickOn",i,r,e)||n.someProp("handleClick",t=>t(n,i,e))||(o?function(e,t){if(-1==t)return!1;let n=e.state.selection,i,r;n instanceof nB&&(i=n.node);let o=e.state.doc.resolve(t);for(let e=o.depth+1;e>0;e--){let t=e>o.depth?o.nodeAfter:o.node(e);if(nB.isSelectable(t)){r=i&&n.$from.depth>0&&e>=n.$from.depth&&o.before(n.$from.depth+1)==n.$from.pos?o.before(n.$from.depth):o.before(e);break}}return null!=r&&(oe(e,nB.create(e.state.doc,r),"pointer"),!0)}(n,r):function(e,t){if(-1==t)return!1;let n=e.state.doc.resolve(t),i=n.nodeAfter;return!!(i&&i.isAtom&&nB.isSelectable(i))&&(oe(e,new nB(n),"pointer"),!0)}(n,r)))?e.preventDefault():0==e.button&&(this.flushed||iH&&this.mightDrag&&!this.mightDrag.node.isAtom||ij&&!this.view.state.selection.visible&&2>=Math.min(Math.abs(t.pos-this.view.state.selection.from),Math.abs(t.pos-this.view.state.selection.to)))?(oe(this.view,nP.near(this.view.state.doc.resolve(t.pos)),"pointer"),e.preventDefault()):r4(this.view,"pointer")}}move(e){this.updateAllowDefault(e),r4(this.view,"pointer"),super.move(e)}updateAllowDefault(e){!this.allowDefault&&(Math.abs(this.event.x-e.clientX)>4||Math.abs(this.event.y-e.clientY)>4)&&(this.allowDefault=!0)}delaySelUpdate(){return!!this.allowDefault&&(this.delayedSelectionSync=!0,!0)}}class oo extends oi{constructor(e,t){super(e),this.startSelection=t,this.startDoc=e.state.doc}move(e){if(0==e.buttons||this.view.isDestroyed||!this.view.state.doc.eq(this.startDoc))return void this.done();e.preventDefault(),r4(this.view,"pointer");let t=this.view.posAtCoords(r7(e)),n=t&&ot(this.view,t.inside,!1);if(!n)return;let{doc:i}=this.view.state,r=this.startSelection,[o,a]=n.from<r.from?[r.to,n.from]:[r.from,n.to];oe(this.view,nO.create(i,o,a),"pointer")}}function oa(e,t){return!!e.composing||!!(iH&&500>Math.abs(Date.now()-e.input.compositionEndedAt))&&(e.input.compositionEndedAt=-2e8,!0)}r1.touchstart=e=>{e.input.lastTouch=Date.now(),oc(e),r4(e,"pointer")},r1.touchmove=e=>{e.input.lastTouch=Date.now(),r4(e,"pointer")},r1.contextmenu=e=>oc(e);let ol=iU?5e3:-1;function od(e,t){clearTimeout(e.input.composingTimeout),t>-1&&(e.input.composingTimeout=setTimeout(()=>
230oc(e),t))}function ou(e){for(e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=Date.now());e.input.compositionNodes.length>0;)e.input.compositionNodes.pop().markParentsDirty()}function oc(e,t=!1){if(!iU||!(e.domObserver.flushingSoon>=0)){if(e.domObserver.forceFlush(),ou(e),t||e.docView&&e.docView.dirty){let n=rw(e),i=e.state.selection;return n&&!n.eq(i)?e.dispatch(e.state.tr.setSelection(n)):(e.markCursor||t)&&!i.$from.node(i.$from.sharedDepth(i.to)).inlineContent?e.dispatch(e.state.tr.deleteSelection()):e.updateState(e.state),!0}return!1}}r2.compositionstart=r2.compositionupdate=e=>{if(!e.composing){e.domObserver.flush();let{state:t}=e,n=t.selection.$to;if(t.selection instanceof nO&&(t.storedMarks||!n.textOffset&&n.parentOffset&&n.nodeBefore.marks.some(e=>!1===e.type.spec.inclusive)||ij&&i$&&function(e){let{focusNode:t,focusOffset:n}=e.domSelectionRange();if(!t||1!=t.nodeType||n>=t.childNodes.length)return!1;let i=t.childNodes[n];return 1==i.nodeType&&"false"==i.contentEditable}(e)))e.markCursor=e.state.storedMarks||n.marks(),oc(e,!0),e.markCursor=null;else if(oc(e,!t.selection.empty),iB&&t.selection.empty&&n.parentOffset&&!n.textOffset&&n.nodeBefore.marks.length){let t=e.domSelectionRange();for(let n=t.focusNode,i=t.focusOffset;n&&1==n.nodeType&&0!=i;){let t=i<0?n.lastChild:n.childNodes[i-1];if(!t)break;if(3==t.nodeType){let n=e.domSelection();n&&n.collapse(t,t.nodeValue.length);break}n=t,i=-1}}e.input.composing=!0}od(e,ol)},r2.compositionend=(e,t)=>{e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=Date.now(),e.input.compositionPendingChanges=e.domObserver.pendingRecords().length?e.input.compositionID:0,e.input.compositionNode=null,e.input.badSafariComposition?e.domObserver.forceFlush():e.input.compositionPendingChanges&&Promise.resolve().then(()=>e.domObserver.flush()),e.input.compositionID++,od(e,20))};let oh=iO&&iN<15||iG&&iK<604;function op(e,t,n,i,r){let o=rU(e,t,n,i,e.state.selection.$from);if(e.someProp("handlePaste",t=>t(e,r,o||tf.empty)))return!0;if(!o)return!1;let a=0==o.openStart&&0==o.openEnd&&1==o.content.childCount?o.content.firstChild:null,s=a?e.state.tr.replaceSelectionWith(a,i):e.state.tr.replaceSelection(o);return e.dispatch(s.scrollIntoView().setMeta("paste",!0).setMeta("uiEvent","paste")),!0}function of(e){let t=e.getData("text/plain")||e.getData("Text");if(t)return t;let n=e.getData("text/uri-list");return n?n.replace(/\r?\n/g," "):""}r1.copy=r2.cut=(e,t)=>{let n=e.state.selection,i="cut"==t.type;if(n.empty)return;let r=oh?null:t.clipboardData,{dom:o,text:a}=r$(e,n.content());r?(t.preventDefault(),r.clearData(),r.setData("text/html",o.innerHTML),r.setData("text/plain",a)):function(e,t){if(!e.dom.parentNode)return;let n=e.dom.parentNode.appendChild(document.createElement("div"));n.appendChild(t),n.style.cssText="position: fixed; left: -10000px; top: 10px";let i=getSelection(),r=document.createRange();r.selectNodeContents(t),e.dom.blur(),i.removeAllRanges(),i.addRange(r),setTimeout(()=>{n.parentNode&&n.parentNode.removeChild(n),e.focus()},50)}(e,o),i&&e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))},r2.paste=(e,t)=>{if(e.composing&&!iU)return;let n=oh?null:t.clipboardData,i=e.input.shiftKey&&45!=e.input.lastKeyCode;n&&op(e,of(n),n.getData("text/html"),i,t)?t.preventDefault():function(e,t){if(!e.dom.parentNode)return;let n=e.input.shiftKey||e.state.selection.$from.parent.type.spec.code,i=e.dom.parentNode.appendChild(document.createElement(n?"textarea":"div"));n||(i.contentEditable="true"),i.style.cssText="position: fixed; left: -10000px; top: 10px",i.focus();let r=e.input.shiftKey&&45!=e.input.lastKeyCode;setTimeout(()=>{e.focus(),i.parentNode&&i.parentNode.removeChild(i),n?op(e,i.value,null,r,t):op(e,i.textContent,i.innerHTML,r,t)},50)}(e,t)};class og{constructor(e,t,n){this.slice=e,this.move=t,this.node=n}}let om=iW?"altKey":"ctrlKey";function ov(e,t){let n;return e.someProp("dragCopies",e=>{n=n||e(t)}),null!=n?!n:!t[om]}for(let e in r1.dragstart=(e,t)=>{let n,i=e.input.mouseDown;if(i&&i.done(),!t.dataTransfer)return;let r=e.state.selection,o=r.empty?null:e.posAtCoords(r7(t));if(o&&o.pos>=r.from&&o.pos<=(r instanceof nB?r.to-1:r.to));else if(i&&i.mightDrag)n=nB.create(e.state.doc,i.mightDrag.pos);else if(t.target&&1==t.target.nodeType){let i=e.docView.nearestDesc(t.target,!0);i&&i.node.type.spec.draggable&&i!=e.docView&&(n=nB.create(e.state.doc,i.posBefore))}
vendor: 4,382 bytes, line 230
230let a=(n||e.state.selection).content(),{dom:s,text:l,slice:d}=r$(e,a);t.dataTransfer.files.length&&ij&&!(iV>120)||t.dataTransfer.clearData(),t.dataTransfer.setData(oh?"Text":"text/html",s.innerHTML),t.dataTransfer.effectAllowed="copyMove",oh||t.dataTransfer.setData("text/plain",l),e.dragging=new og(d,ov(e,t),n)},r1.dragend=e=>{let t=e.dragging;window.setTimeout(()=>{e.dragging==t&&(e.dragging=null)},50)},r2.dragover=r2.dragenter=(e,t)=>t.preventDefault(),r2.drop=(e,t)=>{try{!function(e,t,n){if(!t.dataTransfer)return;let i=e.posAtCoords(r7(t));if(!i)return;let r=e.state.doc.resolve(i.pos),o=n&&n.slice;o?e.someProp("transformPasted",t=>{o=t(o,e,!1)}):o=rU(e,of(t.dataTransfer),oh?null:t.dataTransfer.getData("text/html"),!1,r);let a=!!(n&&ov(e,t));if(e.someProp("handleDrop",n=>n(e,t,o||tf.empty,a)))return t.preventDefault();if(!o)return;t.preventDefault();let s=o?ny(e.state.doc,r.pos,o):r.pos;null==s&&(s=r.pos);let l=e.state.tr;if(a){let{node:e}=n;e?e.replace(l):l.deleteSelection()}let d=l.mapping.map(s),u=0==o.openStart&&0==o.openEnd&&1==o.content.childCount,c=l.doc;if(u?l.replaceRangeWith(d,d,o.content.firstChild):l.replaceRange(d,d,o),l.doc.eq(c))return;let h=l.doc.resolve(d);if(u&&nB.isSelectable(o.content.firstChild)&&h.nodeAfter&&h.nodeAfter.sameMarkup(o.content.firstChild))l.setSelection(new nB(h));else{let t=l.mapping.map(s);l.mapping.maps[l.mapping.maps.length-1].forEach((e,n,i,r)=>t=r),l.setSelection(rI(e,h,l.doc.resolve(t)))}e.focus(),e.dispatch(l.setMeta("uiEvent","drop"))}(e,t,e.dragging)}finally{e.dragging=null}},r1.focus=e=>{e.input.lastFocus=Date.now(),e.focused||(e.domObserver.stop(),e.dom.classList.add("ProseMirror-focused"),e.domObserver.start(),e.focused=!0,setTimeout(()=>{e.docView&&e.hasFocus()&&!e.domObserver.currentSelection.eq(e.domSelectionRange())&&rS(e)},20))},r1.blur=(e,t)=>{e.focused&&(e.domObserver.stop(),e.dom.classList.remove("ProseMirror-focused"),e.domObserver.start(),t.relatedTarget&&e.dom.contains(t.relatedTarget)&&e.domObserver.currentSelection.clear(),e.focused=!1)},r1.beforeinput=(e,t)=>{if(ij&&iU&&"deleteContentBackward"==t.inputType){e.domObserver.flushSoon();let{domChangeCount:t}=e.input;setTimeout(()=>{if(e.input.domChangeCount!=t||(e.dom.blur(),e.focus(),e.someProp("handleKeyDown",t=>t(e,iR(8,"Backspace")))))return;let{$cursor:n}=e.state.selection;n&&n.pos>0&&e.dispatch(e.state.tr.delete(n.pos-1,n.pos).scrollIntoView())},50)}},r2)r1[e]=r2[e];function oy(e,t){if(e==t)return!0;for(let n in e)if(e[n]!==t[n])return!1;for(let n in t)if(!(n in e))return!1;return!0}class ob{constructor(e,t){this.toDOM=e,this.spec=t||o_,this.side=this.spec.side||0}map(e,t,n,i){let{pos:r,deleted:o}=e.mapResult(t.from+i,this.side<0?-1:1);return o?null:new oC(r-n,r-n,this)}valid(){return!0}eq(e){return this==e||e instanceof ob&&(this.spec.key&&this.spec.key==e.spec.key||this.toDOM==e.toDOM&&oy(this.spec,e.spec))}destroy(e){this.spec.destroy&&this.spec.destroy(e)}}class ox{constructor(e,t){this.attrs=e,this.spec=t||o_}map(e,t,n,i){let r=e.map(t.from+i,this.spec.inclusiveStart?-1:1)-n,o=e.map(t.to+i,this.spec.inclusiveEnd?1:-1)-n;return r>=o?null:new oC(r,o,this)}valid(e,t){return t.from<t.to}eq(e){return this==e||e instanceof ox&&oy(this.attrs,e.attrs)&&oy(this.spec,e.spec)}static is(e){return e.type instanceof ox}destroy(){}}class ow{constructor(e,t){this.attrs=e,this.spec=t||o_}map(e,t,n,i){let r=e.mapResult(t.from+i,1);if(r.deleted)return null;let o=e.mapResult(t.to+i,-1);return o.deleted||o.pos<=r.pos?null:new oC(r.pos-n,o.pos-n,this)}valid(e,t){let{index:n,offset:i}=e.content.findIndex(t.from),r;return i==t.from&&!(r=e.child(n)).isText&&i+r.nodeSize==t.to}eq(e){return this==e||e instanceof ow&&oy(this.attrs,e.attrs)&&oy(this.spec,e.spec)}destroy(){}}class oC{constructor(e,t,n){this.from=e,this.to=t,this.type=n}copy(e,t){return new oC(e,t,this.type)}eq(e,t=0){return this.type.eq(e.type)&&this.from+t==e.from&&this.to+t==e.to}map(e,t,n){return this.type.map(e,this,t,n)}static widget(e,t,n){return new oC(e,e,new ob(t,n))}static inline(e,t,n,i){return new oC(e,t,new ox(n,i))}static node(e,t,n,i){return new oC(e,t,new ow(n,i))}get spec(){return this.type.spec}get inline(){return this.type instanceof ox}get widget(){return this.type instanceof ob}}let oS=[],o_={};class ok{constructor(e,t){this.local=e.length?e:oS,this.children=t.length?t:oS}static create(e,t){return t.length?oA(t,e,0,o_):oM}
vendor: 4,481 bytes, line 230
230find(e,t,n){let i=[];return this.findInner(null==e?0:e,null==t?1e9:t,i,0,n),i}findInner(e,t,n,i,r){for(let o=0;o<this.local.length;o++){let a=this.local[o];a.from<=t&&a.to>=e&&(!r||r(a.spec))&&n.push(a.copy(a.from+i,a.to+i))}for(let o=0;o<this.children.length;o+=3)if(this.children[o]<t&&this.children[o+1]>e){let a=this.children[o]+1;this.children[o+2].findInner(e-a,t-a,n,i+a,r)}}map(e,t,n){return this==oM||0==e.maps.length?this:this.mapInner(e,t,0,0,n||o_)}mapInner(e,t,n,i,r){let o;for(let a=0;a<this.local.length;a++){let s=this.local[a].map(e,n,i);s&&s.type.valid(t,s)?(o||(o=[])).push(s):r.onRemove&&r.onRemove(this.local[a].spec)}return this.children.length?function(e,t,n,i,r,o,a){let s=e.slice();for(let e=0,t=o;e<n.maps.length;e++){let i=0;n.maps[e].forEach((e,n,r,o)=>{let a=o-r-(n-e);for(let r=0;r<s.length;r+=3){let o=s[r+1];if(o<0||e>o+t-i)continue;let l=s[r]+t-i;n>=l?s[r+1]=e<=l?-2:-1:e>=t&&a&&(s[r]+=a,s[r+1]+=a)}i+=a}),t=n.maps[e].map(t,-1)}let l=!1;for(let t=0;t<s.length;t+=3)if(s[t+1]<0){if(-2==s[t+1]){l=!0,s[t+1]=-1;continue}let d=n.map(e[t]+o),u=d-r;if(u<0||u>=i.content.size){l=!0;continue}let c=n.map(e[t+1]+o,-1)-r,{index:h,offset:p}=i.content.findIndex(u),f=i.maybeChild(h);if(f&&p==u&&p+f.nodeSize==c){let i=s[t+2].mapInner(n,f,d+1,e[t]+o+1,a);i!=oM?(s[t]=u,s[t+1]=c,s[t+2]=i):(s[t+1]=-2,l=!0)}else l=!0}if(l){let l=oA(function(e,t,n,i,r,o,a){for(let s=0;s<e.length;s+=3)-1==e[s+1]&&function e(t,o){for(let e=0;e<t.local.length;e++){let s=t.local[e].map(i,r,o);s?n.push(s):a.onRemove&&a.onRemove(t.local[e].spec)}for(let n=0;n<t.children.length;n+=3)e(t.children[n+2],t.children[n]+o+1)}(e[s+2],t[s]+o+1);return n}(s,e,t,n,r,o,a),i,0,a);t=l.local;for(let e=0;e<s.length;e+=3)s[e+1]<0&&(s.splice(e,3),e-=3);for(let e=0,t=0;e<l.children.length;e+=3){let n=l.children[e];for(;t<s.length&&s[t]<n;)t+=3;s.splice(t,0,l.children[e],l.children[e+1],l.children[e+2])}}return new ok(t.sort(oP),s)}(this.children,o||[],e,t,n,i,r):o?new ok(o.sort(oP),oS):oM}add(e,t){return t.length?this==oM?ok.create(e,t):this.addInner(e,t,0):this}addInner(e,t,n){let i,r=0;e.forEach((e,o)=>{let a=o+n,s;if(s=oR(t,e,a)){for(i||(i=this.children.slice());r<i.length&&i[r]<o;)r+=3;i[r]==o?i[r+2]=i[r+2].addInner(e,s,a+1):i.splice(r,0,o,o+e.nodeSize,oA(s,e,a+1,o_)),r+=3}});let o=oD(r?oI(t):t,-n);for(let t=0;t<o.length;t++)o[t].type.valid(e,o[t])||o.splice(t--,1);return new ok(o.length?this.local.concat(o).sort(oP):this.local,i||this.children)}remove(e){return 0==e.length||this==oM?this:this.removeInner(e,0)}removeInner(e,t){let n=this.children,i=this.local;for(let i=0;i<n.length;i+=3){let r,o=n[i]+t,a=n[i+1]+t;for(let t=0,n;t<e.length;t++)(n=e[t])&&n.from>o&&n.to<a&&(e[t]=null,(r||(r=[])).push(n));if(!r)continue;n==this.children&&(n=this.children.slice());let s=n[i+2].removeInner(r,o+1);s!=oM?n[i+2]=s:(n.splice(i,3),i-=3)}if(i.length){for(let n=0,r;n<e.length;n++)if(r=e[n])for(let e=0;e<i.length;e++)i[e].eq(r,t)&&(i==this.local&&(i=this.local.slice()),i.splice(e--,1))}return n==this.children&&i==this.local?this:i.length||n.length?new ok(i,n):oM}forChild(e,t){let n,i;if(this==oM)return this;if(t.isLeaf)return ok.empty;for(let t=0;t<this.children.length;t+=3)if(this.children[t]>=e){this.children[t]==e&&(n=this.children[t+2]);break}let r=e+1,o=r+t.content.size;for(let e=0;e<this.local.length;e++){let t=this.local[e];if(t.from<o&&t.to>r&&t.type instanceof ox){let e=Math.max(r,t.from)-r,n=Math.min(o,t.to)-r;e<n&&(i||(i=[])).push(t.copy(e,n))}}if(i){let e=new ok(i.sort(oP),oS);return n?new oT([e,n]):e}return n||oM}eq(e){if(this==e)return!0;if(!(e instanceof ok)||this.local.length!=e.local.length||this.children.length!=e.children.length)return!1;for(let t=0;t<this.local.length;t++)if(!this.local[t].eq(e.local[t]))return!1;for(let t=0;t<this.children.length;t+=3)if(this.children[t]!=e.children[t]||this.children[t+1]!=e.children[t+1]||!this.children[t+2].eq(e.children[t+2]))return!1;return!0}locals(e){return oE(this.localsInner(e))}localsInner(e){if(this==oM)return oS;if(e.inlineContent||!this.local.some(ox.is))return this.local;let t=[];for(let e=0;e<this.local.length;e++)this.local[e].type instanceof ox||t.push(this.local[e]);return t}forEachSet(e){e(this)}}ok.empty=new ok([],[]),ok.removeOverlap=oE;let oM=ok.empty;class oT{constructor(e){this.members=e}map(e,t){let n=this.members.map(n=>n.map(e,t,o_));return oT.from(n)}forChild(e,t){if(t.isLeaf)return ok.empty;let n=[];for(let i=0;i<this.members.length;i++){let r=this.members[i].forChild(e,t);
vendor: 5,589 bytes, line 230
230r!=oM&&(r instanceof oT?n=n.concat(r.members):n.push(r))}return oT.from(n)}eq(e){if(!(e instanceof oT)||e.members.length!=this.members.length)return!1;for(let t=0;t<this.members.length;t++)if(!this.members[t].eq(e.members[t]))return!1;return!0}locals(e){let t,n=!0;for(let i=0;i<this.members.length;i++){let r=this.members[i].localsInner(e);if(r.length)if(t){n&&(t=t.slice(),n=!1);for(let e=0;e<r.length;e++)t.push(r[e])}else t=r}return t?oE(n?t:t.sort(oP)):oS}static from(e){switch(e.length){case 0:return oM;case 1:return e[0];default:return new oT(e.every(e=>e instanceof ok)?e:e.reduce((e,t)=>e.concat(t instanceof ok?t:t.members),[]))}}forEachSet(e){for(let t=0;t<this.members.length;t++)this.members[t].forEachSet(e)}}function oD(e,t){if(!t||!e.length)return e;let n=[];for(let i=0;i<e.length;i++){let r=e[i];n.push(new oC(r.from+t,r.to+t,r.type))}return n}function oR(e,t,n){if(t.isLeaf)return null;let i=n+t.nodeSize,r=null;for(let t=0,o;t<e.length;t++)(o=e[t])&&o.from>n&&o.to<i&&((r||(r=[])).push(o),e[t]=null);return r}function oI(e){let t=[];for(let n=0;n<e.length;n++)null!=e[n]&&t.push(e[n]);return t}function oA(e,t,n,i){let r=[],o=!1;t.forEach((t,a)=>{let s=oR(e,t,a+n);if(s){o=!0;let e=oA(s,t,n+a+1,i);e!=oM&&r.push(a,a+t.nodeSize,e)}});let a=oD(o?oI(e):e,-n).sort(oP);for(let e=0;e<a.length;e++)a[e].type.valid(t,a[e])||(i.onRemove&&i.onRemove(a[e].spec),a.splice(e--,1));return a.length||r.length?new ok(a,r):oM}function oP(e,t){return e.from-t.from||e.to-t.to}function oE(e){let t=e;for(let n=0;n<t.length-1;n++){let i=t[n];if(i.from!=i.to)for(let r=n+1;r<t.length;r++){let o=t[r];if(o.from==i.from){o.to!=i.to&&(t==e&&(t=e.slice()),t[r]=o.copy(o.from,i.to),oL(t,r+1,o.copy(i.to,o.to)));continue}o.from<i.to&&(t==e&&(t=e.slice()),t[n]=i.copy(i.from,o.from),oL(t,r,i.copy(o.from,i.to)));break}}return t}function oL(e,t,n){for(;t<e.length&&oP(n,e[t])>0;)t++;e.splice(t,0,n)}function oF(e){let t=[];return e.someProp("decorations",n=>{let i=n(e.state);i&&i!=oM&&t.push(i)}),e.cursorWrapper&&t.push(ok.create(e.state.doc,[e.cursorWrapper.deco])),oT.from(t)}let oO={childList:!0,characterData:!0,characterDataOldValue:!0,attributes:!0,attributeOldValue:!0,subtree:!0},oN=iO&&iN<=11;class oB{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}set(e){this.anchorNode=e.anchorNode,this.anchorOffset=e.anchorOffset,this.focusNode=e.focusNode,this.focusOffset=e.focusOffset}clear(){this.anchorNode=this.focusNode=null}eq(e){return e.anchorNode==this.anchorNode&&e.anchorOffset==this.anchorOffset&&e.focusNode==this.focusNode&&e.focusOffset==this.focusOffset}}class oz{constructor(e,t){this.view=e,this.handleDOMChange=t,this.queue=[],this.flushingSoon=-1,this.observer=null,this.currentSelection=new oB,this.onCharData=null,this.suppressingSelectionUpdates=!1,this.lastChangedTextNode=null,this.observer=window.MutationObserver&&new window.MutationObserver(t=>{for(let e=0;e<t.length;e++)this.queue.push(t[e]);iO&&iN<=11&&t.some(e=>"childList"==e.type&&e.removedNodes.length||"characterData"==e.type&&e.oldValue.length>e.target.nodeValue.length)?this.flushSoon():iH&&e.composing&&t.some(e=>"childList"==e.type&&"TR"==e.target.nodeName)?(e.input.badSafariComposition=!0,this.flushSoon()):this.flush()}),oN&&(this.onCharData=e=>{this.queue.push({target:e.target,type:"characterData",oldValue:e.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this)}flushSoon(){this.flushingSoon<0&&(this.flushingSoon=window.setTimeout(()=>{this.flushingSoon=-1,this.flush()},20))}forceFlush(){this.flushingSoon>-1&&(window.clearTimeout(this.flushingSoon),this.flushingSoon=-1,this.flush())}start(){this.observer&&(this.observer.takeRecords(),this.observer.observe(this.view.dom,oO)),this.onCharData&&this.view.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.connectSelection()}stop(){if(this.observer){let e=this.observer.takeRecords();if(e.length){for(let t=0;t<e.length;t++)this.queue.push(e[t]);window.setTimeout(()=>this.flush(),20)}this.observer.disconnect()}this.onCharData&&this.view.dom.removeEventListener("DOMCharacterDataModified",this.onCharData),this.disconnectSelection()}connectSelection(){this.view.dom.ownerDocument.addEventListener("selectionchange",this.onSelectionChange)}disconnectSelection(){this.view.dom.ownerDocument.removeEventListener("selectionchange",this.onSelectionChange)}suppressSelectionUpdates(){this.suppressingSelectionUpdates=!0,setTimeout(()=>this.suppressingSelectionUpdates=!1,50)}onSelectionChange(){if(rA(this.view)){if(this.suppressingSelectionUpdates)return rS(this.view);if(iO&&iN<=11&&!this.view.state.selection.empty){let e=this.view.domSelectionRange();if(e.focusNode&&iS(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset))return this.flushSoon()}this.flush()}}setCurSelection(){this.currentSelection.set(this.view.domSelectionRange())}ignoreSelectionChange(e){if(!e.focusNode)return!0;let t=new Set,n;for(let n=e.focusNode;n;n=ib(n))t.add(n);for(let i=e.anchorNode;i;i=ib(i))if(t.has(i)){n=i;break}let i=n&&this.view.docView.nearestDesc(n);if(i&&i.ignoreMutation({type:"selection",target:3==n.nodeType?n.parentNode:n}))return this.setCurSelection(),!0}pendingRecords(){if(this.observer)for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}flush(){var e;let{view:t}=this;if(!t.docView||this.flushingSoon>-1)return;let n=this.pendingRecords();n.length&&(this.queue=[]);let i=t.domSelectionRange(),r=!this.suppressingSelectionUpdates&&!this.currentSelection.eq(i)&&rA(t)&&!this.ignoreSelectionChange(i),o=-1,a=-1,s=!1,l=[];
230if(t.editable)for(let e=0;e<n.length;e++){let t=this.registerMutation(n[e],l);t&&(o=o<0?t.from:Math.min(t.from,o),a=a<0?t.to:Math.max(t.to,a),t.typeOver&&(s=!0))}if(l.some(e=>"BR"==e.nodeName)&&(8==t.input.lastKeyCode||46==t.input.lastKeyCode||ij&&(t.composing||t.input.compositionEndedAt>Date.now()-50)&&n.some(e=>"childList"==e.type&&e.removedNodes.length))){for(let e of l)if("BR"==e.nodeName&&e.parentNode){let t=e.nextSibling;for(;t&&1==t.nodeType;){if("false"==t.contentEditable){e.parentNode.removeChild(e);break}t=t.firstChild}}}else if(iB&&l.length){let e=l.filter(e=>"BR"==e.nodeName);if(2==e.length){let[t,n]=e;t.parentNode&&t.parentNode.parentNode==n.parentNode?n.remove():t.remove()}else{let{focusNode:n}=this.currentSelection;for(let i of e){let e=i.parentNode;e&&"LI"==e.nodeName&&(!n||function(e,t){for(let n=t.parentNode;n&&n!=e.dom;n=n.parentNode){let t=e.docView.nearestDesc(n,!0);if(t&&t.node.isBlock)return n}return null}(t,n)!=e)&&i.remove()}}}let d=null;o<0&&r&&t.input.lastFocus>Date.now()-200&&Math.max(t.input.lastTouch,t.input.lastClick.time)<Date.now()-300&&iD(i)&&(d=rw(t))&&d.eq(nP.near(t.state.doc.resolve(0),1))?(t.input.lastFocus=0,rS(t),this.currentSelection.set(i),t.scrollToSelection()):(o>-1||r)&&(o>-1&&(t.docView.markDirty(o,a),e=t,!oj.has(e)&&(oj.set(e,null),-1!==["normal","nowrap","pre-line"].indexOf(getComputedStyle(e.dom).whiteSpace))&&(e.requiresGeckoHackNode=iB,oV||(console.warn("ProseMirror expects the CSS white-space property to be set, preferably to 'pre-wrap'. It is recommended to load style/prosemirror.css from the prosemirror-view package."),oV=!0))),t.input.badSafariComposition&&(t.input.badSafariComposition=!1,function(e,t){var n;let{focusNode:i,focusOffset:r}=e.domSelectionRange();for(let o of t)if((null==(n=o.parentNode)?void 0:n.nodeName)=="TR"){let t=o.nextSibling;for(;t&&"TD"!=t.nodeName&&"TH"!=t.nodeName;)t=t.nextSibling;if(t){let n=t;for(;;){let e=n.firstChild;if(!e||1!=e.nodeType||"false"==e.contentEditable||/^(BR|IMG)$/.test(e.nodeName))break;n=e}n.insertBefore(o,n.firstChild),i==o&&e.domSelection().collapse(o,r)}else o.parentNode.removeChild(o)}}(t,l)),this.handleDOMChange(o,a,s,l),t.docView&&t.docView.dirty?t.updateState(t.state):this.currentSelection.eq(i)||rS(t),this.currentSelection.set(i))}registerMutation(e,t){if(t.indexOf(e.target)>-1)return null;let n=this.view.docView.nearestDesc(e.target);if("attributes"==e.type&&(n==this.view.docView||"contenteditable"==e.attributeName||"style"==e.attributeName&&!e.oldValue&&!e.target.getAttribute("style"))||!n||n.ignoreMutation(e))return null;if("childList"==e.type){for(let n=0;n<e.addedNodes.length;n++){let i=e.addedNodes[n];t.push(i),3==i.nodeType&&(this.lastChangedTextNode=i)}if(n.contentDOM&&n.contentDOM!=n.dom&&!n.contentDOM.contains(e.target))return{from:n.posBefore,to:n.posAfter};let i=e.previousSibling,r=e.nextSibling;if(iO&&iN<=11&&e.addedNodes.length)for(let t=0;t<e.addedNodes.length;t++){let{previousSibling:n,nextSibling:o}=e.addedNodes[t];(!n||0>Array.prototype.indexOf.call(e.addedNodes,n))&&(i=n),(!o||0>Array.prototype.indexOf.call(e.addedNodes,o))&&(r=o)}let o=i&&i.parentNode==e.target?iy(i)+1:0,a=n.localPosFromDOM(e.target,o,-1),s=r&&r.parentNode==e.target?iy(r):e.target.childNodes.length;return{from:a,to:n.localPosFromDOM(e.target,s,1)}}return"attributes"==e.type?{from:n.posAtStart-n.border,to:n.posAtEnd+n.border}:(this.lastChangedTextNode=e.target,{from:n.posAtStart,to:n.posAtEnd,typeOver:e.target.nodeValue==e.oldValue})}}let oj=new WeakMap,oV=!1;function oH(e,t){let n=t.startContainer,i=t.startOffset,r=t.endContainer,o=t.endOffset,a=e.domAtPos(e.state.selection.anchor);return iS(a.node,a.offset,r,o)&&([n,i,r,o]=[r,o,n,i]),{anchorNode:n,anchorOffset:i,focusNode:r,focusOffset:o}}function oG(e){let t=e.pmViewDesc;if(t)return t.parseRule();if("BR"==e.nodeName&&e.parentNode){if(iH&&/^(ul|ol)$/i.test(e.parentNode.nodeName)){let e=document.createElement("div");return e.appendChild(document.createElement("li")),{skip:e}}else if(e.parentNode.lastChild==e||iH&&/^(tr|table)$/i.test(e.parentNode.nodeName))return{ignore:!0}}else if("IMG"==e.nodeName&&e.getAttribute("mark-placeholder"))return{ignore:!0};return null}let oW=/^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|dfn|em|i|img|ins|kbd|label|map|mark|meter|output|q|ruby|s|samp|small|span|strong|su[bp]|time|u|tt|var)$/i;
vendor: 1,307 bytes, line 230
230function o$(e,t,n){return Math.max(n.anchor,n.head)>t.content.size?null:rI(e,t.resolve(n.anchor),t.resolve(n.head))}function oU(e,t,n){let i=e.depth,r=t?e.end():e.pos;for(;i>0&&(t||e.indexAfter(i)==e.node(i).childCount);)i--,r++,t=!1;if(n){let t=e.node(i).maybeChild(e.indexAfter(i));for(;t&&!t.isLeaf;)t=t.firstChild,r++}return r}class oq{constructor(e,t){this._root=null,this.focused=!1,this.trackWrites=null,this.mounted=!1,this.markCursor=null,this.cursorWrapper=null,this.lastSelectedViewDesc=void 0,this.input=new r5,this.prevDirectPlugins=[],this.pluginViews=[],this.requiresGeckoHackNode=!1,this.dragging=null,this._props=t,this.state=t.state,this.directPlugins=t.plugins||[],this.directPlugins.forEach(oJ),this.dispatch=this.dispatch.bind(this),this.dom=e&&e.mount||document.createElement("div"),e&&(e.appendChild?e.appendChild(this.dom):"function"==typeof e?e(this.dom):e.mount&&(this.mounted=!0)),this.editable=oZ(this),oY(this),this.nodeViews=oX(this),this.docView=rs(this.state.doc,oK(this),oF(this),this.dom,this),this.domObserver=new oz(this,(e,t,n,i)=>(function(e,t,n,i,r){let o,a,s,l=e.input.compositionPendingChanges||(e.composing?e.input.compositionID:0);if(e.input.compositionPendingChanges=0,t<0){let t=e.input.lastSelectionTime>Date.now()-50?e.input.lastSelectionOrigin:null,n=rw(e,t);
230if(n&&!e.state.selection.eq(n)){if(ij&&iU&&13===e.input.lastKeyCode&&Date.now()-100<e.input.lastKeyCodeTime&&e.someProp("handleKeyDown",t=>t(e,iR(13,"Enter"))))return;let i=e.state.tr.setSelection(n);"pointer"==t?i.setMeta("pointer",!0):"key"==t&&i.scrollIntoView(),l&&i.setMeta("composition",l),e.dispatch(i)}return}let d=e.state.doc.resolve(t),u=d.sharedDepth(n);t=d.before(u+1),n=e.state.doc.resolve(n).after(u+1);let c=e.state.selection,h=function(e,t,n){let i,{node:r,fromOffset:o,toOffset:a,from:s,to:l}=e.docView.parseRange(t,n),d=e.domSelectionRange(),u=d.anchorNode;if(u&&e.dom.contains(1==u.nodeType?u:u.parentNode)&&(i=[{node:u,offset:d.anchorOffset}],iD(d)||i.push({node:d.focusNode,offset:d.focusOffset})),ij&&8===e.input.lastKeyCode)for(let e=a;e>o;e--){let t=r.childNodes[e-1],n=t.pmViewDesc;if("BR"==t.nodeName&&!n){a=e;break}if(!n||n.size)break}let c=e.state.doc,h=e.someProp("domParser")||tW.fromSchema(e.state.schema),p=c.resolve(s),f=null,g=h.parse(r,{topNode:p.parent,topMatch:p.parent.contentMatchAt(p.index()),topOpen:!0,from:o,to:a,preserveWhitespace:"pre"!=p.parent.type.whitespace||"full",findPositions:i,ruleFromNode:oG,context:p});if(i&&null!=i[0].pos){let e=i[0].pos,t=i[1]&&i[1].pos;null==t&&(t=e),f={anchor:e+s,head:t+s}}return{doc:g,sel:f,from:s,to:l}}(e,t,n),p=e.state.doc,f=p.slice(h.from,h.to);8===e.input.lastKeyCode&&Date.now()-100<e.input.lastKeyCodeTime?(o=e.state.selection.to,a="end"):(o=e.state.selection.from,a="start"),e.input.lastKeyCode=null;let g=function(e,t,n,i,r){let o=e.findDiffStart(t,n),a=n+e.size,s=n+t.size;if(null==o)return null;let{a:l,b:d}=e.findDiffEnd(t,a,s);if("end"==r){let e=Math.max(0,o-Math.min(l,d));i-=l+e-o}if(l<o&&a<s){let e=i<=o&&i>=l?o-i:0;o-=e,d=o+(d-l),l=o}else if(d<o){let e=i<=o&&i>=d?o-i:0;o-=e,l=o+(l-d),d=o}return{start:o,endA:l,endB:d}}(f.content,h.doc.content,h.from,o,a);if(g&&e.input.domChangeCount++,(iG&&e.input.lastIOSEnter>Date.now()-225||iU)&&r.some(e=>1==e.nodeType&&!oW.test(e.nodeName))&&(!g||g.endA>=g.endB)&&e.someProp("handleKeyDown",t=>t(e,iR(13,"Enter")))){e.input.lastIOSEnter=0;return}if(!g)if(i&&c instanceof nO&&!c.empty&&c.$head.sameParent(c.$anchor)&&!e.composing&&!(h.sel&&h.sel.anchor!=h.sel.head))g={start:c.from,endA:c.to,endB:c.to};else{if(h.sel){let t=o$(e,e.state.doc,h.sel);if(t&&!t.eq(e.state.selection)){let n=e.state.tr.setSelection(t);l&&n.setMeta("composition",l),e.dispatch(n)}}return}e.state.selection.from<e.state.selection.to&&g.start==g.endB&&e.state.selection instanceof nO&&(g.start>e.state.selection.from&&g.start<=e.state.selection.from+2&&e.state.selection.from>=h.from?g.start=e.state.selection.from:g.endA<e.state.selection.to&&g.endA>=e.state.selection.to-2&&e.state.selection.to<=h.to&&(g.endB+=e.state.selection.to-g.endA,g.endA=e.state.selection.to)),iO&&iN<=11&&g.endB==g.start+1&&g.endA==g.start&&g.start>h.from&&" Â "==h.doc.textBetween(g.start-h.from-1,g.start-h.from+1)&&(g.start--,g.endA--,g.endB--);let m=h.doc.resolveNoCache(g.start-h.from),v=h.doc.resolveNoCache(g.endB-h.from),y=p.resolve(g.start),b=m.sameParent(v)&&m.parent.inlineContent&&y.end()>=g.endA;if((iG&&e.input.lastIOSEnter>Date.now()-225&&(!b||r.some(e=>"DIV"==e.nodeName||"P"==e.nodeName))||!b&&m.pos<h.doc.content.size&&(!m.sameParent(v)||!m.parent.inlineContent)&&m.pos<v.pos&&!/\S/.test(h.doc.textBetween(m.pos,v.pos,"","")))&&e.someProp("handleKeyDown",t=>t(e,iR(13,"Enter")))){e.input.lastIOSEnter=0;return}if(e.state.selection.anchor>g.start&&function(e,t,n,i,r){if(n-t<=r.pos-i.pos||oU(i,!0,!1)<r.pos)return!1;let o=e.resolve(t);if(!i.parent.isTextblock){let e=o.nodeAfter;return null!=e&&n==t+e.nodeSize}if(o.parentOffset<o.parent.content.size||!o.parent.isTextblock)return!1;let a=e.resolve(oU(o,!0,!0));return!(!a.parent.isTextblock||a.pos>n||oU(a,!0,!1)<n)&&i.parent.content.cut(i.parentOffset).eq(a.parent.content)}(p,g.start,g.endA,m,v)&&e.someProp("handleKeyDown",t=>t(e,iR(8,"Backspace")))){iU&&ij&&e.domObserver.suppressSelectionUpdates();return}ij&&g.endB==g.start&&(e.input.lastChromeDelete=Date.now()),iU&&!b&&m.start()!=v.start()&&0==v.parentOffset&&m.depth==v.depth&&h.sel&&h.sel.anchor==h.sel.head&&h.sel.head==g.endA&&(g.endB-=2,v=h.doc.resolveNoCache(g.endB-h.from),setTimeout(()=>{e.someProp("handleKeyDown",function(t){return t(e,iR(13,"Enter"))})},20));let x=g.start,w=g.endA,C=t=>{let n=t||e.state.tr.replace(x,w,h.doc.slice(g.start-h.from,g.endB-h.from));if(h.sel){let t=o$(e,n.doc,h.sel);
vendor: 4,599 bytes, line 230
230t&&!(ij&&e.composing&&t.empty&&(g.start!=g.endB||e.input.lastChromeDelete<Date.now()-100)&&(t.head==x||t.head==n.mapping.map(w)-1)||iO&&t.empty&&t.head==x)&&n.setSelection(t)}return l&&n.setMeta("composition",l),n.scrollIntoView()};if(b)if(m.pos==v.pos){iO&&iN<=11&&0==m.parentOffset&&(e.domObserver.suppressSelectionUpdates(),setTimeout(()=>rS(e),20));let t=C(e.state.tr.delete(x,w)),n=p.resolve(g.start).marksAcross(p.resolve(g.endA));n&&t.ensureMarks(n),e.dispatch(t)}else if(g.endA==g.endB&&(s=function(e,t){let n=e.firstChild.marks,i=t.firstChild.marks,r=n,o=i,a,s,l;for(let e=0;e<i.length;e++)r=i[e].removeFromSet(r);for(let e=0;e<n.length;e++)o=n[e].removeFromSet(o);if(1==r.length&&0==o.length)s=r[0],a="add",l=e=>e.mark(s.addToSet(e.marks));else{if(0!=r.length||1!=o.length)return null;s=o[0],a="remove",l=e=>e.mark(s.removeFromSet(e.marks))}let d=[];for(let e=0;e<t.childCount;e++)d.push(l(t.child(e)));if(tl.from(d).eq(e))return{mark:s,type:a}}(m.parent.content.cut(m.parentOffset,v.parentOffset),y.parent.content.cut(y.parentOffset,g.endA-y.start())))){let t=C(e.state.tr);"add"==s.type?t.addMark(x,w,s.mark):t.removeMark(x,w,s.mark),e.dispatch(t)}else if(m.parent.child(m.index()).isText&&m.index()==v.index()-!v.textOffset){let t=m.parent.textBetween(m.parentOffset,v.parentOffset),n=()=>C(e.state.tr.insertText(t,x,w));e.someProp("handleTextInput",i=>i(e,x,w,t,n))||e.dispatch(n())}else e.dispatch(C());else e.dispatch(C())})(this,e,t,n,i)),this.domObserver.start(),function(e){for(let t in r1){let n=r1[t];e.dom.addEventListener(t,e.input.eventHandlers[t]=t=>{!function(e,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let n=t.target;n!=e.dom;n=n.parentNode)if(!n||11==n.nodeType||n.pmViewDesc&&n.pmViewDesc.stopEvent(t))return!1;return!0}(e,t)||r8(e,t)||!e.editable&&t.type in r2||n(e,t)},r3[t]?{passive:!0}:void 0)}iH&&e.dom.addEventListener("input",()=>null),r6(e)}(this),this.updatePluginViews()}get composing(){return this.input.composing}get props(){if(this._props.state!=this.state){let e=this._props;for(let t in this._props={},e)this._props[t]=e[t];this._props.state=this.state}return this._props}update(e){e.handleDOMEvents!=this._props.handleDOMEvents&&r6(this);let t=this._props;this._props=e,e.plugins&&(e.plugins.forEach(oJ),this.directPlugins=e.plugins),this.updateStateInner(e.state,t)}setProps(e){let t={};for(let e in this._props)t[e]=this._props[e];for(let n in t.state=this.state,e)t[n]=e[n];this.update(t)}updateState(e){this.updateStateInner(e,this._props)}updateStateInner(e,t){var n,i,r;let o=this.state,a=!1,s=!1;e.storedMarks&&this.composing&&(ou(this),s=!0),this.state=e;let l=o.plugins!=e.plugins||this._props.plugins!=t.plugins;if(l||this._props.plugins!=t.plugins||this._props.nodeViews!=t.nodeViews){let e=oX(this);(function(e,t){let n=0,i=0;for(let i in e){if(e[i]!=t[i])return!0;n++}for(let e in t)i++;return n!=i})(e,this.nodeViews)&&(this.nodeViews=e,a=!0)}(l||t.handleDOMEvents!=this._props.handleDOMEvents)&&r6(this),this.editable=oZ(this),oY(this);let d=oF(this),u=oK(this),c=o.plugins==e.plugins||o.doc.eq(e.doc)?e.scrollToSelection>o.scrollToSelection?"to selection":"preserve":"reset",h=a||!this.docView.matchesNode(e.doc,u,d);(h||!e.selection.eq(o.selection))&&(s=!0);let p="preserve"==c&&s&&null==this.dom.style.overflowAnchor&&function(e){let t,n,i=e.dom.getBoundingClientRect(),r=Math.max(0,i.top);for(let o=(i.left+i.right)/2,a=r+1;a<Math.min(innerHeight,i.bottom);a+=5){let i=e.root.elementFromPoint(o,a);if(!i||i==e.dom||!e.dom.contains(i))continue;let s=i.getBoundingClientRect();if(s.top>=r-20){t=i,n=s.top;break}}return{refDOM:t,refTop:n,stack:iX(e.dom)}}(this);if(s){let t,n,s;this.domObserver.stop();let l=h&&(iO||ij)&&!this.composing&&!o.selection.empty&&!e.selection.empty&&(i=o.selection,r=e.selection,s=Math.min(i.$anchor.sharedDepth(i.head),r.$anchor.sharedDepth(r.head)),i.$anchor.start(s)!=r.$anchor.start(s));if(h){let t=ij?this.trackWrites=this.domSelectionRange().focusNode:null;this.composing&&(this.input.compositionNode=function(e){let t=e.domSelectionRange();if(!t.focusNode)return null;let n=function(e,t){for(;;){if(3==e.nodeType&&t)return e;if(1==e.nodeType&&t>0){if("false"==e.contentEditable)return null;t=iM(e=e.childNodes[t-1])}else{if(!e.parentNode||iT(e))return null;t=iy(e),e=e.parentNode}}}(t.focusNode,t.focusOffset),i=function(e,t){for(;;){if(3==e.nodeType&&t<e.nodeValue.length)return e;if(1==e.nodeType&&t<e.childNodes.length){if("false"==e.contentEditable)return null;e=e.childNodes[t],t=0}else{if(!e.parentNode||iT(e))return null;t=iy(e)+1,e=e.parentNode}}}(t.focusNode,t.focusOffset);
230if(n&&i&&n!=i){let t=i.pmViewDesc,r=e.domObserver.lastChangedTextNode;if(n==r||i==r)return r;if(!t||!t.isText(i.nodeValue))return i;if(e.input.compositionNode==i){let e=n.pmViewDesc;if(!(!e||!e.isText(n.nodeValue)))return i}}return n||i}(this)),(a||!this.docView.update(e.doc,u,d,this))&&(this.docView.updateOuterDeco(u),this.docView.destroy(),this.docView=rs(e.doc,u,d,this.dom,this)),!t||this.trackWrites&&this.dom.contains(this.trackWrites)||(l=!0)}let c=this.input.mouseDown;l||!(c&&this.domObserver.currentSelection.eq(this.domSelectionRange())&&(t=this.docView.domFromPos(this.state.selection.anchor,0),n=this.domSelectionRange(),iS(t.node,t.offset,n.anchorNode,n.anchorOffset))&&c.delaySelUpdate())?rS(this,l):(rD(this,e.selection),this.domObserver.setCurSelection()),this.domObserver.start()}this.updatePluginViews(o),(null==(n=this.dragging)?void 0:n.node)&&!o.doc.eq(e.doc)&&this.updateDraggedNode(this.dragging,o),"reset"==c?this.dom.scrollTop=0:"to selection"==c?this.scrollToSelection():p&&function({refDOM:e,refTop:t,stack:n}){let i=e?e.getBoundingClientRect().top:0;iJ(n,0==i?0:i-t)}(p)}scrollToSelection(){let e=this.domSelectionRange().focusNode;if(e&&this.dom.contains(1==e.nodeType?e:e.parentNode))if(this.someProp("handleScrollToSelection",e=>e(this)));else if(this.state.selection instanceof nB){let t=this.docView.domAfterPos(this.state.selection.from);1==t.nodeType&&iZ(this,t.getBoundingClientRect(),e)}else iZ(this,this.coordsAtPos(this.state.selection.head,1),e)}destroyPluginViews(){let e;for(;e=this.pluginViews.pop();)e.destroy&&e.destroy()}updatePluginViews(e){if(e&&e.plugins==this.state.plugins&&this.directPlugins==this.prevDirectPlugins)for(let t=0;t<this.pluginViews.length;t++){let n=this.pluginViews[t];n.update&&n.update(this,e)}else{this.prevDirectPlugins=this.directPlugins,this.destroyPluginViews();for(let e=0;e<this.directPlugins.length;e++){let t=this.directPlugins[e];t.spec.view&&this.pluginViews.push(t.spec.view(this))}for(let e=0;e<this.state.plugins.length;e++){let t=this.state.plugins[e];t.spec.view&&this.pluginViews.push(t.spec.view(this))}}}updateDraggedNode(e,t){let n=e.node,i=-1;if(n.from<this.state.doc.content.size&&this.state.doc.nodeAt(n.from)==n.node)i=n.from;else{let e=n.from+(this.state.doc.content.size-t.doc.content.size);(e>0&&e<this.state.doc.content.size&&this.state.doc.nodeAt(e))==n.node&&(i=e)}this.dragging=new og(e.slice,e.move,i<0?void 0:nB.create(this.state.doc,i))}someProp(e,t){let n=this._props&&this._props[e],i;if(null!=n&&(i=t?t(n):n))return i;for(let n=0;n<this.directPlugins.length;n++){let r=this.directPlugins[n].props[e];if(null!=r&&(i=t?t(r):r))return i}let r=this.state.plugins;if(r)for(let n=0;n<r.length;n++){let o=r[n].props[e];if(null!=o&&(i=t?t(o):o))return i}}hasFocus(){if(iO){let e=this.root.activeElement;if(e==this.dom)return!0;if(!e||!this.dom.contains(e))return!1;for(;e&&this.dom!=e&&this.dom.contains(e);){if("false"==e.contentEditable)return!1;e=e.parentElement}return!0}return this.root.activeElement==this.dom}focus(){this.domObserver.stop(),this.editable&&function(e){if(e.setActive)return e.setActive();if(iQ)return e.focus(iQ);let t=iX(e);e.focus(null==iQ?{get preventScroll(){return iQ={preventScroll:!0},!0}}:void 0),iQ||(iQ=!1,iJ(t,0))}(this.dom),rS(this),this.domObserver.start()}get root(){let e=this._root;if(null==e){for(let e=this.dom.parentNode;e;e=e.parentNode)if(9==e.nodeType||11==e.nodeType&&e.host)return e.getSelection||(Object.getPrototypeOf(e).getSelection=()=>e.ownerDocument.getSelection()),this._root=e}return e||document}updateRoot(){this._root=null}posAtCoords(e){return function(e,t){var n;let i,r,o=e.dom.ownerDocument,a,s=0,l=function(e,t,n){if(e.caretPositionFromPoint)try{let i=e.caretPositionFromPoint(t,n);if(i)return{node:i.offsetNode,offset:Math.min(iM(i.offsetNode),i.offset)}}catch(e){}if(e.caretRangeFromPoint){let i=e.caretRangeFromPoint(t,n);if(i)return{node:i.startContainer,offset:Math.min(iM(i.startContainer),i.startOffset)}}}(o,t.left,t.top);l&&({node:a,offset:s}=l);let d=(e.root.elementFromPoint?e.root:o).elementFromPoint(t.left,t.top);if(!d||!e.dom.contains(1!=d.nodeType?d.parentNode:d)){let n=e.dom.getBoundingClientRect();if(!i0(t,n)||!(d=function e(t,n,i){let r=t.childNodes.length;if(r&&i.top<i.bottom)for(let o=Math.max(0,Math.min(r-1,Math.floor(r*(n.top-i.top)/(i.bottom-i.top))-2)),a=o;;){let i=t.childNodes[a];if(1==i.nodeType){let t=i.getClientRects();for(let r=0;r<t.length;r++){let o=t[r];if(i0(n,o))return e(i,n,o)}}if((a=(a+1)%r)==o)break}return t}(e.dom,t,n)))return null}if(iH)for(let e=d;a&&e;e=ib(e))e.draggable&&(a=void 0);if(d=(i=(n=d).parentNode)&&/^li$/i.test(i.nodeName)&&t.left<n.getBoundingClientRect().left?i:n,a){let n;if(iB&&1==a.nodeType&&(s=Math.min(s,a.childNodes.length))<a.childNodes.length){let e=a.childNodes[s],n;"IMG"==e.nodeName&&(n=e.getBoundingClientRect()).right<=t.left&&n.bottom>t.top&&s++}iq&&s&&1==a.nodeType&&1==(n=a.childNodes[s-1]).nodeType&&"false"==n.contentEditable&&n.getBoundingClientRect().top>=t.top&&s--,a==e.dom&&s==a.childNodes.length-1&&1==a.lastChild.nodeType&&t.top>
230a.lastChild.getBoundingClientRect().bottom?r=e.state.doc.content.size:(0==s||1!=a.nodeType||"BR"!=a.childNodes[s-1].nodeName)&&(r=function(e,t,n,i){let r=-1;for(let n=t,o=!1;n!=e.dom;){let t=e.docView.nearestDesc(n,!0),a;if(!t)return null;if(1==t.dom.nodeType&&(t.node.isBlock&&t.parent||!t.contentDOM)&&((a=t.dom.getBoundingClientRect()).width||a.height)&&(t.node.isBlock&&t.parent&&!/^T(R|BODY|HEAD|FOOT)$/.test(t.dom.nodeName)&&(!o&&a.left>i.left||a.top>i.top?r=t.posBefore:(!o&&a.right<i.left||a.bottom<i.top)&&(r=t.posAfter),o=!0),!t.contentDOM&&r<0&&!t.node.isText))return(t.node.isBlock?i.top<(a.top+a.bottom)/2:i.left<(a.left+a.right)/2)?t.posBefore:t.posAfter;n=t.dom.parentNode}return r>-1?r:e.docView.posFromDOM(t,n,-1)}(e,a,s,t))}null==r&&(r=function(e,t,n){let{node:i,offset:r}=function e(t,n){let i,r,o,a=2e8,s,l=0,d=n.top,u=n.top;for(let e=t.firstChild,c=0;e;e=e.nextSibling,c++){let t;if(1==e.nodeType)t=e.getClientRects();else{if(3!=e.nodeType)continue;t=iw(e).getClientRects()}for(let h=0;h<t.length;h++){let p=t[h];if(p.top<=d&&p.bottom>=u){d=Math.max(p.bottom,d),u=Math.min(p.top,u);let t=p.left>n.left?p.left-n.left:p.right<n.left?n.left-p.right:0;if(t<a){o=e,a=t,s=t&&3==o.nodeType?{left:p.right<n.left?p.right:p.left,top:n.top}:n,1==e.nodeType&&t&&(l=c+ +(n.left>=(p.left+p.right)/2));continue}}else p.top>n.top&&!i&&p.left<=n.left&&p.right>=n.left&&(i=e,r={left:Math.max(p.left,Math.min(p.right,n.left)),top:p.top});!o&&(n.left>=p.right&&n.top>=p.top||n.left>=p.left&&n.top>=p.bottom)&&(l=c+1)}}return(!o&&i&&(o=i,s=r,a=0),o&&3==o.nodeType)?function(e,t){let n=e.nodeValue.length,i=document.createRange(),r;for(let o=0;o<n;o++){i.setEnd(e,o+1),i.setStart(e,o);let n=i2(i,1);if(n.top!=n.bottom&&i0(t,n)){r={node:e,offset:o+ +(t.left>=(n.left+n.right)/2)};break}}return i.detach(),r||{node:e,offset:0}}(o,s):!o||a&&1==o.nodeType?{node:t,offset:l}:e(o,s)}(t,n),o=-1;if(1==i.nodeType&&!i.firstChild){let e=i.getBoundingClientRect();o=e.left!=e.right&&n.left>(e.left+e.right)/2?1:-1}return e.docView.posFromDOM(i,r,o)}(e,d,t));let u=e.docView.nearestDesc(d,!0);return{pos:r,inside:u?u.posAtStart-u.border:-1}}(this,e)}coordsAtPos(e,t=1){return i5(this,e,t)}domAtPos(e,t=0){return this.docView.domFromPos(e,t)}nodeDOM(e){let t=this.docView.descAt(e);return t?t.nodeDOM:null}posAtDOM(e,t,n=-1){let i=this.docView.posFromDOM(e,t,n);if(null==i)throw RangeError("DOM position not inside the editor");return i}endOfTextblock(e,t){return function(e,t,n){let i,r;return i9==t&&re==n?rt:(i9=t,re=n,rt="up"==n||"down"==n?(i=t.selection,r="up"==n?i.$from:i.$to,i8(e,t,()=>{let{node:t}=e.docView.domFromPos(r.pos,"up"==n?-1:1);for(;;){let n=e.docView.nearestDesc(t,!0);if(!n)break;if(n.node.isBlock){t=n.contentDOM||n.dom;break}t=n.dom.parentNode}let i=i5(e,r.pos,1);for(let e=t.firstChild;e;e=e.nextSibling){let t;if(1==e.nodeType)t=e.getClientRects();else{if(3!=e.nodeType)continue;t=iw(e,0,e.nodeValue.length).getClientRects()}for(let e=0;e<t.length;e++){let r=t[e];if(r.bottom>r.top+1&&("up"==n?i.top-r.top>(r.bottom-i.top)*2:r.bottom-i.bottom>(i.bottom-r.top)*2))return!1}}return!0})):function(e,t,n){let{$head:i}=t.selection;if(!i.parent.isTextblock)return!1;let r=i.parentOffset,o=r==i.parent.content.size,a=e.domSelection();return a?i7.test(i.parent.textContent)&&a.modify?i8(e,t,()=>{let{focusNode:t,focusOffset:r,anchorNode:o,anchorOffset:s}=e.domSelectionRange(),l=a.caretBidiLevel;a.modify("move",n,"character");let d=i.depth?e.docView.domAfterPos(i.before()):e.dom,{focusNode:u,focusOffset:c}=e.domSelectionRange(),h=u&&!d.contains(1==u.nodeType?u:u.parentNode)||t==u&&r==c;try{a.collapse(o,s),t&&(t!=o||r!=s)&&a.extend&&a.extend(t,r)}catch(e){}return null!=l&&(a.caretBidiLevel=l),h}):"left"==n||"backward"==n?!r:o:i.pos==i.start()||i.pos==i.end()}(e,t,n))}(this,t||this.state,e)}pasteHTML(e,t){return op(this,"",e,!1,t||new ClipboardEvent("paste"))}pasteText(e,t){return op(this,e,null,!0,t||new ClipboardEvent("paste"))}serializeForClipboard(e){return r$(this,e)}destroy(){if(this.docView){for(let e in this.input.mouseDown&&this.input.mouseDown.done(),this.domObserver.stop(),this.input.eventHandlers)this.dom.removeEventListener(e,this.input.eventHandlers[e]);clearTimeout(this.input.composingTimeout),clearTimeout(this.input.lastIOSEnterFallbackTimeout),this.destroyPluginViews(),this.mounted?(this.docView.update(this.state.doc,[],oF(this),this),this.dom.textContent=""):this.dom.parentNode&&this.dom.parentNode.removeChild(this.dom),this.docView.destroy(),this.docView=null,iC()}}get isDestroyed(){return null==this.docView}dispatchEvent(e){!r8(this,e)&&r1[e.type]&&(this.editable||!(e.type in r2))&&r1[e.type](this,e)}domSelectionRange(){let e=this.domSelection();return e?iH&&11===this.root.nodeType&&function(e){let t=e.activeElement;for(;t&&t.shadowRoot;)t=t.shadowRoot.activeElement;return t}(this.dom.ownerDocument)==this.dom&&function(e,t){let n;if(t.getComposedRanges){let n=t.getComposedRanges(e.root)[0];if(n)return oH(e,n)}function i(e){e.preventDefault(),e.stopImmediatePropagation(),n=e.getTargetRanges()[0]}return e.dom.addEventListener("beforeinput",i,!0),document.execCommand("indent"),e.dom.removeEventListener("beforeinput",i,!0),n?oH(e,n):null}
230(this,e)||e:{focusNode:null,focusOffset:0,anchorNode:null,anchorOffset:0}}domSelection(){return this.root.getSelection()}}function oK(e){let t=Object.create(null);return t.class="ProseMirror",t.contenteditable=String(e.editable),e.someProp("attributes",n=>{if("function"==typeof n&&(n=n(e.state)),n)for(let e in n)"class"==e?t.class+=" "+n[e]:"style"==e?t.style=(t.style?t.style+";":"")+n[e]:t[e]||"contenteditable"==e||"nodeName"==e||(t[e]=String(n[e]))}),t.translate||(t.translate="no"),[oC.node(0,e.state.doc.content.size,t)]}function oY(e){if(e.markCursor){let t=document.createElement("img");t.className="ProseMirror-separator",t.setAttribute("mark-placeholder","true"),t.setAttribute("alt",""),e.cursorWrapper={dom:t,deco:oC.widget(e.state.selection.from,t,{raw:!0,marks:e.markCursor})}}else e.cursorWrapper=null}function oZ(e){return!e.someProp("editable",t=>!1===t(e.state))}function oX(e){let t=Object.create(null);function n(e){for(let n in e)Object.prototype.hasOwnProperty.call(t,n)||(t[n]=e[n])}return e.someProp("nodeViews",n),e.someProp("markViews",n),t}function oJ(e){if(e.spec.state||e.spec.filterTransaction||e.spec.appendTransaction)throw RangeError("Plugins passed directly to the view must not have a state component")}oq.prototype.dispatch=function(e){let t=this._props.dispatchTransaction;t?t.call(this,e):this.updateState(this.state.apply(e))};for(var oQ={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},o0={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},o1="u">typeof navigator&&/Mac/.test(navigator.platform),o2="u">typeof navigator&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),o3=0;o3<10;o3++)oQ[48+o3]=oQ[96+o3]=String(o3);for(var o3=1;o3<=24;o3++)oQ[o3+111]="F"+o3;for(var o3=65;o3<=90;o3++)oQ[o3]=String.fromCharCode(o3+32),o0[o3]=String.fromCharCode(o3);for(var o5 in oQ)o0.hasOwnProperty(o5)||(o0[o5]=oQ[o5]);let o4="u">typeof navigator&&/Mac|iP(hone|[oa]d)/.test(navigator.platform),o6="u">typeof navigator&&/Win/.test(navigator.platform);function o8(e,t,n=!0){return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),n&&t.shiftKey&&(e="Shift-"+e),e}function o7(e){let t=function(e){let t=Object.create(null);for(let n in e)t[function(e){let t,n,i,r,o=e.split(/-(?!$)/),a=o[o.length-1];"Space"==a&&(a=" ");for(let e=0;e<o.length-1;e++){let a=o[e];if(/^(cmd|meta|m)$/i.test(a))r=!0;else if(/^a(lt)?$/i.test(a))t=!0;else if(/^(c|ctrl|control)$/i.test(a))n=!0;else if(/^s(hift)?$/i.test(a))i=!0;else if(/^mod$/i.test(a))o4?r=!0:n=!0;else throw Error("Unrecognized modifier name: "+a)}return t&&(a="Alt-"+a),n&&(a="Ctrl-"+a),r&&(a="Meta-"+a),i&&(a="Shift-"+a),a}(n)]=e[n];return t}(e);return function(e,n){var i;let r=("Esc"==(i=!(o1&&n.metaKey&&n.shiftKey&&!n.ctrlKey&&!n.altKey||o2&&n.shiftKey&&n.key&&1==n.key.length||"Unidentified"==n.key)&&n.key||(n.shiftKey?o0:oQ)[n.keyCode]||n.key||"Unidentified")&&(i="Escape"),"Del"==i&&(i="Delete"),"Left"==i&&(i="ArrowLeft"),"Up"==i&&(i="ArrowUp"),"Right"==i&&(i="ArrowRight"),"Down"==i&&(i="ArrowDown"),i),o,a=t[o8(r,n)];if(a&&a(e.state,e.dispatch,e))return!0;if(1==r.length&&" "!=r){if(n.shiftKey){let i=t[o8(r,n,!1)];if(i&&i(e.state,e.dispatch,e))return!0}if((n.altKey||n.metaKey||n.ctrlKey)&&!(o6&&n.ctrlKey&&n.altKey)&&(o=oQ[n.keyCode])&&o!=r){let i=t[o8(o,n)];if(i&&i(e.state,e.dispatch,e))return!0}}return!1}}var o9=Object.defineProperty,ae=(e,t)=>{for(var n in t)o9(e,n,{get:t[n],enumerable:!0})};function at(e){let{state:t,transaction:n}=e,{selection:i}=n,{doc:r}=n,{storedMarks:o}=n;return{...t,apply:t.apply.bind(t),applyTransaction:t.applyTransaction.bind(t),plugins:t.plugins,schema:t.schema,reconfigure:t.reconfigure.bind(t),toJSON:t.toJSON.bind(t),get storedMarks(){return o},get selection(){return i},get doc(){return r},get tr(){return i=n.selection,r=n.doc,o=n.storedMarks,n}}}var an=class{constructor(e){this.editor=e.editor,this.rawCommands=this.editor.extensionManager.commands,this.customState=e.state}get hasCustomState(){return!!this.customState}get state(){return this.customState||this.editor.state}get commands(){let{rawCommands:e,editor:t,state:n}=this,{view:i}=t,{tr:r}=n,o=this.buildProps(r);return Object.fromEntries(Object.entries(e).map(([e,t])=>[e,(...e)=>{let n=t(...e)(o);return r.getMeta("preventDispatch")||this.hasCustomState||i.dispatch(r),n}
230]))}get chain(){return()=>this.createChain()}get can(){return()=>this.createCan()}createChain(e,t=!0){let{rawCommands:n,editor:i,state:r}=this,{view:o}=i,a=[],s=!!e,l=e||r.tr,d=()=>(s||!t||l.getMeta("preventDispatch")||this.hasCustomState||o.dispatch(l),a.every(e=>!0===e)),u={...Object.fromEntries(Object.entries(n).map(([e,n])=>[e,(...e)=>{let i=this.buildProps(l,t),r=n(...e)(i);return a.push(r),u}])),run:d};return u}createCan(e){let{rawCommands:t,state:n}=this,i=e||n.tr,r=this.buildProps(i,!1);return{...Object.fromEntries(Object.entries(t).map(([e,t])=>[e,(...e)=>t(...e)({...r,dispatch:void 0})])),chain:()=>this.createChain(i,!1)}}buildProps(e,t=!0){let{rawCommands:n,editor:i,state:r}=this,{view:o}=i,a={tr:e,editor:i,view:o,state:at({state:r,transaction:e}),dispatch:t?()=>void 0:void 0,chain:()=>this.createChain(e,t),can:()=>this.createCan(e),get commands(){return Object.fromEntries(Object.entries(n).map(([e,t])=>[e,(...e)=>t(...e)(a)]))}};return a}},ai={};ae(ai,{blur:()=>ar,clearContent:()=>ao,clearNodes:()=>aa,command:()=>as,createParagraphNear:()=>al,cut:()=>ad,deleteCurrentNode:()=>au,deleteNode:()=>ah,deleteRange:()=>ap,deleteSelection:()=>ag,enter:()=>am,exitCode:()=>av,extendMarkRange:()=>a_,first:()=>ak,focus:()=>aA,forEach:()=>aP,insertContent:()=>aE,insertContentAt:()=>aN,joinBackward:()=>aj,joinDown:()=>az,joinForward:()=>aV,joinItemBackward:()=>aH,joinItemForward:()=>aG,joinTextblockBackward:()=>aW,joinTextblockForward:()=>a$,joinUp:()=>aB,keyboardShortcut:()=>aq,lift:()=>aY,liftEmptyBlock:()=>aZ,liftListItem:()=>aX,newlineInCode:()=>aJ,resetAttributes:()=>a1,scrollIntoView:()=>a2,selectAll:()=>a3,selectNodeBackward:()=>a5,selectNodeForward:()=>a4,selectParentNode:()=>a6,selectTextblockEnd:()=>a8,selectTextblockStart:()=>a7,setContent:()=>se,setMark:()=>sL,setMeta:()=>sF,setNode:()=>sO,setNodeSelection:()=>sN,setTextDirection:()=>sB,setTextSelection:()=>sz,sinkListItem:()=>sj,splitBlock:()=>sH,splitListItem:()=>sG,toggleList:()=>sq,toggleMark:()=>sK,toggleNode:()=>sY,toggleWrap:()=>sZ,undoInputRule:()=>sX,unsetAllMarks:()=>sJ,unsetMark:()=>sQ,unsetTextDirection:()=>s0,updateAttributes:()=>s1,wrapIn:()=>s2,wrapInList:()=>s3});var ar=()=>({editor:e,view:t})=>(requestAnimationFrame(()=>{var n;e.isDestroyed||(t.dom.blur(),null==(n=null==window?void 0:window.getSelection())||n.removeAllRanges())}),!0),ao=(e=!0)=>({commands:t})=>t.setContent("",{emitUpdate:e}),aa=()=>({state:e,tr:t,dispatch:n})=>{let{selection:i}=t,{ranges:r}=i;return!n||(r.forEach(({$from:n,$to:i})=>{e.doc.nodesBetween(n.pos,i.pos,(e,n)=>{if(e.type.isText)return;let{doc:i,mapping:r}=t,o=i.resolve(r.map(n)),a=i.resolve(r.map(n+e.nodeSize)),s=o.blockRange(a);if(!s)return;let l=nd(s);if(e.type.isTextblock){let{defaultType:e}=o.parent.contentMatchAt(o.index());t.setNodeMarkup(s.start,e)}(l||0===l)&&t.lift(s,l)})}),!0)},as=e=>t=>e(t),al=()=>({state:e,dispatch:t})=>io(e,t),ad=(e,t)=>({editor:n,tr:i})=>{let{state:r}=n,o=r.doc.slice(e.from,e.to);i.deleteRange(e.from,e.to);let a=i.mapping.map(t);return i.insert(a,o.content),i.setSelection(new nO(i.doc.resolve(Math.max(a-1,0)))),!0},au=()=>({tr:e,dispatch:t})=>{let{selection:n}=e,i=n.$anchor.node();if(i.content.size>0)return!1;let r=e.selection.$anchor;for(let n=r.depth;n>0;n-=1)if(r.node(n).type===i.type){if(t){let t=r.before(n),i=r.after(n);e.delete(t,i).scrollIntoView()}return!0}return!1};function ac(e,t){if("string"==typeof e){if(!t.nodes[e])throw Error(`There is no node type named '${e}'. Maybe you forgot to add the extension?`);return t.nodes[e]}return e}var ah=e=>({tr:t,state:n,dispatch:i})=>{let r=ac(e,n.schema),o=t.selection.$anchor;for(let e=o.depth;e>0;e-=1)if(o.node(e).type===r){if(i){let n=o.before(e),i=o.after(e);t.delete(n,i).scrollIntoView()}return!0}return!1},ap=e=>({tr:t,dispatch:n})=>{let{from:i,to:r}=e;return n&&t.delete(i,r),!0},af=(e,t,n)=>{var i;return!e.parent.isInline||"left"===n&&e.pos>e.start()||"right"===n&&e.pos<e.end()?e.pos:(i=t.nodes[e.parent.type.name].spec).content&&/^text(\*|\+)/.test(i.content)?"left"===n?e.start()-1:e.end()+1:e.pos},ag=()=>({state:e,dispatch:t})=>{var n;let{$from:i,$to:r}=e.selection;if(e.selection.empty)return!1;let{from:o,to:a}
230={from:af(i,n=e.schema,"left"),to:af(r,n,"right")};return t&&(e.tr.deleteRange(o,a).scrollIntoView(),t(e.tr)),!0},am=()=>({commands:e})=>e.keyboardShortcut("Enter"),av=()=>({state:e,dispatch:t})=>ir(e,t);function ay(e){return"[object RegExp]"===Object.prototype.toString.call(e)}function ab(e,t,n={strict:!0}){let i=Object.keys(t);return!i.length||i.every(i=>n.strict?t[i]===e[i]:ay(t[i])?t[i].test(e[i]):t[i]===e[i])}function ax(e,t,n={}){return e.find(e=>e.type===t&&ab(Object.fromEntries(Object.keys(n).map(t=>[t,e.attrs[t]])),n))}function aw(e,t,n={}){return!!ax(e,t,n)}function aC(e,t,n){if(!e||!t)return;let i=e.parent.childAfter(e.parentOffset);if(i.node&&i.node.marks.some(e=>e.type===t)||(i=e.parent.childBefore(e.parentOffset)),!i.node||!i.node.marks.some(e=>e.type===t))return;if(!n){let e=i.node.marks.find(e=>e.type===t);e&&(n=e.attrs)}if(!ax([...i.node.marks],t,n))return;let r=i.index,o=e.start()+i.offset,a=r+1,s=o+i.node.nodeSize;for(;r>0&&aw([...e.parent.child(r-1).marks],t,n);)r-=1,o-=e.parent.child(r).nodeSize;for(;a<e.parent.childCount&&aw([...e.parent.child(a).marks],t,n);)s+=e.parent.child(a).nodeSize,a+=1;return{from:o,to:s}}function aS(e,t){if("string"==typeof e){if(!t.marks[e])throw Error(`There is no mark type named '${e}'. Maybe you forgot to add the extension?`);return t.marks[e]}return e}var a_=(e,t)=>({tr:n,state:i,dispatch:r})=>{let o=aS(e,i.schema),{doc:a,selection:s}=n,{$from:l,from:d,to:u}=s;if(r){let e=aC(l,o,t);if(e&&e.from<=d&&e.to>=u){let t=nO.create(a,e.from,e.to);n.setSelection(t)}}return!0},ak=e=>t=>{let n="function"==typeof e?e(t):e;for(let e=0;e<n.length;e+=1)if(n[e](t))return!0;return!1};function aM(e){return e instanceof nO}function aT(e=0,t=0,n=0){return Math.min(Math.max(e,t),n)}function aD(e,t=null){if(!t)return null;let n=nP.atStart(e),i=nP.atEnd(e);if("start"===t||!0===t)return n;if("end"===t)return i;let r=n.from,o=i.to;return"all"===t?nO.create(e,aT(0,r,o),aT(e.content.size,r,o)):nO.create(e,aT(t,r,o),aT(t,r,o))}function aR(){return"Android"===navigator.platform||/android/i.test(navigator.userAgent)}function aI(){return["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document}var aA=(e=null,t={})=>({editor:n,view:i,tr:r,dispatch:o})=>{t={scrollIntoView:!0,...t};let a=()=>{(aI()||aR())&&i.dom.focus(),"u">typeof navigator&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent)&&!aI()&&!aR()&&i.dom.focus({preventScroll:!0}),requestAnimationFrame(()=>{!n.isDestroyed&&(i.focus(),(null==t?void 0:t.scrollIntoView)&&n.commands.scrollIntoView())})};try{if(i.hasFocus()&&null===e||!1===e)return!0}catch{return!1}if(o&&null===e&&!aM(n.state.selection))return a(),!0;let s=aD(r.doc,e)||n.state.selection,l=n.state.selection.eq(s);return o&&(l||r.setSelection(s),l&&r.storedMarks&&r.setStoredMarks(r.storedMarks),a()),!0},aP=(e,t)=>
230n=>e.every((e,i)=>t(e,{...n,index:i})),aE=(e,t)=>({tr:n,commands:i})=>i.insertContentAt({from:n.selection.from,to:n.selection.to},e,t),aL=e=>{let t=e.childNodes;for(let n=t.length-1;n>=0;n-=1){let i=t[n];3===i.nodeType&&i.nodeValue&&/^(\n\s\s|\n)$/.test(i.nodeValue)?e.removeChild(i):1===i.nodeType&&aL(i)}return e};function aF(e){if("u"<typeof window)throw Error("[tiptap error]: there is no window object available, so this function cannot be used");let t=`<body>${e}</body>`;return aL(new window.DOMParser().parseFromString(t,"text/html").body)}function aO(e,t,n){if(e instanceof tT||e instanceof tl)return e;n={slice:!0,parseOptions:{},...n};let i="object"==typeof e&&null!==e,r="string"==typeof e;if(i)try{if(Array.isArray(e)&&e.length>0)return tl.fromArray(e.map(e=>t.nodeFromJSON(e)));let i=t.nodeFromJSON(e);return n.errorOnInvalidContent&&i.check(),i}catch(i){if(n.errorOnInvalidContent)throw Error("[tiptap error]: Invalid JSON content",{cause:i});return console.warn("[tiptap warn]: Invalid content.","Passed value:",e,"Error:",i),aO("",t,n)}if(r){if(n.errorOnInvalidContent){let i=!1,r="",o=new tH({topNode:t.spec.topNode,marks:t.spec.marks,nodes:t.spec.nodes.append({__tiptap__private__unknown__catch__all__node:{content:"inline*",group:"block",parseDOM:[{tag:"*",getAttrs:e=>(i=!0,r="string"==typeof e?e:e.outerHTML,null)}]}})});if(n.slice?tW.fromSchema(o).parseSlice(aF(e),n.parseOptions):tW.fromSchema(o).parse(aF(e),n.parseOptions),n.errorOnInvalidContent&&i)throw Error("[tiptap error]: Invalid HTML content",{cause:Error(`Invalid element found: ${r}`)})}let i=tW.fromSchema(t);return n.slice?i.parseSlice(aF(e),n.parseOptions).content:i.parse(aF(e),n.parseOptions)}return aO("",t,n)}var aN=(e,t,n)=>({tr:i,dispatch:r,editor:o})=>{var a;if(r){let r,s;n={parseOptions:o.options.parseOptions,updateSelection:!0,applyInputRules:!1,applyPasteRules:!1,...n};let l=e=>{o.emit("contentError",{editor:o,error:e,disableCollaboration:()=>{"collaboration"in o.storage&&"object"==typeof o.storage.collaboration&&o.storage.collaboration&&(o.storage.collaboration.isDisabled=!0)}})},d={preserveWhitespace:"full",...n.parseOptions};if(!n.errorOnInvalidContent&&!o.options.enableContentCheck&&o.options.emitContentError)try{aO(t,o.schema,{parseOptions:d,errorOnInvalidContent:!0})}catch(e){l(e)}try{r=aO(t,o.schema,{parseOptions:d,errorOnInvalidContent:null!=(a=n.errorOnInvalidContent)?a:o.options.enableContentCheck})}catch(e){return l(e),!1}let{from:u,to:c}="number"==typeof e?{from:e,to:e}:{from:e.from,to:e.to},h=!0,p=!0;if((!("type"in r)?r:[r]).forEach(e=>{e.check(),h=!!h&&e.isText&&0===e.marks.length,p=!!p&&e.isBlock}),u===c&&p){let{parent:e}=i.doc.resolve(u);!e.isTextblock||e.type.spec.code||e.childCount||(u-=1,c+=1)}if(h){if(Array.isArray(t))s=t.map(e=>e.text||"").join("");else if(t instanceof tl){let e="";t.forEach(t=>{t.text&&(e+=t.text)}),s=e}else s="object"==typeof t&&t&&t.text?t.text:t;i.insertText(s,u,c)}else{s=r;let e=i.doc.resolve(u),t=e.node(),n=0===e.parentOffset,o=t.isText||t.isTextblock,a=t.content.size>0;n&&o&&a&&p&&(u=Math.max(0,u-1)),i.replaceWith(u,c,s)}n.updateSelection&&function(e,t,n){let i=e.steps.length-1;if(i<t)return;let r=e.steps[i];if(!(r instanceof no||r instanceof na))return;let o=e.mapping.maps[i],a=0;o.forEach((e,t,n,i)=>{0===a&&(a=i)}),e.setSelection(nP.near(e.doc.resolve(a),-1))}(i,i.steps.length-1,0),n.applyInputRules&&i.setMeta("applyInputRules",{from:u,text:s}),n.applyPasteRules&&i.setMeta("applyPasteRules",{from:u,text:s})}return!0},aB=()=>({state:e,dispatch:t})=>((e,t)=>{let n=e.selection,i=n instanceof nB,r;if(i){if(n.node.isTextblock||!ng(e.doc,n.from))return!1;r=n.from}else if(null==(r=nv(e.doc,n.from,-1)))return!1;if(t){let n=e.tr.join(r);i&&n.setSelection(nB.create(n.doc,r-e.doc.resolve(r).nodeBefore.nodeSize)),t(n.scrollIntoView())}return!0})(e,t),az=()=>({state:e,dispatch:t})=>((e,t)=>{let n=e.selection,i;if(n instanceof nB){if(n.node.isTextblock||!ng(e.doc,n.to))return!1;i=n.to}else if(null==(i=nv(e.doc,n.to,1)))return!1;return t&&t(e.tr.join(i).scrollIntoView()),!0})(e,t),aj=()=>({state:e,dispatch:t})=>n2(e,t),aV=()=>({state:e,dispatch:t})=>n7(e,t),aH=()=>({state:e,dispatch:t,tr:n})=>{try{let i=nv(e.doc,e.selection.$from.pos,-1);if(null==i)return!1;return n.join(i,2),t&&t(n),!0}catch{return!1}},aG=()=>({state:e,dispatch:t,tr:n})=>{try{let i=nv(e.doc,e.selection.$from.pos,1);if(null==i)return!1;return n.join(i,2),t&&t(n),!0}catch{return!1}},aW=()=>({state:e,dispatch:t})=>((e,t,n)=>{let i=n1(e,n);if(!i)return!1;let r=n6(i);return!!r&&n3(e,r,t)})(e,t),a$=()=>({state:e,dispatch:t})=>((e,t,n)=>{let i=n8(e,n);if(!i)return!1;let r=ie(i);return!!r&&n3(e,r,t)})(e,t);function aU(){return"u">typeof navigator&&/Mac/.test(navigator.platform)}var aq=e=>({editor:t,view:n,tr:i,dispatch:r})=>{let o=(function(e){let t,n,i,r,o=e.split(/-(?!$)/),a=o[o.length-1];"Space"===a&&(a=" ");for(let e=0;e<o.length-1;e+=1){let a=o[e];if(/^(cmd|meta|m)$/i.test(a))r=!0;else if(/^a(lt)?$/i.test(a))t=!0;else if(/^(c|ctrl|control)$/i.test(a))n=!0;else if(/^s(hift)?$/i.test(a))i=!0;else if(/^mod$/i.test(a))aI()||aU()?r=!0:n=!0;else throw Error(`Unrecognized modifier name: ${a}`)}return t&&(a=`Alt-${a}`),n&&(a=`Ctrl-${a}`),r&&(a=`Meta-${a}`),i&&(a=`Shift-${a}`),a})(e).split(/-(?!$)/),a=o.find(e=>!["Alt","Ctrl","Meta","Shift"].includes(e)),s=new KeyboardEvent("keydown",{key:"Space"
230===a?" ":a,altKey:o.includes("Alt"),ctrlKey:o.includes("Ctrl"),metaKey:o.includes("Meta"),shiftKey:o.includes("Shift"),bubbles:!0,cancelable:!0}),l=t.captureTransaction(()=>{n.someProp("handleKeyDown",e=>e(n,s))});return null==l||l.steps.forEach(e=>{let t=e.map(i.mapping);t&&r&&i.maybeStep(t)}),!0};function aK(e,t,n={}){let{from:i,to:r,empty:o}=e.selection,a=t?ac(t,e.schema):null,s=[];e.doc.nodesBetween(i,r,(e,t)=>{if(e.isText)return;let n=Math.max(i,t),o=Math.min(r,t+e.nodeSize);s.push({node:e,from:n,to:o})});let l=r-i,d=s.filter(e=>!a||a.name===e.node.type.name).filter(e=>ab(e.node.attrs,n,{strict:!1}));return o?!!d.length:d.reduce((e,t)=>e+t.to-t.from,0)>=l}var aY=(e,t={})=>({state:n,dispatch:i})=>{let r=ac(e,n.schema);return!!aK(n,r,t)&&((e,t)=>{let{$from:n,$to:i}=e.selection,r=n.blockRange(i),o=r&&nd(r);return null!=o&&(t&&t(e.tr.lift(r,o).scrollIntoView()),!0)})(n,i)},aZ=()=>({state:e,dispatch:t})=>ia(e,t),aX=e=>({state:t,dispatch:n})=>{var i;return(i=ac(e,t.schema),function(e,t){let{$from:n,$to:r}=e.selection,o=n.blockRange(r,e=>e.childCount>0&&e.firstChild.type==i);return!!o&&(!t||(n.node(o.depth-1).type==i?function(e,t,n,i){let r=e.tr,o=i.end,a=i.$to.end(i.depth);o<a&&(r.step(new na(o-1,a,o,a,new tf(tl.from(n.create(null,i.parent.copy())),1,0),1,!0)),i=new tk(r.doc.resolve(i.$from.pos),r.doc.resolve(a),i.depth));let s=nd(i);if(null==s)return!1;r.lift(i,s);let l=r.doc.resolve(r.mapping.map(o,-1)-1);return ng(r.doc,l.pos)&&l.nodeBefore.type==l.nodeAfter.type&&r.join(l.pos),t(r.scrollIntoView()),!0}(e,t,i,o):function(e,t,n){let i=e.tr,r=n.parent;for(let e=n.end,t=n.endIndex-1,o=n.startIndex;t>o;t--)e-=r.child(t).nodeSize,i.delete(e-1,e+1);let o=i.doc.resolve(n.start),a=o.nodeAfter;if(i.mapping.map(n.end)!=n.start+o.nodeAfter.nodeSize)return!1;let s=0==n.startIndex,l=n.endIndex==r.childCount,d=o.node(-1),u=o.index(-1);if(!d.canReplace(u+ +!s,u+1,a.content.append(l?tl.empty:tl.from(r))))return!1;let c=o.pos,h=c+a.nodeSize;return i.step(new na(c-!!s,h+ +!!l,c+1,h-1,new tf((s?tl.empty:tl.from(r.copy(tl.empty))).append(l?tl.empty:tl.from(r.copy(tl.empty))),+!s,+!l),+!s)),t(i.scrollIntoView()),!0}(e,t,o)))})(t,n)},aJ=()=>({state:e,dispatch:t})=>it(e,t);function aQ(e,t){return t.nodes[e]?"node":t.marks[e]?"mark":null}function a0(e,t){let n="string"==typeof t?[t]:t;return Object.keys(e).reduce((t,i)=>(n.includes(i)||(t[i]=e[i]),t),{})}var a1=(e,t)=>({tr:n,state:i,dispatch:r})=>{let o=null,a=null,s=aQ("string"==typeof e?e:e.name,i.schema);if(!s)return!1;"node"===s&&(o=ac(e,i.schema)),"mark"===s&&(a=aS(e,i.schema));let l=!1;return n.selection.ranges.forEach(e=>{i.doc.nodesBetween(e.$from.pos,e.$to.pos,(e,i)=>{o&&o===e.type&&(l=!0,r&&n.setNodeMarkup(i,void 0,a0(e.attrs,t))),a&&e.marks.length&&e.marks.forEach(o=>{a===o.type&&(l=!0,r&&n.addMark(i,i+e.nodeSize,a.create(a0(o.attrs,t))))})})}),l},a2=()=>({tr:e,dispatch:t})=>(t&&e.scrollIntoView(),!0),a3=()=>({tr:e,dispatch:t})=>{if(t){let t=new nj(e.doc);e.setSelection(t)}return!0},a5=()=>({state:e,dispatch:t})=>n4(e,t),a4=()=>({state:e,dispatch:t})=>n9(e,t),a6=()=>({state:e,dispatch:t})=>((e,t)=>{let{$from:n,to:i}=e.selection,r,o=n.sharedDepth(i);return 0!=o&&(r=n.before(o),t&&t(e.tr.setSelection(nB.create(e.doc,r))),!0)})(e,t),a8=()=>({state:e,dispatch:t})=>iu(e,t),a7=()=>({state:e,dispatch:t})=>id(e,t);function a9(e,t,n={},i={}){return aO(e,t,{slice:!1,parseOptions:n,errorOnInvalidContent:i.errorOnInvalidContent})}var se=(e,{errorOnInvalidContent:t,emitUpdate:n=!0,parseOptions:i={}}={})=>({editor:r,tr:o,dispatch:a,commands:s})=>{let{doc:l}=o;if("full"!==i.preserveWhitespace){let s=a9(e,r.schema,i,{errorOnInvalidContent:null!=t?t:r.options.enableContentCheck});return a&&o.replaceWith(0,l.content.size,s).setMeta("preventUpdate",!n),!0}return a&&o.setMeta("preventUpdate",!n),s.insertContentAt({from:0,to:l.content.size},e,{parseOptions:i,errorOnInvalidContent:null!=t?t:r.options.enableContentCheck})};function st(e,t){let n=aS(t,e.schema),{from:i,to:r,empty:o}=e.selection,a=[];o?(e.storedMarks&&a.push(...e.storedMarks),a.push(...e.selection.$head.marks())):e.doc.nodesBetween(i,r,e=>{a.push(...e.marks)});let s=a.find(e=>
230e.type.name===n.name);return s?{...s.attrs}:{}}function sn(e,t){let n=new nI(e);return t.forEach(e=>{e.steps.forEach(e=>{n.step(e)})}),n}function si(e){return t=>(function(e,t){for(let n=e.depth;n>0;n-=1){let i=e.node(n);if(t(i))return{pos:n>0?e.before(n):0,start:e.start(n),depth:n,node:i}}})(t.$from,e)}function sr(e,t,n){return void 0===e.config[t]&&e.parent?sr(e.parent,t,n):"function"==typeof e.config[t]?e.config[t].bind({...n,parent:e.parent?sr(e.parent,t,n):null}):e.config[t]}function so(e){return e.map(e=>{let t={name:e.name,options:e.options,storage:e.storage},n=sr(e,"addExtensions",t);return n?[e,...so(n())]:e}).flat(10)}function sa(e,t){let n=tQ.fromSchema(t).serializeFragment(e),i=document.implementation.createHTMLDocument().createElement("div");return i.appendChild(n),i.innerHTML}function ss(e){return"function"==typeof e}function sl(e,t,...n){return ss(e)?t?e.bind(t)(...n):e(...n):e}function sd(e){let t=e.filter(e=>"extension"===e.type);return{baseExtensions:t,nodeExtensions:e.filter(e=>"node"===e.type),markExtensions:e.filter(e=>"mark"===e.type)}}function su(e){let t=[],{nodeExtensions:n,markExtensions:i}=sd(e),r=[...n,...i],o={default:null,validate:void 0,rendered:!0,renderHTML:null,parseHTML:null,keepOnSplit:!0,isRequired:!1},a=n.filter(e=>"text"!==e.name).map(e=>e.name),s=i.map(e=>e.name),l=[...a,...s];return e.forEach(e=>{let n={name:e.name,options:e.options,storage:e.storage,extensions:r},i=sr(e,"addGlobalAttributes",n);i&&i().forEach(e=>{(Array.isArray(e.types)?e.types:"*"===e.types?l:"nodes"===e.types?a:"marks"===e.types?s:[]).forEach(n=>{Object.entries(e.attributes).forEach(([e,i])=>{t.push({type:n,name:e,attribute:{...o,...i}})})})})}),r.forEach(e=>{let n={name:e.name,options:e.options,storage:e.storage},i=sr(e,"addAttributes",n);i&&Object.entries(i()).forEach(([n,i])=>{let r={...o,...i};"function"==typeof(null==r?void 0:r.default)&&(r.default=r.default()),(null==r?void 0:r.isRequired)&&(null==r?void 0:r.default)===void 0&&delete r.default,t.push({type:e.name,name:n,attribute:r})})}),t}function sc(e){let t=[],n=function(e){let t=[],n="",i=!1,r=!1,o=0,a=e.length;for(let s=0;s<a;s+=1){let a=e[s];if("'"===a&&!r){i=!i,n+=a;continue}if('"'===a&&!i){r=!r,n+=a;continue}if(!i&&!r){if("("===a){o+=1,n+=a;continue}if(")"===a&&o>0){o-=1,n+=a;continue}if(";"===a&&0===o){t.push(n),n="";continue}}n+=a}return n&&t.push(n),t}(e||""),i=n.length;for(let e=0;e<i;e+=1){let i=n[e],r=i.indexOf(":");if(-1===r)continue;let o=i.slice(0,r).trim(),a=i.slice(r+1).trim();o&&a&&t.push([o,a])}return t}function sh(...e){return e.filter(e=>!!e).reduce((e,t)=>{let n={...e};return Object.entries(t).forEach(([e,t])=>{if(!n[e]){n[e]=t;return}if("class"===e){let i=t?String(t).split(" "):[],r=n[e]?n[e].split(" "):[],o=i.filter(e=>!r.includes(e));n[e]=[...r,...o].join(" ")}else if("style"===e){let i=new Map([...sc(n[e]),...sc(t)]);n[e]=Array.from(i.entries()).map(([e,t])=>`${e}: ${t}`).join("; ")}else n[e]=t}),n},{})}function sp(e,t){return t.filter(t=>t.type===e.type.name).filter(e=>e.attribute.rendered).map(t=>t.attribute.renderHTML?t.attribute.renderHTML(e.attrs)||{}:{[t.name]:e.attrs[t.name]}).reduce((e,t)=>sh(e,t),{})}function sf(e,t){return"style"in e?e:{...e,getAttrs:n=>{let i=e.getAttrs?e.getAttrs(n):e.attrs;if(!1===i)return!1;let r=t.reduce((e,t)=>{var i;let r=t.attribute.parseHTML?t.attribute.parseHTML(n):"string"!=typeof(i=n.getAttribute(t.name))?i:i.match(/^[+-]?(?:\d*\.)?\d+$/)?Number(i):"true"===i||"false"!==i&&i;return null==r?e:{...e,[t.name]:r}},{});return{...i,...r}}}}function sg(e){return Object.fromEntries(Object.entries(e).filter(([e,t])=>!("attrs"===e&&function(e={}){return 0===Object.keys(e).length&&e.constructor===Object}(t))&&null!=t))}function sm(e){var t,n;let i={};return!(null==(t=null==e?void 0:e.attribute)?void 0:t.isRequired)&&"default"in((null==e?void 0:e.attribute)||{})&&(i.default=e.attribute.default),(null==(n=null==e?void 0:e.attribute)?void 0:n.validate)!==void 0&&(i.validate=e.attribute.validate),[e.name,i]}function sv(e){return e.sort((e,t)=>{let n=sr(e,"priority")||100,i=sr(t,"priority")||100;return n>i?-1:+(n<i)})}function sy(e){var t;let n=sv(so(e)),i=Array.from(new Set((t=n.map(e=>
230e.name)).filter((e,n)=>t.indexOf(e)!==n)));return i.length&&console.warn(`[tiptap warn]: Duplicate extension names found: [${i.map(e=>`'${e}'`).join(", ")}]. This can lead to issues.`),n}function sb(e,t,n){let{from:i,to:r}=t,{blockSeparator:o="\n\n",textSerializers:a={}}=n||{},s="";return e.nodesBetween(i,r,(e,n,l,d)=>{var u;e.isBlock&&n>i&&(s+=o);let c=null==a?void 0:a[e.type.name];if(c)return l&&(s+=c({node:e,pos:n,parent:l,index:d,range:t})),!1;e.isText&&(s+=null==(u=null==e?void 0:e.text)?void 0:u.slice(Math.max(i,n)-n,r-n))}),s}function sx(e){return Object.fromEntries(Object.entries(e.nodes).filter(([,e])=>e.spec.toText).map(([e,t])=>[e,t.spec.toText]))}function sw(e,t){let n=aQ("string"==typeof t?t:t.name,e.schema);return"node"===n?function(e,t){let n=ac(t,e.schema),{from:i,to:r}=e.selection,o=[];e.doc.nodesBetween(i,r,e=>{o.push(e)});let a=o.reverse().find(e=>e.type.name===n.name);return a?{...a.attrs}:{}}(e,t):"mark"===n?st(e,t):{}}function sC(e){let t,{mapping:n,steps:i}=e,r=[];return n.maps.forEach((e,t)=>{let o=[];if(e.ranges.length)e.forEach((e,t)=>{o.push({from:e,to:t})});else{let{from:e,to:n}=i[t];if(void 0===e||void 0===n)return;o.push({from:e,to:n})}o.forEach(({from:e,to:i})=>{let o=n.slice(t).map(e,-1),a=n.slice(t).map(i),s=n.invert().map(o,-1),l=n.invert().map(a);r.push({oldRange:{from:s,to:l},newRange:{from:o,to:a}})})}),1===(t=function(e,t=JSON.stringify){let n={};return e.filter(e=>{let i=t(e);return!Object.prototype.hasOwnProperty.call(n,i)&&(n[i]=!0)})}(r)).length?t:t.filter((e,n)=>!t.filter((e,t)=>t!==n).some(t=>e.oldRange.from>=t.oldRange.from&&e.oldRange.to<=t.oldRange.to&&e.newRange.from>=t.newRange.from&&e.newRange.to<=t.newRange.to))}function sS(e,t,n){let i=[];return e===t?n.resolve(e).marks().forEach(t=>{let r=aC(n.resolve(e),t.type);r&&i.push({mark:t,...r})}):n.nodesBetween(e,t,(e,t)=>{e&&(null==e?void 0:e.nodeSize)!==void 0&&i.push(...e.marks.map(n=>({from:t,to:t+e.nodeSize,mark:n})))}),i}function s_(e,t){return t.nodes[e]||t.marks[e]||null}function sk(e,t,n){return Object.fromEntries(Object.entries(n).filter(([n])=>{let i=e.find(e=>e.type===t&&e.name===n);return!!i&&i.attribute.keepOnSplit}))}function sM(e,t,n={}){let{empty:i,ranges:r}=e.selection,o=t?aS(t,e.schema):null;if(i)return!!(e.storedMarks||e.selection.$from.marks()).filter(e=>!o||o.name===e.type.name).find(e=>ab(e.attrs,n,{strict:!1}));let a=0,s=[];if(r.forEach(({$from:t,$to:n})=>{let i=t.pos,r=n.pos;e.doc.nodesBetween(i,r,(e,t)=>{if(o&&e.inlineContent&&!e.type.allowsMarkType(o))return!1;if(!e.isText&&!e.marks.length)return;let n=Math.max(i,t),l=Math.min(r,t+e.nodeSize);a+=l-n,s.push(...e.marks.map(e=>({mark:e,from:n,to:l})))})}),0===a)return!1;let l=s.filter(e=>!o||o.name===e.mark.type.name).filter(e=>ab(e.mark.attrs,n,{strict:!1})).reduce((e,t)=>e+t.to-t.from,0),d=s.filter(e=>!o||e.mark.type!==o&&e.mark.type.excludes(o)).reduce((e,t)=>e+t.to-t.from,0);return(l>0?l+d:l)>=a}function sT(e,t){return Array.isArray(t)?t.some(t=>("string"==typeof t?t:t.name)===e.name):t}function sD(e,t){let{nodeExtensions:n}=sd(t),i=n.find(t=>t.name===e);if(!i)return!1;let r={name:i.name,options:i.options,storage:i.storage},o=sl(sr(i,"group",r));return"string"==typeof o&&o.split(" ").includes("list")}function sR(e,{checkChildren:t=!0,ignoreWhitespace:n=!1}={}){var i;if(n){if("hardBreak"===e.type.name)return!0;if(e.isText)return!/\S/.test(null!=(i=e.text)?i:"")}if(e.isText)return!e.text;if(e.isAtom||e.isLeaf)return!1;if(0===e.content.childCount)return!0;if(t){let i=!0;return e.content.forEach(e=>{!1!==i&&(sR(e,{ignoreWhitespace:n,checkChildren:t})||(i=!1))}),i}return!1}function sI(e){return e instanceof nB}var sA=class e{constructor(e){this.position=e}static fromJSON(t){return new e(t.position)}toJSON(){return{position:this.position}}};function sP(e,t){let n=t.mapping.mapResult(e.position);return{position:new sA(n.pos),mapResult:n}}function sE(e){return new sA(e)}var sL=(e,t={})=>({tr:n,state:i,dispatch:r})=>{let{selection:o}=n,{empty:a,ranges:s}=o,l=aS(e,i.schema);if(r)if(a){let e=st(i,l);n.addStoredMark(l.create({...e,...t}))}else s.forEach(e=>{let r=e.$from.pos,o=e.$to.pos;i.doc.nodesBetween(r,o,(e,i)=>{let a=Math.max(i,r),s=Math.min(i+e.nodeSize,o);e.marks.find(e=>
230e.type===l)?e.marks.forEach(e=>{l===e.type&&n.addMark(a,s,l.create({...e.attrs,...t}))}):n.addMark(a,s,l.create(t))})});return function(e,t,n){var i;let{selection:r}=t,o=null;if(aM(r)&&(o=r.$cursor),o){let t=null!=(i=e.storedMarks)?i:o.marks();return o.parent.type.allowsMarkType(n)&&(!!n.isInSet(t)||!t.some(e=>e.type.excludes(n)))}let{ranges:a}=r;return a.some(({$from:t,$to:i})=>{let r=0===t.depth&&e.doc.inlineContent&&e.doc.type.allowsMarkType(n);return e.doc.nodesBetween(t.pos,i.pos,(e,t,i)=>{if(r)return!1;if(e.isInline){let t=!i||i.type.allowsMarkType(n),o=!!n.isInSet(e.marks)||!e.marks.some(e=>e.type.excludes(n));r=t&&o}return!r}),r})}(i,n,l)},sF=(e,t)=>({tr:n})=>(n.setMeta(e,t),!0),sO=(e,t={})=>({state:n,dispatch:i,chain:r})=>{let o,a=ac(e,n.schema);return(n.selection.$anchor.sameParent(n.selection.$head)&&(o=n.selection.$anchor.parent.attrs),a.isTextblock)?r().command(({commands:e})=>!!ic(a,{...o,...t})(n)||e.clearNodes()).command(({state:e})=>ic(a,{...o,...t})(e,i)).run():(console.warn('[tiptap warn]: Currently "setNode()" only supports text block nodes.'),!1)},sN=e=>({tr:t,dispatch:n})=>{if(n){let{doc:n}=t,i=aT(e,0,n.content.size),r=nB.create(n,i);t.setSelection(r)}return!0},sB=(e,t)=>({tr:n,state:i,dispatch:r})=>{let o,a,{selection:s}=i;return"number"==typeof t?(o=t,a=t):t&&"from"in t&&"to"in t?(o=t.from,a=t.to):(o=s.from,a=s.to),r&&n.doc.nodesBetween(o,a,(t,i)=>{t.isText||n.setNodeMarkup(i,void 0,{...t.attrs,dir:e})}),!0},sz=e=>({tr:t,dispatch:n})=>{if(n){let{doc:n}=t,{from:i,to:r}="number"==typeof e?{from:e,to:e}:e,o=nO.atStart(n).from,a=nO.atEnd(n).to,s=aT(i,o,a),l=aT(r,o,a),d=nO.create(n,s,l);t.setSelection(d)}return!0},sj=e=>({state:t,dispatch:n})=>{var i;return(i=ac(e,t.schema),function(e,t){let{$from:n,$to:r}=e.selection,o=n.blockRange(r,e=>e.childCount>0&&e.firstChild.type==i);if(!o)return!1;let a=o.startIndex;if(0==a)return!1;let s=o.parent,l=s.child(a-1);if(l.type!=i)return!1;if(t){let n=l.lastChild&&l.lastChild.type==s.type,r=tl.from(n?i.create():null),a=new tf(tl.from(i.create(null,tl.from(s.type.create(null,r)))),n?3:1,0),d=o.start,u=o.end;t(e.tr.step(new na(d-(n?3:1),u,d,u,a,1,!0)).scrollIntoView())}return!0})(t,n)};function sV(e,t){let n=e.storedMarks||e.selection.$to.parentOffset&&e.selection.$from.marks();if(n){let i=n.filter(e=>null==t?void 0:t.includes(e.type.name));e.tr.ensureMarks(i)}}var sH=({keepMarks:e=!0}={})=>({tr:t,state:n,dispatch:i,editor:r})=>{let{selection:o,doc:a}=t,{$from:s,$to:l}=o,d=sk(r.extensionManager.attributes,s.node().type.name,s.node().attrs);if(o instanceof nB&&o.node.isBlock)return!!s.parentOffset&&!!nf(a,s.pos)&&(i&&(e&&sV(n,r.extensionManager.splittableMarks),t.split(s.pos).scrollIntoView()),!0);if(!s.parent.isBlock)return!1;let u=l.parentOffset===l.parent.content.size,c=0===s.depth?void 0:function(e){for(let t=0;t<e.edgeCount;t+=1){let{type:n}=e.edge(t);if(n.isTextblock&&!n.hasRequiredAttrs())return n}return null}(s.node(-1).contentMatchAt(s.indexAfter(-1))),h=u&&c?[{type:c,attrs:d}]:void 0,p=nf(t.doc,t.mapping.map(s.pos),1,h);if(!h&&!p&&nf(t.doc,t.mapping.map(s.pos),1,c?[{type:c}]:void 0)&&(p=!0,h=c?[{type:c,attrs:d}]:void 0),i){if(p&&(o instanceof nO&&t.deleteSelection(),t.split(t.mapping.map(s.pos),1,h),c&&!u&&!s.parentOffset&&s.parent.type!==c)){let e=t.mapping.map(s.before()),n=t.doc.resolve(e);s.node(-1).canReplaceWith(n.index(),n.index()+1,c)&&t.setNodeMarkup(t.mapping.map(s.before()),c)}e&&sV(n,r.extensionManager.splittableMarks),t.scrollIntoView()}return p},sG=(e,t={})=>({tr:n,state:i,dispatch:r,editor:o})=>{var a;let s=ac(e,i.schema),{$from:l,$to:d}=i.selection,u=i.selection.node;if(u&&u.isBlock||l.depth<2||!l.sameParent(d))return!1;let c=l.node(-1);if(c.type!==s)return!1;let h=o.extensionManager.attributes;if(0===l.parent.content.size&&l.node(-1).childCount===l.indexAfter(-1)){if(2===l.depth||l.node(-3).type!==s||l.index(-2)!==l.node(-2).childCount-1)return!1;if(r){let e=tl.empty,i=l.index(-1)?1:l.index(-2)?2:3;for(let t=l.depth-i;t>=l.depth-3;t-=1)e=tl.from(l.node(t).copy(e));let r=l.indexAfter(-1)<l.node(-2).childCount?1:l.indexAfter(-2)<l.node(-3).childCount?2:3,o={...sk(h,l.node().type.name,l.node().attrs),...t},d=(null==(a=s.contentMatch.defaultType)?void 0:a.createAndFill(o))||void 0;e=e.append(tl.from(s.createAndFill(null,d)||void 0));let u=l.before(l.depth-(i-1));n.replace(u,l.after(-r),new tf(e,4-i,0));let c=-1;n.doc.nodesBetween(u,n.doc.content.size,(e,t)=>{if(c>-1)return!1;e.isTextblock&&0===e.content.size&&(c=t+1)}),c>-1&&n.setSelection(nO.near(n.doc.resolve(c))),n.scrollIntoView()}return!0}let p=d.pos===l.end()?c.contentMatchAt(0).defaultType:null,f={...sk(h,c.type.name,c.attrs),...t},g={...sk(h,l.node().type.name,l.node().attrs),...t};n.delete(l.pos,d.pos);let m=p?[{type:s,attrs:f},{type:p,attrs:g}]:[{type:s,attrs:f}];if(!nf(n.doc,l.pos,2))return!1;if(r){let{selection:e,storedMarks:t}=i,{splittableMarks:a}=o.extensionManager,s=t||e.$to.parentOffset&&e.$from.marks();if(n.split(l.pos,2,m).scrollIntoView(),!s||!r)return!0;let d=s.filter(e=>
230a.includes(e.type.name));n.ensureMarks(d)}return!0};function sW(e){return e&&"1"!==e?e:null}var s$=(e,t)=>{var n,i;let r=si(e=>e.type===t)(e.selection);if(!r)return!0;let o=e.doc.resolve(Math.max(0,r.pos-1)).before(r.depth);if(void 0===o)return!0;let a=e.doc.nodeAt(o);return!(r.node.type===(null==a?void 0:a.type)&&ng(e.doc,r.pos))||(n=r.node.attrs.type,i=null==a?void 0:a.attrs.type,sW(n)!==sW(i)||(e.join(r.pos),!0))},sU=(e,t)=>{var n,i;let r=si(e=>e.type===t)(e.selection);if(!r)return!0;let o=e.doc.resolve(r.start).after(r.depth);if(void 0===o)return!0;let a=e.doc.nodeAt(o);return!(r.node.type===(null==a?void 0:a.type)&&ng(e.doc,o))||(n=r.node.attrs.type,i=null==a?void 0:a.attrs.type,sW(n)!==sW(i)||(e.join(o),!0))},sq=(e,t,n,i={})=>({editor:r,tr:o,state:a,dispatch:s,chain:l,commands:d,can:u})=>{let{extensions:c,splittableMarks:h}=r.extensionManager,p=ac(e,a.schema),f=ac(t,a.schema),{selection:g,storedMarks:m}=a,{$from:v,$to:y}=g,b=v.blockRange(y),x=m||g.$to.parentOffset&&g.$from.marks();if(!b)return!1;let w=si(e=>sD(e.type.name,c))(g),C=0===g.from&&g.to===a.doc.content.size,S=a.doc.content.content,_=1===S.length?S[0]:null,k=C&&_&&sD(_.type.name,c)?{node:_,pos:0,depth:0}:null,M=null!=w?w:k,T=!!w&&b.depth>=1&&b.depth-w.depth<=1,D=!!k;if((T||D)&&M){if(M.node.type===p)return C&&D?l().command(({tr:e,dispatch:t})=>{let n=function(e){let t=e.doc,n=t.firstChild;if(!n)return null;let i=t.resolve(1),r=t.resolve(n.nodeSize-1);return nO.between(i,r)}(e);return!!n&&(e.setSelection(n),t&&t(e),!0)}).liftListItem(f).run():d.liftListItem(f);if(sD(M.node.type.name,c)&&p.validContent(M.node.content))return l().command(()=>(o.setNodeMarkup(M.pos,p),!0)).command(()=>s$(o,p)).command(()=>sU(o,p)).run()}return n&&x&&s?l().command(()=>{let e=u().wrapInList(p,i),t=x.filter(e=>h.includes(e.type.name));return o.ensureMarks(t),!!e||d.clearNodes()}).wrapInList(p,i).command(()=>s$(o,p)).command(()=>sU(o,p)).run():l().command(()=>!!u().wrapInList(p,i)||d.clearNodes()).wrapInList(p,i).command(()=>s$(o,p)).command(()=>sU(o,p)).run()},sK=(e,t={},n={})=>({state:i,commands:r})=>{let{extendEmptyMarkRange:o=!1}=n,a=aS(e,i.schema);return sM(i,a,t)?r.unsetMark(a,{extendEmptyMarkRange:o}):r.setMark(a,t)},sY=(e,t,n={})=>({state:i,commands:r})=>{let o,a=ac(e,i.schema),s=ac(t,i.schema),l=aK(i,a,n);return(i.selection.$anchor.sameParent(i.selection.$head)&&(o=i.selection.$anchor.parent.attrs),l)?r.setNode(s,o):r.setNode(a,{...o,...n})},sZ=(e,t={})=>({state:n,commands:i})=>{let r=ac(e,n.schema);return aK(n,r,t)?i.lift(r):i.wrapIn(r,t)},sX=()=>({state:e,dispatch:t})=>{let n=e.plugins;for(let i=0;i<n.length;i+=1){let r,o=n[i];if(o.spec.isInputRules&&(r=o.getState(e))){if(t){let t=e.tr,n=r.transform;for(let e=n.steps.length-1;e>=0;e-=1)t.step(n.steps[e].invert(n.docs[e]));if(r.text){let n=t.doc.resolve(r.from).marks();t.replaceWith(r.from,r.to,e.schema.text(r.text,n))}else t.delete(r.from,r.to)}return!0}}return!1},sJ=(e={})=>({tr:t,dispatch:n,editor:i})=>{let{ignoreClearable:r=!1}=e,{selection:o}=t,{empty:a,ranges:s}=o;if(a)return!0;let{nonClearableMarks:l}=i.extensionManager;if(n){let e=Object.values(i.schema.marks).filter(e=>r||!l.includes(e.name));s.forEach(n=>{for(let i of e)t.removeMark(n.$from.pos,n.$to.pos,i)})}return!0},sQ=(e,t={})=>({tr:n,state:i,dispatch:r})=>{var o;let{extendEmptyMarkRange:a=!1}=t,{selection:s}=n,l=aS(e,i.schema),{$from:d,empty:u,ranges:c}=s;if(!r)return!0;if(u&&a){let{from:e,to:t}=s,i=null==(o=d.marks().find(e=>e.type===l))?void 0:o.attrs,r=aC(d,l,i);r&&(e=r.from,t=r.to),n.removeMark(e,t,l)}else c.forEach(e=>{n.removeMark(e.$from.pos,e.$to.pos,l)});return n.removeStoredMark(l),!0},s0=e=>({tr:t,state:n,dispatch:i})=>{let r,o,{selection:a}=n;return"number"==typeof e?(r=e,o=e):e&&"from"in e&&"to"in e?(r=e.from,o=e.to):(r=a.from,o=a.to),i&&t.doc.nodesBetween(r,o,(e,n)=>{if(e.isText)return;let i={...e.attrs};delete i.dir,t.setNodeMarkup(n,void 0,i)}),!0},s1=(e,t={})=>({tr:n,state:i,dispatch:r})=>{let o=null,a=null,s=aQ("string"==typeof e?e:e.name,i.schema);if(!s)return!1;"node"===s&&(o=ac(e,i.schema)),"mark"===s&&(a=aS(e,i.schema));let l=!1;
230return n.selection.ranges.forEach(e=>{let s,d,u,c,h=e.$from.pos,p=e.$to.pos;n.selection.empty?i.doc.nodesBetween(h,p,(e,t)=>{o&&o===e.type&&(l=!0,u=Math.max(t,h),c=Math.min(t+e.nodeSize,p),s=t,d=e)}):i.doc.nodesBetween(h,p,(e,i)=>{i<h&&o&&o===e.type&&(l=!0,u=Math.max(i,h),c=Math.min(i+e.nodeSize,p),s=i,d=e),i>=h&&i<=p&&(o&&o===e.type&&(l=!0,r&&n.setNodeMarkup(i,void 0,{...e.attrs,...t})),a&&e.marks.length&&e.marks.forEach(o=>{if(a===o.type&&(l=!0,r)){let r=Math.max(i,h),s=Math.min(i+e.nodeSize,p);n.addMark(r,s,a.create({...o.attrs,...t}))}}))}),d&&(void 0!==s&&r&&n.setNodeMarkup(s,void 0,{...d.attrs,...t}),a&&d.marks.length&&d.marks.forEach(e=>{a===e.type&&r&&n.addMark(u,c,a.create({...e.attrs,...t}))}))}),l},s2=(e,t={})=>({state:n,dispatch:i})=>(function(e,t=null){return function(n,i){let{$from:r,$to:o}=n.selection,a=r.blockRange(o),s=a&&nu(a,e,t);return!!s&&(i&&i(n.tr.wrap(a,s).scrollIntoView()),!0)}})(ac(e,n.schema),t)(n,i),s3=(e,t={})=>({state:n,dispatch:i})=>(function(e,t=null){return function(n,i){let{$from:r,$to:o}=n.selection,a=r.blockRange(o);if(!a)return!1;let s=i?n.tr:null;return!!function(e,t,n,i=null){let r=!1,o=t,a=t.$from.doc;if(t.depth>=2&&t.$from.node(t.depth-1).type.compatibleContent(n)&&0==t.startIndex){if(0==t.$from.index(t.depth-1))return!1;let e=a.resolve(t.start-2);o=new tk(e,e,t.depth),t.endIndex<t.parent.childCount&&(t=new tk(t.$from,a.resolve(t.$to.end(t.depth)),t.depth)),r=!0}let s=nu(o,n,i,t);return!!s&&(e&&function(e,t,n,i,r){let o=tl.empty;for(let e=n.length-1;e>=0;e--)o=tl.from(n[e].type.create(n[e].attrs,o));e.step(new na(t.start-2*!!i,t.end,t.start,t.end,new tf(o,0,0),n.length,!0));let a=0;for(let e=0;e<n.length;e++)n[e].type==r&&(a=e+1);let s=n.length-a,l=t.start+n.length-2*!!i,d=t.parent;for(let n=t.startIndex,i=t.endIndex,r=!0;n<i;n++,r=!1)!r&&nf(e.doc,l,s)&&(e.split(l,s),l+=2*s),l+=d.child(n).nodeSize}(e,t,s,r,n),!0)}(s,a,e,t)&&(i&&i(s.scrollIntoView()),!0)}})(ac(e,n.schema),t)(n,i),s5=class{constructor(){this.callbacks={}}on(e,t){return this.callbacks[e]||(this.callbacks[e]=[]),this.callbacks[e].push(t),this}emit(e,...t){let n=this.callbacks[e];return n&&n.forEach(e=>e.apply(this,t)),this}off(e,t){let n=this.callbacks[e];return n&&(t?this.callbacks[e]=n.filter(e=>e!==t):delete this.callbacks[e]),this}once(e,t){let n=(...i)=>{this.off(e,n),t.apply(this,i)};return this.on(e,n)}removeAllListeners(){this.callbacks={}}};function s4(e,t,n){let i=document.querySelector(`style[data-tiptap-style${n?`-${n}`:""}]`);if(null!==i)return i;let r=document.createElement("style");return t&&r.setAttribute("nonce",t),r.setAttribute(`data-tiptap-style${n?`-${n}`:""}`,""),r.innerHTML=e,document.getElementsByTagName("head")[0].appendChild(r),r}function s6(e){return"Object"===Object.prototype.toString.call(e).slice(8,-1)&&e.constructor===Object&&Object.getPrototypeOf(e)===Object.prototype}function s8(e){if(!(null==e?void 0:e.trim()))return{};let t={},n=[],i=e.replace(/["']([^"']*)["']/g,e=>(n.push(e),`__QUOTED_${n.length-1}__`)),r=i.match(/(?:^|\s)\.([\w-]+)/g);r&&(t.class=r.map(e=>e.trim().slice(1)).join(" "));let o=i.match(/(?:^|\s)#([\w-]+)/);o&&(t.id=o[1]),Array.from(i.matchAll(/([a-zA-Z][\w-]*)\s*=\s*(__QUOTED_\d+__)/g)).forEach(([,e,i])=>{var r;let o=n[parseInt((null==(r=i.match(/__QUOTED_(\d+)__/))?void 0:r[1])||"0",10)];o&&(t[e]=o.slice(1,-1))});let a=i.replace(/(?:^|\s)\.([\w-]+)/g,"").replace(/(?:^|\s)#([\w-]+)/g,"").replace(/([a-zA-Z][\w-]*)\s*=\s*__QUOTED_\d+__/g,"").trim();return a&&a.split(/\s+/).filter(Boolean).forEach(e=>
230{e.match(/^[a-zA-Z][\w-]*$/)&&(t[e]=!0)}),t}function s7(e){if(!e||0===Object.keys(e).length)return"";let t=[];return e.class&&String(e.class).split(/\s+/).filter(Boolean).forEach(e=>t.push(`.${e}`)),e.id&&t.push(`#${e.id}`),Object.entries(e).forEach(([e,n])=>{"class"!==e&&"id"!==e&&(!0===n?t.push(e):!1!==n&&null!=n&&t.push(`${e}="${String(n)}"`))}),t.join(" ")}function s9(e){let{nodeName:t,name:n,parseAttributes:i=s8,serializeAttributes:r=s7,defaultAttributes:o={},requiredAttributes:a=[],allowedAttributes:s}=e,l=n||t;return{parseMarkdown:(e,n)=>{let i={...o,...e.attributes};return n.createNode(t,i,[])},markdownTokenizer:{name:t,level:"block",start(e){var t;let n=RegExp(`^:::${l}(?:\\s|$)`,"m"),i=null==(t=e.match(n))?void 0:t.index;return void 0!==i?i:-1},tokenize(e,n,r){let o=RegExp(`^:::${l}(?:\\s+\\{([^}]*)\\})?\\s*:::(?:\\n|$)`),s=e.match(o);if(!s)return;let d=i(s[1]||"");if(!a.find(e=>!(e in d)))return{type:t,raw:s[0],attributes:d}}},renderMarkdown:e=>{let t=r((e=>{if(!s)return e;let t={};return s.forEach(n=>{n in e&&(t[n]=e[n])}),t})(e.attrs||{})),n=t?` {${t}}`:"";return`:::${l}${n} :::`}}}function le(e){let{nodeName:t,name:n,getContent:i,parseAttributes:r=s8,serializeAttributes:o=s7,defaultAttributes:a={},content:s="block",allowedAttributes:l}=e,d=n||t;return{parseMarkdown:(e,n)=>{let r;if(i){let t=i(e);r="string"==typeof t?[{type:"text",text:t}]:t}else r="block"===s?n.parseChildren(e.tokens||[]):n.parseInline(e.tokens||[]);let o={...a,...e.attributes};return n.createNode(t,o,r)},markdownTokenizer:{name:t,level:"block",start(e){var t;let n=RegExp(`^:::${d}`,"m"),i=null==(t=e.match(n))?void 0:t.index;return void 0!==i?i:-1},tokenize(e,n,i){var o;let a=RegExp(`^:::${d}(?:\\s+\\{([^}]*)\\})?\\s*\\n`),l=e.match(a);if(!l)return;let[u,c=""]=l,h=r(c),p=1,f=u.length,g="",m=/^:::([\w-]*)(\s.*)?/gm,v=e.slice(f);for(m.lastIndex=0;;){let n=m.exec(v);if(null===n)break;let r=n.index,a=n[1];if(null==(o=n[2])||!o.endsWith(":::")){if(a)p+=1;else if(0==(p-=1)){let o=v.slice(0,r);g=o.trim();let a=e.slice(0,f+r+n[0].length),l=[];if(g)if("block"===s)for((l=i.blockTokens(o)).forEach(e=>{e.text&&(!e.tokens||0===e.tokens.length)&&(e.tokens=i.inlineTokens(e.text))});l.length>0;){let e=l[l.length-1];if("paragraph"!==e.type||e.text&&""!==e.text.trim())break;l.pop()}else l=i.inlineTokens(g);return{type:t,raw:a,attributes:h,content:g,tokens:l}}}}}},renderMarkdown:(e,t)=>{let n=o((e=>{if(!l)return e;let t={};return l.forEach(n=>{n in e&&(t[n]=e[n])}),t})(e.attrs||{})),i=n?` {${n}}`:"",r=t.renderChildren(e.content||[],"\n\n");return`:::${d}${i} 231 232${r} 233 234:::`}}}function lt(e){if(!e.trim())return{};let t={},n=/(\w+)=(?:"([^"]*)"|'([^']*)')/g,i=n.exec(e);for(;null!==i;){let[,r,o,a]=i;t[r]=o||a,i=n.exec(e)}return t}function ln(e){return Object.entries(e).filter(([,e])=>null!=e).map(([e,t])=>`${e}="${t}"`).join(" ")}function li(e){let{nodeName:t,name:n,getContent:i,parseAttributes:r=lt,serializeAttributes:o=ln,defaultAttributes:a={},selfClosing:s=!1,allowedAttributes:l}=e,d=n||t,u=d.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return{parseMarkdown:(e,n)=>{let r={...a,...e.attributes};if(s)return n.createNode(t,r);let o=i?i(e):e.content||"";return o?n.createNode(t,r,[n.createTextNode(o)]):n.createNode(t,r,[])},markdownTokenizer:{name:t,level:"inline",start(e){let t=s?RegExp(`\\[${u}\\s*[^\\]]*\\]`):RegExp(`\\[${u}\\s*[^\\]]*\\][\\s\\S]*?\\[\\/${u}\\]`),n=e.match(t),i=null==n?void 0:n.index;return void 0!==i?i:-1},tokenize(e,n,i){let o=s?RegExp(`^\\[${u}\\s*([^\\]]*)\\]`):RegExp(`^\\[${u}\\s*([^\\]]*)\\]([\\s\\S]*?)\\[\\/${u}\\]`),a=e.match(o);if(!a)return;let l="",d="";if(s){let[,e]=a;d=e}else{let[,e,t]=a;d=e,l=t||""}let c=r(d.trim());return{type:t,raw:a[0],content:l.trim(),attributes:c}}},renderMarkdown:e=>{let t="";i?t=i(e):e.content&&e.content.length>0&&(t=e.content.filter(e=>"text"===e.type).map(e=>e.text).join(""));let n=o((e=>{if(!l)return e;let t={};return l.forEach(n=>{let i="string"==typeof n?n:n.name,r="string"==typeof n?void 0:n.skipIfDefault;if(i in e){let n=e[i];if(void 0!==r&&n===r)return;t[i]=n}}),t})(e.attrs||{})),r=n?` ${n}`:"";return s?`[${d}${r}]`:`[${d}${r}]${t}[/${d}]`}}}function lr(e,t,n){var i,r,o,a;let s=e.split("\n"),l=[],d="",u=0,c=t.baseIndentSize||2;for(;u<s.length;){let e,h=s[u],p=h.match(t.itemPattern);if(!p)if(l.length>0)break;else{if(""!==h.trim())return;u+=1,d=`${d}${h} 235`;continue}let f=t.extractItemData(p),{indentLevel:g,mainContent:m}=f;d=`${d}${h} 236`;let v=[m];for(u+=1;u<s.length;){let e=s[u];if(""===e.trim()){let t=s.slice(u+1).findIndex(e=>""!==e.trim());if(-1===t)break;
236if(((null==(r=null==(i=s[u+1+t].match(/^(\s*)/))?void 0:i[1])?void 0:r.length)||0)>g){v.push(e),d=`${d}${e} 237`,u+=1;continue}break}if(((null==(a=null==(o=e.match(/^(\s*)/))?void 0:o[1])?void 0:a.length)||0)>g)v.push(e),d=`${d}${e} 238`,u+=1;else break}let y=v.slice(1);if(y.length>0){let i=y.map(e=>e.slice(g+c)).join("\n");i.trim()&&(e=t.customNestedParser?t.customNestedParser(i):n.blockTokens(i))}let b=t.createToken(f,e);l.push(b)}if(0!==l.length)return{items:l,raw:d}}function lo(e,t,n,i){if(!e||!Array.isArray(e.content))return"";let r="function"==typeof n?n(i):n,[o,...a]=e.content,s=t.renderChildren([o]),l=`${r}${s}`;return a&&a.length>0&&a.forEach((e,n)=>{var i,r;let o=null!=(r=null==(i=t.renderChild)?void 0:i.call(t,e,n+1))?r:t.renderChildren([e]);if(null!=o){let n=o.split("\n").map(e=>e?t.indent(e):t.indent("")).join("\n");l+="paragraph"===e.type?` 239 240${n}`:` 241${n}`}}),l}ae({},{createAtomBlockMarkdownSpec:()=>s9,createBlockMarkdownSpec:()=>le,createInlineMarkdownSpec:()=>li,parseAttributes:()=>s8,parseIndentedBlocks:()=>lr,renderNestedMarkdownContent:()=>lo,serializeAttributes:()=>s7});var la=class{constructor(e){var t;this.find=e.find,this.handler=e.handler,this.undoable=null==(t=e.undoable)||t}};function ls(e){var t;let{editor:n,from:i,to:r,text:o,rules:a,plugin:s}=e,{view:l}=n;if(l.composing)return!1;let d=l.state.doc.resolve(i);if(d.parent.type.spec.code||(null==(t=d.nodeBefore||d.nodeAfter)?void 0:t.marks.find(e=>e.type.spec.code)))return!1;let u=!1,c=((e,t=500)=>{let n="",i=e.parentOffset;return e.parent.nodesBetween(Math.max(0,i-t),i,(e,t,r,o)=>{var a,s;let l=(null==(s=(a=e.type.spec).toText)?void 0:s.call(a,{node:e,pos:t,parent:r,index:o}))||e.textContent||"%leaf%";n+=e.isAtom&&!e.isText?l:l.slice(0,Math.max(0,i-t))}),n})(d)+o;return a.forEach(e=>{if(u)return;let t=((e,t)=>{if(ay(t))return t.exec(e);let n=t(e);if(!n)return null;let i=[n.text];return i.index=n.index,i.input=e,i.data=n.data,n.replaceWith&&(n.text.includes(n.replaceWith)||console.warn('[tiptap warn]: "inputRuleMatch.replaceWith" must be part of "inputRuleMatch.text".'),i.push(n.replaceWith)),i})(c,e.find);if(!t)return;let a=l.state.tr,d=at({state:l.state,transaction:a}),h={from:i-(t[0].length-o.length),to:r},{commands:p,chain:f,can:g}=new an({editor:n,state:d});null!==e.handler({state:d,range:h,match:t,commands:p,chain:f,can:g})&&a.steps.length&&(e.undoable&&a.setMeta(s,{transform:a,from:i,to:r,text:o}),l.dispatch(a),u=!0)}),u}var ll=class{constructor(e={}){this.type="extendable",this.parent=null,this.child=null,this.name="",this.config={name:this.name},this.config={...this.config,...e},this.name=this.config.name}get options(){return{...sl(sr(this,"addOptions",{name:this.name}))}}get storage(){return{...sl(sr(this,"addStorage",{name:this.name,options:this.options}))}}configure(e={}){let t=this.extend({...this.config,addOptions:()=>(function e(t,n){let i={...t};return s6(t)&&s6(n)&&Object.keys(n).forEach(r=>{s6(n[r])&&s6(t[r])?i[r]=e(t[r],n[r]):i[r]=n[r]}),i})(this.options,e)});return t.name=this.name,t.parent=this.parent,this.child=null,t}extend(e={}){let t=new this.constructor({...this.config,...e});return t.parent=this,this.child=t,t.name="name"in e?e.name:t.parent.name,t}},ld=class e extends ll{constructor(){super(...arguments),this.type="mark"}static create(t={}){return new e("function"==typeof t?t():t)}static handleExit({editor:e,mark:t}){let{tr:n}=e.state,i=e.state.selection.$from;if(i.pos===i.end()){let r=i.marks();if(!r.find(e=>(null==e?void 0:e.type.name)===t.name))return!1;let o=r.find(e=>(null==e?void 0:e.type.name)===t.name);return o&&n.removeStoredMark(o),n.insertText(" ",i.pos),e.view.dispatch(n),!0}return!1}configure(e){return super.configure(e)}extend(e){let t="function"==typeof e?e():e;return super.extend(t)}},lu=class{constructor(e){this.find=e.find,this.handler=e.handler}},lc=null,lh=class{constructor(e,t){this.splittableMarks=[],this.nonClearableMarks=[],this.editor=t,this.baseExtensions=e,this.extensions=sy(e),this.schema=function(e,t){var n;let i=su(e),{nodeExtensions:r,markExtensions:o}=sd(e),a=null==(n=r.find(e=>sr(e,"topNode")))?void 0:n.name;return new tH({topNode:a,nodes:Object.fromEntries(r.map(n=>{let r=i.filter(e=>e.type===n.name),o={name:n.name,options:n.options,storage:n.storage,editor:t},a=sg({...e.reduce((e,t)=>
241{let i=sr(t,"extendNodeSchema",o);return{...e,...i?i(n):{}}},{}),content:sl(sr(n,"content",o)),marks:sl(sr(n,"marks",o)),group:sl(sr(n,"group",o)),inline:sl(sr(n,"inline",o)),atom:sl(sr(n,"atom",o)),selectable:sl(sr(n,"selectable",o)),draggable:sl(sr(n,"draggable",o)),code:sl(sr(n,"code",o)),whitespace:sl(sr(n,"whitespace",o)),linebreakReplacement:sl(sr(n,"linebreakReplacement",o)),defining:sl(sr(n,"defining",o)),isolating:sl(sr(n,"isolating",o)),attrs:Object.fromEntries(r.map(sm))}),s=sl(sr(n,"parseHTML",o));s&&(a.parseDOM=s.map(e=>sf(e,r)));let l=sr(n,"renderHTML",o);l&&(a.toDOM=e=>l({node:e,HTMLAttributes:sp(e,r)}));let d=sr(n,"renderText",o);return d&&(a.toText=d),[n.name,a]})),marks:Object.fromEntries(o.map(n=>{let r=i.filter(e=>e.type===n.name),o={name:n.name,options:n.options,storage:n.storage,editor:t},a=sg({...e.reduce((e,t)=>{let i=sr(t,"extendMarkSchema",o);return{...e,...i?i(n):{}}},{}),inclusive:sl(sr(n,"inclusive",o)),excludes:sl(sr(n,"excludes",o)),group:sl(sr(n,"group",o)),spanning:sl(sr(n,"spanning",o)),code:sl(sr(n,"code",o)),attrs:Object.fromEntries(r.map(sm))}),s=sl(sr(n,"parseHTML",o));s&&(a.parseDOM=s.map(e=>sf(e,r)));let l=sr(n,"renderHTML",o);return l&&(a.toDOM=e=>l({mark:e,HTMLAttributes:sp(e,r)})),[n.name,a]}))})}(this.extensions,t),this.setupExtensions()}get commands(){return this.extensions.reduce((e,t)=>{let n={name:t.name,options:t.options,storage:this.editor.extensionStorage[t.name],editor:this.editor,type:s_(t.name,this.schema)},i=sr(t,"addCommands",n);return i?{...e,...i()}:e},{})}get plugins(){let{editor:e}=this;return sv([...this.extensions].reverse()).flatMap(t=>{let n={name:t.name,options:t.options,storage:this.editor.extensionStorage[t.name],editor:e,type:s_(t.name,this.schema)},i=[],r=sr(t,"addKeyboardShortcuts",n),o={};if("mark"===t.type&&sr(t,"exitable",n)&&(o.ArrowRight=()=>ld.handleExit({editor:e,mark:t})),r){let t=Object.fromEntries(Object.entries(r()).map(([t,n])=>[t,()=>n({editor:e})]));o={...o,...t}}let a=new nZ({props:{handleKeyDown:o7(o)}});i.push(a);let s=sr(t,"addInputRules",n);if(sT(t,e.options.enableInputRules)&&s){let t=s();if(t&&t.length){let n=function(e){let{editor:t,rules:n}=e,i=new nZ({state:{init:()=>null,apply(e,r,o){let a=e.getMeta(i);if(a)return a;let s=e.getMeta("applyInputRules");return s&&setTimeout(()=>{let{text:e}=s;"string"==typeof e||(e=sa(tl.from(e),o.schema));let{from:r}=s,a=r+e.length;ls({editor:t,from:r,to:a,text:e,rules:n,plugin:i})}),e.selectionSet||e.docChanged?null:r}},props:{handleTextInput:(e,r,o,a)=>ls({editor:t,from:r,to:o,text:a,rules:n,plugin:i}),handleDOMEvents:{compositionend:e=>(setTimeout(()=>{let{$cursor:r}=e.state.selection;r&&ls({editor:t,from:r.pos,to:r.pos,text:"",rules:n,plugin:i})}),!1)},handleKeyDown(e,r){if("Enter"!==r.key)return!1;let{$cursor:o}=e.state.selection;return!!o&&ls({editor:t,from:o.pos,to:o.pos,text:"\n",rules:n,plugin:i})}},isInputRules:!0});return i}({editor:e,rules:t}),r=Array.isArray(n)?n:[n];i.push(...r)}}let l=sr(t,"addPasteRules",n);if(sT(t,e.options.enablePasteRules)&&l){let t=l();if(t&&t.length){let n=function(e){let t,{editor:n,rules:i}=e,r=null,o=!1,a=!1,s="u">typeof ClipboardEvent?new ClipboardEvent("paste"):null;try{t="u">typeof DragEvent?new DragEvent("drop"):null}catch{t=null}let l=({state:e,from:i,to:r,rule:o,pasteEvt:a})=>{let l=e.tr;if(function(e){let{editor:t,state:n,from:i,to:r,rule:o,pasteEvent:a,dropEvent:s}=e,{commands:l,chain:d,can:u}=new an({editor:t,state:n}),c=[];return n.doc.nodesBetween(i,r,(e,t)=>{var h,p,f,g,m;if((null==(p=null==(h=e.type)?void 0:h.spec)?void 0:p.code)||!(e.isText||e.isTextblock||e.isInline))return;let v=null!=(m=null!=(g=null==(f=e.content)?void 0:f.size)?g:e.nodeSize)?m:0,y=Math.max(i,t),b=Math.min(r,t+v);y>=b||((e,t,n)=>{if(ay(t))return[...e.matchAll(t)];let i=t(e,n);return i?i.map(t=>{let n=[t.text];return n.index=t.index,n.input=e,n.data=t.data,t.replaceWith&&(t.text.includes(t.replaceWith)||console.warn('[tiptap warn]: "pasteRuleMatch.replaceWith" must be part of "pasteRuleMatch.text".'),n.push(t.replaceWith)),n}):[]})(e.isText?e.text||"":e.textBetween(y-t,b-t,void 0,""),o.find,a).forEac
241h(e=>{if(void 0===e.index)return;let t=y+e.index+1,i=t+e[0].length,r={from:n.tr.mapping.map(t),to:n.tr.mapping.map(i)},h=o.handler({state:n,range:r,match:e,commands:l,chain:d,can:u,pasteEvent:a,dropEvent:s});c.push(h)})}),c.every(e=>null!==e)}({editor:n,state:at({state:e,transaction:l}),from:Math.max(i-1,0),to:r.b-1,rule:o,pasteEvent:a,dropEvent:t})&&l.steps.length){try{t="u">typeof DragEvent?new DragEvent("drop"):null}catch{t=null}return s="u">typeof ClipboardEvent?new ClipboardEvent("paste"):null,l}};return i.map(e=>new nZ({view(e){let t=t=>{var i;(r=(null==(i=e.dom.parentElement)?void 0:i.contains(t.target))?e.dom.parentElement:null)&&(lc=n)},i=()=>{lc&&(lc=null)};return window.addEventListener("dragstart",t),window.addEventListener("dragend",i),{destroy(){window.removeEventListener("dragstart",t),window.removeEventListener("dragend",i)}}},props:{handleDOMEvents:{drop:(e,n)=>{if(a=r===e.dom.parentElement,t=n,!a){let e=lc;(null==e?void 0:e.isEditable)&&setTimeout(()=>{let t=e.state.selection;t&&e.commands.deleteRange({from:t.from,to:t.to})},10)}return!1},paste:(e,t)=>{var n;let i=null==(n=t.clipboardData)?void 0:n.getData("text/html");return s=t,o=!!(null==i?void 0:i.includes("data-pm-slice")),!1}}},appendTransaction:(t,n,i)=>{let r=t[0],d="paste"===r.getMeta("uiEvent")&&!o,u="drop"===r.getMeta("uiEvent")&&!a,c=r.getMeta("applyPasteRules"),h=!!c;if(!d&&!u&&!h)return;if(h){var p,f;let t,{text:n}=c;"string"==typeof n||(n=sa(tl.from(n),i.schema));let{from:r}=c,o=r+n.length;return l({rule:e,state:i,from:r,to:{b:o},pasteEvt:(p=n,null==(f=(t=new ClipboardEvent("paste",{clipboardData:new DataTransfer})).clipboardData)||f.setData("text/html",p),t)})}let g=n.doc.content.findDiffStart(i.doc.content),m=n.doc.content.findDiffEnd(i.doc.content);if("number"==typeof g&&m&&g!==m.b)return l({rule:e,state:i,from:g,to:m,pasteEvt:s})}}))}({editor:e,rules:t});i.push(...n)}}let d=sr(t,"addProseMirrorPlugins",n);if(d){let e=d();i.push(...e)}return i})}get attributes(){return su(this.extensions)}get nodeViews(){let{editor:e}=this,{nodeExtensions:t}=sd(this.extensions);return Object.fromEntries(t.filter(e=>!!sr(e,"addNodeView")).map(t=>{let n=this.attributes.filter(e=>e.type===t.name),i={name:t.name,options:t.options,storage:this.editor.extensionStorage[t.name],editor:e,type:ac(t.name,this.schema)},r=sr(t,"addNodeView",i);if(!r)return[];let o=r();return o?[t.name,(i,r,a,s,l)=>{let d=sp(i,n);return o({node:i,view:r,getPos:a,decorations:s,innerDecorations:l,editor:e,extension:t,HTMLAttributes:d})}]:[]}))}dispatchTransaction(e){let{editor:t}=this;return sv([...this.extensions].reverse()).reduceRight((e,n)=>{let i={name:n.name,options:n.options,storage:this.editor.extensionStorage[n.name],editor:t,type:s_(n.name,this.schema)},r=sr(n,"dispatchTransaction",i);return r?t=>{r.call(i,{transaction:t,next:e})}:e},e)}transformPastedHTML(e){let{editor:t}=this;return sv([...this.extensions]).reduce((e,n)=>{let i={name:n.name,options:n.options,storage:this.editor.extensionStorage[n.name],editor:t,type:s_(n.name,this.schema)},r=sr(n,"transformPastedHTML",i);return r?(t,n)=>{let o=e(t,n);return r.call(i,o)}:e},e||(e=>e))}get markViews(){let{editor:e}=this,{markExtensions:t}=sd(this.extensions);return Object.fromEntries(t.filter(e=>!!sr(e,"addMarkView")).map(t=>{let n=this.attributes.filter(e=>e.type===t.name),i={name:t.name,options:t.options,storage:this.editor.extensionStorage[t.name],editor:e,type:aS(t.name,this.schema)},r=sr(t,"addMarkView",i);return r?[t.name,(i,o,a)=>{let s=sp(i,n);return r()({mark:i,view:o,inline:a,editor:e,extension:t,HTMLAttributes:s,updateAttributes:t=>{!function(e,t,n={}){let{state:i}=t,{doc:r,tr:o}=i;r.descendants((t,i)=>{let r=o.mapping.map(i),a=o.mapping.map(i)+t.nodeSize,s=null;if(t.marks.forEach(t=>{if(t!==e)return!1;s=t}),!s)return;let l=!1;if(Object.keys(n).forEach(e=>{n[e]!==s.attrs[e]&&(l=!0)}),l){let t=e.type.create({...e.attrs,...n});o.removeMark(r,a,e.type),o.addMark(r,a,t)}}),o.docChanged&&t.view.dispatch(o)}(i,e,t)}})}]:[]}))}destroy(){this.extensions.forEach(e=>{let t=e;for(;t.parent;){let e=t.parent;e.child===t&&(e.child=null),t=e}}),this.extensions=[],this.baseExtensions=[],this.schema=null,this.editor=null}setupExtensions(){let e=this.extensions;this.editor.extensionStorage=Object.fromEntries(e.map(e=>
241[e.name,e.storage])),e.forEach(e=>{var t,n;let i={name:e.name,options:e.options,storage:this.editor.extensionStorage[e.name],editor:this.editor,type:s_(e.name,this.schema)};"mark"===e.type&&((null==(t=sl(sr(e,"keepOnSplit",i)))||t)&&this.splittableMarks.push(e.name),null==(n=sl(sr(e,"clearable",i)))||n||this.nonClearableMarks.push(e.name));let r=sr(e,"onBeforeCreate",i),o=sr(e,"onCreate",i),a=sr(e,"onUpdate",i),s=sr(e,"onSelectionUpdate",i),l=sr(e,"onTransaction",i),d=sr(e,"onFocus",i),u=sr(e,"onBlur",i),c=sr(e,"onDestroy",i);r&&this.editor.on("beforeCreate",r),o&&this.editor.on("create",o),a&&this.editor.on("update",a),s&&this.editor.on("selectionUpdate",s),l&&this.editor.on("transaction",l),d&&this.editor.on("focus",d),u&&this.editor.on("blur",u),c&&this.editor.on("destroy",c)})}};lh.resolve=sy,lh.sort=sv,lh.flatten=so,ae({},{ClipboardTextSerializer:()=>lf,Commands:()=>lg,Delete:()=>lm,Drop:()=>lv,Editable:()=>ly,FocusEvents:()=>lx,Keymap:()=>lw,Paste:()=>lC,Tabindex:()=>lS,TextDirection:()=>l_,focusEventsPluginKey:()=>lb});var lp=class e extends ll{constructor(){super(...arguments),this.type="extension"}static create(t={}){return new e("function"==typeof t?t():t)}configure(e){return super.configure(e)}extend(e){let t="function"==typeof e?e():e;return super.extend(t)}},lf=lp.create({name:"clipboardTextSerializer",addOptions:()=>({blockSeparator:void 0}),addProseMirrorPlugins(){return[new nZ({key:new nQ("clipboardTextSerializer"),props:{clipboardTextSerializer:()=>{let{editor:e}=this,{state:t,schema:n}=e,{doc:i,selection:r}=t,o=sx(n),{blockSeparator:a}=this.options,s={...void 0!==a?{blockSeparator:a}:{},textSerializers:o};return[...r.ranges].sort((e,t)=>e.$from.pos-t.$from.pos).map(({$from:e,$to:t})=>sb(i,{from:e.pos,to:t.pos},s)).join(null!=a?a:"\n\n")}}})]}}),lg=lp.create({name:"commands",addCommands:()=>({...ai})}),lm=lp.create({name:"delete",onUpdate({transaction:e,appendedTransactions:t}){var n,i,r;let o=()=>{var n,i,r,o;if(null!=(o=null==(r=null==(i=null==(n=this.editor.options.coreExtensionOptions)?void 0:n.delete)?void 0:i.filterTransaction)?void 0:r.call(i,e))?o:e.getMeta("y-sync$"))return;let a=sn(e.before,[e,...t]);sC(a).forEach(t=>{a.mapping.mapResult(t.oldRange.from).deletedAfter&&a.mapping.mapResult(t.oldRange.to).deletedBefore&&a.before.nodesBetween(t.oldRange.from,t.oldRange.to,(n,i)=>{let r=i+n.nodeSize-2,o=t.oldRange.from<=i&&r<=t.oldRange.to;this.editor.emit("delete",{type:"node",node:n,from:i,to:r,newFrom:a.mapping.map(i),newTo:a.mapping.map(r),deletedRange:t.oldRange,newRange:t.newRange,partial:!o,editor:this.editor,transaction:e,combinedTransform:a})})});let s=a.mapping;a.steps.forEach((t,n)=>{var i,r;if(t instanceof nn){let o=s.slice(n).map(t.from,-1),l=s.slice(n).map(t.to),d=s.invert().map(o,-1),u=s.invert().map(l),c=o>0&&(null==(i=a.doc.nodeAt(o-1))?void 0:i.marks.some(e=>e.eq(t.mark))),h=null==(r=a.doc.nodeAt(l))?void 0:r.marks.some(e=>e.eq(t.mark));this.editor.emit("delete",{type:"mark",mark:t.mark,from:t.from,to:t.to,deletedRange:{from:d,to:u},newRange:{from:o,to:l},partial:!!(h||c),editor:this.editor,transaction:e,combinedTransform:a})}})};null==(r=null==(i=null==(n=this.editor.options.coreExtensionOptions)?void 0:n.delete)?void 0:i.async)||r?setTimeout(o,0):o()}}),lv=lp.create({name:"drop",addProseMirrorPlugins(){return[new nZ({key:new nQ("tiptapDrop"),props:{handleDrop:(e,t,n,i)=>{this.editor.emit("drop",{editor:this.editor,event:t,slice:n,moved:i})}}})]}}),ly=lp.create({name:"editable",addProseMirrorPlugins(){return[new nZ({key:new nQ("editable"),props:{editable:()=>this.editor.options.editable}})]}}),lb=new nQ("focusEvents"),lx=lp.create({name:"focusEvents",addProseMirrorPlugins(){let{editor:e}=this;return[new nZ({key:lb,props:{handleDOMEvents:{focus:(t,n)=>{e.isFocused=!0;let i=e.state.tr.setMeta("focus",{event:n}).setMeta("addToHistory",!1);return t.dispatch(i),!1},blur:(t,n)=>{e.isFocused=!1;let i=e.state.tr.setMeta("blur",{event:n}).setMeta("addToHistory",!1);return t.dispatch(i),!1}}}})]}}),lw=lp.create({name:"keymap",addKeyboardShortcuts(){let e=()=>this.editor.commands.first(({commands:e})=>[()=>e.undoInputRule(),()=>e.command(({tr:t})=>{let{selection:n,doc:i}=t,{empty:r,$anchor:o}=n,{pos:a,parent:s}=o,l=o.parent.isTextblock&&a>0?t.doc.resolve(a-1):o,d=l.parent.type.spec.isolating,u=o.pos-o.parentOffset,c=d&&1===l.parent.childCount?u===o.pos:nP.atStart(i).from===a;return!!r&&!!s.type.isTextblock&&!s.textContent.length&&!!c&&(!c||"paragraph"!==o.parent.type.name)&&e.clearNodes()}),()=>e.deleteSelection(),()=>e.joinBackward(),()=>e.selectNodeBackward()]),t=()=>this.editor.commands.first(({commands:e})=>[()=>e.deleteSelection(),()=>e.deleteCurrentNode(),()=>e.joinForward(),()=>e.selectNodeForward()]),n={Enter:()=>this.editor.commands.first(({commands:e})=>[()=>e.newlineInCode(),()=>e.createParagraphNear(),()=>e.liftEmptyBlock(),()=>e.splitBlock()]),"Mod-Enter":()=>this.editor.commands.exitCode(),Backspace:e,"Mod-Backspace":e,"Shift-Backspace":e,Delete:t,"Mod-Delete":t,"Mod-a":()=>this.editor.commands.selectAll()},i={...n},r={...n,"Ctrl-h":e,"Alt-Backspace":e,"Ctrl-d":t,"Ctrl-Alt-Backspace":t,"Alt-Delete":t,"Alt-d":t,"Ctrl-a":()=>this.editor.commands.selectTextblockStart(),"Ctrl-e":()=>this.editor.commands.selectTextblockEnd()};return aI()||aU()?r:i},addProseMirrorPlugins(){return[new nZ({key:new nQ("clearDocument"),appendTransaction:(e,t,n)=>{if(e.some(e=>e.getMeta("composition")))return;let i=e.some(e=>e.docChanged)&&!t.doc.eq(n.doc),r=e.some(e=>e.getMeta("preventClearDocument"));if(!i||r)return;let{empty:o,from:a,to:s}=t.selection,l=nP.atStart(t.doc).from,d=nP.atEnd(t.doc).to;
241if(o||a!==l||s!==d||!sR(n.doc))return;let u=n.tr,c=at({state:n,transaction:u}),{commands:h}=new an({editor:this.editor,state:c});if(h.clearNodes(),u.steps.length)return u}})]}}),lC=lp.create({name:"paste",addProseMirrorPlugins(){return[new nZ({key:new nQ("tiptapPaste"),props:{handlePaste:(e,t,n)=>{this.editor.emit("paste",{editor:this.editor,event:t,slice:n})}}})]}}),lS=lp.create({name:"tabindex",addOptions:()=>({value:void 0}),addProseMirrorPlugins(){return[new nZ({key:new nQ("tabindex"),props:{attributes:()=>{var e;return this.editor.isEditable||void 0!==this.options.value?{tabindex:null!=(e=this.options.value)?e:"0"}:{}}}})]}}),l_=lp.create({name:"textDirection",addOptions:()=>({direction:void 0}),addGlobalAttributes(){if(!this.options.direction)return[];let{nodeExtensions:e}=sd(this.extensions);return[{types:e.filter(e=>"text"!==e.name).map(e=>e.name),attributes:{dir:{default:this.options.direction,parseHTML:e=>{let t=e.getAttribute("dir");return t&&("ltr"===t||"rtl"===t||"auto"===t)?t:this.options.direction},renderHTML:e=>e.dir?{dir:e.dir}:{}}}}]},addProseMirrorPlugins(){return[new nZ({key:new nQ("textDirection"),props:{attributes:()=>{let e=this.options.direction;return e?{dir:e}:{}}}})]}}),lk=class e{constructor(e,t,n=!1,i=null){this.currentNode=null,this.actualDepth=null,this.isBlock=n,this.resolvedPos=e,this.editor=t,this.currentNode=i}get name(){return this.node.type.name}get node(){return this.currentNode||this.resolvedPos.node()}get element(){return this.editor.view.domAtPos(this.pos).node}get depth(){var e;return null!=(e=this.actualDepth)?e:this.resolvedPos.depth}get pos(){return this.resolvedPos.pos}get content(){return this.node.content}set content(e){let t=this.from,n=this.to;if(this.isBlock){if(0===this.content.size)return void console.error(`You can\u2019t set content on a block node. Tried to set content on ${this.name} at ${this.pos}`);t=this.from+1,n=this.to-1}this.editor.commands.insertContentAt({from:t,to:n},e)}get attributes(){return this.node.attrs}get textContent(){return this.node.textContent}get size(){return this.node.nodeSize}get from(){return this.isBlock?this.pos:this.resolvedPos.start(this.resolvedPos.depth)}get range(){return{from:this.from,to:this.to}}get to(){return this.isBlock?this.pos+this.size:this.resolvedPos.end(this.resolvedPos.depth)+ +!this.node.isText}get parent(){if(0===this.depth)return null;let t=this.resolvedPos.start(this.resolvedPos.depth-1);return new e(this.resolvedPos.doc.resolve(t),this.editor)}get before(){let t=this.resolvedPos.doc.resolve(this.from-(this.isBlock?1:2));return t.depth!==this.depth&&(t=this.resolvedPos.doc.resolve(this.from-3)),new e(t,this.editor)}get after(){let t=this.resolvedPos.doc.resolve(this.to+(this.isBlock?2:1));return t.depth!==this.depth&&(t=this.resolvedPos.doc.resolve(this.to+3)),new e(t,this.editor)}get children(){let t=[];return this.node.content.forEach((n,i)=>{let r=n.isBlock&&!n.isTextblock,o=n.isAtom&&!n.isText,a=n.isInline,s=this.pos+i+ +!o;if(s<0||s>this.resolvedPos.doc.nodeSize-2)return;let l=this.resolvedPos.doc.resolve(s);if(!r&&!a&&l.depth<=this.depth)return;let d=new e(l,this.editor,r,r||a?n:null);r&&(d.actualDepth=this.depth+1),t.push(d)}),t}get firstChild(){return this.children[0]||null}get lastChild(){let e=this.children;return e[e.length-1]||null}closest(e,t={}){let n=null,i=this.parent;for(;i&&!n;){if(i.node.type.name===e)if(Object.keys(t).length>0){let e=i.node.attrs,n=Object.keys(t);for(let i=0;i<n.length;i+=1){let r=n[i];if(e[r]!==t[r])break}}else n=i;i=i.parent}return n}querySelector(e,t={}){return this.querySelectorAll(e,t,!0)[0]||null}querySelectorAll(e,t={},n=!1){let i=[];if(!this.children||0===this.children.length)return i;let r=Object.keys(t);return this.children.forEach(o=>{n&&i.length>0||(o.node.type.name===e&&r.every(e=>t[e]===o.node.attrs[e])&&i.push(o),n&&i.length>0||(i=i.concat(o.querySelectorAll(e,t,n))))}),i}setAttribute(e){let{tr:t}=this.editor.state;t.setNodeMarkup(this.from,void 0,{...this.node.attrs,...e}),this.editor.view.dispatch(t)}},lM=`.ProseMirror { 242 position: relative; 243} 244 245.ProseMirror { 246 word-wrap: break-word; 247 white-space: pre-wrap; 248 white-space: break-spaces; 249 -webkit-font-variant-ligatures: none; 250 font-variant-ligatures: none; 251 font-feature-settings: "liga" 0; /* the above doesn't seem to work in Edge */ 252} 253 254.ProseMirror [contenteditable="false"] { 255 white-space: normal; 256} 257 258.ProseMirror [contenteditable="false"] [contenteditable="true"] { 259 white-space: pre-wrap; 260} 261 262.ProseMirror pre { 263 white-space: pre-wrap; 264} 265 266img.ProseMirror-separator { 267 display: inline !important; 268 border: none !important; 269 margin: 0 !important; 270 width: 0 !important; 271 height: 0 !important; 272} 273 274.ProseMirror-gapcursor { 275 display: none; 276 pointer-events: none; 277 position: absolute; 278 margin: 0; 279} 280 281.ProseMirror-gapcursor:after {
282 content: ""; 283 display: block; 284 position: absolute; 285 top: -2px; 286 width: 20px; 287 border-top: 1px solid black; 288 animation: ProseMirror-cursor-blink 1.1s steps(2, start) infinite; 289} 290 291@keyframes ProseMirror-cursor-blink { 292 to { 293 visibility: hidden; 294 } 295} 296 297.ProseMirror-hideselection *::selection { 298 background: transparent; 299} 300 301.ProseMirror-hideselection *::-moz-selection { 302 background: transparent; 303} 304 305.ProseMirror-hideselection * { 306 caret-color: transparent; 307} 308 309.ProseMirror-focused .ProseMirror-gapcursor { 310 display: block; 311}`,lT=class extends s5{constructor(e={}){super(),this.css=null,this.className="tiptap",this.editorView=null,this.isFocused=!1,this.destroyed=!1,this.isInitialized=!1,this.extensionStorage={},this.instanceId=Math.random().toString(36).slice(2,9),this.options={element:"u">typeof document?document.createElement("div"):null,content:"",injectCSS:!0,injectNonce:void 0,extensions:[],autofocus:!1,editable:!0,textDirection:void 0,editorProps:{},parseOptions:{},coreExtensionOptions:{},enableInputRules:!0,enablePasteRules:!0,enableCoreExtensions:!0,enableContentCheck:!1,emitContentError:!1,onBeforeCreate:()=>null,onCreate:()=>null,onMount:()=>null,onUnmount:()=>null,onUpdate:()=>null,onSelectionUpdate:()=>null,onTransaction:()=>null,onFocus:()=>null,onBlur:()=>null,onDestroy:()=>null,onContentError:({error:e})=>{throw e},onPaste:()=>null,onDrop:()=>null,onDelete:()=>null,enableExtensionDispatchTransaction:!0},this.isCapturingTransaction=!1,this.capturedTransaction=null,this.utils={getUpdatedPosition:sP,createMappablePosition:sE},this.setOptions(e),this.createExtensionManager(),this.createCommandManager(),this.createSchema(),this.on("beforeCreate",this.options.onBeforeCreate),this.emit("beforeCreate",{editor:this}),this.on("mount",this.options.onMount),this.on("unmount",this.options.onUnmount),this.on("contentError",this.options.onContentError),this.on("create",this.options.onCreate),this.on("update",this.options.onUpdate),this.on("selectionUpdate",this.options.onSelectionUpdate),this.on("transaction",this.options.onTransaction),this.on("focus",this.options.onFocus),this.on("blur",this.options.onBlur),this.on("destroy",this.options.onDestroy),this.on("drop",({event:e,slice:t,moved:n})=>this.options.onDrop(e,t,n)),this.on("paste",({event:e,slice:t})=>this.options.onPaste(e,t)),this.on("delete",this.options.onDelete);const t=this.createDoc(),n=aD(t,this.options.autofocus);this.editorState=nY.create({doc:t,schema:this.schema,selection:n||void 0}),this.options.element&&this.mount(this.options.element)}mount(e){if("u"<typeof document)throw Error("[tiptap error]: The editor cannot be mounted because there is no 'document' defined in this environment.");this.createView(e),this.emit("mount",{editor:this}),this.css&&!document.head.contains(this.css)&&document.head.appendChild(this.css),window.setTimeout(()=>{this.isDestroyed||(!1!==this.options.autofocus&&null!==this.options.autofocus&&this.commands.focus(this.options.autofocus),this.emit("create",{editor:this}),this.isInitialized=!0)},0)}unmount(){if(this.editorView){let e=this.editorView.dom;(null==e?void 0:e.editor)&&delete e.editor,this.editorView.destroy()}if(this.editorView=null,this.isInitialized=!1,this.css&&!document.querySelectorAll(`.${this.className}`).length)try{"function"==typeof this.css.remove?this.css.remove():this.css.parentNode&&this.css.parentNode.removeChild(this.css)}catch(e){console.warn("Failed to remove CSS element:",e)}this.css=null,this.emit("unmount",{editor:this})}get storage(){return this.extensionStorage}get commands(){return this.commandManager.commands}chain(){return this.commandManager.chain()}can(){return this.commandManager.can()}injectCSS(){this.options.injectCSS&&"u">typeof document&&(this.css=s4(lM,this.options.injectNonce))}setOptions(e={}){this.options={...this.options,...e},this.editorView&&this.state&&!this.isDestroyed&&(this.options.editorProps&&this.view.setProps(this.options.editorProps),this.view.updateState(this.state))}setEditable(e,t=!0){this.setOptions({editable:e}),t&&this.emit("update",{editor:this,transaction:this.state.tr,appendedTransactions:[]})}get isEditable(){return this.options.editable&&this.view&&this.view.editable}get view(){return this.editorView?this.editorView:new Proxy({state:this.editorState,updateState:e=>{this.editorState=e},dispatch:e=>{this.dispatchTransaction(e)},composing:!1,dragging:null,editable:!0,isDestroyed:!1},{get:(e,t)=>{if(this.editorView)return this.editorView[t];if("state"===t)return this.editorState;if(t in e)return Reflect.get(e,t);throw Error(`[tiptap error]: The editor view is not available. Cannot access view['${t}']. The editor may not be mounted yet.`)}})}get state(){return this.editorView&&(this.editorState=this.view.state),this.editorState}registerPlugin(e,t){let n=ss(t)?t(e,[...this.state.plugins]):[...this.state.plugins,e],i=this.state.reconfigure({plugins:n});return this.view.updateState(i),i}unregisterPlugin(e){if(this.isDestroyed)return;let t=this.state.plugins,n=t;
311if([].concat(e).forEach(e=>{let t="string"==typeof e?`${e}$`:e.key;n=n.filter(e=>!e.key.startsWith(t))}),t.length===n.length)return;let i=this.state.reconfigure({plugins:n});return this.view.updateState(i),i}createExtensionManager(){var e,t,n,i;let r=[...this.options.enableCoreExtensions?[ly,lf.configure({blockSeparator:null==(t=null==(e=this.options.coreExtensionOptions)?void 0:e.clipboardTextSerializer)?void 0:t.blockSeparator}),lg,lx,lw,lS.configure({value:null==(i=null==(n=this.options.coreExtensionOptions)?void 0:n.tabindex)?void 0:i.value}),lv,lC,lm,l_.configure({direction:this.options.textDirection})].filter(e=>"object"!=typeof this.options.enableCoreExtensions||!1!==this.options.enableCoreExtensions[e.name]):[],...this.options.extensions].filter(e=>["extension","node","mark"].includes(null==e?void 0:e.type));this.extensionManager=new lh(r,this)}createCommandManager(){this.commandManager=new an({editor:this})}createSchema(){this.schema=this.extensionManager.schema}createDoc(){let e;try{e=a9(this.options.content,this.schema,this.options.parseOptions,{errorOnInvalidContent:this.options.enableContentCheck})}catch(t){if(!(t instanceof Error)||!["[tiptap error]: Invalid JSON content","[tiptap error]: Invalid HTML content"].includes(t.message))throw t;this.emit("contentError",{editor:this,error:t,disableCollaboration:()=>{"collaboration"in this.storage&&"object"==typeof this.storage.collaboration&&this.storage.collaboration&&(this.storage.collaboration.isDisabled=!0),this.options.extensions=this.options.extensions.filter(e=>"collaboration"!==e.name),this.createExtensionManager()}}),e=a9(this.options.content,this.schema,this.options.parseOptions,{errorOnInvalidContent:!1})}return e}createView(e){let{editorProps:t,enableExtensionDispatchTransaction:n}=this.options,i=t.dispatchTransaction||this.dispatchTransaction.bind(this),r=n?this.extensionManager.dispatchTransaction(i):i,o=t.transformPastedHTML,a=this.extensionManager.transformPastedHTML(o);this.editorView=new oq(e,{...t,attributes:{role:"textbox",...null==t?void 0:t.attributes},dispatchTransaction:r,transformPastedHTML:a,state:this.editorState,markViews:this.extensionManager.markViews,nodeViews:this.extensionManager.nodeViews});let s=this.state.reconfigure({plugins:this.extensionManager.plugins});this.view.updateState(s),this.prependClass(),this.injectCSS(),this.view.dom.editor=this}createNodeViews(){this.view.isDestroyed||this.view.setProps({markViews:this.extensionManager.markViews,nodeViews:this.extensionManager.nodeViews})}prependClass(){this.view.dom.className=`${this.className} ${this.view.dom.className}`}captureTransaction(e){this.isCapturingTransaction=!0,e(),this.isCapturingTransaction=!1;let t=this.capturedTransaction;return this.capturedTransaction=null,t}dispatchTransaction(e){if(this.view.isDestroyed)return;if(this.isCapturingTransaction){if(!this.capturedTransaction){this.capturedTransaction=e;return}e.steps.forEach(e=>{var t;return null==(t=this.capturedTransaction)?void 0:t.step(e)});return}let{state:t,transactions:n}=this.state.applyTransaction(e),i=!this.state.selection.eq(t.selection),r=n.includes(e),o=this.state;if(this.emit("beforeTransaction",{editor:this,transaction:e,nextState:t}),!r)return;this.view.updateState(t),this.emit("transaction",{editor:this,transaction:e,appendedTransactions:n.slice(1)}),i&&this.emit("selectionUpdate",{editor:this,transaction:e});let a=n.findLast(e=>e.getMeta("focus")||e.getMeta("blur")),s=null==a?void 0:a.getMeta("focus"),l=null==a?void 0:a.getMeta("blur");s&&this.emit("focus",{editor:this,event:s.event,transaction:a}),l&&this.emit("blur",{editor:this,event:l.event,transaction:a}),e.getMeta("preventUpdate")||!n.some(e=>e.docChanged)||o.doc.eq(t.doc)||this.emit("update",{editor:this,transaction:e,appendedTransactions:n.slice(1)})}getAttributes(e){return sw(this.state,e)}isActive(e,t){let n="string"==typeof e?e:null,i="string"==typeof e?t:e;return function(e,t,n={}){if(!t)return aK(e,null,n)||sM(e,null,n);let i=aQ(t,e.schema);return"node"===i?aK(e,t,n):"mark"===i&&sM(e,t,n)}(this.state,n,i)}getJSON(){return this.state.doc.toJSON()}
311getHTML(){return sa(this.state.doc.content,this.schema)}getText(e){var t,n;let i,{blockSeparator:r="\n\n",textSerializers:o={}}=e||{};return t=this.state.doc,n={blockSeparator:r,textSerializers:{...sx(this.schema),...o}},i={from:0,to:t.content.size},sb(t,i,n)}get isEmpty(){return sR(this.state.doc)}destroy(){this.destroyed||(this.destroyed=!0,this.emit("destroy"),this.unmount(),this.removeAllListeners(),this.extensionManager.destroy(),this.extensionManager=null,this.schema=null,this.commandManager=null,this.extensionStorage={})}get isDestroyed(){var e,t;return null==(t=null==(e=this.editorView)?void 0:e.isDestroyed)||t}$node(e,t){var n;return(null==(n=this.$doc)?void 0:n.querySelector(e,t))||null}$nodes(e,t){var n;return(null==(n=this.$doc)?void 0:n.querySelectorAll(e,t))||null}$pos(e){let t=this.state.doc.resolve(e),n=e>0&&t.nodeAfter&&!t.nodeAfter.isText?t.nodeAfter:null;return new lk(t,this,!1,n)}get $doc(){return this.$pos(0)}};function lD(e){return new la({find:e.find,handler:({state:t,range:n,match:i})=>{let r=sl(e.getAttributes,void 0,i);if(!1===r||null===r)return null;let{tr:o}=t,a=i[i.length-1],s=i[0];if(a){let i=s.search(/\S/),l=n.from+s.indexOf(a),d=l+a.length;if(sS(n.from,n.to,t.doc).filter(t=>t.mark.type.excluded.find(n=>n===e.type&&n!==t.mark.type)).filter(e=>e.to>l).length)return null;
311d<n.to&&o.delete(d,n.to),l>n.from&&o.delete(n.from+i,l);let u=n.from+i+a.length;o.addMark(n.from+i,u,e.type.create(r||{})),o.removeStoredMark(e.type)}},undoable:e.undoable})}function lR(e){return new la({find:e.find,handler:({state:t,range:n,match:i})=>{let r=t.doc.resolve(n.from),o=sl(e.getAttributes,void 0,i)||{};if(!r.node(-1).canReplaceWith(r.index(-1),r.indexAfter(-1),e.type))return null;t.tr.delete(n.from,n.to).setBlockType(n.from,n.from,e.type,o)},undoable:e.undoable})}function lI(e){return new la({find:e.find,handler:({state:t,range:n,match:i,chain:r})=>{let o=sl(e.getAttributes,void 0,i)||{},a=t.tr.delete(n.from,n.to),s=a.doc.resolve(n.from).blockRange(),l=s&&nu(s,e.type,o);if(!l)return null;if(a.wrap(s,l),e.keepMarks&&e.editor){let{selection:n,storedMarks:i}=t,{splittableMarks:r}=e.editor.extensionManager,o=i||n.$to.parentOffset&&n.$from.marks();if(o){let e=o.filter(e=>r.includes(e.type.name));a.ensureMarks(e)}}if(e.keepAttributes){let t="bulletList"===e.type.name||"orderedList"===e.type.name?"listItem":"taskList";r().updateAttributes(t,o).run()}let d=a.doc.resolve(n.from-1).nodeBefore;d&&d.type===e.type&&ng(a.doc,n.from-1)&&(!e.joinPredicate||e.joinPredicate(i,d))&&a.join(n.from-1)},undoable:e.undoable})}var lA=class e extends ll{constructor(){super(...arguments),this.type="node"}static create(t={}){return new e("function"==typeof t?t():t)}configure(e){return super.configure(e)}extend(e){let t="function"==typeof e?e():e;return super.extend(t)}};function lP(e){return new lu({find:e.find,handler:({state:t,range:n,match:i,pasteEvent:r})=>{let o=sl(e.getAttributes,void 0,i,r);if(!1===o||null===o)return null;let{tr:a}=t,s=i[i.length-1],l=i[0],d=n.to;if(s){let r=l.search(/\S/),u=n.from+l.indexOf(s),c=u+s.length;if(sS(n.from,n.to,t.doc).filter(t=>t.mark.type.excluded.find(n=>n===e.type&&n!==t.mark.type)).filter(e=>e.to>u).length)return null;c<n.to&&a.delete(c,n.to),u>n.from&&a.delete(n.from+r,u),d=n.from+r+s.length,a.addMark(n.from+r,d,e.type.create(o||{})),void 0!==i.index&&void 0!==i.input&&i.index+i[0].length>=i.input.length||a.removeStoredMark(e.type)}}})}let{getOwnPropertyNames:lE,getOwnPropertySymbols:lL}=Object,{hasOwnProperty:lF}=Object.prototype;function lO(e,t){return function(n,i,r){return e(n,i,r)&&t(n,i,r)}}function lN(e){return function(t,n,i){if(!t||!n||"object"!=typeof t||"object"!=typeof n)return e(t,n,i);let{cache:r}=i,o=r.get(t),a=r.get(n);if(o&&a)return o===n&&a===t;r.set(t,n),r.set(n,t);let s=e(t,n,i);return r.delete(t),r.delete(n),s}}function lB(e){return lE(e).concat(lL(e))}let lz=Object.hasOwn||((e,t)=>lF.call(e,t));function lj(e,t){return e===t||!e&&!t&&e!=e&&t!=t}let{getOwnPropertyDescriptor:lV,keys:lH}=Object;function lG(e,t){return e.byteLength===t.byteLength&&l1(new Uint8Array(e),new Uint8Array(t))}function lW(e,t,n){let i=e.length;if(t.length!==i)return!1;for(;i-- >0;)if(!n.equals(e[i],t[i],i,i,e,t,n))return!1;return!0}function l$(e,t){return e.byteLength===t.byteLength&&l1(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function lU(e,t){return lj(e.getTime(),t.getTime())}function lq(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function lK(e,t){return e===t}function lY(e,t,n){let i,r,o=e.size;if(o!==t.size)return!1;if(!o)return!0;let a=Array(o),s=e.entries(),l=0;for(;(i=s.next())&&!i.done;){let o=t.entries(),s=!1,d=0;for(;(r=o.next())&&!r.done;){if(a[d]){d++;continue}let o=i.value,u=r.value;if(n.equals(o[0],u[0],l,d,e,t,n)&&n.equals(o[1],u[1],o[0],u[0],e,t,n)){s=a[d]=!0;break}d++}if(!s)return!1;l++}return!0}function lZ(e,t,n){let i=lH(e),r=i.length;if(lH(t).length!==r)return!1;for(;r-- >0;)if(!l3(e,t,n,i[r]))return!1;return!0}function lX(e,t,n){let i,r,o,a=lB(e),s=a.length;if(lB(t).length!==s)return!1;for(;s-- >0;)if(!l3(e,t,n,i=a[s])||(r=lV(e,i),o=lV(t,i),(r||o)&&(!r||!o||r.configurable!==o.configurable||r.enumerable!==o.enumerable||r.writable!==o.writable)))return!1;return!0}function lJ(e,t){return lj(e.valueOf(),t.valueOf())}function lQ(e,t){return e.source===t.source&&e.flags===t.flags}function l0(e,t,n){let i,r,o=e.size;if(o!==t.size)return!1;if(!o)return!0;let a=Array(o),s=e.values();for(;(i=s.next())&&!i.done;){let o=t.values(),s=!1,l=0;for(;(r=o.next())&&!r.done;){if(!a[l]&&n.equals(i.value,r.value,i.value,r.value,e,t,n)){s=a[l]=!0;break}l++}if(!s)return!1}return!0}function l1(e,t){let n=e.byteLength;if(t.byteLength!==n||e.byteOffset!==t.byteOffset)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}function l2(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function l3(e,t,n,i){return("_owner"===i||"__o"===i||"__v"===i)&&(!!e.$$typeof||!!t.$$typeof)||lz(t,i)&&n.equals(e[i],t[i],i,i,e,t,n)}let l5={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float16Array]":!0,"[object Float32Array]":!0,"[object Float64Array
311]":!0,"[object BigInt64Array]":!0,"[object BigUint64Array]":!0},l4=Object.prototype.toString,l6=l8();function l8(e={}){let{circular:t=!1,createInternalComparator:n,createState:i,strict:r=!1}=e,o=function({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:n,areDatesEqual:i,areErrorsEqual:r,areFunctionsEqual:o,areMapsEqual:a,areNumbersEqual:s,areObjectsEqual:l,arePrimitiveWrappersEqual:d,areRegExpsEqual:u,areSetsEqual:c,areTypedArraysEqual:h,areUrlsEqual:p,unknownTagComparators:f}){return function(g,m,v){if(g===m)return!0;if(null==g||null==m)return!1;let y=typeof g;if(y!==typeof m)return!1;if("object"!==y)return"number"===y?s(g,m,v):"function"===y&&o(g,m,v);let b=g.constructor;if(b!==m.constructor)return!1;if(b===Object)return l(g,m,v);if(Array.isArray(g))return t(g,m,v);if(b===Date)return i(g,m,v);if(b===RegExp)return u(g,m,v);if(b===Map)return a(g,m,v);if(b===Set)return c(g,m,v);let x=l4.call(g);if("[object Date]"===x)return i(g,m,v);if("[object RegExp]"===x)return u(g,m,v);if("[object Map]"===x)return a(g,m,v);if("[object Set]"===x)return c(g,m,v);if("[object Object]"===x)return"function"!=typeof g.then&&"function"!=typeof m.then&&l(g,m,v);if("[object URL]"===x)return p(g,m,v);if("[object Error]"===x)return r(g,m,v);if("[object Arguments]"===x)return l(g,m,v);if(l5[x])return h(g,m,v);if("[object ArrayBuffer]"===x)return e(g,m,v);if("[object DataView]"===x)return n(g,m,v);if("[object Boolean]"===x||"[object Number]"===x||"[object String]"===x)return d(g,m,v);if(f){let e=f[x];if(!e){let t=null!=g?g[Symbol.toStringTag]:void 0;t&&(e=f[t])}if(e)return e(g,m,v)}return!1}}(function({circular:e,createCustomConfig:t,strict:n}){let i={areArrayBuffersEqual:lG,areArraysEqual:n?lX:lW,areDataViewsEqual:l$,areDatesEqual:lU,areErrorsEqual:lq,areFunctionsEqual:lK,areMapsEqual:n?lO(lY,lX):lY,areNumbersEqual:lj,areObjectsEqual:n?lX:lZ,arePrimitiveWrappersEqual:lJ,areRegExpsEqual:lQ,areSetsEqual:n?lO(l0,lX):l0,areTypedArraysEqual:n?lO(l1,lX):l1,areUrlsEqual:l2,unknownTagComparators:void 0};if(t&&(i=Object.assign({},i,t(i))),e){let e=lN(i.areArraysEqual),t=lN(i.areMapsEqual),n=lN(i.areObjectsEqual),r=lN(i.areSetsEqual);i=Object.assign({},i,{areArraysEqual:e,areMapsEqual:t,areObjectsEqual:n,areSetsEqual:r})}return i}(e)),a=n?n(o):function(e,t,n,i,r,a,s){return o(e,t,s)};return function({circular:e,comparator:t,createState:n,equals:i,strict:r}){if(n)return function(o,a){let{cache:s=e?new WeakMap:void 0,meta:l}=n();return t(o,a,{cache:s,equals:i,meta:l,strict:r})};if(e)return function(e,n){return t(e,n,{cache:new WeakMap,equals:i,meta:void 0,strict:r})};let o={cache:void 0,equals:i,meta:void 0,strict:r};return function(e,n){return t(e,n,o)}}({circular:t,comparator:o,createState:i,equals:a,strict:r})}l8({strict:!0}),l8({circular:!0}),l8({circular:!0,strict:!0}),l8({createInternalComparator:()=>lj}),l8({strict:!0,createInternalComparator:()=>lj}),l8({circular:!0,createInternalComparator:()=>lj}),l8({circular:!0,createInternalComparator:()=>lj,strict:!0}),e.s(["deepEqual",()=>l6],44505);var l7=e.i(35686),l9=({contentComponent:e})=>{let t=(0,tr.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getServerSnapshot);return(0,a.jsx)(a.Fragment,{children:Object.values(t)})},de=class extends tn.default.Component{constructor(e){super(e),this.editorContentRef=tn.default.createRef()}componentDidMount(){this.init()}componentDidUpdate(){this.init()}init(){var e;let t=this.props.editor;if(t&&!t.isDestroyed&&(null==(e=t.view.dom)?void 0:e.parentNode)){let e,n;if(t.contentComponent)return;let i=this.editorContentRef.current;i.append(...t.view.dom.parentNode.childNodes),t.setOptions({element:i}),e=new Set,n={},t.contentComponent={subscribe:t=>(e.add(t),()=>{e.delete(t)}),getSnapshot:()=>n,getServerSnapshot:()=>n,setRenderer(t,i){n={...n,[t]:ti.default.createPortal(i.reactElement,i.element,t)},e.forEach(e=>e())},removeRenderer(t){let i={...n};delete i[t],n=i,e.forEach(e=>e())}},t.createNodeViews(),t.isEditorContentInitialized=!0,this.forceUpdate()}}componentWillUnmount(){var e;let t=this.props.editor;if(t){t.isEditorContentInitialized=!1,t.isDestroyed||t.view.setProps({nodeViews:{}}),t.contentComponent=null;try{if(!(null==(e=t.view.dom)?void 0:e.parentNode))return;let n=document.createElement("div");n.append(...t.view.dom.parentNode.childNodes),t.setOptions({element:n})}catch{}}}render(){let{editor:e,innerRef:t,...n}=this.props;return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{ref:((...e)=>t=>
311{e.forEach(e=>{"function"==typeof e?e(t):e&&(e.current=t)})})(t,this.editorContentRef),...n}),(null==e?void 0:e.contentComponent)&&(0,a.jsx)(l9,{contentComponent:e.contentComponent})]})}},dt=(0,tn.forwardRef)((e,t)=>{let n=tn.default.useMemo(()=>Math.floor(0xffffffff*Math.random()).toString(),[e.editor]);return tn.default.createElement(de,{key:n,innerRef:t,...e})}),dn=tn.default.memo(dt),di="u">typeof window?tn.useLayoutEffect:tn.useEffect,dr=class{constructor(e){this.transactionNumber=0,this.lastTransactionNumber=0,this.subscribers=new Set,this.editor=e,this.lastSnapshot={editor:e,transactionNumber:0},this.getSnapshot=this.getSnapshot.bind(this),this.getServerSnapshot=this.getServerSnapshot.bind(this),this.watch=this.watch.bind(this),this.subscribe=this.subscribe.bind(this)}getSnapshot(){return this.transactionNumber===this.lastTransactionNumber||(this.lastTransactionNumber=this.transactionNumber,this.lastSnapshot={editor:this.editor,transactionNumber:this.transactionNumber}),this.lastSnapshot}getServerSnapshot(){return{editor:null,transactionNumber:0}}subscribe(e){return this.subscribers.add(e),()=>{this.subscribers.delete(e)}}watch(e){if(this.editor=e,this.editor){let e=()=>{this.transactionNumber+=1,this.subscribers.forEach(e=>e())},t=this.editor;return t.on("transaction",e),()=>{t.off("transaction",e)}}}},da="u"<typeof window,ds=da||!!("u">typeof window&&window.next),dl=class e{constructor(e){this.editor=null,this.subscriptions=new Set,this.isComponentMounted=!1,this.previousDeps=null,this.instanceId="",this.options=e,this.subscriptions=new Set,this.setEditor(this.getInitialEditor()),this.scheduleDestroy(),this.getEditor=this.getEditor.bind(this),this.getServerSnapshot=this.getServerSnapshot.bind(this),this.subscribe=this.subscribe.bind(this),this.refreshEditorInstance=this.refreshEditorInstance.bind(this),this.scheduleDestroy=this.scheduleDestroy.bind(this),this.onRender=this.onRender.bind(this),this.createEditor=this.createEditor.bind(this)}setEditor(e){this.editor=e,this.instanceId=Math.random().toString(36).slice(2,9),this.subscriptions.forEach(e=>e())}getInitialEditor(){let e=this.options.current.immediatelyRender,t=null==e||e;return da?t=!1:ds&&void 0===e&&(t=!1),t?this.createEditor():null}createEditor(){return new lT({...this.options.current,onBeforeCreate:(...e)=>{var t,n;return null==(n=(t=this.options.current).onBeforeCreate)?void 0:n.call(t,...e)},onBlur:(...e)=>{var t,n;return null==(n=(t=this.options.current).onBlur)?void 0:n.call(t,...e)},onCreate:(...e)=>{var t,n;return null==(n=(t=this.options.current).onCreate)?void 0:n.call(t,...e)},onDestroy:(...e)=>{var t,n;return null==(n=(t=this.options.current).onDestroy)?void 0:n.call(t,...e)},onFocus:(...e)=>{var t,n;return null==(n=(t=this.options.current).onFocus)?void 0:n.call(t,...e)},onSelectionUpdate:(...e)=>{var t,n;return null==(n=(t=this.options.current).onSelectionUpdate)?void 0:n.call(t,...e)},onTransaction:(...e)=>{var t,n;return null==(n=(t=this.options.current).onTransaction)?void 0:n.call(t,...e)},onUpdate:(...e)=>{var t,n;return null==(n=(t=this.options.current).onUpdate)?void 0:n.call(t,...e)},onContentError:(...e)=>{var t,n;return null==(n=(t=this.options.current).onContentError)?void 0:n.call(t,...e)},onDrop:(...e)=>{var t,n;return null==(n=(t=this.options.current).onDrop)?void 0:n.call(t,...e)},onPaste:(...e)=>{var t,n;return null==(n=(t=this.options.current).onPaste)?void 0:n.call(t,...e)},onDelete:(...e)=>{var t,n;return null==(n=(t=this.options.current).onDelete)?void 0:n.call(t,...e)}})}getEditor(){return this.editor}getServerSnapshot(){return null}subscribe(e){return this.subscriptions.add(e),()=>{this.subscriptions.delete(e)}}static compareOptions(e,t){return Object.keys(e).every(n=>!!["onCreate","onBeforeCreate","onDestroy","onUpdate","onTransaction","onFocus","onBlur","onSelectionUpdate","onContentError","onDrop","onPaste"].includes(n)||("extensions"===n&&e.extensions&&t.extensions?e.extensions.length===t.extensions.length&&e.extensions.every((e,n)=>{var i;return e===(null==(i=t.extensions)?void 0:i[n])}):e[n]===t[n]))}onRender(t){return()=>(this.isComponentMounted=!0,clearTimeout(this.scheduledDestructionTimeout),this.editor&&!this.editor.isDestroyed&&0===t.length?e.compareOptions(this.options.current,this.editor.options)||this.editor.setOptions({...this.options.current,editable:this.editor.isEditable}):this.refreshEditorInstance(t),()=>{this.isComponentMounted=!1,this.scheduleDestroy()})}refreshEditorInstance(e){if(this.editor&&!this.editor.isDestroyed){
311if(null===this.previousDeps){this.previousDeps=e;return}if(this.previousDeps.length===e.length&&this.previousDeps.every((t,n)=>t===e[n]))return}this.editor&&!this.editor.isDestroyed&&this.editor.destroy(),this.setEditor(this.createEditor()),this.previousDeps=e}scheduleDestroy(){let e=this.instanceId,t=this.editor;this.scheduledDestructionTimeout=setTimeout(()=>{if(this.isComponentMounted&&this.instanceId===e){t&&t.setOptions(this.options.current);return}t&&!t.isDestroyed&&(t.destroy(),this.instanceId===e&&this.setEditor(null))},1)}},dd=(0,tn.createContext)({editor:null});dd.Consumer;var du=(0,tn.createContext)({onDragStart:()=>{},nodeViewContentChildren:void 0,nodeViewContentRef:()=>{}});tn.default.forwardRef((e,t)=>{let{onDragStart:n}=(0,tn.useContext)(du),i=e.as||"div";return(0,a.jsx)(i,{...e,ref:t,"data-node-view-wrapper":"",onDragStart:n,style:{whiteSpace:"normal",...e.style}})}),tn.default.createContext({markViewContentRef:()=>{}});var dc=(0,tn.createContext)({get editor(){throw Error("useTiptap must be used within a <Tiptap> provider")}});function dh({editor:e,instance:t,children:n}){let i=null!=e?e:t;if(!i)throw Error("Tiptap: An editor instance is required. Pass a non-null `editor` prop.");let r=(0,tn.useMemo)(()=>({editor:i}),[i]),o=(0,tn.useMemo)(()=>({editor:i}),[i]);return(0,a.jsx)(dd.Provider,{value:o,children:(0,a.jsx)(dc.Provider,{value:r,children:n})})}function dp({...e}){let{editor:t}=(0,tn.useContext)(dc);return(0,a.jsx)(dn,{editor:t,...e})}dc.displayName="TiptapContext",dh.displayName="Tiptap",dp.displayName="Tiptap.Content",Object.assign(dh,{Content:dp});var df={root:"m_d08caa0"};let dg=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("Typography",null,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,attributes:d,...u}=n,c=(0,x.useStyles)({name:"Typography",classes:df,props:n,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:d});return(0,a.jsx)(w.Box,{ref:t,...c("root"),...u})});dg.classes=df,dg.displayName="@mantine/core/Typography";let dm=(0,C.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:s,...l}=(0,b.useProps)("RichTextEditorContent",null,e),d=e9();return d.withTypographyStyles?(0,a.jsx)(dg,{...d.getStyles("Typography",{className:i,style:r,styles:o,classNames:n}),unstyled:d.unstyled,ref:t,children:(0,a.jsx)(w.Box,{component:dn,editor:d.editor,...d.getStyles("content",{classNames:n,styles:o}),...l})}):(0,a.jsx)(w.Box,{component:dn,editor:d.editor,...d.getStyles("content",{classNames:n,styles:o,className:i,style:r}),...l})});function dv(e){return(0,a.jsx)("svg",{...e,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"})}function dy(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M7 5h6a3.5 3.5 0 0 1 0 7h-6z"}),(0,a.jsx)("path",{d:"M13 12h1a3.5 3.5 0 0 1 0 7h-7v-7"})]})}function db(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M11 5l6 0"}),(0,a.jsx)("path",{d:"M7 19l6 0"}),(0,a.jsx)("path",{d:"M14 5l-4 14"})]})}function dx(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M7 5v5a5 5 0 0 0 10 0v-5"}),(0,a.jsx)("path",{d:"M5 19h14"})]})}function dw(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M5 12l14 0"}),(0,a.jsx)("path",{d:"M16 6.5a4 2 0 0 0 -4 -1.5h-1a3.5 3.5 0 0 0 0 7h2a3.5 3.5 0 0 1 0 7h-1.5a4 2 0 0 1 -4 -1.5"})]})}function dC(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M17 15l4 4m0 -4l-4 4"}),(0,a.jsx)("path",{d:"M7 6v-1h11v1"}),(0,a.jsx)("path",{d:"M7 19l4 0"}),(0,a.jsx)("path",{d:"M13 5l-4 14"})]})}function dS(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M19 18v-8l-2 2"}),(0,a.jsx)("path",{d:"M4 6v12"}),(0,a.jsx)("path",{d:"M12 6v12"}),(0,a.jsx)("path",{d:"M11 18h2"}),(0,a.jsx)("path",{d:"M3 18h2"}),(0,a.jsx)("path",{d:"M4 12h8"}),(0,a.jsx)("path",{d:"M3 6h2"}),(0,a.jsx)("path",{d:"M11 6h2"})]})}function d_(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M17 12a2 2 0 1 1 4 0c0 .591 -.417 1.318 -.816 1.858l-3.184 4.143l4 0"}),(0,a.jsx)("path",{d:"M4 6v12"}),(0,a.jsx)("path",{d:"M12 6v12"}),(0,a.jsx)("path",{d:"M11 18h2"}),(0,a.jsx)("path",{d:"M3 18h2"}),(0,a.jsx)("path",{d:"M4 12h8"}),(0,a.jsx)("path",{d:"M3 6h2"}),(0,a.jsx)("path",{d:"M11 6h2"})]})}function dk(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M19 14a2 2 0 1 0 -2 -2"}),(0,a.jsx)("path",{d:"M17 16a2 2 0 1 0 2 -2"}),(0,a.jsx)("path",{d:"M4 6v12"}),(0,a.jsx)("path",{d:"M12 6v12"}),(0,a.jsx)("path",{d:"M11 18h2"}),(0,a.jsx)("path",{d:"M3 18h2"}),(0,a.jsx)("path",{d:"M4 12h8"}),(0,a.jsx)("path",{d:"M3 6h2"}),(0,a.jsx)("path",{d:"M11 6h2"})]})}function dM(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M20 18v-8l-4 6h5"}),(0,a.jsx)("path",{d:"M4 6v12"}),(0,a.jsx)("path",{d:"M12 6v12"}),(0,a.jsx)("path",{d:"M11 18h2"}),(0,a.jsx)("path",{d:"M3 18h2"}),(0,a.jsx)("path",{d:"M4 12h8"}),(0,a.jsx)("path",{d:"M3 6h2"}),(0,a.jsx)("path",{d:"M11 6h2"})]})}function dT(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M17 18h2a2 2 0 1 0 0 -4h-2v-4h4"}),(0,a.jsx)("path",{d:"M4 6v12"}),(0,a.jsx)("path",{d:"M12 6v12"}),(0,a.jsx)("path",{d:"M11 18h2"}),(0,a.jsx)("path",{d:"M3 18h2"}),(0,a.jsx)("path",{d:"M4 12h8"}),(0,a.jsx)("path",{d:"M3 6h2"}),(0,a.jsx)("path",{d:"M11 6h2"})]})}function dD(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M19 14a2 2 0 1 0 0 4a2 2 0 0 0 0 -4z"}),(0,a.jsx)("path",{d:"M21 12a2 2 0 1 0 -4 0v4"}),(0,a.jsx)("path",{d:"M4 6v12"}),(0,a.jsx)("path",{d:"M12 6v12"}),(0,a.jsx)("path",{d:"M11 18h2"}),(0,a.jsx)("path",{d:"M3 18h2"}),(0,a.jsx)("path",{d:"M4 12h8"}),(0,a.jsx)("path",{d:"M3 6h2"}),(0,a.jsx)("path",{d:"M11 6h2"})]})}function dR(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M9 6l11 0"}),(0,a.jsx)("path",{d:"M9 12l11 0"}),(0,a.jsx)("path",{d:"M9 18l11 0"}),(0,a.jsx)("path",{d:"M5 6l0 .01"}),(0,a.jsx)("path",{d:"M5 12l0 .01"}),(0,a.jsx)("path",{d:"M5 18l0 .01"})]})}function dI(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M11 6h9"}),(0,a.jsx)("path",{d:"M11 12h9"}),(0,a.jsx)("path",{d:"M12 18h8"}),(0,a.jsx)("path",{d:"M4 16a2 2 0 1 1 4 0c0 .591 -.5 1 -1 1.5l-3 2.5h4"}),(0,a.jsx)("path",{d:"M6 10v-6l-2 2"})]})}function dA(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M17 22v-2"}),(0,a.jsx)("path",{d:"M9 15l6 -6"}),(0,a.jsx)("path",{d:"M11 6l.463 -.536a5 5 0 0 1 7.071 7.072l-.534 .464"}),(0,a.jsx)("path",{d:"M13 18l-.397 .534a5.068 5.068 0 0 1 -7.127 0a4.972 4.972 0 0 1 0 -7.071l.524 -.463"}),(0,a.jsx)("path",{d:"M20 17h2"}),(0,a.jsx)("path",{d:"M2 7h2"}),(0,a.jsx)("path",{d:"M7 2v2"})]})}function dP(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M6 15h15"}),(0,a.jsx)("path",{d:"M21 19h-15"}),(0,a.jsx)("path",{d:"M15 11h6"}),(0,a.jsx)("path",{d:"M21 7h-6"}),(0,a.jsx)("path",{d:"M9 9h1a1 1 0 1 1 -1 1v-2.5a2 2 0 0 1 2 -2"}),(0,a.jsx)("path",{d:"M3 9h1a1 1 0 1 1 -1 1v-2.5a2 2 0 0 1 2 -2"})]})}function dE(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M4 6l16 0"}),(0,a.jsx)("path",{d:"M4 12l10 0"}),(0,a.jsx)("path",{d:"M4 18l14 0"})]})}function dL(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M4 6l16 0"}),(0,a.jsx)("path",{d:"M10 12l10 0"}),(0,a.jsx)("path",{d:"M6 18l14 0"})]})}function dF(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M4 6l16 0"}),(0,a.jsx)("path",{d:"M8 12l8 0"}),(0,a.jsx)("path",{d:"M6 18l12 0"})]})}function dO(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M4 6l16 0"}),(0,a.jsx)("path",{d:"M4 12l16 0"}),(0,a.jsx)("path",{d:"M4 18l12 0"})]})}function dN(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M5 7l8 10m-8 0l8 -10"}),(0,a.jsx)("path",{d:"M21 20h-4l3.5 -4a1.73 1.73 0 0 0 -3.5 -2"})]})}function dB(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M5 7l8 10m-8 0l8 -10"}),(0,a.jsx)("path",{d:"M21 11h-4l3.5 -4a1.73 1.73 0 0 0 -3.5 -2"})]})}function dz(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M7 8l-4 4l4 4"}),(0,a.jsx)("path",{d:"M17 8l4 4l-4 4"}),(0,a.jsx)("path",{d:"M14 4l-4 16"})]})}function dj(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M3 19h4l10.5 -10.5a2.828 2.828 0 1 0 -4 -4l-10.5 10.5v4"}),(0,a.jsx)("path",{d:"M12.5 5.5l4 4"}),(0,a.jsx)("path",{d:"M4.5 13.5l4 4"}),(0,a.jsx)("path",{d:"M21 15v4h-8l4 -4z"})]})}function dV(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M5 12h2"}),(0,a.jsx)("path",{d:"M17 12h2"}),(0,a.jsx)("path",{d:"M11 12h2"})]})}function dH(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M20.042 16.045a9 9 0 0 0 -12.087 -12.087m-2.318 1.677a9 9 0 1 0 12.725 12.73"}),(0,a.jsx)("path",{d:"M3 3l18 18"})]})}function dG(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M11 7l6 6"}),(0,a.jsx)("path",{d:"M4 16l11.7 -11.7a1 1 0 0 1 1.4 0l2.6 2.6a1 1 0 0 1 0 1.4l-11.7 11.7h-4v-4z"})]})}function dW(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M18 6l-12 12"}),(0,a.jsx)("path",{d:"M6 6l12 12"})]})}function d$(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M12 21a9 9 0 0 1 0 -18c4.97 0 9 3.582 9 8c0 1.06 -.474 2.078 -1.318 2.828c-.844 .75 -1.989 1.172 -3.182 1.172h-2.5a2 2 0 0 0 -1 3.75a1.3 1.3 0 0 1 -1 2.25"}),(0,a.jsx)("path",{d:"M8.5 10.5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"}),(0,a.jsx)("path",{d:"M12.5 7.5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"}),(0,a.jsx)("path",{d:"M16.5 10.5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"})]})}function dU(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M5 12l5 5l10 -10"})]})}function dq(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M9 15l6 -6"}),(0,a.jsx)("path",{d:"M11 6l.463 -.536a5 5 0 0 1 7.071 7.072l-.534 .464"}),(0,a.jsx)("path",{d:"M13 18l-.397 .534a5.068 5.068 0 0 1 -7.127 0a4.972 4.972 0 0 1 0 -7.071l.524 -.463"})]})}function dK(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M12 6h-6a2 2 0 0 0 -2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-6"}),(0,a.jsx)("path",{d:"M11 13l9 -9"}),(0,a.jsx)("path",{d:"M15 4h5v5"})]})}function dY(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M9 14l-4 -4l4 -4"}),(0,a.jsx)("path",{d:"M5 10h11a4 4 0 1 1 0 8h-1"})]})}function dZ(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M15 14l4 -4l-4 -4"}),(0,a.jsx)("path",{d:"M19 10h-11a4 4 0 1 0 0 8h1"})]})}function dX(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M3.5 5.5l1.5 1.5l2.5 -2.5"}),(0,a.jsx)("path",{d:"M3.5 11.5l1.5 1.5l2.5 -2.5"}),(0,a.jsx)("path",{d:"M3.5 17.5l1.5 1.5l2.5 -2.5"}),(0,a.jsx)("path",{d:"M11 6l9 0"}),(0,a.jsx)("path",{d:"M11 12l9 0"}),(0,a.jsx)("path",{d:"M11 18l9 0"})]})}function dJ(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M20 6l-11 0"}),(0,a.jsx)("path",{d:"M20 12l-7 0"}),(0,a.jsx)("path",{d:"M20 18l-11 0"}),(0,a.jsx)("path",{d:"M4 8l4 4l-4 4"})]})}function dQ(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M20 6l-7 0"}),(0,a.jsx)("path",{d:"M20 12l-9 0"}),(0,a.jsx)("path",{d:"M20 18l-7 0"}),(0,a.jsx)("path",{d:"M8 8l-4 4l4 4"})]})}function d0(e){return(0,a.jsxs)(dv,{...e,children:[(0,a.jsx)("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),(0,a.jsx)("path",{d:"M19 3v16a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V7.914\n a1 1 0 0 1 .293-.707l3.914-3.914A1 1 0 0 1 9.914 3H18\n a1 1 0 0 1 1 1Z"}),(0,a.jsx)("path",{d:"M10 11l-2 2 2 2"}),(0,a.jsx)("path",{d:"M14 11l2 2-2 2"})]})}dm.classes=te,dm.displayName="@mantine/tiptap/RichTextEditorContent";let d1={interactive:!0},d2=(0,C.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:s,interactive:l,active:d,onMouseDown:u,disabled:c,...h}=(0,b.useProps)("RichTextEditorControl",d1,e),p=e9();return(0,a.jsx)(ef.UnstyledButton,{...h,...p.getStyles("control",{className:i,style:r,classNames:n,styles:o}),disabled:c,"data-rich-text-editor-control":!0,tabIndex:l?0:-1,"data-interactive":l||void 0,"data-disabled":c||void 0,"data-active":d||void 0,"aria-pressed":d&&l||void 0,"aria-hidden":!l||void 0,ref:t,unstyled:p.unstyled,variant:p.variant||"default",onMouseDown:e=>{e.preventDefault(),u?.(e)}})});d2.classes=te,d2.displayName="@mantine/tiptap/RichTextEditorControl";let d3=(0,f.forwardRef)(({className:e,icon:t,...n},i)=>{let r=e9();return(0,a.jsx)(d2,{ref:i,...n,children:(0,a.jsx)(t,{...r.getStyles("controlIcon")})})});function d5({label:e,isActive:t,operation:n,icon:i,isDisabled:r}){let o=(0,f.forwardRef)((o,s)=>{let{editor:l,labels:d}=e9(),u=d[e];return(0,a.jsx)(d3,{"aria-label":u,title:u,active:!!t?.name&&l?.isActive(t.name,t.attributes),ref:s,icon:o.icon||i,disabled:r?.(l)||!1,...o,onClick:()=>l?.chain().focus()[n.name](n.attributes).run()})});return o.displayName=`@mantine/tiptap/${e}`,o}d3.displayName="@mantine/tiptap/RichTextEditorControlBase";let d4=d5({label:"boldControlLabel",icon:e=>(0,a.jsx)(dy,{...e}),isActive:{name:"bold"},operation:{name:"toggleBold"}}
311),d6=d5({label:"italicControlLabel",icon:e=>(0,a.jsx)(db,{...e}),isActive:{name:"italic"},operation:{name:"toggleItalic"}}),d8=d5({label:"underlineControlLabel",icon:e=>(0,a.jsx)(dx,{...e}),isActive:{name:"underline"},operation:{name:"toggleUnderline"}}),d7=d5({label:"strikeControlLabel",icon:e=>(0,a.jsx)(dw,{...e}),isActive:{name:"strike"},operation:{name:"toggleStrike"}}),d9=d5({label:"clearFormattingControlLabel",icon:e=>(0,a.jsx)(dC,{...e}),operation:{name:"unsetAllMarks"}}),ue=d5({label:"unlinkControlLabel",icon:e=>(0,a.jsx)(dA,{...e}),operation:{name:"unsetLink"}}),ut=d5({label:"bulletListControlLabel",icon:e=>(0,a.jsx)(dR,{...e}),isActive:{name:"bulletList"},operation:{name:"toggleBulletList"}}),un=d5({label:"orderedListControlLabel",icon:e=>(0,a.jsx)(dI,{...e}),isActive:{name:"orderedList"},operation:{name:"toggleOrderedList"}}),ui=d5({label:"h1ControlLabel",icon:e=>(0,a.jsx)(dS,{...e}),isActive:{name:"heading",attributes:{level:1}},operation:{name:"toggleHeading",attributes:{level:1}}}),ur=d5({label:"h2ControlLabel",icon:e=>(0,a.jsx)(d_,{...e}),isActive:{name:"heading",attributes:{level:2}},operation:{name:"toggleHeading",attributes:{level:2}}}),uo=d5({label:"h3ControlLabel",icon:e=>(0,a.jsx)(dk,{...e}),isActive:{name:"heading",attributes:{level:3}},operation:{name:"toggleHeading",attributes:{level:3}}}),ua=d5({label:"h4ControlLabel",icon:e=>(0,a.jsx)(dM,{...e}),isActive:{name:"heading",attributes:{level:4}},operation:{name:"toggleHeading",attributes:{level:4}}}),us=d5({label:"h5ControlLabel",icon:e=>(0,a.jsx)(dT,{...e}),isActive:{name:"heading",attributes:{level:5}},operation:{name:"toggleHeading",attributes:{level:5}}}),ul=d5({label:"h6ControlLabel",icon:e=>(0,a.jsx)(dD,{...e}),isActive:{name:"heading",attributes:{level:6}},operation:{name:"toggleHeading",attributes:{level:6}}}),ud=d5({label:"blockquoteControlLabel",icon:e=>(0,a.jsx)(dP,{...e}),isActive:{name:"blockquote"},operation:{name:"toggleBlockquote"}}),uu=d5({label:"alignLeftControlLabel",icon:e=>(0,a.jsx)(dE,{...e}),operation:{name:"setTextAlign",attributes:"left"}}),uc=d5({label:"alignRightControlLabel",icon:e=>(0,a.jsx)(dL,{...e}),operation:{name:"setTextAlign",attributes:"right"}}),uh=d5({label:"alignCenterControlLabel",icon:e=>(0,a.jsx)(dF,{...e}),operation:{name:"setTextAlign",attributes:"center"}}),up=d5({label:"alignJustifyControlLabel",icon:e=>(0,a.jsx)(dO,{...e}),operation:{name:"setTextAlign",attributes:"justify"}}),uf=d5({label:"subscriptControlLabel",icon:e=>(0,a.jsx)(dN,{...e}),isActive:{name:"subscript"},operation:{name:"toggleSubscript"}}),ug=d5({label:"superscriptControlLabel",icon:e=>(0,a.jsx)(dB,{...e}),isActive:{name:"superscript"},operation:{name:"toggleSuperscript"}}),um=d5({label:"codeControlLabel",icon:e=>(0,a.jsx)(dz,{...e}),isActive:{name:"code"},operation:{name:"toggleCode"}}),uv=d5({label:"codeBlockControlLabel",icon:e=>(0,a.jsx)(dz,{...e}),isActive:{name:"codeBlock"},operation:{name:"toggleCodeBlock"}}),uy=d5({label:"highlightControlLabel",icon:e=>(0,a.jsx)(dj,{...e}),isActive:{name:"highlight"},operation:{name:"toggleHighlight"}}),ub=d5({label:"hrControlLabel",icon:e=>(0,a.jsx)(dV,{...e}),operation:{name:"setHorizontalRule"}}),ux=d5({label:"unsetColorControlLabel",icon:e=>(0,a.jsx)(dH,{...e}),operation:{name:"unsetColor"}}),uw=d5({label:"undoControlLabel",icon:e=>(0,a.jsx)(dY,{...e}),isDisabled:e=>!e?.can().undo(),operation:{name:"undo"}}),uC=d5({label:"redoControlLabel",icon:e=>(0,a.jsx)(dZ,{...e}),isDisabled:e=>!e?.can().redo(),operation:{name:"redo"}}),uS=d5({label:"tasksControlLabel",icon:e=>(0,a.jsx)(dX,{...e}),isActive:{name:"taskList"},operation:{name:"toggleTaskList"}}),u_=d5({label:"tasksSinkLabel",icon:e=>(0,a.jsx)(dJ,{...e}),operation:{name:"sinkListItem",attributes:"taskItem"},isDisabled:e=>!e?.can().sinkListItem("taskItem")}),uk=d5({label:"tasksLiftLabel",icon:e=>(0,a.jsx)(dQ,{...e}),operation:{name:"liftListItem",attributes:"taskItem"},isDisabled:e=>!e?.can().liftListItem("taskItem")});var uM=e.i(14845),uT=e.i(93297),uD=e.i(90905),uR=e.i(84584),uI=e.i(26460),uA={root:"m_77c9d27d",inner:"m_80f1301b",label:"m_811560b9",section:"m_a74036a",loader:"m_a25b86ee",group:"m_80d6d844",groupSection:"m_70be2a01"};let uP={orientation:"horizontal"},uE=(0,v.createVarsResolver)((e,{borderWidth:t})=>({group:{"--button-border-width":(0,S.rem)(t)}})),uL=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("ButtonGroup",uP,e),{className:i,style:r,classNames:o,styles:s,unstyled:l,orientation:d,vars:u,borderWidth:c,variant:h,mod:p,attributes:f,...g}=(0,b.useProps)("ButtonGroup",uP,e),m=(0,x.useStyles)({name:"ButtonGroup",props:n,classes:uA,className:i,style:r,classNames:o,styles:s,unstyled:l,attributes:f,vars:u,varsResolver:uE,rootSelector:"group"});return(0,a.jsx)(w.Box,{...m("group"),ref:t,variant:h,mod:[{"data-orientation":d},p],role:"group",...g})});uL.classes=uA,uL.displayName="@mantine/core/ButtonGroup";let uF=(0,v.createVarsResolver)((e,{radius:t,color:n,gradient:i,variant:r,autoContrast:o,size:a})=>{let s=e.variantColorResolver({color:n||e.primaryColor,theme:e,gradient:i,variant:r||"filled",autoContrast:o});return{groupSection:{"--section-height":(0,ec.getSize)(a,"section-height"),"--section-padding-x":(0,ec.getSize)(a,"section-padding-x"),"--section-fz":a?.includes("compact")?(0,ec.getFontSize)(a.replace("compact-","")):(0,ec.getFontSize)(a),"--section-radius":void 0===t?void 0:(0,ec.getRadius)(t),"--section-bg":n||r?s.background:void 0,"--section-color":s.color,"--section-bd":n||r?s.border:void 0}}}),uO=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("ButtonGroupSection",null,e),{className:i,style:r,classNames:o,styles:s,unstyled:l,vars:d,variant:u,gradient:c,radius:h,autoContrast:p,attributes:f,...g}=n,m=(0,x.useStyles)({name:"ButtonGroupSection",props:n,classes:uA,className:i,style:r,classNames:o,styles:s,unstyled:l,attributes:f,vars:d,varsResolver:uF,rootSelector:"groupSection"});return(0,a.jsx)(w.Box,{...m("groupSection"),ref:t,variant:u,...g})});uO.classes=uA,uO.displayName="@mantine/core/ButtonGroupSection";let uN={in:{opacity:1,transform:`translate(-50%, calc(-50% + ${(0,S.rem)(1)}))`},out:{opacity:0,transform:"translate(-50%, -200%)"},common:{transformOrigin:"center"},transitionProperty:"transform, opacity"},uB=(0,v.createVarsResolver)((e,{radius:t,color:n,gradient:i,variant:r,size:o,justify:a,autoContrast:s})=>{let l=e.variantColorResolver({color:n||e.primaryColor,theme:e,gradient:i,variant:r||"filled",autoContrast:s});return{root:{"--button-justify":a,"--button-height":(0,ec.getSize)(o,"button-height"),"--button-padding-x":(0,ec.getSize)(o,"button-padding-x"),"--button-fz":o?.includes("compact")?(0,ec.getFontSize)(o.replace("compact-","")):(0,ec.getFontSize)(o),"--button-radius":void 0===t?void 0:(0,ec.getRadius)(t),"--button-bg":n||r?l.background:void 0,"--button-hover":n||r?l.hover:void 0,"--button-color":l.color,"--button-bd":n||r?l.border:void 0,"--button-hover-color":n||r?l.hoverColor:void 0}}}),uz=(0,uD.polymorphicFactory)((e,t)=>{let n=(0,b.useProps)("Button",null,e),{style:i,vars:r,className:o,color:s,disabled:l,children:d,leftSection:u,rightSection:c,fullWidth:h,variant:p,radius:f,loading:g,loaderProps:m,gradient:v,classNames:y,styles:C,unstyled:S,"data-disabled":_,autoContrast:k,mod:M,attributes:T,...D}=n,R=(0,x.useStyles)({name:"Button",props:n,classes:uA,className:o,style:i,classNames:y,styles:C,unstyled:S,attributes:T,vars:r,varsResolver:uB}),I=!!u,A=!!c;return(0,a.jsxs)(ef.UnstyledButton,{ref:t,...R("root",{active:!l&&!g&&!_}),unstyled:S,variant:p,disabled:l||g,mod:[{disabled:l||_,loading:g,block:h,"with-left-section":I,"with-right-section":A},M],...D,children:["boolean"==typeof g&&(0,a.jsx)(uI.Transition,{mounted:g,transition:uN,duration:150,children:e=>(0,a.jsx)(w.Box,{component:"span",...R("loader",{style:e}
311),"aria-hidden":!0,children:(0,a.jsx)(uR.Loader,{color:"var(--button-color)",size:"calc(var(--button-height) / 1.8)",...m})})}),(0,a.jsxs)("span",{...R("inner"),children:[u&&(0,a.jsx)(w.Box,{component:"span",...R("section"),mod:{position:"left"},children:u}),(0,a.jsx)(w.Box,{component:"span",mod:{loading:g},...R("label"),children:d}),c&&(0,a.jsx)(w.Box,{component:"span",...R("section"),mod:{position:"right"},children:c})]})]})});uz.classes=uA,uz.displayName="@mantine/core/Button",uz.Group=uL,uz.GroupSection=uO;var uj=e.i(36676),uV=e.i(43819);let uH=e=>(0,a.jsx)(dq,{...e}),uG=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("RichTextEditorLinkControl",null,e),{classNames:i,className:r,style:o,styles:l,vars:d,icon:u,popoverProps:c,disableTooltips:h,initialExternal:p,...g}=n,m=e9(),v={classNames:i,styles:l},[y,x]=function(e){let[t,n]=(0,f.useState)("");return[t,e=>{if(e)if("function"==typeof e)n(e);else if("object"==typeof e&&"nativeEvent"in e){let{currentTarget:t}=e;n("checkbox"===t.type?t.checked:t.value)}else n(e);else n(e)}]}(0),[w,C]=(0,f.useState)(p),[_,{open:k,close:M}]=(0,uj.useDisclosure)(!1),T=()=>{k();let e=m.editor?.getAttributes("link");x(e?.href||""),C(e?.href?e?.target==="_blank":p)},D=()=>{M(),x(""),C(p)},R=()=>{D(),""===y?m.editor?.chain().focus().extendMarkRange("link").unsetLink().run():m.editor?.chain().focus().extendMarkRange("link").setLink({href:y,target:w?"_blank":null}).run()};(0,uV.useWindowEvent)("edit-link",T,!1);let{resolvedClassNames:I,resolvedStyles:A}=(0,eh.useResolvedStylesApi)({classNames:i,styles:l,props:n});return(0,a.jsxs)(uM.Popover,{trapFocus:!0,shadow:"md",withinPortal:!0,opened:_,onChange:e=>!e&&D(),offset:-44,zIndex:1e4,...c,children:[(0,a.jsx)(uM.Popover.Target,{children:(0,a.jsx)(d3,{icon:u||uH,...g,"aria-label":m.labels.linkControlLabel,title:m.labels.linkControlLabel,onClick:T,active:m.editor?.isActive("link"),ref:t,classNames:I,styles:A,className:r,style:o,variant:m.variant})}),(0,a.jsx)(uM.Popover.Dropdown,{...m.getStyles("linkEditorDropdown",v),children:(0,a.jsxs)("div",{...m.getStyles("linkEditor",v),children:[(0,a.jsx)(s.TextInput,{placeholder:m.labels.linkEditorInputPlaceholder,"aria-label":m.labels.linkEditorInputLabel,type:"url",value:y,onChange:x,classNames:{input:m.getStyles("linkEditorInput",v).className},onKeyDown:e=>{"Enter"===e.key&&(e.preventDefault(),R())},rightSection:(0,a.jsx)(uT.Tooltip,{label:w?m.labels.linkEditorExternalLink:m.labels.linkEditorInternalLink,events:{hover:!0,focus:!0,touch:!0},withinPortal:!0,withArrow:!0,disabled:h,zIndex:1e4,children:(0,a.jsx)(ef.UnstyledButton,{onClick:()=>C(e=>!e),"data-active":w||void 0,...m.getStyles("linkEditorExternalControl",v),children:(0,a.jsx)(dK,{style:{width:(0,S.rem)(14),height:(0,S.rem)(14)}})})})}),(0,a.jsx)(uz,{variant:"default",onClick:R,...m.getStyles("linkEditorSave",v),children:m.labels.linkEditorSave})]})})]})});uG.classes=te,uG.displayName="@mantine/tiptap/RichTextEditorLinkControl";var uW={root:"m_de3d2490",colorOverlay:"m_862f3d1b",shadowOverlay:"m_98ae7f22",alphaOverlay:"m_95709ac0",childrenOverlay:"m_93e74e3"};let u$={withShadow:!0},uU=(0,v.createVarsResolver)((e,{radius:t,size:n})=>({root:{"--cs-radius":void 0===t?void 0:(0,ec.getRadius)(t),"--cs-size":(0,S.rem)(n)}})),uq=(0,uD.polymorphicFactory)((e,t)=>{let n=(0,b.useProps)("ColorSwatch",u$,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,color:u,size:c,radius:h,withShadow:p,children:f,variant:g,attributes:m,...v}=(0,b.useProps)("ColorSwatch",u$,n),y=(0,x.useStyles)({name:"ColorSwatch",props:n,classes:uW,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:m,vars:d,varsResolver:uU});return(0,a.jsxs)(w.Box,{ref:t,variant:g,size:c,...y("root",{focusable:!0}),...v,children:[(0,a.jsx)("span",{...y("alphaOverlay")}),p&&(0,a.jsx)("span",{...y("shadowOverlay")}),(0,a.jsx)("span",{...y("colorOverlay",{style:{backgroundColor:u}})}),(0,a.jsx)("span",{...y("childrenOverlay"),children:f})]})});uq.classes=uW,uq.displayName="@mantine/core/ColorSwatch";var uK=e.i(17236),uY=e.i(79352);
311function uZ(e){return{x:(0,el.clamp)(e.x,0,1),y:(0,el.clamp)(e.y,0,1)}}function uX(e,t,n="ltr"){let i=(0,f.useRef)(!1),r=(0,f.useRef)(!1),o=(0,f.useRef)(0),[a,s]=(0,f.useState)(!1),l=(0,f.useRef)(null);return(0,f.useEffect)(()=>{i.current=!0},[]),{ref:(0,f.useCallback)(a=>{if(l.current&&(l.current(),l.current=null),!a)return;let d=({x:t,y:r})=>{cancelAnimationFrame(o.current),o.current=requestAnimationFrame(()=>{if(i.current&&a){a.style.userSelect="none";let i=a.getBoundingClientRect();if(i.width&&i.height){let o=(0,el.clamp)((t-i.left)/i.width,0,1);e({x:"ltr"===n?o:1-o,y:(0,el.clamp)((r-i.top)/i.height,0,1)})}}})},u=()=>{!r.current&&i.current&&(r.current=!0,"function"==typeof t?.onScrubStart&&t.onScrubStart(),s(!0),document.addEventListener("mousemove",p),document.addEventListener("mouseup",c),document.addEventListener("touchmove",g,{passive:!1}),document.addEventListener("touchend",c))},c=()=>{r.current&&i.current&&(r.current=!1,s(!1),document.removeEventListener("mousemove",p),document.removeEventListener("mouseup",c),document.removeEventListener("touchmove",g),document.removeEventListener("touchend",c),setTimeout(()=>{"function"==typeof t?.onScrubEnd&&t.onScrubEnd()},0))},h=e=>{u(),e.preventDefault(),p(e)},p=e=>d({x:e.clientX,y:e.clientY}),f=e=>{e.cancelable&&e.preventDefault(),u(),g(e)},g=e=>{e.cancelable&&e.preventDefault(),d({x:e.changedTouches[0].clientX,y:e.changedTouches[0].clientY})};a.addEventListener("mousedown",h),a.addEventListener("touchstart",f,{passive:!1}),l.current=()=>{a.removeEventListener("mousedown",h),a.removeEventListener("touchstart",f)}},[n,e]),active:a}}var uJ=e.i(11920);let[uQ,u0]=(0,eO.createOptionalContext)(null);var u1={wrapper:"m_fee9c77",preview:"m_9dddfbac",body:"m_bffecc3e",sliders:"m_3283bb96",thumb:"m_40d572ba",swatch:"m_d8ee6fd8",swatches:"m_5711e686",saturation:"m_202a296e",saturationOverlay:"m_11b3db02",slider:"m_d856d47d",sliderOverlay:"m_8f327113"};let u2=(0,f.forwardRef)(({position:e,...t},n)=>(0,a.jsx)(w.Box,{ref:n,__vars:{"--thumb-y-offset":`${100*e.y}%`,"--thumb-x-offset":`${100*e.x}%`},...t}));u2.displayName="@mantine/core/ColorPickerThumb";let u3=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("ColorSlider",null,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,onChange:u,onChangeEnd:c,maxValue:h,round:p,size:g="md",focusable:m=!0,value:v,overlays:y,thumbColor:C="transparent",onScrubStart:_,onScrubEnd:k,__staticSelector:M="ColorPicker",attributes:T,...D}=n,R=(0,x.useStyles)({name:M,classes:u1,props:n,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:T}),I=u0()?.getStyles||R,A=(0,uJ.useMantineTheme)(),[P,E]=(0,f.useState)({y:0,x:v/h}),L=(0,f.useRef)(P),F=e=>p?Math.round(e*h):e*h,{ref:O}=uX(({x:e,y:t})=>{L.current={x:e,y:t},u?.(F(e))},{onScrubEnd:()=>{let{x:e}=L.current;c?.(F(e)),k?.()},onScrubStart:_});(0,uY.useDidUpdate)(()=>{E({y:0,x:v/h})},[v]);let N=(e,t)=>{e.preventDefault();let n=uZ(t);u?.(F(n.x)),c?.(F(n.x))},B=y.map((e,t)=>(0,f.createElement)("div",{...I("sliderOverlay"),style:e,key:t}));return(0,a.jsxs)(w.Box,{...D,ref:(0,ed.useMergedRef)(O,t),...I("slider"),role:"slider","aria-valuenow":v,"aria-valuemax":h,"aria-valuemin":0,tabIndex:m?0:-1,onKeyDown:e=>{switch(e.key){case"ArrowRight":N(e,{x:P.x+.05,y:P.y});break;case"ArrowLeft":N(e,{x:P.x-.05,y:P.y})}},"data-focus-ring":A.focusRing,__vars:{"--cp-thumb-size":`var(--cp-thumb-size-${g})`},children:[B,(0,a.jsx)(u2,{position:P,...I("thumb",{style:{top:(0,S.rem)(1),background:C}})})]})});function u5(e,t=0,n=10**t){return Math.round(n*e)/n}u3.displayName="@mantine/core/ColorSlider";let u4={grad:.9,turn:360,rad:360/(2*Math.PI)},u6=/hsla?\(?\s*(-?\d*\.?\d+)(deg|rad|grad|turn)?[,\s]+(-?\d*\.?\d+)%?[,\s]+(-?\d*\.?\d+)%?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i;function u8(e){let t=u6.exec(e);return t?function({h:e,s:t,l:n,a:i}){let r=(n<50?n:100-n)/100*t;return{h:e,s:r>0?2*r/(n+r)*100:0,v:n+r,a:i}}({h:function(e,t="deg"){return Number(e)*(u4[t]||1)}(t[1],t[2]),s:Number(t[3]),l:Number(t[4]),a:void 0===t[5]?1:Number(t[5])/(t[6]?100:1)}):{h:0,s:0,v:0,a:1}}function u7({r:e,g:t,b:n,a:i}){let r=Math.max(e,t,n),o=r-Math.min(e,t,n),a=o?r===e?(t-n)/o:r===t?2+(n-e)/o:4+(e-t)/o:0;return{h:u5(60*(a<0?a+6:a),3),s:u5(r?o/r*100:0,3),v:u5(r/255*100,3),a:i}}function u9(e){let t="#"===e[0]?e.slice(1):e;return 3===t.length?u7({r:parseInt(t[0]+t[0],16),g:parseInt(t[1]+t[1],16),b:parseInt(t[2]+t[2],16),a:1}):u7({r:parseInt(t.slice(0,2),16),g:parseInt(t.slice(2,4),16),b:parseInt(t.slice(4,6),16),a:1})}let ce=/rgba?\(?\s*(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i;function ct(e){let t=ce.exec(e);return t?u7({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:void 0===t[7]?1:Number(t[7])/(t[8]?100:1)}):{h:0,s:0,v:0,a:1}}let cn={hex:/^#?([0-9A-F]{3}){1,2}
311$/i,hexa:/^#?([0-9A-F]{4}){1,2}$/i,rgb:/^rgb\((\d+),\s*(\d+),\s*(\d+)(?:,\s*(\d+(?:\.\d+)?))?\)$/i,rgba:/^rgba\((\d+),\s*(\d+),\s*(\d+)(?:,\s*(\d+(?:\.\d+)?))?\)$/i,hsl:/hsl\(\s*(\d+)\s*,\s*(\d+(?:\.\d+)?%)\s*,\s*(\d+(?:\.\d+)?%)\)/i,hsla:/^hsla\((\d+),\s*([\d.]+)%,\s*([\d.]+)%,\s*(\d*(?:\.\d+)?)\)$/i},ci={hex:u9,hexa:function(e){let t="#"===e[0]?e.slice(1):e,n=e=>u5(parseInt(e,16)/255,3);if(4===t.length){let e=t.slice(0,3),i=n(t[3]+t[3]);return{...u9(e),a:i}}let i=t.slice(0,6),r=n(t.slice(6,8));return{...u9(i),a:r}},rgb:ct,rgba:ct,hsl:u8,hsla:u8};function cr(e){if("string"!=typeof e)return{h:0,s:0,v:0,a:1};if("transparent"===e)return{h:0,s:0,v:0,a:0};let t=e.trim();for(let[e,n]of Object.entries(cn))if(n.test(t))return ci[e](t);return{h:0,s:0,v:0,a:1}}let co=(0,f.forwardRef)((e,t)=>{let{value:n,onChange:i,onChangeEnd:r,color:o,...s}=(0,b.useProps)("AlphaSlider",null,e);return(0,a.jsx)(u3,{...s,ref:t,value:n,onChange:e=>i?.(u5(e,2)),onChangeEnd:e=>r?.(u5(e,2)),maxValue:1,round:!1,"data-alpha":!0,overlays:[{backgroundImage:"linear-gradient(45deg, var(--slider-checkers) 25%, transparent 25%), linear-gradient(-45deg, var(--slider-checkers) 25%, transparent 25%), linear-gradient(45deg, transparent 75%, var(--slider-checkers) 75%), linear-gradient(-45deg, var(--mantine-color-body) 75%, var(--slider-checkers) 75%)",backgroundSize:`${(0,S.rem)(8)} ${(0,S.rem)(8)}`,backgroundPosition:`0 0, 0 ${(0,S.rem)(4)}, ${(0,S.rem)(4)} ${(0,S.rem)(-4)}, ${(0,S.rem)(-4)} 0`},{backgroundImage:`linear-gradient(90deg, transparent, ${o})`},{boxShadow:`rgba(0, 0, 0, .1) 0 0 0 ${(0,S.rem)(1)} inset, rgb(0, 0, 0, .15) 0 0 ${(0,S.rem)(4)} inset`}]})});function ca({h:e,s:t,v:n,a:i}){let r=e/360*6,o=t/100,a=n/100,s=Math.floor(r),l=a*(1-o),d=a*(1-(r-s)*o),u=a*(1-(1-r+s)*o),c=s%6;return{r:u5(255*[a,d,l,l,u,a][c]),g:u5(255*[u,a,a,d,l,l][c]),b:u5(255*[l,l,u,a,a,d][c]),a:u5(i,2)}}function cs(e,t){let{r:n,g:i,b:r,a:o}=ca(e);return t?`rgba(${n}, ${i}, ${r}, ${u5(o,2)})`:`rgb(${n}, ${i}, ${r})`}function cl({h:e,s:t,v:n,a:i},r){let o=(200-t)*n/100,a={h:Math.round(e),s:Math.round(o>0&&o<200?t*n/100/(o<=100?o:200-o)*100:0),l:Math.round(o/2)};return r?`hsla(${a.h}, ${a.s}%, ${a.l}%, ${u5(i,2)})`:`hsl(${a.h}, ${a.s}%, ${a.l}%)`}function cd(e){let t=e.toString(16);return t.length<2?`0${t}`:t}function cu(e){let{r:t,g:n,b:i}=ca(e);return`#${cd(t)}${cd(n)}${cd(i)}`}co.displayName="@mantine/core/AlphaSlider";let cc={hex:cu,hexa:e=>{let t;return t=Math.round(255*e.a),`${cu(e)}${cd(t)}`},rgb:e=>cs(e,!1),rgba:e=>cs(e,!0),hsl:e=>cl(e,!1),hsla:e=>cl(e,!0)};function ch(e,t){return t?e in cc?cc[e](t):cc.hex(t):"#000000"}let cp=(0,f.forwardRef)((e,t)=>{let{value:n,onChange:i,onChangeEnd:r,color:o,...s}=(0,b.useProps)("HueSlider",{},e);return(0,a.jsx)(u3,{...s,ref:t,value:n,onChange:i,onChangeEnd:r,maxValue:360,thumbColor:`hsl(${n}, 100%, 50%)`,round:!0,"data-hue":!0,overlays:[{backgroundImage:"linear-gradient(to right,hsl(0,100%,50%),hsl(60,100%,50%),hsl(120,100%,50%),hsl(170,100%,50%),hsl(240,100%,50%),hsl(300,100%,50%),hsl(360,100%,50%))"},{boxShadow:`rgba(0, 0, 0, .1) 0 0 0 ${(0,S.rem)(1)} inset, rgb(0, 0, 0, .15) 0 0 ${(0,S.rem)(4)} inset`}]})});function cf({className:e,onChange:t,onChangeEnd:n,value:i,saturationLabel:r,focusable:o=!0,size:s,color:l,onScrubStart:d,onScrubEnd:u,...c}){let{getStyles:h}=u0(),[p,g]=(0,f.useState)({x:i.s/100,y:1-i.v/100}),m=(0,f.useRef)(p),{ref:v}=uX(({x:e,y:n})=>{m.current={x:e,y:n},t({s:Math.round(100*e),v:Math.round((1-n)*100)})},{onScrubEnd:()=>{let{x:e,y:t}=m.current;n({s:Math.round(100*e),v:Math.round((1-t)*100)}),u?.()},onScrubStart:d});(0,f.useEffect)(()=>{g({x:i.s/100,y:1-i.v/100})},[i.s,i.v]);let y=(e,i)=>{e.preventDefault();let r=uZ(i);t({s:Math.round(100*r.x),v:Math.round((1-r.y)*100)}),n({s:Math.round(100*r.x),v:Math.round((1-r.y)*100)})};return(0,a.jsxs)(w.Box,{...h("saturation"),ref:v,...c,role:"slider","aria-label":r,"aria-valuenow":p.x,"aria-valuetext":ch("rgba",i),tabIndex:o?0:-1,onKeyDown:e=>{switch(e.key){case"ArrowUp":y(e,{y:p.y-.05,x:p.x});break;case"ArrowDown":y(e,{y:p.y+.05,x:p.x});break;case"ArrowRight":y(e,{x:p.x+.05,y:p.y});break;case"ArrowLeft":y(e,{x:p.x-.05,y:p.y})}},children:[(0,a.jsx)("div",{...h("saturationOverlay",{style:{backgroundColor:`hsl(${i.h}, 100%, 50%)`}})}),(0,a.jsx)("div",{...h("saturationOverlay",{style:{backgroundImage:"linear-gradient(90deg, #fff, transparent)"}})}),(0,a.jsx)("div",{...h("saturationOverlay",{style:{backgroundImage:"linear-gradient(0deg, #000, transparent)"}})}),(0,a.jsx)(u2,{position:p,...h("thumb",{style:{backgroundColor:l}})})]})}cp.displayName="@mantine/core/HueSlider",cf.displayName="@mantine/core/Saturation";var cg=e.i(91701),cm=e.i(88146);let cv=(0,f.forwardRef)(({className:e,datatype:t,setValue:n,onChangeEnd:i,size:r,focusable:o,data:s,swatchesPerRow:l,value:d,...u},c)=>{let h=u0(),p=s.map((e,t)=>(0,f.createElement)(uq,{...h.getStyles("swatch"),unstyled:h.unstyled,component:"button",type:"button",color:e,key:t,radius:"sm",onClick:()=>{n(e),i?.(e)},"aria-label":e,tabIndex:o?0:-1,"data-swatch":!0},d===e&&(0,a.jsx)(cm.CheckIcon,{size:"35%",color:.5>(0,cg.luminance)(e)?"white":"black"})));return(0,a.jsx)(w.Box,{...h.getStyles("swatches"),ref:c,...u,children:p})});cv.displayName="@mantine/core/Swatches";let cy={swatchesPerRow:7,withPicker:!0,focusable:!0,size:"md",__staticSelector:"ColorPicker"},cb=(0,v.createVarsResolver)((e,{size:t,swatchesPerRow:n})=>({wrapper:{"--cp-preview-size":(0,ec.getSize)(t,"cp-preview-size"),"--cp-width":(0,ec.getSize)(t,"cp-width"),"
311--cp-body-spacing":(0,ec.getSpacing)(t),"--cp-swatch-size":`${100/n}%`,"--cp-thumb-size":(0,ec.getSize)(t,"cp-thumb-size"),"--cp-saturation-height":(0,ec.getSize)(t,"cp-saturation-height")}})),cx=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("ColorPicker",cy,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,format:u="hex",value:c,defaultValue:h,onChange:p,onChangeEnd:g,withPicker:m,size:v,saturationLabel:y,hueLabel:C,alphaLabel:S,focusable:_,swatches:k,swatchesPerRow:M,fullWidth:T,onColorSwatchClick:D,__staticSelector:R,mod:I,attributes:A,...P}=n,E=(0,x.useStyles)({name:R,props:n,classes:u1,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:A,rootSelector:"wrapper",vars:d,varsResolver:cb}),L=(0,f.useRef)(u||"hex"),F=(0,f.useRef)(""),O=(0,f.useRef)(-1),N=(0,f.useRef)(!1),B="hexa"===u||"rgba"===u||"hsla"===u,[z,j,V]=(0,es.useUncontrolled)({value:c,defaultValue:h,finalValue:"#FFFFFF",onChange:p}),[H,G]=(0,f.useState)(cr(z)),W=()=>{window.clearTimeout(O.current),N.current=!0},$=()=>{window.clearTimeout(O.current),O.current=window.setTimeout(()=>{N.current=!1},200)},U=e=>{G(t=>{let n={...t,...e};return F.current=ch(L.current,n),n}),j(F.current)};return(0,uY.useDidUpdate)(()=>{"string"==typeof c&&function(e){for(let[,t]of Object.entries(cn))if(t.test(e))return!0;return!1}(c)&&!N.current&&G(cr(c))},[c]),(0,uY.useDidUpdate)(()=>{L.current=u||"hex",j(ch(L.current,H))},[u]),(0,a.jsx)(uQ,{value:{getStyles:E,unstyled:l},children:(0,a.jsxs)(w.Box,{ref:t,...E("wrapper"),size:v,mod:[{"full-width":T},I],...P,children:[m&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(cf,{value:H,onChange:U,onChangeEnd:({s:e,v:t})=>g?.(ch(L.current,{...H,s:e,v:t})),color:z,size:v,focusable:_,saturationLabel:y,onScrubStart:W,onScrubEnd:$}),(0,a.jsxs)("div",{...E("body"),children:[(0,a.jsxs)("div",{...E("sliders"),children:[(0,a.jsx)(cp,{value:H.h,onChange:e=>U({h:e}),onChangeEnd:e=>g?.(ch(L.current,{...H,h:e})),size:v,focusable:_,"aria-label":C,onScrubStart:W,onScrubEnd:$}),B&&(0,a.jsx)(co,{value:H.a,onChange:e=>U({a:e}),onChangeEnd:e=>{g?.(ch(L.current,{...H,a:e}))},size:v,color:ch("hex",H),focusable:_,"aria-label":S,onScrubStart:W,onScrubEnd:$})]}),B&&(0,a.jsx)(uq,{color:z,radius:"sm",size:"var(--cp-preview-size)",...E("preview")})]})]}),Array.isArray(k)&&(0,a.jsx)(cv,{data:k,swatchesPerRow:M,focusable:_,setValue:j,value:z,onChangeEnd:e=>{let t=ch(u,cr(e));D?.(t),g?.(t),V||G(cr(e))}})]})})});cx.classes=u1,cx.displayName="@mantine/core/ColorPicker";var cw=e.i(83742);let cC=(0,f.forwardRef)((e,t)=>{let{popoverProps:n,colors:i,colorPickerProps:r,...o}=(0,b.useProps)("RichTextEditorColorPickerControl",null,e),{editor:s,labels:l,getStyles:d,variant:u}=e9(),[c,{toggle:h,close:p}]=(0,uj.useDisclosure)(!1),[g,m]=(0,f.useState)("palette"),v=s?.getAttributes("textStyle").color||"var(--mantine-color-text)",y=(e,t=!0)=>{(s?.chain()).focus().setColor(e).run(),t&&p()},x=i.map((e,t)=>(0,a.jsx)(uq,{component:"button",color:e,onClick:()=>y(e),size:26,radius:"xs",style:{cursor:"pointer"},title:l.colorPickerColorLabel(e),"aria-label":l.colorPickerColorLabel(e)},t));return(0,a.jsxs)(uM.Popover,{opened:c,withinPortal:!0,trapFocus:!0,onChange:e=>!e&&p(),...n,children:[(0,a.jsx)(uM.Popover.Target,{children:(0,a.jsx)(d2,{...o,variant:u,"aria-label":l.colorPickerControlLabel,title:l.colorPickerControlLabel,ref:t,onClick:h,children:(0,a.jsx)(uq,{color:v,size:14})})}),(0,a.jsxs)(uM.Popover.Dropdown,{...d("linkEditorDropdown"),children:["palette"===g&&(0,a.jsx)(uK.SimpleGrid,{cols:7,spacing:2,children:x}),"colorPicker"===g&&(0,a.jsx)(cx,{defaultValue:v,onChange:e=>y(e,!1),...r}),(0,a.jsx)(uT.Tooltip.Group,{closeDelay:200,children:(0,a.jsxs)(e2.Group,{justify:"flex-end",gap:"xs",mt:"sm",children:["palette"===g&&(0,a.jsx)(cw.ActionIcon,{variant:"default",onClick:p,title:l.colorPickerCancel,"aria-label":l.colorPickerCancel,children:(0,a.jsx)(dW,{style:{width:(0,S.rem)(16),height:(0,S.rem)(16)}})}),(0,a.jsx)(cw.ActionIcon,{variant:"default",onClick:()=>{(s?.chain()).focus().unsetColor().run(),p()},title:l.colorPickerClear,"aria-label":l.colorPickerClear,children:(0,a.jsx)(dH,{style:{width:(0,S.rem)(16),height:(0,S.rem)(16)}})}),"palette"===g?(0,a.jsx)(cw.ActionIcon,{variant:"default",onClick:()=>m("colorPicker"),title:l.colorPickerColorPicker,"aria-label":l.colorPickerColorPicker,children:(0,a.jsx)(dG,{style:{width:(0,S.rem)(16),height:(0,S.rem)(16)}})}):(0,a.jsx)(cw.ActionIcon,{variant:"default",onClick:()=>m("palette"),"aria-label":l.colorPickerPalette,title:l.colorPickerPalette,children:(0,a.jsx)(d$,{style:{width:(0,S.rem)(16),height:(0,S.rem)(16)}})}),"colorPicker"===g&&(0,a.jsx)(cw.ActionIcon,{variant:"default",onClick:p,title:l.colorPickerSave,"aria-label":l.colorPickerSave,children:(0,a.jsx)(dU,{style:{width:(0,S.rem)(16),height:(0,S.rem)(16)}})})]})})]})]})});cC.displayName="@mantine/tiptap/ColorPickerControl";let cS=(0,f.forwardRef)((e,t)=>{let{color:n,...i}=(0,b.useProps)("RichTextEditorColorControl",null,e),{editor:r,labels:o,variant:s}=e9(),l=r?.getAttributes("textStyle").color||null,d=o.colorControl
311Label(n);return(0,a.jsx)(d2,{...i,variant:s,active:l===n,"aria-label":d,title:d,onClick:()=>(r?.chain()).focus().setColor(n).run(),ref:t,children:(0,a.jsx)(uq,{color:n,size:14})})});cS.displayName="@mantine/tiptap/RichTextEditorColorControl";let c_={},ck=(0,f.forwardRef)((e,t)=>{let{...n}=(0,b.useProps)("RichTextEditorSourceCodeControl",c_,e),{editor:i,labels:r,variant:o,onSourceCodeTextSwitch:s}=e9(),[l,d]=(0,f.useState)(!1);return(0,a.jsx)(d2,{...n,variant:o,active:l,"aria-label":r.sourceCodeControlLabel,title:r.sourceCodeControlLabel,onClick:()=>{let e;return l?i?.commands.setContent(i.getText(),{emitUpdate:!0}):i?.commands.setContent(`<textarea>${i.getHTML()}</textarea>`),void(d(e=!l),s?.(e))},ref:t,children:(0,a.jsx)(d0,{style:{width:(0,S.rem)(16),height:(0,S.rem)(16)}})})});ck.displayName="@mantine/tiptap/RichTextEditorSourceCodeControl";let cM=(0,C.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:s,variant:l,...d}=(0,b.useProps)("RichTextEditorControlsGroup",null,e),u=e9();return(0,a.jsx)(w.Box,{ref:t,variant:l||u.variant,...u.getStyles("controlsGroup",{className:i,style:r,styles:o,classNames:n}),...d})});cM.classes=te,cM.displayName="@mantine/tiptap/RichTextEditorControlsGroup";let cT=(0,C.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:s,sticky:l,stickyOffset:d,mod:u,variant:c,...h}=(0,b.useProps)("RichTextEditorToolbar",null,e),p=e9();return(0,a.jsx)(w.Box,{ref:t,mod:[{sticky:l},u],variant:c||p.variant,...p.getStyles("toolbar",{className:i,style:r,styles:o,classNames:n}),...h,__vars:{"--rte-sticky-offset":(0,S.rem)(d)}})});cT.classes=te,cT.displayName="@mantine/tiptap/RichTextEditorToolbar";let cD={withCodeHighlightStyles:!0,withTypographyStyles:!0,variant:"default"},cR=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("RichTextEditor",cD,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,editor:u,withCodeHighlightStyles:c,withTypographyStyles:h,onSourceCodeTextSwitch:p,labels:g,children:m,variant:v,attributes:y,...C}=n,S=(0,x.useStyles)({name:"RichTextEditor",classes:te,props:n,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:y,vars:d}),_=(0,f.useMemo)(()=>({...e6,...g}),[g]);return(0,a.jsx)(e7,{value:{editor:u,getStyles:S,labels:_,withCodeHighlightStyles:c,withTypographyStyles:h,onSourceCodeTextSwitch:p,unstyled:l,variant:v},children:(0,a.jsx)(w.Box,{...S("root"),...C,ref:t,children:m})})});cR.classes=te,cR.displayName="@mantine/tiptap/RichTextEditor",cR.Content=dm,cR.Control=d2,cR.Toolbar=cT,cR.ControlsGroup=cM,cR.Bold=d4,cR.Italic=d6,cR.Strikethrough=d7,cR.Underline=d8,cR.ClearFormatting=d9,cR.H1=ui,cR.H2=ur,cR.H3=uo,cR.H4=ua,cR.H5=us,cR.H6=ul,cR.BulletList=ut,cR.OrderedList=un,cR.Link=uG,cR.Unlink=ue,cR.Blockquote=ud,cR.AlignLeft=uu,cR.AlignRight=uc,cR.AlignCenter=uh,cR.AlignJustify=up,cR.Superscript=ug,cR.Subscript=uf,cR.Code=um,cR.CodeBlock=uv,cR.ColorPicker=cC,cR.Color=cS,cR.Highlight=uy,cR.Hr=ub,cR.UnsetColor=ux,cR.Undo=uw,cR.Redo=uC,cR.TaskList=uS,cR.TaskListSink=u_,cR.TaskListLift=uk,cR.SourceCode=ck;var cI=(e,t)=>{if("slot"===e)return 0;if(e instanceof Function)return e(t);let{children:n,...i}=null!=t?t:{};if("svg"===e)throw Error("SVG elements are not supported in the JSX syntax, use the array syntax instead");return[e,i,n]},cA=class e{constructor(e,t){if(this.content=e,this.size=t||0,null==t)for(let t=0;t<e.length;t++)this.size+=e[t].nodeSize}nodesBetween(e,t,n,i=0,r){for(let o=0,a=0;a<t;o++){let s=this.content[o],l=a+s.nodeSize;if(l>e&&!1!==n(s,i+a,r||null,o)&&s.content.size){let r=a+1;s.nodesBetween(Math.max(0,e-r),Math.min(s.content.size,t-r),n,i+r)}a=l}}descendants(e){this.nodesBetween(0,this.size,e)}textBetween(e,t,n,i){let r="",o=!0;return this.nodesBetween(e,t,(a,s)=>{let l=a.isText?a.text.slice(Math.max(e,s)-s,t-s):a.isLeaf?i?"function"==typeof i?i(a):i:a.type.spec.leafText?a.type.spec.leafText(a):"":"";a.isBlock&&(a.isLeaf&&l||a.isTextblock)&&n&&(o?o=!1:r+=n),r+=l},0),r}append(t){if(!t.size)return this;if(!this.size)return t;let n=this.lastChild,i=t.firstChild,r=this.content.slice(),o=0;for(n.isText&&n.sameMarkup(i)&&(r[r.length-1]=n.withText(n.text+i.text),o=1);o<t.content.length;o++)r.push(t.content[o]);return new e(r,this.size+t.size)}cut(t,n=this.size){if(0==t&&n==this.size)return this;let i=[],r=0;if(n>t)for(let e=0,o=0;o<n;e++){let a=this.content[e],s=o+a.nodeSize;s>t&&((o<t||s>n)&&(a=a.isText?a.cut(Math.max(0,t-o),Math.min(a.text.length,n-o)):a.cut(Math.max(0,t-o-1),Math.min(a.content.size,n-o-1))),i.push(a),r+=a.nodeSize),o=s}return new e(i,r)}cutByIndex(t,n){return t==n?e.empty:0==t&&n==this.content.length?this:new e(this.content.slice(t,n))}replaceChild(t,n){let i=this.content[t];if(i==n)return this;let r=this.content.slice(),o=this.size+n.nodeSize-i.nodeSize;return r[t]=n,new e(r,o)}addToStart(t){return new e([t].concat(this.content),this.size+t.no
311deSize)}addToEnd(t){return new e(this.content.concat(t),this.size+t.nodeSize)}eq(e){if(this.content.length!=e.content.length)return!1;for(let t=0;t<this.content.length;t++)if(!this.content[t].eq(e.content[t]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(e){let t=this.content[e];if(!t)throw RangeError("Index "+e+" out of range for "+this);return t}maybeChild(e){return this.content[e]||null}forEach(e){for(let t=0,n=0;t<this.content.length;t++){let i=this.content[t];e(i,n,t),n+=i.nodeSize}}findDiffStart(e,t=0){return function e(t,n,i){for(let r=0;;r++){if(r==t.childCount||r==n.childCount)return t.childCount==n.childCount?null:i;let o=t.child(r),a=n.child(r);if(o==a){i+=o.nodeSize;continue}if(!o.sameMarkup(a))return i;if(o.isText&&o.text!=a.text){for(let e=0;o.text[e]==a.text[e];e++)i++;return i}if(o.content.size||a.content.size){let t=e(o.content,a.content,i+1);if(null!=t)return t}i+=o.nodeSize}}(this,e,t)}findDiffEnd(e,t=this.size,n=e.size){return function e(t,n,i,r){for(let o=t.childCount,a=n.childCount;;){if(0==o||0==a)return o==a?null:{a:i,b:r};let s=t.child(--o),l=n.child(--a),d=s.nodeSize;if(s==l){i-=d,r-=d;continue}if(!s.sameMarkup(l))return{a:i,b:r};if(s.isText&&s.text!=l.text){let e=0,t=Math.min(s.text.length,l.text.length);for(;e<t&&s.text[s.text.length-e-1]==l.text[l.text.length-e-1];)e++,i--,r--;return{a:i,b:r}}if(s.content.size||l.content.size){let t=e(s.content,l.content,i-1,r-1);if(t)return t}i-=d,r-=d}}(this,e,t,n)}findIndex(e){if(0==e)return cE(0,e);if(e==this.size)return cE(this.content.length,e);if(e>this.size||e<0)throw RangeError(`Position ${e} outside of fragment (${this})`);for(let t=0,n=0;;t++){let i=n+this.child(t).nodeSize;if(i>=e){if(i==e)return cE(t+1,i);return cE(t,n)}n=i}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(e=>e.toJSON()):null}static fromJSON(t,n){if(!n)return e.empty;if(!Array.isArray(n))throw RangeError("Invalid input for Fragment.fromJSON");return e.fromArray(n.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return e.empty;let n,i=0;for(let e=0;e<t.length;e++){let r=t[e];i+=r.nodeSize,e&&r.isText&&t[e-1].sameMarkup(r)?(n||(n=t.slice(0,e)),n[n.length-1]=r.withText(n[n.length-1].text+r.text)):n&&n.push(r)}return new e(n||t,i)}static from(t){if(!t)return e.empty;if(t instanceof e)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new e([t],t.nodeSize);throw RangeError("Can not convert "+t+" to a Fragment"+(t.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}};cA.empty=new cA([],0);var cP={index:0,offset:0};function cE(e,t){return cP.index=e,cP.offset=t,cP}function cL(e,t){if(e===t)return!0;if(!(e&&"object"==typeof e)||!(t&&"object"==typeof t))return!1;let n=Array.isArray(e);if(Array.isArray(t)!=n)return!1;if(n){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!cL(e[n],t[n]))return!1}else{for(let n in e)if(!(n in t)||!cL(e[n],t[n]))return!1;for(let n in t)if(!(n in e))return!1}return!0}var cF=class e{constructor(e,t){this.type=e,this.attrs=t}addToSet(e){let t,n=!1;for(let i=0;i<e.length;i++){let r=e[i];if(this.eq(r))return e;if(this.type.excludes(r.type))t||(t=e.slice(0,i));else{if(r.type.excludes(this.type))return e;!n&&r.type.rank>this.type.rank&&(t||(t=e.slice(0,i)),t.push(this),n=!0),t&&t.push(r)}}return t||(t=e.slice()),n||t.push(this),t}removeFromSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return e.slice(0,t).concat(e.slice(t+1));return e}isInSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return!0;return!1}eq(e){return this==e||this.type==e.type&&cL(this.attrs,e.attrs)}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return e}static fromJSON(e,t){if(!t)throw RangeError("Invalid input for Mark.fromJSON");let n=e.marks[t.type];if(!n)throw RangeError(`There is no mark type ${t.type} in this schema`);let i=n.create(t.attrs);return n.checkAttrs(i.attrs),i}static sameSet(e,t){if(e==t)return!0;
vendor: 5,704 bytes, line 311
311if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].eq(t[n]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&0==t.length)return e.none;if(t instanceof e)return[t];let n=t.slice();return n.sort((e,t)=>e.type.rank-t.type.rank),n}};cF.none=[];var cO=class extends Error{},cN=class e{constructor(e,t,n){this.content=e,this.openStart=t,this.openEnd=n}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,n){let i=function e(t,n,i,r,o,a){let{index:s,offset:l}=t.findIndex(n),d=t.maybeChild(s);if(l==n||d.isText)return a&&r<=0&&o<=0&&!a.canReplace(s,s,i)?null:t.cut(0,n).append(i).append(t.cut(n));let u=e(d.content,n-l-1,i,0==s?r-1:0,s==t.childCount-1?o-1:0,d);return u&&t.replaceChild(s,d.copy(u))}(this.content,t+this.openStart,n,this.openStart+1,this.openEnd+1);return i&&new e(i,this.openStart,this.openEnd)}removeBetween(t,n){return new e(function e(t,n,i){let{index:r,offset:o}=t.findIndex(n),a=t.maybeChild(r),{index:s,offset:l}=t.findIndex(i);if(o==n||a.isText){if(l!=i&&!t.child(s).isText)throw RangeError("Removing non-flat range");return t.cut(0,n).append(t.cut(i))}if(r!=s)throw RangeError("Removing non-flat range");return t.replaceChild(r,a.copy(e(a.content,n-o-1,i-o-1)))}(this.content,t+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e}static fromJSON(t,n){if(!n)return e.empty;let i=n.openStart||0,r=n.openEnd||0;if("number"!=typeof i||"number"!=typeof r)throw RangeError("Invalid input for Slice.fromJSON");return new e(cA.fromJSON(t,n.content),i,r)}static maxOpen(t,n=!0){let i=0,r=0;for(let e=t.firstChild;e&&!e.isLeaf&&(n||!e.type.spec.isolating);e=e.firstChild)i++;for(let e=t.lastChild;e&&!e.isLeaf&&(n||!e.type.spec.isolating);e=e.lastChild)r++;return new e(t,i,r)}};function cB(e,t){if(!t.type.compatibleContent(e.type))throw new cO("Cannot join "+t.type.name+" onto "+e.type.name)}function cz(e,t,n){let i=e.node(n);return cB(i,t.node(n)),i}function cj(e,t){let n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function cV(e,t,n,i){let r=(t||e).node(n),o=0,a=t?t.index(n):r.childCount;e&&(o=e.index(n),e.depth>n?o++:e.textOffset&&(cj(e.nodeAfter,i),o++));for(let e=o;e<a;e++)cj(r.child(e),i);t&&t.depth==n&&t.textOffset&&cj(t.nodeBefore,i)}function cH(e,t){return e.type.checkContent(t),e.copy(t)}function cG(e,t,n){let i=[];return cV(null,e,n,i),e.depth>n&&cj(cH(cz(e,t,n+1),cG(e,t,n+1)),i),cV(t,null,n,i),new cA(i)}cN.empty=new cN(cA.empty,0,0);var cW=class e{constructor(e,t,n){this.pos=e,this.path=t,this.parentOffset=n,this.depth=t.length/3-1}resolveDepth(e){return null==e?this.depth:e<0?this.depth+e:e}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(e){return this.path[3*this.resolveDepth(e)]}index(e){return this.path[3*this.resolveDepth(e)+1]}indexAfter(e){return e=this.resolveDepth(e),this.index(e)+(e!=this.depth||this.textOffset?1:0)}start(e){return 0==(e=this.resolveDepth(e))?0:this.path[3*e-1]+1}end(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size}before(e){if(!(e=this.resolveDepth(e)))throw RangeError("There is no position before the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]}after(e){if(!(e=this.resolveDepth(e)))throw RangeError("There is no position after the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]+this.path[3*e].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let e=this.parent,t=this.index(this.depth);if(t==e.childCount)return null;let n=this.pos-this.path[this.path.length-1],i=e.child(t);return n?e.child(t).cut(n):i}get nodeBefore(){let e=this.index(this.depth),t=this.pos-this.path[this.path.length-1];return t?this.parent.child(e).cut(0,t):0==e?null:this.parent.child(e-1)}posAtIndex(e,t){t=this.resolveDepth(t);let n=this.path[3*t],i=0==t?0:this.path[3*t-1]+1;for(let t=0;t<e;t++)i+=n.child(t).nodeSize;return i}marks(){let e=this.parent,t=this.index();if(0==e.content.size)return cF.none;if(this.textOffset)return e.child(t).marks;let n=e.maybeChild(t-1),i=e.maybeChild(t);if(!n){let e=n;n=i,i=e}let r=n.marks;for(var o=0;o<r.length;o++)!1!==r[o].type.spec.inclusive||i&&r[o].isInSet(i.marks)||(r=r[o--].removeFromSet(r));return r}marksAcross(e){let t=this.parent.maybeChild(this.index());if(!t||!t.isInline)return null;let n=t.marks,i=e.parent.maybeChild(e.index());for(var r=0;r<n.length;r++)!1!==n[r].type.spec.inclusive||i&&n[r].isInSet(i.marks)||(n=n[r--].removeFromSet(n));return n}sharedDepth(e){for(let t=this.depth;t>0;t--)if(this.start(t)<=e&&this.end(t)>=e)return t;return 0}blockRange(e=this,t){if(e.pos<this.pos)return e.blockRange(this);for(let n=this.depth-(this.parent.inlineContent||this.pos==e.pos?1:0);n>=0;n--)if(e.pos<=this.end(n)&&(!t||t(this.node(n))))return new cK(this,e,n);return null}sameParent(e){return this.pos-this.parentOffset==e.pos-e.parentOffset}max(e){return e.pos>this.pos?e:this}min(e){return e.pos<this.pos?e:this}toString(){let e="";for(let t=1;t<=this.depth;t++)e+=(e?"/":"")+this.node(t).type.name+"_"+this.index(t-1);return e+":"+this.parentOffset}static resolve(t,n){if(!(n>=0&&n<=t.content.size))throw RangeError("Position "+n+" out of range");let i=[],r=0,o=n;for(let e=t;;){let{index:t,offset:n}=e.content.findIndex(o),a=o-n;if(i.push(e,t,r+n),!a||(e=e.child(t)).isText)break;o=a-1,r+=n+1}return new e(n,i,o)}
311static resolveCached(t,n){let i=cq.get(t);if(i)for(let e=0;e<i.elts.length;e++){let t=i.elts[e];if(t.pos==n)return t}else cq.set(t,i=new c$);let r=i.elts[i.i]=e.resolve(t,n);return i.i=(i.i+1)%cU,r}},c$=class{constructor(){this.elts=[],this.i=0}},cU=12,cq=new WeakMap,cK=class{constructor(e,t,n){this.$from=e,this.$to=t,this.depth=n}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}},cY=Object.create(null);(class e{constructor(e,t,n,i=cF.none){this.type=e,this.attrs=t,this.marks=i,this.content=n||cA.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(e){return this.content.child(e)}maybeChild(e){return this.content.maybeChild(e)}forEach(e){this.content.forEach(e)}nodesBetween(e,t,n,i=0){this.content.nodesBetween(e,t,n,i,this)}descendants(e){this.nodesBetween(0,this.content.size,e)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(e,t,n,i){return this.content.textBetween(e,t,n,i)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)}sameMarkup(e){return this.hasMarkup(e.type,e.attrs,e.marks)}hasMarkup(e,t,n){return this.type==e&&cL(this.attrs,t||e.defaultAttrs||cY)&&cF.sameSet(this.marks,n||cF.none)}copy(t=null){return t==this.content?this:new e(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new e(this.type,this.attrs,this.content,t)}cut(e,t=this.content.size){return 0==e&&t==this.content.size?this:this.copy(this.content.cut(e,t))}slice(e,t=this.content.size,n=!1){if(e==t)return cN.empty;let i=this.resolve(e),r=this.resolve(t),o=n?0:i.sharedDepth(t),a=i.start(o);return new cN(i.node(o).content.cut(i.pos-a,r.pos-a),i.depth-o,r.depth-o)}replace(e,t,n){var i=this.resolve(e),r=this.resolve(t);if(n.openStart>i.depth)throw new cO("Inserted content deeper than insertion position");if(i.depth-n.openStart!=r.depth-n.openEnd)throw new cO("Inconsistent open depths");return function e(t,n,i,r){let o=t.index(r),a=t.node(r);if(o==n.index(r)&&r<t.depth-i.openStart){let s=e(t,n,i,r+1);return a.copy(a.content.replaceChild(o,s))}if(!i.content.size)return cH(a,cG(t,n,r));if(i.openStart||i.openEnd||t.depth!=r||n.depth!=r){let{start:e,end:o}=function(e,t){let n=t.depth-e.openStart,i=t.node(n).copy(e.content);for(let e=n-1;e>=0;e--)i=t.node(e).copy(cA.from(i));return{start:i.resolveNoCache(e.openStart+n),end:i.resolveNoCache(i.content.size-e.openEnd-n)}}(i,t);return cH(a,function e(t,n,i,r,o){let a=t.depth>o&&cz(t,n,o+1),s=r.depth>o&&cz(i,r,o+1),l=[];return cV(null,t,o,l),a&&s&&n.index(o)==i.index(o)?(cB(a,s),cj(cH(a,e(t,n,i,r,o+1)),l)):(a&&cj(cH(a,cG(t,n,o+1)),l),cV(n,i,o,l),s&&cj(cH(s,cG(i,r,o+1)),l)),cV(r,null,o,l),new cA(l)}(t,e,o,n,r))}{let e=t.parent,r=e.content;return cH(e,r.cut(0,t.parentOffset).append(i.content).append(r.cut(n.parentOffset)))}}(i,r,n,0)}nodeAt(e){for(let t=this;;){let{index:n,offset:i}=t.content.findIndex(e);if(!(t=t.maybeChild(n)))return null;if(i==e||t.isText)return t;e-=i+1}}childAfter(e){let{index:t,offset:n}=this.content.findIndex(e);return{node:this.content.maybeChild(t),index:t,offset:n}}childBefore(e){if(0==e)return{node:null,index:0,offset:0};let{index:t,offset:n}=this.content.findIndex(e);if(n<e)return{node:this.content.child(t),index:t,offset:n};let i=this.content.child(t-1);return{node:i,index:t-1,offset:n-i.nodeSize}}resolve(e){return cW.resolveCached(this,e)}resolveNoCache(e){return cW.resolve(this,e)}rangeHasMark(e,t,n){let i=!1;return t>e&&this.nodesBetween(e,t,e=>(n.isInSet(e.marks)&&(i=!0),!i)),i}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}
311toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let e=this.type.name;return this.content.size&&(e+="("+this.content.toStringInner()+")"),function(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+"("+t+")";return t}(this.marks,e)}contentMatchAt(e){let t=this.type.contentMatch.matchFragment(this.content,0,e);if(!t)throw Error("Called contentMatchAt on a node with invalid content");return t}canReplace(e,t,n=cA.empty,i=0,r=n.childCount){let o=this.contentMatchAt(e).matchFragment(n,i,r),a=o&&o.matchFragment(this.content,t);if(!a||!a.validEnd)return!1;for(let e=i;e<r;e++)if(!this.type.allowsMarks(n.child(e).marks))return!1;return!0}canReplaceWith(e,t,n,i){if(i&&!this.type.allowsMarks(i))return!1;let r=this.contentMatchAt(e).matchType(n),o=r&&r.matchFragment(this.content,t);return!!o&&o.validEnd}canAppend(e){return e.content.size?this.canReplace(this.childCount,this.childCount,e.content):this.type.compatibleContent(e.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let e=cF.none;for(let t=0;t<this.marks.length;t++){let n=this.marks[t];n.type.checkAttrs(n.attrs),e=n.addToSet(e)}if(!cF.sameSet(e,this.marks))throw RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(e=>e.type.name)}`);this.content.forEach(e=>e.check())}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return this.content.size&&(e.content=this.content.toJSON()),this.marks.length&&(e.marks=this.marks.map(e=>e.toJSON())),e}static fromJSON(e,t){let n;if(!t)throw RangeError("Invalid input for Node.fromJSON");if(t.marks){if(!Array.isArray(t.marks))throw RangeError("Invalid mark data for Node.fromJSON");n=t.marks.map(e.markFromJSON)}if("text"==t.type){if("string"!=typeof t.text)throw RangeError("Invalid text node in JSON");return e.text(t.text,n)}let i=cA.fromJSON(e,t.content),r=e.nodeType(t.type).create(t.attrs,i,n);return r.type.checkAttrs(r.attrs),r}}).prototype.text=void 0;var cZ=class e{constructor(e){this.validEnd=e,this.next=[],this.wrapCache=[]}static parse(t,n){var i;let r,o=new cX(t,n);if(null==o.next)return e.empty;let a=function e(t){let n=[];do n.push(function(t){let n=[];do n.push(function(t){let n=function(t){if(t.eat("(")){let n=e(t);return t.eat(")")||t.err("Missing closing paren"),n}if(/\W/.test(t.next))t.err("Unexpected token '"+t.next+"'");else{let e=(function(e,t){let n=e.nodeTypes,i=n[t];if(i)return[i];let r=[];for(let e in n){let i=n[e];i.isInGroup(t)&&r.push(i)}return 0==r.length&&e.err("No node type or group '"+t+"' found"),r})(t,t.next).map(e=>(null==t.inline?t.inline=e.isInline:t.inline!=e.isInline&&t.err("Mixing inline and block content"),{type:"name",value:e}));return t.pos++,1==e.length?e[0]:{type:"choice",exprs:e}}}(t);for(;;)if(t.eat("+"))n={type:"plus",expr:n};else if(t.eat("*"))n={type:"star",expr:n};else if(t.eat("?"))n={type:"opt",expr:n};else if(t.eat("{"))n=function(e,t){let n=cJ(e),i=n;return e.eat(",")&&(i="}"!=e.next?cJ(e):-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:n,max:i,expr:t}}(t,n);else break;return n}(t));while(t.next&&")"!=t.next&&"|"!=t.next)return 1==n.length?n[0]:{type:"seq",exprs:n}}(t));while(t.eat("|"))return 1==n.length?n[0]:{type:"choice",exprs:n}}(o);o.next&&o.err("Unexpected trailing text");let s=(i=function(e){let t=[[]];return r(function e(t,o){if("choice"==t.type)return t.exprs.reduce((t,n)=>t.concat(e(n,o)),[]);if("seq"==t.type)for(let i=0;;i++){let a=e(t.exprs[i],o);if(i==t.exprs.length-1)return a;r(a,o=n())}else if("star"==t.type){let a=n();return i(o,a),r(e(t.expr,a),a),[i(a)]}else if("plus"==t.type){let a=n();return r(e(t.expr,o),a),r(e(t.expr,a),a),[i(a)]}else if("opt"==t.type)return[i(o)].concat(e(t.expr,o));else if("range"==t.type){let a=o;for(let i=0;i<t.min;i++){let i=n();r(e(t.expr,a),i),a=i}if(-1==t.max)r(e(t.expr,a),a);else for(let o=t.min;o<t.max;o++){let o=n();i(a,o),r(e(t.expr,a),o),a=o}return[i(a)]}else if("name"==t.type)return[i(o,void 0,t.value)];else throw Error("Unknown expr type")}(e,0),n()),t;function n(){return t.push([])-1}function i(e,n,i){let r={term:i,to:n};return t[e].push(r),r}
311function r(e,t){e.forEach(e=>e.to=t)}}(a),r=Object.create(null),function e(t){let n=[];t.forEach(e=>{i[e].forEach(({term:e,to:t})=>{let r;if(e){for(let t=0;t<n.length;t++)n[t][0]==e&&(r=n[t][1]);c0(i,t).forEach(t=>{r||n.push([e,r=[]]),-1==r.indexOf(t)&&r.push(t)})}})});let o=r[t.join(",")]=new cZ(t.indexOf(i.length-1)>-1);for(let t=0;t<n.length;t++){let i=n[t][1].sort(cQ);o.next.push({type:n[t][0],next:r[i.join(",")]||e(i)})}return o}(c0(i,0)));return function(e,t){for(let n=0,i=[e];n<i.length;n++){let e=i[n],r=!e.validEnd,o=[];for(let t=0;t<e.next.length;t++){let{type:n,next:a}=e.next[t];o.push(n.name),r&&!(n.isText||n.hasRequiredAttrs())&&(r=!1),-1==i.indexOf(a)&&i.push(a)}r&&t.err("Only non-generatable nodes ("+o.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}(s,o),s}matchType(e){for(let t=0;t<this.next.length;t++)if(this.next[t].type==e)return this.next[t].next;return null}matchFragment(e,t=0,n=e.childCount){let i=this;for(let r=t;i&&r<n;r++)i=i.matchType(e.child(r).type);return i}get inlineContent(){return 0!=this.next.length&&this.next[0].type.isInline}get defaultType(){for(let e=0;e<this.next.length;e++){let{type:t}=this.next[e];if(!(t.isText||t.hasRequiredAttrs()))return t}return null}compatible(e){for(let t=0;t<this.next.length;t++)for(let n=0;n<e.next.length;n++)if(this.next[t].type==e.next[n].type)return!0;return!1}fillBefore(e,t=!1,n=0){let i=[this];return function r(o,a){let s=o.matchFragment(e,n);if(s&&(!t||s.validEnd))return cA.from(a.map(e=>e.createAndFill()));for(let e=0;e<o.next.length;e++){let{type:t,next:n}=o.next[e];if(!(t.isText||t.hasRequiredAttrs())&&-1==i.indexOf(n)){i.push(n);let e=r(n,a.concat(t));if(e)return e}}return null}(this,[])}findWrapping(e){for(let t=0;t<this.wrapCache.length;t+=2)if(this.wrapCache[t]==e)return this.wrapCache[t+1];let t=this.computeWrapping(e);return this.wrapCache.push(e,t),t}computeWrapping(e){let t=Object.create(null),n=[{match:this,type:null,via:null}];for(;n.length;){let i=n.shift(),r=i.match;if(r.matchType(e)){let e=[];for(let t=i;t.type;t=t.via)e.push(t.type);return e.reverse()}for(let e=0;e<r.next.length;e++){let{type:o,next:a}=r.next[e];o.isLeaf||o.hasRequiredAttrs()||o.name in t||i.type&&!a.validEnd||(n.push({match:o.contentMatch,type:o,via:i}),t[o.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(e){if(e>=this.next.length)throw RangeError(`There's no ${e}th edge in this content match`);return this.next[e]}toString(){let e=[];return!function t(n){e.push(n);for(let i=0;i<n.next.length;i++)-1==e.indexOf(n.next[i].next)&&t(n.next[i].next)}(this),e.map((t,n)=>{let i=n+(t.validEnd?"*":" ")+" ";for(let n=0;n<t.next.length;n++)i+=(n?", ":"")+t.next[n].type.name+"->"+e.indexOf(t.next[n].next);return i}).join("\n")}};cZ.empty=new cZ(!0);var cX=class{constructor(e,t){this.string=e,this.nodeTypes=t,this.inline=null,this.pos=0,this.tokens=e.split(/\s*(?=\b|\W|$)/),""==this.tokens[this.tokens.length-1]&&this.tokens.pop(),""==this.tokens[0]&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(e){return this.next==e&&(this.pos++||!0)}err(e){throw SyntaxError(e+" (in content expression '"+this.string+"')")}};function cJ(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");let t=Number(e.next);return e.pos++,t}function cQ(e,t){return t-e}function c0(e,t){let n=[];return function t(i){let r=e[i];if(1==r.length&&!r[0].term)return t(r[0].to);n.push(i);for(let e=0;e<r.length;e++){let{term:i,to:o}=r[e];i||-1!=n.indexOf(o)||t(o)}}(t),n.sort(cQ)}var c1=class{constructor(e,t,n){this.pos=e,this.delInfo=t,this.recover=n}get deleted(){return(8&this.delInfo)>0}get deletedBefore(){return(5&this.delInfo)>0}get deletedAfter(){return(6&this.delInfo)>0}get deletedAcross(){return(4&this.delInfo)>0}},c2=class e{constructor(t,n=!1){if(this.ranges=t,this.inverted=n,!t.length&&e.empty)return e.empty}recover(e){let t=0,n=65535&e;if(!this.inverted)for(let e=0;e<n;e++)t+=this.ranges[3*e+2]-this.ranges[3*e+1];return this.ranges[3*n]+t+(e-(65535&e))/65536}mapResult(e,t=1){return this._map(e,t,!1)}map(e,t=1){return this._map(e,t,!0)}_map(e,t,n){let i=0,r=this.inverted?2:1,o=this.inverted?1:2;
vendor: 10,509 bytes, line 311
311for(let a=0;a<this.ranges.length;a+=3){let s=this.ranges[a]-(this.inverted?i:0);if(s>e)break;let l=this.ranges[a+r],d=this.ranges[a+o],u=s+l;if(e<=u){let r=l?e==s?-1:e==u?1:t:t,o=s+i+(r<0?0:d);if(n)return o;let c=e==(t<0?s:u)?null:a/3+(e-s)*65536,h=e==s?2:e==u?1:4;return(t<0?e!=s:e!=u)&&(h|=8),new c1(o,h,c)}i+=d-l}return n?e+i:new c1(e+i,0,null)}touches(e,t){let n=0,i=65535&t,r=this.inverted?2:1,o=this.inverted?1:2;for(let t=0;t<this.ranges.length;t+=3){let a=this.ranges[t]-(this.inverted?n:0);if(a>e)break;let s=this.ranges[t+r];if(e<=a+s&&t==3*i)return!0;n+=this.ranges[t+o]-s}return!1}forEach(e){let t=this.inverted?2:1,n=this.inverted?1:2;for(let i=0,r=0;i<this.ranges.length;i+=3){let o=this.ranges[i],a=o-(this.inverted?r:0),s=o+(this.inverted?0:r),l=this.ranges[i+t],d=this.ranges[i+n];e(a,a+l,s,s+d),r+=d-l}}invert(){return new e(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(t){return 0==t?e.empty:new e(t<0?[0,-t,0]:[0,0,t])}};c2.empty=new c2([]);var c3=Object.create(null),c5=class{getMap(){return c2.empty}merge(e){return null}static fromJSON(e,t){if(!t||!t.stepType)throw RangeError("Invalid input for Step.fromJSON");let n=c3[t.stepType];if(!n)throw RangeError(`No step type ${t.stepType} defined`);return n.fromJSON(e,t)}static jsonID(e,t){if(e in c3)throw RangeError("Duplicate use of step JSON ID "+e);return c3[e]=t,t.prototype.jsonID=e,t}},c4=class e{constructor(e,t){this.doc=e,this.failed=t}static ok(t){return new e(t,null)}static fail(t){return new e(null,t)}static fromReplace(t,n,i,r){try{return e.ok(t.replace(n,i,r))}catch(t){if(t instanceof cO)return e.fail(t.message);throw t}}};function c6(e,t,n){let i=[];for(let r=0;r<e.childCount;r++){let o=e.child(r);o.content.size&&(o=o.copy(c6(o.content,t,o))),o.isInline&&(o=t(o,n,r)),i.push(o)}return cA.fromArray(i)}var c8=class e extends c5{constructor(e,t,n){super(),this.from=e,this.to=t,this.mark=n}apply(e){let t=e.slice(this.from,this.to),n=e.resolve(this.from),i=n.node(n.sharedDepth(this.to)),r=new cN(c6(t.content,(e,t)=>e.isAtom&&t.type.allowsMarkType(this.mark.type)?e.mark(this.mark.addToSet(e.marks)):e,i),t.openStart,t.openEnd);return c4.fromReplace(e,this.from,this.to,r)}invert(){return new c7(this.from,this.to,this.mark)}map(t){let n=t.mapResult(this.from,1),i=t.mapResult(this.to,-1);return n.deleted&&i.deleted||n.pos>=i.pos?null:new e(n.pos,i.pos,this.mark)}merge(t){return t instanceof e&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new e(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw RangeError("Invalid input for AddMarkStep.fromJSON");return new e(n.from,n.to,t.markFromJSON(n.mark))}};c5.jsonID("addMark",c8);var c7=class e extends c5{constructor(e,t,n){super(),this.from=e,this.to=t,this.mark=n}apply(e){let t=e.slice(this.from,this.to),n=new cN(c6(t.content,e=>e.mark(this.mark.removeFromSet(e.marks)),e),t.openStart,t.openEnd);return c4.fromReplace(e,this.from,this.to,n)}invert(){return new c8(this.from,this.to,this.mark)}map(t){let n=t.mapResult(this.from,1),i=t.mapResult(this.to,-1);return n.deleted&&i.deleted||n.pos>=i.pos?null:new e(n.pos,i.pos,this.mark)}merge(t){return t instanceof e&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new e(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw RangeError("Invalid input for RemoveMarkStep.fromJSON");return new e(n.from,n.to,t.markFromJSON(n.mark))}};c5.jsonID("removeMark",c7);var c9=class e extends c5{constructor(e,t){super(),this.pos=e,this.mark=t}apply(e){let t=e.nodeAt(this.pos);if(!t)return c4.fail("No node at mark step's position");let n=t.type.create(t.attrs,null,this.mark.addToSet(t.marks));return c4.fromReplace(e,this.pos,this.pos+1,new cN(cA.from(n),0,+!t.isLeaf))}invert(t){let n=t.nodeAt(this.pos);if(n){let t=this.mark.addToSet(n.marks);if(t.length==n.marks.length){for(let i=0;i<n.marks.length;i++)if(!n.marks[i].isInSet(t))return new e(this.pos,n.marks[i]);return new e(this.pos,this.mark)}}return new he(this.pos,this.mark)}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new e(n.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,n){if("number"!=typeof n.pos)throw RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new e(n.pos,t.markFromJSON(n.mark))}};c5.jsonID("addNodeMark",c9);var he=class e extends c5{constructor(e,t){super(),this.pos=e,this.mark=t}apply(e){let t=e.nodeAt(this.pos);if(!t)return c4.fail("No node at mark step's position");let n=t.type.create(t.attrs,null,this.mark.removeFromSet(t.marks));return c4.fromReplace(e,this.pos,this.pos+1,new cN(cA.from(n),0,+!t.isLeaf))}invert(e){let t=e.nodeAt(this.pos);return t&&this.mark.isInSet(t.marks)?new c9(this.pos,this.mark):this}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new e(n.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,n){if("number"!=typeof n.pos)throw RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new e(n.pos,t.markFromJSON(n.mark))}};c5.jsonID("removeNodeMark",he);var ht=class e extends c5{constructor(e,t,n,i=!1){super(),this.from=e,this.to=t,this.slice=n,this.structure=i}apply(e){return this.structure&&hi(e,this.from,this.to)?c4.fail("Structure replace would overwrite content"):c4.fromReplace(e,this.from,this.to,this.slice)}getMap(){return new c2([this.from,this.to-this.from,this.slice.size])}invert(t){return new e(this.from,this.from+this.slice.size,t.slice(this.from,this.to))}map(t){let n=t.mapResult(this.to,-1),i=this.from==this.to&&e.MAP_BIAS<0?n:t.mapResult(this.from,1);return i.deletedAcross&&n.deletedAcross?null:new e(i.pos,Math.max(i.pos,n.pos),this.slice,this.structure)}merge(t){if(!(t instanceof e)||t.structure||this.structure)return null;if(this.from+this.slice.size!=t.from||this.slice.openEnd||t.slice.openStart)if(t.to!=this.from||this.slice.openStart||t.slice.openEnd)return null;else{let n=this.slice.size+t.slice.size==0?cN.empty:new cN(t.slice.content.append(this.slice.content),t.slice.openStart,this.slice.openEnd);return new e(t.from,this.to,n,this.structure)}{let n=this.slice.size+t.slice.size==0?cN.empty:new cN(this.slice.content.append(t.slice.content),this.slice.openStart,t.slice.openEnd);return new e(this.from,this.to+(t.to-t.from),n,this.structure)}}toJSON(){let e={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(t,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw RangeError("Invalid input for ReplaceStep.fromJSON");return new e(n.from,n.to,cN.fromJSON(t,n.slice),!!n.structure)}};ht.MAP_BIAS=1,c5.jsonID("replace",ht);var hn=class e extends c5{constructor(e,t,n,i,r,o,a=!1){super(),this.from=e,this.to=t,this.gapFrom=n,this.gapTo=i,this.slice=r,this.insert=o,this.structure=a}apply(e){if(this.structure&&(hi(e,this.from,this.gapFrom)||hi(e,this.gapTo,this.to)))return c4.fail("Structure gap-replace would overwrite content");let t=e.slice(this.gapFrom,this.gapTo);if(t.openStart||t.openEnd)return c4.fail("Gap is not a flat range");let n=this.slice.insertAt(this.insert,t.content);return n?c4.fromReplace(e,this.from,this.to,n):c4.fail("Content does not fit in gap")}getMap(){return new c2([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(t){let n=this.gapTo-this.gapFrom;return new e(this.from,this.from+this.slice.size+n,this.from+this.insert,this.from+this.insert+n,t.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(t){let n=t.mapResult(this.from,1),i=t.mapResult(this.to,-1),r=this.from==this.gapFrom?n.pos:t.map(this.gapFrom,-1),o=this.to==this.gapTo?i.pos:t.map(this.gapTo,1);return n.deletedAcross&&i.deletedAcross||r<n.pos||o>i.pos?null:new e(n.pos,i.pos,r,o,this.slice,this.insert,this.structure)}toJSON(){let e={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(t,n){if("number"!=typeof n.from||"number"!=typeof n.to||"number"!=typeof n.gapFrom||"number"!=typeof n.gapTo||"number"!=typeof n.insert)throw RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new e(n.from,n.to,n.gapFrom,n.gapTo,cN.fromJSON(t,n.slice),n.insert,!!n.structure)}};function hi(e,t,n){let i=e.resolve(t),r=n-t,o=i.depth;for(;r>0&&o>0&&i.indexAfter(o)==i.node(o).childCount;)o--,r--;if(r>0){let e=i.node(o).maybeChild(i.indexAfter(o));for(;r>0;){if(!e||e.isLeaf)return!0;e=e.firstChild,r--}}return!1}c5.jsonID("replaceAround",hn);var hr=class e extends c5{constructor(e,t,n){super(),this.pos=e,this.attr=t,this.value=n}apply(e){let t=e.nodeAt(this.pos);if(!t)return c4.fail("No node at attribute step's position");let n=Object.create(null);for(let e in t.attrs)n[e]=t.attrs[e];n[this.attr]=this.value;let i=t.type.create(n,null,t.marks);return c4.fromReplace(e,this.pos,this.pos+1,new cN(cA.from(i),0,+!t.isLeaf))}getMap(){return c2.empty}invert(t){return new e(this.pos,this.attr,t.nodeAt(this.pos).attrs[this.attr])}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new e(n.pos,this.attr,this.value)}toJSON(){return{stepType:"attr",pos:this.pos,attr:this.attr,value:this.value}}static fromJSON(t,n){if("number"!=typeof n.pos||"string"!=typeof n.attr)throw RangeError("Invalid input for AttrStep.fromJSON");return new e(n.pos,n.attr,n.value)}};c5.jsonID("attr",hr);var ho=class e extends c5{constructor(e,t){super(),this.attr=e,this.value=t}apply(e){let t=Object.create(null);for(let n in e.attrs)t[n]=e.attrs[n];t[this.attr]=this.value;let n=e.type.create(t,e.content,e.marks);return c4.ok(n)}getMap(){return c2.empty}invert(t){return new e(this.attr,t.attrs[this.attr])}map(e){return this}toJSON(){return{stepType:"docAttr",attr:this.attr,value:this.value}}static fromJSON(t,n){if("string"!=typeof n.attr)throw RangeError("Invalid input for DocAttrStep.fromJSON");return new e(n.attr,n.value)}};c5.jsonID("docAttr",ho);
311var ha=class extends Error{};(ha=function e(t){let n=Error.call(this,t);return n.__proto__=e.prototype,n}).prototype=Object.create(Error.prototype),ha.prototype.constructor=ha,ha.prototype.name="TransformError";var hs=Object.create(null),hl=class{constructor(e,t,n){this.$anchor=e,this.$head=t,this.ranges=n||[new hd(e.min(t),e.max(t))]}get anchor(){return this.$anchor.pos}get head(){return this.$head.pos}get from(){return this.$from.pos}get to(){return this.$to.pos}get $from(){return this.ranges[0].$from}get $to(){return this.ranges[0].$to}get empty(){let e=this.ranges;for(let t=0;t<e.length;t++)if(e[t].$from.pos!=e[t].$to.pos)return!1;return!0}content(){return this.$from.doc.slice(this.from,this.to,!0)}replace(e,t=cN.empty){let n=t.content.lastChild,i=null;for(let e=0;e<t.openEnd;e++)i=n,n=n.lastChild;let r=e.steps.length,o=this.ranges;for(let a=0;a<o.length;a++){let{$from:s,$to:l}=o[a],d=e.mapping.slice(r);e.replaceRange(d.map(s.pos),d.map(l.pos),a?cN.empty:t),0==a&&hb(e,r,(n?n.isInline:i&&i.isTextblock)?-1:1)}}replaceWith(e,t){let n=e.steps.length,i=this.ranges;for(let r=0;r<i.length;r++){let{$from:o,$to:a}=i[r],s=e.mapping.slice(n),l=s.map(o.pos),d=s.map(a.pos);r?e.deleteRange(l,d):(e.replaceRangeWith(l,d,t),hb(e,n,t.isInline?-1:1))}}static findFrom(e,t,n=!1){let i=e.parent.inlineContent?new hh(e):hy(e.node(0),e.parent,e.pos,e.index(),t,n);if(i)return i;for(let i=e.depth-1;i>=0;i--){let r=t<0?hy(e.node(0),e.node(i),e.before(i+1),e.index(i),t,n):hy(e.node(0),e.node(i),e.after(i+1),e.index(i)+1,t,n);if(r)return r}return null}
vendor: 4,399 bytes, line 311
311static near(e,t=1){return this.findFrom(e,t)||this.findFrom(e,-t)||new hm(e.node(0))}static atStart(e){return hy(e,e,0,0,1)||new hm(e)}static atEnd(e){return hy(e,e,e.content.size,e.childCount,-1)||new hm(e)}static fromJSON(e,t){if(!t||!t.type)throw RangeError("Invalid input for Selection.fromJSON");let n=hs[t.type];if(!n)throw RangeError(`No selection type ${t.type} defined`);return n.fromJSON(e,t)}static jsonID(e,t){if(e in hs)throw RangeError("Duplicate use of selection JSON ID "+e);return hs[e]=t,t.prototype.jsonID=e,t}getBookmark(){return hh.between(this.$anchor,this.$head).getBookmark()}};hl.prototype.visible=!0;var hd=class{constructor(e,t){this.$from=e,this.$to=t}},hu=!1;function hc(e){hu||e.parent.inlineContent||(hu=!0,console.warn("TextSelection endpoint not pointing into a node with inline content ("+e.parent.type.name+")"))}var hh=class e extends hl{constructor(e,t=e){hc(e),hc(t),super(e,t)}get $cursor(){return this.$anchor.pos==this.$head.pos?this.$head:null}map(t,n){let i=t.resolve(n.map(this.head));if(!i.parent.inlineContent)return hl.near(i);let r=t.resolve(n.map(this.anchor));return new e(r.parent.inlineContent?r:i,i)}replace(e,t=cN.empty){if(super.replace(e,t),t==cN.empty){let t=this.$from.marksAcross(this.$to);t&&e.ensureMarks(t)}}eq(t){return t instanceof e&&t.anchor==this.anchor&&t.head==this.head}getBookmark(){return new hp(this.anchor,this.head)}toJSON(){return{type:"text",anchor:this.anchor,head:this.head}}static fromJSON(t,n){if("number"!=typeof n.anchor||"number"!=typeof n.head)throw RangeError("Invalid input for TextSelection.fromJSON");return new e(t.resolve(n.anchor),t.resolve(n.head))}static create(e,t,n=t){let i=e.resolve(t);return new this(i,n==t?i:e.resolve(n))}static between(t,n,i){let r=t.pos-n.pos;if((!i||r)&&(i=r>=0?1:-1),!n.parent.inlineContent){let e=hl.findFrom(n,i,!0)||hl.findFrom(n,-i,!0);if(!e)return hl.near(n,i);n=e.$head}return t.parent.inlineContent||(0==r?t=n:(t=(hl.findFrom(t,-i,!0)||hl.findFrom(t,i,!0)).$anchor).pos<n.pos!=r<0&&(t=n)),new e(t,n)}};hl.jsonID("text",hh);var hp=class e{constructor(e,t){this.anchor=e,this.head=t}map(t){return new e(t.map(this.anchor),t.map(this.head))}resolve(e){return hh.between(e.resolve(this.anchor),e.resolve(this.head))}},hf=class e extends hl{constructor(e){let t=e.nodeAfter,n=e.node(0).resolve(e.pos+t.nodeSize);super(e,n),this.node=t}map(t,n){let{deleted:i,pos:r}=n.mapResult(this.anchor),o=t.resolve(r);return i?hl.near(o):new e(o)}content(){return new cN(cA.from(this.node),0,0)}eq(t){return t instanceof e&&t.anchor==this.anchor}toJSON(){return{type:"node",anchor:this.anchor}}getBookmark(){return new hg(this.anchor)}static fromJSON(t,n){if("number"!=typeof n.anchor)throw RangeError("Invalid input for NodeSelection.fromJSON");return new e(t.resolve(n.anchor))}static create(t,n){return new e(t.resolve(n))}static isSelectable(e){return!e.isText&&!1!==e.type.spec.selectable}};hf.prototype.visible=!1,hl.jsonID("node",hf);var hg=class e{constructor(e){this.anchor=e}map(t){let{deleted:n,pos:i}=t.mapResult(this.anchor);return n?new hp(i,i):new e(i)}resolve(e){let t=e.resolve(this.anchor),n=t.nodeAfter;return n&&hf.isSelectable(n)?new hf(t):hl.near(t)}},hm=class e extends hl{constructor(e){super(e.resolve(0),e.resolve(e.content.size))}replace(e,t=cN.empty){if(t==cN.empty){e.delete(0,e.doc.content.size);let t=hl.atStart(e.doc);t.eq(e.selection)||e.setSelection(t)}else super.replace(e,t)}toJSON(){return{type:"all"}}static fromJSON(t){return new e(t)}map(t){return new e(t)}eq(t){return t instanceof e}getBookmark(){return hv}};hl.jsonID("all",hm);var hv={map(){return this},resolve:e=>new hm(e)};function hy(e,t,n,i,r,o=!1){if(t.inlineContent)return hh.create(e,n);for(let a=i-(r>0?0:1);r>0?a<t.childCount:a>=0;a+=r){let i=t.child(a);if(i.isAtom){if(!o&&hf.isSelectable(i))return hf.create(e,n-(r<0?i.nodeSize:0))}else{let t=hy(e,i,n+r,r<0?i.childCount:0,r,o);if(t)return t}n+=i.nodeSize*r}return null}function hb(e,t,n){let i,r=e.steps.length-1;if(r<t)return;let o=e.steps[r];(o instanceof ht||o instanceof hn)&&(e.mapping.maps[r].forEach((e,t,n,r)=>{null==i&&(i=r)}),e.setSelection(hl.near(e.doc.resolve(i),n)))}function hx(e,t){return t&&e?e.bind(t):e}var hw=class{constructor(e,t,n){this.name=e,this.init=hx(t.init,n),this.apply=hx(t.apply,n)}};new hw("doc",{init:e=>e.doc||e.schema.topNodeType.createAndFill(),apply:e=>e.doc}),new hw("selection",{init:(e,t)=>
311e.selection||hl.atStart(t.doc),apply:e=>e.selection}),new hw("storedMarks",{init:e=>e.storedMarks||null,apply:(e,t,n,i)=>i.selection.$cursor?e.storedMarks:null}),new hw("scrollToSelection",{init:()=>0,apply:(e,t)=>e.scrolledIntoView?t+1:t});var hC=/^\s*>\s$/,hS=lA.create({name:"blockquote",addOptions:()=>({HTMLAttributes:{}}),content:"block+",group:"block",defining:!0,parseHTML:()=>[{tag:"blockquote"}],renderHTML({HTMLAttributes:e}){return cI("blockquote",{...sh(this.options.HTMLAttributes,e),children:cI("slot",{})})},parseMarkdown:(e,t)=>{var n;let i=null!=(n=t.parseBlockChildren)?n:t.parseChildren;return t.createNode("blockquote",void 0,i(e.tokens||[]))},renderMarkdown:(e,t)=>{if(!e.content)return"";let n=[];return e.content.forEach((e,i)=>{var r,o;let a=(null!=(o=null==(r=t.renderChild)?void 0:r.call(t,e,i))?o:t.renderChildren([e])).split("\n").map(e=>""===e.trim()?">":`> ${e}`);n.push(a.join("\n"))}),n.join(` 312> 313`)},addCommands(){return{setBlockquote:()=>({commands:e})=>e.wrapIn(this.name),toggleBlockquote:()=>({commands:e})=>e.toggleWrap(this.name),unsetBlockquote:()=>({commands:e})=>e.lift(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-b":()=>this.editor.commands.toggleBlockquote(),Backspace:()=>((e,t)=>{var n;let{state:i,view:r}=e,{selection:o}=i;if(!o.empty)return!1;let{$from:a}=o;if(0!==a.parentOffset)return!1;let s=a.depth-1,l=a.node(s),d=a.index(s);if(0===d)return!1;if(l.type===t)return e.commands.lift(t.name);let u=l.child(d-1);if(u.type!==t||!(null==(n=u.lastChild)?void 0:n.isTextblock))return!1;let c=a.before(),h=c-1-1,{tr:p}=i;return p.delete(c,a.after()).insert(h,a.parent.content),p.setSelection(hh.create(p.doc,h)),r.dispatch(p.scrollIntoView()),!0})(this.editor,this.type)}}
313,addInputRules(){return[lI({find:hC,type:this.type})]}}),h_=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))$/,hk=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))/g,hM=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))$/,hT=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))/g,hD=ld.create({name:"bold",addOptions:()=>({HTMLAttributes:{}}),parseHTML(){return[{tag:"strong"},{tag:"b",getAttrs:e=>"normal"!==e.style.fontWeight&&null},{style:"font-weight=400",clearMark:e=>e.type.name===this.name},{style:"font-weight",getAttrs:e=>/^(bold(er)?|[5-9]\d{2,})$/.test(e)&&null}]},renderHTML({HTMLAttributes:e}){return cI("strong",{...sh(this.options.HTMLAttributes,e),children:cI("slot",{})})},markdownTokenName:"strong",parseMarkdown:(e,t)=>t.applyMark("bold",t.parseInline(e.tokens||[])),markdownOptions:{htmlReopen:{open:"<strong>",close:"</strong>"}},renderMarkdown:(e,t)=>`**${t.renderChildren(e)}**`,addCommands(){return{setBold:()=>({commands:e})=>e.setMark(this.name),toggleBold:()=>({commands:e})=>e.toggleMark(this.name),unsetBold:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-b":()=>this.editor.commands.toggleBold(),"Mod-B":()=>this.editor.commands.toggleBold()}},addInputRules(){return[lD({find:h_,type:this.type}
313),lD({find:hM,type:this.type})]},addPasteRules(){return[lP({find:hk,type:this.type}),lP({find:hT,type:this.type})]}}),hR=e=>{let t=/`([^`]+)`(?!`)$/.exec(e);return!t||t.index>0&&"`"===e[t.index-1]?null:{index:t.index,text:t[0],replaceWith:t[1]}},hI=e=>{let t,n=/`([^`]+)`(?!`)/g,i=[];for(;null!==(t=n.exec(e));)t.index>0&&"`"===e[t.index-1]||i.push({index:t.index,text:t[0],replaceWith:t[1]});return i},hA=ld.create({name:"code",addOptions:()=>({HTMLAttributes:{}}),excludes:"_",code:!0,exitable:!0,parseHTML:()=>[{tag:"code"}],renderHTML({HTMLAttributes:e}){return["code",sh(this.options.HTMLAttributes,e),0]},markdownTokenName:"codespan",parseMarkdown:(e,t)=>t.applyMark("code",[{type:"text",text:e.text||""}]),renderMarkdown:(e,t)=>e.content?`\`${t.renderChildren(e.content)}\``:"",addCommands(){return{setCode:()=>({commands:e})=>e.setMark(this.name),toggleCode:()=>({commands:e})=>e.toggleMark(this.name),unsetCode:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-e":()=>this.editor.commands.toggleCode()}}
313,addInputRules(){return[lD({find:hR,type:this.type})]},addPasteRules(){return[lP({find:hI,type:this.type})]}}),hP=/^```([a-z]+)?[\s\n]$/,hE=/^~~~([a-z]+)?[\s\n]$/,hL=lA.create({name:"codeBlock",addOptions:()=>({languageClassPrefix:"language-",exitOnTripleEnter:!0,exitOnArrowDown:!0,defaultLanguage:null,enableTabIndentation:!1,tabSize:4,HTMLAttributes:{}}),content:"text*",marks:"",group:"block",code:!0,defining:!0,addAttributes(){return{language:{default:this.options.defaultLanguage,parseHTML:e=>{var t;let{languageClassPrefix:n}=this.options;if(!n)return null;let i=[...(null==(t=e.firstElementChild)?void 0:t.classList)||[]].filter(e=>e.startsWith(n)).map(e=>e.replace(n,""))[0];return i||null},rendered:!1}}},parseHTML:()=>[{tag:"pre",preserveWhitespace:"full"}],renderHTML({node:e,HTMLAttributes:t}){return["pre",sh(this.options.HTMLAttributes,t),["code",{class:e.attrs.language?this.options.languageClassPrefix+e.attrs.language:null},0]]},markdownTokenName:"code",parseMarkdown:(e,t)=>{var n,i;return(null==(n=e.raw)?void 0:n.startsWith("```"))===!1&&(null==(i=e.raw)?void 0:i.startsWith("~~~"))===!1&&"indented"!==e.codeBlockStyle?[]:t.createNode("codeBlock",{language:e.lang||null},e.text?[t.createTextNode(e.text)]:[])},renderMarkdown:(e,t)=>{var n;let i=(null==(n=e.attrs)?void 0:n.language)||"";return e.content?[`\`\`\`${i}`,t.renderChildren(e.content),"```"].join("\n"):`\`\`\`${i} 314 315\`\`\``},addCommands(){return{setCodeBlock:e=>({commands:t})=>t.setNode(this.name,e),toggleCodeBlock:e=>({commands:t})=>t.toggleNode(this.name,"paragraph",e)}},addKeyboardShortcuts(){return{"Mod-Alt-c":()=>this.editor.commands.toggleCodeBlock(),Backspace:()=>{let{empty:e,$anchor:t}=this.editor.state.selection,n=1===t.pos;return!!e&&t.parent.type.name===this.name&&(!!n||!t.parent.textContent.length)&&this.editor.commands.clearNodes()},Tab:({editor:e})=>{var t;if(!this.options.enableTabIndentation)return!1;let n=null!=(t=this.options.tabSize)?t:4,{state:i}=e,{selection:r}=i,{$from:o,empty:a}=r;if(o.parent.type!==this.type)return!1;let s=" ".repeat(n);return a?e.commands.insertContent(s):e.commands.command(({tr:e})=>{let{from:t,to:n}=r,o=i.doc.textBetween(t,n,"\n","\n").split("\n").map(e=>s+e).join("\n");return e.replaceWith(t,n,i.schema.text(o)),!0})},"Shift-Tab":({editor:e})=>{var t;if(!this.options.enableTabIndentation)return!1;let n=null!=(t=this.options.tabSize)?t:4,{state:i}=e,{selection:r}=i,{$from:o,empty:a}=r;return o.parent.type===this.type&&(a?e.commands.command(({tr:e})=>{var t;let{pos:r}=o,a=o.start(),s=o.end(),l=i.doc.textBetween(a,s,"\n","\n").split("\n"),d=0,u=0,c=r-a;for(let e=0;e<l.length;e+=1){if(u+l[e].length>=c){d=e;break}u+=l[e].length+1}let h=Math.min(((null==(t=l[d].match(/^ */))?void 0:t[0])||"").length,n);if(0===h)return!0;let p=a;for(let e=0;e<d;e+=1)p+=l[e].length+1;return e.delete(p,p+h),r-p<=h&&e.setSelection(nO.create(e.doc,p)),!0}):e.commands.command(({tr:e})=>{let{from:t,to:o}=r,a=i.doc.textBetween(t,o,"\n","\n").split("\n").map(e=>{var t;let i=Math.min(((null==(t=e.match(/^ */))?void 0:t[0])||"").length,n);return e.slice(i)}).join("\n");return e.replaceWith(t,o,i.schema.text(a)),!0}))},Enter:({editor:e})=>{if(!this.options.exitOnTripleEnter)return!1;let{state:t}=e,{selection:n}=t,{$from:i,empty:r}=n;if(!r||i.parent.type!==this.type)return!1;let o=i.parentOffset===i.parent.nodeSize-2,a=i.parent.textContent.endsWith("\n\n");return!!o&&!!a&&e.chain().command(({tr:e})=>(e.delete(i.pos-2,i.pos),!0)).exitCode().run()},ArrowDown:({editor:e})=>{if(!this.options.exitOnArrowDown)return!1;let{state:t}=e,{selection:n,doc:i}=t,{$from:r,empty:o}=n;if(!o||r.parent.type!==this.type||r.parentOffset!==r.parent.nodeSize-2)return!1;let a=r.after();return void 0!==a&&(i.nodeAt(a)?e.commands.command(({tr:e})=>(e.setSelection(nP.near(i.resolve(a))),!0)):e.commands.exitCode())}}},addInputRules(){return[lR({find:hP,type:this.type,getAttributes:e=>({language:e[1]})}
315),lR({find:hE,type:this.type,getAttributes:e=>({language:e[1]})})]},addProseMirrorPlugins(){return[new nZ({key:new nQ("codeBlockVSCodeHandler"),props:{handlePaste:(e,t)=>{if(!t.clipboardData||this.editor.isActive(this.type.name))return!1;let n=t.clipboardData.getData("text/plain"),i=t.clipboardData.getData("vscode-editor-data"),r=i?JSON.parse(i):void 0,o=null==r?void 0:r.mode;if(!n||!o)return!1;let{tr:a,schema:s}=e.state,l=s.text(n.replace(/\r\n?/g,"\n"));return a.replaceSelectionWith(this.type.create({language:o},l)),a.selection.$from.parent.type!==this.type&&a.setSelection(nO.near(a.doc.resolve(Math.max(0,a.selection.from-2)))),a.setMeta("paste",!0),e.dispatch(a),!0}}})]}}),hF=lA.create({name:"doc",topNode:!0,content:"block+",renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n\n"):""}),hO=lA.create({name:"hardBreak",markdownTokenName:"br",addOptions:()=>({keepMarks:!0,HTMLAttributes:{}}),inline:!0,group:"inline",selectable:!1,linebreakReplacement:!0,parseHTML:()=>[{tag:"br"}],renderHTML({HTMLAttributes:e}){return["br",sh(this.options.HTMLAttributes,e)]},renderText:()=>"\n",renderMarkdown:()=>` 316`,parseMarkdown:()=>({type:"hardBreak"}),addCommands(){return{setHardBreak:()=>({commands:e,chain:t,state:n,editor:i})=>e.first([()=>e.exitCode(),()=>e.command(()=>{let{selection:e,storedMarks:r}=n;if(e.$from.parent.type.spec.isolating)return!1;let{keepMarks:o}=this.options,{splittableMarks:a}=i.extensionManager,s=r||e.$to.parentOffset&&e.$from.marks();return t().insertContent({type:this.name}).command(({tr:e,dispatch:t})=>{if(t&&s&&o){let t=s.filter(e=>a.includes(e.type.name));e.ensureMarks(t)}return!0}).run()})])}},addKeyboardShortcuts(){return{"Mod-Enter":()=>this.editor.commands.setHardBreak(),"Shift-Enter":()=>this.editor.commands.setHardBreak()}}}),hN=lA.create({name:"heading",addOptions:()=>({levels:[1,2,3,4,5,6],HTMLAttributes:{}}),content:"inline*",group:"block",defining:!0,addAttributes:()=>({level:{default:1,rendered:!1}}),parseHTML(){return this.options.levels.map(e=>({tag:`h${e}`,attrs:{level:e}}))},renderHTML({node:e,HTMLAttributes:t}){let n=this.options.levels.includes(e.attrs.level)?e.attrs.level:this.options.levels[0];return[`h${n}`,sh(this.options.HTMLAttributes,t),0]},parseMarkdown:(e,t)=>t.createNode("heading",{level:e.depth||1},t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>{var n;let i=(null==(n=e.attrs)?void 0:n.level)?parseInt(e.attrs.level,10):1,r="#".repeat(i);return e.content?`${r} ${t.renderChildren(e.content)}`:""},addCommands(){return{setHeading:e=>({commands:t})=>!!this.options.levels.includes(e.level)&&t.setNode(this.name,e),toggleHeading:e=>({commands:t})=>!!this.options.levels.includes(e.level)&&t.toggleNode(this.name,"paragraph",e)}},addKeyboardShortcuts(){return this.options.levels.reduce((e,t)=>({...e,[`Mod-Alt-${t}`]:()=>this.editor.commands.toggleHeading({level:t})}),{})},addInputRules(){return this.options.levels.map(e=>lR({find:RegExp(`^(#{${Math.min(...this.options.levels)},${e}}
316)\\s$`),type:this.type,getAttributes:{level:e}}))}}),hB=lA.create({name:"horizontalRule",addOptions:()=>({HTMLAttributes:{},nextNodeType:"paragraph"}),group:"block",parseHTML:()=>[{tag:"hr"}],renderHTML({HTMLAttributes:e}){return["hr",sh(this.options.HTMLAttributes,e)]},markdownTokenName:"hr",parseMarkdown:(e,t)=>t.createNode("horizontalRule"),renderMarkdown:()=>"---",addCommands(){return{setHorizontalRule:()=>({chain:e,state:t})=>{if(!function(e,t){let{selection:n}=e,{$from:i}=n;if(n instanceof nB){let e=i.index();return i.parent.canReplaceWith(e,e+1,t)}let r=i.depth;for(;r>=0;){let e=i.index(r);if(i.node(r).contentMatchAt(e).matchType(t))return!0;r-=1}return!1}(t,t.schema.nodes[this.name]))return!1;let{selection:n}=t,{$to:i}=n,r=e();return sI(n)?r.insertContentAt(i.pos,{type:this.name}):r.insertContent({type:this.name}),r.command(({state:e,tr:t,dispatch:n})=>{if(n){let{$to:n}=t.selection,i=n.end();if(n.nodeAfter)n.nodeAfter.isTextblock?t.setSelection(nO.create(t.doc,n.pos+1)):n.nodeAfter.isBlock?t.setSelection(nB.create(t.doc,n.pos)):t.setSelection(nO.create(t.doc,n.pos));else{let r=e.schema.nodes[this.options.nextNodeType]||n.parent.type.contentMatch.defaultType,o=null==r?void 0:r.create();o&&(t.insert(i,o),t.setSelection(nO.create(t.doc,i+1)))}t.scrollIntoView()}return!0}).run()}}},addInputRules(){var e;return[new la({find:(e={find:/^(?:---|â-|___\s|\*\*\*\s)$/,type:this.t
316ype}).find,handler:({state:t,range:n,match:i})=>{let r=sl(e.getAttributes,void 0,i)||{},{tr:o}=t,a=n.from,s=n.to,l=e.type.create(r);if(i[1]){let e=a+i[0].lastIndexOf(i[1]);e>s?e=s:s=e+i[1].length;let t=i[0][i[0].length-1];o.insertText(t,a+i[0].length-1),o.replaceWith(e,s,l)}else if(i[0]){let t=e.type.isInline?a:a-1;o.insert(t,e.type.create(r)).delete(o.mapping.map(a),o.mapping.map(s))}o.scrollIntoView()},undoable:e.undoable})]}}),hz=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))$/,hj=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))/g,hV=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))$/,hH=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))/g,hG=ld.create({name:"italic",addOptions:()=>({HTMLAttributes:{}}),parseHTML(){return[{tag:"em"},{tag:"i",getAttrs:e=>"normal"!==e.style.fontStyle&&null},{style:"font-style=normal",clearMark:e=>e.type.name===this.name},{style:"font-style=italic"}]},renderHTML({HTMLAttributes:e}){return["em",sh(this.options.HTMLAttributes,e),0]},addCommands(){return{setItalic:()=>({commands:e})=>e.setMark(this.name),toggleItalic:()=>({commands:e})=>e.toggleMark(this.name),unsetItalic:()=>({commands:e})=>e.unsetMark(this.name)}},markdownTokenName:"em",parseMarkdown:(e,t)=>t.applyMark("italic",t.parseInline(e.tokens||[])),markdownOptions:{htmlReopen:{open:"<em>",close:"</em>"}},renderMarkdown:(e,t)=>`*${t.renderChildren(e)}*`,addKeyboardShortcuts(){return{"Mod-i":()=>this.editor.commands.toggleItalic(),"Mod-I":()=>this.editor.commands.toggleItalic()}},addInputRules(){return[lD({find:hz,type:this.type}
316),lD({find:hV,type:this.type})]},addPasteRules(){return[lP({find:hj,type:this.type}),lP({find:hH,type:this.type})]}});let hW="numeric",h$="ascii",hU="alpha",hq="asciinumeric",hK="alphanumeric",hY="domain",hZ="emoji",hX="whitespace";function hJ(e,t,n){for(let i in t[hW]&&(t[hq]=!0,t[hK]=!0),t[h$]&&(t[hq]=!0,t[hU]=!0),t[hq]&&(t[hK]=!0),t[hU]&&(t[hK]=!0),t[hK]&&(t[hY]=!0),t[hZ]&&(t[hY]=!0),t){let t=(i in n||(n[i]=[]),n[i]);0>t.indexOf(e)&&t.push(e)}}function hQ(e=null){this.j={},this.jr=[],this.jd=null,this.t=e}hQ.groups={},hQ.prototype={accepts(){return!!this.t},go(e){let t=this.j[e];if(t)return t;for(let t=0;t<this.jr.length;t++){let n=this.jr[t][0],i=this.jr[t][1];if(i&&n.test(e))return i}return this.jd},has(e,t=!1){return t?e in this.j:!!this.go(e)},ta(e,t,n,i){for(let r=0;r<e.length;r++)this.tt(e[r],t,n,i)},tr(e,t,n,i){let r;return i=i||hQ.groups,t&&t.j?r=t:(r=new hQ(t),n&&i&&hJ(t,n,i)),this.jr.push([e,r]),r},ts(e,t,n,i){let r=this,o=e.length;if(!o)return r;for(let t=0;t<o-1;t++)r=r.tt(e[t]);return r.tt(e[o-1],t,n,i)},tt(e,t,n,i){if(i=i||hQ.groups,t&&t.j)return this.j[e]=t,t;let r,o=this.go(e);return o?(Object.assign((r=new hQ).j,o.j),r.jr.push.apply(r.jr,o.jr),r.jd=o.jd,r.t=o.t):r=new hQ,t&&(i&&(r.t&&"string"==typeof r.t?hJ(t,Object.assign(function(e,t){let n={};for(let i in t)t[i].indexOf(e)>=0&&(n[i]=!0);return n}(r.t,i),n),i):n&&hJ(t,n,i)),r.t=t),this.j[e]=r,r}};let h0=(e,t,n,i,r)=>e.ta(t,n,i,r),h1=(e,t,n,i,r)=>e.tr(t,n,i,r),h2=(e,t,n,i,r)=>e.ts(t,n,i,r),h3=(e,t,n,i,r)=>e.tt(t,n,i,r),h5="WORD",h4="UWORD",h6="ASCIINUMERICAL",h8="ALPHANUMERICAL",h7="LOCALHOST",h9="UTLD",pe="SCHEME",pt="SLASH_SCHEME",pn="OPENBRACE",pi="CLOSEBRACE",pr="OPENBRACKET",po="
316CLOSEBRACKET",pa="OPENPAREN",ps="CLOSEPAREN",pl="OPENANGLEBRACKET",pd="CLOSEANGLEBRACKET",pu="FULLWIDTHLEFTPAREN",pc="FULLWIDTHRIGHTPAREN",ph="LEFTCORNERBRACKET",pp="RIGHTCORNERBRACKET",pf="LEFTWHITECORNERBRACKET",pg="RIGHTWHITECORNERBRACKET",pm="FULLWIDTHLESSTHAN",pv="FULLWIDTHGREATERTHAN",py="AMPERSAND",pb="APOSTROPHE",px="ASTERISK",pw="BACKSLASH",pC="BACKTICK",pS="CARET",p_="COLON",pk="COMMA",pM="DOLLAR",pT="EQUALS",pD="EXCLAMATION",pR="HYPHEN",pI="PERCENT",pA="PIPE",pP="PLUS",pE="POUND",pL="QUERY",pF="QUOTE",pO="FULLWIDTHMIDDLEDOT",pN="SEMI",pB="SLASH",pz="TILDE",pj="UNDERSCORE",pV="EMOJI";var pH=Object.freeze({__proto__:null,ALPHANUMERICAL:h8,AMPERSAND:py,APOSTROPHE:pb,ASCIINUMERICAL:h6,ASTERISK:px,AT:"AT",BACKSLASH:pw,BACKTICK:pC,CARET:pS,CLOSEANGLEBRACKET:pd,CLOSEBRACE:pi,CLOSEBRACKET:po,CLOSEPAREN:ps,COLON:p_,COMMA:pk,DOLLAR:pM,DOT:"DOT",EMOJI:pV,EQUALS:pT,EXCLAMATION:pD,FULLWIDTHGREATERTHAN:pv,FULLWIDTHLEFTPAREN:pu,FULLWIDTHLESSTHAN:pm,FULLWIDTHMIDDLEDOT:pO,FULLWIDTHRIGHTPAREN:pc,HYPHEN:pR,LEFTCORNERBRACKET:ph,LEFTWHITECORNERBRACKET:pf,LOCALHOST:h7,NL:"NL",NUM:"NUM",OPENANGLEBRACKET:pl,OPENBRACE:pn,OPENBRACKET:pr,OPENPAREN:pa,PERCENT:pI,PIPE:pA,PLUS:pP,POUND:pE,QUERY:pL,QUOTE:pF,RIGHTCORNERBRACKET:pp,RIGHTWHITECORNERBRACKET:pg,SCHEME:pe,SEMI:pN,SLASH:pB,SLASH_SCHEME:pt,SYM:"SYM",TILDE:pz,TLD:"TLD",UNDERSCORE:pj,UTLD:h9,UWORD:h4,WORD:h5,WS:"WS"});let pG=/[a-z]/,pW=/\p{L}/u,p$=/\p{Emoji}/u,pU=/\d/,pq=/\s/,pK=null,pY=null;function pZ(e,t){let n=function(e){let t=[],n=e.length,i=0;for(;i<n;){let r,o=e.charCodeAt(i),a=o<55296||o>56319||i+1===n||(r=e.charCodeAt(i+1))<56320||r>57343?e[i]:e.slice(i,i+2);t.push(a),i+=a.length}return t}(t.replace(/[A-Z]/g,e=>e.toLowerCase())),i=n.length,r=[],o=0,a=0;for(;a<i;){let s=e,l=null,d=0,u=null,c=-1,h=-1;for(;a<i&&(l=s.go(n[a]));)(s=l).accepts()?(c=0,h=0,u=s):c>=0&&(c+=n[a].length,h++),d+=n[a].length,o+=n[a].length,a++;o-=c,a-=h,d-=c,r.push({t:u.t,v:t.slice(o-d,o),s:o-d,e:o})}return r}function pX(e,t,n,i,r){let o,a=t.length;for(let n=0;n<a-1;n++){let a=t[n];e.j[a]?o=e.j[a]:((o=new hQ(i)).jr=r.slice(),e.j[a]=o),e=o}return(o=new hQ(n)).jr=r.slice(),e.j[t[a-1]]=o,o}function pJ(e){let t=[],n=[],i=0;for(;i<e.length;){let r=0;for(;"0123456789".indexOf(e[i+r])>=0;)r++;if(r>0){t.push(n.join(""));for(let t=parseInt(e.substring(i,i+r),10);t>0;t--)n.pop();i+=r}else n.push(e[i]),i++}return t}let pQ={defaultProtocol:"http",events:null,format:p1,formatHref:p1,nl2br:!1,tagName:"a",target:null,rel:null,validate:!0,truncate:1/0,className:null,attributes:null,ignoreTags:[],render:null};function p0(e,t=null){let n=Object.assign({},pQ);e&&(n=Object.assign(n,e instanceof p0?e.o:e));let i=n.ignoreTags,r=[];for(let e=0;e<i.length;e++)r.push(i[e].toUpperCase());this.o=n,t&&(this.defaultRender=t),this.ignoreTags=r}function p1(e){return e}function p2(e,t){this.t="token",this.v=e,this.tk=t}function p3(e,t){class n extends p2{constructor(t,n){super(t,n),this.t=e}}for(let e in t)n.prototype[e]=t[e];return n.t=e,n}p0.prototype={o:pQ,ignoreTags:[],defaultRender:e=>e,check(e){return this.get("validate",e.toString(),e)},get(e,t,n){let i=null!=t,r=this.o[e];return r&&("object"==typeof r?"function"==typeof(r=n.t in r?r[n.t]:pQ[e])&&i&&(r=r(t,n)):"function"==typeof r&&i&&(r=r(t,n.t,n))),r},getObj(e,t,n){let i=this.o[e];return"function"==typeof i&&null!=t&&(i=i(t,n.t,n)),i},render(e){let t=e.render(this);return(this.get("render",null,e)||this.defaultRender)(t,e.t,e)}},p2.prototype={isLink:!1,toString(){return this.v},toHref(e){return this.toString()},toFormattedString(e){let t=this.toString(),n=e.get("truncate",t,this),i=e.get("format",t,this);return n&&i.length>n?i.substring(0,n)+"â¦":i},toFormattedHref(e){return e.get("formatHref",this.toHref(e.get("defaultProtocol")),this)},startIndex(){return this.tk[0].s},endIndex(){return this.tk[this.tk.length-1].e},toObject(e=pQ.defaultProtocol){return{type:this.t,value:this.toString(),isLink:this.isLink,href:this.toHref(e),start:this.startIndex(),end:this.endIndex()}},toFormattedObject(e){return{type:this.t,value:this.toFormattedString(e),isLink:this.isLink,href:this.toFormattedHref(e),start:this.startIndex(),end:this.endIndex()}},validate(e){return e.get("validate",this.toString(),this)},render(e){let t=this.toHref(e.get("defaultProtocol")),n=e.get("formatHref",t,this),i=e.get("tagName",t,this),r=this.toFormattedString(e),o={}
316,a=e.get("className",t,this),s=e.get("target",t,this),l=e.get("rel",t,this),d=e.getObj("attributes",t,this),u=e.getObj("events",t,this);return o.href=n,a&&(o.class=a),s&&(o.target=s),l&&(o.rel=l),d&&Object.assign(o,d),{tagName:i,attributes:o,content:r,eventListeners:u}}};let p5=p3("email",{isLink:!0,toHref(){return"mailto:"+this.toString()}}),p4=p3("text"),p6=p3("nl"),p8=p3("url",{isLink:!0,toHref(e=pQ.defaultProtocol){return this.hasProtocol()?this.v:`${e}://${this.v}`},hasProtocol(){let e=this.tk;return e.length>=2&&e[0].t!==h7&&e[1].t===p_}}),p7=e=>new hQ(e);function p9(e,t,n){let i=n[0].s,r=n[n.length-1].e;return new e(t.slice(i,r),n)}let fe="u">typeof console&&console&&console.warn||(()=>{}),ft={scanner:null,parser:null,tokenQueue:[],pluginQueue:[],customSchemes:[],initialized:!1};function fn(e,t=!1){if(ft.initialized&&fe(`linkifyjs: already initialized - will not register custom scheme "${e}" until manual call of linkify.init(). Register all schemes and plugins before invoking linkify the first time.`),!/^[0-9a-z]+(-[0-9a-z]+)*$/.test(e))throw Error(`linkifyjs: incorrect scheme format. 3171. Must only contain digits, lowercase ASCII letters or "-" 3182. Cannot start or end with "-" 3193. "-" cannot repeat`);ft.customSchemes.push([e,t])}function fi(e){return ft.initialized||function(){ft.scanner=function(e=[]){let t={};hQ.groups=t;let n=new hQ;null==pK&&(pK=pJ("aaa1rp3bb0ott3vie4c1le2ogado5udhabi7c0ademy5centure6ountant0s9o1tor4d0s1ult4e0g1ro2tna4f0l1rica5g0akhan5ency5i0g1rbus3force5tel5kdn3l0ibaba4pay4lfinanz6state5y2sace3tom5m0azon4ericanexpress7family11x2fam3ica3sterdam8nalytics7droid5quan4z2o0l2partments8p0le4q0uarelle8r0ab1mco4chi3my2pa2t0e3s0da2ia2sociates9t0hleta5torney7u0ction5di0ble3o3spost5thor3o0s4w0s2x0a2z0ure5ba0by2idu3namex4d1k2r0celona5laycard4s5efoot5gains6seball5ketball8uhaus5yern5b0c1t1va3cg1n2d1e0ats2uty4er2rlin4st0buy5t2f1g1h0arti5i0ble3d1ke2ng0o3o1z2j1lack0friday9ockbuster8g1omberg7ue3m0s1w2n0pparibas9o0ats3ehringer8fa2m1nd2o0k0ing5sch2tik2on4t1utique6x2r0adesco6idgestone9oadway5ker3ther5ussels7s1t1uild0ers6siness6y1zz3v1w1y1z0h3ca0b1fe2l0l1vinklein9m0era3p2non3petown5ital0one8r0avan4ds2e0er0s4s2sa1e1h1ino4t0ering5holic7ba1n1re3c1d1enter4o1rn3f0a1d2g1h0anel2nel4rity4se2t2eap3intai5ristmas6ome4urch5i0priani6rcle4sco3tadel4i0c2y3k1l0aims4eaning6ick2nic1que6othing5ud3ub0med6m1n1o0ach3des3ffee4llege4ogne5m0mbank4unity6pany2re3uter5sec4ndos3struction8ulting7tact3ractors9oking4l1p2rsica5untry4pon0s4rses6pa2r0edit0card4union9icket5own3s1uise0s6u0isinella9v1w1x1y0mru3ou3z2dad1nce3ta1e1ing3sun4y2clk3ds2e0al0er2s3gree4livery5l1oitte5ta3mocrat6ntal2ist5si0gn4v2hl2iamonds6et2gital5rect0ory7scount3ver5h2y2j1k1m1np2o0cs1tor4g1mains5t1wnload7rive4tv2ubai3pont4rban5vag2r2z2earth3t2c0o2deka3u0cation8e1g1mail3erck5nergy4gineer0ing9terprises10pson4quipment8r0icsson6ni3s0q1tate5t1u0rovision8s2vents5xchange6pert3osed4ress5traspace10fage2il1rwinds6th3mily4n0s2rm0ers5shion4t3edex3edback6rrari3ero6i0delity5o2lm2nal1nce1ial7re0stone6mdale6sh0ing5t0ness6j1k1lickr3ghts4r2orist4wers5y2m1o0o0d1tball6rd1ex2sale4um3undation8x2r0ee1senius7l1ogans4ntier7tr2ujitsu5n0d2rniture7tbol5yi3ga0l0lery3o1up4me0s3p1rden4y2b0iz3d0n2e0a1nt0ing5orge5f1g0ee3h1i0ft0s3ves2ing5l0ass3e1obal2o4m0ail3bh2o1x2n1odaddy5ld0point6f2odyear5g0le4p1t1v2p1q1r0ainger5phics5tis4een3ipe3ocery4up4s1t1u0cci3ge2ide2tars5ru3w1y2hair2mburg5ngout5us3bo2dfc0bank7ealth0care8lp1sinki6re1mes5iphop4samitsu7tachi5v2k0t2m1n1ockey4ldings5iday5medepot5goods5s0ense7nda3rse3spital5t0ing5t0els3mail5use3w2r1sbc3t1u0ghes5yatt3undai7ibm2cbc2e1u2d1e0ee3fm2kano4l1m0amat4db2mo0bilien9n0c1dustries8finiti5o2g1k1stitute6urance4e4t0ernational10uit4vestments10o1piranga7q1r0ish4s0maili5t0anbul7t0au2v3jaguar4va3cb2e0ep2tzt3welry6io2ll2m0p2nj2o0bs1urg4t1y2p0morgan6rs3uegos4niper7kaufen5ddi3e0rryhotels6properties14fh2g1h1i0a1ds2m1ndle4tchen5wi3m1n1oeln3matsu5sher5p0mg2n2r0d1ed3uokgroup8w1y0oto4z2la0caixa5mborghini8er3nd0rover6xess5salle5t0ino3robe5w0yer5b1c1ds2ease3clerc5frak4gal2o2xus4gbt3i0dl2fe0insurance9style7ghting6ke2lly3mited4o2ncoln4k2ve1ing5k1lc1p2oan0s3cker3us3l1ndon4tte1o3ve3pl0financial11r1s1t0d0a3u0ndbeck6xe1ury5v1y2ma0drid4if1son4keup4n0agement7go3p1rket0ing3s4riott5shalls7ttel5ba2c0kinsey7d1e0d0ia3et2lbourne7me1orial6n0u2rck0msd7g1h1iami3crosoft7l1ni1t2t0subishi9k1l0b1s2m0a2n1o0bi0le4da2e1i1m1nash3ey2ster5rmon3tgage6scow4to0rcycles9v0ie4p1q1r1s0d2t0n1r2u0seum3ic4v1w1x1y1z2na0b1goya4me2vy3ba2c1e0c1t0bank4flix4work5ustar5w0s2xt0direct7us4f0l2g0o2hk2i0co2ke1on3nja3ssan1y5l1o0kia3rton4w0ruz3tv4p1r0a1w2tt2u1yc2z2obi1server7ffice5kinawa6layan0group9lo3m0ega4ne1g1l0ine5oo2pen3racle3nge4g0anic5igins6saka4tsuka4t2vh3pa0ge2nasonic7ris2s1tners4s1y3y2
319ccw3e0t2f0izer5g1h0armacy6d1ilips5one2to0graphy6s4ysio5ics1tet2ures6d1n0g1k2oneer5zza4k1l0ace2y0station9umbing5s3m1n0c2ohl2ker3litie5rn2st3r0axi3ess3ime3o0d0uctions8f1gressive8mo2perties3y5tection8u0dential9s1t1ub2w0c2y2qa1pon3uebec3st5racing4dio4e0ad1lestate6tor2y4cipes5d0umbrella9hab3ise0n3t2liance6n0t0als5pair3ort3ublican8st0aurant8view0s5xroth6ich0ardli6oh3l1o1p2o0cks3deo3gers4om3s0vp3u0gby3hr2n2w0e2yukyu6sa0arland6fe0ty4kura4le1on3msclub4ung5ndvik0coromant12ofi4p1rl2s1ve2xo3b0i1s2c0b1haeffler7midt4olarships8ol3ule3warz5ience5ot3d1e0arch3t2cure1ity6ek2lect4ner3rvices6ven3w1x0y3fr2g1h0angrila6rp3ell3ia1ksha5oes2p0ping5uji3w3i0lk2na1gles5te3j1k0i0n2y0pe4l0ing4m0art3ile4n0cf3o0ccer3ial4ftbank4ware6hu2lar2utions7ng1y2y2pa0ce3ort2t3r0l2s1t0ada2ples4r1tebank4farm7c0group6ockholm6rage3e3ream4udio2y3yle4u0cks3pplies3y2ort5rf1gery5zuki5v1watch4iss4x1y0dney4stems6z2tab1ipei4lk2obao4rget4tamotors6r2too4x0i3c0i2d0k2eam2ch0nology8l1masek5nnis4va3f1g1h0d1eater2re6iaa2ckets5enda4ps2res2ol4j0maxx4x2k0maxx5l1m0all4n1o0day3kyo3ols3p1ray3shiba5tal3urs3wn2yota3s3r0ade1ing4ining5vel0ers0insurance16ust3v2t1ube2i1nes3shu4v0s2w1z2ua1bank3s2g1k1nicom3versity8o2ol2ps2s1y1z2va0cations7na1guard7c1e0gas3ntures6risign5mögensberater2ung14sicherung10t2g1i0ajes4deo3g1king4llas4n1p1rgin4sa1ion4va1o3laanderen9n1odka3lvo3te1ing3o2yage5u2wales2mart4ter4ng0gou5tch0es6eather0channel12bcam3er2site5d0ding5ibo2r3f1hoswho6ien2ki2lliamhill9n0dows4e1ners6me2oodside6rk0s2ld3w2s1tc1f3xbox3erox4ihuan4n2xx2yz3yachts4hoo3maxun5ndex5e1odobashi7ga2kohama6u0tube6t1un3za0ppos4ra3ero3ip2m1one3uerich6w2")),null==pY&&(pY=pJ("ελ1Ï
2бг1ел3деÑи4еÑ2каÑолик6ом3мÐ
319ºÐ´2он1Ñква6онлайн5Ñг3ÑÑÑ2Ñ2ÑайÑ3Ñб3ÑкÑ3Òаз3Õ°Õ¡Õµ3×שר××5×§××3Ø§Ø¨ÙØ¸Ø¨Ù5راÙ
ÙÙ5ÙØ§Ø±Ø¯Ù4Ø¨ØØ±ÙÙ5جزائر5Ø³Ø¹ÙØ¯ÙØ©6عÙÙØ§Ù5Ù
غرب5Ù
ارات5ÛØ±Ø§Ù5بارت2زار4ÙØªÙ3ھارت5تÙÙØ³4Ø³ÙØ¯Ø§Ù3Ø±ÙØ©5Ø´Ø¨ÙØ©4عراÙ2ب2Ù
اÙ4ÙÙØ³Ø·ÙÙ6ÙØ·Ø±3ÙØ§Ø«ÙÙÙÙ6ÙÙ
3Ù
صر2ÙÙØ³Ùا5ÙØ±ÙتاÙÙØ§7ÙØ¹4ÙÙ
راÙ5پاکستاÙ7ÚØ§Ø±Øª4à¤à¥à¤®3नà¥à¤3à¤à¤¾à¤°à¤¤0मà¥3à¥à¤¤5सà¤à¤à¤ न5বাà¦à¦²à¦¾5à¦à¦¾à¦°à¦¤2ৰত4à¨à¨¾à¨°à¨¤4àªàª¾àª°àª¤4à¬à¬¾à¬°à¬¤4à®à®¨à¯à®¤à®¿à®¯à®¾6லà®à¯à®à¯6à®à®¿à®à¯à®à®ªà¯à®ªà¯à®°à¯11à°à°¾à°°à°¤à±5à²à²¾à²°à²¤4à´à´¾à´°à´¤à´5à¶½à¶à¶à·4à¸à¸à¸¡3à¹à¸à¸¢3ລາວ3áá2ã¿ããª3ã¢ãã¾ã³4ã¯ã©ã¦ã4ã°ã¼ã°ã«4ã³ã 2ã¹ãã¢3ã»ã¼ã«3ãã¡ãã·ã§ã³6ãã¤ã³ã4ä¸ç2ä¸ä¿¡1å½1å1æç½3äºé©¬é3ä¼ä¸2ä½å±±2ä¿¡æ¯2å¥åº·2å
«å¦2å
¬å¸1ç2å°æ¹¾1ç£2åå1åº1æ 2åé0大é
åº5å¨çº¿2大æ¿2天主æ3娱ä¹2å®¶é»2广ä¸2å¾®å2æ
å2æç±ä½ 3ææº2æè2æ¿å¡1åº2æ°å å¡2é»2æ¶å°2æ¸ç±2æºæ2淡马é¡3游æ2æ¾³é2ç¹ç2ç§»å¨2ç»ç»æºæ4ç½å1åº1ç«1ç»2èé2è°·æ2è´ç©2é販2éå¢2é»è¨çç§4é£å©æµ¦3é£å2é¤å
2馿 ¼éæ3港2ë·ë·1ì»´2ì¼ì±2íêµ2")),h3(n,"'",pb),h3(n,"{",pn),h3(n,"}",pi),h3(n,"[",pr),h3(n,"]",po),h3(n,"(",pa),h3(n,")",ps),h3(n,"<",pl),h3(n,">",pd),h3(n,"ï¼",pu),h3(n,"ï¼",pc),h3(n,"ã",ph),h3(n,"ã",pp),h3(n,"ã",pf),h3(n,"ã",pg),h3(n,"ï¼",pm),h3(n,"ï¼",pv),h3(n,"&",py),h3(n,"*",px),h3(n,"@","AT"),h3(n,"`",pC),h3(n,"^",pS),h3(n,":",p_),h3(n,",",pk),h3(n,"$",pM),h3(n,".","DOT"),h3(n,"=",pT),h3(n,"!",pD),h3(n,"-",pR),h3(n,"%",pI),h3(n,"|",pA),h3(n,"+",pP),h3(n,"#",pE),h3(n,"?",pL),h3(n,'"',pF),h3(n,"/",pB),h3(n,";",pN),h3(n,"~",pz),h3(n,"_",pj),h3(n,"\\",pw),h3(n,"ã»",pO);let i=h1(n,pU,"NUM",{[hW]:!0});h1(i,pU,i);let r=h1(i,pG,h6,{[hq]:!0}),o=h1(i,pW,h8,{[hK]:!0}),a=h1(n,pG,h5,{[h$]:!0});h1(a,pU,r),h1(a,pG,a),h1(r,pU,r),h1(r,pG,r);let s=h1(n,pW,h4,{[hU]:!0});h1(s,pG),h1(s,pU,o),h1(s,pW,s),h1(o,pU,o),h1(o,pG),h1(o,pW,o);let l=h3(n,"\n","NL",{[hX]:!0}),d=h3(n,"\r","WS",{[hX]:!0}),u=h1(n,pq,"WS",{[hX]:!0});h3(n,"",u),h3(d,"\n",l),h3(d,"",u),h1(d,pq,u),h3(u,"\r"),h3(u,"\n"),h1(u,pq,u),h3(u,"",u);let c=h1(n,p$,pV,{[hZ]:!0});h3(c,"#"),h1(c,p$,c),h3(c,"ï¸",c);let h=h3(c,"â");h3(h,"#"),h1(h,p$,c);let p=[[pG,a],[pU,r]],f=[[pG,null],[pW,s],[pU,o]];for(let e=0;e<pK.length;e++)pX(n,pK[e],"TLD",h5,p);for(let e=0;e<pY.length;e++)pX(n,pY[e],h9,h4,f);hJ("TLD",{tld:!0,ascii:!0},t),hJ(h9,{utld:!0,alpha:!0},t),pX(n,"file",pe,h5,p),pX(n,"mailto",pe,h5,p),pX(n,"http",pt,h5,p),pX(n,"https",pt,h5,p),pX(n,"ftp",pt,h5,p),pX(n,"ftps",pt,h5,p),hJ(pe,{scheme:!0,ascii:!0},t),hJ(pt,{slashscheme:!0,ascii:!0},t),e=e.sort((e,t)=>e[0]>t[0]?1:-1);for(let t=0;t<e.length;t++){let i=e[t][0],r=e[t][1]?{scheme:!0}:{slashscheme:!0};i.indexOf("-")>=0?r[hY]=!0:pG.test(i)?pU.test(i)?r[hq]=!0:r[h$]=!0:r[hW]=!0,h2(n,i,i,r)}return h2(n,"localhost",h7,{ascii:!0}),n.jd=new hQ("SYM"),{start:n,tokens:Object.assign({groups:t},pH)}}(ft.customSchemes);for(let e=0;e<ft.tokenQueue.length;e++)ft.tokenQueue[e][1]({scanner:ft.scanner});ft.parser=function({groups:e}){let t=e.domain.concat([py,px,"AT",pw,pC,pS,pM,pT,pR,"NUM",pI,pA,pP,pE,pB,"SYM",pz,pj]),n=[pb,p_,pk,"DOT",pD,pI,pL,pF,pN,pl,pd,pn,pi,po,pr,pa,ps,pu,pc,ph,pp,pf,pg,pm,pv],i=[py,pb,px,pw,pC,pS,pM,pT,pR,pn,pi,pI,pA,pP,pE,pL,pB,"SYM",pz,pj],r=p7(),o=h3(r,pz);h0(o,i,o),h0(o,e.domain,o);let a=p7(),s=p7(),l=p7();h0(r,e.domain,a),h0(r,e.scheme,s),h0(r,e.slashscheme,l),h0(a,i,o),h0(a,e.domain,a);let d=h3(a,"AT");h3(o,"AT",d),h3(s,"AT",d),h3(l,"AT",d);let u=h3(o,"DOT");h0(u,i,o),h0(u,e.domain,o);let c=p7();h0(d,e.domain,c),h0(c,e.domain,c);let h=h3(c,"DOT");h0(h,e.domain,c);let p=p7(p5);h0(h,e.tld,p),h0(h,e.utld,p),h3(d,h7,p);let f=h3(c,pR);h3(f,pR,f),h0(f,e.domain,c),h0(p,e.domain,c),h3(p,"DOT",h),h3(p,pR,f);let g=h3(a,pR),m=h3(a,"DOT");h3(g,pR,g),h0(g,e.domain,a),h0(m,i,o),h0(m,e.domain,a);let v=p7(p8);h0(m,e.tld,v),h0(m,e.utld,v),h0(v,e.domain,a),h0(v,i,o),h3(v,"DOT",m),h3(v,pR,g),h3(v,"AT",d);let y=h3(v,p_),b=p7(p8);h0(y,e.numeric,b);let x=p7(p8),w=p7();h0(x,t,x),h0(x,n,w),h0(w,t,x),h0(w,n,w),h3(v,pB,x),h3(b,pB,x);let C=h3(s,p_),S=h3(l,p_),_=h3(S,pB),k=h3(_,pB);h0(s,e.domain,a),h3(s,"DOT",m),h3(s,pR,g),h0(l,e.domain,a),h3(l,"DOT",m),h3(l,pR,g),h0(C,e.domain,x),h3(C,pB,x),h3(C,pL,x),h0(k,e.domain,x),h0(k,t,x),h3(k,pB,x);let M=[[pn,pi],[pr,po],[pa,ps],[pl,pd],[pu,pc],[ph,pp],[pf,pg],[pm,pv]];for(let e=0;e<M.length;e++){let[i,r]=M[e],o=h3(x,i);h3(w,i,o);let a=p7(p8);h0(o,t,a);let s=p7();h0(o,n,s),h3(o,r,x),h0(a,t,a),h0(a,n,s),h0(s,t,a),h0(s,n,s),h3(a,r,x),h3(s,r,x)}return h3(r,h7,v),h3(r,"NL",p6),{start:r,tokens:pH}}(ft.scanner.tokens);for(let e=0;e<ft.pluginQueue.length;e++)ft.pluginQueue[e][1]({scanner:ft.scanner,parser:ft.parser});ft.initialized=!0}(),function(e,t,n){let i=n.length,r=0,o=[],a=[];for(;r<i;){let s=e,l=null,d=null,u=0,c=null,h=-1;for(;r<i&&!(l=s.go(n[r].t));)a.push(n[r++]);for(;r<i&&(d=l||s.go(n[r].t));)l=null,(s=d).accepts()?(h=0,c=s):h>=0&&h++,r++,u++;if(h<0)(r-=u)<i&&(a.push(n[r]),r++);else{a.length>0&&(o.push(p9(p4,t,a)),a=[]),r-=h,u-=h;let e=c.t,i=n.slice(r-u,r);o.push(p9(e,t,i))}}return a.length>0&&o.push(p9(p4,t,a)),o}(ft.parser.start,e,pZ(ft.scanner.start,e))}function fr(e,t=null,n=null){if(t&&"object"==typeof t){if(n)throw Error(`linkifyjs: Invalid link type ${t}; must be a string`);n=t,t=null}let i=new p0(n),r=fi(e),o=[];for(let e=0;e<r.length;e++){let n=r[e];n.isLink&&(!t||n.t===t)&&i.check(n)&&o.push(n.toFormattedObject(i))}return o}fi.scan=pZ;var fo="[\0-  áá â-\u2029âã]",fa=new RegExp(fo),fs=RegExp(`${fo}$`),fl=RegExp(fo,"g");function fd(e,t){let n=["http","https","ftp","ftps","mailto","tel","callto","sms","cid","xmpp"];
319return t&&t.forEach(e=>{let t="string"==typeof e?e:e.scheme;t&&n.push(t)}),!e||e.replace(fl,"").match(RegExp(`^(?:(?:${n.map(e=>e.replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&")).join("|")}):|[^a-z]|[a-z0-9+.\\-]+(?:[^a-z+.\\-:]|$))`,"i"))}var fu=ld.create({name:"link",priority:1e3,keepOnSplit:!1,exitable:!0,onCreate(){this.options.validate&&!this.options.shouldAutoLink&&(this.options.shouldAutoLink=this.options.validate,console.warn("The `validate` option is deprecated. Rename to the `shouldAutoLink` option instead.")),this.options.protocols.forEach(e=>{"string"==typeof e?fn(e):fn(e.scheme,e.optionalSlashes)})},onDestroy(){hQ.groups={},ft.scanner=null,ft.parser=null,ft.tokenQueue=[],ft.pluginQueue=[],ft.customSchemes=[],ft.initialized=!1},inclusive(){return this.options.autolink},addOptions:()=>({openOnClick:!0,enableClickSelection:!1,linkOnPaste:!0,autolink:!0,protocols:[],defaultProtocol:"http",HTMLAttributes:{target:"_blank",rel:"noopener noreferrer nofollow",class:null},isAllowedUri:(e,t)=>!!fd(e,t.protocols),validate:e=>!!e,shouldAutoLink:e=>{let t=/^[a-z][a-z0-9+.-]*:\/\//i.test(e),n=/^[a-z][a-z0-9+.-]*:/i.test(e);if(t||n&&!e.includes("@"))return!0;let i=(e.includes("@")?e.split("@").pop():e).split(/[/?#:]/)[0];return!/^\d{1,3}(\.\d{1,3}){3}$/.test(i)&&!!/\./.test(i)}}),addAttributes(){return{href:{default:null,parseHTML:e=>e.getAttribute("href")},target:{default:this.options.HTMLAttributes.target},rel:{default:this.options.HTMLAttributes.rel},class:{default:this.options.HTMLAttributes.class},title:{default:null}}},parseHTML(){return[{tag:"a[href]",getAttrs:e=>{let t=e.getAttribute("href");return!!t&&!!this.options.isAllowedUri(t,{defaultValidate:e=>!!fd(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})&&null}}]},renderHTML({HTMLAttributes:e}){return this.options.isAllowedUri(e.href,{defaultValidate:e=>!!fd(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?["a",sh(this.options.HTMLAttributes,e),0]:["a",sh(this.options.HTMLAttributes,{...e,href:""}),0]},markdownTokenName:"link",parseMarkdown:(e,t)=>t.applyMark("link",t.parseInline(e.tokens||[]),{href:e.href,title:e.title||null}),renderMarkdown:(e,t)=>{var n,i,r,o;let a=null!=(i=null==(n=e.attrs)?void 0:n.href)?i:"",s=null!=(o=null==(r=e.attrs)?void 0:r.title)?o:"",l=t.renderChildren(e);return s?`[${l}](${a} "${s}")`:`[${l}](${a})`},addCommands(){return{setLink:e=>({chain:t})=>{let{href:n}=e;return!!this.options.isAllowedUri(n,{defaultValidate:e=>!!fd(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})&&t().setMark(this.name,e).setMeta("preventAutolink",!0).run()},toggleLink:e=>({chain:t})=>{let{href:n}=e||{};return(!n||!!this.options.isAllowedUri(n,{defaultValidate:e=>!!fd(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol}))&&t().toggleMark(this.name,e,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run()},unsetLink:()=>({chain:e})=>e().unsetMark(this.name,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run()}},addPasteRules(){return[lP({find:e=>{let t=[];if(e){let{protocols:n,defaultProtocol:i}=this.options,r=fr(e).filter(e=>e.isLink&&this.options.isAllowedUri(e.value,{defaultValidate:e=>!!fd(e,n),protocols:n,defaultProtocol:i}));r.length&&r.forEach(e=>{this.options.shouldAutoLink(e.value)&&t.push({text:e.value,data:{href:e.href},index:e.start})})}return t}
319,type:this.type,getAttributes:e=>{var t;return{href:null==(t=e.data)?void 0:t.href}}})]},addProseMirrorPlugins(){var e,t,n;let i=[],{protocols:r,defaultProtocol:o}=this.options;return this.options.autolink&&i.push((e={type:this.type,defaultProtocol:this.options.defaultProtocol,validate:e=>this.options.isAllowedUri(e,{defaultValidate:e=>!!fd(e,r),protocols:r,defaultProtocol:o}),shouldAutoLink:this.options.shouldAutoLink},new nZ({key:new nQ("autolink"),appendTransaction:(t,n,i)=>{let r=t.some(e=>e.docChanged)&&!n.doc.eq(i.doc),o=t.some(e=>e.getMeta("preventAutolink"));if(!r||o)return;let{tr:a}=i;if(sC(sn(n.doc,[...t])).forEach(({newRange:t})=>{var n,r;let o,s,l,d=(n=i.doc,r=e=>e.isTextblock,l=[],n.nodesBetween(t.from,t.to,(e,t)=>{r(e)&&l.push({node:e,pos:t})}),l);if(d.length>1)o=d[0],s=i.doc.textBetween(o.pos,o.pos+o.node.nodeSize,void 0," ");else if(d.length){let e=i.doc.textBetween(t.from,t.to," "," ");if(!fs.test(e))return;o=d[0],s=i.doc.textBetween(o.pos,t.to,void 0," ")}if(o&&s){let t=s.split(fa).filter(Boolean);if(t.length<=0)return!1;let n=t[t.length-1],r=o.pos+s.lastIndexOf(n);if(!n)return!1;let l=fi(n).map(t=>t.toObject(e.defaultProtocol));if(!(1===l.length?l[0].isLink:3===l.length&&!!l[1].isLink&&["()","[]"].includes(l[0].value+l[2].value)))return!1;l.filter(e=>e.isLink).map(e=>({...e,from:r+e.start+1,to:r+e.end+1})).filter(e=>!i.schema.marks.code||!i.doc.rangeHasMark(e.from,e.to,i.schema.marks.code)).filter(t=>e.validate(t.value)).filter(t=>e.shouldAutoLink(t.value)).forEach(t=>{sS(t.from,t.to,i.doc).some(t=>t.mark.type===e.type)||a.addMark(t.from,t.to,e.type.create({href:t.href}))})}}),a.steps.length)return a}}))),i.push((t={type:this.type,editor:this.editor,openOnClick:"whenNotEditable"===this.options.openOnClick||this.options.openOnClick,enableClickSelection:this.options.enableClickSelection},new nZ({key:new nQ("handleClickLink"),props:{handleClick:(e,n,i)=>{var r,o;if(0!==i.button||!e.editable)return!1;let a=null;if(i.target instanceof HTMLAnchorElement)a=i.target;else{let e=i.target;if(!e)return!1;let n=t.editor.view.dom;(a=e.closest("a"))&&!n.contains(a)&&(a=null)}if(!a)return!1;let s=!1;if(t.enableClickSelection&&(s=t.editor.commands.extendMarkRange(t.type.name)),t.openOnClick){let n=sw(e.state,t.type.name),i=null!=(r=a.href)?r:n.href,l=null!=(o=a.target)?o:n.target;i&&(window.open(i,l),s=!0)}return s}}}))),this.options.linkOnPaste&&i.push((n={editor:this.editor,defaultProtocol:this.options.defaultProtocol,type:this.type,shouldAutoLink:this.options.shouldAutoLink},new nZ({key:new nQ("handlePasteLink"),props:{handlePaste:(e,t,i)=>{let{shouldAutoLink:r}=n,{state:o}=e,{selection:a}=o,{empty:s}=a;if(s)return!1;let l="";i.content.forEach(e=>{l+=e.textContent});let d=fr(l,{defaultProtocol:n.defaultProtocol}).find(e=>e.isLink&&e.value===l);return!!l&&!!d&&(void 0===r||!!r(d.value))&&n.editor.commands.setMark(n.type,{href:d.href})}}}))),i}}),fc=Object.defineProperty,fh="textStyle",fp=/^\s*([-+*])\s$/,ff=lA.create({name:"bulletList",addOptions:()=>({itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}),group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML:()=>[{tag:"ul"}],renderHTML({HTMLAttributes:e}){return["ul",sh(this.options.HTMLAttributes,e),0]},markdownTokenName:"list",parseMarkdown:(e,t)=>"list"!==e.type||e.ordered?[]:{type:"bulletList",content:e.items?t.parseChildren(e.items):[]},renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n"):"",markdownOptions:{indentsContent:!0},addCommands(){return{toggleBulletList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes("listItem",this.editor.getAttributes(fh)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-8":()=>this.editor.commands.toggleBulletList()}}
319,addInputRules(){let e=lI({find:fp,type:this.type});return(this.options.keepMarks||this.options.keepAttributes)&&(e=lI({find:fp,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:()=>this.editor.getAttributes(fh),editor:this.editor})),[e]}}),fg=(e,t)=>lp.create({name:`${e}BranchingDeleteKeymap`,priority:101,addKeyboardShortcuts(){let n=()=>{let n;return n=this.editor,((e,t,n,i)=>{let r=((e,t,n)=>{let{selection:i}=e;if(!i.empty)return null;let{$from:r}=i;if(!r.parent.isTextblock||r.parentOffset!==r.parent.content.size)return null;let o=-1;for(let e=r.depth;e>0;e-=1)if(r.node(e).type.name===t){o=e;break}if(o<0)return null;let a=r.node(o),s=r.index(o);if(s+1>=a.childCount)return null;let l=a.child(s+1);if(!n.includes(l.type.name))return null;let d=e.schema.nodes[t],u=!1;if(l.forEach(e=>{e.type===d&&e.childCount>1&&(u=!0)}),!u)return null;let c=e.doc.resolve(r.after()).nodeAfter;if(!c||!n.includes(c.type.name))return null;let h=[];return(c.forEach(e=>{h.push(e)}),0===h.length)?null:{listItemDepth:o,nestedList:c,nestedListPos:r.after(),insertPos:r.after(o),items:h}})(e,n,i);if(!r)return!1;let{selection:o}=e,{nestedList:a,nestedListPos:s,insertPos:l,items:d}=r,u=e.tr;u.delete(s,s+a.nodeSize);let c=u.mapping.map(l);return u.insert(c,tl.from(d)),u.setSelection(o.map(u.doc,u.mapping)),t&&t(u),!0})(n.state,n.view.dispatch,e,t)};return{Delete:n,"Mod-Delete":n}}}),fm=[[1e3,"m"],[900,"cm"],[500,"d"],[400,"cd"],[100,"c"],[90,"xc"],[50,"l"],[40,"xl"],[10,"x"],[9,"ix"],[5,"v"],[4,"iv"],[1,"i"]],fv="abcdefghijklmnopqrstuvwxyz",fy=String.raw`\d+|[ivxlcdmIVXLCDM]+|${"[a-zA-Z]{1,2}"}`;function fb(e){let t=e,n="";for(let[e,i]of fm)for(;t>=e;)n+=i,t-=e;return n}function fx(e){return fb(e).toUpperCase()}function fw(e){let t=e.toLowerCase(),n=0,i=0;for(;n<t.length;){let e=!1;for(let[r,o]of fm)if(t.startsWith(o,n)){i+=r,n+=o.length,e=!0;break}if(!e)return 0}return i}function fC(e){if(e<=26)return fv[e-1];let t=Math.floor((e-1)/26)-1,n=(e-1)%26;return t<0?fv[n]:fv[t]+fv[n]}function fS(e){if(!(!e||/^\d+$/.test(e))){if(function(e){if(!/^[ivxlcdmIVXLCDM]+$/.test(e))return!1;let t=fw(e);return!(t<=0)&&(e===e.toLowerCase()?fb(t):fx(t))===e}(e))return e===e.toLowerCase()?"i":"I";if(/^[a-z]{1,2}$/.test(e))return"a";if(/^[A-Z]{1,2}$/.test(e))return"A"}}function f_(e){if(/^\d+$/.test(e))return parseInt(e,10);let t=fS(e);if("i"===t||"I"===t)return fw(e);if("a"===t||"A"===t){let t,n=1===(t=e.toLowerCase()).length?t.charCodeAt(0)-97+1:2===t.length?(t.charCodeAt(0)-97+1)*26+(t.charCodeAt(1)-97)+1:0;return n>0?n:1}let n=parseInt(e,10);return Number.isNaN(n)?1:n}var fk=lA.create({name:"listItem",addOptions:()=>({HTMLAttributes:{},bulletListTypeName:"bulletList",orderedListTypeName:"orderedList"}),content:"paragraph block*",defining:!0,parseHTML:()=>[{tag:"li"}],renderHTML({HTMLAttributes:e}){return["li",sh(this.options.HTMLAttributes,e),0]},markdownTokenName:"list_item",parseMarkdown:(e,t)=>{var n,i,r,o;if("list_item"!==e.type)return[];let a=null!=(n=t.parseBlockChildren)?n:t.parseChildren,s=[];if(e.tokens&&e.tokens.length>0){let n;if(n=null==(i=e.tokens)?void 0:i[0],e.text&&(null==(r=e.tokens)?void 0:r.length)===1&&(null==n?void 0:n.type)==="list"&&n.ordered&&n.raw===e.text)return{type:"listItem",content:[{type:"paragraph",content:(o=e.text||"",t.tokenizeInline?t.parseInline(t.tokenizeInline(o)):t.parseInline([{type:"text",raw:o,text:o}]))}]};if(e.tokens.some(e=>"paragraph"===e.type))s=a(e.tokens);else{let n=e.tokens[0];if(n&&"text"===n.type&&n.tokens&&n.tokens.length>0){if(s=[{type:"paragraph",content:t.parseInline(n.tokens)}],e.tokens.length>1){let t=a(e.tokens.slice(1));s.push(...t)}}else s=a(e.tokens)}}return 0===s.length&&(s=[{type:"paragraph",content:[]}]),{type:"listItem",content:s}},renderMarkdown:(e,t,n)=>lo(e,t,e=>{var t,n,i,r;if("bulletList"===e.parentType)return"- ";if("orderedList"===e.parentType){let o=(null==(n=null==(t=e.meta)?void 0:t.parentAttrs)?void 0:n.start)||1;return function(e,t,n=". "){let i=t+1;if(!e||"1"===e)return`${i}${n}`;switch(e){case"a":return`${fC(i)}${n}`;case"A":return`${fC(i).toUpperCase()}${n}`;case"i":return`${fb(i)}${n}`;case"I":return`${fx(i)}${n}`;default:return`${i}${n}`}}(null==(r=null==(i=e.meta)?void 0:i.parentAttrs)?void 0:r.type,o-1+(e.index||0),". ")}return"- "},n),addExtensions(){return[fg(this.name,[this.options.bulletListTypeName,this.options.orderedListTypeName])]},addKeyboardShortcuts(){return{Enter:()=>this.editor.commands.splitListItem(this.name),Tab:()=>this.editor.commands.sinkListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)}}}),fM={},fT={findListItemPos:()=>fR,getNextListDepth:()=>fI,handleBackspace:()=>fP,handleDelete:()=>fF,hasListBefore:()=>fA,hasListItemAfter:()=>fO,hasListItemBefore:()=>fN,listItemHasSubList:()=>fB,nextListIsDeeper:()=>fE,nextListIsHigher:()=>fL};for(var fD in fT)fc(fM,fD,{get:fT[fD],enumerable:!0});var fR=(e,t)=>{let{$from:n}=t.selection,i=ac(e,t.schema),r=n.depth,o=n.pos,a=null;for(;r>0&&null===a;)n.node(r).type===i?a=r:(r-=1,o-=1);return null===a?null:{$pos:t.doc.resolve(o),depth:a}},fI=(e,t)=>{let n=fR(e,t);if(!n)return!1;let[,i]=((e,t,n,i=20)=>{let r=e.doc.resolve(n),o=i,a=null;for(;o>0&&null===a;){let e=r.node(o);
319(null==e?void 0:e.type.name)===t?a=e:o-=1}return[a,o]})(t,e,n.$pos.pos+4);return i},fA=(e,t,n)=>{let{$anchor:i}=e.selection,r=Math.max(0,i.pos-2),o=e.doc.resolve(r).node();return!!o&&!!n.includes(o.type.name)},fP=(e,t,n)=>{if(e.commands.undoInputRule())return!0;if(e.state.selection.from!==e.state.selection.to)return!1;if(!aK(e.state,t)&&fA(e.state,t,n)){let{$anchor:n}=e.state.selection,i=e.state.doc.resolve(n.before()-1),r=[];i.node().descendants((e,n)=>{e.type.name===t&&r.push({node:e,pos:n})});let o=r.at(-1);if(!o)return!1;let a=e.state.doc.resolve(i.start()+o.pos+1);return e.chain().cut({from:n.start()-1,to:n.end()+1},a.end()).joinForward().run()}return!!aK(e.state,t)&&!!(e=>{let{$from:t,$to:n}=e.selection;return!(t.parentOffset>0)&&t.pos===n.pos})(e.state)&&e.chain().liftListItem(t).run()},fE=(e,t)=>{let n=fI(e,t),i=fR(e,t);return!!i&&!!n&&n>i.depth},fL=(e,t)=>{let n=fI(e,t),i=fR(e,t);return!!i&&!!n&&n<i.depth},fF=(e,t)=>{if(!aK(e.state,t)||!((e,t)=>{let{$from:n,$to:i,$anchor:r}=e.selection;if(t){let n=si(e=>e.type.name===t)(e.selection);if(!n)return!1;let i=e.doc.resolve(n.pos+1);return r.pos+1===i.end()}return!(i.parentOffset<i.parent.nodeSize-2)&&n.pos===i.pos})(e.state,t))return!1;let{selection:n}=e.state,{$from:i,$to:r}=n;return!(!n.empty&&i.sameParent(r))&&(fE(t,e.state)?e.chain().focus(e.state.selection.from+4).lift(t).joinBackward().run():fL(t,e.state)?e.chain().joinForward().joinBackward().run():e.commands.joinItemForward())},fO=(e,t)=>{var n;let{$anchor:i}=t.selection,r=t.doc.resolve(i.pos-i.parentOffset-2);return r.index()!==r.parent.childCount-1&&(null==(n=r.nodeAfter)?void 0:n.type.name)===e},fN=(e,t)=>{var n;let{$anchor:i}=t.selection,r=t.doc.resolve(i.pos-2);return 0!==r.index()&&(null==(n=r.nodeBefore)?void 0:n.type.name)===e},fB=(e,t,n)=>{if(!n)return!1;let i=ac(e,t.schema),r=!1;return n.descendants(e=>{e.type===i&&(r=!0)}),r},fz=lp.create({name:"listKeymap",addOptions:()=>({listTypes:[{itemName:"listItem",wrapperNames:["bulletList","orderedList"]},{itemName:"taskItem",wrapperNames:["taskList"]}]}),addKeyboardShortcuts(){return{Delete:({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n})=>{void 0!==e.state.schema.nodes[n]&&fF(e,n)&&(t=!0)}),t},"Mod-Delete":({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n})=>{void 0!==e.state.schema.nodes[n]&&fF(e,n)&&(t=!0)}),t},Backspace:({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n,wrapperNames:i})=>{void 0!==e.state.schema.nodes[n]&&fP(e,n,i)&&(t=!0)}),t},"Mod-Backspace":({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n,wrapperNames:i})=>{void 0!==e.state.schema.nodes[n]&&fP(e,n,i)&&(t=!0)}),t}}}}),fj=RegExp(`^(\\s*)(${fy})([.)])\\s+(.*)$`),fV=RegExp(`^(\\s*)(${fy})([.)])\\s+`),fH=/^\s/,fG=RegExp(`^(${fy})([.)])\\s+(.+)$`),fW="textStyle",f$=/^(\d+)\.\s$/;function fU(e){let t=e.match(/list-style-type\s*:\s*([^;]+)/i);if(!t)return null;switch(t[1].trim().toLowerCase()){case"upper-roman":return"I";case"lower-roman":return"i";case"upper-alpha":case"upper-latin":return"A";case"lower-alpha":case"lower-latin":return"a";default:return null}}var fq=lA.create({name:"orderedList",addOptions:()=>({itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}),group:"block list",content(){return`${this.options.itemTypeName}+`},addAttributes:()=>({start:{default:1,parseHTML:e=>e.hasAttribute("start")?parseInt(e.getAttribute("start")||"",10):1},type:{default:null,parseHTML:e=>{let t=e.getAttribute("type");if(t)return t;let n=e.getAttribute("style");if(n){let e=fU(n);if(e)return e}let i=e.querySelector("li");if(i){let e=i.getAttribute("style");if(e){let t=fU(e);if(t)return t}}return null}}}),parseHTML:()=>[{tag:"ol"}],renderHTML({HTMLAttributes:e}){let{start:t,type:n,...i}=e,r=sh(this.options.HTMLAttributes,i);return 1!==t&&(r.start=t),n&&"1"!==n&&(r.type=n),["ol",r,0]},markdownTokenName:"list",parseMarkdown:(e,t)=>{var n;if("list"!==e.type||!e.ordered)return[];let i=e.start||1,r=e.typeMarker,o=e.items?(n=e.items,n.map(e=>{if("list_item"!==e.type)return t.parseChildren([e])[0];let n=[];return e.tokens&&e.tokens.length>
3190&&e.tokens.forEach(e=>{if("paragraph"===e.type||"list"===e.type||"blockquote"===e.type||"code"===e.type)n.push(...t.parseChildren([e]));else if("text"===e.type&&e.tokens){let i=t.parseChildren([e]);n.push({type:"paragraph",content:i})}else{let i=t.parseChildren([e]);i.length>0&&n.push(...i)}}),{type:"listItem",content:n}})):[],a={};return(1!==i&&(a.start=i),r&&(a.type=r),Object.keys(a).length>0)?{type:"orderedList",attrs:a,content:o}:{type:"orderedList",content:o}},renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n"):"",markdownTokenizer:{name:"orderedList",level:"block",start:e=>{let t=e.match(fV),n=null==t?void 0:t.index;return void 0!==n?n:-1},tokenize:(e,t,n)=>{var i,r;let o=e.split("\n"),[a,s]=function(e){let t=[],n=0,i=0;for(;n<e.length;){let r=e[n],o=r.match(fj);if(!o)break;let[,a,s,l,d]=o,u=a.length,c=parseInt(s,10),h=isNaN(c)?fS(s):void 0,p=isNaN(c)?f_(s):c,f=[d],g=n+1,m=[r],v=!1;for(;g<e.length;){let t=e[g];if(t.match(fj))break;if(""===t.trim())m.push(t),f.push(""),v=!0,g+=1;else if(t.match(fH)){let e=t.length-t.trimStart().length,n=u+s.length+1;m.push(t),f.push(t.slice(Math.min(e,n))),g+=1}else{if(v)break;m.push(t),f.push(t),g+=1}}t.push({indent:u,number:p,type:h,content:f.join("\n").trim(),contentLines:f,raw:m.join("\n")}),i=g,n=g}return[t,i]}(o);if(0===a.length)return;let l=function e(t,n,i){let r=[],o=0;for(;o<t.length;){let a=t[o];if(a.indent===n){let{paragraphLines:s,blockLines:l}=function(e){let t=[],n=[],i=!1;return e.forEach(e=>{let r;if(i)return void n.push(e);if(""===e.trim()||t.length>0&&(r=e.trimStart(),/^[-+*]\s+/.test(r)||fj.test(r.trimStart())||/^>\s?/.test(r)||/^```/.test(r)||/^~~~/.test(r))){i=!0,n.push(e);return}t.push(e)}),{paragraphLines:t,blockLines:n}}(a.contentLines),d=s.join("\n").trim(),u=[];d&&u.push({type:"paragraph",raw:d,tokens:i.inlineTokens(d)});let c=l.join("\n").trim();if(c){let e=i.blockTokens(c);u.push(...e)}let h=o+1,p=[];for(;h<t.length&&t[h].indent>n;)p.push(t[h]),h+=1;if(p.length>0){let t=Math.min(...p.map(e=>e.indent)),n=e(p,t,i);u.push({type:"list",ordered:!0,start:p[0].number,typeMarker:p[0].type,items:n,raw:p.map(e=>e.raw).join("\n")})}r.push({type:"list_item",raw:a.raw,tokens:u}),o=h}else o+=1}return r}(a,0,n);if(0!==l.length)return{type:"list",ordered:!0,start:(null==(i=a[0])?void 0:i.number)||1,typeMarker:null==(r=a[0])?void 0:r.type,items:l,raw:o.slice(0,s).join("\n")}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleOrderedList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes("listItem",this.editor.getAttributes(fW)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addProseMirrorPlugins:()=>[new nZ({props:{handlePaste:(e,t)=>
319{var n,i;let r=null==(n=t.clipboardData)?void 0:n.getData("text/html");if(null==r?void 0:r.trim())return!1;let o=null==(i=t.clipboardData)?void 0:i.getData("text/plain");if(!o)return!1;let a=function(e){let t=e.split("\n").filter(e=>e.trim().length>0);if(0===t.length)return null;let n=[];for(let e of t){let t=e.trim().match(fG);if(!t)return null;n.push({marker:t[1],content:t[3]})}return!function(e){var t;if(0===e.length)return!1;let n=null!=(t=fS(e[0]))?t:"numeric",i=f_(e[0]);if(i<1)return!1;for(let t=0;t<e.length;t++){let r=function(e,t){if("numeric"===e)return String(t);switch(e){case"a":return fC(t);case"A":return fC(t).toUpperCase();case"i":return fb(t);case"I":return fx(t);default:return String(t)}}(n,i+t);if(e[t]!==r)return!1}return!0}(n.map(e=>e.marker))?null:{type:"orderedList",attrs:function(e){let{type:t,start:n}={type:fS(e),start:f_(e)},i={};return t&&(i.type=t),1!==n&&(i.start=n),i}(n[0].marker),content:n.map(e=>({type:"listItem",content:[{type:"paragraph",content:[{type:"text",text:e.content}]}]}))}}(o);if(!a)return!1;try{let t=e.state.schema.nodeFromJSON(a),n=e.state.tr.replaceSelectionWith(t);return e.dispatch(n),!0}catch{return!1}}}})],addInputRules(){let e=(e,t)=>(!t.attrs.type||"1"===t.attrs.type)&&t.childCount+t.attrs.start===+e[1],t=lI({find:f$,type:this.type,getAttributes:e=>({start:+e[1]}),joinPredicate:e});return(this.options.keepMarks||this.options.keepAttributes)&&(t=lI({find:f$,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:e=>({start:+e[1],...this.editor.getAttributes(fW)}),joinPredicate:e,editor:this.editor})),[t]}}),fK=/^\s*(\[([( |x])?\])\s$/,fY=lA.create({name:"taskItem",addOptions:()=>({nested:!1,HTMLAttributes:{},taskListTypeName:"taskList",a11y:void 0}),content(){return this.options.nested?"paragraph block*":"paragraph+"},defining:!0,addAttributes:()=>({checked:{default:!1,keepOnSplit:!1,parseHTML:e=>{let t=e.getAttribute("data-checked");return""===t||"true"===t},renderHTML:e=>({"data-checked":e.checked})}}),parseHTML(){return[{tag:`li[data-type="${this.name}"]`,priority:51}]},renderHTML({node:e,HTMLAttributes:t}){return["li",sh(this.options.HTMLAttributes,t,{"data-type":this.name}),["label",["input",{type:"checkbox",checked:e.attrs.checked?"checked":null}],["span"]],["div",0]]},parseMarkdown:(e,t)=>{let n=[];if(e.tokens&&e.tokens.length>0?n.push(t.createNode("paragraph",{},t.parseInline(e.tokens))):e.text?n.push(t.createNode("paragraph",{},[t.createNode("text",{text:e.text})])):n.push(t.createNode("paragraph",{},[])),e.nestedTokens&&e.nestedTokens.length>0){let i=t.parseChildren(e.nestedTokens);n.push(...i)}return t.createNode("taskItem",{checked:e.checked||!1},n)},renderMarkdown:(e,t)=>{var n;let i=(null==(n=e.attrs)?void 0:n.checked)?"x":" ";return lo(e,t,`- [${i}] `)},addExtensions(){return this.options.nested?[fg(this.name,[this.options.taskListTypeName])]:[]},addKeyboardShortcuts(){let e={Enter:()=>this.editor.commands.splitListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)};return this.options.nested?{...e,Tab:()=>this.editor.commands.sinkListItem(this.name)}:e},addNodeView(){return({node:e,HTMLAttributes:t,getPos:n,editor:i})=>{let r=document.createElement("li"),o=document.createElement("label"),a=document.createElement("span"),s=document.createElement("input"),l=document.createElement("div"),d=e=>{var t,n;s.ariaLabel=(null==(n=null==(t=this.options.a11y)?void 0:t.checkboxLabel)?void 0:n.call(t,e,s.checked))||`Task item checkbox for ${e.textContent||"empty task item"}`};d(e),o.contentEditable="false",s.type="checkbox",s.addEventListener("mousedown",e=>e.preventDefault()),s.addEventListener("change",t=>{if(!i.isEditable&&!this.options.onReadOnlyChecked){s.checked=!s.checked;return}let{checked:r}=t.target;i.isEditable&&"function"==typeof n&&i.chain().focus(void 0,{scrollIntoView:!1}).command(({tr:e})=>{let t=n();if("number"!=typeof t)return!1;let i=e.doc.nodeAt(t);return e.setNodeMarkup(t,void 0,{...null==i?void 0:i.attrs,checked:r}),!0}).run(),i.isEditable||!this.options.onReadOnlyChecked||this.options.onReadOnlyChecked(e,r)||(s.checked=!s.checked)}
319),Object.entries(this.options.HTMLAttributes).forEach(([e,t])=>{r.setAttribute(e,t)}),r.dataset.checked=e.attrs.checked,s.checked=e.attrs.checked,o.append(s,a),r.append(o,l),Object.entries(t).forEach(([e,t])=>{r.setAttribute(e,t)});let u=new Set(Object.keys(t));return{dom:r,contentDOM:l,update:e=>{if(e.type!==this.type)return!1;r.dataset.checked=e.attrs.checked,s.checked=e.attrs.checked,d(e);let t=sp(e,i.extensionManager.attributes),n=new Set(Object.keys(t)),o=this.options.HTMLAttributes;return u.forEach(e=>{n.has(e)||(e in o?r.setAttribute(e,o[e]):r.removeAttribute(e))}),Object.entries(t).forEach(([e,t])=>{null==t?e in o?r.setAttribute(e,o[e]):r.removeAttribute(e):r.setAttribute(e,t)}),u=n,!0}}}},addInputRules(){return[lI({find:fK,type:this.type,getAttributes:e=>({checked:"x"===e[e.length-1]})})]}}),fZ=lA.create({name:"taskList",addOptions:()=>({itemTypeName:"taskItem",HTMLAttributes:{}}),group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:`ul[data-type="${this.name}"]`,priority:51}]},renderHTML({HTMLAttributes:e}){return["ul",sh(this.options.HTMLAttributes,e,{"data-type":this.name}),0]},parseMarkdown:(e,t)=>t.createNode("taskList",{},t.parseChildren(e.items||[])),renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n"):"",markdownTokenizer:{name:"taskList",level:"block",start(e){var t;let n=null==(t=e.match(/^\s*[-+*]\s+\[([ xX])\]\s+/))?void 0:t.index;return void 0!==n?n:-1},tokenize(e,t,n){let i=e=>{let t=lr(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:"x"===e[3].toLowerCase()}),createToken:(e,t)=>({type:"taskItem",raw:"",mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:i},n);return t?[{type:"taskList",raw:t.raw,items:t.items}]:n.blockTokens(e)},r=lr(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:"x"===e[3].toLowerCase()}),createToken:(e,t)=>({type:"taskItem",raw:"",mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:i},n);if(r)return{type:"taskList",raw:r.raw,items:r.items}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleTaskList:()=>({commands:e})=>e.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}});lp.create({name:"listKit",addExtensions(){let e=[];return!1!==this.options.bulletList&&e.push(ff.configure(this.options.bulletList)),!1!==this.options.listItem&&e.push(fk.configure(this.options.listItem)),!1!==this.options.listKeymap&&e.push(fz.configure(this.options.listKeymap)),!1!==this.options.orderedList&&e.push(fq.configure(this.options.orderedList)),!1!==this.options.taskItem&&e.push(fY.configure(this.options.taskItem)),!1!==this.options.taskList&&e.push(fZ.configure(this.options.taskList)),e}});var fX=" ",fJ=lA.create({name:"paragraph",priority:1e3,addOptions:()=>({HTMLAttributes:{}}),group:"block",content:"inline*",parseHTML:()=>[{tag:"p"}],renderHTML({HTMLAttributes:e}){return["p",sh(this.options.HTMLAttributes,e),0]},parseMarkdown:(e,t)=>{let n=e.tokens||[];if(1===n.length&&"image"===n[0].type)return t.parseChildren([n[0]]);let i=t.parseInline(n);return 1===n.length&&"text"===n[0].type&&(n[0].raw===fX||n[0].text===fX||"Â "===n[0].raw||"Â "===n[0].text)&&1===i.length&&"text"===i[0].type&&(i[0].text===fX||"Â "===i[0].text)?t.createNode("paragraph",void 0,[]):t.createNode("paragraph",void 0,i)},renderMarkdown:(e,t,n)=>{var i,r;if(!e)return"";let o=Array.isArray(e.content)?e.content:[];if(0===o.length){let e=Array.isArray(null==(i=null==n?void 0:n.previousNode)?void 0:i.content)?n.previousNode.content:[];return(null==(r=null==n?void 0:n.previousNode)?void 0:r.type)==="paragraph"&&0===e.length?fX:""}return t.renderChildren(o)},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),fQ=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,f0=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,f1=ld.create({name:"strike",addOptions:()=>({HTMLAttributes:{}}),parseHTML:()=>[{tag:"s"},{tag:"del"},{tag:"strike"},{style:"text-decoration",consuming:!1,getAttrs:e=>!!e.includes("line-through")&&{}}],renderHTML({HTMLAttributes:e}){return["s",sh(this.options.HTMLAttributes,e),0]},markdownTokenName:"del",parseMarkdown:(e,t)=>t.applyMark("strike",t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`~~${t.renderChildren(e)}~~`,addCommands(){return{setStrike:()=>({commands:e})=>e.setMark(this.name),toggleStrike:()=>({commands:e})=>e.toggleMark(this.name),unsetStrike:()=>({commands:e})=>e.unsetMark(this.name)}}
319,addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[lD({find:fQ,type:this.type})]},addPasteRules(){return[lP({find:f0,type:this.type})]}}),f2=lA.create({name:"text",group:"inline",parseMarkdown:e=>({type:"text",text:e.text||""}),renderMarkdown:e=>e.text||""}),f3=ld.create({name:"underline",addOptions:()=>({HTMLAttributes:{}}),parseHTML:()=>[{tag:"u"},{style:"text-decoration",consuming:!1,getAttrs:e=>!!e.includes("underline")&&{}}],renderHTML({HTMLAttributes:e}){return["u",sh(this.options.HTMLAttributes,e),0]},parseMarkdown(e,t){return t.applyMark(this.name||"underline",t.parseInline(e.tokens||[]))},renderMarkdown:(e,t)=>`++${t.renderChildren(e)}++`,markdownTokenizer:{name:"underline",level:"inline",start:e=>e.indexOf("++"),tokenize(e,t,n){let i=/^(\+\+)([\s\S]+?)(\+\+)/.exec(e);if(!i)return;let r=i[2].trim();return{type:"underline",raw:i[0],text:r,tokens:n.inlineTokens(r)}}},addCommands(){return{setUnderline:()=>({commands:e})=>e.setMark(this.name),toggleUnderline:()=>({commands:e})=>e.toggleMark(this.name),unsetUnderline:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}});class f5{constructor(e,t){var n;this.editorView=e,this.cursorPos=null,this.element=null,this.timeout=-1,this.width=null!=(n=t.width)?n:1,this.color=!1===t.color?void 0:t.color||"black",this.class=t.class,this.handlers=["dragover","dragend","drop","dragleave"].map(t=>{let n=e=>{this[t](e)};return e.dom.addEventListener(t,n),{name:t,handler:n}})}destroy(){this.handlers.forEach(({name:e,handler:t})=>this.editorView.dom.removeEventListener(e,t))}update(e,t){null!=this.cursorPos&&t.doc!=e.state.doc&&(this.cursorPos>e.state.doc.content.size?this.setCursor(null):this.updateOverlay())}setCursor(e){e!=this.cursorPos&&(this.cursorPos=e,null==e?(this.element.parentNode.removeChild(this.element),this.element=null):this.updateOverlay())}updateOverlay(){let e,t,n=this.editorView.state.doc.resolve(this.cursorPos),i=!n.parent.inlineContent,r,o=this.editorView.dom,a=o.getBoundingClientRect(),s=a.width/o.offsetWidth,l=a.height/o.offsetHeight;if(i){let e=n.nodeBefore,t=n.nodeAfter;if(e||t){let n=this.editorView.nodeDOM(this.cursorPos-(e?e.nodeSize:0));if(n){let i=n.getBoundingClientRect(),o=e?i.bottom:i.top;e&&t&&(o=(o+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2);let a=this.width/2*l;r={left:i.left,right:i.right,top:o-a,bottom:o+a}}}}if(!r){let e=this.editorView.coordsAtPos(this.cursorPos),t=this.width/2*s;r={left:e.left-t,right:e.left+t,top:e.top,bottom:e.bottom}}let d=this.editorView.dom.offsetParent;if(!this.element&&(this.element=d.appendChild(document.createElement("div")),this.class&&(this.element.className=this.class),this.element.style.cssText="position: absolute; z-index: 50; pointer-events: none;",this.color&&(this.element.style.backgroundColor=this.color)),this.element.classList.toggle("prosemirror-dropcursor-block",i),this.element.classList.toggle("prosemirror-dropcursor-inline",!i),d&&(d!=document.body||"static"!=getComputedStyle(d).position)){let n=d.getBoundingClientRect(),i=n.width/d.offsetWidth,r=n.height/d.offsetHeight;e=n.left-d.scrollLeft*i,t=n.top-d.scrollTop*r}else e=-pageXOffset,t=-pageYOffset;this.element.style.left=(r.left-e)/s+"px",this.element.style.top=(r.top-t)/l+"px",this.element.style.width=(r.right-r.left)/s+"px",this.element.style.height=(r.bottom-r.top)/l+"px"}scheduleRemoval(e){clearTimeout(this.timeout),this.timeout=setTimeout(()=>this.setCursor(null),e)}dragover(e){if(!this.editorView.editable)return;let t=this.editorView.posAtCoords({left:e.clientX,top:e.clientY}),n=t&&t.inside>=0&&this.editorView.state.doc.nodeAt(t.inside),i=n&&n.type.spec.disableDropCursor,r="function"==typeof i?i(this.editorView,t,e):i;if(t&&!r){let e=t.pos;if(this.editorView.dragging&&this.editorView.dragging.slice){let t=ny(this.editorView.state.doc,e,this.editorView.dragging.slice);null!=t&&(e=t)}this.setCursor(e),this.scheduleRemoval(5e3)}}dragend(){this.scheduleRemoval(20)}drop(){this.scheduleRemoval(20)}dragleave(e){this.editorView.dom.contains(e.relatedTarget)||this.setCursor(null)}}class f4 extends nP{constructor(e){super(e,e)}map(e,t){let n=e.resolve(t.map(this.head));return f4.valid(n)?new f4(n):nP.near(n)}content(){return tf.empty}eq(e){return e instanceof f4&&e.head==this.head}toJSON(){return{type:"gapcursor",pos:this.head}}static fromJSON(e,t){if("number"!=typeof t.pos)throw RangeError("Invalid input for GapCursor.fromJSON");return new f4(e.resolve(t.pos))}getBookmark(){return new f6(this.anchor)}static valid(e){let t=e.parent;if(t.inlineContent||!function(e){for(let t=e.depth;t>=0;t--){let n=e.index(t),i=e.node(t);if(0==n){if(i.type.spec.isolating)return!0;continue}for(let e=i.child(n-1);;e=e.lastChild){if(0==e.childCount&&!e.inlineContent||f8(e.type))return!0;
vendor: 1,360 bytes, line 319
319if(e.inlineContent)return!1}}return!0}(e)||!function(e){for(let t=e.depth;t>=0;t--){let n=e.indexAfter(t),i=e.node(t);if(n==i.childCount){if(i.type.spec.isolating)return!0;continue}for(let e=i.child(n);;e=e.firstChild){if(0==e.childCount&&!e.inlineContent||f8(e.type))return!0;if(e.inlineContent)return!1}}return!0}(e))return!1;let n=t.type.spec.allowGapCursor;if(null!=n)return n;let i=t.contentMatchAt(e.index()).defaultType;return i&&i.isTextblock}static findGapCursorFrom(e,t,n=!1){i:for(;;){if(!n&&f4.valid(e))return e;let i=e.pos,r=null;for(let n=e.depth;;n--){let o=e.node(n);if(t>0?e.indexAfter(n)<o.childCount:e.index(n)>0){r=o.child(t>0?e.indexAfter(n):e.index(n)-1);break}if(0==n)return null;i+=t;let a=e.doc.resolve(i);if(f4.valid(a))return a}for(;;){let o=t>0?r.firstChild:r.lastChild;if(!o){if(r.isAtom&&!r.isText&&!nB.isSelectable(r)){e=e.doc.resolve(i+r.nodeSize*t),n=!1;continue i}break}r=o,i+=t;let a=e.doc.resolve(i);if(f4.valid(a))return a}return null}}}f4.prototype.visible=!1,f4.findFrom=f4.findGapCursorFrom,nP.jsonID("gapcursor",f4);class f6{constructor(e){this.pos=e}map(e){return new f6(e.map(this.pos))}resolve(e){let t=e.resolve(this.pos);return f4.valid(t)?new f4(t):nP.near(t)}}function f8(e){return e.isAtom||e.spec.isolating||e.spec.createGapCursor}let f7=o7({ArrowLeft:f9("horiz",-1),ArrowRight:f9("horiz",1),ArrowUp:f9("vert",
319-1),ArrowDown:f9("vert",1)});function f9(e,t){let n="vert"==e?t>0?"down":"up":t>0?"right":"left";return function(e,i,r){let o=e.selection,a=t>0?o.$to:o.$from,s=o.empty;if(o instanceof nO){if(!r.endOfTextblock(n)||0==a.depth)return!1;s=!1,a=e.doc.resolve(t>0?a.after():a.before())}let l=f4.findGapCursorFrom(a,t,s);return!!l&&(i&&i(e.tr.setSelection(new f4(l))),!0)}}function ge(e,t,n){if(!e||!e.editable)return!1;let i=e.state.doc.resolve(t);if(!f4.valid(i))return!1;let r=e.posAtCoords({left:n.clientX,top:n.clientY});return!(r&&r.inside>-1&&nB.isSelectable(e.state.doc.nodeAt(r.inside)))&&(e.dispatch(e.state.tr.setSelection(new f4(i))),!0)}function gt(e,t){if("insertCompositionText"!=t.inputType||!(e.state.selection instanceof f4))return!1;let{$from:n}=e.state.selection,i=n.parent.contentMatchAt(n.index()).findWrapping(e.state.schema.nodes.text);if(!i)return!1;let r=tl.empty;for(let e=i.length-1;e>=0;e--)r=tl.from(i[e].createAndFill(null,r));let o=e.state.tr.replace(n.pos,n.pos,new tf(r,0,0));return o.setSelection(nO.near(o.doc.resolve(n.pos+1))),e.dispatch(o),!1}function gn(e){if(!(e.selection instanceof f4))return null;let t=document.createElement("div");return t.className="ProseMirror-gapcursor",ok.create(e.doc,[oC.widget(e.selection.head,t,{key:"gapcursor"})])}var gi=function(){};gi.prototype.append=function(e){return e.length?(e=gi.from(e),!this.length&&e||e.length<200&&this.leafAppend(e)||this.length<200&&e.leafPrepend(this)||this.appendInner(e)):this},gi.prototype.prepend=function(e){return e.length?gi.from(e).append(this):this},gi.prototype.appendInner=function(e){return new go(this,e)},gi.prototype.slice=function(e,t){return(void 0===e&&(e=0),void 0===t&&(t=this.length),e>=t)?gi.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,t))},gi.prototype.get=function(e){if(!(e<0)&&!(e>=this.length))return this.getInner(e)},gi.prototype.forEach=function(e,t,n){void 0===t&&(t=0),void 0===n&&(n=this.length),t<=n?this.forEachInner(e,t,n,0):this.forEachInvertedInner(e,t,n,0)},gi.prototype.map=function(e,t,n){void 0===t&&(t=0),void 0===n&&(n=this.length);var i=[];return this.forEach(function(t,n){return i.push(e(t,n))},t,n),i},gi.from=function(e){return e instanceof gi?e:e&&e.length?new gr(e):gi.empty};var gr=function(e){function t(t){e.call(this),this.values=t}t.__proto__=e,t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(e,n){return 0==e&&n==this.length?this:new t(this.values.slice(e,n))},t.prototype.getInner=function(e){return this.values[e]},t.prototype.forEachInner=function(e,t,n,i){for(var r=t;r<n;r++)if(!1===e(this.values[r],i+r))return!1},t.prototype.forEachInvertedInner=function(e,t,n,i){for(var r=t-1;r>=n;r--)if(!1===e(this.values[r],i+r))return!1},t.prototype.leafAppend=function(e){if(this.length+e.length<=200)return new t(this.values.concat(e.flatten()))},t.prototype.leafPrepend=function(e){if(this.length+e.length<=200)return new t(e.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}(gi);gi.empty=new gr([]);var go=function(e){function t(t,n){e.call(this),this.left=t,this.right=n,this.length=t.length+n.length,this.depth=Math.max(t.depth,n.depth)+1}return t.__proto__=e,t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(e){return e<this.left.length?this.left.get(e):this.right.get(e-this.left.length)},t.prototype.forEachInner=function(e,t,n,i){var r=this.left.length;if(t<r&&!1===this.left.forEachInner(e,t,Math.min(n,r),i)||n>r&&!1===this.right.forEachInner(e,Math.max(t-r,0),Math.min(this.length,n)-r,i+r))return!1},t.prototype.forEachInvertedInner=function(e,t,n,i){var r=this.left.length;if(t>r&&!1===this.right.forEachInvertedInner(e,t-r,Math.max(n,r)-r,i+r)||n<r&&!1===this.left.forEachInvertedInner(e,Math.min(t,r),n,i))return!1},t.prototype.sliceInner=function(e,t){if(0==e&&t==this.length)return this;var n=this.left.length;return t<=n?this.left.slice(e,t):e>=n?this.right.slice(e-n,t-n):this.left.slice(e,n).append(this.right.slice(0,t-n))},t.prototype.leafAppend=function(e){var n=this.right.leafAppend(e);if(n)return new t(this.left,n)},t.prototype.leafPrepend=function(e){var n=this.left.leafPrepend(e);if(n)return new t(n,this.right)},t.prototype.appendInner=function(e){return this.left.depth>=Math.max(this.right.depth,e.depth)+1?new t(this.left,new t(this.right,e)):new t(this,e)},t}(gi);class ga{constructor(e,t){this.items=e,this.eventCount=t}popEvent(e,t){let n,i,r,o;
319if(0==this.eventCount)return null;let a=this.items.length;for(;;a--)if(this.items.get(a-1).selection){--a;break}t&&(i=(n=this.remapping(a,this.items.length)).maps.length);let s=e.tr,l=[],d=[];return this.items.forEach((e,t)=>{if(!e.step){n||(i=(n=this.remapping(a,t+1)).maps.length),i--,d.push(e);return}if(n){d.push(new gs(e.map));let t=e.step.map(n.slice(i)),r;t&&s.maybeStep(t).doc&&(r=s.mapping.maps[s.mapping.maps.length-1],l.push(new gs(r,void 0,void 0,l.length+d.length))),i--,r&&n.appendMap(r,i)}else s.maybeStep(e.step);if(e.selection)return r=n?e.selection.map(n.slice(i)):e.selection,o=new ga(this.items.slice(0,a).append(d.reverse().concat(l)),this.eventCount-1),!1},this.items.length,0),{remaining:o,transform:s,selection:r}}addTransform(e,t,n,i){var r,o;let a,s=[],l=this.eventCount,d=this.items,u=!i&&d.length?d.get(d.length-1):null;for(let n=0;n<e.steps.length;n++){let r=e.steps[n].invert(e.docs[n]),o=new gs(e.mapping.maps[n],r,t),a;(a=u&&u.merge(o))&&(o=a,n?s.pop():d=d.slice(0,d.length-1)),s.push(o),t&&(l++,t=void 0),i||(u=o)}let c=l-n.depth;return c>gd&&(r=d,o=c,r.forEach((e,t)=>{if(e.selection&&0==o--)return a=t,!1}),d=r.slice(a),l-=c),new ga(d.append(s),l)}remapping(e,t){let n=new t6;return this.items.forEach((t,i)=>{let r=null!=t.mirrorOffset&&i-t.mirrorOffset>=e?n.maps.length-t.mirrorOffset:void 0;n.appendMap(t.map,r)},e,t),n}addMaps(e){return 0==this.eventCount?this:new ga(this.items.append(e.map(e=>new gs(e))),this.eventCount)}rebased(e,t){if(!this.eventCount)return this;let n=[],i=Math.max(0,this.items.length-t),r=e.mapping,o=e.steps.length,a=this.eventCount;this.items.forEach(e=>{e.selection&&a--},i);let s=t;this.items.forEach(t=>{let i=r.getMirror(--s);if(null==i)return;o=Math.min(o,i);let l=r.maps[i];if(t.step){let o=e.steps[i].invert(e.docs[i]),d=t.selection&&t.selection.map(r.slice(s+1,i));d&&a++,n.push(new gs(l,o,d))}else n.push(new gs(l))},i);let l=[];for(let e=t;e<o;e++)l.push(new gs(r.maps[e]));let d=new ga(this.items.slice(0,i).append(l).append(n),a);return d.emptyItemCount()>500&&(d=d.compress(this.items.length-n.length)),d}emptyItemCount(){let e=0;return this.items.forEach(t=>{!t.step&&e++}),e}compress(e=this.items.length){let t=this.remapping(0,e),n=t.maps.length,i=[],r=0;return this.items.forEach((o,a)=>{if(a>=e)i.push(o),o.selection&&r++;else if(o.step){let e=o.step.map(t.slice(n)),a=e&&e.getMap();if(n--,a&&t.appendMap(a,n),e){let s=o.selection&&o.selection.map(t.slice(n));s&&r++;let l=new gs(a.invert(),e,s),d,u=i.length-1;(d=i.length&&i[u].merge(l))?i[u]=d:i.push(l)}}else o.map&&n--},this.items.length,0),new ga(gi.from(i.reverse()),r)}}ga.empty=new ga(gi.empty,0);class gs{constructor(e,t,n,i){this.map=e,this.step=t,this.selection=n,this.mirrorOffset=i}merge(e){if(this.step&&e.step&&!e.selection){let t=e.step.merge(this.step);if(t)return new gs(t.getMap().invert(),t,this.selection)}}}class gl{constructor(e,t,n,i,r){this.done=e,this.undone=t,this.prevRanges=n,this.prevTime=i,this.prevComposition=r}}let gd=20;function gu(e){let t=[];for(let n=e.length-1;n>=0&&0==t.length;n--)e[n].forEach((e,n,i,r)=>t.push(i,r));return t}function gc(e,t){if(!e)return null;let n=[];for(let i=0;i<e.length;i+=2){let r=t.map(e[i],1),o=t.map(e[i+1],-1);r<=o&&n.push(r,o)}return n}let gh=!1,gp=null;function gf(e){let t=e.plugins;if(gp!=t){gh=!1,gp=t;for(let e=0;e<t.length;e++)if(t[e].spec.historyPreserveItems){gh=!0;break}}return gh}let gg=new nQ("history"),gm=new nQ("closeHistory");function gv(e,t){return(n,i)=>{let r=gg.getState(n);if(!r||0==(e?r.undone:r.done).eventCount)return!1;if(i){let o=function(e,t,n){let i=gf(t),r=gg.get(t).spec.config,o=(n?e.undone:e.done).popEvent(t,i);if(!o)return null;let a=o.selection.resolve(o.transform.doc),s=(n?e.done:e.undone).addTransform(o.transform,t.selection.getBookmark(),r,i),l=new gl(n?s:o.remaining,n?o.remaining:s,null,0,-1);return o.transform.setSelection(a).setMeta(gg,{redo:n,historyState:l})}(r,n,e);o&&i(t?o.scrollIntoView():o)}return!0}}let gy=gv(!1,!0),gb=gv(!0,!0);gv(!1,!1),gv(!0,!1),lp.create({name:"characterCount",addOptions:()=>({limit:null,autoTrim:!0,mode:"textSize",textCounter:e=>e.length,wordCounter:e=>e.split(" ").filter(e=>""!==e).length}),addStorage:()=>({characters:()=>0,words:()=>0}),onBeforeCreate(){this.storage.characters=e=>{let t=(null==e?void 0:e.node)||this.editor.state.doc;if("textSize"===((null==e?void 0:e.mode)||this.options.mode)){let e=t.textBetween(0,t.content.size,void 0," ");return this.options.textCounter(e)}return t.nodeSize},this.storage.words=e=>{let t=(null==e?void 0:e.node)||this.editor.state.doc,n=t.textBetween(0,t.content.size," "," ");return this.options.wordCounter(n)}},addProseMirrorPlugins(){let e=!1;return[new nZ({key:new nQ("characterCount"),appendTransaction:(t,n,i)=>{if(e)return;let r=this.options.limit,o=this.options.autoTrim;if(null==r||0===r||!1===o){e=!0;return}let a=this.storage.characters({node:i.doc});if(a>r){console.warn(`[CharacterCount] Initial content exceeded limit of ${r} characters. Content was automatically trimmed.`);let t=i.tr.deleteRange(0,a-r);return e=!0,t}e=!0},filterTransaction:(e,t)=>{let n=this.options.limit;if(!e.docChanged||0===n||null==n)return!0;let i=this.storage.characters({node:t.doc}),r=this.storage.characters({node:e.doc});if(r<=n||i>n&&r>n&&r<=i)return!0;
319if(i>n&&r>n&&r>i||!e.getMeta("paste"))return!1;let o=e.selection.$head.pos;return e.deleteRange(o-(r-n),o),!(this.storage.characters({node:e.doc})>n)}})]}});var gx=lp.create({name:"dropCursor",addOptions:()=>({color:"currentColor",width:1,class:void 0}),addProseMirrorPlugins(){return[function(e={}){return new nZ({view:t=>new f5(t,e)})}(this.options)]}});lp.create({name:"focus",addOptions:()=>({className:"has-focus",mode:"all"}),addProseMirrorPlugins(){return[new nZ({key:new nQ("focus"),props:{decorations:({doc:e,selection:t})=>{let{isEditable:n,isFocused:i}=this.editor,{anchor:r}=t,o=[];if(!n||!i)return ok.create(e,[]);let a=0;"deepest"===this.options.mode&&e.descendants((e,t)=>{if(!e.isText){if(!(r>=t&&r<=t+e.nodeSize-1))return!1;a+=1}});let s=0;return e.descendants((e,t)=>!e.isText&&!!(r>=t&&r<=t+e.nodeSize-1)&&((s+=1,"deepest"===this.options.mode&&a-s>0||"shallowest"===this.options.mode&&s>1)?"deepest"===this.options.mode:void o.push(oC.node(t,t+e.nodeSize,{class:this.options.className})))),ok.create(e,o)}}})]}});var gw=lp.create({name:"gapCursor",addProseMirrorPlugins:()=>[new nZ({props:{decorations:gn,createSelectionBetween:(e,t,n)=>t.pos==n.pos&&f4.valid(n)?new f4(n):null,handleClick:ge,handleKeyDown:f7,handleDOMEvents:{beforeinput
319:gt}}})],extendNodeSchema(e){var t;let n={name:e.name,options:e.options,storage:e.storage};return{allowGapCursor:null!=(t=sl(sr(e,"allowGapCursor",n)))?t:null}}}),gC="placeholder",gS=new nQ("tiptap__placeholder");function g_(e){let{editor:t,placeholder:n,dataAttribute:i,pos:r,node:o,isEmptyDoc:a,hasAnchor:s,classes:{emptyNode:l,emptyEditor:d}}=e,u=[l];return a&&u.push(d),oC.node(r,r+o.nodeSize,{class:u.join(" "),[i]:"function"==typeof n?n({editor:t,node:o,pos:r,hasAnchor:s}):n})}function gk(e,t){return"function"==typeof e?e(t):e}var gM={init:()=>({topPos:null,bottomPos:null}),apply(e,t){let n=e.getMeta(gS);return(null==n?void 0:n.positions)?{topPos:n.positions.top,bottomPos:n.positions.bottom}:e.docChanged?{topPos:null!==t.topPos?e.mapping.map(t.topPos):null,bottomPos:null!==t.bottomPos?e.mapping.map(t.bottomPos):null}:t}};function gT(e){let t=function(e){let t=e;for(;t;){if(function(e){let t=getComputedStyle(e),n=`${t.overflow} ${t.overflowY} ${t.overflowX}`;return/auto|scroll|overlay/.test(n)}(t))return t;let e=t.parentElement;if(!e){let e=t.getRootNode();if(e instanceof ShadowRoot){t=e.host;continue}break}t=e}return window}(e.dom),n=()=>{let n=function({view:e,scrollContainer:t}){let n=e.dom.getBoundingClientRect();if(n.width<=0||n.height<=0)return null;let i=t?t===window?{top:0,bottom:window.innerHeight}:t.getBoundingClientRect():{top:0,bottom:window.innerHeight},r=Math.max(n.top,i.top)-200,o=Math.min(n.bottom,i.bottom)+200;if(r>=o)return null;let a=n.left+1,s=n.right-1;if(a>s)return null;let l=Math.min(Math.max("rtl"===getComputedStyle(e.dom).direction?n.right-2:n.left+2,a),s),d=Math.max(r+2,n.top+1),u=Math.min(o-2,n.bottom-1);if(d>u)return null;let c=e.posAtCoords({left:l,top:d}),h=e.posAtCoords({left:l,top:u});return c&&h?{top:c.pos,bottom:h.pos}:null}({view:e,scrollContainer:t});if(null===n)return;let i=gS.getState(e.state);if((null==i?void 0:i.topPos)===n.top&&(null==i?void 0:i.bottomPos)===n.bottom)return;let r=e.state.tr.setMeta(gS,{positions:n});e.dispatch(r)},i=null,r=0,o=()=>{null===i&&(i=requestAnimationFrame(()=>{i=null;let e=performance.now();e-r>=150?(r=e,n()):o()}))};t.addEventListener("scroll",o,{passive:!0});let a="u">typeof ResizeObserver?new ResizeObserver(o):null;null==a||a.observe(e.dom);let s="u">typeof IntersectionObserver?new IntersectionObserver(o):null;return null==s||s.observe(e.dom),e.dom.addEventListener("focus",o),n(),{update(t,n){e.state.doc.content.size!==n.doc.content.size&&o()},destroy:()=>{null!==i&&cancelAnimationFrame(i),t.removeEventListener("scroll",o),null==a||a.disconnect(),null==s||s.disconnect(),e.dom.removeEventListener("focus",o)}}}lp.create({name:"placeholder",addOptions:()=>({emptyEditorClass:"is-editor-empty",emptyNodeClass:"is-empty",dataAttribute:gC,placeholder:"Write something â¦",showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}),addProseMirrorPlugins(){return[function({editor:e,options:t}){let n=t.dataAttribute?`data-${t.dataAttribute.replace(/\s+/g,"-").replace(/[^a-zA-Z0-9-]/g,"").replace(/^[0-9-]+/,"").replace(/^-+/,"").toLowerCase()}`:`data-${gC}`;return new nZ({key:gS,state:gM,view:gT,props:{decorations:({doc:i,selection:r})=>(function({editor:e,options:t,dataAttribute:n,doc:i,selection:r}){var o,a;if(!(e.isEditable||!t.showOnlyWhenEditable))return null;let{anchor:s}=r,l=[],d=e.isEmpty;if(t.showOnlyCurrent&&!t.includeChildren){let r=i.resolve(s),o=r.depth>0?r.node(1):r.nodeAfter,a=r.depth>0?r.before(1):s;if(o&&o.type.isTextblock&&sR(o)){let i=s>=a&&s<=a+o.nodeSize;l.push(g_({editor:e,isEmptyDoc:d,dataAttribute:n,hasAnchor:i,placeholder:t.placeholder,classes:{emptyEditor:t.emptyEditorClass,emptyNode:gk(t.emptyNodeClass,{editor:e,node:o,pos:a,hasAnchor:i})},node:o,pos:a}))}}else{let r=gS.getState(e.state),u=null!=(o=null==r?void 0:r.topPos)?o:0,c=null!=(a=null==r?void 0:r.bottomPos)?a:i.content.size;i.nodesBetween(u,c,(i,r)=>{let o=s>=r&&s<=r+i.nodeSize,a=!i.isLeaf&&sR(i);return i.type.isTextblock&&(o||!t.showOnlyCurrent)&&a&&l.push(g_({editor:e,isEmptyDoc:d,dataAttribute:n,hasAnchor:o,placeholder:t.placeholder,classes:{emptyEditor:t.emptyEditorClass,emptyNode:gk(t.emptyNodeClass,{editor:e,node:i,pos:r,hasAnchor:o})},node:i,pos:r})),t.includeChildren})}return ok.create(i,l)})({editor:e,options:t,dataAttribute:n,doc:i,selection:r})}})}({editor:this.editor,options:this.options})]}});var gD=`.ProseMirror:not(.ProseMirror-focused) *::selection { 320 background: transparent; 321} 322 323.ProseMirror:not(.ProseMirror-focused) *::-moz-selection { 324 background: transparent; 325}`;function gR({types:e,node:t}){return t&&Array.isArray(e)&&e.includes(t.type)||(null==t?void 0:t.type)===e}lp.create({name:"selection",addOptions:()=>({className:"selection"}),addProseMirrorPlugins(){let{editor:e,options:t}=this;return e.options.injectCSS&&"u">typeof document&&s4(gD,e.options.injectNonce,"selection"),[new nZ({key:new nQ("selection"),props:{decorations:n=>n.selection.empty||e.isFocused||!e.isEditable||sI(n.selection)||e.view.dragging?null:ok.create(n.doc,[oC.inline(n.selection.from,n.selection.to,{class:t.className})])}})]}});var gI=lp.create({name:"trailingNode",addOptions:()=>({node:void 0,notAfter:[]}),addProseMirrorPlugins(){var e;let t=new nQ(this.name),n=this.options.node||(null==(e=this.editor.schema.topNodeType.contentMatch.defaultType)?void 0:e.name)||"paragraph",i=Object.entries(this.editor.schema.nodes).map(([,e])=>e).filter(e=>(this.options.notAfter||[]).concat(n).includes(e.name));return[new nZ({key:t,appendTransaction:(e,i,r)=>{let{doc:o,tr:a,schema:s}=r,l=t.getState(r),d=o.content.size,u=s.nodes[n];if(!e.some(e=>e.getMeta("skipTrailingNode"))&&l)return a.insert(d,u.create())},state:{init:(e,t)=>
325!gR({node:t.tr.doc.lastChild,types:i}),apply:(e,t)=>!e.docChanged||e.getMeta("__uniqueIDTransaction")?t:!gR({node:e.doc.lastChild,types:i})}})]}}),gA=lp.create({name:"undoRedo",addOptions:()=>({depth:100,newGroupDelay:500}),addCommands:()=>({undo:()=>({state:e,dispatch:t})=>gy(e,t),redo:()=>({state:e,dispatch:t})=>gb(e,t)}),addProseMirrorPlugins(){return[function(e={}){return new nZ({key:gg,state:{init:()=>new gl(ga.empty,ga.empty,null,0,-1),apply:(t,n,i)=>(function(e,t,n,i){let r=n.getMeta(gg),o;if(r)return r.historyState;n.getMeta(gm)&&(e=new gl(e.done,e.undone,null,0,-1));let a=n.getMeta("appendedTransaction");if(0==n.steps.length)return e;if(a&&a.getMeta(gg))if(a.getMeta(gg).redo)return new gl(e.done.addTransform(n,void 0,i,gf(t)),e.undone,gu(n.mapping.maps),e.prevTime,e.prevComposition);else return new gl(e.done,e.undone.addTransform(n,void 0,i,gf(t)),null,e.prevTime,e.prevComposition);if(!1===n.getMeta("addToHistory")||a&&!1===a.getMeta("addToHistory"))if(o=n.getMeta("rebased"))return new gl(e.done.rebased(n,o),e.undone.rebased(n,o),gc(e.prevRanges,n.mapping),e.prevTime,e.prevComposition);else return new gl(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),gc(e.prevRanges,n.mapping),e.prevTime,e.prevComposition);{let r=n.getMeta("composition"),o=0==e.prevTime||!a&&e.prevComposition!=r&&(e.prevTime<(n.time||0)-i.newGroupDelay||!function(e,t){if(!t)return!1;if(!e.docChanged)return!0;let n=!1;return e.mapping.maps[0].forEach((e,i)=>{for(let r=0;r<t.length;r+=2)e<=t[r+1]&&i>=t[r]&&(n=!0)}),n}(n,e.prevRanges)),s=a?gc(e.prevRanges,n.mapping):gu(n.mapping.maps);return new gl(e.done.addTransform(n,o?t.selection.getBookmark():void 0,i,gf(t)),ga.empty,s,n.time,null==r?e.prevComposition:r)}})(n,i,t,e)},config:e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},props:{handleDOMEvents:{beforeinput(e,t){let n=t.inputType,i="historyUndo"==n?gy:"historyRedo"==n?gb:null;return!!i&&!!e.editable&&(t.preventDefault(),i(e.state,e.dispatch))}}}})}(this.options)]},addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Shift-Mod-z":()=>this.editor.commands.redo(),"Mod-y":()=>this.editor.commands.redo(),"Mod-Ñ":()=>this.editor.commands.undo(),"Shift-Mod-Ñ":()=>this.editor.commands.redo()}}}),gP=lp.create({name:"starterKit",addExtensions(){var e,t,n,i;let r=[];return!1!==this.options.bold&&r.push(hD.configure(this.options.bold)),!1!==this.options.blockquote&&r.push(hS.configure(this.options.blockquote)),!1!==this.options.bulletList&&r.push(ff.configure(this.options.bulletList)),!1!==this.options.code&&r.push(hA.configure(this.options.code)),!1!==this.options.codeBlock&&r.push(hL.configure(this.options.codeBlock)),!1!==this.options.document&&r.push(hF.configure(this.options.document)),!1!==this.options.dropcursor&&r.push(gx.configure(this.options.dropcursor)),!1!==this.options.gapcursor&&r.push(gw.configure(this.options.gapcursor)),!1!==this.options.hardBreak&&r.push(hO.configure(this.options.hardBreak)),!1!==this.options.heading&&r.push(hN.configure(this.options.heading)),!1!==this.options.undoRedo&&r.push(gA.configure(this.options.undoRedo)),!1!==this.options.horizontalRule&&r.push(hB.configure(this.options.horizontalRule)),!1!==this.options.italic&&r.push(hG.configure(this.options.italic)),!1!==this.options.listItem&&r.push(fk.configure(this.options.listItem)),!1!==this.options.listKeymap&&r.push(fz.configure(null==(e=this.options)?void 0:e.listKeymap)),!1!==this.options.link&&r.push(fu.configure(null==(t=this.options)?void 0:t.link)),!1!==this.options.orderedList&&r.push(fq.configure(this.options.orderedList)),!1!==this.options.paragraph&&r.push(fJ.configure(this.options.paragraph)),!1!==this.options.strike&&r.push(f1.configure(this.options.strike)),!1!==this.options.text&&r.push(f2.configure(this.options.text)),!1!==this.options.underline&&r.push(f3.configure(null==(n=this.options)?void 0:n.underline)),!1!==this.options.trailingNode&&r.push(gI.configure(null==(i=this.options)?void 0:i.trailingNode)),r}}),gE=lp.create({name:"textAlign",addOptions:()=>({types:[],alignments:["left","center","right","justify"],defaultAlignment:null}),addGlobalAttributes(){return[{types:this.options.types,attributes:{textAlign:{default:this.options.defaultAlignment,parseHTML:e=>{let t=e.style.textAlign;return this.options.alignments.includes(t)?t:this.options.defaultAlignment},renderHTML:e=>e.textAlign?{style:`text-align: ${e.textAlign}`}:{}}}}]},addCommands(){return{setTextAlign:e=>({commands:t})=>!!this.options.alignments.includes(e)&&this.options.types.map(n=>t.updateAttributes(n,{textAlign:e})).some(e=>e),unsetTextAlign:()=>({commands:e})=>this.options.types.map(t=>e.resetAttributes(t,"textAlign")).some(e=>e),toggleTextAlign:e=>({editor:t,commands:n})=>!!this.options.alignments.includes(e)&&(t.isActive({textAlign:e})?n.unsetTextAlign():n.setTextAlign(e))}}
325,addKeyboardShortcuts(){return{"Mod-Shift-l":()=>this.editor.commands.setTextAlign("left"),"Mod-Shift-e":()=>this.editor.commands.setTextAlign("center"),"Mod-Shift-r":()=>this.editor.commands.setTextAlign("right"),"Mod-Shift-j":()=>this.editor.commands.setTextAlign("justify")}}}),gL=e.i(3218),gF=e.i(17363);e.s(["RichTextInput",0,({name:e,label:t,required:n,errors:i,width:r,readonly:o,control:s,tooltip:u,toolbar:g})=>{let{tenant:m}=(0,l.useTenant)(),{t:v}=(0,p.useTranslations)(),[y,b]=f.default.useState(!1);return f.default.useEffect(()=>{b(!0)},[]),(0,a.jsx)(c.Width,{width:r,children:(0,a.jsx)(E.Controller,{name:e,control:s,rules:{required:n},render:({field:r})=>{let s=function(e={},t=[]){let n=(0,tn.useRef)(e);n.current=e;let[i]=(0,tn.useState)(()=>new dl(n)),r=(0,tr.useSyncExternalStore)(i.subscribe,i.getEditor,i.getServerSnapshot);return(0,tn.useDebugValue)(r),(0,tn.useEffect)(i.onRender(t)),!function(e){var t;let[n]=(0,tn.useState)(()=>new dr(e.editor)),i=(0,l7.useSyncExternalStoreWithSelector)(n.subscribe,n.getSnapshot,n.getServerSnapshot,e.selector,null!=(t=e.equalityFn)?t:l6);di(()=>n.watch(e.editor),[e.editor,n]),(0,tn.useDebugValue)(i)}({editor:r,selector:({transactionNumber:t})=>!1===e.shouldRerenderOnTransaction||void 0===e.shouldRerenderOnTransaction?null:e.immediatelyRender&&0===t?0:t+1}),r}({extensions:[gP,gE.configure({types:["heading","paragraph"]})],content:r.value||"",onUpdate:({editor:e})=>{r.onChange(e.getHTML())},editable:!o,immediatelyRender:!1});return y?(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{className:gF.default.label,children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:u}),n&&(0,a.jsx)("span",{className:gF.default.required,children:" *"})]}),(0,a.jsx)(gL.Paper,{radius:(0,d.getRadius)(m.Theme?.borderRadius),className:gF.default.richTextWrapper,children:(0,a.jsxs)(cR,{editor:s,styles:{root:{border:"none"},control:{"&[dataDisabled]":{backgroundColor:"var(--mantine-color-disabled)",color:"var(--mantine-color-disabled-color)"}}},children:[(0,a.jsxs)(cR.Toolbar,{children:[(0,a.jsxs)(cR.ControlsGroup,{children:[(0,a.jsx)(cR.Bold,{disabled:!g?.bold}),(0,a.jsx)(cR.Italic,{disabled:!g?.italic}),(0,a.jsx)(cR.Underline,{disabled:!g?.underline}),(0,a.jsx)(cR.Strikethrough,{disabled:!g?.strikethrough}),(0,a.jsx)(cR.Superscript,{disabled:!g?.superscript}),(0,a.jsx)(cR.Subscript,{disabled:!g?.subscript})]}),(0,a.jsxs)(cR.ControlsGroup,{children:[(0,a.jsx)(cR.H1,{disabled:!g?.h1}),(0,a.jsx)(cR.H2,{disabled:!g?.h2}),(0,a.jsx)(cR.H3,{disabled:!g?.h3}),(0,a.jsx)(cR.H4,{disabled:!g?.h4}),(0,a.jsx)(cR.H5,{disabled:!g?.h5}),(0,a.jsx)(cR.H6,{disabled:!g?.h6})]}),(0,a.jsxs)(cR.ControlsGroup,{children:[(0,a.jsx)(cR.BulletList,{disabled:!g?.bulletList}),(0,a.jsx)(cR.OrderedList,{disabled:!g?.orderedList}),(0,a.jsx)(cR.Hr,{disabled:!g?.hr})]}),(0,a.jsxs)(cR.ControlsGroup,{children:[(0,a.jsx)(cR.Link,{disabled:!g?.link}),(0,a.jsx)(cR.Unlink,{disabled:!g?.link})]}),(0,a.jsxs)(cR.ControlsGroup,{children:[(0,a.jsx)(cR.AlignLeft,{disabled:!g?.alignLeft}),(0,a.jsx)(cR.AlignCenter,{disabled:!g?.alignCenter}),(0,a.jsx)(cR.AlignRight,{disabled:!g?.alignRight}),(0,a.jsx)(cR.AlignJustify,{disabled:!g?.alignJustify})]})]}),(0,a.jsx)(cR.Content,{})]})}),n&&i[e]&&(0,a.jsx)("div",{className:gF.default.error,children:v("fieldRequired")})]}):(0,a.jsx)("div",{children:(0,a.jsxs)("label",{className:gF.default.label,children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:u}),n&&(0,a.jsx)("span",{className:gF.default.required,children:" *"})]})})}})})}],8812);var gO=e.i(46310),gN=e.i(29730),gB=e.i(12998),gz=e.i(8090),gj=e.i(84352),gV=e.i(66831),gH=e.i(41577),gG=e.i(48159),gW=e.i(65457),g$=e.i(60062),gU={field:"m_45c4369d"};let gq={type:"visible"},gK=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("PillsInputField",gq,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,type:u,disabled:c,id:h,pointer:p,mod:f,attributes:g,...m}=n,v=(0,gW.usePillsInputContext)(),y=(0,g$.useInputWrapperContext)(),C=(0,x.useStyles)({name:"PillsInputField",classes:gU,props:n,className:r,style:o,classNames:i,styles:s,unstyled:l,attributes:g,rootSelector:"field"}),S=c||v?.disabled;return(0,a.jsx)(w.Box,{component:"input",ref:(0,ed.useMergedRef)(t,v?.fieldRef),"data-type":u,disabled:S,mod:[{disabled:S,pointer:p},f],...C("field"),...m,id:y?.inputId||h,"aria-invalid":v?.hasError,"aria-describedby":y?.describedBy,type:"text",onMouseDown:e=>!p&&e.stopPropagation()})});gK.classes=gU,gK.displayName="@mantine/core/PillsInputField";let gY={size:"sm"},gZ=(0,C.factory)((e,t)=>{let{children:n,onMouseDown:i,onClick:r,size:o,disabled:s,__staticSelector:l,error:d,variant:u,...c}=(0,b.useProps)("PillsInput",gY,e),h=(0,f.useRef)(null);return(0,a.jsx)(gW.PillsInputProvider,{value:{fieldRef:h,size:o,disabled:s,hasError:!!d,variant:u},children:(0,a.jsx)(ep.InputBase,{size:o,error:d,variant:u,component:"div",ref:t,"data-no-overflow":!0,onMouseDown:e=>{e.preventDefault(),i?.(e),h.current?.focus()},onClick:e=>{e.preventDefault();let t=e.currentTarget.closest("fieldset");t?.disabled||(h.current?.focus(),r?.(e))},...c,multiline:!0,disabled:s,__staticSelector:l||"PillsInput",withAria:!1,children:n})})});gZ.displayName="@mantine/core/PillsInput",gZ.Field=gK;var gX=e.i(97450);let gJ={xs:41,sm:50,md:60,lg:72,xl:89},gQ={maxValues:1/0,withCheckIcon:!0,checkIconPosition:"left",hiddenInputValuesDivider:",",clearSearchOnChange:!0,openOnFocus:!0,size:"sm"},g0=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("MultiSelect",gQ,e),{classNames:i,className:r,style:o,styles:s,unstyled:l,vars:d,size:u,value:c,defaultValue:h,onChange:p,onKeyDown:g,variant:m,data:v,dropdownOpened:y,defaultDropdownOpened:w,onDropdownOpen:C,onDropdownClose:S,selectFirstOptionOnChange:_,selectFirstOptionOnDropdownOpen:k,onOptionSubmit:M,comboboxProps:T,filter:D,limit:R,withScrollArea:I,maxDropdownHeight:A,searchValue:P,defaultSearchValue:E,onSearchChange:L,readOnly:F,disabled:O,onFocus:N,onBlur:B,radius:z,rightSection:j,rightSectionWidth:V,rightSectionPointerEvents:H,rightSectionProps:G,leftSection:W,leftSectionWidth:$,leftSectionPointerEvents:U,leftSectionProps:q,inputContainer:K,inputWrapperOrder:Y,withAsterisk:Z,labelProps:X,descriptionProps:J,errorProps:Q,wrapperProps:ee,description:et,label:en,error:ei,maxValues:er,searchable:eo,nothingFoundMessage:ea,withCheckIcon:el,withAlignedLabels:ed,checkIconPosition:eu,hidePickedOptions:ec,withErrorStyles:ep,name:ef,form:eg,id:em,clearable:ev,clearButtonProps:ey,hiddenInputProps:eb,placeholder:ex,hiddenInputValuesDivider:ew,required:eC,mod:eS,renderOption:e_,onRemove:ek,onClear:eM,scrollAreaProps:eD,chevronColor:eR,attributes:eI,clearSearchOnChange:eA,openOnFocus:eE,...eL}=n,eF=(0,eT.useId)(em),eO=(0,gB.getParsedComboboxData)(v),eN=(0,gz.getOptionsLockup)(eO),eB=(0,f.useRef)({}),ez=(0,gH.useCombobox)({opened:y,defaultOpened:w,onDropdownOpen:()=>{C?.(),k&&ez.selectFirstOption()},onDropdownClose:()=>{S?.(),ez.resetSelectedOption()}}),{styleProps:ej,rest:{type:eV,autoComplete:eH,...eG}}=(0,eP.extractStyleProps)(eL),[eW,e$]=(0,es.useUncontrolled)({value:c,defaultValue:h,finalValue:[],onChange:p}),[eU,eq]=(0,es.useUncontrolled)({value:P,defaultValue:E,finalValue:"",onChange:L}),eK=e=>{eq(e),ez.resetSelectedOption()},eY=(0,x.useStyles)({name:"MultiSelect",classes:{},props:n,classNames:i,styles:s,unstyled:l,attributes:eI}),{resolvedClassNames:eZ,resolvedStyles:eX}=(0,eh.useResolvedStylesApi)({props:n,styles:s,classNames:i}),eJ=eW.map((e,t)=>{let n=eN[e]||eB.current[e];return(0,a.jsx)(gG.Pill,{withRemoveButton:!F&&!eN[e]?.disabled,onRemove:()=>{e$(eW.filter(t=>e!==t)),ek?.(e)},unstyled:l,disabled:O,...eY("pill"),children:n?.label||e},`${e}-${t}`)});(0,f.useEffect)(()=>{_&&ez.selectFirstOption()},[_,eU]),(0,f.useEffect)(()=>
325{eW.forEach(e=>{e in eN&&(eB.current[e]=eN[e])})},[eN,eW]);let eQ=(0,a.jsx)(gj.Combobox.ClearButton,{...ey,onClear:()=>{eM?.(),e$([]),eK("")}}),e0=function({data:e,value:t}){let n=t.map(e=>e.trim().toLowerCase());return e.reduce((e,t)=>((0,gX.isOptionsGroup)(t)?e.push({group:t.group,items:t.items.filter(e=>-1===n.indexOf(e.value.toLowerCase().trim()))}):-1===n.indexOf(t.value.toLowerCase().trim())&&e.push(t),e),[])}({data:eO,value:eW}),e1=ev&&eW.length>0&&!O&&!F,e2=e1?{paddingInlineEnd:gJ[u]??gJ.sm}:void 0;return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)(gj.Combobox,{store:ez,classNames:eZ,styles:eX,unstyled:l,size:u,readOnly:F,__staticSelector:"MultiSelect",attributes:eI,onOptionSubmit:e=>{M?.(e),eA&&eK(""),ez.updateSelectedOptionIndex("selected"),eW.includes(eN[e].value)?(e$(eW.filter(t=>t!==eN[e].value)),ek?.(eN[e].value)):eW.length<er&&e$([...eW,eN[e].value])},...T,children:[(0,a.jsx)(gj.Combobox.DropdownTarget,{children:(0,a.jsx)(gZ,{...ej,__staticSelector:"MultiSelect",classNames:eZ,styles:eX,unstyled:l,size:u,className:r,style:o,variant:m,disabled:O,radius:z,__defaultRightSection:(0,a.jsx)(gj.Combobox.Chevron,{size:u,error:ei,unstyled:l,color:eR}),__clearSection:eQ,__clearable:e1,rightSection:j,rightSectionPointerEvents:H||"none",rightSectionWidth:V,rightSectionProps:G,leftSection:W,leftSectionWidth:$,leftSectionPointerEvents:U,leftSectionProps:q,inputContainer:K,inputWrapperOrder:Y,withAsterisk:Z,labelProps:X,descriptionProps:J,errorProps:Q,wrapperProps:ee,description:et,label:en,error:ei,withErrorStyles:ep,__stylesApiProps:{...n,rightSectionPointerEvents:H||"none",multiline:!0},pointer:!eo,onClick:()=>eo?ez.openDropdown():ez.toggleDropdown(),"data-expanded":ez.dropdownOpened||void 0,id:eF,required:eC,mod:eS,attributes:eI,children:(0,a.jsxs)(gG.Pill.Group,{attributes:eI,disabled:O,unstyled:l,...eY("pillsList",{style:e2}),children:[eJ,(0,a.jsx)(gj.Combobox.EventsTarget,{autoComplete:eH,children:(0,a.jsx)(gZ.Field,{...eG,ref:t,id:eF,placeholder:ex,type:eo||ex?"visible":"hidden",...eY("inputField"),unstyled:l,onFocus:e=>{N?.(e),eE&&eo&&ez.openDropdown()},onBlur:e=>{B?.(e),ez.closeDropdown(),eK("")},onKeyDown:e=>{g?.(e)," "!==e.key||eo||(e.preventDefault(),ez.toggleDropdown()),"Backspace"===e.key&&0===eU.length&&eW.length>0&&(ek?.(eW[eW.length-1]),e$(eW.slice(0,eW.length-1)))},value:eU,onChange:e=>{eK(e.currentTarget.value),eo&&ez.openDropdown(),_&&ez.selectFirstOption()},disabled:O,readOnly:F||!eo,pointer:!eo})})]})})}),(0,a.jsx)(gV.OptionsDropdown,{data:ec?e0:eO,hidden:F||O,filter:D,search:eU,limit:R,hiddenWhenEmpty:!ea,withScrollArea:I,maxDropdownHeight:A,filterOptions:eo,value:eW,checkIconPosition:eu,withCheckIcon:el,withAlignedLabels:ed,nothingFoundMessage:ea,unstyled:l,labelId:en?`${eF}-label`:void 0,"aria-label":en?void 0:eL["aria-label"],renderOption:e_,scrollAreaProps:eD})]}),(0,a.jsx)(gj.Combobox.HiddenInput,{name:ef,valuesDivider:ew,value:eW,form:eg,disabled:O,...eb})]})});g0.classes={...ep.InputBase.classes,...gj.Combobox.classes},g0.displayName="@mantine/core/MultiSelect",e.s(["MultiSelect",()=>g0],40867);var g1=e.i(35515),g2=e.i(98661),g3=e.i(69693);(0,g3.LINK_FIELDS)({disableAppearance:!0});var g5=e.i(21143);let g4=` 326 query Pages { 327 Pages(limit: 300) { 328 docs { 329 id 330 slug 331 title 332 } 333 } 334 } 335`;g5.HERO,g2.ARCHIVE_BLOCK,g2.CARD,g2.CAROUSEL,g2.COLLAPSIBLE,g2.COLUMN_BLOCK,g2.DIRECTORY_BLOCK,g2.ECHARTS_BLOCK,g2.FORM_BLOCK,g2.GRID_BLOCK,g2.HTML_EMBED,g2.IMAGE_AND_TEXT_BLOCK,g2.LINKS_BLOCK,g2.MAP_BLOCK,g2.MEDIA_BLOCK,g2.OPTIONS_BLOCK,g2.RICH_TEXT_BLOCK,g2.TABLE_BLOCK,g2.TOC_BLOCK,g2.VIDEO_BLOCK,g2.PLACEHOLDER_BLOCK,g1.SEO_META;var g6=e.i(92448);let g8=tt.default.env.BACKEND_TOKEN||"";var g7=e.i(27187);let g9=` 336 query Posts($where: Post_where) { 337 Posts(limit: 300, where: $where) { 338 docs { 339 id 340 slug 341 title 342 } 343 } 344 } 345`;g7.CATEGORIES,g5.HERO,g2.ARCHIVE_BLOCK,g2.CARD,g2.CAROUSEL,g2.COLLAPSIBLE,g2.COLUMN_BLOCK,g2.DIRECTORY_BLOCK,g2.ECHARTS_BLOCK,g2.FORM_BLOCK,g2.GRID_BLOCK,g2.HTML_EMBED,g2.IMAGE_AND_TEXT_BLOCK,g2.LINKS_BLOCK,g2.MAP_BLOCK,g2.MEDIA_BLOCK,g2.OPTIONS_BLOCK,g2.RICH_TEXT_BLOCK,g2.TABLE_BLOCK,g2.TOC_BLOCK,g2.VIDEO_BLOCK,g2.PLACEHOLDER_BLOCK,g5.HERO,g1.SEO_META;var me=e.i(86088);let mt=` 346 query Teams { 347 Teams(limit: 300) { 348 docs { 349 id 350 slug 351 fullName 352 } 353 } 354 } 355`;(0,me.MEDIA)(),(0,g3.LINK_FIELDS)(),g2.RICH_TEXT_BLOCK,g2.COLLAPSIBLE,g2.CAROUSEL,g2.MEDIA_BLOCK,g2.ARCHIVE_BLOCK,g2.IMAGE_AND_TEXT_BLOCK,g2.TABLE_BLOCK,g2.LINKS_BLOCK,g2.VIDEO_BLOCK,g2.FORM_BLOCK,g2.PLACEHOLDER_BLOCK,g1.SEO_META;var mn=e.i(80202);let mi={pages:{query:g4,key:"Pages"},posts:{query:g9,key:"Posts"},teams:{query:mt,key:"Teams"}},mr=async(t,n,i)=>{let r,o=mi[t];if(!o)throw Error(`Collection ${t} not found`);if(n){let{cookies:t}=await e.A(31981);r=(await t()).get(g8)}let a=await (0,g6.getTenantHeaders)();return a?await (0,mn.fetchWithRetry)(`${(0,g6.getGraphqlApiUrl)()}/api/graphql`,{method:"POST",headers:{...a||{},"Content-Type":"application/json",...r?.value&&n?{Authorization:`JWT ${r.value}`}:{}},...n?{cache:"no-store"}:{next:{revalidate:60,tags:[t]}},body:JSON.stringify({query:o.query,variables:i})})?.then(e=>e.json())?.then(e=>{if(e.errors)throw Error(e?.errors?.[0]?.message??"Error fetching docs");return e?.data?.[o.key]?.docs}):[]};e.s(["Select",0,({name:e,label:t="",options:n,required:i,hidden:r,errors:o,control:s,width:u,selectDefaultValue:g,setValue:m,getValues:v,selectDoc:y,maxValues:b,collection:x,postTypes:w,authors:C,categories:S,placeholder:_="Select an option",tooltip:k})=>{let{tenant:M}=(0,l.useTenant)(),{t:T}=(0,p.useTranslations)(),{options:D,loading:R}=((e,t)=>
355{let[n,i]=(0,f.useState)([]),[r,o]=(0,f.useState)(!1),a=(0,f.useMemo)(()=>t?JSON.stringify({postTypes:t.postTypes?.map(e=>"string"==typeof e?e:e.id).sort(),authors:t.authors?.map(e=>"string"==typeof e?e:e.id).sort(),categories:t.categories?.map(e=>"string"==typeof e?e:e.id).sort()}):"",[t]);return(0,f.useEffect)(()=>{e&&["pages","posts","teams"].includes(e)?(async()=>{o(!0);try{let n={};if("posts"===e&&t){let e={};t.postTypes?.length&&(e.postType={in:t.postTypes.map(e=>"string"==typeof e?e:e.id)}),t.authors?.length&&(e.author={in:t.authors.map(e=>"string"==typeof e?e:e.id)}),t.categories?.length&&(e.categories={in:t.categories.map(e=>"string"==typeof e?e:e.id)}),Object.keys(e).length>0&&(n.where=e)}let r=await mr(e,!1,n),o=r?.map(t=>({value:t.id,label:"teams"===e?t.fullName:t.title}))||[];i(o)}catch(e){console.error("Error fetching collection options:",e),i([])}finally{o(!1)}})():i([])},[e,a]),{options:n,loading:r}})(y?x:void 0,{postTypes:w,authors:C,categories:S}),I=y?D:n;f.default.useEffect(()=>{g&&!v(e)&&m(e,g)},[e,g,m,v]);let A=I.map(e=>({value:e.value,label:String(e.label)}));return(0,a.jsx)(c.Width,{width:u,hide:r,children:(0,a.jsx)(E.Controller,{control:s,rules:{required:i},name:e,render:({field:{onChange:n,value:r}})=>b&&b>1?(0,a.jsx)(g0,{searchable:!0,classNames:{label:gO.default.label},value:Array.isArray(r)?r:r?[r]:[],onChange:n,size:"md",radius:(0,d.getRadius)(M.Theme?.borderRadius),label:(0,a.jsxs)(a.Fragment,{children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:k})]}),withAsterisk:i,error:i&&o[e]&&T("fieldRequired"),placeholder:_,data:A,disabled:y&&R,clearable:!0,maxValues:b}):(0,a.jsx)(gN.Select,{searchable:!0,classNames:{label:gO.default.label},value:r,onChange:e=>n(e||null),size:"md",radius:(0,d.getRadius)(M.Theme?.borderRadius),label:(0,a.jsxs)(a.Fragment,{children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:k})]}),withAsterisk:i,error:i&&o[e]&&T("fieldRequired"),placeholder:_,data:A,disabled:y&&R,clearable:!0,allowDeselect:!0})})})}],2390);var mo=e.i(26369);function ma(){return(ma=Object.assign.bind()).apply(null,arguments)}e.s(["Text",0,({name:e,label:t,register:n,required:i,errors:r,width:o,readonly:u,textDefaultValue:g,setValue:m,getValues:v,placeholder:y,tooltip:b})=>{let{tenant:x}=(0,l.useTenant)(),{t:w}=(0,p.useTranslations)();return f.default.useEffect(()=>{g&&!v(e)&&m(e,g)},[e,g,m,v]),(0,a.jsx)(c.Width,{width:o,children:(0,a.jsx)(s.TextInput,{readOnly:u,classNames:{label:mo.default.label},size:"md",radius:(0,d.getRadius)(x.Theme?.borderRadius),label:(0,a.jsxs)(a.Fragment,{children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:b})]}),withAsterisk:i,placeholder:y||w("enterText"),error:i&&r[e]&&w("fieldRequired"),...n(e,{required:i})})})}],19858);var ms=f.useLayoutEffect,ml=function(e){var t=f.default.useRef(e);return ms(function(){t.current=e}),t},md=function(e,t){"function"==typeof e?e(t):e.current=t},mu=function(e,t){var n=f.default.useRef();return f.default.useCallback(function(i){e.current=i,n.current&&md(n.current,null),n.current=t,t&&md(t,i)},[t])},mc={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0",display:"block"},mh=function(e){Object.keys(mc).forEach(function(t){e.style.setProperty(t,mc[t],"important")})},mp=null,mf=function(e,t){var n=e.scrollHeight;return"border-box"===t.sizingStyle.boxSizing?n+t.borderSize:n-t.paddingSize},mg=function(){},mm=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width","wordBreak","wordSpacing","scrollbarGutter"],mv=!!document.documentElement.currentStyle,my=function(e){var t=window.getComputedStyle(e);if(null===t)return null;var n=mm.reduce(function(e,n){return e[n]=t[n],e},{}),i=n.boxSizing;if(""===i)return null;mv&&"border-box"===i&&(n.width=parseFloat(n.width)+parseFloat(n.borderRightWidth)+parseFloat(n.borderLeftWidth)+parseFloat(n.paddingRight)+parseFloat(n.paddingLeft)+"px");var r=parseFloat(n.paddingBottom)+parseFloat(n.paddingTop),o=parseFloat(n.borderBottomWidth)+parseFloat(n.borderTopWidth);return{sizingStyle:n,paddingSize:r,borderSize:o}};
355function mb(e,t,n){var i=ml(n);f.useLayoutEffect(function(){var n=function(e){return i.current(e)};if(e)return e.addEventListener(t,n),function(){return e.removeEventListener(t,n)}},[])}var mx=function(e,t){mb(document.body,"reset",function(n){e.current.form===n.target&&t(n)})},mw=function(e){mb(window,"resize",e)},mC=function(e){mb(document.fonts,"loadingdone",e)},mS=["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"],m_=f.forwardRef(function(e,t){var n=e.cacheMeasurements,i=e.maxRows,r=e.minRows,o=e.onChange,a=void 0===o?mg:o,s=e.onHeightChange,l=void 0===s?mg:s,d=function(e,t){if(null==e)return{};var n={};for(var i in e)if(({}).hasOwnProperty.call(e,i)){if(-1!==t.indexOf(i))continue;n[i]=e[i]}return n}(e,mS),u=void 0!==d.value,c=f.useRef(null),h=mu(c,t),p=f.useRef(0),g=f.useRef(),m=function(){var e=c.current,t=n&&g.current?g.current:my(e);if(t){g.current=t;var o,a,s,d,u,h,f,m,v,y,b,x=(o=e.value||e.placeholder||"x",void 0===(a=r)&&(a=1),void 0===(s=i)&&(s=1/0),mp||((mp=document.createElement("textarea")).setAttribute("tabindex","-1"),mp.setAttribute("aria-hidden","true"),mh(mp)),null===mp.parentNode&&document.body.appendChild(mp),d=t.paddingSize,u=t.borderSize,f=(h=t.sizingStyle).boxSizing,Object.keys(h).forEach(function(e){mp.style[e]=h[e]}),mh(mp),mp.value=o,m=mf(mp,t),mp.value=o,m=mf(mp,t),mp.value="x",y=(v=mp.scrollHeight-d)*a,"border-box"===f&&(y=y+d+u),m=Math.max(y,m),b=v*s,"border-box"===f&&(b=b+d+u),[m=Math.min(b,m),v]),w=x[0],C=x[1];p.current!==w&&(p.current=w,e.style.setProperty("height",w+"px","important"),l(w,{rowHeight:C}))}};return f.useLayoutEffect(m),mx(c,function(){if(!u){var e=c.current.value;requestAnimationFrame(function(){var t=c.current;t&&e!==t.value&&m()})}}),mw(m),mC(m),f.createElement("textarea",ma({},d,{onChange:function(e){u||m(),a(e)},ref:h}))});function mk(){return void 0!==tt.default&&tt.default.env&&1?"production":"development"}e.s(["getEnv",()=>mk],37012);let mM={size:"sm"},mT=(0,C.factory)((e,t)=>{let{autosize:n,maxRows:i,minRows:r,__staticSelector:o,resize:s,...l}=(0,b.useProps)("Textarea",mM,e),d=n&&"test"!==mk();return(0,a.jsx)(ep.InputBase,{component:d?m_:"textarea",ref:t,...l,__staticSelector:o||"Textarea",multiline:!0,"data-no-overflow":n&&void 0===i||void 0,__vars:{"--input-resize":s},...d?{maxRows:i,minRows:r}:{}})});mT.classes=ep.InputBase.classes,mT.displayName="@mantine/core/Textarea",e.s(["Textarea",0,({name:e,label:t,register:n,required:i,errors:r,width:o,readonly:s,textareaDefaultValue:u,setValue:g,getValues:m,placeholder:v,description:y,minRows:b=2,maxRows:x,tooltip:w})=>{let{tenant:C}=(0,l.useTenant)(),{t:S}=(0,p.useTranslations)();return f.default.useEffect(()=>{u&&!m(e)&&g(e,u)},[e,u,g,m]),(0,a.jsx)(c.Width,{width:o,children:(0,a.jsx)(mT,{readOnly:s,size:"md",radius:(0,d.getRadius)(C.Theme?.borderRadius),label:(0,a.jsxs)(a.Fragment,{children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:w})]}),placeholder:v||S("enterText"),description:y,withAsterisk:i,error:i&&r[e]&&S("fieldRequired"),...n(e,{required:i}),autosize:!0,minRows:b,maxRows:x})})}],46769);var mD=e.i(13872),mR=e.i(55807);function mI(e,t){return n=>{if("string"!=typeof n||0===n.trim().length)throw Error(t);return`${e}-${n}`}}e.s(["SelectNumber",0,({name:e,label:t,required:n,errors:i,width:r,control:o,presetValues:s,textDefaultValue:u,getValues:g,setValue:m,placeholder:v,color:y,tooltip:b})=>{let{tenant:x}=(0,l.useTenant)(),{t:w}=(0,p.useTranslations)();f.default.useEffect(()=>{u&&!g(e)&&m(e,u)},[e,u,m,g]);let C=(e,t)=>{let n="number"==typeof e?e:parseInt(e.replaceAll(/[^-\d]/g,""));t(Number.isNaN(n)?"":n.toString())};return(0,a.jsx)(c.Width,{width:r,children:(0,a.jsx)(E.Controller,{control:o,rules:{required:n},name:e,defaultValue:"",render:({field:{onChange:r,value:o}})=>(0,a.jsxs)("div",{className:mD.default.wrap,children:[(0,a.jsxs)("label",{htmlFor:e,className:mD.default.label,children:[t,(0,a.jsx)(h.FieldTooltip,{tooltip:b})]}),(0,a.jsxs)(gL.Paper,{radius:x?.Theme?.borderRadius||"md",className:mD.default.paper,children:[(0,a.jsx)("div",{className:mD.default.select,children:s.map(e=>(0,a.jsx)(mR.Button,{className:mD.default.select__buttons,label:e,appearance:"secondary",color:y,el:"button",isActive:o==e,onClick:()=>C(e,r)},e))}),(0,a.jsx)(eM,{value:o,onChange:e=>C(e,r),size:"md",radius:(0,d.getRadius)(x.Theme?.borderRadius),withAsterisk:n,placeholder:v||w("enterText"),error:n&&i[e]&&w("fieldRequired")})]})]})})})}],88431),e.s(["getSafeId",()=>mI],499);let[mA,mP]=(0,e8.createSafeContext)("Tabs component was not found in the tree");
355e.s(["TabsProvider",()=>mA,"useTabsContext",()=>mP],19361);var mE={root:"m_89d60db1","list--default":"m_576c9d4",list:"m_89d33d6d",tab:"m_4ec4dce6",panel:"m_b0c91715",tabSection:"m_fc420b1f",tabLabel:"m_42bbd1ae","tab--default":"m_539e827b","list--outline":"m_6772fbd5","tab--outline":"m_b59ab47c","tab--pills":"m_c3381914"};e.s(["default",()=>mE],56418);let mL=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("TabsList",null,e),{children:i,className:r,grow:o,justify:s,classNames:l,styles:d,style:u,mod:c,...h}=n,p=mP();return(0,a.jsx)(w.Box,{...h,...p.getStyles("list",{className:r,style:u,classNames:l,styles:d,props:n,variant:p.variant}),ref:t,role:"tablist",variant:p.variant,mod:[{grow:o,orientation:p.orientation,placement:"vertical"===p.orientation&&p.placement,inverted:p.inverted},c],"aria-orientation":p.orientation,__vars:{"--tabs-justify":s},children:i})});mL.classes=mE,mL.displayName="@mantine/core/TabsList",e.s(["TabsList",()=>mL],55191);let mF=(0,C.factory)((e,t)=>{let n=(0,b.useProps)("TabsPanel",null,e),{children:i,className:r,value:o,classNames:s,styles:l,style:d,mod:u,keepMounted:c,...h}=n,p=mP(),f=p.value===o,g=p.keepMounted||c||f?i:null;return(0,a.jsx)(w.Box,{...p.getStyles("panel",{className:r,classNames:s,styles:l,style:[d,f?void 0:{display:"none"}],props:n}),ref:t,mod:[{orientation:p.orientation},u],role:"tabpanel",id:p.getPanelId(o),"aria-labelledby":p.getTabId(o),...h,children:g})});mF.classes=mE,mF.displayName="@mantine/core/TabsPanel",e.s(["TabsPanel",()=>mF],61901)},57671,(e,t,n)=>{"use strict";t.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},91163,(e,t,n)=>{"use strict";var i=e.r(57671);function r(){}function o(){}o.resetWarningCache=r,t.exports=function(){function e(e,t,n,r,o,a){if(a!==i){var s=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:r};return n.PropTypes=n,n}},88575,(e,t,n)=>{t.exports=e.r(91163)()},20728,(e,t,n)=>{"use strict";n.__esModule=!0,n.default=function(e,t){if(e&&t){var n=Array.isArray(t)?t:t.split(",");if(0===n.length)return!0;var i=e.name||"",r=(e.type||"").toLowerCase(),o=r.replace(/\/.*$/,"");return n.some(function(e){var t=e.trim().toLowerCase();return"."===t.charAt(0)?i.toLowerCase().endsWith(t):t.endsWith("/*")?o===t.replace(/\/.*$/,""):r===t})}return!0}},99019,e=>{e.v({dropzone:"index-module-scss-module__ggdBCq__dropzone",error:"index-module-scss-module__ggdBCq__error",fileIcon:"index-module-scss-module__ggdBCq__fileIcon",filePreview:"index-module-scss-module__ggdBCq__filePreview",icon:"index-module-scss-module__ggdBCq__icon",iconAccept:"index-module-scss-module__ggdBCq__iconAccept",iconReject:"index-module-scss-module__ggdBCq__iconReject",previewImage:"index-module-scss-module__ggdBCq__previewImage",removeButton:"index-module-scss-module__ggdBCq__removeButton",removeIcon:"index-module-scss-module__ggdBCq__removeIcon",uploadField:"index-module-scss-module__ggdBCq__uploadField"})},91736,e=>{e.v({"block-wrapper":"index-module-scss-module__LOdMlW__block-wrapper",grid:"index-module-scss-module__LOdMlW__grid","grid--glued":"index-module-scss-module__LOdMlW__grid--glued","grid--glued--lg":"index-module-scss-module__LOdMlW__grid--glued--lg","grid--glued--md":"index-module-scss-module__LOdMlW__grid--glued--md","grid--glued--none":"index-module-scss-module__LOdMlW__grid--glued--none","grid--glued--sm":"index-module-scss-module__LOdMlW__grid--glued--sm","grid--glued--xl":"index-module-scss-module__LOdMlW__grid--glued--xl",gridContainer:"index-module-scss-module__LOdMlW__gridContainer",item:"index-module-scss-module__LOdMlW__item","item--align":"index-module-scss-module__LOdMlW__item--align"})},57012,e=>{e.v({"image-text-block":"index-module-scss-module__LIvj9a__image-text-block","image-text-block__content":"index-module-scss-module__LIvj9a__image-text-block__content","image-text-block__img":"index-module-scss-module__LIvj9a__image-text-block__img","image-text-block__img-wrapper":"index-module-scss-module__LIvj9a__image-text-block__img-wrapper","image-text-block__text":"index-module-scss-module__LIvj9a__image-text-block__text"})},67484,e=>{e.v({inGrid:"index-module-scss-module__8sVH5a__inGrid",linkWrapper:"index-module-scss-module__8sVH5a__linkWrapper","linkWrapper--black":"index-module-scss-module__8sVH5a__linkWrapper--black","linkWrapper--primary":"index-module-scss-module__8sVH5a__linkWrapper--primary","linkWrapper--quaternary":"index-module-scss-module__8sVH5a__linkWrapper--quaternary","linkWrapper--quinary":"index-module-scss-module__8sVH5a__linkWrapper--quinary","linkWrapper--secondary":"index-module-scss-module__8sVH5a__linkWrapper--secondary","linkWrapper--senary":"index-module-scss-module__8sVH5a__linkWrapper--senary","linkWrapper--tertiary":"index-module-scss-module__8sVH5a__linkWrapper--tertiary","linkWrapper--white":"index-module-scss-module__8sVH5a__linkWrapper--white",linksBlock:"index-module-scss-module__8sVH5a__linksBlock","linksBlock--black":"index-module-scss-module__8sVH5a__linksBlock--black","linksBlock--center":"index-module-scss-module__8sVH5a__linksBlock--center","linksBlock--left":"index-module-scss-module__8sVH5a__linksBlock--left","linksBlock--primary":"index-module-scss-module__8sVH5a__linksBlock--primary","linksBlock--quaternary":"index-module-scss-module__8sVH5a__linksBlock--quaternary","linksBlock--quinary":"index-module-scss-module__8sVH5a__linksBlock--quinary","linksBlock--right":"index-module-scss-module__8sVH5a__linksBlock--right","linksBlock--secondary":"index-module-scss-module__8sVH5a__linksBlock--secondary","linksBlock--senary":"index-module-scss-module__8sVH5a__linksBlock--senary","linksBlock--tertiary":"index-module-scss-module__8sVH5a__linksBlock--tertiary","linksBlock--white":"index-module-scss-module__8sVH5a__linksBlock--white"})},44700,(e,t,n)=>{"use strict";
355t.exports=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;if(Array.isArray(t)){if((i=t.length)!=n.length)return!1;for(r=i;0!=r--;)if(!e(t[r],n[r]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((i=(o=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(r=i;0!=r--;)if(!Object.prototype.hasOwnProperty.call(n,o[r]))return!1;for(r=i;0!=r--;){var i,r,o,a=o[r];if(!e(t[a],n[a]))return!1}return!0}return t!=t&&n!=n}},45703,e=>{e.v({"cluster-marker":"index-module-scss-module__37_buq__cluster-marker","cluster-marker--blue":"index-module-scss-module__37_buq__cluster-marker--blue","cluster-marker--cyan":"index-module-scss-module__37_buq__cluster-marker--cyan","cluster-marker--darkgreen":"index-module-scss-module__37_buq__cluster-marker--darkgreen","cluster-marker--green":"index-module-scss-module__37_buq__cluster-marker--green","cluster-marker--magenta":"index-module-scss-module__37_buq__cluster-marker--magenta","cluster-marker--orange":"index-module-scss-module__37_buq__cluster-marker--orange","cluster-marker--pink":"index-module-scss-module__37_buq__cluster-marker--pink","cluster-marker--purple":"index-module-scss-module__37_buq__cluster-marker--purple","cluster-marker--red":"index-module-scss-module__37_buq__cluster-marker--red","cluster-marker--yellow":"index-module-scss-module__37_buq__cluster-marker--yellow","dot-marker":"index-module-scss-module__37_buq__dot-marker","dot-marker--blue":"index-module-scss-module__37_buq__dot-marker--blue","dot-marker--cyan":"index-module-scss-module__37_buq__dot-marker--cyan","dot-marker--darkgreen":"index-module-scss-module__37_buq__dot-marker--darkgreen","dot-marker--green":"index-module-scss-module__37_buq__dot-marker--green","dot-marker--magenta":"index-module-scss-module__37_buq__dot-marker--magenta","dot-marker--orange":"index-module-scss-module__37_buq__dot-marker--orange","dot-marker--pink":"index-module-scss-module__37_buq__dot-marker--pink","dot-marker--purple":"index-module-scss-module__37_buq__dot-marker--purple","dot-marker--red":"index-module-scss-module__37_buq__dot-marker--red","dot-marker--yellow":"index-module-scss-module__37_buq__dot-marker--yellow","infowindow-content":"index-module-scss-module__37_buq__infowindow-content","infowindow-header":"index-module-scss-module__37_buq__infowindow-header","infowindow-icon--blue":"index-module-scss-module__37_buq__infowindow-icon--blue","infowindow-icon--cyan":"index-module-scss-module__37_buq__infowindow-icon--cyan","infowindow-icon--darkgreen":"index-module-scss-module__37_buq__infowindow-icon--darkgreen","infowindow-icon--green":"index-module-scss-module__37_buq__infowindow-icon--green","infowindow-icon--magenta":"index-module-scss-module__37_buq__infowindow-icon--magenta","infowindow-icon--orange":"index-module-scss-module__37_buq__infowindow-icon--orange","infowindow-icon--pink":"index-module-scss-module__37_buq__infowindow-icon--pink","infowindow-icon--purple":"index-module-scss-module__37_buq__infowindow-icon--purple","infowindow-icon--red":"index-module-scss-module__37_buq__infowindow-icon--red","infowindow-icon--yellow":"index-module-scss-module__37_buq__infowindow-icon--yellow",map:"index-module-scss-module__37_buq__map","map-container":"index-module-scss-module__37_buq__map-container","map-control-icon":"index-module-scss-module__37_buq__map-control-icon","map-control-icon--active":"index-module-scss-module__37_buq__map-control-icon--active","map-controls":"index-module-scss-module__37_buq__map-controls","map-filter":"index-module-scss-module__37_buq__map-filter","map-legend":"index-module-scss-module__37_buq__map-legend","map-legend__header":"index-module-scss-module__37_buq__map-legend__header","map-legend__item":"index-module-scss-module__37_buq__map-legend__item","map-legend__item--blue":"index-module-scss-module__37_buq__map-legend__item--blue","map-legend__item--cyan":"index-module-scss-module__37_buq__map-legend__item--cyan","map-legend__item--darkgreen":"index-module-scss-module__37_buq__map-legend__item--darkgreen","map-legend__item--green":"index-module-scss-module__37_buq__map-legend__item--green","map-legend__item--magenta":"index-module-scss-module__37_buq__map-legend__item--magenta","map-legend__item--orange":"index-module-scss-module__37_buq__map-legend__item--orange","map-legend__item--pink":"index-module-scss-module__37_buq__map-legend__item--pink","map-legend__item--purple":"index-module-scss-module__37_buq__map-legend__item--purple","map-legend__item--red":"index-module-scss-module__37_buq__map-legend__item--red","map-legend__item--yellow":"index-module-scss-module__37_buq__map-legend__item--yellow","map-legend__list":"index-module-scss-module__37_buq__map-legend__list","map-search":"index-module-scss-module__37_buq__map-search","map-wrapper":"index-module-scss-module__37_buq__map-wrapper","marker-description":"index-module-scss-module__37_buq__marker-description","marker-group":"index-module-scss-module__37_buq__marker-group","marker-labels":"index-module-scss-module__37_buq__marker-labels","marker-name":"index-module-scss-module__37_buq__marker-name"})},34872,e=>{e.v({"dot-marker":"MapMarker-module-scss-module__jEWvOq__dot-marker","dot-marker--blue":"MapMarker-module-scss-module__jEWvOq__dot-marker--blue","dot-marker--cyan":"MapMarker-module-scss-module__jEWvOq__dot-marker--cyan","dot-marker--darkgreen":"MapMarker-module-scss-module__jEWvOq__dot-marker--darkgreen","dot-marker--green":"MapMarker-module-scss-module__jEWvOq__dot-marker--green","dot-marker--magenta":"MapMarker-module-scss-module__jEWvOq__dot-marker--magenta","dot-marker--orange":"MapMarker-module-scss-module__jEWvOq__dot-marker--orange","dot-marker--pink":"MapMarker-module-scss-module__jEWvOq__dot-marker--pink","dot-marker--purple":"MapMarker-module-scss-module__jEWvOq__dot-marker--purple","dot-marker--red":"MapMarker-module-scss-module__jEWvOq__dot-marker--red","dot-marker--yellow":"Map
355Marker-module-scss-module__jEWvOq__dot-marker--yellow","infowindow-header":"MapMarker-module-scss-module__jEWvOq__infowindow-header","infowindow-icon--blue":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--blue","infowindow-icon--cyan":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--cyan","infowindow-icon--darkgreen":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--darkgreen","infowindow-icon--green":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--green","infowindow-icon--magenta":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--magenta","infowindow-icon--orange":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--orange","infowindow-icon--pink":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--pink","infowindow-icon--purple":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--purple","infowindow-icon--red":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--red","infowindow-icon--yellow":"MapMarker-module-scss-module__jEWvOq__infowindow-icon--yellow","marker-description":"MapMarker-module-scss-module__jEWvOq__marker-description","marker-group":"MapMarker-module-scss-module__jEWvOq__marker-group","marker-labels":"MapMarker-module-scss-module__jEWvOq__marker-labels","marker-name":"MapMarker-module-scss-module__jEWvOq__marker-name"})},30156,e=>{e.v({container:"index-module-scss-module__UsCa4W__container",introContent:"index-module-scss-module__UsCa4W__introContent",table:"index-module-scss-module__UsCa4W__table"})},21636,e=>{e.v({caption:"index-module-scss-module__n7zL0G__caption",closeButton:"index-module-scss-module__n7zL0G__closeButton",default:"index-module-scss-module__n7zL0G__default",iframe:"index-module-scss-module__n7zL0G__iframe",left:"index-module-scss-module__n7zL0G__left",overflowing:"index-module-scss-module__n7zL0G__overflowing",placeholderBlank:"index-module-scss-module__n7zL0G__placeholderBlank",placeholderWrapper:"index-module-scss-module__n7zL0G__placeholderWrapper",playButton:"index-module-scss-module__n7zL0G__playButton",richTextWrapper:"index-module-scss-module__n7zL0G__richTextWrapper",right:"index-module-scss-module__n7zL0G__right",videoBlock:"index-module-scss-module__n7zL0G__videoBlock"})},52999,99564,4352,94576,4698,34852,25363,23039,25499,e=>{"use strict";let t,n,i,r,o,a,s;e.i(39057);var l,d,u,c,h,p,f,g,m,v,y,b,x,w,C,S,_,k,M,T,D,R=e.i(48277),I=e.i(30668),A=e.i(63584),P=e.i(94118),E=e.i(55807);e.s(["formFields",()=>t7],99564);var L=e.i(56370),F=e.i(28935),O=e.i(44412),N=e.i(11427),B=e.i(98551),z=e.i(20633),j=e.i(54407),V=e.i(2551),H=e.i(98604),G=e.i(8812),W=e.i(2390),$=e.i(19858),U=e.i(46769),q=e.i(88431),K=e.i(28259),Y=e.i(57472),Z=e.i(99850),X=e.i(499),J=e.i(90112),Q=e.i(73596),ee=e.i(99325),et=e.i(12112),en=e.i(1483),ei=e.i(59678),er=e.i(1584),eo=e.i(24133),ea=e.i(56297),es=e.i(77219),el=e.i(19361),ed=e.i(56418),eu=e.i(55191),ec=e.i(61901),eh=e.i(57922),ep=e.i(11920),ef=e.i(58960),eg=e.i(20425);let em=(0,es.factory)((e,t)=>{let n=(0,er.useProps)("TabsTab",null,e),{className:i,children:r,rightSection:o,leftSection:a,value:s,onClick:l,onKeyDown:d,disabled:u,color:c,style:h,classNames:p,styles:f,vars:g,mod:m,tabIndex:v,...y}=n,b=(0,ep.useMantineTheme)(),{dir:x}=(0,ef.useDirection)(),w=(0,el.useTabsContext)(),C=s===w.value,S={classNames:p,styles:f,props:n};return(0,R.jsxs)(eg.UnstyledButton,{...w.getStyles("tab",{className:i,style:h,variant:w.variant,...S}),disabled:u,unstyled:w.unstyled,variant:w.variant,mod:[{active:C,disabled:u,orientation:w.orientation,inverted:w.inverted,placement:"vertical"===w.orientation&&w.placement},m],ref:t,role:"tab",id:w.getTabId(s),"aria-selected":C,tabIndex:void 0!==v?v:C||null===w.value?0:-1,"aria-controls":w.getPanelId(s),onClick:e=>{w.onChange(w.allowTabDeactivation&&s===w.value?null:s),l?.(e)},__vars:{"--tabs-color":c?(0,et.getThemeColor)(c,b):void 0},onKeyDown:(0,eh.createScopedKeydownHandler)({siblingSelector:'[role="tab"]',parentSelector:'[role="tablist"]',activateOnFocus:w.activateTabWithKeyboard,loop:w.loop,orientation:w.orientation||"horizontal",dir:x,onKeyDown:d}),...y,children:[a&&(0,R.jsx)("span",{...w.getStyles("tabSection",S),"data-position":"left",children:a}),r&&(0,R.jsx)("span",{...w.getStyles("tabLabel",S),children:r}),o&&(0,R.jsx)("span",{...w.getStyles("tabSection",S),"data-position":"right",children:o})]})});em.classes=ed.default,em.displayName="@mantine/core/TabsTab";let ev="Tabs.Tab or Tabs.Panel component was rendered with invali
355d value or without value",ey={keepMounted:!0,orientation:"horizontal",loop:!0,activateTabWithKeyboard:!0,variant:"default",placement:"left"},eb=(0,Q.createVarsResolver)((e,{radius:t,color:n,autoContrast:i})=>({root:{"--tabs-radius":(0,J.getRadius)(t),"--tabs-color":(0,et.getThemeColor)(n,e),"--tabs-text-color":(0,ei.getAutoContrastValue)(i,e)?(0,en.getContrastColor)({color:n,theme:e,autoContrast:i}):void 0}})),ex=(0,es.factory)((e,t)=>{let n=(0,er.useProps)("Tabs",ey,e),{defaultValue:i,value:r,onChange:o,orientation:a,children:s,loop:l,id:d,activateTabWithKeyboard:u,allowTabDeactivation:c,variant:h,color:p,radius:f,inverted:g,placement:m,keepMounted:v,classNames:y,styles:b,unstyled:x,className:w,style:C,vars:S,autoContrast:_,mod:k,attributes:M,...T}=n,D=(0,Y.useId)(d),[I,A]=(0,Z.useUncontrolled)({value:r,defaultValue:i,finalValue:null,onChange:o}),P=(0,eo.useStyles)({name:"Tabs",props:n,classes:ed.default,className:w,style:C,classNames:y,styles:b,unstyled:x,attributes:M,vars:S,varsResolver:eb});return(0,R.jsx)(el.TabsProvider,{value:{placement:m,value:I,orientation:a,id:D,loop:l,activateTabWithKeyboard:u,getTabId:(0,X.getSafeId)(`${D}-tab`,ev),getPanelId:(0,X.getSafeId)(`${D}-panel`,ev),onChange:A,allowTabDeactivation:c,variant:h,color:p,radius:f,inverted:g,keepMounted:v,unstyled:x,getStyles:P},children:(0,R.jsx)(ea.Box,{ref:t,id:D,variant:h,mod:[{orientation:a,inverted:"horizontal"===a&&g,placement:"vertical"===a&&m},k],...P("root"),...T,children:s})})});ex.classes=ed.default,ex.displayName="@mantine/core/Tabs",ex.Tab=em,ex.Panel=ec.TabsPanel,ex.List=eu.TabsList;var ew=e.i(40775),eC=e.i(84584),eS=e.i(79908),e_=e.i(90388),ek=e.i(46471),eM=e.i(75857),eT=e.i(17236),eD=e.i(90905),eR={root:"m_9e117634"};let eI=(0,Q.createVarsResolver)((e,{radius:t,fit:n})=>({root:{"--image-radius":void 0===t?void 0:(0,J.getRadius)(t),"--image-object-fit":n}})),eA=(0,eD.polymorphicFactory)((e,t)=>{let n=(0,er.useProps)("Image",null,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,onError:d,src:u,radius:c,fit:h,fallbackSrc:p,mod:f,attributes:g,...m}=n,[v,y]=(0,I.useState)(!u);(0,I.useEffect)(()=>y(!u),[u]);let b=(0,eo.useStyles)({name:"Image",classes:eR,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:g,vars:l,varsResolver:eI});return v&&p?(0,R.jsx)(ea.Box,{component:"img",ref:t,src:p,...b("root"),onError:d,mod:["fallback",f],...m}):(0,R.jsx)(ea.Box,{component:"img",ref:t,...b("root"),src:u,onError:e=>{d?.(e),y(!0)},mod:f,...m})});eA.classes=eR,eA.displayName="@mantine/core/Image";var eP=e.i(44804),eE=e.i(3218),eL=e.i(88575);function eF(e,t,n,i){return new(n||(n=Promise))(function(r,o){function a(e){try{l(i.next(e))}catch(e){o(e)}}function s(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?r(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(a,s)}l((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;let eO
vendor: 41,168 bytes, line 355
355=new Map([["1km","application/vnd.1000minds.decision-model+xml"],["3dml","text/vnd.in3d.3dml"],["3ds","image/x-3ds"],["3g2","video/3gpp2"],["3gp","video/3gp"],["3gpp","video/3gpp"],["3mf","model/3mf"],["7z","application/x-7z-compressed"],["7zip","application/x-7z-compressed"],["123","application/vnd.lotus-1-2-3"],["aab","application/x-authorware-bin"],["aac","audio/x-acc"],["aam","application/x-authorware-map"],["aas","application/x-authorware-seg"],["abw","application/x-abiword"],["ac","application/vnd.nokia.n-gage.ac+xml"],["ac3","audio/ac3"],["acc","application/vnd.americandynamics.acc"],["ace","application/x-ace-compressed"],["acu","application/vnd.acucobol"],["acutc","application/vnd.acucorp"],["adp","audio/adpcm"],["aep","application/vnd.audiograph"],["afm","application/x-font-type1"],["afp","application/vnd.ibm.modcap"],["ahead","application/vnd.ahead.space"],["ai","application/pdf"],["aif","audio/x-aiff"],["aifc","audio/x-aiff"],["aiff","audio/x-aiff"],["air","application/vnd.adobe.air-application-installer-package+zip"],["ait","application/vnd.dvb.ait"],["ami","application/vnd.amiga.ami"],["amr","audio/amr"],["apk","application/vnd.android.package-archive"],["apng","image/apng"],["appcache","text/cache-manifest"],["application","application/x-ms-application"],["apr","application/vnd.lotus-approach"],["arc","application/x-freearc"],["arj","application/x-arj"],["asc","application/pgp-signature"],["asf","video/x-ms-asf"],["asm","text/x-asm"],["aso","application/vnd.accpac.simply.aso"],["asx","video/x-ms-asf"],["atc","application/vnd.acucorp"],["atom","application/atom+xml"],["atomcat","application/atomcat+xml"],["atomdeleted","application/atomdeleted+xml"],["atomsvc","application/atomsvc+xml"],["atx","application/vnd.antix.game-component"],["au","audio/x-au"],["avi","video/x-msvideo"],["avif","image/avif"],["aw","application/applixware"],["azf","application/vnd.airzip.filesecure.azf"],["azs","application/vnd.airzip.filesecure.azs"],["azv","image/vnd.airzip.accelerator.azv"],["azw","application/vnd.amazon.ebook"],["b16","image/vnd.pco.b16"],["bat","application/x-msdownload"],["bcpio","application/x-bcpio"],["bdf","application/x-font-bdf"],["bdm","application/vnd.syncml.dm+wbxml"],["bdoc","application/x-bdoc"],["bed","application/vnd.realvnc.bed"],["bh2","application/vnd.fujitsu.oasysprs"],["bin","application/octet-stream"],["blb","application/x-blorb"],["blorb","application/x-blorb"],["bmi","application/vnd.bmi"],["bmml","application/vnd.balsamiq.bmml+xml"],["bmp","image/bmp"],["book","application/vnd.framemaker"],["box","application/vnd.previewsystems.box"],["boz","application/x-bzip2"],["bpk","application/octet-stream"],["bpmn","application/octet-stream"],["bsp","model/vnd.valve.source.compiled-map"],["btif","image/prs.btif"],["buffer","application/octet-stream"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["c","text/x-c"],["c4d","application/vnd.clonk.c4group"],["c4f","application/vnd.clonk.c4group"],["c4g","application/vnd.clonk.c4group"],["c4p","application/vnd.clonk.c4group"],["c4u","application/vnd.clonk.c4group"],["c11amc","application/vnd.cluetrust.cartomobile-config"],["c11amz","application/vnd.cluetrust.cartomobile-config-pkg"],["cab","application/vnd.ms-cab-compressed"],["caf","audio/x-caf"],["cap","application/vnd.tcpdump.pcap"],["car","application/vnd.curl.car"],["cat","application/vnd.ms-pki.seccat"],["cb7","application/x-cbr"],["cba","application/x-cbr"],["cbr","application/x-cbr"],["cbt","application/x-cbr"],["cbz","application/x-cbr"],["cc","text/x-c"],["cco","application/x-cocoa"],["cct","application/x-director"],["ccxml","application/ccxml+xml"],["cdbcmsg","application/vnd.contact.cmsg"],["cda","application/x-cdf"],["cdf","application/x-netcdf"],["cdfx","application/cdfx+xml"],["cdkey","application/vnd.mediastation.cdkey"],["cdmia","application/cdmi-capability"],["cdmic","application/cdmi-container"],["cdmid","application/cdmi-domain"],["cdmio","application/cdmi-object"],["cdmiq","application/cdmi-queue"],["cdr","application/cdr"],["cdx","chemical/x-cdx"],["cdxml","application/vnd.chemdraw+xml"],["cdy","application/vnd.cinderella"],["cer","application/pkix-cert"],["cfs","application/x-cfs-compressed"],["cgm","image/cgm"],["chat","application/x-chat"],["chm","application/vnd.ms-htmlhelp"],["chrt","application/vnd.kde.kchart"],["cif","chemical/x-cif"],["cii","application/vnd.anser-web-certificate-issue-initiation"],["cil","application/vnd.ms-artgalry"],["cjs","application/node"],["cla","application/vnd.claymore"],["class","application/octet-stream"],["clkk","application/vnd.crick.clicker.keyboard"],["clkp","application/vnd.crick.clicker.palette"],["clkt","application/vnd.crick.clicker.template"],["clkw","application/vnd.crick.clicker.wordbank"],["clkx","application/vnd.crick.clicker"],["clp","application/x-msclip"],["cmc","application/vnd.cosmocaller"],["cmdf","chemical/x-cmdf"],["cml","chemical/x-cml"],["cmp","application/vnd.yellowriver-custom-menu"],["cmx","image/x-cmx"],["cod","application/vnd.rim.cod"],["coffee","text/coffeescript"],["com","application/x-msdownload"],["conf","text/plain"],["cpio","application/x-cpio"],["cpp","text/x-c"],["cpt","application/mac-compactpro"],["crd","application/x-mscardfile"],["crl","application/pkix-crl"],["crt","application/x-x509-ca-cert"],["crx","application/x-chrome-extension"],["cryptonote","application/vnd.rig.cryptonote"],["csh","application/x-csh"],["csl","application/vnd.citationstyles.style+xml"],["csml","chemical/x-csml"],["csp","application/vnd.commonspace"],["csr","application/octet-stream"],["css","text/css"],["cst","application/x-director"],["csv","text/csv"],["cu","application/cu-seeme"],["curl","text/vnd.curl"],["cww","application/prs.cww"],["cxt","application/x-director"],["cxx","text/x-c"],["dae","model/vnd.collada+xml"],["daf","application/vnd.mobius.daf"],["dart","application/vnd.dart"],["dataless","application/vnd.fdsn.seed"],["davmount","application/davmount+xml"],["dbf","application/vnd.dbf"],["dbk","application/docbook+xml"],["dcr","application/x-director"],["dcurl","text/vnd.curl.dcurl"],["dd2","application/vnd.oma.dd2+xml"],["ddd","application/vnd.fujixerox.ddd"],["ddf","application/vnd.syncml.dmddf+xml"],["dds","image/vnd.ms-dds"],["deb","application/x-debian-package"],["def","text/plain"],["deploy","application/octet-stream"],["der","application/x-x509-ca-cert"],["dfac","application/vnd.dreamfactory"],["dgc","application/x-dgc-compressed"],["dic","text/x-c"],["dir","application/x-director"],["dis","application/vnd.mobius.dis"],["disposition-notification","message/disposition-notification"],["dist","application/octet-stream"],["distz","application/octet-stream"],["djv","image/vnd.djvu"],["djvu","image/vnd.djvu"],["dll","application/octet-stream"],["dmg","application/x-apple-diskimage"],["dmn","application/octet-stream"],["dmp","application/vnd.tcpdump.pcap"],["dms","application/octet-stream"],["dna","application/vnd.dna"],["doc","application/msword"],["docm","application/vnd.ms-word.template.macroEnabled.12"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["dot","application/msword"],["dotm","application/vnd.ms-word.template.macroEnabled.12"],["dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],["dp","application/vnd.osgi.dp"],["dpg","application/vnd.dpgraph"],["dra","audio/vnd.dra"],["drle","image/dicom-rle"],["dsc","text/prs.lines.tag"],["dssc","application/dssc+der"],["dtb","application/x-dtbook+xml"],["dtd","application/xml-dtd"],["dts","audio/vnd.dts"],["dtshd","audio/vnd.dts.hd"],["dump","application/octet-stream"],["dvb","video/vnd.dvb.file"],["dvi","application/x-dvi"],["dwd","application/atsc-dwd+xml"],["dwf","model/vnd.dwf"],["dwg","image/vnd.dwg"],["dxf","image/vnd.dxf"],["dxp","application/vnd.spotfire.dxp"],["dxr","application/x-director"],["ear","application/java-archive"],["ecelp4800","audio/vnd.nuera.ecelp4800"],["ecelp7470","audio/vnd.nuera.ecelp7470"],["ecelp9600","audio/vnd.nuera.ecelp9600"],["ecma","application/ecmascript"],["edm","application/vnd.novadigm.edm"],["edx","application/vnd.novadigm.edx"],["efif","application/vnd.picsel"],["ei6","application/vnd.pg.osasli"],["elc","application/octet-stream"],["emf","image/emf"],["eml","message/rfc822"],["emma","application/emma+xml"],["emotionml","application/emotionml+xml"],["emz","application/x-msmetafile"],["eol","audio/vnd.digital-winds"],["eot","application/vnd.ms-fontobject"],["eps","application/postscript"],["epub","application/epub+zip"],["es","application/ecmascript"],["es3","application/vnd.eszigno3+xml"],["esa","application/vnd.osgi.subsystem"],["esf","application/vnd.epson.esf"],["et3","application/vnd.eszigno3+xml"],["etx","text/x-setext"],["eva","application/x-eva"],["evy","application/x-envoy"],["exe","application/octet-stream"],["exi","application/exi"],["exp","application/express"],["exr","image/aces"],["ext","application/vnd.novadigm.ext"],["ez","application/andrew-inset"],["ez2","application/vnd.ezpix-album"],["ez3","application/vnd.ezpix-package"],["f","text/x-fortran"],["f4v","video/mp4"],["f77","text/x-fortran"],["f90","text/x-fortran"],["fbs","image/vnd.fastbidsheet"],["fcdt","application/vnd.adobe.formscentral.fcdt"],["fcs","application/vnd.isac.fcs"],["fdf","application/vnd.fdf"],["fdt","application/fdt+xml"],["fe_launch","application/vnd.denovo.fcselayout-link"],["fg5","application/vnd.fujitsu.oasysgp"],["fgd","application/x-director"],["fh","image/x-freehand"],["fh4","image/x-freehand"],["fh5","image/x-freehand"],["fh7","image/x-freehand"],["fhc","image/x-freehand"],["fig","application/x-xfig"],["fits","image/fits"],["flac","audio/x-flac"],["fli","video/x-fli"],["flo","application/vnd.micrografx.flo"],["flv","video/x-flv"],["flw","application/vnd.kde.kivio"],["flx","text/vnd.fmi.flexstor"],["fly","text/vnd.fly"],["fm","application/vnd.framemaker"],["fnc","application/vnd.frogans.fnc"],["fo","application/vnd.software602.filler.form+xml"],["for","text/x-fortran"],["fpx","image/vnd.fpx"],["frame","application/vnd.framemaker"],["fsc","application/vnd.fsc.weblaunch"],["fst","image/vnd.fst"],["ftc","application/vnd.fluxtime.clip"],["fti","application/vnd.anser-web-funds-transfer-initiation"],["fvt","video/vnd.fvt"],["fxp","application/vnd.adobe.fxp"],["fxpl","application/vnd.adobe.fxp"],["fzs","application/vnd.fuzzysheet"],["g2w","application/vnd.geoplan"],["g3","image/g3fax"],["g3w","application/vnd.geospace"],["gac","application/vnd.groove-account"],["gam","application/x-tads"],["gbr","application/rpki-ghostbusters"],["gca","application/x-gca-compressed"],["gdl","model/vnd.gdl"],["gdoc","application/vnd.google-apps.document"],["geo","application/vnd.dynageo"],["geojson","application/geo+json"],["gex","application/vnd.geometry-explorer"],["ggb","application/vnd.geogebra.file"],["ggt","application/vnd.geogebra.tool"],["ghf","application/vnd.groove-help"],["gif","image/gif"],["gim","application/vnd.groove-identity-message"],["glb","model/gltf-binary"],["gltf","model/gltf+json"],["gml","application/gml+xml"],["gmx","application/vnd.gmx"],["gnumeric","application/x-gnumeric"],["gpg","application/gpg-keys"],["gph","application/vnd.flographit"],["gpx","application/gpx+xml"],["gqf","application/vnd.grafeq"],["gqs","application/vnd.grafeq"],["gram","application/srgs"],["gramps","application/x-gramps-xml"],["gre","application/vnd.geometry-explorer"],["grv","application/vnd.groove-injector"],["grxml","application/srgs+xml"],["gsf","application/x-font-ghostscript"],["gsheet","application/vnd.google-apps.spreadsheet"],["gslides","application/vnd.google-apps.presentation"],["gtar","application/x-gtar"],["gtm","application/vnd.groove-tool-message"],["gtw","model/vnd.gtw"],["gv","text/vnd.graphviz"],["gxf","application/gxf"],["gxt","application/vnd.geonext"],["gz","application/gzip"],["gzip","application/gzip"],["h","text/x-c"],["h261","video/h261"],["h263","video/h263"],["h264","video/h264"],["hal","application/vnd.hal+xml"],["hbci","application/vnd.hbci"],["hbs","text/x-handlebars-template"],["hdd","application/x-virtualbox-hdd"],["hdf","application/x-hdf"],["heic","image/heic"],["heics","image/heic-sequence"],["heif","image/heif"],["heifs","image/heif-sequence"],["hej2","image/hej2k"],["held","application/atsc-held+xml"],["hh","text/x-c"],["hjson","application/hjson"],["hlp","application/winhlp"],["hpgl","application/vnd.hp-hpgl"],["hpid","application/vnd.hp-hpid"],["hps","application/vnd.hp-hps"],["hqx","application/mac-binhex40"],["hsj2","image/hsj2"],["htc","text/x-component"],["htke","application/vnd.kenameaapp"],["htm","text/html"],["html","text/html"],["hvd","application/vnd.yamaha.hv-dic"],["hvp","application/vnd.yamaha.hv-voice"],["hvs","application/vnd.yamaha.hv-script"],["i2g","application/vnd.intergeo"],["icc","application/vnd.iccprofile"],["ice","x-conference/x-cooltalk"],["icm","application/vnd.iccprofile"],["ico","image/x-icon"],["ics","text/calendar"],["ief","image/ief"],["ifb","text/calendar"],["ifm","application/vnd.shana.informed.formdata"],["iges","model/iges"],["igl","application/vnd.igloader"],["igm","application/vnd.insors.igm"],["igs","model/iges"],["igx","application/vnd.micrografx.igx"],["iif","application/vnd.shana.informed.interchange"],["img","application/octet-stream"],["imp","application/vnd.accpac.simply.imp"],["ims","application/vnd.ms-ims"],["in","text/plain"],["ini","text/plain"],["ink","application/inkml+xml"],["inkml","application/inkml+xml"],["install","application/x-install-instructions"],["iota","application/vnd.astraea-software.iota"],["ipfix","application/ipfix"],["ipk","application/vnd.shana.informed.package"],["irm","application/vnd.ibm.rights-management"],["irp","application/vnd.irepository.package+xml"],["iso","application/x-iso9660-image"],["itp","application/vnd.shana.informed.formtemplate"],["its","application/its+xml"],["ivp","application/vnd.immervision-ivp"],["ivu","application/vnd.immervision-ivu"],["jad","text/vnd.sun.j2me.app-descriptor"],["jade","text/jade"],["jam","application/vnd.jam"],["jar","application/java-archive"],["jardiff","application/x-java-archive-diff"],["java","text/x-java-source"],["jhc","image/jphc"],["jisp","application/vnd.jisp"],["jls","image/jls"],["jlt","application/vnd.hp-jlyt"],["jng","image/x-jng"],["jnlp","application/x-java-jnlp-file"],["joda","application/vnd.joost.joda-archive"],["jp2","image/jp2"],["jpe","image/jpeg"],["jpeg","image/jpeg"],["jpf","image/jpx"],["jpg","image/jpeg"],["jpg2","image/jp2"],["jpgm","video/jpm"],["jpgv","video/jpeg"],["jph","image/jph"],["jpm","video/jpm"],["jpx","image/jpx"],["js","application/javascript"],["json","application/json"],["json5","application/json5"],["jsonld","application/ld+json"],["jsonl","application/jsonl"],["jsonml","application/jsonml+json"],["jsx","text/jsx"],["jxr","image/jxr"],["jxra","image/jxra"],["jxrs","image/jxrs"],["jxs","image/jxs"],["jxsc","image/jxsc"],["jxsi","image/jxsi"],["jxss","image/jxss"],["kar","audio/midi"],["karbon","application/vnd.kde.karbon"],["kdb","application/octet-stream"],["kdbx","application/x-keepass2"],["key","application/x-iwork-keynote-sffkey"],["kfo","application/vnd.kde.kformula"],["kia","application/vnd.kidspiration"],["kml","application/vnd.google-earth.kml+xml"],["kmz","application/vnd.google-earth.kmz"],["kne","application/vnd.kinar"],["knp","application/vnd.kinar"],["kon","application/vnd.kde.kontour"],["kpr","application/vnd.kde.kpresenter"],["kpt","application/vnd.kde.kpresenter"],["kpxx","application/vnd.ds-keypoint"],["ksp","application/vnd.kde.kspread"],["ktr","application/vnd.kahootz"],["ktx","image/ktx"],["ktx2","image/ktx2"],["ktz","application/vnd.kahootz"],["kwd","application/vnd.kde.kword"],["kwt","application/vnd.kde.kword"],["lasxml","application/vnd.las.las+xml"],["latex","application/x-latex"],["lbd","application/vnd.llamagraphics.life-balance.desktop"],["lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],["les","application/vnd.hhe.lesson-player"],["less","text/less"],["lgr","application/lgr+xml"],["lha","application/octet-stream"],["link66","application/vnd.route66.link66+xml"],["list","text/plain"],["list3820","application/vnd.ibm.modcap"],["listafp","application/vnd.ibm.modcap"],["litcoffee","text/coffeescript"],["lnk","application/x-ms-shortcut"],["log","text/plain"],["lostxml","application/lost+xml"],["lrf","application/octet-stream"],["lrm","application/vnd.ms-lrm"],["ltf","application/vnd.frogans.ltf"],["lua","text/x-lua"],["luac","application/x-lua-bytecode"],["lvp","audio/vnd.lucent.voice"],["lwp","application/vnd.lotus-wordpro"],["lzh","application/octet-stream"],["m1v","video/mpeg"],["m2a","audio/mpeg"],["m2v","video/mpeg"],["m3a","audio/mpeg"],["m3u","text/plain"],["m3u8","application/vnd.apple.mpegurl"],["m4a","audio/x-m4a"],["m4p","application/mp4"],["m4s","video/iso.segment"],["m4u","application/vnd.mpegurl"],["m4v","video/x-m4v"],["m13","application/x-msmediaview"],["m14","application/x-msmediaview"],["m21","application/mp21"],["ma","application/mathematica"],["mads","application/mads+xml"],["maei","application/mmt-aei+xml"],["mag","application/vnd.ecowin.chart"],["maker","application/vnd.framemaker"],["man","text/troff"],["manifest","text/cache-manifest"],["map","application/json"],["mar","application/octet-stream"],["markdown","text/markdown"],["mathml","application/mathml+xml"],["mb","application/mathematica"],["mbk","application/vnd.mobius.mbk"],["mbox","application/mbox"],["mc1","application/vnd.medcalcdata"],["mcd","application/vnd.mcd"],["mcurl","text/vnd.curl.mcurl"],["md","text/markdown"],["mdb","application/x-msaccess"],["mdi","image/vnd.ms-modi"],["mdx","text/mdx"],["me","text/troff"],["mesh","model/mesh"],["meta4","application/metalink4+xml"],["metalink","application/metalink+xml"],["mets","application/mets+xml"],["mfm","application/vnd.mfmp"],["mft","application/rpki-manifest"],["mgp","application/vnd.osgeo.mapguide.package"],["mgz","application/vnd.proteus.magazine"],["mid","audio/midi"],["midi","audio/midi"],["mie","application/x-mie"],["mif","application/vnd.mif"],["mime","message/rfc822"],["mj2","video/mj2"],["mjp2","video/mj2"],["mjs","application/javascript"],["mk3d","video/x-matroska"],["mka","audio/x-matroska"],["mkd","text/x-markdown"],["mks","video/x-matroska"],["mkv","video/x-matroska"],["mlp","application/vnd.dolby.mlp"],["mmd","application/vnd.chipnuts.karaoke-mmd"],["mmf","application/vnd.smaf"],["mml","text/mathml"],["mmr","image/vnd.fujixerox.edmics-mmr"],["mng","video/x-mng"],["mny","application/x-msmoney"],["mobi","application/x-mobipocket-ebook"],["mods","application/mods+xml"],["mov","video/quicktime"],["movie","video/x-sgi-movie"],["mp2","audio/mpeg"],["mp2a","audio/mpeg"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mp4a","audio/mp4"],["mp4s","application/mp4"],["mp4v","video/mp4"],["mp21","application/mp21"],["mpc","application/vnd.mophun.certificate"],["mpd","application/dash+xml"],["mpe","video/mpeg"],["mpeg","video/mpeg"],["mpg","video/mpeg"],["mpg4","video/mp4"],["mpga","audio/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["mpm","application/vnd.blueice.multipass"],["mpn","application/vnd.mophun.application"],["mpp","application/vnd.ms-project"],["mpt","application/vnd.ms-project"],["mpy","application/vnd.ibm.minipay"],["mqy","application/vnd.mobius.mqy"],["mrc","application/marc"],["mrcx","application/marcxml+xml"],["ms","text/troff"],["mscml","application/mediaservercontrol+xml"],["mseed","application/vnd.fdsn.mseed"],["mseq","application/vnd.mseq"],["msf","application/vnd.epson.msf"],["msg","application/vnd.ms-outlook"],["msh","model/mesh"],["msi","application/x-msdownload"],["msl","application/vnd.mobius.msl"],["msm","application/octet-stream"],["msp","application/octet-stream"],["msty","application/vnd.muvee.style"],["mtl","model/mtl"],["mts","model/vnd.mts"],["mus","application/vnd.musician"],["musd","application/mmt-usd+xml"],["musicxml","application/vnd.recordare.musicxml+xml"],["mvb","application/x-msmediaview"],["mvt","application/vnd.mapbox-vector-tile"],["mwf","application/vnd.mfer"],["mxf","application/mxf"],["mxl","application/vnd.recordare.musicxml"],["mxmf","audio/mobile-xmf"],["mxml","application/xv+xml"],["mxs","application/vnd.triscape.mxs"],["mxu","video/vnd.mpegurl"],["n-gage","application/vnd.nokia.n-gage.symbian.install"],["n3","text/n3"],["nb","application/mathematica"],["nbp","application/vnd.wolfram.player"],["nc","application/x-netcdf"],["ncx","application/x-dtbncx+xml"],["nfo","text/x-nfo"],["ngdat","application/vnd.nokia.n-gage.data"],["nitf","application/vnd.nitf"],["nlu","application/vnd.neurolanguage.nlu"],["nml","application/vnd.enliven"],["nnd","application/vnd.noblenet-directory"],["nns","application/vnd.noblenet-sealer"],["nnw","application/vnd.noblenet-web"],["npx","image/vnd.net-fpx"],["nq","application/n-quads"],["nsc","application/x-conference"],["nsf","application/vnd.lotus-notes"],["nt","application/n-triples"],["ntf","application/vnd.nitf"],["numbers","application/x-iwork-numbers-sffnumbers"],["nzb","application/x-nzb"],["oa2","application/vnd.fujitsu.oasys2"],["oa3","application/vnd.fujitsu.oasys3"],["oas","application/vnd.fujitsu.oasys"],["obd","application/x-msbinder"],["obgx","application/vnd.openblox.game+xml"],["obj","model/obj"],["oda","application/oda"],["odb","application/vnd.oasis.opendocument.database"],["odc","application/vnd.oasis.opendocument.chart"],["odf","application/vnd.oasis.opendocument.formula"],["odft","application/vnd.oasis.opendocument.formula-template"],["odg","application/vnd.oasis.opendocument.graphics"],["odi","application/vnd.oasis.opendocument.image"],["odm","application/vnd.oasis.opendocument.text-master"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogex","model/vnd.opengex"],["ogg","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["omdoc","application/omdoc+xml"],["onepkg","application/onenote"],["onetmp","application/onenote"],["onetoc","application/onenote"],["onetoc2","application/onenote"],["opf","application/oebps-package+xml"],["opml","text/x-opml"],["oprc","application/vnd.palm"],["opus","audio/ogg"],["org","text/x-org"],["osf","application/vnd.yamaha.openscoreformat"],["osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],["osm","application/vnd.openstreetmap.data+xml"],["otc","application/vnd.oasis.opendocument.chart-template"],["otf","font/otf"],["otg","application/vnd.oasis.opendocument.graphics-template"],["oth","application/vnd.oasis.opendocument.text-web"],["oti","application/vnd.oasis.opendocument.image-template"],["otp","application/vnd.oasis.opendocument.presentation-template"],["ots","application/vnd.oasis.opendocument.spreadsheet-template"],["ott","application/vnd.oasis.opendocument.text-template"],["ova","application/x-virtualbox-ova"],["ovf","application/x-virtualbox-ovf"],["owl","application/rdf+xml"],["oxps","application/oxps"],["oxt","application/vnd.openofficeorg.extension"],["p","text/x-pascal"],["p7a","application/x-pkcs7-signature"],["p7b","application/x-pkcs7-certificates"],["p7c","application/pkcs7-mime"],["p7m","application/pkcs7-mime"],["p7r","application/x-pkcs7-certreqresp"],["p7s","application/pkcs7-signature"],["p8","application/pkcs8"],["p10","application/x-pkcs10"],["p12","application/x-pkcs12"],["pac","application/x-ns-proxy-autoconfig"],["pages","application/x-iwork-pages-sffpages"],["pas","text/x-pascal"],["paw","application/vnd.pawaafile"],["pbd","application/vnd.powerbuilder6"],["pbm","image/x-portable-bitmap"],["pcap","application/vnd.tcpdump.pcap"],["pcf","application/x-font-pcf"],["pcl","application/vnd.hp-pcl"],["pclxl","application/vnd.hp-pclxl"],["pct","image/x-pict"],["pcurl","application/vnd.curl.pcurl"],["pcx","image/x-pcx"],["pdb","application/x-pilot"],["pde","text/x-processing"],["pdf","application/pdf"],["pem","application/x-x509-user-cert"],["pfa","application/x-font-type1"],["pfb","application/x-font-type1"],["pfm","application/x-font-type1"],["pfr","application/font-tdpfr"],["pfx","application/x-pkcs12"],["pgm","image/x-portable-graymap"],["pgn","application/x-chess-pgn"],["pgp","application/pgp"],["php","application/x-httpd-php"],["php3","application/x-httpd-php"],["php4","application/x-httpd-php"],["phps","application/x-httpd-php-source"],["phtml","application/x-httpd-php"],["pic","image/x-pict"],["pkg","application/octet-stream"],["pki","application/pkixcmp"],["pkipath","application/pkix-pkipath"],["pkpass","application/vnd.apple.pkpass"],["pl","application/x-perl"],["plb","application/vnd.3gpp.pic-bw-large"],["plc","application/vnd.mobius.plc"],["plf","application/vnd.pocketlearn"],["pls","application/pls+xml"],["pm","application/x-perl"],["pml","application/vnd.ctc-posml"],["png","image/png"],["pnm","image/x-portable-anymap"],["portpkg","application/vnd.macports.portpkg"],["pot","application/vnd.ms-powerpoint"],["potm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["potx","application/vnd.openxmlformats-officedocument.presentationml.template"],["ppa","application/vnd.ms-powerpoint"],["ppam","application/vnd.ms-powerpoint.addin.macroEnabled.12"],["ppd","application/vnd.cups-ppd"],["ppm","image/x-portable-pixmap"],["pps","application/vnd.ms-powerpoint"],["ppsm","application/vnd.ms-powerpoint.slideshow.macroEnabled.12"],["ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],["ppt","application/powerpoint"],["pptm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["pqa","application/vnd.palm"],["prc","application/x-pilot"],["pre","application/vnd.lotus-freelance"],["prf","application/pics-rules"],["provx","application/provenance+xml"],["ps","application/postscript"],["psb","application/vnd.3gpp.pic-bw-small"],["psd","application/x-photoshop"],["psf","application/x-font-linux-psf"],["pskcxml","application/pskc+xml"],["pti","image/prs.pti"],["ptid","application/vnd.pvi.ptid1"],["pub","application/x-mspublisher"],["pvb","application/vnd.3gpp.pic-bw-var"],["pwn","application/vnd.3m.post-it-notes"],["pya","audio/vnd.ms-playready.media.pya"],["pyv","video/vnd.ms-playready.media.pyv"],["qam","application/vnd.epson.quickanime"],["qbo","application/vnd.intu.qbo"],["qfx","application/vnd.intu.qfx"],["qps","application/vnd.publishare-delta-tree"],["qt","video/quicktime"],["qwd","application/vnd.quark.quarkxpress"],["qwt","application/vnd.quark.quarkxpress"],["qxb","application/vnd.quark.quarkxpress"],["qxd","application/vnd.quark.quarkxpress"],["qxl","application/vnd.quark.quarkxpress"],["qxt","application/vnd.quark.quarkxpress"],["ra","audio/x-realaudio"],["ram","audio/x-pn-realaudio"],["raml","application/raml+yaml"],["rapd","application/route-apd+xml"],["rar","application/x-rar"],["ras","image/x-cmu-raster"],["rcprofile","application/vnd.ipunplugged.rcprofile"],["rdf","application/rdf+xml"],["rdz","application/vnd.data-vision.rdz"],["relo","application/p2p-overlay+xml"],["rep","application/vnd.businessobjects"],["res","application/x-dtbresource+xml"],["rgb","image/x-rgb"],["rif","application/reginfo+xml"],["rip","audio/vnd.rip"],["ris","application/x-research-info-systems"],["rl","application/resource-lists+xml"],["rlc","image/vnd.fujixerox.edmics-rlc"],["rld","application/resource-lists-diff+xml"],["rm","audio/x-pn-realaudio"],["rmi","audio/midi"],["rmp","audio/x-pn-realaudio-plugin"],["rms","application/vnd.jcp.javame.midlet-rms"],["rmvb","application/vnd.rn-realmedia-vbr"],["rnc","application/relax-ng-compact-syntax"],["rng","application/xml"],["roa","application/rpki-roa"],["roff","text/troff"],["rp9","application/vnd.cloanto.rp9"],["rpm","audio/x-pn-realaudio-plugin"],["rpss","application/vnd.nokia.radio-presets"],["rpst","application/vnd.nokia.radio-preset"],["rq","application/sparql-query"],["rs","application/rls-services+xml"],["rsa","application/x-pkcs7"],["rsat","application/atsc-rsat+xml"],["rsd","application/rsd+xml"],["rsheet","application/urc-ressheet+xml"],["rss","application/rss+xml"],["rtf","text/rtf"],["rtx","text/richtext"],["run","application/x-makeself"],["rusd","application/route-usd+xml"],["rv","video/vnd.rn-realvideo"],["s","text/x-asm"],["s3m","audio/s3m"],["saf","application/vnd.yamaha.smaf-audio"],["sass","text/x-sass"],["sbml","application/sbml+xml"],["sc","application/vnd.ibm.secure-container"],["scd","application/x-msschedule"],["scm","application/vnd.lotus-screencam"],["scq","application/scvp-cv-request"],["scs","application/scvp-cv-response"],["scss","text/x-scss"],["scurl","text/vnd.curl.scurl"],["sda","application/vnd.stardivision.draw"],["sdc","application/vnd.stardivision.calc"],["sdd","application/vnd.stardivision.impress"],["sdkd","application/vnd.solent.sdkm+xml"],["sdkm","application/vnd.solent.sdkm+xml"],["sdp","application/sdp"],["sdw","application/vnd.stardivision.writer"],["sea","application/octet-stream"],["see","application/vnd.seemail"],["seed","application/vnd.fdsn.seed"],["sema","application/vnd.sema"],["semd","application/vnd.semd"],["semf","application/vnd.semf"],["senmlx","application/senml+xml"],["sensmlx","application/sensml+xml"],["ser","application/java-serialized-object"],["setpay","application/set-payment-initiation"],["setreg","application/set-registration-initiation"],["sfd-hdstx","application/vnd.hydrostatix.sof-data"],["sfs","application/vnd.spotfire.sfs"],["sfv","text/x-sfv"],["sgi","image/sgi"],["sgl","application/vnd.stardivision.writer-global"],["sgm","text/sgml"],["sgml","text/sgml"],["sh","application/x-sh"],["shar","application/x-shar"],["shex","text/shex"],["shf","application/shf+xml"],["shtml","text/html"],["sid","image/x-mrsid-image"],["sieve","application/sieve"],["sig","application/pgp-signature"],["sil","audio/silk"],["silo","model/mesh"],["sis","application/vnd.symbian.install"],["sisx","application/vnd.symbian.install"],["sit","application/x-stuffit"],["sitx","application/x-stuffitx"],["siv","application/sieve"],["skd","application/vnd.koan"],["skm","application/vnd.koan"],["skp","application/vnd.koan"],["skt","application/vnd.koan"],["sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],["sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],["slim","text/slim"],["slm","text/slim"],["sls","application/route-s-tsid+xml"],["slt","application/vnd.epson.salt"],["sm","application/vnd.stepmania.stepchart"],["smf","application/vnd.stardivision.math"],["smi","application/smil"],["smil","application/smil"],["smv","video/x-smv"],["smzip","application/vnd.stepmania.package"],["snd","audio/basic"],["snf","application/x-font-snf"],["so","application/octet-stream"],["spc","application/x-pkcs7-certificates"],["spdx","text/spdx"],["spf","application/vnd.yamaha.smaf-phrase"],["spl","application/x-futuresplash"],["spot","text/vnd.in3d.spot"],["spp","application/scvp-vp-response"],["spq","application/scvp-vp-request"],["spx","audio/ogg"],["sql","application/x-sql"],["src","application/x-wais-source"],["srt","application/x-subrip"],["sru","application/sru+xml"],["srx","application/sparql-results+xml"],["ssdl","application/ssdl+xml"],["sse","application/vnd.kodak-descriptor"],["ssf","application/vnd.epson.ssf"],["ssml","application/ssml+xml"],["sst","application/octet-stream"],["st","application/vnd.sailingtracker.track"],["stc","application/vnd.sun.xml.calc.template"],["std","application/vnd.sun.xml.draw.template"],["stf","application/vnd.wt.stf"],["sti","application/vnd.sun.xml.impress.template"],["stk","application/hyperstudio"],["stl","model/stl"],["stpx","model/step+xml"],["stpxz","model/step-xml+zip"],["stpz","model/step+zip"],["str","application/vnd.pg.format"],["stw","application/vnd.sun.xml.writer.template"],["styl","text/stylus"],["stylus","text/stylus"],["sub","text/vnd.dvb.subtitle"],["sus","application/vnd.sus-calendar"],["susp","application/vnd.sus-calendar"],["sv4cpio","application/x-sv4cpio"],["sv4crc","application/x-sv4crc"],["svc","application/vnd.dvb.service"],["svd","application/vnd.svd"],["svg","image/svg+xml"],["svgz","image/svg+xml"],["swa","application/x-director"],["swf","application/x-shockwave-flash"],["swi","application/vnd.aristanetworks.swi"],["swidtag","application/swid+xml"],["sxc","application/vnd.sun.xml.calc"],["sxd","application/vnd.sun.xml.draw"],["sxg","application/vnd.sun.xml.writer.global"],["sxi","application/vnd.sun.xml.impress"],["sxm","application/vnd.sun.xml.math"],["sxw","application/vnd.sun.xml.writer"],["t","text/troff"],["t3","application/x-t3vm-image"],["t38","image/t38"],["taglet","application/vnd.mynfc"],["tao","application/vnd.tao.intent-module-archive"],["tap","image/vnd.tencent.tap"],["tar","application/x-tar"],["tcap","application/vnd.3gpp2.tcap"],["tcl","application/x-tcl"],["td","application/urc-targetdesc+xml"],["teacher","application/vnd.smart.teacher"],["tei","application/tei+xml"],["teicorpus","application/tei+xml"],["tex","application/x-tex"],["texi","application/x-texinfo"],["texinfo","application/x-texinfo"],["text","text/plain"],["tfi","application/thraud+xml"],["tfm","application/x-tex-tfm"],["tfx","image/tiff-fx"],["tga","image/x-tga"],["tgz","application/x-tar"],["thmx","application/vnd.ms-officetheme"],["tif","image/tiff"],["tiff","image/tiff"],["tk","application/x-tcl"],["tmo","application/vnd.tmobile-livetv"],["toml","application/toml"],["torrent","application/x-bittorrent"],["tpl","application/vnd.groove-tool-template"],["tpt","application/vnd.trid.tpt"],["tr","text/troff"],["tra","application/vnd.trueapp"],["trig","application/trig"],["trm","application/x-msterminal"],["ts","video/mp2t"],["tsd","application/timestamped-data"],["tsv","text/tab-separated-values"],["ttc","font/collection"],["ttf","font/ttf"],["ttl","text/turtle"],["ttml","application/ttml+xml"],["twd","application/vnd.simtech-mindmapper"],["twds","application/vnd.simtech-mindmapper"],["txd","application/vnd.genomatix.tuxedo"],["txf","application/vnd.mobius.txf"],["txt","text/plain"],["u8dsn","message/global-delivery-status"],["u8hdr","message/global-headers"],["u8mdn","message/global-disposition-notification"],["u8msg","message/global"],["u32","application/x-authorware-bin"],["ubj","application/ubjson"],["udeb","application/x-debian-package"],["ufd","application/vnd.ufdl"],["ufdl","application/vnd.ufdl"],["ulx","application/x-glulx"],["umj","application/vnd.umajin"],["unityweb","application/vnd.unity"],["uoml","application/vnd.uoml+xml"],["uri","text/uri-list"],["uris","text/uri-list"],["urls","text/uri-list"],["usdz","model/vnd.usdz+zip"],["ustar","application/x-ustar"],["utz","application/vnd.uiq.theme"],["uu","text/x-uuencode"],["uva","audio/vnd.dece.audio"],["uvd","application/vnd.dece.data"],["uvf","application/vnd.dece.data"],["uvg","image/vnd.dece.graphic"],["uvh","video/vnd.dece.hd"],["uvi","image/vnd.dece.graphic"],["uvm","video/vnd.dece.mobile"],["uvp","video/vnd.dece.pd"],["uvs","video/vnd.dece.sd"],["uvt","application/vnd.dece.ttml+xml"],["uvu","video/vnd.uvvu.mp4"],["uvv","video/vnd.dece.video"],["uvva","audio/vnd.dece.audio"],["uvvd","application/vnd.dece.data"],["uvvf","application/vnd.dece.data"],["uvvg","image/vnd.dece.graphic"],["uvvh","video/vnd.dece.hd"],["uvvi","image/vnd.dece.graphic"],["uvvm","video/vnd.dece.mobile"],["uvvp","video/vnd.dece.pd"],["uvvs","video/vnd.dece.sd"],["uvvt","application/vnd.dece.ttml+xml"],["uvvu","video/vnd.uvvu.mp4"],["uvvv","video/vnd.dece.video"],["uvvx","application/vnd.dece.unspecified"],["uvvz","application/vnd.dece.zip"],["uvx","application/vnd.dece.unspecified"],["uvz","application/vnd.dece.zip"],["vbox","application/x-virtualbox-vbox"],["vbox-extpack","application/x-virtualbox-vbox-extpack"],["vcard","text/vcard"],["vcd","application/x-cdlink"],["vcf","text/x-vcard"],["vcg","application/vnd.groove-vcard"],["vcs","text/x-vcalendar"],["vcx","application/vnd.vcx"],["vdi","application/x-virtualbox-vdi"],["vds","model/vnd.sap.vds"],["vhd","application/x-virtualbox-vhd"],["vis","application/vnd.visionary"],["viv","video/vnd.vivo"],["vlc","application/videolan"],["vmdk","application/x-virtualbox-vmdk"],["vob","video/x-ms-vob"],["vor","application/vnd.stardivision.writer"],["vox","application/x-authorware-bin"],["vrml","model/vrml"],["vsd","application/vnd.visio"],["vsf","application/vnd.vsf"],["vss","application/vnd.visio"],["vst","application/vnd.visio"],["vsw","application/vnd.visio"],["vtf","image/vnd.valve.source.texture"],["vtt","text/vtt"],["vtu","model/vnd.vtu"],["vxml","application/voicexml+xml"],["w3d","application/x-director"],["wad","application/x-doom"],["wadl","application/vnd.sun.wadl+xml"],["war","application/java-archive"],["wasm","application/wasm"],["wav","audio/x-wav"],["wax","audio/x-ms-wax"],["wbmp","image/vnd.wap.wbmp"],["wbs","application/vnd.criticaltools.wbs+xml"],["wbxml","application/wbxml"],["wcm","application/vnd.ms-works"],["wdb","application/vnd.ms-works"],["wdp","image/vnd.ms-photo"],["weba","audio/webm"],["webapp","application/x-web-app-manifest+json"],["webm","video/webm"],["webmanifest","application/manifest+json"],["webp","image/webp"],["wg","application/vnd.pmi.widget"],["wgt","application/widget"],["wks","application/vnd.ms-works"],["wm","video/x-ms-wm"],["wma","audio/x-ms-wma"],["wmd","application/x-ms-wmd"],["wmf","image/wmf"],["wml","text/vnd.wap.wml"],["wmlc","application/wmlc"],["wmls","text/vnd.wap.wmlscript"],["wmlsc","application/vnd.wap.wmlscriptc"],["wmv","video/x-ms-wmv"],["wmx","video/x-ms-wmx"],["wmz","application/x-msmetafile"],["woff","font/woff"],["woff2","font/woff2"],["word","application/msword"],["wpd","application/vnd.wordperfect"],["wpl","application/vnd.ms-wpl"],["wps","application/vnd.ms-works"],["wqd","application/vnd.wqd"],["wri","application/x-mswrite"],["wrl","model/vrml"],["wsc","message/vnd.wfa.wsc"],["wsdl","application/wsdl+xml"],["wspolicy","application/wspolicy+xml"],["wtb","application/vnd.webturbo"],["wvx","video/x-ms-wvx"],["x3d","model/x3d+xml"],["x3db","model/x3d+fastinfoset"],["x3dbz","model/x3d+binary"],["x3dv","model/x3d-vrml"],["x3dvz","model/x3d+vrml"],["x3dz","model/x3d+xml"],["x32","application/x-authorware-bin"],["x_b","model/vnd.parasolid.transmit.binary"],["x_t","model/vnd.parasolid.transmit.text"],["xaml","application/xaml+xml"],["xap","application/x-silverlight-app"],["xar","application/vnd.xara"],["xav","application/xcap-att+xml"],["xbap","application/x-ms-xbap"],["xbd","application/vnd.fujixerox.docuworks.binder"],["xbm","image/x-xbitmap"],["xca","application/xcap-caps+xml"],["xcs","application/calendar+xml"],["xdf","application/xcap-diff+xml"],["xdm","application/vnd.syncml.dm+xml"],["xdp","application/vnd.adobe.xdp+xml"],["xdssc","application/dssc+xml"],["xdw","application/vnd.fujixerox.docuworks"],["xel","application/xcap-el+xml"],["xenc","application/xenc+xml"],["xer","application/patch-ops-error+xml"],["xfdf","application/vnd.adobe.xfdf"],["xfdl","application/vnd.xfdl"],["xht","application/xhtml+xml"],["xhtml","application/xhtml+xml"],["xhvml","application/xv+xml"],["xif","image/vnd.xiff"],["xl","application/excel"],["xla","application/vnd.ms-excel"],["xlam","application/vnd.ms-excel.addin.macroEnabled.12"],["xlc","application/vnd.ms-excel"],["xlf","application/xliff+xml"],["xlm","application/vnd.ms-excel"],["xls","application/vnd.ms-excel"],["xlsb","application/vnd.ms-excel.sheet.binary.macroEnabled.12"],["xlsm","application/vnd.ms-excel.sheet.macroEnabled.12"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xlt","application/vnd.ms-excel"],["xltm","application/vnd.ms-excel.template.macroEnabled.12"],["xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],["xlw","application/vnd.ms-excel"],["xm","audio/xm"],["xml","application/xml"],["xns","application/xcap-ns+xml"],["xo","application/vnd.olpc-sugar"],["xop","application/xop+xml"],["xpi","application/x-xpinstall"],["xpl","application/xproc+xml"],["xpm","image/x-xpixmap"],["xpr","application/vnd.is-xpr"],["xps","application/vnd.ms-xpsdocument"],["xpw","application/vnd.intercon.formnet"],["xpx","application/vnd.intercon.formnet"],["xsd","application/xml"],["xsl","application/xml"],["xslt","application/xslt+xml"],["xsm","application/vnd.syncml+xml"],["xspf","application/xspf+xml"],["xul","application/vnd.mozilla.xul+xml"],["xvm","application/xv+xml"],["xvml","application/xv+xml"],["xwd","image/x-xwindowdump"],["xyz","chemical/x-xyz"],["xz","application/x-xz"],["yaml","text/yaml"],["yang","application/yang"],["yin","application/yin+xml"],["yml","text/yaml"],["ymp","text/x-suse-ymp"],["z","application/x-compress"],["z1","application/x-zmachine"],["z2","application/x-zmachine"],["z3","application/x-zmachine"],["z4","application/x-zmachine"],["z5","application/x-zmachine"],["z6","application/x-zmachine"],["z7","application/x-zmachine"],["z8","application/x-zmachine"],["zaz","application/vnd.zzazz.deck+xml"],["zip","application/zip"],["zir","application/vnd.zul"],["zirz","application/vnd.zul"],["zmm","application/vnd.handheld-entertainment+xml"],["zsh","text/x-scriptzsh"]]);function
355eN(e,t,n){let i=function(e){let{name:t}=e;if(t&&-1!==t.lastIndexOf(".")&&!e.type){let n=t.split(".").pop().toLowerCase(),i=eO.get(n);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}(e),{webkitRelativePath:r}=e,o="string"==typeof t?t:"string"==typeof r&&r.length>0?r:`./${e.name}`;return"string"!=typeof i.path&&eB(i,"path",o),void 0!==n&&Object.defineProperty(i,"handle",{value:n,writable:!1,configurable:!1,enumerable:!0}),eB(i,"relativePath",o),i}function eB(e,t,n){Object.defineProperty(e,t,{value:n,writable:!1,configurable:!1,enumerable:!0})}let ez=[".DS_Store","Thumbs.db"];function ej(e){return"object"==typeof e&&null!==e}function eV(e){return e.filter(e=>-1===ez.indexOf(e.name))}function eH(e){if(null===e)return[];let t=[];for(let n=0;n<e.length;n++){let i=e[n];t.push(i)}return t}function eG(e){if("function"!=typeof e.webkitGetAsEntry)return eW(e);let t=e.webkitGetAsEntry();return t&&t.isDirectory?eU(t):eW(e,t)}function eW(e,t){return eF(this,void 0,void 0,function*(){var n;if(globalThis.isSecureContext&&"function"==typeof e.getAsFileSystemHandle){let t=yield e.getAsFileSystemHandle();if(null===t)throw Error(`${e} is not a File`);if(void 0!==t){let e=yield t.getFile();return e.handle=t,eN(e)}}let i=e.getAsFile();if(!i)throw Error(`${e} is not a File`);return eN(i,null!=(n=null==t?void 0:t.fullPath)?n:void 0)})}function e$(e){return eF(this,void 0,void 0,function*(){return e.isDirectory?eU(e):function(e){return eF(this,void 0,void 0,function*(){return new Promise((t,n)=>{e.file(n=>{t(eN(n,e.fullPath))},e=>{n(e)})})})}(e)})}function eU(e){let t=e.createReader();return new Promise((e,n)=>{let i=[];!function r(){t.readEntries(t=>eF(this,void 0,void 0,function*(){if(t.length){let e=Promise.all(t.map(e$));i.push(e),r()}else try{let t=yield Promise.all(i);e(t)}catch(e){n(e)}}),e=>{n(e)})}()})}var eq=e.i(20728);function eK(e){return function(e){if(Array.isArray(e))return e0(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||eQ(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function eY(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,i)}return n}function eZ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?eY(Object(n),!0).forEach(function(t){eX(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):eY(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function eX(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function eJ(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n,i,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var o=[],a=!0,s=!1;try{for(r=r.call(e);!(a=(n=r.next()).done)&&(o.push(n.value),!t||o.length!==t);a=!0);}catch(e){s=!0,i=e}finally{try{a||null==r.return||r.return()}finally{if(s)throw i}}return o}}(e,t)||eQ(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function eQ(e,t){if(e){if("string"==typeof e)return e0(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return e0(e,t)}}function e0(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}var e1="function"==typeof eq.default?eq.default:eq.default.default,e2=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=e.split(","),n=t.length>1?"one of ".concat(t.join(", ")):t[0];return{code:"file-invalid-type",message:"File type must be ".concat(n)}},e3=function(e){return{code:"file-too-large",message:"File is larger than ".concat(e," ").concat(1===e?"byte":"bytes")}},e5=function(e){return{code:"file-too-small",message:"File is smaller than ".concat(e," ").concat(1===e?"byte":"bytes")}},e4={code:"too-many-files",message:"Too many files"};function e6(e,t){var n="application/x-moz-file"===e.type||e1(e,t)||""===e.type&&"function"==typeof e.getAsFile;return[n,n?null:e2(t)]}function e8(e,t,n){if(e7(e.size)){if(e7(t)&&e7(n)){if(e.size>n)return[!1,e3(n)];if(e.size<t)return[!1,e5(t)]}else if(e7(t)&&e.size<t)return[!1,e5(t)];else if(e7(n)&&e.size>n)return[!1,e3(n)]}return[!0,null]}function e7(e){return null!=e}function e9(e){return"function"==typeof e.isPropagationStopped?e.isPropagationStopped():void 0!==e.cancelBubble&&e.cancelBubble}function te(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(e){return"Files"===e||"application/x-moz-file"===e}):!!e.target&&!!e.target.files}function tt(e){e.preventDefault()}function tn(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,i=Array(n>1?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];return t.some(function(t){return!e9(e)&&t&&t.apply(void 0,[e].concat(i)),e9(e)})}}function ti(e){return"audio/*"===e||"video/*"===e||"image/*"===e||"text/*"===e||"application/*"===e||/\w+\/[-+.\w]+/g.test(e)}function tr(e){return/^.*\.[\w]+$/.test(e)}var to=["children"],ta=["open"],ts=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],tl=["refKey","onChange","onClick"];function td(e){return function(e){if(Array.isArray(e))return th(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||tc(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function tu(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n,i,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var o=[],a=!0,s=!1;try{for(r=r.call(e);!(a=(n=r.next()).done)&&(o.push(n.value),!t||o.length!==t);a=!0);}catch(e){s=!0,i=e}finally{try{a||null==r.return||r.return()}finally{if(s)throw i}}return o}}(e,t)||tc(e,t)||function(){throw TypeError("Invalid attempt to de
355structure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function tc(e,t){if(e){if("string"==typeof e)return th(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return th(e,t)}}function th(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function tp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,i)}return n}function tf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tp(Object(n),!0).forEach(function(t){tg(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tp(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function tg(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tm(e,t){if(null==e)return{};var n,i,r=function(e,t){if(null==e)return{};var n,i,r={},o=Object.keys(e);for(i=0;i<o.length;i++)n=o[i],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var tv=(0,I.forwardRef)(function(e,t){var n=e.children,i=tx(tm(e,to)),r=i.open,o=tm(i,ta);return(0,I.useImperativeHandle)(t,function(){return{open:r}},[r]),I.default.createElement(I.Fragment,null,n(tf(tf({},o),{},{open:r})))});tv.displayName="Dropzone";var ty={disabled:!1,getFilesFromEvent:function(e){return eF(this,void 0,void 0,function*(){var t;if(ej(e)&&ej(e.dataTransfer))return function(e,t){return eF(this,void 0,void 0,function*(){if(e.items){let n=eH(e.items).filter(e=>"file"===e.kind);return"drop"!==t?n:eV(function e(t){return t.reduce((t,n)=>[...t,...Array.isArray(n)?e(n):[n]],[])}((yield Promise.all(n.map(eG)))))}return eV(eH(e.files).map(e=>eN(e)))})}(e.dataTransfer,e.type);if(ej(t=e)&&ej(t.target))return eH(e.target.files).map(e=>eN(e));return Array.isArray(e)&&e.every(e=>"getFile"in e&&"function"==typeof e.getFile)?function(e){return eF(this,void 0,void 0,function*(){return(yield Promise.all(e.map(e=>e.getFile()))).map(e=>eN(e))})}(e):[]})},maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};tv.defaultProps=ty,tv.propTypes={children:eL.default.func,accept:eL.default.objectOf(eL.default.arrayOf(eL.default.string)),multiple:eL.default.bool,preventDropOnDocument:eL.default.bool,noClick:eL.default.bool,noKeyboard:eL.default.bool,noDrag:eL.default.bool,noDragEventsBubbling:eL.default.bool,minSize:eL.default.number,maxSize:eL.default.number,maxFiles:eL.default.number,disabled:eL.default.bool,getFilesFromEvent:eL.default.func,onFileDialogCancel:eL.default.func,onFileDialogOpen:eL.default.func,useFsAccessApi:eL.default.bool,autoFocus:eL.default.bool,onDragEnter:eL.default.func,onDragLeave:eL.default.func,onDragOver:eL.default.func,onDrop:eL.default.func,onDropAccepted:eL.default.func,onDropRejected:eL.default.func,onError:eL.default.func,validator:eL.default.func};var tb={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,isDragGlobal:!1,acceptedFiles:[],fileRejections:[]};function tx(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=tf(tf({},ty),e),n=t.accept,i=t.disabled,r=t.getFilesFromEvent,o=t.maxSize,a=t.minSize,s=t.multiple,l=t.maxFiles,d=t.onDragEnter,u=t.onDragLeave,c=t.onDragOver,h=t.onDrop,p=t.onDropAccepted,f=t.onDropRejected,g=t.onFileDialogCancel,m=t.onFileDialogOpen,v=t.useFsAccessApi,y=t.autoFocus,b=t.preventDropOnDocument,x=t.noClick,w=t.noKeyboard,C=t.noDrag,S=t.noDragEventsBubbling,_=t.onError,k=t.validator,M=(0,I.useMemo)(function(){return e7(n)?Object.entries(n).reduce(function(e,t){var n=eJ(t,2),i=n[0],r=n[1];return[].concat(eK(e),[i],eK(r))},[]).filter(function(e){return ti(e)||tr(e)}).join(","):void 0},[n]),T=(0,I.useMemo)(function(){return e7(n)?[{description:"Files",accept:Object.entries(n).filter(function(e){var t=eJ(e,2),n=t[0],i=t[1],r=!0;return ti(n)||(console.warn('Skipped "'.concat(n,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),r=!1),Array.isArray(i)&&i.every(tr)||(console.warn('Skipped "'.concat(n,'" because an invali
355d file extension was provided.')),r=!1),r}).reduce(function(e,t){var n=eJ(t,2),i=n[0],r=n[1];return eZ(eZ({},e),{},eX({},i,r))},{})}]:n},[n]),D=(0,I.useMemo)(function(){return"function"==typeof m?m:tC},[m]),R=(0,I.useMemo)(function(){return"function"==typeof g?g:tC},[g]),A=(0,I.useRef)(null),P=(0,I.useRef)(null),E=tu((0,I.useReducer)(tw,tb),2),L=E[0],F=E[1],O=L.isFocused,N=L.isFileDialogActive,B=(0,I.useRef)("u">typeof window&&window.isSecureContext&&v&&"showOpenFilePicker"in window),z=function(){!B.current&&N&&setTimeout(function(){P.current&&(P.current.files.length||(F({type:"closeDialog"}),R()))},300)};(0,I.useEffect)(function(){return window.addEventListener("focus",z,!1),function(){window.removeEventListener("focus",z,!1)}},[P,N,R,B]);var j=(0,I.useRef)([]),V=(0,I.useRef)([]),H=function(e){A.current&&A.current.contains(e.target)||(e.preventDefault(),j.current=[])};(0,I.useEffect)(function(){return b&&(document.addEventListener("dragover",tt,!1),document.addEventListener("drop",H,!1)),function(){b&&(document.removeEventListener("dragover",tt),document.removeEventListener("drop",H))}},[A,b]),(0,I.useEffect)(function(){var e=function(e){V.current=[].concat(td(V.current),[e.target]),te(e)&&F({isDragGlobal:!0,type:"setDragGlobal"})},t=function(e){V.current=V.current.filter(function(t){return t!==e.target&&null!==t}),V.current.length>0||F({isDragGlobal:!1,type:"setDragGlobal"})},n=function(){V.current=[],F({isDragGlobal:!1,type:"setDragGlobal"})},i=function(){V.current=[],F({isDragGlobal:!1,type:"setDragGlobal"})};return document.addEventListener("dragenter",e,!1),document.addEventListener("dragleave",t,!1),document.addEventListener("dragend",n,!1),document.addEventListener("drop",i,!1),function(){document.removeEventListener("dragenter",e),document.removeEventListener("dragleave",t),document.removeEventListener("dragend",n),document.removeEventListener("drop",i)}},[A]),(0,I.useEffect)(function(){return!i&&y&&A.current&&A.current.focus(),function(){}},[A,y,i]);var G=(0,I.useCallback)(function(e){_?_(e):console.error(e)},[_]),W=(0,I.useCallback)(function(e){e.preventDefault(),e.persist(),ei(e),j.current=[].concat(td(j.
355current),[e.target]),te(e)&&Promise.resolve(r(e)).then(function(t){if(!e9(e)||S){var n,i,r,u,c,h,p,f,g=t.length,m=g>0&&(i=(n={files:t,accept:M,minSize:a,maxSize:o,multiple:s,maxFiles:l,validator:k}).files,r=n.accept,u=n.minSize,c=n.maxSize,h=n.multiple,p=n.maxFiles,f=n.validator,(!!h||!(i.length>1))&&(!h||!(p>=1)||!(i.length>p))&&i.every(function(e){var t=eJ(e6(e,r),1)[0],n=eJ(e8(e,u,c),1)[0],i=f?f(e):null;return t&&n&&!i}));F({isDragAccept:m,isDragReject:g>0&&!m,isDragActive:!0,type:"setDraggedFiles"}),d&&d(e)}}).catch(function(e){return G(e)})},[r,d,G,S,M,a,o,s,l,k]),$=(0,I.useCallback)(function(e){e.preventDefault(),e.persist(),ei(e);var t=te(e);if(t&&e.dataTransfer)try{e.dataTransfer.dropEffect="copy"}catch(e){}return t&&c&&c(e),!1},[c,S]),U=(0,I.useCallback)(function(e){e.preventDefault(),e.persist(),ei(e);var t=j.current.filter(function(e){return A.current&&A.current.contains(e)}),n=t.indexOf(e.target);-1!==n&&t.splice(n,1),j.current=t,!(t.length>0)&&(F({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),te(e)&&u&&u(e))},[A,u,S]),q=(0,I.useCallback)(function(e,t){var n=[],i=[];e.forEach(function(e){var t=tu(e6(e,M),2),r=t[0],s=t[1],l=tu(e8(e,a,o),2),d=l[0],u=l[1],c=k?k(e):null;if(r&&d&&!c)n.push(e);else{var h=[s,u];
355c&&(h=h.concat(c)),i.push({file:e,errors:h.filter(function(e){return e})})}}),(!s&&n.length>1||s&&l>=1&&n.length>l)&&(n.forEach(function(e){i.push({file:e,errors:[e4]})}),n.splice(0)),F({acceptedFiles:n,fileRejections:i,type:"setFiles"}),h&&h(n,i,t),i.length>0&&f&&f(i,t),n.length>0&&p&&p(n,t)},[F,s,M,a,o,l,h,p,f,k]),K=(0,I.useCallback)(function(e){e.preventDefault(),e.persist(),ei(e),j.current=[],te(e)&&Promise.resolve(r(e)).then(function(t){(!e9(e)||S)&&q(t,e)}).catch(function(e){return G(e)}),F({type:"reset"})},[r,q,G,S]),Y=(0,I.useCallback)(function(){if(B.current){F({type:"openDialog"}),D(),window.showOpenFilePicker({multiple:s,types:T}).then(function(e){return r(e)}).then(function(e){q(e,null),F({type:"closeDialog"})}).catch(function(e){e instanceof DOMException&&("AbortError"===e.name||e.code===e.ABORT_ERR)?(R(e),F({type:"closeDialog"})):e instanceof DOMException&&("SecurityError"===e.name||e.code===e.SECURITY_ERR)?(B.current=!1,P.current?(P.current.value=null,P.current.click()):G(Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):G(e)});return}P.current&&(F({type:"openDialog"}),D(),P.current.value=null,P.current.click())},[F,D,R,v,q,G,T,s]),Z=(0,I.useCallback)(function(e){A.current&&A.current.isEqualNode(e.target)&&(" "===e.key||"Enter"===e.key||32===e.keyCode||13===e.keyCode)&&(e.preventDefault(),Y())},[A,Y]),X=(0,I.useCallback)(function(){F({type:"focus"})},[]),J=(0,I.useCallback)(function(){F({type:"blur"})},[]),Q=(0,I.useCallback)(function(){x||(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.navigator.userAgent;return -1!==e.indexOf("MSIE")||-1!==e.indexOf("Trident/")||-1!==e.indexOf("Edge/")}()?setTimeout(Y,0):Y())},[x,Y]),ee=function(e){return i?null:e},et=function(e){return w?null:ee(e)},en=function(e){return C?null:ee(e)},ei=function(e){S&&e.stopPropagation()},er=(0,I.useMemo)(function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=e.role,r=e.onKeyDown,o=e.onFocus,a=e.onBlur,s=e.onClick,l=e.onDragEnter,d=e.onDragOver,u=e.onDragLeave,c=e.onDrop,h=tm(e,ts);return tf(tf(tg({onKeyDown:et(tn(r,Z)),onFocus:et(tn(o,X)),onBlur:et(tn(a,J)),onClick:ee(tn(s,Q)),onDragEnter:en(tn(l,W)),onDragOver:en(tn(d,$)),onDragLeave:en(tn(u,U)),onDrop:en(tn(c,K)),role:"string"==typeof n&&""!==n?n:"presentation"},void 0===t?"ref":t,A),i||w?{}:{tabIndex:0}),h)}},[A,Z,X,J,Q,W,$,U,K,w,C,i]),eo=(0,I.useCallback)(function(e){e.stopPropagation()},[]),ea=(0,I.useMemo)(function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=e.onChange,i=e.onClick,r=tm(e,tl);return tf(tf({},tg({accept:M,multiple:s,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:ee(tn(n,K)),onClick:ee(tn(i,eo)),tabIndex:-1},void 0===t?"ref":t,P)),r)}},[P,n,s,K,i]);return tf(tf({},L),{},{isFocused:O&&!i,getRootProps:er,getInputProps:ea,rootRef:A,inputRef:P,open:ee(Y)})}function tw(e,t){switch(t.type){case"focus":return tf(tf({},e),{},{isFocused:!0});case"blur":return tf(tf({},e),{},{isFocused:!1});case"openDialog":return tf(tf({},tb),{},{isFileDialogActive:!0});case"closeDialog":return tf(tf({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return tf(tf({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return tf(tf({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections,isDragReject:!1});case"setDragGlobal":return tf(tf({},e),{},{isDragGlobal:t.isDragGlobal});case"reset":return tf({},tb);default:return e}}function tC(){}var tS=e.i(78598),t_=e.i(28915),tk=e.i(26460),tM={root:"m_6e45937b",loader:"m_e8eb006c",overlay:"m_df587f17"};let tT={transitionProps:{transition:"fade",duration:0},overlayProps:{backgroundOpacity:.75},zIndex:(0,tS.getDefaultZIndex)("overlay")},tD=(0,Q.createVarsResolver)((e,{zIndex:t})=>({root:{"--lo-z-index":t?.toString()}})),tR=(0,es.factory)((e,t)=>{let n=(0,er.useProps)("LoadingOverlay",tT,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,transitionProps:d,loaderProps:u,overlayProps:c,visible:h,zIndex:p,attributes:f,...g}=n,m=(0,ep.useMantineTheme)(),v=(0,eo.useStyles)({name:"LoadingOverlay",classes:tM,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:f,vars:l,varsResolver:tD}),y={...tT.overlayProps,...c};return(0,R.jsx)(tk.Transition,{transition:"fade",...d,mounted:!!h,children:e=>(0,R.jsxs)(ea.Box,{...v("root",{style:e}),ref:t,...g,children:[(0,R.jsx)(eC.Loader,{...v("loader"),unstyled:s,...u}),(0,R.jsx)(t_.Overlay,{...y,...v("overlay"),darkHidden:!0,unstyled:s,color:c?.color||m.white}),(0,R.jsx)(t_.Overlay,{...y,...v("overlay"),lightHidden:!0,unstyled:s,color:c?.color||m.colors.dark[5]})]})})});tR.classes=tM,tR.displayName="@mantine/core/LoadingOverlay";var tI=e.i(12824),tA=e.i(20826);let[tP,tE]=(0,tA.createSafeContext)("Dropzone component was not found in tree");var tL={root:"m_d46a4834",inner:"m_b85f7144",fullScreen:"m_96f6e9ad",dropzone:"m_7946116d"},tF=e.i(10172);function tO(e){return"string"!=typeof e?"":e.charAt(0).toUpperCase()+e.slice(1)}function tN(e){let t=t=>{let{children:n,...i}=(0,er.useProps)(`Dropzone${tO(e)}`,{},t),r=tE(),o=(0,tF.isElement)(n)?n:(0,R.jsx)("span",{children:n});return r[e]?(0,I.cloneElement)(o,i):null};return t.displayName=`@mantine/dropzone/${tO(e)}`,t}let tB=tN("accept"),tz=tN("reject"),tj=tN("idle"),tV={multiple:!0,maxSize:1/0,activateOnClick:!0,activateOnDrag:!0,dragEventsBubbling:!0,activateOnKeyboard:!0,useFsAccessApi:!0,variant:"light",rejectColor:"red"},tH=(0,Q.createVarsResolver)((e,{radius:t,variant:n,acceptColor:i,rejectColor:r})=>{let o=e.variantColorResolver({color:i||e.primaryColor,theme:e,variant:n}),a=e.variantColorResolver({color:r||"red",theme:e,variant:n});return{root:{"--dropzone-radius":(0,J.getRadius)(t),"--dropzone-accept-color":o.color,"--dropzone-accept-bg":o.background,"--dropzone-reject-color":a.color,"--dropzone-reject-bg":a.background}}}),tG=(0,es.factory)((e,t)=>{let n=(0,er.useProps)("Dropzone",tV,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,radiu
355s:d,disabled:u,loading:c,multiple:h,maxSize:p,accept:f,children:g,onDropAny:m,onDrop:v,onReject:y,openRef:b,name:x,maxFiles:w,autoFocus:C,activateOnClick:S,activateOnDrag:_,dragEventsBubbling:k,activateOnKeyboard:M,onDragEnter:T,onDragLeave:D,onDragOver:I,onFileDialogCancel:A,onFileDialogOpen:P,preventDropOnDocument:E,useFsAccessApi:L,getFilesFromEvent:F,validator:O,rejectColor:N,acceptColor:B,enablePointerEvents:z,loaderProps:j,inputProps:V,mod:H,attributes:G,...W}=n,$=(0,eo.useStyles)({name:"Dropzone",classes:tL,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:G,vars:l,varsResolver:tH}),{getRootProps:U,getInputProps:q,isDragAccept:K,isDragReject:Y,isDragActive:Z,open:X}=tx({onDrop:m,onDropAccepted:v,onDropRejected:y,disabled:u||c,accept:Array.isArray(f)?f.reduce((e,t)=>({...e,[t]:[]}),{}):f,multiple:h,maxSize:p,maxFiles:w,autoFocus:C,noClick:!S,noDrag:!_,noDragEventsBubbling:!k,noKeyboard:!M,onDragEnter:T,onDragLeave:D,onDragOver:I,onFileDialogCancel:A,onFileDialogOpen:P,preventDropOnDocument:E,useFsAccessApi:L,validator:O,...F?{getFilesFromEvent:F}:null});(0,tI.assignRef)(b,X);let J=Z&&K,Q=Z&&Y,ee=!J&&!Q;return(0,R.jsx)(tP,{value:{accept:J,reject:Q,idle:ee},children:(0,R.jsxs)(ea.Box,{...U(),...$("root",{focusable:!0}),...W,mod:[{accept:J,reject:Q,idle:ee,disabled:u,loading:c,"activate-on-click":S},H],children:[(0,R.jsx)(tR,{visible:c,overlayProps:{radius:d},unstyled:s,loaderProps:j}),(0,R.jsx)("input",{...q(V),name:x}),(0,R.jsx)("div",{...$("inner"),ref:t,"data-enable-pointer-events":z||void 0,children:g})]})})});tG.classes=tL,tG.displayName="@mantine/dropzone/Dropzone",tG.Accept=tB,tG.Idle=tj,tG.Reject=tz;var tW=e.i(36546),t$=e.i(5565),tU=e.i(36676);let tq={maxSize:1/0,activateOnDrag:!0,dragEventsBubbling:!0,activateOnKeyboard:!0,active:!0,zIndex:(0,tS.getDefaultZIndex)("max"),withinPortal:!0},tK=(0,es.factory)((e,t)=>{let n=(0,er.useProps)("DropzoneFullScreen",tq,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,active:d,onDrop:u,onReject:c,zIndex:h,withinPortal:p,portalProps:f,attributes:g,...m}=n,v=(0,eo.useStyles)({name:"DropzoneFullScreen",classes:tL,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:g,rootSelector:"fullScreen"}),{resolvedClassNames:y,resolvedStyles:b}=(0,tW.useResolvedStylesApi)({classNames:i,styles:a,props:n}),[x,w]=(0,I.useState)(0),[C,{open:S,close:_}]=(0,tU.useDisclosure)(!1),k=e=>{e.dataTransfer?.types.includes("Files")&&(w(e=>e+1),S())},M=()=>{w(e=>e-1)};return(0,I.useEffect)(()=>{0===x&&_()},[x]),(0,I.useEffect)(()=>{if(d)return document.addEventListener("dragenter",k,!1),document.addEventListener("dragleave",M,!1),()=>{document.removeEventListener("dragenter",k,!1),document.removeEventListener("dragleave",M,!1)}},[d]),(0,R.jsx)(t$.OptionalPortal,{...f,withinPortal:p,children:(0,R.jsx)(ea.Box,{ref:t,...v("fullScreen",{style:{opacity:+!!C,pointerEvents:C?"all":"none",zIndex:h}}),children:(0,R.jsx)(tG,{activateOnClick:!1,...m,classNames:y,styles:b,unstyled:s,className:tL.dropzone,onDrop:e=>{u?.(e),_(),w(0)},onReject:e=>{c?.(e),_(),w(0)}})})})});tK.classes=tL,tK.displayName="@mantine/dropzone/DropzoneFullScreen",tG.FullScreen=tK;let tY=({className:e,fill:t})=>(0,R.jsx)("svg",{className:e,style:{color:t},width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,R.jsx)("path",{d:"M11 16V7.85L8.4 10.45L7 9L12 4L17 9L15.6 10.45L13 7.85V16H11ZM6 20C5.45 20 4.97917 19.8042 4.5875 19.4125C4.19583 19.0208 4 18.55 4 18V15H6V18H18V15H20V18C20 18.55 19.8042 19.0208 19.4125 19.4125C19.0208 19.8042 18.55 20 18 20H6Z",fill:"currentColor"})});var tZ=e.i(45716);let tX=({className:e})=>(0,R.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,children:(0,R.jsx)("polyline",{points:"20 6 9 17 4 12"})}),tJ=({className:e})=>(0,R.jsxs)("svg",{className:e,width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,R.jsx)("path",{d:"M14 2H6C4.9 2 4 2.9 4 4V20C4 21.1 4.9 22 6 22H18C19.1 22 20 21.1 20 20V8L14 2ZM6 20V4H13V9H18V20H6Z",fill:"#E53935"}),(0,R.jsx)("text",{x:"12",y:"15.5",fontSize:"5",fontWeight:"bold",fill:"#E53935",textAnchor:"middle",fontFamily:"Arial, sans-serif",children:"PDF"})]}),tQ=({className:e})=>(0,R.jsxs)("svg",{className:e,width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,R.jsx)("path",{d:"M14 2H6C4.9 2 4 2.9 4 4V20C4 21.1 4.9 22 6 22H18C19.1 22 20 21.1 20 20V8L14 2ZM6 20V4H13V9H18V20H6Z",fill:"#2196F3"}),(0,R.jsx)("path",{d:"M8 11L9.5 17H10.5L12 12L13.5 17H14.5L16 11H15L13.75 16L12.25 11H11.75L10.25 16L9 11H8Z",fill:"#2196F3"})]}),t0=({className:e})=>(0,R.jsxs)("svg",{className:e,width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,R.jsx)("path",{d:"M14 2H6C4.9 2 4 2.9 4 4V20C4 21.1 4.9 22 6 22H18C19.1 22 20 21.1 20 20V8L14 2ZM6 20V4H13V9H18V20H6Z",fill:"#4CAF50"}),(0,R.jsx)("path",{d:"M9 11L11 14L9 17H10.5L12 15L13.5 17H15L13 14L15 11H13.5L12 13L10.5 11H9Z",fill:"#4CAF50"})]}),t1=({className:e})=>(0,R.jsxs)("svg",{className:e,width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,R.jsx)("path",{d:"M14 2H6C4.9 2 4 2.9 4 4V20C4 21.1 4.9 22 6 22H18C19.1 22 20 21.1 20 20V8L14 2ZM6 20V4H13V9H18V20H6Z",fill:"#FF6F00"}),(0,R.jsx)("path",{d:"M10 11H12.5C13.33 11 14 11.67 14 12.5C14 13.33 13.33 14 12.5 14H10V17H9V11H10ZM10 13H12.5C12.78 13 13 12.78 13 12.5C13 12.22 12.78 12 12.5 12H10V13Z",fill:"#FF6F00"})]});var t2=e.i(60872),t3=e.i(99019),t5=e.i(42993),t4=e.i(86824);
355let t6={image:["image/png","image/gif","image/jpeg","image/svg+xml","image/webp","image/avif","image/heic","image/heif"],pdf:["application/pdf"],word:["application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],excel:["application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],powerpoint:["application/vnd.ms-powerpoint","application/vnd.openxmlformats-officedocument.presentationml.presentation"]},t8={image:"Images",pdf:"PDF",word:"Word",excel:"Excel",powerpoint:"PowerPoint"},t7={checkbox:L.Checkbox,date:F.Date,email:O.Email,formGroup:N.FormGroup,formGrid:B.FormGrid,mediaBlock:z.MediaBlock,number:j.Number,radio:V.Radio,richTextBlock:H.RichTextBlock,richTextInput:G.RichTextInput,select:W.Select,text:$.Text,textarea:U.Textarea,selectNumber:q.SelectNumber,formTabsBlock:e=>{let{tabs:t,errors:n,form:i,variant:r="default",orientation:o="horizontal",placement:a="left",grow:s,justify:l,tabsColor:d,buttonsPosition:u="bottom",isLoading:c,handleReset:h,submitButtonLabel:p}=e,{tenant:f}=(0,e_.useTenant)(),{t:g}=(0,eS.useTranslations)(),m=`formTab_${i.id}`,[v,y]=(0,I.useState)(()=>localStorage.getItem(m)||t?.[0]?.label||null),b=t?.findIndex(e=>e.label===v)??0,x=b<(t?.length??0)-1,w=b>0,C=t?.[b],S=(e,n)=>{let i=e.withSubmit,r=e.withReset,o=e.withNav;if(!i&&!r&&!o)return null;let a=o&&w,s=o&&x,l=i||r,d="flex-start";return(a||s)&&(d="space-between"),(0,R.jsxs)(ew.Group,{mt:"xl",mb:"xl",gap:"sm",justify:d,className:K.default.buttonGroup,children:[a&&(0,R.jsx)(E.Button,{label:g("previous"),appearance:"secondary",el:"button",type:"button",onClick:()=>y(t[b-1].label),disabled:c}),l&&(0,R.jsxs)(ew.Group,{gap:"sm",children:[i&&(0,R.jsx)(E.Button,{label:c?void 0:p??void 0,appearance:"primary",el:"button",type:"submit",disabled:c,children:c&&(0,R.jsx)(eC.Loader,{type:"dots",size:"md",color:"white"})}),r&&(0,R.jsx)(E.Button,{label:g("reset"),appearance:"tertiary",el:"button",type:"button",onClick:h,disabled:c})]}),s&&(0,R.jsx)(E.Button,{label:g("next"),appearance:"secondary",el:"button",type:"button",onClick:()=>y(t[b+1].label),disabled:c})]})};return(0,I.useEffect)(()=>{v&&localStorage.setItem(m,v)},[v,m]),(0,I.useEffect)(()=>{if(n&&Object.keys(n).length>0){let e=t?.find(e=>e.fields?.some(e=>"name"in e&&e.name&&n[e.name]));e&&e.label!==v&&y(e.label)}},[n,t,v]),(0,R.jsxs)("div",{className:[P.default.formTabsBlock,K.default["formTabsBlock--"+d]].filter(Boolean).join(" "),children:["top"===u&&C&&S(C,b),(0,R.jsxs)(ex,{value:v,onChange:y,variant:r||"default",orientation:o||"horizontal",placement:a||"left",color:d?(e=>{if(!f?.Theme)return;let t=f.Theme;switch(e){case"primary":default:return t.cPrimary||void 0;case"secondary":return t.cSecondary||void 0;case"tertiary":return t.cTertiary||void 0;case"quaternary":return t.cQuaternary||void 0;case"quinary":return t.cQuinary||void 0;case"senary":return t.cSenary||void 0;case"white":return t.cWhite||void 0;case"black":return t.cBlack||void 0}})(d):void 0,children:[(0,R.jsx)(ex.List,{grow:s||!1,justify:l||"flex-start",children:t?.map((e,t)=>{let i,r=(i=e.fields,i?.some(e=>e.name&&n?.[e.name])||!1);return(0,R.jsx)(ex.Tab,{value:e.label,color:r?"red":void 0,className:[K.default.tab,r?K.default.errorTab:""].filter(Boolean).join(" "),rightSection:r?"â ï¸":void 0,children:e.label},t)})}),t?.map((t,n)=>(0,R.jsxs)(ex.Panel,{value:t.label,ml:"md",mr:"md",children:[(0,R.jsx)("div",{className:P.default.fieldWrap,children:t.fields?.map((t,n)=>{let i=t7?.[t.blockType];return i?(0,R.jsx)(i,{form:e.form,...t,register:e.register,errors:e.errors,control:e.control,setValue:e.setValue,getValues:e.getValues,watch:e.watch},n):null})}),("bottom"===u||"topandbottom"===u)&&S(t,n)]},n))]})]})},upload:({name:e,label:t,control:n,required:i,errors:r,width:o,tooltip:a,maxFiles:s=1,acceptedMimeTypes:l=[],form:d})=>{let{tenant:u}=(0,e_.useTenant)(),{t:c}=(0,eS.useTranslations)(),[h,p]=I.default.useState(!1),[f,g]=I.default.useState(null),m=d?.tenant?.maxUploadSizeMB||10,v=1024*m*1024;if(!d?.tenant?.uploads)return null;let y=l.length>0?l.reduce((e,t)=>
355((t6[t]||[]).forEach(t=>{e[t]=[]}),e),{}):void 0,b=l.map(e=>t8[e]).filter(Boolean).join(", "),x=[s>1?c("maxFiles",{maxFiles:s}):"",b?c("allowed",{types:b}):"",c("maxFileSize",{maxSize:m})].filter(Boolean).join(" ⢠"),w=({file:e,onRemove:t})=>{let n,[i,r]=I.default.useState(null);return I.default.useEffect(()=>{if(e&&e?.type?.startsWith("image/")&&e?.type!=="image/svg+xml"){let t=URL.createObjectURL(e);return r(t),()=>URL.revokeObjectURL(t)}},[e]),(0,R.jsxs)(eE.Paper,{className:t3.default.filePreview,radius:(0,t2.getRadius)(u.Theme?.borderRadius),withBorder:!0,children:[(0,R.jsx)("button",{type:"button",onClick:t,className:t3.default.removeButton,"aria-label":c("removeFile"),children:(0,R.jsx)(tZ.default,{className:t3.default.removeIcon})}),(0,R.jsxs)(eP.Stack,{gap:"xs",align:"center",children:[i?(0,R.jsx)(eA,{src:i,alt:e.name,className:t3.default.previewImage,radius:(0,t2.getRadius)(u.Theme?.borderRadius)}):"image/svg+xml"===(n=e?.type)?(0,R.jsx)(eM.Text,{size:"xl",fw:700,c:"dimmed",children:".svg"}):n?.includes("pdf")?(0,R.jsx)(tJ,{className:t3.default.fileIcon}):n?.includes("sheet")||n?.includes("excel")?(0,R.jsx)(t0,{className:t3.default.fileIcon}):n?.includes("presentation")||n?.includes("powerpoint")?(0,R.jsx)(t1,{className:t3.default.fileIcon}):n?.includes("word")||n?.includes("document")?(0,R.jsx)(tQ,{className:t3.default.fileIcon}):null,(0,R.jsx)(eM.Text,{size:"xs",ta:"center",lineClamp:2,style:{wordBreak:"break-word",width:"100%"},children:e?.name||c("unknownFile")})]})]})};return(0,R.jsx)(t5.Width,{width:o,children:(0,R.jsxs)("div",{className:t3.default.uploadField,children:[(0,R.jsxs)(eM.Text,{size:"sm",fw:500,mb:4,children:[t,i&&(0,R.jsx)("span",{style:{color:"red"},children:" *"}),(0,R.jsx)(t4.FieldTooltip,{tooltip:a})]}),(0,R.jsx)(ek.Controller,{name:e,control:n,rules:{required:i,validate:e=>!(i&&e?.__fileMetadata||i&&Array.isArray(e)&&e[0]?.__fileMetadata)||c("reselectAfterRefresh")},render:({field:{onChange:t,value:n}})=>{I.default.useEffect(()=>{n?.__fileMetadata||Array.isArray(n)&&n[0]?.__fileMetadata?p(!0):p(!1)},[n]);let i=((Array.isArray(n)?n.some(e=>e instanceof File):n instanceof File)?Array.isArray(n)?n.length:1:0)>=s&&!h;return(0,R.jsxs)(R.Fragment,{children:[!i&&(0,R.jsx)(tG,{onDrop:e=>{g(null),1===s?t(e[0]):t([...Array.isArray(n)?n.filter(e=>e instanceof File):[],...e].slice(0,s)),p(!1)},onReject:e=>{let t=e[0];t.errors.some(e=>"file-too-large"===e.code)?g(c("fileExceedsMaxSize",{fileName:t.file.name,maxSize:m})):t.errors.some(e=>"file-invalid-type"===e.code)?g(c("fileInvalidType",{fileName:t.file.name})):g(c("fileRejected",{fileName:t.file.name}))},maxFiles:s,maxSize:v,accept:y,className:`${t3.default.dropzone} ${r[e]?t3.default.error:""}`,radius:(0,t2.getRadius)(u.Theme?.borderRadius),children:(0,R.jsxs)(ew.Group,{justify:"center",gap:"xl",mih:220,children:[(0,R.jsx)(tG.Accept,{children:(0,R.jsx)(tX,{className:t3.default.iconAccept})}),(0,R.jsx)(tG.Reject,{children:(0,R.jsx)(tZ.default,{className:t3.default.iconReject})}),(0,R.jsx)(tG.Idle,{children:(0,R.jsx)(tY,{className:t3.default.icon})}),(0,R.jsxs)("div",{children:[(0,R.jsx)(tG.Accept,{children:(0,R.jsx)(eM.Text,{size:"xl",inline:!0,children:c("dropFilesHere")})}),(0,R.jsx)(tG.Reject,{children:(0,R.jsx)(eM.Text,{size:"xl",inline:!0,c:"red",children:c("invalidFileTypeOrSize")})}),(0,R.jsx)(tG.Idle,{children:(0,R.jsx)(eM.Text,{size:"xl",inline:!0,children:c("dragFilesHere")})}),(0,R.jsx)(eM.Text,{size:"sm",c:"dimmed",inline:!0,mt:7,children:x})]})]})}),f&&(0,R.jsx)(eM.Text,{size:"sm",c:"red",mt:"xs",children:f}),i&&(0,R.jsx)(eM.Text,{size:"sm",c:"blue",mt:"xs",children:c("maxFilesReached",{maxFiles:s})}),h&&(0,R.jsxs)(eM.Text,{size:"sm",c:"orange",mt:"xs",children:[c("filesLostRefresh"),Array.isArray(n)?n.map(e=>` ${e.name}`).join(","):` ${n.name}`]}),n&&!h&&(0,R.jsx)(eT.SimpleGrid,{cols:{base:2,sm:4},mt:"md",children:(Array.isArray(n)?n:[n]).map((e,i)=>(0,R.jsx)(w,{file:e,onRemove:()=>{Array.isArray(n)?t(n.filter((e,t)=>t!==i)):t(null)}},i))})]})}}),i&&r[e]&&(0,R.jsx)(eM.Text,{size:"sm",c:"red",mt:4,children:c("fieldRequired")})]})})}},t9=e=>e?.reduce((e,t)=>
355"checkbox"===t.blockType?{...e,[t.name]:!1}:"email"===t.blockType||"text"===t.blockType||"select"===t.blockType||"number"===t.blockType||"radio"===t.blockType?{...e,[t.name]:""}:"upload"===t.blockType?{...e,[t.name]:null}:void 0,{});var ne=e.i(86957);e.s(["default",0,e=>{let{t}=(0,eS.useTranslations)(),{tenant:n}=(0,e_.useTenant)();if("object"!=typeof e.form)return null;let{form:i,form:{id:r,bgColor:o,submitButtonLabel:a,confirmationType:s,redirect:l,confirmationMessage:d}={}}=e,u=(0,ek.useForm)({defaultValues:t9(i.fields)}),{register:c,handleSubmit:h,formState:{errors:p},control:f}=u,[g,m]=(0,I.useState)(!1),[v,y]=(0,I.useState)(),[b,x]=(0,I.useState)(),w=`form_draft_${r}`,C=()=>{window.confirm(t("resetFormConfirm"))&&(u.reset(),localStorage.removeItem(w))};(0,I.useEffect)(()=>{let e=localStorage.getItem(w);if(e)try{let t=JSON.parse(e);Object.keys(t).forEach(e=>{u.setValue(e,t[e])})}catch(e){console.warn("Failed to load saved form data",e)}},[w]),(0,I.useEffect)(()=>{let e=u.watch(e=>{try{let t=Object.entries(e).reduce((e,[t,n])=>n instanceof File?{...e,[t]:{__fileMetadata:!0,name:n.name}}:Array.isArray(n)&&n[0]instanceof File?{...e,[t]:n.map(e=>({__fileMetadata:!0,name:e.name}))}:{...e,[t]:n},{});localStorage.setItem(w,JSON.stringify(t))}catch(e){console.warn("Failed to save form data",e)}});return()=>e.unsubscribe()},[u.watch,w]);let S=(0,I.useCallback)(e=>{(async()=>{var n;let o;if(e._honeypot){y(!0),localStorage.removeItem(w);return}m(!0),n=async n=>{let o;x(void 0);let a=Object.values(e).some(e=>e instanceof File||Array.isArray(e)&&e[0]instanceof File),d={"x-recaptcha-v3":n};if(a){let t=new FormData;t.append("form",r||""),t.append("locale",(0,A.getLang)()||"nl");let n=new Map,a=e=>{e?.forEach(e=>{if(e.name){let t=e.selectType||e.checkboxType||e.dateType||e.uploadType||e.richTextInputType||e.type;t&&n.set(e.name,t)}e.fields&&a(e.fields),e.tabs&&e.tabs.forEach(e=>{e.fields&&a(e.fields)})})};a(i.fields||[]);let s=[];Object.entries(e).filter(([e])=>"_honeypot"!==e).forEach(([e,i])=>{if(i instanceof File)t.append(e,i),s.push({field:e,value:i,type:"upload"});else if(Array.isArray(i)&&i[0]instanceof File)i.forEach(n=>t.append(e,n)),s.push({field:e,value:i,type:"upload"});else{let r=n.get(e)||"text",o=Array.isArray(i)?JSON.stringify(i):String(i??"");
355t.append(e,o),s.push({field:e,value:o,type:r})}}),t.append("submissionData",JSON.stringify(s)),o=t}else{d["Content-Type"]="application/json";let t=new Map,n=e=>{e?.forEach(e=>{if(e.name){let n=e.selectType||e.checkboxType||e.dateType||e.uploadType||e.richTextInputType||e.type;n&&t.set(e.name,n)}e.fields&&n(e.fields),e.tabs&&e.tabs.forEach(e=>{e.fields&&n(e.fields)})})};n(i.fields||[]),o=JSON.stringify({form:r,submissionData:Object.entries(e).filter(([e])=>"_honeypot"!==e).map(([e,n])=>{let i=t.get(e)||"text";return{field:e,value:Array.isArray(n)?JSON.stringify(n):n??"",type:i}}),locale:(0,A.getLang)()||"nl"})}try{let e,n,r,a=await fetch("https://app.axio-cms.com/api/form-submissions",{method:"POST",headers:d,body:o}),c=await a.json();if(a.status>=400){m(!1),x({status:c.status,message:c.error||c.errors?.[0]?.message||t("internalServerError")});return}e={},n=u.getValues(),(r=t=>{t&&t.forEach(t=>{let i=t.name||t.id;t.preserveOnSubmit&&i&&void 0!==n[i]&&(e[i]=n[i]),t.tabs&&r(t.tabs),t.fields&&r(t.fields)})})(i.fields),Object.keys(e).length>0?(localStorage.setItem(w,JSON.stringify(e)),u.reset({...t9(i.fields),...e})):(localStorage.removeItem(w),u.reset(t9(i.fields))),m(!1),y(!0),"redirect"===s&&l?.url&&(window.location.href=l.url)}catch(e){console.warn(e),m(!1),x({message:t("somethingWentWrong")})}},(o=window).grecaptcha&&o.grecaptcha.ready(function(){o.grecaptcha.execute("6Lc800IrAAAAAHcAi-nIfFozySwOTP467NkIcJRT",{action:"submit"}).then(function(e){n(e)})})})()},[r,l,s,i]);return(0,R.jsxs)(eE.Paper,{radius:(0,t2.getRadius)(n.Theme?.borderRadius),bg:"transparent",className:[P.default.form,o?P.default[`form--${o}`]:"transparent",v&&P.default.hasSubmitted].filter(Boolean).join(" "),children:[v&&"message"===s&&(0,R.jsx)(ne.default,{className:P.default.confirmationMessage,content:d,excludeFromToc:!0}),!v&&(0,R.jsxs)("form",{id:r,onSubmit:h(S),children:[(0,R.jsx)("input",{type:"text",name:"_honeypot",style:{position:"absolute",left:"-9999px",width:"1px",height:"1px"},tabIndex:-1,autoComplete:"off","aria-hidden":"true"}),(0,R.jsx)("div",{className:P.default.fieldWrap,children:i&&i.fields&&i.fields.map((e,t)=>{let n=t7?.[e.blockType];return n?(0,R.jsx)(I.default.Fragment,{children:(0,R.jsx)(n,{form:i,...e,...u,register:c,errors:p,control:f,isLoading:g,handleReset:C,submitButtonLabel:a})},t):null})}),!i.fields?.some(e=>"formTabsBlock"===e.blockType&&e.tabs?.some(e=>e.withSubmit||e.withReset))&&(0,R.jsxs)("div",{className:P.default.buttons,children:[(0,R.jsx)(E.Button,{label:g?void 0:a??void 0,appearance:"primary",el:"button",type:"submit",disabled:g,children:g&&(0,R.jsx)(eC.Loader,{type:"dots",size:"md",color:"white"})}),(0,R.jsx)(E.Button,{label:t("reset"),appearance:"tertiary",el:"button",type:"button",onClick:C,disabled:g})]}),b&&(0,R.jsx)("div",{children:`${b.status||"500"}: ${b.message||""}`})]})]})}],52999),e.s(["GridBlock",()=>nS],4352);var nt=e.i(91736),nn=e.i(14932),ni=e.i(52487);let[nr,no]=(0,tA.createSafeContext)("Grid component was not found in tree");var na={container:"m_8478a6da",root:"m_410352e9",inner:"m_dee7bd2f",col:"m_96bdd299"},ns=e.i(87481),nl=e.i(78720),nd=e.i(85250),nu=e.i(55227),nc=e.i(12493);let nh=(e,t)=>"content"===e?"auto":"auto"===e?"0rem":e?`${100/(t/e)}%`:void 0,np=(e,t,n)=>n||"auto"===e?"100%":"content"===e?"unset":nh(e,t),nf=(e,t)=>{if(e)return"auto"===e||t?"1":"auto"},ng=(e,t)=>0===e?"0":e?`${100/(t/e)}%`:void 0;function nm({span:e,order:t,offset:n,selector:i}){let r=(0,ep.useMantineTheme)(),o=no(),a=o.breakpoints||r.breakpoints,s=void 0===(0,nu.getBaseValue)(e)?12:(0,nu.getBaseValue)(e),l=(0,nl.filterProps)({"--col-order":(0,nu.getBaseValue)(t)?.toString(),"--col-flex-grow":nf(s,o.grow),"--col-flex-basis":nh(s,o.columns),"--col-width":"content"===s?"auto":void 0,"--col-max-width":np(s,o.columns,o.grow),"--col-offset":ng((0,nu.getBaseValue)(n),o.columns)}),d=(0,ns.keys)(a).reduce((i,r)=>(i[r]||(i[r]={}),"object"==typeof t&&void 0!==t[r]&&(i[r]["--col-order"]=t[r]?.toString()),"object"==typeof e&&void 0!==e[r]&&(i[r]["--col-flex-grow"]=nf(e[r],o.grow),i[r]["--col-flex-basis"]=nh(e[r],o.columns),i[r]["--col-width"]="content"===e[r]?"auto":void 0,i[r]["--col-max-width"]=np(e[r],o.columns,o.grow)),"object"==typeof n&&void 0!==n[r]&&(i[r]["--col-offset"]=ng(n[r],o.columns)),i),{}),u=(0,nd.getSortedBreakpoints)((0,ns.keys)(d),a).filter(e=>(0,ns.keys)(d[e.value]).length>0).map(e=>({query:"container"===o.type?`mantine-grid (min-width: ${a[e.value]})`:`(min-width: ${a[e.value]})`,styles:d[e.value]}));return(0,R.jsx)(nc.InlineStyles,{styles:l,media:"container"===o.type?void 0:u,container:"container"===o.type?u:void 0,selector:i})}let nv={span:12},ny=(0,es.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,span:s,order:l,offset:d,...u}=(0,er.useProps)("GridCol",nv,e),c=no(),h=(0,ni.useRandomClassName)();return(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(nm,{selector:`.${h}`,span:s,order:l,offset:d}),(0,R.jsx)(ea.Box,{ref:t,...c.getStyles("col",{className:(0,ee.default)(i,h),style:r,classNames:n,styles:o}),...u})]})});function nb({gutter:e,selector:t,breakpoints:n,type:i}){let r=(0,ep.useMantineTheme)(),o=n||r.breakpoints,a=(0,nl.filterProps)({"--grid-gutter":(0,J.getSpacing)((0,nu.getBaseValue)(e))}),s=(0,ns.keys)(o).reduce((t,n)=>(t[n]||(t[n]={}),"object"==typeof e&&void 0!==e[n]&&(t[n]["--grid-gutter"]=(0,J.getSpacing)(e[n])),t),{}),l=(0,nd.getSortedBreakpoints)((0,ns.keys)(s),o).filter(e=>(0,ns.keys)(s[e.value]).length>0).map(e=>({query:"container"===i?`mantine-grid (min-width: ${o[e.value]})`:`(min-width: ${o[e.value]})`,styles:s[e.value]}));return(0,R.jsx)(nc.InlineStyles,{styles:a,media:"container"===i?void 0:l,container:"container"===i?l:void 0,selector:t})}ny.classes=na,ny.displayName="@mantine/core/GridCol";let nx={gutter:"md",grow:!1,columns:12},nw=(0,Q.createVarsResolver)((e,{justify:t,align:n,overflow:i})=>({root:{"--grid-justify":t,"--grid-align":n,"--grid-overflow":i}})),nC=(0,es.factory)((e,t)=>{let n=(0,er.useProps)("Grid",nx,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,grow:d,gutter:u,columns:c,align:h,justify:p,children:f,breakpoints:g,type:m,attributes:v,...y}=n,b=(0,eo.useStyles)({name:"Grid",classes:na,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:v,vars:l,varsResolver:nw}),x=(0,ni.useRandomClassName)();return"container"===m&&g?(0,R.jsxs)(nr,{value:{getStyles:b,grow:d,columns:c,breakpoints:g,type:m},children:[(0,R.jsx)(nb,{selector:`.${x}`,...n}),(0,R.jsx)("div",{...b("container"),children:(0,R.jsx)(ea.Box,{ref:t,...b("root",{className:x}),...y,children:(0,R.jsx)("div",{...b("inner"),children:f})})})]}):(0,R.jsxs)(nr,{value:{getStyles:b,grow:d,columns:c,breakpoints:g,type:m},children:[(0,R.jsx)(nb,{selector:`.${x}`,...n}),(0,R.jsx)(ea.Box,{ref:t,...b("root",{className:x}),...y,children:(0,R.jsx)("div",{...b("inner"),children:f})})]})});nC.classes=na,nC.displayName="@mantine/core/Grid",nC.Col=ny;let nS=e=>{let{gridItems:t,maxColumns:n,gridGap:i,introText:r}=e,{tenant:o}=(0,e_.useTenant)(),a=i?"none"==i?0:i:"md",s=0===a,l=s?(0,t2.getRadius)(o.Theme?.borderRadius):0,d=[nt.default.grid,nt.default[`grid--${l}
355`],s?nt.default["grid--glued"]:""].filter(Boolean).join(" ");return(0,R.jsxs)("div",{className:nt.default.gridContainer,"data-block":"grid",...e.blockDataId?{"data-block-id":e.blockDataId}:{},children:[r&&(0,R.jsx)(ne.default,{content:r,className:nt.default.introText}),(0,R.jsx)(nC,{breakpoints:{xs:"360px",sm:"768px",md:"1024px",lg:"1440px",xl:"1920px"},type:"container",gutter:a,className:d,children:t&&t.length>0&&t.map((e,t)=>{let i=e.layout[0],{blockName:r,blockType:o}=i,a=(0,nn.getBlockBackgroundColor)(i),l={...i,inGrid:!0};if(o&&o in nn.blockComponents){let e=nn.blockComponents[o];if(e){let d=o.replace(/Block$/,"").replace(/([A-Z])/g,"-$1").toLowerCase().replace(/^-/,"");return(0,R.jsx)(nC.Col,{span:{base:12,sm:n?12/({one:1,two:2,three:3,four:4})[n]:12},className:[nt.default.item,["mediaBlock","echartsBlock"].includes(o)?nt.default["item--align"]:""].filter(Boolean).join(" "),children:(0,R.jsx)("div",{className:nt.default["block-wrapper"],"data-block":d,...i.blockDataId?{"data-block-id":i.blockDataId}:{},children:(0,R.jsx)(e,{...s?{padding:"xl"}:{withRadius:!0},...r?{id:r}:{},...a?{bgColor:a}:{},...l})})},t)}}})})]})};var n_=e.i(17444),nk=e.i(57012);e.s(["ImageAndTextBlock",0,e=>{let{richText:t,media:n,imagePosition:i,withRadius:r=!0,ITMediafit:o}=e,{tenant:a}=(0,e_.useTenant)();return(0,R.jsx)("div",{className:nk.default["image-text-block"],"data-image-position":i,children:(0,R.jsx)("div",{children:(0,R.jsxs)(eE.Paper,{radius:r?(0,t2.getRadius)(a.Theme?.borderRadius):0,className:nk.default["image-text-block__content"],bg:"transparent",children:[(0,R.jsx)(eE.Paper,{radius:r?(0,t2.getRadius)(a.Theme?.borderRadius):0,shadow:" var(--box-sha
355dow-hero)",className:nk.default["image-text-block__text"],children:(0,R.jsx)(ne.default,{content:t,withRadius:r})}),n&&(0,R.jsx)(eE.Paper,{radius:r?(0,t2.getRadius)(a.Theme?.borderRadius):0,className:nk.default["image-text-block__img-wrapper"],bg:"transparent",children:(0,R.jsx)(n_.Media,{className:nk.default["image-text-block__img"],resource:n,mediaFit:o,sizes:"(min-width: 768px) 50vw, 100vw"})})]})})})}],94576);var nM=e.i(86577),nT=e.i(67484);e.s(["LinksBlock",0,e=>{let{links:t,linksPosition:n,bgColor:i,colorTypography:r,linksWithArrowIcon:o,className:a}=e;return t&&0!==t.length?(0,R.jsx)("div",{className:[a,nT.default.linksBlock,nT.default[`linksBlock--${n}`],nT.default[`linksBlock--${i}`]].join(" "),children:t.map((e,t)=>(0,R.jsx)("div",{className:nT.default.linkWrapper,children:(0,R.jsx)(nM.CMSLink,{...e.link,colorTypography:r,linksWithArrowIcon:o})},t))}):null}],4698);var nD=e.i(69941),nR=e.i(44700);function nI(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&0>t.indexOf(i)&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var r=0,i=Object.getOwnPropertySymbols(e);r<i.length;r++)0>t.indexOf(i[r])&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]]);return n}function nA(e,t,n,i){return new(n||(n=Promise))(function(r,o){function a(e){try{l(i.next(e))}catch(e){o(e)}}function s(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?r(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(a,s)}l((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;let nP=()=>{},nE=!1;async function nL(e){if(nE||nP("No options were set before calling importLibrary. Make sure to configure the loader using setOptions()."),!window?.google?.maps?.importLibrary)throw Error("google.maps.importLibrary is not installed.");return await google.maps.importLibrary(e)}let nF="NOT_LOADED",nO="LOADING",nN="LOADED",nB=["gmp_visgl_reactgooglemaps_v1.8.3"],nz=I.default.createContext(null),nj=nF,nV=new Set;function nH(e){e!==nj&&(nj=e,nV.forEach(e=>e(nj)))}let nG=e=>{let{children:n}=e,i=nI(e,["children"]),{mapInstances:r,addMapInstance:o,removeMapInstance:a,clearMapInstances:s}=function(){let[e,t]=(0,I.useState)({});return{mapInstances:e,addMapInstance:(e,n="default")=>{t(t=>Object.assign(Object.assign({},t),{[n]:e}))},removeMapInstance:(e="default")=>{t(t=>(t[e],nI(t,["symbol"==typeof e?e:e+""])))},clearMapInstances:()=>{t({})}}}(),{map3dInstances:l,addMap3DInstance:d,removeMap3DInstance:u,clearMap3DInstances:c}=function(){let[e,t]=(0,I.useState)({});return{map3dInstances:e,addMap3DInstance:(e,n="default")=>{t(t=>Object.assign(Object.assign({},t),{[n]:e}))},removeMap3DInstance:(e="default")=>{t(t=>(t[e],nI(t,["symbol"==typeof e?e:e+""])))},clearMap3DInstances:()=>{t({})}}}(),{status:h,loadedLibraries:p,importLibrary:f}=function(e){let{onLoad:n,onError:i,apiKey:r,version:o,libraries:a=[],region:s,language:l,authReferrerPolicy:d,channel:u,solutionChannel:c,fetchAppCheckToken:h}=e,[p,f]=(0,I.useState)(nj),[g,m]=(0,I.useReducer)((e,t)=>e[t.name]?e:Object.assign(Object.assign({},e),{[t.name]:t.value}),{}),v=(0,I.useMemo)(()=>JSON.stringify({apiKey:r,version:o,libraries:a.join(","),region:s,language:l,authReferrerPolicy:d,channel:u,solutionChannel:c}),[r,o,a,s,l,d,u,c]),y=(0,I.useCallback)(e=>nA(this,void 0,void 0,function*(){if(g[e])return g[e];let t=yield nL(e);return m({name:e,value:t}),t}),[g]);return(0,I.useEffect)(()=>(nV.add(f),f(nj),()=>{nV.delete(f)}),[]),(0,I.useEffect)(()=>{nA(this,void 0,void 0,function*(){var e,h;try{t&&t!==v&&console.warn("The Google Maps JavaScript API has already been loaded with different parameters. The new parameters will be ignored. If you need to use different parameters, please refresh the page.");let i=["core","maps",...a];if(null==(h=null==(e=window.google)?void 0:e.maps)?void 0:h.importLibrary){t||nH(nN),yield Promise.all(i.map(e=>y(e))),n&&n();return}if(nj===nO||nj===nN){nj===nN&&n&&n();return}t=v,nH(nO);let p=Object.fromEntries(Object.entries({key:r,v:o,libraries:a,region:s,language:l,authReferrerPolicy:d}).filter(([,e])=>void 0!==e));void 0!==u&&u>=0&&u<=999&&(p.channel=String(u)),void 0===c?p.solutionChannel="GMP_visgl_rgmlibrary_v1_default":""!==c&&(p.solutionChannel=c),function(e){if(nE)return nP(`The setOptions() function should only be called once. The options passed to the additional call (${JSON.stringify(e)}) will be ignored.`);(function(e){var t,n,i,r,o,a,s,l,d,u,c;let h=!!window.google?.maps?.importLibrary;h&&JSON.stringify(e);h||(r="google",o="importLibrary",a=document,d=(l=(s=window)[r]||(s[r]={})).maps||(l.maps={}),u=new Set,c=new URLSearchParams,d[o]?console.warn("The Google Maps JavaScript API only loads once. Ignoring:",e):d[o]=(s,...l)=>u.add(s)&&(t||(t=new Promise(async(o,s)=>{for(i in await (n=a.createElement("script")),c.set("libraries",[...u]+""),e)c.set(i.replace(/[A-Z]/g,e=>"_"+e[0].toLowerCase()),e[i]);c.set("callback",r+".maps.__ib__"),n.src="https://maps.googleapis.com/ma
355ps/api/js?"+c,d.__ib__=o,n.onerror=()=>t=s(Error("The Google Maps JavaScript API could not load.")),n.nonce=a.querySelector("script[nonce]")?.nonce||"",a.head.append(n)}))).then(()=>d[o](s,...l)))})(e),nE=!0}(p),yield Promise.all(i.map(e=>y(e))),nH(nN),n&&n()}catch(e){nH("FAILED"),i?i(e):console.error("The Google Maps JavaScript API failed to load.",e)}})},[v,n,i,y,a]),(0,I.useEffect)(()=>{if(p!==nN)return;let e=google.maps.Settings.getInstance();h?e.fetchAppCheckToken=h:e.fetchAppCheckToken&&(e.fetchAppCheckToken=null)},[p,h]),{status:p,loadedLibraries:g,importLibrary:y}}(i),g=(0,I.useMemo)(()=>i.disableUsageAttribution?null:nB,[i.disableUsageAttribution]),m=(0,I.useMemo)(()=>({mapInstances:r,addMapInstance:o,removeMapInstance:a,clearMapInstances:s,map3dInstances:l,addMap3DInstance:d,removeMap3DInstance:u,clearMap3DInstances:c,status:h,loadedLibraries:p,importLibrary:f,internalUsageAttributionIds:g}),[r,o,a,s,l,d,u,c,h,p,f,g]);return I.default.createElement(nz.Provider,{value:m},n)},nW={onBoundsChanged:"bounds_changed",onCenterChanged:"center_changed",onClick:"click",onContextmenu:"contextmenu",onDblclick:"dblclick",onDrag:"drag",onDragend:"dragend",onDragstart:"dragstart",onHeadingChanged:"heading_changed",onIdle:"idle",onIsFractionalZoomEnabledChanged:"isfractionalzoomenabled_changed",onMapCapabilitiesChanged:"mapcapabilities_changed",onMapTypeIdChanged:"maptypeid_changed",onMousemove:"mousemove",onMouseout:"mouseout",onMouseover:"mouseover",onProjectionChanged:"projection_changed",onRenderingTypeChanged:"renderingtype_changed",onTilesLoaded:"tilesloaded",onTiltChanged:"tilt_changed",onZoomChanged:"zoom_changed",onCameraChanged:"bounds_changed"},n$=["bounds_changed","center_changed","heading_changed","tilt_changed","zoom_changed"],nU=["click","contextmenu","dblclick","mousemove","mouseout","mouseover"],nq=Object.keys(nW);function nK(e,t){let n=(0,I.useRef)(e);return t(e,n.current)||(n.current=e),n.current}function nY(e,t){var n;n=nR.default,(0,I.useEffect)(e,[nK(t,n)])}let nZ=new Set(["backgroundColor","clickableIcons","controlSize","disableDefaultUI","disableDoubleClickZoom","draggable","draggableCursor","draggingCursor","fullscreenControl","fullscreenControlOptions","gestureHandling","headingInteractionEnabled","isFractionalZoomEnabled","keyboardShortcuts","mapTypeControl","mapTypeControlOptions","mapTypeId","maxZoom","minZoom","noClear","panControl","panControlOptions","restriction","rotateControl","rotateControlOptions","scaleControl","scaleControlOptions","scrollwheel","streetView","streetViewControl","streetViewControlOptions","styles","tiltInteractionEnabled","zoomControl","zoomControlOptions"]);function nX(){var e;return(null==(e=(0,I.useContext)(nz))?void 0:e.status)||nF}function nJ(e,t){if(!e||!t)return!1;let n=nQ(e),i=nQ(t);return n.lat===i.lat&&n.lng===i.lng}function nQ(e){return e&&"object"==typeof e&&"lat"in e&&"lng"in e&&Number.isFinite(e.lat)&&Number.isFinite(e.lng)?e:e.toJSON()}function n0(e){if("north"in e&&"south"in e&&"east"in e&&"west"in e)return e;
355let t=e.getNorthEast().toJSON(),n=e.getSouthWest().toJSON();return{north:t.lat,east:t.lng,south:n.lat,west:n.lng}}function n1(e,t){if(!e||!t)return e===t;let n="getArray"in t?t.getArray():t;if(e.length!==n.length)return!1;for(let t=0;t<e.length;t++)if(!nJ(e[t],n[t]))return!1;return!0}let n2=()=>I.default.createElement("div",{style:{position:"absolute",top:0,left:0,bottom:0,right:0,zIndex:999,display:"flex",flexFlow:"column nowrap",textAlign:"center",justifyContent:"center",fontSize:".8rem",color:"rgba(0,0,0,0.6)",background:"#dddddd",padding:"1rem 1.5rem"}},I.default.createElement("h2",null,"Error: AuthFailure"),I.default.createElement("p",null,"A problem with your API key prevents the map from rendering correctly. Please make sure the value of the ",I.default.createElement("code",null,"APIProvider.apiKey")," prop is correct. Check the error-message in the console for further details."));function n3(){let[e,t]=(0,I.useState)(null);return[e,(0,I.useCallback)(e=>t(e),[t])]}function n5(){let[,e]=(0,I.useReducer)(e=>e+1,0);return e}class n4{static has(e){return this.entries[e]&&this.entries[e].length>0}static pop(e){return this.entries[e]&&this.entries[e].pop()||null}static push(e,t){this.entries[e]||(this.entries[e]=[]),this.entries[e].push(t)}}n4.entries={};let n6=I.default.createContext(null),n8=e=>{let t,n,i,r,o,a,{children:s,id:l,className:d,style:u}=e,c=(0,I.useContext)(nz),h=nX();if(!c)throw Error("<Map> can only be used inside an <ApiProvider> component.");let[p,f,g]=function(e,t){let n,i,r=nX()===nN,[o,a]=(0,I.useState)(null),[s,l]=n3(),d=(n=n5(),i=(0,I.useRef)({center:{lat:0,lng:0},heading:0,tilt:0,zoom:0}),(0,I.useEffect)(()=>{if(!o)return;let e=google.maps.event.addListener(o,"bounds_changed",()=>{let e,t,r,a,s;e=o.getCenter(),t=o.getZoom(),r=o.getHeading()||0,a=o.getTilt()||0,s=o.getBounds(),e&&s&&Number.isFinite(t)||console.warn("[useTrackedCameraState] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),Object.assign(i.current,{center:(null==e?void 0:e.toJSON())||{lat:0,lng:0},zoom:t||0,heading:r,tilt:a}),n()});return()=>e.remove()},[o,n]),i),{id:u,defaultBounds:c,defaultCenter:h,defaultZoom:p,defaultHeading:f,defaultTilt:g,reuseMaps:m,renderingType:v,colorScheme:y}=e,b=nI(e,["id","defaultBounds","defaultCenter","defaultZoom","defaultHeading","defaultTilt","reuseMaps","renderingType","colorScheme"]),x=void 0!==e.zoom||void 0!==e.defaultZoom,w=void 0!==e.center||void 0!==e.defaultCenter;c||x&&w||console.warn("<Map> component is missing configuration. You have to provide zoom and center (via the `zoom`/`defaultZoom` and `center`/`defaultCenter` props) or specify the region to show using `defaultBounds`. See https://visgl.github.io/react-google-maps/docs/api-reference/components/map#required"),!b.center&&h&&(b.center=h),!b.zoom&&Number.isFinite(p)&&(b.zoom=p),!b.heading&&Number.isFinite(f)&&(b.heading=f),!b.tilt&&Number.isFinite(g)&&(b.tilt=g);let C=b.internalUsageAttributionIds;for(let e of(null==C?b.internalUsageAttributionIds=t.internalUsageAttributionIds:b.internalUsageAttributionIds=[...t.internalUsageAttributionIds||[],...C],Object.keys(b)))void 0===b[e]&&delete b[e];let S=(0,I.useRef)(void 0);return(0,I.useEffect)(()=>{let n,i;if(!s||!r)return;let{addMapInstance:o,removeMapInstance:l}=t,{mapId:h}=e,p=`${h||"default"}:${v||"default"}:${y||"LIGHT"}`;if(m&&n4.has(p)?(n=(i=n4.pop(p)).getDiv(),s.appendChild(n),i.setOptions(b),setTimeout(()=>i.moveCamera({}),0)):((n=document.createElement("div")).style.height="100%",s.appendChild(n),i=new google.maps.Map(n,Object.assign(Object.assign(Object.assign({},b),v?{renderingType:v}:{}),y?{colorScheme:y}:{}))),a(i),o(i,u),c){let{padding:e}=c,t=nI(c,["padding"]);i.fitBounds(t,e)}else x&&w||i.fitBounds({east:180,west:-180,south:-90,north:90});if(S.current){let{mapId:e,cameraState:t}=S.current;e!==h&&i.moveCamera(t)}return()=>{S.current={mapId:h,cameraState:d.current},n.remove(),m?n4.push(p,i):google.maps.event.clearInstanceListeners(i),a(null),l(u)}},[s,r,u,e.mapId,e.renderingType,e.colorScheme]),[o,l,d]}(e,c);for(let s of(t=e.center?nQ(e.center):null,n=null,i=null,t&&Number.isFinite(t.lat)&&Number.isFinite(t.lng)&&(n=t.lat,i=t.lng),r=Number.isFinite(e.zoom)?e.zoom:null,o=Number.isFinite(e.heading)?e.heading:null,a=Number.isFinite(e.tilt)?e.tilt:null,(0,I.useLayoutEffect)(()=>
355{if(!p)return;let e={},t=!1;null!==n&&null!==i&&(g.current.center.lat!==n||g.current.center.lng!==i)&&(e.center={lat:n,lng:i},t=!0),null!==r&&g.current.zoom!==r&&(e.zoom=r,t=!0),null!==o&&g.current.heading!==o&&(e.heading=o,t=!0),null!==a&&g.current.tilt!==a&&(e.tilt=a,t=!0),t&&p.moveCamera(e)}),nq)){let t=e[s],n=nW[s];(0,I.useEffect)(()=>{if(!p||!t)return;let e=google.maps.event.addListener(p,n,e=>{t(function(e,t,n){var i;let r={type:e,map:t,detail:{},stoppable:!1,stop:()=>{}};if(n$.includes(e)){let e=t.getCenter(),n=t.getZoom(),i=t.getHeading()||0,o=t.getTilt()||0,a=t.getBounds();return e&&a&&Number.isFinite(n)||console.warn("[createEvent] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),r.detail={center:(null==e?void 0:e.toJSON())||{lat:0,lng:0},zoom:n||0,heading:i,tilt:o,bounds:(null==a?void 0:a.toJSON())||{north:90,east:180,south:-90,west:-180}},r}if(nU.includes(e)){if(!n)throw Error("[createEvent] mouse events must provide a srcEvent");return r.domEvent=n.domEvent,r.stoppable=!0,r.stop=()=>n.stop(),r.detail={latLng:(null==(i=n.latLng)?void 0:i.toJSON())||null,placeId:n.placeId},r}return r}(n,p,e))});return()=>e.remove()},[p,n,t])}let m={};for(let t of Object.keys(e))nZ.has(t)&&(m[t]=e[t]);nY(()=>{p&&p.setOptions(m)},[m]);let v=function(e,t){let{viewport:n,viewState:i}=t;return(0,I.useLayoutEffect)(()=>{if(!e||!i)return;let{latitude:t,longitude:n,bearing:r,pitch:o,zoom:a}=i;e.moveCamera({center:{lat:t,lng:n},heading:r,tilt:o,zoom:a+1})},[e,i]),!!n}(p,e),y=!!e.controlled;(0,I.useEffect)(()=>{if(p)return v&&p.setOptions({disableDefaultUI:!0}),(v||y)&&p.setOptions({gestureHandling:"none",keyboardShortcuts:!1}),()=>{p.setOptions({gestureHandling:e.gestureHandling,keyboardShortcuts:e.keyboardShortcuts})}},[p,v,y,e.gestureHandling,e.keyboardShortcuts]);let b=e.center?nQ(e.center):null,x=null,w=null;b&&Number.isFinite(b.lat)&&Number.isFinite(b.lng)&&(x=b.lat,w=b.lng);let C=(0,I.useMemo)(()=>{var t,n,i;return{center:{lat:null!=x?x:0,lng:null!=w?w:0},zoom:null!=(t=e.zoom)?t:0,heading:null!=(n=e.heading)?n:0,tilt:null!=(i=e.tilt)?i:0}},[x,w,e.zoom,e.heading,e.tilt]);(0,I.useLayoutEffect)(()=>{if(!p||!y)return;p.moveCamera(C);let e=p.addListener("bounds_changed",()=>{p.moveCamera(C)});return()=>e.remove()},[p,y,C]);let S=(0,I.useMemo)(()=>Object.assign({width:"100%",height:"100%",position:"relative",zIndex:v?-1:0},u),[u,v]),_=(0,I.useMemo)(()=>({map:p}),[p]);return"AUTH_FAILURE"===h?I.default.createElement("div",{style:Object.assign({position:"relative"},d?{}:S),className:d},I.default.createElement(n2,null)):I.default.createElement("div",Object.assign({ref:f,"data-testid":"map",style:d?void 0:S,className:d},l?{id:l}:{}),p?I.default.createElement(n6.Provider,{value:_},s):null)};n8.deckGLViewProps=!0;let n7=new Set;function n9(...e){let t=JSON.stringify(e);n7.has(t)||(n7.add(t),console.error(...e))}let ie=(e=null)=>{let t=(0,I.useContext)(nz),{map:n}=(0,I.useContext)(n6)||{};if(null===t)return n9("useMap(): failed to retrieve APIProviderContext. Make sure that the <APIProvider> component exists and that the component you are calling `useMap()` from is a sibling of the <APIProvider>."),null;let{mapInstances:i}=t;return null!==e?i[e]||null:n||i.default||null};function it(e){let t=nX()===nN,n=(0,I.useContext)(nz);return(0,I.useEffect)(()=>{t&&n&&n.importLibrary(e)},[t,n,e]),(null==n?void 0:n.loadedLibraries[e])||null}let{useLayoutEffect:ii,useRef:ir}=I,io=null!=(f=I.useInsertionEffect)?f:ii;function ia(){throw Error("useEffectEvent: invalid call during rendering.")}let is=function(e){let t=ir(ia);return io(()=>{t.current=e},[e]),(...e)=>t.current(...e)},il=()=>{};function id(e,t,n){let i=is(null!=n?n:il),r=!!n;(0,I.useEffect)(()=>{if(!e||!t||!r)return;let n=google.maps.event.addListener(e,t,i);return()=>n.remove()},[e,t,r])}function iu(e,t,n){(0,I.useEffect)(()=>{e&&(e[t]=n)},[e,t,n])}let ic=()=>{};function ih(e,t,n){let i=is(null!=n?n:ic),r=!!n;(0,I.useEffect)(()=>{if(e&&t&&r)return e.addEventListener(t,i),()=>e.removeEventListener(t,i)},[e,t,r])}let ip=new class{constructor(){this.renderedStyles=new Set,this.styleElement=null}getStyleElement(){return this.styleElement||(this.styleElement=document.createElement("style"),this.styleElement.setAttribute("data-rgm-anchor-styles",""),document.head.appendChild(this.styleElement)),this.styleElement}addAdvancedMarkerPointerEventsOverwrite(){if(this.renderedStyles.has("marker-pointer-events"))return;let e=this.getStyleElement();e.textContent+=` 356 gmp-advanced-marker[data-origin='rgm'] { 357 pointer-events: none !important; 358 } 359 `,this.renderedStyles.add("marker-pointer-events")}cleanup(){this.styleElement&&(this.styleElement.remove(),this.styleElement=null,this.renderedStyles.clear())}},ig=I.default.createContext(null),im=["50%","100%"],iv=(0,I.forwardRef)((e,t)=>{let{children:n,style:i,className:r,anchorPoint:o}=e,[a,s]=function(e){var t,n,i,r,o;let[a,s]=(0,I.useState)(null),[l,d]=(0,I.useState)(null),u=ie(),c=it("marker"),{children:h,onClick:p,className:f,onMouseEnter:g,onMouseLeave:m,onDrag:v,onDragStart:y,onDragEnd:b,collisionBehavior:x,clickable:w,draggable:C,position:S,title:_,zIndex:k,anchorPoint:M,anchorLeft:T,anchorTop:D}=e,R=I.Children.count(h);return(0,I.useEffect)(()=>
359{if(!u||!c)return;let e=new c.AdvancedMarkerElement;e.map=u,s(e);let t=null;return R>0&&(e.content=t=document.createElement("div"),d(t)),()=>{e.map=null,null==t||t.remove(),s(null),d(null)}},[u,c,R]),(0,I.useEffect)(()=>{(null==a?void 0:a.content)&&iy(a.content)&&!(R>0)&&(a.content.className=null!=f?f:"")},[a,f,R]),t=a,n=M,i=T,r=D,o=R>0,(0,I.useEffect)(()=>{if(!t||!o)return;let e=function(e,t){var n;if(!(null==(n=null==google?void 0:google.maps)?void 0:n.version))return;let i=google.maps.version.split("."),r=parseInt(i[0],10),o=parseInt(i[1],10);return r>3||3===r&&o>=62}(0,0),a=t.content;if(a&&iy(a)){if(void 0!==i||void 0!==r){e||console.warn(`AdvancedMarker: The anchorLeft and anchorTop props are only supported in Google Maps API version 3.62 and above. The current version is ${google.maps.version}.`),t.anchorLeft=i,t.anchorTop=r,void 0!==n&&console.warn("AdvancedMarker: the anchorPoint prop is ignored when anchorLeft and/or anchorTop are set.");return}if(void 0!==n){let[i,r]=null!=n?n:im,o=`calc(-1 * ${i})`,s=`calc(-1 * ${r})`;e?(t.anchorLeft=o,t.anchorTop=s,a.style.transform=""):(a.style.transform=`translate(50%, 100%) translate(${o}, ${s})`,t.dataset.origin="rgm",ip.addAdvancedMarkerPointerEventsOverwrite())}}},[t,n,i,r,o]),iu(a,"position",S),iu(a,"title",null!=_?_:""),iu(a,"zIndex",k),iu(a,"collisionBehavior",x),(0,I.useEffect)(()=>{a&&(void 0!==C?a.gmpDraggable=C:v||y||b?a.gmpDraggable=!0:a.gmpDraggable=!1)},[a,C,v,b,y]),(0,I.useEffect)(()=>{if(!a)return;let e=void 0!==w?w:!!p||!!g||!!m;a.gmpClickable=e,e&&(null==a?void 0:a.content)&&iy(a.content)&&(a.content.style.pointerEvents="all",p&&(a.content.style.cursor="pointer"))},[a,w,p,g,m]),id(a,"click",p),id(a,"drag",v),id(a,"dragstart",y),id(a,"dragend",b),ih(null==a?void 0:a.element,"mouseenter",g),ih(null==a?void 0:a.element,"mouseleave",m),[a,l]}(e),l=(0,I.useMemo)(()=>a?{marker:a}:null,[a]);return((0,I.useImperativeHandle)(t,()=>a,[a]),s)?I.default.createElement(ig.Provider,{value:l},(0,nD.createPortal)(I.default.createElement(ib,{anchorPoint:o,styles:i,className:r},n),s)):null});function iy(e){return e.nodeType===Node.ELEMENT_NODE}iv.displayName="AdvancedMarker";let ib=({children:e,styles:t,className:n})=>I.default.createElement("div",{className:n,style:t},e);function ix(e,t,n){if(null!=t&&"object"!=typeof t)throw Error("The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.");let i=e.style;if(null==n){if(null==t)return;for(let e in t)t.hasOwnProperty(e)&&iw(i,e,t[e]);return}for(let e in n)n.hasOwnProperty(e)&&(null==t||!t.hasOwnProperty(e))&&(0===e.indexOf("--")?i.setProperty(e,""):"float"===e?i.cssFloat="":i[e]="");if(null!=t)for(let e in t){let r=t[e];t.hasOwnProperty(e)&&n[e]!==r&&iw(i,e,r)}}function iw(e,t,n){var i;let r=0===t.indexOf("--");null==n||"boolean"==typeof n||""===n?r?e.setProperty(t,""):"float"===t?e.cssFloat="":e[t]="":r?e.setProperty(t,n):"number"!=typeof n||0===n||(i=t,iC.has(i))?"float"===t?e.cssFloat=n:e[t]=(""+n).trim():e[t]=n+"px"}(0,I.forwardRef)((e,t)=>{let n=function(e){var t,n,i;let{onClick:r,onDrag:o,onDragStart:a,onDragEnd:s,onMouseOver:l,onMouseOut:d,onRadiusChanged:u,onCenterChanged:c,center:h,defaultCenter:p,radius:f,defaultRadius:g}=e,m=nI(e,["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut","onRadiusChanged","onCenterChanged","center","defaultCenter","radius","defaultRadius"]),[v,y]=(0,I.useState)(null),b=ie(),x=nK(Object.assign(Object.assign({},m),{clickable:null!=(t=m.clickable)?t:!!r,draggable:null!=(n=m.draggable)?n:!!(o||a||s||c),editable:null!=(i=m.editable)?i:!!u}),nR.default);return(0,I.useEffect)(()=>{if(!b){void 0===b&&console.error("<Circle> has to be inside a Map component.");return}let e=new google.maps.Circle(Object.assign(Object.assign({},x),{center:null!=h?h:p,radius:null!=f?f:g}));return e.setMap(b),y(e),()=>{e.setMap(null),y(null)}},[b]),id(v,"click",r),id(v,"drag",o),id(v,"dragstart",a),id(v,"dragend",s),id(v,"mouseover",l),id(v,"mouseout",d),id(v,"radius_changed",u?()=>{let e=null==v?void 0:v.getRadius();void 0!==e&&u(e)}:null),id(v,"center_changed",c?()=>{c(null==v?void 0:v.getCenter())}:null),(0,I.useEffect)(()=>{v&&v.setOptions(x)},[v,x]),(0,I.useEffect)(()=>{v&&h&&(nJ(h,v.getCenter())||v.setCenter(h))},[v,h]),(0,I.useEffect)(()=>{v&&void 0!==f&&f!==v.getRadius()&&v.setRadius(f)},[v,f]),v}(e);return(0,I.useImperativeHandle)(t,()=>n,[n]),I.default.createElement(I.default.Fragment,null)}).displayName="Circle";let iC=new Set(["animationIterationCount","aspectRatio","borderImageOutset","borderImageSlice","borderImageWidth","boxFlex","boxFlexGroup","boxOrdinalGroup","columnCount","columns","flex","flexGrow","flexPositive","flexShrink","flexNegative","flexOrder","gridArea","gridRow","gridRowEnd","gridRowSpan","gridRowStart","gridColumn","gridColumnEnd","gridColumnSpan","gridColumnStart","fontWeight","lineClamp","lineHeight","o
359pacity","order","orphans","scale","tabSize","widows","zIndex","zoom","fillOpacity","floodOpacity","stopOpacity","strokeDasharray","strokeDashoffset","strokeMiterlimit","strokeOpacity","strokeWidth"]),iS=e=>{let{children:t,headerContent:n,style:i,className:r,pixelOffset:o,anchor:a,shouldFocus:s,onClose:l,onCloseClick:d}=e,u=nI(e,["children","headerContent","style","className","pixelOffset","anchor","shouldFocus","onClose","onCloseClick"]),c=it("maps"),[h,p]=(0,I.useState)(null),f=(0,I.useRef)(null),g=(0,I.useRef)(null),m=nK(u,nR.default);(0,I.useEffect)(()=>{if(!c)return;f.current=document.createElement("div"),g.current=document.createElement("div");let e=Object.assign({},m);o&&(e.pixelOffset=new google.maps.Size(o[0],o[1])),n&&(e.headerContent="string"==typeof n?n:g.current);let t=new google.maps.InfoWindow(e);return t.setContent(f.current),p(t),()=>{var e,n;t.setContent(null),null==(e=f.current)||e.remove(),null==(n=g.current)||n.remove(),f.current=null,g.current=null,p(null)}},[c]);let v=(0,I.useRef)(null);(0,I.useLayoutEffect)(()=>{h&&f.current&&(ix(f.current,i||null,v.current),v.current=i||null,r!==f.current.className&&(f.current.className=r||""))},[h,r,i]),(0,I.useEffect)(()=>{if(!h)return;let e=Object.assign({},m);o?e.pixelOffset=new google.maps.Size(o[0],o[1]):e.pixelOffset=null,n?e.headerContent="string"==typeof n?n:g.current:e.headerContent=null,h.setOptions(e)},[m,o,n]),id(h,"close",l),id(h,"closeclick",d);let y=ie();return(0,I.useEffect)(()=>{var e;if(!y||!h||null===a)return;let t=!!a,n={map:y};if(a&&(n.anchor=a,void 0!==a.content&&a.content instanceof Element)){let t=null==a?void 0:a.getBoundingClientRect();if(t&&"rgm"===a.dataset.origin){let n=null==(e=a.content.firstElementChild)?void 0:e.firstElementChild,i=null==n?void 0:n.getBoundingClientRect(),r=i.x-t.x+(i.width-t.width)/2,s=i.y-t.y,l=Object.assign({},m);l.pixelOffset=new google.maps.Size(o?o[0]+r:r,o?o[1]+s:s),h.setOptions(l)}}return void 0!==s&&(n.shouldFocus=s),h.open(n),()=>{t&&h.set("anchor",null),h.close()}},[h,a,y,s,m,o]),I.default.createElement(I.default.Fragment,null,f.current&&(0,nD.createPortal)(t,f.current),null!==g.current&&(0,nD.createPortal)(n,g.current))};function i_(e){let t=e.getPaths(),n=[];for(let e=0;e<t.getLength();e++)n.push(t.getAt(e).getArray());return n}(0,I.forwardRef)((e,t)=>{let n=function(e){var t,n,i;let{onClick:r,onDrag:o,onDragStart:a,onDragEnd:s,onMouseOver:l,onMouseOut:d,onPathsChanged:u,polygon:c,encodedPaths:h,paths:p,defaultPaths:f}=e,g=nI(e,["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut","onPathsChanged","polygon","encodedPaths","paths","defaultPaths"]),[m,v]=(0,I.useState)(null),y=ie(),b=it("geometry"),x=(0,I.useRef)(!1),w=nK(Object.assign(Object.assign({},g),{clickable:null!=(t=g.clickable)?t:!!r,draggable:null!=(n=g.draggable)?n:!!(o||a||s||u),editable:null!=(i=g.editable)?i:!!u}),nR.default);return(0,I.useEffect)(()=>{let e;if(!y){void 0===y&&console.error("<Polygon> has to be inside a Map component.");return}if(c){e=c;let t=null!=p?p:f;t&&Array.isArray(t)&&e.setPaths(t),e.setOptions(w)}else{let t=null!=p?p:f,n=Object.assign({},w);t&&Array.isArray(t)&&(n.paths=t),e=new google.maps.Polygon(n)}return e.setMap(y),v(e),()=>{e.setMap(null),v(null)}},[y,c]),id(m,"click",r),id(m,"drag",o),id(m,"dragstart",a),id(m,"mouseover",l),id(m,"mouseout",d),id(m,"dragend",e=>{null==s||s(e),u&&m&&!x.current&&u(i_(m))}),(0,I.useEffect)(()=>{if(!m||!u)return;let e=[],t=m.getPaths();if("function"!=typeof t.getLength||"function"!=typeof t.getAt)return;let n=()=>{x.current||u(i_(m))},i=t=>{e.push(google.maps.event.addListener(t,"insert_at",n)),e.push(google.maps.event.addListener(t,"remove_at",n)),e.push(google.maps.event.addListener(t,"set_at",n))};for(let e=0;e<t.getLength();e++)i(t.getAt(e));return e.push(google.maps.event.addListener(t,"insert_at",e=>{i(t.getAt(e)),n()})),e.push(google.maps.event.addListener(t,"set_at",e=>{i(t.getAt(e)),n()})),e.push(google.maps.event.addListener(t,"remove_at",n)),()=>{e.forEach(e=>e.remove())}},[m,u,p,h,w.editable,w.draggable]),(0,I.useEffect)(()=>{m&&m.setOptions(w)},[m,w]),(0,I.useEffect)(()=>{m&&p&&Array.isArray(p)&&!function(e,t){if(!e||!t)return e===t;let n="getArray"in t?t.getArray().map(e=>e.getArray()):t;if(e.length!==n.length)return!1;for(let t=0;t<e.length;t++)if(!n1(e[t],n[t]))return!1;return!0}(Array.isArray(p[0])?p:[p],m.getPaths())&&(x.current=!0,m.setPaths(p),x.current=!1)},[m,p]),(0,I.useEffect)(()=>
359{if(!m||!h||!b)return;x.current=!0;let e=h.map(e=>b.encoding.decodePath(e));m.setPaths(e),x.current=!1},[m,h,b]),m}(e);return(0,I.useImperativeHandle)(t,()=>n,[n]),I.default.createElement(I.default.Fragment,null)}).displayName="Polygon",(0,I.forwardRef)((e,t)=>{let n=function(e){var t,n,i;let{onClick:r,onDrag:o,onDragStart:a,onDragEnd:s,onMouseOver:l,onMouseOut:d,onPathChanged:u,polyline:c,encodedPath:h,path:p,defaultPath:f}=e,g=nI(e,["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut","onPathChanged","polyline","encodedPath","path","defaultPath"]),[m,v]=(0,I.useState)(null),y=ie(),b=it("geometry"),x=(0,I.useRef)(!1),w=nK(Object.assign(Object.assign({},g),{clickable:null!=(t=g.clickable)?t:!!r,draggable:null!=(n=g.draggable)?n:!!(o||a||s||u),editable:null!=(i=g.editable)?i:!!u}),nR.default);return(0,I.useEffect)(()=>{let e;if(!y){void 0===y&&console.error("<Polyline> has to be inside a Map component.");return}if(c){e=c;let t=null!=p?p:f;t&&Array.isArray(t)&&e.setPath(t),e.setOptions(w)}else{let t=null!=p?p:f,n=Object.assign({},w);t&&Array.isArray(t)&&(n.path=t),e=new google.maps.Polyline(n)}return e.setMap(y),v(e),()=>{e.setMap(null),v(null)}},[y,c]),id(m,"click",r),id(m,"drag",o),id(m,"dragstart",a),id(m,"mouseover",l),id(m,"mouseout",d),id(m,"dragend",e=>{null==s||s(e),u&&m&&!x.current&&u(m.getPath().getArray())}),(0,I.useEffect)(()=>{if(!m||!u)return;let e=m.getPath();if(!e)return;let t=()=>{x.current||u(e.getArray())},n=[google.maps.event.addListener(e,"insert_at",t),google.maps.event.addListener(e,"remove_at",t),google.maps.event.addListener(e,"set_at",t)];return()=>{n.forEach(e=>e.remove())}},[m,u,p,h,w.editable,w.draggable]),(0,I.useEffect)(()=>{m&&m.setOptions(w)},[m,w]),(0,I.useEffect)(()=>{m&&p&&(n1(p,m.getPath())||(x.current=!0,m.setPath(p),x.current=!1))},[m,p]),(0,I.useEffect)(()=>{if(!m||!h||!b)return;x.current=!0;let e=b.encoding.decodePath(h);m.setPath(e),x.current=!1},[m,h,b]),m}(e);return(0,I.useImperativeHandle)(t,()=>n,[n]),I.default.createElement(I.default.Fragment,null)}).displayName="Polyline";let ik={center:{lat:0,lng:0,altitude:0},range:0,heading:0,tilt:0,roll:0},iM=["center","range","heading","tilt","roll"],iT=["gmp-centerchange","gmp-headingchange","gmp-tiltchange","gmp-rangechange","gmp-rollchange"];function iD(e,t){let n=e.center;return{type:t,map3d:e,detail:{center:n&&"toJSON"in n&&"function"==typeof n.toJSON?n.toJSON():n||{lat:0,lng:0,altitude:0},range:e.range||0,heading:e.heading||0,tilt:e.tilt||0,roll:e.roll||0}}}function iR(e,t,n,i){(0,I.useEffect)(()=>{if(!e||!n)return;let r=()=>{n(i(e,t))};return e.addEventListener(t,r),()=>e.removeEventListener(t,r)},[e,t,n,i])}let iI=new Set(["bounds","defaultUIHidden","gestureHandling","internalUsageAttributionIds","maxAltitude","maxHeading","maxTilt","minAltitude","minHeading","minTilt","mode"]),iA=I.default.createContext(null),iP={width:"100%",height:"100%",position:"relative"};(0,I.forwardRef)((e,t)=>{var n,i,r,o,a,s,l,d;
359let u,c,h,p,f,g,m,v,y,{children:b,id:x,className:w,style:C}=e,S=(0,I.useContext)(nz);if(!S)throw Error("<Map3D> can only be used inside an <APIProvider> component.");let{addMap3DInstance:_,removeMap3DInstance:k}=S,[M,T,D,R,A]=function(e){let t,n,i=it("maps3d"),[r,o]=(0,I.useState)(!1),[,a]=n3(),[s,l]=n3(),d=(t=n5(),n=(0,I.useRef)(Object.assign({},ik)),(0,I.useEffect)(()=>{if(!s)return;let e=[];for(let i of iM){let r=`gmp-${i}change`,o=()=>{!function(e,t,n){let i=e[n];null!=i&&("center"===n?t.current.center=i.toJSON?i.toJSON():i:t.current[n]=i)}(s,n,i),t()};s.addEventListener(r,o),e.push(()=>s.removeEventListener(r,o))}return()=>{for(let t of e)t()}},[s,t]),n);return(0,I.useEffect)(()=>{customElements.whenDefined("gmp-map-3d").then(()=>{o(!0)})},[]),(0,I.useEffect)(()=>{if(!s)return;let{center:t,heading:n,tilt:i,range:r,roll:o,defaultCenter:a,defaultHeading:l,defaultTilt:d,defaultRange:u,defaultRoll:c,id:h,style:p,className:f,children:g,onCenterChanged:m,onHeadingChanged:v,onTiltChanged:y,onRangeChanged:b,onRollChanged:x,onCameraChanged:w,onClick:C,onSteadyChange:S,onAnimationEnd:_,onError:k,mode:M,gestureHandling:T}=e,D=nI(e,["center","heading","tilt","range","roll","defaultCenter","defaultHeading","defaultTilt","defaultRange","defaultRoll","
359id","style","className","children","onCenterChanged","onHeadingChanged","onTiltChanged","onRangeChanged","onRollChanged","onCameraChanged","onClick","onSteadyChange","onAnimationEnd","onError","mode","gestureHandling"]),R=null!=t?t:a,I=null!=n?n:l,A=null!=i?i:d,P=null!=r?r:u,E=null!=o?o:c,L=Object.assign({},D);R&&(L.center=R),void 0!==I&&(L.heading=I),void 0!==A&&(L.tilt=A),void 0!==P&&(L.range=P),void 0!==E&&(L.roll=E),Object.assign(s,L)},[s]),[s,a,l,d,!!i&&r]}(e);c=null!=(n=null==(u=(d=e.center)?"toJSON"in d&&"function"==typeof d.toJSON?d.toJSON():d:null)?void 0:u.lat)?n:null,h=null!=(i=null==u?void 0:u.lng)?i:null,p=null!=(r=null==u?void 0:u.altitude)?r:null,f=null!=(o=e.range)?o:null,g=null!=(a=e.heading)?a:null,m=null!=(s=e.tilt)?s:null,v=null!=(l=e.roll)?l:null,(0,I.useLayoutEffect)(()=>{var e;if(!M)return;let t=R.current;null!==c&&null!==h&&(t.center.lat!==c||t.center.lng!==h||null!==p&&t.center.altitude!==p)&&(M.center={lat:c,lng:h,altitude:null!=(e=null!=p?p:t.center.altitude)?e:0}),null!==f&&t.range!==f&&(M.range=f),null!==g&&t.heading!==g&&(M.heading=g),null!==m&&t.tilt!==m&&(M.tilt=m),null!==v&&t.roll!==v&&(M.roll=v)}),function(e,t){let{onCenterChanged:n,onHeadingChanged:i,onTiltChanged:r,onRangeChanged:o,onRollChanged:a,onCameraChanged:s,onClick:l,onSteadyChange:d,onAnimationEnd:u,onError:c}=t;iR(e,"gmp-centerchange",n,iD),iR(e,"gmp-headingchange",i,iD),iR(e,"gmp-tiltchange",r,iD),iR(e,"gmp-rangechange",o,iD),iR(e,"gmp-rollchange",a,iD),(0,I.useEffect)(()=>{if(!e||!s)return;let t=()=>{s(iD(e,"camerachange"))};for(let n of iT)e.addEventListener(n,t);return()=>{for(let n of iT)e.removeEventListener(n,t)}},[e,s]),(0,I.useEffect)(()=>{if(!e||!l)return;let t=t=>{l({type:"gmp-click",map3d:e,detail:{position:t.position||null,placeId:t.placeId}})};return e.addEventListener("gmp-click",t),()=>e.removeEventListener("gmp-click",t)},[e,l]),(0,I.useEffect)(()=>{if(!e||!d)return;let t=t=>{d({type:"gmp-steadychange",map3d:e,detail:{isSteady:t.isSteady}})};return e.addEventListener("gmp-steadychange",t),()=>e.removeEventListener("gmp-steadychange",t)},[e,d]),iR(e,"gmp-animationend",u,(e,t)=>({type:t,map3d:e})),iR(e,"gmp-error",c,(e,t)=>({type:t,map3d:e}))}(M,e),nY(()=>{M&&Object.assign(M,y)},[M,y=(0,I.useMemo)(()=>{let t={};for(let n of Object.keys(e)){if(!iI.has(n))continue;let i=e[n];void 0!==i&&(t[n]=i)}return t},[e])]),(0,I.useEffect)(()=>{if(!M)return;let e=null!=x?x:"default";return _(M,e),()=>{k(e)}},[M,x]),(0,I.useImperativeHandle)(t,()=>({map3d:M,flyCameraAround:e=>{null==M||M.flyCameraAround(e)},flyCameraTo:e=>{null==M||M.flyCameraTo(e)},stopCameraAnimation:()=>{null==M||M.stopCameraAnimation()}}),[M]);let P=(0,I.useMemo)(()=>Object.assign(Object.assign({},iP),C),[C]),E=(0,I.useMemo)(()=>({map3d:M}),[M]);return A?I.default.createElement("div",Object.assign({ref:T,"data-testid":"map-3d",style:w?void 0:P,className:w},x?{id:x}:{}),I.default.createElement("gmp-map-3d",{ref:D,style:{width:"100%",height:"100%"}},M&&I.default.createElement(iA.Provider,{value:E},b))):I.default.createElement("div",Object.assign({ref:T,"data-testid":"map-3d",style:w?void 0:P,className:w},x?{id:x}:{}))}).displayName="Map3D";let iE=(0,I.createContext)(null);(0,I.forwardRef)(function(e,t){let{children:n,onClick:i,position:r,altitudeMode:o,collisionBehavior:a,drawsWhenOccluded:s,extruded:l,label:d,sizePreserved:u,zIndex:c,title:h}=e,p=!!i,[f,g]=(0,I.useState)(null),[m,v]=(0,I.useState)(!1),y=(0,I.useMemo)(()=>{let e=document.createElement("div");return e.style.display="none",document.body.appendChild(e),e},[]);(0,I.useEffect)(()=>()=>y.remove(),[y]);let b=(0,I.useCallback)(e=>{g(e),"function"==typeof t?t(e):t&&(t.current=e)},[t]);ih(f,"gmp-click",i),(0,I.useLayoutEffect)(()=>{if(!m&&f&&y){for(;f.firstChild;)f.removeChild(f.firstChild);for(let e of Array.from(y.childNodes)){if(e.nodeType!==Node.ELEMENT_NODE)continue;let t=e.tagName.toLowerCase();if("img"===t||"svg"===t){let t=document.createElement("template");t.content.appendChild(e.cloneNode(!0)),f.appendChild(t)}else f.appendChild(e.cloneNode(!0))}}},[f,y,n,m]);let x=(0,I.useMemo)(()=>({marker:f,setContentHandledExternally:v}),[f]);return iu(f,"position",r),iu(f,"altitudeMode",o),iu(f,"collisionBehavior",a),iu(f,"drawsWhenOccluded",s),iu(f,"extruded",l),iu(f,"label",d),iu(f,"sizePreserved",u),iu(f,"zIndex",c),iu(f,"title",null!=h?h:""),I.default.createElement(iE.Provider,{value:x},p?I.default.createElement("gmp-marker-3d-interactive",{ref:b}):I.default.createElement("gmp-marker-3d",{ref:b}),(0,nD.createPortal)(n,y))}).displayName="Marker3D",(0,I.forwardRef)(function(e,t){var n,i,r,o;let a,s,{children:l,headerContent:d,style:u,className:c,open:h=!0,position:p,anchor:f,anchorId:g,altitudeMode:m,lightDismissDisabled:v,autoPanDisabled:y,onClose:b}=e,[x,w]=(0,I.useState)(null),C=(0,I.useRef)(null);return(0,I.useImperativeHandle)(t,()=>x,[x]),i=x,r=h,o=b,a=(0,I.useRef)(void 0),s=(0,I.useRef)(r),(0,I.useEffect)(()=>{s.current=r},[r]),(0,I.useEffect)(()=>
359{if(!i||!o)return;let e=new MutationObserver(e=>{for(let t of e)if("attributes"===t.type&&"open"===t.attributeName){let e=i.hasAttribute("open");!0!==a.current||e||!1===s.current||o(),a.current=e}});return e.observe(i,{attributes:!0,attributeFilter:["open"]}),a.current=i.hasAttribute("open"),()=>{e.disconnect()}},[i,o]),iu(x,"open",null!=h&&h),iu(x,"altitudeMode",m),iu(x,"lightDismissDisabled",v),iu(x,"autoPanDisabled",y),iu(x,"positionAnchor",null!=(n=null!=f?f:g)?n:p),(0,I.useLayoutEffect)(()=>{x&&(ix(x,u||null,C.current),C.current=u||null)},[x,u]),I.default.createElement("gmp-popover",{ref:w,className:c},d&&I.default.createElement("div",{slot:"header"},d),l)}).displayName="Popover",(0,I.forwardRef)((e,t)=>{let n=function(e){let[t,n]=(0,I.useState)(null),i=ie(),{onClick:r,onDrag:o,onDragStart:a,onDragEnd:s,onMouseOver:l,onMouseOut:d}=e,u=nI(e,["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut"]),{position:c,draggable:h}=u;return(0,I.useEffect)(()=>{if(!i){void 0===i&&console.error("<Marker> has to be inside a Map component.");return}let e=new google.maps.Marker(u);return e.setMap(i),n(e),()=>{e.setMap(null),n(null)}},[i]),(0,I.useEffect)(()=>{if(!t)return;let e=google.maps.event;return r&&e.addListener(t,"click",r),o&&e.addListener(t,"drag",o),a&&e.addListener(t,"dragstart",a),s&&e.addListener(t,"dragend",s),l&&e.addListener(t,"mouseover",l),d&&e.addListener(t,"mouseout",d),t.setDraggable(!!h),()=>{e.clearInstanceListeners(t)}},[t,h,r,o,a,s,l,d]),(0,I.useEffect)(()=>{t&&t.setOptions(u)},[t,u]),(0,I.useEffect)(()=>{!h&&c&&t&&t.setPosition(c)},[h,c,t]),t}(e);return(0,I.useImperativeHandle)(t,()=>n,[n]),I.default.createElement(I.default.Fragment,null)}).displayName="Marker";let iL=e=>{let t=(0,I.useContext)(ig),n=(0,I.useContext)(iE),i=null==t?void 0:t.marker,r=null==n?void 0:n.marker,o=null==n?void 0:n.setContentHandledExternally,a=(0,I.useMemo)(()=>document.createElement("div"),[]),s=it("marker");return(0,I.useEffect)(()=>{if(r&&o)return o(!0),()=>o(!1)},[r,o]),(0,I.useEffect)(()=>{if(!r||!s)return;let t=Object.assign({},e),n=new s.PinElement(t);for(e.children&&(n.glyph=a);r.firstChild;)r.removeChild(r.firstChild);return r.append(n),()=>{}},[r,s,a,e]),(0,I.useEffect)(()=>{var t;if(r)return;if(!i){void 0===i&&void 0===r&&console.error("The <Pin> component can only be used inside <AdvancedMarker> or <Marker3D>.");return}e.glyph&&e.children&&n9("The <Pin> component only uses children to render the glyph if both the glyph property and children are present."),I.Children.count(e.children)>1&&n9("Passing multiple children to the <Pin> component might lead to unexpected results.");let n=Object.assign({},e),o=new google.maps.marker.PinElement(n);e.children&&(o.glyph=a);let s=null==(t=i.content)?void 0:t.firstChild;for(;null==s?void 0:s.firstChild;)s.removeChild(s.firstChild);s&&s.appendChild(o.element)},[i,a,r,e]),(0,nD.createPortal)(e.children,a)},iF=e=>{let{children:t}=e,n=(0,I.useContext)(ig),i=(0,I.useContext)(iE),r=null==n?void 0:n.marker,o=null==i?void 0:i.marker,a=null==i?void 0:i.setContentHandledExternally,s=(0,I.useMemo)(()=>document.createElement("div"),[]),l=it("marker");return(0,I.useEffect)(()=>{if(o&&a)return a(!0),()=>a(!1)},[o,a]),(0,I.useEffect)(()=>{if(!o||!l)return;let n=Object.assign({},e),i=new l.PinElement(n);for(t&&i.appendChild(s);o.firstChild;)o.removeChild(o.firstChild);return o.appendChild(i),()=>{}},[o,l,s,t,e]),(0,I.useEffect)(()=>{var n;if(o)return;if(!r||!l){void 0===r&&void 0===o&&console.error("The <Pin> component can only be used inside <AdvancedMarker> or <Marker3D>.");return}(e.glyphSrc||e.glyphText)&&t&&n9("The <Pin> component only uses children to render the glyph if both glyphSrc/glyphText and children are present."),I.Children.count(t)>1&&n9("Passing multiple children to the <Pin> component might lead to unexpected results.");let i=Object.assign({},e),a=new l.PinElement(i);t&&a.appendChild(s);let d=null==(n=r.content)?void 0:n.firstChild;for(;null==d?void 0:d.firstChild;)d.removeChild(d.firstChild);d&&d.appendChild(a)},[r,l,s,o,t,e]),(0,nD.createPortal)(t,s)},iO=e=>{var t;let n=it("marker"),i=(0,I.useMemo)(()=>!!n&&"u">
359typeof customElements&&void 0!==customElements.get("gmp-pin"),[n]);if(!n)return null;if(i){let{glyph:t,glyphSrc:n,glyphText:i}=e,r=nI(e,["glyph","glyphSrc","glyphText"]),o=t instanceof URL||"string"==typeof t&&t.startsWith("http"),a=null!=i?i:"string"!=typeof t||o?void 0:t,s=null!=n?n:o?String(t):void 0;return I.default.createElement(iF,Object.assign({},r,{glyphText:a,glyphSrc:s}))}{let{glyph:n,glyphSrc:i,glyphText:r}=e,o=nI(e,["glyph","glyphSrc","glyphText"]),a=null!=(t=null!=n?n:i)?t:r;return I.default.createElement(iL,Object.assign({},o,{glyph:a}))}};(0,I.forwardRef)((e,t)=>{let n=function(e){var t,n,i;let{onClick:r,onDrag:o,onDragStart:a,onDragEnd:s,onMouseOver:l,onMouseOut:d,onBoundsChanged:u,bounds:c,defaultBounds:h}=e,p=nI(e,["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut","onBoundsChanged","bounds","defaultBounds"]),[f,g]=(0,I.useState)(null),m=ie(),v=nK(Object.assign(Object.assign({},p),{clickable:null!=(t=p.clickable)?t:!!r,draggable:null!=(n=p.draggable)?n:!!(o||a||s||u),editable:null!=(i=p.editable)?i:!!u}),nR.default);return(0,I.useEffect)(()=>{if(!m){void 0===m&&console.error("<Rectangle> has to be inside a Map component.");return}let e=new google.maps.Rectangle(Object.assign(Object.assign({},v),{bounds:null!=c?c:h}));return e.setMap(m),g(e),()=>{e.setMap(null),g(null)}},[m]),id(f,"click",r),id(f,"drag",o),id(f,"dragstart",a),id(f,"dragend",s),id(f,"mouseover",l),id(f,"mouseout",d),id(f,"bounds_changed",u?()=>{u(null==f?void 0:f.getBounds())}:null),(0,I.useEffect)(()=>{f&&f.setOptions(v)},[f,v]),(0,I.useEffect)(()=>{f&&c&&!function(e,t){if(!e||!t)return!1;let n=n0(e),i=n0(t);return n.north===i.north&&n.south===i.south&&n.east===i.east&&n.west===i.west}(c,f.getBounds())&&f.setBounds(c)},[f,c]),f}(e);return(0,I.useImperativeHandle)(t,()=>n,[n]),I.default.createElement(I.default.Fragment,null)}).displayName="Rectangle";var iN=e.i(44505);let iB=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],iz=new Uint32Array(96);class ij{static from(e){if(!e||void 0===e.byteLength||e.buffer)throw Error("Data must be an instance of ArrayBuffer or SharedArrayBuffer.");let[t,n]=new Uint8Array(e,0,2);if(219!==t)throw Error("Data does not appear to be in a KDBush format.");let i=n>>4;if(1!==i)throw Error(`Got v${i} data when expected v1.`);let r=iB[15&n];if(!r)throw Error("Unrecognized array type.");let[o]=new Uint16Array(e,2,1),[a]=new Uint32Array(e,4,1);return new ij(a,o,r,void 0,e)}constructor(e,t=64,n=Float64Array,i=ArrayBuffer,r){if(isNaN(e)||e<0)throw Error(`Unexpected numItems value: ${e}.`);this.numItems=+e,this.nodeSize=Math.min(Math.max(+t,2),65535),this.ArrayType=n,this.IndexArrayType=e<65536?Uint16Array:Uint32Array;const o=iB.indexOf(this.ArrayType),a=2*e*this.ArrayType.BYTES_PER_ELEMENT,s=e*this.IndexArrayType.BYTES_PER_ELEMENT,l=(8-s%8)%8;if(o<0)throw Error(`Unexpected typed array class: ${n}.`);if(r)this.data=r,this.ids=new this.IndexArrayType(r,8,e),this.coords=new n(r,8+s+l,2*e),this._pos=2*e,this._finished=!0;else{const r=this.data=new i(8+a+s+l);this.ids=new this.IndexArrayType(r,8,e),this.coords=new n(r,8+s+l,2*e),this._pos=0,this._finished=!1,new Uint8Array(r,0,2).set([219,16+o]),new Uint16Array(r,2,1)[0]=t,new Uint32Array(r,4,1)[0]=e}}add(e,t){let n=this._pos>>1;return this.ids[n]=n,this.coords[this._pos++]=e,this.coords[this._pos++]=t,n}finish(){let e=this._pos>>1;if(e!==this.numItems)throw Error(`Added ${e} items when expected ${this.numItems}.`);return function e(t,n,i,r,o,a){if(o-r<=i)return;let s=r+o>>1;(function e(t,n,i,r,o,a){for(;o>r;){if(o-r>600){let s=o-r+1,l=i-r+1,d=Math.log(s),u=.5*Math.exp(2*d/3),c=.5*Math.sqrt(d*u*(s-u)/s)*(l-s/2<0?-1:1),h=Math.max(r,Math.floor(i-l*u/s+c)),p=Math.min(o,Math.floor(i+(s-l)*u/s+c));e(t,n,i,h,p,a)}let s=n[2*i+a],l=r,d=o;for(iV(t,n,r,i),n[2*o+a]>s&&iV(t,n,r,o);l<d;){for(iV(t,n,l,d),l++,d--;n[2*l+a]<s;)l++;for(;n[2*d+a]>s;)d--}n[2*r+a]===s?iV(t,n,r,d):iV(t,n,++d,o),d<=i&&(r=d+1),i<=d&&(o=d-1)}})(t,n,s,r,o,a),e(t,n,i,r,s-1,1-a),e(t,n,i,s+1,o,1-a)}(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(e,t,n,i){if(!this._finished)throw Error("Data not yet indexed - call index.finish().");let{ids:r,coords:o,nodeSize:a}=this;iz[0]=0,iz[1]=r.length-1,iz[2]=0;let s=3,l=[];for(;s>0;
359){let d=iz[--s],u=iz[--s],c=iz[--s];if(u-c<=a){for(let a=c;a<=u;a++){let s=o[2*a],d=o[2*a+1];s>=e&&s<=n&&d>=t&&d<=i&&l.push(r[a])}continue}let h=c+u>>1,p=o[2*h],f=o[2*h+1];p>=e&&p<=n&&f>=t&&f<=i&&l.push(r[h]),(0===d?e<=p:t<=f)&&(iz[s++]=c,iz[s++]=h-1,iz[s++]=1-d),(0===d?n>=p:i>=f)&&(iz[s++]=h+1,iz[s++]=u,iz[s++]=1-d)}return l}within(e,t,n){let i=[];return this.withinInto(e,t,n,i),i}withinInto(e,t,n,i){if(!this._finished)throw Error("Data not yet indexed - call index.finish().");let{ids:r,coords:o,nodeSize:a}=this;iz[0]=0,iz[1]=r.length-1,iz[2]=0;let s=3,l=0,d=n*n;for(;s>0;){let u=iz[--s],c=iz[--s],h=iz[--s];if(c-h<=a){for(let n=h;n<=c;n++)iG(o[2*n],o[2*n+1],e,t)<=d&&(i[l++]=r[n]);continue}let p=h+c>>1,f=o[2*p],g=o[2*p+1];iG(f,g,e,t)<=d&&(i[l++]=r[p]),(0===u?e-n<=f:t-n<=g)&&(iz[s++]=h,iz[s++]=p-1,iz[s++]=1-u),(0===u?e+n>=f:t+n>=g)&&(iz[s++]=p+1,iz[s++]=c,iz[s++]=1-u)}return l}}function iV(e,t,n,i){iH(e,n,i),iH(t,2*n,2*i),iH(t,2*n+1,2*i+1)}function iH(e,t,n){let i=e[t];e[t]=e[n],e[n]=i}function iG(e,t,n,i){let r=e-n,o=t-i;return r*r+o*o}let iW={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:e=>e},i$=Math.fround||(n=new Float32Array(1),e=>(n[0]=+e,n[0]));class iU{constructor(e){this.options=Object.assign(Object.create(iW),e),this.trees=Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}load(e){let{log:t,minZoom:n,maxZoom:i}=this.options;t&&console.time("total time");let r=`prepare ${e.length} points`;t&&console.time(r),this.points=e;let o=[];for(let t=0;t<e.length;t++){let n=e[t];if(!n.geometry)continue;let[i,r]=n.geometry.coordinates,a=i$(iY(i)),s=i$(iZ(r));o.push(a,s,1/0,t,-1,1),this.options.reduce&&o.push(0)}let a=this.trees[i+1]=this._createTree(o);t&&console.timeEnd(r);for(let e=i;e>=n;e--){let n=+Date.now();a=this.trees[e]=this._createTree(this._cluster(a,e)),t&&console.log("z%d: %d clusters in %dms",e,a.numItems,Date.now()-n)}return t&&console.timeEnd("total time"),this}getClusters(e,t){let n=((e[0]+180)%360+360)%360-180,i=Math.max(-90,Math.min(90,e[1])),r=180===e[2]?180:((e[2]+180)%360+360)%360-180,o=Math.max(-90,Math.min(90,e[3]));if(e[2]-e[0]>=360)n=-180,r=180;else if(n>r){let e=this.getClusters([n,i,180,o],t),a=this.getClusters([-180,i,r,o],t);return e.concat(a)}let a=this.trees[this._limitZoom(t)],s=a.range(iY(n),iZ(o),iY(r),iZ(i)),l=a.data,d=[];for(let e of s){let t=this.stride*e;d.push(l[t+5]>1?iq(l,t,this.clusterProps):this.points[l[t+3]])}return d}getChildren(e){let t=this._getOriginId(e),n=this._getOriginZoom(e),i="No cluster with the specified id.",r=this.trees[n];if(!r)throw Error(i);let o=r.data;if(t*this.stride>=o.length)throw Error(i);let a=this.options.radius/(this.options.extent*Math.pow(2,n-1)),s=o[t*this.stride],l=o[t*this.stride+1],d=r.within(s,l,a),u=[];for(let t of d){let n=t*this.stride;o[n+4]===e&&u.push(o[n+5]>1?iq(o,n,this.clusterProps):this.points[o[n+3]])}if(0===u.length)throw Error(i);return u}getLeaves(e,t,n){t=t||10,n=n||0;let i=[];return this._appendLeaves(i,e,t,n,0),i}getTile(e,t,n){let i=this.trees[this._limitZoom(e)],r=Math.pow(2,e),{extent:o,radius:a}=this.options,s=a/o,l=(n-s)/r,d=(n+1+s)/r,u={features:[]};return this._addTileFeatures(i.range((t-s)/r,l,(t+1+s)/r,d),i.data,t,n,r,u),0===t&&this._addTileFeatures(i.range(1-s/r,l,1,d),i.data,r,n,r,u),t===r-1&&this._addTileFeatures(i.range(0,l,s/r,d),i.data,-1,n,r,u),u.features.length?u:null}getClusterExpansionZoom(e){let t=this._getOriginZoom(e)-1;for(;t<=this.options.maxZoom;){let n=this.getChildren(e);if(t++,1!==n.length)break;e=n[0].properties.cluster_id}return t}_appendLeaves(e,t,n,i,r){for(let o of this.getChildren(t)){let t=o.properties;if(t&&t.cluster?r+t.point_count<=i?r+=t.point_count:r=this._appendLeaves(e,t.cluster_id,n,i,r):r<i?r++:e.push(o),e.length===n)break}return r}_createTree(e){let t=new ij(e.length/this.stride|0,this.options.nodeSize,Float32Array);for(let n=0;n<e.length;n+=this.stride)t.add(e[n],e[n+1]);return t.finish(),t.data=e,t}_addTileFeatures(e,t,n,i,r,o){for(let a of e){let e,s,l,d,u=a*this.stride,c=t[u+5]>1;if(c)e=iK(t,u,this.clusterProps),s=t[u],l=t[u+1];else{let n=this.points[t[u+3]];e=n.properties;let[i,r]=n.geometry.coordinates;s=iY(i),l=iZ(r)}let h={type:1,geometry:[[Math.round(this.options.extent*(s*r-n)),Math.round(this.options.extent*(l*r-i))]],tags:e};void 0!==(d=c||this.options.generateId?t[u+3]:this.points[t[u+3]].id)&&(h.id=d),o.features.push(h)}}_limitZoom(e){return Math.max(this.options.minZoom,Math.min(Math.floor(+e),this.options.maxZoom+1))}_cluster(e,t){let{radius:n,extent:i,reduce:r,minPoints:o}=this.options,a=n/(i*Math.pow(2,t)),s=e.data,l=[],d=this.stride;for(let n=0;n<s.length;n+=d){if(s[n+2]<=t)continue;s[n+2]=t;let i=s[n],u=s[n+1],c=e.within(s[n],s[n+1],a),h=s[n+5],p=h;for(let e of c){let n=e*d;s[n+2]>t&&(p+=s[n+5])}if(p>h&&p>=o){let e,o=i*h,a=u*h,f=-1,g=(n/d<<5)+(t+1)+this.points.length;for(let i of c){let l=i*d;if(s[l+2]<=t)continue;s[l+2]=t;let u=s[l+5];o+=s[l]*u,a+=s[l+1]*u,s[l+4]=g,r&&(e||(e=this._map(s,n,!0),f=this.clusterProps.length,this.clusterProps.push(e)),r(e,this._map(s,l)))}s[n+4]=g,l.push(o/p,a/p,1/0,g,-1,p),r&&l.push(f)}else{for(let e=0;e<d;e++)l.push(s[n+e]);if(p>1)for(let e of c){let n=e*d;if(!(s[n+2]<=t)){s[n+2]=t;for(let e=0;e<d;e++)l.push(s[n+e])}}}}return l}_getOriginId(e){return e-this.points.length>>5}_getOriginZoom(e){return(e-this.points.length)%32}_map(e,t,n){if(e[t+5]>1){let i=this.clusterProps[e[t+6]];return n?Object.assign({},i):i}let i=this.points[e[t+3]].properties,r=this.options.map(i);return n&&r===i?Object.assign({},r):r}}function iq(e,t,n){return{type:"Feature",id:e[t+3],properties:iK(e,t,n),geometry:{type:"Point",coordinates:[(e[t]-.5)*360,360*Math.atan(Math.exp((180-360*e[t+1])*Math.PI/180)
359)/Math.PI-90]}}}function iK(e,t,n){let i=e[t+5],r=i>=1e4?`${Math.round(i/1e3)}k`:i>=1e3?`${Math.round(i/100)/10}k`:i,o=e[t+6];return Object.assign(-1===o?{}:Object.assign({},n[o]),{cluster:!0,cluster_id:e[t+3],point_count:i,point_count_abbreviated:r})}function iY(e){return e/360+.5}function iZ(e){let t=Math.sin(e*Math.PI/180),n=.5-.25*Math.log((1+t)/(1-t))/Math.PI;return n<0?0:n>1?1:n}"function"==typeof SuppressedError&&SuppressedError;class iX{static isAdvancedMarkerAvailable(e){return google.maps.marker&&!0===e.getMapCapabilities().isAdvancedMarkersAvailable}static isAdvancedMarker(e){return google.maps.marker&&e instanceof google.maps.marker.AdvancedMarkerElement}static setMap(e,t){this.isAdvancedMarker(e)?e.map=t:e.setMap(t)}static getPosition(e){if(this.isAdvancedMarker(e)){if(e.position){if(e.position instanceof google.maps.LatLng)return e.position;if(Number.isFinite(e.position.lat)&&Number.isFinite(e.position.lng))return new google.maps.LatLng(e.position.lat,e.position.lng)}return new google.maps.LatLng(null)}return e.getPosition()}static getVisible(e){return!!this.isAdvancedMarker(e)||e.getVisible()}}class iJ{constructor({markers:e,position:t}){this.markers=[],e&&(this.markers=e),t&&(t instanceof google.maps.LatLng?this._position=t:this._position=new google.maps.LatLng(t))}get bounds(){if(0===this.markers.length&&!this._position)return;let e=new google.maps.LatLngBounds(this._position,this._position);for(let t of this.markers)e.extend(iX.getPosition(t));return e}get position(){return this._position||this.bounds.getCenter()}get count(){return this.markers.filter(e=>iX.getVisible(e)).length}push(e){this.markers.push(e)}delete(){this.marker&&(iX.setMap(this.marker,null),this.marker=void 0),this.markers.length=0}}function iQ(e,t="assertion failed"){if(null==e)throw Error(t)}class i0{constructor({maxZoom:e=16}){this.maxZoom=e}noop({markers:e}){return i1(e)}}let i1=e=>e.map(e=>new iJ({position:iX.getPosition(e),markers:[e]}));class i2 extends i0{constructor(e){var{maxZoom:t,radius:n=60}=e,i=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&0>t.indexOf(i)&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var r=0,i=Object.getOwnPropertySymbols(e);r<i.length;r++)0>t.indexOf(i[r])&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]]);return n}(e,["maxZoom","radius"]);super({maxZoom:t}),this.markers=[],this.clusters=[],this.state={zoom:-1},this.superCluster=new iU(Object.assign({maxZoom:this.maxZoom,radius:n},i))}calculate(e){let t=!1,n=e.map.getZoom();iQ(n);let i={zoom:n=Math.round(n)};if(!(0,iN.deepEqual)(e.markers,this.markers)){t=!0,this.markers=[...e.markers];let n=this.markers.map(e=>{let t=iX.getPosition(e);return{type:"Feature",geometry:{type:"Point",coordinates:[t.lng(),t.lat()]},properties:{marker:e}}});this.superCluster.load(n)}return(!t&&(this.state.zoom<=this.maxZoom||i.zoom<=this.maxZoom)&&(t=!(0,iN.deepEqual)(this.state,i)),this.state=i,0===e.markers.length)?this.clusters=[]:t&&(this.cluster
359s=this.cluster(e)),{clusters:this.clusters,changed:t}}cluster({map:e}){let t=e.getZoom();return iQ(t),this.superCluster.getClusters([-180,-90,180,90],Math.round(t)).map(e=>this.transformCluster(e))}transformCluster({geometry:{coordinates:[e,t]},properties:n}){if(n.cluster)return new iJ({markers:this.superCluster.getLeaves(n.cluster_id,1/0).map(e=>e.properties.marker),position:{lat:t,lng:e}});let i=n.marker;return new iJ({markers:[i],position:iX.getPosition(i)})}}class i3{constructor(e,t){this.markers={sum:e.length};const n=t.map(e=>e.count),i=n.reduce((e,t)=>e+t,0);this.clusters={count:t.length,markers:{mean:i/t.length,sum:i,min:Math.min(...n),max:Math.max(...n)}}}}class i5{render({count:e,position:t},n,i){let r=e>Math.max(10,n.clusters.markers.mean)?"#ff0000":"#0000ff",o=`<svg fill="${r}" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240" width="50" height="50"> 360<circle cx="120" cy="120" opacity=".6" r="70" /> 361<circle cx="120" cy="120" opacity=".3" r="90" /> 362<circle cx="120" cy="120" opacity=".2" r="110" /> 363<text x="50%" y="50%" style="fill:#fff" text-anchor="middle" font-size="50" dominant-baseline="middle" font-family="roboto,arial,sans-serif">${e}</text> 364</svg>`,a=`Cluster of ${e} markers`,s=Number(google.maps.Marker.MAX_ZINDEX)+e;if(iX.isAdvancedMarkerAvailable(i)){let e=new DOMParser().parseFromString(o,"image/svg+xml").documentElement;return e.setAttribute("transform","translate(0 25)"),new google.maps.marker.AdvancedMarkerElement({map:i,position:t,zIndex:s,title:a,content:e})}let l={position:t,zIndex:s,title:a,icon:{url:`data:image/svg+xml;base64,${btoa(o)}`,anchor:new google.maps.Point(25,25)}};return new google.maps.Marker(l)}}class i4{constructor(){!function(e,t){for(let n in t.prototype)e.prototype[n]=t.prototype[n]}(i4,google.maps.OverlayView)}}(l=g||(g={})).CLUSTERING_BEGIN="clusteringbegin",l.CLUSTERING_END="clusteringend",l.CLUSTER_CLICK="click",l.GMP_CLICK="gmp-click";let i6=(e,t,n)=>{t.bounds&&n.fitBounds(t.bounds)};class i8 extends i4{constructor({map:e,markers:t=[],algorithmOptions:n={},algorithm:i=new i2(n),renderer:r=new i5,onClusterClick:o=i6}){super(),this.map=null,this.idleListener=null,this.markers=[...t],this.clusters=[],this.algorithm=i,this.renderer=r,this.onClusterClick=o,e&&this.setMap(e)}addMarker(e,t){!this.markers.includes(e)&&(this.markers.push(e),t||this.render())}addMarkers(e,t){e.forEach(e=>{this.addMarker(e,!0)}),t||this.render()}removeMarker(e,t){let n=this.markers.indexOf(e);return -1!==n&&(iX.setMap(e,null),this.markers.splice(n,1),t||this.render(),!0)}removeMarkers(e,t){let n=!1;return e.forEach(e=>{n=this.removeMarker(e,!0)||n}),n&&!t&&this.render(),n}clearMarkers(e){this.markers.length=0,e||this.render()}render(){let e=this.getMap();if(e instanceof google.maps.Map&&e.getProjection()){google.maps.event.trigger(this,g.CLUSTERING_BEGIN,this);let{clusters:t,changed:n}=this.algorithm.calculate({markers:this.markers,map:e,mapCanvasProjection:this.getProjection()});if(n||void 0==n){let e=new Set;for(let n of t)1==n.markers.length&&e.add(n.markers[0]);let n=[];for(let t of this.clusters)null!=t.marker&&(1==t.markers.length?e.has(t.marker)||iX.setMap(t.marker,null):n.push(t.marker));this.clusters=t,this.renderClusters(),requestAnimationFrame(()=>n.forEach(e=>iX.setMap(e,null)))}google.maps.event.trigger(this,g.CLUSTERING_END,this)}}onAdd(){let e=this.getMap();iQ(e),this.idleListener=e.addListener("idle",this.render.bind(this)),this.render()}onRemove(){this.idleListener&&google.maps.event.removeListener(this.idleListener),this.reset()}reset(){this.markers.forEach(e=>iX.setMap(e,null)),this.clusters.forEach(e=>e.delete()),this.clusters=[]}renderClusters(){let e=new i3(this.markers,this.clusters),t=this.getMap();this.clusters.forEach(n=>{if(1===n.markers.length)n.marker=n.markers[0];else if(n.marker=this.renderer.render(n,e,t),n.markers.forEach(e=>iX.setMap(e,null)),this.onClusterClick){let e=iX.isAdvancedMarker(n.marker)?g.GMP_CLICK:g.CLUSTER_CLICK;n.marker.addListener(e,e=>{google.maps.event.trigger(this,g.CLUSTER_CLICK,n),this.onClusterClick(e,n,t)})}iX.setMap(n.marker,t)})}}var i7=e.i(40867),i9=e.i(63797);let re=({className:e})=>(0,R.jsx)("svg",{className:e,xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",fill:"none",children:(0,R.jsx)("path",{d:"M10 18H14V16H10V18ZM3 6V8H21V6H3ZM6 13H18V11H6V13Z",fill:"currentColor"})});var rt=e.i(62304);let rn=({className:e})=>(0,R.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 16 16",fill:"none",className:e,children:(0,R.jsx)("path",{d:"M8 8C8.55 8 9.02083 7.80417 9.4125 7.4125C9.80417 7.02083 10 6.55 10 6C10 5.45 9.80417 4.97917 9.4125 4.5875C9.02083 4.19583 8.55 4 8 4C7.45 4 6.97917 4.19583 6.5875 4.5875C6.19583 4.97917 6 5.45 6 6C6 6.55 6.19583 7.02083 6.5875 7.4125C6.97917 7.80417 7.45 8 8 8ZM8 14C6.33333 12.5333 5.08333 11.2083 4.25 10.025C3.41667 8.84167 3 7.76667 3 6.8C3 5.26667 3.48333 4.04167 4.45 3.125C5.41667 2.20833 6.6 1.75 8 1.75C9.4 1.75 10.5833 2.20833 11.55 3.125C12.5167 4.04167 13 5.26667 13 6.8C13 7.76667 12.5833 8.84167 11.75 10.025C10.9167 11.2083 9.66667 12.5333 8 14Z",fill:"currentColor"})}),ri=({className:e})=>(0,R.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 16 16",fill:"none",className:e,children:(0,R.jsx)("path",{d:"M5 6C5.275 6 5.51042 5.90208 5.70625 5.70625C5.90208 5.51042 6 5.275 6 5C6 4.725 5.90208 4.48958 5.70625 4.29375C5.51042 4.09792 5.275 4 5 4C4.725 4 4.48958 4.09792 4.29375 4.29375C4.09792 4.48958 4 4.725 4 5C4 5.275 4.09792 5.51042 4.29375 5.70625C4.48958 5.90208 4.725 6 5 6ZM5 9C4.16667 8.16667 3.54167 7.42708 3.125 6.78125C2.70833 6.13542 2.5 5.53333 2.5 4.975C2.5 4.15833 2.74167 3.52083 3.225 3.0625C3.70833 2.60417 4.3 2.375 5 2.375C5.7 2.375 6.29167 2.60417 6.775 3.0625C7.25833 3.52083 7.5 4.15833 7.5 4.975C7.5 5.53333 7.29167 6.13542 6.875 6.78125C6.45833 7.42708 5.83333 8.16667 5 9ZM11 10C11.275 10 11.5104 9.90208 11.7062 9.70625C11.9021 9.51042 12 9.275 12 9C12 8.725 11.9021 8.48958 11.7062 8.29375C11.5104 8.09792 11.275 8 11 8C10.725 8 10.4896 8.09792 10.2938 8.29375C10.0979 8.48958 10 8.725 10 9C10 9.275 10.0979 9.51042 10.2938 9.70625C10.4896 9.90208 10.725 10 11 10ZM11 13C10.1667 12.1667 9.54167 11.4271 9.125 10.7812C8.70833 10.1354 8.5 9.53333 8.5 8.975C8.5 8.15833 8.74167 7.52083 9.225 7.0625C9.70833 6.60417 10.3 6.375 11 6.375C11.7 6.375 12.2917 6.60417 12.775 7.0625C13.2583 7.52083 13.5 8.15833 13.5 8.975C13.5 9.53333 13.2917 10.1354 12.875 10.7812C12.4583 11.4271 11.8333 12.1667 11 13Z",fill:"currentColor"})});var rr=e.i(45703);let ro={blue:"#00f",red:"#be0202",darkgreen:"#008000",magenta:"#f0f",green:"#06ba06",cyan:"#0ff",orange:"#ff8c00",purple:"#800080",pink:"#ff1493",yellow:"#ff0"};var ra={root:"m_347db0ec","root--dot":"m_fbd81e3d",label:"m_5add502a",section:"m_91fdda9b"};let rs=(0,Q.createVarsResolver)((e,{radius:t,color:n,gradient:i,variant:r,size:o,autoContrast:a,circle:s})=>{let l=e.variantColorResolver({color:n||e.primaryColor,theme:e,gradient:i,variant:r||"filled",autoContrast:a});return{root:{"--badge-height":(0,J.getSize)(o,"badge-height"),"--badge-padding-x":(0,J.getSize)(o,"badge-padding-x"),"--badge-fz":(0,J.getSize)(o,"badge-fz"),"--badge-radius":s||void 0===t?void 0:(0,J.getRadius)(t),"--badge-bg":n||r?l.background:void 0,"--badge-color":n||r?l.color:void 0,"--badge-bd":n||r?l.border:void 0,"--badge-dot-color":"dot"===r?(0,et.getThemeColor)(n,e):void 0}}}),rl=(0,eD.polymorphicFactory)((e,t)=>{let n=(0,er.useProps)("Badge",null,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,radiu
364s:d,color:u,gradient:c,leftSection:h,rightSection:p,children:f,variant:g,fullWidth:m,autoContrast:v,circle:y,mod:b,attributes:x,...w}=n,C=(0,eo.useStyles)({name:"Badge",props:n,classes:ra,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:x,vars:l,varsResolver:rs});return(0,R.jsxs)(ea.Box,{variant:g,mod:[{block:m,circle:y,"with-right-section":!!p,"with-left-section":!!h},b],...C("root",{variant:g}),ref:t,...w,children:[h&&(0,R.jsx)("span",{...C("section"),"data-position":"left",children:h}),(0,R.jsx)("span",{...C("label"),children:f}),p&&(0,R.jsx)("span",{...C("section"),"data-position":"right",children:p})]})});rl.classes=ra,rl.displayName="@mantine/core/Badge";var rd=e.i(34872);let ru=({markerGroup:e,markerDescription:t,labels:n,color:i})=>(0,R.jsxs)(R.Fragment,{children:[e&&(0,R.jsx)("div",{className:rd.default["marker-group"],style:{color:i?ro[i]:void 0},children:e}),t&&(0,R.jsx)("div",{className:rd.default["marker-description"],dangerouslySetInnerHTML:{__html:t}}),n&&(0,R.jsx)("div",{className:rd.default["marker-labels"],children:n.split(",").map(e=>e.trim()).map(e=>(0,R.jsx)(rl,{size:"sm",mr:"xs",mb:"xs",children:e},e))})]}),rc=({color:e})=>{let t=`${rd.default["dot-marker"]}`;return e&&(t+=` ${rd.default["dot-marker--"+e]}`),(0,R.jsx)("div",{className:t})},rh=e=>{let[t,n]=(0,I.useState)(!1),[i,r]=function(){let[e,t]=(0,I.useState)(null);return[(0,I.useCallback)(e=>{t(e)},[]),e]}();(0,I.useEffect)(()=>{if(r&&e.clusterer)return r.color=e.color,r.markerGroup=e.markerGroup,r.markerName=e.markerName,r.markerDescription=e.markerDescription,r.labels=e.labels,r.markerLatitude=e.markerLatitude,r.markerLongitude=e.markerLongitude,e.clusterer.addMarker(r),()=>{e.clusterer?.removeMarker(r)}},[r,e.clusterer,e.color,e.markerGroup,e.markerName,e.markerDescription,e.labels,e.markerLatitude,e.markerLongitude]);let o=e.color&&!e.useDefaultPin?(0,R.jsx)(rc,{color:e.color}):null,a=e.color&&e.useDefaultPin?(0,R.jsx)(iO,{background:ro[e.color],borderColor:"#fff",glyphColor:"#fff"}):null;return(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(iv,{ref:i,onClick:()=>n(!0),position:{lat:parseFloat(e.markerLatitude),lng:parseFloat(e.markerLongitude)},children:o||a}),t&&(0,R.jsx)(iS,{anchor:r,maxWidth:200,headerContent:(0,R.jsxs)("span",{className:`${rd.default["infowindow-header"]} ${e.color?rd.default[`infowindow-icon--${e.color}`]:""}`,children:[(0,R.jsx)(rn,{}),(0,R.jsx)("span",{className:rd.default["marker-name"],dangerouslySetInnerHTML:{__html:e.markerName}})]}),onCloseClick:()=>n(!1),children:(0,R.jsx)("div",{"data-marker-color":e.color||void 0,children:(0,R.jsx)(ru,{color:e.color,markerGroup:e.markerGroup!==e.markerName?e.markerGroup:void 0,markerDescription:e.markerDescription,labels:e.labels})})})]})},rp=["blue","red","darkgreen","magenta","green","cyan","orange","purple","pink","yellow"],rf=[],rg=()=>{let{t:e}=(0,eS.useTranslations)();return(0,R.jsxs)("section",{className:rr.default["map-legend"],children:[(0,R.jsx)("h5",{className:rr.default["map-legend__header"],children:e("legend")}),(0,R.jsx)("ul",{className:rr.default["map-legend__list"],children:rf.map(e=>(0,R.jsx)("li",{className:`${rr.default["map-legend__item"]} ${rr.default["map-legend__item--"+e.color]}`,children:e.name},e.name))})]})},rm=({filterEnabled:e,searchEnabled:t,allLabels:n,selectedLabels:i,setSelectedLabels:r,searchQuery:o,setSearchQuery:a})=>{let{t:s}=(0,eS.useTranslations)(),[l,d]=(0,I.useState)(!1),[u,c]=(0,I.useState)(!1),h=i.length<n.length,p=o.length>0;return e||t?(0,R.jsxs)("div",{className:rr.default["map-controls"],children:[e&&n.length>0&&!l&&!u&&(0,R.jsx)("button",{onClick:()=>d(!0),className:`${rr.default["map-control-icon"]} ${h?rr.default["map-control-icon--active"]:""}`,"aria-label":s("openFilter"),children:(0,R.jsx)(re,{})}),t&&!l&&!u&&(0,R.jsx)("button",{onClick:()=>c(!0),className:`${rr.default["map-control-icon"]} ${p?rr.default["map-control-icon--active"]:""}`,"aria-label":s("openSearch"),children:(0,R.jsx)(rt.default,{})}),e&&n.length>0&&l&&(0,R.jsx)(i7.MultiSelect,{data:n,value:i,onChange:r,placeholder:s("filter"),searchable:!0,clearable:!0,leftSection:(0,R.jsx)(re,{}),className:rr.default["map-filter"],onBlur:()=>d(!1),autoFocus:!0}),t&&u&&(0,R.jsx)(i9.TextInput,{value:o,onChange:e=>a(e.currentTarget.value),placeholder:s("search"),leftSection:(0,R.jsx)(rt.default,{}),className:rr.default["map-search"],onBlur:()=>c(!1),autoFocus:!0})]}):null},rv=({displayMarkers:e,maxZoom:t,autoZoom:n})=>{let i=ie(),{t:r}=(0,eS.useTranslations)(),o=I.default.useRef(null),[a,s]=I.default.useState(null),[l,d]=I.default.useState([]),[u,c]=I.default.useState(null);return I.default.useEffect(()=>{if(!i)return;let e=setTimeout(()=>
364{document.querySelectorAll(".gm-control-active").forEach(e=>{e.style.borderRadius="0.625rem",e.style.background="#fffc",e.style.boxShadow="var(--box-shadow-card)"});let e=document.querySelector(".gm-bundled-control");e&&(e.style.margin="1rem");let t=document.querySelector(".gm-fullscreen-control");t&&(t.style.margin="1rem")},1e3);return()=>clearTimeout(e)},[i]),I.default.useEffect(()=>{if(!i||!e.length||!n)return;let t=new google.maps.LatLngBounds;e.forEach(e=>{t.extend({lat:parseFloat(e.markerLatitude),lng:parseFloat(e.markerLongitude)})}),i.fitBounds(t)},[i,e,n]),I.default.useEffect(()=>{if(i)return o.current||(o.current=new i8({map:i,onClusterClick:(e,n,i)=>{(i.getZoom()||0)>=(t||21)?(d(n.markers),s(n.position.toJSON())):n.bounds&&i.fitBounds(n.bounds)},renderer:{render:({count:e,position:t,markers:n})=>{let i=n.map(e=>e.color).filter(Boolean),o=i.length>0&&i.every(e=>e===i[0]),a=[...new Set(n.map(e=>e.markerGroup).filter(Boolean))],s=a.length>0?a.join(", "):r("markers",{count:e}),l=document.createElement("div");l.className=o?`cluster-icon cluster-icon--${i[0]}`:"cluster-icon";let d=document.createElement("span");return d.textContent=String(e),d.title=s,l.appendChild(d),new google.maps.marker.AdvancedMarkerElement({position:t,content:l})}}})),()=>{o.current?.clearMarkers()}},[i]),(0,R.jsxs)(R.Fragment,{children:[e.map(e=>(0,R.jsx)(rh,{...e,clusterer:o.current,useDefaultPin:!0},`marker-${e.id}`)),a&&!u&&(0,R.jsx)(iS,{position:a,pixelOffset:[0,-40],onCloseClick:()=>s(null),maxWidth:200,headerContent:(0,R.jsxs)("span",{className:`${rr.default["infowindow-header"]} ${l[0]?.color?rr.default[`infowindow-icon--${l[0].color}`]:""}`,children:[(0,R.jsx)(ri,{}),1===l.length?r("marker"):r("markers",{count:l.length})]}),children:(0,R.jsx)("ol",{"data-marker-color":l[0]?.color||void 0,className:rr.default["infowindow-content"],children:l.map((e,t)=>(0,R.jsx)("li",{className:`${rr.default["cluster-marker"]} ${e.color?rr.default[`cluster-marker--${e.color}`]:""}`,onClick:t=>{"A"!==t.target.tagName&&c(e)},dangerouslySetInnerHTML:{__html:e.markerName||r("unknown")}},t))})}),u&&(0,R.jsx)(iS,{position:{lat:parseFloat(u.markerLatitude),lng:parseFloat(u.markerLongitude)},pixelOffset:[0,-40],onCloseClick:()=>c(null),maxWidth:200,headerContent:(0,R.jsxs)("span",{className:`${rr.default["infowindow-header"]} ${u.color?rr.default[`infowindow-icon--${u.color}`]:""}`,children:[(0,R.jsx)(rn,{}),(0,R.jsx)("span",{dangerouslySetInnerHTML:{__html:u.markerName}})]}),children:(0,R.jsx)("div",{"data-marker-color":u.color||void 0,children:(0,R.jsx)(ru,{color:u.color,markerGroup:u.markerGroup!==u.markerName?u.markerGroup:void 0,markerDescription:u.markerDescription,labels:u.labels})})})]})};e.s(["MapBlock",0,({id:e,width:t=100,mapCenterLatitude:n,mapCenterLongitude:i,mapZoomLevel:r,mapMinZoom:o,mapMaxZoom:a,mapFullscreenControl:s=!0,mapAspectRatio:l="16/9",mapShowLegend:d,filterEnabled:u,searchEnabled:c,markers:h=[],inGrid:p=!1})=>{var f;let g,{tenant:m}=(0,e_.useTenant)(),{t:v}=(0,eS.useTranslations)(),y=parseFloat(n)??52.0958,b=parseFloat(i)??5.6453,x=l?.startsWith("_")?l.substring(1).replace("_","/"):l?.replace("_","/")||"16/9",w=(0,I.useMemo)(()=>{let e=new Set;return h.forEach(t=>{t.labels&&t.labels.split(",").forEach(t=>e.add(t.trim()))}),Array.from(e)},[h]),[C,S]=(0,I.useState)(w),[_,k]=(0,I.useState)(""),M=(0,I.useMemo)(()=>h.filter(e=>{if(u&&e.labels&&!e.labels.split(",").map(e=>e.trim()).some(e=>C.includes(e)))return!1;if(c&&_&&e.searchKeywords){let t=e.searchKeywords.toLowerCase(),n=_.toLowerCase();if(!t.includes(n))return!1}return!0}),[h,C,_,u,c]);return(rf=(g=[...new Set((f=M).map(e=>e.markerGroup).filter(Boolean))]).map((e,t)=>({name:e,color:rp[t%rp.length]})),M=f.map(e=>({...e,color:e.markerGroup?rp[g.indexOf(e.markerGroup)%rp.length]:void 0})),m?.maps)?m?.googleMapsKey?(0,R.jsx)("div",{className:rr.default["map-container"],style:{width:`${t}%`},children:(0,R.jsxs)(eE.Paper,{radius:m?.Theme?.borderRadius||"md",style:{overflow:"hidden",aspectRatio:x},className:rr.default["map-wrapper"],children:[(0,R.jsx)(nG,{apiKey:m?.googleMapsKey||"",children:(0,R.jsx)(n8,{defaultCenter:{lat:y,lng:b},defaultZoom:r??7,minZoom:o,maxZoom:a,fullscreenControl:s,disableDefaultUI:!0,gestureHandling:"greedy",mapId:`map-${e}`,className:rr.default.map,children:(0,R.jsx)(rv,{displayMarkers:M,maxZoom:a,autoZoom:!r})})}),d&&(0,R.jsx)(rg,{}),(0,R.jsx)(rm,{filterEnabled:u,searchEnabled:c,allLabels:w,selectedLabels:C,setSelectedLabels:S,searchQuery:_,setSearchQuery:k})]})}):(0,R.jsx)("p",{children:"Missing Google Maps API key for this website."}):(0,R.jsx)("p",{children:"Maps feature is not enabled for this website."})}],34852);let ry=({csvData:e,delimiter:t=","})=>
364{if("string"!=typeof e||""===e.trim())return"Input must be a non-empty string.";let[n,...i]=e.trim().split(/\r?\n/);if(!n)return"CSV must have a header row.";let r=(e,t)=>{let n=[],i="",r=!1;for(let o=0;o<e.length;o++){let a=e[o];'"'===a?r=!r:a!==t||r?i+=a:(n.push(i.trim()),i="")}return n.push(i.trim()),n},o=r(n,t).map(e=>e.trim()),a=i.map(e=>r(e,t)),s=o.length;return a.every(e=>e.length===s)?{data:[o,...a],headColumns:s,headRows:1}:"All rows must have the same number of columns."};e.s(["parseCsv",0,ry],25363);var rb=I,rx=class{constructor(){this.allSyncListeners=new Map,this.allAsyncListeners=new Map,this.globalSyncListeners=new Set,this.globalAsyncListeners=new Set,this.asyncFunctionsQueue=[],this.scheduled=!1,this.firedEvents={}}setFrameworkOverrides(e){this.frameworkOverrides=e}getListeners(e,t,n){let i=t?this.allAsyncListeners:this.allSyncListeners,r=i.get(e);return!r&&n&&(r=new Set,i.set(e,r)),r}noRegisteredListenersExist(){return 0===this.allSyncListeners.size&&0===this.allAsyncListeners.size&&0===this.globalSyncListeners.size&&0===this.globalAsyncListeners.size}addEventListener(e,t,n=!1){this.getListeners(e,n,!0).add(t)}removeEventListener(e,t,n=!1){let i=this.getListeners(e,n,!1);i&&(i.delete(t),0===i.size&&(n?this.allAsyncListeners:this.allSyncListeners).delete(e))}addGlobalListener(e,t=!1){this.getGlobalListeners(t).add(e)}removeGlobalListener(e,t=!1){this.getGlobalListeners(t).delete(e)}dispatchEvent(e){this.dispatchToListeners(e,!0),this.dispatchToListeners(e,!1),this.firedEvents[e.type]=!0}dispatchEventOnce(e){this.firedEvents[e.type]||this.dispatchEvent(e)}dispatchToListeners(e,t){let n=e.type;if(t&&"event"in e){let t=e.event;t instanceof Event&&(e.eventPath=t.composedPath())}let{frameworkOverrides:i}=this,r=e=>{let n=i?()=>i.wrapIncoming(e):e;t?this.dispatchAsync(n):n()},o=this.getListeners(n,t,!1);if((o?.size??0)>0)for(let t of new Set(o))o?.has(t)&&r(()=>t(e));let a=this.getGlobalListeners(t);if(a.size>0)for(let t of new Set(a))r(()=>t(n,e))}getGlobalListeners(e){return e?this.globalAsyncListeners:this.globalSyncListeners}dispatchAsync(e){if(this.asyncFunctionsQueue.push(e),!this.scheduled){let e=()=>{window.setTimeout(this.flushAsyncQueue.bind(this),0)};this.frameworkOverrides?this.frameworkOverrides.wrapIncoming(e):e(),this.scheduled=!0}}flushAsyncQueue(){this.scheduled=!1;let e=this.asyncFunctionsQueue.slice();for(let t of(this.asyncFunctionsQueue=[],e))t()}};function rw(e){return null==e||""===e?null:e}function rC(e){return null!=e&&""!==e}function rS(e){return!rC(e)}function r_(e){return null!=e&&"function"==typeof e.toString?e.toString():null}function rk(e,t){return(e?JSON.stringify(e):null)===(t?JSON.stringify(t):null)}var rM=/[&<>"']/g,rT={"&":"&","<":"<",">":">",'"':""","'":"'"};function rD(e){return e?.toString().toString()??null}function rR(e){return rD(e)?.replace(rM,e=>rT[e])??null}function rI(e){return e.eRootDiv.getRootNode()}function rA(e){return rI(e).activeElement}function rP(e){let{gos:t,eRootDiv:n}=e,i=null,r=t.get("getDocument");return(r&&rC(r)?i=r():n&&(i=n.ownerDocument),i&&rC(i))?i:document}function rE(e){let t=rA(e);return null===t||t===rP(e).body}function rL(e){return rP(e).defaultView||window}function rF(e){let t=null,n=null;try{t=rP(e).fullscreenElement}catch(e){}finally{t||(t=rI(e));let i=t.querySelector("body");n=i||(t instanceof ShadowRoot?t:t instanceof Document?t?.documentElement:t)}return n}function rO(e,t,n){null==n||"string"==typeof n&&""==n?rB(e,t):rN(e,t,n)}function rN(e,t,n){var i;e.setAttribute((i=t,`aria-${i}`),n.toString())}function rB(e,t){var n;e.removeAttribute((n=t,`aria-${n}`))}function rz(e,t){t?e.setAttribute("role",t):e.removeAttribute("role")}function rj(e,t){rO(e,"label",t)}function rV(e,t){rO(e,"labelledby",t)}function rH(e,t){rO(e,"hidden",t)}function rG(e,t){rN(e,"expanded",t)}function rW(e,t){rN(e,"rowindex",t)}function r$(e,t){rN(e,"colindex",t)}function rU(e,t){rO(e,"selected",t)}function rq(e,t){return void 0===t?e("ariaIndeterminate","indeterminate"):!0===t?e("ariaChecked","checked"):e("ariaUnchecked","unchecked")}var rK="[disabled], .ag-disabled:not(.ag-button), .ag-disabled *";function rY(e){return!!e&&!!e.matches("input, select, button, textarea")&&!!e.matches(rK)&&oe(e)}function rZ(e,t,n={}){let{skipAriaHidden:i}=n;e.classList.toggle("ag-hidden",!t),i||rH(e,!t)}function rX(e,t){let n="disabled",i=t?e=>
364e.setAttribute(n,""):e=>e.removeAttribute(n);for(let t of(i(e),e.querySelectorAll("input")??[]))i(t)}function rJ(e,t,n){let i=0;for(;e;){if(e.classList.contains(t))return!0;if(e=e.parentElement,"number"==typeof n){if(++i>n)break}else if(e===n)break}return!1}function rQ(e){let{height:t,width:n,borderTopWidth:i,borderRightWidth:r,borderBottomWidth:o,borderLeftWidth:a,paddingTop:s,paddingRight:l,paddingBottom:d,paddingLeft:u,marginTop:c,marginRight:h,marginBottom:p,marginLeft:f,boxSizing:g}=window.getComputedStyle(e),m=Number.parseFloat;return{height:m(t||"0"),width:m(n||"0"),borderTopWidth:m(i||"0"),borderRightWidth:m(r||"0"),borderBottomWidth:m(o||"0"),borderLeftWidth:m(a||"0"),paddingTop:m(s||"0"),paddingRight:m(l||"0"),paddingBottom:m(d||"0"),paddingLeft:m(u||"0"),marginTop:m(c||"0"),marginRight:m(h||"0"),marginBottom:m(p||"0"),marginLeft:m(f||"0"),boxSizing:g}}function r0(e){let t=rQ(e);return"border-box"===t.boxSizing?t.height-t.paddingTop-t.paddingBottom-t.borderTopWidth-t.borderBottomWidth:t.height}function r1(e){let t=rQ(e);return"border-box"===t.boxSizing?t.width-t.paddingLeft-t.paddingRight-t.borderLeftWidth-t.borderRightWidth:t.width}function r2(e){let{height:t,marginBottom:n,marginTop:i}=rQ(e);return Math.floor(t+n+i)}function r3(e){let{width:t,marginLeft:n,marginRight:i}=rQ(e);return Math.floor(t+n+i)}function r5(e){let t=e.getBoundingClientRect(),{borderTopWidth:n,borderLeftWidth:i,borderRightWidth:r,borderBottomWidth:o}=rQ(e);return{top:t.top+(n||0),left:t.left+(i||0),right:t.right+(r||0),bottom:t.bottom+(o||0)}}function r4(e,t){let n=e.scrollLeft;return t&&(n=Math.abs(n)),n}function r6(e,t,n){n&&(t*=-1),e.scrollLeft=t}function r8(e){for(;e?.firstChild;)e.firstChild.remove()}function r7(e){e?.parentNode&&e.remove()}function r9(e){return!!e.offsetParent}function oe(e){return e.checkVisibility?e.checkVisibility({checkVisibilityCSS:!0}):!(!r9(e)||"visible"!==window.getComputedStyle(e).visibility)}function ot(e){let t=document.createElement("div");return t.innerHTML=(e||"").trim(),t.firstChild}function on(e){return()=>{let t=e();return!t||oi(t)||or(t)}}function oi(e){return e.clientWidth<e.scrollWidth}function or(e){return e.clientHeight<e.scrollHeight}function oo(e,t){"flex"===t?(e.style.removeProperty("width"),e.style.removeProperty("minWidth"),e.style.removeProperty("maxWidth"),e.style.flex="1 1 auto"):oa(e,t)}
364function oa(e,t){t=od(t),e.style.width=t,e.style.maxWidth=t,e.style.minWidth=t}function ol(e,t){t=od(t),e.style.height=t,e.style.maxHeight=t,e.style.minHeight=t}function od(e){return"number"==typeof e?`${e}px`:e}function ou(e){return e instanceof Node||e instanceof HTMLElement}function oc(e,t,n){null==n||""===n?e.removeAttribute(t):e.setAttribute(t,n.toString())}function oh(e,t,n){let i=rL(e).ResizeObserver,r=i?new i(n):null;return r?.observe(t),()=>r?.disconnect()}function op(e,t){let n=rL(e);n.requestAnimationFrame?n.requestAnimationFrame(t):n.webkitRequestAnimationFrame?n.webkitRequestAnimationFrame(t):n.setTimeout(t,0)}var of="data-ref";function og(){return m??(m=document.createTextNode(" ")),m.cloneNode()}function om(e){let{attrs:t,children:n,cls:i,ref:r,role:o,tag:a}=e,s=document.createElement(a);if(i&&(s.className=i),r&&s.setAttribute(of,r),o&&s.setAttribute("role",o),t)for(let e of Object.keys(t))s.setAttribute(e,t[e]);if(n)if("string"==typeof n)s.textContent=n;else{let e=!0;for(let t of n)t&&("string"==typeof t?(s.appendChild(document.createTextNode(t)),e=!1):"function"==typeof t?s.appendChild(t()):(e&&(s.appendChild(og()),e=!1),s.append(om(t)),s.appendChild(og())))}return s}var ov=["touchstart","touchend","touchmove","touchcancel","scroll"],oy=["wheel"],ob={},ox=(i={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"},e=>{if("boolean"==typeof ob[e])return ob[e];let t=document.createElement(i[e]||"div");return ob[e="on"+e]=e in t});function ow(e,t,n){return 0!==n&&Math.max(Math.abs(e.clientX-t.clientX),Math.abs(e.clientY-t.clientY))<=n}var oC=(e,t)=>{let n=e.identifier;for(let e=0,i=t.length;e<i;++e){let i=t[e];if(i.identifier===n)return i}return null};function oS(e,t){return e.gos.isElementInThisInstance(t.target)}var o_=(e,...t)=>{for(let n of t){let[t,i,r,o]=n;t.addEventListener(i,r,o),e.push(n)}},ok=e=>{if(e){for(let[t,n,i,r]of e)t.removeEventListener(n,i,r);e.length=0}},oM=e=>{e.cancelable&&e.preventDefault()};function oT(e,t){return t}function oD(e){return e?.getLocaleTextFunc()??oT}var oR=class{constructor(){this.destroyFunctions=[],this.destroyed=!1,this.__v_skip=!0,this.propertyListenerId=0,this.lastChangeSetIdLookup={},this.isAlive=()=>!this.destroyed}preWireBeans(e){this.beans=e,this.stubContext=e.context,this.eventSvc=e.eventSvc,this.gos=e.gos}destroy(){let{destroyFunctions:e}=this;for(let t=0;t<e.length;t++)e[t]();e.length=0,this.destroyed=!0,this.dispatchLocalEvent({type:"destroyed"})}addEventListener(e,t,n){this.localEventService||(this.localEventService=new rx),this.localEventService.addEventListener(e,t,n)}removeEventListener(e,t,n){this.localEventService?.removeEventListener(e,t,n)}dispatchLocalEvent(e){this.localEventService?.dispatchEvent(e)}addManagedElementListeners(e,t){return this._setupListeners(e,t)}addManagedEventListeners(e){return this._setupListeners(this.eventSvc,e)}addManagedListeners(e,t){return this._setupListeners(e,t)}_setupListeners(e,t){let n=[];for(let i of Object.keys(t)){let r=t[i];r&&n.push(this._setupListener(e,i,r))}return n}_setupListener(e,t,n){let i;if(this.destroyed)return()=>null;if(void 0!==e.__addEventListener)e.__addEventListener(t,n),i=()=>(e.__removeEventListener(t,n),null);else{let o="global"===e.eventServiceType;if(e instanceof HTMLElement){var r;let i,o,a,s;r=t,a=ov.includes(r),s=oy.includes(r),null!=(o=!!a||!s&&void 0)&&(i={passive:o}),e.addEventListener(t,n,i)}else o?e.addListener(t,n):e.addEventListener(t,n);i=o?()=>(e.removeListener(t,n),null):()=>(e.removeEventListener(t,n),null)}return this.destroyFunctions.push(i),()=>(i(),this.destroyFunctions=this.destroyFunctions.filter(e=>e!==i),null)}setupPropertyListener(e,t){let{gos:n}=this;n.addPropertyEventListener(e,t);let i=()=>(n.removePropertyEventListener(e,t),null);return this.destroyFunctions.push(i),()=>(i(),this.destroyFunctions=this.destroyFunctions.filter(e=>e!==i),null)}addManagedPropertyListener(e,t){return this.destroyed?()=>null:this.setupPropertyListener(e,t)}addManagedPropertyListeners(e,t){if(this.destroyed)return;let n=e.join("-")+this.propertyListenerId++,i=e=>{if(e.changeSet){if(e.changeSet&&e.changeSet.id===this.lastChangeSetIdLookup[n])return;this.lastChangeSetIdLookup[n]=e.changeSet.id}
364t({type:"propertyChanged",changeSet:e.changeSet,source:e.source})};for(let t of e)this.setupPropertyListener(t,i)}getLocaleTextFunc(){return oD(this.beans.localeSvc)}addDestroyFunc(e){this.isAlive()?this.destroyFunctions.push(e):e()}createOptionalManagedBean(e,t){return e?this.createManagedBean(e,t):void 0}createManagedBean(e,t){let n=this.createBean(e,t);return this.addDestroyFunc(this.destroyBean.bind(this,e,t)),n}createBean(e,t,n){return(t||this.stubContext).createBean(e,n)}destroyBean(e,t){return(t||this.stubContext).destroyBean(e)}destroyBeans(e,t){return(t||this.stubContext).destroyBeans(e)}},oI=class extends oR{},oA={};function oP(e,t){oA[t]||(e(),oA[t]=!0)}var oE={pending:!1,funcs:[]},oL={pending:!1,funcs:[]};function oF(e,t="setTimeout",n){let i="raf"===t?oL:oE;if(i.funcs.push(e),i.pending)return;i.pending=!0;let r=()=>{let e=i.funcs.slice();for(let t of(i.funcs.length=0,i.pending=!1,e))t()};"raf"===t?op(n,r):window.setTimeout(r,0)}function oO(e,t,n){let i;return function(...r){let o=this;window.clearTimeout(i),i=window.setTimeout(function(){e.isAlive()&&t.apply(o,r)},n)}}function oN(e,t){let n=0;return function(...i){let r=Date.now();r-n<t||(n=r,e.apply(this,i))}}var oB=new Set(["__proto__","constructor","prototype"]);function oz(e,t,n=!0,i=!1){rC(t)&&function(e,t){if(null!=e){if(Array.isArray(e)){for(let n=0;n<e.length;n++)t(n.toString(),e[n]);return}for(let n of Object.keys(e).filter(e=>!oB.has(e)))t(n,e[n])}}(t,(t,r)=>{let o=e[t];o!==r&&(i&&null==o&&null!=r&&"object"==typeof r&&r.constructor===Object&&(o={},e[t]=o),oj(r)&&oj(o)&&!Array.isArray(o)?oz(o,r,n,i):(n||void 0!==r)&&(e[t]=r))})}function oj(e){return"object"==typeof e&&null!==e}var oV=class e{static applyGlobalGridOptions(t){if(!e.gridOptions)return{...t};let n={};return oz(n,e.gridOptions,!0,!0),"deep"===e.mergeStrategy?oz(n,t,!0,!0):n={...n,...t},e.gridOptions.context&&(n.context=e.gridOptions.context),t.context&&("deep"===e.mergeStrategy&&n.context&&oz(t.context,n.context,!0,!0),n.context=t.context),n}static applyGlobalGridOption(t,n){if("deep"===e.mergeStrategy){let i=oH(t);if(i&&"object"==typeof i&&"object"==typeof n)return e.applyGlobalGridOptions({[t]:n})[t]}return n}};function oH(e){return oV.gridOptions?.[e]}oV.gridOptions=void 0,oV.mergeStrategy="shallow";var oG={suppressContextMenu:!1,preventDefaultOnContextMenu:!1,allowContextMenuWithControlKey:!1,suppressMenuHide:!0,enableBrowserTooltips:!1,tooltipTrigger:"hover",tooltipShowDelay:2e3,tooltipHideDelay:1e4,tooltipMouseTrack:!1,tooltipShowMode:"standard",tooltipInteraction:!1,copyHeadersToClipboard:!1,copyGroupHeadersToClipboard:!1,clipboardDelimiter:" ",suppressCopyRowsToClipboard:!1,suppressCopySingleCellRanges:!1,suppressLastEmptyLineOnPaste:!1,suppressClipboardPaste:!1,suppressClipboardApi:!1,suppressCutToClipboard:!1,maintainColumnOrder:!1,enableStrictPivotColumnOrder:!1,suppressFieldDotNotation:!1,allowDragFromColumnsToolPanel:!1,suppressMovableColumns:!1,suppressColumnMoveAnimation:!1,suppressMoveWhenColumnDragging:!1,suppressDragLeaveHidesColumns:!1,suppressRowGroupHidesColumns:!1,suppressAutoSize:!1,autoSizePadding:20,skipHeaderOnAutoSize:!1,singleClickEdit:!1,suppressClickEdit:!1,readOnlyEdit:!1,stopEditingWhenCellsLoseFocus:!1,enterNavigatesVertically:!1,enterNavigatesVerticallyAfterEdit:!1,enableCellEditingOnBackspace:!1,undoRedoCellEditing:!1,undoRedoCellEditingLimit:10,suppressCsvExport:!1,suppressExcelExport:!1,cacheQuickFilter:!1,includeHiddenColumnsInQuickFilter:!1,excludeChildrenWhenTreeDataFiltering:!1,enableAdvancedFilter:!1,includeHiddenColumnsInAdvancedFilter:!1,enableCharts:!1,masterDetail:!1,keepDetailRows:!1,keepDetailRowsCount:10,detailRowAutoHeight:!1,tabIndex:0,rowBuffer:10,valueCache:!1,valueCacheNeverExpires:!1,enableCellExpressions:!1,suppressTouch:!1,suppressFocusAfterRefresh:!1,suppressBrowserResizeObserver:!1,suppressPropertyNamesCheck:!1,suppressChangeDetection:!1,debug:!1,suppressLoadingOverlay:!1,suppressNoRowsOverlay:!1,pagination:!1,paginationPageSize:100,paginationPageSizeSelector:!0,paginationAutoPageSize:!1,paginateChildRows:!1,suppressPaginationPanel:!1,pivotMode:!1,pivotPanelShow:"never",pivotDefaultExpanded:0,pivotSuppressAutoColumn:!1,suppressExpandablePivotGroups:!1,functionsReadOnly:!1,suppressAggFuncInHeader:!1,alwaysAggregateAtRootLevel:!1,aggregateOnlyChangedColumns:!1,suppressAggFilteredOnly:!1,removePivotHeaderRowWhenSingleValueColumn:!1,animateRows:!0,cellFlashDuration:500,cellFadeDuration:1e3,allowShowChangeAfterFilter:!1,domLayout:"normal",ensureDomOrder:!1,enableRtl:!1,suppressColumnVirtualisation:!1,suppressMaxRenderedRowRestriction:!1,suppressRowVirtualisation:!1,rowDragManaged:!1,rowDragInsertDelay:500,suppressRowDrag:!1,suppressMoveWhenRowDragging:!1,rowDragEntireRow:!1,rowDragMultiRow:!1,embedFullWidthRows:!1,groupDisplayType:"singleColumn",groupDefaultExpanded:0,groupMaintainOrder:!1,groupSelectsChildren:!1,groupSuppressBlankHeader:!1,groupSelectsFiltered:!1,showOpenedGroup:!1,groupRemoveSingleChildren:!1,groupRemoveLowestSingleChildren:!1,groupHideOpenParents:!1,groupAllowUnbalanced:!1,rowGroupPanelShow:"never",suppressMakeColumnVisibleAfterUnGroup:!1,treeData:!1,rowGroupPanelSuppressSort:!1,suppressGroupRowsSticky:!1,rowModelType:"clientSide",asyncTransactionWaitMillis:50,suppressModelUpdateAfterUpdateTransaction:!1,cacheOverflowSize:1,infiniteInitialRowCount:1,serverSideInitialRowCount:1,cacheBlockSize:100,maxBlocksInCache:-1,maxConcurrentDatasourceRequests:2,blockLoadDebounceMillis:0,purgeClosedRowNodes:!1,serverSideSortAllLevels:!1,serverSideOnlyRefreshFilteredGroups:!1,serverSidePivotResultFieldSeparator:"_",viewportRowModelPageSize:5,viewportRowModelBufferSize:5,alwaysShowHorizontalScroll:!1,alwaysShowVerticalScroll:!1,debounceVerticalScrollbar:!1,suppressHorizontalScroll:!1,suppressScrollOnNewData:!1,suppressScrollWhenPopupsAreOpen:!1,suppressAnimationFrame:!1,suppressMiddleClickScrolls:!1,suppressPreventDefaultOnMouseWheel:!1,rowMultiSelectWithClick:!1,suppressRowDeselection:!1,suppressRowClickSelection:!1,suppressCellFocus:!1,suppressHeaderFocus:!1,suppressMultiRangeSelection:!1,enableCellTextSelection:!1,enableRangeSelection:!1,enableRangeHandle:!1,enableFillHandle:!1,fillHandleDirection:"xy",suppressClearOnFillReduction:!1,accentedSort:!1,unSortIcon:!1,suppressMultiSort:!1,alwaysMultiSort:!1,suppressMaintainUnsortedOrder:!1,suppressRowHoverHighlight:!1,suppressRowTransform:!1,columnHoverHighlight:!1,deltaSort:!1,enableGroupEdit:!1,groupLockGroupColumns:0,serverSideEnableClientSideSort:!1,suppressServerSideFullWidthLoadingRow:!1,pivotMaxGeneratedColumns:-1,columnMenu:"new",reactiveCustomComponents:!0,suppressSetFilterByDefault:!1,rowNumbers:!1,enableFilterHandlers:!1},oW="https://www.ag-grid.com";function o$(e,t,...n){e.get("debug")&&console.log("AG Grid: "+t,...n)}function oU(e,...t){oP(()=>console.warn("AG Grid: "+e,...t),e+t?.join(""))}function oq(e,...t){oP(()=>console.error("AG Grid: "+e,...t),e+t?.join(""))}var oK=new Set,oY={},oZ={},oX=!1,oJ=!1;function oQ(e,t,n=!1){let i,r,o;n||(oX=!0),v||(v=e.version),r=e=>`You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. ${e} Please update all modules to the same version.`,e.version?!function(e){let[t,n]=e.version.split(".")||[],[i,r]=v.split(".")||[];return t===i&&n===r}(e)&&oq(r(`'${e.moduleName}
364' is version ${e.version} but the other modules are version ${v}.`)):oq(r(`'${e.moduleName}' is incompatible.`)),(o=e.validate?.())&&!o.isValid&&oq(`${o.message}`);let a=e.rowModels??["all"];for(let n of(oK.add(e),void 0!==t?(oJ=!0,void 0===oZ[t]&&(oZ[t]={}),i=oZ[t]):i=oY,a))void 0===i[n]&&(i[n]={}),i[n][e.moduleName]=e;if(e.dependsOn)for(let i of e.dependsOn)oQ(i,t,n)}function o0(e,t,n){let i=n=>!!oY[n]?.[e]||!!oZ[t]?.[n]?.[e];return i(n)||i("all")}var o1="34.3.1",o2="_version_",o3=null,o5=`${oW}/javascript-data-grid`;function o4(e,t,n){return o3?.(e,t)??[ae(e,t,n)]}function o6(e,t,n,i,r){e(`${i?"warning":"error"} #${t}`,...o4(t,n,r))}function o8(e){return void 0===e?"undefined":null===e?"null":e}function o7(e,t){return`${e}?${t.toString()}`}function o9(e,t){let n=new URLSearchParams;if(n.append(o2,o1),t)for(let e of Object.keys(t))n.append(e,function(e){let t=e;return e instanceof Error?t=e.toString():"object"==typeof e&&(t=function(e){if(!e)return String(e);let t={};for(let n of Object.keys(e))"object"!=typeof e[n]&&"function"!=typeof e[n]&&(t[n]=e[n]);return JSON.stringify(t)}(e)),t}(t[e]));let i=`${o5}/errors/${e}`,r=o7(i,n);return r.length<=2e3?r:function(e,t,n){let i=Array.from(t.entries()).sort((e,t)=>t[1].length-e[1].length),r=o7(e,t);for(let[n,o]of i){if(n===o2)continue;let i=r.length-2e3;if(i<=0)break;let a=i+3,s=o.length-a>100?o.slice(0,o.length-a)+"...":o.slice(0,100)+"...";t.set(n,s),r=o7(e,t)}return r}(i,n,0)}var ae=(e,t,n)=>{let i=o9(e,t),r=`${n?n+" \n":""}Visit ${i}`;return`${r}${n?"":" \n Alternatively register the ValidationModule to see the full message in the console."}`};function at(...e){o6(oU,e[0],e[1],!0)}function an(...e){o6(oq,e[0],e[1],!1)}function ai(e,t,n){o6(oq,e,t,!1,n)}function ar(...e){var t;let n;return t=void 0,n=e[0],`error #${n} `+o4(n,e[1],t).join(" ")}function ao(e,t){return e.get("rowModelType")===t}function aa(e,t){return ao(e,"clientSide")}function as(e,t){return ao(e,"serverSide")}function al(e,t){return e.get("domLayout")===t}function ad(e){return void 0!==aI(e)}function au(e){return"function"==typeof e.get("getRowHeight")}function ac(e,t,n=!1,i){let{gos:r,environment:o}=e;if(null==i&&(i=o.getDefaultRowHeight()),au(r)){if(n)return{height:i,estimated:!0};let e={node:t,data:t.data},o=r.getCallback("getRowHeight")(e);if(ap(o))return 0===o&&at(23),{height:Math.max(1,o),estimated:!1}}if(t.detail&&r.get("masterDetail")){var a=r;if(a.get("detailRowAutoHeight"))return{height:1,estimated:!1};let e=a.get("detailRowHeight");return ap(e)?{height:e,estimated:!1}:{height:300,estimated:!1}}let s=r.get("rowHeight");return{height:s&&ap(s)?s:i,estimated:!1}}function ah(e){let{environment:t,gos:n}=e,i=n.get("rowHeight");if(!i||rS(i))return t.getDefaultRowHeight();let r=t.refreshRowHeightVariable();return -1!==r?r:(at(24),t.getDefaultRowHeight())}function ap(e){return!isNaN(e)&&"number"==typeof e&&isFinite(e)}function af(e,t,n){let i=t[e.getDomDataKey()];return i?i[n]:void 0}function ag(e,t,n,i){let r=e.getDomDataKey(),o=t[r];rS(o)&&(o={},t[r]=o),o[n]=i}function am(e){return!e.get("ensureDomOrder")&&e.get("animateRows")}function av(e){return!(e.get("paginateChildRows")||e.get("groupHideOpenParents")||al(e,"print"))}function ay(e){let t=e.get("autoGroupColumnDef");return!t?.comparator&&!e.get("treeData")}function ab(e){let t=e.get("groupAggFiltering");return"function"==typeof t?e.getCallback("groupAggFiltering"):!0===t?()=>!0:void 0}function ax(e,t){return!t&&"groupRows"===e.get("groupDisplayType")}function aw(e,t,n){return!!t.group&&!t.footer&&ax(e,n)}function aC(e){let t=e.getCallback("getRowId");return void 0===t?t:e=>{let n=t(e);return"string"!=typeof n&&(oP(()=>at(25,{id:n}),"getRowIdString"),n=String(n)),n}}function aS(e){return e?.checkboxes??!0}function a_(e){return e?.mode==="multiRow"&&(e.headerCheckbox??!0)}function ak(e){if("object"==typeof e)return e.checkboxLocation??"selectionColumn"}function aM(e){return e?.hideDisabledCheckboxes??!1}function aT(e){let t=e.get("cellSelection");return void 0!==t?!!t:e.get("enableRangeSelection")}function aD(e){let t=e.get("rowSelection")??"single";if("string"==typeof t){let t=e.get("suppressRowClickSelection"),n=e.get("suppressRowDeselection");return(!t||!n)&&(t?"enableDeselection":!n||"enableSelection")}return("singleRow"===t.mode||"multiRow"===t.mode)&&(t.enableClickSelection??!1)}function aR(e){let t=e.get("rowSelection");
364return"string"==typeof t?e.get("isRowSelectable"):t?.isRowSelectable}function aI(e){let t="beanName"in e&&"gos"===e.beanName?e.get("rowSelection"):e.rowSelection;if("string"==typeof t)switch(t){case"multiple":return"multiRow";case"single":return"singleRow";default:return}switch(t?.mode){case"multiRow":case"singleRow":return t.mode;default:return}}function aA(e){return"multiRow"===aI(e)}function aP(e){let t=e.get("rowSelection");if("string"==typeof t){let t=e.get("groupSelectsChildren"),n=e.get("groupSelectsFiltered");return t&&n?"filteredDescendants":t?"descendants":"self"}return t?.mode==="multiRow"?t.groupSelects:void 0}function aE(e,t=!0){let n=e.get("rowSelection");return"object"!=typeof n?t?"all":void 0:"multiRow"===n.mode?n.selectAll:"all"}function aL(e){let t=aP(e);return"descendants"===t||"filteredDescendants"===t}function aF(e){let t=e.get("rowSelection");return"object"==typeof t&&t.masterSelects||"self"}function aO(e){return"legacy"===e.get("columnMenu")}function aN(e,t){return e.addCommon(t)}function aB(e,t){return e[t]??e.gridOptions?.[t]??oH(t)??oG[t]}function az({gos:e},t){return 2===t.button||t.ctrlKey&&e.get("allowContextMenuWithControlKey")}var aj={resizable:!0,sortable:!0},aV=0;function aH(e){return e instanceof aG}var aG=class extends oI{constructor(e,t,n,i){super(),this.colDef=e,this.userProvidedColDef=t,this.colId=n,this.primary=i,this.isColumn=!0,this.instanceId=aV++,this.autoHeaderHeight=null,this.moving=!1,this.resizing=!1,this.menuVisible=!1,this.lastLeftPinned=!1,this.firstRightPinned=!1,this.filterActive=!1,this.colEventSvc=new rx,this.tooltipEnabled=!1,this.rowGroupActive=!1,this.pivotActive=!1,this.aggregationActive=!1,this.flex=null,this.colIdSanitised=rR(n)}destroy(){super.destroy(),this.beans.rowSpanSvc?.deregister(this)}getInstanceId(){return this.instanceId}setState(){let{colDef:e,beans:{sortSvc:t,pinnedCols:n,colFlex:i}}=this;t?.initCol(this);let r=e.hide;void 0!==r?this.visible=!r:this.visible=!e.initialHide,n?.initCol(this),i?.initCol(this)}setColDef(e,t,n){let i=e.spanRows!==this.colDef.spanRows;this.colDef=e,this.userProvidedColDef=t,this.initMinAndMaxWidths(),this.initDotNotation(),this.initTooltip(),i&&(this.beans.rowSpanSvc?.deregister(this),this.initRowSpan()),this.dispatchColEvent("colDefChanged",n)}getUserProvidedColDef(){return this.userProvidedColDef}getParent(){return this.parent}getOriginalParent(){return this.originalParent}postConstruct(){this.setState(),this.initMinAndMaxWidths(),this.resetActualWidth("gridInitializing"),this.initDotNotation(),this.initTooltip(),this.initRowSpan(),this.addPivotListener()}initDotNotation(){let{gos:e,colDef:{field:t,tooltipField:n}}=this,i=e.get("suppressFieldDotNotation");this.fieldContainsDots=rC(t)&&t.includes(".")&&!i,this.tooltipFieldContainsDots=rC(n)&&n.includes(".")&&!i}initMinAndMaxWidths(){let e=this.colDef;this.minWidth=e.minWidth??this.beans.environment.getDefaultColumnMinWidth(),this.maxWidth=e.maxWidth??Number.MAX_SAFE_INTEGER}initTooltip(){this.beans.tooltipSvc?.initCol(this)}initRowSpan(){this.colDef.spanRows&&this.beans.rowSpanSvc?.register(this)}addPivotListener(){let e=this.beans.pivotColDefSvc,t=this.colDef.pivotValueColumn;e&&t&&this.addManagedListeners(t,{colDefChanged:t=>{let n=e.recreateColDef(this.colDef);this.setColDef(n,n,t.source)}})}resetActualWidth(e){let t=this.calculateColInitialWidth(this.colDef);this.setActualWidth(t,e,!0)}calculateColInitialWidth(e){let t=e.width,n=e.initialWidth;return Math.max(Math.min(null!=t?t:null!=n?n:200,this.maxWidth),this.minWidth)}isEmptyGroup(){return!1}isRowGroupDisplayed(e){return this.beans.showRowGroupCols?.isRowGroupDisplayed(this,e)??!1}isPrimary(){return this.primary}isFilterAllowed(){return!!this.colDef.filter}isFieldContainsDots(){return this.fieldContainsDots}isTooltipEnabled(){return this.tooltipEnabled}isTooltipFieldContainsDots(){return this.tooltipFieldContainsDots}getHighlighted(){return this.highlighted}__addEventListener(e,t){this.colEventSvc.addEventListener(e,t)}__removeEventListener(e,t){this.colEventSvc.removeEventListener(e,t)}addEventListener(e,t){this.frameworkEventListenerService=this.beans.frameworkOverrides.createLocalEventListenerWrapper?.(this.frameworkEventListenerService,this.colEventSvc);let n=this.frameworkEventListenerService?.wrap(e,t)??t;this.colEventSvc.addEventListener(e,n)}removeEventListener(e,t){let n=this.frameworkEventListenerService?.unwrap(e,t)??t;this.colEventSvc.removeEventListener(e,n)}createColumnFunctionCallbackParams(e){return aN(this.gos,{node:e,data:e.data,column:this,colDef:this.colDef})}isSuppressNavigable(e){return this.beans.cellNavigation?.isSuppressNavigable(this,e)??!1}isCellEditable(e){return this.beans.editSvc?.isCellEditable({rowNode:e,column:this})??!1}isSuppressFillHandle(){return!!this.colDef.suppressFillHandle}isAutoHeight(){return!!this.colDef.autoHeight}isAutoHeaderHeight(){return!!this.colDef.autoHeaderHeight}isRowDrag(e){return this.isColumnFunc(e,this.colDef.rowDrag)}isDndSource(e){return this.isColumnFunc(e,this.colDef.dndSource)}isCellCheckboxSelection(e){return this.beans.selectionSvc?.isCellCheckboxSelection(this,e)??!1}isSuppressPaste(e){return this.isColumnFunc(e,this.colDef?.suppressPaste??null)}isResizable(){return!!this.getColDefValue("resizable")}getColDefValue(e){return this.colDef[e]??aj[e]}isColumnFunc(e,t){return"boolean"==typeof t?t:"function"==typeof t&&t(this.createColumnFunctionCallbackParams(e))}createColumnEvent(e,t){return aN(this.gos,{type:e,column:this,columns:[this],source:t})}isMoving(){return this.moving}getSort(){return this.sort}isSortable(){return!!this.getColDefValue("sortable")}isSortAscending(){return"asc"===this.sort}isSortDescending(){return"desc"===this.sort}isSortNone(){return rS(this.sort)}isSorting(){return rC(this.sort)}getSortIndex(){return this.sortIndex}isMenuVisible(){return this.menuVisible}getAggFunc(){return this.aggFunc}getLeft(){return this.left}getOldLeft(){return this.oldLeft}getRight(){return this.left+this.actualWidth}setLeft(e,t){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.dispatchColEvent("leftChanged",t))}isFilterActive(){return this.filterActive}isHovered(){return at(261),!!this.beans.colHover?.isHovered(this)}setFirstRightPinned(e,t){this.firstRightPinned!==e&&(this.firstRightPinned=e,this.dispatchColEvent("firstRightPinnedChanged",t))}setLastLeftPinned(e,t){this.lastLeftPinned!==e&&(this.lastLeftPinned=e,this.dispatchColEvent("lastLeftPinnedChanged",t))}isFirstRightPinned(){return this.firstRightPinned}isLastLeftPinned(){return this.lastLeftPinned}isPinned(){return"left"===this.pinned||"right"===this.pinned}isPinnedLeft(){return"left"===this.pinned}isPinnedRight(){return"right"===this.pinned}getPinned(){return this.pinned}setVisible(e,t){let n=!0===e;this.visible!==n&&(this.visible=n,this.dispatchColEvent("visibleChanged",t)),this.dispatchStateUpdatedEvent("hide")}isVisible(){return this.visible}
364isSpanHeaderHeight(){return!this.getColDef().suppressSpanHeaderHeight}getFirstRealParent(){let e=this.getOriginalParent();for(;e?.isPadding();)e=e.getOriginalParent();return e}getColumnGroupPaddingInfo(){let e=this.getParent();if(!e?.isPadding())return{numberOfParents:0,isSpanningTotal:!1};let t=e.getPaddingLevel()+1,n=!0;for(;e;){if(!e.isPadding()){n=!1;break}e=e.getParent()}return{numberOfParents:t,isSpanningTotal:n}}getColDef(){return this.colDef}getDefinition(){return this.colDef}getColumnGroupShow(){return this.colDef.columnGroupShow}getColId(){return this.colId}getId(){return this.colId}getUniqueId(){return this.colId}getActualWidth(){return this.actualWidth}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){let t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}createBaseColDefParams(e){return aN(this.gos,{node:e,data:e.data,colDef:this.colDef,column:this})}getColSpan(e){if(rS(this.colDef.colSpan))return 1;let t=this.createBaseColDefParams(e);return Math.max(this.colDef.colSpan(t),1)}getRowSpan(e){if(rS(this.colDef.rowSpan))return 1;let t=this.createBaseColDefParams(e);return Math.max(this.colDef.rowSpan(t),1)}setActualWidth(e,t,n=!1){e=Math.min(e=Math.max(e,this.minWidth),this.maxWidth),this.actualWidth!==e&&(this.actualWidth=e,null!=this.flex&&"flex"!==t&&"gridInitializing"!==t&&(this.flex=null),n||this.fireColumnWidthChangedEvent(t)),this.dispatchStateUpdatedEvent("width")}fireColumnWidthChangedEvent(e){this.dispatchColEvent("widthChanged",e)}isGreaterThanMax(e){return e>this.maxWidth}getMinWidth(){return this.minWidth}getMaxWidth(){return this.maxWidth}getFlex(){return this.flex}isRowGroupActive(){return this.rowGroupActive}isPivotActive(){return this.pivotActive}isAnyFunctionActive(){return this.isPivotActive()||this.isRowGroupActive()||this.isValueActive()}isAnyFunctionAllowed(){return this.isAllowPivot()||this.isAllowRowGroup()||this.isAllowValue()}isValueActive(){return this.aggregationActive}isAllowPivot(){return!0===this.colDef.enablePivot}isAllowValue(){return!0===this.colDef.enableValue}isAllowRowGroup(){return!0===this.colDef.enableRowGroup}dispatchColEvent(e,t,n){let i=this.createColumnEvent(e,t);n&&oz(i,n),this.colEventSvc.dispatchEvent(i)}dispatchStateUpdatedEvent(e){this.colEventSvc.dispatchEvent({type:"columnStateUpdated",key:e})}};function aW(e){return e instanceof a$}var a$=class extends oI{constructor(e,t,n,i){super(),this.colGroupDef=e,this.groupId=t,this.padding=n,this.level=i,this.isColumn=!1,this.expandable=!1,this.instanceId=aV++,this.expandableListenerRemoveCallback=null,this.expanded=!!e?.openByDefault}destroy(){this.expandableListenerRemoveCallback&&this.reset(null,void 0),super.destroy()}reset(e,t){this.colGroupDef=e,this.level=t,this.originalParent=null,this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback(),this.children=void 0,this.expandable=void 0}getInstanceId(){return this.instanceId}getOriginalParent(){return this.originalParent}getLevel(){return this.level}isVisible(){return!!this.children&&this.children.some(e=>e.isVisible())}isPadding(){return this.padding}setExpanded(e){this.expanded=void 0!==e&&e,this.dispatchLocalEvent({type:"expandedChanged"})}isExpandable(){return this.expandable}isExpanded(){return this.expanded}getGroupId(){return this.groupId}getId(){return this.getGroupId()}setChildren(e){this.children=e}getChildren(){return this.children}getColGroupDef(){return this.colGroupDef}getLeafColumns(){let e=[];return this.addLeafColumns(e),e}forEachLeafColumn(e){if(this.children)for(let t of this.children)aH(t)?e(t):aW(t)&&t.forEachLeafColumn(e)}addLeafColumns(e){if(this.children)for(let t of this.children)aH(t)?e.push(t):aW(t)&&t.addLeafColumns(e)}getColumnGroupShow(){let e=this.colGroupDef;if(e)return e.columnGroupShow}setupExpandable(){this.setExpandable(),this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback();let e=this.onColumnVisibilityChanged.bind(this);for(let t of this.getLeafColumns())t.__addEventListener("visibleChanged",e);this.expandableListenerRemoveCallback=()=>{for(let t of this.getLeafColumns())t.__removeEventListener("visibleChanged",e);this.expandableListenerRemoveCallback=null}}setExpandable(){if(this.isPadding())return;let e=!1,t=!1,n=!1,i=this.findChildrenRemovingPadding();for(let r=0,o=i.length;r<o;r++){let o=i[r];if(!o.isVisible())continue;let a=o.getColumnGroupShow();"open"===a?(e=!0,n=!0):"closed"===a?(t=!0,n=!0):(e=!0,t=!0)}let r=e&&t&&n;this.expandable!==r&&(this.expandable=r,this.dispatchLocalEvent({type:"exp
364andableChanged"}))}findChildrenRemovingPadding(){let e=[],t=n=>{for(let i of n)aW(i)&&i.isPadding()?t(i.children):e.push(i)};return t(this.children),e}onColumnVisibilityChanged(){this.setExpandable()}},aU={numericColumn:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"},rightAligned:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"}};function aq(e,t,n){let i={},r=e.gos;return Object.assign(i,r.get("defaultColGroupDef")),Object.assign(i,t),r.validateColDef(i,n),i}var aK=class{constructor(){this.existingKeys={}}addExistingKeys(e){for(let t=0;t<e.length;t++)this.existingKeys[e[t]]=!0}getUniqueKey(e,t){e=r_(e);let n=0;for(;;){let i=e??t;if(i?0!==n&&(i+="_"+n):i=n,!this.existingKeys[i]){let t=String(i);return e&&n>0&&at(273,{providedId:e,usedId:t}),this.existingKeys[t]=!0,t}n++}}};function aY(e){if(e?.length)return e[e.length-1]}function aZ(e,t,n){if(e===t)return!0;if(!e||!t)return null==e&&null==t;let i=e.length;if(i!==t.length)return!1;for(let r=0;r<i;r++)if(e[r]!==t[r]&&!n?.(e[r],t[r]))return!1;return!0}function aX(e,t){if(e)for(let n of e)t(n)}function aJ(e,t){let n=e.indexOf(t);n>=0&&e.splice(n,1)}function aQ(e,t,n){for(let n=0;n<t.length;n++)aJ(e,t[n]);for(let i=t.length-1;i>=0;i--)e.splice(n,0,t[i])}Object.freeze([]);var a0="ag-Grid-AutoColumn",a1="ag-Grid-SelectionColumn",a2="ag-Grid-RowNumbersColumn";function a3(e){let t=[],n=e=>{for(let i=0;i<e.length;i++){let r=e[i];aH(r)?t.push(r):aW(r)&&n(r.getChildren())}};return n(e),t}function a5(e){return e.reduce((e,t)=>e+t.getActualWidth(),0)}function a4(e,t,n){let i={};if(!t)return;sa(null,t,e=>{i[e.getInstanceId()]=e}),n&&sa(null,n,e=>{i[e.getInstanceId()]=null});let r=Object.values(i).filter(e=>null!=e);e.context.destroyBeans(r)}function a6(e){return e.getId().startsWith(a0)}function a8(e){let t="string"==typeof e?e:"getColId"in e?e.getColId():e.colId;return t?.startsWith(a1)??!1}function a7(e){let t="string"==typeof e?e:"getColId"in e?e.getColId():e.colId;return t?.startsWith(a2)??!1}function a9(e){let t=[];return e instanceof Array?t=e:"string"==typeof e&&(t=e.split(",")),t}function se(e){return"optionsUpdated"===e?"gridOptionsChanged":e}function st(e,t){let n=e===t,i=e.getColDef()===t,r=e.getColId()==t;return n||i||r}var sn=(e,t)=>{aW(e)&&e.setupExpandable(),e.originalParent=t};function si(e,t,n,i,r,o,a,s){if(!t)return[];let{colGroupSvc:l}=e,d=Array(t.length);for(let u=0;u<d.length;u++){let c=t[u];l&&void 0!==c.children?d[u]=l.createProvidedColumnGroup(i,c,n,r,o,a,s):d[u]=function(e,t,n,i,r,o){let a=function(e,t){if(t)for(let n=0;n<t.length;n++){let i=t[n].getUserProvidedColDef();if(i){if(null!=e.colId){if(t[n].getId()===e.colId)return{idx:n,column:t[n]};continue}
364if(null!=e.field){if(i.field===e.field)return{idx:n,column:t[n]};continue}if(i===e)return{idx:n,column:t[n]}}}}(n,i);a&&i?.splice(a.idx,1);let s=a?.column;if(s){let t=so(e,n,s.getColId());s.setColDef(t,n,o),function(e,t,n,i){sr(e,t,n.hide,n.sort,n.sortIndex,n.pinned,n.flex,i);let r=t.getFlex();if(null==r||!(r>0))if(null!=n.width)t.setActualWidth(n.width,i);else{let e=t.getActualWidth();t.setActualWidth(e,i)}}(e,s,t,o)}else{let i=r.getUniqueKey(n.colId,n.field);s=new aG(so(e,n,i),n,i,t),e.context.createBean(s)}return e.dataTypeSvc?.addColumnListeners(s),s}(e,i,c,r,o,s)}return d}function sr(e,t,n,i,r,o,a,s){let{sortSvc:l,pinnedCols:d,colFlex:u}=e;void 0!==n&&t.setVisible(!n,s),l&&(l.updateColSort(t,i,s),void 0!==r&&l.setColSortIndex(t,r)),void 0!==o&&d?.setColPinned(t,o),void 0!==a&&u?.setColFlex(t,a)}function so(e,t,n,i){var r,o,a,s;let l,d,{gos:u,dataTypeSvc:c}=e,h={};oz(h,u.get("defaultColDef"),!1,!0);let p=(r=e,o=h,a=t,s=n,l=r.dataTypeSvc?.updateColDefAndGetColumnType(o,a,s),d=a.type??l??o.type,o.type=d,d?a9(d):void 0);p&&function(e,t,n){if(!t.length)return;let i=Object.assign({},aU),r=e.gos.get("columnTypes")||{};for(let e of Object.keys(r)){let t=r[e];e in i?at(34,{key:e}):(t.type&&at(35),i[e]=t)}for(let e of t){let t=i[e.trim()];t?oz(n,t,!1,!0):at(36,{t:e})}}(e,p,h);let f=h.cellDataType;oz(h,t,!1,!0),void 0!==f&&(h.cellDataType=f);let g=u.get("autoGroupColumnDef"),m=ay(u);return t.rowGroup&&g&&m&&oz(h,{sort:g.sort,initialSort:g.initialSort},!1,!0),c&&(c.postProcess(h),c.validateColDef(h)),u.validateColDef(h,n,i),h}function sa(e,t,n){if(t)for(let i=0;i<t.length;i++){let r=t[i];aW(r)&&sa(r,r.getChildren(),n),n(r,e)}}function ss(e,t){let n=[],i=[],r=[];return(e.forEach(e=>{let t=e.getColDef().lockPosition;"right"===t?r.push(e):"left"===t||!0===t?n.push(e):i.push(e)}),t.get("enableRtl"))?[...r,...i,...n]:[...n,...i,...r]}function sl(e,t){let n=!0;return sa(null,t,t=>{if(!aW(t))return;let i=t.getColGroupDef();if(!i?.marryChildren)return;let r=[];for(let n of t.getLeafColumns()){let t=e.indexOf(n);r.push(t)}Math.max.apply(Math,r)-Math.min.apply(Math,r)>t.getLeafColumns().length-1&&(n=!1)}),n}function sd(e,t){if(!e||0==e.length)return;let n=t(e[0]);for(let i=1;i<e.length;i++)if(n!==t(e[i]))return;return n}function su(e,t,n){if(!t.length)return;let i=1===t.length?t[0]:null,r=sd(t,e=>e.getPinned());e.dispatchEvent({type:"columnPinned",pinned:null!=r?r:null,columns:t,column:i,source:n})}function sc(e,t,n,i,r=null){t?.length&&e.dispatchEvent({type:"columnResized",columns:t,column:1===t.length?t[0]:null,flexColumns:r,finished:n,source:i})}function sh(e,t,n){let{colModel:i,rowGroupColsSvc:r,pivotColsSvc:o,autoColSvc:a,selectionColSvc:s,colAnimation:l,visibleCols:d,pivotResultCols:u,environment:c,valueColsSvc:h,eventSvc:p,gos:f}=e,g=i.getColDefCols()??[],m=s?.getColumns();if(!g.length&&!m?.length)return!1;if(t?.state&&!t.state.forEach)return at(32),!1;let v=(i,a,s,l,d)=>{let u;if(!i)return;let p=(u=t.defaultState,(e,t)=>{let n={value1:void 0,value2:void 0},i=!1;return a&&(void 0!==a[e]&&(n.value1=a[e],i=!0),rC(t)&&void 0!==a[t]&&(n.value2=a[t],i=!0)),!i&&u&&(void 0!==u[e]&&(n.value1=u[e]),rC(t)&&void 0!==u[t]&&(n.value2=u[t])),n}),f=p("flex").value1;if(sr(e,i,p("hide").value1,p("sort").value1,p("sortIndex").value1,p("pinned").value1,f,n),null==f){let e=p("width").value1;if(null!=e){let t=i.getColDef().minWidth??c.getDefaultColumnMinWidth();null!=t&&e>=t&&i.setActualWidth(e,n)}}!d&&i.isPrimary()&&(h?.syncColumnWithState(i,n,p),r?.syncColumnWithState(i,n,p,s),o?.syncColumnWithState(i,n,p,l))},y=(l,u,c)=>{let h=sp(e,n),g=u.slice(),m={},y={},b=[],x=[],w=[],C=0,S=r?.columns.slice()??[],_=o?.columns.slice()??[];for(let e of l){let t=e.colId;if(t.startsWith(a0)){b.push(e),w.push(e);continue}if(a8(t)){x.push(e),w.push(e);continue}let n=c(t);n?(v(n,e,m,y,!1),aJ(g,n)):(w.push(e),C+=1)}let k=e=>v(e,null,m,y,!1);g.forEach(k),r?.sortColumns(sm.bind(r,m,S)),o?.sortColumns(sm.bind(o,y,_)),i.refreshCols(!1,n);let M=(e,t,n=[])=>{for(let i of t){let t=e(i.colId);aJ(n,t),v(t,i,null,null,!0)}n.forEach(k)};return M(e=>a?.getColumn(e)??null,b,a?.getColumns()?.slice()),M(e=>s?.getColumn(e)??null,x,s?.getColumns()?.slice()),function(e,t,n){if(!e.applyOrder||!e.state)return;let i=[];for(let t of e.state)null!=t.colId&&i.push(t.colId);!function(e,t,n,i){if(null==e)return;let r=[],o={};for(let n of t){if(o[n])continue;let t=e.map[n];t&&(r.push(t),o[n]=!0)}let a=0;for(let t of e.list){let e=t.getColId();null==o[e]&&(e.startsWith(a0)?r.splice(a++,0,t):r.push(t))}sl(r=ss(r,i),n.getColTree())?e.list=r:at(39)}(t.cols,i,t,n)}(t,i,f),d.refresh(n),p.dispatchEvent({type:"columnEverythingChanged",source:n}),h(),{unmatchedAndAutoStates:w,unmatchedCount:C}};l?.start();let{unmatchedAndAutoStates:b,unmatchedCount:x}=y(t.state||[],g,e=>i.getColDefCol(e));return(b.length>0||rC(t.defaultState))&&(x=y(b,u?.getPivotResultCols()?.list??[],e=>u?.getPivotResultCol(e)??null).unmatchedCount),l?.finish(),0===x}function sp(e,t){let{rowGroupColsSvc:n,pivotColsSvc:i,valueColsSvc:r,colModel:o,sortSvc:a,eventSvc:s}=e,l={rowGroupColumns:n?.columns.slice()??[],pivotColumns:i?.columns.slice()??[],valueColumns:r?.columns.slice()??[]},d=sf(e),u={};for(let e of d)u[e.colId]=e;return()=>{let r=(e,n,i,r)=>{if(aZ(n.map(r),i.map(r)))return;let o=new Set(n);for(let e of i)o.delete(e)||o.add(e);let a=[...o];s.dispatchEvent({type:e,columns:a,column:1===a.length?a[0]:null,source:t})},c=e=>{let t=[];return o.forAllCols(n=>{let i=u[n.getColId()];
364i&&e(i,n)&&t.push(n)}),t},h=e=>e.getColId();r("columnRowGroupChanged",l.rowGroupColumns,n?.columns??[],h),r("columnPivotChanged",l.pivotColumns,i?.columns??[],h);let p=c((e,t)=>{let n=null!=e.aggFunc,i=n!=t.isValueActive(),r=n&&e.aggFunc!=t.getAggFunc();return i||r});p.length>0&&s.dispatchEvent({type:"columnValueChanged",columns:p,column:p&&1==p.length?p[0]:null,source:t}),sc(s,c((e,t)=>e.width!=t.getActualWidth()),!0,t),su(s,c((e,t)=>e.pinned!=t.getPinned()),t),!function(e,t,n){if(!t.length)return;let i=1===t.length?t[0]:null,r=sd(t,e=>e.isVisible());e.dispatchEvent({type:"columnVisible",visible:r,columns:t,column:i,source:n})}(s,c((e,t)=>e.hide==t.isVisible()),t);let f=c((e,t)=>e.sort!=t.getSort()||e.sortIndex!=t.getSortIndex());f.length>0&&a?.dispatchSortChangedEvents(t,f),function(e,t,n,i,r){let o={};for(let e of t)o[e.colId]=e;let a={};for(let t of e)o[t.colId]&&(a[t.colId]=!0);let s=e.filter(e=>a[e.colId]),l=t.filter(e=>a[e.colId]),d=[];l.forEach((e,t)=>{let n=s?.[t];if(n&&n.colId!==e.colId){let e=i.getCol(n.colId);e&&d.push(e)}}),d.length&&r.dispatchEvent({type:"columnMoved",columns:d,column:1===d.length?d[0]:null,finished:!0,source:n})}(d,sf(e),t,o,s)}}function sf(e){let{colModel:t,rowGroupColsSvc:n,pivotColsSvc:i}=e;if(rS(t.getColDefCols())||!t.isAlive())return[];let r=n?.columns,o=i?.columns,a=[];t.forAllCols(e=>{let t,n,i,s,l;return t=e.isRowGroupActive()&&r?r.indexOf(e):null,n=e.isPivotActive()&&o?o.indexOf(e):null,i=e.isValueActive()?e.getAggFunc():null,s=null!=e.getSort()?e.getSort():null,l=null!=e.getSortIndex()?e.getSortIndex():null,void a.push({colId:e.getColId(),width:e.getActualWidth(),hide:!e.isVisible(),pinned:e.getPinned(),sort:s,sortIndex:l,aggFunc:i,rowGroup:e.isRowGroupActive(),rowGroupIndex:t,pivot:e.isPivotActive(),pivotIndex:n,flex:e.getFlex()??null})});let s=new Map(t.getCols().map((e,t)=>[e.getColId(),t]));return a.sort((e,t)=>(s.has(e.colId)?s.get(e.colId):-1)-(s.has(t.colId)?s.get(t.colId):-1)),a}function sg(e){let t=(e,t)=>null!=e?e:null!=t?t:null,n=e.getColDef(),i=t(n.sort,n.initialSort),r=t(n.sortIndex,n.initialSortIndex),o=t(n.hide,n.initialHide),a=t(n.pinned,n.initialPinned),s=t(n.width,n.initialWidth),l=t(n.flex,n.initialFlex),d=t(n.rowGroupIndex,n.initialRowGroupIndex),u=t(n.rowGroup,n.initialRowGroup);null!=d||u||(d=null,u=null);let c=t(n.pivotIndex,n.initialPivotIndex),h=t(n.pivot,n.initialPivot);null!=c||h||(c=null,h=null);let p=t(n.aggFunc,n.initialAggFunc);return{colId:e.getColId(),sort:i,sortIndex:r,hide:o,pinned:a,width:s,flex:l,rowGroup:u,rowGroupIndex:d,pivot:h,pivotIndex:c,aggFunc:p}}var sm=(e,t,n,i)=>{let r=e[n.getId()],o=e[i.getId()],a=null!=r,s=null!=o;if(a&&s)return r-o;if(a)return -1;if(s)return 1;let l=t.indexOf(n),d=t.indexOf(i),u=l>=0;return u&&d>=0?l-d:u?-1:1},sv=class extends oI{constructor(){super(...arguments),this.beanName="colModel",this.pivotMode=!1,this.ready=!1,this.changeEventsDispatching=!1}postConstruct(){this.pivotMode=this.gos.get("pivotMode"),this.addManagedPropertyListeners(["groupDisplayType","treeData","treeDataDisplayType","groupHideOpenParents","rowNumbers","hidePaddedHeaderRows"],e=>this.refreshAll(se(e.source))),this.addManagedPropertyListeners(["defaultColDef","defaultColGroupDef","columnTypes","suppressFieldDotNotation"],this.recreateColumnDefs.bind(this)),this.addManagedPropertyListener("pivotMode",e=>this.setPivotMode(this.gos.get("pivotMode"),se(e.source)))}createColsFromColDefs(e){let{beans:t}=this,{valueCache:n,colAutosize:i,rowGroupColsSvc:r,pivotColsSvc:o,valueColsSvc:a,visibleCols:s,eventSvc:l,groupHierarchyColSvc:d}=t,u=this.colDefs?sp(t,e):void 0;n?.expire();let c=this.colDefCols?.list,h=this.colDefCols?.tree,p=function(e,t=null,n,i,r){var o;let a,s,l,d=new aK,{existingCols:u,existingGroups:c,existingColKeys:h}=(a=[],s=[],l=[],(o=i)&&sa(null,o,e=>{aW(e)?s.push(e):(l.push(e.getId()),a.push(e))}),{existingCols:a,existingGroups:s,existingColKeys:l});d.addExistingKeys(h);let p=si(e,t,0,n,u,d,c,r),{colGroupSvc:f}=e,g=f?.findMaxDepth(p,0)??0,m=f?f.balanceColumnTree(p,0,g,d):p;return sa(null,m,sn),{columnTree:m,treeDepth:g}}(t,this.colDefs,!0,h,e);a4(t,this.colDefCols?.tree,p.columnTree);
364let f=p.columnTree,g=p.treeDepth,m=a3(f),v={};for(let e of m)v[e.getId()]=e;this.colDefCols={tree:f,treeDepth:g,list:m,map:v},this.createColumnsForService([d],this.colDefCols,e),r?.extractCols(e,c),o?.extractCols(e,c),a?.extractCols(e,c),this.ready=!0,this.refreshCols(!0,e),s.refresh(e),l.dispatchEvent({type:"columnEverythingChanged",source:e}),u&&(this.changeEventsDispatching=!0,u(),this.changeEventsDispatching=!1),l.dispatchEvent({type:"newColumnsLoaded",source:e}),"gridInitializing"===e&&i?.applyAutosizeStrategy()}refreshCols(e,t){var n;if(!this.colDefCols)return;let i=this.cols?.tree;this.saveColOrder();let{autoColSvc:r,selectionColSvc:o,rowNumbersSvc:a,quickFilter:s,pivotResultCols:l,showRowGroupCols:d,rowAutoHeight:u,visibleCols:c,colViewport:h,eventSvc:p}=this.beans,f=this.selectCols(l,this.colDefCols);this.createColumnsForService([r,o,a],f,t);let g=(n=this.gos,this.showingPivotResult?!n.get("enableStrictPivotColumnOrder"):n.get("maintainColumnOrder"));(!e||g)&&this.restoreColOrder(f),this.positionLockedCols(f),d?.refresh(),s?.refreshCols(),this.setColSpanActive(),u?.setAutoHeightActive(f),c.clear(),h.clear(),aZ(i,this.cols.tree)||p.dispatchEvent({type:"gridColumnsChanged"})}createColumnsForService(e,t,n){for(let i of e)i&&(i.createColumns(t,e=>{this.lastOrder=e(this.lastOrder),this.lastPivotOrder=e(this.lastPivotOrder)},n),i.addColumns(t))}selectCols(e,t){let n=e?.getPivotResultCols()??null;this.showingPivotResult=null!=n;let{map:i,list:r,tree:o,treeDepth:a}=n??t;return this.cols={list:r.slice(),map:{...i},tree:o.slice(),treeDepth:a},n&&(n.list.some(e=>this.cols?.map[e.getColId()]!==void 0)||(this.lastPivotOrder=null)),this.cols}getColsToShow(){if(!this.cols)return[];let{valueColsSvc:e,selectionColSvc:t,gos:n}=this.beans,i=this.isPivotMode()&&!this.showingPivotResult,r=t?.isSelectionColumnEnabled(),o=n.get("rowNumbers"),a=e?.columns;return this.cols.list.filter(e=>{let t=a6(e);if(!i)return t||e.isVisible();{let n=a?.includes(e);return t||n||r&&a8(e)||o&&a7(e)}})}refreshAll(e){this.ready&&(this.refreshCols(!1,e),this.beans.visibleCols.refresh(e))}setColsVisible(e,t=!1,n){sh(this.beans,{state:e.map(e=>({colId:"string"==typeof e?e:e.getColId(),hide:!t}))},n)}restoreColOrder(e){let t=this.showingPivotResult?this.lastPivotOrder:this.lastOrder;if(!t)return;let n=t.filter(t=>null!=e.map[t.getId()]);if(0===n.length)return;if(n.length===e.list.length){e.list=n;return}let i=e=>{let t=e.getOriginalParent();return!!t&&(t.getChildren().length>1||i(t))};if(!n.some(e=>i(e))){let t=new Set(n);for(let i of e.list)t.has(i)||n.push(i);e.list=n;return}let r=new Map;for(let e=0;e<n.length;e++){let t=n[e];r.set(t,e)}let o=e.list.filter(e=>!r.has(e));if(0===o.length){e.list=n;return}let a=(e,t)=>{let n=t?t.getOriginalParent():e.getOriginalParent();if(!n)return null;let i=null,o=null;for(let a of n.getChildren())if(a!==t&&a!==e){if(a instanceof aG){let e=r.get(a);if(null==e)continue;(null==i||i<e)&&(i=e,o=a);continue}a.forEachLeafColumn(e=>{let t=r.get(e);null!=t&&(null==i||i<t)&&(i=t,o=e)})}return null==o?a(e,n):o},s=[],l=new Map;for(let e of o){let t=a(e,null);if(null==t){s.push(e);continue}let n=l.get(t);void 0===n?l.set(t,e):Array.isArray(n)?n.push(e):l.set(t,[n,e])}let d=Array(e.list.length),u=d.length-1;for(let e=s.length-1;e>=0;e--)d[u--]=s[e];for(let e=n.length-1;e>=0;e--){let t=n[e],i=l.get(t);if(i)if(Array.isArray(i))for(let e=i.length-1;e>=0;e--){let t=i[e];d[u--]=t}else d[u--]=i;d[u--]=t}e.list=d}positionLockedCols(e){e.list=ss(e.list,this.gos)}saveColOrder(){this.showingPivotResult?this.lastPivotOrder=this.cols?.list??null:this.lastOrder=this.cols?.list??null}getColumnDefs(e){return this.colDefCols&&this.beans.colDefFactory?.getColumnDefs(this.colDefCols.list,this.showingPivotResult,this.lastOrder,this.cols?.list??[],e)}setColSpanActive(){this.colSpanActive=!!this.cols?.list.some(e=>null!=e.getColDef().colSpan)}isPivotMode(){return this.pivotMode}setPivotMode(e,t){if(e===this.pivotMode||(this.pivotMode=e,!this.ready))return;this.refreshCols(!1,t);let{visibleCols:n,eventSvc:i}=this.beans;n.refresh(t),i.dispatchEvent({type:"columnPivotModeChanged"})}isPivotActive(){let e=this.beans.pivotColsSvc?.columns;return this.pivotMode&&!!e?.length}recreateColumnDefs(e){if(!this.cols)return;this.beans.autoColSvc?.updateColumns(e);let t=se(e.source);this.createColsFromColDefs(t)}setColumnDefs(e,t){this.colDefs=e,this.createColsFromColDefs(t)}destroy(){a4(this.beans,this.colDefCols?.tree),super.destroy()}getColTree(){return this.cols?.tree??[]}getColDefColTree(){return this.colDefCols?.tree??[]}getColDefCols(){return this.colDefCols?.list??null}getCols(){return this.cols?.list??[]}forAllCols(e){let{pivotResultCols:t,autoColSvc:n,selectionColSvc:i,groupHierarchyColSvc:r}=this.beans;aX(this.colDefCols?.list,e),aX(n?.columns?.list,e),aX(i?.columns?.list,e),aX(r?.columns?.list,e),aX(t?.getPivotResultCols()?.list,e)}getColsForKeys(e){return e?e.map(e=>this.getCol(e)).filter(e=>null!=e):[]}getColDefCol(e){return this.colDefCols?.list?this.getColFromCollection(e,this.colDefCols):null}getCol(e){return null==e?null:this.getColFromCollection(e,this.cols)}getColById(e){return this.cols?.map[e]??null}getColFromCollection(e,t){if(null==t)return null;let{map:n,list:i}=t;if("string"==typeof e&&n[e])return n[e];for(let t=0;t<i.length;t++)if(st(i[t],e))return i[t];let{autoColSvc:r,selectionColSvc:o,groupHierarchyColSvc:a}=this.beans;return r?.getColumn(e)??o?.getColumn(e)??a?.getColumn(e)??null}},sy=class{constructor(){this.existingIds={}}getInstanceIdForKey(e){let t,n=this.existingIds[e];return t="number"!=typeof n?0:n+1,this.existingIds[e]=t,t}},sb=class extends oI{};function sx(e,t,n){return n&&e.addDestroyFunc(()=>t.destroyBean(n)),n??e}function sw(e){return"function"==typeof e?.getGui}var sC=class{constructor(e){this.cssClassStates={},this.getGui=e}toggleCss(e,t){if(e){if(e.indexOf(" ")>=0){let n=(e||"").split(" ");if(n.length>1){for(let e of n)this.toggleCss(e,t);return}}this.cssClassStates[e]!==t&&e.length&&(this.getGui()?.classList.toggle(e,t),this.cssClassStates[e]=t)}}},sS=0,s_=class extends oR{constructor(e,t){super(),this.suppressDataRefValidation=!1,this.displayed=!0,this.visible=!0,this.compId=sS++,this.cssManager=new sC(()=>this.eGui),this.componentSelectors=new Map((t??[]).map(e=>[e.selector,e])),e&&this.setTemplate(e)}preConstruct(){this.wireTemplate(this.getGui());let e="component-"+Object.getPrototypeOf(this)?.constructor?.name;for(let t of this.css??[])this.beans.environment.addGlobalCSS(t,e)}wireTemplate(e,t){e&&this.gos&&(this.applyElementsToComponent(e),this.createChildComponentsFromTags(e,t))}getCompId(){return this.compId}getDataRefAttribute(e){return e.getAttribute?e.getAttribute(of):null}applyElementsToComponent(e,t,n,i=null){if(void 0===t&&(t=this.getDataRefAttribute(e)),t){let r=this[t];if(null===r)this[t]=i??e;else{let e=n?.[t];if(!this.suppressDataRefValidation&&!e)throw Error(`data-ref: ${t} on ${this.constructor.name} with ${r}`)}}}createChildComponentsFromTags(e,t){let n=[];for(let t of e.childNodes??[])n.push(t);for(let i of n){if(!(i instanceof HTMLElement))continue;let n=this.createComponentFromElement(i,e=>{let t=e.getGui();if(t)for(let e of i.attributes??[])t.setAttribute(e.name,e.value)},t);if(n){if(n.addItems&&i.children.length){this.createChildComponentsFromTags(i,t);let e=Array.prototype.slice.call(i.children);n.addItems(e)}this.swapComponentForNode(n,e,i)}else i.childNodes&&this.createChildComponentsFromTags(i,t)}}createComponentFromElement(e,t,n){let i=e.nodeName,r=this.getDataRefAttribute(e),o=0===i.indexOf("AG-"),a=o?this.componentSelectors.get(i):null,s=null;if(a){let e=n&&r?n[r]:void 0;(s=new a.component(e)).setParentComponent(this),this.createBean(s,null,t)}else if(o)throw Error(`selector: ${i}`);return this.applyElementsToComponent(e,r,n,s),s}swapComponentForNode(e,t,n){let i=e.getGui();t.replaceChild(i,n),t.insertBefore(document.createComment(n.nodeName),i),this.addDestroyFunc(this.destroyBean.bind(this,e))}activateTabIndex(e){let t=this.gos.get("tabIndex");for(let n of(e||(e=[]),e.length||e.push(this.getGui()),e))n.setAttribute("tabindex",t.toString())}setTemplate(e,t,n){let i;i="string"==typeof e||null==e?ot(e):om(e),this.setTemplateFromElement(i,t,n)}setTemplateFromElement(e,t,n,i=!1){if(this.eGui=e,this.suppressDataRefValidation=i,t)for(let e=0;e<t.length;e++){let n=t[e];this.componentSelectors.set(n.selector,n)}this.wireTemplate(e,n)}getGui(){return this.eGui}getFocusableElement(){return this.eGui}getAriaElement(){return this.getFocusableElement()}setParentComponent(e){this.parentComponent=e}getParentComponent(){return this.parentComponent}setGui(e){this.eGui=e}queryForHtmlElement(e){return this.eGui.querySelector(e)}getContainerAndElement(e,t){let n=t;return null==e?null:(n||(n=this.eGui),ou(e))?{element:e,parent:n}:{element:e.getGui(),parent:n}}prependChild(e,t){let{element:n,parent:i}=this.getContainerAndElement(e,t)||{};n&&i&&i.insertAdjacentElement("afterbegin",n)}appendChild(e,t){let{element:n,parent:i}=this.getContainerAndElement(e,t)||{};n&&i&&i.appendChild(n)}isDisplayed(){return this.displayed}setVisible(e,t={}){if(e!==this.visible){this.visible=e;let{skipAriaHidden:n}=t;!function(e,t,n={}){let{skipAriaHidden:i}=n;e.classList.toggle("ag-invisible",!t),i||rH(e,!t)}(this.eGui,e,{skipAriaHidden:n})}}setDisplayed(e,t={}){if(e!==this.displayed){this.displayed=e;let{skipAriaHidden:n}=t;rZ(this.eGui,e,{skipAriaHidden:n});let i={type:"displayChanged",visible:this.displayed};this.dispatchLocalEvent(i)}}destroy(){this.parentComponent&&(this.parentComponent=void 0),super.destroy()}
364addGuiEventListener(e,t,n){this.eGui.addEventListener(e,t,n),this.addDestroyFunc(()=>this.eGui.removeEventListener(e,t))}addCss(e){this.cssManager.toggleCss(e,!0)}removeCss(e){this.cssManager.toggleCss(e,!1)}toggleCss(e,t){this.cssManager.toggleCss(e,t)}registerCSS(e){this.css||(this.css=[]),this.css.push(e)}},sk=class extends s_{};function sM(e){return"object"==typeof e&&!!e.component}var sT=class e{constructor(e){this.status=0,this.resolution=null,this.waiters=[],e(e=>this.onDone(e),e=>this.onReject(e))}static all(t){return t.length?new e(e=>{let n=t.length,i=Array(n);t.forEach((t,r)=>{t.then(t=>{i[r]=t,0==--n&&e(i)})})}):e.resolve()}static resolve(t=null){return new e(e=>e(t))}then(t){return new e(e=>{1===this.status?e(t(this.resolution)):this.waiters.push(n=>e(t(n)))})}onDone(e){for(let t of(this.status=1,this.resolution=e,this.waiters))t(e)}onReject(e){}};function sD(e,t,n,i){let r,o,a,s,l,d,{name:u}=n;if(t){let n=t[u+"Selector"],c=n?n(i):null,h=t=>{"string"==typeof t?r=t:null!=t&&!0!==t&&(e.isFrameworkComponent(t)?a=t:o=t)};c?(h(c.component),s=c.params,l=c.popup,d=c.popupPosition):h(t[u])}return{compName:r,jsComp:o,fwComp:a,paramsFromSelector:s,popupFromSelector:l,popupPositionFromSelector:d}}var sR=class extends oI{constructor(){super(...arguments),this.beanName="userCompFactory"}wireBeans(e){this.agCompUtils=e.agCompUtils,this.registry=e.registry,this.frameworkCompWrapper=e.frameworkCompWrapper,this.gridOptions=e.gridOptions}getCompDetailsFromGridOptions(e,t,n,i=!1){return this.getCompDetails(this.gridOptions,e,t,n,i)}getCompDetails(e,t,n,i,r=!1){var o;let a,s,{name:l,cellRenderer:d}=t,{compName:u,jsComp:c,fwComp:h,paramsFromSelector:p,popupFromSelector:f,popupPositionFromSelector:g}=sD(this.beans.frameworkOverrides,e,t,i),m=e=>{let t=this.registry.getUserComponent(l,e);t&&(c=t.componentFromFramework?void 0:t.component,h=t.componentFromFramework?t.component:void 0,a=t.params,s=t.processParams)};if(null!=u&&m(u),null==c&&null==h&&null!=n&&m(n),c&&d&&!((o=c)&&o.prototype&&"getGui"in o.prototype)&&(c=this.agCompUtils?.adaptFunction(t,c)),!c&&!h){let{validation:e}=this.beans;r&&(u!==n||!n)?u?e?.isProvidedUserComp(u)||an(50,{compName:u}):n?e||an(260,{...this.gos.getModuleErrorParams(),propName:l,compName:n}):an(216,{name:l}):n&&!e&&an(146,{comp:n});return}
364let v=this.mergeParams(e,t,i,p,a,s),y=null==c,b=c??h;return{componentFromFramework:y,componentClass:b,params:v,type:t,popupFromSelector:f,popupPositionFromSelector:g,newAgStackInstance:()=>this.newAgStackInstance(b,y,v,t)}}newAgStackInstance(e,t,n,i){let r;r=t?this.frameworkCompWrapper.wrap(e,i.mandatoryMethods,i.optionalMethods,i):new e,this.createBean(r);let o=r.init?.(n);return null==o?sT.resolve(r):o.then(()=>r)}mergeParams(e,t,n,i=null,r,o){let a={...n,...r},s=e?.[t.name+"Params"];return"function"==typeof s?oz(a,s(n)):"object"==typeof s&&oz(a,s),oz(a,i),o?o(a):a}},sI={name:"dateComponent",mandatoryMethods:["getDate","setDate"],optionalMethods:["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled","refresh"]},sA={name:"dragAndDropImageComponent",mandatoryMethods:["setIcon","setLabel"]},sP={name:"headerComponent",optionalMethods:["refresh"]},sE={name:"innerHeaderComponent"},sL={name:"innerHeaderGroupComponent"},sF={name:"headerGroupComponent"},sO={name:"cellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},sN={name:"loadingCellRenderer",cellRenderer:!0},sB={name:"cellEditor",mandatoryMethods:["getValue"],optionalMethods:["isPopup","isCancelBeforeStart","isCancelAfterEnd","getPopupPosition","focusIn","focusOut","afterGuiAttached","refresh"]},sz={name:"loadingOverlayComponent",optionalMethods:["refresh"]},sj={name:"noRowsOverlayComponent",optionalMethods:["refresh"]},sV={name:"filter",mandatoryMethods:["isFilterActive","doesFilterPass","getModel","setModel"],optionalMethods:["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onFloatingFilterChanged","onAnyFilterChanged","refresh"]},sH={name:"floatingFilterComponent",mandatoryMethods:["onParentModelChanged"],optionalMethods:["afterGuiAttached","refresh"]},sG={name:"fullWidthCellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},sW={name:"loadingCellRenderer",cellRenderer:!0},s$={name:"groupRowRenderer",optionalMethods:["afterGuiAttached"],cellRenderer:!0},sU={name:"detailCellRenderer",optionalMethods:["refresh"],cellRenderer:!0};function sq(e,t,n){return e.getCompDetails(t,sO,void 0,n)}function sK(e,t,n){return e.getCompDetails(t,sN,"agSkeletonCellRenderer",n,!0)}function sY(e,t,n){return e.mergeParams(t,sV,n)}function sZ(e){return e?.getFrameworkComponentInstance!=null?e.getFrameworkComponentInstance():e}var sX="Backspace",sJ="Enter",sQ="Escape",s0="ArrowLeft",s1="ArrowUp",s2="ArrowRight",s3="ArrowDown",s5="Delete",s4="PageUp",s6="PageDown",s8="Home",s7="KeyA",s9="KeyC",le="KeyD",lt="KeyV",ln="KeyY",li="KeyZ";function lr(){return void 0===y&&(y=/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),y}function lo(){return void 0===b&&(b=/(firefox)/i.test(navigator.userAgent)),b}function la(){return void 0===x&&(x=/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform)),x}function ls(){return void 0===w&&(w=/iPad|iPhone|iPod/.test(navigator.platform)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1),w}function ll(e){if(!e)return null;let t=e.tabIndex,n=e.getAttribute("tabIndex");return -1!==t||null!==n&&(""!==n||lo())?t.toString():null}function ld(){let e=document.body,t=document.createElement("div");t.style.width=t.style.height="100px",t.style.opacity="0",t.style.overflow="scroll",t.style.msOverflowStyle="scrollbar",t.style.position="absolute",e.appendChild(t);let n=t.offsetWidth-t.clientWidth;0===n&&0===t.clientWidth&&(n=null),t.parentNode&&t.remove(),null!=n&&(S=n,C=0===n)}function lu(){return null==C&&ld(),C}var lc=RegExp("[T ]"),lh=RegExp("^\\d{4}-\\d{2}-\\d{2}(T\\d{2}:\\d{2}:\\d{2}\\D?)?");function lp(e,t){return e.toString().padStart(t,"0")}function lf(e,t=!0,n="T"){if(!e)return null;let i=[e.getFullYear(),e.getMonth()+1,e.getDate()].map(e=>lp(e,2)).join("-");return t&&(i+=n+[e.getHours(),e.getMinutes(),e.getSeconds()].map(e=>lp(e,2)).join(":")),i}function lg(e,t=!0){return e?t?[String(e.getFullYear()),String(e.getMonth()+1),lp(e.getDate(),2),lp(e.getHours(),2),`:${lp(e.getMinutes(),2)}`,`:${lp(e.getSeconds(),2)}
364`]:[e.getFullYear(),e.getMonth()+1,lp(e.getDate(),2)].map(String):null}function lm(e,t=!1){return!!lv(e,t)}function lv(e,t=!1,n){if(!e||!n&&!lh.test(e))return null;let[i,r]=e.split(lc);if(!i)return null;let o=i.split("-").map(e=>Number.parseInt(e,10));if(3!==o.filter(e=>!isNaN(e)).length)return null;let[a,s,l]=o,d=new Date(a,s-1,l);if(d.getFullYear()!==a||d.getMonth()!==s-1||d.getDate()!==l||!r&&t)return null;if(!r||"00:00:00"===r)return d;let[u,c,h]=r.split(":").map(e=>Number.parseInt(e,10));if(u>=0&&u<24)d.setHours(u);else if(t)return null;if(c>=0&&c<60)d.setMinutes(c);else if(t)return null;if(h>=0&&h<60)d.setSeconds(h);else if(t)return null;return d}function ly(e){let{inputValue:t,allSuggestions:n,hideIrrelevant:i,filterByPercentageOfBestMatch:r}=e,o=(n??[]).map((e,n)=>({value:e,relevance:function(e,t){e.length<t.length&&([e,t]=[t,e]);let n=[],i=[],r=e.length,o=t.length;for(let e=0;e<=o;e++)n[e]=e;let a=0;for(let s=1;s<=r;s++){i[0]=s;for(let l=1;l<=o;l++){let o=e[s-1],d=t[l-1];if(o.toLocaleLowerCase()===d.toLocaleLowerCase())++a,o===d&&++a,s>1&&l>1&&e[s-2].toLocaleLowerCase()===t[l-2].toLocaleLowerCase()&&(++a,e[s-2]===t[l-2]&&++a),s<r/2-10&&++a,i[l]=n[l-1];else{let e=i[l-1],t=n[l],r=n[l-1];i[l]=1+Math.min(e,t,r)}}[n,i]=[i,n]}return n[o]/(a+1)}(t,e),idx:n}));if(o.sort((e,t)=>e.relevance-t.relevance),i&&(o=o.filter(e=>e.relevance<Math.max(e.value.length,t.length))),o.length>0&&r&&r>0){let e=o[0].relevance*r;o=o.filter(t=>e-t.relevance<0)}let a=[],s=[];for(let e of o)a.push(e.value),s.push(e.idx);return{values:a,indices:s}}function lb(e){return!e.altKey&&!e.ctrlKey&&!e.metaKey&&e.key?.length===1}var lx=!1,lw=0;function lC(e){let t=lx,n="keydown"===e.type;n&&(e.ctrlKey||e.metaKey||e.altKey)||t!==n&&(lx=n)}function lS(e,t,n=!1){let i=rK;t&&(i+=", "+t),n&&(i+=', [tabindex="-1"]');let r=Array.prototype.slice.apply(e.querySelectorAll("[tabindex], input, select, button, textarea, [href]")).filter(e=>oe(e)),o=Array.prototype.slice.apply(e.querySelectorAll(i));return o.length?r.filter(e=>-1===o.indexOf(e)):r}function l_(e,t=!1,n=!1,i=!1){let r=lS(e,i?".ag-tab-guard":null,n),o=t?aY(r):r[0];return!!o&&(o.focus({preventScroll:!0}),!0)}function lk(e,t,n,i){let r=lS(t,n?':not([tabindex="-1"])':null),o=rA(e),a=(n?r.findIndex(e=>e.contains(o)):r.indexOf(o))+(i?-1:1);return a<0||a>=r.length?null:r[a]}function lM(e,t=5){let n=0;for(;e&&null===ll(e)&&++n<=t;)e=e.parentElement;return null===ll(e)?null:e}var lT=class extends s_{constructor(e,t,n){super(t,n),this.labelSeparator="",this.labelAlignment="left",this.disabled=!1,this.label="",this.config=e||{},this.registerCSS(".ag-label{white-space:nowrap}:where(.ag-ltr) .ag-label{margin-right:var(--ag-spacing)}:where(.ag-rtl) .ag-label{margin-left:var(--ag-spacing)}:where(.ag-label-align-right) .ag-label{order:1}:where(.ag-ltr) :where(.ag-label-align-right) .ag-label{margin-left:var(--ag-spacing)}:where(.ag-rtl) :where(.ag-label-align-right) .ag-label{margin-right:var(--ag-spacing)}.ag-label-align-right>*{flex:none}.ag-label-align-top{align-items:flex-start;flex-direction:column;>*{align-self:stretch}}.ag-label-ellipsis{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:where(.ag-label-align-top) .ag-label{margin-bottom:calc(var(--ag-spacing)*.5)}")}postConstruct(){this.addCss("ag-labeled"),this.eLabel.classList.add("ag-label");let{labelSeparator:e,label:t,labelWidth:n,labelAlignment:i,disabled:r}=this.config;null!=r&&this.setDisabled(r),null!=e&&this.setLabelSeparator(e),null!=t&&this.setLabel(t),null!=n&&this.setLabelWidth(n),this.setLabelAlignment(i||this.labelAlignment),this.refreshLabel()}refreshLabel(){let{label:e,eLabel:t}=this;r8(t),"string"==typeof e?t.innerText=e+this.labelSeparator:e&&t.appendChild(e),""===e?(rZ(t,!1),rz(t,"presentation")):(rZ(t,!0),rz(t,null))}setLabelSeparator(e){return this.labelSeparator===e||(this.labelSeparator=e,null!=this.label&&this.refreshLabel()),this}getLabelId(){let e=this.eLabel;return e.id=e.id||`ag-${this.getCompId()}-label`,e.id}getLabel(){return this.label}setLabel(e){return this.label===e||(this.label=e,this.refreshLabel()),this}setLabelAlignment(e){let t=this.getGui().classList;return t.toggle("ag-label-align-left","left"===e),t.toggle("ag-label-align-right","right"===e),t.toggle("ag-label-align-top","top"===e),this}setLabelEllipsis(e){return this.eLabel.classList.toggle("ag-label-ellipsis",e),this}setLabelWidth(e){return null==this.label||oo(this.eLabel,e),this}setDisabled(e){e=!!e;let t=this.getGui();return rX(t,e),t.classList.toggle("ag-disabled",e),this.disabled=e,this}isDisabled(){return!!this.disabled}},lD=class extends lT{constructor(e,t,n,i){super(e,t,n),this.className=i}
vendor: 1,922 bytes, line 364
364postConstruct(){super.postConstruct();let{width:e,value:t,onValueChange:n}=this.config;null!=e&&this.setWidth(e),null!=t&&this.setValue(t),null!=n&&this.onValueChange(n),this.className&&this.addCss(this.className),this.refreshAriaLabelledBy()}setLabel(e){return super.setLabel(e),this.refreshAriaLabelledBy(),this}refreshAriaLabelledBy(){let e=this.getAriaElement(),t=this.getLabelId(),n=this.getLabel();null==n||""==n||null!==e.getAttribute("aria-label")?rV(e,""):rV(e,t??"")}setAriaLabel(e){return rj(this.getAriaElement(),e),this.refreshAriaLabelledBy(),this}onValueChange(e){return this.addManagedListeners(this,{fieldValueChanged:()=>e(this.getValue())}),this}getWidth(){return this.getGui().clientWidth}setWidth(e){return oa(this.getGui(),e),this}getPreviousValue(){return this.previousValue}getValue(){return this.value}setValue(e,t){return this.value===e||(this.previousValue=this.value,this.value=e,t||this.dispatchLocalEvent({type:"fieldValueChanged"})),this}},lR=class extends lD{constructor(e,t,n="text",i="input"){super(e,e?.template??function(e){return{tag:"div",role:"presentation",children:[{tag:"div",ref:"eLabel",cls:"ag-input-field-label"},{tag:"div",ref:"eWrapper",cls:"ag-wrapper ag-input-wrapper",role:"presentation",children:[{tag:e,ref:"eInput",cls:"ag-input-field-input"}]}]}}(i),[],t),this.inputType=n,this.displayFieldTag=i,this.eLabel=null,this.eWrapper=null,this.eInput=null}postConstruct(){super.postConstruct(),this.setInputType(this.inputType);let{eLabel:e,eWrapper:t,eInput:n,className:i}=this;e.classList.add(`${i}-label`),t.classList.add(`${i}-input-wrapper`),n.classList.add(`${i}-input`),this.addCss("ag-input-field"),n.id=n.id||`ag-${this.getCompId()}-input`;let{inputName:r,inputWidth:o}=this.config;null!=r&&this.setInputName(r),null!=o&&this.setInputWidth(o),this.addInputListeners(),this.activateTabIndex([n])}addInputListeners(){this.addManagedElementListeners(this.eInput,{input
364:e=>this.setValue(e.target.value)})}setInputType(e){"input"===this.displayFieldTag&&(this.inputType=e,oc(this.eInput,"type",e))}getInputElement(){return this.eInput}setInputWidth(e){return oo(this.eWrapper,e),this}setInputName(e){return this.getInputElement().setAttribute("name",e),this}getFocusableElement(){return this.eInput}setMaxLength(e){return this.eInput.maxLength=e,this}setInputPlaceholder(e){return oc(this.eInput,"placeholder",e),this}setInputAriaLabel(e){return rj(this.eInput,e),this.refreshAriaLabelledBy(),this}setDisabled(e){return rX(this.eInput,e),super.setDisabled(e)}setAutoComplete(e){return!0===e?oc(this.eInput,"autocomplete",null):oc(this.eInput,"autocomplete","string"==typeof e?e:"off"),this}},lI=class extends lR{constructor(e,t="ag-checkbox",n="checkbox"){super(e,t,n),this.labelAlignment="right",this.selected=!1,this.readOnly=!1,this.passive=!1}postConstruct(){super.postConstruct();let{readOnly:e,passive:t}=this.config;"boolean"==typeof e&&this.setReadOnly(e),"boolean"==typeof t&&this.setPassive(t)}addInputListeners(){this.addManagedElementListeners(this.eInput,{click:this.onCheckboxClick.bind(this)}),this.addManagedElementListeners(this.eLabel,{click:this.toggle.bind(this)})}getNextValue(){return void 0===this.selected||!this.selected}setPassive(e){this.passive=e}isReadOnly(){return this.readOnly}setReadOnly(e){this.eWrapper.classList.toggle("ag-disabled",e),this.eInput.disabled=e,this.readOnly=e}setDisabled(e){return this.eWrapper.classList.toggle("ag-disabled",e),super.setDisabled(e)}toggle(){if(this.eInput.disabled)return;let e=this.isSelected(),t=this.getNextValue();this.passive?this.dispatchChange(t,e):this.setValue(t)}getValue(){return this.isSelected()}setValue(e,t){return this.refreshSelectedClass(e),this.setSelected(e,t),this}setName(e){return this.getInputElement().name=e,this}isSelected(){return this.selected}setSelected(e,t){if(this.isSelected()===e)return;this.previousValue=this.isSelected(),e=this.selected="boolean"==typeof e?e:void 0;let n=this.eInput;n.checked=e,n.indeterminate=void 0===e,t||this.dispatchChange(this.selected,this.previousValue)}dispatchChange(e,t,n){this.dispatchLocalEvent({type:"fieldValueChanged",selected:e,previousValue:t,event:n});let i=this.getInputElement();this.eventSvc.dispatchEvent({type:"checkboxChanged",id:i.id,name:i.name,selected:e,previousValue:t})}onCheckboxClick(e){if(this.passive||this.eInput.disabled)return;let t=this.isSelected(),n=this.selected=e.target.checked;this.refreshSelectedClass(n),this.dispatchChange(n,t,e)}refreshSelectedClass(e){let t=this.eWrapper.classList;t.toggle("ag-checked",!0===e),t.toggle("ag-indeterminate",null==e)}},lA={selector:"AG-CHECKBOX",component:lI},lP=class extends lI{constructor(e){super(e,"ag-radio-button","radio")}isSelected(){return this.eInput.checked}toggle(){!this.eInput.disabled&&(this.isSelected()||this.setValue(!0))}addInputListeners(){super.addInputListeners(),this.addManagedEventListeners({checkboxChanged:this.onChange.bind(this)})}onChange(e){let t=this.eInput;e.selected&&e.name&&t.name&&t.name===e.name&&e.id&&t.id!==e.id&&this.setValue(!1,!0)}},lE=class extends lR{constructor(e,t="ag-text-field",n="text"){super(e,t,n)}postConstruct(){super.postConstruct(),this.config.allowedCharPattern&&this.preventDisallowedCharacters()}setValue(e,t){let n=this.eInput;return n.value!==e&&(n.value=rC(e)?e:""),super.setValue(e,t)}setStartValue(e){this.setValue(e,!0)}preventDisallowedCharacters(){let e=RegExp(`[${this.config.allowedCharPattern}]`);this.addManagedListeners(this.eInput,{keydown:t=>{lb(t)&&t.key&&!e.test(t.key)&&t.preventDefault()},paste:t=>{let n=t.clipboardData?.getData("text");n?.split("").some(t=>!e.test(t))&&t.preventDefault()}})}},lL={selector:"AG-INPUT-TEXT-AREA",component:class extends lR{constructor(e){super(e,"ag-text-area",null,"textarea")}setValue(e,t){let n=super.setValue(e,t);return this.eInput.value=e,n}setCols(e){return this.eInput.cols=e,this}setRows(e){return this.eInput.rows=e,this}}},lF={selector:"AG-INPUT-DATE-FIELD",component:class extends lE{constructor(e){super(e,"ag-date-field","date")}
364postConstruct(){super.postConstruct();let e=lr();this.addManagedListeners(this.eInput,{wheel:this.onWheel.bind(this),mousedown:()=>{this.isDisabled()||e||this.eInput.focus()}}),this.eInput.step="any"}onWheel(e){rA(this.beans)===this.eInput&&e.preventDefault()}setMin(e){let t=e instanceof Date?lf(e??null,!!this.includeTime)??void 0:e;return this.min===t||(this.min=t,oc(this.eInput,"min",t)),this}setMax(e){let t=e instanceof Date?lf(e??null,!!this.includeTime)??void 0:e;return this.max===t||(this.max=t,oc(this.eInput,"max",t)),this}setStep(e){return this.step===e||(this.step=e,oc(this.eInput,"step",e)),this}setIncludeTime(e){return this.includeTime===e||(this.includeTime=e,super.setInputType(e?"datetime-local":"date"),e&&this.setStep(1)),this}getDate(){if(this.eInput.validity.valid)return lv(this.getValue())??void 0}setDate(e,t){this.setValue(lf(e??null,this.includeTime),t)}}},lO=class extends s_{constructor(e,t,n){super(((e,t)=>({tag:"div",cls:`ag-list-item ag-${e}-list-item`,attrs:{role:"option"},children:[{tag:"span",ref:"eText",children:t}]}))(e,t)),this.label=t,this.value=n,this.eText=null}postConstruct(){this.createTooltip(),this.addEventListeners()}setHighlighted(e){let t=this.getGui();t.classList.toggle("ag-active-item",e),rU(t,e),this.dispatchLocalEvent({type:"itemHighlighted",highlighted:e})}getHeight(){return this.getGui().clientHeight}setIndex(e,t){let n=this.getGui();rN(n,"posinset",e),rN(n,"setsize",t)}createTooltip(){let e=this.createOptionalManagedBean(this.beans.registry.createDynamicBean("highlightTooltipFeature",!1,{getTooltipValue:()=>this.label,getGui:()=>this.getGui(),getLocation:()=>"UNKNOWN",shouldDisplayTooltip:()=>oi(this.eText)},this));e&&(this.tooltipFeature=e)}addEventListeners(){let e=this.getParentComponent();e&&(this.addGuiEventListener("mouseover",()=>{e.highlightItem(this)}),this.addGuiEventListener("mousedown",t=>{t.preventDefault(),t.stopPropagation(),e.setValue(this.value)}))}},lN=class extends s_{constructor(e="default"){super({tag:"div",cls:`ag-list ag-${e}-list`}),this.cssIdentifier=e,this.options=[],this.listItems=[],this.highlightedItem=null,this.registerCSS(".ag-list-item{align-items:center;display:flex;height:var(--ag-list-item-height);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;&.ag-active-item{background-color:var(--ag-row-hover-color)}}")}postConstruct(){let e=this.getGui();this.addManagedElementListeners(e,{mouseleave:()=>this.clearHighlighted()})}handleKeyDown(e){let t=e.key;switch(t){case sJ:if(this.highlightedItem){let e=this.listItems.indexOf(this.highlightedItem);this.setValueByIndex(e)}else this.setValue(this.getValue());break;case s3:case s1:e.preventDefault(),this.navigate(t);break;case s6:case s4:case s8:case"End":e.preventDefault(),this.navigateToPage(t)}}addOptions(e){for(let t of e)this.addOption(t);return this}addOption(e){let{value:t,text:n}=e,i=n??t;return this.options.push({value:t,text:i}),this.renderOption(t,i),this.updateIndices(),this}clearOptions(){for(let e of(this.options=[],this.reset(!0),this.listItems))e.destroy();r8(this.getGui()),this.listItems=[],this.refreshAriaRole()}setValue(e,t){if(this.value===e)return this.fireItemSelected(),this;if(null==e)return this.reset(t),this;let n=this.options.findIndex(t=>t.value===e);if(-1!==n){let e=this.options[n];this.value=e.value,this.displayValue=e.text,this.highlightItem(this.listItems[n]),t||this.fireChangeEvent()}return this}setValueByIndex(e){return this.setValue(this.options[e].value)}getValue(){return this.value}getDisplayValue(){return this.displayValue}refreshHighlighted(){this.clearHighlighted();let e=this.options.findIndex(e=>e.value===this.value);-1!==e&&this.highlightItem(this.listItems[e])}highlightItem(e){let t=e.getGui();if(!oe(t))return;this.clearHighlighted(),e.setHighlighted(!0),this.highlightedItem=e;let{scrollTop:n,clientHeight:i}=this.getGui(),{offsetTop:r,offsetHeight:o}=t;(r+o>n+i||r<n)&&t.scrollIntoView({block:"nearest"})}hideItemTooltip(){this.highlightedItem?.tooltipFeature?.attemptToHideTooltip()}destroy(){this.hideItemTooltip(),super.destroy()}reset(e){this.value=null,this.displayValue=null,this.clearHighlighted(),e||this.fireChangeEvent()}clearHighlighted(){this.highlightedItem?.setHighlighted(!1),this.highlightedItem=null}renderOption(e,t){let n=new lO(this.cssIdentifier,t,e);n.setParentComponent(this);let i=this.createManagedBean(n);this.listItems.push(i),this.getGui().appendChild(i.getGui())}navigate(e){let t,n=e===s3,{listItems:i,highlightedItem:r}=this;if(r){let e=i.indexOf(r)+(n?1:-1);e=Math.min(Math.max(e,0),i.length-1),t=i[e]}else t=n?i[0]:aY(i);this.highlightItem(t)}navigateToPage(e){let{listItems:t,highlightedItem:n}=this;
364if(!n||0===t.length)return;let i=t.indexOf(n),r=this.options.length-1,o=t[0].getHeight(),a=Math.floor(this.getGui().clientHeight/o),s=-1;e===s8?s=0:"End"===e?s=r:e===s6?s=Math.min(i+a,r):e===s4&&(s=Math.max(i-a,0)),-1!==s&&this.highlightItem(t[s])}refreshAriaRole(){rz(this.getGui(),0===this.options.length?"presentation":"listbox")}updateIndices(){this.refreshAriaRole();let e=this.listItems,t=e.length;e.forEach((e,n)=>{e.setIndex(n+1,t)})}fireChangeEvent(){this.dispatchLocalEvent({type:"fieldValueChanged"}),this.fireItemSelected()}fireItemSelected(){this.dispatchLocalEvent({type:"selectedItem"})}},lB={tag:"div",cls:"ag-picker-field",role:"presentation",children:[{tag:"div",ref:"eLabel"},{tag:"div",ref:"eWrapper",cls:"ag-wrapper ag-picker-field-wrapper ag-picker-collapsed",children:[{tag:"div",ref:"eDisplayField",cls:"ag-picker-field-display"},{tag:"div",ref:"eIcon",cls:"ag-picker-field-icon",attrs:{"aria-hidden":"true"}}]}]},lz=class extends lD{constructor(e){if(super(e,e?.template||lB,e?.agComponents||[],e?.className),this.isPickerDisplayed=!1,this.skipClick=!1,this.pickerGap=4,this.hideCurrentPicker=null,this.eLabel=null,this.eWrapper=null,this.eDisplayField=null,this.eIcon=null,this.registerCSS(".ag-picker-field-display{flex:1 1 auto}.ag-picker-field{align-items:center;display:flex}.ag-picker-field-icon{border:0;cursor:pointer;display:flex;margin:0;padding:0}.ag-picker-field-wrapper{background-color:var(--ag-picker-button-background-color);border:var(--ag-picker-button-border);border-radius:5px;min-height:max(var(--ag-list-item-height),calc(var(--ag-spacing)*4));overflow:hidden;&:where(.ag-picker-has-focus),&:where(:focus-within){background-color:var(--ag-picker-button-focus-background-color);border:var(--ag-picker-button-focus-border);box-shadow:var(--ag-focus-shadow);&:where(.invalid){box-shadow:var(--ag-focus-error-shadow)}}&:where(.invalid){background-color:var(--ag-input-invalid-background-color);border:var(--ag-input-invalid-border);color:var(--ag-input-invalid-text-color)}&:disabled{opacity:.5}}"),this.ariaRole=e?.ariaRole,this.onPickerFocusIn=this.onPickerFocusIn.bind(this),this.onPickerFocusOut=this.onPickerFocusOut.bind(this),!e)return;const{pickerGap:t,maxPickerHeight:n,variableWidth:i,minPickerWidth:r,maxPickerWidth:o}=e;null!=t&&(this.pickerGap=t),this.variableWidth=!!i,null!=n&&this.setPickerMaxHeight(n),null!=r&&this.setPickerMinWidth(r),null!=o&&this.setPickerMaxWidth(o)}postConstruct(){super.postConstruct(),this.setupAria();let e=`ag-${this.getCompId()}-display`;this.eDisplayField.setAttribute("id",e);let t=this.getAriaElement();this.addManagedElementListeners(t,{keydown:this.onKeyDown.bind(this)}),this.addManagedElementListeners(this.eLabel,{mousedown:this.onLabelOrWrapperMouseDown.bind(this)}),this.addManagedElementListeners(this.eWrapper,{mousedown:this.onLabelOrWrapperMouseDown.bind(this)});let{pickerIcon:n,inputWidth:i}=this.config;if(n){let e=this.beans.iconSvc.createIconNoSpan(n);e&&this.eIcon.appendChild(e)}null!=i&&this.setInputWidth(i)}setupAria(){let e=this.getAriaElement();e.setAttribute("tabindex",this.gos.get("tabIndex").toString()),rG(e,!1),this.ariaRole&&rz(e,this.ariaRole)}onLabelOrWrapperMouseDown(e){if(e){let t=this.getFocusableElement();if(t!==this.eWrapper&&e?.target===t)return;e.preventDefault(),this.getFocusableElement().focus()}if(this.skipClick){this.skipClick=!1;return}this.isDisabled()||(this.isPickerDisplayed?this.hidePicker():this.showPicker())}onKeyDown(e){switch(e.key){case s1:case s3:case sJ:case" ":e.preventDefault(),this.onLabelOrWrapperMouseDown();break;case sQ:this.isPickerDisplayed&&(e.preventDefault(),e.stopPropagation(),this.hideCurrentPicker&&this.hideCurrentPicker())}}showPicker(){this.isPickerDisplayed=!0,this.pickerComponent||(this.pickerComponent=this.createPickerComponent());let e=this.pickerComponent.getGui();e.addEventListener("focusin",this.onPickerFocusIn),e.addEventListener("focusout",this.onPickerFocusOut),this.hideCurrentPicker=this.renderAndPositionPicker(),this.toggleExpandedStyles(!0)}renderAndPositionPicker(){let e=this.pickerComponent.getGui();this.gos.get("suppressScrollWhenPopupsAreOpen")||([this.destroyMouseWheelFunc]=this.addManagedEventListeners({bodyScroll:()=>{this.hidePicker()}}));let t=this.getLocaleTextFunc(),{config:{pickerAriaLabelKey:n,pickerAriaLabelValue:i,modalPicker:r=!0},maxPickerHeight:o,minPickerWidth:a,maxPickerWidth:s,variableWidth:l,beans:d,eWrapper:u}=this,c={modal:r,eChild:e,closeOnEsc:!0,closedCallback:()=>{let e=rE(d);this.beforeHidePicker(),e&&this.isAlive()&&this.getFocusableElement().focus()},ariaLabel:t(n,i),anchorToElement:u};e.style.position="absolute";let h=d.popupSvc,p=h.addPopup(c);l?(a&&(e.style.minWidth=a),e.style.width=od(r3(u)),s&&(e.style.maxWidth=s)):oo(e,s??r3(u));let f=o??`${r0(h.getPopupParent())}px`;return e.style.setProperty("max-height",f),this.alignPickerToComponent(),p.hideFunc}alignPickerToComponent(){if(!this.pickerComponent)return;let{pickerGap:e,config:{pickerType:t},beans:{popupSvc:n,gos:i},eWrapper:r,pickerComponent:o}=this,a=i.get("enableRtl")?"right":"left";n.positionPopupByComponent({type:t,eventSource:r,ePopup:o.getGui(),position:"under",alignSide:a,keepWithinBounds:!0,nudgeY:e})}beforeHidePicker(){this.destroyMouseWheelFunc&&(this.destroyMouseWheelFunc(),this.destroyMouseWheelFunc=void 0),this.toggleExpandedStyles(!1);let e=this.pickerComponent.getGui();e.removeEventListener("focusin",this.onPickerFocusIn),e.removeEventListener("focusout",this.onPickerFocusOut),this.isPickerDisplayed=!1,this.pickerComponent=void 0,this.hideCurrentPicker=null}toggleExpandedStyles(e){if(!this.isAlive())return;rG(this.getAriaElement(),e);let t=this.eWrapper.classList;t.toggle("ag-picker-expanded",e),t.toggle("ag-picker-collapsed",!e)}onPickerFocusIn(){this.togglePickerHasFocus(!0)}onPickerFocusOut(e){this.pickerComponent?.getGui().contains(e.relatedTarget)||this.togglePickerHasFocus(!1)}togglePickerHasFocus(e){this.pickerComponent&&this.eWrapper.classList.toggle("ag-picker-has-focus",e)}hidePicker(){this.hideCurrentPicker&&(this.hideCurrentPicker(),this.dispatchLocalEvent({type:"pickerHidden"}))}setInputWidth(e){return oo(this.eWrapper,e),this}getFocusableElement(){return this.eWrapper}setPickerGap(e){return this.pickerGap=e,this}setPickerMinWidth(e){return"number"==typeof e&&(e=`${e}px`),this.minPickerWidth=null==e?void 0:e,this}setPickerMaxWidth(e){return"number"==typeof e&&(e=`${e}px`),this.maxPickerWidth=null==e?void 0:e,this}setPickerMaxHeight(e){return"number"==typeof e&&(e=`${e}px`),this.maxPickerHeight=null==e?void 0:e,this}destroy(){this.hidePicker(),super.destroy()}},lj=class extends lz{constructor(e){super({pickerAriaLabelKey:"ariaLabelSelectField",pickerAriaLabelValue:"Select Field",pickerType:"ag-list",className:"ag-select",pickerIcon:"selectOpen",ariaRole:"combobox",...e}),this.registerCSS(".ag-select{align-items:center;display:flex;&.ag-disabled{opacity:.5}}:where(.ag-select){.ag-picker-field-wrapper{cursor:default}&.ag-disabled .ag-picker-field-wrapper:focus{box-shadow:none}&:not(.ag-cell-editor,.ag-label-align-top){min-height:var(--ag-list-item-height)}.ag-picker-field-display{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ag-picker-field-icon{align-items:center;display:flex}}:where(.ag-ltr) :where(.ag-select){.ag-picker-field-wrapper{padding-left:calc(var(--ag-cell-horizontal-padding)/2);padding-right:var(--ag-spacing)}}:where(.ag-rtl) :where(.ag-select){.ag-picker-field-wrapper{padding-left:var(--ag-spacing);padding-right:calc(var(--ag-cell-horizontal-padding)/2)}}.ag-select-list{background-color:var(--ag-picker-list-background-color);border:var(--ag-picker-list-border);border-radius:var(--ag-border-radius);box-shadow:var(--ag-dropdown-shadow);overflow:hidden auto}.ag-select-list-item{cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;:where(span){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}}:where(.ag-ltr) .ag-select-list-item{padding-left:calc(var(--ag-cell-horizontal-padding)/2)}:where(.ag-rtl) .ag-select-list-item{padding-right:calc(var(--ag-cell-horizontal-padding)/2)}")}postConstruct(){this.tooltipFeature=this.createOptionalManagedBean(this.beans.registry.createDynamicBean("tooltipFeature",!1,{shouldDisplayTooltip:on(()=>this.eDisplayField),getGui:()=>this.getGui()})),super.postConstruct(),this.createListComponent(),this.eWrapper.tabIndex=this.gos.get("tabIndex");let{options:e,value:t,placeholder:n}=this.config;null!=e&&this.addOptions(e),null!=t&&this.setValue(t,!0),n&&null==t&&(this.eDisplayField.textContent=n),this.addManagedElementListeners(this.eWrapper,{focusout:this.onWrapperFocusOut.bind(this)})}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}createListComponent(){let e=this.createBean(new lN("select"));this.listComponent=e,e.setParentComponent(this);let t=e.getAriaElement(),n=`ag-select-list-${e.getCompId()}`;t.setAttribute("id",n);var i=this.getAriaElement();rO(i,"controls",t.id),rV(t,i.id),e.addManagedElementListeners(e.getGui(),{mousedown:e=>{e?.preventDefault()}}),e.addManagedListeners(e,{selectedItem:()=>{this.hidePicker(),this.dispatchLocalEvent({type:"selectedItem"})},fieldValueChanged:()=>{this.listComponent&&(this.setValue(this.listComponent.getValue(),!1,!0),this.hidePicker())}})}createPickerComponent(){return this.listComponent}beforeHidePicker(){this.listComponent?.hideItemTooltip(),super.beforeHidePicker()}onKeyDown(e){let{key:t}=e;switch("Tab"===t&&this.hidePicker(),t){case sJ:case s1:case s3:case s4:case s6:case s8:case"End":e.preventDefault(),this.isPickerDisplayed?this.listComponent?.handleKeyDown(e):super.onKeyDown(e);break;case sQ:super.onKeyDown(e);break;case" ":this.isPickerDisplayed?e.preventDefault():super.onKeyDown(e)}}showPicker(){let e=this.listComponent;e&&(super.showPicker(),e.refreshHighlighted())}addOptions(e){for(let t of e)this.addOption(t);return this}addOption(e){return this.listComponent.addOption(e),this}clearOptions(){return this.listComponent?.clearOptions(),this.setValue(void 0,!0),this}setValue(e,t,n){let{listComponent:i,config:{placeholder:r},eDisplayField:o,tooltipFeature:a}=this;if(this.value===e||!i||(n||i.setValue(e,!0),i.getValue()===this.getValue()))return this;let s=i.getDisplayValue();return null==s&&r&&(s=r),o.textContent=s,a?.setTooltipAndRefresh(s??null),super.setValue(e,t)}destroy(){this.listComponent=this.destroyBean(this.listComponent),super.destroy()}},lV=((d=lV||{})[d.Vertical=0]="Vertical",d[d.Horizontal=1]="Horizontal",d),lH="object"!=typeof window||!window?.document?.fonts?.forEach,lG=(e,t,n,i,r,o)=>{let a;if(lH)return;i&&(e=`@layer ${CSS.escape(i)} { ${e} }`);let s=l$.map.get(t);if(s||(s=[],l$.map.set(t,s)),s.some(t=>t.css===e))return;
364let l=document.createElement("style");o&&l.setAttribute("nonce",o),l.dataset.agGlobalCss=n,l.textContent=e;let d={css:e,el:l,priority:r};for(let e of s){if(e.priority>r)break;a=e}if(a){a.el.insertAdjacentElement("afterend",l);let e=s.indexOf(a);s.splice(e+1,0,d)}else t.insertBefore(l,t.querySelector(":not(title, meta)")),s.push(d)},lW=(e,t,n,i)=>{lG(':where(.ag-root-wrapper,.ag-external,.ag-popup,.ag-dnd-ghost,.ag-chart),:where(.ag-root-wrapper,.ag-external,.ag-popup,.ag-dnd-ghost,.ag-chart) :where([class^=ag-]){box-sizing:border-box;&:after,&:before{box-sizing:border-box}&:where(div,span,label):focus-visible{box-shadow:inset var(--ag-focus-shadow);outline:none;&:where(.invalid){box-shadow:inset var(--ag-focus-error-shadow)}}&:where(button){color:inherit}}:where(.ag-root-wrapper,ag-external,.ag-popup,.ag-dnd-ghost,.ag-chart) :where([class^=ag-]) ::-ms-clear{display:none}.ag-hidden{display:none!important}.ag-invisible{visibility:hidden!important}.ag-popup-child{top:0;z-index:5;&:where(:not(.ag-tooltip-custom)){box-shadow:var(--ag-popup-shadow)}}.ag-input-wrapper,.ag-picker-field-wrapper{align-items:center;display:flex;flex:1 1 auto;line-height:normal;position:relative}.ag-input-field{align-items:center;display:flex;flex-direction:row}.ag-input-field-input:where(:not([type=checkbox],[type=radio])){flex:1 1 auto;min-width:0;width:100%}.ag-chart,.ag-dnd-ghost,.ag-external,.ag-popup,.ag-root-wrapper{cursor:default;line-height:normal;white-space:normal;-webkit-font-smoothing:antialiased;background-color:var(--ag-background-color);color:var(--ag-text-color);color-scheme:var(--ag-browser-color-scheme);font-family:var(--ag-font-family);font-size:var(--ag-font-size);--ag-indentation-level:0}:where(.ag-icon):before{align-items:center;background-color:currentcolor;color:inherit;content:"";display:flex;font-family:inherit;font-size:var(--ag-icon-size);font-style:normal;font-variant:normal;height:var(--ag-icon-size);justify-content:center;line-height:var(--ag-icon-size);-webkit-mask-size:contain;mask-size:contain;text-transform:none;width:var(--ag-icon-size)}.ag-icon{background-position:50%;background-repeat:no-repeat;background-size:contain;color:var(--ag-icon-color);display:block;height:var(--ag-icon-size);position:relative;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:var(--ag-icon-size)}.ag-disabled,[disabled]{.ag-icon{opacity:.5}&.ag-icon-grip{opacity:.35}}.ag-resizer{pointer-events:none;position:absolute;-webkit-user-select:none;-moz-user-select:none;user-select:none;z-index:1}:where(.ag-resizer){&.ag-resizer-topLeft{cursor:nwse-resize;height:5px;left:0;top:0;width:5px}&.ag-resizer-top{cursor:ns-resize;height:5px;left:5px;right:5px;top:0}&.ag-resizer-topRight{cursor:nesw-resize;height:5px;right:0;top:0;width:5px}&.ag-resizer-right{bottom:5px;cursor:ew-resize;right:0;top:5px;width:5px}&.ag-resizer-bottomRight{bottom:0;cursor:nwse-resize;height:5px;right:0;width:5px}&.ag-resizer-bottom{bottom:0;cursor:ns-resize;height:5px;left:5px;right:5px}&.ag-resizer-bottomLeft{bottom:0;cursor:nesw-resize;height:5px;left:0;width:5px}&.ag-resizer-left{bottom:5px;cursor:ew-resize;left:0;top:5px;width:5px}}',e,"shared",t,0,n),i?.forEach((i,r)=>i.forEach(i=>lG(i,e,r,t,0,n)))},l$=(k="object"==typeof window?window:{}).agStyleInjectionState??(k.agStyleInjectionState={map:new WeakMap,grids:new Set}),lU=e=>new lY(e),lq="$default",lK=0,lY=class{constructor({feature:e,params:t,modeParams:n={},css:i,cssImports:r}){this.feature=e,this.css=i,this.cssImports=r,this.modeParams={[lq]:{...n[lq]??{},...t??{}},...n}}use(e,t,n){let i=this._inject;if(null==i){let{css:e}=this;if(e){let t=`ag-theme-${this.feature??"part"}-${++lK}`;for(let n of("function"==typeof e&&(e=e()),e=`:where(.${t}) { 365${e} 366} 367`,this.cssImports??[]))e=`@import url(${JSON.stringify(n)}); 368${e}`;i={css:e,class:t}}else i=!1;this._inject=i}return i&&e&&lG(i.css,e,i.class,t,1,n),!!i&&i.class}},lZ=e=>`--ag-${e.replace(/[A-Z]/g,e=>`-${e}`).toLowerCase()}`,lX=e=>`var(${lZ(e)})`,lJ=e=>({ref:"accentColor",mix:e}),lQ=e=>({ref:"foregroundColor",mix:e}),l0=e=>({ref:"foregroundColor",mix:e,onto:"backgroundColor"}),l1={ref:"backgroundColor"},l2={ref:"foregroundColor"},l3={ref:"accentColor"},l5={backgroundColor:"#fff",foregroundColor:"#181d1f",borderColor:lQ(.15),chromeBackgroun
368dColor:l0(.02),browserColorScheme:"light"},l4={...l5,textColor:l2,accentColor:"#2196f3",invalidColor:"#e02525",fontFamily:["-apple-system","BlinkMacSystemFont","Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue","sans-serif"],subtleTextColor:{ref:"textColor",mix:.5},borderWidth:1,borderRadius:4,spacing:8,fontSize:14,focusShadow:{spread:3,color:lJ(.5)},focusErrorShadow:{spread:3,color:{ref:"invalidColor",onto:"backgroundColor",mix:.5}},popupShadow:"0 0 16px #00000026",cardShadow:"0 1px 4px 1px #00000018",dropdownShadow:{ref:"cardShadow"},listItemHeight:{calc:"max(iconSize, dataFontSize) + widgetVerticalSpacing"},dragAndDropImageBackgroundColor:l1,dragAndDropImageBorder:!0,dragAndDropImageNotAllowedBorder:{color:{ref:"invalidColor",onto:"dragAndDropImageBackgroundColor",mix:.5}},dragAndDropImageShadow:{ref:"popupShadow"},iconSize:16,iconColor:"inherit",toggleButtonWidth:28,toggleButtonHeight:18,toggleButtonOnBackgroundColor:l3,toggleButtonOffBackgroundColor:l0(.3),toggleButtonSwitchBackgroundColor:l1,toggleButtonSwitchInset:2,tooltipBackgroundColor:{ref:"chromeBackgroundColor"},tooltipErrorBackgroundColor:{ref:"invalidColor",onto:"backgroundColor",mix:.1},tooltipTextColor:{ref:"textColor"},tooltipErrorTextColor:{ref:"invalidColor"},tooltipBorder:!0,tooltipErrorBorder:{color:{ref:"invalidColor",onto:"backgroundColor",mix:.25}}},l6=["colorScheme","color","length","scale","borderStyle","border","shadow","image","fontFamily","fontWeight","duration"],l8=(u=e=>(e=e.toLowerCase(),l6.find(t=>e.endsWith(t.toLowerCase()))??"length"),r=new Map,e=>(r.has(e)||r.set(e,u(e)),r.get(e))),l7=e=>"object"==typeof e&&e?.ref?lX(e.ref):"string"==typeof e?e:"number"==typeof e&&String(e),l9=e=>{if("string"==typeof e)return e;if(e&&"ref"in e){let t=lX(e.ref);if(null==e.mix)return t;let n=e.onto?lX(e.onto):"transparent";return`color-mix(in srgb, ${n}, ${t} ${Math.max(0,Math.min(100,100*e.mix))}%)`}return!1},de=e=>{if("string"==typeof e)return e;if("number"==typeof e)return`${e}px`;if(e&&"calc"in e){let t=e.calc.replace(/ ?[*/+] ?/g," $& ");return`calc(${t.replace(/-?\b[a-z][a-z0-9]*\b(?![-(])/gi,e=>"-"===e[0]?e:" "+lX(e)+" ")})`}return!!e&&"ref"in e&&lX(e.ref)},dt=(e,t)=>"string"==typeof e?e:!0===e?dt({},t):!1===e?"columnBorder"===t?dt({color:"transparent"},t):"none":e&&"ref"in e?lX(e.ref):dn(e.style??"solid")+" "+de(e.width??{ref:"borderWidth"})+" "+l9(e.color??{ref:"borderColor"}),dn=l7,di=e=>"string"==typeof e?e.includes(",")?e:dr(e):e&&"googleFont"in e?di(e.googleFont):e&&"ref"in e?lX(e.ref):!!Array.isArray(e)&&e.map(e=>("object"==typeof e&&"googleFont"in e&&(e=e.googleFont),dr(e))).join(", "),dr=e=>/^[\w-]+$|\w\(/.test(e)?e:JSON.stringify(e),da=e=>"string"==typeof e?e:e&&"url"in e?`url(${JSON.stringify(e.url)})`:e&&"svg"in e?da({url:`data:image/svg+xml,${encodeURIComponent(e.svg)}`}):!!e&&"ref"in e&&lX(e.ref),ds={color:l9,colorScheme:l7,length:de,scale:l7,border:dt,borderStyle:dn,shadow:e=>"string"==typeof e?e:!1===e?"none":e&&"ref"in e?lX(e.ref):[de(e.offsetX??0),de(e.offsetY??0),de(e.radius??0),de(e.spread??0),l9(e.color??{ref:"foregroundColor"})].join(" "),image:da,fontFamily:di,fontWeight:l7,duration:(e,t,n)=>"string"==typeof e?e:"number"==typeof e?(e>=10&&n.warn(104,{value:e,param:t}),`${e}s`):!!e&&"ref"in e&&lX(e.ref)},dl=(e,t,n)=>ds[l8(e)](t,e,n),dd=class e{constructor(e,t=[]){this.themeLogger=e,this.parts=t}withPart(t){return("function"==typeof t&&(t=t()),t instanceof lY)?new e(this.themeLogger,[...this.parts,t]):(this.themeLogger.preInitErr(259,"Invalid part",{part:t}),this)}withoutPart(e){return this.withPart(lU({feature:e}))}withParams(e,t=lq){return this.withPart(lU({modeParams:{[t]:e}}))}_startUse({styleContainer:e,cssLayer:t,nonce:n,loadThemeGoogleFonts:i,moduleCss:r}){if(lH)return;dp(),lW(e,t,n,r);let o=dc(this);if(o.length>0)for(let e of o)i&&df(e,n);for(let i of this.parts)i.use(e,t,n)}_getCssClass(){return this._cssClassCache??(this._cssClassCache=du(this.parts).map(e=>e.use(void 0,void 0,void 0)).filter(Boolean).join(" "))}_getModeParams(){let e=this._paramsCache;if(!e){let t={[lq]:{...l4}};for(let e of du(this.parts))for(let n of Object.keys(e.modeParams)){let i=e.modeParams[n];if(i){let e=t[n]??(t[n]={}),r=new Set;for(let t of Object.keys(i)){let n=i[t];void 0!==n&&(e[t]=n,r.add(t))}if(n===lq)for(let e of Object.keys(t)){let n=t[e];if(e!==lq)for(let e of r)delete n[e]}}}this._paramsCache=e=t}return e}_getPerInstanceCss(e){let t="##SELECTOR##",n=this._paramsCssCache;if(!n){let e="",i="",r=this._getModeParams();for(let t of Object.keys(r)){let n=r[t];if(t!==lq){let n="object"==typeof CSS?CSS.escape(t):t,r=`:where([data-ag-theme-mode="${n}"]) & { 369`;e+=r,i+=r}for(let t of Object.keys(n).sort()){let r=n[t],o=dl(t,r,this.themeLogger);if(!1===o)this.themeLogger.error(107,{key:t,value:r});else{let n=lZ(t),r=n.replace("--ag-","--ag-inherited-");e+=` ${n}: var(${r}, ${o}); 370`,i+=` ${r}: var(${n}); 371`}}t!==lq&&(e+="}\n",i+="}\n")}let o=`${t} { 372${e}} 373`;o+=`:has(> ${t}):not(${t}) { 374${i}} 375`,this._paramsCssCache=n=o}return n.replaceAll(t,`:where(.${e})`)}},du=e=>{let t=new Map;for(let n of e)t.set(n.feature,n);let n=[];for(let i of e)i.feature&&t.get(i.feature)!==i||n.push(i);return n},dc=e=>{let t=new Set,n=e=>{if(Array.isArray(e))e.forEach(n);else{let n=e?.googleFont;"string"==typeof n&&t.add(n)}};return Object.values(e._getModeParams()).flatMap(e=>
375Object.values(e)).forEach(n),Array.from(t).sort()},dh=!1,dp=()=>{if(!dh)for(let e of(dh=!0,Array.from(document.head.querySelectorAll('style[data-ag-scope="legacy"]'))))e.remove()},df=async(e,t)=>{lG(`@import url('https://${dg}/css2?family=${encodeURIComponent(e)}:wght@100;200;300;400;500;600;700;800;900&display=swap'); 376`,document.head,`googleFont:${e}`,void 0,0,t)},dg="fonts.googleapis.com",dm=1,dv=class{constructor(e){if(this.beans={},this.createdBeans=[],this.destroyed=!1,this.instanceId=dm++,!e?.beanClasses)return;this.beanDestroyComparator=e.beanDestroyComparator,this.init(e)}init(e){for(let t of(this.id=e.id,this.beans.context=this,this.destroyCallback=e.destroyCallback,Object.keys(e.providedBeanInstances)))this.beans[t]=e.providedBeanInstances[t];for(let t of e.beanClasses){let e=new t;e.beanName?this.beans[e.beanName]=e:console.error(`Bean ${t.name} is missing beanName`),this.createdBeans.push(e)}for(let t of e.derivedBeans??[]){let{beanName:e,bean:n}=t(this);this.beans[e]=n,this.createdBeans.push(n)}e.beanInitComparator&&this.createdBeans.sort(e.beanInitComparator),this.initBeans(this.createdBeans)}getBeanInstances(){return Object.values(this.beans)}createBean(e,t){return this.initBeans([e],t),e}initBeans(e,t){let n=this.beans;for(let t of e)t.preWireBeans?.(n),t.wireBeans?.(n);for(let t of e)t.preConstruct?.();for(let n of(t&&e.forEach(t),e))n.postConstruct?.()}getBeans(){return this.beans}getBean(e){return this.beans[e]}getId(){return this.id}destroy(){if(this.destroyed)return;this.destroyed=!0;let e=this.getBeanInstances();this.beanDestroyComparator&&e.sort(this.beanDestroyComparator),this.destroyBeans(e),this.beans={},this.createdBeans=[],this.destroyCallback?.()}destroyBean(e){e?.destroy?.()}destroyBeans(e){if(e)for(let t=0;t<e.length;t++)this.destroyBean(e[t]);return[]}isDestroyed(){return this.destroyed}},dy=0,db=class extends oR{constructor(){super(...arguments),this.beanName="environment",this.paramsClass=`ag-theme-params-${++dy}`,this.globalCSS=[]}wireBeans(e){this.eRootDiv=e.eRootDiv}postConstruct(){let{gos:e,eRootDiv:t}=this;e.setInstanceDomData(t),this.eStyleContainer=e.get("themeStyleContainer")??(t.getRootNode()===document?document.head:t),this.cssLayer=e.get("themeCssLayer"),this.styleNonce=e.get("styleNonce"),this.addManagedPropertyListener("theme",()=>this.handleThemeChange()),this.handleThemeChange(),this.initVariables(),this.addDestroyFunc(()=>(e=>{if(l$.grids.delete(e),0===l$.grids.size)for(let e of(l$.map=new WeakMap,document.head.querySelectorAll("style[data-ag-global-css]")))e.remove()})(this)),this.mutationObserver=new MutationObserver(()=>{this.fireStylesChangedEvent("themeChanged")}),this.addDestroyFunc(()=>this.mutationObserver.disconnect())}applyThemeClasses(e,t=[]){let n,{theme:i}=this;for(let t of(n=i?`${this.paramsClass} ${i._getCssClass()}`:this.applyLegacyThemeClasses(),Array.from(e.classList)))t.startsWith("ag-theme-")&&e.classList.remove(t);if(n){let i=e.className;e.className=`${i}${i?" ":""}${n}${t?.length?" "+t.join(" "):""}`}}applyLegacyThemeClasses(){let e="";this.mutationObserver.disconnect();let t=this.eRootDiv;for(;t;){let n=!1;for(let i of Array.from(t.classList))i.startsWith("ag-theme-")&&(n=!0,e=e?`${e} ${i}`:i);n&&this.mutationObserver.observe(t,{attributes:!0,attributeFilter:["class"]}),t=t.parentElement}return e}addGlobalCSS(e,t){this.theme?lG(e,this.eStyleContainer,t,this.cssLayer,0,this.styleNonce):this.globalCSS.push([e,t])}handleThemeChange(){let e,{gos:t,theme:n}=this,i=t.get("theme");if("legacy"===i)e=void 0;else{let t=i??this.getDefaultTheme();t instanceof dd?e=t:this.themeError(t)}e!==n&&this.handleNewTheme(e),this.postProcessThemeChange(e,i)}handleNewTheme(e){let{gos:t,eRootDiv:n,globalCSS:i}=this,r=this.getAdditionalCss();if(e){for(let[e,t]of(l$.grids.add(this),lW(this.eStyleContainer,this.cssLayer,this.styleNonce,r),i))lG(e,this.eStyleContainer,t,this.cssLayer,0,this.styleNonce);i.length=0}this.theme=e,e?._startUse({loadThemeGoogleFonts:t.get("loadThemeGoogleFonts"),styleContainer:this.eStyleContainer,cssLayer:this.cssLayer,nonce:this.styleNonce,moduleCss:r});let o=this.eParamsStyle;if(!o){o=this.eParamsStyle=om({tag:"style"});let e=t.get("styleNonce");e&&o.setAttribute("nonce",e),n.appendChild(o)}lH||(o.textContent=e?._getPerInstanceCss(this.paramsClass)||""),this.applyThemeClasses(n),this.fireStylesChangedEvent("themeChanged")}},dx=class extends oR{constructor(){super(...arguments),this.beanName="registry"}
376registerDynamicBeans(e){if(e)for(let t of(this.dynamicBeans??(this.dynamicBeans={}),Object.keys(e)))this.dynamicBeans[t]=e[t]}createDynamicBean(e,t,...n){if(!this.dynamicBeans)throw Error(this.getDynamicError(e,!0));let i=this.dynamicBeans[e];if(null==i){if(t)throw Error(this.getDynamicError(e,!1));return}return new i(...n)}},dw=class extends oR{constructor(){super(...arguments),this.beanName="eventSvc",this.eventServiceType="global",this.globalSvc=new rx}addListener(e,t,n){this.globalSvc.addEventListener(e,t,n)}removeListener(e,t,n){this.globalSvc.removeEventListener(e,t,n)}addGlobalListener(e,t=!1){this.globalSvc.addGlobalListener(e,t)}removeGlobalListener(e,t=!1){this.globalSvc.removeGlobalListener(e,t)}dispatchEvent(e){this.globalSvc.dispatchEvent(this.gos.addCommon(e))}dispatchEventOnce(e){this.globalSvc.dispatchEventOnce(this.gos.addCommon(e))}},dC=0,dS=class extends oR{constructor(){super(...arguments),this.beanName="popupSvc",this.popupList=[]}getPopupParent(){let e=this.gos.get("popupParent");return e||this.getDefaultPopupParent()}positionPopupUnderMouseEvent(e){let{ePopup:t,nudgeX:n,nudgeY:i,skipObserver:r}=e;this.positionPopup({ePopup:t,nudgeX:n,nudgeY:i,keepWithinBounds:!0,skipObserver:r,updatePosition:()=>this.calculatePointerAlign(e.mouseEvent),postProcessCallback:()=>this.callPostProcessPopup(e,e.type,e.ePopup,null,e.mouseEvent)})}calculatePointerAlign(e){let t=this.getParentRect();return{x:e.clientX-t.left,y:e.clientY-t.top}}positionPopupByComponent(e){let{ePopup:t,nudgeX:n,nudgeY:i,keepWithinBounds:r,eventSource:o,alignSide:a="left",position:s="over",type:l}=e,d=o.getBoundingClientRect(),u=this.getParentRect();this.setAlignedTo(o,t);let c=()=>{let n,r=d.left-u.left;return"right"===a&&(r-=t.offsetWidth-d.width),"over"===s?(n=d.top-u.top,this.setAlignedStyles(t,"over")):(this.setAlignedStyles(t,"under"),n="under"===this.shouldRenderUnderOrAbove(t,d,u,e.nudgeY||0)?d.top-u.top+d.height:d.top-t.offsetHeight-2*(i||0)-u.top),{x:r,y:n}};this.positionPopup({ePopup:t,nudgeX:n,nudgeY:i,keepWithinBounds:r,updatePosition:c,postProcessCallback:()=>this.callPostProcessPopup(e,l,t,o,null)})}shouldRenderUnderOrAbove(e,t,n,i){let r=n.bottom-t.bottom,o=t.top-n.top,a=e.offsetHeight+i;return r>a?"under":o>a||o>r?"above":"under"}setAlignedStyles(e,t){let n=this.getPopupIndex(e);if(-1===n)return;let{alignedToElement:i}=this.popupList[n];if(i){for(let t of["right","left","over","above","under"])i.classList.remove(`ag-has-popup-positioned-${t}`),e.classList.remove(`ag-popup-positioned-${t}`);t&&(i.classList.add(`ag-has-popup-positioned-${t}`),e.classList.add(`ag-popup-positioned-${t}`))}}setAlignedTo(e,t){let n=this.getPopupIndex(t);-1!==n&&(this.popupList[n].alignedToElement=e)}positionPopup(e){let{ePopup:t,keepWithinBounds:n,nudgeX:i,nudgeY:r,skipObserver:o,updatePosition:a}=e,s={width:0,height:0},l=(o=!1)=>{let{x:l,y:d}=a();(!o||t.clientWidth!==s.width||t.clientHeight!==s.height)&&(s.width=t.clientWidth,s.height=t.clientHeight,i&&(l+=i),r&&(d+=r),n&&(l=this.keepXYWithinBounds(t,l,1),d=this.keepXYWithinBounds(t,d,0)),t.style.left=`${l}px`,t.style.top=`${d}px`,e.postProcessCallback&&e.postProcessCallback())};if(l(),!o){let e=oh(this.beans,t,()=>l(!0));setTimeout(()=>e(),200)}}getParentRect(){let e=rP(this.beans),t=this.getPopupParent();return t===e.body?t=e.documentElement:"static"===getComputedStyle(t).position&&(t=t.offsetParent),r5(t)}keepXYWithinBounds(e,t,n){let i=0===n,r=i?"top":"left",o=rP(this.beans),a=o.documentElement,s=this.getPopupParent(),l=e.getBoundingClientRect(),d=s.getBoundingClientRect(),u=o.documentElement.getBoundingClientRect(),c=s===o.body,h=Math.ceil(l[i?"height":"width"]),p=c?(i?r2:r3)(a)+a[i?"scrollTop":"scrollLeft"]:s[i?"clientHeight":"clientWidth"];return c&&(p-=Math.abs(u[r]-d[r])),Math.min(Math.max(t,0),Math.max(p-h,0))}addPopup(e){let{eChild:t,ariaLabel:n,ariaOwns:i,alwaysOnTop:r,positionCallback:o,anchorToElement:a}=e,s=this.getPopupIndex(t);if(-1!==s)return{hideFunc:this.popupList[s].hideFunc};this.initialisePopupPosition(t);let l=this.createPopupWrapper(t,!!r,n,i),d=this.addEventListenersToPopup({...e,wrapperEl:l});return o&&o(),this.addPopupToPopupList(t,l,d,a),{hideFunc:d}}initialisePopupPosition(e){let t=this.getPopupParent().getBoundingClientRect();rC(e.style.top)||(e.style.top=`${-1*t.top}px`),rC(e.style.left)||(e.style.left=`${-1*t.left}px`)}createPopupWrapper(e,t,n,i){let r=this.getPopupParent(),{environment:o,gos:a}=this.beans,s=om({tag:"div"});return(o.applyThemeClasses(s),s.classList.add("ag-popup"),e.classList.add(a.get("enableRtl")?"ag-rtl":"ag-ltr","ag-popup-child"),e.hasAttribute("role")||rz(e,"dialog"),n)?rj(e,n):i&&(e.id||(e.id=`popup-component-${dC}`),rO(i,"owns",e.id)),s.appendChild(e),r.appendChild(s),t?this.setAlwaysOnTop(e,!0):this.bringPopupToFront(e),s}
376addEventListenersToPopup(e){let t=this.beans,n=rP(t),{wrapperEl:i,eChild:r,closedCallback:o,afterGuiAttached:a,closeOnEsc:s,modal:l,ariaOwns:d}=e,u=!1,c=e=>{!i.contains(rA(t))||e.key!==sQ||this.isStopPropagation(e)||f({keyboardEvent:e})},h=e=>f({mouseEvent:e}),p=e=>f({touchEvent:e}),f=(e={})=>{let{mouseEvent:t,touchEvent:a,keyboardEvent:s,forceHide:l}=e;!l&&(this.isEventFromCurrentPopup({mouseEvent:t,touchEvent:a},r)||u)||(u=!0,i.remove(),n.removeEventListener("keydown",c),n.removeEventListener("mousedown",h),n.removeEventListener("touchstart",p),n.removeEventListener("contextmenu",h),this.eventSvc.removeListener("dragStarted",h),o&&o(t||a||s),this.removePopupFromPopupList(r,d))};return a&&a({hidePopup:f}),window.setTimeout(()=>{s&&n.addEventListener("keydown",c),l&&(n.addEventListener("mousedown",h),this.eventSvc.addListener("dragStarted",h),n.addEventListener("touchstart",p),n.addEventListener("contextmenu",h))},0),f}addPopupToPopupList(e,t,n,i){this.popupList.push({element:e,wrapper:t,hideFunc:n,instanceId:dC,isAnchored:!!i}),i&&this.setPopupPositionRelatedToElement(e,i),dC+=1}getPopupIndex(e){return this.popupList.findIndex(t=>t.element===e)}setPopupPositionRelatedToElement(e,t){let n=this.getPopupIndex(e);if(-1===n)return;let i=this.popupList[n];if(i.stopAnchoringPromise&&i.stopAnchoringPromise.then(e=>e&&e()),i.stopAnchoringPromise=void 0,i.isAnchored=!1,!t)return;let r=this.keepPopupPositionedRelativeTo({element:t,ePopup:e,hidePopup:i.hideFunc});return i.stopAnchoringPromise=r,i.isAnchored=!0,r}removePopupFromPopupList(e,t){this.setAlignedStyles(e,null),this.setPopupPositionRelatedToElement(e,null),t&&rO(t,"owns",null),this.popupList=this.popupList.filter(t=>t.element!==e)}keepPopupPositionedRelativeTo(e){let t=this.getPopupParent(),n=t.getBoundingClientRect(),{element:i,ePopup:r}=e,o=i.getBoundingClientRect(),a=e=>Number.parseInt(e.substring(0,e.length-1),10),s=(e,t)=>{let i=n[e]-o[e],s=a(r.style[e]);return{initialDiff:i,lastDiff:i,initial:s,last:s,direction:t}},l=s("top",0),d=s("left",1),u=this.beans.frameworkOverrides;return new sT(n=>{u.wrapIncoming(()=>{var o;(o=()=>{let n=t.getBoundingClientRect(),o=i.getBoundingClientRect();if(0==o.top&&0==o.left&&0==o.height&&0==o.width)return void e.hidePopup();let s=(e,t)=>{let i=a(r.style[t]);e.last!==i&&(e.initial=i,e.last=i);let s=n[t]-o[t];if(s!=e.lastDiff){let n=this.keepXYWithinBounds(r,e.initial+e.initialDiff-s,e.direction);r.style[t]=`${n}px`,e.last=n}e.lastDiff=s};s(l,"top"),s(d,"left")},new sT(e=>{e(window.setInterval(o,200))})).then(e=>{n(()=>{null!=e&&window.clearInterval(e)})})},"popupPositioning")})}isEventFromCurrentPopup(e,t){let{mouseEvent:n,touchEvent:i}=e,r=n||i;if(!r)return!1;let o=this.getPopupIndex(t);if(-1===o)return!1;for(let e=o;e<this.popupList.length;e++){var a;if(a=this.popupList[e].element,r&&a&&(function(e){if(e.path)return e.path;if(e.composedPath)return e.composedPath();let t=[],n=e.target;for(;n;)t.push(n),n=n.parentElement;return t})(r).indexOf(a)>=0)return!0}return this.isElementWithinCustomPopup(r.target)}isElementWithinCustomPopup(e){let t=rP(this.beans);for(;e&&e!==t.body;){if(e.classList.contains("ag-custom-component-popup")||null===e.parentElement)return!0;e=e.parentElement}return!1}getWrapper(e){for(;!e.classList.contains("ag-popup")&&e.parentElement;)e=e.parentElement;return e.classList.contains("ag-popup")?e:null}setAlwaysOnTop(e,t){let n=this.getWrapper(e);n&&(n.classList.toggle("ag-always-on-top",!!t),t&&this.bringPopupToFront(n))}bringPopupToFront(e){let t=this.getPopupParent(),n=Array.prototype.slice.call(t.querySelectorAll(".ag-popup")),i=n.length,r=this.getWrapper(e);if(!r||i<=1||!t.contains(e))return;let o=[],a=[];for(let e of n)e!==r&&(e.classList.contains("ag-always-on-top")?a.push(e):o.push(e));let s=[],l=a.length,d=r.classList.contains("ag-always-on-top")||!l?[...o,...a,r]:[...o,r,...a];for(let e=0;e<=i;e++){let i=d[e];if(n[e]!==d[e]&&i!==r){for(let e of i.querySelectorAll("div"))0!==e.scrollTop&&s.push([e,e.scrollTop]);0===e?t.insertAdjacentElement("afterbegin",i):d[e-1].insertAdjacentElement("afterend",i)}}for(;s.length;){let e=s.pop();e[0].scrollTop=e[1]}}},d_=(e,t)=>{if(null!=t&&e?.setPointerCapture)try{return e.setPointerCapture(t),e.hasPointerCapture(t)}catch{}return!1},dk=e=>{let{eElement:t,onLost:n}=e;t&&n&&(t.removeEventListener("lostpointercapture",n),e.onLost=null)},dM=e=>{if(T){if(T.has(e))return!1}else T=new WeakSet;return T.add(e),!0}
376,dT=class extends oR{constructor(){super(...arguments),this.beanName="dragSvc",this.dragging=!1,this.drag=null,this.dragSources=[]}get startTarget(){return this.drag?.start.target??null}isPointer(){return!!M?.has(rI(this.beans))}hasPointerCapture(){let e=this.drag?.pointerCapture;return!!(e&&this.beans.eRootDiv.hasPointerCapture?.(e.pointerId))}destroy(){this.drag&&this.cancelDrag();let e=this.dragSources;for(let t of e)dD(t);e.length=0,super.destroy()}removeDragSource(e){let t=this.dragSources;for(let n=0,i=t.length;n<i;++n){let i=t[n];if(i.params===e){t.splice(n,1),dD(i);break}}}addDragSource(e){let t;if(!this.isAlive())return;let{eElement:n,includeTouch:i}=e,r=[];if(i){let e=n.style;e&&(t=e.touchAction,e.touchAction="none")}let o={handlers:r,params:e,oldTouchAction:t};this.dragSources.push(o),o_(r,[n,"pointerdown",t=>this.onPointerDown(e,t),{passive:!1}],[n,"mousedown",t=>this.onMouseDown(e,t)]);let a=this.gos.get("suppressTouch");i&&!a&&o_(r,[n,"touchstart",t=>this.onTouchStart(e,t),{passive:!1}])}cancelDrag(e){let t=this.drag;e??(e=t?.eElement),e&&this.eventSvc.dispatchEvent({type:"dragCancelled",target:e}),t?.params.onDragCancel?.(),this.destroyDrag()}shouldPreventMouseEvent(e){let t=e.type;return("mousemove"===t||"pointermove"===t)&&e.cancelable&&oS(this.beans,e)&&!rY(dI(e))}initDrag(e,...t){this.drag=e;let n=this.beans,i=e=>this.onScroll(e),r=e=>this.onKeyDown(e),o=rI(n),a=rP(n);o_(e.handlers,[o,"contextmenu",oM],[o,"keydown",r],[a,"scroll",i,{capture:!0}],[a.defaultView||window,"scroll",i],...t)}destroyDrag(){this.dragging=!1;let e=this.drag;if(e){let t=e.rootEl;M?.get(t)===e&&M?.delete(t),this.drag=null,(e=>{if(!e)return;dk(e);let{eElement:t,pointerId:n}=e;if(t){try{t.releasePointerCapture(n)}catch{}e.eElement=null}})(e.pointerCapture),ok(e.handlers)}}onPointerDown(e,t){if(this.isPointer())return;let n=this.beans;if(T?.has(t))return;let i=t.pointerType;if("touch"===i&&(n.gos.get("suppressTouch")||!e.includeTouch||(e.stopPropagationForTouch&&t.stopPropagation(),rY(dI(t)))))return;if(!t.isPrimary||"mouse"===i&&0!==t.button)return;this.destroyDrag();let r=rI(n),o=e.eElement,a=t.pointerId,s=new dR(r,e,t,a);M??(M=new WeakMap),M.set(r,s);let l=e=>{e.pointerId===a&&this.onMouseOrPointerMove(e)},d=e=>{e.pointerId===a&&this.onMouseOrPointerUp(e)},u=e=>{e.pointerId===a&&dM(e)&&this.cancelDrag()};this.initDrag(s,[r,"pointerup",d],[r,"pointercancel",u],[r,"pointermove",l,{passive:!1}],[r,"touchmove",oM,{passive:!1}],[o,"mousemove",oM,{passive:!1}]),0===e.dragStartPixels?this.onMouseOrPointerMove(t):dM(t)}onTouchStart(e,t){if(this.gos.get("suppressTouch")||!e.includeTouch||!dM(t)||rY(dI(t)))return;if(e.stopPropagationForTouch&&t.stopPropagation(),this.isPointer())return void oM(t);this.destroyDrag();let n=this.beans,i=new dR(rI(n),e,t.touches[0]),r=e=>this.onTouchMove(e),o=e=>this.onTouchUp(e),a=t.target??e.eElement;this.initDrag(i,[rI(n),"touchmove",oM,{passive:!1}],[a,"touchmove",r,{passive:!0}],[a,"touchend",o,{passive:!0}],[a,"touchcancel",o,{passive:!0}]),0===e.dragStartPixels&&this.onMove(i.start)}onMouseDown(e,t){if(0!==t.button||T?.has(t)||this.isPointer())return;let n=this.beans;this.destroyDrag();let i=new dR(rI(n),e,t),r=e=>this.onMouseOrPointerMove(e),o=e=>this.onMouseOrPointerUp(e),a=rI(n);this.initDrag(i,[a,"mousemove",r],[a,"mouseup",o]),0===e.dragStartPixels?this.onMouseOrPointerMove(t):dM(t)}onScroll(e){if(!dM(e))return;let t=this.drag,n=t?.lastDrag;n&&this.dragging&&t.params?.onDragging(n)}onMouseOrPointerMove(e){dM(e)&&(lr()&&rP(this.beans).getSelection()?.removeAllRanges(),this.shouldPreventMouseEvent(e)&&oM(e),this.onMove(e))}onTouchMove(e){let t=this.drag;if(!t||!dM(e))return;let n=oC(t.start,e.touches);n&&(e.preventDefault(),this.onMove(n))}onMove(e){let t=this.drag;if(!t)return;t.lastDrag=e;let n=t.params;if(!this.dragging){let i=t.start;if(ow(e,i,n.dragStartPixels??4)||(this.dragging=!0,n.capturePointer&&(t.pointerCapture=((e,t)=>{if("u"<typeof PointerEvent||!(t instanceof PointerEvent))return null;let n=t.pointerId;if(!d_(e,n))return null;let i={eElement:e,pointerId:n,onLost(e){((e,t)=>{dk(e);let{eElement:n,pointerId:i}=e;n&&t.pointerId===i&&d_(n,i)})(i,e)}};return e.addEventListener("lostpointercapture",i.onLost),i})(this.beans.eRootDiv,e)),this.eventSvc.dispatchEvent({type:"dragStarted",target:n.eElement}),n.onDragStart(i),this.drag!==t)||(n.onDragging(i),this.drag!==t))return}n.onDragging(e)}onTouchUp(e){let t=this.drag;t&&dM(e)&&this.onUp(oC(t.start,e.changedTouches))}onMouseOrPointerUp(e){dM(e)&&this.onUp(e)}
376onUp(e){let t=this.drag;t&&(e||(e=t.lastDrag),e&&this.dragging&&(this.dragging=!1,t.params.onDragStop(e),this.eventSvc.dispatchEvent({type:"dragStopped",target:t.params.eElement})),this.destroyDrag())}onKeyDown(e){e.key===sQ&&this.cancelDrag()}},dD=e=>{ok(e.handlers);let t=e.oldTouchAction;if(null!=t){let n=e.params.eElement.style;n&&(n.touchAction=t)}},dR=class{constructor(e,t,n,i=null){this.rootEl=e,this.params=t,this.start=n,this.pointerId=i,this.handlers=[],this.lastDrag=null,this.pointerCapture=null,this.eElement=t.eElement}},dI=e=>{let t=e.target;return t instanceof Element?t:null},dA=class extends oR{constructor(){super(...arguments),this.beanName="dragAndDrop",this.dragSourceAndParamsList=[],this.dragItem=null,this.dragInitialSourcePointerOffsetX=0,this.dragInitialSourcePointerOffsetY=0,this.lastMouseEvent=null,this.lastDraggingEvent=null,this.dragSource=null,this.dragImageParent=null,this.dragImageCompPromise=null,this.dragImageComp=null,this.dragImageLastIcon=void 0,this.dragImageLastLabel=void 0,this.dropTargets=[],this.lastDropTarget=null}addDragSource(e,t=!1){let n={capturePointer:!0,dragSource:e,eElement:e.eElement,dragStartPixels:e.dragStartPixels,onDragStart:t=>this.onDragStart(e,t),onDragStop:this.onDragStop.bind(this),onDragging:this.onDragging.bind(this),onDragCancel:this.onDragCancel.bind(this),includeTouch:t};this.dragSourceAndParamsList.push(n),this.beans.dragSvc.addDragSource(n)}setDragImageCompIcon(e,t=!1){let n=this.dragImageComp;n&&(t||this.dragImageLastIcon!==e)&&(this.dragImageLastIcon=e,n.setIcon(e,t))}removeDragSource(e){let{dragSourceAndParamsList:t,beans:n}=this,i=t.find(t=>t.dragSource===e);i&&(n.dragSvc?.removeDragSource(i),aJ(t,i))}destroy(){let{dragSourceAndParamsList:e,dropTargets:t,beans:n}=this,i=n.dragSvc;for(let t of e)i?.removeDragSource(t);e.length=0,t.length=0,this.clearDragAndDropProperties(),super.destroy()}nudge(){let e=this.lastMouseEvent;e&&this.onDragging(e,!0)}onDragStart(e,t){this.lastMouseEvent=t,this.dragSource=e,this.dragItem=e.getDragItem();let n=e.eElement.getBoundingClientRect();this.dragInitialSourcePointerOffsetX=t.clientX-n.left,this.dragInitialSourcePointerOffsetY=t.clientY-n.top,e.onDragStarted?.(),this.createAndUpdateDragImageComp(e)}onDragStop(e){let{dragSource:t,lastDropTarget:n}=this;if(t?.onDragStopped?.(),n){let t=this.dropTargetEvent(n,e,!1);n.onDragStop?.(t)}this.clearDragAndDropProperties()}onDragCancel(){let{dragSource:e,lastDropTarget:t,lastMouseEvent:n}=this;if(e?.onDragCancelled?.(),t&&n){let e=this.dropTargetEvent(t,n,!1);t.onDragCancel?.(e)}this.clearDragAndDropProperties()}onDragging(e,t=!1){this.positionDragImageComp(e);let n=this.findCurrentDropTarget(e),{lastDropTarget:i,dragSource:r,dragItem:o}=this,a=!1;if(n!==i){if(a=!0,i){let n=this.dropTargetEvent(i,e,t);i.onDragLeave?.(n)}if(null===i||n?null===i&&n&&this.handleEnter(r,o):this.handleExit(r,o),n){let i=this.dropTargetEvent(n,e,t);n.onDragEnter?.(i)}this.lastDropTarget=n}else if(n){let i=this.dropTargetEvent(n,e,t);n.onDragging?.(i),i?.changed&&(a=!0)}this.lastMouseEvent=e,a&&this.updateDragImageComp()}clearDragAndDropProperties(){this.removeDragImageComp(this.dragImageComp),this.dragImageCompPromise=null,this.dragImageParent=null,this.dragImageLastIcon=void 0,this.dragImageLastLabel=void 0,this.lastMouseEvent=null,this.lastDraggingEvent=null,this.lastDropTarget=null,this.dragItem=null,this.dragInitialSourcePointerOffsetX=0,this.dragInitialSourcePointerOffsetY=0,this.dragSource=null}getAllContainersFromDropTarget(e){let t=e.getSecondaryContainers?e.getSecondaryContainers():null,n=[[e.getContainer()]];return t?n.concat(t):n}isMouseOnDropTarget(e,t){let n=this.getAllContainersFromDropTarget(t),i=!1,r=(e,t)=>{for(let n of t){let{width:t,height:i,left:r,right:o,top:a,bottom:s}=n.getBoundingClientRect();if(0===t||0===i)return!1;let l=e.clientX>=r&&e.clientX<o,d=e.clientY>=a&&e.clientY<s;if(!l||!d)return!1}return!0};for(let t of n)if(r(e,t)){i=!0;break}let{eElement:o,type:a}=this.dragSource;return(!t.targetContainsSource||!!t.getContainer().contains(o))&&i&&t.isInterestedIn(a,o)}findCurrentDropTarget(e){let t=this.dropTargets.filter(t=>this.isMouseOnDropTarget(e,t)),n=t.length;if(0===n)return null;if(1===n)return t[0];for(let n of rI(this.beans).elementsFromPoint(e.clientX,e.clientY))for(let e of t)if(-1!==this.getAllContainersFromDropTarget(e).flatMap(e=>e).indexOf(n))return e;return null}addDropTarget(e){this.dropTargets.push(e)}removeDropTarget(e){this.dropTargets=this.dropTargets.filter(t=>t.getContainer()!==e.getContainer())}hasExternalDropZones(){return this.dropTargets.some(e=>e.external)}findExternalZone(e){return this.dropTargets.find(t=>t.external&&t.getContainer()===e)||null}dropTargetEvent(e,t,n){let{dragSource:i,dragItem:r,lastDraggingEvent:o,lastMouseEvent:a,dragInitialSourcePointerOffsetX:s,dragInitialSourcePointerOffsetY:l}=this,d=e.getContainer(),u=d.getBoundingClientRect(),{clientX:c,clientY:h}=t,p=c-(a?.clientX||0),f=h-(a?.clientY||0),g=this.createEvent({event:t,x:c-u.left,y:h-u.top,vDirection:f>0?"down":f<0?"up":null,hDirection:p<0?"left":p>0?"right":null,initialSourcePointerOffsetX:s,initialSourcePointerOffsetY:l,dragSource:i,fromNudge:n,dragItem:r,dropZoneTarget:d,dropTarget:o?.dropTarget??null,changed:!!o?.changed});return this.lastDraggingEvent=g,g}
376positionDragImageComp(e){let t=this.dragImageComp?.getGui();t&&function(e,t,n){let i,r,o=e.getBoundingClientRect().height,a=(i=rF(n),(i?.clientWidth??(window.innerWidth||-1))-2),s=(r=rF(n),(r?.clientHeight??(window.innerHeight||-1))-2);if(!e.offsetParent)return;let l=r5(e.offsetParent),{clientY:d,clientX:u}=t,c=d-l.top-o/2,h=u-l.left-10,p=rP(n),f=p.defaultView||window,g=f.pageYOffset||p.documentElement.scrollTop,m=f.pageXOffset||p.documentElement.scrollLeft;a>0&&h+e.clientWidth>a+m&&(h=a+m-e.clientWidth),h<0&&(h=0),s>0&&c+e.clientHeight>s+g&&(c=s+g-e.clientHeight),c<0&&(c=0),e.style.left=`${h}px`,e.style.top=`${c}px`}(t,e,this.beans)}removeDragImageComp(e){this.dragImageComp===e&&(this.dragImageComp=null),e&&(e.getGui()?.remove(),this.destroyBean(e))}createAndUpdateDragImageComp(e){let t=this.createDragImageComp(e)??null;this.dragImageCompPromise=t,t?.then(e=>{if(t!==this.dragImageCompPromise||!this.lastMouseEvent||!this.isAlive())return void this.destroyBean(e);this.dragImageCompPromise=null,this.dragImageLastIcon=void 0,this.dragImageLastLabel=void 0;let n=this.dragImageComp;n!==e&&(this.dragImageComp=e,this.removeDragImageComp(n)),e&&(this.appendDragImageComp(e),this.updateDragImageComp())})}appendDragImageComp(e){let t=e.getGui(),n=t.style;n.position="absolute",n.zIndex="9999",this.beans.dragSvc?.hasPointerCapture()&&(n.pointerEvents="none"),this.gos.setInstanceDomData(t),this.beans.environment.applyThemeClasses(t),n.top="20px",n.left="20px";let i=rF(this.beans);this.dragImageParent=i,i?i.appendChild(t):this.warnNoBody()}updateDragImageComp(){let{dragImageComp:e,dragSource:t,lastDropTarget:n,lastDraggingEvent:i,dragImageLastLabel:r}=this;if(!e)return;this.setDragImageCompIcon(n?.getIconName?.(i)??null);let o=t?.dragItemName;"function"==typeof o&&(o=o(i)),o||(o=""),r!==o&&(this.dragImageLastLabel=o,e.setLabel(o))}},dP=((c=dP||{})[c.ToolPanel=0]="ToolPanel",c[c.HeaderCell=1]="HeaderCell",c[c.RowDrag=2]="RowDrag",c[c.ChartPanel=3]="ChartPanel",c[c.AdvancedFilterBuilder=4]="AdvancedFilterBuilder",c),dE=class extends dA{createEvent(e){return aN(this.gos,e)}createDragImageComp(e){var t,n;let{gos:i,beans:r}=this,o=(t=r.userCompFactory,n=aN(i,{dragSource:e}),t.getCompDetailsFromGridOptions(sA,"agDragAndDropImage",n,!0));return o?.newAgStackInstance()}handleEnter(e,t){e?.onGridEnter?.(t)}handleExit(e,t){e?.onGridExit?.(t)}warnNoBody(){at(54)}isDropZoneWithinThisGrid(e){return this.beans.ctrlsSvc.getGridBodyCtrl().eGridBody.contains(e.dropZoneTarget)}registerGridDropTarget(e,t){let n={getContainer:e,isInterestedIn:e=>1===e||0===e,getIconName:()=>"notAllowed"};this.addDropTarget(n),t.addDestroyFunc(()=>this.removeDropTarget(n))}};function dL(e){return e instanceof dF}var dF=class extends oI{constructor(e,t,n,i){super(),this.providedColumnGroup=e,this.groupId=t,this.partId=n,this.pinned=i,this.isColumn=!1,this.displayedChildren=[],this.autoHeaderHeight=null,this.parent=null,this.colIdSanitised=rR(this.getUniqueId())}reset(){this.parent=null,this.children=null,this.displayedChildren=null}getParent(){return this.parent}getUniqueId(){return this.groupId+"_"+this.partId}isEmptyGroup(){return 0===this.displayedChildren.length}isMoving(){let e=this.getProvidedColumnGroup().getLeafColumns();return!!e&&0!==e.length&&e.every(e=>e.isMoving())}checkLeft(){for(let e of this.displayedChildren)dL(e)&&e.checkLeft();if(this.displayedChildren.length>0)if(this.gos.get("enableRtl")){let e=aY(this.displayedChildren).getLeft();this.setLeft(e)}else{let e=this.displayedChildren[0].getLeft();this.setLeft(e)}else this.setLeft(null)}getLeft(){return this.left}getOldLeft(){return this.oldLeft}setLeft(e){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.dispatchLocalEvent({type:"leftChanged"}))}getPinned(){return this.pinned}getGroupId(){return this.groupId}getPartId(){return this.partId}getActualWidth(){let e=0;for(let t of this.displayedChildren??[])e+=t.getActualWidth();return e}isResizable(){if(!this.displayedChildren)return!1;let e=!1;for(let t of this.displayedChildren)t.isResizable()&&(e=!0);return e}getMinWidth(){let e=0;for(let t of this.displayedChildren)e+=t.getMinWidth();return e}addChild(e){this.children||(this.children=[]),this.children.push(e)}getDisplayedChildren(){return this.displayedChildren}getLeafColumns(){let e=[];return this.addLeafColumns(e),e}getDisplayedLeafColumns(){let e=[];return this.addDisplayedLeafColumns(e),e}getDefinition(){return this.providedColumnGroup.getColGroupDef()}getColGroupDef(){return this.providedColumnGroup.getColGroupDef()}isPadding(){return this.providedColumnGroup.isPadding()}isExpandable(){return this.providedColumnGroup.isExpandable()}isExpanded(){return this.providedColumnGroup.isExpanded()}setExpanded(e){this.providedColumnGroup.setExpanded(e)}isAutoHeaderHeight(){return!!this.getColGroupDef()?.autoHeaderHeight}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){let t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}addDisplayedLeafColumns(e){for(let t of this.displayedChildren??[])aH(t)?e.push(t):dL(t)&&t.addDisplayedLeafColumns(e)}addLeafColumns(e){for(let t of this.children??[])aH(t)?e.push(t):dL(t)&&t.addLeafColumns(e)}getChildren(){return this.children}getColumnGroupShow(){return this.providedColumnGroup.getColumnGroupShow()}getProvidedColumnGroup(){return this.providedColumnGroup}getPaddingLevel(){let e=this.getParent();return this.isPadding()&&e?.isPadding()?1+e.getPaddingLevel():0}calculateDisplayedColumns(){this.displayedChildren=[];let e=this;for(;e?.isPadding();)e=e.getParent();if(!(e&&e.getProvidedColumnGroup().isExpandable())){this.displayedChildren=this.children,this.dispatchLocalEvent({type:"displayedChildrenChanged"});return}for(let t of this.children??[])if(!dL(t)||t.displayedChildren?.length)switch(t.getColumnGroupShow()){case"open":e.getProvidedColumnGroup().isExpanded()&&this.displayedChildren.push(t);break;case"closed":e.getProvidedColumnGroup().isExpanded()||this.displayedChildren.push(t);break;default:this.displayedChildren.push(t)}this.dispatchLocalEvent({type:"displayedChildrenChanged"})}},dO="row-group-",dN=0,dB=class{constructor(e){this.master=!1,this.detail=void 0,this.rowIndex=null,this.key=null,this.sourceRowIndex=-1,this._leafs=void 0,this.childrenMapped=null,this.treeParent=null,this.treeNodeFlags=0,this.displayed=!1,this.rowTop=null,this.oldRowTop=null,this.selectable=!0,this.__objectId=dN++,this.alreadyRendered=!1,this.hovered=!1,this.__selected=!1,this.beans=e}get allLeafChildren(){let e=this._leafs;return void 0===e?this.beans.groupStage?.loadLeafs?.(this)??null:e}set allLeafChildren(e){this._leafs=e}setData(e){this.setDataCommon(e,!1)}updateData(e){this.setDataCommon(e,!0)}setDataCommon(e,t){let{valueCache:n,eventSvc:i}=this.beans,r=this.data;this.data=e,n?.onDataChanged(),this.updateDataOnDetailNode(),this.resetQuickFilterAggregateText();let o=this.createDataChangedEvent(e,r,t);if(this.__localEventService?.dispatchEvent(o),this.sibling){this.sibling.data=e;let n=this.sibling.createDataChangedEvent(e,r,t);this.sibling.__localEventService?.dispatchEvent(n)}i.dispatchEvent({type:"rowNodeDataChanged",node:this});let a=this.pinnedSibling;a&&(a.data=e,a.__localEventService?.dispatchEvent(a.createDataChangedEvent(e,r,t)),i.dispatchEvent({type:"rowNodeDataChanged",node:a}))}updateDataOnDetailNode(){let e=this.detailNode;e&&(e.data=this.data)}createDataChangedEvent(e,t,n){return{type:"dataChanged",node:this,oldData:t,newData:e,update:n}}getRowIndexString(){return null==this.rowIndex?(an(13),null):"top"===this.rowPinned?"t-"+this.rowIndex:"bottom"===this.rowPinned?"b-"+this.rowIndex:this.rowIndex.toString()}setDataAndId(e,t){let{selectionSvc:n}=this.beans,i=n?.createDaemonNode?.(this),r=this.data;this.data=e,this.updateDataOnDetailNode(),this.setId(t),n&&(n.updateRowSelectable(this),n.syncInRowNode(this,i));let o=this.createDataChangedEvent(e,r,!1);this.__localEventService?.dispatchEvent(o)}setId(e){let t=aC(this.beans.gos);if(t)if(this.data){let e=this.parent?.getRoute()??[];this.id=t({data:this.data,parentKeys:e.length>0?e:void 0,level:this.level,rowPinned:this.rowPinned}),this.id.startsWith(dO)&&an(14,{groupPrefix:dO})}else this.id=void 0;else this.id=e}setRowTop(e){if(this.oldRowTop=this.rowTop,this.rowTop===e)return;this.rowTop=e,this.dispatchRowEvent("topChanged");let t=null!==e;this.displayed!==t&&(this.displayed=t,this.dispatchRowEvent("displayedChanged"))}clearRowTopAndRowIndex(){this.oldRowTop=null,this.setRowTop(null),this.setRowIndex(null)}setHovered(e){this.hovered=e}isHovered(){return this.hovered}setRowHeight(e,t=!1){this.rowHeight=e,this.rowHeightEstimated=t,this.dispatchRowEvent("heightChanged")}setExpanded(e,t,n){this.beans.expansionSvc?.setExpanded(this,e,t,n)}setDataValue(e,t,n){let{colModel:i,valueSvc:r,gos:o,editSvc:a}=this.beans,s="string"!=typeof e?e:i.getCol(e)??i.getColDefCol(e);if(!s)return!1;let l=r.getValueForDisplay(s,this,void 0,void 0,"api").value;if(o.get("readOnlyEdit")){let{beans:{eventSvc:e},data:i,rowIndex:r,rowPinned:o}=this;return e.dispatchEvent({type:"cellEditRequest",event:null,rowIndex:r,rowPinned:o,column:s,colDef:s.colDef,data:i,node:this,oldValue:l,newValue:t,value:t,source:n}),!1}if(a&&!a.committing){let e=a.setDataValue({rowNode:this,column:s},t,n);if(null!=e)return e}let d=r.setValue(this,s,t,n);return this.dispatchCellChangedEvent(s,t,l),d&&this.pinnedSibling?.dispatchCellChangedEvent(s,t,l),d}updateHasChildren(){let e=this.group&&!this.footer||!!this.childrenAfterGroup?.length,{rowChildrenSvc:t}=this.beans;t&&(e=t.getHasChildrenValue(this)),e!==this.__hasChildren&&(this.__hasChildren=!!e,this.dispatchRowEvent("hasChildrenChanged"))}hasChildren(){return null==this.__hasChildren&&this.updateHasChildren(),this.__hasChildren}dispatchCellChangedEvent(e,t,n){this.__localEventService?.dispatchEvent({type:"cellChanged",node:this,column:e,newValue:t,oldValue:n})}resetQuickFilterAggregateText(){this.quickFilterAggregateText=null}isExpandable(){return this.beans.expansionSvc?.isExpandable(this)??!1}isSelected(){if(this.footer)return this.sibling.isSelected();let e=this.rowPinned&&this.pinnedSibling;return e?e.isSelected():this.__selected}depthFirstSearch(e){let t=this.childrenAfterGroup;if(t)for(let n=0,i=t.length;n<i;++n)t[n].depthFirstSearch(e);e(this)}dispatchRowEvent(e){this.__localEventService?.dispatchEvent({type:e,node:this})}
376setSelected(e,t=!1,n="api"){this.beans.selectionSvc?.setNodesSelected({nodes:[this],newValue:e,clearSelection:t,source:n})}isRowPinned(){return!!this.rowPinned}__addEventListener(e,t){(this.__localEventService??(this.__localEventService=new rx)).addEventListener(e,t)}__removeEventListener(e,t){this.removeLocalListener(e,t)}addEventListener(e,t){this.beans.validation?.checkRowEvents(e);let n=this.__localEventService??(this.__localEventService=new rx);this.frameworkEventListenerService=this.beans.frameworkOverrides.createLocalEventListenerWrapper?.(this.frameworkEventListenerService,n);let i=this.frameworkEventListenerService?.wrap(e,t)??t;n.addEventListener(e,i)}removeEventListener(e,t){let n=this.frameworkEventListenerService?.unwrap(e,t)??t;this.removeLocalListener(e,n)}removeLocalListener(e,t){let n=this.__localEventService;n&&(n.removeEventListener(e,t),n.noRegisteredListenersExist()&&(this.__localEventService=null))}isFullWidthCell(){if(at(61),this.detail)return!0;let e=this.beans.gos.getCallback("isFullWidthRow");return!!e&&e({rowNode:this})}getRoute(){if(-1===this.level)return[];if(null==this.key)return;let e=[],t=this;for(;t?.key!=null;)e.push(t.key),t=t.parent;return e.reverse()}setRowIndex(e){this.rowIndex!==e&&(this.rowIndex=e,this.dispatchRowEvent("rowIndexChanged"))}setAllChildrenCount(e){this.allChildrenCount!==e&&(this.allChildrenCount=e,this.dispatchRowEvent("allChildrenCountChanged"))}setUiLevel(e){this.uiLevel!==e&&(this.uiLevel=e,this.dispatchRowEvent("uiLevelChanged"))}getFirstChild(){let e=this.childStore;return e?e.getFirstNode():this.childrenAfterSort?.[0]??null}},dz=new Set(["__autoHeights","__checkAutoHeightsDebounced","__localEventService","__objectId","_leafs","childStore","oldRowTop","sticky","treeNodeFlags","treeParent"]),dj=e=>{for(;e?.length;){let t=e[0];if(t.data)return t;e=t.childrenAfterGroup}},dV={agSetColumnFilter:"agSetColumnFilterHandler",agMultiColumnFilter:"agMultiColumnFilterHandler",agGroupColumnFilter:"agGroupColumnFilterHandler",agNumberColumnFilter:"agNumberColumnFilterHandler",agDateColumnFilter:"agDateColumnFilterHandler",agTextColumnFilter:"agTextColumnFilterHandler"},dH=new Set(Object.values(dV));function dG(e,t){let n=e.filterUi;if(!n)return null;if(n.created)return n.promise;if(t)return null;let i=n.create(n.refreshed);return n.created=!0,n.promise=i,i}function dW(e,t,n,i,r,o){e?.refresh?.({...t,model:n,state:i,source:r,additionalEventAttributes:o})}function d$(e,t,n){let i=e();i?.created&&i.promise.then(e=>{let r=t();dW(e,i.filterParams,r,n()??{model:r},"ui")})}function dU(e,t,n,i,r,o,a){let s,l,d=!1;switch(e){case"apply":{let e=i();l=e?.model??null,a&&(l=a(l)),s={state:e?.state,model:l},d=!0;break}case"clear":s={model:null};break;case"reset":s={model:null},d=!0,l=null;break;case"cancel":s={model:n()}}r(s),d?o(l):d$(t,n,i)}function dq(e,t){return e[t]??null}var dK=class extends sk{constructor(e){const{className:t="ag-filter-apply-panel"}=e??{};super(function(e){return{tag:"div",cls:e}}(t)),this.listeners=[],this.validationMessage=null,this.className=t}updateButtons(e,t){let n,i=this.buttons;if(this.buttons=e,i===e)return;let r=this.getGui();r8(r),this.destroyListeners();let o=document.createDocumentFragment(),a=this.className,s=({type:e,label:i})=>{let r=t=>{this.dispatchLocalEvent({type:e,event:t})};["apply","clear","reset","cancel"].includes(e)||at(75);let s="apply"===e,l=om({tag:"button",attrs:{type:s&&t?"submit":"button"},ref:`${e}FilterButton`,cls:`ag-button ag-standard-button ${a}-button${s?" "+a+"-apply-button":""}`,children:i});this.activateTabIndex([l]),s&&(n=l);let d=e=>{e.key===sJ&&(e.preventDefault(),r(e))},u=this.listeners;l.addEventListener("click",r),u.push(()=>l.removeEventListener("click",r)),l.addEventListener("keydown",d),u.push(()=>l.removeEventListener("keydown",d)),o.append(l)};for(let t of e)s(t);this.eApply=n;let l=this.validationTooltipFeature;n&&!l?this.validationTooltipFeature=this.createOptionalManagedBean(this.beans.registry.createDynamicBean("tooltipFeature",!1,{getGui:()=>this.eApply,getLocation:()=>"advancedFilter",getTooltipShowDelayOverride:()=>1e3})):!n&&l&&(this.validationTooltipFeature=this.destroyBean(l)),r.append(o)}getApplyButton(){return this.eApply}updateValidity(e,t=null){let n=this.eApply;n&&(rX(n,!1===e),this.validationMessage=t??null,this.validationTooltipFeature?.setTooltipAndRefresh(this.validationMessage))}destroyListeners(){for(let e of this.listeners)e();this.listeners=[]}destroy(){this.destroyListeners(),super.destroy()}},dY={applyFilter:"Apply",clearFilter:"Clear",resetFilter:"Reset",cancelFilter:"Cancel",textFilter:"Text Filter",numberFilter:"Number Filter",dateFilter:"Date Filter",setFilter:"Set Filter",filterOoo:"Filter...",empty:"Choose one",equals:"Equals",notEqual:"Does not equal",lessThan:"Less than",greaterThan:"Greater than",inRange:"Between",inRangeStart:"From",inRangeEnd:"To",lessThanOrEqual:"Less than or equal to",greaterThanOrEqual:"Greater than or equal to",contains:"Contains",notContains:"Does not contain",startsWith:"Begins with",endsWith:"Ends with",blank:"Blank",notBlank:"Not blank",before:"Before",after:"After",andCondition:"AND",orCondition:"OR",dateFormatOoo:"yyyy-mm-dd",filterSummaryInactive:"is (All)",filterSummaryContains:"contains",filterSummaryNotContains:"does not contain",filterSummaryTextEquals:"equals",filterSummaryTextNotEqual:"does not equal",filterSummaryStartsWith:"begins with",filterSummaryEndsWith:"ends with",filterSummaryBlank:"is blank",filterSummaryNotBlank:"is not blank",filterSummaryEquals:"=",filterSummaryNotEqual:"!=",filterSummaryGreaterThan:">",filterSummaryGreaterThanOrEqual:">=",filterSummaryLessThan:"<",filterSummaryLessThanOrEqual:"<=",filterSummaryInRange:"between",filterSummaryInRangeValues:e=>`(${e[0]}, ${e[1]})`,filterSummaryTextQuote:e=>`"${e[0]}"`};function dZ(e,t,n){let i;return i=dY[t],e.getLocaleTextFunc()(t,"function"==typeof i?i(n):i,n)}function dX(e,t){let{debounceMs:n}=e;return dJ(e)?(null!=n&&at(71),0):n??t}function dJ(e){return(e.buttons?.indexOf("apply")??-1)>=0}var dQ=class extends sk{constructor(e,t,n,i,r,o){super(),this.column=e,this.wrapper=t,this.eventParent=n,this.updateModel=i,this.isGlobalButtons=r,this.enableGlobalButtonCheck=o,this.hidePopup=null,this.applyActive=!1}postConstruct(){let{comp:e,params:t}=this.wrapper,n=t.useForm;this.setTemplate({tag:n?"form":"div",cls:"ag-filter-wrapper"}),n&&this.addManagedElementListeners(this.getGui(),{submit:e=>{e?.preventDefault()},keydown:this.handleKeyDown.bind(this)}),this.appendChild(e.getGui()),this.params=t,this.resetButtonsPanel(t),this.addManagedListeners(this.eventParent,{filterParamsChanged:({column:e,params:t})=>{e===this.column&&this.resetButtonsPanel(t,this.params)},filterStateChanged:({column:e,state:t})=>{e===this.column&&this.eButtons?.updateValidity(!1!==t.valid)},filterAction:({column:e,action:t,event:n})=>{e===this.column&&this.afterAction(t,n)},...this.enableGlobalButtonCheck?{filterGlobalButtons:({isGlobal:e})=>
376{if(e!==this.isGlobalButtons){this.isGlobalButtons=e;let t=this.params;this.resetButtonsPanel(t,t,!0)}}}:void 0})}afterGuiAttached(e){e&&(this.hidePopup=e.hidePopup)}resetButtonsPanel(e,t,n){let{buttons:i,readOnly:r}=t??{},{buttons:o,readOnly:a,useForm:s}=e;if(!n&&r===a&&rk(i,o))return;let l=o&&o.length>0&&!e.readOnly&&!this.isGlobalButtons,d=this.eButtons;if(l){let e=o.map(e=>{let t=`${e}Filter`;return{type:e,label:dZ(this,t)}});if(this.applyActive=dJ(this.params),!d){d=this.createBean(new dK),this.appendChild(d.getGui());let e=this.column,t=t=>({event:n})=>{this.updateModel(e,t,{fromButtons:!0}),this.afterAction(t,n)};d?.addManagedListeners(d,{apply:t("apply"),clear:t("clear"),reset:t("reset"),cancel:t("cancel")}),this.eButtons=d}d.updateButtons(e,s)}else this.applyActive=!1,d&&(r7(d.getGui()),this.eButtons=this.destroyBean(d))}close(e){let t,n=this.hidePopup;if(!n)return;let i=e?.key;(i===sJ||" "===i)&&(t={keyboardEvent:e}),n(t),this.hidePopup=null}afterAction(e,t){let{params:n,applyActive:i}=this,r=n?.closeOnApply;switch(e){case"apply":t?.preventDefault(),r&&i&&this.close(t);break;case"reset":r&&i&&this.close();break;case"cancel":r&&this.close(t)}}handleKeyDown(e){!e.defaultPrevented&&e.key===sJ&&this.applyActive&&(this.updateModel(this.column,"apply",{fromButtons:!0}),this.afterAction("apply",e))}destroy(){this.hidePopup=null,this.eButtons=this.destroyBean(this.eButtons)}},d0={tag:"div",cls:"ag-filter"},d1=class extends sk{constructor(e,t,n){super(d0),this.column=e,this.source=t,this.enableGlobalButtonCheck=n,this.wrapper=null}postConstruct(){this.beans.colFilter?.activeFilterComps.add(this),this.createFilter(!0),this.addManagedEventListeners({filterDestroyed:this.onFilterDestroyed.bind(this)})}hasFilter(){return null!=this.wrapper}getFilter(){return this.wrapper?.then(e=>e.comp)??null}afterInit(){return this.wrapper?.then(()=>{})??sT.resolve()}afterGuiAttached(e){this.afterGuiAttachedParams=e,this.wrapper?.then(t=>{this.comp?.afterGuiAttached(e),t?.comp?.afterGuiAttached?.(e)})}afterGuiDetached(){this.wrapper?.then(e=>{e?.comp?.afterGuiDetached?.()})}createFilter(e){let{column:t,source:n,beans:{colFilter:i}}=this,r=i.getFilterUiForDisplay(t)??null;this.wrapper=r,r?.then(r=>{let o;if(!r)return;let{isHandler:a,comp:s}=r;if(a){let e=!!this.enableGlobalButtonCheck,n=this.createBean(new dQ(t,r,i,i.updateModel.bind(i),e&&i.isGlobalButtons,e));this.comp=n,o=n.getGui()}else rC(o=s.getGui())||at(69,{guiFromFilter:o});this.appendChild(o),e?this.eventSvc.dispatchEvent({type:"filterOpened",column:t,source:n,eGui:this.getGui()}):s.afterGuiAttached?.(this.afterGuiAttachedParams)})}onFilterDestroyed(e){let{source:t,column:n}=e;("api"===t||"paramsUpdated"===t)&&n.getId()===this.column.getId()&&this.beans.colModel.getColDefCol(this.column)&&(r8(this.getGui()),this.comp=this.destroyBean(this.comp),this.createFilter())}destroy(){this.beans.colFilter?.activeFilterComps.delete(this),this.eventSvc.dispatchEvent({type:"filterClosed",column:this.column}),this.wrapper=null,this.comp=this.destroyBean(this.comp),this.afterGuiAttachedParams=void 0,super.destroy()}},d2={january:"January",february:"February",march:"March",april:"April",may:"May",june:"June",july:"July",august:"August",september:"September",october:"October",november:"November",december:"December"},d3=["january","february","march","april","may","june","july","august","september","october","november","december"];function d5(e,t){return null==e?-1:null==t?1:Number.parseFloat(e)-Number.parseFloat(t)}function d4(e){return e instanceof Date&&!isNaN(e.getTime())}var d6={number:()=>void 0,boolean:()=>({maxNumConditions:1,debounceMs:0,filterOptions:["empty",{displayKey:"true",displayName:"True",predicate:(e,t)=>t,numberOfInputs:0},{displayKey:"false",displayName:"False",predicate:(e,t)=>!1===t,numberOfInputs:0}]}),date:()=>({isValidDate:d4}),dateString:({dataTypeDefinition:e})=>({comparator:(t,n)=>{let i=e.dateParser(n);return null==n||i<t?-1:+(i>t)},isValidDate:t=>"string"==typeof t&&d4(e.dateParser(t))}),dateTime:e=>d6.date(e),dateTimeString:e=>d6.dateString(e),object:()=>void 0,text:()=>void 0},d8={number:()=>({comparator:d5}),boolean:({t:e})=>({valueFormatter:t=>rC(t.value)?e(String(t.value),t.value?"True":"False"):e("blanks","(Blanks)")}),date:({formatValue:e,t})=>({valueFormatter:n=>{let i=e(n);return rC(i)?i:t("blanks","(Blanks)")},treeList:!0,treeListFormatter:(e,n)=>{if("NaN"===e)return t("invalidDate","Invalid Date");if(1===n&&null!=e){let n=d3[Number(e)-1];return t(n,d2[n])}return e??t("blanks","(Blanks)")},treeListPathGetter:e=>lg(e,!1)}),dateString:({formatValue:e,dataTypeDefinition:t,t:n})=>({valueFormatter:t=>{let i=e(t);return rC(i)?i:n("blanks","(Blanks)")},treeList:!0,treeListPathGetter:e=>lg(t.dateParser(e??void 0),!1),treeListFormatter:(e,t)=>{if(1===t&&null!=e){let t=d3[Number(e)-1];return n(t,d2[t])}return e??n("blanks","(Blanks)")}}),dateTime:e=>{let t=d8.date(e);return t.treeListPathGetter=lg,t},dateTimeString(e){let t=e.dataTypeDefinition.dateParser,n=d8.dateString(e);return n.treeListPathGetter=e=>lg(t(e??void 0)),n},object:({formatValue:e,t})=>({valueFormatter:n=>{let i=e(n);return rC(i)?i:t("blanks","(Blanks)")}}),text:()=>void 0},d7={boolean:"agTextColumnFilter",date:"agDateColumnFilter",dateString:"agDateColumnFilter",dateTime:"agDateColumnFilter",dateTimeString:"agDateColumnFilter",number:"agNumberColumnFilter",object:"agTextColumnFilter",text:"agTextColumnFilter"},d9={boolean:"agTextColumnFloatingFilter",date:"agDateColumnFloatingFilter",dateString:"agDateColumnFloatingFilter",dateTime:"agDateColumnFloatingFilter",dateTimeString:"agDateColumnFloatingFilter",number:"agNumberColumnFloatingFilter",object:"agTextColumnFloatingFilter",text:"agTextColumnFloatingFilter"},ue="ag-resizer-wrapper",ut=(e,t)=>({tag:"div",ref:`${e}Resizer`,cls:`ag-resizer ag-resizer-${t}`}),un={tag:"div",cls:ue,children:[ut("eTopLeft","topLeft"),ut("eTop","top"),ut("eTopRight","topRight"),ut("eRight","right"),ut("eBottomRight","bottomRight"),ut("eBottom","bottom"),ut("eBottomLeft","bottomLeft"),ut("eLeft","left")]},ui=class extends oI{constructor(e,t){super(),this.element=e,this.dragStartPosition={x:0,y:0},this.position={x:0,y:0}
376,this.lastSize={width:-1,height:-1},this.positioned=!1,this.resizersAdded=!1,this.resizeListeners=[],this.boundaryEl=null,this.isResizing=!1,this.isMoving=!1,this.resizable={},this.movable=!1,this.currentResizer=null,this.config=Object.assign({},{popup:!1},t)}wireBeans(e){this.popupSvc=e.popupSvc,this.dragSvc=e.dragSvc}center(e){let{clientHeight:t,clientWidth:n}=this.offsetParent,i=n/2-this.getWidth()/2,r=t/2-this.getHeight()/2;this.offsetElement(i,r,e)}initialisePosition(e){if(this.positioned)return;let{centered:t,forcePopupParentAsOffsetParent:n,minWidth:i,width:r,minHeight:o,height:a,x:s,y:l}=this.config;this.offsetParent||this.setOffsetParent();let d=0,u=0,c=oe(this.element);if(c){let e=this.findBoundaryElement(),t=window.getComputedStyle(e);if(null!=t.minWidth){let n=e.offsetWidth-this.element.offsetWidth;u=Number.parseInt(t.minWidth,10)-n}if(null!=t.minHeight){let n=e.offsetHeight-this.element.offsetHeight;d=Number.parseInt(t.minHeight,10)-n}}if(this.minHeight=o||d,this.minWidth=i||u,r&&this.setWidth(r),a&&this.setHeight(a),r&&a||this.refreshSize(),t)this.center(e);else if(s||l)this.offsetElement(s,l,e);else if(c&&n){let t=this.boundaryEl,n=!0;if(t||(t=this.findBoundaryElement(),n=!1),t){let i=Number.parseFloat(t.style.top),r=Number.parseFloat(t.style.left);n?this.offsetElement(isNaN(r)?0:r,isNaN(i)?0:i,e):this.setPosition(r,i)}}this.positioned=!!this.offsetParent}isPositioned(){return this.positioned}getPosition(){return this.position}setMovable(e,t){if(!this.config.popup||e===this.movable)return;this.movable=e;let n=this.moveElementDragListener||{eElement:t,onDragStart:this.onMoveStart.bind(this),onDragging:this.onMove.bind(this),onDragStop:this.onMoveEnd.bind(this)};e?(this.dragSvc?.addDragSource(n),this.moveElementDragListener=n):(this.dragSvc?.removeDragSource(n),this.moveElementDragListener=void 0)}setResizable(e){if(this.clearResizeListeners(),e?this.addResizers():this.removeResizers(),"boolean"==typeof e){if(!1===e)return;e={topLeft:e,top:e,topRight:e,right:e,bottomRight:e,bottom:e,bottomLeft:e,left:e}}Object.keys(e).forEach(t=>{let n=!!e[t],i=this.getResizerElement(t),r={dragStartPixels:0,eElement:i,onDragStart:e=>this.onResizeStart(e,t),onDragging:this.onResize.bind(this),onDragStop:e=>this.onResizeEnd(e,t)};!n&&(this.isAlive()||n)||(n?(this.dragSvc?.addDragSource(r),this.resizeListeners.push(r),i.style.pointerEvents="all"):i.style.pointerEvents="none",this.resizable[t]=n)})}removeSizeFromEl(){this.element.style.removeProperty("height"),this.element.style.removeProperty("width"),this.element.style.removeProperty("flex")}restoreLastSize(){this.element.style.flex="0 0 auto";let{height:e,width:t}=this.lastSize;-1!==t&&(this.element.style.width=`${t}px`),-1!==e&&(this.element.style.height=`${e}px`)}getHeight(){return this.element.offsetHeight}setHeight(e){let{popup:t}=this.config,n=this.element,i=!1;if("string"==typeof e&&e.includes("%"))ol(n,e),e=r2(n),i=!0;else if(e=Math.max(this.minHeight,e),this.positioned){let t=this.getAvailableHeight();t&&e>t&&(e=t)}this.getHeight()!==e&&(i?(n.style.maxHeight="unset",n.style.minHeight="unset"):t?ol(n,e):(n.style.height=`${e}px`,n.style.flex="0 0 auto",this.lastSize.height="number"==typeof e?e:Number.parseFloat(e)))}getAvailableHeight(){let{popup:e,forcePopupParentAsOffsetParent:t}=this.config;this.positioned||this.initialisePosition();let{clientHeight:n}=this.offsetParent;if(!n)return null;let i=this.element.getBoundingClientRect(),r=this.offsetParent.getBoundingClientRect(),o=e?this.position.y:i.top,a=e?0:r.top,s=0;if(t){let e=this.element.parentElement;if(e){let{bottom:t}=e.getBoundingClientRect();s=t-i.bottom}}return n+a-o-s}getWidth(){return this.element.offsetWidth}setWidth(e){let t=this.element,{popup:n}=this.config,i=!1;if("string"==typeof e&&e.includes("%"))oa(t,e),e=r3(t),i=!0;else if(this.positioned){e=Math.max(this.minWidth,e);let{clientWidth:t}=this.offsetParent,i=n?this.position.x:this.element.getBoundingClientRect().left;t&&e+i>t&&(e=t-i)}this.getWidth()!==e&&(i?(t.style.maxWidth="unset",t.style.minWidth="unset"):this.config.popup?oa(t,e):(t.style.width=`${e}px`,t.style.flex=" unset",this.lastSize.width="number"==typeof e?e:Number.parseFloat(e)))}offsetElement(e=0,t=0,n){let{forcePopupParentAsOffsetParent:i}=this.config,r=i?this.boundaryEl:this.element;r&&(this.popupSvc?.positionPopup({ePopup:r,keepWithinBounds:!0,skipObserver:this.movable||this.isResizable(),updatePosition:()=>({x:e,y:t}),postProcessCallback:n}),this.setPosition(Number.parseFloat(r.style.left),Number.parseFloat(r.style.top)))}constrainSizeToAvailableHeight(e){if(!this.config.forcePopupParentAsOffsetParent)return;let t=()=>{let e=this.getAvailableHeight();this.element.style.setProperty("max-height",`${e}px`)};e&&this.popupSvc?(this.resizeObserverSubscriber?.(),this.resizeObserverSubscriber=oh(this.beans,this.popupSvc?.getPopupParent(),t)):(this.element.style.removeProperty("max-height"),this.resizeObserverSubscriber&&(this.resizeObserverSubscriber(),this.resizeObserverSubscriber=void 0))}setPosition(e,t){this.position.x=e,this.position.y=t}updateDragStartPosition(e,t){this.dragStartPosition={x:e,y:t}}calculateMouseMovement(e){let{e:t,isLeft:n,isTop:i,anywhereWithin:r,topBuffer:o}=e,a=t.clientX-this.dragStartPosition.x,s=t.clientY-this.dragStartPosition.y;return{movementX:this.shouldSkipX(t,!!n,!!r,a)?0:a,movementY:this.shouldSkipY(t,!!i,o,s)?0:s}}shouldSkipX(e,t,n,i){let r=this.element.getBoundingClientRect(),o=this.offsetParent.getBoundingClientRect(),a=this.boundaryEl.getBoundingClientRect(),s=this.config.popup?this.position.x:r.left,l=s<=0&&o.left>=e.clientX||o.right<=e.clientX&&o.right<=a.right;return!!l||(l=t?i<0&&e.clientX>s+o.left||i>0&&e.clientX<s+o.left:n?i<0&&e.clientX>a.right||i>0&&e.clientX<s+o.left:i<0&&e.clientX>a.right||i>0&&e.clientX<a.right)}shouldSkipY(e,t,n=0,i){let r=this.element.getBoundingClientRect(),o=this.offsetParent.getBoundingClientRect(),a=this.boundaryEl.getBoundingClientRect(),s=this.config.popup?this.position.y:r.top,l=s<=0&&o.top>=e.clientY||o.bottom<=e.clientY&&o.bottom<=a.bottom;return!!l||(l=t?i<0&&e.clientY>s+o.top+n||i>
3760&&e.clientY<s+o.top:i<0&&e.clientY>a.bottom||i>0&&e.clientY<a.bottom)}createResizeMap(){let e=e=>({element:this.element.querySelector(`[data-ref=${e}Resizer]`)});this.resizerMap={topLeft:e("eTopLeft"),top:e("eTop"),topRight:e("eTopRight"),right:e("eRight"),bottomRight:e("eBottomRight"),bottom:e("eBottom"),bottomLeft:e("eBottomLeft"),left:e("eLeft")}}addResizers(){if(this.resizersAdded)return;let e=this.element;e&&(e.appendChild(om(un)),this.createResizeMap(),this.resizersAdded=!0)}removeResizers(){this.resizerMap=void 0;let e=this.element.querySelector(`.${ue}`);e?.remove(),this.resizersAdded=!1}getResizerElement(e){return this.resizerMap[e].element}onResizeStart(e,t){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.currentResizer={isTop:!!t.match(/top/i),isRight:!!t.match(/right/i),isBottom:!!t.match(/bottom/i),isLeft:!!t.match(/left/i)},this.element.classList.add("ag-resizing"),this.resizerMap[t].element.classList.add("ag-active");let{popup:n,forcePopupParentAsOffsetParent:i}=this.config;n||i||this.applySizeToSiblings(this.currentResizer.isBottom||this.currentResizer.isTop),this.isResizing=!0,this.updateDragStartPosition(e.clientX,e.clientY)}getSiblings(){let e=this.element.parentElement;return e?Array.prototype.slice.call(e.children).filter(e=>!e.classList.contains("ag-hidden")):null}getMinSizeOfSiblings(){let e=this.getSiblings()||[],t=0,n=0;for(let i=0;i<e.length;i++){let r=e[i],o=!!r.style.flex&&"0 0 auto"!==r.style.flex;if(r===this.element)continue;let a=this.minHeight||0,s=this.minWidth||0;if(o){let e=window.getComputedStyle(r);e.minHeight&&(a=Number.parseInt(e.minHeight,10)),e.minWidth&&(s=Number.parseInt(e.minWidth,10))}else a=r.offsetHeight,s=r.offsetWidth;t+=a,n+=s}return{height:t,width:n}}applySizeToSiblings(e){let t=null,n=this.getSiblings();if(n){for(let i=0;i<n.length;i++){let r=n[i];r!==t&&(e?r.style.height=`${r.offsetHeight}px`:r.style.width=`${r.offsetWidth}px`,r.style.flex="0 0 auto",r===this.element&&(t=n[i+1]))}t&&(t.style.removeProperty("height"),t.style.removeProperty("min-height"),t.style.removeProperty("max-height"),t.style.flex="1 1 auto")}}isResizable(){return Object.values(this.resizable).some(e=>e)}onResize(e){if(!this.isResizing||!this.currentResizer)return;let{popup:t,forcePopupParentAsOffsetParent:n}=this.config,{isTop:i,isRight:r,isBottom:o,isLeft:a}=this.currentResizer,s=r||a,l=o||i,{movementX:d,movementY:u}=this.calculateMouseMovement({e,isLeft:a,isTop:i}),c=this.position.x,h=this.position.y,p=0,f=0;if(s&&d){let e=a?-1:1,t=this.getWidth(),n=t+d*e,i=!1;a&&(c+(p=t-n)<=0||n<=this.minWidth)&&(i=!0,p=0),i||this.setWidth(n)}if(l&&u){let e=i?-1:1,t=this.getHeight(),n=t+u*e,r=!1;i?(h+(f=t-n)<=0||n<=this.minHeight)&&(r=!0,f=0):!this.config.popup&&!this.config.forcePopupParentAsOffsetParent&&t<n&&this.getMinSizeOfSiblings().height+n>this.element.parentElement.offsetHeight&&(r=!0),r||this.setHeight(n)}this.updateDragStartPosition(e.clientX,e.clientY),((t||n)&&p||f)&&this.offsetElement(c+p,h+f)}onResizeEnd(e,t){this.isResizing=!1,this.currentResizer=null,this.boundaryEl=null,this.element.classList.remove("ag-resizing"),this.resizerMap[t].element.classList.remove("ag-active"),this.dispatchLocalEvent({type:"resize"})}refreshSize(){let e=this.element;this.config.popup&&(this.config.width||this.setWidth(e.offsetWidth),this.config.height||this.setHeight(e.offsetHeight))}onMoveStart(e){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.isMoving=!0,this.element.classList.add("ag-moving"),this.updateDragStartPosition(e.clientX,e.clientY)}onMove(e){let t;if(!this.isMoving)return;let{x:n,y:i}=this.position;this.config.calculateTopBuffer&&(t=this.config.calculateTopBuffer());let{movementX:r,movementY:o}=this.calculateMouseMovement({e,isTop:!0,anywhereWithin:!0,topBuffer:t});this.offsetElement(n+r,i+o),this.updateDragStartPosition(e.clientX,e.clientY)}onMoveEnd(){this.isMoving=!1,this.boundaryEl=null,this.element.classList.remove("ag-moving")}setOffsetParent(){this.config.forcePopupParentAsOffsetParent&&this.popupSvc?this.offsetParent=this.popupSvc.getPopupParent():this.offsetParent=this.element.offsetParent}findBoundaryElement(){let e=this.element;for(;e;){if("static"!==window.getComputedStyle(e).position)return e;e=e.parentElement}return this.element}clearResizeListeners(){for(;this.resizeListeners.length;){let e=this.resizeListeners.pop();this.dragSvc?.removeDragSource(e)}}destroy(){super.destroy(),this.moveElementDragListener&&this.dragSvc?.removeDragSource(this.moveElementDragListener),this.constrainSizeToAvailableHeight(!1),this.clearResizeListeners(),this.removeResizers()}},ur="__ag_Grid_Stop_Propagation";function uo(e){e[ur]=!0}function ua(e){return!0===e[ur]}var us=class extends oI{constructor(e,t={}){super(),this.eFocusable=e,this.callbacks=t,this.callbacks={shouldStopEventPropagation:()=>!1,onTabKeyDown:e=>{if(e.defaultPrevented)return;let t=lk(this.beans,this.eFocusable,!1,e.shiftKey);t&&(t.focus(),e.preventDefault())},...t}}postConstruct(){let{eFocusable:e,callbacks:{onFocusIn:t,onFocusOut:n}}=this;e.classList.add("ag-focus-managed"),this.addKeyDownListeners(e),t&&this.addManagedElementListeners(e,{focusin:t}),n&&this.addManagedElementListeners(e,{focusout:n})}addKeyDownListeners(e){this.addManagedElementListeners(e,{keydown:e=>{if(e.defaultPrevented||ua(e))return;let{callbacks:t}=this;t.shouldStopEventPropagation(e)?uo(e):"Tab"===e.key?t.onTabKeyDown(e):t.handleKeyDown&&t.handleKeyDown(e)}})}},ul=class extends sk{constructor(e,t){super(),this.filterNameKey=e,this.cssIdentifier=t,this.applyActive=!1,this.debouncePending=!1,this.defaultDebounceMs=0}postConstruct(){let e={tag:"div",cls:`ag-filter-body-wrapper ag-${this.cssIdentifier}-body-wrapper`,children:[this.createBodyTemplate()]};this.setTemplate(e,this.getAgComponents()),this.createManagedBean(new us(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.positionableFeature=this.createBean(new ui(this.getPositionableElement(),{forcePopupParentAsOffsetParent:!0}))}handleKeyDown(e){}init(e){this.setParams(e),this.setModelIntoUi(e.state.model,!0).then(()=>this.updateUiVisibility())}refresh(e){let t=this.params;this.params=e,"colDef"===e.source&&this.updateParams(e,t);let n=e.state,i=this.state;return this.state=n,(n.model!==i.model||n.state!==i.state)&&this.setModelIntoUi(n.model),!0}setParams(e){this.params=e,this.state=e.state,this.commonUpdateParams(e)}updateParams(e,t){this.commonUpdateParams(e,t)}commonUpdateParams(e,t){this.applyActive=dJ(e),this.setupApplyDebounced()}doesFilterPass(e){at(283);let{getHandler:t,model:n,column:i}=this.params;return t().doesFilterPass({...e,model:n,handlerParams:this.beans.colFilter.getHandlerParams(i)})}getFilterTitle(){return this.translate(this.filterNameKey)}isFilterActive(){return at(284),null!=this.params.model}setupApplyDebounced(){let e=dX(this.params,this.defaultDebounceMs),t=oO(this,this.checkApplyDebounce.bind(this),e);this.applyDebounced=()=>{this.debouncePending=!0,t()}}checkApplyDebounce(){this.debouncePending&&(this.debouncePending=!1,this.doApplyModel())}getModel(){return at(285),this.params.model}setModel(e){at(286);let{beans:t,params:n}=this;return t.colFilter.setModelForColumnLegacy(n.column,e)}applyModel(e="api"){return this.doApplyModel()}canApply(e){return!0}doApplyModel(e){let{params:t,state:n}=this,i=!this.areModelsEqual(t.model,n.model);return i&&t.onAction("apply",e),i}onNewRowsLoaded(){}onUiChanged(e,t=!1){this.updateUiVisibility();let n=this.getModelFromUi(),i={model:n,state:this.getState(),val
376id:this.canApply(n)};this.state=i;let r=this.params;r.onStateChange(i),r.onUiChange(this.getUiChangeEventParams()),this.gos.get("enableFilterHandlers")||this.eventSvc.dispatchEvent({type:"filterModified",column:r.column,filterInstance:this}),e??(e=this.applyActive?void 0:"debounce"),"immediately"===e?this.doApplyModel({afterFloatingFilter:t,afterDataChange:!1}):"debounce"===e&&this.applyDebounced()}getState(){}getUiChangeEventParams(){}afterGuiAttached(e){this.lastContainerType=e?.container,this.refreshFilterResizer(e?.container)}refreshFilterResizer(e){let{positionableFeature:t,gos:n}=this;if(!t)return;let i="floatingFilter"===e||"columnFilter"===e;i?(t.restoreLastSize(),t.setResizable(n.get("enableRtl")?{bottom:!0,bottomLeft:!0,left:!0}:{bottom:!0,bottomRight:!0,right:!0})):(t.removeSizeFromEl(),t.setResizable(!1)),t.constrainSizeToAvailableHeight(i)}afterGuiDetached(){this.checkApplyDebounce(),this.positionableFeature?.constrainSizeToAvailableHeight(!1)}destroy(){this.positionableFeature=this.destroyBean(this.positionableFeature),super.destroy()}translate(e){return dZ(this,e)}getPositionableElement(){return this.getGui()}areModelsEqual(e,t){return e===t||null==e&&null==t||null!=e&&null!=t&&this.areNonNullModelsEqual(e,t)}};function ud(e){return!!e.operator}var uu={AUTO_HEIGHT:"ag-layout-auto-height",NORMAL:"ag-layout-normal",PRINT:"ag-layout-print"},uc=class extends oI{constructor(e){super(),this.view=e}postConstruct(){this.addManagedPropertyListener("domLayout",this.updateLayoutClasses.bind(this)),this.updateLayoutClasses()}updateLayoutClasses(){let e=this.gos.get("domLayout"),t={autoHeight:"autoHeight"===e,normal:"normal"===e,print:"print"===e},n=t.autoHeight?uu.AUTO_HEIGHT:t.print?uu.PRINT:uu.NORMAL;this.view.updateLayoutClasses(n,t)}},uh="Viewport",up="fakeVScrollComp",uf=["fakeHScrollComp","centerHeader","topCenter","bottomCenter","stickyTopCenter","stickyBottomCenter"],ug=class extends oI{constructor(e){super(),this.clearRetryListenerFncs=[],this.lastScrollSource=[null,null],this.scrollLeft=-1,this.nextScrollTop=-1,this.scrollTop=-1,this.lastOffsetHeight=-1,this.lastScrollTop=-1,this.lastIsHorizontalScrollShowing=!1,this.scrollTimer=0,this.isScrollActive=!1,this.isVerticalPositionInvalidated=!0,this.isHorizontalPositionInvalidated=!0,this.eBodyViewport=e,this.resetLastHScrollDebounced=oO(this,()=>this.lastScrollSource[1]=null,150),this.resetLastVScrollDebounced=oO(this,()=>this.lastScrollSource[0]=null,150)}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.animationFrameSvc=e.animationFrameSvc,this.visibleCols=e.visibleCols}destroy(){super.destroy(),this.clearRetryListenerFncs=[],window.clearTimeout(this.scrollTimer)}postConstruct(){this.enableRtl=this.gos.get("enableRtl");let e=this.invalidateVerticalScroll.bind(this),t=this.invalidateHorizontalScroll.bind(this);this.addManagedEventListeners({displayedColumnsWidthChanged:this.onDisplayedColumnsWidthChanged.bind(this),bodyHeightChanged:e,scrollGapChanged:t}),this.addManagedElementListeners(this.eBodyViewport,{scroll:e}),this.ctrlsSvc.whenReady(this,e=>{this.centerRowsCtrl=e.center,this.onDisplayedColumnsWidthChanged(),this.addScrollListener()})}invalidateHorizontalScroll(){this.isHorizontalPositionInvalidated=!0}invalidateVerticalScroll(){this.isVerticalPositionInvalidated=!0}addScrollListener(){this.addHorizontalScrollListeners(),this.addVerticalScrollListeners()}addHorizontalScrollListeners(){for(let e of(this.addManagedElementListeners(this.centerRowsCtrl.eViewport,{scroll:this.onHScroll.bind(this,uh)}),uf)){let t=this.ctrlsSvc.get(e);this.registerScrollPartner(t,this.onHScroll.bind(this,e))}}addVerticalScrollListeners(){let e=this.ctrlsSvc.get("fakeVScrollComp"),t=this.gos.get("debounceVerticalScrollbar"),n=t?oO(this,this.onVScroll.bind(this,uh),100):this.onVScroll.bind(this,uh),i=t?oO(this,this.onVScroll.bind(this,up),100):this.onVScroll.bind(this,up);this.addManagedElementListeners(this.eBodyViewport,{scroll:n}),this.registerScrollPartner(e,i)}registerScrollPartner(e,t){e.onScrollCallback(t)}onDisplayedColumnsWidthChanged(){this.enableRtl&&this.horizontallyScrollHeaderCenterAndFloating
376Center()}horizontallyScrollHeaderCenterAndFloatingCenter(e){null!=this.centerRowsCtrl&&(void 0===e&&(e=this.centerRowsCtrl.getCenterViewportScrollLeft()),this.setScrollLeftForAllContainersExceptCurrent(Math.abs(e)))}setScrollLeftForAllContainersExceptCurrent(e){for(let t of[...uf,uh])this.lastScrollSource[1]!==t&&r6(this.getViewportForSource(t),e,this.enableRtl)}getViewportForSource(e){return e===uh?this.centerRowsCtrl.eViewport:this.ctrlsSvc.get(e).eViewport}isControllingScroll(e,t){return null==this.lastScrollSource[t]?(0===t?this.lastScrollSource[0]=e:this.lastScrollSource[1]=e,!0):this.lastScrollSource[t]===e}onHScroll(e){if(!this.isControllingScroll(e,1))return;let{scrollLeft:t}=this.centerRowsCtrl.eViewport;if(this.shouldBlockScrollUpdate(1,t,!0))return;let n=r4(this.getViewportForSource(e),this.enableRtl);this.doHorizontalScroll(n),this.resetLastHScrollDebounced()}onVScroll(e){let t;if(!this.isControllingScroll(e,0)||(t=e===uh?this.eBodyViewport.scrollTop:this.ctrlsSvc.get("fakeVScrollComp").getScrollPosition(),this.shouldBlockScrollUpdate(0,t,!0)))return;let{animationFrameSvc:n}=this;n?.setScrollTop(t),this.nextScrollTop=t,e===uh?this.ctrlsSvc.get("fakeVScrollComp").setScrollPosition(t):this.eBodyViewport.scrollTop=t,n?.active?n.schedule():this.scrollGridIfNeeded(!0),this.resetLastVScrollDebounced()}doHorizontalScroll(e){let t=this.ctrlsSvc.get("fakeHScrollComp").getScrollPosition();(this.scrollLeft!==e||e!==t)&&(this.scrollLeft=e,this.fireScrollEvent(1),this.horizontallyScrollHeaderCenterAndFloatingCenter(e),this.centerRowsCtrl.onHorizontalViewportChanged(!0))}isScrolling(){return this.isScrollActive}fireScrollEvent(e){let t={type:"bodyScroll",direction:1===e?"horizontal":"vertical",left:this.scrollLeft,top:this.scrollTop};this.isScrollActive=!0,this.eventSvc.dispatchEvent(t),window.clearTimeout(this.scrollTimer),this.scrollTimer=window.setTimeout(()=>{this.scrollTimer=0,this.isScrollActive=!1,this.eventSvc.dispatchEvent({...t,type:"bodyScrollEnd"})},150)}shouldBlockScrollUpdate(e,t,n=!1){return(!n||!!ls())&&(0===e?this.shouldBlockVerticalScroll(t):this.shouldBlockHorizontalScroll(t))}shouldBlockVerticalScroll(e){let t=r0(this.eBodyViewport),{scrollHeight:n}=this.eBodyViewport;return!!(e<0||e+t>n)}shouldBlockHorizontalScroll(e){let t=this.centerRowsCtrl.getCenterWidth(),{scrollWidth:n}=this.centerRowsCtrl.eViewport;if(this.enableRtl){if(e>0)return!0}else if(e<0)return!0;return Math.abs(e)+t>n}redrawRowsAfterScroll(){this.fireScrollEvent(0)}checkScrollLeft(){let e=this.scrollLeft,t=!1;for(let n of uf)if(this.getViewportForSource(n).scrollLeft!==e){t=!0;break}t&&this.onHScroll(uh)}scrollGridIfNeeded(e=!1){let t=this.scrollTop!=this.nextScrollTop;return t&&(this.scrollTop=this.nextScrollTop,e&&this.invalidateVerticalScroll(),this.redrawRowsAfterScroll()),t}setHorizontalScrollPosition(e,t=!1){let n=this.centerRowsCtrl.eViewport.scrollWidth-this.centerRowsCtrl.getCenterWidth();!t&&this.shouldBlockScrollUpdate(1,e)&&(e=this.enableRtl?e>0?0:n:Math.min(Math.max(e,0),n)),r6(this.centerRowsCtrl.eViewport,Math.abs(e),this.enableRtl),this.doHorizontalScroll(e)}setVerticalScrollPosition(e){this.invalidateVerticalScroll(),this.eBodyViewport.scrollTop=e}getVScrollPosition(){if(!this.isVerticalPositionInvalidated){let{lastOffsetHeight:e,lastScrollTop:t}=this;return{top:t,bottom:t+e}}this.isVerticalPositionInvalidated=!1;let{scrollTop:e,offsetHeight:t}=this.eBodyViewport;return this.lastScrollTop=e,this.lastOffsetHeight=t,{top:e,bottom:e+t}}getApproximateVScollPosition(){return this.lastScrollTop>=0&&this.lastOffsetHeight>=0?{top:this.scrollTop,bottom:this.scrollTop+this.lastOffsetHeight}:this.getVScrollPosition()}getHScrollPosition(){return this.centerRowsCtrl.getHScrollPosition()}isHorizontalScrollShowing(){return this.isHorizontalPositionInvalidated&&(this.lastIsHorizontalScrollShowing=this.centerRowsCtrl.isHorizontalScrollShowing(),this.isHorizontalPositionInvalidated=!1),this.lastIsHorizontalScrollShowing}scrollHorizontally(e){let t=this.centerRowsCtrl.eViewport.scrollLeft;return this.setHorizontalScrollPosition(t+e),this.centerRowsCtrl.eViewport.scrollLeft-t}scrollToTop(){this.eBodyViewport.scrollTop=0}ensureNodeVisible(e,t=null){let{rowModel:n}=this.beans,i=n.getRowCount(),r=-1;for(let t=0;t<i;t++){let i=n.getRow(t);if("function"==typeof e){if(i&&e(i)){r=t;break}}else if(e===i||e===i.data){r=t;break}}r>=0&&this.ensureIndexVisible(r,t)}ensureIndexVisible(e,t,n=0){if(al(this.gos,"print"))return;let{rowModel:i}=this.beans,r=i.getRowCount();if("number"!=typeof e||e<0||e>=r)return void at(88,{index:e});this.clearRetryListeners();let{frameworkOverrides:o,pageBounds:a,rowContainerHeight:s,rowRenderer:l}=this.beans;o.wrapIncoming(()=>{let r,o,d=this.ctrlsSvc.getGridBodyCtrl(),u=i.getRow(e),c=0;this.invalidateVerticalScroll();do{let{stickyTopHeight:e,stickyBottomHeight:n}=d,i=u.rowTop,h=u.rowHeight,p=a.getPixelOffset(),f=u.rowTop-p,g=f+u.rowHeight,m=this.getVScrollPosition(),v=s.divStretchOffset,y=m.top+v,b=m.bottom+v,x=b-y,w=s.getScrollPositionForPixel(f),C=s.getScrollPositionForPixel(g-x),S=Math.min((w+C)/2,f),_=y+e>f,k=b-n<g,M=null;"top"===t?M=w-e:"bottom"===t?M=C+n:"middle"===t?M=S:_?M=w-e:k&&(M=C-w>x?w-e:C+n),null!==M&&(this.setVerticalScrollPosition(M),l.redraw({afterScroll:!0})),r=i!==u.rowTop||h!==u.rowHeight,o=e!==d.stickyTopHeight||n!==d.stickyBottomHeight,c++}while((r||o)&&c<10)if(this.animationFrameSvc?.flushAllFrames(),n<10&&(u?.stub||!this.beans.rowAutoHeight?.areRowsMeasured())){let r=this.getVScrollPosition().top;this.clearRetryListenerFncs=this.addManagedEventListeners({bodyScroll:()=>{r!==this.getVScrollPosition().top&&this.clearRetryListeners()},modelUpdated:()=>{this.clearRetryListeners(),e>=i.getRowCount()||this.ensureIndexVisible(e,t,n+1)}})}})}clearRetryListeners(){for(let e of this.clearRetryListenerFncs)e();this.clearRetryListenerFncs=[]}ensureColumnVisible(e,t="auto"){let{colModel:n,frameworkOverrides:i}=this.beans,r=n.getCol(e);if(!r||r.isPinned()||!this.visibleCols.isColDisplayed(r))return;let o=this.getPositionedHorizontalScroll(r,t);i.wrapIncoming(()=>{null!==o&&this.centerRowsCtrl.setCenterViewportScrollLeft(o),this.centerRowsCtrl.onHorizontalViewportChanged(),this.animationFrameSvc?.flushAllFrames()})}
376getPositionedHorizontalScroll(e,t){let{columnBeforeStart:n,columnAfterEnd:i}=this.isColumnOutsideViewport(e),r=this.centerRowsCtrl.getCenterWidth()<e.getActualWidth(),o=this.centerRowsCtrl.getCenterWidth(),a=this.enableRtl,s=(a?n:i)||r,l=a?i:n;"auto"!==t&&(s="start"===t,l="end"===t);let d="middle"===t;if(s||l||d){let{colLeft:t,colMiddle:n,colRight:i}=this.getColumnBounds(e);return d?n-o/2:s?a?i:t:a?t-o:i-o}return null}isColumnOutsideViewport(e){let{start:t,end:n}=this.getViewportBounds(),{colLeft:i,colRight:r}=this.getColumnBounds(e),o=this.enableRtl;return{columnBeforeStart:o?t>r:n<r,columnAfterEnd:o?n<i:t>i}}getColumnBounds(e){let t=this.enableRtl,n=this.visibleCols.bodyWidth,i=e.getActualWidth(),r=e.getLeft(),o=t?-1:1,a=t?n-r:r;return{colLeft:a,colMiddle:a+i/2*o,colRight:a+i*o}}getViewportBounds(){let e=this.centerRowsCtrl.getCenterWidth(),t=this.centerRowsCtrl.getCenterViewportScrollLeft();return{start:t,end:e+t,width:e}}},um=class extends oI{constructor(e,t=!1){super(),this.callback=e,this.addSpacer=t}postConstruct(){let e=this.setWidth.bind(this);this.addManagedPropertyListener("domLayout",e),this.addManagedEventListeners({columnContainerWidthChanged:e,displayedColumnsChanged:e,leftPinnedWidthChanged:e}),this.addSpacer&&this.addManagedEventListeners({rightPinnedWidthChanged:e,scrollVisibilityChanged:e,scrollbarWidthChanged:e}),this.setWidth()}setWidth(){let e,t=al(this.gos,"print"),{visibleCols:n,scrollVisibleSvc:i}=this.beans,r=n.bodyWidth,o=n.getColsLeftWidth(),a=n.getDisplayedColumnsRightWidth();t?e=r+o+a:(e=r,this.addSpacer&&0===(this.gos.get("enableRtl")?o:a)&&i.verticalScrollShowing&&(e+=i.getScrollbarWidth())),this.callback(e)}},uv=class extends oI{constructor(e){super(),this.centerContainerCtrl=e}wireBeans(e){this.scrollVisibleSvc=e.scrollVisibleSvc}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.listenForResize()}),this.addManagedEventListeners({scrollbarWidthChanged:this.onScrollbarWidthChanged.bind(this)}),this.addManagedPropertyListeners(["alwaysShowHorizontalScroll","alwaysShowVerticalScroll"],()=>{this.checkViewportAndScrolls()})}listenForResize(){let{beans:e,centerContainerCtrl:t,gridBodyCtrl:n}=this,i=()=>{op(e,()=>{this.onCenterViewportResized()})};t.registerViewportResizeListener(i),n.registerBodyViewportResizeListener(i)}onScrollbarWidthChanged(){this.checkViewportAndScrolls()}onCenterViewportResized(){if(this.scrollVisibleSvc.updateScrollGap(),this.centerContainerCtrl.isViewportInTheDOMTree()){let{pinnedCols:e,colFlex:t}=this.beans;e?.keepPinnedColumnsNarrowerThanViewport(),this.checkViewportAndScrolls();let n=this.centerContainerCtrl.getCenterWidth();n!==this.centerWidth&&(this.centerWidth=n,t?.refreshFlexedColumns({viewportWidth:this.centerWidth,updateBodyWidths:!0,fireResizedEvent:!0}))}else this.bodyHeight=0}checkViewportAndScrolls(){this.updateScrollVisibleService(),this.checkBodyHeight(),this.onHorizontalViewportChanged(),this.gridBodyCtrl.scrollFeature.checkScrollLeft()}getBodyHeight(){return this.bodyHeight}checkBodyHeight(){let e=r0(this.gridBodyCtrl.eBodyViewport);this.bodyHeight!==e&&(this.bodyHeight=e,this.eventSvc.dispatchEvent({type:"bodyHeightChanged"}))}updateScrollVisibleService(){this.updateScrollVisibleServiceImpl(),setTimeout(this.updateScrollVisibleServiceImpl.bind(this),500)}updateScrollVisibleServiceImpl(){if(!this.isAlive())return;let e={horizontalScrollShowing:this.centerContainerCtrl.isHorizontalScrollShowing(),verticalScrollShowing:this.gridBodyCtrl.isVerticalScrollShowing()};this.scrollVisibleSvc.setScrollsVisible(e)}onHorizontalViewportChanged(){let e=this.centerContainerCtrl.getCenterWidth(),t=this.centerContainerCtrl.getViewportScrollLeft();this.beans.colViewport.setScrollPosition(e,t)}};function uy(e,t,n,i){let r=t.getColDef().cellRendererParams?.suppressMouseEventHandling;return ub(e,t,n,i,r)}function ub(e,t,n,i,r){return!!r&&r(aN(e,{column:t,node:n,event:i}))}function ux(e,t,n){let i=t;for(;i;){let t=af(e,i,n);if(t)return t;i=i.parentElement}return null}var uw="cellCtrl",uC="renderedRow";function uS(e,t,n,i,r){let o=i?i.getColDef().suppressKeyboardEvent:void 0;if(!o)return!1;let a=aN(e,{event:t,editing:r,column:i,node:n,data:n.data,colDef:i.getColDef()});return!!(o&&o(a))||!1}var u_=class extends oI{constructor(e){super(),this.element=e}postConstruct(){this.addKeyboardListeners(),this.addMouseListeners(),this.beans.touchSvc?.mockRowContextMenu(this),this.editSvc=this.beans.editSvc}
376addKeyboardListeners(){let e="keydown",t=this.processKeyboardEvent.bind(this,e);this.addManagedElementListeners(this.element,{[e]:t})}addMouseListeners(){for(let e of["dblclick","contextmenu","mouseover","mouseout","click",ox("touchstart")?"touchstart":"mousedown"]){let t=this.processMouseEvent.bind(this,e);this.addManagedElementListeners(this.element,{[e]:t})}}processMouseEvent(e,t){if(!oS(this.beans,t)||ua(t))return;let{cellCtrl:n,rowCtrl:i}=this.getControlsForEventTarget(t.target);"contextmenu"===e?(n?.column&&n.dispatchCellContextMenuEvent(t),this.beans.contextMenuSvc?.handleContextMenuMouseEvent(t,void 0,i,n)):(n&&n.onMouseEvent(e,t),i&&i.onMouseEvent(e,t))}getControlsForEventTarget(e){let{gos:t}=this;return{cellCtrl:ux(t,e,uw),rowCtrl:ux(t,e,uC)}}processKeyboardEvent(e,t){let{cellCtrl:n,rowCtrl:i}=this.getControlsForEventTarget(t.target);!t.defaultPrevented&&(n?this.processCellKeyboardEvent(n,e,t):i?.isFullWidth()&&this.processFullWidthRowKeyboardEvent(i,e,t))}processCellKeyboardEvent(e,t,n){let i=this.editSvc?.isEditing(e,{withOpenEditor:!0})??!1;!uS(this.gos,n,e.rowNode,e.column,i)&&"keydown"===t&&(!i&&this.beans.navigation?.handlePageScrollingKey(n)||e.onKeyDown(n),this.doGridOperations(n,i),lb(n)&&e.processCharacter(n)),"keydown"===t&&this.eventSvc.dispatchEvent(e.createEvent(n,"cellKeyDown"))}processFullWidthRowKeyboardEvent(e,t,n){let{rowNode:i}=e,{focusSvc:r,navigation:o}=this.beans,a=r.getFocusedCell(),s=a?.column;if(!uS(this.gos,n,i,s,!1)){let i=n.key;if("keydown"===t)switch(i){case s8:case"End":case s4:case s6:o?.handlePageScrollingKey(n,!0);break;case s0:case s2:if(!this.gos.get("embedFullWidthRows"))break;case s1:case s3:e.onKeyboardNavigate(n);break;case"Tab":e.onTabKeyDown(n)}}"keydown"===t&&this.eventSvc.dispatchEvent(e.createRowEvent("cellKeyDown",n))}doGridOperations(e,t){if(!e.ctrlKey&&!e.metaKey||t||!oS(this.beans,e))return;let n=function(e){let t,{keyCode:n}=e;switch(n){case 65:t=s7;break;case 67:t=s9;break;case 86:t=lt;break;case 68:t=le;break;case 90:t=li;break;case 89:t=ln;break;default:t=e.code}return t}(e),{clipboardSvc:i,undoRedo:r}=this.beans;return n===s7?this.onCtrlAndA(e):n===s9?this.onCtrlAndC(i,e):n===le?this.onCtrlAndD(i,e):n===lt?this.onCtrlAndV(i,e):"KeyX"===n?this.onCtrlAndX(i,e):n===ln?this.onCtrlAndY(r):n===li?this.onCtrlAndZ(r,e):void 0}onCtrlAndA(e){let t,{beans:{rowModel:n,rangeSvc:i,selectionSvc:r},gos:o}=this;i&&aT(o)&&("string"==typeof(t=o.get("rowSelection"))||t?.mode!=="multiRow"||!t.ctrlASelectsRows)&&n.isRowsToRender()?!function(e){let t,n,{pinnedRowModel:i,rowModel:r}=e,[o,a]=[i?.isEmpty("top")??!0,i?.isEmpty("bottom")??!0];a?(t=null,n=r.getRowCount()-1):(t="bottom",n=i?.getPinnedBottomRowCount()??-1);let{visibleCols:s,rangeSvc:l}=e,d=s.allCols;l&&d?.length&&l.setCellRange({rowStartIndex:0,rowStartPinned:o?null:"top",rowEndIndex:n,rowEndPinned:t})}(this.beans):r&&r.selectAllRowNodes({source:"keyboardSelectAll",selectAll:aE(o)}),e.preventDefault()}onCtrlAndC(e,t){if(!e||this.gos.get("enableCellTextSelection"))return;let{cellCtrl:n}=this.getControlsForEventTarget(t.target);this.editSvc?.isEditing(n,{withOpenEditor:!0})||(t.preventDefault(),e.copyToClipboard())}onCtrlAndX(e,t){if(!e||this.gos.get("enableCellTextSelection")||this.gos.get("suppressCutToClipboard"))return;let{cellCtrl:n}=this.getControlsForEventTarget(t.target);this.editSvc?.isEditing(n,{withOpenEditor:!0})||(t.preventDefault(),e.cutToClipboard(void 0,"ui"))}onCtrlAndV(e,t){let{cellCtrl:n}=this.getControlsForEventTarget(t.target);this.editSvc?.isEditing(n,{withOpenEditor:!0})||e&&!this.gos.get("suppressClipboardPaste")&&e.pasteFromClipboard()}onCtrlAndD(e,t){e&&!this.gos.get("suppressClipboardPaste")&&e.copyRangeDown(),t.preventDefault()}onCtrlAndZ(e,t){this.gos.get("undoRedoCellEditing")&&e&&(t.preventDefault(),t.shiftKey?e.redo("ui"):e.undo("ui"))}onCtrlAndY(e){e?.redo("ui")}},uk=class extends oI{constructor(e,t){super(),this.eContainer=e,this.eViewport=t}postConstruct(){this.addManagedEventListeners({rowContainerHeightChanged:this.onHeightChanged.bind(this,this.beans.rowContainerHeight)})}onHeightChanged(e){let t=e.uiContainerHeight,n=null!=t?`${t}px`:"";this.eContainer.style.height=n,this.eViewport&&(this.eViewport.style.height=n)}},uM=e=>e.topRowCtrls,uT=e=>e.getStickyTopRowCtrls(),uD=e=>e.getStickyBottomRowCtrls(),uR=e=>e.bottomRowCtrls,uI=e=>e.allRowCtrls,uA=e=>e.getCtrls("top"),uP=e=>e.getCtrls("center"),uE=e=>
376e.getCtrls("bottom"),uL={center:{type:"center",name:"center-cols",getRowCtrls:uI,getSpannedRowCtrls:uP},left:{type:"left",name:"pinned-left-cols",pinnedType:"left",getRowCtrls:uI,getSpannedRowCtrls:uP},right:{type:"right",name:"pinned-right-cols",pinnedType:"right",getRowCtrls:uI,getSpannedRowCtrls:uP},fullWidth:{type:"fullWidth",name:"full-width",fullWidth:!0,getRowCtrls:uI},topCenter:{type:"center",name:"floating-top",getRowCtrls:uM,getSpannedRowCtrls:uA},topLeft:{type:"left",name:"pinned-left-floating",container:"ag-pinned-left-floating-top",pinnedType:"left",getRowCtrls:uM,getSpannedRowCtrls:uA},topRight:{type:"right",name:"pinned-right-floating",container:"ag-pinned-right-floating-top",pinnedType:"right",getRowCtrls:uM,getSpannedRowCtrls:uA},topFullWidth:{type:"fullWidth",name:"floating-top-full-width",fullWidth:!0,getRowCtrls:uM},stickyTopCenter:{type:"center",name:"sticky-top",getRowCtrls:uT},stickyTopLeft:{type:"left",name:"pinned-left-sticky-top",container:"ag-pinned-left-sticky-top",pinnedType:"left",getRowCtrls:uT},stickyTopRight:{type:"right",name:"pinned-right-sticky-top",container:"ag-pinned-right-sticky-top",pinnedType:"right",getRowCtrls:uT},stickyTopFullWidth:{type:"fullWidth",name:"sticky-top-full-width",fullWidth:!0,getRowCtrls:uT},stickyBottomCenter:{type:"center",name:"sticky-bottom",getRowCtrls:uD},stickyBottomLeft:{type:"left",name:"pinned-left-sticky-bottom",container:"ag-pinned-left-sticky-bottom",pinnedType:"left",getRowCtrls:uD},stickyBottomRight:{type:"right",name:"pinned-right-sticky-bottom",container:"ag-pinned-right-sticky-bottom",pinnedType:"right",getRowCtrls:uD},stickyBottomFullWidth:{type:"fullWidth",name:"sticky-bottom-full-width",fullWidth:!0,getRowCtrls:uD},bottomCenter:{type:"center",name:"floating-bottom",getRowCtrls:uR,getSpannedRowCtrls:uE},bottomLeft:{type:"left",name:"pinned-left-floating-bottom",container:"ag-pinned-left-floating-bottom",pinnedType:"left",getRowCtrls:uR,getSpannedRowCtrls:uE},bottomRight:{type:"right",name:"pinned-right-floating-bottom",container:"ag-pinned-right-floating-bottom",pinnedType:"right",getRowCtrls:uR,getSpannedRowCtrls:uE},bottomFullWidth:{type:"fullWidth",name:"floating-bottom-full-width",fullWidth:!0,getRowCtrls:uR}};function uF(e){let t=uL[e];return`ag-${t.name}-viewport`}function uO(e){let t=uL[e];return t.container??`ag-${t.name}-container`}var uN=["center","left","right","fullWidth"],uB=["stickyTopCenter","stickyBottomCenter","center","topCenter","bottomCenter"],uz=["left","bottomLeft","topLeft","stickyTopLeft","stickyBottomLeft"],uj=["right","bottomRight","topRight","stickyTopRight","stickyBottomRight"],uV=["stickyTopCenter","stickyTopLeft","stickyTopRight"],uH=["stickyBottomCenter","stickyBottomLeft","stickyBottomRight"],uG=[...uV,"stickyTopFullWidth",...uH,"stickyBottomFullWidth"],uW=["topCenter","topLeft","topRight","bottomCenter","bottomLeft","bottomRight","center","left","right",...uV,...uH],u$=class extends oI{constructor(e){super(),this.name=e,this.visible=!0,this.EMPTY_CTRLS=[],this.options=function(e){return uL[e]}(e)}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.forContainers(["center"],()=>{this.viewportSizeFeature=this.createManagedBean(new uv(this)),this.addManagedEventListeners({stickyTopOffsetChanged:this.onStickyTopOffsetChanged.bind(this)})})}onStickyTopOffsetChanged(e){this.comp.setOffsetTop(`${e.offset}px`)}registerWithCtrlsService(){this.options.fullWidth||this.beans.ctrlsSvc.register(this.name,this)}forContainers(e,t){e.indexOf(this.name)>=0&&t()}setComp(e,t,n,i){this.comp=e,this.eContainer=t,this.eSpannedContainer=n,this.eViewport=i,this.createManagedBean(new u_(this.eViewport??this.eContainer)),this.addPreventScrollWhileDragging(),this.listenOnDomOrder();let{pinnedCols:r,rangeSvc:o}=this.beans,a=()=>this.onPinnedWidthChanged();this.forContainers(uz,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(r?.createPinnedWidthFeature(!0,this.eContainer,this.eSpannedContainer)),this.addManagedEventListeners({leftPinnedWidthChanged:a})}),this.forContainers(uj,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(r?.createPinnedWidthFeature(!1,this.eContainer,this.eSpannedContainer)),this.addManagedEventListeners({rightPinnedWidthChanged:a})}),this.forContainers(uN,()=>this.createManagedBean(new uk(this.eContainer,"center"===this.name?i:void 0))),o&&this.forContainers(uW,()=>this.createManagedBean(o.createDragListenerFeature(this.eContainer))),this.forContainers(uB,()=>this.createManagedBean(new um(e=>this.comp.setContainerWidth(`${e}px`)))),this.visible=this.isContainerVisible(),this.addListeners(),this.registerWithCtrlsService()}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}addListeners(){let{spannedRowRenderer:e,gos:t}=this.beans,n=this.onDisplayedColumnsChanged.bind(this);this.addManagedEventListeners({displayedColumnsChanged:n,displayedColumnsWidthChanged:n,displayedRowsChanged:e=>this.onDisplayedRowsChanged(e.afterScroll)}),n(),this.onDisplayedRowsChanged(),e&&this.options.getSpannedRowCtrls&&t.get("enableCellSpan")&&this.addManagedListeners(e,{spannedRowsUpdated:()=>{let t=this.options.getSpannedRowCtrls(e);t&&this.comp.setSpannedRowCtrls(t,!1)}})}listenOnDomOrder(){if(uG.indexOf(this.name)>=0)return void this.comp.setDomOrder(!0);let e=()=>{let e=this.gos.get("ensureDomOrder"),t=al(this.gos,"print");this.comp.setDomOrder(e||t)};this.addManagedPropertyListener("domLayout",e),e()}onDisplayedColumnsChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}addPreventScrollWhileDragging(){let{dragSvc:e}=this.beans;if(!e)return;let t=t=>{e.dragging&&t.cancelable&&t.preventDefault()};this.eContainer.addEventListener("touchmove",t,{passive:!1}),this.addDestroyFunc(()=>this.eContainer.removeEventListener("touchmove",t))}onHorizontalViewportChanged(e=!1){let t=this.getCenterWidth(),n=this.getCenterViewportScrollLeft();this.beans.colViewport.setScrollPosition(t,n,e)}hasHorizontalScrollGap(){return this.eContainer.clientWidth-this.eViewport.clientWidth<0}hasVerticalScrollGap(){return this.eContainer.clientHeight-this.eViewport.clientHeight<0}getCenterWidth(){return r1(this.eViewport)}getCenterViewportScrollLeft(){return r4(this.eViewport,this.enableRtl)}registerViewportResizeListener(e){let t=oh(this.beans,this.eViewport,e);this.addDestroyFunc(()=>t())}isViewportInTheDOMTree(){return r9(this.eViewport)}getViewportScrollLeft(){return r4(this.eViewport,this.enableRtl)}
376isHorizontalScrollShowing(){return this.gos.get("alwaysShowHorizontalScroll")||oi(this.eViewport)}setHorizontalScroll(e){this.comp.setHorizontalScroll(e)}getHScrollPosition(){return{left:this.eViewport.scrollLeft,right:this.eViewport.scrollLeft+this.eViewport.offsetWidth}}setCenterViewportScrollLeft(e){r6(this.eViewport,e,this.enableRtl)}isContainerVisible(){return null==this.options.pinnedType||!!this.pinnedWidthFeature&&this.pinnedWidthFeature.getWidth()>0}onPinnedWidthChanged(){let e=this.isContainerVisible();this.visible!=e&&(this.visible=e,this.onDisplayedRowsChanged())}onDisplayedRowsChanged(e=!1){let t=this.options.getRowCtrls(this.beans.rowRenderer);if(!this.visible||0===t.length)return void this.comp.setRowCtrls({rowCtrls:this.EMPTY_CTRLS});let n=al(this.gos,"print"),i=this.gos.get("embedFullWidthRows")||n,r=t.filter(e=>{let t=e.isFullWidth();return this.options.fullWidth?!i&&t:i||!t});this.comp.setRowCtrls({rowCtrls:r,useFlushSync:e})}},uU=class extends oI{constructor(){super(...arguments),this.stickyTopHeight=0,this.stickyBottomHeight=0}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.colModel=e.colModel,this.scrollVisibleSvc=e.scrollVisibleSvc,this.pinnedRowModel=e.pinnedRowModel,this.filterManager=e.filterManager,this.rowGroupColsSvc=e.rowGroupColsSvc}setComp(e,t,n,i,r,o,a){this.comp=e,this.eGridBody=t,this.eBodyViewport=n,this.eTop=i,this.eBottom=r,this.eStickyTop=o,this.eStickyBottom=a,this.eCenterColsViewport=n.querySelector(`.${uF("center")}`),this.eFullWidthContainer=n.querySelector(`.${uO("fullWidth")}`),this.eStickyTopFullWidthContainer=o.querySelector(`.${uO("stickyTopFullWidth")}`),this.eStickyBottomFullWidthContainer=a.querySelector(`.${uO("stickyBottomFullWidth")}`),this.setCellTextSelection(this.gos.get("enableCellTextSelection")),this.addManagedPropertyListener("enableCellTextSelection",e=>this.setCellTextSelection(e.currentValue)),this.createManagedBean(new uc(this.comp)),this.scrollFeature=this.createManagedBean(new ug(n)),this.beans.rowDragSvc?.setupRowDrag(n,this),this.setupRowAnimationCssClass(),this.addEventListeners(),this.addFocusListeners([i,n,r,o,a]),this.setGridRootRole(),this.onGridColumnsChanged(),this.addBodyViewportListener(),this.setFloatingHeights(),this.disableBrowserDragging(),this.addStopEditingWhenGridLosesFocus(),this.updateScrollingClasses(),this.filterManager?.setupAdvFilterHeaderComp(i),this.ctrlsSvc.register("gridBodyCtrl",this)}addEventListeners(){let e=this.setFloatingHeights.bind(this),t=this.setGridRootRole.bind(this),n=this.toggleRowResizeStyles.bind(this);this.addManagedEventListeners({gridColumnsChanged:this.onGridColumnsChanged.bind(this),scrollVisibilityChanged:this.onScrollVisibilityChanged.bind(this),scrollGapChanged:this.updateScrollingClasses.bind(this),pinnedRowDataChanged:e,pinnedHeightChanged:e,pinnedRowsChanged:e,headerHeightChanged:this.setStickyTopOffsetTop.bind(this),columnRowGroupChanged:t,columnPivotChanged:t,rowResizeStarted:n,rowResizeEnded:n}),this.addManagedPropertyListener("treeData",t)}toggleRowResizeStyles(e){let t="rowResizeStarted"===e.type;this.eBodyViewport.classList.toggle("ag-prevent-animation",t)}onGridColumnsChanged(){let e=this.beans.colModel.getCols();this.comp.setColumnCount(e.length)}onScrollVisibilityChanged(){let{scrollVisibleSvc:e}=this,t=e.verticalScrollShowing;this.setVerticalScrollPaddingVisible(t),this.setStickyWidth(t),this.setStickyBottomOffsetBottom();let n=t&&e.getScrollbarWidth()||0,i=16*!!lu(),r=`calc(100% + ${n+i}px)`;op(this.beans,()=>this.comp.setBodyViewportWidth(r)),this.updateScrollingClasses()}setGridRootRole(){let{rowGroupColsSvc:e,colModel:t}=this,n=this.gos.get("treeData");if(!n){let i=t.isPivotMode();n=(e?e.columns.length:0)>=(i?2:1)}this.comp.setGridRootRole(n?"treegrid":"grid")}addFocusListeners(e){for(let t of e)this.addManagedElementListeners(t,{focusin:e=>{let{target:n}=e,i=rJ(n,"ag-root",t);t.classList.toggle("ag-has-focus",!i)},focusout:e=>{let{target:n,relatedTarget:i}=e,r=t.contains(i),o=rJ(i,"ag-root",t);rJ(n,"ag-root",t)||(!r||o)&&t.classList.remove("ag-has-focus")}})}setColumnMovingCss(e){this.comp.setColumnMovingCss("ag-column-moving",e)}setCellTextSelection(e=!1){this.comp.setCellSelectableCss("ag-selectable",e)}updateScrollingClasses(){let{eGridBody:{classList:e},scrollVisibleSvc:t}=this;e.toggle("ag-body-vertical-content-no-gap",!t.verticalScrollGap),e.toggle("ag-body-horizontal-content-no-gap",!t.horizontalScrollGap)}disableBrowserDragging(){this.addManagedElementListeners(this.eGridBody,{dragstart:e=>{if(e.target instanceof HTMLImageElement)return e.preventDefault(),!1}})}addStopEditingWhenGridLosesFocus(){this.beans.editSvc?.addStopEditingWhenGridLosesFocus([this.eBodyViewport,this.eBottom,this.eTop,this.eStickyTop,this.eStickyBottom])}updateRowCount(){let e=(this.ctrlsSvc.getHeaderRowContainerCtrl()?.getRowCount()??0)+(this.filterManager?.getHeaderRowCount()??0),{rowModel:t}=this.beans,n=t.isLastRowIndexKnown()?t.getRowCount():-1;this.comp.setRowCount(-1===n?-1:e+n)}registerBodyViewportResizeListener(e){this.comp.registerBodyViewportResizeListener(e)}setVerticalScrollPaddingVisible(e){this.comp.setPinnedTopBottomOverflowY(e?"scroll":"hidden")}isVerticalScrollShowing(){let e=this.gos.get("alwaysShowVerticalScroll"),t=al(this.gos,"normal");return this.comp.setAlwaysVerticalScrollClass(e?"ag-force-vertical-scroll":null,e),e||t&&or(this.eBodyViewport)}setupRowAnimationCssClass(){let{rowContainerHeight:e,environment:t}=this.beans,n=t.sizesMeasured,i=()=>{let t=n&&am(this.gos)&&!e.stretching;this.comp.setRowAnimationCssOnBodyViewport(t?"ag-row-animation":"ag-row-no-animation",t)};i(),this.addManagedEventListeners({heightScaleChanged:i}),this.addManagedPropertyListener("animateRows",i),this.addManagedEventListeners({gridStylesChanged:()=>{!n&&t.sizesMeasured&&(n=!0,i())}})}addBodyViewportListener(){let{eBodyViewport:e,eStickyTop:t,eStickyBottom:n,eTop:i,eBottom:r,beans:{popupSvc:o,touchSvc:a}}=this,s=this.onBodyViewportContextMenu.bind(this);this.addManagedElementListeners(e,{contextmenu:s}),a?.mockBodyContextMenu(this,s),this.addManagedElementListeners(e,{wheel:this.onBodyViewportWheel.bind(this,o)});let l=this.onStickyWheel.bind(this);for(let e of[t,n,i,r])this.addManagedElementListeners(e,{wheel:l});let d=this.onHorizontalWheel.bind(this);for(let e of["left","right","topLeft","topRight","bottomLeft","bottomRight"])this.addManagedElementListeners(this.ctrlsSvc.get(e).eContainer,{wheel:d});this.addFullWidthContainerWheelListener()}addFullWidthContainerWheelListener(){this.addManagedElementListeners(this.eFullWidthContainer,{wheel:e=>this.onFullWidthContainerWheel(e)})}onFullWidthContainerWheel(e){let{deltaX:t,deltaY:n,shiftKey:i}=e;(i||Math.abs(t)>Math.abs(n))&&oS(this.beans,e)&&this.scrollGridBodyToMatchEvent(e)}onStickyWheel(e){let{deltaY:t}=e;this.scrollVertically(t)>0&&e.preventDefault()}onHorizontalWheel(e){let{deltaX:t,deltaY:n,shiftKey:i}=e;(i||Math.abs(t)>Math.abs(n))&&this.scrollGridBodyToMatchEvent(e)}scrollGridBodyToMatchEvent(e){let{deltaX:t,deltaY:n}=e;e.preventDefault(),this.eCenterColsViewport.scrollBy({left:t||n})}onBodyViewportContextMenu(e,t,n){if(!e&&!n)return;this.gos.get("preventDefaultOnContextMenu")&&(e||n).preventDefault();let{target:i}=e||t;(i===this.eBodyViewport||i===this.ctrlsSvc.get("center").eViewport)&&this.beans.contextMenuSvc?.showContextMenu({mouseEvent:e,touchEvent:n,value:null,anchorToElement:this.eGridBody,source:"ui"})}onBodyViewportWheel(e,t){this.gos.get("suppressScrollWhenPopupsAreOpen")&&e?.hasAnchoredPopup()&&t.preventDefault()}scrollVertically(e){let t=this.eBodyViewport.scrollTop;return this.scrollFeature.setVerticalScrollPosition(t+e),this.eBodyViewport.scrollTop-t}setFloatingHeights(){let{pinnedRowModel:e,beans:{environment:t}}=this,n=e?.getPinnedTopTotalHeight(),i=e?.getPinnedBottomTotalHeight(),r=t.getPinnedRowBorderWidth()-t.getRowBorderWidth(),o=n?r+n:0,a=i?r+i:0;this.comp.setTopHeight(o),this.comp.setBottomHeight(a),this.comp.setTopInvisible(o<=0),this.comp.setBottomInvisible(a<=0),this.setStickyTopOffsetTop(),this.setStickyBottomOffsetBottom()}setStickyTopHeight(e=0){this.comp.setStickyTopHeight(`${e}px`),this.stickyTopHeight=e}setStickyBottomHeight(e=0){this.comp.setStickyBottomHeight(`${e}px`),this.stickyBottomHeight=e}setStickyWidth(e){if(e){let e=this.scrollVisibleSvc.getScrollbarWidth();this.comp.setStickyTopWidth(`calc(100% - ${e}px)`),this.comp.setStickyBottomWidth(`calc(100% - ${e}px)`)}else this.comp.setStickyTopWidth("100%"),this.comp.setStickyBottomWidth("100%")}setStickyTopOffsetTop(){let e=this.ctrlsSvc.get("gridHeaderCtrl").headerHeight+(this.filterManager?.getHeaderHeight()??0),t=this.pinnedRowModel?.getPinnedTopTotalHeight()??0,n=0;e>0&&(n+=e),t>0&&(n+=t),n>0&&(n+=1),this.comp.setStickyTopTop(`${n}px`)}setStickyBottomOffsetBottom(){let{pinnedRowModel:e,scrollVisibleSvc:t,comp:n}=this,i=e?.getPinnedBottomTotalHeight()??0,r=t.horizontalScrollShowing&&t.getScrollbarWidth()||0;n.setStickyBottomBottom(`${i+r}px`)}},uq=class extends sk{constructor(e,t){super(),this.direction=t,this.eViewport=null,this.eContainer=null,this.hideTimeout=0,this.setTemplate(e)}postConstruct(){this.addManagedEventListeners({scrollVisibilityChanged:this.onScrollVisibilityChanged.bind(this)}),this.onScrollVisibilityChanged(),this.toggleCss("ag-apple-scrollbar",la()||ls())}destroy(){super.destroy(),window.clearTimeout(this.hideTimeout)}initialiseInvisibleScrollbar(){void 0===this.invisibleScrollbar&&(this.invisibleScrollbar=lu(),this.invisibleScrollbar&&(this.hideAndShowInvisibleScrollAsNeeded(),this.addActiveListenerToggles())
376)}addActiveListenerToggles(){let e=this.getGui(),t=()=>this.toggleCss("ag-scrollbar-active",!0),n=()=>this.toggleCss("ag-scrollbar-active",!1);this.addManagedListeners(e,{mouseenter:t,mousedown:t,touchstart:t,mouseleave:n,touchend:n})}onScrollVisibilityChanged(){void 0===this.invisibleScrollbar&&this.initialiseInvisibleScrollbar(),op(this.beans,()=>this.setScrollVisible())}hideAndShowInvisibleScrollAsNeeded(){this.addManagedEventListeners({bodyScroll:e=>{e.direction===this.direction&&(this.hideTimeout&&(window.clearTimeout(this.hideTimeout),this.hideTimeout=0),this.toggleCss("ag-scrollbar-scrolling",!0))},bodyScrollEnd:()=>{this.hideTimeout=window.setTimeout(()=>{this.toggleCss("ag-scrollbar-scrolling",!1),this.hideTimeout=0},400)}})}attemptSettingScrollPosition(e){let t=this.eViewport;!function(e,t,n,i=100){let r=Date.now(),o=null,a=!1,s=()=>{null!=o&&(window.clearInterval(o),o=null)};e.addDestroyFunc(s);let l=()=>{let e=Date.now()-r>i;(t()||e)&&(n(),a=!0,s())};l(),a||(o=window.setInterval(l,10))}(this,()=>oe(t),()=>this.setScrollPosition(e),100)}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}},uK={tag:"div",cls:"ag-body-horizontal-scroll",attrs:{"aria-hidden":"true"},children:[{tag:"div",ref:"eLeftSpacer",cls:"ag-horizontal-left-spacer"},{tag:"div",ref:"eViewport",cls:"ag-body-horizontal-scroll-viewport",children:[{tag:"div",ref:"eContainer",cls:"ag-body-horizontal-scroll-container"}]},{tag:"div",ref:"eRightSpacer",cls:"ag-horizontal-right-spacer"}]},uY=class extends uq{constructor(){super(uK,"horizontal"),this.eLeftSpacer=null,this.eRightSpacer=null,this.setScrollVisibleDebounce=0}wireBeans(e){this.visibleCols=e.visibleCols,this.scrollVisibleSvc=e.scrollVisibleSvc}postConstruct(){super.postConstruct();let e=this.setFakeHScrollSpacerWidths.bind(this);this.addManagedEventListeners({displayedColumnsChanged:e,displayedColumnsWidthChanged:e,pinnedRowDataChanged:this.refreshCompBottom.bind(this)}),this.addManagedPropertyListener("domLayout",e),this.beans.ctrlsSvc.register("fakeHScrollComp",this),this.createManagedBean(new um(e=>this.eContainer.style.width=`${e}px`)),this.addManagedPropertyListeners(["suppressHorizontalScroll"],this.onScrollVisibilityChanged.bind(this))}destroy(){window.clearTimeout(this.setScrollVisibleDebounce),super.destroy()}initialiseInvisibleScrollbar(){void 0===this.invisibleScrollbar&&(this.enableRtl=this.gos.get("enableRtl"),super.initialiseInvisibleScrollbar(),this.invisibleScrollbar&&this.refreshCompBottom())}refreshCompBottom(){if(!this.invisibleScrollbar)return;let e=this.beans.pinnedRowModel?.getPinnedBottomTotalHeight()??0;this.getGui().style.bottom=`${e}px`}onScrollVisibilityChanged(){super.onScrollVisibilityChanged(),this.setFakeHScrollSpacerWidths()}setFakeHScrollSpacerWidths(){let e=this.scrollVisibleSvc.verticalScrollShowing,t=this.visibleCols.getDisplayedColumnsRightWidth(),n=!this.enableRtl&&e,i=this.scrollVisibleSvc.getScrollbarWidth();n&&(t+=i),oa(this.eRightSpacer,t),this.eRightSpacer.classList.toggle("ag-scroller-corner",t<=i);let r=this.visibleCols.getColsLeftWidth();this.enableRtl&&e&&(r+=i),oa(this.eLeftSpacer,r),this.eLeftSpacer.classList.toggle("ag-scroller-corner",r<=i)}setScrollVisible(){let e=this.scrollVisibleSvc.horizontalScrollShowing,t=this.invisibleScrollbar,n=this.gos.get("suppressHorizontalScroll"),i=e&&this.scrollVisibleSvc.getScrollbarWidth()||0,r=0===i&&t?16:i,o=n?0:r,a=()=>{this.setScrollVisibleDebounce=0,this.toggleCss("ag-scrollbar-invisible",t),ol(this.getGui(),o),ol(this.eViewport,o),ol(this.eContainer,o),o||this.eContainer.style.setProperty("min-height","1px"),this.setVisible(e,{skipAriaHidden:!0})};window.clearTimeout(this.setScrollVisibleDebounce),e?this.setScrollVisibleDebounce=window.setTimeout(a,100):a()}getScrollPosition(){return r4(this.eViewport,this.enableRtl)}setScrollPosition(e){oe(this.eViewport)||this.attemptSettingScrollPosition(e),r6(this.eViewport,e,this.enableRtl)}},uZ={tag:"div",cls:"ag-body-vertical-scroll",attrs:{"aria-hidden":"true"},children:[{tag:"div",ref:"eViewport",cls:"ag-body-vertical-scroll-viewport",children:[{tag:"div",ref:"eContainer",cls:"ag-body-vertical-scroll-container"}]}]},uX=class extends uq{constructor(){super(uZ,"vertical")}
376postConstruct(){super.postConstruct(),this.createManagedBean(new uk(this.eContainer));let{ctrlsSvc:e}=this.beans;e.register("fakeVScrollComp",this),this.addManagedEventListeners({rowContainerHeightChanged:this.onRowContainerHeightChanged.bind(this,e)})}setScrollVisible(){let{scrollVisibleSvc:e}=this.beans,t=e.verticalScrollShowing,n=this.invisibleScrollbar,i=t&&e.getScrollbarWidth()||0,r=0===i&&n?16:i;this.toggleCss("ag-scrollbar-invisible",n),oa(this.getGui(),r),oa(this.eViewport,r),oa(this.eContainer,r),this.setDisplayed(t,{skipAriaHidden:!0})}onRowContainerHeightChanged(e){let t=e.getGridBodyCtrl().eBodyViewport,n=this.getScrollPosition(),i=t.scrollTop;n!=i&&this.setScrollPosition(i,!0)}getScrollPosition(){return this.eViewport.scrollTop}setScrollPosition(e,t){t||oe(this.eViewport)||this.attemptSettingScrollPosition(e),this.eViewport.scrollTop=e}};function uJ(e,t,n,i){return rS(e)?[]:function(e,t,n,i,r){let o;if(rS(e))return[];if("function"==typeof e)o=e(aN(n,{colDef:t,column:i,columnGroup:r}));else o=e;return"string"==typeof o?[o]:Array.isArray(o)?[...o]:[]}(e.headerClass,e,t,n,i)}function uQ(e,t,n){e.toggleCss("ag-column-first",n.isColAtEdge(t,"first")),e.toggleCss("ag-column-last",n.isColAtEdge(t,"last"))}function u0(e){return e.gos.get("suppressHeaderFocus")||!!e.overlays?.isExclusive()}function u1(e){return e.gos.get("suppressCellFocus")||!!e.overlays?.isExclusive()}function u2(e,t,n=!1){let i=e.ctrlsSvc.get("gridCtrl");return!!(!n&&i.focusNextInnerContainer(t))||(!n&&(t||i.isDetailGrid())||i.forceFocusOutOfContainer(t),!1)}function u3(e){return e.ctrlsSvc.getHeaderRowContainerCtrl()?.getRowCount()??0}function u5(e){let t=[];for(let n of e.ctrlsSvc.getHeaderRowContainerCtrls()){if(!n)continue;let i=n.getGroupRowCount()||0;for(let r=0;r<i;r++){let i=n.getGroupRowCtrlAtIndex(r),o=t[r];if(i){let n=function(e,t){var n;let i=e.colModel.isPivotMode()?(n=e).gos.get("pivotGroupHeaderHeight")??u7(n):u7(e);for(let e of t.getHeaderCellCtrls()){let{column:t}=e,n=t.getAutoHeaderHeight();null!=n&&n>i&&t.isAutoHeaderHeight()&&(i=n)}return i}(e,i);(null==o||n>o)&&(t[r]=n)}}}return t}function u4(e){var t;let n=e.colModel.isPivotMode()?(t=e).gos.get("pivotHeaderHeight")??u6(t):u6(e);return e.colModel.forAllCols(e=>{let t=e.getAutoHeaderHeight();null!=t&&t>n&&e.isAutoHeaderHeight()&&(n=t)}),n}function u6(e){return e.gos.get("headerHeight")??e.environment.getDefaultHeaderHeight()}function u8(e){return e.gos.get("floatingFiltersHeight")??u6(e)}function u7(e){return e.gos.get("groupHeaderHeight")??u6(e)}var u9=class extends oI{setComp(e,t,n){this.comp=e,this.eGui=t;let{beans:i}=this,{headerNavigation:r,touchSvc:o,ctrlsSvc:a}=i;r&&this.createManagedBean(new us(n,{onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addManagedEventListeners({columnPivotModeChanged:this.onPivotModeChanged.bind(this,i),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this,i)}),this.onPivotModeChanged(i),this.setupHeaderHeight();let s=this.onHeaderContextMenu.bind(this);this.addManagedElementListeners(this.eGui,{contextmenu:s}),o?.mockHeaderContextMenu(this,s),a.register("gridHeaderCtrl",this)}setupHeaderHeight(){let e=this.setHeaderHeight.bind(this);e(),this.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],e),this.addManagedEventListeners({headerRowsChanged:e,columnHeaderHeightChanged:e,columnGroupHeaderHeightChanged:()=>op(this.beans,()=>e()),gridStylesChanged:e,advancedFilterEnabledChanged:e})}setHeaderHeight(){let{beans:e}=this,t=0,n=u5(e).reduce((e,t)=>e+t,0),i=u4(e);if(e.filterManager?.hasFloatingFilters()&&(t+=u8(e)),t+=n,t+=i,this.headerHeight===t)return;this.headerHeight=t;let r=`${t+1}px`;this.comp.setHeightAndMinHeight(r),this.eventSvc.dispatchEvent({type:"headerHeightChanged"})}onPivotModeChanged(e){let t=e.colModel.isPivotMode();this.comp.toggleCss("ag-pivot-on",t),this.comp.toggleCss("ag-pivot-off",!t)}onDisplayedColumnsChanged(e){let t=e.visibleCols.allCols.some(e=>e.isSpanHeaderHeight());this.comp.toggleCss("ag-header-allow-overflow",t)}onTabKeyDown(e){let t=this.gos.get("enableRtl"),n=e.shiftKey,{beans:i}=this,{headerNavigation:r,focusSvc:o}=i;(r.navigateHorizontally(n!==t?"LEFT":"RIGHT",!0,e)||!n&&o.focusOverlay(!1)||u2(i,n,!0))&&e.preventDefault()}handleKeyDown(e){let t=null,{headerNavigation:n}=this.beans;switch(e.key){case s0:t="LEFT";case s2:rC(t)||(t="RIGHT"),n.navigateHorizontally(t,!1,e)&&e.preventDefault();break;case s1:t="UP";case s3:rC(t)||(t="DOWN"),n.navigateVertically(t,e)&&e.preventDefault();break;default:return}}onFocusOut(e){let{relatedTarget:t}=e,{eGui:n,beans:i}=this;
376!(!t&&n.contains(rA(i)))&&(n.contains(t)||(i.focusSvc.focusedHeader=null))}onHeaderContextMenu(e,t,n){let{menuSvc:i,ctrlsSvc:r}=this.beans;if(!e&&!n||!i?.isHeaderContextMenuEnabled())return;let{target:o}=e??t;(o===this.eGui||o===r.getHeaderRowContainerCtrl()?.eViewport)&&i.showHeaderContextMenu(void 0,e,n)}},ce=class extends oI{constructor(e,t,n,i){super(),this.columnOrGroup=e,this.eCell=t,this.colsSpanning=i,this.columnOrGroup=e,this.ariaEl=t.querySelector("[role=columnheader]")||t,this.beans=n}setColsSpanning(e){this.colsSpanning=e,this.onLeftChanged()}getColumnOrGroup(){let{beans:e,colsSpanning:t}=this;return e.gos.get("enableRtl")&&t?aY(t):this.columnOrGroup}postConstruct(){let e=this.onLeftChanged.bind(this);this.addManagedListeners(this.columnOrGroup,{leftChanged:e}),this.setLeftFirstTime(),this.addManagedEventListeners({displayedColumnsWidthChanged:e}),this.addManagedPropertyListener("domLayout",e)}setLeftFirstTime(){let{gos:e,colAnimation:t}=this.beans,n=e.get("suppressColumnMoveAnimation"),i=rC(this.columnOrGroup.getOldLeft());t?.isActive()&&i&&!n?this.animateInLeft():this.onLeftChanged()}animateInLeft(){let e=this.getColumnOrGroup(),t=this.modifyLeftForPrintLayout(e,e.getOldLeft()),n=this.modifyLeftForPrintLayout(e,e.getLeft());this.setLeft(t),this.actualLeft=n,this.beans.colAnimation.executeNextVMTurn(()=>{this.actualLeft===n&&this.setLeft(n)})}onLeftChanged(){let e=this.getColumnOrGroup(),t=e.getLeft();this.actualLeft=this.modifyLeftForPrintLayout(e,t),this.setLeft(this.actualLeft)}modifyLeftForPrintLayout(e,t){let{gos:n,visibleCols:i}=this.beans;if(!al(n,"print")||"left"===e.getPinned())return t;let r=i.getColsLeftWidth();return"right"===e.getPinned()?r+i.bodyWidth+t:r+t}setLeft(e){if(rC(e)&&(this.eCell.style.left=`${e}px`),dL(this.columnOrGroup)){let e=this.columnOrGroup.getLeafColumns();e.length&&e.length>1&&rN(this.ariaEl,"colspan",e.length)}}},ct=0,cn="headerCtrl",ci=class extends oI{constructor(e,t){super(),this.column=e,this.rowCtrl=t,this.resizeToggleTimeout=0,this.resizeMultiplier=1,this.resizeFeature=null,this.lastFocusEvent=null,this.dragSource=null,this.reAttemptToFocus=!1,this.instanceId=e.getUniqueId()+"-"+ct++}postConstruct(){let e=this.refreshTabIndex.bind(this);this.addManagedPropertyListeners(["suppressHeaderFocus"],e),this.addManagedEventListeners({overlayExclusiveChanged:e})}setComp(e,t,n,i,r){t.setAttribute("col-id",this.column.colIdSanitised),this.wireComp(e,t,n,i,r),this.reAttemptToFocus&&(this.reAttemptToFocus=!1,this.focus(this.lastFocusEvent??void 0))}shouldStopEventPropagation(e){let{headerRowIndex:t,column:n}=this.beans.focusSvc.focusedHeader,i=n.getDefinition(),r=i?.suppressHeaderKeyboardEvent;return!!rC(r)&&!!r(aN(this.gos,{colDef:i,column:n,headerRowIndex:t,event:e}))}getWrapperHasFocus(){return rA(this.beans)===this.eGui}setGui(e,t){this.eGui=e,this.addDomData(t),t.addManagedListeners(this.beans.eventSvc,{displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this)}),t.addManagedElementListeners(this.eGui,{focus:this.onGuiFocus.bind(this)}),this.onDisplayedColumnsChanged(),this.refreshTabIndex()}refreshHeaderStyles(){let e,t=this.column.getDefinition();if(!t)return;let{headerStyle:n}=t;(e="function"==typeof n?n(this.getHeaderClassParams()):n)&&this.comp.setUserStyles(e)}onGuiFocus(){this.eventSvc.dispatchEvent({type:"headerFocused",column:this.column})}setupAutoHeight(e){let t,{wrapperElement:n,checkMeasuringCallback:i,compBean:r}=e,{beans:o}=this,a=e=>{if(!this.isAlive()||!r.isAlive())return;let{paddingTop:t,paddingBottom:i,borderBottomWidth:s,borderTopWidth:l}=rQ(this.eGui),d=n.offsetHeight+(t+i+s+l);if(e<5){let t=rP(o),i=!t?.contains(n),r=0==d;if(i||r)return void oF(()=>a(e+1),"raf",o)}this.setColHeaderHeight(this.column,d)},s=!1,l=()=>{let e=this.column.isAutoHeaderHeight();e&&!s&&d(),!e&&s&&u()},d=()=>{s=!0,this.comp.toggleCss("ag-header-cell-auto-height",!0),a(0),t=oh(this.beans,n,()=>a(0))},u=()=>{s=!1,t&&t(),this.comp.toggleCss("ag-header-cell-auto-height",!1),t=void 0};l(),r.addDestroyFunc(()=>u()),r.addManagedListeners(this.column,{widthChanged:()=>s&&a(0)}),r.addManagedEventListeners({sortChanged:()=>{s&&window.setTimeout(()=>a(0))}}),i&&i(l)}onDisplayedColumnsChanged(){let{comp:e,column:t,beans:n,eGui:i}=this;e&&t&&i&&(uQ(e,t,n.visibleCols),r$(i,n.visibleCols.getAriaColIndex(t)))}addResizeAndMoveKeyboardListeners(e){e.addManagedListeners(this.eGui,{keydown:this.onGuiKeyDown.bind(this),keyup:this.onGuiKeyUp.bind(this)})}refreshTabIndex(){let e=u0(this.beans);this.eGui&&oc(this.eGui,"tabindex",e?null:"-1")}onGuiKeyDown(e){let t=rA(this.beans),n=e.key===s0||e.key===s2;if(this.isResizing&&(e.preventDefault(),e.stopImmediatePropagation()),t!==this.eGui||!e.shiftKey&&!e.altKey||((this.isResizing||n)&&(e.preventDefault(),e.stopImmediatePropagation()),!n))return;let i=e.key===s0!==this.gos.get("enableRtl");if(e.altKey){this.isResizing=!0,this.resizeMultiplier+=1;let t=this.getViewportAdjustedResizeDiff(e);
376this.resizeHeader(t,e.shiftKey),this.resizeFeature?.toggleColumnResizing(!0)}else this.moveHeader(i?"left":"right")}moveHeader(e){this.beans.colMoves?.moveHeader(e,this.eGui,this.column,this.rowCtrl.pinned,this)}getViewportAdjustedResizeDiff(e){let t=this.getResizeDiff(e),{pinnedCols:n}=this.beans;return n?n.getHeaderResizeDiff(t,this.column):t}getResizeDiff(e){let{gos:t,column:n}=this,i=e.key===s0!==t.get("enableRtl"),r=n.getPinned(),o=t.get("enableRtl");return r&&o!==("right"===r)&&(i=!i),(i?-1:1)*this.resizeMultiplier}onGuiKeyUp(){this.isResizing&&(this.resizeToggleTimeout&&(window.clearTimeout(this.resizeToggleTimeout),this.resizeToggleTimeout=0),this.isResizing=!1,this.resizeMultiplier=1,this.resizeToggleTimeout=window.setTimeout(()=>{this.resizeFeature?.toggleColumnResizing(!1)},150))}handleKeyDown(e){let t=this.getWrapperHasFocus();switch(e.key){case s6:case s4:case s8:case"End":t&&e.preventDefault()}}addDomData(e){let{eGui:t,gos:n}=this;ag(n,t,cn,this),e.addDestroyFunc(()=>ag(n,t,cn,null))}focus(e){if(!this.isAlive())return!1;let{eGui:t}=this;return t?(t.focus(),this.lastFocusEvent=e||null):this.reAttemptToFocus=!0,!0}focusThis(){this.beans.focusSvc.focusedHeader={headerRowIndex:this.rowCtrl.rowIndex,column:this.column}}removeDragSource(){this.dragSource&&(this.beans.dragAndDrop?.removeDragSource(this.dragSource),this.dragSource=null)}handleContextMenuMouseEvent(e,t,n){let i=e??t,{menuSvc:r,gos:o}=this.beans;o.get("preventDefaultOnContextMenu")&&i.preventDefault(),r?.isHeaderContextMenuEnabled(n)&&r.showHeaderContextMenu(n,e,t),this.dispatchColumnMouseEvent("columnHeaderContextMenu",n)}dispatchColumnMouseEvent(e,t){this.eventSvc.dispatchEvent({type:e,column:t})}setColHeaderHeight(e,t){if(!e.setAutoHeaderHeight(t))return;let{eventSvc:n}=this;e.isColumn?n.dispatchEvent({type:"columnHeaderHeightChanged",column:e,columns:[e],source:"autosizeColumnHeaderHeight"}):n.dispatchEvent({type:"columnGroupHeaderHeightChanged",columnGroup:e,source:"autosizeColumnGroupHeaderHeight"})}clearComponent(){this.removeDragSource(),this.resizeFeature=null,this.comp=null,this.eGui=null}destroy(){super.destroy(),this.column=null,this.lastFocusEvent=null,this.rowCtrl=null}},cr=class extends ci{constructor(){super(...arguments),this.refreshFunctions={},this.userHeaderClasses=new Set,this.ariaDescriptionProperties=new Map}wireComp(e,t,n,i,r){this.comp=e;let{rowCtrl:o,column:a,beans:s}=this,{colResize:l,context:d,colHover:u,rangeSvc:c}=s,h=sx(this,d,r);this.setGui(t,h),this.updateState(),this.setupWidth(h),this.setupMovingCss(h),this.setupMenuClass(h),this.setupSortableClass(h),this.setupWrapTextClass(),this.refreshSpanHeaderHeight(),this.setupAutoHeight({wrapperElement:i,checkMeasuringCallback:e=>this.setRefreshFunction("measuring",e),compBean:h}),this.addColumnHoverListener(h),this.setupFilterClass(h),this.setupStylesFromColDef(),this.setupClassesFromColDef(),this.setupTooltip(),this.addActiveHeaderMouseListeners(h),this.setupSelectAll(h),this.setupUserComp(),this.refreshAria(),l?this.resizeFeature=h.createManagedBean(l.createResizeFeature(o.pinned,a,n,e,this)):rZ(n,!1),u?.createHoverFeature(h,[a],t),c?.createRangeHighlightFeature(h,a,e),h.createManagedBean(new ce(a,t,s)),h.createManagedBean(new us(t,{shouldStopEventPropagation:e=>this.shouldStopEventPropagation(e),onTabKeyDown:()=>null,handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addResizeAndMoveKeyboardListeners(h),h.addManagedPropertyListeners(["suppressMovableColumns","suppressMenuHide","suppressAggFuncInHeader","enableAdvancedFilter"],()=>this.refresh()),h.addManagedListeners(a,{colDefChanged:()=>this.refresh()}),h.addManagedListeners(a,{headerHighlightChanged:this.onHeaderHighlightChanged.bind(this)});let p=()=>this.checkDisplayName();h.addManagedEventListeners({columnValueChanged:p,columnRowGroupChanged:p,columnPivotChanged:p,headerHeightChanged:this.onHeaderHeightChanged.bind(this)}),h.addDestroyFunc(()=>{this.refreshFunctions={},this.selectAllFeature=null,this.dragSourceElement=void 0,this.userCompDetail
376s=null,this.userHeaderClasses.clear(),this.ariaDescriptionProperties.clear(),this.clearComponent()})}resizeHeader(e,t){this.beans.colResize?.resizeHeader(this.column,e,t)}getHeaderClassParams(){let{column:e,beans:t}=this,n=e.colDef;return aN(t.gos,{colDef:n,column:e,floatingFilter:!1})}setupUserComp(){let e=this.lookupUserCompDetails();e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setUserCompDetails(e)}lookupUserCompDetails(){var e;let t=this.createParams(),n=this.column.getColDef();return e=this.beans.userCompFactory,e.getCompDetails(n,sP,"agColumnHeader",t)}createParams(){let{menuSvc:e,sortSvc:t,colFilter:n,gos:i}=this.beans;return aN(i,{column:this.column,displayName:this.displayName,enableSorting:this.column.isSortable(),enableMenu:this.menuEnabled,enableFilterButton:this.openFilterEnabled&&!!e?.isHeaderFilterButtonEnabled(this.column),enableFilterIcon:!!n&&(!this.openFilterEnabled||aO(this.gos)),showColumnMenu:(t,n)=>{e?.showColumnMenu({column:this.column,buttonElement:t,positionBy:"button",onClosedCallback:n})},showColumnMenuAfterMouseClick:(t,n)=>{e?.showColumnMenu({column:this.column,mouseEvent:t,positionBy:"mouse",onClosedCallback:n})},showFilter:t=>{e?.showFilterMenu({column:this.column,buttonElement:t,containerType:"columnFilter",positionBy:"button"})},progressSort:e=>{t?.progressSort(this.column,!!e,"uiColumnSorted")},setSort:(e,n)=>{t?.setSortForColumn(this.column,e,!!n,"uiColumnSorted")},eGridHeader:this.eGui,setTooltip:(e,t)=>{i.assertModuleRegistered("Tooltip",3),this.setupTooltip(e,t)}})}setupSelectAll(e){let{selectionSvc:t}=this.beans;t&&(this.selectAllFeature=e.createOptionalManagedBean(t.createSelectAllFeature(this.column)),this.selectAllFeature?.setComp(this),e.addManagedPropertyListener("rowSelection",()=>{let n=t.createSelectAllFeature(this.column);n&&!this.selectAllFeature?(this.selectAllFeature=e.createManagedBean(n),this.selectAllFeature?.setComp(this),this.comp.refreshSelectAllGui()):this.selectAllFeature&&!n&&(this.comp.removeSelectAllGui(),this.selectAllFeature=this.destroyBean(this.selectAllFeature))}))}getSelectAllGui(){return this.selectAllFeature?.getCheckboxGui()}handleKeyDown(e){super.handleKeyDown(e)," "===e.key&&this.selectAllFeature?.onSpaceKeyDown(e),e.key===sJ&&this.onEnterKeyDown(e),e.key===s3&&e.altKey&&this.showMenuOnKeyPress(e,!1)}onEnterKeyDown(e){e.ctrlKey||e.metaKey?this.showMenuOnKeyPress(e,!0):this.sortable&&this.beans.sortSvc?.progressSort(this.column,e.shiftKey,"uiColumnSorted")}showMenuOnKeyPress(e,t){let n=this.comp.getUserCompInstance();co(n)&&n.onMenuKeyboardShortcut(t)&&e.preventDefault()}onFocusIn(e){this.eGui.contains(e.relatedTarget)||(this.focusThis(),this.announceAriaDescription()),lx&&this.setActiveHeader(!0)}onFocusOut(e){this.eGui.contains(e.relatedTarget)||this.setActiveHeader(!1)}setupTooltip(e,t){this.tooltipFeature=this.beans.tooltipSvc?.setupHeaderTooltip(this.tooltipFeature,this,e,t)}setupStylesFromColDef(){this.setRefreshFunction("headerStyles",this.refreshHeaderStyles.bind(this)),this.refreshHeaderStyles()}setupClassesFromColDef(){let e=()=>{let e=uJ(this.column.getColDef(),this.gos,this.column,null),t=this.userHeaderClasses;for(let n of(this.userHeaderClasses=new Set(e),e))t.has(n)?t.delete(n):this.comp.toggleCss(n,!0);for(let e of t)this.comp.toggleCss(e,!1)};this.setRefreshFunction("headerClasses",e),e()}setDragSource(e){this.dragSourceElement=e,this.removeDragSource(),e&&this.draggable&&(this.dragSource=this.beans.colMoves?.setDragSourceForHeader(e,this.column,this.displayName)??null)}updateState(){let{menuSvc:e}=this.beans;this.menuEnabled=!!e?.isColumnMenuInHeaderEnabled(this.column),this.openFilterEnabled=!!e?.isFilterMenuInHeaderEnabled(this.column),this.sortable=this.column.isSortable(),this.displayName=this.calculateDisplayName(),this.draggable=this.workOutDraggable()}setRefreshFunction(e,t){this.refreshFunctions[e]=t}refresh(){for(let e of(this.updateState(),this.refreshHeaderComp(),this.refreshAria(),Object.values(this.refreshFunctions)))e()}refreshHeaderComp(){let e=this.lookupUserCompDetails();
376e&&(null!=this.comp.getUserCompInstance()&&this.userCompDetails.componentClass==e.componentClass&&this.attemptHeaderCompRefresh(e.params)?this.setDragSource(this.dragSourceElement):this.setCompDetails(e))}attemptHeaderCompRefresh(e){let t=this.comp.getUserCompInstance();return!!t&&!!t.refresh&&t.refresh(e)}calculateDisplayName(){return this.beans.colNames.getDisplayNameForColumn(this.column,"header",!0)}checkDisplayName(){this.displayName!==this.calculateDisplayName()&&this.refresh()}workOutDraggable(){let e=this.column.getColDef();return!!(!this.gos.get("suppressMovableColumns")&&!e.suppressMovable&&!e.lockPosition)||!!e.enableRowGroup||!!e.enablePivot}setupWidth(e){let t=()=>{let e=this.column.getActualWidth();this.comp.setWidth(`${e}px`)};e.addManagedListeners(this.column,{widthChanged:t}),t()}setupMovingCss(e){let t=()=>{this.comp.toggleCss("ag-header-cell-moving",this.column.isMoving())};e.addManagedListeners(this.column,{movingChanged:t}),t()}setupMenuClass(e){let t=()=>{this.comp?.toggleCss("ag-column-menu-visible",this.column.isMenuVisible())};e.addManagedListeners(this.column,{menuVisibleChanged:t}),t()}setupSortableClass(e){let t=()=>{this.comp.toggleCss("ag-header-cell-sortable",!!this.sortable)};t(),this.setRefreshFunction("updateSortable",t),e.addManagedEventListeners({sortChanged:this.refreshAriaSort.bind(this)})}setupFilterClass(e){let t=()=>{let e=this.column.isFilterActive();this.comp.toggleCss("ag-header-cell-filtered",e),this.refreshAria()};e.addManagedListeners(this.column,{filterActiveChanged:t}),t()}setupWrapTextClass(){let e=()=>{let e=!!this.column.getColDef().wrapHeaderText;this.comp.toggleCss("ag-header-cell-wrap-text",e)};e(),this.setRefreshFunction("wrapText",e)}onHeaderHighlightChanged(){let e=this.column.getHighlighted();this.comp.toggleCss("ag-header-highlight-before",0===e),this.comp.toggleCss("ag-header-highlight-after",1===e)}onDisplayedColumnsChanged(){super.onDisplayedColumnsChanged(),this.isAlive()&&this.onHeaderHeightChanged()}onHeaderHeightChanged(){this.refreshSpanHeaderHeight()}refreshSpanHeaderHeight(){let{eGui:e,column:t,comp:n,beans:i}=this,r=u5(this.beans),o=0===r.reduce((e,t)=>e+t,0);if(n.toggleCss("ag-header-parent-hidden",o),!t.isSpanHeaderHeight()){e.style.removeProperty("top"),e.style.removeProperty("height"),n.toggleCss("ag-header-span-height",!1),n.toggleCss("ag-header-span-total",!1);return}let{numberOfParents:a,isSpanningTotal:s}=this.column.getColumnGroupPaddingInfo();n.toggleCss("ag-header-span-height",a>0);let l=u4(i);if(0===a){n.toggleCss("ag-header-span-total",!1),e.style.setProperty("top","0px"),e.style.setProperty("height",`${l}px`);return}n.toggleCss("ag-header-span-total",s);let d=(this.column.getFirstRealParent()?.getLevel()??-1)+1,u=r.length-d,c=0;for(let e=0;e<u;e++)c+=r[r.length-1-e];e.style.setProperty("top",`${-c}px`),e.style.setProperty("height",`${l+c}px`)}refreshAriaSort(){if(this.sortable){let e=this.getLocaleTextFunc(),t=this.beans.sortSvc?.getDisplaySortForColumn(this.column)||null;this.comp.setAriaSort("asc"===t?"ascending":"desc"===t?"descending":"mixed"===t?"other":"none"),this.setAriaDescriptionProperty("sort",e("ariaSortableColumn","Press ENTER to sort"))}else this.comp.setAriaSort(),this.setAriaDescriptionProperty("sort",null)}refreshAriaMenu(){if(this.menuEnabled){let e=this.getLocaleTextFunc();this.setAriaDescriptionProperty("menu",e("ariaMenuColumn","Press ALT DOWN to open column menu"))}else this.setAriaDescriptionProperty("menu",null)}refreshAriaFilterButton(){if(this.openFilterEnabled&&!aO(this.gos)){let e=this.getLocaleTextFunc();this.setAriaDescriptionProperty("filterButton",e("ariaFilterColumn","Press CTRL ENTER to open filter"))}else this.setAriaDescriptionProperty("filterButton",null)}refreshAriaFiltered(){let e=this.getLocaleTextFunc();this.column.isFilterActive()?this.setAriaDescriptionProperty("filter",e("ariaColumnFiltered","Column Filtered")):this.setAriaDescriptionProperty("filter",null)}setAriaDescriptionProperty(e,t){null!=t?this.ariaDescriptionProperties.set(e,t):this.ariaDescriptionProperties.delete(e)}announceAriaDescription(){if(!this.eGui.contains(rA(this.beans)))return;let e=Array.from(this.ariaDescriptionProperties.keys()).sort((e,t)=>
376"filter"===e?-1:t.charCodeAt(0)-e.charCodeAt(0)).map(e=>this.ariaDescriptionProperties.get(e)).join(". ");this.beans.ariaAnnounce?.announceValue(e,"columnHeader")}refreshAria(){this.refreshAriaSort(),this.refreshAriaMenu(),this.refreshAriaFilterButton(),this.refreshAriaFiltered()}addColumnHoverListener(e){this.beans.colHover?.addHeaderColumnHoverListener(e,this.comp,this.column)}addActiveHeaderMouseListeners(e){let t=e=>this.handleMouseOverChange("mouseenter"===e.type),n=()=>{this.setActiveHeader(!0),this.dispatchColumnMouseEvent("columnHeaderClicked",this.column)},i=e=>this.handleContextMenuMouseEvent(e,void 0,this.column);e.addManagedListeners(this.eGui,{mouseenter:t,mouseleave:t,click:n,contextmenu:i})}handleMouseOverChange(e){this.setActiveHeader(e),this.eventSvc.dispatchEvent({type:e?"columnHeaderMouseOver":"columnHeaderMouseLeave",column:this.column})}setActiveHeader(e){this.comp.toggleCss("ag-header-active",e)}getAnchorElementForMenu(e){let t=this.comp.getUserCompInstance();return co(t)?t.getAnchorElementForMenu(e):this.eGui}destroy(){this.tooltipFeature=this.destroyBean(this.tooltipFeature),super.destroy()}};function co(e){return"function"==typeof e?.getAnchorElementForMenu&&"function"==typeof e.onMenuKeyboardShortcut}var ca=0,cs=class extends oI{constructor(e,t,n){super(),this.rowIndex=e,this.pinned=t,this.type=n,this.instanceId=ca++,this.comp=null,this.allCtrls=[];let i="ag-header-row-column";"group"===n?i="ag-header-row-group":"filter"===n&&(i="ag-header-row-filter"),this.headerRowClass=`ag-header-row ${i}`}setRowIndex(e){this.rowIndex=e,this.comp?.setRowIndex(this.getAriaRowIndex()),this.onRowHeightChanged()}postConstruct(){this.isPrintLayout=al(this.gos,"print"),this.isEnsureDomOrder=this.gos.get("ensureDomOrder")}areCellsRendered(){return!!this.comp&&this.allCtrls.every(e=>null!=e.eGui)}setComp(e,t,n=!0){this.comp=e,t=sx(this,this.beans.context,t),n&&(this.setRowIndex(this.rowIndex),this.onVirtualColumnsChanged()),this.setWidth(),this.addEventListeners(t)}getAriaRowIndex(){return this.rowIndex+1}addEventListeners(e){let t=this.onRowHeightChanged.bind(this),n=this.onDisplayedColumnsChanged.bind(this);e.addManagedEventListeners({columnResized:this.setWidth.bind(this),displayedColumnsChanged:n,virtualColumnsChanged:e=>this.onVirtualColumnsChanged(e.afterScroll),columnGroupHeaderHeightChanged:t,columnHeaderHeightChanged:t,gridStylesChanged:t,advancedFilterEnabledChanged:t}),e.addManagedPropertyListener("domLayout",n),e.addManagedPropertyListener("ensureDomOrder",e=>this.isEnsureDomOrder=e.currentValue),e.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],t)}onDisplayedColumnsChanged(){this.isPrintLayout=al(this.gos,"print"),this.onVirtualColumnsChanged(),this.setWidth(),this.onRowHeightChanged()}setWidth(){if(!this.comp)return;let e=this.getWidthForRow();this.comp.setWidth(`${e}px`)}getWidthForRow(){let{visibleCols:e}=this.beans;return this.isPrintLayout?null!=this.pinned?0:e.getContainerWidth("right")+e.getContainerWidth("left")+e.getContainerWidth(null):e.getContainerWidth(this.pinned)}onRowHeightChanged(){if(!this.comp)return;let{topOffset:e,rowHeight:t}=this.getTopAndHeight();this.comp.setTop(e+"px"),this.comp.setHeight(t+"px")}getTopAndHeight(){let e=0,t=u5(this.beans);for(let n=0;n<t.length;n++){if(n===this.rowIndex&&"group"===this.type)return{topOffset:e,rowHeight:t[n]};e+=t[n]}let n=u4(this.beans);return"column"===this.type?{topOffset:e,rowHeight:n}:{topOffset:e+=n,rowHeight:u8(this.beans)}}onVirtualColumnsChanged(e=!1){if(!this.comp)return;let t=this.getUpdatedHeaderCtrls(),n=this.isEnsureDomOrder||this.isPrintLayout;this.comp.setHeaderCtrls(t,n,e)}getUpdatedHeaderCtrls(){let e=this.ctrlsById;for(let t of(this.ctrlsById=new Map,this.getColumnsInViewport()))this.recycleAndCreateHeaderCtrls(t,this.ctrlsById,e);let t=e=>{let{focusSvc:t,visibleCols:n}=this.beans;return!!t.isHeaderWrapperFocused(e)&&n.isVisible(e.column)};if(e)for(let[n,i]of e)t(i)?this.ctrlsById.set(n,i):this.destroyBean(i);return this.allCtrls=Array.from(this.ctrlsById.values()),this.allCtrls}getHeaderCellCtrls(){return this.allCtrls}
376recycleAndCreateHeaderCtrls(e,t,n){let i;if(e.isEmptyGroup())return;let r=e.getUniqueId();if(n&&(i=n.get(r),n.delete(r)),i&&i.column!=e&&(this.destroyBean(i),i=void 0),null==i)switch(this.type){case"filter":i=this.createBean(this.beans.registry.createDynamicBean("headerFilterCellCtrl",!0,e,this));break;case"group":i=this.createBean(this.beans.registry.createDynamicBean("headerGroupCellCtrl",!0,e,this));break;default:i=this.createBean(new cr(e,this))}t.set(r,i)}getColumnsInViewport(){if(!this.isPrintLayout)return this.getComponentsToRender();if(this.pinned)return[];let e=[];for(let t of["left",null,"right"])e.push(...this.getComponentsToRender(t));return e}getComponentsToRender(e=this.pinned){return"group"===this.type?this.beans.colViewport.getHeadersToRender(e,this.rowIndex):this.beans.colViewport.getColumnHeadersToRender(e)}focusHeader(e,t){let n=this.allCtrls.find(t=>t.column==e);return!!n&&n.focus(t)}destroy(){this.allCtrls=this.destroyBeans(this.allCtrls),this.ctrlsById=void 0,this.comp=null,super.destroy()}},cl=class extends oI{constructor(e){super(),this.pinned=e,this.hidden=!1,this.includeFloatingFilter=!1,this.groupsRowCtrls=[]}setComp(e,t){this.comp=e,this.eViewport=t;let{pinnedCols:n,ctrlsSvc:i,colModel:r,colMoves:o}=this.beans;this.setupCenterWidth(),n?.setupHeaderPinnedWidth(this),this.setupDragAndDrop(o,this.eViewport);let a=this.refresh.bind(this,!0);this.addManagedEventListeners({displayedColumnsChanged:a,advancedFilterEnabledChanged:a});let s=`${"string"==typeof this.pinned?this.pinned:"center"}Header`;i.register(s,this),r.ready&&this.refresh()}getAllCtrls(){let e=[...this.groupsRowCtrls];return this.columnsRowCtrl&&e.push(this.columnsRowCtrl),this.filtersRowCtrl&&e.push(this.filtersRowCtrl),e}refresh(e=!1){let{focusSvc:t,filterManager:n,visibleCols:i}=this.beans,r=0,o=t.getFocusHeaderToUseAfterRefresh(),a=()=>{let t=i.headerGroupRowCount;r=t,e||(this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls));let n=this.groupsRowCtrls.length;if(n!==t){if(n>t){for(let e=t;e<n;e++)this.destroyBean(this.groupsRowCtrls[e]);this.groupsRowCtrls.length=t;return}for(let e=n;e<t;e++){let t=this.createBean(new cs(e,this.pinned,"group"));this.groupsRowCtrls.push(t)}}},s=()=>{let t=r++;if(this.hidden){this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl);return}null!=this.columnsRowCtrl&&e?this.columnsRowCtrl.rowIndex!==t&&this.columnsRowCtrl.setRowIndex(t):(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl),this.columnsRowCtrl=this.createBean(new cs(t,this.pinned,"column")))},l=()=>{this.includeFloatingFilter=!!n?.hasFloatingFilters()&&!this.hidden;let t=()=>{this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)};if(!this.includeFloatingFilter)return void t();e||t();let i=r++;this.filtersRowCtrl?this.filtersRowCtrl.rowIndex!==i&&this.filtersRowCtrl.setRowIndex(i):this.filtersRowCtrl=this.createBean(new cs(i,this.pinned,"filter"))},d=this.getAllCtrls();a(),s(),l();let u=this.getAllCtrls();this.comp.setCtrls(u),this.restoreFocusOnHeader(t,o),d.length!==u.length&&this.beans.eventSvc.dispatchEvent({type:"headerRowsChanged"})}getHeaderCtrlForColumn(e){let t=t=>t?.getHeaderCellCtrls().find(t=>t.column===e);if(aH(e))return t(this.columnsRowCtrl);if(0!==this.groupsRowCtrls.length)for(let e=0;e<this.groupsRowCtrls.length;e++){let n=t(this.groupsRowCtrls[e]);if(n)return n}}getHtmlElementForColumnHeader(e){return this.getHeaderCtrlForColumn(e)?.eGui??null}getRowType(e){return this.getAllCtrls()[e]?.type}focusHeader(e,t,n){let i=this.getAllCtrls()[e];return!!i&&i.focusHeader(t,n)}getGroupRowCount(){return this.groupsRowCtrls.length}getGroupRowCtrlAtIndex(e){return this.groupsRowCtrls[e]}getRowCount(){return this.groupsRowCtrls.length+ +!!this.columnsRowCtrl+ +!!this.filtersRowCtrl}setHorizontalScroll(e){this.comp.setViewportScrollLeft(e)}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}destroy(){this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl),this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl),this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls),super.destroy()}setupDragAndDrop(e,t){let n=e?.createBodyDropTarget(this.pinned,t);n&&this.createManagedBean(n)}restoreFocusOnHeader(e,t){if(!t)return;let{column:n}=t;n.getPinned()==this.pinned&&e.focusHeaderPosition({headerPosition:t,scroll:!1})}setupCenterWidth(){null==this.pinned&&this.createManagedBean(new um(e=>this.comp.setCenterWidth(`${e}px`),!0))}},cd=class extends oI{constructor(){super(...arguments),this.beanName="menuSvc"}postConstruct(){let{enterpriseMenuFactory:e,filterMenuFactory:t}=this.beans;this.activeMenuFactory=e??t}showColumnMenu(e){this.showColumnMenuCommon(this.activeMenuFactory,e,"columnMenu")}showFilterMenu(e){this.showColumnMenuCommon(cc(this.beans),e,e.containerType,!0)}showHeaderContextMenu(e,t,n){this.activeMenuFactory?.showMenuAfterContextMenuEvent(e,t,n)}hidePopupMenu(){this.beans.contextMenuSvc?.hideActiveMenu(),this.activeMenuFactory?.hideActiveMenu()}hideFilterMenu(){cc(this.beans)?.hideActiveMenu()}isColumnMenuInHeaderEnabled(e){let{suppressHeaderMenuButton:t}=e.getColDef();return!t&&!!this.activeMenuFactory?.isMenuEnabled(e)&&(aO(this.gos)||!!this.beans.enterpriseMenuFactory)}isFilterMenuInHeaderEnabled(e){return!e.getColDef().suppressHeaderFilterButton&&!!this.beans.filterManager?.is
376FilterAllowed(e)}isHeaderContextMenuEnabled(e){let t=e&&aH(e)?e.getColDef():e?.getColGroupDef();return!t?.suppressHeaderContextMenu&&"new"===this.gos.get("columnMenu")}isHeaderMenuButtonAlwaysShowEnabled(){return this.isSuppressMenuHide()}isHeaderMenuButtonEnabled(){let e=!this.isSuppressMenuHide();return!(ls()&&e)}isHeaderFilterButtonEnabled(e){return this.isFilterMenuInHeaderEnabled(e)&&!aO(this.gos)&&!this.isFloatingFilterButtonDisplayed(e)}isFilterMenuItemEnabled(e){return!!this.beans.filterManager?.isFilterAllowed(e)&&!aO(this.gos)&&!this.isFilterMenuInHeaderEnabled(e)&&!this.isFloatingFilterButtonDisplayed(e)}isFloatingFilterButtonEnabled(e){return!e.getColDef().suppressFloatingFilterButton}isFloatingFilterButtonDisplayed(e){return!!e.getColDef().floatingFilter&&this.isFloatingFilterButtonEnabled(e)}isSuppressMenuHide(){let e=this.gos,t=e.get("suppressMenuHide");return aO(e)?!!e.exists("suppressMenuHide")&&t:t}showColumnMenuCommon(e,t,n,i){let{positionBy:r,onClosedCallback:o}=t,a=t.column;if("button"===r){let{buttonElement:r}=t;e?.showMenuAfterButtonClick(a,r,n,o,i)}else if("mouse"===r){let{mouseEvent:r}=t;e?.showMenuAfterMouseEvent(a,r,n,o,i)}else if(a){let t=this.beans,r=t.ctrlsSvc;r.getScrollFeature().ensureColumnVisible(a,"auto"),op(t,()=>{let t=r.getHeaderRowContainerCtrl(a.getPinned())?.getHeaderCtrlForColumn(a);t&&e?.showMenuAfterButtonClick(a,t.getAnchorElementForMenu(i),n,o,i)})}}};function cu(e,t,n){e.menuVisible!==t&&(e.menuVisible=t,e.dispatchColEvent("menuVisibleChanged",n))}function cc(e){let{enterpriseMenuFactory:t,filterMenuFactory:n,gos:i}=e;return t&&aO(i)?t:n}var ch=class extends sk{constructor(){super()}},cp={tag:"span",cls:"ag-overlay-loading-center"},cf=class extends ch{init(){let e=rw(this.gos.get("overlayLoadingTemplate")?.trim());if(this.setTemplate(e??cp),!e){let e=this.getLocaleTextFunc()("loadingOoo","Loading...");this.getGui().textContent=e,this.beans.ariaAnnounce.announceValue(e,"overlay")}}},cg={tag:"span",cls:"ag-overlay-no-rows-center"},cm=class extends ch{init(){let e=rw(this.gos.get("overlayNoRowsTemplate")?.trim());if(this.setTemplate(e??cg),!e){let e=this.getLocaleTextFunc()("noRowsToShow","No Rows To Show");this.getGui().textContent=e,this.beans.ariaAnnounce.announceValue(e,"overlay")}}};function cv(e,t,n){let i=null;"smallDown"===e?at(262):"smallLeft"===e?at(263):"smallRight"===e&&at(264);let r=n?.getColDef().icons;if(r&&(i=r[e]),t.gos&&!i){let n=t.gos.get("icons");n&&(i=n[e])}if(i){let t;if("function"==typeof i)t=i();else{if("string"!=typeof i)return void at(38,{iconName:e});t=i}return"string"==typeof t?ot(t):ou(t)?t:void at(133,{iconName:e})}{let n=t.registry.getIcon(e);return n||t.validation?.validateIcon(e),om({tag:"span",cls:`ag-icon ag-icon-${n??e}`,role:"presentation",attrs:{unselectable:"on"}})}}var cy={tag:"div",children:[{tag:"div",ref:"eGhost",cls:"ag-dnd-ghost ag-unselectable",children:[{tag:"span",ref:"eIcon",cls:"ag-dnd-ghost-icon ag-shake-left-to-right"},{tag:"div",ref:"eLabel",cls:"ag-dnd-ghost-label"}]}]},cb=class extends sk{constructor(){super(),this.dragSource=null,this.eIcon=null,this.eLabel=null,this.eGhost=null,this.registerCSS(".ag-dnd-ghost{align-items:center;background-color:var(--ag-drag-and-drop-image-background-color);border:var(--ag-drag-and-drop-image-border);border-radius:var(--ag-border-radius);box-shadow:var(--ag-drag-and-drop-image-shadow);color:var(--ag-text-color);cursor:move;display:flex;font-weight:500;gap:var(--ag-cell-widget-spacing);height:var(--ag-header-height);overflow:hidden;padding-left:var(--ag-cell-horizontal-padding);padding-right:var(--ag-cell-horizontal-padding);text-overflow:ellipsis;transform:translateY(calc(var(--ag-spacing)*2));white-space:nowrap}.ag-dnd-ghost-not-allowed{border:var(--ag-drag-and-drop-image-not-allowed-border)}")}postConstruct(){let e=e=>(function(e,t,n){let i=cv(e,t,null);if(i){let{className:e}=i;if("string"==typeof e&&e.includes("ag-icon")||"object"==typeof e&&e["ag-icon"])return i}let r=om({tag:"span"});return r.appendChild(i),r})(e,this.beans,0);this.dropIconMap={pinned:e("columnMovePin"),hide:e("columnMoveHide"),move:e("columnMoveMove"),left:e("columnMoveLeft"),right:e("columnMoveRight"),group:e("columnMoveGroup"),aggregate:e("columnMoveValue"),pivot:e("columnMovePivot"),notAllowed:e("dropNotAllowed")}}init(e){this.dragSource=e.dragSource,this.setTemplate(cy),this.beans.environment.applyThemeClasses(this.eGhost)}destroy(){this.dragSource=null,super.destroy()}setIcon(e,t){let{eGhost:n,eIcon:i,dragSource:r,dropIconMap:o,gos:a}=this;r8(i);let s=null;e||(e=r?.getDefaultIconName?r.getDefaultIconName():"notAllowed"),s=o[e],n.classList.toggle("ag-dnd-ghost-not-allowed","
376notAllowed"===e),i.classList.toggle("ag-shake-left-to-right",t),!(s===o.hide&&a.get("suppressDragLeaveHidesColumns"))&&s&&i.appendChild(s)}setLabel(e){this.eLabel.textContent=e}},cx={tag:"div",cls:"ag-cell-wrapper ag-checkbox-cell",role:"presentation",children:[{tag:"ag-checkbox",ref:"eCheckbox",role:"presentation"}]},cw=class extends sk{constructor(){super(cx,[lA]),this.eCheckbox=null,this.registerCSS(".ag-checkbox-cell{height:100%}")}init(e){this.refresh(e);let{eCheckbox:t,beans:n}=this,i=t.getInputElement();i.setAttribute("tabindex","-1"),rO(i,"live","polite"),this.addManagedListeners(i,{click:e=>{if(uo(e),t.isDisabled())return;let n=t.getValue();this.onCheckboxChanged(n)},dblclick:e=>{uo(e)}}),this.addManagedElementListeners(e.eGridCell,{keydown:i=>{if(" "===i.key&&!t.isDisabled()){e.eGridCell===rA(n)&&t.toggle();let r=t.getValue();this.onCheckboxChanged(r),i.preventDefault()}}})}refresh(e){return this.params=e,this.updateCheckbox(e),!0}updateCheckbox(e){let t,n=!0,{value:i,column:r,node:o}=e;if(o.group&&r)if("boolean"==typeof i)t=i;else{let e=r.getColId();e.startsWith(a0)?t=null==i||""===i?void 0:"true"===i:o.aggData&&void 0!==o.aggData[e]||o.sourceRowIndex>=0?t=i??void 0:n=!1}else t=i??void 0;let{eCheckbox:a}=this;if(!n)return void a.setDisplayed(!1);a.setValue(t);let s=e.disabled??!r?.isCellEditable(o);a.setDisabled(s);let l=this.getLocaleTextFunc(),d=rq(l,t),u=s?d:`${l("ariaToggleCellValue","Press SPACE to toggle cell value")} (${d})`;a.setInputAriaLabel(u)}onCheckboxChanged(e){let{params:t}=this,{column:n,node:i,value:r}=t;this.beans?.editSvc?.setEditingCells([{column:n,colId:n.getColId(),rowIndex:i.rowIndex,rowPinned:i.rowPinned,state:"changed",oldValue:r,newValue:r}],{update:!0,forceRefreshOfEditCellsOnly:!0});let o=i.setDataValue(n,e,"renderer");this.beans.editSvc?.stopEditing({rowNode:i,column:n},{source:this.beans.editSvc?.isBatchEditing()?"ui":"api"}),o||this.updateCheckbox(t)}},cC=((h=cC||{}).Applied="Applied",h.StoreNotFound="StoreNotFound",h.StoreLoading="StoreLoading",h.StoreWaitingToLoad="StoreWaitingToLoad",h.StoreLoadingFailed="StoreLoadingFailed",h.StoreWrongType="StoreWrongType",h.Cancelled="Cancelled",h.StoreNotStarted="StoreNotStarted",h);function cS(e){return!!(e.rowPinned&&e.pinnedSibling)}function c_(e,t,n,i){let r="top"===t;if(!n)return c_(e,t,r?e.getPinnedTopRow(0):e.getPinnedBottomRow(0),i);if(!i){let i=r?e.getPinnedTopRowCount():e.getPinnedBottomRowCount();return c_(e,t,n,r?e.getPinnedTopRow(i-1):e.getPinnedBottomRow(i-1))}let o=!1,a=!1,s=[];return e.forEachPinnedRow(t,e=>{if(e===n&&!o){o=!0,s.push(e);return}if(o&&e===i){a=!0,s.push(e);return}o&&!a&&s.push(e)}),s}var ck={tag:"div",cls:"ag-selection-checkbox",role:"presentation",children:[{tag:"ag-checkbox",ref:"eCheckbox",role:"presentation"}]},cM=class extends sk{constructor(){super(ck,[lA]),this.eCheckbox=null}postConstruct(){this.eCheckbox.setPassive(!0)}onDataChanged(){this.onSelectionChanged()}onSelectableChanged(){this.showOrHideSelect()}onSelectionChanged(){let e=this.getLocaleTextFunc(),{rowNode:t,eCheckbox:n}=this,i=t.isSelected(),r=rq(e,i),[o,a]=t.selectable?["ariaRowToggleSelection","Press Space to toggle row selection"]:["ariaRowSelectionDisabled","Row Selection is disabled for this row"],s=e(o,a);n.setValue(i,!0),n.setInputAriaLabel(`${s} (${r})`)}init(e){if(this.rowNode=e.rowNode,this.column=e.column,this.overrides=e.overrides,this.onSelectionChanged(),this.addManagedListeners(this.eCheckbox.getInputElement(),{dblclick:uo,click:e=>{uo(e),this.beans.selectionSvc?.handleSelectionEvent(e,this.rowNode,"checkboxSelected")}}),this.addManagedListeners(this.rowNode,{rowSelected:this.onSelectionChanged.bind(this),dataChanged:this.onDataChanged.bind(this),selectableChanged:this.onSelectableChanged.bind(this)}),this.addManagedPropertyListener("rowSelection",({currentValue:e,previousValue:t})=>{("object"==typeof e?aM(e):void 0)!==("object"==typeof t?aM(t):void 0)&&this.onSelectableChanged()}),aR(this.gos)||"function"==typeof this.getIsVisible()){let e=this.showOrHideSelect.bind(this);this.addManagedEventListeners({displayedColumnsChanged:e}),this.addManagedListeners(this.rowNode,{dataChanged:e,cellChanged:e}),this.showOrHideSelect()}this.eCheckbox.getInputElement().setAttribute("tabindex","-1")}showOrHideSelect(){let e,{column:t,rowNode:n,overrides:i,gos:r}=this,o=n.selectable,a=this.getIsVisible();if("function"==typeof a){let r=i?.callbackParams;if(t){let i=t.createColumnFunctionCallbackParams(n);e=a({...r,...i})}else e=a({...r,node:n,data:n.data})}else e=a??!1;
376let s=o&&!e||!o&&e,l=o||e,d=r.get("rowSelection"),u=d&&"string"!=typeof d?!aM(d):!!t?.getColDef().showDisabledCheckboxes;this.setVisible(l&&(!s||u)),this.setDisplayed(l&&(!s||u)),l&&this.eCheckbox.setDisabled(s),i?.removeHidden&&this.setDisplayed(l)}getIsVisible(){let e=this.overrides;if(e)return e.isVisible;let t=this.gos.get("rowSelection");return t&&"string"!=typeof t?aS(t):this.column?.getColDef()?.checkboxSelection}},cT=class{constructor(e,t){this.rowModel=e,this.pinnedRowModel=t,this.selectAll=!1,this.rootId=null,this.endId=null,this.cachedRange=[]}reset(){this.rootId=null,this.endId=null,this.cachedRange.length=0}setRoot(e){this.rootId=e.id,this.endId=null,this.cachedRange.length=0}setEndRange(e){this.endId=e.id,this.cachedRange.length=0}getRange(){if(0===this.cachedRange.length){let e=this.getRoot(),t=this.getEnd();if(null==e||null==t)return this.cachedRange;this.cachedRange=this.getNodesInRange(e,t)??[]}return this.cachedRange}isInRange(e){return null!==this.rootId&&this.getRange().some(t=>t.id===e.id)}getRoot(e){return this.rootId?this.getRowNode(this.rootId):e?(this.setRoot(e),e):void 0}getEnd(){if(this.endId)return this.getRowNode(this.endId)}getRowNode(e){let t,{rowModel:n,pinnedRowModel:i}=this;return t??(t=n.getRowNode(e)),i?.isManual()&&(t??(t=i.getPinnedRowById(e,"top")),t??(t=i.getPinnedRowById(e,"bottom"))),t}truncate(e){let t=this.getRange();if(0===t.length)return{keep:[],discard:[]};let n=t[0].id===this.rootId,i=t.findIndex(t=>t.id===e.id);if(!(i>-1))return{keep:t,discard:[]};{let r=t.slice(0,i),o=t.slice(i+1);return this.setEndRange(e),n?{keep:r,discard:o}:{keep:o,discard:r}}}extend(e,t=!1){let n=this.getRoot();if(null==n){let n=this.getRange().slice();return t&&e.depthFirstSearch(e=>!e.group&&n.push(e)),n.push(e),this.setRoot(e),{keep:n,discard:[]}}let i=this.getNodesInRange(n,e);if(!i)return this.setRoot(e),{keep:[e],discard:[]};if(i.find(e=>e.id===this.endId))return this.setEndRange(e),{keep:this.getRange(),discard:[]};{let t=this.getRange().slice();return this.setEndRange(e),{keep:this.getRange(),discard:t}}}getNodesInRange(e,t){let{pinnedRowModel:n,rowModel:i}=this;if(!n?.isManual())return i.getNodesInRangeForSelection(e,t);if("top"===e.rowPinned&&!t.rowPinned)return c_(n,"top",e,void 0).concat(i.getNodesInRangeForSelection(i.getRow(0),t)??[]);if("bottom"===e.rowPinned&&!t.rowPinned){let r=c_(n,"bottom",void 0,e),o=i.getRowCount(),a=i.getRow(o-1);return(i.getNodesInRangeForSelection(t,a)??[]).concat(r)}if(!e.rowPinned&&!t.rowPinned)return i.getNodesInRangeForSelection(e,t);if("top"===e.rowPinned&&"top"===t.rowPinned)return c_(n,"top",e,t);if("bottom"===e.rowPinned&&"top"===t.rowPinned){let r=c_(n,"top",t,void 0),o=c_(n,"bottom",void 0,e),a=i.getRow(0),s=i.getRow(i.getRowCount()-1);return r.concat(i.getNodesInRangeForSelection(a,s)??[]).concat(o)}if(!e.rowPinned&&"top"===t.rowPinned)return c_(n,"top",t,void 0).concat(i.getNodesInRangeForSelection(i.getRow(0),e)??[]);if("top"===e.rowPinned&&"bottom"===t.rowPinned){let r=c_(n,"top",e,void 0),o=c_(n,"bottom",void 0,t),a=i.getRow(0),s=i.getRow(i.getRowCount()-1);return r.concat(i.getNodesInRangeForSelection(a,s)??[]).concat(o)}if("bottom"===e.rowPinned&&"bottom"===t.rowPinned)return c_(n,"bottom",e,t);if(!e.rowPinned&&"bottom"===t.rowPinned){let r=c_(n,"bottom",void 0,t),o=i.getRow(i.getRowCount());return(i.getNodesInRangeForSelection(e,o)??[]).concat(r)}return null}},cD=class extends oI{constructor(e){super(),this.column=e,this.cbSelectAllVisible=!1,this.processingEventFromCheckbox=!1}onSpaceKeyDown(e){let t=this.cbSelectAll;t.isDisplayed()&&!t.getGui().contains(rA(this.beans))&&(e.preventDefault(),t.setValue(!t.getValue()))}getCheckboxGui(){return this.cbSelectAll.getGui()}setComp(e){this.headerCellCtrl=e;let t=this.createManagedBean(new lI);this.cbSelectAll=t,t.addCss("ag-header-select-all"),rz(t.getGui(),"presentation"),this.showOrHideSelectAll();let n=this.updateStateOfCheckbox.bind(this);this.addManagedEventListeners({newColumnsLoaded:()=>this.showOrHideSelectAll(),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),selectionChanged:n,paginationChanged:n,modelUpdated:n}),this.addManagedPropertyListener("rowSelection",({currentValue:e,previousValue:t})=>{let n=e=>"string"!=typeof e&&e&&"singleRow"!==e.mode?e.selectAll:void 0;n(e)!==n(t)&&this.showOrHideSelectAll(),this.updateStateOfCheckbox()}),this.addManagedListeners(t,{fieldValueChanged:this.onCbSelectAll.bind(this)}),t.getInputElement().setAttribute("tabindex","-1"),this.refreshSelectAllLabel()}onDisplayedColumnsChanged(e){this.isAlive()&&this.showOrHideSelectAll("uiColumnMoved"===e.source)}showOrHideSelectAll(e=!1){let t=this.isCheckboxSelection();this.cbSelectAllVisible=t,this.cbSelectAll.setDisplayed(t),t&&(this.checkRightRowModelType("selectAllCheckbox"),this.checkSelectionType("selectAllCheckbox"),this.updateStateOfCheckbox()),this.refreshSelectAllLabel(e)}updateStateOfCheckbox(){if(!this.cbSelectAllVisible||this.processingEventFromCheckbox)return;this.processingEventFromCheckbox=!0;let e=this.getSelectAllMode(),t=this.beans.selectionSvc,n=this.cbSelectAll,i=t.getSelectAllState(e);n.setValue(i);let r=t.hasNodesToSelect(e);n.setDisabled(!r),this.refreshSelectAllLabel(),this.processingEventFromCheckbox=!1}refreshSelectAllLabel(e=!1){let t=this.getLocaleTextFunc(),{headerCellCtrl:n,cbSelectAll:i,cbSelectAllVisible:r}=this,o=rq(t,i.getValue()),a=t("ariaRowSelectAll","Press Space to toggle all rows selection");n.setAriaDescriptionProperty("selectAll",r?`${a} (${o})`:null),i.setInputAriaLabel(t("ariaHeaderSelection","Column with Header Selection")),e||n.announceAriaDescription()}checkSelectionType(e){return!!aA(this.gos)||(at(128,{feature:e}),!1)}checkRightRowModelType(e){let{gos:t,rowModel:n}=this.beans;return!!(aa(t)||as(t))||(at(129,{feature:e,rowModel:n.getType()}),!1)}onCbSelectAll(){if(this.processingEventFromCheckbox||!this.cbSelectAllVisible)return;let e=this.cbSelectAll.getValue(),t=this.getSelectAllMode(),n="uiSelectAll";"currentPage"===t?n="uiSelectAllCurrentPage":"filtered"===t&&(n="uiSelectAllFiltered");let i={source:n,selectAll:t},r=this.beans.selectionSvc;e?r.selectAllRowNodes(i):r.deselectAllRowNodes(i)}isCheckboxSelection(){let{column:e,gos:t,beans:n}=this,i="object"==typeof t.get("rowSelection")?"headerCheckbox":"headerCheckboxSelection";return cR(n,e)&&this.checkRightRowModelType(i)&&this.checkSelectionType(i)}getSelectAllMode(){let e=aE(this.gos,!1);if(e)return e;let{headerCheckboxSelectionCurrentPageOnly:t,headerCheckboxSelectionFilteredOnly:n}=this.column.getColDef();return t?"currentPage":n?"filtered":"all"}destroy(){super.destroy(),this.cbSelectAll=void 0,this.headerCellCtrl=void 0}};function cR({gos:e,selectionColSvc:t},n){let i=e.get("rowSelection"),r=n.getColDef(),{headerCheckboxSelection:o}=r,a=!1;if("object"==typeof i){let e=a8(n),r=a6(n);("autoGroupColumn"===ak(i)&&r||e&&t?.isSelectionColumnEnabled())&&(a=a_(i))}else a="function"==typeof o?o(aN(e,{column:n,colDef:r})):!!o;return a}var cI=class extends oI{postConstruct(){let{gos:e,beans:t}=this;this.selectionCtx=new cT(t.rowModel,t.pinnedRowModel),this.addManagedPropertyListeners(["isRowSelectable","rowSelection"],()=>{let t=aR(e);t!==this.isRowSelectable&&(this.isRowSelectable=t,this.updateSelectable())}),this.isRowSelectable=aR(e),this.addManagedEventListeners({cellValueChanged:e=>this.updateRowSelectable(e.node),rowNodeDataChanged:e=>this.updateRowSelectable(e.node)})}destroy(){super.destroy(),this.selectionCtx.reset()}createCheckboxSelectionComponent(){return new cM}
376createSelectAllFeature(e){if(cR(this.beans,e))return new cD(e)}isMultiSelect(){return aA(this.gos)}onRowCtrlSelected(e,t,n){let i=!!e.rowNode.isSelected();e.forEachGui(n,e=>{e.rowComp.toggleCss("ag-row-selected",i);let n=e.element;rU(n,i),n.contains(rA(this.beans))&&t(e)})}announceAriaRowSelection(e){if(this.isRowSelectionBlocked(e))return;let t=e.isSelected(),n=this.beans.editSvc?.isEditing({rowNode:e});if(!e.selectable||n)return;let i=this.getLocaleTextFunc()(t?"ariaRowDeselect":"ariaRowSelect",`Press SPACE to ${t?"deselect":"select"} this row`);this.beans.ariaAnnounce?.announceValue(i,"rowSelection")}isRowSelectionBlocked(e){return!e.selectable||e.rowPinned&&!cS(e)||!ad(this.gos)}updateRowSelectable(e,t){let n=e.rowPinned&&e.pinnedSibling?e.pinnedSibling.selectable:this.isRowSelectable?.(e)??!0;return this.setRowSelectable(e,n,t),n}setRowSelectable(e,t,n){if(e.selectable!==t&&(e.selectable=t,e.dispatchRowEvent("selectableChanged"),!n)){if(aL(this.gos)){let t=this.calculateSelectedFromChildren(e);this.setNodesSelected({nodes:[e],newValue:t??!1,source:"selectableChanged"});return}e.isSelected()&&!e.selectable&&this.setNodesSelected({nodes:[e],newValue:!1,source:"selectableChanged"})}}calculateSelectedFromChildren(e){let t=!1,n=!1;if(!e.childrenAfterGroup?.length)return e.selectable?e.__selected:null;for(let i=0;i<e.childrenAfterGroup.length;i++){let r=e.childrenAfterGroup[i],o=r.isSelected();if(!r.selectable){let e=this.calculateSelectedFromChildren(r);if(null===e)continue;o=e}switch(o){case!0:t=!0;break;case!1:n=!0;break;default:return}}if(!t||!n)return!!t||!n&&(e.selectable?e.__selected:null)}selectRowNode(e,t,n,i="api"){let r=!e.selectable&&t,o=e.__selected===t;if(r||o)return!1;e.__selected=t,e.dispatchRowEvent("rowSelected");let a=e.sibling;a&&a.footer&&a.__localEventService&&a.dispatchRowEvent("rowSelected");let s=e.pinnedSibling;return s?.rowPinned&&s.__localEventService&&s.dispatchRowEvent("rowSelected"),this.eventSvc.dispatchEvent({...aN(this.gos,{type:"rowSelected",node:e,data:e.data,rowIndex:e.rowIndex,rowPinned:e.rowPinned}),event:n||null,source:i}),!0}isCellCheckboxSelection(e,t){let n=this.gos.get("rowSelection");if(!n||"string"==typeof n)return e.isColumnFunc(t,e.colDef.checkboxSelection);{let i=a8(e)&&aS(n);return e.isColumnFunc(t,i)}}inferNodeSelections(e,t,n,i){let r,o,{gos:a,selectionCtx:s}=this,l=e.isSelected(),d=aL(a),u=!0===(r=aD(a))||"enableSelection"===r,c=!0===(o=aD(a))||"enableDeselection"===o,h=this.isMultiSelect(),p="rowClicked"===i;if(p&&!(u||c))return null;if(t&&n&&h){let t=s.getRoot();if(!t)return null;if(!t.isSelected())return{select:[],deselect:s.extend(e,d).keep,reset:!1};{let t=s.isInRange(e)?s.truncate(e):s.extend(e,d);return{deselect:t.discard,select:t.keep,reset:!1}}}if(t&&h){let t=s.selectAll?this.beans.rowModel.getRow(0):void 0,n=s.getRoot(t),i=s.isInRange(e)?s.truncate(e):s.extend(e,d);return{select:i.keep,deselect:i.discard,reset:s.selectAll||!!(n&&!n.isSelected())}}if(n){if(p){let t=!l;return(!t||u)&&(t||c)?(s.setRoot(e),{node:e,newValue:t,clearSelection:!1}):null}return s.setRoot(e),{node:e,newValue:!l,clearSelection:!h}}{let t;s.setRoot(e);let n="string"==typeof(t=a.get("rowSelection"))?a.get("rowMultiSelectWithClick"):t?.enableSelectionWithoutKeys??!1,i="filteredDescendants"===aP(a),r=p&&(!n||!u);if(i&&void 0===l&&aa(a))return{node:e,newValue:!1,checkFilteredNodes:!0,clearSelection:!h||r};if(p){let t=l?!n:u;return(t!==l||r)&&(!t||u)&&(t||c)?{node:e,newValue:t,clearSelection:!h||r,keepDescendants:e.group&&d}:null}return{node:e,newValue:!l,clearSelection:!h||r}}}},cA="ag-tab-guard",cP="ag-tab-guard-top",cE="ag-tab-guard-bottom",cL=class extends oI{constructor(e){super(),this.skipTabGuardFocus=!1,this.forcingFocusOut=!1,this.allowFocus=!1;const{comp:t,eTopGuard:n,eBottomGuard:i,focusTrapActive:r,forceFocusOutWhenTabGuardsAreEmpty:o,isFocusableContainer:a,focusInnerElement:s,onFocusIn:l,onFocusOut:d,shouldStopEventPropagation:u,onTabKeyDown:c,handleKeyDown:h,isEmpty:p,eFocusableElement:f}=e;this.comp=t,this.eTopGuard=n,this.eBottomGuard=i,this.providedFocusInnerElement=s,this.eFocusableElement=f,this.focusTrapActive=!!r,this.forceFocusOutWhenTabGuardsAreEmpty=!!o,this.isFocusableContainer=!!a,this.providedFocusIn=l,this.providedFocusOut=d,this.providedShouldStopEventPropagation=u,this.providedOnTabKeyDown=c,this.providedHandleKeyDown=h,this.providedIsEmpty=p}postConstruct(){for(let e of(this.createManagedBean(new us(this.eFocusableElement,{shouldStopEventPropagation:()=>this.shouldStopEventPropagation(),onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e),onFocusIn:e=>this.onFocusIn(e),onFocusOut:e=>this.onFocusOut(e)})),this.activateTabGuards(),[this.eTopGuard,this.eBottomGuard]))this.addManagedElementListeners(e,{focus:this.onFocus.bind(this)})}handleKeyDown(e){this.providedHandleKeyDown&&this.providedHandleKeyDown(e)}tabGuardsAreActive(){return!!this.eTopGuard&&this.eTopGuard.hasAttribute("tabIndex")}shouldStopEventPropagation(){return!!this.providedShouldStopEventPropagation&&this.providedShouldStopEventPropagation()}activateTabGuards(){if(this.forcingFocusOut)return;let e=this.gos.get("tabIndex");this.comp.setTabIndex(e.toString())}deactivateTabGuards(){this.comp.setTabIndex()}onFocus(e){if(this.isFocusableContainer&&!this.eFocusableElement.contains(e.relatedTarget)&&!this.allowFocus)return void this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);if(this.skipTabGuardFocus){this.skipTabGuardFocus=!1;return}if(this.forceFocusOutWhenTabGuardsAreEmpty&&(this.providedIsEmpty?this.providedIsEmpty():0===lS(this.eFocusableElement,".ag-tab-guard").length))return void this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);if(this.isFocusableContainer&&this.eFocusableElement.contains(e.relatedTarget))return;let t=e.target===this.eBottomGuard;(this.providedFocusInnerElement?this.providedFocusInnerElement(t):this.focusInnerElement(t))||!this.forceFocusOutWhenTabGuardsAreEmpty||this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard)}findNextElementOutsideAndFocus(e){let t,n,i=lS(rP(this.beans).body,null,!0),r=i.indexOf(e?this.eTopGuard:this.eBottomGuard);if(-1===r)return;e?(t=0,n=r):(t=r+1,n=i.length);let o=i.slice(t,n),a=this.gos.get("tabIndex");o.sort((e,t)=>
376{let n=Number.parseInt(e.getAttribute("tabindex")||"0"),i=Number.parseInt(t.getAttribute("tabindex")||"0");return i===a?1:n===a?-1:0===n?1:0===i?-1:n-i}),o[e?o.length-1:0]?.focus()}onFocusIn(e){this.focusTrapActive||this.forcingFocusOut||(this.providedFocusIn&&this.providedFocusIn(e),this.isFocusableContainer||this.deactivateTabGuards())}onFocusOut(e){!this.focusTrapActive&&(this.providedFocusOut&&this.providedFocusOut(e),this.eFocusableElement.contains(e.relatedTarget)||this.activateTabGuards())}onTabKeyDown(e){if(this.providedOnTabKeyDown)return void this.providedOnTabKeyDown(e);if(this.focusTrapActive||e.defaultPrevented)return;let t=this.tabGuardsAreActive();t&&this.deactivateTabGuards();let n=this.getNextFocusableElement(e.shiftKey);t&&setTimeout(()=>this.activateTabGuards(),0),n&&(n.focus(),e.preventDefault())}focusInnerElement(e=!1){let t=lS(this.eFocusableElement);return this.tabGuardsAreActive()&&(t.splice(0,1),t.splice(t.length-1,1)),!!t.length&&(t[e?t.length-1:0].focus({preventScroll:!0}),!0)}getNextFocusableElement(e){return lk(this.beans,this.eFocusableElement,!1,e)}forceFocusOutOfContainer(e=!1){if(this.forcingFocusOut)return;let t=e?this.eTopGuard:this.eBottomGuard;this.activateTabGuards(),this.skipTabGuardFocus=!0,this.forcingFocusOut=!0,t.focus(),window.setTimeout(()=>{this.forcingFocusOut=!1,this.activateTabGuards()})}isTabGuard(e,t){return e===this.eTopGuard&&!t||e===this.eBottomGuard&&(t??!0)}setAllowFocus(e){this.allowFocus=e}},cF=class extends oI{constructor(e){super(),this.comp=e}initialiseTabGuard(e){this.eTopGuard=this.createTabGuard("top"),this.eBottomGuard=this.createTabGuard("bottom"),this.eFocusableElement=this.comp.getFocusableElement();let{eTopGuard:t,eBottomGuard:n,eFocusableElement:i}=this,r=[t,n];this.addTabGuards(t,n);let{focusTrapActive:o=!1,onFocusIn:a,onFocusOut:s,focusInnerElement:l,handleKeyDown:d,onTabKeyDown:u,shouldStopEventPropagation:c,isEmpty:h,forceFocusOutWhenTabGuardsAreEmpty:p,isFocusableContainer:f}=e;this.tabGuardCtrl=this.createManagedBean(new cL({comp:{setTabIndex:e=>{for(let t of r)null!=e?t.setAttribute("tabindex",e):t.removeAttribute("tabindex")}},focusTrapActive:o,eTopGuard:t,eBottomGuard:n,eFocusableElement:i,onFocusIn:a,onFocusOut:s,focusInnerElement:l,handleKeyDown:d,onTabKeyDown:u,shouldStopEventPropagation:c,isEmpty:h,forceFocusOutWhenTabGuardsAreEmpty:p,isFocusableContainer:f}))}getTabGuardCtrl(){return this.tabGuardCtrl}createTabGuard(e){let t=rP(this.beans).createElement("div");return t.classList.add(cA,"top"===e?cP:cE),rz(t,"presentation"),t}addTabGuards(e,t){let n=this.eFocusableElement;n.insertAdjacentElement("afterbegin",e),n.insertAdjacentElement("beforeend",t)}removeAllChildrenExceptTabGuards(){let e=[this.eTopGuard,this.eBottomGuard];r8(this.comp.getFocusableElement()),this.addTabGuards(...e)}forceFocusOutOfContainer(e=!1){this.tabGuardCtrl.forceFocusOutOfContainer(e)}appendChild(e,t,n){ou(t)||(t=t.getGui());let{eBottomGuard:i}=this;i?i.insertAdjacentElement("beforebegin",t):e(t,n)}destroy(){let{eTopGuard:e,eBottomGuard:t}=this;r7(e),r7(t),super.destroy()}},cO=class extends sk{initialiseTabGuard(e){this.tabGuardFeature=this.createManagedBean(new cF(this)),this.tabGuardFeature.initialiseTabGuard(e)}forceFocusOutOfContainer(e=!1){this.tabGuardFeature.forceFocusOutOfContainer(e)}appendChild(e,t){this.tabGuardFeature.appendChild(super.appendChild.bind(this),e,t)}},cN=class{constructor(e,t=!1){this.eElement=e,this.preventClick=t,this.startListener=null,this.handlers=[],this.eventSvc=void 0,this.touchStart=null,this.lastTapTime=null,this.longPressTimer=0,this.moved=!1}addEventListener(e,t){let n=this.eventSvc;if(!n){if(null===n)return;this.eventSvc=n=new rx;let e=this.onTouchStart.bind(this);this.startListener=e,this.eElement.addEventListener("touchstart",e,{passive:!0})}n.addEventListener(e,t)}removeEventListener(e,t){this.eventSvc?.removeEventListener(e,t)}onTouchStart(e){if(this.touchStart||!(e=>{if(D){if(D.has(e))return!1}else D=new WeakSet;return D.add(e),!0})(e))return;let t=e.touches[0];this.touchStart=t;let n=this.handlers;if(!n.length){let e=this.eElement,t=e.ownerDocument,i=this.onTouchMove.bind(this),r=this.onTouchEnd.bind(this),o=this.onTouchCancel.bind(this),a={passive:!0},s={passive:!1};o_(n,[e,"touchmove",i,a],[t,"touchcancel",o,a],[t,"touchend",r,s],[t,"contextmenu",oM,s])}this.clearLongPress(),this.longPressTimer=window.setTimeout(()=>{this.longPressTimer=0,this.touchStart!==t||this.moved||(this.moved=!0,this.eventSvc?.dispatchEvent({type:"longTap",touchStart:t,touchEvent:e}))},550)}onTouchMove(e){let{moved:t,touchStart:n}=this;
376if(!t&&n){let t=oC(n,e.touches);t&&!ow(t,n,4)&&(this.clearLongPress(),this.moved=!0)}}onTouchEnd(e){let t=this.touchStart;t&&oC(t,e.changedTouches)&&(this.moved||(this.eventSvc?.dispatchEvent({type:"tap",touchStart:t}),this.checkDoubleTap(t)),this.preventClick&&oM(e),this.cancel())}onTouchCancel(e){let t=this.touchStart;t&&oC(t,e.changedTouches)&&(this.lastTapTime=null,this.cancel())}checkDoubleTap(e){let t=Date.now(),n=this.lastTapTime;n&&t-n>500&&(this.eventSvc?.dispatchEvent({type:"doubleTap",touchStart:e}),t=null),this.lastTapTime=t}cancel(){this.clearLongPress(),ok(this.handlers),this.touchStart=null}clearLongPress(){window.clearTimeout(this.longPressTimer),this.longPressTimer=0,this.moved=!1}destroy(){let e=this.startListener;e&&(this.startListener=null,this.eElement.removeEventListener("touchstart",e)),this.cancel(),this.eElement=null,this.eventSvc=null}},cB=((p=cB||{})[p.VALUE=0]="VALUE",p[p.DIMENSION=1]="DIMENSION",p),cz=class{constructor(e="javascript"){this.frameworkName=e,this.renderingEngine="vanilla",this.batchFrameworkComps=!1,this.wrapIncoming=e=>e(),this.wrapOutgoing=e=>e(),this.baseDocLink=`${oW}/${this.frameworkName}-data-grid`,function(e){o5=e}(this.baseDocLink)}frameworkComponent(e){return null}isFrameworkComponent(e){return!1}getDocLink(e){return this.baseDocLink+(e?"/"+e:"")}};function cj(e){return{beanName:"gridApi",bean:e.getBean("apiFunctionSvc").api}}var cV=Object.fromEntries(["licenseManager","environment","eventSvc","gos","paginationAutoPageSizeSvc","apiFunctionSvc","gridApi","registry","agCompUtils","userCompFactory","rowContainerHeight","horizontalResizeSvc","localeSvc","pinnedRowModel","dragSvc","colGroupSvc","visibleCols","popupSvc","selectionSvc","colFilter","quickFilter","filterManager","colModel","headerNavigation","pageBounds","pagination","pageBoundsListener","rowSpanSvc","stickyRowSvc","rowRenderer","expressionSvc","alignedGridsSvc","navigation","valueCache","valueSvc","autoWidthCalc","filterMenuFactory","dragAndDrop","focusSvc","cellNavigation","cellStyles","scrollVisibleSvc","sortSvc","colHover","colAnimation","autoColSvc","selectionColSvc","changeDetectionSvc","animationFrameSvc","undoRedo","colDefFactory","rowStyleSvc","rowNodeBlockLoader","rowNodeSorter","ctrlsSvc","pinnedCols","dataTypeSvc","syncSvc","overlays","stateSvc","expansionSvc","apiEventSvc","ariaAnnounce","menuSvc","colMoves","colAutosize","colFlex","colResize","pivotColsSvc","valueColsSvc","rowGroupColsSvc","colNames","colViewport","pivotResultCols","showRowGroupCols","validation"].map((e,t)=>[e,t]));function cH(e,t){return((e.beanName?cV[e.beanName]:void 0)??Number.MAX_SAFE_INTEGER)-((t.beanName?cV[t.beanName]:void 0)??Number.MAX_SAFE_INTEGER)}function cG(e,t){return e?.beanName==="gridDestroySvc"?-1:+(t?.beanName==="gridDestroySvc")}var cW=class extends oI{constructor(){super(...arguments),this.additionalFocusableContainers=new Set}setComp(e,t,n){this.view=e,this.eGridHostDiv=t,this.eGui=n,this.eGui.setAttribute("grid-id",this.beans.context.getId());let{dragAndDrop:i,ctrlsSvc:r}=this.beans;i?.registerGridDropTarget(()=>this.eGui,this),this.createManagedBean(new uc(this.view)),this.view.setRtlClass(this.gos.get("enableRtl")?"ag-rtl":"ag-ltr");let o=oh(this.beans,this.eGridHostDiv,this.onGridSizeChanged.bind(this));this.addDestroyFunc(()=>o()),r.register("gridCtrl",this)}isDetailGrid(){let e=lM(this.getGui());return e?.getAttribute("row-id")?.startsWith("detail")||!1}getOptionalSelectors(){let e=this.beans;return{paginationSelector:e.pagination?.getPaginationSelector(),gridHeaderDropZonesSelector:e.registry?.getSelector("AG-GRID-HEADER-DROP-ZONES"),sideBarSelector:e.sideBar?.getSelector(),statusBarSelector:e.registry?.getSelector("AG-STATUS-BAR"),watermarkSelector:e.licenseManager?.getWatermarkSelector()}}onGridSizeChanged(){this.eventSvc.dispatchEvent({type:"gridSizeChanged",clientWidth:this.eGridHostDiv.clientWidth,clientHeight:this.eGridHostDiv.clientHeight})}destroyGridUi(){this.view.destroyGridUi()}getGui(){return this.eGui}setResizeCursor(e){let{view:t}=this;!1===e?t.setCursor(null):t.setCursor(1===e?"ew-resize":"ns-resize")}disableUserSelect(e){this.view.setUserSelect(e?"none":null)}focusNextInnerContainer(e){let t=this.getFocusableContainers(),{indexWithFocus:n,nextIndex:i}=this.getNextFocusableIndex(t,e);if(i<0||i>=t.length)return!1;if(0===i){if(n>0){let{visibleCols:e,focusSvc:t}=this.beans,n=aY(e.allCols);if(t.focusGridView({column:n,backwards:!0}))return!0}return!1}return this.focusContainer(t[i],e)}focusInnerElement(e){let t=this.gos.getCallback("focusGridInnerElement");
376if(t?.({fromBottom:!!e}))return!0;let n=this.getFocusableContainers(),{focusSvc:i,visibleCols:r}=this.beans,o=r.allCols;if(e){if(n.length>1)return this.focusContainer(aY(n),e);let t=aY(o);if(i.focusGridView({column:t,backwards:e}))return!0}if(0===this.gos.get("headerHeight")||u0(this.beans)){if(i.focusGridView({column:o[0],backwards:e}))return!0;for(let t=1;t<n.length;t++)if(l_(n[t].getGui(),e))return!0;return!1}return i.focusFirstHeader()}forceFocusOutOfContainer(e=!1){this.view.forceFocusOutOfContainer(e)}addFocusableContainer(e){this.additionalFocusableContainers.add(e)}removeFocusableContainer(e){this.additionalFocusableContainers.delete(e)}allowFocusForNextCoreContainer(e){let t=this.view.getFocusableContainers(),{nextIndex:n,indexWithFocus:i}=this.getNextFocusableIndex(t,e);if(-1===i||n<0||n>=t.length)return;let r=t[n];r.setAllowFocus?.(!0),setTimeout(()=>{r.setAllowFocus?.(!1)})}isFocusable(){let e=this.beans;return!u1(e)||!u0(e)||!!e.sideBar?.comp?.isDisplayed()}getNextFocusableIndex(e,t){let n=rA(this.beans),i=e.findIndex(e=>e.getGui().contains(n));return{indexWithFocus:i,nextIndex:i+(t?-1:1)}}focusContainer(e,t){e.setAllowFocus?.(!0);let n=l_(e.getGui(),t,!1,!0);return e.setAllowFocus?.(!1),n}getFocusableContainers(){return[...this.view.getFocusableContainers(),...this.additionalFocusableContainers]}destroy(){this.additionalFocusableContainers.clear(),super.destroy()}},c$=(e,t)=>{for(let n of Object.keys(t))t[n]=e;return t},cU={dispatchEvent:"CommunityCore",...c$("CommunityCore",{destroy:0,getGridId:0,getGridOption:0,isDestroyed:0,setGridOption:0,updateGridOptions:0,isModuleRegistered:0}),...c$("GridState",{getState:0,setState:0}),...c$("SharedRowSelection",{setNodesSelected:0,selectAll:0,deselectAll:0,selectAllFiltered:0,deselectAllFiltered:0,selectAllOnCurrentPage:0,deselectAllOnCurrentPage:0,getSelectedNodes:0,getSelectedRows:0}),...c$("RowApi",{redrawRows:0,setRowNodeExpanded:0,getRowNode:0,addRenderedRowListener:0,getRenderedNodes:0,forEachNode:0,getFirstDisplayedRowIndex:0,getLastDisplayedRowIndex:0,getDisplayedRowAtIndex:0,getDisplayedRowCount:0}),...c$("ScrollApi",{getVerticalPixelRange:0,getHorizontalPixelRange:0,ensureColumnVisible:0,ensureIndexVisible:0,ensureNodeVisible:0}),...c$("KeyboardNavigation",{getFocusedCell:0,clearFocusedCell:0,setFocusedCell:0,tabToNextCell:0,tabToPreviousCell:0,setFocusedHeader:0}),...c$("EventApi",{addEventListener:0,addGlobalListener:0,removeEventListener:0,removeGlobalListener:0}),...c$("ValueCache",{expireValueCache:0}),...c$("CellApi",{getCellValue:0}),...c$("SharedMenu",{showColumnMenu:0,hidePopupMenu:0}),...c$("Sort",{onSortChanged:0}),...c$("PinnedRow",{getPinnedTopRowCount:0,getPinnedBottomRowCount:0,getPinnedTopRow:0,getPinnedBottomRow:0,forEachPinnedRow:0}),...c$("Overlay",{showLoadingOverlay:0,showNoRowsOverlay:0,hideOverlay:0}),...c$("RenderApi",{setGridAriaProperty:0,refreshCells:0,refreshHeader:0,isAnimationFrameQueueEmpty:0,flushAllAnimationFrames:0,getSizesForCurrentTheme:0,getCellRendererInstances:0}),...c$("HighlightChanges",{flashCells:0}),...c$("RowDrag",{addRowDropZone:0,removeRowDropZone:0,getRowDropZoneParams:0,getRowDropPositionIndicator:0,setRowDropPositionIndicator:0}),...c$("ColumnApi",{getColumnDefs:0,getColumnDef:0,getDisplayNameForColumn:0,getColumn:0,getColumns:0,applyColumnState:0,getColumnState:0,resetColumnState:0,isPinning:0,isPinningLeft:0,isPinningRight:0,getDisplayedColAfter:0,getDisplayedColBefore:0,setColumnsVisible:0,setColumnsPinned:0,getAllGridColumns:0,getDisplayedLeftColumns:0,getDisplayedCenterColumns:0,getDisplayedRightColumns:0,getAllDisplayedColumns:0,getAllDisplayedVirtualColumns:0}),...c$("ColumnAutoSize",{sizeColumnsToFit:0,autoSizeColumns:0,autoSizeAllColumns:0}),...c$("ColumnGroup",{setColumnGroupOpened:0,getColumnGroup:0,getProvidedColumnGroup:0,getDisplayNameForColumnGroup:0,getColumnGroupState:0,setColumnGroupState:0,resetColumnGroupState:0,getLeftDisplayedColumnGroups:0,getCenterDisplayedColumnGroups:0,getRightDisplayedColumnGroups:0,getAllDisplayedColumnGroups:0}),...c$("ColumnMove",{moveColumnByIndex:0,moveColumns:0}),...c$("ColumnResize",{setColumnWidths:0}),...c$("ColumnHover",{isColumnHovered:0}),...c$("EditCore",{getCellEditorInstances:0,getEditingCells:0,getEditRowValues:0,stopEditing:0,startEditingCell:0,isEditing:0,validateEdit:0}),...c$("BatchEdit",{startBatchEdit:0,cancelBatchEdit:0,commitBatchEdit:0,isBatchEditing:0}
376),...c$("UndoRedoEdit",{undoCellEditing:0,redoCellEditing:0,getCurrentUndoSize:0,getCurrentRedoSize:0}),...c$("FilterCore",{isAnyFilterPresent:0,onFilterChanged:0}),...c$("ColumnFilter",{isColumnFilterPresent:0,getColumnFilterInstance:0,destroyFilter:0,setFilterModel:0,getFilterModel:0,getColumnFilterModel:0,setColumnFilterModel:0,showColumnFilter:0,hideColumnFilter:0,getColumnFilterHandler:0,doFilterAction:0}),...c$("QuickFilter",{isQuickFilterPresent:0,getQuickFilter:0,resetQuickFilter:0}),...c$("Find",{findGetActiveMatch:0,findGetTotalMatches:0,findGoTo:0,findNext:0,findPrevious:0,findGetNumMatches:0,findGetParts:0,findClearActive:0,findRefresh:0}),...c$("Pagination",{paginationIsLastPageFound:0,paginationGetPageSize:0,paginationGetCurrentPage:0,paginationGetTotalPages:0,paginationGetRowCount:0,paginationGoToNextPage:0,paginationGoToPreviousPage:0,paginationGoToFirstPage:0,paginationGoToLastPage:0,paginationGoToPage:0}),...c$("CsrmSsrmSharedApi",{expandAll:0,collapseAll:0}),...c$("SsrmInfiniteSharedApi",{setRowCount:0,getCacheBlockState:0,isLastRowIndexKnown:0}),...c$("ClientSideRowModelApi",{onGroupExpandedOrCollapsed:0,refreshClientSideRowModel:0,isRowDataEmpty:0,forEachLeafNode:0,forEachNodeAfterFilter:0,forEachNodeAfterFilterAndSort:0,applyTransaction:0,applyTransactionAsync:0,flushAsyncTransactions:0,getBestCostNodeSelection:0,onRowHeightChanged:0,resetRowHeights:0}
376),...c$("CsvExport",{getDataAsCsv:0,exportDataAsCsv:0}),...c$("InfiniteRowModel",{refreshInfiniteCache:0,purgeInfiniteCache:0,getInfiniteRowCount:0}),...c$("AdvancedFilter",{getAdvancedFilterModel:0,setAdvancedFilterModel:0,showAdvancedFilterBuilder:0,hideAdvancedFilterBuilder:0}),...c$("IntegratedCharts",{getChartModels:0,getChartRef:0,getChartImageDataURL:0,downloadChart:0,openChartToolPanel:0,closeChartToolPanel:0,createRangeChart:0,createPivotChart:0,createCrossFilterChart:0,updateChart:0,restoreChart:0}),...c$("Clipboard",{copyToClipboard:0,cutToClipboard:0,copySelectedRowsToClipboard:0,copySelectedRangeToClipboard:0,copySelectedRangeDown:0,pasteFromClipboard:0}),...c$("ExcelExport",{getDataAsExcel:0,exportDataAsExcel:0,getSheetDataForExcel:0,getMultipleSheetsAsExcel:0,exportMultipleSheetsAsExcel:0}),...c$("SharedMasterDetail",{addDetailGridInfo:0,removeDetailGridInfo:0,getDetailGridInfo:0,forEachDetailGridInfo:0}),...c$("ContextMenu",{showContextMenu:0}),...c$("ColumnMenu",{showColumnChooser:0,hideColumnChooser:0}),...c$("CellSelection",{getCellRanges:0,addCellRange:0,clearRangeSelection:0,clearCellSelection:0}),...c$("SharedRowGrouping",{setRowGroupColumns:0,removeRowGroupColumns:0,addRowGroupColumns:0,getRowGroupColumns:0,moveRowGroupColumn:0}),...c$("SharedAggregation",{addAggFuncs:0,clearAggFuncs:0,setColumnAggFunc:0}),...c$("SharedPivot",{isPivotMode:0,getPivotResultColumn:0,setValueColumns:0,getValueColumns:0,removeValueColumns:0,addValueColumns:0,setPivotColumns:0,removePivotColumns:0,addPivotColumns:0,getPivotColumns:0,setPivotResultColumns:0,getPivotResultColumns:0}),...c$("ServerSideRowModelApi",{getServerSideSelectionState:0,setServerSideSelectionState:0,applyServerSideTransaction:0,applyServerSideTransactionAsync:0,applyServerSideRowData:0,retryServerSideLoads:0,flushServerSideAsyncTransactions:0,refreshServerSide:0,getServerSideGroupLevelState:0,onRowHeightChanged:0,resetRowHeights:0}),...c$("SideBar",{isSideBarVisible:0,setSideBarVisible:0,setSideBarPosition:0,openToolPanel:0,closeToolPanel:0,getOpenedToolPanel:0,refreshToolPanel:0,isToolPanelShowing:0,getToolPanelInstance:0,getSideBar:0}),...c$("StatusBar",{getStatusPanel:0}),...c$("AiToolkit",{getStructuredSchema:0})},cq={isDestroyed:()=>!0,destroy(){},preConstruct(){},postConstruct(){},preWireBeans(){},wireBeans(){}},cK=(e,t)=>e.eventSvc.dispatchEvent(t),cY=class{};Reflect.defineProperty(cY,"name",{value:"GridApi"});var cZ=class extends oI{constructor(){super(),this.beanName="apiFunctionSvc",this.api=new cY,this.fns={...cq,dispatchEvent:cK},this.preDestroyLink="";const{api:e}=this;for(const t of Object.keys(cU))e[t]=this.makeApi(t)[t]}postConstruct(){this.preDestroyLink=this.beans.frameworkOverrides.getDocLink("grid-lifecycle/#grid-pre-destroyed")}addFunction(e,t){let{fns:n,beans:i}=this;n!==cq&&(n[e]=i?.validation?.validateApiFunction(e,t)??t)}makeApi(e){return{[e]:(...t)=>{let{beans:n,fns:{[e]:i}}=this;return i?i(n,...t):this.apiNotFound(e)}}}apiNotFound(e){let{beans:t,gos:n,preDestroyLink:i}=this;if(t){let t=cU[e];n.assertModuleRegistered(t,`api.${e}`)&&at(27,{fnName:e,module:t})}else at(26,{fnName:e,preDestroyLink:i})}destroy(){super.destroy(),this.fns=cq,this.beans=null}};function cX(e,t){e.gos.updateGridOptions({options:t})}var cJ={tag:"div",cls:"ag-drag-handle ag-row-drag",attrs:{draggable:"true"}},cQ=class extends dT{shouldPreventMouseEvent(e){return this.gos.get("enableCellTextSelection")&&super.shouldPreventMouseEvent(e)}},c0=class extends oI{constructor(){super(...arguments),this.beanName="horizontalResizeSvc"}addResizeBar(e){let t={dragStartPixels:e.dragStartPixels||0,eElement:e.eResizeBar,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this,e),onDragging:this.onDragging.bind(this,e),onDragCancel:this.onDragStop.bind(this,e),includeTouch:!0,stopPropagationForTouch:!0},{dragSvc:n}=this.beans;return n.addDragSource(t),()=>n.removeDragSource(t)}onDragStart(e,t){this.dragStartX=t.clientX,this.setResizeIcons();let n=t instanceof MouseEvent&&!0===t.shiftKey;e.onResizeStart(n)}setResizeIcons(){let e=this.beans.ctrlsSvc.get("gridCtrl");
376e.setResizeCursor(1),e.disableUserSelect(!0)}onDragStop(e){e.onResizeEnd(this.resizeAmount),this.resetIcons()}resetIcons(){let e=this.beans.ctrlsSvc.get("gridCtrl");e.setResizeCursor(!1),e.disableUserSelect(!1)}onDragging(e,t){this.resizeAmount=t.clientX-this.dragStartX,e.onResizing(this.resizeAmount)}},c1={tag:"div",cls:"ag-drag-handle ag-row-drag",attrs:{"aria-hidden":"true"}},c2=class{constructor(){this.reordered=!1,this.removals=new Set,this.updates=new Set,this.adds=new Set}};function c3(e,t){let n=e.column===t.column,i=e.rowPinned===t.rowPinned,r=e.rowIndex===t.rowIndex;return n&&i&&r}function c5(e,t){switch(t.rowPinned){case"top":return e.pinnedRowModel?.getPinnedTopRow(t.rowIndex);case"bottom":return e.pinnedRowModel?.getPinnedBottomRow(t.rowIndex);default:return e.rowModel.getRow(t.rowIndex)}}function c4(e,t){let n=e.spannedRowRenderer?.getCellByPosition(t);if(n)return n;let i=e.rowRenderer.getRowByPosition(t);return i?i.getCellCtrl(t.column):null}function c6(e,t,n=!1){let{rowIndex:i,rowPinned:r}=t,{pageBounds:o,pinnedRowModel:a,rowModel:s}=e;return 0===i?"top"===r?null:"bottom"===r&&s.isRowsToRender()?{rowIndex:o.getLastRow(),rowPinned:null}:a?.isRowsToRender("top")?{rowIndex:a.getPinnedTopRowCount()-1,rowPinned:"top"}:null:n?c7(e,r?void 0:s.getRow(i),!0)??{rowIndex:i-1,rowPinned:r}:{rowIndex:i-1,rowPinned:r}}function c8(e,t,n=!1){let{rowIndex:i,rowPinned:r}=t,{pageBounds:o,pinnedRowModel:a,rowModel:s}=e;return function(e,t){let{rowPinned:n,rowIndex:i}=t,{pinnedRowModel:r,pageBounds:o}=e;return"top"===n?(r?.getPinnedTopRowCount()??0)-1<=i:"bottom"===n?(r?.getPinnedBottomRowCount()??0)-1<=i:o.getLastRow()<=i}(e,t)?"bottom"===r?null:"top"===r&&s.isRowsToRender()?{rowIndex:o.getFirstRow(),rowPinned:null}:a?.isRowsToRender("bottom")?{rowIndex:0,rowPinned:"bottom"}:null:n?c7(e,r?void 0:s.getRow(i))??{rowIndex:i+1,rowPinned:r}:{rowIndex:i+1,rowPinned:r}}function c7(e,t,n=!1){let i,{gos:r,rowRenderer:o}=e;if(!t?.sticky||!av(r))return;let a=o.getStickyTopRowCtrls(),s=o.getStickyBottomRowCtrls(),l=!s.some(e=>e.rowNode.rowIndex===t.rowIndex),d=l?a:s,u=(n?-1:1)*(l?-1:1);for(let e=0;e<d.length;e++)if(d[e].rowNode.rowIndex===t.rowIndex){i=d[e+u];break}return i?{rowIndex:i.rowNode.rowIndex,rowPinned:null}:void 0}var c9=class{constructor(e,t){this.active=!0,this.nodeIdsToColumns={},this.mapToItems={},this.keepingColumns=e,this.pathRoot={rowNode:t,children:null},this.mapToItems[t.id]=this.pathRoot}depthFirstSearchChangedPath(e,t){let{rowNode:n,children:i}=e;if(i)for(let e=0;e<i.length;++e)this.depthFirstSearchChangedPath(i[e],t);t(n)}depthFirstSearchEverything(e,t,n){let i=e.childrenAfterGroup;if(i)for(let e=0,r=i.length;e<r;++e){let r=i[e];r.childrenAfterGroup?this.depthFirstSearchEverything(r,t,n):n&&t(r)}t(e)}forEachChangedNodeDepthFirst(e,t=!1,n=!1){this.active&&!n?this.depthFirstSearchChangedPath(this.pathRoot,e):this.depthFirstSearchEverything(this.pathRoot.rowNode,e,t)}executeFromRootNode(e){e(this.pathRoot.rowNode)}createPathItems(e){let t=e,n=0;for(;!this.mapToItems[t.id];){let e={rowNode:t,children:null};this.mapToItems[t.id]=e,n++,t=t.parent}return n}populateColumnsMap(e,t){if(!this.keepingColumns||!t)return;let n=e;for(;n;){for(let e of(this.nodeIdsToColumns[n.id]||(this.nodeIdsToColumns[n.id]={}),t))this.nodeIdsToColumns[n.id][e.getId()]=!0;n=n.parent}}linkPathItems(e,t){let n=e;for(let e=0;e<t;e++){let e=this.mapToItems[n.id],t=this.mapToItems[n.parent.id];t.children||(t.children=[]),t.children.push(e),n=n.parent}}addParentNode(e,t){if(!e||e.isRowPinned())return;let n=this.createPathItems(e);this.linkPathItems(e,n),this.populateColumnsMap(e,t)}canSkip(e){return this.active&&!this.mapToItems[e.id]}getValueColumnsForNode(e,t){if(!this.keepingColumns)return t;let n=this.nodeIdsToColumns[e.id];return t.filter(e=>n[e.getId()])}getNotValueColumnsForNode(e,t){if(!this.keepingColumns)return null;let n=this.nodeIdsToColumns[e.id];return t.filter(e=>!n[e.getId()])}}
376,he={moduleName:"Drag",version:o1,beans:[cQ]},ht=class extends oI{constructor(){super(...arguments),this.beanName="colAnimation",this.executeNextFuncs=[],this.executeLaterFuncs=[],this.active=!1,this.activeNext=!1,this.suppressAnimation=!1,this.animationThreadCount=0}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>this.gridBodyCtrl=e.gridBodyCtrl)}isActive(){return this.active&&!this.suppressAnimation}setSuppressAnimation(e){this.suppressAnimation=e}start(){if(this.active)return;let{gos:e}=this;e.get("suppressColumnMoveAnimation")||e.get("enableRtl")||(this.ensureAnimationCssClassPresent(),this.active=!0,this.activeNext=!0)}finish(){this.active&&this.flush(()=>this.activeNext=!1,()=>this.active=!1)}executeNextVMTurn(e){this.activeNext?this.executeNextFuncs.push(e):e()}executeLaterVMTurn(e){this.active?this.executeLaterFuncs.push(e):e()}ensureAnimationCssClassPresent(){this.animationThreadCount++;let e=this.animationThreadCount,{gridBodyCtrl:t}=this;t.setColumnMovingCss(!0),this.executeLaterFuncs.push(()=>{this.animationThreadCount===e&&t.setColumnMovingCss(!1)})}flush(e,t){let{executeNextFuncs:n,executeLaterFuncs:i}=this;if(0===n.length&&0===i.length){e(),t();return}let r=e=>{for(;e.length;){let t=e.pop();t&&t()}};this.beans.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(()=>{e(),r(n)},0),window.setTimeout(()=>{t(),r(i)},200)})}},hn=class extends oI{constructor(e){super(),this.pinned=e,this.columnsToAggregate=[],this.columnsToGroup=[],this.columnsToPivot=[]}onDragEnter(e){if(this.clearColumnsList(),this.gos.get("functionsReadOnly"))return;let t=e.dragItem.columns;if(t)for(let e of t)e.isPrimary()&&!e.isAnyFunctionActive()&&(e.isAllowValue()?this.columnsToAggregate.push(e):e.isAllowRowGroup()?this.columnsToGroup.push(e):e.isAllowPivot()&&this.columnsToPivot.push(e))}getIconName(){return this.columnsToAggregate.length+this.columnsToGroup.length+this.columnsToPivot.length>0?this.pinned?"pinned":"move":null}onDragLeave(e){this.clearColumnsList()}clearColumnsList(){this.columnsToAggregate.length=0,this.columnsToGroup.length=0,this.columnsToPivot.length=0}onDragging(e){}onDragStop(e){let{valueColsSvc:t,rowGroupColsSvc:n,pivotColsSvc:i}=this.beans;this.columnsToAggregate.length>0&&t?.addColumns(this.columnsToAggregate,"toolPanelDragAndDrop"),this.columnsToGroup.length>0&&n?.addColumns(this.columnsToGroup,"toolPanelDragAndDrop"),this.columnsToPivot.length>0&&i?.addColumns(this.columnsToPivot,"toolPanelDragAndDrop")}onDragCancel(){this.clearColumnsList()}};function hi(e){var t,n;let i,r,o,{isFromHeader:a,fromLeft:s,xPosition:l,fromEnter:d,fakeEvent:u,pinned:c,gos:h,colModel:p,colMoves:f,visibleCols:g}=e,{allMovingColumns:m}=e;a&&(m=function(e){let t=[...e];for(let n of e){let e=null,i=n.getParent();for(;null!=i&&1===i.getDisplayedLeafColumns().length;)e=i,i=i.getParent();if(null!=e)for(let n of e.getColGroupDef()?.marryChildren?e.getProvidedColumnGroup().getLeafColumns():e.getLeafColumns())t.includes(n)||t.push(n)}return t}(m));let v=m.slice();t=p.getCols(),v&&!(v.length<=1)&&(v.filter(e=>0>t.indexOf(e)).length>0||v.sort((e,n)=>t.indexOf(e)-t.indexOf(n)));let y=function(e){let t,{movingCols:n,draggingRight:i,xPosition:r,pinned:o,gos:a,colModel:s,visibleCols:l}=e;if(a.get("suppressMovableColumns")||n.some(e=>e.getColDef().suppressMovable))return[];let d=function(e,t){switch(t){case"left":return e.leftCols;case"right":return e.rightCols;default:return e.centerCols}}(l,o),u=s.getCols(),c=d.filter(e=>n.includes(e)),h=d.filter(e=>!n.includes(e)),p=u.filter(e=>!n.includes(e)),f=0,g=r;if(i){let e=0;for(let t of c)e+=t.getActualWidth();g-=e}if(g>0){for(let e=0;e<h.length&&!((g-=h[e].getActualWidth())<0);e++)f++;i&&f++}if(f>0){let e=h[f-1];t=p.indexOf(e)+1}else -1===(t=p.indexOf(h[0]))&&(t=0);let m=[t],v=(e,t)=>e-t;if(i){let e=t+1,n=u.length-1;for(;e<=n;)m.push(e),e++;m.sort(v)}else{let e=t,n=u.length-1,i=u[e];for(;e<=n&&0>d.indexOf(i);)e++,m.push(e),i=u[e];for(e=t-1;e>=0;)m.push(e),e--;m.sort(v).reverse()}return m}({movingCols:v,draggingRight:s,xPosition:l,pinned:c,gos:h,colModel:p,visibleCols:g}),b=(n=v,i=p.getCols(),o=(r=n.map(e=>i.indexOf(e)).sort((e,t)=>
376e-t))[0],aY(r)-o!=r.length-1?null:o);if(0===y.length)return;let x=y[0];if(null!==b&&(a||!d)&&!u&&(!s&&x>=b||s&&x<=b))return;let w=function(e,t,n,i){let r=i.allCols,o=null,a=null;for(let i=0;i<e.length;i++){let s=e[i],l=n.getProposedColumnOrder(t,s);if(!n.doesOrderPassRules(l))continue;let d=l.filter(e=>r.includes(e));if(null===a)a=d;else if(!aZ(d,a))break;let u=function(e){function t(e){let t=[],n=e.getOriginalParent();for(;null!=n;)t.push(n),n=n.getOriginalParent();return t}let n=0;for(let i=0;i<e.length-1;i++){let r=t(e[i]),o=t(e[i+1]);for(let e of([r,o]=r.length>o.length?[r,o]:[o,r],r))-1===o.indexOf(e)&&n++}return n}(l);(null===o||u<o.fragCount)&&(o={move:s,fragCount:u})}return o}(y,v,f,g);if(!w)return;let C=w.move;if(!(C>p.getCols().length-v.length))return{columns:v,toIndex:C}}function hr(e){let{columns:t,toIndex:n}=hi(e)||{},{finished:i,colMoves:r}=e;return t&&null!=n?(r.moveColumns(t,n,"uiColumnMoved",i),i?null:{columns:t,toIndex:n}):null}function ho(e){let{pinned:t,fromKeyboard:n,gos:i,ctrlsSvc:r,useHeaderRow:o,skipScrollPadding:a}=e,s=r.getHeaderRowContainerCtrl(t)?.eViewport,{x:l}=e;return s?(n&&(l-=s.getBoundingClientRect().left),i.get("enableRtl")&&(o&&(s=s.querySelector(".ag-header-row")),l=s.clientWidth-l),null!=t||a||(l+=r.get("center").getCenterViewportScrollLeft()),l):0}function ha(e,t){for(let n of e)n.moving=t,n.dispatchColEvent("movingChanged","uiColumnMoved")}var hs=class extends oI{constructor(e){super(),this.pinned=e,this.needToMoveLeft=!1,this.needToMoveRight=!1,this.lastMovedInfo=null,this.isCenterContainer=!rC(e)}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl})}getIconName(){let{pinned:e,lastDraggingEvent:t}=this,{dragItem:n}=t||{};for(let t of n?.columns??[]){let i=t.getPinned();if(t.getColDef().lockPinned){if(i==e)return"move";continue}let r=n?.containerType;if(r===e||!e)return"move";if(e&&(!i||r!==e))return"pinned"}return"notAllowed"}onDragEnter(e){let t=e.dragItem,n=t.columns;if(0===e.dragSource.type)this.setColumnsVisible(n,!0,"uiColumnDragged");else{let e=t.visibleState,i=(n||[]).filter(t=>e[t.getId()]&&!t.isVisible());this.setColumnsVisible(i,!0,"uiColumnDragged")}this.gos.get("suppressMoveWhenColumnDragging")||this.attemptToPinColumns(n,this.pinned),this.onDragging(e,!0,!0)}onDragging(e=this.lastDraggingEvent,t=!1,n=!1,i=!1){let{gos:r,ctrlsSvc:o}=this.beans,a=r.get("suppressMoveWhenColumnDragging");if(i&&!a)return void this.finishColumnMoving();if(this.lastDraggingEvent=e,!e||!i&&rS(e.hDirection))return;let s=ho({x:e.x,pinned:this.pinned,gos:r,ctrlsSvc:o});t||this.checkCenterForScrolling(s),a?this.handleColumnDragWhileSuppressingMovement(e,t,n,s,i):this.handleColumnDragWhileAllowingMovement(e,t,n,s,i)}onDragLeave(){this.ensureIntervalCleared(),this.clearHighlighted(),this.updateDragItemContainerType(),this.lastMovedInfo=null}onDragStop(){this.onDragging(this.lastDraggingEvent,!1,!0,!0),this.ensureIntervalCleared(),this.lastMovedInfo=null}onDragCancel(){this.clearHighlighted(),this.ensureIntervalCleared(),this.lastMovedInfo=null}setColumnsVisible(e,t,n){if(!e?.length)return;let i=e.filter(e=>!e.getColDef().lockVisible);i.length&&this.beans.colModel.setColsVisible(i,t,n)}finishColumnMoving(){this.clearHighlighted();let e=this.lastMovedInfo;if(!e)return;let{columns:t,toIndex:n}=e;this.beans.colMoves.moveColumns(t,n,"uiColumnMoved",!0)}updateDragItemContainerType(){let{lastDraggingEvent:e}=this;if(this.gos.get("suppressMoveWhenColumnDragging")||!e)return;let t=e.dragItem;t&&(t.containerType=this.pinned)}handleColumnDragWhileSuppressingMovement(e,t,n,i,r){let o=this.getAllMovingColumns(e,!0);if(r){let e=this.isAttemptingToPin(o);e&&this.attemptToPinColumns(o,void 0,!0);let{fromLeft:i,xPosition:r}=this.getNormalisedXPositionInfo(o,e)||{};if(null==i||null==r)return void this.finishColumnMoving();this.moveColumnsAfterHighlight({allMovingColumns:o,xPosition:r,fromEnter:t,fakeEvent:n,fromLeft:i})}else{if(!this.beans.dragAndDrop.isDropZoneWithinThisGrid(e))return;this.highlightHoveredColumn(o,i)}}handleColumnDragWhileAllowingMovement(e,t,n,i,r){let o=this.getAllMovingColumns(e),a="right"===this.normaliseDirection(e.hDirection),s=1===e.dragSource.type,l=hr({...this.getMoveColumnParams({allMovingColumns:o,isFromHeader:s,xPosition:i,fromLeft:a,fromEnter:t,fakeEvent:n}),finished:r});l&&(this.lastMovedInfo=l)}getAllMovingColumns(e,t=!1){let n=e.dragSource.getDragItem(),i=null;t&&(i=n.columnsInSplit)||(i=n.columns);let r=e=>!e.getColDef().lockPinned||e.getPinned()==this.pinned;return i?i.filter(r):[]}getMoveColumnParams(e){let{allMovingColumns:t,isFromHeader:n,xPosition:i,fromLeft:r,fromEnter:o,fakeEvent:a}=e,{gos:s,colModel:l,colMoves:d,visibleCols:u}=this.beans;return{allMovingColumns:t,isFromHeader:n,fromLeft:r,xPosition:i,pinned:this.pinned,fromEnter:o,fakeEvent:a,gos:s,colModel:l,colMoves:d,visibleCols:u}}highlightHoveredColumn(e,t){let n,{gos:i,colModel:r}=this.beans,o=i.get("enableRtl"),a=r.getCols().filter(e=>e.isVisible()&&e.getPinned()===this.pinned),s=null,l=null,d=null;for(let e of a){if(l=e.getActualWidth(),null!=(s=this.getNormalisedColumnLeft(e,0,o))){let n=s+l;if(s<=t&&n>=t){d=e;break}}s=null,l=null}if(d)-1!==e.indexOf(d)&&(d=null);else{for(let e=a.length-1;e>=0;e--){let t=a[e],n=a[e].getParent();if(!n){d=t;break}let i=n?.getDisplayedLeafColumns();if(i.length){d=aY(i);break}}if(!d)return;s=this.getNormalisedColumnLeft(d,0,o),l=d.getActualWidth()}this.lastHighlightedColumn?.column!==d&&this.clearHighlighted(),null!=d&&null!=s&&null!=l&&(hl(d,n=+(t-s<l/2===o)),this.lastHighlightedColumn={column:d,position:n})}getNormalisedXPositionInfo(e,t){let{gos:n,visibleCols:i}=this.beans,r=n.get("enableRtl"),{firstMovingCol:o,column:a,position:s}=this.getColumnMoveAndTargetInfo(e,t,r);if(!o||!a||null==s)return;let l=i.allCols,d=l.indexOf(o),u=l.indexOf(a),c=0===s!==r,h=d<u||d===u&&!c,p=0;if(c?h&&(p-=1):h||(p+=1),u+p===d)return;let f=l[u+p];if(f)return{fromLeft:h,xPosition:this.getNormalisedColumnLeft(f,20,r)}}getColumnMoveAndTargetInfo(e,t,n){let i=this.lastHighlightedColumn||{},{firstMovingCol:r,lastMovingCol:o}=function(e){let t,n,i=e.length;for(let r=0;r<i;r++){if(!t){let n=e[r];null!=n.getLeft()&&(t=n)}if(!n){let t=e[i-1-r];null!=t.getLeft()&&(n=t)}if(t&&n)break}return{firstMovingCol:t,lastMovingCol:n}}(e);
376if(!r||!o||i.column||!t)return{firstMovingCol:r,...i};let a="left"===this.getPinDirection();return{firstMovingCol:r,position:+!!a,column:a!==n?r:o}}normaliseDirection(e){if(this.gos.get("enableRtl"))switch(e){case"left":return"right";case"right":return"left"}return e}getNormalisedColumnLeft(e,t,n){let{gos:i,ctrlsSvc:r}=this.beans,o=e.getLeft();if(null==o)return null;let a=e.getActualWidth();return ho({x:n?o+a-t:o+t,pinned:e.getPinned(),useHeaderRow:n,skipScrollPadding:!0,gos:i,ctrlsSvc:r})}isAttemptingToPin(e){let t=this.needToMoveLeft||this.needToMoveRight,n=this.failedMoveAttempts>7;return t&&n||e.some(e=>e.getPinned()!==this.pinned)}moveColumnsAfterHighlight(e){let{allMovingColumns:t,xPosition:n,fromEnter:i,fakeEvent:r,fromLeft:o}=e,{columns:a,toIndex:s}=hi(this.getMoveColumnParams({allMovingColumns:t,isFromHeader:!0,xPosition:n,fromLeft:o,fromEnter:i,fakeEvent:r}))||{};a&&null!=s&&(this.lastMovedInfo={columns:a,toIndex:s}),this.finishColumnMoving()}clearHighlighted(){let{lastHighlightedColumn:e}=this;e&&(hl(e.column,null),this.lastHighlightedColumn=null)}checkCenterForScrolling(e){let t,n;if(!this.isCenterContainer)return;let i=this.beans.ctrlsSvc.get("center"),r=i.getCenterViewportScrollLeft(),o=r+i.getCenterWidth();this.gos.get("enableRtl")?(t=e<r+50,n=e>o-50):(n=e<r+50,t=e>o-50),this.needToMoveRight=t,this.needToMoveLeft=n,n||t?this.ensureIntervalStarted():this.ensureIntervalCleared()}ensureIntervalStarted(){this.movingIntervalId||(this.intervalCount=0,this.failedMoveAttempts=0,this.movingIntervalId=window.setInterval(this.moveInterval.bind(this),100),this.beans.dragAndDrop.setDragImageCompIcon(this.needToMoveLeft?"left":"right",!0))}ensureIntervalCleared(){this.movingIntervalId&&(window.clearInterval(this.movingIntervalId),this.movingIntervalId=null,this.failedMoveAttempts=0,this.beans.dragAndDrop.setDragImageCompIcon(this.getIconName()))}moveInterval(){let e;this.intervalCount++,(e=10+5*this.intervalCount)>100&&(e=100);let t=null,n=this.gridBodyCon.scrollFeature;if(this.needToMoveLeft?t=n.scrollHorizontally(-e):this.needToMoveRight&&(t=n.scrollHorizontally(e)),0!==t)this.onDragging(this.lastDraggingEvent),this.failedMoveAttempts=0;else{this.failedMoveAttempts++;let{pinnedCols:e,dragAndDrop:t,gos:n}=this.beans;if(this.failedMoveAttempts<=8||!e)return;if(t.setDragImageCompIcon("pinned"),!n.get("suppressMoveWhenColumnDragging")){let e=this.lastDraggingEvent?.dragItem.columns;this.attemptToPinColumns(e,void 0,!0)}}}getPinDirection(){return this.needToMoveLeft||"left"===this.pinned?"left":this.needToMoveRight||"right"===this.pinned?"right":void 0}attemptToPinColumns(e,t,n=!1){let i=(e||[]).filter(e=>!e.getColDef().lockPinned);if(!i.length)return 0;n&&(t=this.getPinDirection());let{pinnedCols:r,dragAndDrop:o}=this.beans;return r?.setColsPinned(i,t,"uiColumnDragged"),n&&o.nudge(),i.length}destroy(){super.destroy(),this.lastDraggingEvent=null,this.clearHighlighted(),this.lastMovedInfo=null}};function hl(e,t){e.highlighted!==t&&(e.highlighted=t,e.dispatchColEvent("headerHighlightChanged","uiColumnMoved"))}var hd=class extends oI{constructor(e,t){super(),this.pinned=e,this.eContainer=t}postConstruct(){let{ctrlsSvc:e,dragAndDrop:t}=this.beans,n=this.pinned;e.whenReady(this,e=>{let t,i=e.gridBodyCtrl.eBodyViewport;switch(n){case"left":t=[[i,e.left.eContainer],[e.bottomLeft.eContainer],[e.topLeft.eContainer]];break;case"right":t=[[i,e.right.eContainer],[e.bottomRight.eContainer],[e.topRight.eContainer]];break;default:t=[[i,e.center.eViewport],[e.bottomCenter.eViewport],[e.topCenter.eViewport]]}this.eSecondaryContainers=t}),this.moveColumnFeature=this.createManagedBean(new hs(n)),this.bodyDropPivotTarget=this.createManagedBean(new hn(n)),t.addDropTarget(this),this.addDestroyFunc(()=>t.removeDropTarget(this))}isInterestedIn(e){return 1===e||0===e&&this.gos.get("allowDragFromColumnsToolPanel")}getSecondaryContainers(){return this.eSecondaryContainers}getContainer(){return this.eContainer}getIconName(){return this.currentDropListener.getIconName()}isDropColumnInPivotMode(e){return this.beans.colModel.isPivotMode()&&0===e.dragSource.type}onDragEnter(e){this.currentDropListener=this.isDropColumnInPivotMode(e)?this.bodyDropPivotTarget:this.moveColumnFeature,this.currentDropListener.onDragEnter(e)}onDragLeave(e){this.currentDropListener.onDragLeave(e)}onDragging(e){this.currentDropListener.onDragging(e)}onDragStop(e){this.currentDropListener.onDragStop(e)}onDragCancel(){this.currentDropListener.onDragCancel()}},hu=class extends oI{constructor(){super(...arguments),this.beanName="
376colMoves"}moveColumnByIndex(e,t,n){let i=this.beans.colModel.getCols();if(!i)return;let r=i[e];this.moveColumns([r],t,n)}moveColumns(e,t,n,i=!0){let{colModel:r,colAnimation:o,visibleCols:a,eventSvc:s}=this.beans,l=r.getCols();if(!l)return;if(t>l.length-e.length)return void at(30,{toIndex:t});o?.start();let d=r.getColsForKeys(e);this.doesMovePassRules(d,t)&&(aQ(r.getCols(),d,t),a.refresh(n),s.dispatchEvent({type:"columnMoved",columns:d,column:1===d.length?d[0]:null,toIndex:t,finished:i,source:n})),o?.finish()}doesMovePassRules(e,t){let n=this.getProposedColumnOrder(e,t);return this.doesOrderPassRules(n)}doesOrderPassRules(e){let{colModel:t,gos:n}=this.beans;return!!sl(e,t.getColTree())&&!!(e=>{let t=e=>e?"left"===e||!0===e?-1:1:0,i=n.get("enableRtl"),r=i?1:-1,o=!0;for(let n of e){let e=t(n.getColDef().lockPosition);i?e>r&&(o=!1):e<r&&(o=!1),r=e}return o})(e)}getProposedColumnOrder(e,t){let n=this.beans.colModel.getCols().slice();return aQ(n,e,t),n}createBodyDropTarget(e,t){return new hd(e,t)}moveHeader(e,t,n,i,r){let o,{ctrlsSvc:a,gos:s,colModel:l,visibleCols:d,focusSvc:u}=this.beans,c=t.getBoundingClientRect(),h=c.left,p=dL(n),f=p?c.width:n.getActualWidth(),g="left"===e!==s.get("enableRtl"),m=ho({x:g?h-20:h+f+20,pinned:i,fromKeyboard:!0,gos:s,ctrlsSvc:a}),v=u.focusedHeader;if(hr({allMovingColumns:p?n.getLeafColumns():[n],isFromHeader:!0,fromLeft:"right"===e,xPosition:m,pinned:i,fromEnter:!1,fakeEvent:!1,gos:s,colModel:l,colMoves:this,visibleCols:d,finished:!0}),p){let e=n.getDisplayedLeafColumns();o=g?e[0]:aY(e)}else o=n;if(a.getScrollFeature().ensureColumnVisible(o,"auto"),(!r.isAlive()||s.get("ensureDomOrder"))&&v){let e;if(p){let t=n.getGroupId(),i=n.getLeafColumns();if(!i.length)return;let r=i[0].getParent();if(!r)return;e=function(e,t){for(;e;){if(e.getGroupId()===t)return e;e=e.getParent()}}(r,t)}else e=n;e&&u.focusHeaderPosition({headerPosition:{...v,column:e}})}}setDragSourceForHeader(e,t,n){let{gos:i,colModel:r,dragAndDrop:o,visibleCols:a}=this.beans,s=!i.get("suppressDragLeaveHidesColumns"),l=dL(t),d=l?t.getProvidedColumnGroup().getLeafColumns():[t],u={type:1,eElement:e,getDefaultIconName:()=>s?"hide":"notAllowed",getDragItem:l?()=>(function(e,t){let n=e.getProvidedColumnGroup().getLeafColumns(),i={};for(let e of n)i[e.getId()]=e.isVisible();let r=[];for(let e of t)n.indexOf(e)>=0&&(r.push(e),aJ(n,e));for(let e of n)r.push(e);let o=[],a=e.getLeafColumns();for(let e of r)-1!==a.indexOf(e)&&o.push(e);return{columns:r,columnsInSplit:o,visibleState:i,containerType:o[0]?.pinned}})(t,a.allCols):()=>{var e;let n;return(n={})[(e=t).getId()]=e.isVisible(),{columns:[e],visibleState:n,containerType:e.pinned}},dragItemName:n,onDragStarted:()=>{s=!i.get("suppressDragLeaveHidesColumns"),ha(d,!0)},onDragStopped:()=>ha(d,!1),onDragCancelled:()=>ha(d,!1),onGridEnter:e=>{if(s){let{columns:t=[],visibleState:n}=e??{},i=l?e=>!n||n[e.getColId()]:()=>!0,o=t.filter(e=>!e.getColDef().lockVisible&&i(e));r.setColsVisible(o,!0,"uiColumnMoved")}},onGridExit:e=>{if(s){let t=e?.columns?.filter(e=>!e.getColDef().lockVisible)||[];r.setColsVisible(t,!1,"uiColumnMoved")}}};return o.addDragSource(u,!0),u}},hc={moduleName:"AutoWidth",version:o1,beans:[class extends oI{constructor(){super(...arguments),this.beanName="autoWidthCalc"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.centerRowContainerCtrl=e.center})}getPreferredWidthForColumn(e,t){let n=this.getHeaderCellForColumn(e);if(!n)return -1;let i=this.beans.rowRenderer.getAllCellsNotSpanningForColumn(e);return t||i.push(n),this.getPreferredWidthForElements(i)}getPreferredWidthForColumnGroup(e){let t=this.getHeaderCellForColumn(e);return t?this.getPreferredWidthForElements([t]):-1}getPreferredWidthForElements(e,t){let n=document.createElement("form");n.style.position="fixed";let i=this.centerRowContainerCtrl.eContainer;for(let t of e)this.cloneItemIntoDummy(t,n);i.appendChild(n);let r=n.offsetWidth;return n.remove(),r+(t=t??this.gos.get("autoSizePadding"))}getHeaderCellForColumn(e){let t=null;for(let n of this.beans.ctrlsSvc.getHeaderRowContainerCtrls()){let i=n.getHtmlElementForColumnHeader(e);null!=i&&(t=i)}return t}cloneItemIntoDummy(e,t){let n=e.cloneNode(!0);n.style.width="",n.style.position="static",n.style.left="";let i=document.createElement("div"),r=i.classList;["ag-header-cell","ag-header-group-cell"].some(e=>n.classList.contains(e))?(r.add("ag-header","ag-header-row"),i.style.position="static"):r.add("ag-row");let o=e.parentElement;for(;o;){if(["ag-header-row","ag-row"].some(e=>o.classList.contains(e))){for(let e=0;e<o.classList.length;
376e++){let t=o.classList[e];"ag-row-position-absolute"!=t&&r.add(t)}break}o=o.parentElement}i.appendChild(n),t.appendChild(i)}}]},hh=class extends oI{constructor(e,t,n,i){super(),this.comp=e,this.eResize=t,this.pinned=n,this.columnGroup=i}postConstruct(){if(!this.columnGroup.isResizable())return void this.comp.setResizableDisplayed(!1);let{horizontalResizeSvc:e,gos:t,colAutosize:n}=this.beans,i=e.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});this.addDestroyFunc(i),!t.get("suppressAutoSize")&&n&&this.addDestroyFunc(n.addColumnGroupResize(this.eResize,this.columnGroup,()=>this.resizeLeafColumnsToFit("uiColumnResized")))}onResizeStart(e){let{columnsToResize:t,resizeStartWidth:n,resizeRatios:i,groupAfterColumns:r,groupAfterStartWidth:o,groupAfterRatios:a}=this.getInitialValues(e);this.resizeCols=t,this.resizeStartWidth=n,this.resizeRatios=i,this.resizeTakeFromCols=r,this.resizeTakeFromStartWidth=o,this.resizeTakeFromRatios=a,this.toggleColumnResizing(!0)}onResizing(e,t,n="uiColumnResized"){let i=this.normaliseDragChange(t),r=this.resizeStartWidth+i;this.resizeColumnsFromLocalValues(r,n,e)}getInitialValues(e){let t=e=>e.reduce((e,t)=>e+t.getActualWidth(),0),n=(e,t)=>e.map(e=>e.getActualWidth()/t),i=this.getColumnsToResize(),r=t(i),o=n(i,r),a={columnsToResize:i,resizeStartWidth:r,resizeRatios:o},s=null;if(e&&(s=this.beans.colGroupSvc?.getGroupAtDirection(this.columnGroup,"After")??null),s){let e=a.groupAfterColumns=s.getDisplayedLeafColumns().filter(e=>e.isResizable()),i=a.groupAfterStartWidth=t(e);a.groupAfterRatios=n(e,i)}else a.groupAfterColumns=void 0,a.groupAfterStartWidth=void 0,a.groupAfterRatios=void 0;return a}resizeLeafColumnsToFit(e){let t=this.beans.autoWidthCalc.getPreferredWidthForColumnGroup(this.columnGroup),n=this.getInitialValues();t>n.resizeStartWidth&&this.resizeColumns(n,t,e,!0)}resizeColumnsFromLocalValues(e,t,n=!0){if(!this.resizeCols||!this.resizeRatios)return;let i={columnsToResize:this.resizeCols,resizeStartWidth:this.resizeStartWidth,resizeRatios:this.resizeRatios,groupAfterColumns:this.resizeTakeFromCols,groupAfterStartWidth:this.resizeTakeFromStartWidth,groupAfterRatios:this.resizeTakeFromRatios};this.resizeColumns(i,e,t,n)}resizeColumns(e,t,n,i=!0){let{columnsToResize:r,resizeStartWidth:o,resizeRatios:a,groupAfterColumns:s,groupAfterStartWidth:l,groupAfterRatios:d}=e,u=[];if(u.push({columns:r,ratios:a,width:t}),s){let e=t-o;u.push({columns:s,ratios:d,width:l-e})}this.beans.colResize?.resizeColumnSets({resizeSets:u,finished:i,source:n}),i&&this.toggleColumnResizing(!1)}toggleColumnResizing(e){this.comp.toggleCss("ag-column-resizing",e)}getColumnsToResize(){return this.columnGroup.getDisplayedLeafColumns().filter(e=>e.isResizable())}normaliseDragChange(e){let t=e;return this.gos.get("enableRtl")?"left"!==this.pinned&&(t*=-1):"right"===this.pinned&&(t*=-1),t}destroy(){super.destroy(),this.resizeCols=void 0,this.resizeRatios=void 0,this.resizeTakeFromCols=void 0,this.resizeTakeFromRatios=void 0}},hp=class extends oI{constructor(e,t,n,i,r){super(),this.pinned=e,this.column=t,this.eResize=n,this.comp=i,this.ctrl=r}postConstruct(){let e,t,n=[],i=()=>{if(rZ(this.eResize,e),!e)return;let{horizontalResizeSvc:i,colAutosize:r}=this.beans,o=i.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});n.push(o),t&&r&&n.push(r.addColumnAutosizeListeners(this.eResize,this.column))},r=()=>{for(let e of n)e();n.length=0},o=()=>{let n=this.column.isResizable(),o=!this.gos.get("suppressAutoSize")&&!this.column.getColDef().suppressAutoSize;(n!==e||o!==t)&&(e=n,t=o,r(),i())};
376o(),this.addDestroyFunc(r),this.ctrl.setRefreshFunction("resize",o)}onResizing(e,t){let{column:n,lastResizeAmount:i,resizeStartWidth:r,beans:o}=this,a=this.normaliseResizeAmount(t),{pinnedCols:s,ctrlsSvc:l,colResize:d}=o;if(!(this.column.getPinned()&&(s?.leftWidth??0)+(s?.rightWidth??0)+(a-i)>r1(l.getGridBodyCtrl().eBodyViewport)-50))this.lastResizeAmount=a,d?.setColumnWidths([{key:n,newWidth:r+a}],this.resizeWithShiftKey,e,"uiColumnResized"),e&&this.toggleColumnResizing(!1)}onResizeStart(e){this.resizeStartWidth=this.column.getActualWidth(),this.lastResizeAmount=0,this.resizeWithShiftKey=e,this.toggleColumnResizing(!0)}toggleColumnResizing(e){this.column.resizing=e,this.comp.toggleCss("ag-column-resizing",e)}normaliseResizeAmount(e){let t=e,n="left"!==this.pinned,i="right"===this.pinned;return this.gos.get("enableRtl")?n&&(t*=-1):i&&(t*=-1),t}},hf=class extends oI{constructor(){super(...arguments),this.beanName="colResize"}setColumnWidths(e,t,n,i){let r=[],{colModel:o,gos:a,visibleCols:s}=this.beans;for(let n of e){let e=o.getColDefCol(n.key)||o.getCol(n.key);if(e&&(r.push({width:n.newWidth,ratios:[1],columns:[e]}),"shift"===a.get("colResizeDefault")&&(t=!t),t)){let t=s.getColAfter(e);if(!t)continue;let i=e.getActualWidth()-n.newWidth,o=t.getActualWidth()+i;r.push({width:o,ratios:[1],columns:[t]})}}0!==r.length&&this.resizeColumnSets({resizeSets:r,finished:n,source:i})}resizeColumnSets(e){let{resizeSets:t,finished:n,source:i}=e;if(!(!t||t.every(e=>(function(e){let{columns:t,width:n}=e,i=0,r=0,o=!0;for(let e of t){i+=e.getMinWidth()||0;let t=e.getMaxWidth();t>0?r+=t:o=!1}let a=n>=i,s=!o||n<=r;return a&&s})(e)))){if(n){let e=t&&t.length>0?t[0].columns:null;sc(this.eventSvc,e,n,i)}return}let r=[],o=[];for(let e of t){let{width:t,columns:n,ratios:a}=e,s={},l={};for(let e of n)o.push(e);let d=!0,u=0;for(;d;){if(++u>1e3){an(31);break}d=!1;let e=[],i=0,r=t;n.forEach((t,n)=>{if(l[t.getId()])r-=s[t.getId()];else{e.push(t);let r=a[n];i+=r}});let o=1/i;e.forEach((n,i)=>{let u;i===e.length-1?u=r:(u=Math.round(a[i]*t*o),r-=u);let c=n.getMinWidth(),h=n.getMaxWidth();u<c?(u=c,l[n.getId()]=!0,d=!0):h>0&&u>h&&(u=h,l[n.getId()]=!0,d=!0),s[n.getId()]=u})}for(let e of n){let t=s[e.getId()];e.getActualWidth()!==t&&(e.setActualWidth(t,i),r.push(e))}}let a=r.length>0,s=[];if(a){let{colFlex:e,visibleCols:t,colViewport:n}=this.beans;s=e?.refreshFlexedColumns({resizingCols:o,skipSetLeft:!0})??[],t.setLeftValues(i),t.updateBodyWidths(),n.checkViewportColumns()}let l=o.concat(s);(a||n)&&sc(this.eventSvc,l,n,i,s)}resizeHeader(e,t,n){if(!e.isResizable())return;let i=Math.min(Math.max(e.getActualWidth()+t,e.getMinWidth()),e.getMaxWidth());this.setColumnWidths([{key:e,newWidth:i}],n,!0,"uiColumnResized")}createResizeFeature(e,t,n,i,r){return new hp(e,t,n,i,r)}createGroupResizeFeature(e,t,n,i){return new hh(e,t,n,i)}},hg=class extends oI{constructor(e,t){super(),this.removeChildListenersFuncs=[],this.columnGroup=t,this.comp=e}postConstruct(){this.addListenersToChildrenColumns(),this.addManagedListeners(this.columnGroup,{displayedChildrenChanged:this.onDisplayedChildrenChanged.bind(this)}),this.onWidthChanged(),this.addDestroyFunc(this.removeListenersOnChildrenColumns.bind(this))}addListenersToChildrenColumns(){this.removeListenersOnChildrenColumns();let e=this.onWidthChanged.bind(this);for(let t of this.columnGroup.getLeafColumns())t.__addEventListener("widthChanged",e),t.__addEventListener("visibleChanged",e),this.removeChildListenersFuncs.push(()=>{t.__removeEventListener("widthChanged",e),t.__removeEventListener("visibleChanged",e)})}removeListenersOnChildrenColumns(){for(let e of this.removeChildListenersFuncs)e();this.removeChildListenersFuncs=[]}onDisplayedChildrenChanged(){this.addListenersToChildrenColumns(),this.onWidthChanged()}onWidthChanged(){let e=this.columnGroup.getActualWidth();this.comp.setWidth(`${e}px`),this.comp.toggleCss("ag-hidden",0===e)}},hm=class extends ci{constructor(){super(...arguments),this.onSuppressColMoveChange=()=>{!this.isAlive()||this.isSuppressMoving()?this.removeDragSource():this.dragSource||this.setDragSource(this.eGui)}}
376wireComp(e,t,n,i,r){let{column:o,beans:a}=this,{context:s,colNames:l,colHover:d,rangeSvc:u,colResize:c}=a;this.comp=e,r=sx(this,s,r),this.setGui(t,r),this.displayName=l.getDisplayNameForColumnGroup(o,"header"),this.refreshHeaderStyles(),this.addClasses(),this.setupMovingCss(r),this.setupExpandable(r),this.setupTooltip(),this.setupAutoHeight({wrapperElement:i,compBean:r}),this.setupUserComp(),this.addHeaderMouseListeners(r),this.addManagedPropertyListener("groupHeaderHeight",this.refreshMaxHeaderHeight.bind(this)),this.refreshMaxHeaderHeight();let h=this.rowCtrl.pinned,p=o.getProvidedColumnGroup().getLeafColumns();d?.createHoverFeature(r,p,t),u?.createRangeHighlightFeature(r,o,e),r.createManagedBean(new ce(o,t,a)),r.createManagedBean(new hg(e,o)),c?this.resizeFeature=r.createManagedBean(c.createGroupResizeFeature(e,n,h,o)):e.setResizableDisplayed(!1),r.createManagedBean(new us(t,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:()=>void 0,handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)})),this.addHighlightListeners(r,p),r.addManagedPropertyListener("suppressMovableColumns",this.onSuppressColMoveChange),this.addResizeAndMoveKeyboardListeners(r),r.addDestroyFunc(()=>this.clearComponent())}getHeaderClassParams(){let{column:e,beans:t}=this,n=e.getDefinition();return aN(t.gos,{colDef:n,columnGroup:e,floatingFilter:!1})}refreshMaxHeaderHeight(){let{gos:e,comp:t}=this,n=e.get("groupHeaderHeight");null!=n?0===n?t.setHeaderWrapperHidden(!0):t.setHeaderWrapperMaxHeight(n):(t.setHeaderWrapperHidden(!1),t.setHeaderWrapperMaxHeight(null))}addHighlightListeners(e,t){if(this.beans.gos.get("suppressMoveWhenColumnDragging"))for(let n of t)e.addManagedListeners(n,{headerHighlightChanged:this.onLeafColumnHighlightChanged.bind(this,n)})}onLeafColumnHighlightChanged(e){let t=this.column.getDisplayedLeafColumns(),n=t[0]===e,i=aY(t)===e;if(!n&&!i)return;let r=e.getHighlighted(),o=!!this.rowCtrl.getHeaderCellCtrls().find(e=>e.column.isMoving()),a=!1,s=!1;if(o){let e=this.beans.gos.get("enableRtl"),t=1===r,o=0===r;n&&(e?s=t:a=o),i&&(e?a=o:s=t)}this.comp.toggleCss("ag-header-highlight-before",a),this.comp.toggleCss("ag-header-highlight-after",s)}resizeHeader(e,t){let{resizeFeature:n}=this;if(!n)return;let i=n.getInitialValues(t);n.resizeColumns(i,i.resizeStartWidth+e,"uiColumnResized",!0)}resizeLeafColumnsToFit(e){this.resizeFeature?.resizeLeafColumnsToFit(e)}setupUserComp(){let e,{colGroupSvc:t,userCompFactory:n,gos:i,enterpriseMenuFactory:r}=this.beans,o=this.column,a=o.getProvidedColumnGroup(),s=aN(i,{displayName:this.displayName,columnGroup:o,setExpanded:e=>{t.setColumnGroupOpened(a,e,"gridInitializing")},setTooltip:(e,t)=>{i.assertModuleRegistered("Tooltip",3),this.setupTooltip(e,t)},showColumnMenu:(e,t)=>r?.showMenuAfterButtonClick(a,e,"columnMenu",t),showColumnMenuAfterMouseClick:(e,t)=>r?.showMenuAfterMouseEvent(a,e,"columnMenu",t),eGridHeader:this.eGui}),l=(e=s.columnGroup.getColGroupDef(),n.getCompDetails(e,sF,"agColumnGroupHeader",s));l&&this.comp.setUserCompDetails(l)}addHeaderMouseListeners(e){let t=e=>this.handleMouseOverChange("mouseenter"===e.type),n=()=>this.dispatchColumnMouseEvent("columnHeaderClicked",this.column.getProvidedColumnGroup()),i=e=>this.handleContextMenuMouseEvent(e,void 0,this.column.getProvidedColumnGroup());e.addManagedListeners(this.eGui,{mouseenter:t,mouseleave:t,click:n,contextmenu:i})}handleMouseOverChange(e){this.eventSvc.dispatchEvent({type:e?"columnHeaderMouseOver":"columnHeaderMouseLeave",column:this.column.getProvidedColumnGroup()})}setupTooltip(e,t){this.tooltipFeature=this.beans.tooltipSvc?.setupHeaderGroupTooltip(this.tooltipFeature,this,e,t)}setupExpandable(e){let t=this.column.getProvidedColumnGroup();this.refreshExpanded();let n=this.refreshExpanded.bind(this);e.addManagedListeners(t,{expandedChanged:n,expandableChanged:n})}refreshExpanded(){let{column:e}=this;this.expandable=e.isExpandable();let t=e.isExpanded();this.expandable?this.comp.setAriaExpanded(t?"true":"false"):this.comp.setAriaExpanded(void 0),this.refreshHeaderStyles()}addClasses(){let{column:e}=this,t=e.getColGroupDef(),n=uJ(t,this.gos,null,e);for(let i of(e.isPadding()?(n.push("ag-header-group-cell-no-group"),e.getLeafColumns().every(e=>e.isSpanHeaderHeight())&&n.push("ag-header-span-height")):(n.push("ag-header-group-cell-with-group"),t?.wrapHeaderText&&n.push("ag-header-cell-wrap-text")),n))this.comp.toggleCss(i,!0)}
376setupMovingCss(e){let{column:t}=this,n=t.getProvidedColumnGroup().getLeafColumns(),i=()=>this.comp.toggleCss("ag-header-cell-moving",t.isMoving());for(let t of n)e.addManagedListeners(t,{movingChanged:i});i()}onFocusIn(e){this.eGui.contains(e.relatedTarget)||this.focusThis()}handleKeyDown(e){super.handleKeyDown(e);let t=this.getWrapperHasFocus();if(this.expandable&&t&&e.key===sJ){let e=this.column,t=!e.isExpanded();this.beans.colGroupSvc.setColumnGroupOpened(e.getProvidedColumnGroup(),t,"uiColumnExpanded")}}setDragSource(e){!this.isAlive()||this.isSuppressMoving()||(this.removeDragSource(),e&&(this.dragSource=this.beans.colMoves?.setDragSourceForHeader(e,this.column,this.displayName)??null))}isSuppressMoving(){return this.gos.get("suppressMovableColumns")||this.column.getLeafColumns().some(e=>e.getColDef().suppressMovable||e.getColDef().lockPosition)}destroy(){this.tooltipFeature=this.destroyBean(this.tooltipFeature),super.destroy()}},hv=class extends oI{constructor(){super(...arguments),this.beanName="visibleCols",this.colsAndGroupsMap={},this.leftCols=[],this.rightCols=[],this.centerCols=[],this.allCols=[],this.headerGroupRowCount=0,this.bodyWidth=0,this.leftWidth=0,this.rightWidth=0,this.isBodyWidthDirty=!0}refresh(e,t=!1){let{colFlex:n,colModel:i,colGroupSvc:r,colViewport:o,selectionColSvc:a}=this.beans;t||this.buildTrees(i,r),r?.updateOpenClosedVisibility(),this.leftCols=hb(this.treeLeft),this.centerCols=hb(this.treeCenter),this.rightCols=hb(this.treeRight),a?.refreshVisibility(this.leftCols,this.centerCols,this.rightCols),this.joinColsAriaOrder(i),this.joinCols(),this.headerGroupRowCount=this.getHeaderRowCount(),this.setLeftValues(e),this.autoHeightCols=this.allCols.filter(e=>e.isAutoHeight()),n?.refreshFlexedColumns(),this.updateBodyWidths(),this.setFirstRightAndLastLeftPinned(i,this.leftCols,this.rightCols,e),o.checkViewportColumns(!1),this.eventSvc.dispatchEvent({type:"displayedColumnsChanged",source:e})}getHeaderRowCount(){if(!this.gos.get("hidePaddedHeaderRows"))return this.beans.colModel.cols.treeDepth;let e=0;for(let t of this.allCols){let n=t.getParent();for(;n;){if(!n.isPadding()){let t=n.getProvidedColumnGroup().getLevel()+1;t>e&&(e=t);break}n=n.getParent()}}return e}updateBodyWidths(){let e=a5(this.centerCols),t=a5(this.leftCols),n=a5(this.rightCols);this.isBodyWidthDirty=this.bodyWidth!==e,(this.bodyWidth!==e||this.leftWidth!==t||this.rightWidth!==n)&&(this.bodyWidth=e,this.leftWidth=t,this.rightWidth=n,this.eventSvc.dispatchEvent({type:"columnContainerWidthChanged"}),this.eventSvc.dispatchEvent({type:"displayedColumnsWidthChanged"}))}setLeftValues(e){this.setLeftValuesOfCols(e),this.setLeftValuesOfGroups()}setFirstRightAndLastLeftPinned(e,t,n,i){let r,o;for(let a of(this.gos.get("enableRtl")?(r=t?t[0]:null,o=n?aY(n):null):(r=t?aY(t):null,o=n?n[0]:null),e.getCols()))a.setLastLeftPinned(a===r,i),a.setFirstRightPinned(a===o,i)}buildTrees(e,t){let n=e.getColsToShow(),i=n.filter(e=>"left"==e.getPinned()),r=n.filter(e=>"right"==e.getPinned()),o=n.filter(e=>"left"!=e.getPinned()&&"right"!=e.getPinned()),a=new sy,s=e=>t?t.createColumnGroups(e):e.columns;this.treeLeft=s({columns:i,idCreator:a,pinned:"left",oldDisplayedGroups:this.treeLeft}),this.treeRight=s({columns:r,idCreator:a,pinned:"right",oldDisplayedGroups:this.treeRight}),this.treeCenter=s({columns:o,idCreator:a,pinned:null,oldDisplayedGroups:this.treeCenter}),this.updateColsAndGroupsMap()}clear(){this.leftCols=[],this.rightCols=[],this.centerCols=[],this.allCols=[],this.ariaOrderColumns=[]}joinColsAriaOrder(e){let t=e.getCols(),n=[],i=[],r=[];for(let e of t){let t=e.getPinned();t?!0===t||"left"===t?n.push(e):r.push(e):i.push(e)}this.ariaOrderColumns=n.concat(i).concat(r)}getAriaColIndex(e){let t;return t=dL(e)?e.getLeafColumns()[0]:e,this.ariaOrderColumns.indexOf(t)+1}setLeftValuesOfGroups(){for(let e of[this.treeLeft,this.treeRight,this.treeCenter])for(let t of e)dL(t)&&t.checkLeft()}setLeftValuesOfCols(e){let{colModel:t}=this.beans;if(!t.getColDefCols())return;let n=t.getCols().slice(0),i=this.gos.get("enableRtl");for(let t of[this.leftCols,this.rightCols,this.centerCols]){if(i){let n=a5(t);for(let i of t)n-=i.getActualWidth(),i.setLeft(n,e)}else{let n=0;for(let i of t)i.setLeft(n,e),n+=i.getActualWidth()}for(let e=0;e<t.length;e++){let i=n.indexOf(t[e]);i>=0&&(n[i]=n[n.length-1],n.pop())}}for(let t of n)t.setLeft(null,e)}joinCols(){this.gos.get("enableRtl")?this.allCols=this.rightCols.concat(this.centerCols).concat(this.leftCols):this.allCols=this.leftCols.concat(this.centerCols).concat(this.rightCols)}getAllTrees(){return this.treeLeft&&this.treeRight&&this.treeCenter?this.treeLeft.concat(this.treeCenter).concat(this.treeRight):null}isColDisplayed(e){return this.allCols.indexOf(e)>=0}getLeftColsForRow(e){let{leftCols:t,beans:{colModel:n}}=this;return n.colSpanActive?this.getColsForRow(e,t):t}getRightColsForRow(e){let{rightCols:t,beans:{colModel:n}}=this;return n.colSpanActive?this.getColsForRow(e,t):t}getColsForRow(e,t,n,i){let r=[],o=null;for(let a=0;a<t.length;a++){let s,l=t[a],d=t.length-a,u=Math.min(l.getColSpan(e),d),c=[l];if(u>1){let e=u-1;for(let n=1;n<=e;n++)c.push(t[a+n]);a+=e}if(n)for(let e of(s=!1,c))n(e)&&(s=!0);else s=!0;s&&(0===r.length&&o&&i&&i(l)&&r.push(o),r.push(l)),o=l}return r}getContainerWidth(e){switch(e){case"left":return this.leftWidth;case"right":return this.rightWidth;default:return this.bodyWidth}}getColBefore(e){let t=this.allCols,n=t.indexOf(e);return n>0?t[n-1]:null}isPinningLeft(){return this.leftCols.length>0}isPinningRight(){return this.rightCols.length>0}updateColsAndGroupsMap(){this.colsAndGroupsMap={};let e=e=>{this.colsAndGroupsMap[e.getUniqueId()]=e};hy(this.treeCenter,!1,e),hy(this.treeLeft,!1,e),hy(this.treeRight,!1,e)}isVisible(e){return this.colsAndGroupsMap[e.getUniqueId()]===e}getFirstColumn(){let e=this.gos.get("enableRtl"),t=["leftCols","centerCols","rightCols"];e&&t.reverse();for(let n=0;n<t.length;n++){let i=this[t[n]];if(i.length)return e?aY(i):i[0]}return null}getColAfter(e){let t=this.allCols,n=t.indexOf(e);return n<t.length-1?t[n+1]:null}getColsLeftWidth(){return a5(this.leftCols)}getDisplayedColumnsRightWidth(){return a5(this.rightCols)}isColAtEdge(e,t){let n,i=this.allCols;if(!i.length)return!1;let r="first"===t;if(dL(e)){let t=e.getDisplayedLeafColumns();if(!t.length)return!1;n=r?t[0]:aY(t)}else n=e;return(r?i[0]:aY(i))===n}};function hy(e,t,n){if(e)for(let i=0;i<e.length;i++){let r=e[i];dL(r)&&hy(t?r.getDisplayedChildren():r.getChildren(),t,n),n(r)}}function hb(e){let t=[];return hy(e,!0,e=>{aH(e)&&t.push(e)}),t}var hx=class extends oI{constructor(){super(...arguments),this.beanName="
376colGroupSvc"}getColumnGroupState(){let e=[];return sa(null,this.beans.colModel.getColTree(),t=>{aW(t)&&e.push({groupId:t.getGroupId(),open:t.isExpanded()})}),e}resetColumnGroupState(e){let t=this.beans.colModel.getColDefColTree();if(!t)return;let n=[];sa(null,t,e=>{if(aW(e)){let t=e.getColGroupDef(),i={groupId:e.getGroupId(),open:t?t.openByDefault:void 0};n.push(i)}}),this.setColumnGroupState(n,e)}setColumnGroupState(e,t){let{colModel:n,colAnimation:i,visibleCols:r,eventSvc:o}=this.beans;if(!n.getColTree().length)return;i?.start();let a=[];for(let t of e){let e=t.groupId,n=t.open,i=this.getProvidedColGroup(e);i&&i.isExpanded()!==n&&(i.setExpanded(n),a.push(i))}r.refresh(t,!0),a.length&&o.dispatchEvent({type:"columnGroupOpened",columnGroup:1===a.length?a[0]:void 0,columnGroups:a}),i?.finish()}setColumnGroupOpened(e,t,n){let i;i=aW(e)?e.getId():e||"",this.setColumnGroupState([{groupId:i,open:t}],n)}getProvidedColGroup(e){let t=null;return sa(null,this.beans.colModel.getColTree(),n=>{aW(n)&&n.getId()===e&&(t=n)}),t}getGroupAtDirection(e,t){let n=e.getProvidedColumnGroup().getLevel()+e.getPaddingLevel(),i=e.getDisplayedLeafColumns(),r="After"===t?aY(i):i[0],o=`getCol${t}`;for(;;){let t=this.beans.visibleCols[o](r);if(!t)return null;let i=this.getColGroupAtLevel(t,n);if(i!==e)return i}}getColGroupAtLevel(e,t){let n=e.getParent();for(;!(n.getProvidedColumnGroup().getLevel()+n.getPaddingLevel()<=t);)n=n.getParent();return n}updateOpenClosedVisibility(){hy(this.beans.visibleCols.getAllTrees(),!1,e=>{dL(e)&&e.calculateDisplayedColumns()})}getColumnGroup(e,t){if(!e)return null;if(dL(e))return e;let n=this.beans.visibleCols.getAllTrees(),i="number"==typeof t,r=null;return hy(n,!1,n=>{dL(n)&&(i?e===n.getGroupId()&&t===n.getPartId():e===n.getGroupId())&&(r=n)}),r}createColumnGroups(e){let{columns:t,idCreator:n,pinned:i,oldDisplayedGroups:r,isStandaloneStructure:o}=e,a=this.mapOldGroupsById(r),s=[],l=t;for(;l.length;){let e=l;l=[];let t=0,r=r=>{let d=t;t=r;let u=e[d],c=(dL(u)?u.getProvidedColumnGroup():u).getOriginalParent();if(null==c){for(let t=d;t<r;t++)s.push(e[t]);return}let h=this.createColumnGroup(c,n,a,i,o);for(let t=d;t<r;t++)h.addChild(e[t]);l.push(h)};for(let n=1;n<e.length;n++){let i=e[n],o=(dL(i)?i.getProvidedColumnGroup():i).getOriginalParent(),a=e[t];o!==(dL(a)?a.getProvidedColumnGroup():a).getOriginalParent()&&r(n)}t<e.length&&r(e.length)}return o||this.setupParentsIntoCols(s,null),s}createProvidedColumnGroup(e,t,n,i,r,o,a){let s=r.getUniqueKey(t.groupId||null,null),l=aq(this.beans,t,s),d=new a$(l,s,!1,n);this.createBean(d);let u=this.findExistingGroup(t,o);u&&o.splice(u.idx,1);let c=u?.group;c&&d.setExpanded(c.isExpanded());let h=si(this.beans,l.children,n+1,e,i,r,o,a);return d.setChildren(h),d}balanceColumnTree(e,t,n,i){let r=[];for(let o=0;o<e.length;o++){let a=e[o];if(aW(a)){let e=this.balanceColumnTree(a.getChildren(),t+1,n,i);a.setChildren(e),r.push(a)}else{let o,s;for(let e=t;e<n;e++){let t=i.getUniqueKey(null,null),n=new a$(aq(this.beans,null,t),t,!0,e);this.createBean(n),s&&s.setChildren([n]),s=n,o||(o=s)}if(o&&s){if(r.push(o),e.some(e=>aW(e))){s.setChildren([a]);continue}s.setChildren(e);break}r.push(a)}}return r}findDepth(e){let t=0,n=e;for(;n?.[0]&&aW(n[0]);)t++,n=n[0].getChildren();return t}findMaxDepth(e,t){let n=t;for(let i=0;i<e.length;i++){let r=e[i];if(aW(r)){let e=this.findMaxDepth(r.getChildren(),t+1);n<e&&(n=e)}}return n}balanceTreeForAutoCols(e,t){let n=[];for(let i of e){let e=i;for(let n=t-1;n>=0;n--){let t=new a$(null,`FAKE_PATH_${i.getId()}}_${n}`,!0,n);this.createBean(t),t.setChildren([e]),e.originalParent=t,e=t}0===t&&(i.originalParent=null),n.push(e)}return n}findExistingGroup(e,t){if(null!=e.groupId)for(let n=0;n<t.length;n++){let i=t[n];if(i.getColGroupDef()&&i.getId()===e.groupId)return{idx:n,group:i}}}createColumnGroup(e,t,n,i,r){let o=e.getGroupId(),a=t.getInstanceIdForKey(o),s=n[o+"_"+a];return s&&s.getProvidedColumnGroup()!==e&&(s=null),rC(s)?s.reset():(s=new dF(e,o,a,i),r||this.createBean(s)),s}mapOldGroupsById(e){let t={},n=e=>{for(let i of e)dL(i)&&(t[i.getUniqueId()]=i,n(i.getChildren()))};return e&&n(e),t}setupParentsIntoCols(e,t){for(let n of e??[])n.parent!==t&&(this.beans.colViewport.colsWithinViewportHash=""),n.parent=t,dL(n)&&this.setupParentsIntoCols(n.getChildren(),n)}},hw={tag:"div",cls:"ag-skeleton-container"},hC=class extends sk{constructor(){super(hw)}init(e){let t=`ag-cell-skeleton-renderer-${this.getCompId()}`;this.getGui().setAttribute("id",t),this.addDestroyFunc(()=>rV(e.eParentOfValue)),rV(e.eParentOfValue,t),e.deferRender?this.setupLoading(e):e.node.failedLoad?this.setupFailed():this.setupLoading(e)}setupFailed(){let e=this.getLocaleTextFunc();this.getGui().textContent=e("loadingError","ERR");let t=e("ariaSkeletonCellLoadingFailed","Row failed to load");rj(this.getGui(),t)}setupLoading(e){let t=om({tag:"div",cls:"ag-skeleton-effect"}),n=e.node.rowIndex;if(null!=n){let e=75+25*(n%2==0?Math.sin(n):Math.cos(n));t.style.width=`${e}%`}this.getGui().appendChild(t);let i=this.getLocaleTextFunc(),r=e.deferRender?i("ariaDeferSkeletonCellLoading","Cell is loading"):i("ariaSkeletonCellLoading","Row data is loading");rj(this.getGui(),r)}refresh(e){return!1}};function hS(e,t){if(!e)return;let n={};for(let i of Object.keys(e)){if(t&&t.indexOf(i)>=0||oB.has(i))continue;let r=e[i];"object"==typeof r&&null!==r&&r.constructor===Object?n[i]=hS(r):n[i]=r}return n}var h_=class extends oI{constructor(){super(...arguments),this.beanName="
376colDefFactory"}wireBeans(e){this.rowGroupColsSvc=e.rowGroupColsSvc,this.pivotColsSvc=e.pivotColsSvc}getColumnDefs(e,t,n,i,r=!1){let o=e.slice();t?o.sort((e,t)=>n.indexOf(e)-n.indexOf(t)):(n||r)&&o.sort((e,t)=>i.indexOf(e)-i.indexOf(t));let a=this.rowGroupColsSvc?.columns,s=this.pivotColsSvc?.columns;return this.buildColumnDefs(o,a,s)}buildColumnDefs(e,t=[],n=[]){let i=[],r={};for(let o of e){let e=this.createDefFromColumn(o,t,n),a=!0,s=e,l=o.getOriginalParent(),d=null;for(;l;){let e=null;if(l.isPadding()){l=l.getOriginalParent();continue}let t=r[l.getGroupId()];if(t){t.children.push(s),a=!1;break}if((e=this.createDefFromGroup(l))&&(e.children=[s],r[e.groupId]=e,s=e,l=l.getOriginalParent()),null!=l&&d===l){a=!1;break}d=l}a&&i.push(s)}return i}createDefFromGroup(e){let t=hS(e.getColGroupDef(),["children"]);return t&&(t.groupId=e.getGroupId()),t}createDefFromColumn(e,t,n){let i=hS(e.getColDef());return i.colId=e.getColId(),i.width=e.getActualWidth(),i.rowGroup=e.isRowGroupActive(),i.rowGroupIndex=e.isRowGroupActive()?t.indexOf(e):null,i.pivot=e.isPivotActive(),i.pivotIndex=e.isPivotActive()?n.indexOf(e):null,i.aggFunc=e.isValueActive()?e.getAggFunc():null,i.hide=!e.isVisible()||void 0,i.pinned=e.isPinned()?e.getPinned():null,i.sort=e.getSort()?e.getSort():null,i.sortIndex=null!=e.getSortIndex()?e.getSortIndex():null,i}},hk=class extends oI{constructor(){super(...arguments),this.beanName="colFlex",this.columnsHidden=!1}refreshFlexedColumns(e={}){let t=e.source??"flex";null!=e.viewportWidth&&(this.flexViewportWidth=e.viewportWidth);let n=this.flexViewportWidth,{visibleCols:i,colDelayRenderSvc:r}=this.beans,o=i.centerCols,a=-1;if(e.resizingCols){let t=new Set(e.resizingCols);for(let e=o.length-1;e>=0;e--)if(t.has(o[e])){a=e;break}}let s=!1,l=o.map((e,t)=>{let n=e.getFlex(),i=null!=n&&n>0&&t>a;return s||(s=i),{col:e,isFlex:i,flex:Math.max(0,n??0),initialSize:e.getActualWidth(),min:e.getMinWidth(),max:e.getMaxWidth(),targetSize:0}});if(s?(r?.hideColumns("colFlex"),this.columnsHidden=!0):this.columnsHidden&&this.revealColumns(r),!n||!s)return[];let d=l.length,u=l.reduce((e,t)=>e+t.flex,0),c=n,h=(e,n)=>{e.frozenSize=n,e.col.setActualWidth(n,t),c-=n,u-=e.flex,d-=1},p=e=>null!=e.frozenSize;for(let e of l)e.isFlex||h(e,e.initialSize);for(;d>0;){let e,t=Math.round(u<1?c*u:c),n=0,i=0;for(let r of l){if(p(r))continue;e=r;let o=Math.round((i+=t*(r.flex/u))-n);r.targetSize=o,n+=o}e&&(e.targetSize+=t-n);let r=0;for(let e of l){if(p(e))continue;let t=e.targetSize,n=Math.min(Math.max(t,e.min),e.max);r+=n-t,e.violationType=n===t?void 0:n<t?"max":"min",e.targetSize=n}let o=0===r?"all":r>0?"min":"max";for(let e of l)p(e)||("all"===o||e.violationType===o)&&h(e,e.targetSize)}e.skipSetLeft||i.setLeftValues(t),e.updateBodyWidths&&i.updateBodyWidths();let f=l.filter(e=>e.isFlex&&!e.violationType).map(e=>e.col);if(e.fireResizedEvent){let e=l.filter(e=>e.initialSize!==e.frozenSize).map(e=>e.col),n=l.filter(e=>e.flex).map(e=>e.col);sc(this.eventSvc,e,!0,t,n)}return this.revealColumns(r),f}revealColumns(e){this.columnsHidden&&(e?.revealColumns("colFlex"),this.columnsHidden=!1)}initCol(e){let{flex:t,initialFlex:n}=e.colDef;void 0!==t?e.flex=t:void 0!==n&&(e.flex=n)}setColFlex(e,t){e.flex=t??null,e.dispatchStateUpdatedEvent("flex")}};function hM(e,t,n){if(!t||!e)return;if(!n)return e[t];let i=t.split("."),r=e;for(let e=0;e<i.length;e++){if(null==r)return;r=r[i[e]]}return r}var hT=["dateTimeString","dateString","text","number","boolean","date"],hD=class extends oI{constructor(){super(...arguments),this.beanName="dataTypeSvc",this.dataTypeDefinitions={},this.isPendingInference=!1,this.isColumnTypeOverrideInDataTypeDefinitions=!1,this.columnStateUpdatesPendingInference={},this.columnStateUpdateListenerDestroyFuncs=[],this.columnDefinitionPropsPerDataType={number:()=>({cellEditor:"agNumberCellEditor"}),boolean:()=>({cellEditor:"agCheckboxCellEditor",cellRenderer:"agCheckboxCellRenderer",getFindText:()=>null,suppressKeyboardEvent:e=>!!e.colDef.editable&&" "===e.event.key}),date:({formatValue:e})=>({cellEditor:"agDateCellEditor",keyCreator:e}),dateString:({formatValue:e})=>
376({cellEditor:"agDateStringCellEditor",keyCreator:e}),dateTime(e){return this.date(e)},dateTimeString(e){return this.dateString(e)},object:({formatValue:e,colModel:t,colId:n})=>({cellEditorParams:{useFormatter:!0},comparator:(i,r)=>{let o=t.getColDefCol(n),a=o?.getColDef();if(!o||!a)return 0;let s=null==i?"":e({column:o,node:null,value:i}),l=null==r?"":e({column:o,node:null,value:r});return s===l?0:s>l?1:-1},keyCreator:e}),text:()=>({})}}wireBeans(e){this.colModel=e.colModel}postConstruct(){this.processDataTypeDefinitions(),this.addManagedPropertyListener("dataTypeDefinitions",e=>{this.processDataTypeDefinitions(),this.colModel.recreateColumnDefs(e)})}processDataTypeDefinitions(){let e=this.getDefaultDataTypes(),t={},n={},i=e=>t=>{let{column:n,node:i,value:r}=t,o=n.getColDef().valueFormatter;return o===e.groupSafeValueFormatter&&(o=e.valueFormatter),this.beans.valueSvc.formatValue(n,i,r,o)};for(let r of Object.keys(e)){let o=e[r],a={...o,groupSafeValueFormatter:hA(o,this.gos)};t[r]=a,n[r]=i(a)}let r=this.gos.get("dataTypeDefinitions")??{},o={};for(let a of Object.keys(r)){let s=r[a],l=this.processDataTypeDefinition(s,r,[a],e);l&&(t[a]=l,s.dataTypeMatcher&&(o[a]=s.dataTypeMatcher),n[a]=i(l))}let{valueParser:a,valueFormatter:s}=e.object,{valueParser:l,valueFormatter:d}=t.object;this.hasObjectValueParser=l!==a,this.hasObjectValueFormatter=d!==s,this.formatValueFuncs=n,this.dataTypeDefinitions=t,this.dataTypeMatchers=this.sortKeysInMatchers(o,e)}sortKeysInMatchers(e,t){let n={...e};for(let i of hT)delete n[i],n[i]=e[i]??t[i].dataTypeMatcher;return n}processDataTypeDefinition(e,t,n,i){let r,o=e.extendsDataType;if(e.columnTypes&&(this.isColumnTypeOverrideInDataTypeDefinitions=!0),e.extendsDataType===e.baseDataType){let n=i[o],a=t[o];if(n&&a&&(n=a),!hI(e,n,o))return;r=hR(n,e)}else{if(n.includes(o))return void at(44);let a=t[o];if(!hI(e,a,o))return;let s=this.processDataTypeDefinition(a,t,[...n,o],i);if(!s)return;r=hR(s,e)}return{...r,groupSafeValueFormatter:hA(r,this.gos)}}updateColDefAndGetColumnType(e,t,n){let{cellDataType:i}=t,{field:r}=t;if(void 0===i&&(i=e.cellDataType),(null==i||!0===i)&&(i=!!this.canInferCellDataType(e,t)&&this.inferCellDataType(r,n)),!i){e.cellDataType=!1;return}let o=this.dataTypeDefinitions[i];return o?(e.cellDataType=i,o.groupSafeValueFormatter&&(e.valueFormatter=o.groupSafeValueFormatter),o.valueParser&&(e.valueParser=o.valueParser),o.suppressDefaultProperties||this.setColDefPropertiesForBaseDataType(e,i,o,n),o.columnTypes):void at(47,{cellDataType:i})}addColumnListeners(e){if(!this.isPendingInference)return;let t=this.columnStateUpdatesPendingInference[e.getColId()];if(!t)return;let n=e=>{t.add(e.key)};e.__addEventListener("columnStateUpdated",n),this.columnStateUpdateListenerDestroyFuncs.push(()=>e.__removeEventListener("columnStateUpdated",n))}canInferCellDataType(e,t){let{gos:n}=this;if(!aa(n))return!1;let i={cellRenderer:!0,valueGetter:!0,valueParser:!0,refData:!0}
376;if(hP(t,i))return!1;let r=null===t.type?e.type:t.type;if(r){let e=n.get("columnTypes")??{};if(a9(r).some(t=>{let n=e[t.trim()];return n&&hP(n,i)}))return!1}return!hP(e,i)}inferCellDataType(e,t){let n;if(!e)return;let i=this.getInitialData();if(i){let t=e.includes(".")&&!this.gos.get("suppressFieldDotNotation");n=hM(i,e,t)}else this.initWaitForRowData(t);if(null!=n)return Object.keys(this.dataTypeMatchers).find(e=>this.dataTypeMatchers[e](n))??"object"}getInitialData(){let e=this.gos.get("rowData");if(e?.length)return e[0];{if(this.initialData)return this.initialData;let e=this.beans.rowModel.rootNode?._leafs;if(e?.length)return e[0].data}return null}initWaitForRowData(e){if(this.columnStateUpdatesPendingInference[e]=new Set,this.isPendingInference)return;this.isPendingInference=!0;let t=this.isColumnTypeOverrideInDataTypeDefinitions,{colAutosize:n,eventSvc:i}=this.beans;t&&n&&(n.shouldQueueResizeOperations=!0);let[r]=this.addManagedEventListeners({rowDataUpdateStarted:e=>{let{firstRowData:o}=e;o&&(r?.(),this.isPendingInference=!1,this.processColumnsPendingInference(o,t),this.columnStateUpdatesPendingInference={},t&&n?.processResizeOperations(),i.dispatchEvent({type:"dataTypesInferred"}))}})}processColumnsPendingInference(e,t){this.initialData=e;let n=[];this.destroyColumnStateUpdateListeners();let i={},r={};for(let e of Object.keys(this.columnStateUpdatesPendingInference)){let o=this.columnStateUpdatesPendingInference[e],a=this.colModel.getCol(e);if(!a)return;let s=a.getColDef();if(!this.resetColDefIntoCol(a,"cellDataTypeInferred"))return;let l=a.getColDef();if(t&&l.type&&l.type!==s.type){let t=function(e,t){let n=sg(e);for(let e of t)delete n[e],"rowGroup"===e?delete n.rowGroupIndex:"pivot"===e&&delete n.pivotIndex;return n}(a,o);t.rowGroup&&null==t.rowGroupIndex&&(i[e]=t),t.pivot&&null==t.pivotIndex&&(r[e]=t),n.push(t)}}t&&n.push(...this.generateColumnStateForRowGroupAndPivotIndexes(i,r)),n.length&&sh(this.beans,{state:n},"cellDataTypeInferred"),this.initialData=null}generateColumnStateForRowGroupAndPivotIndexes(e,t){let n={},{rowGroupColsSvc:i,pivotColsSvc:r}=this.beans;return i?.restoreColumnOrder(n,e),r?.restoreColumnOrder(n,t),Object.values(n)}resetColDefIntoCol(e,t){let n=e.getUserProvidedColDef();if(!n)return!1;let i=so(this.beans,n,e.getColId());return e.setColDef(i,n,t),!0}getDateStringTypeDefinition(e){let{dateString:t}=this.dataTypeDefinitions;return e?this.getDataTypeDefinition(e)??t:t}getDateParserFunction(e){return this.getDateStringTypeDefinition(e).dateParser}getDateFormatterFunction(e){return this.getDateStringTypeDefinition(e).dateFormatter}getDateIncludesTimeFlag(e){return"dateTime"===e||"dateTimeString"===e}getDataTypeDefinition(e){let t=e.getColDef();if(t.cellDataType)return this.dataTypeDefinitions[t.cellDataType]}getBaseDataType(e){return this.getDataTypeDefinition(e)?.baseDataType}checkType(e,t){if(null==t)return!0;let n=this.getDataTypeDefinition(e)?.dataTypeMatcher;return!n||n(t)}validateColDef(e){let t=e=>at(48,{property:e});if("object"===e.cellDataType){let{object:n}=this.dataTypeDefinitions;e.valueFormatter!==n.groupSafeValueFormatter||this.hasObjectValueFormatter||t("Formatter"),e.editable&&e.valueParser===n.valueParser&&!this.hasObjectValueParser&&t("Parser")}}postProcess(e){let t=e.cellDataType;if(!t||"string"!=typeof t)return;let{dataTypeDefinitions:n,beans:i,formatValueFuncs:r}=this,o=n[t];o&&i.colFilter?.setColDefPropsForDataType(e,o,r[t])}getFormatValue(e){return this.formatValueFuncs[e]}isColPendingInference(e){return this.isPendingInference&&!!this.columnStateUpdatesPendingInference[e]}setColDefPropertiesForBaseDataType(e,t,n,i){let r=this.formatValueFuncs[t],o=this.columnDefinitionPropsPerDataType[n.baseDataType]({colDef:e,cellDataType:t,colModel:this.colModel,dataTypeDefinition:n,colId:i,formatValue:r});Object.assign(e,o)}getDateObjectTypeDef(e){let t=this.getLocaleTextFunc(),n=this.getDateIncludesTimeFlag(e);return{baseDataType:e,valueParser:e=>lv(e.newValue&&String(e.newValue)),valueFormatter:e=>null==e.value?"":!(e.value instanceof Date)||isNaN(e.value.getTime())?t("invalidDate","Invalid Date"):lf(e.value,n)??"",dataTypeMatcher:e=>e instanceof Date}}getDateStringTypeDef(e){let t=this.getDateIncludesTimeFlag(e);return{baseDataType:e,dateParser:e=>lv(e)??void 0,dateFormatter:e=>lf(e??null,t)??void 0,valueParser:e=>lm(String(e.newValue))?e.newValue:null,valueFormatter:e=>lm(String(e.value))?String(e.value):"",dataTypeMatcher:e=>"string"==typeof e&&lm(e)}}getDefaultDataTypes(){let e=this.getLocaleTextFunc();return{number:{baseDataType:"number",valueParser:e=>e.newValue?.trim?.()===""?null:Number(e.newValue),valueFormatter:t=>null==t.value?"":"number"!=typeof t.value||isNaN(t.value)?e("invalidNumber","Invalid Number"):String(t.value),dataTypeMatcher:e=>"number"==typeof e},text:{baseDataType:"text",valueParser:e=>""===e.newValue?null:r_(e.newValue),dataTypeMatcher:e=>"string"==typeof e},boolean:{baseDataType:"boolean",valueParser:e=>null==e.newValue?e.newValue:e.newValue?.trim?.()===""?null:"true"===String(e.newValue).toLowerCase(),valueFormatter:e=>null==e.value?"":String(e.value),dataTypeMatcher:e=>"boolean"==typeof e},date:this.getDateObjectTypeDef("date"),dateString:this.getDateStringTypeDef("dateString"),dateTime:this.getDateObjectTypeDef("dateTime"),dateTimeString:{...this.getDateStringTypeDef("dateTimeString"),dataTypeMatcher:e=>"string"==typeof e&&lm(e,!0)},object:{baseDataType:"object",valueParser:()=>null,valueFormatter:e=>r_(e.value)??""}}}destroyColumnStateUpdateListeners(){for(let e of this.columnStateUpdateListenerDestroyFuncs)e();this.columnStateUpdateListenerDestroyFuncs=[]}destroy(){this.dataTypeDefinitions={},this.dataTypeMatchers={},this.formatValueFuncs={},this.columnStateUpdatesPendingInference={},this.destroyColumnStateUpdateListeners(),super.destroy()}};function hR(e,t){let n={...e,...t};return e.columnTypes&&t.columnTypes&&t.appendColumnTypes&&(n.columnTypes=[...a9(e.columnTypes),...a9(t.columnTypes)]),n}
376function hI(e,t,n){return t?t.baseDataType===e.baseDataType||(at(46),!1):(at(45,{parentCellDataType:n}),!1)}function hA(e,t){if(e.valueFormatter)return n=>{if(n.node?.group){let t=(n.colDef.pivotValueColumn??n.column).getAggFunc();if(t){if("first"===t||"last"===t)return e.valueFormatter(n);if("number"===e.baseDataType&&"count"!==t){if("number"==typeof n.value)return e.valueFormatter(n);if("object"==typeof n.value){if(!n.value)return;if("toNumber"in n.value)return e.valueFormatter({...n,value:n.value.toNumber()});if("value"in n.value)return e.valueFormatter({...n,value:n.value.value})}}return}}else if(t.get("groupHideOpenParents")&&n.column.isRowGroupActive()&&"string"==typeof n.value&&!e.dataTypeMatcher?.(n.value))return;return e.valueFormatter(n)}}function hP(e,t){return[["cellRenderer","agSparklineCellRenderer"],["valueGetter",void 0],["valueParser",void 0],["refData",void 0]].some(([n,i])=>(function(e,t,n,i){if(!t[n])return!1;let r=e[n];return null===r?(t[n]=!1,!1):void 0===i?!!r:r===i})(e,t,n,i))}var hE={moduleName:"ColumnApi",version:o1,beans:[h_],apiFunctions:{getColumnDef:function(e,t){let n=e.colModel.getColDefCol(t);return n?n.getColDef():null},getDisplayNameForColumn:function(e,t,n){return e.colNames.getDisplayNameForColumn(t,n)||""},getColumn:function(e,t){return e.colModel.getColDefCol(t)},getColumns:function(e){return e.colModel.getColDefCols()},applyColumnState:function(e,t){return sh(e,t,"api")},getColumnState:function(e){return sf(e)},resetColumnState:function(e){!function(e,t){let{colModel:n,autoColSvc:i,selectionColSvc:r,eventSvc:o,gos:a}=e,s=n.getColDefCols();if(!s?.length)return;let l=a3(n.getColDefColTree()),d=[],u=1e3,c=1e3,h=e=>{let t=sg(e);rS(t.rowGroupIndex)&&t.rowGroup&&(t.rowGroupIndex=u++),rS(t.pivotIndex)&&t.pivot&&(t.pivotIndex=c++),d.push(t)};i?.getColumns()?.forEach(h),r?.getColumns()?.forEach(h),l?.forEach(h),sh(e,{state:d},"api");let p=i?.getColumns()??[];sh(e,{state:[...r?.getColumns()??[],...p,...s].map(e=>({colId:e.colId})),applyOrder:!0},"api"),o.dispatchEvent(aN(a,{type:"columnsReset",source:"api"}))}(e,0)},isPinning:function(e){return e.visibleCols.isPinningLeft()||e.visibleCols.isPinningRight()},isPinningLeft:function(e){return e.visibleCols.isPinningLeft()},isPinningRight:function(e){return e.visibleCols.isPinningRight()},getDisplayedColAfter:function(e,t){return e.visibleCols.getColAfter(t)},getDisplayedColBefore:function(e,t){return e.visibleCols.getColBefore(t)},setColumnsVisible:function(e,t,n){e.colModel.setColsVisible(t,n,"api")},setColumnsPinned:function(e,t,n){e.pinnedCols?.setColsPinned(t,n,"api")},getAllGridColumns:function(e){return e.colModel.getCols()},getDisplayedLeftColumns:function(e){return e.visibleCols.leftCols},getDisplayedCenterColumns:function(e){return e.visibleCols.centerCols},getDisplayedRightColumns:function(e){return e.visibleCols.rightCols},getAllDisplayedColumns:function(e){return e.visibleCols.allCols},getAllDisplayedVirtualColumns:function(e){return e.colViewport.getViewportColumns()},getColumnDefs:function(e){return e.colModel.getColumnDefs(!0)}}},hL=class extends oI{constructor(){super(...arguments),this.beanName="colNames"}getDisplayNameForColumn(e,t,n=!1){if(!e)return null;let i=this.getHeaderName(e.getColDef(),e,null,null,t),{aggColNameSvc:r}=this.beans;return n&&r?r.getHeaderName(e,i):i}getDisplayNameForProvidedColumnGroup(e,t,n){let i=t?.getColGroupDef();return i?this.getHeaderName(i,null,e,t,n):null}getDisplayNameForColumnGroup(e,t){return this.getDisplayNameForProvidedColumnGroup(e,e.getProvidedColumnGroup(),t)}getHeaderName(e,t,n,i,r){let o=e.headerValueGetter;if(o){let a=aN(this.gos,{colDef:e,column:t,columnGroup:n,providedColumnGroup:i,location:r});if("function"==typeof o)return o(a);if("string"==typeof o)return this.beans.expressionSvc?.evaluate(o,a)??null}else if(null!=e.headerName)return e.headerName;else if(e.field){var a;return(a=e.field)&&null!=a?a.replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z])([a-z])/g,"$1 $2$3").replace(/\./g," ").split(" ").map(e=>e.substring(0,1).toUpperCase()+(e.length>1?e.substring(1,e.length):"")).join(" "):null}return""}},hF=class extends oI{constructor(){super(...arguments),this.beanName="
376colViewport",this.colsWithinViewport=[],this.headerColsWithinViewport=[],this.colsWithinViewportHash="",this.rowsOfHeadersToRenderLeft={},this.rowsOfHeadersToRenderRight={},this.rowsOfHeadersToRenderCenter={},this.columnsToRenderLeft=[],this.columnsToRenderRight=[],this.columnsToRenderCenter=[]}wireBeans(e){this.visibleCols=e.visibleCols,this.colModel=e.colModel}postConstruct(){this.suppressColumnVirtualisation=this.gos.get("suppressColumnVirtualisation")}setScrollPosition(e,t,n=!1){let{visibleCols:i}=this,r=i.isBodyWidthDirty;if(!(e===this.scrollWidth&&t===this.scrollPosition&&!r)){if(this.scrollWidth=e,this.scrollPosition=t,i.isBodyWidthDirty=!0,this.gos.get("enableRtl")){let n=i.bodyWidth;this.viewportLeft=n-t-e,this.viewportRight=n-t}else this.viewportLeft=t,this.viewportRight=e+t;this.colModel.ready&&this.checkViewportColumns(n)}}getColumnHeadersToRender(e){switch(e){case"left":return this.columnsToRenderLeft;case"right":return this.columnsToRenderRight;default:return this.columnsToRenderCenter}}getHeadersToRender(e,t){let n;switch(e){case"left":n=this.rowsOfHeadersToRenderLeft[t];break;case"right":n=this.rowsOfHeadersToRenderRight[t];break;default:n=this.rowsOfHeadersToRenderCenter[t]}return n??[]}extractViewportColumns(){let e=this.visibleCols.centerCols;this.isColumnVirtualisationSuppressed()?(this.colsWithinViewport=e,this.headerColsWithinViewport=e):(this.colsWithinViewport=e.filter(this.isColumnInRowViewport.bind(this)),this.headerColsWithinViewport=e.filter(this.isColumnInHeaderViewport.bind(this)))}isColumnVirtualisationSuppressed(){return this.suppressColumnVirtualisation||0===this.viewportRight}clear(){this.rowsOfHeadersToRenderLeft={},this.rowsOfHeadersToRenderRight={},this.rowsOfHeadersToRenderCenter={},this.colsWithinViewportHash=""}isColumnInHeaderViewport(e){return!!(e.isAutoHeaderHeight()||function(e){for(;e;){if(e.isAutoHeaderHeight())return!0;e=e.getParent()}return!1}(e))||this.isColumnInRowViewport(e)}isColumnInRowViewport(e){if(e.isAutoHeight())return!0;let t=e.getLeft()||0,n=t+e.getActualWidth(),i=this.viewportLeft-200,r=this.viewportRight+200;return!(t<i&&n<i)&&!(t>r&&n>r)}getViewportColumns(){let{leftCols:e,rightCols:t}=this.visibleCols;return this.colsWithinViewport.concat(e).concat(t)}getColsWithinViewport(e){if(!this.colModel.colSpanActive)return this.colsWithinViewport;let t=e=>{let t=e.getLeft();return rC(t)&&t>this.viewportLeft},n=this.isColumnVirtualisationSuppressed()?void 0:this.isColumnInRowViewport.bind(this),{visibleCols:i}=this,r=i.centerCols;return i.getColsForRow(e,r,n,t)}checkViewportColumns(e=!1){this.extractViewport()&&this.eventSvc.dispatchEvent({type:"virtualColumnsChanged",afterScroll:e})}calculateHeaderRows(){let{leftCols:e,rightCols:t}=this.visibleCols;this.columnsToRenderLeft=e,this.columnsToRenderRight=t,this.columnsToRenderCenter=this.colsWithinViewport;let n=e=>{let t=new Set,n={};for(let i of e){let e=i.getParent(),r=i.isSpanHeaderHeight();for(;e&&!t.has(e);){if(r&&e.isPadding()){e=e.getParent();continue}let i=e.getProvidedColumnGroup().getLevel();n[i]??(n[i]=[]),n[i].push(e),t.add(e),e=e.getParent()}}return n};this.rowsOfHeadersToRenderLeft=n(e),this.rowsOfHeadersToRenderRight=n(t),this.rowsOfHeadersToRenderCenter=n(this.headerColsWithinViewport)}extractViewport(){this.extractViewportColumns();let e=this.getViewportColumns().map(e=>`${e.getId()}-${e.getPinned()||"normal"}`).join("#"),t=this.colsWithinViewportHash!==e;return t&&(this.colsWithinViewportHash=e,this.calculateHeaderRows()),t}},hO=class extends oI{constructor(){super(...arguments),this.beanName="agCompUtils"}adaptFunction(e,t){return e.cellRenderer?class{refresh(){return!1}getGui(){return this.eGui}init(e){let n=t(e),i=typeof n;if("string"===i||"number"===i||"boolean"===i){this.eGui=ot("<span>"+n+"</span>");return}if(null==n){this.eGui=om({tag:"span"});return}this.eGui=n}}:null}},hN=class extends dx{constructor(){super(...arguments),this.agGridDefaults={},this.agGridDefaultOverrides={},this.jsComps={},this.selectors={},this.icons={}}postConstruct(){let e=this.gos.get("components");if(null!=e)for(let t of Object.keys(e))this.jsComps[t]=e[t]}registerModule(e){let{icons:t,userComponents:n,dynamicBeans:i,selectors:r}=e;if(n){let e=(e,t,n,i)=>{this.agGridDefaults[e]=t,(n||i)&&(this.agGridDefaultOverrides[e]={params:n,processParams:i}
376)};for(let t of Object.keys(n)){var o;let i=n[t];if("object"==typeof(o=i)&&o.getComp&&(i=i.getComp(this.beans)),"object"==typeof i){let{classImp:n,params:r,processParams:o}=i;e(t,n,r,o)}else e(t,i)}}for(let e of(this.registerDynamicBeans(i),r??[]))this.selectors[e.selector]=e;if(t)for(let e of Object.keys(t))this.icons[e]=t[e]}getUserComponent(e,t){let n=(e,t,n,i)=>({componentFromFramework:t,component:e,params:n,processParams:i}),{frameworkOverrides:i}=this.beans,r=i.frameworkComponent(t,this.gos.get("components"));if(null!=r)return n(r,!0);let o=this.jsComps[t];if(o){let e=i.isFrameworkComponent(o);return n(o,e)}let a=this.agGridDefaults[t];if(a){let e=this.agGridDefaultOverrides[t];return n(a,!1,e?.params,e?.processParams)}return this.beans.validation?.missingUserComponent(e,t,this.agGridDefaults,this.jsComps),null}getSelector(e){return this.selectors[e]}getIcon(e){return this.icons[e]}getDynamicError(e,t){return t?ar(279,{name:e}):this.beans.validation?.missingDynamicBean(e)??ar(256)}},hB=class extends oI{constructor(){super(...arguments),this.beanName="ctrlsSvc",this.params={},this.ready=!1,this.readyCallbacks=[]}postConstruct(){this.addEventListener("ready",()=>{if(this.updateReady(),this.ready){for(let e of this.readyCallbacks)e(this.params);this.readyCallbacks.length=0}},this.beans.frameworkOverrides.runWhenReadyAsync?.()??!1)}updateReady(){let e=Object.values(this.params);this.ready=23===e.length&&e.every(e=>e?.isAlive()??!1)}whenReady(e,t){this.ready?t(this.params):this.readyCallbacks.push(t),e.addDestroyFunc(()=>{let e=this.readyCallbacks.indexOf(t);e>=0&&this.readyCallbacks.splice(e,1)})}register(e,t){this.params[e]=t,this.updateReady(),this.ready&&this.dispatchLocalEvent({type:"ready"}),t.addDestroyFunc(()=>{this.updateReady()})}get(e){return this.params[e]}getGridBodyCtrl(){return this.params.gridBodyCtrl}getHeaderRowContainerCtrls(){let{leftHeader:e,centerHeader:t,rightHeader:n}=this.params;return[e,n,t]}getHeaderRowContainerCtrl(e){let t=this.params;switch(e){case"left":return t.leftHeader;case"right":return t.rightHeader;default:return t.centerHeader}}getScrollFeature(){return this.getGridBodyCtrl().scrollFeature}},hz={wrapperBorder:!0,rowBorder:!0,headerRowBorder:!0,footerRowBorder:{ref:"rowBorder"},columnBorder:{style:"solid",width:1,color:"transparent"},headerColumnBorder:!1,headerColumnBorderHeight:"100%",pinnedColumnBorder:!0,pinnedRowBorder:!0,sidePanelBorder:!0,sideBarPanelWidth:250,sideBarBackgroundColor:{ref:"chromeBackgroundColor"}
376,sideButtonBarBackgroundColor:{ref:"sideBarBackgroundColor"},sideButtonBarTopPadding:0,sideButtonSelectedUnderlineWidth:2,sideButtonSelectedUnderlineColor:"transparent",sideButtonSelectedUnderlineTransitionDuration:0,sideButtonBackgroundColor:"transparent",sideButtonTextColor:{ref:"textColor"},sideButtonHoverBackgroundColor:{ref:"sideButtonBackgroundColor"},sideButtonHoverTextColor:{ref:"sideButtonTextColor"},sideButtonSelectedBackgroundColor:l1,sideButtonSelectedTextColor:{ref:"sideButtonTextColor"},sideButtonBorder:"solid 1px transparent",sideButtonSelectedBorder:!0,sideButtonLeftPadding:{ref:"spacing"},sideButtonRightPadding:{ref:"spacing"},sideButtonVerticalPadding:{calc:"spacing * 3"},headerBackgroundColor:{ref:"chromeBackgroundColor"},headerFontFamily:{ref:"fontFamily"},cellFontFamily:{ref:"fontFamily"},headerFontWeight:500,headerFontSize:{ref:"fontSize"},dataFontSize:{ref:"fontSize"},headerTextColor:{ref:"textColor"},headerCellHoverBackgroundColor:"transparent",headerCellMovingBackgroundColor:{ref:"headerCellHoverBackgroundColor"}
vendor: 2,279 bytes, line 376
376,headerCellBackgroundTransitionDuration:"0.2s",cellTextColor:{ref:"textColor"},rangeSelectionBorderStyle:"solid",rangeSelectionBorderColor:l3,rangeSelectionBackgroundColor:lJ(.2),rangeSelectionChartBackgroundColor:"#0058FF1A",rangeSelectionChartCategoryBackgroundColor:"#00FF841A",rangeSelectionHighlightColor:lJ(.5),rangeHeaderHighlightColor:{ref:"foregroundColor",mix:.08,onto:"headerBackgroundColor"},rowNumbersSelectedColor:lJ(.5),rowHoverColor:lJ(.08),columnHoverColor:lJ(.05),selectedRowBackgroundColor:lJ(.12),modalOverlayBackgroundColor:{ref:"backgroundColor",mix:.66},dataBackgroundColor:l1,oddRowBackgroundColor:{ref:"dataBackgroundColor"},wrapperBorderRadius:8,cellHorizontalPadding:{calc:"spacing * 2 * cellHorizontalPaddingScale"},cellWidgetSpacing:{calc:"spacing * 1.5"},cellHorizontalPaddingScale:1,rowGroupIndentSize:{calc:"cellWidgetSpacing + iconSize"},valueChangeDeltaUpColor:"#43a047",valueChangeDeltaDownColor:"#e53935",valueChangeValueHighlightBackgroundColor:"#16a08580",rowHeight:{calc:"max(iconSize, dataFontSize) + spacing * 3.25 * rowVerticalPaddingScale"},rowVerticalPaddingScale:1,headerHeight:{calc:"max(iconSize, dataFontSize) + spacing * 4 * headerVerticalPaddingScale"},headerVerticalPaddingScale:1,paginationPanelHeight:{ref:"rowHeight",calc:"max(rowHeight, 22px)"},dragHandleColor:lQ(.7),headerColumnResizeHandleHeight:"30%",headerColumnResizeHandleWidth:2,headerColumnResizeHandleColor:{ref:"borderColor"},widgetContainerHorizontalPadding:{calc:"spacing * 1.5"},widgetContainerVerticalPadding:{calc:"spacing * 1.5"},widgetHorizontalSpacing:{calc:"spacing * 1.5"},widgetVerticalSpacing:{ref:"spacing"},iconButtonColor:{ref:"iconColor"},iconButtonBackgroundColor:"transparent",iconButtonBackgroundSpread:4,iconButtonBorderRadius:1,iconButtonHoverColor:{ref:"iconButtonColor"},iconButtonHoverBackgroundColor:lQ(.1),iconButtonActiveColor:l3,iconButtonActiveBackgroundColor:lJ(.28),iconButtonActiveIndicatorColor:l3,menuBorder:{color:lQ(.2)},menuBackgroundColor:l0(.03),menuTextColor:l0(.95),menuShadow:{ref:"popupShadow"},menuSeparatorColor:{ref:"borderColor"},setFilterIndentSize:{ref:"iconSize"},chartMenuPanelWidth:260,chartMenuLabelColor:lQ(.8),dialogShadow:{ref:"popupShadow"},cellEditingBorder:{color:l3},cellEditingShadow:{ref:"cardShadow"}
376,fullRowEditInvalidBackgroundColor:{ref:"invalidColor",onto:"backgroundColor",mix:.25},dialogBorder:{color:lQ(.2)},panelBackgroundColor:l1,panelTitleBarHeight:{ref:"headerHeight"},panelTitleBarBackgroundColor:{ref:"headerBackgroundColor"},panelTitleBarIconColor:{ref:"headerTextColor"},panelTitleBarTextColor:{ref:"headerTextColor"},panelTitleBarFontWeight:{ref:"headerFontWeight"},panelTitleBarBorder:!0,columnSelectIndentSize:{ref:"iconSize"},toolPanelSeparatorBorder:!0,columnDropCellBackgroundColor:lQ(.07),columnDropCellTextColor:{ref:"textColor"},columnDropCellDragHandleColor:{ref:"textColor"},columnDropCellBorder:{color:lQ(.13)},selectCellBackgroundColor:lQ(.07),selectCellBorder:{color:lQ(.13)},advancedFilterBuilderButtonBarBorder:!0,advancedFilterBuilderIndentSize:{calc:"spacing * 2 + iconSize"},advancedFilterBuilderJoinPillColor:"#f08e8d",advancedFilterBuilderColumnPillColor:"#a6e194",advancedFilterBuilderOptionPillColor:"#f3c08b",advancedFilterBuilderValuePillColor:"#85c0e4",filterPanelApplyButtonColor:l1,filterPanelApplyButtonBackgroundColor:l3,filterPanelCardSubtleColor:{ref:"textColor",mix:.7},filterPanelCardSubtleHoverColor:{ref:"textColor"},findMatchColor:l2,findMatchBackgroundColor:"#ffff00",findActiveMatchColor:l2,findActiveMatchBackgroundColor:"#ffa500",filterToolPanelGroupIndent:{ref:"spacing"},rowLoadingSkeletonEffectColor:lQ(.15),statusBarLabelColor:l2,statusBarLabelFontWeight:500,statusBarValueColor:l2,statusBarValueFontWeight:500,pinnedSourceRowTextColor:{ref:"textColor"},pinnedSourceRowBackgroundColor:{ref:"dataBackgroundColor"},pinnedSourceRowFontWeight:600,pinnedRowFontWeight:600,pinnedRowBackgroundColor:{ref:"dataBackgroundColor"},pinnedRowTextColor:{ref:"textColor"}},hj={cellBatchEditBackgroundColor:"rgba(220 181 139 / 16%)",cellBatchEditTextColor:"#422f00",rowBatchEditBackgroundColor:{ref:"cellBatchEditBackgroundColor"},rowBatchEditTextColor:{ref:"cellBatchEditTextColor"}},hV={...hj,cellBatchEditTextColor:"#f3d0b3"},hH=lU({feature:"batchEditStyle",params:hj,css:".ag-cell-batch-edit{background-color:var(--ag-cell-batch-edit-background-color);color:var(--ag-cell-batch-edit-text-color);display:inherit}.ag-row-batch-edit{background-color:var(--ag-row-batch-edit-background-color);color:var(--ag-row-batch-edit-text-color)}"}),hG=":where(.ag-button){background:none;border:none;color:inherit;cursor:pointer;font-family:inherit;font-size:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0;text-indent:inherit;text-shadow:inherit;text-transform:inherit;word-spacing:inherit;&:disabled{cursor:default}&:focus-visible{box-shadow:var(--ag-focus-shadow);outline:none}}.ag-standard-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--ag-button-background-color);border:var(--ag-button-border);border-radius:var(--ag-button-border-radius);color:var(--ag-button-text-color);cursor:pointer;font-weight:var(--ag-button-font-weight);padding:var(--ag-button-vertical-padding) var(--ag-button-horizontal-padding);&:hover{background-color:var(--ag-button-hover-background-color);border:var(--ag-button-hover-border);color:var(--ag-button-hover-text-color)}&:active{background-color:var(--ag-button-active-background-color);border:var(--ag-button-active-border);color:var(--ag-button-active-text-color)}&:disabled{background-color:var(--ag-button-disabled-background-color);border:var(--ag-button-disabled-border);color:var(--ag-button-disabled-text-color)}}",hW={buttonTextColor:"inherit",buttonFontWeight:"normal",buttonBackgroundColor:"transparent",buttonBorder:!1,buttonBorderRadius:{ref:"borderRadius"},buttonHorizontalPadding:{calc:"spacing * 2"},buttonVerticalPadding:{ref:"spacing"},buttonHoverTextColor:{ref:"buttonTextColor"},buttonHoverBackgroundColor:{ref:"buttonBackgroundColor"},buttonHoverBorder:{ref:"buttonBorder"},buttonActiveTextColor:{ref:"buttonHoverTextColor"},buttonActiveBackgroundColor:{ref:"buttonHoverBackgroundColor"},buttonActiveBorder:{ref:"buttonHoverBorder"},buttonDisabledTextColor:{ref:"inputDisabledTextColor"}
376,buttonDisabledBackgroundColor:{ref:"inputDisabledBackgroundColor"},buttonDisabledBorder:{ref:"inputDisabledBorder"}},h$=(lU({feature:"buttonStyle",params:hW,css:hG}),lU({feature:"buttonStyle",params:{...hW,buttonBackgroundColor:l1,buttonBorder:!0,buttonHoverBackgroundColor:{ref:"rowHoverColor"},buttonActiveBorder:{color:l3}},css:hG})),hU=(lU({feature:"buttonStyle",params:{...hW,buttonBackgroundColor:l1,buttonBorder:{color:l3},buttonFontWeight:600,buttonTextColor:l3,buttonHoverBackgroundColor:{ref:"rowHoverColor"},buttonActiveBackgroundColor:l3,buttonActiveTextColor:l1},css:hG}),lU({feature:"buttonStyle",params:{...hW,buttonBorder:{color:l2,width:2,style:"outset"},buttonActiveBorder:{color:l2,width:2,style:"inset"},buttonBackgroundColor:l0(.07),buttonHoverBackgroundColor:l1,buttonVerticalPadding:{calc:"spacing * 0.5"}},css:hG}),lU({feature:"columnDropStyle",css:".ag-column-drop-vertical-empty-message{align-items:center;border:dashed var(--ag-border-width);border-color:var(--ag-border-color);display:flex;inset:0;justify-content:center;margin:calc(var(--ag-spacing)*1.5) calc(var(--ag-spacing)*2);overflow:hidden;padding:calc(var(--ag-spacing)*2);position:absolute}"})),hq=(lU({feature:"columnDropStyle",css:".ag-column-drop-vertical-empty-message{color:var(--ag-subtle-text-color);font-size:calc(var(--ag-font-size) - 1px);font-weight:600;padding-top:var(--ag-spacing)}:where(.ag-ltr) .ag-column-drop-vertical-empty-message{padding-left:calc(var(--ag-icon-size) + var(--ag-spacing) + var(--ag-widget-horizontal-spacing));padding-right:var(--ag-spacing)}:where(.ag-rtl) .ag-column-drop-vertical-empty-message{padding-left:var(--ag-spacing);padding-right:calc(var(--ag-icon-size) + var(--ag-spacing) + var(--ag-widget-horizontal-spacing))}"}),{warn:(...e)=>{at(e[0],e[1])},error:(...e)=>{an(e[0],e[1])},preInitErr:(...e)=>{ai(e[0],e[2],e[1])}}),hK=lU({feature:"checkboxStyle",params:{checkboxBorderWidth:1,checkboxBorderRadius:{ref:"borderRadius"},checkboxUncheckedBackgroundColor:l1,checkboxUncheckedBorderColor:l0(.3),checkboxCheckedBackgroundColor:l3,checkboxCheckedBorderColor:{ref:"checkboxCheckedBackgroundColor"},checkboxCheckedShapeImage:{svg:'<svg xmlns="http://www.w3.org/2000/svg" width="10" height="7" fill="none"><path stroke="#000" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.75" d="M1 3.5 3.5 6l5-5"/></svg>'}
vendor: 5,554 bytes, line 376
376,checkboxCheckedShapeColor:l1,checkboxIndeterminateBackgroundColor:l0(.3),checkboxIndeterminateBorderColor:{ref:"checkboxIndeterminateBackgroundColor"},checkboxIndeterminateShapeImage:{svg:'<svg xmlns="http://www.w3.org/2000/svg" width="10" height="2" fill="none"><rect width="10" height="2" fill="#000" rx="1"/></svg>'},checkboxIndeterminateShapeColor:l1,radioCheckedShapeImage:{svg:'<svg xmlns="http://www.w3.org/2000/svg" width="6" height="6" fill="none"><circle cx="3" cy="3" r="3" fill="#000"/></svg>'}},css:'.ag-checkbox-input-wrapper,.ag-radio-button-input-wrapper{background-color:var(--ag-checkbox-unchecked-background-color);border:solid var(--ag-checkbox-border-width) var(--ag-checkbox-unchecked-border-color);flex:none;height:var(--ag-icon-size);position:relative;width:var(--ag-icon-size);:where(input){-webkit-appearance:none;-moz-appearance:none;appearance:none;cursor:pointer;display:block;height:var(--ag-icon-size);margin:0;opacity:0;width:var(--ag-icon-size)}&:after{content:"";display:block;inset:0;-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;pointer-events:none;position:absolute}&:where(.ag-checked){background-color:var(--ag-checkbox-checked-background-color);border-color:var(--ag-checkbox-checked-border-color);&:after{background-color:var(--ag-checkbox-checked-shape-color)}}&:where(:focus-within,:active){box-shadow:var(--ag-focus-shadow)}&:where(.ag-disabled){filter:grayscale();opacity:.5}}.ag-checkbox-input-wrapper{border-radius:var(--ag-checkbox-border-radius);&:where(.ag-checked):after{-webkit-mask-image:var(--ag-checkbox-checked-shape-image);mask-image:var(--ag-checkbox-checked-shape-image)}&:where(.ag-indeterminate){background-color:var(--ag-checkbox-indeterminate-background-color);border-color:var(--ag-checkbox-indeterminate-border-color);&:after{background-color:var(--ag-checkbox-indeterminate-shape-color);-webkit-mask-image:var(--ag-checkbox-indeterminate-shape-image);mask-image:var(--ag-checkbox-indeterminate-shape-image)}}}.ag-cell-editing-error .ag-checkbox-input-wrapper:focus-within{box-shadow:var(--ag-focus-error-shadow)}.ag-radio-button-input-wrapper{border-radius:100%;&:where(.ag-checked):after{-webkit-mask-image:var(--ag-radio-checked-shape-image);mask-image:var(--ag-radio-checked-shape-image)}}'}),hY=()=>({...l5,...hV,backgroundColor:"hsl(217, 0%, 17%)",foregroundColor:"#FFF",chromeBackgroundColor:l0(.05),rowHoverColor:lJ(.15),selectedRowBackgroundColor:lJ(.2),menuBackgroundColor:l0(.1),browserColorScheme:"dark",popupShadow:"0 0px 20px #000A",cardShadow:"0 1px 4px 1px #000A",advancedFilterBuilderJoinPillColor:"#7a3a37",advancedFilterBuilderColumnPillColor:"#355f2d",advancedFilterBuilderOptionPillColor:"#5a3168",advancedFilterBuilderValuePillColor:"#374c86",filterPanelApplyButtonColor:l2,findMatchColor:l1,findActiveMatchColor:l1,checkboxUncheckedBorderColor:l0(.4),toggleButtonOffBackgroundColor:l0(.4),rowBatchEditBackgroundColor:l0(.1)}),hZ=lU({feature:"colorScheme",params:l5,modeParams:{light:l5,dark:hY(),"dark-blue":{...hY(),backgroundColor:"#1f2836"}}}),hX={aggregation:'<path d="M18 7V4H6l6 8-6 8h12v-3"/>',arrows:'<polyline points="5 9 2 12 5 15"/><polyline points="9 5 12 2 15 5"/><polyline points="15 19 12 22 9 19"/><polyline points="19 9 22 12 19 15"/><line x1="2" x2="22" y1="12" y2="12"/><line x1="12" x2="12" y1="2" y2="22"/>',asc:'<path d="m5 12 7-7 7 7"/><path d="M12 19V5"/>',cancel:'<path d="m18 6-12 12"/><path d="m6 6 12 12"/>',chart:'<line x1="18" x2="18" y1="20" y2="10"/><line x1="12" x2="12" y1="20" y2="4"/><line x1="6" x2="6" y1="20" y2="14"/>',"color-picker":'<path d="m19 11-8-8-8.6 8.6a2 2 0 0 0 0 2.8l5.2 5.2c.8.8 2 .8 2.8 0L19 11Z"/><path d="m5 2 5 5"/><path d="M2 13h15"/><path d="M22 20a2 2 0 1 1-4 0c0-1.6 1.7-2.4 2-4 .3 1.6 2 2.4 2 4Z"/>',columns:'<path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18"/>',contracted:'<path d="m9 18 6-6-6-6"/>',copy:'<rect width="14" height="14" x="8" y="8" rx="2" ry="2"/><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"/>',cross:'<path d="M18 6 6 18"/><path d="m6 6 12 12"/>',csv:'<path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z"/><polyline points="14 2 14 8 20 8"/><path d="M8 13h2"/><path d="M8 17h2"/><path d="M14 13h2"/><path d="M14 17h2"/>',cut:'<circle cx="6" cy="6" r="3"/><path d="M8.12 8.12 12 12"/><path d="M20 4 8.12 15.88"/><circle cx="6" cy="18" r="3"/><path d="M14.8 14.8 20 20"/>',desc:'<path d="M12 5v14"/><path d="m19 12-7 7-7-7"/>',down:'<path d="M12 5v14"/><path d="m19 12-7 7-7-7"/>',excel:'<path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z"/><polyline points="14 2 14 8 20 8"/><path d="M8 13h2"/><path d="M8 17h2"/><path d="M14 13h2"/><path d="M14 17h2"/>',expanded:'<path d="m15 18-6-6 6-6"/>',"eye-slash":'<path d="M9.88 9.88a3 3 0 1 0 4.24 4.24"/><path d="M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68"/><path d="M6.61 6.61A13.526 13.526 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61"/><line x1="2" x2="22" y1="2" y2="22"/>',eye:'<path d="M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z"/><circle cx="12" cy="12" r="3"/>',filter:'<path d="M3 6h18"/><path d="M7 12h10"/><path d="M10 18h4"/>',first:'<path d="m17 18-6-6 6-6"/><path d="M7 6v12"/>',group:'<path d="M16 12H3"/><path d="M16 18H3"/><path d="M10 6H3"/><path d="M21 18V8a2 2 0 0 0-2-2h-5"/><path d="m16 8-2-2 2-2"/>',last:'<path d="m7 18 6-6-6-6"/><path d="M17 6v12"/>',left:'<path d="m12 19-7-7 7-7"/>
376<path d="M19 12H5"/>',linked:'<path d="M9 17H7A5 5 0 0 1 7 7h2"/><path d="M15 7h2a5 5 0 1 1 0 10h-2"/><line x1="8" x2="16" y1="12" y2="12"/>',loading:'<line x1="12" x2="12" y1="2" y2="6"/><line x1="12" x2="12" y1="18" y2="22"/><line x1="4.93" x2="7.76" y1="4.93" y2="7.76"/><line x1="16.24" x2="19.07" y1="16.24" y2="19.07"/><line x1="2" x2="6" y1="12" y2="12"/><line x1="18" x2="22" y1="12" y2="12"/><line x1="4.93" x2="7.76" y1="19.07" y2="16.24"/><line x1="16.24" x2="19.07" y1="7.76" y2="4.93"/>',maximize:'<polyline points="15 3 21 3 21 9"/><polyline points="9 21 3 21 3 15"/><line x1="21" x2="14" y1="3" y2="10"/><line x1="3" x2="10" y1="21" y2="14"/>',menu:'<line x1="4" x2="20" y1="12" y2="12"/><line x1="4" x2="20" y1="6" y2="6"/><line x1="4" x2="20" y1="18" y2="18"/>',"menu-alt":'<circle cx="12" cy="5" r="0.75" fill="#D9D9D9"/><circle cx="12" cy="12" r="0.75" fill="#D9D9D9"/><circle cx="12" cy="19" r="0.75" fill="#D9D9D9"/>',minimize:'<polyline points="4 14 10 14 10 20"/><polyline points="20 10 14 10 14 4"/><line x1="14" x2="21" y1="10" y2="3"/><line x1="3" x2="10" y1="21" y2="14"/>',minus:'<circle cx="12" cy="12" r="10"/><path d="M8 12h8"/>',next:'<path d="m9 18 6-6-6-6"/>',none:'<path d="m7 15 5 5 5-5"/><path d="m7 9 5-5 5 5"/>',"not-allowed":'<circle cx="12" cy="12" r="10"/><path d="m4.9 4.9 14.2 14.2"/>',paste:'<path d="M15 2H9a1 1 0 0 0-1 1v2c0 .6.4 1 1 1h6c.6 0 1-.4 1-1V3c0-.6-.4-1-1-1Z"/><path d="M8 4H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2M16 4h2a2 2 0 0 1 2 2v2M11 14h10"/><path d="m17 10 4 4-4 4"/>',pin:'<line x1="12" x2="12" y1="17" y2="22"/><path d="M5 17h14v-1.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V6h1a2 2 0 0 0 0-4H8a2 2 0 0 0 0 4h1v4.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24Z"/>',pivot:'<path d="M15 3v18"/><rect width="18" height="18" x="3" y="3" rx="2"/><path d="M21 9H3"/><path d="M21 15H3"/>',plus:'<circle cx="12" cy="12" r="10"/><path d="M8 12h8"/><path d="M12 8v8"/>',previous:'<path d="m15 18-6-6 6-6"/>',right:'<path d="M5 12h14"/><path d="m12 5 7 7-7 7"/>',save:'<path d="M12 17V3"/><path d="m6 11 6 6 6-6"/><path d="M19 21H5"/>',"small-left":'<path d="m15 18-6-6 6-6"/>',"small-right":'<path d="m9 18 6-6-6-6"/>',tick:'<path d="M20 6 9 17l-5-5"/>',"tree-closed":'<path d="m9 18 6-6-6-6"/>',"tree-indeterminate":'<path d="M5 12h14"/>',"tree-open":'<path d="m6 9 6 6 6-6"/>',unlinked:'<path d="M9 17H7A5 5 0 0 1 7 7"/><path d="M15 7h2a5 5 0 0 1 4 8"/><line x1="8" x2="12" y1="12" y2="12"/><line x1="2" x2="22" y1="2" y2="22"/>',up:'<path d="m5 12 7-7 7 7"/><path d="M12 19V5"/>',grip:'<circle cx="5" cy="8" r="0.5"/><circle cx="12" cy="8" r="0.5"/><circle cx="19" cy="8" r="0.5"/><circle cx="5" cy="16" r="0.5"/><circle cx="12" cy="16" r="0.5"/><circle cx="19" cy="16" r="0.5"/><g stroke="none" fill="currentColor"><circle cx="5" cy="8" r="1"/><circle cx="12" cy="8" r="1"/><circle cx="19" cy="8" r="1"/><circle cx="5" cy="16" r="1"/><circle cx="12" cy="16" r="1"/><circle cx="19" cy="16" r="1"/></g>',settings:'<path d="M20 7h-9"/><path d="M14 17H5"/><circle cx="17" cy="17" r="3"/><circle cx="7" cy="7" r="3"/>'},hJ={"column-arrow":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="none" viewBox="0 0 32 32"><path fill-rule="evenodd" clip-rule="evenodd" d="M0 26C0 28.2092 1.79086 30 4 30H14C16.2091 30 18 28.2092 18 26V15H25.8786L24.4394 16.4393C23.8536 17.0251 23.8536 17.9749 24.4394 18.5607C25.0252 19.1464 25.9748 19.1464 26.5606 18.5607L30.5606 14.5607C31.1464 13.9749 31.1464 13.0251 30.5606 12.4393L26.5606 8.43934C25.9748 7.85356 25.0252 7.85356 24.4394 8.43934C23.8536 9.02512 23.8536 9.97488 24.4394 10.5607L25.8786 12H18V6C18 3.79086 16.2091 2 14 2H4C1.79086 2 0 3.79086 0 6V26ZM14 5H10.5V12H15V6C15 5.44772 14.5523 5 14 5ZM4 5H7.5V12H3V6C3 5.44772 3.44772 5 4 5ZM10.5 15H15V26C15 26.5522 14.5523 27 14 27H10.5V15ZM4 27H7.5V15H3V26C3 26.5522 3.44772 27 4 27Z" fill="currentColor"/></svg>',"small-down":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="black" stroke="none" viewBox="0 0 32 32"><path d="M7.334 10.667 16 21.334l8.667-10.667H7.334Z"/></svg>',"small-up":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="black" stroke="none" viewBox="0 0 32 32">
376<path d="M7.334 21.333 16 10.666l8.667 10.667H7.334Z"/></svg>',"pinned-top":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="none" viewBox="0 0 16 16"><path fill="currentColor" d="M12.53 3.72A.75.75 0 0 1 12 5H4a.75.75 0 0 1 0-1.5h8a.75.75 0 0 1 .53.22ZM3.269 10.744a.75.75 0 0 1 .2-.524l4-4a.75.75 0 0 1 1.06 0l4 4a.75.75 0 1 1-1.06 1.06L8.75 8.56V14a.75.75 0 0 1-1.5 0V8.56l-2.72 2.72a.75.75 0 0 1-1.26-.536Z"/></svg>',"pinned-bottom":'<svg xmlns="http://www.w3.org/2000/svg" fill="none" class="ag-icon" viewBox="0 0 16 16"><path fill="currentColor" d="M3.47 12.28A.75.75 0 0 1 4 11h8a.75.75 0 0 1 0 1.5H4a.75.75 0 0 1-.53-.22ZM12.731 5.256a.75.75 0 0 1-.2.524l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 1 1 1.06-1.06l2.72 2.72V2a.75.75 0 0 1 1.5 0v5.44l2.72-2.72a.75.75 0 0 1 1.26.536Z"/></svg>',"un-pin":'<svg xmlns="http://www.w3.org/2000/svg" fill="none" class="ag-icon" viewBox="0 0 16 16"><path fill="currentColor" d="M8 11a.75.75 0 0 0-.75.75v3.333a.75.75 0 1 0 1.5 0V11.75A.75.75 0 0 0 8 11Z"/><path fill="currentColor" d="M13.11 1.436a.75.75 0 0 0-1.22-.872l-10 14a.75.75 0 1 0 1.22.872L5.207 12.5h7.376a.75.75 0 0 0 .75-.75v-1.174a2.08 2.08 0 0 0-1.153-1.863l-1.185-.599-.005-.002a.58.58 0 0 1-.323-.522V5.165a2.083 2.083 0 0 0 1.854-2.904l.589-.825Zm-3.943 5.52v.634a2.08 2.08 0 0 0 1.153 1.863l1.185.6.005.002a.58.58 0 0 1 .323.522V11H6.28l2.887-4.044ZM9.277 1H5.25a2.084 2.084 0 0 0-.083 4.165v1.676l1.5-2.132v-.292a.75.75 0 0 0-.75-.75H5.25a.584.584 0 0 1 0-1.167h2.972L9.277 1Z"/></svg>',"chevron-down":'<svg width="16" height="16" viewBox="0 0 16 16" class="ag-icon" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M12 6L8 10L4 6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>',"chevron-up":'<svg width="16" height="16" viewBox="0 0 16 16" class="ag-icon" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M4 10L8 6L12 10" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>',"chevron-left":'<svg width="16" height="16" viewBox="0 0 16 16" class="ag-icon" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M10 12L6 8L10 4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>',"chevron-right":'<svg width="16" height="16" viewBox="0 0 16 16" class="ag-icon" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M6 12L10 8L6 4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>',"filter-add":'<svg width="16" height="16" viewBox="0 0 16 16" class="ag-icon" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M5.12126 7.75L10.8517 7.75" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/><path d="M6.65934 11.748L9.32778 11.748" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/><path d="M12.2943 1.04872V6.19184M14.9886 3.74341H9.68478" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/><path d="M8.25488 3C8.04799 3.18323 7.91706 3.45099 7.91699 3.74902C7.91713 4.04868 8.04988 4.31681 8.25879 4.5H2C1.58579 4.5 1.25 4.16421 1.25 3.75C1.25 3.33579 1.58579 3 2 3H8.25488Z" fill="currentColor"/></svg>',edit:'<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M3.5 10.6262V12.5012H5.375L10.905 6.97122L9.03 5.09622L3.5 10.6262ZM12.355 5.52122C12.4014 5.47497 12.4381 5.42002 12.4632 5.35953C12.4883 5.29905 12.5012 5.23421 12.5012 5.16872C12.5012 5.10324 12.4883 5.0384 12.4632 4.97791C12.4381 4.91742 12.4014 4.86248 12.355 4.81622L11.185 3.64622C11.1387 3.59987 11.0838 3.5631 11.0233 3.53801C10.9628 3.51291 10.898 3.5 10.8325 3.5C10.767 3.5 10.7022 3.51291 10.6417 3.53801C10.5812 3.5631 10.5263 3.59987 10.48 3.64622L9.565 4.56122L11.44 6.43622L12.355 5.52122Z" fill="currentColor"/></svg>'},hQ=(e,t=1.5)=>{let n=hJ[e];if(n)return n;let i=hX[e];if(!i)throw Error(`Missing icon data for ${e}`);return`<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke="black" stroke-width="${t}" viewBox="0 0 24 24"><style>* { vector-effect: non-scaling-stroke; }</style>`+i+"</svg>"},h0=((e={})=>lU({feature:"iconSet",css:()=>((e={})=>{let t="";for(let n of[...Object.keys(hX),...Object.keys(hJ)]){let i=hQ(n,e.strokeWidth);t+=`.ag-icon-${n}::before { mask-image: url('data:image/svg+xml,${encodeURIComponent(i)}'); } 377`}return t})(e)}))(),h1=':where(.ag-input-field-input[type=number]:not(.ag-number-field-input-stepper)){-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield;&::-webkit-inner-spin-button,&::-webkit-outer-spin-button{-webkit-appearance:none;appearance:none;margin:0}}.ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){background-color:var(--ag-input-background-color);border:var(--ag-input-border);border-radius:var(--ag-input-border-radius);color:var(--ag-input-text-color);font-family:inherit;font-size:inherit;line-height:inherit;margin:0;min-height:var(--ag-input-height);padding:0;&:where(:disabled){background-color:var(--ag-input-disabled-background-color);border:var(--ag-input-disabled-border);color:var(--ag-input-disabled-text-color)}&:where(:focus){background-color:var(--ag-input-focus-background-color);border:var(--ag-input-focus-border);box-shadow:var(--ag-input-focus-shadow);color:var(--ag-input-focus-text-color);outline:none}&:where(:invalid){background-color:var(--ag-input-invalid-background-color);border:var(--ag-input-invalid-border);color:var(--ag-input-invalid-text-color)}&:where(.invalid){background-color:var(--ag-input-invalid-background-color);border:var(--ag-input-invalid-border);color:var(--ag-input-invalid-text-color)}&::-moz-placeholder{color:var(--ag-input-placeholder-text-color)}&::placeholder{color:var(--ag-input-placeholder-text-color)}}:where(.ag-ltr) .ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){padding-left:var(--ag-input-padding-start)}:where(.ag-rtl) .ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){padding-right:var(--ag-input-padding-start)}:where(.ag-column-select-header-filter-wrapper,.ag-filter-toolpanel-search,.ag-mini-filter,.ag-filter-filter,.ag-filter-add-select){.ag-input-wrapper:before{background-color:currentcolor;color:var(--ag-input-icon-color);content:"";display:block;height:12px;-webkit-mask-image:url("data:image/svg+xml;charset=utf-8;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMiIgaGVpZ2h0PSIxMiIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41Ij48cGF0aCBkPSJNNS4zIDlhMy43IDMuNyAwIDEgMCAwLTcuNSAzLjcgMy43IDAgMCAwIDAgNy41Wk0xMC41IDEwLjUgOC4zIDguMiIvPjwvc3ZnPg==");mask-image:url("data:image/svg+xml;charset=utf-8;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMiIgaGVpZ2h0PSIxMiIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41Ij48cGF0aCBkPSJNNS4zIDlhMy43IDMuNyAwIDEgMCAwLTcuNSAzLjcgMy43IDAgMCAwIDAgNy41Wk0xMC41IDEwLjUgOC4zIDguMiIvPjwvc3ZnPg==");-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;opacity:.5;position:absolute;width:12px}}:where(.ag-ltr) :where(.ag-column-select-header-filter-wrapper,.ag-filter-toolpanel-search,.ag-mini-filter,.ag-filter-filter,.ag-filter-add-select){.ag-input-wrapper:before{margin-left:var(--ag-spacing)}.ag-number-field-input,.ag-text-field-input{padding-left:calc(var(--ag-spacing)*1.5 + 12px)}}:where(.ag-rtl) :where(.ag-column-select-header-filter-wrapper,.ag-filter-toolpanel-search,.ag-mini-filter,.ag-filter-filter,.ag-filter-add-select){.ag-input-wrapper:before{margin-right:var(--ag-spacing)}.ag-number-field-input,.ag-text-field-input{padding-right:calc(var(--ag-spacing)*1.5 + 12px)}}
377',h2={inputBackgroundColor:"transparent",inputBorder:!1,inputBorderRadius:0,inputTextColor:{ref:"textColor"},inputPlaceholderTextColor:{ref:"inputTextColor",mix:.5},inputPaddingStart:0,inputHeight:{calc:"max(iconSize, fontSize) + spacing * 2"},inputFocusBackgroundColor:{ref:"inputBackgroundColor"},inputFocusBorder:{ref:"inputBorder"},inputFocusShadow:"none",inputFocusTextColor:{ref:"inputTextColor"},inputDisabledBackgroundColor:{ref:"inputBackgroundColor"},inputDisabledBorder:{ref:"inputBorder"},inputDisabledTextColor:{ref:"inputTextColor"},inputInvalidBackgroundColor:{ref:"inputBackgroundColor"},inputInvalidBorder:{ref:"inputBorder"},inputInvalidTextColor:{ref:"inputTextColor"},inputIconColor:{ref:"inputTextColor"},pickerButtonBorder:!1,pickerButtonFocusBorder:{ref:"inputFocusBorder"},pickerButtonBackgroundColor:{ref:"backgroundColor"},pickerButtonFocusBackgroundColor:{ref:"backgroundColor"},pickerListBorder:!1,pickerListBackgroundColor:{ref:"backgroundColor"},colorPickerThumbSize:18,colorPickerTrackSize:12,colorPickerThumbBorderWidth:3,colorPickerTrackBorderRadius:12,colorPickerColorBorderRadius:4},h3=lU({feature:"inputStyle",params:{...h2,inputBackgroundColor:l1,inputBorder:!0,inputBorderRadius:{ref:"borderRadius"},inputPaddingStart:{ref:"spacing"},inputFocusBorder:{color:l3},inputFocusShadow:{ref:"focusShadow"},inputDisabledBackgroundColor:l0(.06),inputDisabledTextColor:{ref:"textColor",mix:.5},inputInvalidBorder:{color:{ref:"invalidColor"}},pickerButtonBorder:!0,pickerListBorder:!0},css:()=>h1+".ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){&:focus{box-shadow:var(--ag-focus-shadow);&:where(.invalid),&:where(:invalid){box-shadow:var(--ag-focus-error-shadow)}}}"}),h5=(lU({feature:"inputStyle",params:{...h2,inputBackgroundColor:"transparent",inputBorder:{width:2,color:lQ(.3)},inputPaddingStart:{ref:"spacing"},inputFocusBorder:"solid 2px var(--ag-accent-color)",inputDisabledTextColor:{ref:"textColor",mix:.5},inputDisabledBorder:"solid 1px var(--ag-border-color)",inputInvalidBorder:{width:2,color:{ref:"invalidColor",mix:.3}}},css:()=>h1+".ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){border-left:none;border-right:none;border-top:none}"}),'.ag-tabs-header{background-color:var(--ag-tab-bar-background-color);border-bottom:var(--ag-tab-bar-border);display:flex;flex:1;gap:var(--ag-tab-spacing);padding:var(--ag-tab-bar-top-padding) var(--ag-tab-bar-horizontal-padding) 0}.ag-tabs-header-wrapper{display:flex}.ag-tabs-close-button-wrapper{align-items:center;border:0;display:flex;padding:var(--ag-spacing)}:where(.ag-ltr) .ag-tabs-close-button-wrapper{border-right:solid var(--ag-border-width) var(--ag-border-color)}:where(.ag-rtl) .ag-tabs-close-button-wrapper{border-left:solid var(--ag-border-width) var(--ag-border-color)}.ag-tabs-close-button{background-color:unset;border:0;cursor:pointer;padding:0}.ag-tab{align-items:center;background-color:var(--ag-tab-background-color);border-left:var(--ag-tab-selected-border-width) solid transparent;border-right:var(--ag-tab-selected-border-width) solid transparent;color:var(--ag-tab-text-color);cursor:pointer;display:flex;flex:1;justify-content:center;padding:var(--ag-tab-top-padding) var(--ag-tab-horizontal-padding) var(--ag-tab-bottom-padding);position:relative;&:hover{background-color:var(--ag-tab-hover-background-color);color:var(--ag-tab-hover-text-color)}&.ag-tab-selected{background-color:var(--ag-tab-selected-background-color);color:var(--ag-tab-selected-text-color)}&:after{background-color:var(--ag-tab-selected-underline-color);bottom:0;content:"";display:block;height:var(--ag-tab-selected-underline-width);left:0;opacity:0;position:absolute;right:0;transition:opacity var(--ag-tab-selected-underline-transition-duration)}&.ag-tab-selected:after{opacity:1}}:where(.ag-ltr) .ag-tab{&.ag-tab-selected{&:where(:not(:first-of-type)){border-left-color:var(--ag-tab-selected-border-color)}
377&:where(:not(:last-of-type)){border-right-color:var(--ag-tab-selected-border-color)}}}:where(.ag-rtl) .ag-tab{&.ag-tab-selected{&:where(:not(:first-of-type)){border-right-color:var(--ag-tab-selected-border-color)}&:where(:not(:last-of-type)){border-left-color:var(--ag-tab-selected-border-color)}}}'),h4={tabBarBackgroundColor:"transparent",tabBarHorizontalPadding:0,tabBarTopPadding:0,tabBackgroundColor:"transparent",tabTextColor:{ref:"textColor"},tabHorizontalPadding:{ref:"spacing"},tabTopPadding:{ref:"spacing"},tabBottomPadding:{ref:"spacing"},tabSpacing:"0",tabHoverBackgroundColor:{ref:"tabBackgroundColor"},tabHoverTextColor:{ref:"tabTextColor"},tabSelectedBackgroundColor:{ref:"tabBackgroundColor"},tabSelectedTextColor:{ref:"tabTextColor"},tabSelectedBorderWidth:{ref:"borderWidth"},tabSelectedBorderColor:"transparent",tabSelectedUnderlineColor:"transparent",tabSelectedUnderlineWidth:0,tabSelectedUnderlineTransitionDuration:0,tabBarBorder:!1},h6=lU({feature:"tabStyle",params:{...h4,tabBarBorder:!0,tabBarBackgroundColor:lQ(.05),tabTextColor:{ref:"textColor",mix:.7},tabSelectedTextColor:{ref:"textColor"},tabHoverTextColor:{ref:"textColor"},tabSelectedBorderColor:{ref:"borderColor"},tabSelectedBackgroundColor:l1},css:h5}),h8=(lU({feature:"tabStyle",params:{...h4,tabBarBackgroundColor:{ref:"chromeBackgroundColor"},tabSelectedUnderlineColor:{ref:"primaryColor"},tabSelectedUnderlineWidth:2,tabSelectedUnderlineTransitionDuration:0},css:h5}),lU({feature:"tabStyle",params:{...h4,tabBarBorder:!0,tabBarBackgroundColor:{ref:"chromeBackgroundColor"},tabHoverTextColor:l3,tabSelectedTextColor:l3,tabSelectedUnderlineColor:l3,tabSelectedUnderlineWidth:2,tabSelectedUnderlineTransitionDuration:"0.3s"},css:h5}),lU({feature:"tabStyle",params:{...h4,tabBarBackgroundColor:{ref:"chromeBackgroundColor"},tabBarHorizontalPadding:{ref:"spacing"},tabBarTopPadding:{ref:"spacing"},tabBarBorder:!0,tabHorizontalPadding:{calc:"spacing * 2"},tabTopPadding:{ref:"spacing"},tabBottomPadding:{ref:"spacing"},tabSpacing:{ref:"spacing"},tabSelectedBorderColor:{ref:"borderColor"},tabSelectedBackgroundColor:l1},css:()=>h5+".ag-tab{border-left:var(--ag-tab-selected-border-width) solid transparent;border-right:var(--ag-tab-selected-border-width) solid transparent;border-top:var(--ag-tab-selected-border-width) solid transparent;flex:none;&.ag-tab-selected{border-left-color:var(--ag-tab-selected-border-color);border-right-color:var(--ag-tab-selected-border-color);border-top-color:var(--ag-tab-selected-border-color);margin-bottom:-1px;padding-bottom:calc(var(--ag-tab-bottom-padding) + 1px)}}"}),new dd(hq).withParams(hz).withPart(h$).withPart(hU).withPart(hH).withPart(hK).withPart(hZ).withPart(h0).withPart(h6).withPart(h3).withPart(hU).withParams({fontFamily:[{googleFont:"IBM Plex Sans"},"-apple-system","BlinkMacSystemFont","Segoe UI","Roboto","Oxygen-Sans","Ubuntu"]})),h7=(lU({feature:"styleMaterial",css:".ag-dnd-ghost,.ag-filter-toolpanel-header,.ag-filter-toolpanel-search,.ag-multi-filter-group-title-bar,.ag-panel-title-bar-title,.ag-status-bar{color:var(--ag-header-text-color);font-size:calc(var(--ag-font-size) - 1px);font-weight:600}.ag-column-drop-horizontal{background-color:color-mix(in srgb,var(--ag-background-color),var(--ag-foreground-color) 8%)}.ag-cell.ag-cell-inline-editing{background-color:var(--ag-background-color);background-image:linear-gradient(0deg,var(--ag-input-background-color),var(--ag-input-background-color));border:var(--ag-input-border)!important;border-width:1px!important;height:calc(var(--ag-row-height) + var(--ag-spacing)*3);padding:var(--ag-spacing);:where(.ag-row-last:not(.ag-row-first)) &{bottom:0}:where(.ag-has-focus) &{border:var(--ag-input-focus-border)!important;border-width:1px!important}}.ag-advanced-filter-builder-button,.ag-standard-button{text-transform:uppercase}.ag-status-bar{border:solid var(--ag-border-width) var(--ag-border-color)}.ag-list-item-hovered:after{background-color:var(--ag-primary-color)}.ag-pill-button:hover{color:var(--ag-primary-color)}.ag-header-highlight-after:after,.ag-header-highlight-before:after{background-color:var(--ag-primary-color)}.ag-filter-add-button,.ag-filter-add-button:hover{border-bottom:2px solid var(--ag-primary-color)}",params:a={...o={tabSelectedUnderlineColor:{ref:"primaryColor"},sideButtonSelectedUnderlineColor:{ref:"primaryColor"},buttonTextColor:{ref:"primaryColor"}
377,rangeSelectionBackgroundColor:{ref:"primaryColor",mix:.2},rangeSelectionBorderColor:{ref:"primaryColor"},rangeSelectionHighlightColor:{ref:"primaryColor",mix:.5},rangeHeaderHighlightColor:{ref:"foregroundColor",mix:.08},rowNumbersSelectedColor:{ref:"primaryColor",mix:.5},inputFocusBorder:{width:2,color:{ref:"primaryColor"}},pickerButtonFocusBorder:{width:1,color:{ref:"primaryColor"}},cellEditingBorder:{color:{ref:"primaryColor"}},menuBackgroundColor:{ref:"backgroundColor"},sideButtonBarBackgroundColor:l1,sideButtonSelectedBackgroundColor:"transparent",sideButtonBarTopPadding:{calc:"spacing * 4"},headerColumnResizeHandleColor:"none",headerBackgroundColor:{ref:"backgroundColor"},rowHoverColor:lQ(.08),columnHoverColor:lQ(.08),headerCellHoverBackgroundColor:lQ(.05),statusBarLabelColor:lQ(.63),statusBarLabelFontWeight:600,statusBarValueFontWeight:600,valueChangeValueHighlightBackgroundColor:"#00acc1",panelTitleBarIconColor:l2,advancedFilterBuilderButtonBarBorder:!1,filterPanelApplyButtonColor:{ref:"buttonTextColor"},filterPanelApplyButtonBackgroundColor:{ref:"buttonBackgroundColor"},colorPickerThumbSize:13,colorPickerTrackSize:11,colorPickerThumbBorderWidth:2,colorPickerTrackBorderRadius:2,colorPickerColorBorderRadius:2},primaryColor:"#3f51b5",foregroundColor:"#000D",headerTextColor:"#0008",accentColor:"#ff4081",checkboxUncheckedBorderColor:l2,checkboxIndeterminateBackgroun
377dColor:l2,toggleButtonOffBackgroundColor:l2,selectedRowBackgroundColor:"rgba(33, 150, 243, 0.3)"},modeParams:{light:a,dark:s={...o,primaryColor:"#3f51b5",foregroundColor:"#fffD",headerTextColor:"#fff8",accentColor:"#bb86fc",checkboxUncheckedBorderColor:l0(.5),checkboxIndeterminateBackgroundColor:l0(.5),toggleButtonOffBackgroundColor:l0(.5),selectedRowBackgroundColor:"#bb86fc33"},"dark-blue":s}}),{cssName:"--ag-cell-horizontal-padding",changeKey:"cellHorizontalPaddingChanged",defaultValue:16}),h9={cssName:"--ag-indentation-level",changeKey:"indentationLevelChanged",defaultValue:0,noWarn:!0,cacheDefault:!0},pe={cssName:"--ag-row-group-indent-size",changeKey:"rowGroupIndentSizeChanged",defaultValue:0},pt={cssName:"--ag-row-height",changeKey:"rowHeightChanged",defaultValue:42},pn={cssName:"--ag-header-height",changeKey:"headerHeightChanged",defaultValue:48},pi={cssName:"--ag-list-item-height",changeKey:"listItemHeightChanged",defaultValue:24},pr={cssName:"--ag-row-border",changeKey:"rowBorderWidthChanged",defaultValue:1,border:!0},po={cssName:"--ag-pinned-row-border",changeKey:"pinnedRowBorderWidthChanged",defaultValue:1,border:!0},pa=class extends db{constructor(){super(...arguments),this.sizeEls=new Map,this.lastKnownValues=new Map,this.sizesMeasured=!1}initVariables(){this.addManagedPropertyListener("rowHeight",()=>this.refreshRowHeightVariable()),this.getSizeEl(pt),this.getSizeEl(pn),this.get
377SizeEl(pi),this.getSizeEl(pr),this.getSizeEl(po),this.refreshRowBorderWidthVariable()}getPinnedRowBorderWidth(){return this.getCSSVariablePixelValue(po)}getRowBorderWidth(){return this.getCSSVariablePixelValue(pr)}getDefaultRowHeight(){return this.getCSSVariablePixelValue(pt)}getDefaultHeaderHeight(){return this.getCSSVariablePixelValue(pn)}getDefaultCellHorizontalPadding(){return this.getCSSVariablePixelValue(h7)}getCellPaddingLeft(){let e=this.getDefaultCellHorizontalPadding(),t=this.getCSSVariablePixelValue(h9);return e-1+this.getCSSVariablePixelValue(pe)*t}getCellPadding(){let e=this.getDefaultCellHorizontalPadding()-1;return this.getCellPaddingLeft()+e}getDefaultColumnMinWidth(){return Math.min(36,this.getDefaultRowHeight())}getDefaultListItemHeight(){return this.getCSSVariablePixelValue(pi)}refreshRowHeightVariable(){let{eRootDiv:e}=this,t=e.style.getPropertyValue("--ag-line-height").trim(),n=this.gos.get("rowHeight");if(null==n||isNaN(n)||!isFinite(n))return null!==t&&e.style.setProperty("--ag-line-height",null),-1;let i=`${n}px`;return t!=i?(e.style.setProperty("--ag-line-height",i),n):""!=t?Number.parseFloat(t):-1}getCSSVariablePixelValue(e){let t=this.lastKnownValues.get(e);if(null!=t)return t;let n=this.measureSizeEl(e);return"detached"===n||"no-styles"===n?(e.cacheDefault&&this.lastKnownValues.set(e,e.defaultValue),e.defaultValue):(this.lastKnownValues.set(e,n),n)}measureSizeEl(e){let t=this.getSizeEl(e);if(null==t.offsetParent)return"detached";let n=t.offsetWidth;return n===ps?"no-styles":(this.sizesMeasured=!0,n)}getMeasurementContainer(){let e=this.eMeasurementContainer;return e||(e=this.eMeasurementContainer=om({tag:"div",cls:"ag-measurement-container"}),this.eRootDiv.appendChild(e)),e}getSizeEl(e){let t=this.sizeEls.get(e);if(t)return t;let n=this.getMeasurementContainer();t=om({tag:"div"});let{border:i,noWarn:r}=e;i?(t.className="ag-measurement-element-border",t.style.setProperty("--ag-internal-measurement-border",`var(${e.cssName}, solid ${ps}px)`)):t.style.width=`var(${e.cssName}, ${ps}px)`,n.appendChild(t),this.sizeEls.set(e,t);let o=this.measureSizeEl(e);"no-styles"!==o||r||at(9,{variable:e});let a=oh(this.beans,t,()=>{let t=this.measureSizeEl(e);"detached"!==t&&"no-styles"!==t&&(this.lastKnownValues.set(e,t),t!==o&&(o=t,this.fireStylesChangedEvent(e.changeKey)))});return this.addDestroyFunc(()=>a()),t}fireStylesChangedEvent(e){"rowBorderWidthChanged"===e&&this.refreshRowBorderWidthVariable(),this.eventSvc.dispatchEvent({type:"gridStylesChanged",[e]:!0})}
377refreshRowBorderWidthVariable(){let e=this.getCSSVariablePixelValue(pr);this.eRootDiv.style.setProperty("--ag-internal-row-border-width",`${e}px`)}postProcessThemeChange(e,t){e&&getComputedStyle(this.getMeasurementContainer()).getPropertyValue("--ag-legacy-styles-loaded")&&(t?an(106):an(239))}getAdditionalCss(){let e=new Map;for(let t of(e
vendor: 27,893 bytes, line 377
377.set("core",['.ag-aria-description-container{border:0;z-index:9999;clip:rect(1px,1px,1px,1px);height:1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.ag-unselectable{-webkit-user-select:none;-moz-user-select:none;user-select:none}.ag-selectable{-webkit-user-select:text;-moz-user-select:text;user-select:text}.ag-tab-guard{display:block;height:0;position:absolute;width:0}:where(.ag-virtual-list-viewport) .ag-tab-guard{position:sticky}.ag-tab-guard-top{top:1px}.ag-tab-guard-bottom{bottom:1px}.ag-shake-left-to-right{animation-direction:alternate;animation-duration:.2s;animation-iteration-count:infinite;animation-name:ag-shake-left-to-right}@keyframes ag-shake-left-to-right{0%{padding-left:6px;padding-right:2px}to{padding-left:2px;padding-right:6px}}.ag-body-horizontal-scroll-viewport,.ag-body-vertical-scroll-viewport,.ag-body-viewport,.ag-center-cols-viewport,.ag-floating-bottom-viewport,.ag-floating-top-viewport,.ag-header-viewport,.ag-sticky-bottom-viewport,.ag-sticky-top-viewport,.ag-virtual-list-viewport{flex:1 1 auto;height:100%;min-width:0;overflow:hidden;position:relative}.ag-viewport{position:relative}.ag-spanning-container{position:absolute;top:0;z-index:1}.ag-body-viewport,.ag-center-cols-viewport,.ag-floating-bottom-viewport,.ag-floating-top-viewport,.ag-header-viewport,.ag-sticky-bottom-viewport,.ag-sticky-top-viewport{overflow-x:auto;-ms-overflow-style:none!important;scrollbar-width:none!important;&::-webkit-scrollbar{display:none!important}}.ag-body-viewport{display:flex;overflow-x:hidden;&:where(.ag-layout-normal){overflow-y:auto;-webkit-overflow-scrolling:touch}}.ag-floating-bottom-container,.ag-floating-top-container,.ag-sticky-bottom-container,.ag-sticky-top-container{min-height:1px}.ag-center-cols-viewport{min-height:100%;width:100%}.ag-body-horizontal-scroll-viewport{overflow-x:scroll}.ag-body-vertical-scroll-viewport{overflow-y:scroll}.ag-virtual-list-viewport{overflow:auto;width:100%}.ag-body-container,.ag-body-horizontal-scroll-container,.ag-body-vertical-scroll-container,.ag-center-cols-container,.ag-floating-bottom-container,.ag-floating-bottom-full-width-container,.ag-floating-top-container,.ag-full-width-container,.ag-header-container,.ag-pinned-left-cols-container,.ag-pinned-right-cols-container,.ag-sticky-bottom-container,.ag-sticky-top-container,.ag-virtual-list-container{position:relative}.ag-floating-bottom-container,.ag-floating-top-container,.ag-header-container,.ag-pinned-left-floating-bottom,.ag-pinned-left-floating-top,.ag-pinned-right-floating-bottom,.ag-pinned-right-floating-top,.ag-sticky-bottom-container,.ag-sticky-top-container{height:100%;white-space:nowrap}.ag-center-cols-container,.ag-pinned-right-cols-container{display:block}.ag-body-horizontal-scroll-container{height:100%}.ag-body-vertical-scroll-container{width:100%}.ag-floating-bottom-full-width-container,.ag-floating-top-full-width-container,.ag-full-width-container,.ag-sticky-bottom-full-width-container,.ag-sticky-top-full-width-container{pointer-events:none;position:absolute;top:0}:where(.ag-ltr) .ag-floating-bottom-full-width-container,:where(.ag-ltr) .ag-floating-top-full-width-container,:where(.ag-ltr) .ag-full-width-container,:where(.ag-ltr) .ag-sticky-bottom-full-width-container,:where(.ag-ltr) .ag-sticky-top-full-width-container{left:0}:where(.ag-rtl) .ag-floating-bottom-full-width-container,:where(.ag-rtl) .ag-floating-top-full-width-container,:where(.ag-rtl) .ag-full-width-container,:where(.ag-rtl) .ag-sticky-bottom-full-width-container,:where(.ag-rtl) .ag-sticky-top-full-width-container{right:0}.ag-full-width-container{width:100%}.ag-floating-bottom-full-width-container,.ag-floating-top-full-width-container{display:inline-block;height:100%;overflow:hidden;width:100%}.ag-virtual-list-container{overflow:hidden}.ag-body{display:flex;flex:1 1 auto;flex-direction:row!important;min-height:0;position:relative}.ag-body-horizontal-scroll,.ag-body-vertical-scroll{display:flex;min-height:0;min-width:0;position:relative;&:where(.ag-scrollbar-invisible){bottom:0;position:absolute;&:where(.ag-apple-scrollbar){opacity:0;transition:opacity .4s;visibility:hidden;&:where(.ag-scrollbar-scrolling,.ag-scrollbar-active){opacity:1;visibility:visible}}}}.ag-body-horizontal-scroll{width:100%;&:where(.ag-scrollbar-invisible){left:0;right:0}}.ag-body-vertical-scroll{height:100%;&:where(.ag-scrollbar-invisible){top:0;z-index:10}}:where(.ag-ltr) .ag-body-vertical-scroll{&:where(.ag-scrollbar-invisible){right:0}}:where(.ag-rtl) .ag-body-vertical-scroll{&:where(.ag-scrollbar-invisible){left:0}}.ag-force-vertical-scroll{overflow-y:scroll!important}.ag-horizontal-left-spacer,.ag-horizontal-right-spacer{height:100%;min-width:0;overflow-x:scroll;&:where(.ag-scroller-corner){overflow-x:hidden}}:where(.ag-row-animation) .ag-row{transition:transform .4s,top .4s,opacity .2s;&:where(.ag-after-created){transition:transform .4s,top .4s,height .4s,opacity .2s}}:where(.ag-row-animation.ag-prevent-animation) .ag-row{transition:none!important;&:where(.ag-row.ag-after-created){transition:none!important}}:where(.ag-row-no-animation) .ag-row{transition:none}.ag-row-loading{align-items:center;display:flex}.ag-row-position-absolute{position:absolute}.ag-row-position-relative{position:relative}.ag-full-width-row{overflow:hidden;pointer-events:all}.ag-row-inline-editing{z-index:1}.ag-row-dragging{z-index:2}.ag-stub-cell{align-items:center;display:flex}.ag-cell{display:inline-block;height:100%;position:absolute;white-space:nowrap;&:focus-visible{box-shadow:none}}.ag-cell-value{flex:1 1 auto}.ag-cell-value:not(.ag-allow-overflow),.ag-group-value{overflow:hidden;text-overflow:ellipsis}.ag-cell-wrap-text{white-space:normal;word-break:break-word}:where(.ag-cell) .ag-icon{display:inline-block;vertical-align:middle}.ag-floating-top{display:flex;overflow:hidden;position:relative;white-space:nowrap;width:100%}:where(.ag-floating-top:not(.ag-invisible)){border-bottom:var(--ag-pinned-row-border)}.ag-floating-bottom{display:flex;overflow:hidden;position:relative;white-space:nowrap;width:100%}:where(.ag-floating-bottom:not(.ag-invisible)){border-top:var(--ag-pinned-row-border)}.ag-sticky-bottom,.ag-sticky-top{background-color:var(--ag-data-background-color);display:flex;height:0;overflow:hidden;position:absolute;width:100%;z-index:1}.ag-opacity-zero{opacity:0!important}.ag-cell-label-container{align-items:center;display:flex;flex-direction:row-reverse;height:100%;justify-content:space-between;width:100%}:where(.ag-right-aligned-header){.ag-cell-label-container{flex-direction:row}.ag-header-cell-text{text-align:end}}.ag-column-group-icons{display:block;>*{cursor:pointer}}:where(.ag-ltr){direction:ltr;.ag-body,.ag-body-horizontal-scroll,.ag-body-viewport,.ag-floating-bottom,.ag-floating-top,.ag-header,.ag-sticky-bottom,.ag-sticky-top{flex-direction:row}}:where(.ag-rtl){direction:rtl;text-align:right;.ag-body,.ag-body-horizontal-scroll,.ag-body-viewport,.ag-floating-bottom,.ag-floating-top,.ag-header,.ag-sticky-bottom,.ag-sticky-top{flex-direction:row-reverse}.ag-icon-contracted,.ag-icon-expanded,.ag-icon-tree-closed{display:block}}:where(.ag-rtl){.ag-icon-contracted,.ag-icon-expanded,.ag-icon-tree-closed{transform:rotate(180deg)}}:where(.ag-rtl){.ag-icon-contracted,.ag-icon-expanded,.ag-icon-tree-closed{transform:rotate(-180deg)}}.ag-measurement-container{height:0;overflow:hidden;visibility:hidden;width:0}.ag-measurement-element-border{display:inline-block;&:before{border-left:var(--ag-internal-measurement-border);content:"";display:block}}.ag-group{position:relative;width:100%}.ag-group-title-bar{align-items:center;display:flex;padding:var(--ag-spacing)}.ag-group-title{display:inline;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:where(.ag-group-title-bar) .ag-group-title{cursor:default}.ag-group-toolbar{align-items:center;display:flex;padding:var(--ag-spacing)}.ag-group-container{display:flex}.ag-disabled .ag-group-container{pointer-events:none}.ag-disabled-group-container,.ag-disabled-group-title-bar{opacity:.5}.ag-group-container-horizontal{flex-flow:row wrap}.ag-group-container-vertical{flex-direction:column}.ag-group-title-bar-icon{cursor:pointer;flex:none}:where(.ag-ltr) .ag-group-title-bar-icon{margin-right:var(--ag-spacing)}:where(.ag-rtl) .ag-group-title-bar-icon{margin-left:var(--ag-spacing)}:where(.ag-group-item-alignment-stretch) .ag-group-item{align-items:stretch}:where(.ag-group-item-alignment-start) .ag-group-item{align-items:flex-start}:where(.ag-group-item-alignment-end) .ag-group-item{align-items:flex-end}:where(.ag-ltr) .ag-row:not(.ag-row-level-0) .ag-pivot-leaf-group{margin-left:var(--ag-row-group-indent-size)}:where(.ag-rtl) .ag-row:not(.ag-row-level-0) .ag-pivot-leaf-group{margin-right:var(--ag-row-group-indent-size)}:where(.ag-ltr) .ag-row-group-leaf-indent{margin-left:calc(var(--ag-cell-widget-spacing) + var(--ag-icon-size))}:where(.ag-rtl) .ag-row-group-leaf-indent{margin-right:calc(var(--ag-cell-widget-spacing) + var(--ag-icon-size))}.ag-value-change-delta{padding:0 2px}.ag-value-change-delta-up{color:var(--ag-value-change-delta-up-color)}.ag-value-change-delta-down{color:var(--ag-value-change-delta-down-color)}.ag-value-change-value{background-color:transparent;border-radius:1px;padding-left:1px;padding-right:1px;transition:background-color 1s}.ag-value-change-value-highlight{background-color:var(--ag-value-change-value-highlight-background-color);transition:background-color .1s}.ag-cell-data-changed{background-color:var(--ag-value-change-value-highlight-background-color)!important}.ag-cell-data-changed-animation{background-color:transparent}.ag-cell-highlight{background-color:var(--ag-range-selection-highlight-color)!important}.ag-row,.ag-spanned-row{color:var(--ag-cell-text-color);font-family:var(--ag-cell-font-family);font-size:var(--ag-data-font-size);white-space:nowrap;--ag-internal-content-line-height:calc(min(var(--ag-row-height), var(--ag-line-height, 1000px)) - var(--ag-internal-row-border-width, 1px) - 2px)}.ag-row{background-color:var(--ag-data-background-color);border-bottom:var(--ag-row-border);height:var(--ag-row-height);width:100%;&.ag-row-editing-invalid{background-color:var(--ag-full-row-edit-invalid-background-color)}}:where(.ag-body-vertical-content-no-gap>div>div>div,.ag-body-vertical-content-no-gap>div>div>div>div)>.ag-row-last{border-bottom-color:transparent}.ag-sticky-bottom{border-top:var(--ag-row-border);box-sizing:content-box!important}.ag-group-contracted,.ag-group-expanded{cursor:pointer}.ag-cell,.ag-full-width-row .ag-cell-wrapper.ag-row-group{border:1px solid transparent;line-height:var(--ag-internal-content-line-height);-webkit-font-smoothing:subpixel-antialiased}:where(.ag-ltr) .ag-cell{border-right:var(--ag-column-border)}:where(.ag-rtl) .ag-cell{border-left:var(--ag-column-border)}.ag-spanned-cell-wrapper{background-color:var(--ag-data-background-color);position:absolute}.ag-spanned-cell-wrapper>.ag-spanned-cell{display:block;position:relative}:where(.ag-ltr) :where(.ag-body-horizontal-content-no-gap) .ag-column-last{border-right-color:transparent}:where(.ag-rtl) :where(.ag-body-horizontal-content-no-gap) .ag-column-last{border-left-color:transparent}.ag-cell-wrapper{align-items:center;display:flex;>:where(:not(.ag-cell-value,.ag-group-value)){align-items:center;display:flex;height:var(--ag-internal-content-line-height)}&:where(.ag-row-group){align-items:flex-start}:where(.ag-full-width-row) &:where(.ag-row-group){align-items:center;height:100%}}:where(.ag-ltr) .ag-cell-wrapper{padding-left:calc(var(--ag-indentation-level)*var(--ag-row-group-indent-size))}:where(.ag-rtl) .ag-cell-wrapper{padding-right:calc(var(--ag-indentation-level)*var(--ag-row-group-indent-size))}:where(.ag-cell-wrap-text:not(.ag-cell-auto-height)) .ag-cell-wrapper{align-items:normal;height:100%;:where(.ag-cell-value){height:100%}}:where(.ag-ltr) .ag-row>.ag-cell-wrapper.ag-row-group{padding-left:calc(var(--ag-cell-horizontal-padding) + var(--ag-row-group-indent-size)*var(--ag-indentation-level))}:where(.ag-rtl) .ag-row>.ag-cell-wrapper.ag-row-group{padding-right:calc(var(--ag-cell-horizontal-padding) + var(--ag-row-group-indent-size)*var(--ag-indentation-level))}.ag-cell-focus:not(.ag-cell-range-selected):focus-within,.ag-cell-range-single-cell,.ag-cell-range-single-cell.ag-cell-range-handle,.ag-context-menu-open .ag-cell-focus:not(.ag-cell-range-selected),.ag-context-menu-open .ag-full-width-row.ag-row-focus .ag-cell-wrapper.ag-row-group,.ag-full-width-row.ag-row-focus:focus .ag-cell-wrapper.ag-row-group{border:1px solid;border-color:var(--ag-range-selection-border-color);border-style:var(--ag-range-selection-border-style);outline:initial}.ag-full-width-row.ag-row-focus:focus{box-shadow:none}:where(.ag-ltr) .ag-group-contracted,:where(.ag-ltr) .ag-group-expanded,:where(.ag-ltr) .ag-row-drag,:where(.ag-ltr) .ag-selection-checkbox{margin-right:var(--ag-cell-widget-spacing)}:where(.ag-rtl) .ag-group-contracted,:where(.ag-rtl) .ag-group-expanded,:where(.ag-rtl) .ag-row-drag,:where(.ag-rtl) .ag-selection-checkbox{margin-left:var(--ag-cell-widget-spacing)}:where(.ag-ltr) .ag-group-child-count{margin-left:3px}:where(.ag-rtl) .ag-group-child-count{margin-right:3px}.ag-row-highlight-above:after,.ag-row-highlight-below:after,.ag-row-highlight-inside:after{background-color:var(--ag-range-selection-border-color);content:"";height:1px;pointer-events:none;position:absolute;width:calc(100% - 1px)}:where(.ag-ltr) .ag-row-highlight-above:after,:where(.ag-ltr) .ag-row-highlight-below:after,:where(.ag-ltr) .ag-row-highlight-inside:after{left:1px}:where(.ag-rtl) .ag-row-highlight-above:after,:where(.ag-rtl) .ag-row-highlight-below:after,:where(.ag-rtl) .ag-row-highlight-inside:after{right:1px}.ag-row-highlight-above:after{top:0}.ag-row-highlight-below:after{bottom:0}.ag-row-highlight-indent:after{display:block;width:auto}:where(.ag-ltr) .ag-row-highlight-indent:after{left:calc((var(--ag-cell-widget-spacing) + var(--ag-icon-size))*2 + var(--ag-cell-horizontal-padding) + var(--ag-row-highlight-level)*var(--ag-row-group-indent-size));right:1px}:where(.ag-rtl) .ag-row-highlight-indent:after{left:1px;right:calc((var(--ag-cell-widget-spacing) + var(--ag-icon-size))*2 + var(--ag-cell-horizontal-padding) + var(--ag-row-highlight-level)*var(--ag-row-group-indent-size))}.ag-row-highlight-inside:after{background-color:var(--ag-selected-row-background-color);border:1px solid var(--ag-range-selection-border-color);display:block;height:auto;inset:0;width:auto}.ag-body,.ag-floating-bottom,.ag-floating-top{background-color:var(--ag-data-background-color)}.ag-row-odd{background-color:var(--ag-odd-row-background-color)}.ag-row-selected:before{background-color:var(--ag-selected-row-background-color);content:"";display:block;inset:0;pointer-events:none;position:absolute}.ag-row-hover.ag-full-width-row.ag-row-group:before,.ag-row-hover:not(.ag-full-width-row):before{background-color:var(--ag-row-hover-color);content:"";display:block;inset:0;pointer-events:none;position:absolute}.ag-row-hover.ag-row-selected:before{background-color:var(--ag-row-hover-color);background-image:linear-gradient(var(--ag-selected-row-background-color),var(--ag-selected-row-background-color))}.ag-row.ag-full-width-row.ag-row-group>*{position:relative}.ag-column-hover{background-color:var(--ag-column-hover-color)}.ag-header-range-highlight{background-color:var(--ag-range-header-highlight-color)}.ag-right-aligned-cell{font-variant-numeric:tabular-nums}:where(.ag-ltr) .ag-right-aligned-cell{text-align:right}:where(.ag-rtl) .ag-right-aligned-cell{text-align:left}.ag-right-aligned-cell .ag-cell-value,.ag-right-aligned-cell .ag-group-value{margin-left:auto}:where(.ag-ltr) .ag-cell:not(.ag-cell-inline-editing),:where(.ag-ltr) .ag-full-width-row .ag-cell-wrapper.ag-row-group{padding-left:calc(var(--ag-cell-horizontal-padding) - 1px + var(--ag-row-group-indent-size)*var(--ag-indentation-level));padding-right:calc(var(--ag-cell-horizontal-padding) - 1px)}:where(.ag-rtl) .ag-cell:not(.ag-cell-inline-editing),:where(.ag-rtl) .ag-full-width-row .ag-cell-wrapper.ag-row-group{padding-left:calc(var(--ag-cell-horizontal-padding) - 1px);padding-right:calc(var(--ag-cell-horizontal-padding) - 1px + var(--ag-row-group-indent-size)*var(--ag-indentation-level))}.ag-row>.ag-cell-wrapper{padding-left:calc(var(--ag-cell-horizontal-padding) - 1px);padding-right:calc(var(--ag-cell-horizontal-padding) - 1px)}.ag-row-dragging{cursor:move;opacity:.5}.ag-details-row{background-color:var(--ag-data-background-color);padding:calc(var(--ag-spacing)*3.75)}.ag-layout-auto-height,.ag-layout-print{.ag-center-cols-container,.ag-center-cols-viewport{min-height:150px}}.ag-overlay-loading-wrapper{background-color:var(--ag-modal-overlay-background-color)}.ag-skeleton-container{align-content:center;height:100%;width:100%}.ag-skeleton-effect{animation:ag-skeleton-loading 1.5s ease-in-out .5s infinite;background-color:var(--ag-row-loading-skeleton-effect-color);border-radius:.25rem;height:1em;width:100%}:where(.ag-ltr) .ag-right-aligned-cell .ag-skeleton-effect{margin-left:auto}:where(.ag-rtl) .ag-right-aligned-cell .ag-skeleton-effect{margin-right:auto}@keyframes ag-skeleton-loading{0%{background-color:var(--ag-row-loading-skeleton-effect-color)}50%{background-color:color-mix(in srgb,transparent,var(--ag-row-loading-skeleton-effect-color) 40%)}to{background-color:var(--ag-row-loading-skeleton-effect-color)}}.ag-loading{align-items:center;display:flex;height:100%}:where(.ag-ltr) .ag-loading{padding-left:var(--ag-cell-horizontal-padding)}:where(.ag-rtl) .ag-loading{padding-right:var(--ag-cell-horizontal-padding)}:where(.ag-ltr) .ag-loading-icon{padding-right:var(--ag-cell-widget-spacing)}:where(.ag-rtl) .ag-loading-icon{padding-left:var(--ag-cell-widget-spacing)}.ag-icon-loading{animation-duration:1s;animation-iteration-count:infinite;animation-name:spin;animation-timing-function:linear}@keyframes spin{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}.ag-header{background-color:var(--ag-header-background-color);border-bottom:var(--ag-header-row-border);color:var(--ag-header-text-color);display:flex;font-family:var(--ag-header-font-family);font-size:var(--ag-header-font-size);font-weight:var(--ag-header-font-weight);overflow:hidden;white-space:nowrap;width:100%}.ag-header-row{height:var(--ag-header-height);position:absolute}.ag-floating-filter-button-button,.ag-header-cell-filter-button,.ag-header-cell-menu-button,.ag-header-expand-icon,.ag-panel-title-bar-button,:where(.ag-header-cell-sortable) .ag-header-cell-label{cursor:pointer}:where(.ag-ltr) .ag-header-expand-icon{margin-left:4px}:where(.ag-rtl) .ag-header-expand-icon{margin-right:4px}.ag-header-row:where(:not(:first-child)){:where(.ag-header-cell:not(.ag-header-span-height.ag-header-span-total,.ag-header-parent-hidden),.ag-header-group-cell.ag-header-group-cell-with-group){border-top:var(--ag-header-row-border)}}.ag-header-row:where(:not(.ag-header-row-column-group)){overflow:hidden}:where(.ag-header.ag-header-allow-overflow) .ag-header-row{overflow:visible}.ag-header-cell{display:inline-flex;overflow:hidden}.ag-header-group-cell{contain:paint;display:flex}.ag-header-cell,.ag-header-group-cell{align-items:center;gap:var(--ag-cell-widget-spacing);height:100%;padding:0 var(--ag-cell-horizontal-padding);position:absolute}@property --ag-internal-moving-color{syntax:"<color>";inherits:false;initial-value:transparent}@property --ag-internal-hover-color{syntax:"<color>";inherits:false;initial-value:transparent}.ag-header-cell:where(:not(.ag-floating-filter)),.ag-header-group-cell{&:before{background-image:linear-gradient(var(--ag-internal-hover-color),var(--ag-internal-hover-color)),linear-gradient(var(--ag-internal-moving-color),var(--ag-internal-moving-color));content:"";inset:0;position:absolute;--ag-internal-moving-color:transparent;--ag-internal-hover-color:transparent;transition:--ag-internal-moving-color var(--ag-header-cell-background-transition-duration),--ag-internal-hover-color var(--ag-header-cell-background-transition-duration)}&:where(:hover):before{--ag-internal-hover-color:var(--ag-header-cell-hover-background-color)}&:where(.ag-header-cell-moving):before{--ag-internal-moving-color:var(--ag-header-cell-moving-background-color);--ag-internal-hover-color:var(--ag-header-cell-hover-background-color)}}:where(.ag-header-cell:not(.ag-floating-filter) *,.ag-header-group-cell *){position:relative;z-index:1}.ag-header-cell-menu-button:where(:not(.ag-header-menu-always-show)){opacity:0;transition:opacity .2s}.ag-header-cell-filter-button,:where(.ag-header-cell.ag-header-active) .ag-header-cell-menu-button{opacity:1}.ag-header-cell-label,.ag-header-group-cell-label{align-items:center;align-self:stretch;display:flex;flex:1 1 auto;overflow:hidden;padding:5px 0}:where(.ag-ltr) .ag-sort-indicator-icon{padding-left:var(--ag-spacing)}:where(.ag-rtl) .ag-sort-indicator-icon{padding-right:var(--ag-spacing)}.ag-header-cell-label{text-overflow:ellipsis}.ag-header-group-cell-label.ag-sticky-label{flex:none;max-width:100%;overflow:visible;position:sticky}:where(.ag-ltr) .ag-header-group-cell-label.ag-sticky-label{left:var(--ag-cell-horizontal-padding)}:where(.ag-rtl) .ag-header-group-cell-label.ag-sticky-label{right:var(--ag-cell-horizontal-padding)}.ag-header-cell-text,.ag-header-group-text{overflow:hidden;text-overflow:ellipsis}.ag-header-cell-text{word-break:break-word}.ag-header-cell-comp-wrapper{width:100%}:where(.ag-header-group-cell) .ag-header-cell-comp-wrapper{display:flex}:where(.ag-header-cell:not(.ag-header-cell-auto-height)) .ag-header-cell-comp-wrapper{align-items:center;display:flex;height:100%}.ag-header-cell-wrap-text .ag-header-cell-comp-wrapper{white-space:normal}.ag-header-cell-comp-wrapper-limited-height>*{overflow:hidden}:where(.ag-right-aligned-header) .ag-header-cell-label{flex-direction:row-reverse}:where(.ag-ltr) :where(.ag-header-cell:not(.ag-right-aligned-header)){.ag-header-label-icon,.ag-header-menu-icon{margin-left:var(--ag-spacing)}}:where(.ag-rtl) :where(.ag-header-cell:not(.ag-right-aligned-header)){.ag-header-label-icon,.ag-header-menu-icon{margin-right:var(--ag-spacing)}}:where(.ag-ltr) :where(.ag-header-cell.ag-right-aligned-header){.ag-header-label-icon,.ag-header-menu-icon{margin-right:var(--ag-spacing)}}:where(.ag-rtl) :where(.ag-header-cell.ag-right-aligned-header){.ag-header-label-icon,.ag-header-menu-icon{margin-left:var(--ag-spacing)}}.ag-header-cell:after,.ag-header-group-cell:where(:not(.ag-header-span-height.ag-header-group-cell-no-group)):after{content:"";height:var(--ag-header-column-border-height);position:absolute;top:calc(50% - var(--ag-header-column-border-height)*.5);z-index:1}:where(.ag-ltr) .ag-header-cell:after,:where(.ag-ltr) .ag-header-group-cell:where(:not(.ag-header-span-height.ag-header-group-cell-no-group)):after{border-right:var(--ag-header-column-border);right:0}:where(.ag-rtl) .ag-header-cell:after,:where(.ag-rtl) .ag-header-group-cell:where(:not(.ag-header-span-height.ag-header-group-cell-no-group)):after{border-left:var(--ag-header-column-border);left:0}.ag-header-highlight-after:after,.ag-header-highlight-before:after{background-color:var(--ag-accent-color);content:"";height:100%;position:absolute;width:1px}:where(.ag-ltr) .ag-header-highlight-before:after{left:0}:where(.ag-rtl) .ag-header-highlight-before:after{right:0}:where(.ag-ltr) .ag-header-highlight-after:after{right:0;:where(.ag-pinned-left-header) &{right:1px}}:where(.ag-rtl) .ag-header-highlight-after:after{left:0;:where(.ag-pinned-left-header) &{left:1px}}.ag-header-cell-resize{align-items:center;cursor:ew-resize;display:flex;height:100%;position:absolute;top:0;width:8px;z-index:2;&:after{background-color:var(--ag-header-column-resize-handle-color);content:"";height:var(--ag-header-column-resize-handle-height);position:absolute;top:calc(50% - var(--ag-header-column-resize-handle-height)*.5);width:var(--ag-header-column-resize-handle-width);z-index:1}}:where(.ag-ltr) .ag-header-cell-resize{right:-3px;&:after{left:calc(50% - var(--ag-header-column-resize-handle-width))}}:where(.ag-rtl) .ag-header-cell-resize{left:-3px;&:after{right:calc(50% - var(--ag-header-column-resize-handle-width))}}:where(.ag-header-cell.ag-header-span-height) .ag-header-cell-resize:after{height:calc(100% - var(--ag-spacing)*4);top:calc(var(--ag-spacing)*2)}.ag-header-group-cell-no-group:where(.ag-header-span-height){display:none}.ag-sort-indicator-container{display:flex;gap:var(--ag-spacing)}.ag-layout-print{&.ag-body{display:block;height:unset}&.ag-root-wrapper{display:inline-block}.ag-body-horizontal-scroll,.ag-body-vertical-scroll{display:none}&.ag-force-vertical-scroll{overflow-y:visible!important}}@media print{.ag-root-wrapper.ag-layout-print{display:table;.ag-body-horizontal-scroll-viewport,.ag-body-viewport,.ag-center-cols-container,.ag-center-cols-viewport,.ag-root,.ag-root-wrapper-body,.ag-virtual-list-viewport{display:block!important;height:auto!important;overflow:hidden!important}.ag-cell,.ag-row{-moz-column-break-inside:avoid;break-inside:avoid}}}ag-grid,ag-grid-angular{display:block}.ag-root-wrapper{border:var(--ag-wrapper-border);border-radius:var(--ag-wrapper-border-radius);display:flex;flex-direction:column;overflow:hidden;position:relative;&.ag-layout-normal{height:100%}}.ag-root-wrapper-body{display:flex;flex-direction:row;&.ag-layout-normal{flex:1 1 auto;height:0;min-height:0}}.ag-root{display:flex;flex-direction:column;position:relative;&.ag-layout-auto-height,&.ag-layout-normal{flex:1 1 auto;overflow:hidden;width:0}&.ag-layout-normal{height:100%}}.ag-virtual-list-item{height:var(--ag-list-item-height);position:absolute;width:100%}.ag-list-item-hovered:after{background-color:var(--ag-accent-color);content:"";height:1px;left:0;position:absolute;right:0}.ag-item-highlight-top:after{top:0}.ag-item-highlight-bottom:after{bottom:0}.ag-drag-handle{color:var(--ag-drag-handle-color);cursor:grab;:where(.ag-icon){color:var(--ag-drag-handle-color)}}.ag-chart-menu-icon,.ag-chart-settings-next,.ag-chart-settings-prev,.ag-column-group-icons,.ag-column-select-header-icon,.ag-filter-toolpanel-expand,.ag-floating-filter-button-button,.ag-group-title-bar-icon,.ag-header-cell-filter-button,.ag-header-cell-menu-button,.ag-header-expand-icon,.ag-panel-title-bar-button,.ag-panel-title-bar-button-icon,.ag-set-filter-group-icons,:where(.ag-group-contracted) .ag-icon,:where(.ag-group-expanded) .ag-icon{background-color:var(--ag-icon-button-background-color);border-radius:var(--ag-icon-button-border-radius);box-shadow:0 0 0 var(--ag-icon-button-background-spread) var(--ag-icon-button-background-color);color:var(--ag-icon-button-color);&:hover{background-color:var(--ag-icon-button-hover-background-color);box-shadow:0 0 0 var(--ag-icon-button-background-spread) var(--ag-icon-button-hover-background-color);color:var(--ag-icon-button-hover-color)}}.ag-filter-active{background-image:linear-gradient(var(--ag-icon-button-active-background-color),var(--ag-icon-button-active-background-color));border-radius:1px;outline:solid var(--ag-icon-button-background-spread) var(--ag-icon-button-active-background-color);position:relative;&:after{background-color:var(--ag-icon-button-active-indicator-color);border-radius:50%;content:"";height:6px;position:absolute;top:-1px;width:6px}:where(.ag-icon-filter){clip-path:path("M8,0C8,4.415 11.585,8 16,8L16,16L0,16L0,0L8,0Z");color:var(--ag-icon-button-active-color)}}:where(.ag-ltr) .ag-filter-active{&:after{right:-1px}}:where(.ag-rtl) .ag-filter-active{&:after{left:-1px}}.ag-menu{background-color:var(--ag-menu-background-color);border:var(--ag-menu-border);border-radius:var(--ag-border-radius);box-shadow:var(--ag-menu-shadow);color:var(--ag-menu-text-color);max-height:100%;overflow-y:auto;position:absolute;-webkit-user-select:none;-moz-user-select:none;user-select:none}']),
377Array.from(new Set(oK)).sort((e,t)=>
377e.moduleName.localeCompare(t.moduleName)))){let n=t.css;n&&e.set(`module-${t.moduleName}`,n)}return e}getDefaultTheme(){return h8}themeError(e){an(240,{theme:e})}},ps=15538,pl=class extends dw{postConstruct(){let{globalListener:e,globalSyncListener:t}=this.beans;e&&this.addGlobalListener(e,!0),t&&this.addGlobalListener(t,!1)}};function pd(e,t,n){let i=e.visibleCols.headerGroupRowCount;if(n>=i)return{column:t,headerRowIndex:n};let r=t.getParent();for(;r&&r.getProvidedColumnGroup().getLevel()>n;)r=r.getParent();let o=t.isSpanHeaderHeight();return!r||o&&r.isPadding()?{column:t,headerRowIndex:i}:{column:r,headerRowIndex:r.getProvidedColumnGroup().getLevel()}}var pu=class extends oI{constructor(){super(...arguments),this.beanName="headerNavigation",this.currentHeaderRowWithoutSpan=-1}postConstruct(){let e=this.beans;e.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl});let t=rP(e);this.addManagedElementListeners(t,{mousedown:()=>{this.currentHeaderRowWithoutSpan=-1}})}getHeaderPositionForColumn(e,t){let n,{colModel:i,colGroupSvc:r,ctrlsSvc:o}=this.beans;if("string"==typeof e?(n=i.getCol(e))||(n=r?.getColumnGroup(e)??null):n=e,!n)return null;let a=o.getHeaderRowContainerCtrl(),s="filter"===aY(a?.getAllCtrls()||[]).type,l=u3(this.beans)-1,d=-1,u=n;for(;u;)d++,u=u.getParent();let c=d;return t&&s&&c===l-1&&c++,-1===c?null:{headerRowIndex:c,column:n}}navigateVertically(e,t){let{focusSvc:n,visibleCols:i}=this.beans,{focusedHeader:r}=n;if(!r)return!1;let{headerRowIndex:o}=r,a=r.column,s=u3(this.beans),l=this.getHeaderRowType(o),d=i.headerGroupRowCount,{headerRowIndex:u,column:c,headerRowIndexWithoutSpan:h}="UP"===e?function(e,t,n){let i=n-1;if("filter"!==e){let e=t instanceof aG&&t.isSpanHeaderHeight(),n=t.getParent();for(;n&&(n.getProvidedColumnGroup().getLevel()>i||e&&n.isPadding());)n=n.getParent();if(n)if(e)return{column:n,headerRowIndex:n.getProvidedColumnGroup().getLevel(),headerRowIndexWithoutSpan:i};else return{column:n,headerRowIndex:i,headerRowIndexWithoutSpan:i}}return{column:t,headerRowIndex:i,headerRowIndexWithoutSpan:i}}(l,a,o):function(e,t,n){let i=t+1,r={column:e,headerRowIndex:i,headerRowIndexWithoutSpan:i};if(e instanceof dF){if(i>=n)return{column:e.getDisplayedLeafColumns()[0],headerRowIndex:n,headerRowIndexWithoutSpan:i};let t=e.getDisplayedChildren()[0];if(t instanceof dF&&t.isPadding()){let e=t.getDisplayedLeafColumns()[0];e.isSpanHeaderHeight()&&(t=e)}r.column=t,t instanceof aG&&t.isSpanHeaderHeight()&&(r.headerRowIndex=n,r.headerRowIndexWithoutSpan=i)}return r}(a,o,d),p=!1;return u<0&&(u=0,c=a,p=!0),u>=s?(u=-1,this.currentHeaderRowWithoutSpan=-1):void 0!==h&&(this.currentHeaderRowWithoutSpan=h),(!!p||!!c)&&n.focusHeaderPosition({headerPosition:{headerRowIndex:u,column:c},allowUserOverride:!0,event:t})}navigateHorizontally(e,t=!1,n){let i,r,{focusSvc:o,gos:a}=this.beans,s={...o.focusedHeader};-1!==this.currentHeaderRowWithoutSpan?s.headerRowIndex=this.currentHeaderRowWithoutSpan:this.currentHeaderRowWithoutSpan=s.headerRowIndex,r="LEFT"===e!==a.get("enableRtl")?"Before":"After",i=this.findHeader(s,r);let l=a.getCallback("tabToNextHeader");if(t&&l){let e=o.focusHeaderPositionFromUserFunc({userFunc:l,headerPosition:i,direction:r});if(e){let{headerRowIndex:e}=o.focusedHeader||{};null!=e&&e!=s.headerRowIndex&&(this.currentHeaderRowWithoutSpan=e)}return e}return i||!t?o.focusHeaderPosition({headerPosition:i,direction:r,fromTab:t,allowUserOverride:!0,event:n}):this.focusNextHeaderRow(s,r,n)}focusNextHeaderRow(e,t,n){let i,r=this.beans,o=e.headerRowIndex,a=null,s=u3(r),l=this.beans.visibleCols.allCols;if("Before"===t){if(o<=0)return!1;a=aY(l),i=o-1,this.currentHeaderRowWithoutSpan-=1}else a=l[0],i=o+1,this.currentHeaderRowWithoutSpan<s?this.currentHeaderRowWithoutSpan+=1:this.currentHeaderRowWithoutSpan=-1;let{column:d,headerRowIndex:u}=pd(this.beans,a,i);return u>=s&&(u=-1),r.focusSvc.focusHeaderPosition({headerPosition:{column:d,headerRowIndex:u},direction:t,fromTab:!0,allowUserOverride:!0,event:n})}scrollToColumn(e,t="After"){let n;if(!e.getPinned()){if(dL(e)){let i=e.getDisplayedLeafColumns();n="Before"===t?aY(i):i[0]}else n=e;this.gridBodyCon.scrollFeature.ensureColumnVisible(n)}}
377findHeader(e,t){let{colGroupSvc:n,visibleCols:i}=this.beans,r=e.column;if(r instanceof dF){let e=r.getDisplayedLeafColumns();r="Before"===t?e[0]:e[e.length-1]}let o="Before"===t?i.getColBefore(r):i.getColAfter(r);if(!o)return;let a=i.headerGroupRowCount;if(e.headerRowIndex>=a)return{headerRowIndex:e.headerRowIndex,column:o};let s=n?.getColGroupAtLevel(o,e.headerRowIndex);return s?s.isPadding()&&o.isSpanHeaderHeight()?{headerRowIndex:i.headerGroupRowCount,column:o}:{headerRowIndex:e.headerRowIndex,column:s??o}:{headerRowIndex:o instanceof aG&&o.isSpanHeaderHeight()?i.headerGroupRowCount:e.headerRowIndex,column:o}}getHeaderRowType(e){let t=this.beans.ctrlsSvc.getHeaderRowContainerCtrl();if(t)return t.getRowType(e)}},pc=class extends oI{constructor(){super(...arguments),this.beanName="focusSvc",this.focusFallbackTimeout=null,this.needsFocusRestored=!1}wireBeans(e){this.colModel=e.colModel,this.visibleCols=e.visibleCols,this.rowRenderer=e.rowRenderer,this.navigation=e.navigation,this.filterManager=e.filterManager,this.overlays=e.overlays}postConstruct(){let e,t=this.clearFocusedCell.bind(this);this.addManagedEventListeners({columnPivotModeChanged:t,newColumnsLoaded:this.onColumnEverythingChanged.bind(this),columnGroupOpened:t,columnRowGroupChanged:t}),this.addDestroyFunc((e=rP(this.beans),lw>0||(e.addEventListener("keydown",lC),e.addEventListener("mousedown",lC)),lw++,()=>{--lw>0||(e.removeEventListener("keydown",lC),e.removeEventListener("mousedown",lC))}))}attemptToRecoverFocus(){this.needsFocusRestored=!0,null!=this.focusFallbackTimeout&&clearTimeout(this.focusFallbackTimeout),this.focusFallbackTimeout=window.setTimeout(this.setFocusRecovered.bind(this),100)}setFocusRecovered(){this.needsFocusRestored=!1,null!=this.focusFallbackTimeout&&(clearTimeout(this.focusFallbackTimeout),this.focusFallbackTimeout=null)}shouldTakeFocus(){return this.gos.get("suppressFocusAfterRefresh")?(this.setFocusRecovered(),!1):this.needsFocusRestored?(this.setFocusRecovered(),!0):this.doesRowOrCellHaveBrowserFocus()}onColumnEverythingChanged(){if(!this.focusedCell)return;let e=this.focusedCell.column,t=this.colModel.getCol(e.getId());e!==t&&this.clearFocusedCell()}getFocusCellToUseAfterRefresh(){let{gos:e,focusedCell:t}=this;return e.get("suppressFocusAfterRefresh")||e.get("suppressCellFocus")||!t||!this.doesRowOrCellHaveBrowserFocus()?null:t}getFocusHeaderToUseAfterRefresh(){return!this.gos.get("suppressFocusAfterRefresh")&&this.focusedHeader&&this.isDomDataPresentInHierarchy(rA(this.beans),cn)?this.focusedHeader:null}doesRowOrCellHaveBrowserFocus(){let e=rA(this.beans);return!!this.isDomDataPresentInHierarchy(e,uw)||this.isDomDataPresentInHierarchy(e,uC)}isDomDataPresentInHierarchy(e,t){let n=e;for(;n;){if(af(this.gos,n,t))return!0;n=n.parentNode}return!1}getFocusedCell(){return this.focusedCell}getFocusEventParams(e){let{rowIndex:t,rowPinned:n,column:i}=e,r={rowIndex:t,rowPinned:n,column:i,isFullWidthCell:!1},o=this.rowRenderer.getRowByPosition({rowIndex:t,rowPinned:n});return o&&(r.isFullWidthCell=o.isFullWidth()),r}clearFocusedCell(){if(null==this.focusedCell)return;let e=this.getFocusEventParams(this.focusedCell);this.focusedCell=null,this.eventSvc.dispatchEvent({type:"cellFocusCleared",...e})}setFocusedCell(e){this.setFocusRecovered();let{column:t,rowIndex:n,rowPinned:i,forceBrowserFocus:r=!1,preventScrollOnBrowserFocus:o=!1,sourceEvent:a}=e,s=this.colModel.getCol(t);if(!s){this.focusedCell=null;return}this.focusedCell={rowIndex:n,rowPinned:rw(i),column:s};let l=this.getFocusEventParams(this.focusedCell);this.eventSvc.dispatchEvent({type:"cellFocused",...l,...this.previousCellFocusParams&&{previousParams:this.previousCellFocusParams},forceBrowserFocus:r,preventScrollOnBrowserFocus:o,sourceEvent:a}),this.previousCellFocusParams=l}isCellFocused(e){return null!=this.focusedCell&&c3(e,this.focusedCell)}isHeaderWrapperFocused(e){if(null==this.focusedHeader)return!1;let{column:t,rowCtrl:{rowIndex:n,pinned:i}}=e,{column:r,headerRowIndex:o}=this.focusedHeader;return t===r&&n===o&&i==r.getPinned()}focusHeaderPosition(e){if(this.setFocusRecovered(),u0(this.beans))return!1;let{direction:t,fromTab:n,allowUserOverride:i,event:r,fromCell:o,rowWithoutSpanValue:a,scroll:s=!0}=e,{headerPosition:l}=e;if(o&&this.filterManager?.isAdvFilterHeaderActive())return this.focusAdvancedFilter(l);
377if(i){let e=this.focusedHeader,i=u3(this.beans);if(n){let n=this.gos.getCallback("tabToNextHeader");n&&(l=this.getHeaderPositionFromUserFunc({userFunc:n,direction:t,currentPosition:e,headerPosition:l,headerRowCount:i}))}else{let t=this.gos.getCallback("navigateToNextHeader");t&&r&&(l=t({key:r.key,previousHeaderPosition:e,nextHeaderPosition:l,headerRowCount:i,event:r}))}}return!!l&&this.focusProvidedHeaderPosition({headerPosition:l,direction:t,event:r,fromCell:o,rowWithoutSpanValue:a,scroll:s})}focusHeaderPositionFromUserFunc(e){if(u0(this.beans))return!1;let{userFunc:t,headerPosition:n,direction:i,event:r}=e,o=this.focusedHeader,a=u3(this.beans),s=this.getHeaderPositionFromUserFunc({userFunc:t,direction:i,currentPosition:o,headerPosition:n,headerRowCount:a});return!!s&&this.focusProvidedHeaderPosition({headerPosition:s,direction:i,event:r})}getHeaderPositionFromUserFunc(e){let{userFunc:t,direction:n,currentPosition:i,headerPosition:r,headerRowCount:o}=e,a=t({backwards:"Before"===n,previousHeaderPosition:i,nextHeaderPosition:r,headerRowCount:o});return!0===a?i:!1===a?null:a}focusProvidedHeaderPosition(e){var t,n;let{headerPosition:i,direction:r,fromCell:o,rowWithoutSpanValue:a,event:s,scroll:l=!0}=e,{column:d,headerRowIndex:u}=i,{filterManager:c,ctrlsSvc:h,headerNavigation:p}=this.beans;if(this.focusedHeader&&(t=e.headerPosition,n=this.focusedHeader,t.headerRowIndex===n.headerRowIndex&&t.column===n.column))return!1;if(-1===u)return c?.isAdvFilterHeaderActive()?this.focusAdvancedFilter(i):this.focusGridView({column:d,event:s});l&&p?.scrollToColumn(d,r);let f=h.getHeaderRowContainerCtrl(d.getPinned()),g=f?.focusHeader(i.headerRowIndex,d,s)||!1;return p&&g&&(null!=a||o)&&(p.currentHeaderRowWithoutSpan=a??-1),g}focusFirstHeader(){if(this.overlays?.isExclusive()&&this.focusOverlay())return!0;let e=this.visibleCols.allCols[0];if(!e)return!1;let t=pd(this.beans,e,0);return this.focusHeaderPosition({headerPosition:t,rowWithoutSpanValue:0})}focusLastHeader(e){if(this.overlays?.isExclusive()&&this.focusOverlay(!0))return!0;let t=u3(this.beans)-1,n=aY(this.visibleCols.allCols);return this.focusHeaderPosition({headerPosition:{headerRowIndex:t,column:n},rowWithoutSpanValue:-1,event:e})}focusPreviousFromFirstCell(e){return this.filterManager?.isAdvFilterHeaderActive()?this.focusAdvancedFilter(null):this.focusLastHeader(e)}isAnyCellFocused(){return!!this.focusedCell}isRowFocused(e,t){return null!=this.focusedCell&&this.focusedCell.rowIndex===e&&this.focusedCell.rowPinned===rw(t)}focusOverlay(e){let t=this.overlays?.isVisible()&&this.overlays.eWrapper?.getGui();return!!t&&l_(t,e)}focusGridView(e){let{backwards:t=!1,canFocusOverlay:n=!0,event:i}=e;if(this.overlays?.isExclusive())return n&&this.focusOverlay(t);if(u1(this.beans))return t&&!u0(this.beans)?this.focusLastHeader():!!(n&&this.focusOverlay(t))||!t&&u2(this.beans,t);let r=t?function(e){let t,n=null,{pinnedRowModel:i,pageBounds:r}=e,o=i?.getPinnedBottomRowCount(),a=i?.getPinnedTopRowCount();return o?(n="bottom",t=o-1):e.rowModel.getRowCount()?t=r.getLastRow():a&&(n="top",t=a-1),void 0===t?null:{rowIndex:t,rowPinned:n}}(this.beans):function(e){let t,n=0,{pinnedRowModel:i,rowModel:r,pageBounds:o}=e;return i?.getPinnedTopRowCount()?t="top":r.getRowCount()?(t=null,n=o.getFirstRow()):i?.getPinnedBottomRowCount()&&(t="bottom"),void 0===t?null:{rowIndex:n,rowPinned:t}}(this.beans);if(r){let n=e.column??this.focusedHeader?.column,{rowIndex:o,rowPinned:a}=r,s=c5(this.beans,r);if(!n||!s||null==o)return!1;if(n.isSuppressNavigable(s)){let e,t=this.gos.get("enableRtl");return e=i&&"Tab"!==i.key?i.key:t?s0:s2,this.beans.navigation?.navigateToNextCell(null,e,{rowIndex:o,column:n,rowPinned:a||null},!0),!0}if(this.navigation?.ensureCellVisible({rowIndex:o,column:n,rowPinned:a}),t){let e=this.rowRenderer.getRowByPosition(r);if(e?.isFullWidth()&&this.navigation?.tryToFocusFullWidthRow(r,t))return!0}return this.setFocusedCell({rowIndex:o,column:n,rowPinned:rw(a),forceBrowserFocus:!0}),this.beans.rangeSvc?.setRangeToCell({rowIndex:o,rowPinned:a,column:n}),!0}return!!(n&&this.focusOverlay(t)||t&&this.focusLastHeader())}focusAdvancedFilter(e){return this.advFilterFocusColumn=e?.column,this.beans.advancedFilter?.getCtrl().focusHeaderComp()??!1}focusNextFromAdvancedFilter(e,t){let n=(t?void 0:this.advFilterFocusColumn)??this.visibleCols.allCols?.[0];return e?this.focusHeaderPosition({headerPosition:{column:n,headerRowIndex:u3(this.beans)-1}}):this.focusGridView({column:n})}clearAdvancedFilterColumn(){this.advFilterFocusColumn=void 0}},ph=class extends oI{constructor(){super(...arguments),this.beanName="scrollVisibleSvc"}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.colAnimation=e.colAnimation}postConstruct(){this.horizontalScrollShowing=!0===this.gos.get("alwaysShowHorizontalScroll"),this.verticalScrollShowing=!0===this.gos.get("alwaysShowVerticalScroll"),this.get
377ScrollbarWidth(),this.addManagedEventListeners({displayedColumnsChanged:this.updateScrollVisible.bind(this),displayedColumnsWidthChanged:this.updateScrollVisible.bind(this)})}updateScrollVisible(){let{colAnimation:e}=this;e?.isActive()?e.executeLaterVMTurn(()=>{e.executeLaterVMTurn(()=>this.updateScrollVisibleImpl())}):this.updateScrollVisibleImpl()}updateScrollVisibleImpl(){let e=this.ctrlsSvc.get("center");if(!e||this.colAnimation?.isActive())return;let t={horizontalScrollShowing:e.isHorizontalScrollShowing(),verticalScrollShowing:this.verticalScrollShowing};this.setScrollsVisible(t),this.updateScrollGap()}updateScrollGap(){let e=this.ctrlsSvc.get("center"),t=e.hasHorizontalScrollGap(),n=e.hasVerticalScrollGap();(this.horizontalScrollGap!==t||this.verticalScrollGap!==n)&&(this.horizontalScrollGap=t,this.verticalScrollGap=n,this.eventSvc.dispatchEvent({type:"scrollGapChanged"}))}setScrollsVisible(e){(this.horizontalScrollShowing!==e.horizontalScrollShowing||this.verticalScrollShowing!==e.verticalScrollShowing)&&(this.horizontalScrollShowing=e.horizontalScrollShowing,this.verticalScrollShowing=e.verticalScrollShowing,this.eventSvc.dispatchEvent({type:"scrollVisibilityChanged"}))}getScrollbarWidth(){if(null==this.scrollbarWidth){let e=this.gos.get("scrollbarWidth"),t="number"==typeof e&&e>=0?e:(null==S&&ld(),S);null!=t&&(this.scrollbarWidth=t,this.eventSvc.dispatchEvent({type:"scrollbarWidthChanged"}))}return this.scrollbarWidth}},pp=class extends oI{constructor(){super(...arguments),this.beanName="gridDestroySvc",this.destroyCalled=!1}destroy(){if(this.destroyCalled)return;let{stateSvc:e,ctrlsSvc:t,context:n}=this.beans;this.eventSvc.dispatchEvent({type:"gridPreDestroyed",state:e?.getState()??{}}),this.destroyCalled=!0,t.get("gridCtrl")?.destroyGridUi(),n.destroy(),super.destroy()}},pf=new Set(["gridPreDestroyed","fillStart","pasteStart"]),pg=["columnEverythingChanged","newColumnsLoaded","columnPivotModeChanged","pivotMaxColumnsExceeded","columnRowGroupChanged","expandOrCollapseAll","columnPivotChanged","gridColumnsChanged","columnValueChanged","columnMoved","columnVisible","columnPinned","columnGroupOpened","columnResized","displayedColumnsChanged","virtualColumnsChanged","columnHeaderMouseOver","columnHeaderMouseLeave","columnHeaderClicked","columnHeaderContextMenu","asyncTransactionsFlushed","rowGroupOpened","rowDataUpdated","pinnedRowDataChanged","pinnedRowsChanged","rangeSelectionChanged","cellSelectionChanged","chartCreated","chartRangeSelectionChanged","chartOptionsChanged","chartDestroyed","toolPanelVisibleChanged","toolPanelSizeChanged","modelUpdated","cutStart","cutEnd","pasteStart","pasteEnd","fillStart","fillEnd","cellSelectionDeleteStart","cellSelectionDeleteEnd","rangeDeleteStart","rangeDeleteEnd","undoStarted","undoEnded","redoStarted","redoEnded","cellClicked","cellDoubleClicked","cellMouseDown","cellContextMenu","cellValueChanged","cellEditRequest","rowValueChanged","headerFocused","cellFocused","rowSelected","selectionChanged","tooltipShow","tooltipHide","cellKeyDown","cellMouseOver","cellMouseOut","filterChanged","filterModified","filterUiChanged","filterOpened","floatingFilterUiChanged","advancedFilterBuilderVisibleChanged","sortChanged","virtualRowRemoved","rowClicked","rowDoubleClicked","gridReady","gridPreDestroyed","gridSizeChanged","viewportChanged","firstDataRendered","dragStarted","dragStopped","dragCancelled","rowEditingStarted","rowEditingStopped","cellEditingStarted","cellEditingStopped","bodyScroll","bodyScrollEnd","paginationChanged","componentStateChanged","storeRefreshed","stateUpdated","columnMenuVisibleChanged","contextMenuVisibleChanged","rowDragEnter","rowDragMove","rowDragLeave","rowDragEnd","rowDragCancel","findChanged","rowResizeStarted","rowResizeEnded","columnsReset","bulkEditingStarted","bulkEditingStopped","batchEditingStarted","batchEditingStopped"].reduce((e,t)=>(e[t]=t&&!(t.length<2)?"on"+t[0].toUpperCase()+t.substring(1):t,e),{}),pm=(e,t)=>({tag:"span",ref:`eSort${e}`,cls:`ag-sort-indicator-icon ag-sort-${t} ag-hidden`,attrs:{"aria-hidden":"true"}}),pv={tag:"span",cls:"ag-sort-indicator-container",children:[pm("Order","order"),pm("Asc","ascending-icon"),pm("Desc","descending-icon"),pm("Mixed","mixed-icon"),pm("None","none-icon")]},py=class extends sk{constructor(e){super(),this.eSortOrder=null,this.eSortAsc=null,this.eSortDe
377sc=null,this.eSortMixed=null,this.eSortNone=null,e||this.setTemplate(pv)}attachCustomElements(e,t,n,i,r){this.eSortOrder=e,this.eSortAsc=t,this.eSortDesc=n,this.eSortMixed=i,this.eSortNone=r}setupSort(e,t=!1){if(this.column=e,this.suppressOrder=t,this.setupMultiSortIndicator(),!e.isSortable()&&!e.getColDef().showRowGroup)return;this.addInIcon("sortAscending",this.eSortAsc,e),this.addInIcon("sortDescending",this.eSortDesc,e),this.addInIcon("sortUnSort",this.eSortNone,e);let n=this.updateIcons.bind(this),i=this.onSortChanged.bind(this);this.addManagedPropertyListener("unSortIcon",n),this.addManagedEventListeners({newColumnsLoaded:n,sortChanged:i,columnRowGroupChanged:i}),this.onSortChanged()}addInIcon(e,t,n){if(null==t)return;let i=cv(e,this.beans,n);i&&t.appendChild(i)}onSortChanged(){this.updateIcons(),this.suppressOrder||this.updateSortOrder()}updateIcons(){let{eSortAsc:e,eSortDesc:t,eSortNone:n,column:i,gos:r,beans:o}=this,a=o.sortSvc.getDisplaySortForColumn(i);e&&rZ(e,"asc"===a,{skipAriaHidden:!0}),t&&rZ(t,"desc"===a,{skipAriaHidden:!0}),n&&rZ(n,!(!i.getColDef().unSortIcon&&!r.get("unSortIcon"))&&null==a,{skipAriaHidden:!0})}setupMultiSortIndicator(){let{eSortMixed:e,column:t,gos:n}=this;this.addInIcon("sortUnSort",e,t);let i=t.getColDef().showRowGroup;ay(n)&&i&&(this.addManagedEventListeners({sortChanged:this.updateMultiSortIndicator.bind(this),columnRowGroupChanged:this.updateMultiSortIndicator.bind(this)}),this.updateMultiSortIndicator())}updateMultiSortIndicator(){let{eSortMixed:e,beans:t,column:n}=this;e&&rZ(e,"mixed"===t.sortSvc.getDisplaySortForColumn(n),{skipAriaHidden:!0})}updateSortOrder(){let{eSortOrder:e,column:t,beans:{sortSvc:n}}=this;if(!e)return;let i=n.getColumnsWithSortingOrdered(),r=n.getDisplaySortIndexForColumn(t)??-1,o=i.some(e=>n.getDisplaySortIndexForColumn(e)??!1);rZ(e,r>=0&&o,{skipAriaHidden:!0}),r>=0?e.textContent=(r+1).toString():r8(e)}},pb={selector:"AG-SORT-INDICATOR",component:py},px=["asc","desc",null],pw=class extends oI{constructor(){super(...arguments),this.beanName="sortSvc"}progressSort(e,t,n){let i=this.getNextSortDirection(e);this.setSortForColumn(e,i,t,n)}progressSortFromEvent(e,t){let n="ctrl"===this.gos.get("multiSortKey")?t.ctrlKey||t.metaKey:t.shiftKey;this.progressSort(e,n,"uiColumnSorted")}setSortForColumn(e,t,n,i){"asc"!==t&&"desc"!==t&&(t=null);let{gos:r,showRowGroupCols:o}=this.beans,a=ay(r),s=[e];if(a&&e.getColDef().showRowGroup){let t=o?.getSourceColumnsForGroupColumn?.(e),n=t?.filter(e=>e.isSortable());n&&(s=[e,...n])}for(let e of s)this.setColSort(e,t,i);let l=(n||r.get("alwaysMultiSort"))&&!r.get("suppressMultiSort"),d=[];if(!l){let e=this.clearSortBarTheseColumns(s,i);d.push(...e)}this.updateSortIndex(e),d.push(...s),this.dispatchSortChangedEvents(i,d)}updateSortIndex(e){let{gos:t,colModel:n,showRowGroupCols:i}=this.beans,r=ay(t),o=i?.getShowRowGroupCol(e.getId()),a=r&&o||e,s=this.getColumnsWithSortingOrdered();n.forAllCols(e=>this.setColSortIndex(e,null));let l=s.filter(e=>(!r||!e.getColDef().showRowGroup)&&e!==a);(a.getSort()?[...l,a]:l).forEach((e,t)=>this.setColSortIndex(e,t))}onSortChanged(e,t){this.dispatchSortChangedEvents(e,t)}isSortActive(){let e=!1;return this.beans.colModel.forAllCols(t=>{t.getSort()&&(e=!0)}),e}dispatchSortChangedEvents(e,t){let n={type:"sortChanged",source:e};t&&(n.columns=t),this.eventSvc.dispatchEvent(n)}clearSortBarTheseColumns(e,t){let n=[];return this.beans.colModel.forAllCols(i=>{e.includes(i)||(i.getSort()&&n.push(i),this.setColSort(i,void 0,t))}),n}getNextSortDirection(e){let t=e.getColDef().sortingOrder??this.gos.get("sortingOrder")??px,n=t.indexOf(e.getSort()),i=n==t.length-1;return n<0||i?t[0]:t[n+1]}getIndexedSortMap(){let{gos:e,colModel:t,showRowGroupCols:n,rowGroupColsSvc:i}=this.beans,r=[];if(t.forAllCols(e=>{e.getSort()&&r.push(e)}),t.isPivotMode()){let t=ay(e);r=r.filter(e=>{let i=!!e.getAggFunc(),r=!e.isPrimary(),o=t?n?.getShowRowGroupCol(e.getId()):e.getColDef().showRowGroup;return i||r||o})}let o=i?.columns.filter(e=>!!e.getSort())??[],a={};r.forEach((e,t)=>a[e.getId()]=t),r.sort((e,t)=>{let n=e.getSortIndex(),i=t.getSortIndex();return null!=n&&null!=i?n-i:null==n&&null==i?a[e.getId()]>a[t.getId()]?1:-1:null==i?-1:1});let s=ay(e)&&!!o.length;
377s&&(r=[...new Set(r.map(e=>n?.getShowRowGroupCol(e.getId())??e))]);let l=new Map;if(r.forEach((e,t)=>l.set(e,t)),s)for(let e of o){let t=n.getShowRowGroupCol(e.getId());l.set(e,l.get(t))}return l}getColumnsWithSortingOrdered(){return[...this.getIndexedSortMap().entries()].sort(([,e],[,t])=>e-t).map(([e])=>e)}getSortModel(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),colId:e.getId()}))}getSortOptions(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),column:e}))}canColumnDisplayMixedSort(e){let t=ay(this.gos),n=!!e.getColDef().showRowGroup;return t&&n}getDisplaySortForColumn(e){let t=this.beans.showRowGroupCols?.getSourceColumnsForGroupColumn(e);if(!this.canColumnDisplayMixedSort(e)||!t?.length)return e.getSort();let n=null!=e.getColDef().field||e.getColDef().valueGetter?[e,...t]:t,i=n[0].getSort();return n.every(e=>e.getSort()==i)?i:"mixed"}getDisplaySortIndexForColumn(e){return this.getIndexedSortMap().get(e)}setupHeader(e,t,n){let i=0;e.addManagedListeners(t,{movingChanged:()=>{i=Date.now()}}),n&&e.addManagedElementListeners(n,{click:e=>{let n=t.isMoving(),r=Date.now()-i<50;n||r||this.progressSortFromEvent(t,e)}});let r=()=>{let n=t.getSort();if(e.toggleCss("ag-header-cell-sorted-asc","asc"===n),e.toggleCss("ag-header-cell-sorted-desc","desc"===n),e.toggleCss("ag-header-cell-sorted-none",!n),t.getColDef().showRowGroup){let n=this.beans.showRowGroupCols?.getSourceColumnsForGroupColumn(t),i=n?.every(e=>t.getSort()==e.getSort());e.toggleCss("ag-header-cell-sorted-mixed",!i)}};e.addManagedEventListeners({sortChanged:r,columnRowGroupChanged:r})}initCol(e){let{sort:t,initialSort:n,sortIndex:i,initialSortIndex:r}=e.colDef;void 0!==t?("asc"===t||"desc"===t)&&(e.sort=t):("asc"===n||"desc"===n)&&(e.sort=n),void 0!==i?null!==i&&(e.sortIndex=i):null!==r&&(e.sortIndex=r)}updateColSort(e,t,n){void 0!==t&&("desc"===t||"asc"===t?this.setColSort(e,t,n):this.setColSort(e,void 0,n))}setColSort(e,t,n){e.sort!==t&&(e.sort=t,e.dispatchColEvent("sortChanged",n)),e.dispatchStateUpdatedEvent("sort")}setColSortIndex(e,t){e.sortIndex=t,e.dispatchStateUpdatedEvent("sortIndex")}createSortIndicator(e){return new py(e)}getSortIndicatorSelector(){return pb}},pC={agSetColumnFilter:"SetFilter",agSetColumnFloatingFilter:"SetFilter",agMultiColumnFilter:"MultiFilter",agMultiColumnFloatingFilter:"MultiFilter",agGroupColumnFilter:"GroupFilter",agGroupColumnFloatingFilter:"GroupFilter",agGroupCellRenderer:"GroupCellRenderer",agGroupRowRenderer:"GroupCellRenderer",agRichSelect:"RichSelect",agRichSelectCellEditor:"RichSelect",agDetailCellRenderer:"SharedMasterDetail",agSparklineCellRenderer:"Sparklines",agDragAndDropImage:"SharedDragAndDrop",agColumnHeader:"ColumnHeaderComp",agColumnGroupHeader:"ColumnGroupHeaderComp",agSortIndicator:"Sort",agAnimateShowChangeCellRenderer:"HighlightChanges",agAnimateSlideCellRenderer:"HighlightChanges",agLoadingCellRenderer:"LoadingCellRenderer",agSkeletonCellRenderer:"SkeletonCellRenderer",agCheckboxCellRenderer:"CheckboxCellRenderer",agLoadingOverlay:"Overlay",agNoRowsOverlay:"Overlay",agTooltipComponent:"Tooltip",agReadOnlyFloatingFilter:"CustomFilter",agTextColumnFilter:"TextFilter",agNumberColumnFilter:"NumberFilter",agDateColumnFilter:"DateFilter",agDateInput:"DateFilter",agTextColumnFloatingFilter:"TextFilter",agNumberColumnFloatingFilter:"NumberFilter",agDateColumnFloatingFilter:"DateFilter",agCellEditor:"TextEditor",agSelectCellEditor:"SelectEditor",agTextCellEditor:"TextEditor",agNumberCellEditor:"NumberEditor",agDateCellEditor:"DateEditor",agDateStringCellEditor:"DateEditor",agCheckboxCellEditor:"CheckboxEditor",agLargeTextCellEditor:"LargeTextEditor",agMenuItem:"MenuItem",agColumnsToolPanel:"ColumnsToolPanel",agFiltersToolPanel:"FiltersToolPanel",agNewFiltersToolPanel:"NewFiltersToolPanel",agAggregationComponent:"StatusBar",agSelectedRowCountComponent:"StatusBar",agTotalRowCountComponent:"StatusBar",agFilteredRowCountComponent:"StatusBar",agTotalAndFilteredRowCountComponent:"StatusBar",agFindCellRenderer:"Find"};function pS(e){return`"${e}"`}var p_={aggFunc:"SharedAggregation",autoHeight:"RowAutoHeight",cellClass:"CellStyle",cell
vendor: 5,009 bytes, line 377
377ClassRules:"CellStyle",cellEditor:({cellEditor:e,editable:t})=>t?"string"==typeof e?pC[e]??"CustomEditor":"CustomEditor":null,cellRenderer:({cellRenderer:e})=>"string"!=typeof e?null:pC[e],cellStyle:"CellStyle",columnChooserParams:"ColumnMenu",contextMenuItems:"ContextMenu",dndSource:"DragAndDrop",dndSourceOnRowDrag:"DragAndDrop",editable:({editable:e,cellEditor:t})=>e&&!t?"TextEditor":null,enableCellChangeFlash:"HighlightChanges",enablePivot:"SharedPivot",enableRowGroup:"SharedRowGrouping",enableValue:"SharedAggregation",filter:({filter:e})=>e&&"string"!=typeof e&&"boolean"!=typeof e?"CustomFilter":"string"==typeof e?pC[e]??"ColumnFilter":"ColumnFilter",floatingFilter:"ColumnFilter",getQuickFilterText:"QuickFilter",headerTooltip:"Tooltip",headerTooltipValueGetter:"Tooltip",mainMenuItems:"ColumnMenu",menuTabs:e=>{let t=["columnsMenuTab","generalMenuTab"];return e.menuTabs?.some(e=>t.includes(e))?"ColumnMenu":null},pivot:"SharedPivot",pivotIndex:"SharedPivot",rowDrag:"RowDrag",rowGroup:"SharedRowGrouping",rowGroupIndex:"SharedRowGrouping",tooltipField:"Tooltip",tooltipValueGetter:"Tooltip",tooltipComponentSelector:"Tooltip",spanRows:"CellSpan",groupHierarchy:"SharedRowGrouping"},pk={headerName:void 0,columnGroupShow:void 0,headerStyle:void 0,headerClass:void 0,toolPanelClass:void 0,headerValueGetter:void 0,pivotKeys:void 0,groupId:void 0,colId:void 0,sort:void 0,initialSort:void 0,field:void 0,type:void 0,cellDataType:void 0,tooltipComponent:void 0,tooltipField:void 0,headerTooltip:void 0,headerTooltipValueGetter:void 0,cellClass:void 0,showRowGroup:void 0,filter:void 0,initialAggFunc:void 0,defaultAggFunc:void 0,aggFunc:void 0,pinned:void 0,initialPinned:void 0,chartDataType:void 0,cellAriaRole:void 0,cellEditorPopupPosition:void 0,headerGroupComponent:void 0,headerGroupComponentParams:void 0,cellStyle:void 0,cellRenderer:void 0,cellRendererParams:void 0,cellEditor:void 0,cellEditorParams:void 0,filterParams:void 0,pivotValueColumn:void 0,headerComponent:void 0,headerComponentParams:void 0,floatingFilterComponent:void 0,floatingFilterComponentParams:void 0,tooltipComponentParams:void 0,refData:void 0,columnChooserParams:void 0,children:void 0,sortingOrder:void 0,allowedAggFuncs:void 0,menuTabs:void 0,pivotTotalColumnIds:void 0,cellClassRules:void 0,icons:void 0,sortIndex:void 0,initialSortIndex:void 0,flex:void 0,initialFlex:void 0,width:void 0,initialWidth:void 0,minWidth:void 0,maxWidth:void 0,rowGroupIndex:void 0,initialRowGroupIndex:void 0,pivotIndex:void 0,initialPivotIndex:void 0,suppressColumnsToolPanel:void 0,suppressFiltersToolPanel:void 0,openByDefault:void 0,marryChildren:void 0,suppressStickyLabel:void 0,hide:void 0,initialHide:void 0,rowGroup:void 0,initialRowGroup:void 0,pivot:void 0,initialPivot:void 0,checkboxSelection:void 0,showDisabledCheckboxes:void 0,headerCheckboxSelection:void 0,headerCheckboxSelectionFilteredOnly:void 0,headerCheckboxSelectionCurrentPageOnly:void 0,suppressHeaderMenuButton:void 0,suppressMovable:void 0,lockPosition:void 0,lockVisible:void 0,lockPinned:void 0,unSortIcon:void 0,suppressSizeToFit:void 0,suppressAutoSize:void 0,enableRowGroup:void 0,enablePivot:void 0,enableValue:void 0,editable:void 0,suppressPaste:void 0,suppressNavigable:void 0,enableCellChangeFlash:void 0,rowDrag:void 0,dndSource:void 0,autoHeight:void 0,wrapText:void 0,sortable:void 0,resizable:void 0,singleClickEdit:void 0,floatingFilter:void 0,cellEditorPopup:void 0,suppressFillHandle:void 0,wrapHeaderText:void 0,autoHeaderHeight:void 0,dndSourceOnRowDrag:void 0,valueGetter:void 0,valueSetter:void 0,filterValueGetter:void 0,keyCreator:void 0,valueFormatter:void 0,valueParser:void 0,comparator:void 0,equals:void 0,pivotComparator:void 0,suppressKeyboardEvent:void 0,suppressHeaderKeyboardEvent:void 0,colSpan:void 0,rowSpan:void 0,spanRows:void 0,getQuickFilterText:void 0,onCellValueChanged:void 0,onCellClicked:void 0,onCellDoubleClicked:void 0,onCellContextMenu:void 0,rowDragText:void 0,tooltipValueGetter:void 0,tooltipComponentSelector:void 0,cellRendererSelector:void 0,cellEditorSelector:void 0,suppressSpanHeaderHeight:void 0,useValueFormatterForExport:void 0,useValueParserForImport:void 0,mainMenuItems:void 0,contextMenuItems:void 0,suppressFloatingFilterButton:void 0,suppressHeaderFilterButton:void 0,suppressHeaderContextMenu:void 0,loadingCellRenderer:void 0,loadingCellRendererParams:void 0,loadingCellRendererSelector:void 0,context:void 0,dateComponent:void 0,dateComponentParams:void 0,getFindText:void 0,rowGroupingHierarchy:void 0,groupHierarchy:void 0},pM=["overlayLoadingTemplate","overlayNoRowsTemplate","gridId","quickFilterText","rowModelType","editType","domLayout","clipboardDelimiter","rowGroupPanelShow","multiSortKey","pivotColumnGroupTotals","pivotRowTotals","pivotPanelShow","fillHandleDirection","groupDisplayType","treeDataDisplayType","treeDataChildrenField","treeDataParentIdField","colResizeDefault","tooltipTrigger","serverSidePivotResultFieldSeparator","columnMenu","tooltipShowMode","invali
377dEditValueMode","grandTotalRow","themeCssLayer","findSearchValue","styleNonce","renderingMode"],pT=["components","rowStyle","context","autoGroupColumnDef","localeText","icons","datasource","dragAndDropImageComponentParams","serverSideDatasource","viewportDatasource","groupRowRendererParams","aggFuncs","fullWidthCellRendererParams","defaultColGroupDef","defaultColDef","defaultCsvExportParams","defaultExcelExportParams","columnTypes","rowClassRules","detailCellRendererParams","loadingCellRendererParams","loadingOverlayComponentParams","noRowsOverlayComponentParams","popupParent","themeStyleContainer","statusBar","chartThemeOverrides","customChartThemes","chartToolPanelsDef","dataTypeDefinitions","advancedFilterParent","advancedFilterBuilderParams","advancedFilterParams","initialState","autoSizeStrategy","selectionColumnDef","findOptions","filterHandlers","groupHierarchyConfig"],pD=["sortingOrder","alignedGrids","rowData","columnDefs","excelStyles","pinnedTopRowData","pinnedBottomRowData","chartThemes","rowClass","paginationPageSizeSelector"],pR=["rowHeight","detailRowHeight","rowBuffer","headerHeight","groupHeaderHeight","groupLockGroupColumns","floatingFiltersHeight","pivotHeaderHeight","pivotGroupHeaderHeight","groupDefaultExpanded","pivotDefaultExpanded","viewportRowModelPageSize","viewportRowModelBufferSize","autoSizePadding","maxBlocksInCache","maxConcurrentDatasourceRequests","tooltipShowDelay","tooltipHideDelay","cacheOverflowSize","paginationPageSize","cacheBlockSize","infiniteInitialRowCount","serverSideInitialRowCount","scrollbarWidth","asyncTransactionWaitMillis","blockLoadDebounceMillis","keepDetailRowsCount","undoRedoCellEditingLimit","cellFlashDuration","cellFadeDuration","tabIndex","pivotMaxGeneratedColumns","rowDragInsertDelay"],pI=["theme","rowSelection"],pA=["cellSelection","sideBar","rowNumbers","suppressGroupChangesColumnVisibility","groupAggFiltering","suppressStickyTotalRow","groupHideParentOfSingleChild","enableRowPinning"],pP=["loadThemeGoogleFonts","suppressMakeColumnVisibleAfterUnGroup","suppressRowClickSelection","suppressCellFocus","suppressHeaderFocus","suppressHorizontalScroll","groupSelectsChildren","alwaysShowHorizontalScroll","alwaysShowVerticalScroll","debug","enableBrowserTooltips","enableCellExpressions","groupSuppressBlankHeader","suppressMenuHide","suppressRowDeselection","unSortIcon","suppressMultiSort","alwaysMultiSort","singleClickEdit","suppressLoadingOverlay","suppressNoRowsOverlay","suppressAutoSize","skipHeaderOnAutoSize","suppressColumnMoveAnimation","suppressMoveWhenColumnDragging","suppressMovableColumns","suppressFieldDotNotation","enableRangeSelection","enableRangeHandle","enableFillHandle","suppressClearOnFillReduction","deltaSort","suppressTouch","allowContextMenuWithControlKey","suppressContextMenu","suppressDragLeaveHidesColumns","suppressRowGroupHidesColumns","suppressMiddleClickScrolls","suppressPreventDefaultOnMouseWheel","suppressCopyRowsToClipboard","copyHeadersToClipboard","copyGroupHeadersToClipboard","pivotMode","suppressAggFuncInHeader","suppressColumnVirtualisation","alwaysAggregateAtRootLevel","suppressFocusAfterRefresh","functionsReadOnly","animateRows","groupSelectsFiltered","groupRemoveSingleChildren","groupRemoveLowestSingleChildren","enableRtl","enableCellSpan","suppressClickEdit","rowDragEntireRow","rowDragManaged","suppressRowDrag","suppressMoveWhenRowDragging","rowDragMultiRow","enableGroupEdit","embedFullWidthRows","suppressPaginationPanel","groupHideOpenParents","groupAllowUnbalanced","pagination","paginationAutoPageSize","suppressScrollOnNewData","suppressScrollWhenPopupsAreOpen","purgeClosedRowNodes","cacheQuickFilter","includeHiddenColumnsInQuickFilter","ensureDomOrder","accentedSort","suppressChangeDetection","valueCache","valueCacheNeverExpires","aggregateOnlyChangedColumns","suppressAnimationFrame","suppressExcelExport","suppressCsvExport","includeHiddenColumnsInAdvancedFilter","suppressMultiRangeSelection","enterNavigatesVerticallyAfterEdit","enterNavigatesVertically","suppressPropertyNamesCheck","rowMultiSelectWithClick","suppressRowHoverHighlight","suppressRowTransform","suppressClipboardPaste","suppressLastEmptyLineOnPaste","enableCharts","suppressMaintainUnsortedOrder","enableCellTextSelection","suppressBrowserResizeObserver","suppressMaxRenderedRowRestriction","excludeChildrenWhenTreeDataFiltering","tooltipMouseTrack","tooltipInteraction","keepDetailRows","paginateChildRows","preventDefaultOnContextMenu","undoRedoCellEditing","allowDragFromColumnsToolPanel","pivotSuppressAutoColumn","suppressExpandablePivotGroups","debounceVerticalScrollbar","detailRowAutoHeight","serverSideSortAllLevels","serverSideEnableClientSideSort","serverSideOnlyRefreshFilteredGroups","suppressAggFilteredOnly","showOpenedGroup","suppressClipboardApi","suppressModelUpdateAfterUpdateTransaction","stopEditingWhenCellsLoseFocus","groupMaintainOrder","columnHoverHighlight","readOnlyEdit","suppressRowVirtualisation","enableCellEditingOnBackspace","resetRowDataOnUpdate","removePivotHeaderRowWhenSingleValueColumn","suppressCopySingleCellRanges","suppressGroupRowsSticky","suppressCutToClipboard","rowGroupPanelSuppressSort","allowShowChangeAfterFilter","enableAdvancedFilter","masterDetail","treeData","reactiveCustomComponents","applyQuickFilterBeforePivotOrAgg","suppressServerSideFullWidthLoadingRow","suppressAdvancedFilterEval","loading","maintainColumnOrder","enableStrictPivotColumnOrder","suppressSetFilterByDefault","enableFilterHandlers","suppressStartEditOnTab","hidePaddedHeaderRows","ssrmExpandAllAffectsAllRows"],pE=["doesExternalFilterPass","processPivotResultColDef","processPivotResultColGroupDef","getBusinessKeyForNode","isRowSelectable","rowDragText","groupRowRenderer","dragAndDropImageComponent","fullWidthCellRenderer","loadingCellRenderer","loadingOverlayComponent","noRowsOverlayComponent","detailCellRenderer","quickFilterParser","quickFilterMatcher","getLocaleText","isExternalFilterPresent","getRowHeight","getRowClass","getRowStyle","getFullRowEditValidationErrors","getContextMenuItems","getMainMenuItems","processRowPostCreate","processCellForClipboard","getGroupRowAgg","isFullWidthRow","
377sendToClipboard","focusGridInnerElement","navigateToNextHeader","tabToNextHeader","navigateToNextCell","tabToNextCell","processCellFromClipboard","getDocument","postProcessPopup","getChildCount","getDataPath","isRowMaster","postSortRows","processHeaderForClipboard","processUnpinnedColumns","processGroupHeaderForClipboard","paginationNumberFormatter","processDataFromClipboard","getServerSideGroupKey","isServerSideGroup","createChartContainer","getChartToolbarItems","fillOperation","isApplyServerSideTransaction","getServerSideGroupLevelParams","isServerSideGroupOpenByDefault","isGroupOpenByDefault","initialGroupOrderComparator","loadingCellRendererSelector","getRowId","chartMenuItems","groupTotalRow","alwaysPassFilter","isRowPinnable","isRowPinned","isRowValidDropPosition"];function pL(e,t,n){return"number"==typeof t||null==t?null==t||t>=n?null:`${e}: value should be greater than or equal to ${n}`:`${e}: value should be a number`}var pF={alignedGrids:"AlignedGrids",allowContextMenuWithControlKey:"ContextMenu",autoSizeStrategy:"ColumnAutoSize",cellSelection:"CellSelection",columnHoverHighlight:"ColumnHover",datasource:"InfiniteRowModel",doesExternalFilterPass:"ExternalFilter",editType:"EditCore",invalidEditValueMode:"EditCore",enableAdvancedFilter:"AdvancedFilter",enableCellSpan:"CellSpan",enableCharts:"IntegratedCharts",enableRangeSelection:"CellSelection",enableRowPinning:"PinnedRow",findSearchValue:"Find",getFullRowEditValidationErrors:"EditCore",getContextMenuItems:"ContextMenu",getLocaleText:"Locale",getMainMenuItems:"ColumnMenu",getRowClass:"RowStyle",getRowStyle:"RowStyle",groupTotalRow:"SharedRowGrouping",grandTotalRow:"ClientSideRowModelHierarchy",initialState:"GridState",isExternalFilterPresent:"ExternalFilter",isRowPinnable:"PinnedRow",isRowPinned:"PinnedRow",localeText:"Locale",masterDetail:"SharedMasterDetail",pagination:"Pagination",pinnedBottomRowData:"PinnedRow",pinnedTopRowData:"PinnedRow",pivotMode:"SharedPivot",pivotPanelShow:"RowGroupingPanel",quickFilterText:"QuickFilter",rowClass:"RowStyle",rowClassRules:"RowStyle",rowData:"ClientSideRowModel",rowDragManaged:"RowDrag",rowGroupPanelShow:"RowGroupingPanel",rowNumbers:"RowNumbers",rowSelection:"SharedRowSelection",rowStyle:"RowStyle",serverSideDatasource:"ServerSideRowModel",sideBar:"SideBar",statusBar:"StatusBar",treeData:"SharedTreeData",undoRedoCellEditing:"UndoRedoEdit",valueCache:"ValueCache",viewportDatasource:"ViewportRowModel"},pO=0,pN=0,pB="__ag_grid_instance",pz=class extends oI{constructor(){super(...arguments),this.beanName="gos",this.domDataKey="__AG_"+Math.random().toString(),this.instanceId=pN++,this.gridReadyFired=!1,this.queueEvents=[],this.propEventSvc=new rx,this.globalEventHandlerFactory=e=>(t,n)=>{if(!this.isAlive())return;let i=pf.has(t);if(i&&!e||!i&&e||!pg[t])return;let r=(e,t)=>{let n=pg[e],i=this.gridOptions[n];"function"==typeof i&&this.beans.frameworkOverrides.wrapOutgoing(()=>i(t))};if(this.gridReadyFired)r(t,n);else if("gridReady"===t){for(let e of(r(t,n),this.gridReadyFired=!0,this.queueEvents))r(e.eventName,e.event);this.queueEvents=[]}else this.queueEvents.push({eventName:t,event:n})}}wireBeans(e){this.gridOptions=e.gridOptions,this.validation=e.validation,this.api=e.gridApi,this.gridId=e.context.getId()}get gridOptionsContext(){return this.gridOptions.context}postConstruct(){this.validateGridOptions(this.gridOptions),this.eventSvc.addGlobalListener(this.globalEventHandlerFactory().bind(this),!0),this.eventSvc.addGlobalListener(this.globalEventHandlerFactory(!0).bind(this),!1),this.propEventSvc.setFrameworkOverrides(this.beans.frameworkOverrides),this.addManagedEventListeners({gridOptionsChanged:({options:e})=>{this.updateGridOptions({options:e,force:!0,source:"optionsUpdated"})}})}destroy(){super.destroy(),this.queueEvents=[]}get(e){return this.gridOptions[e]??oG[e]}getCallback(e){return this.mergeGridCommonParams(this.gridOptions[e])}exists(e){return rC(this.gridOptions[e])}mergeGridCommonParams(e){return e?t=>e(this.addCommon(t)):e}updateGridOptions({options:e,force:t,source:n="api"}){let i={id:pO++,properties:[]},r=[],{gridOptions:o,validation:a}=this;for(let s of Object.keys(e)){let l=oV.applyGlobalGridOption(s,e[s]);a?.warnOnInitialPropertyUpdate(n,s);let d=t||"object"==typeof l&&"api"===n,u=o[s];if(d||u!==l){o[s]=l;let e={type:s,currentValue:l,previousValue:u,changeSet:i,source:n};r.push(e)}}for(let e of(this.validateGridOptions(this.gridOptions),i.properties=r.map(e=>e.type),r))o$(this,`Updated property ${e.type} from`,e.previousValue," to ",e.currentValue),this.propEventSvc.dispatchEvent(e)}
377addPropertyEventListener(e,t){this.propEventSvc.addEventListener(e,t)}removePropertyEventListener(e,t){this.propEventSvc.removeEventListener(e,t)}getDomDataKey(){return this.domDataKey}addCommon(e){return e.api=this.api,e.context=this.gridOptionsContext,e}validateOptions(e,t){for(let n of Object.keys(e)){let i=e[n];if(null==i||!1===i)continue;let r=t[n];"function"==typeof r&&(r=r(e,this.gridOptions,this.beans)),r&&this.assertModuleRegistered(r,n)}}validateGridOptions(e){this.validateOptions(e,pF),this.validation?.processGridOptions(e)}validateColDef(e,t,n){(n||!this.beans.dataTypeSvc?.isColPendingInference(t))&&(this.validateOptions(e,p_),this.validation?.validateColDef(e))}assertModuleRegistered(e,t){let n=Array.isArray(e)?e.some(e=>this.isModuleRegistered(e)):this.isModuleRegistered(e);return n||an(200,{...this.getModuleErrorParams(),moduleName:e,reasonOrId:t}),n}getModuleErrorParams(){return{gridId:this.gridId,gridScoped:oJ,rowModelType:this.get("rowModelType"),isUmd:!1}}isModuleRegistered(e){return o0(e,this.gridId,this.get("rowModelType"))}setInstanceDomData(e){e[pB]=this.instanceId}isElementInThisInstance(e){let t=e;for(;t;){let e=t[pB];if(rC(e))return e===this.instanceId;t=t.parentElement}return!1}};function pj(e){let t={"aria-hidden":"true"};return{tag:"div",cls:"ag-cell-label-container",role:"presentation",children:[{tag:"span",ref:"eMenu",cls:"ag-header-icon ag-header-cell-menu-button",attrs:t},{tag:"span",ref:"eFilterButton",cls:"ag-header-icon ag-header-cell-filter-button",attrs:t},{tag:"div",ref:"eLabel",cls:"ag-header-cell-label",role:"presentation",children:[{tag:"span",ref:"eText",cls:"ag-header-cell-text"},{tag:"span",ref:"eFilter",cls:"ag-header-icon ag-header-label-icon ag-filter-icon",attrs:t},e?{tag:"ag-sort-indicator",ref:"eSortIndicator"}:null]}]}}var pV=pj(!0),pH=pj(!1),pG=class extends sk{constructor(){super(...arguments),this.eFilter=null,this.eFilterButton=null,this.eSortIndicator=null,this.eMenu=null,this.eLabel=null,this.eText=null,this.eSortOrder=null,this.eSortAsc=null,this.eSortDesc=null,this.eSortMixed=null,this.eSortNone=null,this.isLoadingInnerComponent=!1}refresh(e){let t=this.params;if(this.params=e,this.workOutTemplate(e,!!this.beans?.sortSvc)!=this.currentTemplate||this.workOutShowMenu()!=this.currentShowMenu||e.enableSorting!=this.currentSort||null!=this.currentSuppressMenuHide&&this.shouldSuppressMenuHide()!=this.currentSuppressMenuHide||t.enableFilterButton!=e.enableFilterButton||t.enableFilterIcon!=e.enableFilterIcon)return!1;if(this.innerHeaderComponent){let t={...e};oz(t,e.innerHeaderComponentParams),this.innerHeaderComponent.refresh?.(t)}else this.setDisplayName(e);return!0}workOutTemplate(e,t){let n=e.template;return n?n?.trim?n.trim():n:t?pV:pH}init(e){this.params=e;let{sortSvc:t,touchSvc:n,rowNumbersSvc:i,userCompFactory:r}=this.beans,o=t?.getSortIndicatorSelector();this.currentTemplate=this.workOutTemplate(e,!!o),this.setTemplate(this.currentTemplate,o?[o]:void 0),n?.setupForHeader(this),this.setMenu(),this.setupSort(),i?.setupForHeader(this),this.setupFilterIcon(),this.setupFilterButton(),this.workOutInnerHeaderComponent(r,e),this.setDisplayName(e)}workOutInnerHeaderComponent(e,t){let n=e.getCompDetails(t,sE,void 0,t);n&&(this.isLoadingInnerComponent=!0,n.newAgStackInstance().then(e=>{this.isLoadingInnerComponent=!1,e&&(this.isAlive()?(this.innerHeaderComponent=e,this.eText&&this.eText.appendChild(e.getGui())):this.destroyBean(e))}))}setDisplayName(e){let{displayName:t}=e,n=this.currentDisplayName;this.currentDisplayName=t,!this.eText||n===t||this.innerHeaderComponent||this.isLoadingInnerComponent||(this.eText.textContent=rD(t))}addInIcon(e,t,n){let i=cv(e,this.beans,n);i&&t.appendChild(i)}workOutShowMenu(){return this.params.enableMenu&&!!this.beans.menuSvc?.isHeaderMenuButtonEnabled()}shouldSuppressMenuHide(){return!!this.beans.menuSvc?.isHeaderMenuButtonAlwaysShowEnabled()}setMenu(){if(!this.eMenu)return;if(this.currentShowMenu=this.workOutShowMenu(),!this.currentShowMenu){r7(this.eMenu),this.eMenu=void 0;return}let{gos:e,eMenu:t,params:n}=this,i=aO(e);this.addInIcon(i?"menu":"menuAlt",t,n.column),t.classList.toggle("ag-header-menu-icon",!i);let r=this.shouldSuppressMenuHide();this.currentSuppressMenuHide=r,this.addManagedElementListeners(t,{click:()=>this.showColumnMenu(this.eMenu)}),this.toggleMenuAlwaysShow(r)}toggleMenuAlwaysShow(e){this.eMenu?.classList.toggle("ag-header-menu-always-show",e)}showColumnMenu(e){let{currentSuppressMenuHide:t,params:n}=this;t||this.toggleMenuAlwaysShow(!0),n.showColumnMenu(e,()=>{t||this.toggleMenuAlwaysShow(!1)})}onMenuKeyboardShortcut(e){let{params:t,gos:n,beans:i,eMenu:r,eFilterButton:o}=this,a=t.column,s=aO(n);if(e&&!s){if(i.menuSvc?.isFilterMenuInHeaderEnabled(a))return t.showFilter(o??r??this.getGui()),!0}else if(t.enableMenu)return this.showColumnMenu(r??o??this.getGui()),!0;return!1}setupSort(){let{sortSvc:e}=this.beans;if(!e)return;let{enableSorting:t,column:n}=this.params;if(this.currentSort=t,!this.eSortIndicator){this.eSortIndicator=this.createBean(e.createSortIndicator(!0));
377let{eSortIndicator:t,eSortOrder:n,eSortAsc:i,eSortDesc:r,eSortMixed:o,eSortNone:a}=this;t.attachCustomElements(n,i,r,o,a)}this.eSortIndicator.setupSort(n),this.currentSort&&e.setupHeader(this,n,this.eLabel)}setupFilterIcon(){let{eFilter:e,params:t}=this;e&&this.configureFilter(t.enableFilterIcon,e,()=>{rZ(e,t.column.isFilterActive(),{skipAriaHidden:!0})},"filterActive")}setupFilterButton(){let{eFilterButton:e,params:t}=this;e&&(this.configureFilter(t.enableFilterButton,e,this.onFilterChangedButton.bind(this),"filter")?this.addManagedElementListeners(e,{click:()=>t.showFilter(e)}):this.eFilterButton=void 0)}configureFilter(e,t,n,i){if(!e)return r7(t),!1;let r=this.params.column;return this.addInIcon(i,t,r),this.addManagedListeners(r,{filterChanged:n}),n(),!0}onFilterChangedButton(){let e=this.params.column.isFilterActive();this.eFilterButton.classList.toggle("ag-filter-active",e)}getAnchorElementForMenu(e){let{eFilterButton:t,eMenu:n}=this;return e?t??n??this.getGui():n??t??this.getGui()}destroy(){super.destroy(),this.innerHeaderComponent&&(this.destroyBean(this.innerHeaderComponent),this.innerHeaderComponent=void 0)}},pW={tag:"div",cls:"ag-header-group-cell-label",role:"presentation",children:[{tag:"span",ref:"agLabel",cls:"ag-header-group-text",role:"presentation"},{tag:"span",ref:"agOpened",cls:"ag-header-icon ag-header-expand-icon ag-header-expand-icon-expanded"},{tag:"span",ref:"agClosed",cls:"ag-header-icon ag-header-expand-icon ag-header-expand-icon-collapsed"}]},p$=class extends sk{constructor(){super(pW),this.agOpened=null,this.agClosed=null,this.agLabel=null,this.isLoadingInnerComponent=!1}init(e){let{userCompFactory:t,touchSvc:n}=this.beans;this.params=e,this.checkWarnings(),this.workOutInnerHeaderGroupComponent(t,e),this.setupLabel(e),this.addGroupExpandIcon(e),this.setupExpandIcons(),n?.setupForHeaderGroup(this)}checkWarnings(){this.params.template&&at(89)}workOutInnerHeaderGroupComponent(e,t){let n=e.getCompDetails(t,sL,void 0,t);n&&(this.isLoadingInnerComponent=!0,n.newAgStackInstance().then(e=>{this.isLoadingInnerComponent=!1,e&&(this.isAlive()?(this.innerHeaderGroupComponent=e,this.agLabel.appendChild(e.getGui())):this.destroyBean(e))}))}setupExpandIcons(){let{agOpened:e,agClosed:t,params:{columnGroup:n},beans:i}=this;this.addInIcon("columnGroupOpened",e),this.addInIcon("columnGroupClosed",t);let r=e=>{if(ua(e))return;let t=!n.isExpanded();i.colGroupSvc.setColumnGroupOpened(n.getProvidedColumnGroup(),t,"uiColumnExpanded")};this.addTouchAndClickListeners(i,t,r),this.addTouchAndClickListeners(i,e,r);let o=e=>{uo(e)};this.addManagedElementListeners(t,{dblclick:o}),this.addManagedElementListeners(e,{dblclick:o}),this.addManagedElementListeners(this.getGui(),{dblclick:r}),this.updateIconVisibility();let a=n.getProvidedColumnGroup(),s=this.updateIconVisibility.bind(this);this.addManagedListeners(a,{expandedChanged:s,expandableChanged:s})}addTouchAndClickListeners(e,t,n){e.touchSvc?.setupForHeaderGroupElement(this,t,n),this.addManagedElementListeners(t,{click:n})}updateIconVisibility(){let{agOpened:e,agClosed:t,params:{columnGroup:n}}=this;if(n.isExpandable()){let i=n.isExpanded();rZ(e,i),rZ(t,!i)}else rZ(e,!1),rZ(t,!1)}addInIcon(e,t){let n=cv(e,this.beans,null);n&&t.appendChild(n)}addGroupExpandIcon(e){if(!e.columnGroup.isExpandable()){let{agOpened:e,agClosed:t}=this;rZ(e,!1),rZ(t,!1)}}setupLabel(e){let{displayName:t,columnGroup:n}=e,i=this.innerHeaderGroupComponent||this.isLoadingInnerComponent;rC(t)&&!i&&(this.agLabel.textContent=rD(t)),this.toggleCss("ag-sticky-label",!n.getColGroupDef()?.suppressStickyLabel)}destroy(){super.destroy(),this.innerHeaderGroupComponent&&(this.destroyBean(this.innerHeaderGroupComponent),this.innerHeaderGroupComponent=void 0)}},pU=class extends oI{constructor(){super(...arguments),this.beanName="animationFrameSvc",this.p1={list:[],sorted:!1},this.p2={list:[],sorted:!1},this.f1={list:[],sorted:!1},this.destroyTasks=[],this.ticking=!1,this.scrollGoingDown=!0,this.lastScrollTop=0,this.taskCount=0}setScrollTop(e){this.scrollGoingDown=e>=this.lastScrollTop,0===e&&(this.scrollGoingDown=!0),this.lastScrollTop=e}postConstruct(){this.active=!this.gos.get("suppressAnimationFrame"),this.batchFrameworkComps=this.beans.frameworkOverrides.batchFrameworkComps}verify(){!1===this.active&&at(92)}createTask(e,t,n,i,r=!1){this.verify();let o=n;i&&this.batchFrameworkComps&&(o="f1");let a={task:e,index:t,createOrder:++this.taskCount,deferred:r};this.addTaskToList(this[o],a),this.schedule()}addTaskToList(e,t){e.list.push(t),e.sorted=!1}sortTaskList(e){if(e.sorted)return;let t=this.scrollGoingDown?1:-1;e.list.sort((e,n)=>e.deferred!==n.deferred?e.deferred?-1:1:e.index!==n.index?t*(n.index-e.index):n.createOrder-e.createOrder),e.sorted=!0}
377addDestroyTask(e){this.verify(),this.destroyTasks.push(e),this.schedule()}executeFrame(e){let{p1:t,p2:n,f1:i,destroyTasks:r,beans:o}=this,{ctrlsSvc:a,frameworkOverrides:s}=o,l=t.list,d=n.list,u=i.list,c=Date.now(),h=0,p=e<=0,f=a.getScrollFeature();for(;p||h<e;){if(!f.scrollGridIfNeeded()){let o;if(l.length)this.sortTaskList(t),o=l.pop().task;else if(d.length)this.sortTaskList(n),o=d.pop().task;else if(u.length)s.wrapOutgoing(()=>{for(;(p||h<e)&&!f.scrollGridIfNeeded()&&u.length;){this.sortTaskList(i),(o=u.pop().task)();h=Date.now()-c}}),o=()=>{};else if(r.length)o=r.pop();else break;o()}h=Date.now()-c}l.length||d.length||u.length||r.length?this.requestFrame():this.ticking=!1}flushAllFrames(){this.active&&this.executeFrame(-1)}schedule(){this.active&&(this.ticking||(this.ticking=!0,this.requestFrame()))}requestFrame(){let e=this.executeFrame.bind(this,60);op(this.beans,e)}isQueueEmpty(){return!this.ticking}},pq=class extends oI{constructor(){super(...arguments),this.beanName="iconSvc"}createIconNoSpan(e,t){return cv(e,this.beans,t?.column)}},pK=class extends oI{constructor(){super(...arguments),this.beanName="touchSvc"}mockBodyContextMenu(e,t){this.mockContextMenu(e,e.eBodyViewport,t)}mockHeaderContextMenu(e,t){this.mockContextMenu(e,e.eGui,t)}mockRowContextMenu(e){if(!ls())return;let t=(t,n,i)=>{let{rowCtrl:r,cellCtrl:o}=e.getControlsForEventTarget(i?.target??null);o?.column&&o.dispatchCellContextMenuEvent(i??null),this.beans.contextMenuSvc?.handleContextMenuMouseEvent(void 0,i,r,o)};this.mockContextMenu(e,e.element,t)}handleCellDoubleClick(e,t){return!!(()=>{if(!ls()||ox("dblclick"))return!1;let t=Date.now(),n=t-e.lastIPadMouseClickEvent<200;return e.lastIPadMouseClickEvent=t,n})()&&(e.onCellDoubleClicked(t),t.preventDefault(),!0)}setupForHeader(e){let{gos:t,sortSvc:n,menuSvc:i}=this.beans;if(t.get("suppressTouch"))return;let{params:r,eMenu:o,eFilterButton:a}=e,s=new cN(e.getGui(),!0);e.addDestroyFunc(()=>s.destroy());let l=e.shouldSuppressMenuHide(),d=l&&rC(o)&&r.enableMenu,u=s;if(d&&(u=new cN(o,!0),e.addDestroyFunc(()=>u.destroy())),r.enableMenu||i?.isHeaderContextMenuEnabled(r.column)){let t=e=>r.showColumnMenuAfterMouseClick(e.touchStart);e.addManagedListeners(u,{[d?"tap":"longTap"]:t}),e.addManagedListeners(s,{longTap:t})}if(r.enableSorting&&e.addManagedListeners(s,{tap:e=>{let t=e.touchStart.target;l&&(o?.contains(t)||a?.contains(t))||n?.progressSort(r.column,!1,"uiColumnSorted")}}),r.enableFilterButton&&a){let t=new cN(a,!0);e.addManagedListeners(t,{tap:()=>r.showFilter(a)}),e.addDestroyFunc(()=>t.destroy())}}setupForHeaderGroup(e){let t=e.params;if(this.beans.menuSvc?.isHeaderContextMenuEnabled(t.columnGroup.getProvidedColumnGroup())){let n=new cN(t.eGridHeader,!0);e.addManagedListeners(n,{longTap:e=>t.showColumnMenuAfterMouseClick(e.touchStart)}),e.addDestroyFunc(()=>n.destroy())}}setupForHeaderGroupElement(e,t,n){let i=new cN(t,!0);e.addManagedListeners(i,{tap:n}),e.addDestroyFunc(()=>i.destroy())}mockContextMenu(e,t,n){if(!ls())return;let i=new cN(t),r=e=>{oS(this.beans,e.touchEvent)&&n(void 0,e.touchStart,e.touchEvent)};e.addManagedListeners(i,{longTap:r}),e.addDestroyFunc(()=>i.destroy())}},pY=class extends oI{constructor(){super(...arguments),this.beanName="cellNavigation"}wireBeans(e){this.rowSpanSvc=e.rowSpanSvc}getNextCellToFocus(e,t,n=!1){return n?this.getNextCellToFocusWithCtrlPressed(e,t):this.getNextCellToFocusWithoutCtrlPressed(e,t)}getNextCellToFocusWithCtrlPressed(e,t){let n,i,r=e===s1,{pageBounds:o,gos:a,visibleCols:s,pinnedRowModel:l}=this.beans,{rowPinned:d}=t;if(r||e===s3)i=d&&l?r?0:"top"===d?l.getPinnedTopRowCount()-1:l.getPinnedBottomRowCount()-1:r?o.getFirstRow():o.getLastRow(),n=t.column;else{let r=a.get("enableRtl");i=t.rowIndex,n=(e===s0!==r?s.allCols:[...s.allCols].reverse()).find(e=>this.isCellGoodToFocusOn({rowIndex:i,rowPinned:null,column:e}))}return n?{rowIndex:i,rowPinned:d,column:n}:null}getNextCellToFocusWithoutCtrlPressed(e,t){let n=t,i=!1;for(;!i;){switch(e){case s1:n=this.getCellAbove(n);break;case s3:n=this.getCellBelow(n);break;case s2:n=this.gos.get("enableRtl")?this.getCellToLeft(n):this.getCellToRight(n);break;case s0:n=this.gos.get("enableRtl")?this.getCellToRight(n):this.getCellToLeft(n);break;default:n=null,at(8,{key:e})}i=!n||this.isCellGoodToFocusOn(n)}return n}isCellGoodToFocusOn(e){let t,n=e.column,{pinnedRowModel:i,rowModel:r}=this.beans;switch(e.rowPinned){case"top":t=i?.getPinnedTopRow(e.rowIndex);break;case"bottom":t=i?.getPinnedBottomRow(e.rowIndex);break;default:t=r.getRow(e.rowIndex)}return!!t&&!this.isSuppressNavigable(n,t)}getCellToLeft(e){if(!e)return null;let t=this.beans.visibleCols.getColBefore(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellToRight(e){if(!e)return null;let t=this.beans.visibleCols.getColAfter(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellBelow(e){if(!e)return null;let t=this.rowSpanSvc?.getCellEnd(e)??e,n=c8(this.beans,t,!0);return n?{rowIndex:n.rowIndex,column:e.column,rowPinned:n.rowPinned}:null}getCellAbove(e){if(!e)return null;let t=this.rowSpanSvc?.getCellStart(e)??e,n=c6(this.beans,{rowIndex:t.rowIndex,rowPinned:t.rowPinned},!0);return n?{rowIndex:n.rowIndex,column:e.column,rowPinned:n.rowPinned}:null}getNextTabbedCell(e,t){return t?this.getNextTabbedCellBackwards(e):this.getNextTabbedCellForwards(e)}getNextTabbedCellForwards(e){let{visibleCols:t,pagination:n}=this.beans,i=t.allCols,r=e.rowIndex,o=e.rowPinned,a=t.getColAfter(e.column);if(!a){a=i[0];let t=c8(this.beans,e,!0);if(rS(t)||!t.rowPinned&&!(n?.isRowInPage(t.rowIndex)??!0))return null;r=t?t.rowIndex:null,o=t?t.rowPinned:null}return{rowIndex:r,column:a,rowPinned:o}}getNextTabbedCellBackwards(e){let{beans:t}=this,{visibleCols:n,pagination:i}
377=t,r=n.allCols,o=e.rowIndex,a=e.rowPinned,s=n.getColBefore(e.column);if(!s){s=aY(r);let n=c6(t,{rowIndex:e.rowIndex,rowPinned:e.rowPinned},!0);if(rS(n)||!n.rowPinned&&!(i?.isRowInPage(n.rowIndex)??!0))return null;o=n?n.rowIndex:null,a=n?n.rowPinned:null}return{rowIndex:o,column:s,rowPinned:a}}isSuppressNavigable(e,t){let{suppressNavigable:n}=e.colDef;return"boolean"==typeof n?n:"function"==typeof n&&n(e.createColumnFunctionCallbackParams(t))}},pZ=class{constructor(){this.cellValidations=new Map}getCellValidation(e){let{rowNode:t,column:n}=e||{};return this.cellValidations?.get(t)?.get(n)}hasCellValidation(e){return e?.rowNode&&e.column?!!this.getCellValidation(e):this.cellValidations.size>0}setCellValidation(e,t){let{rowNode:n,column:i}=e;this.cellValidations.has(n)||this.cellValidations.set(n,new Map),this.cellValidations.get(n).set(i,t)}clearCellValidation(e){let{rowNode:t,column:n}=e;this.cellValidations.get(t)?.delete(n)}setCellValidationMap(e){this.cellValidations=e}getCellValidationMap(){return this.cellValidations}clearCellValidationMap(){this.cellValidations.clear()}},pX=class{constructor(){this.rowValidations=new Map}getRowValidation(e){let{rowNode:t}=e||{};return this.rowValidations.get(t)}hasRowValidation(e){return e?.rowNode?!!this.getRowValidation(e):this.rowValidations.size>0}setRowValidation({rowNode:e},t){this.rowValidations.set(e,t)}clearRowValidation({rowNode:e}){this.rowValidations.delete(e)}setRowValidationMap(e){this.rowValidations=e}getRowValidationMap(){return this.rowValidations}clearRowValidationMap(){this.rowValidations.clear()}};function pJ(e,t={}){let{rowIndex:n,rowId:i,rowCtrl:r,rowPinned:o}=t;if(r)return r;let{rowModel:a,rowRenderer:s}=e,{rowNode:l}=t;return l||(i?l=function(e,t,n){let i,{rowModel:r,pinnedRowModel:o}=e;return i??(i=r?.getRowNode(t)),n?i??(i=o?.getPinnedRowById(t,n)):(i??(i=o?.getPinnedRowById(t,"top")),i??(i=o?.getPinnedRowById(t,"bottom"))),i}(e,i,o):null!=n&&(l=a.getRow(n))),s.getRowCtrls(l?[l]:[])?.[0]}function pQ(e,t={}){let{cellCtrl:n,colId:i,columnId:r,column:o}=t;if(n)return n;let a=e.colModel.getCol(i??r??p0(o)),s=t.rowCtrl??pJ(e,t),l=s?.getCellCtrl(a)??void 0;if(l)return l;let d=t.rowNode??s?.rowNode;if(d)return e.rowRenderer.getCellCtrls([d],[a])?.[0]}function p0(e){if(e)return"string"==typeof e?e:e.getColId()}var p1=Symbol("unedited");function p2(e,t={}){let n=[];for(let i of e.rowRenderer.getCellCtrls(t.rowNodes,t.columns)){let e=i.comp?.getCellEditor();e&&n.push({ctrl:i,editor:sZ(e)})}return n}function p3({pendingValue:e,sourceValue:t}){return e===p1&&(e=t),e!==t}function p5(e,t,n){let i={editorValueExists:!1};if(p8(e)){let e=t.getValidationErrors?.();if((e?.length??0)>0)return i}if(n?.isCancelling)return i;if(n?.isStopping){let e=t?.isCancelAfterEnd?.();if(e)return{...i,isCancelAfterEnd:e}}return{editorValue:t.getValue(),editorValueExists:!0}}function p4(e,t){for(let n of e.editModelSvc?.getEditPositions()??[]){let i=pQ(e,n
377);if(!i)continue;let r=i.comp?.getCellEditor();if(!r)continue;let{editorValue:o,editorValueExists:a,isCancelAfterEnd:s}=p5(e,r,t);s&&e.editModelSvc?.setEdit(n,{editorState:{isCancelAfterEnd:s}}),p6(e,n,o,void 0,!a,t)}}function p6(e,t,n,i,r,o){let{editModelSvc:a,valueSvc:s}=e;if(!a)return;let{rowNode:l,column:d}=t;if(!(l&&d))return;let u=a.getEdit(t,!0);u?.sourceValue||(u=a.setEdit(t,{sourceValue:s.getValue(d,l,void 0,"api"),pendingValue:u?u.editorValue:p1})),a.setEdit(t,{editorValue:r?u.sourceValue:n}),o?.persist&&function(e,t){let{editModelSvc:n}=e,i=n?.getEdit(t,!0);n?.setEdit(t,{pendingValue:i?.editorValue})}(e,t)}function p8(e){let{gos:t,colModel:n}=e,i=!!t.get("getFullRowEditValidationErrors"),r=n.getColumnDefs()?.filter(e=>e.editable).some(({cellEditorParams:e})=>{let{minLength:t,maxLength:n,getValidationErrors:i,min:r,max:o}=e||{};return void 0!==t||void 0!==n||void 0!==i||void 0!==r||void 0!==o}),o=e.gridApi.getCellEditorInstances().some(e=>e.getValidationElement||e.getValidationErrors);return r||i||o}function p7(e,t){if(!(t||p8(e)))return;let n=p2(e),i=new pZ,{ariaAnnounce:r,localeSvc:o,editModelSvc:a,gos:s}=e,l="fullRow"===s.get("editType"),d=oD(o)("ariaValidationErrorPrefix","Cell Editor Validation");for(let e of n){let{ctrl:t,editor:n}=e,{rowNode:o,column:a}=t,s=n.getValidationErrors?.()??[],l=n.getValidationElement?.(!1)||!n.isPopup?.()&&t.eGui;if(l){let e=null!=s&&s.length>0,t=e?s.join(". "):"";rO(l,"invalid",e),e&&r.announceValue(`${d} ${s}`,"editorValidation"),l instanceof HTMLInputElement?l.setCustomValidity(t):l.classList.toggle("invalid",e)}s?.length>0&&i.setCellValidation({rowNode:o,column:a},{errorMessages:s})}p4(e,{persist:!1}),a?.setCellValidationModel(i);let u=new Set;for(let{ctrl:e}of n)u.add(e.rowCtrl);if(l){let t=p9(e);a?.setRowValidationModel(t)}for(let e of u.values())for(let t of(e.rowEditStyleFeature?.applyRowStyles(),e.getAllCellCtrls()))t.tooltipFeature?.refreshTooltip(!0),t.editorTooltipFeature?.refreshTooltip(!0),t.editStyleFeature?.applyCellStyles?.()}var p9=e=>{let t=new pX,n=e.gos.get("getFullRowEditValidationErrors"),i=e.editModelSvc?.getEditMap();if(!i)return t;for(let e of i.keys()){let r=i.get(e);if(!r)continue;let o=[],{rowIndex:a,rowPinned:s}=e;for(let e of r.keys()){let t=r.get(e);if(!t)continue;let{editorValue:n,pendingValue:i,sourceValue:l}=t,d=n??(i===p1?void 0:i)??l;o.push({column:e,colId:e.getColId(),rowIndex:a,rowPinned:s,oldValue:l,newValue:d})}let l=n?.({editorsState:o})??[];l.length>0&&t.setRowValidation({rowNode:e},{errorMessages:l})}return t},fe=class extends oI{constructor(e,t,n,i){super(),this.cellCtrl=e,this.rowNode=n,this.rowCtrl=i,this.beans=t}init(){this.eGui=this.cellCtrl.eGui}onKeyDown(e){let t=e.key;switch(t){case sJ:this.onEnterKeyDown(e);break;case"F2":this.onF2KeyDown(e);break;case sQ:this.onEscapeKeyDown(e);break;case"Tab":this.onTabKeyDown(e);break;case sX:case s5:this.onBackspaceOrDeleteKeyDown(t,e);break;case s3:case s1:case s2:case s0:this.onNavigationKeyDown(e,t)}}onNavigationKeyDown(e,t){let{cellCtrl:n,beans:i}=this;if(!i.editSvc?.isEditing(n,{withOpenEditor:!0})){if(e.shiftKey&&n.isRangeSelectionEnabled())this.onShiftRangeSelect(e);else{let r=n.getFocusedCellPosition();i.navigation?.navigateToNextCell(e,t,r,!0)}e.preventDefault()}}onShiftRangeSelect(e){let{rangeSvc:t,navigation:n}=this.beans;if(!t)return;let i=t.extendLatestRangeInDirection(e);i&&(e.key===s0||e.key===s2?n?.ensureColumnVisible(i.column):n?.ensureRowVisible(i.rowIndex))}onTabKeyDown(e){this.beans.navigation?.onTabKeyDown(this.cellCtrl,e)}onBackspaceOrDeleteKeyDown(e,t){let{cellCtrl:n,beans:i,rowNode:r}=this,{gos:o,rangeSvc:a,eventSvc:s,editSvc:l}=i;if(s.dispatchEvent({type:"keyShortcutChangedCellStart"}),function(e,t=!1){return e===s5||!t&&e===sX&&la()}(e,o.get("enableCellEditingOnBackspace"))&&!l?.isEditing(n,{withOpenEditor:!0})){if(a&&aT(o))a.clearCellRangeCellValues({dispatchWrapperEvents:!0,wrapperEventSource:"deleteKey"});else if(n.isCellEditable()){let{column:e}=n,t=this.beans.valueSvc.getDeleteValue(e,r);r.setDataValue(e,t,"cellClear")}}else l?.isEditing(n,{withOpenEditor:!0})||i.editSvc?.startEditing(n,{startedEdit:!0,event:t});s.dispatchEvent({type:"keyShortcutChangedCellEnd"})}
377onEnterKeyDown(e){let{cellCtrl:t,beans:n}=this,{editSvc:i,navigation:r}=n,o=i?.isEditing(t,{withOpenEditor:!0}),a=t.rowNode,s=i?.isRowEditing(a,{withOpenEditor:!0}),l=t=>{i?.startEditing(t,{startedEdit:!0,event:e,source:"edit"})&&e.preventDefault()};if(o||s){if(this.isCtrlEnter(e))return void i?.applyBulkEdit(t,n?.rangeSvc?.getCellRanges()||[]);if(p7(n),i?.checkNavWithValidation(void 0,e)==="block-stop")return;i?.isEditing(t,{withOpenEditor:!0})?i?.stopEditing(t,{event:e,source:"edit"}):s&&!t.isCellEditable()?i?.stopEditing({rowNode:a},{event:e,source:"edit"}):l(t)}else if(n.gos.get("enterNavigatesVertically")){let n=e.shiftKey?s1:s3;r?.navigateToNextCell(null,n,t.cellPosition,!1)}else{if(i?.hasValidationErrors())return;i?.hasValidationErrors(t)&&i.revertSingleCellEdit(t,!0),l(t)}}isCtrlEnter(e){return(e.ctrlKey||e.metaKey)&&e.key===sJ}onF2KeyDown(e){let{cellCtrl:t,beans:{editSvc:n}}=this;n?.isEditing()&&(p7(this.beans),n?.checkNavWithValidation(void 0,e)==="block-stop")||n?.startEditing(t,{startedEdit:!0,event:e})}onEscapeKeyDown(e){let{cellCtrl:t,beans:{editSvc:n}}=this;n?.checkNavWithValidation(t,e)==="block-stop"&&n.revertSingleCellEdit(t),n?.stopEditing(t,{event:e,cancel:!0})}processCharacter(e){let t=e.target!==this.eGui,{beans:{editSvc:n},cellCtrl:i}=this;if(!(t||n?.isEditing(i,{withOpenEditor:!0}))){if(" "===e.key)this.onSpaceKeyDown(e);else if(n?.isCellEditable(i,"ui")){if(n?.hasValidationErrors()&&!n?.hasValidationErrors(i))return;n?.startEditing(i,{startedEdit:!0,event:e,source:"api"});let t=i.editCompDetails;t?.params?.suppressPreventDefault||e.preventDefault()}}}onSpaceKeyDown(e){let{gos:t,editSvc:n}=this.beans,{rowNode:i}=this.cellCtrl;!n?.isEditing(this.cellCtrl,{withOpenEditor:!0})&&ad(t)&&this.beans.selectionSvc?.handleSelectionEvent(e,i,"spaceKey"),e.preventDefault()}},ft=class extends oI{constructor(e,t,n){super(),this.cellCtrl=e,this.column=n,this.beans=t}onMouseEvent(e,t){if(!ua(t))switch(e){case"click":this.onCellClicked(t);break;case"mousedown":case"touchstart":this.onMouseDown(t);break;case"dblclick":this.onCellDoubleClicked(t);break;case"mouseout":this.onMouseOut(t);break;case"mouseover":this.onMouseOver(t)}}onCellClicked(e){if(this.beans.touchSvc?.handleCellDoubleClick(this,e))return;let{eventSvc:t,rangeSvc:n,editSvc:i,editModelSvc:r,frameworkOverrides:o,gos:a}=this.beans,s=e.ctrlKey||e.metaKey,{cellCtrl:l}=this,{column:d,cellPosition:u,rowNode:c}=l,h=uy(a,d,c,e);n&&s&&!h&&n.getCellRangeCount(u)>1&&n.intersectLastRange(!0);let p=l.createEvent(e,"cellClicked");p.isEventHandlingSuppressed=h,t.dispatchEvent(p);let f=d.getColDef();if(f.onCellClicked&&window.setTimeout(()=>{o.wrapOutgoing(()=>{f.onCellClicked(p)})},0),!h&&r?.getState(l)!=="editing"){let t=i?.isEditing(),n=r?.getCellValidationModel().getCellValidationMap().size??0,o=r?.getRowValidationModel().getRowValidationMap().size??0;if(t&&(n>0||o>0))return;i?.shouldStartEditing(l,e)?i?.startEditing(l,{event:e}):i?.shouldStopEditing(l,e)&&("fullRow"===this.beans.gos.get("editType")?i?.stopEditing(l,{event:e,source:"edit"}):i?.stopEditing(void 0,{event:e,source:"edit"}))}}onCellDoubleClicked(e){let{column:t,beans:n,cellCtrl:i}=this,{eventSvc:r,frameworkOverrides:o,editSvc:a,editModelSvc:s,gos:l}=n,d=uy(l,i.column,i.rowNode,e),u=t.getColDef(),c=i.createEvent(e,"cellDoubleClicked");if(c.isEventHandlingSuppressed=d,r.dispatchEvent(c),"function"==typeof u.onCellDoubleClicked&&window.setTimeout(()=>{o.wrapOutgoing(()=>{u.onCellDoubleClicked(c)})},0),!d&&a?.shouldStartEditing(i,e)&&s?.getState(i)!=="editing"){let t=a?.isEditing(),n=s?.getCellValidationModel().getCellValidationMap().size??0,r=s?.getRowValidationModel().getRowValidationMap().size??0;if(t&&(n>0||r>0))return;a?.startEditing(i,{event:e})}}onMouseDown(e){let{ctrlKey:t,metaKey:n,shiftKey:i}=e,r=e.target,{cellCtrl:o,beans:a}=this,{eventSvc:s,rangeSvc:l,rowNumbersSvc:d,focusSvc:u,gos:c,editSvc:h}=a,{column:p,rowNode:f,cellPosition:g}=o,m=uy(c,p,f,e),v=()=>{let t=o.createEvent(e,"cellMouseDown");t.isEventHandlingSuppressed=m,s.dispatchEvent(t)};if(m)return void v();if(this.isRightClickInExistingRange(e))return;let y=l&&!l.isEmpty(),b=this.containsWidget(r),x=a7(p);if(d&&x&&!d.handleMouseDownOnCell(g,e)){l&&e.preventDefault(),e.stopImmediatePropagation();return}if(!i||!y){let t=h?.isEditing(o),n=c.get("enableCellTextSelection")&&e.defaultPrevented,i=(lr()||n)&&!t&&!rY(r)&&!b;o.focusCell(i,e)}if(i&&y&&!u.isCellFocused(g)){e.preventDefault();let t=u.getFocusedCell();if(t){let{column:n,rowIndex:i,rowPinned:r}=t;h?.isEditing(t)&&h?.stopEditing(t),u.setFocusedCell({column:n,rowIndex:i,rowPinned:r,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0,sourceEvent:e})}}if(!b){if(l){x&&e.preventDefault();let r=az(a,e)&&x;i?l.extendLatestRangeToCell(g):r||l.setRangeToCell(g,t||n)}v()}}isRightClickInExistingRange(e){let{rangeSvc:t}=this.beans;if(t){let n=t.isCellInAnyRange(this.cellCtrl.cellPosition),i=az(this.beans,e);if(n&&i)return!0}return!1}containsWidget(e){return rJ(e,"ag-selection-checkbox",3)||rJ(e,"ag-drag-handle",3)}
377onMouseOut(e){if(this.mouseStayingInsideCell(e))return;let{eventSvc:t,colHover:n}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOut")),n?.clearMouseOver()}onMouseOver(e){if(this.mouseStayingInsideCell(e))return;let{eventSvc:t,colHover:n}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOver")),n?.setMouseOver([this.column])}mouseStayingInsideCell(e){if(!e.target||!e.relatedTarget)return!1;let t=this.cellCtrl.eGui,n=t.contains(e.target),i=t.contains(e.relatedTarget);return n&&i}},fn=class extends oI{constructor(e,t){super(),this.cellCtrl=e,this.beans=t,this.column=e.column,this.rowNode=e.rowNode}setupRowSpan(){this.rowSpan=this.column.getRowSpan(this.rowNode),this.addManagedListeners(this.beans.eventSvc,{newColumnsLoaded:()=>this.onNewColumnsLoaded()})}init(){this.eSetLeft=this.cellCtrl.getRootElement(),this.eContent=this.cellCtrl.eGui;let e=this.cellCtrl.getCellSpan();if(e||(this.setupColSpan(),this.setupRowSpan()),this.onLeftChanged(),this.onWidthChanged(),e||this._legacyApplyRowSpan(),e){let t=this.refreshSpanHeight.bind(this,e);t(),this.addManagedListeners(this.beans.eventSvc,{paginationChanged:t,recalculateRowBounds:t,pinnedHeightChanged:t})}}refreshSpanHeight(e){let t=e.getCellHeight();null!=t&&(this.eContent.style.height=`${t}px`)}onNewColumnsLoaded(){let e=this.column.getRowSpan(this.rowNode);this.rowSpan!==e&&(this.rowSpan=e,this._legacyApplyRowSpan(!0))}onDisplayColumnsChanged(){let e=this.getColSpanningList();aZ(this.colsSpanning,e)||(this.colsSpanning=e,this.onWidthChanged(),this.onLeftChanged())}setupColSpan(){null!=this.column.getColDef().colSpan&&(this.colsSpanning=this.getColSpanningList(),this.addManagedListeners(this.beans.eventSvc,{displayedColumnsChanged:this.onDisplayColumnsChanged.bind(this),displayedColumnsWidthChanged:this.onWidthChanged.bind(this)}))}onWidthChanged(){if(!this.eContent)return;let e=this.getCellWidth();this.eContent.style.width=`${e}px`}getCellWidth(){return this.colsSpanning?this.colsSpanning.reduce((e,t)=>e+t.getActualWidth(),0):this.column.getActualWidth()}getColSpanningList(){let{column:e,rowNode:t}=this,n=e.getColSpan(t),i=[];if(1===n)i.push(e);else{let t=e,r=e.getPinned();for(let e=0;t&&e<n&&(i.push(t),!(!(t=this.beans.visibleCols.getColAfter(t))||rS(t))&&r===t.getPinned());e++);}return i}onLeftChanged(){if(!this.eSetLeft)return;let e=this.modifyLeftForPrintLayout(this.getCellLeft());this.eSetLeft.style.left=e+"px"}getCellLeft(){return(this.beans.gos.get("enableRtl")&&this.colsSpanning?aY(this.colsSpanning):this.column).getLeft()}modifyLeftForPrintLayout(e){if(!this.cellCtrl.printLayout||"left"===this.column.getPinned())return e;let{visibleCols:t}=this.beans,n=t.getColsLeftWidth();return"right"===this.column.getPinned()?n+t.bodyWidth+(e||0):n+(e||0)}_legacyApplyRowSpan(e){if(1===this.rowSpan&&!e)return;let t=ah(this.beans)*this.rowSpan;this.eContent.style.height=`${t}px`,this.eContent.style.zIndex="1"}destroy(){super.destroy()}},fi=0,fr=class extends oI{constructor(e,t,n,i){super(),this.column=e,this.rowNode=t,this.rowCtrl=i,this.rangeFeature=void 0,this.rowResizeFeature=void 0,this.positionFeature=void 0,this.customStyleFeature=void 0,this.editStyleFeature=void 0,this.mouseListener=void 0,this.keyboardListener=void 0,this.suppressRefreshCell=!1,this.onCompAttachedFuncs=[],this.onEditorAttachedFuncs=[],this.focusEventWhileNotReady=null,this.hasBeenFocused=!1,this.hasEdit=!1,this.tooltipFeature=void 0,this.editorTooltipFeature=void 0,this.beans=n,this.gos=n.gos,this.editSvc=n.editSvc,this.hasEdit=!!n.editSvc;const{colId:r}=e;this.instanceId=r+"-"+fi++,this.createCellPosition(),this.updateAndFormatValue(!1)}addFeatures(){let{beans:e}=this;this.positionFeature=new fn(this,e),this.customStyleFeature=e.cellStyles?.createCellCustomStyleFeature(this,e),this.editStyleFeature=e.editSvc?.createCellStyleFeature(this,e),this.mouseListener=new ft(this,e,this.column),this.keyboardListener=new fe(this,e,this.rowNode,this.rowCtrl),this.enableTooltipFeature();let{rangeSvc:t}=e;t&&aT(e.gos)&&(this.rangeFeature=t.createCellRangeFeature(e,this)),a7(this.column)&&(this.rowResizeFeature=this.beans.rowNumbersSvc.createRowNumbers
377RowResizerFeature(e,this))}isCellSpanning(){return!1}getCellSpan(){}removeFeatures(){let e=this.beans.context;this.positionFeature=e.destroyBean(this.positionFeature),this.editorTooltipFeature=e.destroyBean(this.editorTooltipFeature),this.customStyleFeature=e.destroyBean(this.customStyleFeature),this.editStyleFeature=e.destroyBean(this.editStyleFeature),this.mouseListener=e.destroyBean(this.mouseListener),this.keyboardListener=e.destroyBean(this.keyboardListener),this.rangeFeature=e.destroyBean(this.rangeFeature),this.rowResizeFeature=e.destroyBean(this.rowResizeFeature),this.disableTooltipFeature()}enableTooltipFeature(e,t){this.tooltipFeature=this.beans.tooltipSvc?.enableCellTooltipFeature(this,e,t)}disableTooltipFeature(){this.tooltipFeature=this.beans.context.destroyBean(this.tooltipFeature)}enableEditorTooltipFeature(e){this.editorTooltipFeature&&this.disableEditorTooltipFeature(),this.editorTooltipFeature=this.beans.tooltipSvc?.setupCellEditorTooltip(this,e),p7(this.beans)}disableEditorTooltipFeature(){this.editorTooltipFeature=this.beans.context.destroyBean(this.editorTooltipFeature)}setComp(e,t,n,i,r,o,a){if(this.comp=e,this.eGui=t,this.printLayout=r,a??(a=this),this.addDomData(a),this.addFeatures(),a.addDestroyFunc(()=>this.removeFeatures()),this.onSuppressCellFocusChanged(this.beans.gos.get("suppressCellFocus")),this.setupFocus(),this.applyStaticCssClasses(),this.setWrapText(),this.onFirstRightPinnedChanged(),this.onLastLeftPinnedChanged(),this.onColumnHover(),this.setupControlComps(),this.setupAutoHeight(i,a),this.refreshFirstAndLastStyles(),this.refreshAriaColIndex(),this.positionFeature?.init(),this.customStyleFeature?.setComp(e),this.editStyleFeature?.setComp(e),this.tooltipFeature?.refreshTooltip(),this.keyboardListener?.init(),this.rangeFeature?.setComp(e),this.rowResizeFeature?.refreshRowResizer(),o&&this.isCellEditable()||this.hasEdit&&this.editSvc?.isEditing(this,{withOpenEditor:!0})?this.editSvc?.startEditing(this,{startedEdit:!1,source:"api",silent:!0,continueEditing:!0}):this.showValue(!1,!0),this.onCompAttachedFuncs.length){for(let e of this.onCompAttachedFuncs)e();this.onCompAttachedFuncs=[]}}setupAutoHeight(e,t){this.isAutoHeight=this.beans.rowAutoHeight?.setupCellAutoHeight(this,e,t)??!1}getCellAriaRole(){return this.column.getColDef().cellAriaRole??"gridcell"}isCellRenderer(){let e=this.column.getColDef();return null!=e.cellRenderer||null!=e.cellRendererSelector}getValueToDisplay(){return this.valueFormatted??this.value}getDeferLoadingCellRenderer(){let{beans:e,column:t}=this,{userCompFactory:n,ctrlsSvc:i,eventSvc:r}=e,o=t.getColDef(),a=this.createCellRendererParams();a.deferRender=!0;let s=sK(n,o,a);if(i.getGridBodyCtrl()?.scrollFeature?.isScrolling()){let e,t=new sT(t=>{e=t}),[n]=this.addManagedListeners(r,{bodyScrollEnd:()=>{e(),n()}});return{loadingComp:s,onReady:t}}return{loadingComp:s,onReady:sT.resolve()}}showValue(e,t){let n,{beans:i,column:r,rowNode:o,rangeFeature:a}=this,{userCompFactory:s}=i,l=this.getValueToDisplay(),d=o.stub&&o.groupData?.[r.getId()]==null,u=r.getColDef();if(d||this.isCellRenderer()){let e=this.createCellRendererParams();n=!d||a7(r)?sq(s,u,e):sK(s,u,e)}if(!n&&!d&&i.findSvc?.isMatch(o,r)){let e=this.createCellRendererParams();n=sq(s,{...r.getColDef(),cellRenderer:"agFindCellRenderer"},e)}if(this.hasEdit&&this.editSvc.isBatchEditing()&&this.editSvc.isRowEditing(o,{checkSiblings:!0})){let e=this.editSvc.prepDetailsDuringBatch(this,{compDetails:n,valueToDisplay:l});e&&(e.compDetails?n=e.compDetails:e.valueToDisplay&&(l=e.valueToDisplay))}this.comp.setRenderDetails(n,l,e),this.customRowDragComp?.refreshVisibility(),!t&&a&&op(i,()=>a?.refreshHandle()),this.rowResizeFeature?.refreshRowResizer()}setupControlComps(){let e=this.column.getColDef();this.includeSelection=this.isIncludeControl(this.isCheckboxSelection(e),!0),this.includeRowDrag=this.isIncludeControl(e.rowDrag),this.includeDndSource=this.isIncludeControl(e.dndSource),this.comp.setIncludeSelection(this.includeSelection),this.comp.setIncludeDndSource(this.includeDndSource),this.comp.setIncludeRowDrag(this.includeRowDrag)}isForceWrapper(){return this.beans.gos.get("enableCellTextSelection")||this.column.isAutoHeight()}getCellValueClass(){let e="agCheckboxCellRenderer"===this.column.getColDef().cellRenderer,t="";return e&&(t=" ag-allow-overflow"),`ag-cell-value${t}`}isIncludeControl(e,t=!1){return(null==this.rowNode.rowPinned||t&&cS(this.rowNode))&&!!e}isCheckboxSelection(e){let{rowSelection:t,groupDisplayType:n}=this.beans.gridOptions,i=ak(t),r=a8(this.column);return("custom"!==n||"selectionColumn"===i||!r)&&(e.checkboxSelection||r&&"object"==typeof t&&aS(t))}refreshShouldDestroy(){let e=this.column.getColDef(),t=this.includeSelection!=this.isIncludeControl(this.isCheckboxSelection(e),!0),n=this.includeRowDrag!=this.isIncludeControl(e.rowDrag),i=this.includeDndSource!=this.isIncludeControl(e.dndSource),r=this.isAutoHeight!=this.column.isAutoHeight();return t||n||i||r}onPopupEditorClosed(){let{editSvc:e}=this.beans;e?.isEditing(this,{withOpenEditor:!0})&&e?.stopEditing(this,{source:e?.isBatchEditing()?"ui":"api"})}stopEditing(e=!1){let{editSvc:t}=this.beans;return t?.stopEditing(this,{cancel:e,source:t?.isBatchEditing()?"ui":"api"})??!1}createCellRendererParams(){let{value:e,valueFormatted:t,column:n,rowNode:i,comp:r,eGui:o,beans:{valueSvc:a,gos:s,editSvc:l}}=this;return aN(s,{value:e,valueFormatted:t,getValue:()=>a.getValueForDisplay(n,i).value,setValue:e=>l?.setDataValue({rowNode:i,column:n},e)||i.setDataValue(n,e),formatValue:this.formatValue.bind(this),data:i.data,node:i,pinned:n.getPinned(),colDef:n.getColDef(),column:n,refreshCell:this.refreshCell.bind(this),eGridCell:o,eParentOfValue:r.getParentOfValue(),registerRowDragger:(e,t,n,i)=>this.registerRowDragger(e,t,i),setTooltip:(e,t)=>{s.assertModuleRegistered("Tooltip",3),this.tooltipFeature&&this.disableTooltipFeature(),this.enableTooltipFeature(e,t),this.tooltipFeature?.refreshTooltip()}})}onCellChanged(e){e.column===this.column&&this.refreshCell({})}refreshOrDestroyCell(e){if(this.refreshShouldDestroy()?this.rowCtrl?.recreateCell(this):this.refreshCell(e),this.hasEdit&&this.editCompDetail
377s){let{editSvc:e,comp:t}=this;!t?.getCellEditor()&&e.isEditing(this,{withOpenEditor:!0})&&e.startEditing(this,{startedEdit:!1,source:"api",silent:!0})}}refreshCell({force:e,suppressFlash:t,newData:n}={}){let{editStyleFeature:i,customStyleFeature:r,rowCtrl:{rowEditStyleFeature:o},beans:{cellFlashSvc:a,filterManager:s},column:l,comp:d,suppressRefreshCell:u,tooltipFeature:c}=this;if(u)return;let{field:h,valueGetter:p,showRowGroup:f,enableCellChangeFlash:g}=l.getColDef(),m=!!d,v=this.updateAndFormatValue(m),y=e||null==h&&null==p&&null==f||n||v;if(m){if(y){this.showValue(!!n,!1);let e=s?.isSuppressFlashingCellsBecauseFiltering();t||e||!g||a?.flashCell(this),i?.applyCellStyles?.(),r?.applyUserStyles(),r?.applyClassesFromColDef(),o?.applyRowStyles()}c?.refreshTooltip(),r?.applyCellClassRules()}}isCellEditable(){return this.column.isCellEditable(this.rowNode)}formatValue(e){return this.callValueFormatter(e)??e}callValueFormatter(e){return this.beans.valueSvc.formatValue(this.column,this.rowNode,e)}updateAndFormatValue(e){let t=this.value,n=this.valueFormatted,{value:i,valueFormatted:r}=this.beans.valueSvc.getValueForDisplay(this.column,this.rowNode,!0);return this.value=i,this.valueFormatted=r,!e||!this.valuesAreEqual(t,this.value)||this.valueFormatted!=n}valuesAreEqual(e,t){let n=this.column.getColDef();return n.equals?n.equals(e,t):e===t}addDomData(e){let t=this.eGui;ag(this.beans.gos,t,uw,this),e.addDestroyFunc(()=>ag(this.beans.gos,t,uw,null))}createEvent(e,t){let{rowNode:n,column:i,value:r,beans:o}=this;return function(e,t,n,{rowNode:i,column:r},o){return aN(e.gos,{type:n,node:i,data:i.data,value:o,column:r,colDef:r.getColDef(),rowPinned:i.rowPinned,event:t,rowIndex:i.rowIndex})}(o,e,t,{rowNode:n,column:i},r)}processCharacter(e){this.keyboardListener?.processCharacter(e)}onKeyDown(e){this.keyboardListener?.onKeyDown(e)}onMouseEvent(e,t){this.mouseListener?.onMouseEvent(e,t)}getColSpanningList(){return this.positionFeature?.getColSpanningList()??[]}onLeftChanged(){this.comp&&this.positionFeature?.onLeftChanged()}onDisplayedColumnsChanged(){this.eGui&&(this.refreshAriaColIndex(),this.refreshFirstAndLastStyles())}refreshFirstAndLastStyles(){let{comp:e,column:t,beans:n}=this;uQ(e,t,n.visibleCols)}refreshAriaColIndex(){let e=this.beans.visibleCols.getAriaColIndex(this.column);r$(this.eGui,e)}onWidthChanged(){return this.positionFeature?.onWidthChanged()}getRowPosition(){let{rowIndex:e,rowPinned:t}=this.cellPosition;return{rowIndex:e,rowPinned:t}}updateRangeBordersIfRangeCount(){this.comp&&this.rangeFeature?.updateRangeBordersIfRangeCount()}onCellSelectionChanged(){this.comp&&this.rangeFeature?.onCellSelectionChanged()}isRangeSelectionEnabled(){return null!=this.rangeFeature}focusCell(e=!1,t){let n=this.editSvc?.allowedFocusTargetOnValidation(this);n&&n!==this||this.beans.focusSvc.setFocusedCell({...this.getFocusedCellPosition(),forceBrowserFocus:e,sourceEvent:t})}restoreFocus(e=!1){let{beans:{editSvc:t,focusSvc:n},comp:i}=this;if(!i||t?.isEditing(this)||!this.isCellFocused()||!n.shouldTakeFocus())return;let r=()=>{if(!this.isAlive())return;let e=i.getFocusableElement();this.isCellFocused()&&e.focus({preventScroll:!0})};e?setTimeout(r,0):r()}onRowIndexChanged(){this.createCellPosition(),this.onCellFocused(),this.restoreFocus(),this.rangeFeature?.onCellSelectionChanged(),this.rowResizeFeature?.refreshRowResizer()}onSuppressCellFocusChanged(e){let t=this.eGui;t&&(a7(this.column)&&(e=!0),oc(t,"tabindex",e?void 0:-1))}onFirstRightPinnedChanged(){if(!this.comp)return;let e=this.column.isFirstRightPinned();this.comp.toggleCss("ag-cell-first-right-pinned",e)}onLastLeftPinnedChanged(){if(!this.comp)return;let e=this.column.isLastLeftPinned();this.comp.toggleCss("ag-cell-last-left-pinned",e)}checkCellFocused(){return this.beans.focusSvc.isCellFocused(this.cellPosition)}isCellFocused(){let e=this.checkCellFocused();return this.hasBeenFocused||(this.hasBeenFocused=e),e}setupFocus(){this.restoreFocus(!0),this.onCellFocused(this.focusEventWhileNotReady??void 0)}onCellFocused(e){let{beans:t}=this;if(u1(t))return;if(!this.comp){e&&(this.focusEventWhileNotReady=e);return}let n=this.isCellFocused(),i=t.editSvc?.isEditing(this)??!1;if(this.comp.toggleCss("ag-cell-focus",n),n&&e?.forceBrowserFocus){let t=this.comp.getFocusableElement();if(i){let e=lS(t,null,!0);e.length&&(t=e[0])}t.focus({preventScroll:!!e.preventScrollOnBrowserFocus})}n&&e&&this.rowCtrl.announceDescription()}createCellPosition(){let{rowIndex:e,rowPinned:t}=this.rowNode;this.cellPosition={rowIndex:e,rowPinned:rw(t),column:this.column}}
377applyStaticCssClasses(){let{comp:e}=this;e.toggleCss("ag-cell",!0),e.toggleCss("ag-cell-not-inline-editing",!0);let t=!0==this.column.isAutoHeight();e.toggleCss("ag-cell-auto-height",t),e.toggleCss("ag-cell-normal-height",!t)}onColumnHover(){this.beans.colHover?.onCellColumnHover(this.column,this.comp)}onColDefChanged(){this.comp&&(this.column.isTooltipEnabled()?(this.disableTooltipFeature(),this.enableTooltipFeature()):this.disableTooltipFeature(),this.setWrapText(),this.editSvc?.isEditing(this)?this.editSvc?.handleColDefChanged(this):this.refreshOrDestroyCell({force:!0,suppressFlash:!0}))}setWrapText(){let e=!0==this.column.getColDef().wrapText;this.comp.toggleCss("ag-cell-wrap-text",e)}dispatchCellContextMenuEvent(e){let t=this.column.getColDef(),n=this.createEvent(e,"cellContextMenu"),{beans:i}=this;i.eventSvc.dispatchEvent(n),t.onCellContextMenu&&window.setTimeout(()=>{i.frameworkOverrides.wrapOutgoing(()=>{t.onCellContextMenu(n)})},0)}getCellRenderer(){return this.comp?.getCellRenderer()??null}destroy(){this.onCompAttachedFuncs=[],this.onEditorAttachedFuncs=[],this.isCellFocused()&&this.hasBrowserFocus()&&this.beans.focusSvc.attemptToRecoverFocus(),super.destroy()}hasBrowserFocus(){return this.eGui?.contains(rA(this.beans))??!1}createSelectionCheckbox(){let e=this.beans.selectionSvc?.createCheckboxSelectionComponent();if(e)return this.beans.context.createBean(e),e.init({rowNode:this.rowNode,column:this.column}),e}createDndSource(){let e=this.beans.registry.createDynamicBean("dndSourceComp",!1,this.rowNode,this.column,this.eGui);return e&&this.beans.context.createBean(e),e}registerRowDragger(e,t,n){if(this.customRowDragComp)return void this.customRowDragComp.setDragElement(e,t);let i=this.createRowDragComp(e,t,n);i&&(this.customRowDragComp=i,this.addDestroyFunc(()=>{this.beans.context.destroyBean(i),this.customRowDragComp=null}),i.refreshVisibility())}createRowDragComp(e,t,n){let i=this.beans.rowDragSvc?.createRowDragCompForCell(this.rowNode,this.column,()=>this.value,e,t,n);if(i)return this.beans.context.createBean(i),i}cellEditorAttached(){for(let e of this.onEditorAttachedFuncs)e();this.onEditorAttachedFuncs=[]}setFocusedCellPosition(e){}getFocusedCellPosition(){return this.cellPosition}refreshAriaRowIndex(){}getRootElement(){return this.eGui}};function fo(e,t,n,i,r,o){if(null==n&&null==t)return;let a={},s={},l=(e,t)=>{for(let n of e.split(" "))""!=n.trim()&&t(n)};if(n){let t=Object.keys(n);for(let r=0;r<t.length;r++){let o,d=t[r],u=n[d];"string"==typeof u?o=!e||e.evaluate(u,i):"function"==typeof u&&(o=u(i)),l(d,e=>{o?a[e]=!0:s[e]=!0})}}if(t&&o)for(let e of Object.keys(t))l(e,e=>{a[e]||(s[e]=!0)});o&&Object.keys(s).forEach(o),Object.keys(a).forEach(r)}function fa(e){if(e.group)return e.level;let t=e.parent;return t?t.level+1:0}var fs=class extends oI{constructor(){super(...arguments),this.beanName="rowStyleSvc"}processClassesFromGridOptions(e,t){let n=this.gos,i=t=>{if("string"==typeof t)e.push(t);else if(Array.isArray(t))for(let n of t)e.push(n)},r=n.get("rowClass");r&&i(r);let o=n.getCallback("getRowClass");o&&i(o({data:t.data,node:t,rowIndex:t.rowIndex}))}preProcessRowClassRules(e,t){this.processRowClassRules(t,t=>{e.push(t)},()=>{})}processRowClassRules(e,t,n){let{gos:i,expressionSvc:r}=this.beans,o=aN(i,{data:e.data,node:e,rowIndex:e.rowIndex});fo(r,void 0,i.get("rowClassRules"),o,t,n)}processStylesFromGridOptions(e){let t,n=this.gos,i=n.get("rowStyle"),r=n.getCallback("getRowStyle");if(r&&(t=r({data:e.data,node:e,rowIndex:e.rowIndex})),t||i)return Object.assign({},i,t)}},fl=0,fd=class extends oI{constructor(e,t,n,i,r){super(),this.rowNode=e,this.useAnimationFrameForCreate=i,this.printLayout=r,this.allRowGuis=[],this.active=!0,this.centerCellCtrls={list:[],map:{}},this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}},this.slideInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.fadeInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.rowDragComps=[],this.lastMouseDownOnDragger=!1,this.emptyStyle={},this.updateColumnListsPending=!1,this.rowId=null,this.businessKey=null,this.beans=t,this.gos=t.gos,this.paginationPage=t.pagination?.getCurrentPage()??0,this.suppressRowTransform=this.gos.get("suppressRowTransform"),this.instanceId=e.id+"-"+fl++,this.rowId=rR(e.id),this.initRowBusinessKey(),this.rowFocused=t.focusSvc.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned),this.rowLevel=fa(this.rowNode),this.setRowType(),this.setAnimateFlags(n),this.rowStyles=this.processStylesFromGridOptions(),this.rowEditStyleFeature=t.editSvc?.createRowStyleFeature
377(this,t),this.addListeners()}initRowBusinessKey(){this.businessKeyForNodeFunc=this.gos.get("getBusinessKeyForNode"),this.updateRowBusinessKey()}updateRowBusinessKey(){if("function"!=typeof this.businessKeyForNodeFunc)return;let e=this.businessKeyForNodeFunc(this.rowNode);this.businessKey=rR(e)}updateGui(e,t){"left"===e?this.leftGui=t:"right"===e?this.rightGui=t:"fullWidth"===e?this.fullWidthGui=t:this.centerGui=t}setComp(e,t,n,i){let{context:r,focusSvc:o}=this.beans,a={rowComp:e,element:t,containerType:n,compBean:i=sx(this,r,i)};this.allRowGuis.push(a),this.updateGui(n,a),this.initialiseRowComp(a);let s=this.rowNode,l="FullWidthLoading"===this.rowType||s.stub,d=!s.data&&"infinite"===this.beans.rowModel.getType();l||d||s.rowPinned||this.beans.rowRenderer.dispatchFirstDataRenderedEvent();let u=this.fullWidthGui?.element;u&&!this.beans.editSvc?.isEditing(this)&&o.isRowFocused(s.rowIndex,s.rowPinned)&&o.shouldTakeFocus()&&setTimeout(()=>u.focus({preventScroll:!0}),0)}unsetComp(e){this.allRowGuis=this.allRowGuis.filter(t=>t.containerType!==e),this.updateGui(e,void 0)}isCacheable(){return"FullWidthDetail"===this.rowType&&this.gos.get("keepDetailRows")}setCached(e){let t=e?"none":"";for(let e of this.allRowGuis)e.element.style.display=t}initialiseRowComp(e){let t=this.gos;this.onSuppressCellFocusChanged(this.beans.gos.get("suppressCellFocus")),this.listenOnDomOrder(e),this.onRowHeightChanged(e),this.updateRowIndexes(e),this.setFocusedClasses(e),this.setStylesFromGridOptions(!1,e),ad(t)&&this.rowNode.selectable&&this.onRowSelected(e),this.updateColumnLists(!this.useAnimationFrameForCreate);let n=e.rowComp;for(let t of this.getInitialRowClasses(e.containerType))n.toggleCss(t,!0);this.executeSlideAndFadeAnimations(e),this.rowNode.group&&rG(e.element,!0==this.rowNode.expanded),this.setRowCompRowId(n),this.setRowCompRowBusinessKey(n),ag(t,e.element,uC,this),e.compBean.addDestroyFunc(()=>ag(t,e.element,uC,null)),this.useAnimationFrameForCreate?this.beans.animationFrameSvc.createTask(this.addHoverFunctionality.bind(this,e),this.rowNode.rowIndex,"p2",!1):this.addHoverFunctionality(e),this.isFullWidth()&&this.setupFullWidth(e),t.get("rowDragEntireRow")&&this.addRowDraggerToRow(e),this.useAnimationFrameForCreate&&this.beans.animationFrameSvc.addDestroyTask(()=>{this.isAlive()&&e.rowComp.toggleCss("ag-after-created",!0)}),this.executeProcessRowPostCreateFunc()}setRowCompRowBusinessKey(e){null!=this.businessKey&&e.setRowBusinessKey(this.businessKey)}setRowCompRowId(e){let t=rR(this.rowNode.id);this.rowId=t,null!=t&&e.setRowId(t)}executeSlideAndFadeAnimations(e){let{containerType:t}=e;this.slideInAnimation[t]&&(oF(()=>{this.onTopChanged()}),this.slideInAnimation[t]=!1),this.fadeInAnimation[t]&&(oF(()=>{e.rowComp.toggleCss("ag-opacity-zero",!1)}),this.fadeInAnimation[t]=!1)}addRowDraggerToRow(e){let t=this.beans.rowDragSvc?.createRowDragCompForRow(this.rowNode,e.element);if(!t)return;let n=this.createBean(t,this.beans.context);this.rowDragComps.push(n),e.compBean.addDestroyFunc(()=>{this.rowDragComps=this.rowDragComps.filter(e=>e!==n),this.rowEditStyleFeature=this.destroyBean(this.rowEditStyleFeature,this.beans.context),this.destroyBean(n,this.beans.context)})}setupFullWidth(e){let t=this.getPinnedForContainer(e.containerType),n=this.createFullWidthCompDetails(e.element,t);e.rowComp.showFullWidth(n)}getFullWidthCellRenderers(){return this.gos.get("embedFullWidthRows")?this.allRowGuis.map(e=>e?.rowComp?.getFullWidthCellRenderer()):[this.fullWidthGui?.rowComp?.getFullWidthCellRenderer()]}executeProcessRowPostCreateFunc(){let e=this.gos.getCallback("processRowPostCreate");e&&this.areAllContainersReady()&&e({eRow:this.centerGui.element,ePinnedLeftRow:this.leftGui?this.leftGui.element:void 0,ePinnedRightRow:this.rightGui?this.rightGui.element:void 0,node:this.rowNode,rowIndex:this.rowNode.rowIndex,addRenderedRowListener:this.addEventListener.bind(this)})}areAllContainersReady(){let{leftGui:e,centerGui:t,rightGui:n,beans:{visibleCols:i}}=this,r=!!e||!i.isPinningLeft(),o=!!n||!i.isPinningRight();return r&&!!t&&o}isNodeFullWidthCell(){if(this.rowNode.detail)return!0;let e=this.beans.gos.getCallback("isFullWidthRow");return!!e&&e({rowNode:this.rowNode})}setRowType(){let e=this.rowNode.stub&&!this.gos.get("suppressServerSideFullWidthLoadingRow")&&!this.gos.get("groupHideOpenParents"),t=this.isNodeFullWidthCell(),n=this.gos.get("masterDetail")&&this.rowNode.detail,i=this.beans.colModel.isPivotMode(),r=aw(this.gos,this.rowNode,i);e?this.rowType="FullWidthLoading":n?this.rowType="FullWidthDetail":t?this.rowType="FullWidth":r?this.rowType="FullWidthGroup":this.rowType="Normal"}updateColumnLists(e=!1,t=!1){if(this.isFullWidth())return;let{animationFrameSvc:n}=this.beans;!n?.active||e||this.printLayout?this.updateColumnListsImpl(t):this.updateColumnListsPending||(n.createTask(()=>{this.active&&this.updateColumnListsImpl(!0)},this.rowNode.rowIndex,"p1",!1),this.updateColumnListsPending=!0)}getNewCellCtrl(e){if(!this.beans.rowSpanSvc?.isCellSpanning(e,this.rowNode))return new fr(e,this.rowNode,this.beans,this)}isCorrectCtrlForSpan(e){return!this.beans.rowSpanSvc?.isCellSpanning(e.column,this.rowNode)}createCellCtrls(e,t,n=null){let i={list:[],map:{}},r=(e,t,n)=>{null!=n?i.list.splice(n,0,t):i.list.push(t),i.map[e]=t},o=[];for(let n of t){let t=n.getInstanceId(),i=e.map[t];
377i&&!this.isCorrectCtrlForSpan(i)&&(i.destroy(),i=void 0),i||(i=this.getNewCellCtrl(n)),i&&r(t,i)}for(let t of e.list){let e=t.column.getInstanceId();null==i.map[e]&&(this.isCellEligibleToBeRemoved(t,n)?t.destroy():o.push([e,t]))}if(o.length)for(let[e,t]of o){let n=i.list.findIndex(e=>e.column.getLeft()>t.column.getLeft());r(e,t,-1===n?void 0:Math.max(n-1,0))}let{focusSvc:a,visibleCols:s}=this.beans,l=a.getFocusedCell();if(l&&l.column.getPinned()==n){let e=l.column.getInstanceId();if(!i.map[e]&&s.allCols.includes(l.column)){let t=this.createFocusedCellCtrl();if(t){let n=i.list.findIndex(e=>e.column.getLeft()>t.column.getLeft());r(e,t,-1===n?void 0:Math.max(n-1,0))}}}return i}createFocusedCellCtrl(){let{focusSvc:e,rowSpanSvc:t}=this.beans,n=e.getFocusedCell();if(!n)return;let i=t?.getCellSpan(n.column,this.rowNode);if(i){if(i.firstNode!==this.rowNode||!i.doesSpanContain(n))return}else if(!e.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned))return;return this.getNewCellCtrl(n.column)}updateColumnListsImpl(e){this.updateColumnListsPending=!1,this.createAllCellCtrls(),this.setCellCtrls(e)}setCellCtrls(e){for(let t of this.allRowGuis){let n=this.getCellCtrlsForContainer(t.containerType);t.rowComp.setCellCtrls(n,e)}}getCellCtrlsForContainer(e){switch(e){case"left":return this.leftCellCtrls.list;case"right":return this.rightCellCtrls.list;case"fullWidth":return[];case"center":return this.centerCellCtrls.list}}createAllCellCtrls(){let e=this.beans.colViewport,t=this.beans.visibleCols;if(this.printLayout)this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,t.allCols),this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}};else{let n=e.getColsWithinViewport(this.rowNode);this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,n);let i=t.getLeftColsForRow(this.rowNode);this.leftCellCtrls=this.createCellCtrls(this.leftCellCtrls,i,"left");let r=t.getRightColsForRow(this.rowNode);this.rightCellCtrls=this.createCellCtrls(this.rightCellCtrls,r,"right")}}isCellEligibleToBeRemoved(e,t){let{column:n}=e;if(n.getPinned()!=t||!this.isCorrectCtrlForSpan(e))return!0;let{visibleCols:i,editSvc:r}=this.beans,o=r?.isEditing(e),a=e.isCellFocused();return!o&&!a||!(i.allCols.indexOf(n)>=0)}getDomOrder(){return this.gos.get("ensureDomOrder")||al(this.gos,"print")}listenOnDomOrder(e){let t=()=>{e.rowComp.setDomOrder(this.getDomOrder())};e.compBean.addManagedPropertyListeners(["domLayout","ensureDomOrder"],t)}setAnimateFlags(e){if(this.rowNode.sticky||!e)return;let t=rC(this.rowNode.oldRowTop),{visibleCols:n}=this.beans,i=n.isPinningLeft(),r=n.isPinningRight();if(t){let{slideInAnimation:e}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows")){e.fullWidth=!0;return}e.center=!0,e.left=i,e.right=r}else{let{fadeInAnimation:e}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows")){e.fullWidth=!0;return}e.center=!0,e.left=i,e.right=r}}isFullWidth(){return"Normal"!==this.rowType}refreshFullWidth(){let e=(e,t)=>!e||e.rowComp.refreshFullWidth(()=>this.createFullWidthCompDetails(e.element,t).params),t=e(this.fullWidthGui,null),n=e(this.centerGui,null),i=e(this.leftGui,"left"),r=e(this.rightGui,"right");return t&&n&&i&&r}addListeners(){let{beans:e,gos:t,rowNode:n}=this,{expansionSvc:i,eventSvc:r,context:o,rowSpanSvc:a}=e;this.addManagedListeners(this.rowNode,{heightChanged:()=>this.onRowHeightChanged(),rowSelected:()=>this.onRowSelected(),rowIndexChanged:this.onRowIndexChanged.bind(this),topChanged:this.onTopChanged.bind(this),...i?.getRowExpandedListeners(this)??{}}),n.detail&&this.addManagedListeners(n.parent,{dataChanged:this.onRowNodeDataChanged.bind(this)}),this.addManagedListeners(n,{dataChanged:this.onRowNodeDataChanged.bind(this),cellChanged:this.postProcessCss.bind(this),rowHighlightChanged:this.onRowNodeHighlightChanged.bind(this),draggingChanged:this.postProcessRowDragging.bind(this),uiLevelChanged:this.onUiLevelChanged.bind(this),rowPinned:this.onRowPinned.bind(this)}),this.addManagedListeners(r,{paginationPixelOffsetChanged:this.onPaginationPixelOffsetChanged.bind(this),heightScaleChanged:this.onTopChanged.bind(this),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),virtualColumnsChanged:this.onVirtualColumnsChanged.bind(this),cellFocused:this.onCellFocusChanged.bind(this),cellFocusCleared:this.onCellFocusChanged.bind(this),paginationChanged:this.onPaginationChanged.bind(this),modelUpdated:this.refreshFirstAndLastRowStyles.bind(this),columnMoved:()=>this.updateColumnLists()}),a&&this.addManagedListeners(a,{spannedCellsUpdated:({pinned:e})=>{(!e||n.rowPinned)&&this.updateColumnLists()}}),this.addDestroyFunc(()=>{this.rowDragComps=this.destroyBeans(this.rowDragComps,o),this.tooltipFeature=this.destroyBean(this.tooltipFeature,o),this.rowEditStyleFeature=this.destroyBean(this.rowEditStyleFeature,o)}),this.addManagedPropertyListeners(["rowStyle","getRowStyle","rowClass","getRowClass","rowClassRules"],this.postProcessCss.bind(this)),this.addManagedPropertyListener("rowDragEntireRow",()=>{if(t.get("rowDragEntireRow")){for(let e of this.allRowGuis)this.addRowDraggerToRow(e);return}this.rowDragComps=this.destroyBeans(this.rowDragComps,o)}),this.addListenersForCellComps()}
377addListenersForCellComps(){this.addManagedListeners(this.rowNode,{rowIndexChanged:()=>{for(let e of this.getAllCellCtrls())e.onRowIndexChanged()},cellChanged:e=>{for(let t of this.getAllCellCtrls())t.onCellChanged(e)}})}onRowPinned(){for(let e of this.allRowGuis)e.rowComp.toggleCss("ag-row-pinned-source",!!this.rowNode.pinnedSibling)}onRowNodeDataChanged(e){this.refreshRow({suppressFlash:!e.update,newData:!e.update})}refreshRow(e){if(this.isFullWidth()!==!!this.isNodeFullWidthCell())return void this.beans.rowRenderer.redrawRow(this.rowNode);if(this.isFullWidth()){this.refreshFullWidth()||this.beans.rowRenderer.redrawRow(this.rowNode);return}for(let t of this.getAllCellCtrls())t.refreshCell(e);for(let e of this.allRowGuis)this.setRowCompRowId(e.rowComp),this.updateRowBusinessKey(),this.setRowCompRowBusinessKey(e.rowComp);this.onRowSelected(),this.postProcessCss()}postProcessCss(){this.setStylesFromGridOptions(!0),this.postProcessClassesFromGridOptions(),this.postProcessRowClassRules(),this.rowEditStyleFeature?.applyRowStyles(),this.postProcessRowDragging()}onRowNodeHighlightChanged(){let e=this.beans.rowDropHighlightSvc,t=e?.row===this.rowNode?e.position:"none",n="above"===t,i="inside"===t,r="below"===t,o=this.gos.get("treeData")&&(r||n),a=this.rowNode.uiLevel.toString();for(let e of this.allRowGuis){let t=e.rowComp;t.toggleCss("ag-row-highlight-above",n),t.toggleCss("ag-row-highlight-inside",i),t.toggleCss("ag-row-highlight-below",r),t.toggleCss("ag-row-highlight-indent",o),o?e.element.style.setProperty("--ag-row-highlight-level",a):e.element.style.removeProperty("--ag-row-highlight-level")}}postProcessRowDragging(){let e=this.rowNode.dragging;for(let t of this.allRowGuis)t.rowComp.toggleCss("ag-row-dragging",e)}onDisplayedColumnsChanged(){this.updateColumnLists(!0),this.beans.rowAutoHeight?.requestCheckAutoHeight()}onVirtualColumnsChanged(){this.updateColumnLists(!1,!0)}getRowPosition(){return{rowPinned:rw(this.rowNode.rowPinned),rowIndex:this.rowNode.rowIndex}}onKeyboardNavigate(e){let t=this.findFullWidthInfoForEvent(e);if(!t)return;let{rowGui:n,column:i}=t;if(n.element!==e.target)return;let r=this.rowNode,{focusSvc:o,navigation:a}=this.beans,s=o.getFocusedCell(),l={rowIndex:r.rowIndex,rowPinned:r.rowPinned,column:s?.column??i};a?.navigateToNextCell(e,e.key,l,!0),e.preventDefault()}onTabKeyDown(e){if(e.defaultPrevented||ua(e))return;let t=this.allRowGuis.find(t=>t.element.contains(e.target)),n=t?t.element:null,i=n===e.target,r=rA(this.beans),o=!1;n&&r&&(o=n.contains(r)&&r.classList.contains("ag-cell"));let a=null;i||o||(a=lk(this.beans,n,!1,e.shiftKey)),(this.isFullWidth()&&i||!a)&&this.beans.navigation?.onTabKeyDown(this,e)}getFullWidthElement(){return this.fullWidthGui?this.fullWidthGui.element:null}getRowYPosition(){let e=this.allRowGuis.find(e=>oe(e.element))?.element;return e?e.getBoundingClientRect().top:0}onSuppressCellFocusChanged(e){let t=this.isFullWidth()&&e?void 0:this.gos.get("tabIndex");for(let e of this.allRowGuis)oc(e.element,"tabindex",t)}onFullWidthRowFocused(e){let t,n=this.rowNode,i=!!e&&this.isFullWidth()&&e.rowIndex===n.rowIndex&&e.rowPinned==n.rowPinned;if(this.fullWidthGui)t=this.fullWidthGui.element;else{let n=this.beans.colModel.getCol(e?.column),i=n?.pinned;t=i?"right"===i?this.rightGui?.element:this.leftGui?.element:this.centerGui?.element}t&&(t.classList.toggle("ag-full-width-focus",i),i&&e?.forceBrowserFocus&&t.focus({preventScroll:!0}))}recreateCell(e){this.centerCellCtrls=this.removeCellCtrl(this.centerCellCtrls,e),this.leftCellCtrls=this.removeCellCtrl(this.leftCellCtrls,e),this.rightCellCtrls=this.removeCellCtrl(this.rightCellCtrls,e),e.destroy(),this.updateColumnLists()}removeCellCtrl(e,t){let n={list:[],map:{}};for(let i of e.list)i!==t&&(n.list.push(i),n.map[i.column.getInstanceId()]=i);return n}onMouseEvent(e,t){switch(e){case"dblclick":this.onRowDblClick(t);break;case"click":this.onRowClick(t);break;case"touchstart":case"mousedown":this.onRowMouseDown(t)}}createRowEvent(e,t){let{rowNode:n}=this;return aN(this.gos,{type:e,node:n,data:n.data,rowIndex:n.rowIndex,rowPinned:n.rowPinned,event:t})}createRowEventWithSource(e,t){let n=this.createRowEvent(e,t);return n.source=this,n}onRowDblClick(e){if(ua(e))return;let t=this.createRowEventWithSource("rowDoubleClicked",e);t.isEventHandlingSuppressed=this.isSuppressMouseEvent(e),this.beans.eventSvc.dispatchEvent(t)}findFullWidthInfoForEvent(e){if(!e)return;let t=this.findFullWidthRowGui(e.target),n=this.getColumnForFullWidth(t);if(t&&n)return{rowGui:t,column:n}}findFullWidthRowGui(e){return this.allRowGuis.find(t=>t.element.contains(e))}getColumnForFullWidth(e){let{visibleCols:t}=this.beans;switch(e?.containerType){case"center":return t.centerCols[0];case"left":return t.leftCols[0];case"right":return t.rightCols[0];default:return t.allCols[0]}}onRowMouseDown(e){if(this.lastMouseDownOnDragger=rJ(e.target,"ag-row-drag",3),!this.isFullWidth()||this.isSuppressMouseEvent(e))return;let{rangeSvc:t,focusSvc:n}=this.beans;t?.removeAllCellRanges();let i=this.findFullWidthInfoForEvent(e);
377if(!i)return;let{rowGui:r,column:o}=i,a=r.element,s=e.target,l=this.rowNode,d=e.defaultPrevented||lr();a&&a.contains(s)&&rY(s)&&(d=!1),n.setFocusedCell({rowIndex:l.rowIndex,column:o,rowPinned:l.rowPinned,forceBrowserFocus:d})}isSuppressMouseEvent(e){let{gos:t,rowNode:n}=this;if(this.isFullWidth()){var i;let r=this.findFullWidthRowGui(e.target);return i=r?.rowComp.getFullWidthCellRendererParams(),ub(t,void 0,n,e,i?.suppressMouseEventHandling)}let r=ux(t,e.target,uw);return null!=r&&uy(t,r.column,n,e)}onRowClick(e){if(ua(e)||this.lastMouseDownOnDragger)return;let t=this.isSuppressMouseEvent(e),{eventSvc:n,selectionSvc:i}=this.beans,r=this.createRowEventWithSource("rowClicked",e);r.isEventHandlingSuppressed=t,n.dispatchEvent(r),t||i?.handleSelectionEvent(e,this.rowNode,"rowClicked")}setupDetailRowAutoHeight(e){"FullWidthDetail"===this.rowType&&this.beans.masterDetailSvc?.setupDetailRowAutoHeight(this,e)}createFullWidthCompDetails(e,t){let{gos:n,rowNode:i}=this,r=aN(n,{fullWidth:!0,data:i.data,node:i,value:i.key,valueFormatted:i.key,eGridCell:e,eParentOfValue:e,pinned:t,addRenderedRowListener:this.addEventListener.bind(this),registerRowDragger:(e,t,n,i)=>this.addFullWidthRowDragging(e,t,n,i),setTooltip:(e,t)=>{n.assertModuleRegistered("Tooltip",3),this.setupFullWidthRowTooltip(e,t)}}),o=this.beans.userCompFactory;switch(this.rowType){case"FullWidthDetail":return o.getCompDetailsFromGridOptions(sU,"agDetailCellRenderer",r,!0);case"FullWidthGroup":{let{value:e,valueFormatted:t}=this.beans.valueSvc.getValueForDisplay(void 0,this.rowNode,!0);return r.value=e,r.valueFormatted=t,o.getCompDetailsFromGridOptions(s$,"agGroupRowRenderer",r,!0)}case"FullWidthLoading":return o.getCompDetailsFromGridOptions(sW,"agLoadingCellRenderer",r,!0);default:return o.getCompDetailsFromGridOptions(sG,void 0,r,!0)}}setupFullWidthRowTooltip(e,t){this.fullWidthGui&&(this.tooltipFeature=this.beans.tooltipSvc?.setupFullWidthRowTooltip(this.tooltipFeature,this,e,t))}addFullWidthRowDragging(e,t,n="",i){let{rowDragSvc:r,context:o}=this.beans;if(!r||!this.isFullWidth())return;let a=r.createRowDragComp(()=>n,this.rowNode,void 0,e,t,i);this.createBean(a,o),this.addDestroyFunc(()=>{this.destroyBean(a,o)})}onUiLevelChanged(){let e=fa(this.rowNode);if(this.rowLevel!=e){let t="ag-row-level-"+e,n="ag-row-level-"+this.rowLevel;for(let e of this.allRowGuis)e.rowComp.toggleCss(t,!0),e.rowComp.toggleCss(n,!1)}this.rowLevel=e}isFirstRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getFirstRow()}isLastRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getLastRow()}refreshFirstAndLastRowStyles(){let e=this.isFirstRowOnPage(),t=this.isLastRowOnPage();if(this.firstRowOnPage!==e)for(let t of(this.firstRowOnPage=e,this.allRowGuis))t.rowComp.toggleCss("ag-row-first",e);if(this.lastRowOnPage!==t)for(let e of(this.lastRowOnPage=t,this.allRowGuis))e.rowComp.toggleCss("ag-row-last",t)}getAllCellCtrls(){return 0===this.leftCellCtrls.list.length&&0===this.rightCellCtrls.list.length?this.centerCellCtrls.list:[...this.centerCellCtrls.list,...this.leftCellCtrls.list,...this.rightCellCtrls.list]}postProcessClassesFromGridOptions(){let e=[];
377if(this.beans.rowStyleSvc?.processClassesFromGridOptions(e,this.rowNode),e.length)for(let t of e)for(let e of this.allRowGuis)e.rowComp.toggleCss(t,!0)}postProcessRowClassRules(){this.beans.rowStyleSvc?.processRowClassRules(this.rowNode,e=>{for(let t of this.allRowGuis)t.rowComp.toggleCss(e,!0)},e=>{for(let t of this.allRowGuis)t.rowComp.toggleCss(e,!1)})}setStylesFromGridOptions(e,t){e&&(this.rowStyles=this.processStylesFromGridOptions()),this.forEachGui(t,e=>e.rowComp.setUserStyles(this.rowStyles))}getPinnedForContainer(e){return"left"===e||"right"===e?e:null}getInitialRowClasses(e){let t=this.getPinnedForContainer(e),n=this.isFullWidth(),{rowNode:i,beans:r}=this,o=[];o.push("ag-row"),o.push(this.rowFocused?"ag-row-focus":"ag-row-no-focus"),this.fadeInAnimation[e]&&o.push("ag-opacity-zero"),o.push(i.rowIndex%2==0?"ag-row-even":"ag-row-odd"),i.isRowPinned()&&(o.push("ag-row-pinned"),r.pinnedRowModel?.isManual()&&o.push("ag-row-pinned-manual")),!i.isRowPinned()&&i.pinnedSibling&&o.push("ag-row-pinned-source"),i.isSelected()&&o.push("ag-row-selected"),i.footer&&o.push("ag-row-footer"),o.push("ag-row-level-"+this.rowLevel),i.stub&&o.push("ag-row-loading"),n&&o.push("ag-full-width-row"),r.expansionSvc?.addExpandedCss(o,i),i.dragging&&o.push("ag-row-dragging");let{rowStyleSvc:a}=r;return a&&(a.processClassesFromGridOptions(o,i),a.preProcessRowClassRules(o,i)),o.push(this.printLayout?"ag-row-position-relative":"ag-row-position-absolute"),this.isFirstRowOnPage()&&o.push("ag-row-first"),this.isLastRowOnPage()&&o.push("ag-row-last"),n&&("left"===t&&o.push("ag-cell-last-left-pinned"),"right"===t&&o.push("ag-cell-first-right-pinned")),o}processStylesFromGridOptions(){return this.beans.rowStyleSvc?.processStylesFromGridOptions(this.rowNode)??this.emptyStyle}onRowSelected(e){this.beans.selectionSvc?.onRowCtrlSelected(this,e=>{(e===this.centerGui||e===this.fullWidthGui)&&this.announceDescription()},e)}announceDescription(){this.beans.selectionSvc?.announceAriaRowSelection(this.rowNode)}addHoverFunctionality(e){if(!this.active)return;let{element:t,compBean:n}=e,{rowNode:i,beans:r,gos:o}=this;n.addManagedListeners(t,{pointerenter:e=>{"mouse"===e.pointerType&&i.dispatchRowEvent("mouseEnter")},pointerleave:e=>{"mouse"===e.pointerType&&i.dispatchRowEvent("mouseLeave")}}),n.addManagedListeners(i,{mouseEnter:()=>{r.dragSvc?.dragging||o.get("suppressRowHoverHighlight")||(t.classList.add("ag-row-hover"),i.setHovered(!0))},mouseLeave:()=>{this.resetHoveredStatus(t)}})}resetHoveredStatus(e){for(let t of e?[e]:this.allRowGuis.map(e=>e.element))t.classList.remove("ag-row-hover");this.rowNode.setHovered(!1)}roundRowTopToBounds(e){let t=this.beans.ctrlsSvc.getScrollFeature().getApproximateVScollPosition();return Math.min(Math.max(this.applyPaginationOffset(t.top,!0)-100,e),this.applyPaginationOffset(t.bottom,!0)+100)}forEachGui(e,t){if(e)t(e);else for(let e of this.allRowGuis)t(e)}isRowRendered(){return this.allRowGuis.length>0}onRowHeightChanged(e){if(null==this.rowNode.rowHeight)return;let t=this.rowNode.rowHeight,n=this.beans.environment.getDefaultRowHeight(),i=au(this.gos)?ac(this.beans,this.rowNode).height:void 0,r=i?`${Math.min(n,i)-2}px`:void 0;this.forEachGui(e,e=>{e.element.style.height=`${t}px`,r&&e.element.style.setProperty("--ag-line-height",r)})}destroyFirstPass(e=!1){this.active=!1;let{rowNode:t}=this;if(!e&&am(this.gos)&&!t.sticky)if(null!=t.rowTop){let e=this.roundRowTopToBounds(t.rowTop);this.setRowTop(e)}else for(let e of this.allRowGuis)e.rowComp.toggleCss("ag-opacity-zero",!0);this.fullWidthGui?.element.contains(rA(this.beans))&&this.beans.focusSvc.attemptToRecoverFocus(),t.setHovered(!1);let n=this.createRowEvent("virtualRowRemoved");this.dispatchLocalEvent(n),this.beans.eventSvc.dispatchEvent(n),super.destroy()}destroySecondPass(){this.allRowGuis.length=0;let e=e=>{for(let t of e.list)t.destroy();return{list:[],map:{}}};this.centerCellCtrls=e(this.centerCellCtrls),this.leftCellCtrls=e(this.leftCellCtrls),this.rightCellCtrls=e(this.rightCellCtrls)}setFocusedClasses(e){this.forEachGui(e,e=>{e.rowComp.toggleCss("ag-row-focus",this.rowFocused),e.rowComp.toggleCss("ag-row-no-focus",!this.rowFocused)})}onCellFocusChanged(){let{focusSvc:e}=this.beans,t=e.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned);
377t!==this.rowFocused&&(this.rowFocused=t,this.setFocusedClasses())}onPaginationChanged(){let e=this.beans.pagination?.getCurrentPage()??0;this.paginationPage!==e&&(this.paginationPage=e,this.onTopChanged()),this.refreshFirstAndLastRowStyles()}onTopChanged(){this.setRowTop(this.rowNode.rowTop)}onPaginationPixelOffsetChanged(){this.onTopChanged()}applyPaginationOffset(e,t=!1){return this.rowNode.isRowPinned()||this.rowNode.sticky?e:e+this.beans.pageBounds.getPixelOffset()*(t?1:-1)}setRowTop(e){if(!this.printLayout&&rC(e)){let t=this.applyPaginationOffset(e),n=this.rowNode.isRowPinned()||this.rowNode.sticky?t:this.beans.rowContainerHeight.getRealPixelPosition(t),i=`${n}px`;this.setRowTopStyle(i)}}getInitialRowTop(e){return this.suppressRowTransform?this.getInitialRowTopShared(e):void 0}getInitialTransform(e){return this.suppressRowTransform?void 0:`translateY(${this.getInitialRowTopShared(e)})`}getInitialRowTopShared(e){let t;if(this.printLayout)return"";let n=this.rowNode;if(n.sticky)t=n.stickyRowTop;else{let i=this.slideInAnimation[e]?this.roundRowTopToBounds(n.oldRowTop):n.rowTop,r=this.applyPaginationOffset(i);t=n.isRowPinned()?r:this.beans.rowContainerHeight.getRealPixelPosition(r)}return t+"px"}setRowTopStyle(e){for(let t of this.allRowGuis)this.suppressRowTransform?t.rowComp.setTop(e):t.rowComp.setTransform(`translateY(${e})`)}getCellCtrl(e,t=!1){let n=null;for(let t of this.getAllCellCtrls())t.column==e&&(n=t);if(null!=n||t)return n;for(let t of this.getAllCellCtrls())t?.getColSpanningList().indexOf(e)>=0&&(n=t);return n}onRowIndexChanged(){null!=this.rowNode.rowIndex&&(this.onCellFocusChanged(),this.updateRowIndexes(),this.postProcessCss())}updateRowIndexes(e){let t=this.rowNode.getRowIndexString();if(null===t)return;let n=(this.beans.ctrlsSvc.getHeaderRowContainerCtrl()?.getRowCount()??0)+(this.beans.filterManager?.getHeaderRowCount()??0),i=this.rowNode.rowIndex%2==0,r=n+this.rowNode.rowIndex+1;this.forEachGui(e,e=>{e.rowComp.setRowIndex(t),e.rowComp.toggleCss("ag-row-even",i),e.rowComp.toggleCss("ag-row-odd",!i),rW(e.element,r)})}},fu=class extends oI{constructor(){super(),this.beanName="navigation",this.onPageDown=oN(this.onPageDown,100),this.onPageUp=oN(this.onPageUp,100)}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl})}handlePageScrollingKey(e,t=!1){var n,i;let r=e.key,o=e.altKey,a=e.ctrlKey||e.metaKey,s=!!this.beans.rangeSvc&&e.shiftKey,l=(n=this.gos,i=e,ux(n,i.target,uw)?.getFocusedCellPosition()??null),d=!1;switch(r){case s8:case"End":a||o||(this.onHomeOrEndKey(r),d=!0);break;case s0:case s2:case s1:case s3:if(!l)return!1;!a||o||s||(this.onCtrlUpDownLeftRight(r,l),d=!0);break;case s6:case s4:a||o||(d=this.handlePageUpDown(r,l,t))}return d&&e.preventDefault(),d}handlePageUpDown(e,t,n){return n&&(t=this.beans.focusSvc.getFocusedCell()),!!t&&(e===s4?this.onPageUp(t):this.onPageDown(t),!0)}navigateTo({scrollIndex:e,scrollType:t,scrollColumn:n,focusIndex:i,focusColumn:r,isAsync:o,rowPinned:a}){let{scrollFeature:s}=this.gridBodyCon;rC(n)&&!n.isPinned()&&s.ensureColumnVisible(n),rC(e)&&s.ensureIndexVisible(e,t),o||s.ensureIndexVisible(i);let{focusSvc:l,rangeSvc:d}=this.beans;l.setFocusedCell({rowIndex:i,column:r,rowPinned:a,forceBrowserFocus:!0}),d?.setRangeToCell({rowIndex:i,rowPinned:a,column:r})}onPageDown(e){let t=this.beans,n=fc(t),i=this.getViewportHeight(),{pageBounds:r,rowModel:o,rowAutoHeight:a}=t,s=r.getPixelOffset(),l=n.top+i,d=o.getRowIndexAtPixel(l+s);a?.active?this.navigateToNextPageWithAutoHeight(e,d):this.navigateToNextPage(e,d)}onPageUp(e){let t=this.beans,n=fc(t),{pageBounds:i,rowModel:r,rowAutoHeight:o}=t,a=i.getPixelOffset(),s=n.top,l=r.getRowIndexAtPixel(s+a);o?.active?this.navigateToNextPageWithAutoHeight(e,l,!0):this.navigateToNextPage(e,l,!0)}navigateToNextPage(e,t,n=!1){let i,{pageBounds:r,rowModel:o}=this.beans,a=this.getViewportHeight(),s=r.getFirstRow(),l=r.getLastRow(),d=r.getPixelOffset(),u=o.getRow(e.rowIndex),c=n?u?.rowHeight-a-d:a-d,h=u?.rowTop+c,p=o.getRowIndexAtPixel(h+d);p===e.rowIndex&&(t=p=e.rowIndex+(n?-1:1)),n?(i="bottom",p<s&&(p=s),t<s&&(t=s)):(i="top",p>l&&(p=l),t>
377l&&(t=l)),this.isRowTallerThanView(o.getRow(p))&&(t=p,i="top"),this.navigateTo({scrollIndex:t,scrollType:i,scrollColumn:null,focusIndex:p,focusColumn:e.column})}navigateToNextPageWithAutoHeight(e,t,n=!1){this.navigateTo({scrollIndex:t,scrollType:n?"bottom":"top",scrollColumn:null,focusIndex:t,focusColumn:e.column}),setTimeout(()=>{let i=this.getNextFocusIndexForAutoHeight(e,n);this.navigateTo({scrollIndex:t,scrollType:n?"bottom":"top",scrollColumn:null,focusIndex:i,focusColumn:e.column,isAsync:!0})},50)}getNextFocusIndexForAutoHeight(e,t=!1){let n=t?-1:1,i=this.getViewportHeight(),{pageBounds:r,rowModel:o}=this.beans,a=r.getLastRow(),s=0,l=e.rowIndex;for(;l>=0&&l<=a;){let e=o.getRow(l);if(e){let t=e.rowHeight??0;if(s+t>i)break;s+=t}l+=n}return Math.max(0,Math.min(l,a))}getViewportHeight(){let e=this.beans,t=fc(e),n=this.beans.scrollVisibleSvc.getScrollbarWidth(),i=t.bottom-t.top;return e.ctrlsSvc.get("center").isHorizontalScrollShowing()&&(i-=n),i}isRowTallerThanView(e){if(!e)return!1;let t=e.rowHeight;return"number"==typeof t&&t>this.getViewportHeight()}onCtrlUpDownLeftRight(e,t){let n=this.beans.cellNavigation.getNextCellToFocus(e,t,!0),{rowIndex:i,rowPinned:r,column:o}=this.getNormalisedPosition(n)??n;this.navigateTo({scrollIndex:i,scrollType:null,scrollColumn:o,focusIndex:i,focusColumn:o,rowPinned:r})}onHomeOrEndKey(e){let t=e===s8,{visibleCols:n,pageBounds:i,rowModel:r}=this.beans,o=n.allCols,a=t?i.getFirstRow():i.getLastRow(),s=r.getRow(a);if(!s)return;let l=(t?o:[...o].reverse()).find(e=>!e.isSuppressNavigable(s));l&&this.navigateTo({scrollIndex:a,scrollType:null,scrollColumn:l,focusIndex:a,focusColumn:l})}onTabKeyDown(e,t){let n=t.shiftKey,i=this.tabToNextCellCommon(e,n,t),r=this.beans,{ctrlsSvc:o,pageBounds:a,focusSvc:s,gos:l}=r;if(!1!==i)return void(i?t.preventDefault():null===i&&o.get("gridCtrl").allowFocusForNextCoreContainer(n));if(n){let{rowIndex:n,rowPinned:i}=e.getRowPosition();(i?0===n:n===a.getFirstRow())&&(0===l.get("headerHeight")||u0(r)?u2(r,!0,!0):(t.preventDefault(),s.focusPreviousFromFirstCell(t)))}else e instanceof fr&&e.focusCell(!0),(s.focusOverlay(!1)||u2(r,n))&&t.preventDefault()}tabToNextCell(e,t){let n=this.beans,{focusSvc:i,rowRenderer:r}=n,o=i.getFocusedCell();if(!o)return!1;let a=c4(n,o);return(!!a||(a=r.getRowByPosition(o),!!a?.isFullWidth()))&&!!this.tabToNextCellCommon(a,e,t,"api")}tabToNextCellCommon(e,t,n,i="ui"){let r,{editSvc:o,focusSvc:a}=this.beans,s=e instanceof fr?e:e.getAllCellCtrls()?.[0];return null===(r=o?.isEditing()?o?.moveToNextCell(s,t,n,i):this.moveToNextCellNotEditing(e,t,n))?r:r||!!a.focusedHeader}moveToNextCellNotEditing(e,t,n){let i,r=this.beans.visibleCols.allCols;if(e instanceof fd){if(i={...e.getRowPosition(),column:t?r[0]:aY(r)},this.gos.get("embedFullWidthRows")&&n){let t=e.findFullWidthInfoForEvent(n);t&&(i.column=t.column)}}else i=e.getFocusedCellPosition();let o=this.findNextCellToFocusOn(i,{backwards:t,startEditing:!1});if(!1===o)return null;if(o instanceof fr)o.focusCell(!0);else if(o)return this.tryToFocusFullWidthRow(o,t);return rC(o)}findNextCellToFocusOn(e,{backwards:t,startEditing:n,skipToNextEditableCell:i}){let r=e,o=this.beans,{cellNavigation:a,gos:s,focusSvc:l,rowRenderer:d,rangeSvc:u}=o;for(;;){e!==r&&(e=r),t||(r=this.getLastCellOfColSpan(r)),r=a.getNextTabbedCell(r,t);let c=s.getCallback("tabToNextCell");if(rC(c)){let i=c({backwards:t,editing:n,previousCellPosition:e,nextCellPosition:r||null});if(!0===i)r=e;else{if(!1===i)return!1;r={rowIndex:i.rowIndex,column:i.column,rowPinned:i.rowPinned}}}if(!r)return null;if(r.rowIndex<0){let e=u3(o);return l.focusHeaderPosition({headerPosition:{headerRowIndex:e+r.rowIndex,column:r.column},fromCell:!0}),null}let h="fullRow"===s.get("editType");if(n&&(!h||i)&&!this.isCellEditable(r))continue;this.ensureCellVisible(r);let p=c4(o,r);if(!p){let e=d.getRowByPosition(r);if(!e||!e.isFullWidth()||n)continue;return{...e.getRowPosition(),column:r?.column}}if(!a.isSuppressNavigable(p.column,p.rowNode))return p.setFocusedCellPosition(r),u?.setRangeToCell(r),p}}isCellEditable(e){let t=this.lookupRowNodeForCell(e);return!!t&&e.column.isCellEditable(t)}lookupRowNodeForCell({rowIndex:e,rowPinned:t}){let{pinnedRowModel:n,rowModel:i}=this.beans;return"top"===t?n?.getPinnedTopRow(e):"bottom"===t?n?.getPinnedBottomRow(e):i.getRow(e)}navigateToNextCell(e,t,n,i){let r=n,o=!1,a=this.beans,{cellNavigation:s,focusSvc:l,gos:d}=a;for(;r&&(r===n||!this.isValidNavigateCell(r));)d.get("enableRtl")?t===s0&&(r=this.getLastCellOfColSpan(r)):t===s2&&(r=this.getLastCellOfColSpan(r)),o=rS(r=s.getNextCellToFocus(t,r));if(o&&e&&e.key===s1&&(r={rowIndex:-1,rowPinned:null,column:n.column}),i){let i=d.getCallback("navigateToNextCell");if(rC(i)){let o=i({key:t,previousCellPosition:n,nextCellPosition:r||null,event:e});r=rC(o)?{rowPinned:o.rowPinned,rowIndex:o.rowIndex,column:o.column}:null}}if(!r)return;if(r.rowIndex<0){let t=u3(a);l.focusHeaderPosition({headerPosition:{headerRowIndex:t+r.rowIndex,column:n.column},event:e||void 0,fromCell:!0});return}let u=this.getNormalisedPosition(r);u?this.focusPosition(u):this.tryToFocusFullWidthRow(r)}
377getNormalisedPosition(e){if(this.beans.spannedRowRenderer?.getCellByPosition(e))return e;this.ensureCellVisible(e);let t=c4(this.beans,e);return t?(e=t.getFocusedCellPosition(),this.ensureCellVisible(e),e):null}tryToFocusFullWidthRow(e,t){let{visibleCols:n,rowRenderer:i,focusSvc:r,eventSvc:o}=this.beans,a=n.allCols,s=i.getRowByPosition(e);if(!s?.isFullWidth())return!1;let l=r.getFocusedCell(),d={rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:e.column||(t?aY(a):a[0])};this.focusPosition(d);let u=null==t?null!=l&&function(e,t){switch(e.rowPinned){case"top":if("top"!==t.rowPinned)return!0;break;case"bottom":if("bottom"!==t.rowPinned)return!1;break;default:if(rC(t.rowPinned))return"top"!==t.rowPinned}return e.rowIndex<t.rowIndex}(d,l):t;return o.dispatchEvent({type:"fullWidthRowFocused",rowIndex:d.rowIndex,rowPinned:d.rowPinned,column:d.column,isFullWidthCell:!0,fromBelow:u}),!0}focusPosition(e){let{focusSvc:t,rangeSvc:n}=this.beans;t.setFocusedCell({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0}),n?.setRangeToCell(e)}isValidNavigateCell(e){return!!c5(this.beans,e)}getLastCellOfColSpan(e){let t=c4(this.beans,e);if(!t)return e;let n=t.getColSpanningList();return 1===n.length?e:{rowIndex:e.rowIndex,column:aY(n),rowPinned:e.rowPinned}}ensureCellVisible(e){let t=av(this.gos),n=this.beans.rowModel.getRow(e.rowIndex),i=t&&n?.sticky,{scrollFeature:r}=this.gridBodyCon;!i&&rS(e.rowPinned)&&r.ensureIndexVisible(e.rowIndex),e.column.isPinned()||r.ensureColumnVisible(e.column)}ensureColumnVisible(e){let t=this.gridBodyCon.scrollFeature;e.isPinned()||t.ensureColumnVisible(e)}ensureRowVisible(e){this.gridBodyCon.scrollFeature.ensureIndexVisible(e)}};function fc(e){return e.ctrlsSvc.getScrollFeature().getVScrollPosition()}var fh=class extends oI{constructor(){super(...arguments),this.beanName="pageBoundsListener"}postConstruct(){this.addManagedEventListeners({modelUpdated:this.onModelUpdated.bind(this),recalculateRowBounds:this.calculatePages.bind(this)}),this.onModelUpdated()}onModelUpdated(e){this.calculatePages(),this.eventSvc.dispatchEvent({type:"paginationChanged",animate:e?.animate??!1,newData:e?.newData??!1,newPage:e?.newPage??!1,newPageSize:e?.newPageSize??!1,keepRenderedRows:e?.keepRenderedRows??!1})}calculatePages(){let{pageBounds:e,pagination:t,rowModel:n}=this.beans;t?t.calculatePages():e.calculateBounds(0,n.getRowCount()-1)}},fp=class extends oI{constructor(){super(...arguments),this.beanName="pageBounds",this.pixelOffset=0}getFirstRow(){return this.topRowBounds?.rowIndex??-1}getLastRow(){return this.bottomRowBounds?.rowIndex??-1}getCurrentPageHeight(){let{topRowBounds:e,bottomRowBounds:t}=this;return e&&t?Math.max(t.rowTop+t.rowHeight-e.rowTop,0):0}getCurrentPagePixelRange(){let{topRowBounds:e,bottomRowBounds:t}=this;return{pageFirstPixel:e?.rowTop??0,pageLastPixel:t?t.rowTop+t.rowHeight:0}}calculateBounds(e,t){let{rowModel:n}=this.beans,i=n.getRowBounds(e);i&&(i.rowIndex=e),this.topRowBounds=i;let r=n.getRowBounds(t);r&&(r.rowIndex=t),this.bottomRowBounds=r,this.calculatePixelOffset()}getPixelOffset(){return this.pixelOffset}calculatePixelOffset(){let e=this.topRowBounds?.rowTop??0;this.pixelOffset!==e&&(this.pixelOffset=e,this.eventSvc.dispatchEvent({type:"paginationPixelOffsetChanged"}))}},ff=class extends oI{constructor(e,t){super(),this.isLeft=e,this.elements=t,this.getWidth=e?()=>this.beans.pinnedCols.leftWidth:()=>this.beans.pinnedCols.rightWidth}postConstruct(){this.addManagedEventListeners({[`${this.isLeft?"left":"right"}PinnedWidthChanged`]:this.onPinnedWidthChanged.bind(this)})}onPinnedWidthChanged(){let e=this.getWidth(),t=e>0;for(let n of this.elements)n&&(rZ(n,t),oa(n,e))}},fg=class extends oI{constructor(){super(...arguments),this.beanName="pinnedCols"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl});let e=this.checkContainerWidths.bind(this);this.addManagedEventListeners({displayedColumnsChanged:e,displayedColumnsWidthChanged:e}),this.addManagedPropertyListener("domLayout",e)}checkContainerWidths(){let{gos:e,visibleCols:t,eventSvc:n}=this.beans,i=al(e,"print"),r=i?0:t.getColsLeftWidth(),o=i?0:t.getDisplayedColumnsRightWidth();r!=this.leftWidth&&(this.leftWidth=r,n.dispatchEvent({type:"leftPinnedWidthChanged"})),o!=this.rightWidth&&(this.rightWidth=o,n.dispatchEvent({type:"rightPinnedWidthChanged"}))}keepPinnedColumnsNarrowerThanViewport(){let e=r1(this.gridBodyCtrl.eBodyViewport);if(e<=50)return;let t=this.getPinnedColumnsOverflowingViewport(e-50),n=this.gos.getCallback("processUnpinnedColumns"),{columns:i,hasLockedPinned:r}=t,o=i;(o.length||r)&&(n&&(o=n({columns:o,viewportWidth:e})),o?.length&&(o=o.filter(e=>!a7(e)),this.setColsPinned(o,null,"viewportSizeFeature")))}createPinnedWidthFeature(e,...t){return new ff(e,t)}setColsPinned(e,t,n){let i,{colModel:r,colAnimation:o,visibleCols:a,gos:s}=this.beans;if(!r.cols||!e?.length)return;if(al(s,"print"))return void at(37);o?.start(),i=!0===t||"left"===t?"left":"right"===t?"right":null;let l=[];for(let t of e){if(!t)continue;let e=r.getCol(t);e&&e.getPinned()!==i&&(this.setColPinned(e,i),l.push(e))}l.length&&(a.refresh(n),su(this.eventSvc,l,n)),o?.finish()}initCol(e){let{pinned:t,initialPinned:n}=e.colDef;void 0!==t?this.setColPinned(e,t):this.setColPinned(e,n)}setColPinned(e,t){!0===t||"left"===t?e.pinned="left":"right"===t?e.pinned="right":e.pinned=null,e.dispatchStateUpdatedEvent("pinned")}setupHeaderPinnedWidth(e){let{scrollVisibleSvc:t}=this.beans;if(null==e.pinned)return;let n="left"===e.pinned,i="right"===e.pinned;e.hidden=!0;let r=()=>{let r=n?this.leftWidth:this.rightWidth;if(null==r)return;let o=0==r,a=e.hidden!==o,s=this.gos.get("enableRtl"),l=t.getScrollbarWidth(),d=t.verticalScrollShowing&&(s&&n||!s&&i);e.comp.setPinnedContainerWidth(`${d?r+l:r}px`),e.comp.setDisplayed(!o),a&&(e.hidden=o,e.refresh())};e.addManagedEventListeners({leftPinnedWidthChanged:r,rightPinnedWidthChanged:r,scrollVisibilityChanged:r,scrollbarWidthChanged:r})}
377getHeaderResizeDiff(e,t){if(t.getPinned()){let{leftWidth:t,rightWidth:n}=this,i=r1(this.beans.ctrlsSvc.getGridBodyCtrl().eBodyViewport)-50;if(t+n+e>i)if(!(i>t+n))return 0;else e=i-t-n}return e}getPinnedColumnsOverflowingViewport(e){let t=(this.rightWidth??0)+(this.leftWidth??0),n=!1;if(t<e)return{columns:[],hasLockedPinned:n};let{visibleCols:i}=this.beans,r=[...i.leftCols],o=[...i.rightCols],a=0,s=0,l=[],d=t-0-e;for(;(s<r.length||a<o.length)&&d>0;){if(a<o.length){let e=o[a++];if(e.colDef.lockPinned){n=!0;continue}d-=e.getActualWidth(),l.push(e)}if(s<r.length&&d>0){let e=r[s++];if(e.colDef.lockPinned){n=!0;continue}d-=e.getActualWidth(),l.push(e)}}return{columns:l,hasLockedPinned:n}}},fm=class extends oI{constructor(){super(),this.beanName="ariaAnnounce",this.descriptionContainer=null,this.pendingAnnouncements=new Map,this.lastAnnouncement="",this.updateAnnouncement=oO(this,this.updateAnnouncement.bind(this),200)}postConstruct(){let e=this.beans,t=rP(e),n=this.descriptionContainer=t.createElement("div");n.classList.add("ag-aria-description-container"),rO(n,"live","polite"),rO(n,"relevant","additions text"),rO(n,"atomic",!0),e.eGridDiv.appendChild(n)}announceValue(e,t){this.pendingAnnouncements.set(t,e),this.updateAnnouncement()}updateAnnouncement(){if(!this.descriptionContainer)return;let e=Array.from(this.pendingAnnouncements.values()).join(". ");this.pendingAnnouncements.clear(),this.descriptionContainer.textContent="",setTimeout(()=>{this.handleAnnouncementUpdate(e)},50)}handleAnnouncementUpdate(e){if(!this.isAlive()||!this.descriptionContainer)return;let t=e;if(null==t||""==t.replace(/[ .]/g,"")){this.lastAnnouncement="";return}this.lastAnnouncement===t&&(t=`${t}\u200B`),this.lastAnnouncement=t,this.descriptionContainer.textContent=t}destroy(){super.destroy();let{descriptionContainer:e}=this;e&&(r8(e),e.remove()),this.descriptionContainer=null,this.pendingAnnouncements.clear()}},fv="ag-delay-render",fy=class extends oI{constructor(){super(...arguments),this.beanName="colDelayRenderSvc",this.hideRequested=!1,this.alreadyRevealed=!1,this.timesRetried=0,this.requesters=new Set}hideColumns(e){!(this.alreadyRevealed||this.requesters.has(e))&&(this.requesters.add(e),this.hideRequested||(this.beans.ctrlsSvc.whenReady(this,e=>{e.gridBodyCtrl.eGridBody.classList.add(fv)}),this.hideRequested=!0))}revealColumns(e){if(this.alreadyRevealed||!this.isAlive()||(this.requesters.delete(e),this.requesters.size>0))return;let{renderStatus:t,ctrlsSvc:n}=this.beans;if(t){if(!t.areHeaderCellsRendered()&&this.timesRetried<5){this.timesRetried++,setTimeout(()=>this.revealColumns(e));return}this.timesRetried=0}n.getGridBodyCtrl().eGridBody.classList.remove(fv),this.alreadyRevealed=!0}},fb={tag:"div",cls:"ag-overlay",role:"presentation",children:[{tag:"div",cls:"ag-overlay-panel",role:"presentation",children:[{tag:"div",ref:"eOverlayWrapper",cls:"ag-overlay-wrapper",role:"presentation"}]}]},fx=class extends sk{constructor(){super(fb),this.eOverlayWrapper=null,this.activePromise=null,this.activeOverlay=null,this.updateListenerDestroyFunc=null,this.activeCssClass=null,this.elToFocusAfter=null,this.registerCSS(".ag-overlay{inset:0;pointer-events:none;position:absolute;z-index:2}.ag-overlay-panel,.ag-overlay-wrapper{display:flex;height:100%;width:100%}.ag-overlay-wrapper{align-items:center;flex:none;justify-content:center;text-align:center}.ag-overlay-loading-wrapper{pointer-events:all}.ag-overlay-loading-center{background:var(--ag-background-color);border:solid var(--ag-border-width) var(--ag-border-color);border-radius:var(--ag-border-radius);box-shadow:var(--ag-popup-shadow);padding:var(--ag-spacing)}")}handleKeyDown(e){if("Tab"!==e.key||e.defaultPrevented||ua(e))return;let t=this.beans;if(!lk(t,this.eOverlayWrapper,!1,e.shiftKey))(e.shiftKey?t.focusSvc.focusGridView({column:aY(t.visibleCols.allCols),backwards:!0,canFocusOverlay:!1}):u2(t,!1))&&e.preventDefault()}updateLayoutClasses(e,t){let n=this.eOverlayWrapper.classList,{AUTO_HEIGHT:i,NORMAL:r,PRINT:o}=uu;n.toggle(i,t.autoHeight),n.toggle(r,t.normal),n.toggle(o,t.print)}postConstruct(){this.createManagedBean(new uc(this)),this.setDisplayed(!1,{skipAriaHidden:!0}),this.beans.overlays.setOverlayWrapperComp(this),this.addManagedElementListeners(this.getFocusableElement(),{keydown:this.handleKeyDown.bind(this)})}setWrapperTypeClass(e){let t=this.eOverlayWrapper.classList;this.activeCssClass&&t.toggle(this.activeCssClass,!1),this.activeCssClass=e,t.toggle(e,!0)}showOverlay(e,t,n,i){if(this.setWrapperTypeClass(t),this.destroyActiveOverlay(),this.elToFocusAfter=null,this.activePromise=e,e){if(this.setDisplayed(!0,{skipAriaHidden:!0}),n&&this.isGridFocused()){let e=rA(this.beans);e&&!rE(this.beans)&&(this.elToFocusAfter=e)}e.then(t=>{if(this.activePromise!==e){this.activeOverlay!==t&&(this.destroyBean(t),t=null);return}if(this.activePromise=null,t){if(this.activeOverlay!==t&&(this.eOverlayWrapper.appendChild(t.getGui()),this.activeOverlay=t,i)){let e=t;this.updateListenerDestroyFunc=this.addManagedPropertyListener(i,({currentValue:t})=>{e.refresh?.(aN(this.gos,{...t??{}}))})}n&&this.isGridFocused()&&l_(this.eOverlayWrapper)}})}}updateOverlayWrapperPaddingTop(e){this.eOverlayWrapper.style.setProperty("padding-top",`${e}px`)}destroyActiveOverlay(){this.activePromise=null;let e=this.activeOverlay;if(!e)return;let t=this.elToFocusAfter;this.activeOverlay=null,this.elToFocusAfter=null,t&&!this.isGridFocused()&&(t=null);let n=this.updateListenerDestroyFunc;n&&(n(),this.updateListenerDestroyFunc=null),this.destroyBean(e),r8(this.eOverlayWrapper),t?.focus?.({preventScroll:!0})}hideOverlay(){this.destroyActiveOverlay(),this.setDisplayed(!1,{skipAriaHidden:!0})}
377isGridFocused(){let e=rA(this.beans);return!!e&&this.beans.eGridDiv.contains(e)}destroy(){this.elToFocusAfter=null,this.destroyActiveOverlay(),this.beans.overlays.setOverlayWrapperComp(void 0),super.destroy()}},fw={selector:"AG-OVERLAY-WRAPPER",component:fx},fC=class extends oI{constructor(){super(...arguments),this.beanName="overlays",this.state=0,this.showInitialOverlay=!0,this.wrapperPadding=0}postConstruct(){this.isClientSide=aa(this.gos),this.isServerSide=!this.isClientSide&&as(this.gos);let e=()=>this.updateOverlayVisibility();this.addManagedEventListeners({newColumnsLoaded:e,rowDataUpdated:e,gridSizeChanged:this.refreshWrapperPadding.bind(this),rowCountReady:()=>{this.showInitialOverlay=!1,this.updateOverlayVisibility()}}),this.addManagedPropertyListener("loading",e)}setOverlayWrapperComp(e){this.eWrapper=e,this.updateOverlayVisibility()}isVisible(){return 0!==this.state&&!!this.eWrapper}isExclusive(){return 1===this.state&&!!this.eWrapper}showLoadingOverlay(){this.showInitialOverlay=!1;let e=this.gos,t=e.get("loading");!t&&(void 0!==t||e.get("suppressLoadingOverlay"))||this.doShowLoadingOverlay()}showNoRowsOverlay(){this.showInitialOverlay=!1;let e=this.gos;e.get("loading")||e.get("suppressNoRowsOverlay")||this.doShowNoRowsOverlay()}hideOverlay(){(this.showInitialOverlay=!1,this.gos.get("loading"))?at(99):this.doHideOverlay()}getOverlayWrapperSelector(){return fw}getOverlayWrapperCompClass(){return fx}updateOverlayVisibility(){if(!this.eWrapper){this.state=0;return}let{state:e,isClientSide:t,isServerSide:n,beans:{gos:i,colModel:r,rowModel:o}}=this,a=this.gos.get("loading");void 0!==a&&(this.showInitialOverlay=!1),this.showInitialOverlay&&void 0===a&&!i.get("suppressLoadingOverlay")&&(a=!i.get("columnDefs")||!r.ready||!i.get("rowData")&&t),a?1!==e&&this.doShowLoadingOverlay():(this.showInitialOverlay=!1,t&&o.isEmpty()&&!i.get("suppressNoRowsOverlay")?2!==e&&this.doShowNoRowsOverlay():1!==e&&(n||0===e)||this.doHideOverlay())}doShowLoadingOverlay(){if(this.eWrapper){var e,t;this.state=1,this.showOverlay((e=this.beans.userCompFactory,t=aN(this.gos,{}),e.getCompDetailsFromGridOptions(sz,"agLoadingOverlay",t,!0)),"ag-overlay-loading-wrapper","loadingOverlayComponentParams"),this.updateExclusive()}}doShowNoRowsOverlay(){if(this.eWrapper){var e,t;this.state=2,this.showOverlay((e=this.beans.userCompFactory,t=aN(this.gos,{}),e.getCompDetailsFromGridOptions(sj,"agNoRowsOverlay",t,!0)),"ag-overlay-no-rows-wrapper","noRowsOverlayComponentParams"),this.updateExclusive()}}doHideOverlay(){this.eWrapper&&(this.state=0,this.eWrapper.hideOverlay(),this.updateExclusive())}showOverlay(e,t,n){let i=e?.newAgStackInstance()??null;this.eWrapper?.showOverlay(i,t,this.isExclusive(),n),this.refreshWrapperPadding()}updateExclusive(){let e=this.exclusive;this.exclusive=this.isExclusive(),this.exclusive!==e&&this.eventSvc.dispatchEvent({type:"overlayExclusiveChanged"})}refreshWrapperPadding(){let e=this.eWrapper;if(!e)return;let t=0;if(2===this.state){let e=this.beans.ctrlsSvc.get("gridHeaderCtrl");t=e?.headerHeight||0}this.wrapperPadding!==t&&(this.wrapperPadding=t,e.updateOverlayWrapperPaddingTop(t))}},fS=class extends oI{constructor(){super(...arguments),this.beanName="rowContainerHeight",this.scrollY=0,this.uiBodyHeight=0}postConstruct(){this.addManagedEventListeners({bodyHeightChanged:this.updateOffset.bind(this)}),this.maxDivHeight=function(){if(void 0!==_)return _;if(!document.body)return -1;let e=1e6,t=lo()?6e6:1e9,n=document.createElement("div");for(document.body.appendChild(n);;){let i=2*e;if(n.style.height=i+"px",i>t||n.clientHeight!==i)break;e=i}return n.remove(),_=e,e}(),o$(this.gos,"RowContainerHeightService - maxDivHeight = "+this.maxDivHeight)}updateOffset(){if(!this.stretching)return;let e=this.beans.ctrlsSvc.getScrollFeature().getVScrollPosition().top,t=this.getUiBodyHeight();(e!==this.scrollY||t!==this.uiBodyHeight)&&(this.scrollY=e,this.uiBodyHeight=t,this.calculateOffset())}calculateOffset(){this.setUiContainerHeight(this.maxDivHeight),this.pixelsToShave=this.modelHeight-this.uiContainerHeight,this.maxScrollY=this.uiContainerHeight-this.uiBodyHeight;let e=this.scrollY/this.maxScrollY,t=e*this.pixelsToShave;o$(this.gos,`RowContainerHeightService - Div Stretch Offset = ${t} (${this.pixelsToShave} * ${e})`),this.setDivStretchOffset(t)}setUiContainerHeight(e){e!==this.uiContainerHeight&&(this.uiContainerHeight=e,this.eventSvc.dispatchEvent({type:"rowContainerHeight
377Changed"}))}clearOffset(){this.setUiContainerHeight(this.modelHeight),this.pixelsToShave=0,this.setDivStretchOffset(0)}setDivStretchOffset(e){let t="number"==typeof e?Math.floor(e):null;this.divStretchOffset!==t&&(this.divStretchOffset=t,this.eventSvc.dispatchEvent({type:"heightScaleChanged"}))}setModelHeight(e){this.modelHeight=e,this.stretching=null!=e&&this.maxDivHeight>0&&e>this.maxDivHeight,this.stretching?this.calculateOffset():this.clearOffset()}getRealPixelPosition(e){return e-this.divStretchOffset}getUiBodyHeight(){let e=this.beans.ctrlsSvc.getScrollFeature().getVScrollPosition();return e.bottom-e.top}getScrollPositionForPixel(e){if(this.pixelsToShave<=0)return e;let t=this.modelHeight-this.getUiBodyHeight();return this.maxScrollY*(e/t)}},f_=class extends oI{constructor(){super(...arguments),this.beanName="rowRenderer",this.destroyFuncsForColumnListeners=[],this.rowCtrlsByRowIndex={},this.zombieRowCtrls={},this.allRowCtrls=[],this.topRowCtrls=[],this.bottomRowCtrls=[],this.refreshInProgress=!1,this.dataFirstRenderedFired=!1,this.setupRangeSelectionListeners=()=>{let e=()=>{for(let e of this.getAllCellCtrls())e.onCellSelectionChanged()},t=()=>{for(let e of this.getAllCellCtrls())e.updateRangeBordersIfRangeCount()},n=()=>{this.eventSvc.addListener("cellSelectionChanged",e),this.eventSvc.addListener("columnMoved",t),this.eventSvc.addListener("columnPinned",t),this.eventSvc.addListener("columnVisible",t)},i=()=>{this.eventSvc.removeListener("cellSelectionChanged",e),this.eventSvc.removeListener("columnMoved",t),this.eventSvc.removeListener("columnPinned",t),this.eventSvc.removeListener("columnVisible",t)};this.addDestroyFunc(()=>i()),this.addManagedPropertyListeners(["enableRangeSelection","cellSelection"],()=>{aT(this.gos)?n():i()}),aT(this.gos)&&n()}}wireBeans(e){this.pageBounds=e.pageBounds,this.colModel=e.colModel,this.pinnedRowModel=e.pinnedRowModel,this.rowModel=e.rowModel,this.focusSvc=e.focusSvc,this.rowContainerHeight=e.rowContainerHeight,this.ctrlsSvc=e.ctrlsSvc,this.editSvc=e.editSvc}postConstruct(){this.ctrlsSvc.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.initialise()})}initialise(){this.addManagedEventListeners({paginationChanged:this.onPageLoaded.bind(this),pinnedRowDataChanged:this.onPinnedRowDataChanged.bind(this),pinnedRowsChanged:this.onPinnedRowsChanged.bind(this),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),bodyScroll:this.onBodyScroll.bind(this),bodyHeightChanged:this.redraw.bind(this,{})}),this.addManagedPropertyListeners(["domLayout","embedFullWidthRows"],()=>this.onDomLayoutChanged()),this.addManagedPropertyListeners(["suppressMaxRenderedRowRestriction","rowBuffer"],()=>this.redraw()),this.addManagedPropertyListener("suppressCellFocus",e=>this.onSuppressCellFocusChanged(e.currentValue)),this.addManagedPropertyListeners(["groupSuppressBlankHeader","getBusinessKeyForNode","fullWidthCellRenderer","fullWidthCellRendererParams","suppressStickyTotalRow","groupRowRenderer","groupRowRendererParams","loadingCellRenderer","loadingCellRendererParams","detailCellRenderer","detailCellRendererParams","enableRangeSelection","enableCellTextSelection"],()=>this.redrawRows()),this.addManagedPropertyListener("cellSelection",({currentValue:e,previousValue:t})=>{(!t&&e||t&&!e)&&this.redrawRows()});let{stickyRowSvc:e,gos:t,showRowGroupCols:n}=this.beans;if(n&&this.addManagedPropertyListener("showOpenedGroup",()=>{let e=n.getShowRowGroupCols();e.length&&this.refreshCells({columns:e,force:!0})}),e)this.stickyRowFeature=e.createStickyRowFeature(this,this.createRowCon.bind(this),this.destroyRowCtrls.bind(this));else{let e=this.gridBodyCtrl;e.setStickyTopHeight(0),e.setStickyBottomHeight(0)}this.registerCellEventListeners(),this.initialiseCache(),this.printLayout=al(t,"print"),this.embedFullWidthRows=this.printLayout||t.get("embedFullWidthRows"),this.redrawAfterModelUpdate()}initialiseCache(){if(this.gos.get("keepDetailRows")){let e=this.getKeepDetailRowsCount();this.cachedRowCtrls=new fk(null!=e?e:3)}}getKeepDetailRowsCount(){return this.gos.get("keepDetailRowsCount")}getStickyTopRowCtrls(){return this.stickyRowFeature?.stickyTopRowCtrls??[]}getStickyBottomRowCtrls(){return this.stickyRowFeature?.stickyBottomRowCtrls??[]}updateAllRowCtrls(){let e=Object.values(this.rowCtrlsByRowIndex),t=Object.values(this.zombieRowCtrls),n=this.cachedRowCtrls?.getEntries()??[];t.length>0||n.length>0?this.allRowCtrls=[...e,...t,...n]:this.allRowCtrls=e}isCellBeingRendered(e,t){let n=this.rowCtrlsByRowIndex[e];return t&&n?!!n.isFullWidth()||!!this.beans.spannedRowRenderer?.getCellByPosition({rowIndex:e,column:t,rowPinned:null})||!!n.getCellCtrl(t)||!n.isRowRendered():!!n}updateCellFocus(e){for(let t of this.getAllCellCtrls())t.onCellFocused(e);for(let t of this.getFullWidthRowCtrls())t.onFullWidthRowFocused(e)}onCellFocusChanged(e){if(e?.rowIndex!=null&&!e.rowPinned){let t=this.beans.colModel.getCol(e.column)??void 0;this.isCellBeingRendered(e.rowIndex,t)||this.redraw()}this.updateCellFocus(e)}onSuppressCellFocusChanged(e){for(let t of this.getAllCellCtrls())t.onSuppressCellFocusChanged(e);for(let t of this.getFullWidthRowCtrls())t.onSuppressCellFocusChanged(e)}registerCellEventListeners(){this.addManagedEventListeners({cellFocused:e=>this.onCellFocusChanged(e),cellFocusCleared:()=>this.updateCellFocus(),flashCells:e=>{let{cellFlashSvc:t}=this.beans;if(t)for(let n of this.getAllCellCtrls())t.onFlashCells(n,e)},columnHoverChanged:()=>{for(let e of this.getAllCellCtrls())e.onColumnHover()},displayedColumnsChanged:()=>{for(let e of this.getAllCellCtrls())e.onDisplayedColumnsChanged()},displayedColumnsWidthChanged:()=>
377{if(this.printLayout)for(let e of this.getAllCellCtrls())e.onLeftChanged()}}),this.setupRangeSelectionListeners(),this.refreshListenersToColumnsForCellComps(),this.addManagedEventListeners({gridColumnsChanged:this.refreshListenersToColumnsForCellComps.bind(this)}),this.addDestroyFunc(this.removeGridColumnListeners.bind(this))}removeGridColumnListeners(){for(let e of this.destroyFuncsForColumnListeners)e();this.destroyFuncsForColumnListeners.length=0}refreshListenersToColumnsForCellComps(){for(let e of(this.removeGridColumnListeners(),this.colModel.getCols())){let t=t=>{for(let n of this.getAllCellCtrls())n.column===e&&t(n)},n=()=>{t(e=>e.onLeftChanged())},i=()=>{t(e=>e.onWidthChanged())},r=()=>{t(e=>e.onFirstRightPinnedChanged())},o=()=>{t(e=>e.onLastLeftPinnedChanged())},a=()=>{t(e=>e.onColDefChanged())};e.__addEventListener("leftChanged",n),e.__addEventListener("widthChanged",i),e.__addEventListener("firstRightPinnedChanged",r),e.__addEventListener("lastLeftPinnedChanged",o),e.__addEventListener("colDefChanged",a),this.destroyFuncsForColumnListeners.push(()=>{e.__removeEventListener("leftChanged",n),e.__removeEventListener("widthChanged",i),e.__removeEventListener("firstRightPinnedChanged",r),e.__removeEventListener("lastLeftPinnedChanged",o),e.__removeEventListener("colDefChanged",a)})}}onDomLayoutChanged(){let e=al(this.gos,"print"),t=e||this.gos.get("embedFullWidthRows"),n=t!==this.embedFullWidthRows||this.printLayout!==e;this.printLayout=e,this.embedFullWidthRows=t,n&&this.redrawAfterModelUpdate({domLayoutChanged:!0})}datasourceChanged(){this.firstRenderedRow=0,this.lastRenderedRow=-1;let e=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(e)}onPageLoaded(e){let t={recycleRows:e.keepRenderedRows,animate:e.animate,newData:e.newData,newPage:e.newPage,onlyBody:!0};this.redrawAfterModelUpdate(t)}getAllCellsNotSpanningForColumn(e){let t=[];for(let n of this.getAllRowCtrls()){let i=n.getCellCtrl(e,!0)?.eGui;i&&t.push(i)}return t}refreshFloatingRowComps(e=!0){this.refreshFloatingRows(this.topRowCtrls,"top",e),this.refreshFloatingRows(this.bottomRowCtrls,"bottom",e)}refreshFloatingRows(e,t,n){let{pinnedRowModel:i,beans:r,printLayout:o}=this,a=Object.fromEntries(e.map(e=>[e.rowNode.id,e]));i?.forEachPinnedRow(t,(s,l)=>{let d=e[l];d&&void 0===i.getPinnedRowById(d.rowNode.id,t)&&(d.destroyFirstPass(),d.destroySecondPass()),s.id in a&&n?(e[l]=a[s.id],delete a[s.id]):e[l]=new fd(s,r,!1,!1,o)}),e.length=("top"===t?i?.getPinnedTopRowCount():i?.getPinnedBottomRowCount())??0}onPinnedRowDataChanged(){this.redrawAfterModelUpdate({recycleRows:!0})}onPinnedRowsChanged(){this.redrawAfterModelUpdate({recycleRows:!0})}redrawRow(e,t=!1){if(e.sticky)this.stickyRowFeature?.refreshStickyNode(e);else{if(this.cachedRowCtrls?.has(e))return void this.cachedRowCtrls.removeRow(e);let t=t=>{let n=t[e.rowIndex];n&&n.rowNode===e&&(n.destroyFirstPass(),n.destroySecondPass(),t[e.rowIndex]=this.createRowCon(e,!1,!1))};switch(e.rowPinned){case"top":t(this.topRowCtrls);break;case"bottom":t(this.bottomRowCtrls);break;default:t(this.rowCtrlsByRowIndex),this.updateAllRowCtrls()}}t||this.dispatchDisplayedRowsChanged(!1)}redrawRows(e){let{editSvc:t}=this.beans;if(t?.isEditing()&&(t.isBatchEditing()?t.cleanupEditors():t.stopEditing(void 0,{source:"api"})),null!=e){for(let t of e??[])this.redrawRow(t,!0);this.dispatchDisplayedRowsChanged(!1);return}this.redrawAfterModelUpdate()}redrawAfterModelUpdate(e={}){this.getLockOnRefresh();let t=this.beans.focusSvc?.getFocusCellToUseAfterRefresh();this.updateContainerHeights(),this.scrollToTopIfNewData(e);let n=!e.domLayoutChanged&&!!e.recycleRows,i=e.animate&&am(this.gos),r=n?this.getRowsToRecycle():null;n||this.removeAllRowComps(),this.workOutFirstAndLastRowsToRender();let{stickyRowFeature:o,gos:a}=this;if(o){o.checkStickyRows();let e=o.extraTopHeight+o.extraBottomHeight;e&&this.updateContainerHeights(e)}this.recycleRows(r,i),this.gridBodyCtrl.updateRowCount(),e.onlyBody||this.refreshFloatingRowComps(a.get("enableRowPinning")?n:void 0),this.dispatchDisplayedRowsChanged(),null!=t&&this.restoreFocusedCell(t),this.releaseLockOnRefresh()}scrollToTopIfNewData(e){let t=e.newData||e.newPage,n=this.gos.get("suppressScrollOnNewData");t&&!n&&(this.gridBodyCtrl.scrollFeature.scrollToTop(),this.stickyRowFeature?.resetOffsets())}updateContainerHeights(e=0){let{rowContainerHeight:t}=this;if(this.printLayout)return void t.setModelHeight(null);let n=this.pageBounds.getCurrentPageHeight();0===n&&(n=1),t.setModelHeight(n+e)}getLockOnRefresh(){if(this.refreshInProgress)throw Error(ar(252));this.refreshInProgress=!0,this.beans.frameworkOverrides.getLockOnRefresh?.()}releaseLockOnRefresh(){this.refreshInProgress=!1,this.beans.frameworkOverrides.releaseLockOnRefresh?.()}isRefreshInProgress(){return this.refreshInProgress}restoreFocusedCell(e){if(!e)return;let t=this.beans.focusSvc,n=this.findPositionToFocus(e);n?e.rowIndex!==n.rowIndex||e.rowPinned!=n.rowPinned?t.setFocusedCell({...n,preventScrollOnBrowserFocus:!0,forceBrowserFocus:!0}):t.doesRowOrCellHaveBrowserFocus()||this.updateCellFocus(aN(this.gos,{...n,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0,t
377ype:"cellFocused"})):t.focusHeaderPosition({headerPosition:{headerRowIndex:u3(this.beans)-1,column:e.column}})}findPositionToFocus(e){let{pagination:t,pageBounds:n}=this.beans,i=e;for(null==i.rowPinned&&t&&n&&!t.isRowInPage(i.rowIndex)&&(i={rowPinned:null,rowIndex:n.getFirstRow()});i;){if(null==i.rowPinned&&n)if(i.rowIndex<n.getFirstRow()){if(!(i=c6(this.beans,{rowPinned:null,rowIndex:0})))break}else i.rowIndex>n.getLastRow()&&(i={rowPinned:null,rowIndex:n.getLastRow()});let t=this.getRowByPosition(i);if(t?.isAlive())return{...t.getRowPosition(),column:e.column};i=c6(this.beans,i)}return null}getAllCellCtrls(){let e=[],t=this.getAllRowCtrls(),n=t.length;for(let i=0;i<n;i++){let n=t[i].getAllCellCtrls(),r=n.length;for(let t=0;t<r;t++)e.push(n[t])}return e}getAllRowCtrls(){let{spannedRowRenderer:e}=this.beans,t=this.getStickyTopRowCtrls(),n=this.getStickyBottomRowCtrls();return[...this.topRowCtrls,...this.bottomRowCtrls,...t,...n,...e?.getCtrls("top")??[],...e?.getCtrls("bottom")??[],...e?.getCtrls("center")??[],...Object.values(this.rowCtrlsByRowIndex)]}addRenderedRowListener(e,t,n){let i=this.rowCtrlsByRowIndex[t];i&&i.addEventListener(e,n)}refreshCells({rowNodes:e,columns:t,force:n,suppressFlash:i}={}){let r={force:n,newData:!1,suppressFlash:i};for(let n of this.getCellCtrls(e,t))n.refreshOrDestroyCell(r);this.refreshFullWidth(e)}refreshRows(e={}){for(let t of this.getRowCtrls(e.rowNodes))t.refreshRow(e);this.refreshFullWidth(e.rowNodes)}refreshFullWidth(e){if(!e)return;let t=!1;for(let n of this.getRowCtrls(e))n.isFullWidth()&&(n.refreshFullWidth()||(t=!0,this.redrawRow(n.rowNode,!0)));t&&this.dispatchDisplayedRowsChanged(!1)}getRowCtrls(e){let t=fM(e),n=this.getAllRowCtrls();return e&&t?n.filter(e=>fT(e.rowNode,t)):n}getCellCtrls(e,t){let n;rC(t)&&(n={},t.forEach(e=>{let t=this.colModel.getCol(e);rC(t)&&(n[t.getId()]=!0)}));let i=[];for(let t of this.getRowCtrls(e))for(let e of t.getAllCellCtrls()){let t=e.column.getId();n&&!n[t]||i.push(e)}return i}destroy(){this.removeAllRowComps(!0),super.destroy()}removeAllRowComps(e=!1){let t=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(t,e),this.stickyRowFeature?.destroyStickyCtrls()}getRowsToRecycle(){let e=[];for(let t of Object.keys(this.rowCtrlsByRowIndex))null==this.rowCtrlsByRowIndex[t].rowNode.id&&e.push(t);this.removeRowCtrls(e);let t={};for(let e of Object.values(this.rowCtrlsByRowIndex))t[e.rowNode.id]=e;return this.rowCtrlsByRowIndex={},t}removeRowCtrls(e,t=!1){for(let n of e){let e=this.rowCtrlsByRowIndex[n];e&&(e.destroyFirstPass(t),e.destroySecondPass()),delete this.rowCtrlsByRowIndex[n]}}onBodyScroll(e){"vertical"===e.direction&&this.redraw({afterScroll:!0})}redraw(e={}){let t,{focusSvc:n,animationFrameSvc:i}=this.beans,{afterScroll:r}=e,o=this.stickyRowFeature;o&&(t=n?.getFocusCellToUseAfterRefresh()||void 0);let a=this.firstRenderedRow,s=this.lastRenderedRow;this.workOutFirstAndLastRowsToRender();let l=!1;if(o){l=o.checkStickyRows();let e=o.extraTopHeight+o.extraBottomHeight;e&&this.updateContainerHeights(e)}let d=this.firstRenderedRow!==a||this.lastRenderedRow!==s;if((!r||l||d)&&(this.getLockOnRefresh(),this.recycleRows(null,!1,r),this.releaseLockOnRefresh(),this.dispatchDisplayedRowsChanged(r&&!l),null!=t)){let e=n?.getFocusCellToUseAfterRefresh();null!=t&&null==e&&(i?.flushAllFrames(),this.restoreFocusedCell(t))}}removeRowCompsNotToDraw(e,t){let n={};for(let t of e)n[t]=!0;let i=Object.keys(this.rowCtrlsByRowIndex).filter(e=>!n[e]);this.removeRowCtrls(i,t)}calculateIndexesToDraw(e){let t=[];for(let e=this.firstRenderedRow;e<=this.lastRenderedRow;e++)t.push(e);let n=this.beans.pagination,i=this.beans.focusSvc?.getFocusedCell()?.rowIndex;null!=i&&(i<this.firstRenderedRow||i>this.lastRenderedRow)&&(!n||n.isRowInPage(i))&&i<this.rowModel.getRowCount()&&t.push(i);let r=e=>{let n=e.rowNode.rowIndex;null!=n&&n!==i&&(n<this.firstRenderedRow||n>this.lastRenderedRow)&&this.doNotUnVirtualiseRow(e)&&t.push(n)};for(let e of Object.values(this.rowCtrlsByRowIndex))r(e);if(e)for(let t of Object.values(e))r(t);t.sort((e,t)=>e-t);let o=[];for(let e=0;e<t.length;e++){let n=t[e],i=this.rowModel.getRow(n);i&&!i.sticky&&o.push(n)}return o}recycleRows(e,t=!1,n=!1){let i=this.calculateIndexesToDraw(e);for(let r of((this.printLayout||n)&&(t=!1),this.removeRowCompsNotToDraw(i,!t),i))this.createOrUpdateRowCtrl(r,e,t,n);if(e){let{animationFrameSvc:i}=this.beans;i?.active&&n&&!this.printLayout?i.addDestroyTask(()=>{this.destroyRowCtrls(e,t),this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged()}):this.destroyRowCtrls(e,t)}this.updateAllRowCtrls()}dispatchDisplayedRowsChanged(e=!1){this.eventSvc.dispatchEvent({type:"displayedRowsChanged",afterScroll:e})}onDisplayedColumnsChanged(){let{visibleCols:e}=this.beans,t=e.isPinningLeft(),n=e.isPinningRight();(this.pinningLeft!==t||n!==this.pinningRight)&&(this.pinningLeft=t,this.pinningRight=n,this.embedFullWidthRows&&this.redrawFullWidthEmbeddedRows())}redrawFullWidthEmbeddedRows(){let e=[];for(let t of this.getFullWidthRowCtrls()){let n=t.rowNode.rowIndex;e.push(n.toString())}this.refreshFloatingRowComps(),this.removeRowCtrls(e),this.redraw({afterScroll:!0})}getFullWidthRowCtrls(e){let t=fM(e);return this.getAllRowCtrls().filter(e=>{if(!e.isFullWidth())return!1;let n=e.rowNode;return null==t||!!fT(n,t)})}createOrUpdateRowCtrl(e,t,n,i){let r,o=this.rowCtrlsByRowIndex[e];if(!o&&rC(r=this.rowModel.getRow(e))&&rC(t)&&t[r.id]&&r.alreadyRendered&&(o=t[r.id],t[r.id]=null),!o){if(r||(r=this.rowModel.getRow(e)),!rC(r))return;o=this.createRowCon(r,n,i)}r&&(r.alreadyRendered=!0),this.rowCtrlsByRowIndex[e]=o}destroyRowCtrls(e,t){let n=[];if(e){for(let i of Object.values(e))if(i){if(this.cachedRowCtrls&&i.isCacheable()){this.cachedRowCtrls.addRow(i);continue}if(i.destroyFirstPass(!t),t){let e=i.instanceId;this.zombieRowCtrls[e]=i,n.push(()=>{i.destroySecondPass(),delete this.zombieRowCtrls[e]})}else i.destroySecondPass()}}t&&(n.push(()=>{this.isAlive()&&(this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged())}),window.setTimeout(()=>{for(let e of n)e()},400))}getRowBuffer(){return this.gos.get("rowBuffer")}
377getRowBufferInPixels(){return this.getRowBuffer()*ah(this.beans)}workOutFirstAndLastRowsToRender(){let e,t,{rowContainerHeight:n,pageBounds:i,rowModel:r}=this;if(n.updateOffset(),r.isRowsToRender())if(this.printLayout)this.beans.environment.refreshRowHeightVariable(),e=i.getFirstRow(),t=i.getLastRow();else{let o,a,s=this.getRowBufferInPixels(),l=this.ctrlsSvc.getScrollFeature(),d=this.gos.get("suppressRowVirtualisation"),u=!1;do{let e=i.getPixelOffset(),{pageFirstPixel:t,pageLastPixel:r}=i.getCurrentPagePixelRange(),c=n.divStretchOffset,h=l.getVScrollPosition(),p=h.top,f=h.bottom;d?(o=t+c,a=r+c):(o=Math.max(p+e-s,t)+c,a=Math.min(f+e+s,r)+c),this.firstVisibleVPixel=Math.max(p+e,t)+c,this.lastVisibleVPixel=Math.min(f+e,r)+c,u=this.ensureAllRowsInRangeHaveHeightsCalculated(o,a)}while(u)let c=r.getRowIndexAtPixel(o),h=r.getRowIndexAtPixel(a),p=i.getFirstRow(),f=i.getLastRow();c<p&&(c=p),h>f&&(h=f),e=c,t=h}else e=0,t=-1;let o=al(this.gos,"normal"),a=this.gos.get("suppressMaxRenderedRowRestriction"),s=Math.max(this.getRowBuffer(),500);o&&!a&&t-e>s&&(t=e+s);let l=e!==this.firstRenderedRow,d=t!==this.lastRenderedRow;(l||d)&&(this.firstRenderedRow=e,this.lastRenderedRow=t,this.eventSvc.dispatchEvent({type:"viewportChanged",firstRow:e,lastRow:t}))}dispatchFirstDataRenderedEvent(){this.dataFirstRenderedFired||(this.dataFirstRenderedFired=!0,op(this.beans,()=>{this.beans.eventSvc.dispatchEvent({type:"firstDataRendered",firstRow:this.firstRenderedRow,lastRow:this.lastRenderedRow})}))}ensureAllRowsInRangeHaveHeightsCalculated(e,t){let n=this.pinnedRowModel?.ensureRowHeightsValid(),i=this.stickyRowFeature?.ensureRowHeightsValid(),{pageBounds:r,rowModel:o}=this,a=o.ensureRowHeightsValid(e,t,r.getFirstRow(),r.getLastRow());return(a||i)&&this.eventSvc.dispatchEvent({type:"recalculateRowBounds"}),(!!i||!!a||!!n)&&(this.updateContainerHeights(),!0)}doNotUnVirtualiseRow(e){let t=e.rowNode,n=this.focusSvc.isRowFocused(t.rowIndex,t.rowPinned),i=this.editSvc?.isEditing(e),r=t.detail;return!!(n||i||r)&&!!this.isRowPresent(t)}isRowPresent(e){return!!this.rowModel.isRowPresent(e)&&(this.beans.pagination?.isRowInPage(e.rowIndex)??!0)}createRowCon(e,t,n){let i=this.cachedRowCtrls?.getRow(e)??null;if(i)return i;let r=n&&!this.printLayout&&!!this.beans.animationFrameSvc?.active;return new fd(e,this.beans,t,r,this.printLayout)}getRenderedNodes(){let e=Object.values(this.rowCtrlsByRowIndex).map(e=>e.rowNode);return[...this.getStickyTopRowCtrls().map(e=>e.rowNode),...e,...this.getStickyBottomRowCtrls().map(e=>e.rowNode)]}getRowByPosition(e){let t,{rowIndex:n}=e;switch(e.rowPinned){case"top":t=this.topRowCtrls[n];break;case"bottom":t=this.bottomRowCtrls[n];break;default:!(t=this.rowCtrlsByRowIndex[n])&&((t=this.getStickyTopRowCtrls().find(e=>e.rowNode.rowIndex===n)||null)||(t=this.getStickyBottomRowCtrls().find(e=>e.rowNode.rowIndex===n)||null))}return t}isRangeInRenderedViewport(e,t){if(null==e||null==t)return!1;let n=e>this.lastRenderedRow;return!(t<this.firstRenderedRow)&&!n}},fk=class{constructor(e){this.entriesMap={},this.entriesList=[],this.maxCount=e}addRow(e){if(this.entriesMap[e.rowNode.id]=e,this.entriesList.push(e),e.setCached(!0),this.entriesList.length>this.maxCount){let e=this.entriesList[0];e.destroyFirstPass(),e.destroySecondPass(),this.removeFromCache(e)}}getRow(e){if(e?.id==null)return null;let t=this.entriesMap[e.id];return t?(this.removeFromCache(t),t.setCached(!1),t.rowNode!=e?null:t):null}has(e){return null!=this.entriesMap[e.id]}removeRow(e){let t=e.id,n=this.entriesMap[t];delete this.entriesMap[t],aJ(this.entriesList,n)}removeFromCache(e){let t=e.rowNode.id;delete this.entriesMap[t],aJ(this.entriesList,e)}getEntries(){return this.entriesList}};function fM(e){if(!e)return;let t={top:{},bottom:{},normal:{}};for(let n of e){let e=n.id;switch(n.rowPinned){case"top":t.top[e]=n;break;case"bottom":t.bottom[e]=n;break;default:t.normal[e]=n}}return t}function fT(e,t){let n=e.id;switch(e.rowPinned){case"top":return null!=t.top[n];case"bottom":return null!=t.bottom[n];default:return null!=t.normal[n]}}var fD={moduleName:"Sort",version:o1,beans:[pw,class extends oI{constructor(){super(...arguments),this.beanName="rowNodeSorter"}postConstruct(){let{gos:e}=this;this.isAccentedSort=e.get("accentedSort"),this.primaryColumnsSortGroups=ay(e),this.addManagedPropertyListener("accentedSort",e=>this.isAccentedSort=e.currentValue),this.addManagedPropertyListener("autoGroupColumnDef",()=>this.primaryColumnsSortGroups=ay(e))}doFullSort(e,t){let n=e.map((e,t)=>({currentPos:t,rowNode:e}));return n.sort(this.compareRowNodes.bind(this,t)),n.map(e=>e.rowNode)}compareRowNodes(e,t,n){let i=t.rowNode,r=n.rowNode;for(let t=0,n=e.length;t<n;t++){let n,o=e[t],a="desc"===o.sort,s=this.getValue(i,o.column),l=this.getValue(r,o.column),d=this.getComparator(o,i);if(!isNaN(n=d?d(s,l,i,r,a):function(e,t,n=!1){var i,r,o,a;let s=null==e,l=null==t;if(e?.toNumber&&(e=e.toNumber()),t?.toNumber&&(t=t.toNumber()),s&&l)return 0;if(s)return -1;if(l)return 1;if("string"!=typeof e||!n){return(i=e)>(r=t)?1:i<r?-1:0}try{return e.localeCompare(t)}catch(n){return(o=e)>(a=t)?1:o<a?-1:0}}(s,l,this.isAccentedSort))&&0!==n)return"asc"===o.sort?n:-1*n}return t.currentPos-n.currentPos}getComparator(e,t){let n=e.column,i=n.getColDef().comparator;if(null!=i)return i;if(!n.getColDef().showRowGroup)return;let r=!t.group&&n.getColDef().field;if(!r)return;let o=this.beans.colModel.getColDefCol(r);if(o)return o.getColDef().comparator}getValue(e,t){let{valueSvc:n,colModel:i,showRowGroupCols:r,gos:o}=this.beans;if(!this.primaryColumnsSortGroups)return n.getValue(t,e,!1);if(e.rowGroupColumn===t){if(ax(o,i.isPivotActive())){let i=e.data?e:dj(e.childrenAfterGroup);return i&&n.getValue(t,i,!1)}let a=r?.getShowRowGroupCol(t.getId());if(!a)return;return e.groupData?.[a.getId()]}if(!e.group||!t.getColDef().showRowGroup)return n.getValue(t,e,!1)}}],apiFunctions:{onSortChanged:function(e){e.sortSvc?.onSortChanged("api")}},userComponents:{agSortIndicator:py},icons:{sortAscending:"asc",sortDescending:"desc",sortUnSort:"none"}},fR=class extends oI{constructor(){super(...arguments),this.beanName="syncSvc",this.waitingForColumns=!1}postConstruct(){this.addManagedPropertyListener("columnDefs",e=>this.setColumnDefs(e))}start(){this.beans.ctrlsSvc.whenReady(this,()=>{let e=this.gos.get("columnDefs");e?this.setColumnsAndData(e):this.waitingForColumns=!0,this.gridReady()})}
377setColumnsAndData(e){let{colModel:t,rowModel:n}=this.beans;t.setColumnDefs(e??[],"gridInitializing"),n.start()}gridReady(){let{eventSvc:e,gos:t}=this;e.dispatchEvent({type:"gridReady"}),o$(t,`initialised successfully, enterprise = ${t.isModuleRegistered("EnterpriseCore")}`)}setColumnDefs(e){let t=this.gos.get("columnDefs");if(t){if(this.waitingForColumns){this.waitingForColumns=!1,this.setColumnsAndData(t);return}this.beans.colModel.setColumnDefs(t,se(e.source))}}},fI=class extends oI{constructor(){super(...arguments),this.beanName="changeDetectionSvc",this.clientSideRowModel=null}postConstruct(){let{gos:e,rowModel:t}=this.beans;aa(e,t)&&(this.clientSideRowModel=t),this.addManagedEventListeners({cellValueChanged:this.onCellValueChanged.bind(this)})}onCellValueChanged(e){let{gos:t,rowRenderer:n}=this.beans;if("paste"===e.source||t.get("suppressChangeDetection"))return;let i=e.node,r=[i],o=this.clientSideRowModel,a=o?.rootNode;if(a&&!i.isRowPinned()){let n=new c9(t.get("aggregateOnlyChangedColumns"),a);n.addParentNode(i.parent,[e.column]),o.doAggregate(n),n.forEachChangedNodeDepthFirst(e=>{r.push(e),e.sibling&&r.push(e.sibling)})}n.refreshCells({rowNodes:r})}},fA=class extends oI{constructor(){super(...arguments),this.beanName="expressionSvc",this.cache={}}evaluate(e,t){if("string"==typeof e)return this.evaluateExpression(e,t);an(15,{expression:e})}evaluateExpression(e,t){try{return this.createExpressionFunction(e)(t.value,t.context,t.oldValue,t.newValue,t.value,t.node,t.data,t.colDef,t.rowIndex,t.api,t.getValue,t.column,t.columnGroup)}catch(n){return an(16,{expression:e,params:t,e:n}),null}}createExpressionFunction(e){let t=this.cache;if(t[e])return t[e];let n=Function("x, ctx, oldValue, newValue, value, node, data, colDef, rowIndex, api, getValue, column, columnGroup",this.createFunctionBody(e));return t[e]=n,n}createFunctionBody(e){return e.includes("return")?e:"return "+e+";"}},fP={moduleName:"CommunityCore",version:o1,beans:[pp,cZ,hN,sR,fS,hv,pl,pz,sv,fp,fh,f_,class extends oI{constructor(){super(...arguments),this.beanName="valueSvc",this.hasEditSvc=!1,this.initialised=!1,this.isSsrm=!1}wireBeans(e){this.expressionSvc=e.expressionSvc,this.colModel=e.colModel,this.valueCache=e.valueCache,this.dataTypeSvc=e.dataTypeSvc,this.editSvc=e.editSvc,this.hasEditSvc=!!e.editSvc}postConstruct(){this.initialised||this.init()}init(){this.executeValueGetter=this.valueCache?this.executeValueGetterWithValueCache.bind(this):this.executeValueGetterWithoutValueCache.bind(this),this.isSsrm=as(this.gos),this.cellExpressions=this.gos.get("enableCellExpressions"),this.isTreeData=this.gos.get("treeData"),this.initialised=!0;let e=e=>this.callColumnCellValueChangedHandler(e);this.eventSvc.addListener("cellValueChanged",e,!0),this.addDestroyFunc(()=>this.eventSvc.removeListener("cellValueChanged",e,!0)),this.addManagedPropertyListener("treeData",e=>this.isTreeData=e.currentValue)}getValueForDisplay(e,t,n=!1,i=!1,r="ui"){let{showRowGroupColValueSvc:o}=this.beans,a=!e&&t.group,s=e?.colDef.showRowGroup,l=!this.isTreeData||t.footer;if(o&&l&&(a||s)){let r=o.getGroupValue(t,e);if(null==r)return{value:null,valueFormatted:null};if(!n)return{value:r.value,valueFormatted:null};let a=o.formatAndPrefixGroupColValue(r,e,i);return{value:r.value,valueFormatted:a}}if(!e)return{value:t.key,valueFormatted:null};let d=t.leafGroup&&this.colModel.isPivotMode(),u=t.group&&t.expanded&&!t.footer&&!d,c=this.gos.get("groupSuppressBlankHeader")||!t.sibling,h=this.getValue(e,t,u&&!c,r);return{value:h,valueFormatted:n&&!(i&&!1===e.colDef.useValueFormatterForExport)?this.formatValue(e,t,h):null}}getValue(e,t,n=!1,i="ui"){let r;if(this.initialised||this.init(),!t)return;let o=e.getColDef(),a=o.field,s=e.getColId(),l=t.data;if(this.hasEditSvc&&"ui"===i){let n=this.editSvc;if(n.isEditing()){let i=n.getCellDataValue({rowNode:t,column:e},!0);if(void 0!==i)return i}}let d=o.showRowGroup;if("string"==typeof d&&(this.beans.rowGroupColsSvc?.getColumnIndex(d)??-1)>t.level)return null;let u="string"!=typeof d||!t.group,c=t.groupData&&s in t.groupData,h=!n&&t.aggData&&void 0!==t.aggData[s],p=this.isSsrm&&n&&!!o.aggFunc,f=this.isSsrm&&t.footer&&t.field&&(!0===o.showRowGroup||o.showRowGroup===t.field);if(this.isTreeData&&h)r=t.aggData[s];
377else if(this.isTreeData&&o.valueGetter)r=this.executeValueGetter(o.valueGetter,l,e,t);else if(this.isTreeData&&a&&l)r=hM(l,a,e.isFieldContainsDots());else if(c)r=t.groupData[s];else if(h)r=t.aggData[s];else if(o.valueGetter&&!p){if(!u)return r;r=this.executeValueGetter(o.valueGetter,l,e,t)}else if(f)r=hM(l,t.field,e.isFieldContainsDots());else if(a&&l&&!p){if(!u)return r;r=hM(l,a,e.isFieldContainsDots())}if(this.cellExpressions&&"string"==typeof r&&0===r.indexOf("=")){let n=r.substring(1);r=this.executeValueGetter(n,l,e,t)}return r}parseValue(e,t,n,i){let r=e.getColDef(),o=r.valueParser;if(rC(o)){let a=aN(this.gos,{node:t,data:t?.data,oldValue:i,newValue:n,colDef:r,column:e});return"function"==typeof o?o(a):this.expressionSvc?.evaluate(o,a)}return n}getDeleteValue(e,t){return rC(e.getColDef().valueParser)?this.parseValue(e,t,"",this.getValueForDisplay(e,t).value)??null:null}formatValue(e,t,n,i,r=!0){let o,{expressionSvc:a}=this.beans,s=null,l=e.getColDef();if(i?o=i:r&&(o=l.valueFormatter),o){let i=t?t.data:null,r=aN(this.gos,{value:n,node:t,data:i,colDef:l,column:e});s="function"==typeof o?o(r):a?a.evaluate(o,r):null}else if(l.refData)return l.refData[n]||"";return null==s&&Array.isArray(n)&&(s=n.join(", ")),s}setValue(e,t,n,i){let r,o=this.colModel.getColDefCol(t);if(!e||!o)return!1;rS(e.data)&&(e.data={});let{field:a,valueSetter:s}=o.getColDef();if(rS(a)&&rS(s))return at(17),!1;if(this.dataTypeSvc&&!this.dataTypeSvc.checkType(o,n))return at(135),!1;let l=aN(this.gos,{node:e,data:e.data,oldValue:this.getValue(o,e,void 0,i),newValue:n,colDef:o.getColDef(),column:o});if(l.newValue=n,void 0===(r=rC(s)?"function"==typeof s?s(l):this.expressionSvc?.evaluate(s,l):this.setValueUsingField(e.data,a,n,o.isFieldContainsDots()))&&(r=!0),!r)return!1;e.resetQuickFilterAggregateText(),this.valueCache?.onDataChanged();let d=this.getValue(o,e);return this.dispatchCellValueChangedEvent(e,l,d,i),e.pinnedSibling&&this.dispatchCellValueChangedEvent(e.pinnedSibling,l,d,i),!0}
377dispatchCellValueChangedEvent(e,t,n,i){this.eventSvc.dispatchEvent({type:"cellValueChanged",event:null,rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:t.column,colDef:t.colDef,data:e.data,node:e,oldValue:t.oldValue,newValue:n,value:n,source:i})}callColumnCellValueChangedHandler(e){let t=e.colDef.onCellValueChanged;"function"==typeof t&&this.beans.frameworkOverrides.wrapOutgoing(()=>{t({node:e.node,data:e.data,oldValue:e.oldValue,newValue:e.newValue,colDef:e.colDef,column:e.column,api:e.api,context:e.context})})}setValueUsingField(e,t,n,i){if(!t)return!1;let r=!1;if(i){let i=t.split("."),o=e;for(;i.length>0&&o;){let e=i.shift();0===i.length?(r=o[e]===n)||(o[e]=n):o=o[e]}}else(r=e[t]===n)||(e[t]=n);return!r}executeValueGetterWithValueCache(e,t,n,i){let r=n.getColId(),o=this.valueCache.getValue(i,r);if(void 0!==o)return o;let a=this.executeValueGetterWithoutValueCache(e,t,n,i);return this.valueCache.setValue(i,r,a),a}executeValueGetterWithoutValueCache(e,t,n,i){let r=aN(this.gos,{data:t,node:i,column:n,colDef:n.getColDef(),getValue:this.getValueCallback.bind(this,i)});return"function"==typeof e?e(r):this.expressionSvc?.evaluate(e,r)}getValueCallback(e,t){let n=this.colModel.getColDefCol(t);return n?this.getValue(n,e):null}getKeyForNode(e,t){let n=this.getValue(e,t),i=e.getColDef().keyCreator,r=n;return i&&(r=i(aN(this.gos,{value:n,colDef:e.getColDef(),column:e,node:t,data:t.data}))),"string"==typeof r||null==r||"[object Object]"===(r=String(r))&&at(121),r}},pc,pa,ph,hB,fR,hL,hF,pq],icons:{selectOpen:"small-down",smallDown:"small-down",colorPicker:"color-picker",smallUp:"small-up",checkboxChecked:"small-up",checkboxIndeterminate:"checkbox-indeterminate",checkboxUnchecked:"checkbox-unchecked",radioButtonOn:"radio-button-on",radioButtonOff:"radio-button-off",smallLeft:"small-left",smallRight:"small-right"},apiFunctions:{getGridId:function(e){return e.context.getId()},destroy:function(e){e.gridDestroySvc.destroy()},isDestroyed:function(e){return e.gridDestroySvc.destroyCalled},getGridOption:function(e,t){return e.gos.get(t)},setGridOption:function(e,t,n){cX(e,{[t]:n})},updateGridOptions:cX,isModuleRegistered:function(e,t){let n=t.replace(/Module$/,"");return e.gos.isModuleRegistered(n)}},dependsOn:[{moduleName:"DataType",version:o1,beans:[hD],dependsOn:[{moduleName:"CheckboxCellRenderer",version:o1,userComponents:{agCheckboxCellRenderer:cw}}]},{moduleName:"ColumnMove",version:o1,beans:[hu,ht],apiFunctions:{moveColumnByIndex:function(e,t,n){e.colMoves?.moveColumnByIndex(t,n,"api")},moveColumns:function(e,t,n){e.colMoves?.moveColumns(t,n,"api")}},dependsOn:[{moduleName:"SharedDragAndDrop",version:o1,beans:[dE],dependsOn:[he],userComponents:{agDragAndDropImage:cb},icons:{columnMovePin:"pin",columnMoveHide:"eye-slash",columnMoveMove:"arrows",columnMoveLeft:"left",columnMoveRight:"right",columnMoveGroup:"group",columnMoveValue:"aggregation",columnMovePivot:"pivot",dropNotAllowed:"not-allowed",rowDrag:"grip"}}],css:[":where(.ag-ltr) :where(.ag-column-moving){.ag-cell,.ag-header-cell,.ag-spanned-cell-wrapper{transition:left .2s}.ag-header-group-cell{transition:left .2s,width .2s}}:where(.ag-rtl) :where(.ag-column-moving){.ag-cell,.ag-header-cell,.ag-spanned-cell-wrapper{transition:right .2s}.ag-header-group-cell{transition:right .2s,width .2s}}"]},{moduleName:"ColumnResize",version:o1,beans:[hf],apiFunctions:{setColumnWidths:function(e,t,n=!0,i="api"){e.colResize?.setColumnWidths(t,!1,n,i)}},dependsOn:[{moduleName:"HorizontalResize",version:o1,beans:[c0],dependsOn:[he]},hc]},fD,{moduleName:"ColumnHeaderComp",version:o1,userComponents:{agColumnHeader:pG},icons:{menu:"menu",menuAlt:"menu-alt"}},{moduleName:"ColumnGroup",version:o1,dynamicBeans:{headerGroupCellCtrl:hm},beans:[hx],apiFunctions:{getAllDisplayedColumnGroups:function(e){return e.visibleCols.getAllTrees()},getCenterDisplayedColumnGroups:function(e){return e.visibleCols.treeCenter},getColumnGroup:function(e,t,n){return e.colGroupSvc?.getColumnGroup(t,n)??null},getColumnGroupState:function(e){return e.colGroupSvc?.getColumnGroupState()??[]},getDisplayNameForColumnGroup:function(e,t,n){return e.colNames.getDisplayNameForColumnGroup(t,n)||""},getLeftDisplayedColumnGroups:function(e){return e.visibleCols.treeLeft},getProvidedColumnGroup:function(e,t){return e.colGroupSvc?.getProvidedColGroup(t)??null},getRightDisplayedColumnGroups:function(e){return e.visibleCols.treeRight},resetColumnGroupState:function(e){e.colGroupSvc?.resetColumnGroupState("api")},setColumnGroupOpened:function(e,t,n){e.colGroupSvc?.setColumnGroupOpened(t,n,"api")},setColumnGroupState:function(e,t){e.colGroupSvc?.setColumnGroupState(t,"api")}}},{moduleName:"ColumnGroupHeaderComp",version:o1,userComponents:{agColumnGroupHeader:p$},icons:{columnGroupOpened:"expanded",columnGroupClosed:"contracted"}},{moduleName:"Overlay",version:o1,userComponents:{agLoadingOverlay:cf,agNoRowsOverlay:cm}
377,apiFunctions:{showLoadingOverlay:function(e){e.overlays?.showLoadingOverlay()},showNoRowsOverlay:function(e){e.overlays?.showNoRowsOverlay()},hideOverlay:function(e){e.overlays?.hideOverlay()}},beans:[fC]},{moduleName:"ChangeDetection",version:o1,beans:[fI]},{moduleName:"AnimationFrame",version:o1,beans:[pU]},{moduleName:"KeyboardNavigation",version:o1,beans:[fu,pY,pu],apiFunctions:{getFocusedCell:function(e){return e.focusSvc.getFocusedCell()},clearFocusedCell:function(e){return e.focusSvc.clearFocusedCell()},setFocusedCell:function(e,t,n,i){e.focusSvc.setFocusedCell({rowIndex:t,column:n,rowPinned:i,forceBrowserFocus:!0})},setFocusedHeader:function(e,t,n=!1){let i=e.headerNavigation?.getHeaderPositionForColumn(t,n);i&&e.focusSvc.focusHeaderPosition({headerPosition:i})},tabToNextCell:function(e,t){return e.navigation?.tabToNextCell(!1,t)??!1},tabToPreviousCell:function(e,t){return e.navigation?.tabToNextCell(!0,t)??!1}}},{moduleName:"PinnedColumn",version:o1,beans:[fg],css:[".ag-pinned-left-floating-bottom,.ag-pinned-left-floating-top,.ag-pinned-right-floating-bottom,.ag-pinned-right-floating-top{min-width:0;overflow:hidden;position:relative}.ag-pinned-left-sticky-top,.ag-pinned-right-sticky-top{height:100%;overflow:hidden;position:relative}.ag-sticky-bottom-full-width-container,.ag-sticky-top-full-width-container{height:100%;overflow:hidden;width:100%}.ag-pinned-left-header,.ag-pinned-right-header{display:inline-block;height:100%;overflow:hidden;position:relative}.ag-body-horizontal-scroll:not(.ag-scrollbar-invisible){.ag-horizontal-left-spacer:not(.ag-scroller-corner){border-right:var(--ag-pinned-column-border)}.ag-horizontal-right-spacer:not(.ag-scroller-corner){border-left:var(--ag-pinned-column-border)}}.ag-pinned-right-header{border-left:var(--ag-pinned-column-border)}.ag-pinned-left-header{border-right:var(--ag-pinned-column-border)}.ag-cell.ag-cell-first-right-pinned:not(.ag-cell-range-left,.ag-cell-range-single-cell,.ag-cell-focus:not(.ag-cell-range-selected):focus-within){border-left:var(--ag-pinned-column-border)}.ag-cell.ag-cell-last-left-pinned:not(.ag-cell-range-right,.ag-cell-range-single-cell,.ag-cell-focus:not(.ag-cell-range-selected):focus-within){border-right:var(--ag-pinned-column-border)}.ag-pinned-left-header .ag-header-cell-resize:after{left:calc(50% - var(--ag-header-column-resize-handle-width))}.ag-pinned-right-header .ag-header-cell-resize:after{left:50%}.ag-pinned-left-header .ag-header-cell-resize{right:-3px}.ag-pinned-right-header .ag-header-cell-resize{left:-3px}"]},{moduleName:"Aria",version:o1,beans:[fm]},{moduleName:"Touch",version:o1,beans:[pK]},{moduleName:"CellRendererFunction",version:o1,beans:[hO]},{moduleName:"ColumnFlex",version:o1,beans:[hk]},{moduleName:"Expression",version:o1,beans:[fA]},{moduleName:"SkeletonCellRenderer",version:o1,userComponents:{agSkeletonCellRenderer:hC}},{moduleName:"ColumnDelayRender",version:o1,beans:[fy],css:[":where(.ag-delay-render){.ag-cell,.ag-header-cell,.ag-header-group-cell,.ag-row,.ag-spanned-cell-wrapper{visibility:hidden}}"]}]},fE={AdvancedFilter:1,AiToolkit:1,AllEnterprise:1,BatchEdit:1,CellSelection:1,Clipboard:1,ColumnMenu:1,ColumnsToolPanel:1,ContextMenu:1,ExcelExport:1,FiltersToolPanel:1,Find:1,GridCharts:1,IntegratedCharts:1,GroupFilter:1,MasterDetail:1,Menu:1,MultiFilter:1,NewFiltersToolPanel:1,Pivot:1,RangeSelection:1,RichSelect:1,RowNumbers:1,RowGrouping:1,RowGroupingPanel:1,ServerSideRowModelApi:1,ServerSideRowModel:1,SetFilter:1,SideBar:1,Sparklines:1,StatusBar:1,TreeData:1,ViewportRowModel:1},fL=["TextFilter","NumberFilter","DateFilter","SetFilter","MultiFilter","GroupFilter","CustomFilter"],fF={EditCore:["TextEditor","NumberEditor","DateEditor","CheckboxEditor","LargeTextEditor","SelectEditor","RichSelect","CustomEditor"],CheckboxCellRenderer:["AllCommunity"],ClientSideRowModelHierarchy:["RowGrouping","Pivot","TreeData"],ColumnFilter:fL,ColumnGroupHeaderComp:["AllCommunity"],ColumnGroup:["AllCommunity"],ColumnHeaderComp:["AllCommunity"],ColumnMove:["AllCommunity"],ColumnResize:["AllCommunity"],CommunityCore:["AllCommunity"],CsrmSsrmSharedApi:["ClientSideRowModelApi","ServerSideRowModelApi"],RowModelSharedApi:["ClientSideRowModelApi","ServerSideRowModelApi"],EnterpriseCore:["AllEnterprise"],FilterCore:[...fL,"QuickFilter","ExternalFilter","AdvancedFilter"],GroupCellRenderer:["RowGrouping","Pivot","TreeData","MasterDetail","ServerSideRowModel"],KeyboardNavigation:["AllCommunity"],LoadingCellRenderer:["ServerSideRowModel"],MenuCore:["ColumnMenu","ContextMenu"],MenuItem:["ColumnMenu","ContextMenu","MultiFilter","IntegratedCharts","ColumnsToolPanel"],Overlay:["AllCommunity"],PinnedColumn:["AllCommunity"],SharedAggregation:["RowGrouping","Pivot","TreeData","ServerSideRowModel"],SharedDragAndDrop:["AllCommunity"],SharedMasterDetail:["MasterDetail","ServerSideRowModel"],SharedMenu:[...fL,"ColumnMenu","ContextMenu"],SharedPivot:["Pivot","ServerSideRowModel"],SharedRowGrouping:["RowGrouping","ServerSideRowModel"],SharedRowSelection:["RowSelection","ServerSideRowModel"],SkeletonCellRenderer:["ServerSideRowModel"],Sort:["AllCommunity"],SsrmInfiniteSharedApi:["InfiniteRowModel","ServerSideRowModelApi"],SharedTreeData:["TreeData","ServerSideRowModel"]},fO={InfiniteRowModel:"infinite",ClientSideRowModelApi:"clientSide",ClientSideRowModel:"
377clientSide",ServerSideRowModelApi:"serverSide",ServerSideRowModel:"serverSide",ViewportRowModel:"viewport"},fN=()=>`No AG Grid modules are registered! It is recommended to start with all Community features via the AllCommunityModule: 378 379 import { ModuleRegistry, AllCommunityModule } from 'ag-grid-community'; 380 381 ModuleRegistry.registerModules([ AllCommunityModule ]); 382 `;function fB(e,t=!1){return t&&("IntegratedCharts"===e||"Sparklines"===e)?`${e}Module.with(AgChartsEnterpriseModule)`:`${e}Module`}function fz({moduleName:e,rowModelType:t}){return`To use the ${e}Module you must set the gridOption "rowModelType='${t}'"`}var fj=({reasonOrId:e,moduleName:t,gridScoped:n,gridId:i,rowModelType:r,additionalText:o,isUmd:a})=>{let s,l=function(e,t){let n=[];for(let i of Array.isArray(e)?e:[e]){let e=fF[i];if(e)for(let i of e){let e=fO[i];e&&e!==t||n.push(i)}else n.push(i)}return n}(t,r),d="string"==typeof e?e:fW[e];if(a){let e,t;return e=l.filter(e=>"IntegratedCharts"===e||"Sparklines"===e),t="",!globalThis?.agCharts&&e.length>0?t=`Unable to use ${d} as either the ag-charts-community or ag-charts-enterprise script needs to be included alongside ag-grid-enterprise. 383`:l.some(e=>fE[e])&&(t+=`Unable to use ${d} as that requires the ag-grid-enterprise script to be included. 384`),t}let u=l.filter(e=>"IntegratedCharts"===e||"Sparklines"===e),c=u.length>0?`${u.map(e=>fB(e)).join()} must be initialised with an AG Charts module. One of 'AgChartsCommunityModule' / 'AgChartsEnterpriseModule'.`:"",h=`Unable to use ${d} as ${l.length>1?"one of "+l.map(e=>fB(e)).join(", "):fB(l[0])} is not registered${n?" for gridId: "+i:""}. ${c} Check if you have registered the module: 385`;return`${h} 386${s=l.map(e=>`import { ${fB(e)} } from '${fE[e]?"ag-grid-enterprise":"ag-grid-community"}';`),l.some(e=>"IntegratedCharts"===e||"Sparklines"===e)&&s.push("import { AgChartsEnterpriseModule } from 'ag-charts-enterprise';"),`import { ModuleRegistry } from 'ag-grid-community'; 387${s.join(" \n")} 388 389ModuleRegistry.registerModules([ ${l.map(e=>fB(e,!0)).join(", ")} ]); 390 391For more info see: ${o5}/modules/`}`+(o?` 392 393${o}`:"")},fV=e=>`${e} must be initialised with an AG Charts module. One of 'AgChartsCommunityModule' / 'AgChartsEnterpriseModule'. 394 395import { AgChartsEnterpriseModule } from 'ag-charts-enterprise'; 396import { ModuleRegistry } from 'ag-grid-community'; 397import { ${e} } from 'ag-grid-enterprise'; 398 399ModuleRegistry.registerModules([${e}.with(AgChartsEnterpriseModule)]); 400 `,fH={1:()=>"`rowData` must be an array",2:({nodeId:e})=>`Duplicate node id '${e}' detected from getRowId callback, this could cause issues in your grid.`,3:()=>"Calling gridApi.resetRowHeights() makes no sense when using Auto Row Height.",4:({id:e})=>`Could not find row id=${e}, data item was not found for this id`,5:({data:e})=>["Could not find data item as object was not found.",e," Consider using getRowId to help the Grid find matching row data"],6:()=>"'groupHideOpenParents' only works when specifying specific columns for 'colDef.showRowGroup'",7:()=>"Pivoting is not supported with aligned grids as it may produce different columns in each grid.",8:({key:e})=>`Unknown key for navigation ${e}`,9:({variable:e})=>`No value for ${e?.cssName}. This usually means that the grid has been initialised before styles have been loaded. The default value of ${e?.defaultValue} will be used and updated when styles load.`,10:({eventType:e})=>`As of v33, the '${e}' event is deprecated. Use the global 'modelUpdated' event to determine when row children have changed.`,11:()=>"No gridOptions provided to createGrid",12:({colKey:e})=>["column ",e," not found"],13:()=>"Could not find rowIndex, this means tasks are being executed on a rowNode that has been removed from the grid.",14:({groupPrefix:e})=>`Row IDs cannot start with ${e}, this is a reserved prefix for AG Grid's row grouping feature.`,15:({expression:e})=>["value should be either a string or a function",e],16:({expression:e,params:t,e:n})=>["Processing of the expression failed","Expression = ",e,"Params = ",t,"Exception = ",n],17:()=>"you need either field or valueSetter set on colDef for editing to work",18:()=>"alignedGrids contains an undefined option.",19:()=>"alignedGrids - No api found on the linked grid.",20:()=>`You may want to configure via a callback to avoid setup race conditions: 401 "alignedGrids: () => [linkedGrid]"`,21:()=>"pivoting is not supported with aligned grids. You can only use one of these features at a time in a grid.",22:({ke
vendor: 14,714 bytes, lines 401-406
401y:e})=>`${e} is an initial property and cannot be updated.`,23:()=>"The return of `getRowHeight` cannot be zero. If the intention is to hide rows, use a filter instead.",24:()=>"row height must be a number if not using standard row model",25:({id:e})=>["The getRowId callback must return a string. The ID ",e," is being cast to a string."],26:({fnName:e,preDestroyLink:t})=>`Grid API function ${e}() cannot be called as the grid has been destroyed. 402 Either clear local references to the grid api, when it is destroyed, or check gridApi.isDestroyed() to avoid calling methods against a destroyed grid. 403 To run logic when the grid is about to be destroyed use the gridPreDestroy event. See: ${t}`,27:({fnName:e,module:t})=>`API function '${e}' not registered to module '${t}'`,28:()=>"setRowCount cannot be used while using row grouping.",29:()=>"tried to call sizeColumnsToFit() but the grid is coming back with zero width, maybe the grid is not visible yet on the screen?",30:({toIndex:e})=>["tried to insert columns in invalid location, toIndex = ",e,"remember that you should not count the moving columns when calculating the new index"],31:()=>"infinite loop in resizeColumnSets",32:()=>"applyColumnState() - the state attribute should be an array, however an array was not found. Please provide an array of items (one for each col you want to change) for state.",33:()=>"stateItem.aggFunc must be a string. if using your own aggregation functions, register the functions first before using them in get/set state. This is because it is intended for the column state to be stored and retrieved as simple JSON.",34:({key:e})=>`the column type '${e}' is a default column type and cannot be overridden.`,35:()=>"Column type definitions 'columnTypes' with a 'type' attribute are not supported because a column type cannot refer to another column type. Only column definitions 'columnDefs' can use the 'type' attribute to refer to a column type.",36:({t:e})=>"colDef.type '"+e+"' does not correspond to defined gridOptions.columnTypes",37:()=>"Changing the column pinning status is not allowed with domLayout='print'",38:({iconName:e})=>`provided icon '${e}' needs to be a string or a function`,39:()=>"Applying column order broke a group where columns should be married together. Applying new order has been discarded.",40:({e,method:t})=>`${e} 404AG Grid: Unable to use the Clipboard API (navigator.clipboard.${t}()). The reason why it could not be used has been logged in the previous line. For this reason the grid has defaulted to using a workaround which doesn't perform as well. Either fix why Clipboard API is blocked, OR stop this message from appearing by setting grid property suppressClipboardApi=true (which will default the grid to using the workaround rather than the API.`,41:()=>"Browser did not allow document.execCommand('copy'). Ensure 'api.copySelectedRowsToClipboard() is invoked via a user event, i.e. button click, otherwise the browser will prevent it for security reasons.",42:()=>"Browser does not support document.execCommand('copy') for clipboard operations",43:({iconName:e})=>`As of v33, icon '${e}' is deprecated. Use the icon CSS name instead.`,44:()=>'Data type definition hierarchies (via the "extendsDataType" property) cannot contain circular references.',45:({parentCellDataType:e})=>`The data type definition ${e} does not exist.`,46:()=>'The "baseDataType" property of a data type definition must match that of its parent.',47:({cellDataType:e})=>`Missing data type definition - "${e}"`,48:({property:e})=>`Cell data type is "object" but no Value ${e} has been provided. Please either provide an object data type definition with a Value ${e}, or set "colDef.value${e}"`,49:({methodName:e})=>`Framework component is missing the method ${e}()`,50:({compName:e})=>`Could not find component ${e}, did you forget to configure this component?`,51:()=>"Export cancelled. Export is not allowed as per your configuration.",52:()=>"There is no `window` associated with the current `document`",53:()=>"unknown value type during csv conversion",54:()=>"Could not find document body, it is needed for drag and drop and context menu.",55:()=>"addRowDropZone - A container target needs to be provided",56:()=>"addRowDropZone - target already exists in the list of DropZones. Use `removeRowDropZone` before adding it again.",57:()=>"unable to show popup filter, filter instantiation failed",58:()=>"no values found for select cellEditor",59:()=>"cannot select pinned rows",60:()=>"cannot select node until it has finished loading",61:()=>"since version v32.2.0, rowNode.isFullWidthCell() has been deprecated. Instead check `rowNode.detail` followed by the user provided `isFullWidthRow` grid option.",62:({colId:e})=>`setFilterModel() - no column found for colId: ${e}`,63:({colId:e})=>`setFilterModel() - unable to fully apply model, filtering disabled for colId: ${e}`,64:({colId:e})=>`setFilterModel() - unable to fully apply model, unable to create filter for colId: ${e}`,65:()=>"filter missing setModel method, which is needed for setFilterModel",66:()=>"filter API missing getModel method, which is needed for getFilterModel",67:()=>"Filter is missing isFilterActive() method",68:()=>"Column Filter API methods have been disabled as Advanced Filters are enabled.",69:({guiFromFilter:e})=>`getGui method from filter returned ${e}; it should be a DOM element.`,70:({newFilter:e})=>`Grid option quickFilterText only supports string inputs, received: ${typeof e}`,71:()=>"debounceMs is ignored when apply button is present",72:({keys:e})=>["ignoring FilterOptionDef as it doesn't contain one of ",e],73:()=>"invalid FilterOptionDef supplied as it doesn't contain a 'displayKey'",74:()=>"no filter options for filter",75:()=>"Unknown button type specified",76:({filterModelType:e})=>['Unexpected type of filter "',e,'", it looks like the filter was configured with incorrect Filter Options'],77:()=>"Filter model is missing 'conditions'",78:()=>'Filter Model contains more conditions than "filterParams.maxNumConditions". Additional conditions have been ignored.',79:()=>'"filterParams.maxNumConditions" must be greater than or equal to zero.',80:()=>'"filterParams.numAlwaysVisibleConditions" must be greater than or equal to zero.',81:()=>'"filterParams.numAlwaysVisibleConditions" cannot be greater than "filterParams.maxNumConditions".',82:({param:e})=>`DateFilter ${e} is not a number`,83:()=>"DateFilter minValidYear should be <= maxValidYear",84:()=>"DateFilter minValidDate should be <= maxValidDate",85:()=>"DateFilter should not have both minValidDate and minValidYear parameters set at the same time! minValidYear will be ignored.",86:()=>"DateFilter should not have both maxValidDate and maxValidYear parameters set at the same time! maxValidYear will be ignored.",87:()=>"DateFilter parameter minValidDate should always be lower than or equal to parameter maxValidDate.",88:({index:e})=>`Invalid row index for ensureIndexVisible: ${e}`,89:()=>"A template was provided for Header Group Comp - templates are only supported for Header Comps (not groups)",90:()=>"datasource is missing getRows method",91:()=>"Filter is missing method doesFilterPass",92:()=>"AnimationFrameService called but animation frames are off",93:()=>"cannot add multiple ranges when `cellSelection.suppressMultiRanges = true`",94:({paginationPageSizeOption:e,pageSizeSet:t,pageSizesSet:n,pageSizeOptions:i})=>`'paginationPageSize=${e}'${t?"":" (default value)"}, but ${e} is not included in${n?"":" the default"} paginationPageSizeSelector=[${i?.join(", ")}].`,95:({paginationPageSizeOption:e,paginationPageSizeSelector:t})=>`Either set '${t}' to an array that includes ${e} or to 'false' to disable the page size selector.`,96:({id:e,data:t})=>["Duplicate ID",e,"found for pinned row with data",t,"When `getRowId` is defined, it must return unique IDs for all pinned rows. Use the `rowPinned` parameter."],97:({colId:e})=>`cellEditor for column ${e} is missing getGui() method`,98:()=>"popup cellEditor does not work with fullRowEdit - you cannot use them both - either turn off fullRowEdit, or stop using popup editors.",99:()=>"Since v32, `api.hideOverlay()` does not hide the loading overlay when `loading=true`. Set `loading=false` instead.",101:({propertyName:e,componentName:t,agGridDefaults:n,jsComps:i})=>{let r=[],o=ly({inputValue:t,allSuggestions:[...Object.keys(n??[]).filter(e=>!["agCellEditor","agGroupRowRenderer","agSortIndicator"].includes(e)),...Object.keys(i??[]).filter(e=>!!i[e])],hideIrrelevant:!0,filterByPercentageOfBestMatch:.8}).values;return r.push(`Could not find '${t}' component. It was configured as "${e}: '${t}'" but it wasn't found in the list of registered components. 405`),o.length>0&&r.push(` Did you mean: [${o.slice(0,3)}]? 406`),r.push("If using a custom component check it has been registered correctly."),r},102:()=>"selectAll: 'filtered' only works when gridOptions.rowModelType='clientSide'",103:()=>"Invalid selection state. When using client-side row model, the state must conform to `string[]`.",104:({value:e,param:t})=>`Numeric value ${e} passed to ${t} param will be interpreted as ${e} seconds. If this is intentional use "${e}s" to silence this warning.`,105:({e})=>["chart rendering failed",e],106:()=>`Theming API and Legacy Themes are both used in the same page. A Theming API theme has been provided to the 'theme' grid option, but the file (ag-grid.css) is also included and will cause styling issues. Remove ag-grid.css from the page. See the migration guide: ${o5}/theming-migration/`,107:({key:e,value:t})=>`Invalid value for theme param ${e} - ${t}`,108:({e})=>["chart update failed",e],109:({inputValue:e,allSuggestions:t})=>{let n=ly({inputValue:e,allSuggestions:t,hideIrrelevant:!0,filterByPercentageOfBestMatch:.8}).values;return[`Could not find '${e}' aggregate function. It was configured as "aggFunc: '${e}'" but it wasn't found in the list of registered aggregations.`,n.length>0?` Did you mean: [${n.slice(0,3)}]?`:"","If using a custom aggregation function check it has been registered correctly."].join("\n")},110:()=>"groupHideOpenParents only works when specifying specific columns for colDef.showRowGroup",111:()=>"Invalid selection state. When `groupSelects` is enabled, the state must conform to `IServerSideGroupSelectionState`.",113:()=>"Set Filter cannot initialise because you are using a row model that does not contain all rows in the browser. Either use a different filter type, or configure Set Filter such that you provide it with values",114:({component:e})=>`Could not find component with name of ${e}. Is it in Vue.components?`,116:()=>"Invalid selection state. The state must conform to `IServerSideSelectionState`.",117:()=>"selectAll must be of boolean type.",118:()=>"Infinite scrolling must be enabled in order to set the row count.",119:()=>"Unable to instantiate filter",120:()=>"MultiFloatingFilterComp expects MultiFilter as its parent",121:()=>"a column you are grouping or pivoting by has objects as values. If you want to group by complex objects then either a) use a colDef.keyCreator (see AG Grid docs) or b) to toString() on the object to return a key",122:()=>"could not find the document, document is empty",123:()=>"Advanced Filter is only supported with the Client-Side Row Model or Server-Side Row Model.",124:()=>"No active charts to update.",125:({chartId:e})=>`Unable to update chart. No active chart found with ID: ${e}.`,126:()=>"unable to restore chart as no chart model is provided",127:({allRange:e})=>`unable to create chart as ${e?"there are no columns in the grid":"no range is selected"}.`,128:({feature:e})=>`${e} is only available if using 'multiRow' selection mode.`,129:({feature:e,rowModel:t})=>`${e} is only available if using 'clientSide' or 'serverSide' rowModelType, you are using ${t}.`,130:()=>'cannot multi select unless selection mode is "multiRow"',132:()=>"Row selection features are not available unless `rowSelection` is enabled.",133:({iconName:e})=>`icon '${e}' function should return back a string or a dom object`,134:({iconName:e})=>`Did not find icon '${e}'`,135:()=>"Data type of the new value does not match the cell data type of the column",136:()=>"Unable to update chart as the 'type' is missing. It must be either 'rangeChartUpdate', 'pivotChartUpdate', or 'crossFilterChartUpdate'.",137:({type:e,currentChartType:t})=>`Unable to update chart as a '${e}' update type is not permitted on a ${t}.`,138:({chartType:e})=>`invalid chart type supplied: ${e}`,139:({customThemeName:e})=>`a custom chart theme with the name ${e} has been supplied but not added to the 'chartThemes' list`,140:({name:e})=>`no stock theme exists with the name '${e}' and no custom chart theme with that name was supplied to 'customChartThemes'`,141:()=>"cross filtering with row grouping is not supported.",142:()=>"cross filtering is only supported in the client side row model.",143:({panel:e})=>`'${e}' is not a valid Chart Tool Panel name`,144:({type:e})=>`Invalid charts data panel group name supplied: '${e}'`,145:({group:e})=>`As of v32, only one charts customize panel group can be expanded at a time. '${e}' will not be expanded.`,146:({comp:e})=>`Unable to instantiate component '${e}' as its module hasn't been loaded. Add 'ValidationModule' to see which module is required.`,147:({group:e})=>`Invalid charts customize panel group name supplied: '${e}'`,148:({group:e})=>`invalid chartGroupsDef config '${e}'`,149:({group:e,chartType:t})=>`invalid chartGroupsDef config '${e}.${t}'`,150:()=>"'seriesChartTypes' are required when the 'customCombo' chart type is specified.",151:({chartType:e})=>`invalid chartType '${e}' supplied in 'seriesChartTypes', converting to 'line' instead.`,152:({colId:e})=>`no 'seriesChartType' found for colId = '${e}', defaulting to 'line'.`,153:({chartDataType:e})=>`unexpected chartDataType value '${e}' supplied, instead use 'category', 'series' or 'excluded'`,154:({colId:e})=>`cross filtering requires a 'agSetColumnFilter' or 'agMultiColumnFilter' to be defined on the column with id: ${e}`,155:({option:e})=>`'${e}' is not a valid Chart Toolbar Option`,156:({panel:e})=>`Invalid panel in chartToolPanelsDef.panels: '${e}'`,157:({unrecognisedGroupIds:e})=>["unable to find group(s) for supplied groupIds:",e],158:()=>"can not expand a column item that does not represent a column group header",159:()=>"Invalid params supplied to createExcelFileForExcel() - `ExcelExportParams.data` is empty.",160:()=>"Export cancelled. Export is not allowed as per your configuration.",161:()=>"The Excel Exporter is currently on Multi Sheet mode. End that operation by calling 'api.getMultipleSheetAsExcel()' or 'api.exportMultipleSheetsAsExcel
406()'",162:({id:e,dataType:t})=>`Unrecognized data type for excel export [${e}.dataType=${t}]`,163:({featureName:e})=>`Excel table export does not work with ${e}. The exported Excel file will not contain any Excel tables. 407 Please turn off ${e} to enable Excel table exports.`,164:()=>"Unable to add data table to Excel sheet: A table already exists.",165:()=>"Unable to add data table to Excel sheet: Missing required parameters.",166:({unrecognisedGroupIds:e})=>["unable to find groups for these supplied groupIds:",e],167:({unrecognisedColIds:e})=>["unable to find columns for these supplied colIds:",e],168:()=>"detailCellRendererParams.template should be function or string",169:()=>'Reference to eDetailGrid was missing from the details template. Please add data-ref="eDetailGrid" to the template.',170:({providedStrategy:e})=>`invalid cellRendererParams.refreshStrategy = ${e} supplied, defaulting to refreshStrategy = 'rows'.`,171:()=>"could not find detail grid options for master detail, please set gridOptions.detailCellRendererParams.detailGridOptions",172:()=>"could not find getDetailRowData for master / detail, please set gridOptions.detailCellRendererParams.getDetailRowData",173:({group:e})=>`invalid chartGroupsDef config '${e}'`,174:({group:e,chartType:t})=>`invalid chartGroupsDef config '${e}.${t}'`,175:({menuTabName:e,itemsToConsider:t})=>[`Trying to render an invalid menu item '${e}'. Check that your 'menuTabs' contains one of `,t],176:({key:e})=>`unknown menu item type ${e}`,177:()=>"valid values for cellSelection.handle.direction are 'x', 'y' and 'xy'. Default to 'xy'.",178:({colId:e})=>`column ${e} is not visible`,179:()=>"totalValueGetter should be either a function or a string (expression)",180:()=>"agRichSelectCellEditor requires cellEditorParams.values to be set",181:()=>"agRichSelectCellEditor cannot have `multiSelect` and `allowTyping` set to `true`. AllowTyping has been turned off.",182:()=>'you cannot mix groupDisplayType = "multipleColumns" with treeData, only one column can be used to display groups when doing tree data',183:()=>"Group Column Filter only works on group columns. Please use a different filter.",184:({parentGroupData:e,childNodeData:t})=>["duplicate group keys for row data, keys should be unique",[e,t]],185:({data:e})=>["getDataPath() should not return an empty path",[e]],186:({rowId:e,rowData:t,duplicateRowsData:n})=>["duplicate group keys for row data, keys should be unique",e,t,...n??[]],187:({rowId:e,firstData:t,secondData:n})=>[`Duplicate node id ${e}. Row IDs are provided via the getRowId() callback. Please modify the getRowId() callback code to provide unique row id values.`,"first instance",t,"second instance",n],188:e=>`getRowId callback must be provided for Server Side Row Model ${e?.feature||"selection"} to work correctly.`,189:({startRow:e})=>`invalid value ${e} for startRow, the value should be >= 0`,190:({rowGroupId:e,data:t})=>["null and undefined values are not allowed for server side row model keys",e?`column = ${e}`:"","data is ",t],194:({method:e})=>`calling gridApi.${e}() is only possible when using rowModelType=\`clientSide\`.`,195:({justCurrentPage:e})=>`selecting just ${e?"current page":"filtered"} only works when gridOptions.rowModelType='clientSide'`,196:({key:e})=>`Provided ids must be of string type. Invalid id provided: ${e}`,197:()=>"`toggledNodes` must be an array of string ids.",199:()=>"getSelectedNodes and getSelectedRows functions cannot be used with select all functionality with the server-side row model. Use `api.getServerSideSelectionState()` instead.",200:fj,201:({rowModelType:e})=>`Could not find row model for rowModelType = ${e}`,202:()=>"`getSelectedNodes` and `getSelectedRows` functions cannot be used with `groupSelectsChildren` and the server-side row model. Use `api.getServerSideSelectionState()` instead.",203:()=>"Server Side Row Model does not support Dynamic Row Height and Cache Purging. Either a) remove getRowHeight() callback or b) remove maxBlocksInCache property. Purging has been disabled.",204:()=>"Server Side Row Model does not support Auto Row Height and Cache Purging. Either a) remove colDef.autoHeight or b) remove maxBlocksInCache property. Purging has been disabled.",205:({duplicateIdText:e})=>`Unable to display rows as duplicate row ids (${e}) were returned by the getRowId callback. Please modify the getRowId callback to provide unique ids.`,206:()=>"getRowId callback must be implemented for transactions to work. Transaction was ignored.",207:()=>'The Set Filter Parameter "defaultToNothingSelected" value was ignored because it does not work when "excelMode" is used.',208:()=>"Set Filter Value Formatter must return string values. Please ensure the Set Filter Value Formatter returns string values for complex objects.",209:()=>`Set Filter Key Creator is returning null for provided values and provided values are primitives. Please provide complex objects. See ${o5}/filter-set-filter-list/#filter-value-types`,210:()=>"Set Filter has a Key Creator, but provided values are primitives. Did
407you mean to provide complex objects?",211:()=>"property treeList=true for Set Filter params, but you did not provide a treeListPathGetter or values of type Date.",212:()=>"please review all your toolPanel components, it seems like at least one of them doesn't have an id",213:()=>"Advanced Filter does not work with Filters Tool Panel. Filters Tool Panel has been disabled.",214:({key:e})=>`unable to lookup Tool Panel as invalid key supplied: ${e}`,215:({key:e,defaultByKey:t})=>`the key ${e} is not a valid key for specifying a tool panel, valid keys are: ${Object.keys(t??{}).join(",")}`,216:({name:e})=>`Missing component for '${e}'`,217:({invalidColIds:e})=>["unable to find grid columns for the supplied colDef(s):",e],218:({property:e,defaultOffset:t})=>`${e} must be a number, the value you provided is not a valid number. Using the default of ${t}px.`,219:({property:e})=>`Property ${e} does not exist on the target object.`,220:({lineDash:e})=>`'${e}' is not a valid 'lineDash' option.`,221:()=>"agAggregationComponent should only be used with the client and server side row model.",222:()=>"agFilteredRowCountComponent should only be used with the client side row model.",223:()=>"agSelectedRowCountComponent should only be used with the client and server side row model.",224:()=>"agTotalAndFilteredRowCountComponent should only be used with the client side row model.",225:()=>"agTotalRowCountComponent should only be used with the client side row model.",226:()=>"viewport is missing init method.",227:()=>"menu item icon must be DOM node or string",228:({menuItemOrString:e})=>`unrecognised menu item ${e}`,229:({index:e})=>["invalid row index for ensureIndexVisible: ",e],230:()=>"detailCellRendererParams.template is not supported by AG Grid React. To change the template, provide a Custom Detail Cell Renderer. See https://www.ag-grid.com/react-data-grid/master-detail-custom-detail/",231:()=>"As of v32, using custom components with `reactiveCustomComponents = false` is deprecated.",232:()=>"Using both rowData and v-model. rowData will be ignored.",233:({methodName:e})=>`Framework component is missing the method ${e}()`,234:()=>'Group Column Filter does not work with the colDef property "field". This property will be ignored.',235:()=>'Group Column Filter does not work with the colDef property "filterValueGetter". This property will be ignored.',236:()=>'Group Column Filter does not work with the colDef property "filterParams". This property will be ignored.',237:()=>"Group Column Filter does not work with Tree Data enabled. Please disable Tree Data, or use a different filter.",238:()=>"setRowCount can only accept a positive row count.",239:()=>'Theming API and CSS File Themes are both used in the same page. In v33 we released the Theming API as the new default method of styling the grid. See the migration docs https://www.ag-grid.com/react-data-grid/theming-migration/. Because no value was provided to the `theme` grid option it defaulted to themeQuartz. But the file (ag-grid.css) is also included and will cause styling issues. Either pass the string "legacy" to the theme grid option to use v32 style themes, or remove ag-grid.css from the page to use Theming API.',240:({theme:e})=>`theme grid option must be a Theming API theme object or the string "legacy", received: ${e}`,243:()=>"Failed to deserialize state - each provided state object must be an object.",244:()=>"Failed to deserialize state - `selectAllChildren` must be a boolean value or undefined.",245:()=>"Failed to deserialize state - `toggledNodes` must be an array.",246:()=>"Failed to deserialize state - Every `toggledNode` requires an associated string id.",247:()=>`Row selection state could not be parsed due to invalid data. Ensure all child state has toggledNodes or does not conform with the parent rule. 408Please rebuild the selection state and reapply it.`,248:()=>"SetFloatingFilter expects SetFilter as its parent",249:()=>"Must supply a Value Formatter in Set Filter params when using a Key Creator",250:()=>"Must supply a Key Creator in Set Filter params when `treeList = true` on a group column, and Tree Data or Row Grouping is enabled.",251:({chartType:e})=>
408`AG Grid: Unable to create chart as an invalid chartType = '${e}' was supplied.`,252:()=>"cannot get grid to draw rows when it is in the middle of drawing rows. \nYour code probably called a grid API method while the grid was in the render stage. \nTo overcome this, put the API call into a timeout, e.g. instead of api.redrawRows(), call setTimeout(function() { api.redrawRows(); }, 0). \nTo see what part of your code that caused the refresh check this stacktrace.",253:({version:e})=>["Illegal version string: ",e],254:()=>"Cannot create chart: no chart themes available.",255:({point:e})=>`Lone surrogate U+${e?.toString(16).toUpperCase()} is not a scalar value`,256:()=>"Unable to initialise. See validation error, or load ValidationModule if missing.",257:()=>fV("IntegratedChartsModule"),258:()=>fV("SparklinesModule"),259:({part:e})=>`the argument to theme.withPart must be a Theming API part object, received: ${e}`,260:({propName:e,compName:t,gridScoped:n,gridId:i,rowModelType:r})=>fj({reasonOrId:`AG Grid '${e}' component: ${t}`,moduleName:pC[t],gridId:i,gridScoped:n,rowModelType:r}),261:()=>"As of v33, `column.isHovered()` is deprecated. Use `api.isColumnHovered(column)` instead.",262:()=>'As of v33, icon key "smallDown" is deprecated. Use "advancedFilterBuilderSelect" for Advanced Filter Builder dropdown, "selectOpen" for Select cell editor and dropdowns (e.g. Integrated Charts menu), "richSelectOpen" for Rich Select cell editor.',263:()=>'As of v33, icon key "smallLeft" is deprecated. Use "panelDelimiterRtl" for Row Group Panel / Pivot Panel, "subMenuOpenRtl" for sub-menus.',264:()=>'As of v33, icon key "smallRight" is deprecated. Use "panelDelimiter" for Row Group Panel / Pivot Panel, "subMenuOpen" for sub-menus.',265:({colId:e})=>`Unable to infer chart data type for column '${e}' if first data entry is null. Please specify "chartDataType", or a "cellDataType" in the column definition. For more information, see ${o5}/integrated-charts-range-chart#coldefchartdatatype .`,266:()=>'As of v33.1, using "keyCreator" with the Rich Select Editor has been deprecated. It now requires the "formatValue" callback to convert complex data to strings.',267:()=>"Detail grids can not use a different theme to the master grid, the `theme` detail grid option will be ignored.",268:()=>"Transactions aren't supported with tree data when using treeDataChildrenField",269:()=>"When `masterSelects: 'detail'`, detail grids must be configured with multi-row selection",270:({id:e,parentId:t})=>`Cycle detected for row with id='${e}' and parent id='${t}'. Resetting the parent for row with id='${e}' and showing it as a root-level node.`,271:({id:e,parentId:t})=>`Parent row not found for row with id='${e}' and parent id='${t}'. Showing row with id='${e}' as a root-level node.`,272:()=>fN(),273:({providedId:e,usedId:t})=>`Provided column id '${e}' was already in use, ensure all column and group ids are unique. Using '${t}' instead.`,274:({prop:e})=>{let t=`Since v33, ${e} has been deprecated.`;switch(e){case"maxComponentCreationTimeMs":t+=" This property is no longer required and so will be removed in a future version.";break;case"setGridApi":t+=" This method is not called by AG Grid. To access the GridApi see: https://ag-grid.com/react-data-grid/grid-interface/#grid-api ";break;case"children":t+=" For multiple versions AgGridReact does not support children."}return t},275:fz,276:()=>"Row Numbers Row Resizer cannot be used when Grid Columns have `autoHeight` enabled.",277:({colId:e})=>`'enableFilterHandlers' is set to true, but column '${e}' does not have 'filter.doesFilterPass' or 'filter.handler' set.`,278:({colId:e})=>`Unable to create filter handler for column '${e}'`,279:e=>{},280:({colId:e})=>`'name' must be provided for custom filter components for column '${e}`,281:({colId:e})=>`Filter for column '${e}' does not have 'filterParams.buttons', but the new Filters Tool Panel has buttons configured. Either configure buttons for the filter, or disable buttons on the Filters Tool Panel.`,282:()=>"New filter tool panel requires `enableFilterHandlers: true`.",283:()=>"As of v34, use the same method on the filter handler (`api.getColumnFilterHandler(colKey)`) instead.",284:()=>"As of v34, filters are active when they have a model. Use `api.getColumnFilterModel()` instead.",285:()=>"As of v34, use (`api.getColumnFilterModel()`) instead.",286:()=>"As of v34, use (`api.setColumnFilterModel()`) instead.",287:()=>"`api.doFilterAction()` requires `enableFilterHandlers = true",288:()=>"`api.getColumnFilterModel(key, true)` requires `enableFilterHandlers = true",289:({rowModelType:e})=>`Row Model '${e}' is not supported with Batch Editing`,290:({rowIndex:e,rowPinned:t})=>`Row with index '${e}' and pinned state '${t}' not found`,291:()=>"License Key being set multiple times with different values. This can result in an incorrect license key being used,",292:({colId:e})=>`The Multi Filter for column '${e}' has buttons configured against the child filters. When 'enableFilterHandlers=true', buttons must instead be provided against the parent Multi Filter params. The child filter buttons will be ignored.`};function fG(e,t){let n=fH[e];if(!n)return[`Missing error text for error id ${e}!`];let i=n(t),r=o9(e,t),o=` 409See ${r}`;return Array.isArray(i)?i.concat(o):[i,o]}var fW={1:"Charting Aggregation",2:"pivotResultFields",3:"setTooltip"},f$=new WeakMap,fU=new WeakMap,fq=1,fK=class{create(e,t,n,i,r,o){let a=oV.applyGlobalGridOptions(t),s=a.gridId??String(fq++),l=this.getRegisteredModules(r,s,a.rowModelType),d=this.createBeansList(a.rowModelType,l,s),u=this.createProvidedBeans(e,a,r);if(!d)return;
409let c=new dv({providedBeanInstances:u,beanClasses:d,id:s,beanInitComparator:cH,beanDestroyComparator:cG,derivedBeans:[cj],destroyCallback:()=>{fU.delete(h),f$.delete(e),delete oZ[s],o?.()}});this.registerModuleFeatures(c,l),n(c),c.getBean("syncSvc").start(),i?.(c);let h=c.getBean("gridApi");return f$.set(e,h),fU.set(h,e),h}getRegisteredModules(e,t,n){var i;let r;return oQ(fP,void 0,!0),e?.modules?.forEach(e=>oQ(e,t)),i=fY(n),r=oZ[t]??{},[...Object.values(oY.all??{}),...Object.values(r.all??{}),...Object.values(oY[i]??{}),...Object.values(r[i]??{})]}registerModuleFeatures(e,t){let n=e.getBean("registry"),i=e.getBean("apiFunctionSvc");for(let e of t){n.registerModule(e);let t=e.apiFunctions;if(t)for(let e of Object.keys(t))i?.addFunction(e,t[e])}}createProvidedBeans(e,t,n){let i=n?n.frameworkOverrides:null;rS(i)&&(i=new cz);let r={gridOptions:t,eGridDiv:e,eRootDiv:e,globalListener:n?n.globalListener:null,globalSyncListener:n?n.globalSyncListener:null,frameworkOverrides:i};return n?.providedBeanInstances&&Object.assign(r,n.providedBeanInstances),r}createBeansList(e,t,n){let i={clientSide:"ClientSideRowModel",infinite:"InfiniteRowModel",serverSide:"ServerSideRowModel",viewport:"ViewportRowModel"},r=fY(e),o=i[r];if(!o)return void ai(201,{rowModelType:r},`Unknown rowModelType ${r}.`);if(!oX)return void ai(272,void 0,fN());if(!e){let e=Object.entries(i).filter(([e,t])=>o0(t,n,e));if(1==e.length){let[t,n]=e[0];if(t!==r){let e={moduleName:n,rowModelType:t};ai(275,e,fz(e));return}}}if(!o0(o,n,r))return void ai(200,{reasonOrId:`rowModelType = '${r}'`,moduleName:o,gridScoped:oJ,gridId:n,rowModelType:r},`Missing module ${o}Module for rowModelType ${r}.`);let a=new Set;for(let e of t)for(let t of e.beans??[])a.add(t);return Array.from(a)}};function fY(e){return e??"clientSide"}var fZ=class{wrap(e,t,n,i){let r=this.createWrapper(e,i);for(let e of t??[])this.createMethod(r,e,!0);for(let e of n??[])this.createMethod(r,e,!1);return r}createMethod(e,t,n){e.addMethod(t,this.createMethodProxy(e,t,n))}createMethodProxy(e,t,n){return function(){return e.hasMethod(t)?e.callMethod(t,arguments):(n&&at(49,{methodName:t}),null)}}},fX=class extends oI{getFileName(e){let t=this.getDefaultFileExtension();return e?.length||(e=this.getDefaultFileName()),e.includes(".")?e:`${e}.${t}`}getData(e){let t=this.createSerializingSession(e);return this.beans.gridSerializer.serialize(t,e)}getDefaultFileName(){return`export.${this.getDefaultFileExtension()}`}},fJ=class{constructor(e){const{colModel:t,rowGroupColsSvc:n,colNames:i,valueSvc:r,gos:o,processCellCallback:a,processHeaderCallback:s,processGroupHeaderCallback:l,processRowGroupCallback:d}=e;this.colModel=t,this.rowGroupColsSvc=n,this.colNames=i,this.valueSvc=r,this.gos=o,this.processCellCallback=a,this.processHeaderCallback=s,this.processGroupHeaderCallback=l,this.processRowGroupCallback=d}prepare(e){}extractHeaderValue(e){return this.getHeaderName(this.processHeaderCallback,e)??""}extractRowCellValue(e,t,n,i,r){let o=0===t&&aw(this.gos,r,this.colModel.isPivotMode());if(this.processRowGroupCallback&&(this.gos.get("treeData")||r.group)&&(e.isRowGroupDisplayed(r.rowGroupColumn?.getColId()??"")||o))return{value:this.processRowGroupCallback(aN(this.gos,{column:e,node:r}))??""};if(this.processCellCallback)return{value:this.processCellCallback(aN(this.gos,{accumulatedRowIndex:n,column:e,node:r,value:this.valueSvc.getValueForDisplay(e,r,void 0,void 0).value,type:i,parseValue:t=>this.valueSvc.parseValue(e,r,t,this.valueSvc.getValue(e,r,void 0)),formatValue:t=>this.valueSvc.formatValue(e,r,t)??t}))??""};let a=this.gos.get("treeData"),s=this.valueSvc,l=-1===r.level&&r.footer,d=!0===e.colDef.showRowGroup&&(r.group||a);if(!l&&(o||d)){let t="",n=r;for(;n&&-1!==n.level;){let{value:i,valueFormatted:r}=s.getValueForDisplay(o?void 0:e,n,!0,!0);t=` -> ${r??i??""}${t}`,n=n.parent}return{value:t,valueFormatted:t}}let{value:u,valueFormatted:c}=s.getValueForDisplay(e,r,!0,!0);return{value:u??"",valueFormatted:c}}getHeaderName(e,t){return e?e(aN(this.gos,{column:t})):this.colNames.getDisplayNameForColumn(t,"csv",!0)}},fQ={enableBrowserTooltips:!0,tooltipTrigger:!0,tooltipMouseTrack:!0,tooltipShowMode:!0,tooltipInteraction:!0,defaultColGroupDef:!0,suppressAutoSize:!0,skipHeaderOnAutoSize:!0,autoSizeStrategy:!0,components:!0,stopEditingWhenCellsLoseFocus:!0,undoRedoCellEditing:!0,undoRedoCellEditingLimit:!0,excelStyles:!0,cacheQuickFilter:!0,customChartThemes:!0,chartThemeOverrides:!0,chartToolPanelsDef:!0,loadingCellRendererSelector:!0,localeText:!0,keepDetailRows:!0,keepDetailRowsCount:!0,detailRowHeight:!0,detailRowAutoHeight:!0,tabIndex:!0,valueCache:!0,valueCacheNeverExpires:!0,enableCellExpressions:!0,suppressTouch:!0,suppressBrowserResizeObserver:!0,suppressPropertyNamesCheck:!0,debug:!0,dragAndDropImageComponent:!0,loadingOverlayComponent:!0,suppressLoadingOverlay:!0,noRowsOverlayComponent:!0,paginationPageSizeSelector:!0,paginateChildRows:!0,pivotPanelShow:!0,pivotSuppressAutoColumn:!0,suppressExpandablePivotGroups:!0,aggFuncs:!0,allowShowChangeAfterFilter:!0,ensureDomOrder:!0,enableRtl:!0,suppressColumnVirtualisation:!0,suppressMaxRenderedRowRestriction:!0,suppressRowVirtualisation:!0,rowDragText:!0,groupLockGroupColumns:!0,suppressGroupRowsSticky:!0,rowModelType:!0,cacheOverflowSize:!0,infiniteInitialRowCount:!0,serverSideInitialRowCount:!0,maxBlocksInCache:!0,maxConcurrentDatasourceRequests:!0,blockLoadDebounceMillis:!0,serverSideOnlyRefreshFilteredGroups:!0,serverSidePivotResultFieldSeparator:!0,viewportRowModelPageSize:!0,viewportRowModelBufferSize:!0,debounceVerticalScrollbar:!0,suppressAnimationFrame:!0,suppressPreventDefaultOnMouseWheel:!0,scrollbarWidth:!0,icons:!0,suppressRowTransform:!0,gridId:!0,enableGroupEdit:!0,initialState:!0,processUnpinnedColumns:!0,createChartContainer:!0,getLocaleText:!0,getRowId:!0,reactiveCustomComponents:!0,renderingMode:!0,columnMenu:!0,suppressSetFilterByDefault:!0,getDataPath:!0,enableCellSpan:!0,enableFilterHandlers:!0,filterHandlers:!0},f0="clientSide",f1="serverSide",f2="infinite",f3={onGroupExpandedOrCollapsed:[f0],refreshClientSideRowModel:[f0],isRowDataEmpty:[f0],forEac
vendor: 5,423 bytes, line 409
409hLeafNode:[f0],forEachNodeAfterFilter:[f0],forEachNodeAfterFilterAndSort:[f0],resetRowHeights:[f0,f1],applyTransaction:[f0],applyTransactionAsync:[f0],flushAsyncTransactions:[f0],getBestCostNodeSelection:[f0],getServerSideSelectionState:[f1],setServerSideSelectionState:[f1],applyServerSideTransaction:[f1],applyServerSideTransactionAsync:[f1],applyServerSideRowData:[f1],retryServerSideLoads:[f1],flushServerSideAsyncTransactions:[f1],refreshServerSide:[f1],getServerSideGroupLevelState:[f1],refreshInfiniteCache:[f2],purgeInfiniteCache:[f2],getInfiniteRowCount:[f2],isLastRowIndexKnown:[f2,f1],expandAll:[f0,f1],collapseAll:[f0,f1],onRowHeightChanged:[f0,f1],setRowCount:[f2,f1],getCacheBlockState:[f2,f1]},f5={showLoadingOverlay:{version:"v32",message:'`showLoadingOverlay` is deprecated. Use the grid option "loading"=true instead or setGridOption("loading", true).'},clearRangeSelection:{version:"v32.2",message:"Use `clearCellSelection` instead."},getInfiniteRowCount:{version:"v32.2",old:"getInfiniteRowCount()",new:"getDisplayedRowCount()"},selectAllFiltered:{version:"v33",old:"selectAllFiltered()",new:'selectAll("filtered")'},deselectAllFiltered:{version:"v33",old:"deselectAllFiltered()",new:'deselectAll("filtered")'},selectAllOnCurrentPage:{version:"v33",old:"selectAllOnCurrentPage()",new:'selectAll("currentPage")'},deselectAllOnCurrentPage:{version:"v33",old:"deselectAllOnCurrentPage()",new:'deselectAll("currentPage")'}},f4={detailCellRendererCtrl:"SharedMasterDetail",dndSourceComp:"DragAndDrop",fillHandle:"CellSelection",groupCellRendererCtrl:"GroupCellRenderer",headerFilterCellCtrl:"ColumnFilter",headerGroupCellCtrl:"ColumnGroup",rangeHandle:"CellSelection",tooltipFeature:"Tooltip",highlightTooltipFeature:"Tooltip",tooltipStateManager:"Tooltip",groupStrategy:"RowGrouping",treeGroupStrategy:"TreeData",rowNumberRowResizer:"RowNumbers",singleCell:"EditCore",fullRow:"EditCore",agSetColumnFilterHandler:"SetFilter",agMultiColumnFilterHandler:"MultiFilter",agGroupColumnFilterHandler:"GroupFilter",agNumberColumnFilterHandler:"NumberFilter",agDateColumnFilterHandler:"DateFilter",agTextColumnFilterHandler:"TextFilter"},f6={expanded:1,contracted:1,"tree-closed":1,"tree-open":1,"tree-indeterminate":1,pin:1,"eye-slash":1,arrows:1,left:1,right:1,group:1,aggregation:1,pivot:1,"not-allowed":1,chart:1,cross:1,cancel:1,tick:1,first:1,previous:1,next:1,last:1,linked:1,unlinked:1,"color-picker":1,loading:1,menu:1,"menu-alt":1,filter:1,"filter-add":1,columns:1,maximize:1,minimize:1,copy:1,cut:1,paste:1,grip:1,save:1,csv:1,excel:1,"small-down":1,"small-left":1,"small-right":1,"small-up":1,asc:1,desc:1,none:1,up:1,down:1,plus:1,minus:1,settings:1,"checkbox-checked":1,"checkbox-indeterminate":1,"checkbox-unchecked":1,"radio-button-on":1,"radio-button-off":1,eye:1,"column-arrow":1,"un-pin":1,"pinned-top":1,"pinned-bottom":1,"chevron-up":1,"chevron-down":1,"chevron-left":1,"chevron-right":1,edit:1},f8={chart:"MenuCore",cancel:"EnterpriseCore",first:"Pagination",previous:"Pagination",next:"Pagination",last:"Pagination",linked:"IntegratedCharts",loadingMenuItems:"MenuCore",unlinked:"IntegratedCharts",menu:"ColumnHeaderComp",legacyMenu:"ColumnMenu",filter:"ColumnFilter",filterActive:"ColumnFilter",filterAdd:"NewFiltersToolPanel",filterCardCollapse:"NewFiltersToolPanel",filterCardExpand:"NewFiltersToolPanel",filterCardEditing:"NewFiltersToolPanel",filterTab:"ColumnMenu",filtersToolPanel:"FiltersToolPanel",columns:["MenuCore"],columnsToolPanel:["ColumnsToolPanel"],maximize:"EnterpriseCore",minimize:"EnterpriseCore",save:"MenuCore",columnGroupOpened:"ColumnGroupHeaderComp",columnGroupClosed:"ColumnGroupHeaderComp",accordionOpen:"EnterpriseCore",accordionClosed:"EnterpriseCore",accordionIndeterminate:"EnterpriseCore",columnSelectClosed:["ColumnsToolPanel","ColumnMenu"],columnSelectOpen:["ColumnsToolPanel","ColumnMenu"],columnSelectIndeterminate:["ColumnsToolPanel","ColumnMenu"],columnMovePin:"SharedDragAndDrop",columnMoveHide:"SharedDragAndDrop",columnMoveMove:"SharedDragAndDrop",columnMoveLeft:"SharedDragAndDrop",columnMoveRight:"SharedDragAndDrop",columnMoveGroup:"SharedDragAndDrop",columnMoveValue:"SharedDragAndDrop",columnMovePivot:"SharedDragAndDrop",dropNotAllowed:"SharedDragAndDrop",ensureColumnVisible:["ColumnsToolPanel","ColumnMenu"],groupContracted:"GroupCellRenderer",groupExpanded:"GroupCellRenderer",setFilterGroupClosed:"SetFilter",setFilterGroupOpen:"SetFilter",setFilterGroupIndeterminate:"SetFilter",setFilterLoading:"SetFilter",close:"EnterpriseCore",check:"MenuItem",colorPicker:"CommunityCore",groupLoading:"LoadingCellRenderer",menuAlt:"ColumnHeaderComp",menuPin:"MenuCore",menuValue:"MenuCore",menuAddRowGroup:["MenuCore","ColumnsToolPanel"],menuRemoveRowGroup:["MenuCore","ColumnsToolPanel"],clipboardCopy:"MenuCore",clipboardCut:"MenuCore",clipboardPaste:"MenuCore",pivotPanel:["ColumnsToolPanel","RowGroupingPanel"],rowGroupPanel:["ColumnsToolPanel","RowGroupingPanel"],valuePanel:"ColumnsToolPanel",columnDrag:"EnterpriseCore",rowDrag:["RowDrag","DragAndDrop"],csvExport:"MenuCore",excelExport:"MenuCore",smallDown:"CommunityCore",selectOpen:"CommunityCore",richSelectOpen:"RichSelect",richSelectRemove:"RichSelect",smallLeft:"CommunityCore",smallRight:"CommunityCore",subMenuOpen:"MenuItem",subMenuOpenRtl:"MenuItem",panelDelimiter:"RowGroupingPanel",panelDelimiterRtl:"RowGroupingPanel",smallUp:"CommunityCore",sortAscending:["MenuCore","Sort"],sortDe
409scending:["MenuCore","Sort"],sortUnSort:["MenuCore","Sort"],advancedFilterBuilder:"AdvancedFilter",advancedFilterBuilderDrag:"AdvancedFilter",advancedFilterBuilderInvalid:"AdvancedFilter",advancedFilterBuilderMoveUp:"AdvancedFilter",advancedFilterBuilderMoveDown:"AdvancedFilter",advancedFilterBuilderAdd:"AdvancedFilter",advancedFilterBuilderRemove:"AdvancedFilter",advancedFilterBuilderSelectOpen:"AdvancedFilter",chartsMenu:"IntegratedCharts",chartsMenuEdit:"IntegratedCharts",chartsMenuAdvancedSettings:"IntegratedCharts",chartsMenuAdd:"IntegratedCharts",chartsColorPicker:"IntegratedCharts",chartsThemePrevious:"IntegratedCharts",chartsThemeNext:"IntegratedCharts",chartsDownload:"IntegratedCharts",checkboxChecked:"CommunityCore",checkboxIndeterminate:"CommunityCore",checkboxUnchecked:"CommunityCore",radioButtonOn:"CommunityCore",radioButtonOff:"CommunityCore",rowPin:"PinnedRow",rowUnpin:"PinnedRow",rowPinBottom:"PinnedRow",rowPinTop:"PinnedRow"},f7=new Set(["colorPicker","smallUp","checkboxChecked","checkboxIndeterminate","checkboxUnchecked","radioButtonOn","radioButtonOff","smallDown","smallLeft","smallRight"]),f9=class extends oI{constructor(){super(...arguments),this.beanName="validation"}wireBeans(e){this.gridOptions=e.gridOptions,o3=fG}warnOnInitialPropertyUpdate(e,t){"api"===e&&fQ[t]&&at(22,{key:t})}processGridOptions(e){this.processOptions(e,{objectName:"gridOptions",allProperties:[...pD,...pT,...pM,...pR,...pE,...pP,...pA,...pI,...Object.values(pg)],propertyExceptions:["api"],docsUrl:"grid-options/",deprecations:{suppressLoadingOverlay:{version:"32",message:"Use `loading`=false instead."},enableFillHandle:{version:"32.2",message:"Use `cellSelection.handle` instead."},enableRangeHandle:{version:"32.2",message:"Use `cellSelection.handle` instead."},enableRangeSelection:{version:"32.2",message:"Use `cellSelection = true` instead."},suppressMultiRangeSelection:{version:"32.2",message:"Use `cellSelection.suppressMultiRanges` instead."},suppressClearOnFillReduction:{version:"32.2",message:"Use `cellSelection.handle.suppressClearOnFillReduction` instead."},fillHandleDirection:{version:"32.2",message:"Use `cellSelection.handle.direction` instead."},fillOperation:{version:"32.2",message:"Use `cellSelection.handle.setFillValue` instead."},suppressRowClickSelection:{version:"32.2",message:"Use `rowSelection.enableClickSelection` instead."},suppressRowDeselection:{version:"32.2",message:"Use `rowSelection.enableClickSelection` instead."},rowMultiSelectWithClick:{version:"32.2",message:"Use `rowSelection.enableSelectionWithoutKeys` instead."},groupSelectsChildren:{version:"32.2",message:'Use `rowSelection.groupSelects = "descendants"` instead.'},groupSelectsFiltered:{version:"32.2",message:'Use `rowSelection.groupSelects = "filteredDescendants"` instead.'},isRowSelectable:{version:"32.2",message:"Use `selectionOptions.isRowSelectable` instead."},suppressCopySingleCellRanges:{version:"32.2",message:"Use `rowSelection.copySelectedRows` instead."},suppressCopyRowsToClipboard:{version:"32.2",message:"Use `rowSelection.copySelectedRows` instead."},onRangeSelectionChanged:{version:"32.2",message:"Use `onCellSelectionChanged` instead."},onRangeDeleteStart:{version:"32.2",message:"Use `onCellSelectionDeleteStart` instead."},onRangeDeleteEnd:{version:"32.2",message:"Use `onCellSelectionDeleteEnd` instead."},suppressBrowserResizeObserver:{version:"32.2",message:"The grid always uses the browser's ResizeObserver, this grid option has no effect."},onColumnEverythingChanged:{version:"32.2",message:"Either use `onDisplayedColumnsChanged` which is fired at the same time, or use one of the more specific column events."},groupRemoveSingleChildren:{version:"33",message:"Use `groupHideParentOfSingleChild` instead."},groupRemoveLowestSingleChildren:{version:"33",message:'Use `groupHideParentOfSingleChild: "leafGroupsOnly"` instead.'},suppressRowGroupHidesColumns:{version:"33",message:'Use `suppressGroupChangesColumnVisibility: "suppressHideOnGroup"` instead.'},suppressMakeColumnVisibleAfterUnGroup:{version:"33",message:'Use `suppressGroupChangesColumnVisibility: "suppressShowOnUngroup"` instead.'},unSortIcon:{version:"33",message:"Use `defaultColDef.unSortIcon` instead."},sortingOrder:{version:"33",message:"Use `defaultColDef.sortingOrder` instead."},suppressPropertyNamesCheck:{version:"33",message:"`gridOptions` and `columnDefs` both have a `context` property that should be used for arbitrary user data. This means that column definitions and gridOptions should only contain valid properties making this property redundant."},suppressAdvancedFilterEval:{version:"34",message:"Advanced filter no longer uses function evaluation, so this option has no effect."}},validations:(()=>{let e={autoSizePadding:{validate:({autoSizePadding:e})=>pL("autoSizePadding",e,0)},cacheBlockSize:{supportedRowModels:["serverSide","infinite"],validate:({cacheBlockSize:e})=>pL("cacheBlockSize",e,1)},cacheOverflowSize:{validate:({cacheOverflowSize:e})=>pL("cacheOverflowSize",e,1)}
vendor: 4,393 bytes, lines 409-410
409,datasource:{supportedRowModels:["infinite"]},domLayout:{validate:e=>{let t=e.domLayout,n=["autoHeight","normal","print"];return t&&!n.includes(t)?`domLayout must be one of [${n.join()}], currently it's ${t}`:null}},enableFillHandle:{dependencies:{enableRangeSelection:{required:[!0]}}},enableRangeHandle:{dependencies:{enableRangeSelection:{required:[!0]}}},enableRangeSelection:{dependencies:{rowDragEntireRow:{required:[!1,void 0]}}},enableRowPinning:{supportedRowModels:["clientSide"],validate:({enableRowPinning:e,pinnedTopRowData:t,pinnedBottomRowData:n})=>e&&(t||n)?"Manual row pinning cannot be used together with pinned row data. Either set `enableRowPinning` to `false`, or remove `pinnedTopRowData` and `pinnedBottomRowData`.":null},isRowPinnable:{supportedRowModels:["clientSide"],validate:({enableRowPinning:e,isRowPinnable:t,pinnedTopRowData:n,pinnedBottomRowData:i})=>t&&(n||i)?"Manual row pinning cannot be used together with pinned row data. Either remove `isRowPinnable`, or remove `pinnedTopRowData` and `pinnedBottomRowData`.":!e&&t?"`isRowPinnable` requires `enableRowPinning` to be set.":null},isRowPinned:{supportedRowModels:["clientSide"],validate:({enableRowPinning:e,isRowPinned:t,pinnedTopRowData:n,pinnedBottomRowData:i})=>t&&(n||i)?"Manual row pinning cannot be used together with pinned row data. Either remove `isRowPinned`, or remove `pinnedTopRowData` and `pinnedBottomRowData`.":!e&&t?"`isRowPinned` requires `enableRowPinning` to be set.":null},groupDefaultExpanded:{supportedRowModels:["clientSide"]},groupHideOpenParents:{supportedRowModels:["clientSide","serverSide"],dependencies:{groupTotalRow:{required:[void 0,"bottom"]},treeData:{required:[void 0,!1],reason:"Tree Data has values at the group level so it doesn't make sense to hide them."}}},groupHideParentOfSingleChild:{dependencies:{groupHideOpenParents:{required:[void 0,!1]}}},groupRemoveLowestSingleChildren:{dependencies:{groupHideOpenParents:{required:[void 0,!1]},groupRemoveSingleChildren:{required:[void 0,!1]}}},groupRemoveSingleChildren:{dependencies:{groupHideOpenParents:{required:[void 0,!1]},groupRemoveLowestSingleChildren:{required:[void 0,!1]}}},groupSelectsChildren:{dependencies:{rowSelection:{required:["multiple"]}}},groupHierarchyConfig:{validate({groupHierarchyConfig:e={}},t,n){for(let t of Object.keys(e))n.validation?.validateColDef(e[t]);return null}},icons:{validate:({icons:e})=>{if(e){if(e.smallDown)return ar(262);if(e.smallLeft)return ar(263);if(e.smallRight)return ar(264)}return null}},infiniteInitialRowCount:{validate:({infiniteInitialRowCount:e})=>pL("infiniteInitialRowCount",e,1)},initialGroupOrderComparator:{supportedRowModels:["clientSide"]},ssrmExpandAllAffectsAllRows:{validate:e=>{if("boolean"==typeof e.ssrmExpandAllAffectsAllRows){if("serverSide"!==e.rowModelType)return"'ssrmExpandAllAffectsAllRows' is only supported with the Server Side Row Model.";if(e.ssrmExpandAllAffectsAllRows&&"function"!=typeof e.getRowId)return"'getRowId' callback must be provided for Server Side Row Model grouping to work correctly."}return null}},keepDetailRowsCount:{validate:({keepDetailRowsCount:e})=>pL("keepDetailRowsCount",e,1)},paginationPageSize:{validate:({paginationPageSize:e})=>pL("paginationPageSize",e,1)},paginationPageSizeSelector:{validate:e=>{let t=e.paginationPageSizeSelector;return"boolean"==typeof t||null==t||t.length?null:`'paginationPageSizeSelector' cannot be an empty array. 410 If you want to hide the page size selector, set paginationPageSizeSelector to false.`}},pivotMode:{dependencies:{treeData:{required:[!1,void 0],reason:"Pivot Mode is not supported with Tree Data."}}},quickFilterText:{supportedRowModels:["clientSide"]},rowBuffer:{validate:({rowBuffer:e})=>pL("rowBuffer",e,0)},rowClass:{validate:e=>"function"==typeof e.rowClass?"rowClass should not be a function, please use getRowClass instead":null},rowData:{supportedRowModels:["clientSide"]},rowDragManaged:{supportedRowModels:["clientSide"],dependencies:{pagination:{required:[!1,void 0]}}},rowSelection:{validate:({rowSelection:e})=>e&&"string"==typeof e?'As of version 32.2.1, using `rowSelection` with the values "single" or "multiple" has been deprecated. Use the object value instead.':e&&"object"!=typeof e?"Expected `RowSelectionOptions` object for the `rowSelection` property.":e&&"multiRow"!==e.mode&&"singleRow"!==e.mode?`Selection mode "${e.mode}
410" is invalid. Use one of 'singleRow' or 'multiRow'.`:null},rowStyle:{validate:e=>{let t=e.rowStyle;return t&&"function"==typeof t?"rowStyle should be an object of key/value styles, not be a function, use getRowStyle() instead":null}},serverSideDatasource:{supportedRowModels:["serverSide"]},serverSideInitialRowCount:{supportedRowModels:["serverSide"],validate:({serverSideInitialRowCount:e})=>pL("serverSideInitialRowCount",e,1)},serverSideOnlyRefreshFilteredGroups:{supportedRowModels:["serverSide"]},serverSideSortAllLevels:{supportedRowModels:["serverSide"]},sortingOrder:{validate:e=>{let t=e.sortingOrder;if(Array.isArray(t)&&t.length>0){let e=t.filter(e=>!px.includes(e));if(e.length>0)return`sortingOrder must be an array with elements from [${px.map(o8).join()}], currently it includes [${e.map(o8).join()}]`}else if(!Array.isArray(t)||t.length<=0)return`sortingOrder must be an array with at least one element, currently it's ${t}`;return null}},tooltipHideDelay:{validate:e=>e.tooltipHideDelay&&e.tooltipHideDelay<0?"tooltipHideDelay should not be lower than 0":null},tooltipShowDelay:{validate:e=>e.tooltipShowDelay&&e.tooltipShowDelay<0?"tooltipShowDelay should not be lower than 0":null},treeData:{supportedRowModels:["clientSide","serverSide"],validate:e=>{let t=e.rowModelType??"clientSide";switch(t){case"clientSide":{let{treeDataChildrenField:t,treeDataParentIdField:n,getDataPath:i,getRowId:r}=e;if(!t&&!n&&!i)return"treeData requires either 'treeDataChildrenField' or 'treeDataParentIdField' or 'getDataPath' in the clientSide row model.";if(t){if(i)return"Cannot use both 'treeDataChildrenField' and 'getDataPath' at the same time.";if(n)return"Cannot use both 'treeDataChildrenField' and 'treeDataParentIdField' at the same time."}if(n){if(!r)return"getRowId callback not provided, tree data with parent id cannot be built.";if(i)return"Cannot use both 'treeDataParentIdField' and 'getDataPath' at the same time."}break}case"serverSide":{let n=`treeData requires 'isServerSideGroup' and 'getServerSideGroupKey' in the ${t} row model.`;return e.isServerSideGroup&&e.getServerSideGroupKey?null:n}}return null}},viewportDatasource:{supportedRowModels:["viewport"]},viewportRowModelBufferSize:{validate:({viewportRowModelBufferSize:e})=>pL("viewportRowModelBufferSize",e,0)},viewportRowModelPageSize:{validate:({viewportRowModelPageSize:e})=>pL("viewportRowModelPageSize",e,1)},rowDragEntireRow:{dependencies:{cellSelection:{required:[void 0]}}},autoGroupColumnDef:{validate:({autoGroupColumnDef:e,showOpenedGroup:t})=>e?.field&&t?"autoGroupColumnDef.field and showOpenedGroup are not supported when used together.":e?.valueGetter&&t?"autoGroupColumnDef.valueGetter and showOpenedGroup are not supported when used together.":null},renderingMode:{validate:e=>{let t=e.renderingMode,n=["default","legacy"];return t&&!n.includes(t)?`renderingMode must be one of [${n.join()}], currently it's ${t}`:null}},autoSizeStrategy:{validate:({autoSizeStrategy:e})=>{if(!e)return null;let t=e.type;return"fitCellContents"!==t&&"fitGridWidth"!==t&&"fitProvidedWidth"!==t?`Invalid Auto-size strategy. \`autoSizeStrategy\` must be one of ${["fitCellContents","fitGridWidth","fitProvidedWidth"].map(e=>'"'+e+'"').join(", ")}, currently it's ${t}`:"fitProvidedWidth"===t&&"number"!=typeof e.width?`When using the 'fitProvidedWidth' auto-size strategy, must provide a numeric \`width\`. You provided ${e.width}`:null}}},t={};for(let e of pP)t[e]={expectedType:"boolean"};for(let e of pR)t[e]={expectedType:"number"};return oz(t,e),t})()})}validateApiFunction(e,t){return function(e,t,n){let i=f5[e];if(i){let{version:n,new:r,old:o,message:a}=i,s=o??e;return(...e)=>{let i=r?`Please use ${r} instead. `:"";return oU(`Since ${n} api.${s} is deprecated. ${i}${a??""}`),t.apply(t,e)}}let r=f3[e];return r?(...i)=>{let o=n.rowModel.getType();return r.includes(o)?t.apply(t,i):void oq(`api.${e} can only be called when gridOptions.rowModelType is ${r.join(" or ")}`)}:t}(e,t,this.beans)}missingUserComponent(e,t,n,i){let r=pC[t];r?this.gos.assertModuleRegistered(r,`AG Grid '${e}' component: ${t}`):at(101,{propertyName:e,componentName:t,agGridDefaults:n,jsComps:i})}missingDynamicBean(e){let t=f4[e];
410return t?ar(200,{...this.gos.getModuleErrorParams(),moduleName:t,reasonOrId:e}):void 0}checkRowEvents(e){ge.has(e)&&at(10,{eventType:e})}validateIcon(e){if(f7.has(e)&&at(43,{iconName:e}),f6[e])return;let t=f8[e];t?an(200,{reasonOrId:`icon '${e}'`,moduleName:t,gridScoped:oJ,gridId:this.beans.context.getId(),rowModelType:this.gos.get("rowModelType"),additionalText:"Alternatively, use the CSS icon name directly."}):at(134,{iconName:e})}isProvidedUserComp(e){return!!pC[e]}validateColDef(e){this.processOptions(e,{objectName:"colDef",allProperties:Object.keys(pk),docsUrl:"column-properties/",deprecations:{checkboxSelection:{version:"32.2",message:"Use `rowSelection.checkboxes` in `GridOptions` instead."},headerCheckboxSelection:{version:"32.2",message:"Use `rowSelection.headerCheckbox = true` in `GridOptions` instead."},headerCheckboxSelectionFilteredOnly:{version:"32.2",message:'Use `rowSelection.selectAll = "filtered"` in `GridOptions` instead.'},headerCheckboxSelectionCurrentPageOnly:{version:"32.2",message:'Use `rowSelection.selectAll = "currentPage"` in `GridOptions` instead.'},showDisabledCheckboxes:{version:"32.2",message:"Use `rowSelection.hideDisabledCheckboxes = true` in `GridOptions` instead."},rowGroupingHierarchy:{version:"34.3",message:"Use `colDef.groupHierarchy` instead."}},validations:{autoHeight:{supportedRowModels:["clientSide","serverSide"],validate:(e,{paginationAutoPageSize:t})=>t?"colDef.autoHeight is not supported with paginationAutoPageSize.":null},cellRendererParams:{validate:e=>(null!=e.rowGroup||null!=e.rowGroupIndex||"agGroupCellRenderer"===e.cellRenderer)&&"checkbox"in e.cellRendererParams?'Since v33.0, `cellRendererParams.checkbox` has been deprecated. Use `rowSelection.checkboxLocation = "autoGroupColumn"` instead.':null},flex:{validate:(e,t)=>t.autoSizeStrategy?"colDef.flex is not supported with gridOptions.autoSizeStrategy":null},headerCheckboxSelection:{supportedRowModels:["clientSide","serverSide"],validate:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelection is only supported with rowSelection=multiple"},headerCheckboxSelectionCurrentPageOnly:{supportedRowModels:["clientSide"],validate:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelectionCurrentPageOnly is only supported with rowSelection=multiple"},headerCheckboxSelectionFilteredOnly:{supportedRowModels:["clientSide"],validate:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelectionFilteredOnly is only supported with rowSelection=multiple"},headerValueGetter:{validate:e=>{let t=e.headerValueGetter;return"function"==typeof t||"string"==typeof t?null:"headerValueGetter must be a function or a valid string expression"}},icons:{validate:({icons:e})=>{if(e){if(e.smallDown)return ar(262);if(e.smallLeft)return ar(263);if(e.smallRight)return ar(264)}return null}},sortingOrder:{validate:e=>{let t=e.sortingOrder;if(Array.isArray(t)&&t.length>0){let e=t.filter(e=>!px.includes(e));if(e.length>0)return`sortingOrder must be an array with elements from [${px.map(o8).join()}], currently it includes [${e.map(o8).join()}]`}else if(!Array.isArray(t)||t.length<=0)return`sortingOrder must be an array with at least one element, currently it's ${t}`;return null}},type:{validate:e=>{let t=e.type;return t instanceof Array?t.some(e=>"string"!=typeof e)?"if colDef.type is supplied an array it should be of type 'string[]'":null:"string"==typeof t?null:"colDef.type should be of type 'string' | 'string[]'"}},rowSpan:{validate:(e,{suppressRowTransform:t})=>t?null:"colDef.rowSpan requires suppressRowTransform to be enabled."},spanRows:{dependencies:{editable:{required:[!1,void 0]},rowDrag:{required:[!1,void 0]},colSpan:{required:[void 0]},rowSpan:{required:[void 0]}},validate:(e,{rowSelection:t,cellSelection:n,suppressRowTransform:i,enableCellSpan:r,rowDragEntireRow:o,enableCellTextSelection:a})=>"object"==typeof t&&t?.mode==="singleRow"&&t?.enableClickSelection?"colDef.spanRows is not supported with rowSelection.clickSelection":n?"colDef.spanRows is not supported with cellSelection.":i?"colDef.spanRows is not supported with suppressRowTransform.":r?o?"colDef.spanRows is not supported with rowDragEntireRow.":a?"colDef.spanRows is not supported with enableCellTextSelection.":null:"colDef.spanRows requires enableCellSpan to be enabled."},groupHierarchy:{validate(e,{groupHierarchyConfig:t={}},n){let i=new Set(["year","quarter","month","formattedMonth","day","hour","minute","second"]),r=[];for(let o of e.groupHierarchy??[]){if("object"==typeof o){n.validation?.validateColDef(o);continue}i.has(o)||o in t||r.push(pS(o))}if(r.length>0){let e=`The following parts of colDef.groupHierarchy are not recognised: ${r.join(", ")}.`,t=`Choose one of ${[...i].map(pS).join(", ")}, or define your own parts in gridOptions.groupHierarchyConfig.`;return`${e} 411${t}`}return null}}}})}processOptions(e,t){let{validations:n,deprecations:i,allProperties:r,propertyExceptions:o,objectName:a,docsUrl:s}=t;r&&!0!==this.gridOptions.suppressPropertyNamesCheck&&this.checkProperties(e,[...o??[],...Object.keys(i)],r,a,s);let l=new Set;if(Object.keys(e).forEach(t=>{let r=i[t];if(r){let{message:e,version:n}=r;l.add(`As of v${n}, ${String(t)} is deprecated. ${e??""}`)}let o=e[t];if(null==o||!1===o)return;let a=n[t];if(!a)return;let{dependencies:s,validate:d,supportedRowModels:u,expectedType:c}=a;if(c){let e=typeof o;if(e!==c)return void l.add(`${String(t)} should be of type '${c}' but received '${e}' (${o}).`)}if(u){let e=this.gridOptions.rowModelType??"clientSide";if(!u.includes(e))return void l.add(`${String(t)} is not supported with the '${e}' row model. It is only valid with: ${u.join(", ")}.`)}if(s){let n=this.checkForRequiredDependencies(t,s,e);if(n)return void l.add(n)}if(d){let t=d(e,this.gridOptions,this.beans);if(t)return void l.add(t)}}),l.size>0)for(let e of l)oU(e)}checkForRequiredDependencies(e,t,n){let i=Object.entries(t).filter(([e,t])=>{let i=n[e];return!t.required.includes(i)});return 0===i.length?null:i.map(([t,n])=>`'${String(e)}' requires '${t}' to be one of [${n.required.map(e=>null===e?"null":void 0===e?"undefined":e).join(", ")}]. ${n.reason??""}`).join("\n ")}checkProperties(e,t,n,i,r){let o=function(e,t,n){let i={},r=e.filter(e=>!t.some(t=>t===e));if(r.length>0)for(let e of r)i[e]=ly({inputValue:e,allSuggestions:n}).values;return i}(Object.getOwnPropertyNames(e),["__ob__","__v_skip","__metadata__",...t,...n],n),a=Object.keys(o);
411for(let e of a){let t=o[e],r=`invalid ${i} property '${e}' did you mean any of these: ${t.slice(0,8).join(", ")}.`;n.includes("context")&&(r+=` 412If you are trying to annotate ${i} with application data, use the '${i}.context' property instead.`),oU(r)}if(a.length>0&&r){let e=this.beans.frameworkOverrides.getDocLink(r);oU(`to see all the valid ${i} properties please check: ${e}`)}}},ge=new Set(["firstChildChanged","lastChildChanged","childIndexChanged"]),gt={moduleName:"Validation",version:o1,beans:[f9]};function gn(e){let t=e.sibling;t&&(t.childrenAfterFilter=e.childrenAfterFilter)}var gi=class extends oI{constructor(){super(...arguments),this.beanName="filterStage",this.step="filter",this.refreshProps=["excludeChildrenWhenTreeDataFiltering"]}wireBeans(e){this.filterManager=e.filterManager}execute(e){let{changedPath:t}=e;this.filter(t)}filter(e){let t=!!this.filterManager?.isChildFilterPresent();this.filterNodes(t,e)}filterNodes(e,t){let n=(t,n)=>{t.hasChildren()&&e&&!n?t.childrenAfterFilter=t.childrenAfterGroup.filter(e=>{let t=e.childrenAfterFilter&&e.childrenAfterFilter.length>0,n=e.data&&this.filterManager.doesRowPassFilter({rowNode:e});return t||n}):t.childrenAfterFilter=t.childrenAfterGroup,gn(t)};if(this.doingTreeDataFiltering()){let e=(t,i)=>{if(t.childrenAfterGroup)for(let r=0;r<t.childrenAfterGroup.length;r++){let o=t.childrenAfterGroup[r],a=i||this.filterManager.doesRowPassFilter({rowNode:o});o.childrenAfterGroup?e(t.childrenAfterGroup[r],a):n(o,a)}n(t,i)};t.executeFromRootNode(t=>e(t,!1))}else t.forEachChangedNodeDepthFirst(e=>n(e,!1),!0)}doingTreeDataFiltering(){return this.gos.get("treeData")&&!this.gos.get("excludeChildrenWhenTreeDataFiltering")}},gr=class extends ci{constructor(){super(...arguments),this.iconCreated=!1}wireComp(e,t,n,i,r){this.comp=e;let o=sx(this,this.beans.context,r);this.eButtonShowMainFilter=n,this.eFloatingFilterBody=i,this.setGui(t,o),this.setupActive(),this.refreshHeaderStyles(),this.setupWidth(o),this.setupLeft(o),this.setupHover(o),this.setupFocus(o),this.setupAria(),this.setupFilterButton(),this.setupUserComp(),this.setupSyncWithFilter(o),this.setupUi(),o.addManagedElementListeners(this.eButtonShowMainFilter,{click:this.showParentFilter.bind(this)}),this.setupFilterChangedListener(o);let a=()=>this.onColDefChanged(o);o.addManagedListeners(this.column,{colDefChanged:a}),o.addManagedEventListeners({filterSwitched:({column:e})=>{e===this.column&&a()}}),o.addDestroyFunc(()=>{this.eButtonShowMainFilter=null,this.eFloatingFilterBody=null,this.userCompDetails=null,this.clearComponent()})}resizeHeader(){}moveHeader(){}getHeaderClassParams(){let{column:e,beans:t}=this,n=e.colDef;return aN(t.gos,{colDef:n,column:e,floatingFilter:!0})}setupActive(){let e=this.column.getColDef(),t=!!e.filter,n=!!e.floatingFilter;this.active=t&&n}setupUi(){if(this.comp.setButtonWrapperDisplayed(!this.suppressFilterButton&&this.active),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-full-body",this.suppressFilterButton),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-body",!this.suppressFilterButton),!this.active||this.iconCreated)return;let e=cv("filter",this.beans,this.column);e&&(this.iconCreated=!0,this.eButtonShowMainFilter.appendChild(e))}setupFocus(e){e.createManagedBean(new us(this.eGui,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)}))}setupAria(){let e=this.getLocaleTextFunc();rj(this.eButtonShowMainFilter,e("ariaFilterMenuOpen","Open Filter Menu"))}onTabKeyDown(e){let{beans:t}=this;if(rA(t)===this.eGui)return;let n=lk(t,this.eGui,null,e.shiftKey);if(n){t.headerNavigation?.scrollToColumn(this.column),e.preventDefault(),n.focus();return}let i=this.findNextColumnWithFloatingFilter(e.shiftKey);i&&t.focusSvc.focusHeaderPosition({headerPosition:{headerRowIndex:this.rowCtrl.rowIndex,column:i},event:e})&&e.preventDefault()}findNextColumnWithFloatingFilter(e){let t=this.beans.visibleCols,n=this.column;do if(!(n=e?t.getColBefore(n):t.getColAfter(n)))break;while(!n.getColDef().filter||!n.getColDef().floatingFilter)return n}handleKeyDown(e){super.handleKeyDown(e);let t=this.getWrapperHasFocus();switch(e.key){case s1:case s3:case s0:case s2:if(t)return;uo(e);case sJ:t&&l_(this.eGui)&&e.preventDefault();break;case sQ:t||this.eGui.focus()}}onFocusIn(e){if(this.eGui.contains(e.relatedTarget))return;let t=!!e.relatedTarget&&!e.relatedTarget.classList.contains("ag-floating-filter"),n=!!e.relatedTarget&&rJ(e.relatedTarget,"ag-floating-filter");if(t&&n&&e.target===this.eGui){let e=this.lastFocusEvent,t=!!(e&&"Tab"===e.key);if(e&&t){let t=e.shiftKey;l_(this.eGui,t)}}this.focusThis()}setupHover(e){this.beans.colHover?.addHeaderFilterColumnHoverListener(e,this.comp,this.column,this.eGui)}setupLeft(e){let t=new ce(this.column,this.eGui,this.beans);e.createManagedBean(t)}setupFilterButton(){this.suppressFilterButton=!this.beans.menuSvc?.isFloatingFilterButtonEnabled(this.column),this.highlightFilterButtonWhenActive=!aO(this.gos)}setupUserComp(){if(!this.active)return;
412let e=this.beans.colFilter?.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter());e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setCompDetails(e)}showParentFilter(){let e=this.suppressFilterButton?this.eFloatingFilterBody:this.eButtonShowMainFilter;this.beans.menuSvc?.showFilterMenu({column:this.column,buttonElement:e,containerType:"floatingFilter",positionBy:"button"})}setupSyncWithFilter(e){if(!this.active)return;let{beans:{colFilter:t},column:n,gos:i}=this,r=e=>{if(e?.source==="filterDestroyed"&&(!this.isAlive()||!t?.isAlive()))return;let r=this.comp.getFloatingFilterComp();r&&r.then(r=>{if(r){if(i.get("enableFilterHandlers")){let t="filter";e?.afterFloatingFilter?t="ui":e?.afterDataChange?t="dataChanged":e?.source==="api"&&(t="api"),this.updateFloatingFilterParams(this.userCompDetails,t);return}let o=t?.getCurrentFloatingFilterParentModel(n),a=e?{...e,columns:e.columns??[],source:"api"===e.source?"api":"columnFilter"}:null;r.onParentModelChanged(o,a)}})};[this.destroySyncListener]=e.addManagedListeners(n,{filterChanged:r}),t?.isFilterActive(n)&&r(null)}setupWidth(e){let t=()=>{let e=`${this.column.getActualWidth()}px`;this.comp.setWidth(e)};e.addManagedListeners(this.column,{widthChanged:t}),t()}setupFilterChangedListener(e){this.active&&([this.destroyFilterChangedListener]=e.addManagedListeners(this.column,{filterChanged:this.updateFilterButton.bind(this)}),this.updateFilterButton())}updateFilterButton(){if(!this.suppressFilterButton&&this.comp){let e=!!this.beans.filterManager?.isFilterAllowed(this.column);this.comp.setButtonWrapperDisplayed(e),this.highlightFilterButtonWhenActive&&e&&this.eButtonShowMainFilter.classList.toggle("ag-filter-active",this.column.isFilterActive())}}onColDefChanged(e){let t=this.active;this.setupActive();let n=!t&&this.active;t&&!this.active&&(this.destroySyncListener(),this.destroyFilterChangedListener());let i=this.beans.colFilter,r=this.active?i?.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter()):null,o=this.comp.getFloatingFilterComp();o&&r?o.then(t=>{!t||i?.areFilterCompsDifferent(this.userCompDetails??null,r)?this.updateCompDetails(e,r,n):this.updateFloatingFilterParams(r,"colDef")}):this.updateCompDetails(e,r,n)}updateCompDetails(e,t,n){this.isAlive()&&(this.setCompDetails(t),this.setupFilterButton(),this.setupUi(),n&&(this.setupSyncWithFilter(e),this.setupFilterChangedListener(e)))}updateFloatingFilterParams(e,t){if(!e)return;let n=e.params;this.comp.getFloatingFilterComp()?.then(e=>{"function"==typeof e?.refresh&&(this.gos.get("enableFilterHandlers")&&(n={...n,model:dq(this.beans.colFilter?.model??{},this.column.getColId()),source:t}),e.refresh(n))})}addResizeAndMoveKeyboardListeners(){}destroy(){super.destroy(),this.destroySyncListener=null,this.destroyFilterChangedListener=null}},go={moduleName:"Popup",version:o1,beans:[class extends dS{postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridCtrl=e.gridCtrl}),this.addManagedEventListeners({gridStylesChanged:this.handleThemeChange.bind(this)})}getDefaultPopupParent(){return this.gridCtrl.getGui()}positionPopupForMenu(e){let{eventSource:t,ePopup:n,event:i}=e,r=t.getBoundingClientRect(),o=this.getParentRect();this.setAlignedTo(t,n);let a=!1,s=()=>{let e,t=this.keepXYWithinBounds(n,r.top-o.top,0),i=n.clientWidth>0?n.clientWidth:200;a||(n.style.minWidth=`${i}px`,a=!0);let s=o.right-o.left-i;return this.gos.get("enableRtl")?((e=d())<0&&(e=l(),this.setAlignedStyles(n,"left")),e>s&&(e=0,this.setAlignedStyles(n,"right"))):((e=l())>s&&(e=d(),this.setAlignedStyles(n,"right")),e<0&&(e=0,this.setAlignedStyles(n,"left"))),{x:e,y:t};function l(){return r.right-o.left-2}function d(){return r.left-o.left-i}};this.positionPopup({ePopup:n,keepWithinBounds:!0,updatePosition:s,postProcessCallback:()=>this.callPostProcessPopup(e,"subMenu",n,t,i instanceof MouseEvent?i:void 0)})}callPostProcessPopup(e,t,n,i,r){let o=this.gos.getCallback("postProcessPopup");if(o){let{column:a,rowNode:s}=e;o({column:a,rowNode:s,ePopup:n,type:t,eventSource:i,mouseEvent:r})}}getActivePopups(){return this.popupList.map(e=>e.element)}handleThemeChange(e){if(e.themeChanged){let e=this.beans.environment;for(let t of this.popupList)e.applyThemeClasses(t.wrapper)}}hasAnchoredPopup(){return this.popupList.some(e=>e.isAnchored)}isStopPropagation(e){return ua(e)}}]},ga={filterHandler:()=>({doesFilterPass:()=>!0})},gs=class extends oI{constructor(){super(...arguments),this.beanName="
412colFilter",this.allColumnFilters=new Map,this.allColumnListeners=new Map,this.activeAggregateFilters=[],this.activeColumnFilters=[],this.processingFilterChange=!1,this.modelUpdates=[],this.columnModelUpdates=[],this.state=new Map,this.handlerMap={...dV},this.isGlobalButtons=!1,this.activeFilterComps=new Set}postConstruct(){this.addManagedEventListeners({gridColumnsChanged:this.onColumnsChanged.bind(this),dataTypesInferred:this.processFilterModelUpdateQueue.bind(this)});let e=this.gos,t={...e.get("initialState")?.filter?.filterModel??{}};this.initialModel=t,this.model={...t},e.get("enableFilterHandlers")||delete this.handlerMap.agMultiColumnFilter}refreshModel(){this.onNewRowsLoaded("rowDataUpdated")}setModel(e,t="api",n){let{colModel:i,dataTypeSvc:r,filterManager:o}=this.beans;if(r?.isPendingInference)return void this.modelUpdates.push({model:e,source:t});let a=[],s=this.getModel(!0);if(e){let t=new Set(Object.keys(e));this.allColumnFilters.forEach((n,i)=>{let r=e[i];a.push(this.setModelOnFilterWrapper(n,r)),t.delete(i)}),t.forEach(t=>{let n=i.getColDefCol(t)||i.getCol(t);if(!n)return void at(62,{colId:t});if(!n.isFilterAllowed())return void at(63,{colId:t});let r=this.getOrCreateFilterWrapper(n,!0);r?a.push(this.setModelOnFilterWrapper(r,e[t],!0)):at(64,{colId:t})})}else this.model={},this.allColumnFilters.forEach(e=>{a.push(this.setModelOnFilterWrapper(e,null))});sT.all(a).then(()=>{let e=this.getModel(!0),i=[];this.allColumnFilters.forEach((t,n)=>{rk(s?s[n]:null,e?e[n]:null)||i.push(t.column)}),i.length>0?o?.onFilterChanged({columns:i,source:t}):n&&this.updateActive("filterChanged")})}getModel(e){let t={},{allColumnFilters:n,initialModel:i,beans:{colModel:r}}=this;if(n.forEach((e,n)=>{let i=this.getModelFromFilterWrapper(e);rC(i)&&(t[n]=i)}),!e)for(let e of Object.keys(i)){let o=i[e];rC(o)&&!n.has(e)&&r.getCol(e)?.isFilterAllowed()&&(t[e]=o)}return t}setState(e,t,n="api"){if(this.state.clear(),t)for(let e of Object.keys(t)){let n=t[e];this.state.set(e,{model:dq(this.model,e),state:n})}this.setModel(e,n,!0)}getState(){let e=this.state;if(!e.size)return;let t={},n=!1;return e.forEach((e,i)=>{let r=e.state;null!=r&&(n=!0,t[i]=r)}),n?t:void 0}getModelFromFilterWrapper(e){let t=e.column.getColId();if(e.isHandler)return dq(this.model,t);let n=e.filter;return n?"function"!=typeof n.getModel?(at(66),null):n.getModel():dq(this.initialModel,t)}isFilterPresent(){return this.activeColumnFilters.length>0}isAggFilterPresent(){return!!this.activeAggregateFilters.length}disableFilters(){this.initialModel={};let{allColumnFilters:e}=this;return!!e.size&&(e.forEach(e=>this.disposeFilterWrapper(e,"advancedFilterEnabled")),!0)}updateActiveFilters(){let{colModel:e,gos:t}=this.beans,n=!!ab(t),i=[],r=[],o=(t,o,a)=>{o&&((t=>{if(!t.isPrimary())return!0;let i=!e.isPivotActive();return!!t.isValueActive()&&!!i&&(!!e.isPivotMode()||n)})(t)?i.push(a):r.push(a))},a=[];return this.allColumnFilters.forEach(e=>{let t=e.column,n=t.getColId();if(e.isHandler)a.push(sT.resolve().then(()=>{o(t,this.isHandlerActive(t),{colId:n,isHandler:!0,handler:e.handler,handlerParams:e.handlerParams})}));else{let i=dG(e);i&&a.push(i.then(e=>{o(t,!!e&&(e.isFilterActive?e.isFilterActive():(at(67),!1)),{colId:n,isHandler:!1,comp:e})}))}}),sT.all(a).then(()=>{this.activeAggregateFilters=i,this.activeColumnFilters=r})}updateFilterFlagInColumns(e,t){let n=[];return this.allColumnFilters.forEach(i=>{let r=i.column;if(i.isHandler)n.push(sT.resolve().then(()=>{this.setColFilterActive(r,this.isHandlerActive(r),e,t)}));else{let o=dG(i);o&&n.push(o.then(n=>{this.setColFilterActive(r,n.isFilterActive(),e,t)}))}}),this.beans.groupFilter?.updateFilterFlags(e,t),sT.all(n)}doFiltersPass(e,t,n){let{data:i,aggData:r}=e,o=n?this.activeAggregateFilters:this.activeColumnFilters,a=n?r:i,s=this.model;for(let n=0;n<o.length;n++){let i=o[n],{colId:r,isHandler:l}=i;if(r!==t)if(l){let{handler:t,handlerParams:n}=i;if(!t.doesFilterPass({node:e,data:a,model:dq(s,r),handlerParams:n}))return!1}else{let t=i.comp;if("function"!=typeof t.doesFilterPass){an(91);continue}if(!t.doesFilterPass({node:e,data:a}))return!1}}return!0}getHandlerParams(e){let t=this.allColumnFilters.get(e.getColId());return t?.isHandler?t.handlerParams:void 0}callOnFilterChangedOutsideRenderCycle(e){let{rowRenderer:t,filterManager:n}=this.beans,i=()=>{this.isAlive()&&n?.onFilterChanged(e)};t.isRefreshInProgress()?setTimeout(i,0):i()}updateBeforeFilterChanged(e={}){let{column:t,additionalEventAttributes:n}=e,i=t?.getColId();return this.updateActiveFilters().then(()=>this.updateFilterFlagInColumns("filterChanged",n).then(()=>
412{this.allColumnFilters.forEach(e=>{let{column:t,isHandler:n}=e;i!==t.getColId()&&(n&&e.handler.onAnyFilterChanged?.(),dG(e,n)?.then(e=>{"function"==typeof e?.onAnyFilterChanged&&e.onAnyFilterChanged()}))}),this.processingFilterChange=!0}))}updateAfterFilterChanged(){this.processingFilterChange=!1}isSuppressFlashingCellsBecauseFiltering(){return!this.gos.get("allowShowChangeAfterFilter")&&this.processingFilterChange}onNewRowsLoaded(e){let t=[];this.allColumnFilters.forEach(e=>{let n=e.isHandler;n&&e.handler.onNewRowsLoaded?.();let i=dG(e,n);i&&t.push(i.then(e=>{e.onNewRowsLoaded?.()}))}),sT.all(t).then(()=>this.updateActive(e,{afterDataChange:!0}))}updateActive(e,t){this.updateFilterFlagInColumns(e,t).then(()=>this.updateActiveFilters())}createGetValue(e,t){let{filterValueSvc:n,colModel:i}=this.beans;return(r,o)=>{let a=o?i.getCol(o):e;return a?n.getValue(a,r,t):void 0}}isFilterActive(e){let t=this.cachedFilter(e);if(t?.isHandler)return this.isHandlerActive(e);let n=t?.filter;return n?n.isFilterActive():null!=dq(this.initialModel,e.getColId())}isHandlerActive(e){let t=rC(dq(this.model,e.getColId()));if(t)return t;let n=this.beans.groupFilter;return!!n?.isGroupFilter(e)&&n.isFilterActive(e)}getOrCreateFilterUi(e){let t=this.getOrCreateFilterWrapper(e,!0);return t?dG(t):null}getFilterUiForDisplay(e){let t=this.getOrCreateFilterWrapper(e,!0);if(!t)return null;let n=dG(t);return n?n.then(e=>({comp:e,params:t.filterUi.filterParams,isHandler:t.isHandler})):null}getHandler(e,t){let n=this.getOrCreateFilterWrapper(e,t);return n?.isHandler?n.handler:void 0}getOrCreateFilterWrapper(e,t){if(!e.isFilterAllowed())return;let n=this.cachedFilter(e);return!n&&t&&(n=this.createFilterWrapper(e),this.setColumnFilterWrapper(e,n)),n}cachedFilter(e){return this.allColumnFilters.get(e.getColId())}getDefaultFilter(e,t=!1){return this.getDefaultFilterFromDataType(()=>this.beans.dataTypeSvc?.getBaseDataType(e),t)}getDefaultFilterFromDataType(e,t=!1){var n;return(n=this.gos).isModuleRegistered("SetFilter")&&!n.get("suppressSetFilterByDefault")?t?"agSetColumnFloatingFilter":"agSetColumnFilter":function(e,t=!1){return(t?d9:d7)[e??"text"]}(e(),t)}getDefaultFloatingFilter(e){return this.getDefaultFilter(e,!0)}createFilterComp(e,t,n,i,r,o){let a=()=>{var a,s;let l,d=i(this.createFilterCompParams(e,r,o),r);return a=this.beans.userCompFactory,sM(l=(s=t).filter)&&(s={filter:l.component,filterParams:s.filterParams}),a.getCompDetails(s,sV,n,d,!0)},s=a();return s?{compDetails:s,createFilterUi:e=>(e?a():s).newAgStackInstance()}:null}createFilterInstance(e,t,n,i){let r=this.beans.selectableFilter;r?.isSelectable(t)&&(t=r.getFilterDef(e,t));let{handler:o,handlerParams:a,handlerGenerator:s}=this.createHandler(e,t,n)??{},l=this.createFilterComp(e,t,n,i,!!o,"init");if(!l)return{compDetails:null,createFilterUi:null,handler:o,handlerGenerator:s,handlerParams:a};let{compDetails:d,createFilterUi:u}=l;return this.isGlobalButtons&&(d.params?.buttons?.length||at(281,{colId:e.getColId()})),{compDetails:d,handler:o,handlerGenerator:s,handlerParams:a,createFilterUi:u}}createBaseFilterParams(e,t){let{filterManager:n,rowModel:i}=this.beans;return aN(this.gos,{column:e,colDef:e.getColDef(),getValue:this.createGetValue(e),doesRowPassOtherFilter:t?()=>!0:t=>n?.doesRowPassOtherFilters(e.getColId(),t)??!0,rowModel:i})}createFilterCompParams(e,t,n,i){let r=this.filterChangedCallbackFactory(e),o=this.createBaseFilterParams(e,i);if(o.filterChangedCallback=r,o.filterModifiedCallback=i?()=>{}:t=>this.filterModified(e,t),t){let t=e.getColId(),i=dq(this.model,t);o.model=i,o.state=this.state.get(t)??{model:i},o.onModelChange=(n,i)=>{this.updateStoredModel(t,n),this.refreshHandlerAndUi(e,n,"ui",!1,i).then(()=>{r({...i,source:"columnFilter"})})},o.onStateChange=t=>{this.updateState(e,t),this.updateOrRefreshFilterUi(e)},o.onAction=(t,n,i)=>{this.updateModel(e,t,n),this.dispatchLocalEvent({type:"filterAction",column:e,action:t,event:i})},o.getHandler=()=>this.getHandler(e,!0),o.onUiChange=t=>this.filterUiChanged(e,t),o.source=n}return o}createFilterUiForHandler(e,t){return t?{created:!1,create:t,filterParams:e.params,compDetail
412s:e}:null}createFilterUiLegacy(e,t,n){let i=t(),r={created:!0,create:t,filterParams:e.params,compDetails:e,promise:i};return i.then(n),r}createFilterWrapper(e){let{compDetails:t,handler:n,handlerGenerator:i,handlerParams:r,createFilterUi:o}=this.createFilterInstance(e,e.getColDef(),this.getDefaultFilter(e),e=>e),a=e.getColId();if(n)return delete this.initialModel[a],n.init?.({...r,source:"init",model:dq(this.model,a)}),{column:e,isHandler:!0,handler:n,handlerGenerator:i,handlerParams:r,filterUi:this.createFilterUiForHandler(t,o)};if(o){let n={column:e,filterUi:null,isHandler:!1};return n.filterUi=this.createFilterUiLegacy(t,o,e=>{n.filter=e??void 0}),n}return{column:e,filterUi:null,isHandler:!1}}createHandlerFunc(e,t,n){let i,r,o,{gos:a,frameworkOverrides:s,registry:l}=this.beans,d=a.get("enableFilterHandlers"),u=d?(e=>{let t=e.filter;if(sM(t)){let e=t.handler;return e||((i=t.doesFilterPass)?()=>({doesFilterPass:i}):void 0)}return"string"==typeof t?t:void 0})(t):void 0,c=e=>()=>this.createBean(l.createDynamicBean(e,!0));if("string"==typeof u){let e=a.get("filterHandlers")?.[u];null!=e?r=e:dH.has(u)&&(r=c(u),o=u)}else r=u;if(!r){let e,{compName:i,jsComp:a,fwComp:l}=sD(s,t,sV);i?e=i:null==a&&null==l&&!0===t.filter&&(e=n),(o=this.handlerMap[e])&&(r=c(o))}if(!r){if(!d)return;return aa(a)&&at(277,{colId:e.getColId()}),ga}return{filterHandler:r,handlerNameOrCallback:i??o}}createHandler(e,t,n){let i=this.createHandlerFunc(e,t,n);if(!i)return;let r=sY(this.beans.userCompFactory,t,this.createFilterCompParams(e,!0,"init")),{handlerNameOrCallback:o,filterHandler:a}=i,{handler:s,handlerParams:l}=this.createHandlerFromFunc(e,a,r);return{handler:s,handlerParams:l,handlerGenerator:o??a}}createHandlerFromFunc(e,t,n){let i=e.getColDef();return{handler:t(aN(this.gos,{column:e,colDef:i})),handlerParams:this.createHandlerParams(e,n)}}createHandlerParams(e,t){let n=e.getColDef(),i=e.getColId(),r=this.filterChangedCallbackFactory(e);return aN(this.gos,{colDef:n,column:e,getValue:this.createGetValue(e),doesRowPassOtherFilter:e=>this.beans.filterManager?.doesRowPassOtherFilters(i,e)??!0,onModelChange:(t,n)=>{this.updateStoredModel(i,t),this.refreshHandlerAndUi(e,t,"handler",!1,n).then(()=>{r({...n,source:"columnFilter"})})},filterParams:t})}onColumnsChanged(){let e=[],{colModel:t,filterManager:n,groupFilter:i}=this.beans;this.allColumnFilters.forEach((n,i)=>{let r;(r=n.column.isPrimary()?t.getColDefCol(i):t.getCol(i))&&r===n.column||(e.push(n.column),this.disposeFilterWrapper(n,"columnChanged"),this.disposeColumnListener(i))});let r=i&&e.every(e=>i.isGroupFilter(e));e.length>0&&!r&&n?.onFilterChanged({columns:e,source:"api"})}isFilterAllowed(e){if(!e.isFilterAllowed())return!1;let t=this.beans.groupFilter;return!t?.isGroupFilter(e)||t.isFilterAllowed(e)}getFloatingFilterCompDetails(e,t){let{userCompFactory:n,frameworkOverrides:i,selectableFilter:r}=this.beans,o=t=>{let n=this.getOrCreateFilterUi(e);null!=n&&n.then(e=>{t(sZ(e))})},a=e.getColDef(),s=r?.isSelectable(a)?r.getFilterDef(e,a):a,l=function(e,t,n){if(null==t)return null;let i=null,{compName:r,jsComp:o,fwComp:a}=sD(e,t,sV);return r?i=({agSetColumnFilter:"agSetColumnFloatingFilter",agMultiColumnFilter:"agMultiColumnFloatingFilter",agGroupColumnFilter:"agGroupColumnFloatingFilter",agNumberColumnFilter:"agNumberColumnFloatingFilter",agDateColumnFilter:"agDateColumnFloatingFilter",agTextColumnFilter:"agTextColumnFloatingFilter"})[r]:null==o&&null==a&&!0===t.filter&&(i=n()),i}(i,s,()=>this.getDefaultFloatingFilter(e))??"agReadOnlyFloatingFilter",d=this.gos.get("enableFilterHandlers"),u=sY(n,s,this.createFilterCompParams(e,d,"init",!0)),c=aN(this.gos,{column:e,filterParams:u,currentParentModel:()=>this.getCurrentFloatingFilterParentModel(e),parentFilterInstance:o,showParentFilter:t});if(d){let t=e.getColId(),n=this.filterChangedCallbackFactory(e);c.onUiChange=t=>this.floatingFilterUiChanged(e,t),c.model=dq(this.model,t),c.onModelChange=(i,r)=>{this.updateStoredModel(t,i),this.refreshHandlerAndUi(e,i,"floating",!0,r).then(()=>{n({...r,source:"columnFilter"})})},c.getHandler=()=>this.getHandler(e,!0),c.source="init"}
412return n.getCompDetails(a,sH,l,c)}getCurrentFloatingFilterParentModel(e){return this.getModelFromFilterWrapper(this.cachedFilter(e)??{column:e})}destroyFilterUi(e,t,n,i){let r="paramsUpdated";if(e.isHandler){let o=t.getColId();delete this.initialModel[o],this.state.delete(o);let a=e.filterUi;e.filterUi=this.createFilterUiForHandler(n,i);let s=this.eventSvc;a?.created?a.promise.then(e=>{this.destroyBean(e),s.dispatchEvent({type:"filterDestroyed",source:r,column:t})}):s.dispatchEvent({type:"filterHandlerDestroyed",source:r,column:t})}else this.destroyFilter(t,r)}destroyFilter(e,t="api"){let n=e.getColId(),i=this.allColumnFilters.get(n);this.disposeColumnListener(n),delete this.initialModel[n],i&&this.disposeFilterWrapper(i,t).then(t=>{t&&this.isAlive()&&this.beans.filterManager?.onFilterChanged({columns:[e],source:"api"})})}disposeColumnListener(e){let t=this.allColumnListeners.get(e);t&&(this.allColumnListeners.delete(e),t())}disposeFilterWrapper(e,t){let n=!1,{column:i,isHandler:r,filterUi:o}=e,a=i.getColId();r&&(n=this.isHandlerActive(i),this.destroyBean(e.handler),delete this.model[a],this.state.delete(a));let s=()=>{this.setColFilterActive(i,!1,"filterDestroyed"),this.allColumnFilters.delete(a),this.eventSvc.dispatchEvent({type:"filterDestroyed",source:t,column:i})};if(o)if(o.created)return o.promise.then(e=>(n=r?n:!!e?.isFilterActive(),this.destroyBean(e),s(),n));else s();return sT.resolve(n)}filterChangedCallbackFactory(e){return t=>{this.callOnFilterChangedOutsideRenderCycle({additionalEventAttributes:t,columns:[e],column:e,source:t?.source??"columnFilter"})}}filterParamsChanged(e,t="api"){let n=this.allColumnFilters.get(e);if(!n)return;let i=this.beans,r=n.column,o=r.getColDef(),a=r.isFilterAllowed(),s=this.getDefaultFilter(r),l=i.selectableFilter,d=l?.isSelectable(o)?l.getFilterDef(r,o):o,u=a?this.createHandlerFunc(r,d,this.getDefaultFilter(r)):void 0,c=!!u,h=n.isHandler;if(h!=c)return void this.destroyFilter(r,"paramsUpdated");let{compDetails:p,createFilterUi:f}=(a?this.createFilterComp(r,d,s,e=>e,c,"colDef"):null)??{compDetails:null,createFilterUi:null},g=p?.params??sY(i.userCompFactory,d,this.createFilterCompParams(r,c,"colDef"));if(h){let i=u?.handlerNameOrCallback??u?.filterHandler,o=dq(this.model,e);if(n.handlerGenerator!=i){let a=n.handler,{handler:s,handlerParams:l}=this.createHandlerFromFunc(r,u.filterHandler,g);n.handler=s,n.handlerParams=l,n.handlerGenerator=i,delete this.model[e],s.init?.({...l,source:"init",model:null}),this.destroyBean(a),null!=o&&this.beans.filterManager?.onFilterChanged({columns:[r],source:t})}else{let e=this.createHandlerParams(r,p?.params);n.handlerParams=e,n.handler.refresh?.({...e,source:"colDef",model:o})}}!this.areFilterCompsDifferent(n.filterUi?.compDetails??null,p)&&n.filterUi&&p?(n.filterUi.filterParams=g,dG(n,h)?.then(e=>{!1===(!e?.refresh||e.refresh(g))?this.destroyFilterUi(n,r,p,f):this.dispatchLocalEvent({type:"filterParamsChanged",column:r,params:g})})):this.destroyFilterUi(n,r,p,f)}refreshHandlerAndUi(e,t,n,i,r){var o,a;let s=this.cachedFilter(e);if(!s)return i&&this.getOrCreateFilterWrapper(e,!0),sT.resolve();if(!s.isHandler)return sT.resolve();let{filterUi:l,handler:d,handlerParams:u}=s;return o=()=>{if(l){let{created:e,filterParams:t}=l;if(e)return l.promise.then(e=>e?{filter:e,filterParams:t}:void 0);l.refreshed=!0}return sT.resolve(void 0)},a=this.state.get(e.getColId())??{model:t},d.refresh?.({...u,model:t,source:n,additionalEventAttributes:r}),o().then(e=>{if(e){let{filter:i,filterParams:o}=e;dW(i,o,t,a,n,r)}})}setColumnFilterWrapper(e,t){let n=e.getColId();this.allColumnFilters.set(n,t),this.allColumnListeners.set(n,this.addManagedListeners(e,{colDefChanged:()=>this.filterParamsChanged(n)})[0])}areFilterCompsDifferent(e,t){if(!t||!e)return!0;let{componentClass:n}=e,{componentClass:i}=t;return!(n===i||n?.render&&i?.render&&n.render===i.render)}hasFloatingFilters(){return this.beans.colModel.getCols().some(e=>e.getColDef().floatingFilter)}getFilterInstance(e){let t=this.beans.colModel.getColDefCol(e);if(!t)return Promise.resolve(void 0);let n=this.getOrCreateFilterUi(t);return n?new Promise(e=>{n.then(t=>{e(sZ(t))})}):Promise.resolve(null)}
412processFilterModelUpdateQueue(){this.modelUpdates.forEach(({model:e,source:t})=>this.setModel(e,t)),this.modelUpdates=[],this.columnModelUpdates.forEach(({key:e,model:t,resolve:n})=>{this.setModelForColumn(e,t).then(()=>n())}),this.columnModelUpdates=[]}getModelForColumn(e,t){if(t){let{state:t,model:n}=this,i=e.getColId(),r=t.get(i);return r?r.model??null:dq(n,i)}let n=this.cachedFilter(e);return n?this.getModelFromFilterWrapper(n):null}setModelForColumn(e,t){if(this.beans.dataTypeSvc?.isPendingInference){let n=()=>{},i=new Promise(e=>{n=e});return this.columnModelUpdates.push({key:e,model:t,resolve:n}),i}return new Promise(n=>{this.setModelForColumnLegacy(e,t).then(e=>n(e))})}getStateForColumn(e){return this.state.get(e)??{model:dq(this.model,e)}}setModelForColumnLegacy(e,t){let n=this.beans.colModel.getColDefCol(e),i=n?this.getOrCreateFilterWrapper(n,!0):null;return i?this.setModelOnFilterWrapper(i,t):sT.resolve()}setColDefPropsForDataType(e,t,n){let i,r,o=e.filter,a=!0===o?this.getDefaultFilterFromDataType(()=>t.baseDataType):o;if("string"!=typeof a)return;let s=this.beans,{filterParams:l,filterValueGetter:d}=e;if("agMultiColumnFilter"===a)({filterParams:i,filterValueGetter:r}=s.multiFilter?.getParamsForDataType(l,d,t,n)??{});else{var u;let e,o,c;({filterParams:i,filterValueGetter:r}=(u=this.getLocaleTextFunc(),e=d,o="agSetColumnFilter"===a,e||"object"!==t.baseDataType||o||(e=({column:e,node:t})=>n({column:e,node:t,value:s.valueSvc.getValue(e,t)})),c=(0,(o?d8:d6)[t.baseDataType])({dataTypeDefinition:t,formatValue:n,t:u}),{filterParams:"object"==typeof l?{...c,...l}:c,filterValueGetter:e}))}e.filterParams=i,r&&(e.filterValueGetter=r)}setColFilterActive(e,t,n,i){e.filterActive!==t&&(e.filterActive=t,e.dispatchColEvent("filterActiveChanged",n)),e.dispatchColEvent("filterChanged",n,i)}setModelOnFilterWrapper(e,t,n){return new sT(i=>{if(e.isHandler){let r=e.column,o=r.getColId(),a=this.model[o];return(this.updateStoredModel(o,t),n&&t===a)?void i():void this.refreshHandlerAndUi(r,t,"api").then(()=>i())}let r=dG(e);r?r.then(e=>{if("function"!=typeof e?.setModel){at(65),i();return}(e.setModel(t)||sT.resolve()).then(()=>i())}):i()})}updateStoredModel(e,t){rC(t)?this.model[e]=t:delete this.model[e];let n=this.state.get(e),i={model:t,state:n?.state};this.state.set(e,i)}filterModified(e,t){this.getOrCreateFilterUi(e)?.then(n=>{this.eventSvc.dispatchEvent({type:"filterModified",column:e,filterInstance:n,...t})})}filterUiChanged(e,t){this.gos.get("enableFilterHandlers")&&this.eventSvc.dispatchEvent({type:"filterUiChanged",column:e,...t})}floatingFilterUiChanged(e,t){this.gos.get("enableFilterHandlers")&&this.eventSvc.dispatchEvent({type:"floatingFilterUiChanged",column:e,...t})}updateModel(e,t,n){let i=e.getColId(),r=this.cachedFilter(e),o=()=>r?.filterUi;dU(t,o,()=>dq(this.model,i),()=>this.state.get(i),t=>this.updateState(e,t),e=>o()?.filterParams?.onModelChange(e,n),r?.isHandler?r.handler.processModelToApply?.bind(r.handler):void 0)}updateAllModels(e,t){let n=[];this.allColumnFilters.forEach((t,i)=>{let r=this.beans.colModel.getColDefCol(i);r&&dU(e,()=>t.filterUi,()=>dq(this.model,i),()=>this.state.get(i),e=>this.updateState(r,e),t=>{this.updateStoredModel(i,t),this.dispatchLocalEvent({type:"filterAction",column:r,action:e}),n.push(this.refreshHandlerAndUi(r,t,"ui"))},t?.isHandler?t.handler.processModelToApply?.bind(t.handler):void 0)}),n.length&&sT.all(n).then(()=>{this.callOnFilterChangedOutsideRenderCycle({source:"columnFilter",additionalEventAttributes:t,columns:[]})})}updateOrRefreshFilterUi(e){let t=e.getColId();d$(()=>this.cachedFilter(e)?.filterUi,()=>dq(this.model,t),()=>this.state.get(t))}updateState(e,t){this.state.set(e.getColId(),t),this.dispatchLocalEvent({type:"filterStateChanged",column:e,state:t})}canApplyAll(){let{state:e,model:t,activeFilterComps:n}=this;for(let e of n)if("COLUMN_MENU"===e.source)return!1;let i=!1;for(let n of e.keys()){let r=e.get(n);if(!1===r.valid)return!1;(r.model??null)!==dq(t,n)&&(i=!0)}return i}hasUnappliedModel(e){let{model:t,state:n}=this;return(n.get(e)?.model??null)!==dq(t,e)}setGlobalButtons(e){this.isGlobalButtons=e,this.dispatchLocalEvent({type:"filterGlobalButtons",isGlobal:e})}shouldKeepStateOnDetach(e,t){if("newFiltersToolPanel"===t)return!0;let n=this.beans.filterPanelSvc;return!!n?.isActive&&!!n.getState(e.getColId())}
vendor: 4,782 bytes, line 412
412destroy(){super.destroy(),this.allColumnFilters.forEach(e=>this.disposeFilterWrapper(e,"gridDestroyed")),this.allColumnListeners.clear(),this.state.clear(),this.activeFilterComps.clear()}},gl=class extends oI{constructor(){super(...arguments),this.beanName="filterManager",this.advFilterModelUpdateQueue=[]}wireBeans(e){this.quickFilter=e.quickFilter,this.advancedFilter=e.advancedFilter,this.colFilter=e.colFilter}postConstruct(){let e=this.refreshFiltersForAggregations.bind(this),t=this.updateAdvFilterColumns.bind(this);this.addManagedEventListeners({columnValueChanged:e,columnPivotChanged:e,columnPivotModeChanged:e,newColumnsLoaded:t,columnVisible:t,advancedFilterEnabledChanged:({enabled:e})=>this.onAdvFilterEnabledChanged(e),dataTypesInferred:this.processFilterModelUpdateQueue.bind(this)}),this.externalFilterPresent=this.isExternalFilterPresentCallback(),this.addManagedPropertyListeners(["isExternalFilterPresent","doesExternalFilterPass"],()=>{this.onFilterChanged({source:"api"})}),this.updateAggFiltering(),this.addManagedPropertyListener("groupAggFiltering",()=>{this.updateAggFiltering(),this.onFilterChanged()}),this.quickFilter&&this.addManagedListeners(this.quickFilter,{quickFilterChanged:()=>this.onFilterChanged({source:"quickFilter"})});let{gos:n}=this;this.alwaysPassFilter=n.get("alwaysPassFilter"),this.addManagedPropertyListener("alwaysPassFilter",()=>{this.alwaysPassFilter=n.get("alwaysPassFilter"),this.onFilterChanged({source:"api"})})}isExternalFilterPresentCallback(){let e=this.gos.getCallback("isExternalFilterPresent");return"function"==typeof e&&e({})}doesExternalFilterPass(e){let t=this.gos.get("doesExternalFilterPass");return"function"==typeof t&&t(e)}setFilterState(e,t,n="api"){this.isAdvFilterEnabled()||this.colFilter?.setState(e,t,n)}setFilterModel(e,t="api",n){if(this.isAdvFilterEnabled()){n||this.warnAdvFilters();return}this.colFilter?.setModel(e,t)}getFilterModel(){return this.colFilter?.getModel()??{}}getFilterState(){return this.colFilter?.getState()}isColumnFilterPresent(){return!!this.colFilter?.isFilterPresent()}isAggregateFilterPresent(){return!!this.colFilter?.isAggFilterPresent()}isChildFilterPresent(){return this.isColumnFilterPresent()||this.isQuickFilterPresent()||this.externalFilterPresent||this.isAdvFilterPresent()}isAnyFilterPresent(){return this.isChildFilterPresent()||this.isAggregateFilterPresent()}isAdvFilterPresent(){return this.isAdvFilterEnabled()&&this.advancedFilter.isFilterPresent()}onAdvFilterEnabledChanged(e){e?this.colFilter?.disableFilters()&&this.onFilterChanged({source:"advancedFilter"}):this.advancedFilter?.isFilterPresent()&&(this.advancedFilter.setModel(null),this.onFilterChanged({source:"advancedFilter"}))}isAdvFilterEnabled(){return!!this.advancedFilter?.isEnabled()}isAdvFilterHeaderActive(){return this.isAdvFilterEnabled()&&this.advancedFilter.isHeaderActive()}refreshFiltersForAggregations(){ab(this.gos)&&this.isAnyFilterPresent()&&this.onFilterChanged()}onFilterChanged(e={}){let{source:t,additionalEventAttributes:n,columns:i=[]}=e;this.externalFilterPresent=this.isExternalFilterPresentCallback(),(this.colFilter?this.colFilter.updateBeforeFilterChanged(e):sT.resolve()).then(()=>{let e={source:t,type:"filterChanged",columns:i};n&&oz(e,n),this.eventSvc.dispatchEvent(e),this.colFilter?.updateAfterFilterChanged()})}isSuppressFlashingCellsBecauseFiltering(){return!!this.colFilter?.isSuppressFlashingCellsBecauseFiltering()}isQuickFilterPresent(){return!!this.quickFilter?.isFilterPresent()}updateAggFiltering(){this.aggFiltering=!!ab(this.gos)}isAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&this.shouldApplyQuickFilterAfterAgg()}isNonAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&!this.shouldApplyQuickFilterAfterAgg()}shouldApplyQuickFilterAfterAgg(){return(this.aggFiltering||this.beans.colModel.isPivotMode())&&!this.gos.get("applyQuickFilterBeforePivotOrAgg")}doesRowPassOtherFilters(e,t){return this.doesRowPassFilter({rowNode:t,colIdToSkip:e})}doesRowPassAggregateFilters(e){let{rowNode:t}=e;return!!this.alwaysPassFilter?.(t)||!(this.isAggregateQuickFilterPresent()&&!this.quickFilter.doesRowPass(t)||this.isAggregateFilterPresent()&&!this.colFilter.doFiltersPass(t,e.colIdToSkip,!0))}doesRowPassFilter(e){let{rowNode:t}=e;return!!this.alwaysPassFilter?.(t)||!(this.isNonAggregateQuickFilterPresent()&&!this.quickFilter.doesRowPass(t)||this.externalFilterPresent&&!this.doesExternalFilterPass(t)||this.isColumnFilterPresent()&&!this.colFilter.doFiltersPass(t,e.colIdToSkip)||this.isAdvFilterPresent()&&!this.advancedFilter.doesFilterPass(t))}isFilterAllowed(e){return!this.isAdvFilterEnabled()&&!!this.colFilter?.isFilterAllowed(e)}getAdvFilterModel(){return this.isAdvFilterEnabled()?this.advancedFilter.getModel():null}
412setAdvFilterModel(e,t="api"){if(this.isAdvFilterEnabled()){if(this.beans.dataTypeSvc?.isPendingInference)return void this.advFilterModelUpdateQueue.push(e);this.advancedFilter.setModel(e??null),this.onFilterChanged({source:t})}}toggleAdvFilterBuilder(e,t){this.isAdvFilterEnabled()&&this.advancedFilter.getCtrl().toggleFilterBuilder({source:t,force:e})}updateAdvFilterColumns(){this.isAdvFilterEnabled()&&this.advancedFilter.updateValidity()&&this.onFilterChanged({source:"advancedFilter"})}hasFloatingFilters(){return!this.isAdvFilterEnabled()&&!!this.colFilter?.hasFloatingFilters()}getColumnFilterInstance(e){return this.isAdvFilterEnabled()?(this.warnAdvFilters(),Promise.resolve(void 0)):this.colFilter?.getFilterInstance(e)??Promise.resolve(void 0)}warnAdvFilters(){at(68)}setupAdvFilterHeaderComp(e){this.advancedFilter?.getCtrl().setupHeaderComp(e)}getHeaderRowCount(){return+!!this.isAdvFilterHeaderActive()}getHeaderHeight(){return this.isAdvFilterHeaderActive()?this.advancedFilter.getCtrl().getHeaderHeight():0}processFilterModelUpdateQueue(){for(let e of this.advFilterModelUpdateQueue)this.setAdvFilterModel(e);this.advFilterModelUpdateQueue=[]}setColumnFilterModel(e,t){return this.isAdvFilterEnabled()?(this.warnAdvFilters(),Promise.resolve()):this.colFilter?.setModelForColumn(e,t)??Promise.resolve()}},gd=class extends oI{constructor(){super(...arguments),this.beanName="filterMenuFactory"}wireBeans(e){this.popupSvc=e.popupSvc}hideActiveMenu(){this.hidePopup?.()}showMenuAfterMouseEvent(e,t,n,i){(!e||e.isColumn)&&this.showPopup(e,i=>{this.popupSvc?.positionPopupUnderMouseEvent({column:e,type:n,mouseEvent:t,ePopup:i})},n,t.target,aO(this.gos),i)}showMenuAfterButtonClick(e,t,n,i){if(e&&!e.isColumn)return;let r=-1,o="left",a=aO(this.gos);!a&&this.gos.get("enableRtl")&&(r=1,o="right");let s=a?void 0:4*r,l=a?void 0:4;this.showPopup(e,i=>{this.popupSvc?.positionPopupByComponent({type:n,eventSource:t,ePopup:i,nudgeX:s,nudgeY:l,alignSide:o,keepWithinBounds:!0,position:"under",column:e})},n,t,a,i)}showPopup(e,t,n,i,r,o){let a,s=e?this.createBean(new d1(e,"COLUMN_MENU")):void 0;if(this.activeMenu=s,!s?.hasFilter()||!e)return void an(57);let l=om({tag:"div",cls:`ag-menu${!r?" ag-filter-menu":""}`,role:"presentation"});[this.tabListener]=this.addManagedElementListeners(l,{keydown:e=>this.trapFocusWithin(e,l)}),l.appendChild(s?.getGui());let d=aO(this.gos)?void 0:i??this.beans.ctrlsSvc.getGridBodyCtrl().eGridBody,u=t=>{cu(e,!1,"contextMenu");let r=t instanceof KeyboardEvent;if(this.tabListener&&(this.tabListener=this.tabListener()),r&&i&&oe(i)){let e=lM(i);e?.focus({preventScroll:!0})}s?.afterGuiDetached(),this.destroyBean(this.activeMenu),this.dispatchVisibleChangedEvent(!1,n,e),o?.()},c=this.getLocaleTextFunc(),h=r&&"columnFilter"!==n?c("ariaLabelColumnMenu","Column Menu"):c("ariaLabelColumnFilter","Column Filter"),p=this.popupSvc?.addPopup({modal:!0,eChild:l,closeOnEsc:!0,closedCallback:u,positionCallback:()=>t(l),anchorToElement:d,ariaLabel:h});p&&(this.hidePopup=a=p.hideFunc),s.afterInit().then(()=>{t(l),s.afterGuiAttached({container:n,hidePopup:a})}),cu(e,!0,"contextMenu"),this.dispatchVisibleChangedEvent(!0,n,e)}trapFocusWithin(e,t){"Tab"!==e.key||e.defaultPrevented||lk(this.beans,t,!1,e.shiftKey)||(e.preventDefault(),l_(t,e.shiftKey))}dispatchVisibleChangedEvent(e,t,n){this.eventSvc.dispatchEvent({type:"columnMenuVisibleChanged",visible:e,switchingTab:!1,key:t,column:n??null,columnGroup:null})}isMenuEnabled(e){return e.isFilterAllowed()&&(e.getColDef().menuTabs??["filterMenuTab"]).includes("filterMenuTab")}showMenuAfterContextMenuEvent(){}destroy(){this.destroyBean(this.activeMenu),super.destroy()}},gu=class extends oI{constructor(){super(...arguments),this.beanName="filterValueSvc"}getValue(e,t,n){if(!t)return;let i=e.getColDef(),{selectableFilter:r,valueSvc:o}=this.beans,a=n??r?.getFilterValueGetter(e.getColId())??i.filterValueGetter;return a?this.executeFilterValueGetter(a,t.data,e,t,i):o.getValue(e,t)}executeFilterValueGetter(e,t,n,i,r){let{expressionSvc:o,valueSvc:a}=this.beans,s=aN(this.gos,{data:t,node:i,column:n,colDef:r,getValue:a.getValueCallback.bind(a,i)});return"function"==typeof e?e(s):o?.evaluate(e,s)}},gc={tag:"div",cls:"ag-floating-filter-input",role:"presentation",children:[{tag:"ag-input-text-field",ref:"eFloatingFilterText"}]},gh=class{constructor(){this.customFilterOptions={}}init(e,t){this.filterOptions=e.filterOptions??t,this.mapCustomOptions(),this.defaultOption=this.getDefaultItem(e.defaultOption)}refresh(e,t){let n=e.filterOptions??t;this.filterOptions!==n&&(this.filterOptions=n,this.customFilterOptions={},this.mapCustomOptions()),this.defaultOption=this.getDefaultItem(e.defaultOption)}mapCustomOptions(){let{filterOptions:e}=this;if(e){for(let t of e)if("string"!=typeof t){if(![["displayKey"],["displayName"],["predicate","test"]].every(e=>!!e.some(e=>
412null!=t[e])||(at(72,{keys:e}),!1))){this.filterOptions=e.filter(e=>e===t)||[];continue}this.customFilterOptions[t.displayKey]=t}}}getDefaultItem(e){let{filterOptions:t}=this;if(e)return e;if(t.length>=1){let e=t[0];if("string"==typeof e)return e;if(e.displayKey)return e.displayKey;at(73)}else at(74)}getCustomOption(e){return this.customFilterOptions[e]}};function gp(e,t,n){return null==n?e.splice(t):e.splice(t,n)}function gf(e){return null==e||"string"==typeof e&&0===e.trim().length}function gg(e,t){let n=t.getCustomOption(e);if(n){let{numberOfInputs:e}=n;return null!=e?e:1}return e&&["empty","notBlank","blank"].indexOf(e)>=0?0:"inRange"===e?2:1}var gm=class extends ul{constructor(e,t,n){super(e,"simple-filter"),this.mapValuesFromModel=t,this.defaultOptions=n,this.eTypes=[],this.eJoinPanels=[],this.eJoinAnds=[],this.eJoinOrs=[],this.eConditionBodies=[],this.listener=()=>this.onUiChanged(),this.lastUiCompletePosition=null,this.joinOperatorId=0}setParams(e){super.setParams(e);let t=new gh;this.optionsFactory=t,t.init(e,this.defaultOptions),this.commonUpdateSimpleParams(e),this.createOption(),this.createMissingConditionsAndOperators()}updateParams(e,t){this.optionsFactory.refresh(e,this.defaultOptions),super.updateParams(e,t),this.commonUpdateSimpleParams(e)}commonUpdateSimpleParams(e){var t;this.setNumConditions(e),this.defaultJoinOperator="AND"===(t=e.defaultJoinOperator)||"OR"===t?t:"AND",this.filterPlaceholder=e.filterPlaceholder,this.createFilterListOptions();let n=this.getGui();this.isReadOnly()?n.setAttribute("tabindex","-1"):n.removeAttribute("tabindex")}onFloatingFilterChanged(e,t){this.setTypeFromFloatingFilter(e),this.setValueFromFloatingFilter(t),this.onUiChanged("immediately",!0)}setTypeFromFloatingFilter(e){this.eTypes.forEach((t,n)=>{let i=0===n?e:this.optionsFactory.defaultOption;t.setValue(i,!0)})}getModelFromUi(){let e=this.getUiCompleteConditions();return 0===e.length?null:this.maxNumConditions>1&&e.length>1?{filterType:this.filterType,operator:this.getJoinOperator(),conditions:e}:e[0]}getConditionTypes(){return this.eTypes.map(e=>e.getValue())}getConditionType(e){return this.eTypes[e].getValue()}getJoinOperator(){let{eJoinOrs:e,defaultJoinOperator:t}=this;return 0===e.length?t:!0===e[0].getValue()?"OR":"AND"}areNonNullModelsEqual(e,t){let n=!e.operator,i=!t.operator;return(!!n||!i)&&(!n||!!i)&&(n?this.areSimpleModelsEqual(e,t):e.operator===t.operator&&aZ(e.conditions,t.conditions,(e,t)=>this.areSimpleModelsEqual(e,t)))}setModelIntoUi(e,t){if(null==e)return this.resetUiToDefaults(t),sT.resolve();if(e.operator){var n,i;let t,r=e.conditions;null==r&&(r=[],at(77));let o=(n=r,i=this.maxNumConditions,(t=n.length)>i&&(n.splice(i),at(78),t=i),t),a=this.getNumConditions();if(o<a)this.removeConditionsAndOperators(o);else if(o>a)for(let e=a;e<o;e++)this.createJoinOperatorPanel(),this.createOption();let s="OR"===e.operator;this.eJoinAnds.forEach(e=>e.setValue(!s,!0)),this.eJoinOrs.forEach(e=>e.setValue(s,!0)),r.forEach((e,t)=>{this.eTypes[t].setValue(e.type,!0),this.setConditionIntoUi(e,t)})}else this.getNumConditions()>1&&this.removeConditionsAndOperators(1),this.eTypes[0].setValue(e.type,!0),this.setConditionIntoUi(e,0);return this.lastUiCompletePosition=this.getNumConditions()-1,this.createMissingConditionsAndOperators(),this.updateUiVisibility(),t||this.params.onUiChange(this.getUiChangeEventParams()),sT.resolve()}setNumConditions(e){let t=e.maxNumConditions??2;t<1&&(at(79),t=1),this.maxNumConditions=t;let n=e.numAlwaysVisibleConditions??1;n<1&&(at(80),n=1),n>t&&(at(81),n=t),this.numAlwaysVisibleConditions=n}createOption(){let e=this.getGui(),t=this.createManagedBean(new lj);this.eTypes.push(t),t.addCss("ag-filter-select"),e.appendChild(t.getGui());let n=this.createEValue();this.eConditionBodies.push(n),e.appendChild(n),this.putOptionsIntoDropdown(t),this.resetType(t);let i=this.getNumConditions()-1;this.forEachPositionInput(i,e=>this.resetInput(e)),this.addChangedListeners(t,i)}createJoinOperatorPanel(){let e=om({tag:"div",cls:"ag-filter-condition"});this.eJoinPanels.push(e);
vendor: 2,823 bytes, line 412
412let t=this.createJoinOperator(this.eJoinAnds,e,"and"),n=this.createJoinOperator(this.eJoinOrs,e,"or");this.getGui().appendChild(e);let i=this.eJoinPanels.length-1,r=this.joinOperatorId++;this.resetJoinOperatorAnd(t,i,r),this.resetJoinOperatorOr(n,i,r),this.isReadOnly()||(t.onValueChange(this.listener),n.onValueChange(this.listener))}createJoinOperator(e,t,n){let i=this.createManagedBean(new lP);e.push(i);let r="ag-filter-condition-operator";return i.addCss(r),i.addCss(`${r}-${n}`),t.appendChild(i.getGui()),i}createFilterListOptions(){this.filterListOptions=this.optionsFactory.filterOptions.map(e=>"string"==typeof e?this.createBoilerplateListOption(e):this.createCustomListOption(e))}putOptionsIntoDropdown(e){let{filterListOptions:t}=this;for(let n of t)e.addOption(n);e.setDisabled(t.length<=1)}createBoilerplateListOption(e){return{value:e,text:this.translate(e)}}createCustomListOption(e){let{displayKey:t}=e,n=this.optionsFactory.getCustomOption(e.displayKey);return{value:t,text:n?this.getLocaleTextFunc()(n.displayKey,n.displayName):this.translate(t)}}createBodyTemplate(){return null}getAgComponents(){return[]}updateUiVisibility(){let e=this.getJoinOperator();this.updateNumConditions(),this.updateConditionStatusesAndValues(this.lastUiCompletePosition,e)}updateNumConditions(){let e=-1,t=!0;for(let n=0;n<this.getNumConditions();n++)this.isConditionUiComplete(n)?e=n:t=!1;if(this.shouldAddNewConditionAtEnd(t))this.createJoinOperatorPanel(),this.createOption();else{let t=this.lastUiCompletePosition??this.getNumConditions()-2;if(e<t){this.removeConditionsAndOperators(t+1);let n=e+1,i=t-n;i>0&&this.removeConditionsAndOperators(n,i),this.createMissingConditionsAndOperators()}}this.lastUiCompletePosition=e}updateConditionStatusesAndValues(e,t){this.eTypes.forEach((t,n)=>{let i=this.isConditionDisabled(n,e);t.setDisabled(i||this.filterListOptions.length<=1),1===n&&(rX(this.eJoinPanels[0],i),this.eJoinAnds[0].setDisabled(i),this.eJoinOrs[0].setDisabled(i))}),this.eConditionBodies.forEach((e,t)=>{rZ(e,this.isConditionBodyVisible(t))});let n=(t??this.getJoinOperator())==="OR";for(let e of this.eJoinAnds)e.setValue(!n,!0);for(let e of this.eJoinOrs)e.setValue(n,!0);this.forEachInput((t,n,i,r)=>{this.setElementDisplayed(t,n<r),this.setElementDisabled(t,this.isConditionDisabled(i,e))}),this.resetPlaceholder()}shouldAddNewConditionAtEnd(e){return e&&this.getNumConditions()<this.maxNumConditions&&!this.isReadOnly()}removeConditionsAndOperators(e,t){if(e>=this.getNumConditions())return;let{eTypes:n,eConditionBodies:i,eJoinPanels:r,eJoinAnds:o,eJoinOrs:a}=this;this.removeComponents(n,e,t),this.removeElements(i,e,t),this.removeEValues(e,t);let s=Math.max(e-1,0);this.removeElements(r,s,t),this.removeComponents(o,s,t),this.removeComponents(a,s,t)}removeElements(e,t,n){for(let i of gp(e,t,n))r7(i)}
412removeComponents(e,t,n){for(let i of gp(e,t,n))r7(i.getGui()),this.destroyBean(i)}afterGuiAttached(e){if(super.afterGuiAttached(e),this.resetPlaceholder(),!e?.suppressFocus){let e;if(!this.isReadOnly()){let t=this.getInputs(0)[0];e=t instanceof lR&&this.isConditionBodyVisible(0)?t.getInputElement():this.eTypes[0]?.getFocusableElement()}(e??this.getGui()).focus({preventScroll:!0})}}afterGuiDetached(){super.afterGuiDetached();let e=this.params;if(this.beans.colFilter?.shouldKeepStateOnDetach(e.column))return;e.onStateChange({model:e.model});let t=-1,n=-1,i=!1,r=this.getJoinOperator();for(let e=this.getNumConditions()-1;e>=0;e--)if(this.isConditionUiComplete(e))-1===t&&(t=e,n=e);else{let r=e>=this.numAlwaysVisibleConditions&&!this.isConditionUiComplete(e-1),o=e<t;(r||o)&&(this.removeConditionsAndOperators(e,1),i=!0,o&&n--)}let o=!1;this.getNumConditions()<this.numAlwaysVisibleConditions&&(this.createMissingConditionsAndOperators(),o=!0),this.shouldAddNewConditionAtEnd(n===this.getNumConditions()-1)&&(this.createJoinOperatorPanel(),this.createOption(),o=!0),o&&this.updateConditionStatusesAndValues(n,r),i&&this.updateJoinOperatorsDisabled(),this.lastUiCompletePosition=n}getModelAsString(e){return this.params.getHandler()?.getModelAsString?.(e)??""}getPlaceholderText(e,t){let n=this.translate(e);if("function"==typeof this.filterPlaceholder){let e=this.eTypes[t].getValue(),i=this.translate(e);n=this.filterPlaceholder({filterOptionKey:e,filterOption:i,placeholder:n})}else"string"==typeof this.filterPlaceholder&&(n=this.filterPlaceholder);return n}resetPlaceholder(){let e=this.getLocaleTextFunc();this.forEachInput((t,n,i,r)=>{if(!(t instanceof lR))return;let o=0===n&&r>1?e("ariaFilterFromValue","Filter from value"):0===n?e("ariaFilterValue","Filter Value"):e("ariaFilterToValue","Filter to Value");t.setInputPlaceholder(this.getPlaceholderText(0===n&&r>1?"inRangeStart":0===n?"filterOoo":"inRangeEnd",i)),t.setInputAriaLabel(o)})}setElementValue(e,t,n){e instanceof lR&&e.setValue(null!=t?String(t):null,!0)}setElementDisplayed(e,t){sw(e)&&rZ(e.getGui(),t)}setElementDisabled(e,t){sw(e)&&rX(e.getGui(),t)}attachElementOnChange(e,t){e instanceof lR&&e.onValueChange(t)}forEachInput(e){this.getConditionTypes().forEach((t,n)=>{this.forEachPositionTypeInput(n,t,e)})}forEachPositionInput(e,t){let n=this.getConditionType(e);this.forEachPositionTypeInput(e,n,t)}forEachPositionTypeInput(e,t,n){let i=gg(t,this.optionsFactory),r=this.getInputs(e);for(let t=0;t<r.length;t++){let o=r[t];null!=o&&n(o,t,e,i)}}isConditionDisabled(e,t){return!!this.isReadOnly()||0!==e&&e>t+1}isConditionBodyVisible(e){return gg(this.getConditionType(e),this.optionsFactory)>0}isConditionUiComplete(e){return!(e>=this.getNumConditions()||"empty"===this.getConditionType(e)||this.getValues(e).some(e=>null==e))}getNumConditions(){return this.eTypes.length}getUiCompleteConditions(){let e=[];for(let t=0;t<this.getNumConditions();t++)this.isConditionUiComplete(t)&&e.push(this.createCondition(t));return e}createMissingConditionsAndOperators(){if(!this.isReadOnly())for(let e=this.getNumConditions();e<this.numAlwaysVisibleConditions;e++)this.createJoinOperatorPanel(),this.createOption()}resetUiToDefaults(e){this.removeConditionsAndOperators(this.isReadOnly()?1:this.numAlwaysVisibleConditions),this.eTypes.forEach(e=>this.resetType(e)),this.eJoinAnds.forEach((e,t)=>this.resetJoinOperatorAnd(e,t,this.joinOperatorId+t)),this.eJoinOrs.forEach((e,t)=>this.resetJoinOperatorOr(e,t,this.joinOperatorId+t)),this.joinOperatorId++,this.forEachInput(e=>this.resetInput(e)),this.resetPlaceholder(),this.createMissingConditionsAndOperators(),this.lastUiCompletePosition=null,this.updateUiVisibility(),e||this.params.onUiChange(this.getUiChangeEventParams())}resetType(e){let t=this.getLocaleTextFunc()("ariaFilteringOperator","Filtering operator");e.setValue(this.optionsFactory.defaultOption,!0).setAriaLabel(t).setDisabled(this.isReadOnly()||this.filterListOptions.length<=1)}resetJoinOperatorAnd(e,t,n){this.resetJoinOperator(e,t,"AND"===this.defaultJoinOperator,this.translate("andCondition"),n)}resetJoinOperatorOr(e,t,n){this.resetJoinOperator(e,t,"OR"===this.defaultJoinOperator,this.translate("orCondition"),n)}resetJoinOperator(e,t,n,i,r){this.updateJoinOperatorDisabled(e.setValue(n,!0).setName(`ag-simple-filter-and-or-${this.getCompId()}-${r}`).setLabel(i),t)}updateJoinOperatorsDisabled(){let e=(e,t)=>
412this.updateJoinOperatorDisabled(e,t);this.eJoinAnds.forEach(e),this.eJoinOrs.forEach(e)}updateJoinOperatorDisabled(e,t){e.setDisabled(this.isReadOnly()||t>0)}resetInput(e){this.setElementValue(e,null),this.setElementDisabled(e,this.isReadOnly())}setConditionIntoUi(e,t){let n=this.mapValuesFromModel(e,this.optionsFactory);this.forEachInput((e,i,r)=>{r===t&&this.setElementValue(e,null!=n[i]?n[i]:null)})}setValueFromFloatingFilter(e){this.forEachInput((t,n,i)=>{this.setElementValue(t,0===n&&0===i?e:null,!0)})}addChangedListeners(e,t){this.isReadOnly()||(e.onValueChange(this.listener),this.forEachPositionInput(t,e=>{this.attachElementOnChange(e,this.listener)}))}hasInvalidInputs(){return!1}isReadOnly(){return!!this.params.readOnly}},gv=class extends oI{constructor(e,t){super(),this.mapValuesFromModel=e,this.defaultOptions=t}init(e){let t=e.filterParams,n=new gh;this.optionsFactory=n,n.init(t,this.defaultOptions),this.filterModelFormatter=this.createManagedBean(new this.FilterModelFormatterClass(n,t)),this.updateParams(e),this.validateModel(e)}refresh(e){if("colDef"===e.source){let t=e.filterParams,n=this.optionsFactory;n.refresh(t,this.defaultOptions),this.filterModelFormatter.updateParams({optionsFactory:n,filterParams:t}),this.updateParams(e)}this.validateModel(e)}updateParams(e){this.params=e}doesFilterPass(e){let t=e.model;if(null==t)return!0;let{operator:n}=t,i=[];n?i.push(...t.conditions??[]):i.push(t);let r=this.params.getValue(e.node);return i[n&&"OR"===n?"some":"every"](t=>this.individualConditionPasses(e,t,r))}getModelAsString(e,t){return this.filterModelFormatter.getModelAsString(e,t)??""}validateModel(e){let{model:t,filterParams:{filterOptions:n,maxNumConditions:i}}=e;if(null==t)return;let r=ud(t)?t.conditions:[t],o=n?.map(e=>"string"==typeof e?e:e.displayKey)??this.defaultOptions;if(!(!r||r.every(e=>void 0!==o.find(t=>t===e.type)))){this.params={...e,model:null},e.onModelChange(null);return}let a=!1,s=this.filterType;if((r&&!r.every(e=>e.filterType===s)||t.filterType!==s)&&(r=r.map(e=>({...e,filterType:s})),a=!0),"number"==typeof i&&r&&r.length>i&&(r=r.slice(0,i),a=!0),a){let n=r.length>1?{...t,filterType:s,conditions:r}:{...r[0],filterType:s};this.params={...e,model:n},e.onModelChange(n)}}individualConditionPasses(e,t,n){let i=this.optionsFactory,r=this.mapValuesFromModel(t,i),o=function(e,t,n){if(null==e)return;let{predicate:i}=e;if(null!=i&&!t.some(e=>null==e))return i(t,n)}(i.getCustomOption(t.type),r,n);return null!=o?o:null==n?this.evaluateNullValue(t.type):this.evaluateNonNullValue(r,n,t,e)}},gy={contains:"Contains",notContains:"NotContains",equals:"TextEquals",notEqual:"TextNotEqual",startsWith:"StartsWith",endsWith:"EndsWith",inRange:"InRange"},gb=class extends oI{constructor(e,t,n){super(),this.optionsFactory=e,this.filterParams=t,this.valueFormatter=n}getModelAsString(e,t){let n=this.getLocaleTextFunc(),i="filterToolPanel"===t;if(!e)return i?dZ(this,"filterSummaryInactive"):null;if(null!=e.operator){let n=(e.conditions??[]).map(e=>this.getModelAsString(e,t)),i="AND"===e.operator?"andCondition":"orCondition";return n.join(` ${dZ(this,i)} `)}{if("blank"===e.type||"notBlank"===e.type)return i?dZ(this,"blank"===e.type?"filterSummaryBlank":"filterSummaryNotBlank"):n(e.type,e.type);let{displayKey:t,displayName:r,numberOfInputs:o}=this.optionsFactory.getCustomOption(e.type)||{};return t&&r&&0===o?n(t,r):this.conditionToString(e,i,"inRange"===e.type||2===o,t,r)}}updateParams(e){let{optionsFactory:t,filterParams:n}=e;this.optionsFactory=t,this.filterParams=n}conditionForToolPanel(e,t,n,i,r,o){let a,s=this.getTypeKey(e);if(s&&(a=dZ(this,s)),r&&o&&(a=this.getLocaleTextFunc()(r,o)),null!=a)if(t)return`${a} ${dZ(this,"filterSummaryInRangeValues",[n(),i()])}`;else return`${a} ${n()}`;return null}getTypeKey(e){let t=this.filterTypeKeys[e];return t?`filterSummary${t}`:null}formatValue(e){let t=this.valueFormatter;return t?t(e??null)??"":String(e)}},gx=class extends sk{constructor(){super(...arguments),this.defaultDebounceMs=0}setLastTypeFromModel(e){let t;if(!e){this.lastType=this.optionsFactory.defaultOption;return}t=e.operator?e.conditions[0]:e,this.lastType=t.type}canWeEditAfterModelFromParentFilter(e){return e?!e.operator&&this.isTypeEditable(e.type):this.isTypeEditable(this.lastType)}init(e){this.params=e;let t=this.gos.get("enableFilterHandlers");this.reactive=t,this.setParams(e),t&&this.onModelUpdated(e.model)}
412setParams(e){let t=new gh;this.optionsFactory=t,t.init(e.filterParams,this.defaultOptions),this.filterModelFormatter=this.createManagedBean(new this.FilterModelFormatterClass(t,e.filterParams)),this.setSimpleParams(e,!1)}setSimpleParams(e,t=!0){let n=this.optionsFactory.defaultOption;t||(this.lastType=n),this.readOnly=!!e.filterParams.readOnly;let i=this.isTypeEditable(n);this.setEditable(i)}refresh(e){this.params=e;let t=this.reactive;if(t&&"colDef"!==e.source||this.updateParams(e),t){let{source:t,model:n}=e;if("dataChanged"===t||"ui"===t)return;this.onModelUpdated(n)}}updateParams(e){let t=this.optionsFactory;t.refresh(e.filterParams,this.defaultOptions),this.setSimpleParams(e),this.filterModelFormatter.updateParams({optionsFactory:t,filterParams:e.filterParams})}onParentModelChanged(e,t){t?.afterFloatingFilter||t?.afterDataChange||this.onModelUpdated(e)}hasSingleInput(e){let t=this.optionsFactory.getCustomOption(e)?.numberOfInputs;return null==t||1==t}isTypeEditable(e){return!!e&&!this.readOnly&&this.hasSingleInput(e)&&0>["inRange","empty","blank","notBlank"].indexOf(e)}getAriaLabel(e){let t=this.beans.colNames.getDisplayNameForColumn(e.column,"header",!0);return`${t} ${this.getLocaleTextFunc()("ariaFilterInput","Filter Input")}`}},gw={tag:"div",cls:"ag-floating-filter-input",role:"presentation",children:[{tag:"ag-input-text-field",ref:"eReadOnlyText"},{tag:"div",ref:"eDateWrapper",cls:"ag-date-floating-filter-wrapper"}]},gC={tag:"div",cls:"ag-filter-filter",children:[{tag:"ag-input-text-field",ref:"eDateInput",cls:"ag-date-filter"}]},gS=class extends oI{constructor(e){super(),this.params=e,this.eInput=null,this.onValueChanged=()=>{}}setupGui(e){this.eInput=this.createManagedBean(new lE(this.params?.config));let t=this.eInput.getGui();e.appendChild(t);let n=e=>this.onValueChanged(e);this.addManagedListeners(t,{input:n,keydown:n})}setEditable(e){this.eInput.setDisabled(!e)}getValue(){return this.eInput.getValue()}setValue(e,t){this.eInput.setValue(e,t)}setValueChangedListener(e){this.onValueChanged=e}setParams({ariaLabel:e,autoComplete:t}){let{eInput:n}=this;n.setInputAriaLabel(e),void 0!==t&&n.setAutoComplete(t)}};function g_(e){let t=e?.trim();return""===t?e:t}function gk(e,t){let{filter:n,filterTo:i,type:r}=e||{};return[n||null,i||null].slice(0,gg(r,t))}var gM={tag:"div",ref:"eFloatingFilterInputContainer",cls:"ag-floating-filter-input",role:"presentation"},gT=class extends gx{constructor(){super(...arguments),this.eFloatingFilterInputContainer=null,this.defaultDebounceMs=500}postConstruct(){this.setTemplate(gM)}onModelUpdated(e){this.setLastTypeFromModel(e),this.setEditable(this.canWeEditAfterModelFromParentFilter(e)),this.inputSvc.setValue(this.filterModelFormatter.getModelAsString(e))}setParams(e){this.setupFloatingFilterInputService(e),super.setParams(e),this.setTextInputParams(e)}setupFloatingFilterInputService(e){this.inputSvc=this.createFloatingFilterInputService(e),this.inputSvc.setupGui(this.eFloatingFilterInputContainer)}setTextInputParams(e){let t=e.browserAutoComplete??!1,{inputSvc:n,defaultDebounceMs:i,readOnly:r}=this;if(n.setParams({ariaLabel:this.getAriaLabel(e),autoComplete:t}),this.applyActive=dJ(e.filterParams),!r){let t=dX(e.filterParams,i),r=oO(this,this.syncUpWithParentFilter.bind(this),t);n.setValueChangedListener(r)}}updateParams(e){super.updateParams(e),this.setTextInputParams(e)}recreateFloatingFilterInputService(e){let{inputSvc:t}=this,n=t.getValue();r8(this.eFloatingFilterInputContainer),this.destroyBean(t),this.setupFloatingFilterInputService(e),t.setValue(n,!0)}syncUpWithParentFilter(e){let t=e.key===sJ,n=this.reactive;if(n&&this.params.onUiChange(),this.applyActive&&!t)return;let{inputSvc:i,params:r,lastType:o}=this,a=i.getValue();if(r.filterParams.trimInput&&(a=g_(a),i.setValue(a,!0)),n){let e=r.model,t=this.convertValue(a),n=null==t?null:{...e??{filterType:this.filterType,type:o??this.optionsFactory.defaultOption},filter:t};r.onModelChange(n,{afterFloatingFilter:!0})}else r.parentFilterInstance(e=>{e?.onFloatingFilterChanged(o||null,a||null)})}convertValue(e){return e||null}setEditable(e){this.inputSvc.setEditable(e)}},gD=["contains","notContains","equals","notEqual","startsWith","endsWith","blank","notBlank"],gR=class extends gm{constructor(){super("textFilter",gk,gD),this.filterType="text",this.eValuesFrom=[],this.eValuesTo=[],this.defaultDebounceMs=500}createCondition(e){let t=this.getConditionType(e),n={filterType:this.filterType,type:t},i=this.getValues(e);return i.length>0&&(n.filter=i[0]),i.length>1&&(n.filterTo=i[1]),n}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}getInputs(e){let{eValuesFrom:t,eValuesTo:n}=this;return e>=t.length?[null,null]:[t[e],n[e]]}getValues(e){let t=[];return this.forEachPositionInput(e,(e,n,i,r)=>{n<r&&t.push(rw(e.getValue()))}),t}createEValue(){let e=om({tag:"div",cls:"ag-filter-body",role:"presentation"}),{eValuesFrom:t,eValuesTo:n}=this;return this.createFromToElement(e,t,"from"),this.createFromToElement(e,n,"to"),e}createFromToElement(e,t,n){let i=this.createManagedBean(new lE);i.addCss(`ag-filter-${n}`),i.addCss("ag-filter-filter"),t.push(i),e.appendChild(i.getGui())}removeEValues(e,t){let n=n=>this.removeComponents(n,e,t),{eValuesFrom:i,eValuesTo:r}=this;
412n(i),n(r)}},gI=class extends gb{constructor(){super(...arguments),this.filterTypeKeys=gy}conditionToString(e,t,n,i,r){let{filter:o,filterTo:a,type:s}=e;if(t){let e=e=>()=>dZ(this,"filterSummaryTextQuote",[e]),t=this.conditionForToolPanel(s,n,e(o),e(a),i,r);if(null!=t)return t}return n?`${o}-${a}`:null!=o?`${o}`:`${s}`}},gA=({filterOption:e,value:t,filterText:n})=>{if(null==n)return!1;switch(e){case"contains":return t.includes(n);case"notContains":return!t.includes(n);case"equals":return t===n;case"notEqual":return t!=n;case"startsWith":return 0===t.indexOf(n);case"endsWith":{let e=t.lastIndexOf(n);return e>=0&&e===t.length-n.length}default:return!1}},gP=e=>e,gE=e=>null==e?null:e.toString().toLowerCase(),gL=class extends gv{constructor(){super(gk,gD),this.filterType="text",this.FilterModelFormatterClass=gI}updateParams(e){super.updateParams(e);let t=e.filterParams;this.matcher=t.textMatcher??gA,this.formatter=t.textFormatter??(t.caseSensitive?gP:gE)}evaluateNullValue(e){return!!e&&["notEqual","notContains","blank"].indexOf(e)>=0}evaluateNonNullValue(e,t,n,i){let r=e.map(e=>this.formatter(e))||[],o=this.formatter(t),{api:a,colDef:s,column:l,context:d,filterParams:{textFormatter:u}}=this.params;if("blank"===n.type)return gf(t);if("notBlank"===n.type)return!gf(t);let c={api:a,colDef:s,column:l,context:d,node:i.node,data:i.data,filterOption:n.type,value:o,textFormatter:u};return r.some(e=>this.matcher({...c,filterText:e}))}processModelToApply(e){if(e&&this.params.filterParams.trimInput){let t=e=>{let t={...e},{filter:n,filterTo:i}=e;return n&&(t.filter=g_(n)??null),i&&(t.filterTo=g_(i)??null),t};return ud(e)?{...e,conditions:e.conditions.map(t)}:t(e)}return e}},gF=class extends gT{constructor(){super(...arguments),this.FilterModelFormatterClass=gI,this.filterType="text",this.defaultOptions=gD}createFloatingFilterInputService(){return this.createManagedBean(new gS)}},gO={moduleName:"ColumnFilter",version:o1,beans:[gs,gd],dynamicBeans:{headerFilterCellCtrl:gr},icons:{filter:"filter",filterActive:"filter"},apiFunctions:{isColumnFilterPresent:function(e){let t=e.filterManager;return!!t?.isColumnFilterPresent()||!!t?.isAggregateFilterPresent()},getColumnFilterInstance:function(e,t){return e.filterManager?.getColumnFilterInstance(t)??Promise.resolve(void 0)},destroyFilter:function(e,t){let n=e.colModel.getColDefCol(t);if(n)return e.colFilter?.destroyFilter(n,"api")},setFilterModel:function(e,t){e.frameworkOverrides.wrapIncoming(()=>e.filterManager?.setFilterModel(t))},getFilterModel:function(e){return e.filterManager?.getFilterModel()??{}},getColumnFilterModel:function(e,t,n){let{gos:i,colModel:r,colFilter:o}=e;n&&!i.get("enableFilterHandlers")&&(at(288),n=!1);let a=r.getColDefCol(t);return a?o?.getModelForColumn(a,n)??null:null},setColumnFilterModel:function(e,t,n){return e.filterManager?.setColumnFilterModel(t,n)??Promise.resolve()},showColumnFilter:function(e,t){let n=e.colModel.getCol(t);n?e.menuSvc?.showFilterMenu({column:n,containerType:"columnFilter",positionBy:"auto"}):an(12,{colKey:t})},hideColumnFilter:function(e){e.menuSvc?.hideFilterMenu()},getColumnFilterHandler:function(e,t){let n=e.colModel.getCol(t);return n?e.colFilter?.getHandler(n,!0):void an(12,{colKey:t})},doFilterAction:function(e,t){let{colModel:n,colFilter:i,gos:r}=e;if(!r.get("enableFilterHandlers"))return void at(287);let{colId:o,action:a}=t;if(o){let e=n.getColById(o);e&&i?.updateModel(e,a)}else i?.updateAllModels(a)}},dependsOn:[{moduleName:"FilterCore",version:o1,beans:[gl],apiFunctions:{isAnyFilterPresent:function(e){return!!e.filterManager?.isAnyFilterPresent()},onFilterChanged:function(e,t="api"){e.filterManager?.onFilterChanged({source:t
vendor: 5,007 bytes, line 412
412})}},css:[".ag-set-filter{--ag-indentation-level:0}.ag-set-filter-item{align-items:center;display:flex;height:100%}:where(.ag-ltr) .ag-set-filter-item{padding-left:calc(var(--ag-widget-container-horizontal-padding) + var(--ag-indentation-level)*var(--ag-set-filter-indent-size))}:where(.ag-rtl) .ag-set-filter-item{padding-right:calc(var(--ag-widget-container-horizontal-padding) + var(--ag-indentation-level)*var(--ag-set-filter-indent-size))}.ag-set-filter-item-checkbox{display:flex;height:100%;width:100%}.ag-set-filter-group-icons{display:block;>*{cursor:pointer}}:where(.ag-ltr) .ag-set-filter-group-icons{margin-right:var(--ag-widget-container-horizontal-padding)}:where(.ag-rtl) .ag-set-filter-group-icons{margin-left:var(--ag-widget-container-horizontal-padding)}.ag-filter-body-wrapper{display:flex;flex-direction:column}:where(.ag-menu:not(.ag-tabs) .ag-filter) .ag-filter-body-wrapper,:where(.ag-menu:not(.ag-tabs) .ag-filter)>:not(.ag-filter-wrapper){min-width:180px}.ag-filter-filter{flex:1 1 0px}.ag-filter-condition{display:flex;justify-content:center}.ag-floating-filter-body{display:flex;flex:1 1 auto;height:100%;position:relative}.ag-floating-filter-full-body{align-items:center;display:flex;flex:1 1 auto;height:100%;overflow:hidden;width:100%}:where(.ag-floating-filter-full-body)>div{flex:1 1 auto}.ag-floating-filter-input{align-items:center;display:flex;width:100%;>*{flex:1 1 auto}:where(.ag-input-field-input[type=date]),:where(.ag-input-field-input[type=datetime-local]){width:1px}}.ag-floating-filter-button{display:flex;flex:none}.ag-date-floating-filter-wrapper{display:flex}.ag-set-floating-filter-input :where(input)[disabled]{pointer-events:none}.ag-floating-filter-button-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;height:var(--ag-icon-size);width:var(--ag-icon-size)}.ag-filter-loading{align-items:unset;background-color:var(--ag-chrome-background-color);height:100%;padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding);position:absolute;width:100%;z-index:1;:where(.ag-menu) &{background-color:var(--ag-menu-background-color)}}.ag-filter-separator{border-top:solid var(--ag-border-width) var(--menu-separator-color)}:where(.ag-filter-select) .ag-picker-field-wrapper{width:0}.ag-filter-condition-operator{height:17px}:where(.ag-ltr) .ag-filter-condition-operator-or{margin-left:calc(var(--ag-spacing)*2)}:where(.ag-rtl) .ag-filter-condition-operator-or{margin-right:calc(var(--ag-spacing)*2)}.ag-set-filter-select-all{padding-top:var(--ag-widget-container-vertical-padding)}.ag-filter-no-matches,.ag-set-filter-list{height:calc(var(--ag-list-item-height)*6)}.ag-filter-no-matches{padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding)}.ag-set-filter-tree-list{height:calc(var(--ag-list-item-height)*10)}.ag-set-filter-filter{margin-left:var(--ag-widget-container-horizontal-padding);margin-right:var(--ag-widget-container-horizontal-padding);margin-top:var(--ag-widget-container-vertical-padding)}.ag-filter-to{margin-top:var(--ag-widget-vertical-spacing)}.ag-mini-filter{margin:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding)}:where(.ag-ltr) .ag-set-filter-add-group-indent{margin-left:calc(var(--ag-icon-size) + var(--ag-widget-container-horizontal-padding))}:where(.ag-rtl) .ag-set-filter-add-group-indent{margin-right:calc(var(--ag-icon-size) + var(--ag-widget-container-horizontal-padding))}:where(.ag-filter-menu) .ag-set-filter-list{min-width:200px}.ag-filter-virtual-list-item:focus-visible{box-shadow:inset var(--ag-focus-shadow)}.ag-filter-apply-panel{display:flex;justify-content:flex-end;overflow:hidden;padding:var(--ag-widget-vertical-spacing) var(--ag-widget-container-horizontal-padding) var(--ag-widget-container-vertical-padding)}.ag-filter-apply-panel-button{line-height:1.5}:where(.ag-ltr) .ag-filter-apply-panel-button{margin-left:calc(var(--ag-spacing)*2)}:where(.ag-rtl) .ag-filter-apply-panel-button{margin-right:calc(var(--ag-spacing)*2)}.ag-simple-filter-body-wrapper{display:flex;flex-direction:column;min-height:calc(var(--ag-list-item-height) + var(--ag-widget-container-vertical-padding) + var(--ag-widget-vertical-spacing));overflow-y:auto;padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding);padding-bottom:calc(var(--ag-widget-container-vertical-padding) - var(--ag-widget-vertical-spacing));&>*{margin-bottom:var(--ag-widget-vertical-spacing)}:where(.ag-resizer-wrapper){margin:0}}.ag-multi-filter-menu-item{margin:var(--ag-spacing) 0}.ag-multi-filter-group-title-bar{background-color:transparent;color:var(--ag-header-text-color);font-weight:500;padding:calc(var(--ag-spacing)*1.5) var(--ag-spacing)}.ag-group-filter-field-select-wrapper{display:flex;flex-direction:column;gap:var(--ag-widget-vertical-spacing);padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding)}"],dependsOn:[
412{moduleName:"ClientSideRowModelFilter",version:o1,rowModels:["clientSide"],beans:[gi]}]},go,{moduleName:"FilterValue",version:o1,beans:[gu]},{moduleName:"SharedMenu",version:o1,beans:[cd],apiFunctions:{showColumnMenu:function(e,t){let n=e.colModel.getCol(t);n?e.menuSvc?.showColumnMenu({column:n,positionBy:"auto"}):an(12,{colKey:t})},hidePopupMenu:function(e){e.menuSvc?.hidePopupMenu()}}}]},gN={moduleName:"TextFilter",version:o1,dependsOn:[gO],userComponents:{agTextColumnFilter:{classImp:gR,params:{useForm:!0}},agTextColumnFloatingFilter:gF},dynamicBeans:{agTextColumnFilterHandler:gL}},gB={tag:"div",cls:"ag-cell-wrapper ag-cell-edit-wrapper ag-checkbox-edit",children:[{tag:"ag-checkbox",ref:"eEditor",role:"presentation"}]},gz={tag:"div",cls:"ag-large-text",children:[{tag:"ag-input-text-area",ref:"eEditor",cls:"ag-large-text-input"}]},gj={tag:"div",cls:"ag-cell-edit-wrapper",children:[{tag:"ag-select",ref:"eEditor",cls:"ag-cell-editor"}]},gV=(e,t=!1)=>{if(void 0!==e)return p3(e)||t&&"editing"===e.state},gH=(e,t,n)=>{if(e)for(let i=0,r=e.length;i<r;++i){let r=e[i];if(r.data&&(gV(t?.getEdit({rowNode:r,column:n}))||gV(t?.getEdit({rowNode:r.pinnedSibling,column:n})))||gH(r.childrenAfterGroup,t,n))return!0}},gG=new Set(["undo","redo","paste","bulk","rangeSvc"]),gW=new Set(["ui","api"]),g$={paste:"api",rangeSvc:"api",fillHandle:"api",cellClear:"api",bulk:"api"},gU=new Set(Object.keys(g$)),gq=new Set(["paste","rangeSvc","renderer","cellClear","redo","undo"]),gK={cancel:!0,source:"api"},gY={cancel:!1,source:"api"},gZ={checkSiblings:!0},gX={force:!0,suppressFlash:!0},gJ=class extends oI{constructor(){super(...arguments),this.beanName="selectionColSvc"}postConstruct(){this.addManagedPropertyListener("rowSelection",e=>{this.onSelectionOptionsChanged(e.currentValue,e.previousValue,se(e.source))}),this.addManagedPropertyListener("selectionColumnDef",this.updateColumns.bind(this))}addColumns(e){let t=this.columns;if(null!=t){e.list=t.list.concat(e.list),e.tree=t.tree.concat(e.tree);for(let t of(e.map={},e.list))e.map[t.getId()]=t}}createColumns(e,t){let n=()=>{a4(this.beans,this.columns?.tree),this.columns=null},i=e.treeDepth,r=this.columns?.treeDepth??-1,o=this.generateSelectionCols();if(aZ(o,this.columns?.list??[],(e,t)=>e.getColId()===t.getColId())&&r==i)return;n();let{colGroupSvc:a}=this.beans,s=a?.findDepth(e.tree)??0,l=a?.balanceTreeForAutoCols(o,s)??[];this.columns={list:o,tree:l,treeDepth:s,map:{}},t(e=>e?[...o,...e.filter(e=>!a8(e))]:null)}updateColumns(e){let t=se(e.source);for(let n of this.columns?.list??[]){let i=this.createSelectionColDef(e.currentValue);n.setColDef(i,null,t),sh(this.beans,{state:[{...i,colId:n.getColId()}]},t)}}getColumn(e){return this.columns?.list.find(t=>st(t,e))??null}getColumns(){return this.columns?.list??null}isSelectionColumnEnabled(){let{gos:e,beans:t}=this,n=e.get("rowSelection");if("object"!=typeof n||!ad(e))return!1;let i=(t.autoColSvc?.getColumns()?.length??0)>0;if("autoGroupColumn"===n.checkboxLocation&&i)return!1;let r=!!aS(n),o=a_(n);return r||o}createSelectionColDef(e){let{gos:t}=this,n=e??t.get("selectionColumnDef"),i=t.get("enableRtl"),{rowSpan:r,spanRows:o,...a}=n??{};return{width:50,resizable:!1,suppressHeaderMenuButton:!0,sortable:!1,suppressMovable:!0,lockPosition:i?"right":"left",comparator(e,t,n,i){let r=n.isSelected();return r===i.isSelected()?0:r?1:-1},editable:!1,suppressFillHandle:!0,pinned:null,...a,colId:a1,chartDataType:"excluded"}}generateSelectionCols(){if(!this.isSelectionColumnEnabled())return[];let e=this.createSelectionColDef(),t=e.colId;this.gos.validateColDef(e,t,!0);let n=new aG(e,null,t,!1);return this.createBean(n),[n]}onSelectionOptionsChanged(e,t,n){let i=t&&"string"!=typeof t?aS(t):void 0,r=e&&"string"!=typeof e?aS(e):void 0,o=t&&"string"!=typeof t?a_(t):void 0,a=e&&"string"!=typeof e?a_(e):void 0,s=ak(e),l=ak(t);(i!==r||o!==a||s!==l)&&this.beans.colModel.refreshAll(n)}destroy(){a4(this.beans,this.columns?.tree),super.destroy()}refreshVisibility(e,t,n){if(!this.columns?.list.length)return;let i=e.length+t.length+n.length;if(0===i)return;let r=this.columns.list[0];r.isVisible()&&(this.beans.rowNumbersSvc?.getColumn(a2)?2:1)===i&&(()=>{let i;switch(r.pinned){case"left":case!0:i=e;break;case"right":i=n;break;default:i=t}i&&aJ(i,r)})()}};function gQ(e){return cS(e)?e.pinnedSibling:e.footer?e.sibling:e}function g0(e,t){return(0!==e||0!==t)&&(e>0&&t>0?void 0:e>0)}var g1={moduleName:"RowSelection",version:o1,rowModels:["clientSide","infinite","viewport"],beans:[class extends cI{constructor(){super(...arguments),this.beanName="selectionSvc",this.selectedNodes=new Map,this.detailSelection=new Map,this.masterSelectsDetail=!1}
412postConstruct(){super.postConstruct();let{gos:e}=this;this.mode=aI(e),this.groupSelectsDescendants=aL(e),this.groupSelectsFiltered="filteredDescendants"===aP(e),this.masterSelectsDetail="detail"===aF(e),this.addManagedPropertyListeners(["groupSelectsChildren","groupSelectsFiltered","rowSelection"],()=>{let t=aL(e),n=aI(e),i="filteredDescendants"===aP(e);this.masterSelectsDetail="detail"===aF(e),(t!==this.groupSelectsDescendants||i!==this.groupSelectsFiltered||n!==this.mode)&&(this.deselectAllRowNodes({source:"api"}),this.groupSelectsDescendants=t,this.groupSelectsFiltered=i,this.mode=n)}),this.addManagedEventListeners({rowSelected:this.onRowSelected.bind(this)})}destroy(){super.destroy(),this.resetNodes()}handleSelectionEvent(e,t,n){if(this.isRowSelectionBlocked(t))return 0;let i=this.inferNodeSelections(t,e.shiftKey,e.metaKey||e.ctrlKey,n);if(null==i)return 0;if(this.selectionCtx.selectAll=!1,"select"in i)return i.reset?this.resetNodes():this.selectRange(i.deselect,!1,n),this.selectRange(i.select,!0,n);{let t=i.checkFilteredNodes?function e(t){let n=!1===t.isSelected(),i=t.childrenAfterFilter?.some(e)??!1;return n||i}(i.node):i.newValue;return this.setNodesSelected({nodes:[i.node],newValue:t,clearSelection:i.clearSelection,keepDescendants:i.keepDescendants,event:e,source:n})}}setNodesSelected({newValue:e,clearSelection:t,suppressFinishActions:n,nodes:i,event:r,source:o,keepDescendants:a=!1}){if(0===i.length)return 0;let{gos:s}=this;if(!ad(s)&&e)return at(132),0;if(i.length>1&&!this.isMultiSelect())return at(130),0;let l=0;for(let t=0;t<i.length;t++){let n=gQ(i[t]);if(n.rowPinned&&!cS(n)){at(59);continue}if(void 0===n.id){at(60);continue}!(this.groupSelectsFiltered&&n.group&&!s.get("treeData"))&&this.selectRowNode(n,e,r,o)&&(this.detailSelection.delete(n.id),l++),this.groupSelectsDescendants&&n.childrenAfterGroup?.length&&(l+=this.selectChildren(n,e,o))}return!n&&(1===i.length&&"api"===o&&this.selectionCtx.setRoot(gQ(i[0])),e&&(t||!this.isMultiSelect())&&(l+=this.clearOtherNodes(gQ(i[0]),a,o)),l>0&&(this.updateGroupsFromChildrenSelections(o),this.dispatchSelectionChanged(o))),l}selectRange(e,t,n){let i=0;return e.forEach(e=>{let r=gQ(e);r.group&&this.groupSelectsDescendants||this.selectRowNode(r,t,void 0,n)&&i++}),i>0&&(this.updateGroupsFromChildrenSelections(n),this.dispatchSelectionChanged(n)),i}selectChildren(e,t,n){let i=this.groupSelectsFiltered?e.childrenAfterAggFilter:e.childrenAfterGroup;return i?this.setNodesSelected({newValue:t,clearSelection:!1,suppressFinishActions:!0,source:n,nodes:i}):0}getSelectedNodes(){return Array.from(this.selectedNodes.values())}getSelectedRows(){let e=[];return this.selectedNodes.forEach(t=>t.data&&e.push(t.data)),e}getSelectionCount(){return this.selectedNodes.size}filterFromSelection(e){let t=new Map;this.selectedNodes.forEach((n,i)=>{e(n)&&t.set(i,n)}),this.selectedNodes=t}updateGroupsFromChildrenSelections(e,t){if(!this.groupSelectsDescendants)return!1;let{gos:n,rowModel:i}=this.beans;if(!aa(n,i))return!1;let r=i.rootNode;if(!r)return!1;t||((t=new c9(!0,r)).active=!1);let o=!1;return t.forEachChangedNodeDepthFirst(t=>{if(t!==r){let n=this.calculateSelectedFromChildren(t);o=this.selectRowNode(t,null!==n&&n,void 0,e)||o}}),o}clearOtherNodes(e,t,n){let i=new Map,r=0;return this.selectedNodes.forEach(o=>{let a=o.id==e.id;if((!t||!function(e,t){let n=t.parent;for(;n;){if(n===e)return!0;n=n.parent}return!1}(e,o))&&!a){let e=this.selectedNodes.get(o.id);r+=this.setNodesSelected({nodes:[e],newValue:!1,clearSelection:!1,suppressFinishActions:!0,source:n}),this.groupSelectsDescendants&&o.parent&&i.set(o.parent.id,o.parent)}}
412),i.forEach(e=>{let t=this.calculateSelectedFromChildren(e);this.selectRowNode(e,null!==t&&t,void 0,n)}),r}onRowSelected(e){let t=e.node;this.groupSelectsDescendants&&t.group||(t.isSelected()?this.selectedNodes.set(t.id,t):this.selectedNodes.delete(t.id))}syncInRowNode(e,t){this.syncInOldRowNode(e,t),this.syncInNewRowNode(e)}createDaemonNode(e){if(!e.id)return;let t=new dB(this.beans);return t.id=e.id,t.data=e.data,t.__selected=e.__selected,t.level=e.level,t}syncInOldRowNode(e,t){t&&e.id!==t.id&&this.selectedNodes.get(t.id)==e&&this.selectedNodes.set(t.id,t)}syncInNewRowNode(e){this.selectedNodes.has(e.id)?(e.__selected=!0,this.selectedNodes.set(e.id,e)):e.__selected=!1}reset(e){let t=this.getSelectionCount();this.resetNodes(),t&&this.dispatchSelectionChanged(e)}resetNodes(){this.selectedNodes.forEach(e=>{this.selectRowNode(e,!1)}),this.selectedNodes.clear()}getBestCostNodeSelection(){let{gos:e,rowModel:t}=this.beans;if(!aa(e,t))return;let n=t.getTopLevelNodes();if(null===n)return;let i=[];return!function e(t){for(let n=0,r=t.length;n<r;n++){let r=t[n];r.isSelected()?i.push(r):r.group&&r.childrenAfterGroup&&e(r.childrenAfterGroup)}}(n),i}isEmpty(){return 0===this.getSelectionCount()}deselectAllRowNodes({source:e,selectAll:t}){let n=aa(this.gos),i=!1,r=t=>{let n=this.selectRowNode(gQ(t),!1,void 0,e);i||(i=n)};if("currentPage"===t||"filtered"===t){if(!n)return void an(102);this.getNodesToSelect(t).forEach(r)}else this.selectedNodes.forEach(r),this.reset(e);if(this.selectionCtx.selectAll=!1,n&&this.groupSelectsDescendants){let t=this.updateGroupsFromChildrenSelections(e);i||(i=t)}i&&this.dispatchSelectionChanged(e)}getSelectedCounts(e){let t=0,n=0;return this.getNodesToSelect(e).forEach(e=>{(!this.groupSelectsDescendants||!e.group)&&(e.isSelected()?t++:e.selectable&&n++)}),{selectedCount:t,notSelectedCount:n}}getSelectAllState(e){let{selectedCount:t,notSelectedCount:n}=this.getSelectedCounts(e);return g0(t,n)??null}hasNodesToSelect(e){return this.getNodesToSelect(e).filter(e=>e.selectable).length>0}getNodesToSelect(e){if(!this.canSelectAll())return[];let t=[],n=e=>t.push(e);if("currentPage"===e)return this.forEachNodeOnPage(e=>{if(!e.group)return void n(e);if(!e.expanded&&!e.footer){let t=e=>{n(e),e.childrenAfterFilter?.forEach(t)};t(e);return}this.groupSelectsDescendants||n(e)}),t;let i=this.beans.rowModel;return"filtered"===e?i.forEachNodeAfterFilter(n):i.forEachNode(n),t}forEachNodeOnPage(e){let{pageBounds:t,rowModel:n}=this.beans,i=t.getFirstRow(),r=t.getLastRow();for(let t=i;t<=r;t++){let i=n.getRow(t);i&&e(i)}}selectAllRowNodes(e){let{gos:t,selectionCtx:n}=this;if(!ad(t))return void at(132);if("string"!=typeof t.get("rowSelection")&&!aA(t))return void at(130);if(!this.canSelectAll())return;let{source:i,selectAll:r}=e,o=!1;if(this.getNodesToSelect(r).forEach(e=>{let t=this.selectRowNode(gQ(e),!0,void 0,i);o||(o=t)}),n.selectAll=!0,aa(t)&&this.groupSelectsDescendants){let e=this.updateGroupsFromChildrenSelections(i);o||(o=e)}o&&this.dispatchSelectionChanged(i)}getSelectionState(){return this.isEmpty()?null:Array.from(this.selectedNodes.keys())}setSelectionState(e,t,n){if(e||(e=[]),!Array.isArray(e))return void an(103);let i=new Set(e),r=[];this.beans.rowModel.forEachNode(e=>{i.has(e.id)&&r.push(e)}),n&&this.resetNodes(),this.setNodesSelected({newValue:!0,nodes:r,source:t})}canSelectAll(){return aa(this.beans.gos)}updateSelectable(e){let{gos:t,rowModel:n}=this.beans;if(!ad(t))return;let i="selectableChanged",r=void 0!==e,o=aa(t)&&this.groupSelectsDescendants,a=[],s=e=>{if(!r||e.group){if(o&&e.group){let t=e.childrenAfterGroup?.some(e=>e.selectable)??!1;this.setRowSelectable(e,t,!0);return}!this.updateRowSelectable(e,!0)&&e.isSelected()&&a.push(e)}};if(o){if(void 0===e){let t=n.rootNode;e=t?new c9(!1,t):void 0}e?.forEachChangedNodeDepthFirst(s,!r,!r)}else n.forEachNode(s);a.length&&this.setNodesSelected({nodes:a,newValue:!1,source:i}),!r&&o&&this.updateGroupsFromChildrenSelections?.(i)}updateSelectableAfterGrouping(e){this.updateSelectable(e),this.groupSelectsDescendants&&this.updateGroupsFromChildrenSelections?.("rowGroupChanged",e)&&this.dispatchSelectionChanged("rowGroupChanged")}refreshMasterNodeState(e,t){let n,i;if(!this.masterSelectsDetail)return;let r=e.detailNode?.detailGridInfo?.api;if(!r)return;let o=(n=0,i=0,r.forEachNode(e=>{e.isSelected()?n++:e.selectable&&i++}),g0(n,i));if(e.isSelected()!==o&&this.selectRowNode(e,o,t,"masterDetail")&&this.dispatchSelectionChanged("masterDetail"),!o){let t=this.detailSelection.get(e.id)??new Set;for(let e of r.getSelectedNodes())t.add(e.id);this.detailSelection.set(e.id,t)}}setDetailSelectionState(e,t,n){if(this.masterSelectsDetail){if(!aA(t))return void at(269);switch(e.isSelected()){case!0:n.selectAll();break;case!1:n.deselectAll();break;case void 0:{let t=this.detailSelection.get(e.id);if(t){let e=[];for(let i of t){let t=n.getRowNode(i);t&&e.push(t)}n.setNodesSelected({nodes:e,newValue:!0,source:"masterDetail"})}}}}}dispatchSelectionChanged(e){this.eventSvc.dispatchEvent({type:"selectionChanged",source:e,selectedNodes:this.getSelectedNodes(),serverSideState:null})}}],dependsOn:[{moduleName:"SharedRowSelection",version:o1,beans:[gJ],apiFunctions:{setNodesSelected:function(e,t){if(!t.nodes.every(e=>
412e.rowPinned&&!cS(e)?(at(59),!1):void 0!==e.id||(at(60),!1)))return;let{nodes:n,source:i,newValue:r}=t;e.selectionSvc?.setNodesSelected({nodes:n,source:i??"api",newValue:r})},selectAll:function(e,t,n="apiSelectAll"){e.selectionSvc?.selectAllRowNodes({source:n,selectAll:t})},deselectAll:function(e,t,n="apiSelectAll"){e.selectionSvc?.deselectAllRowNodes({source:n,selectAll:t})},selectAllFiltered:function(e,t="apiSelectAllFiltered"){e.selectionSvc?.selectAllRowNodes({source:t,selectAll:"filtered"})},deselectAllFiltered:function(e,t="apiSelectAllFiltered"){e.selectionSvc?.deselectAllRowNodes({source:t,selectAll:"filtered"})},selectAllOnCurrentPage:function(e,t="apiSelectAllCurrentPage"){e.selectionSvc?.selectAllRowNodes({source:t,selectAll:"currentPage"})},deselectAllOnCurrentPage:function(e,t="apiSelectAllCurrentPage"){e.selectionSvc?.deselectAllRowNodes({source:t,selectAll:"currentPage"})},getSelectedNodes:function(e){return e.selectionSvc?.getSelectedNodes()??[]},getSelectedRows:function(e){return e.selectionSvc?.getSelectedRows()??[]}}}]},g2=class extends oI{constructor(e){super(),this.rootNode=e,this.nextId=0,this.allNodesMap={},g5(e)}getRowNode(e){return this.allNodesMap[e]}setNewRowData(e){let{selectionSvc:t,pinnedRowModel:n,groupStage:i}=this.beans;t?.reset("rowDataChanged"),n?.isManual()&&n.reset(),this.dispatchRowDataUpdateStarted(e),this.allNodesMap=Object.create(null),this.nextId=0;let r=g5(this.rootNode),o=Array(e.length);r._leafs=o;let a=0,s=i?.getNestedDataGetter(),l=s?new Set:null,d=(e,t)=>{let n=e.level+1;for(let i=0,r=t.length;i<r;++i){let r=t[i];if(!r)continue;let u=this.createRowNode(r,n);if(u.sourceRowIndex=a,o[a++]=u,l&&!l.has(r)){l.add(r),u.treeParent=e;let t=s(r);t&&d(u,t)}}};d(r,e),o.length=a}setImmutableRowData(e,t){let{rootNode:n,gos:i}=this;this.dispatchRowDataUpdateStarted(t);let r=aC(i),o=e.changedRowNodes,{adds:a,updates:s}=o,l=new Set,d=[],u=this.beans.groupStage?.getNestedDataGetter(),c=!!i.get("suppressMaintainUnsortedOrder")&&void 0,h=-1,p=!1,f=(e,t)=>{if(!c&&void 0!==c){let t=e.sourceRowIndex;c=t<=h,h=t}e.data!==t&&(e.updateData(t),a.has(e)||s.add(e),!e.selectable&&e.isSelected()&&d.push(e))},g=(e,t,n)=>{for(let i=0,o=t.length;i<o;++i){let o=t[i];if(!o)continue;let s=this.getRowNode(r({data:o,level:n}));if(s?(f(s,o),p||(p=!!u&&s.treeParent!==e)):(s=this.createRowNode(o,n),a.add(s)),!u||l.has(s)){l.add(s);continue}l.add(s),s.treeParent=e;let d=u(o);d&&g(s,d,n+1)}};g(n,t,0);let m=this.deleteUnusedNodes(l,o,d)||c||a.size>0;if(m){let e=n._leafs??(n._leafs=[]);void 0===c?g7(e,l,o):g8(e,l)&&(o.reordered=!0)}(m||p||s.size)&&(e.rowDataUpdated=!0,this.deselect(d))}deleteUnusedNodes(e,{removals:t},n){let i=this.rootNode._leafs;for(let r=0,o=i.length;r<o;r++){let o=i[r];e.has(o)||(t.add(o),o.isSelected()&&n.push(o),this.deleteNode(o))}return t.size>0}updateRowData(e,t){if(this.dispatchRowDataUpdateStarted(e.add),this.beans.groupStage?.getNestedDataGetter())return at(268),{remove:[],update:[],add:[]};let n=[],i=aC(this.gos),r=this.executeRemove(i,e,t,n),o=this.executeUpdate(i,e,t,n),a=this.executeAdd(e,t);return this.deselect(n),{remove:r,update:o,add:a}}executeRemove(e,{remove:t},{adds:n,updates:i,removals:r},o){let a,s=this.rootNode._leafs,l=s?.length,d=t?.length;if(!d||!l)return[];let u=0,c=l,h=0,p=Array(d);for(let s=0;s<d;++s){let l=this.lookupNode(e,t[s]);if(!l)continue;let d=l.sourceRowIndex;d<c&&(c=d),d>h&&(h=d),l.isSelected()&&o.push(l),this.deleteNode(l),n.delete(l)?(a??(a=new Set),a.add(l)):(i.delete(l),r.add(l)),p[u++]=l}return p.length=u,u&&g6(s,c,h,r,a),p}executeUpdate(e,{update:t},{adds:n,updates:i},r){let o=t?.length;if(!o)return[];let a=Array(o),s=0;for(let l=0;l<o;l++){let o=t[l],d=this.lookupNode(e,o);d&&(d.updateData(o),!d.selectable&&d.isSelected()&&r.push(d),a[s++]=d,n.has(d)||i.add(d))}return a.length=s,a}executeAdd(e,t){var n;let i=(n=this.rootNode)._leafs??(n._leafs=[]),r=i.length,o=e.add,a=o?.length;if(!a)return[];let s=r+a,l=this.sanitizeAddIndex(i,e.addIndex);if(l<r){for(let e=r-1,t=s-1;e>=l;--e){let n=i[e];n.sourceRowIndex=t,i[t--]=n}t.reordered=!0}i.length=s;let d=Array(a),u=t.adds;for(let e=0;e<a;e++){let t=this.createRowNode(o[e],0);u.add(t),t.sourceRowIndex=l,i[l]=t,d[e]=t,l++}return d}
412dispatchRowDataUpdateStarted(e){this.eventSvc.dispatchEvent({type:"rowDataUpdateStarted",firstRowData:e?.length?e[0]:null})}deselect(e){let t="rowDataChanged",n=this.beans.selectionSvc;e.length&&n?.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t}),n?.updateGroupsFromChildrenSelections?.(t),e.length&&this.eventSvc.dispatchEvent({type:"selectionChanged",source:t,selectedNodes:n?.getSelectedNodes()??null,serverSideState:null})}createRowNode(e,t){let n=new dB(this.beans);n.parent=this.rootNode,n.level=t,n.group=!1,n.expanded=!1,n.setDataAndId(e,String(this.nextId++));let i=n.id,r=this.allNodesMap;return r[i]&&at(2,{nodeId:i}),r[i]=n,n}deleteNode(e){e.clearRowTopAndRowIndex();let t=e.id,n=this.allNodesMap;n[t]===e&&delete n[t];let i=e.pinnedSibling;i&&this.beans.pinnedRowModel?.pinRow(i,null)}lookupNode(e,t){if(!e)return g4(this.rootNode._leafs,t);let n=e({data:t,level:0}),i=this.allNodesMap[n];return i||(an(4,{id:n}),null)}sanitizeAddIndex(e,t){let n=e.length;if("number"!=typeof t||t<0||t>=n||Number.isNaN(t))return n;t=Math.ceil(t);let i=this.gos;return t>0&&i.get("treeData")&&i.get("getDataPath")&&(t=g3(e,t)),t}},g3=(e,t)=>{for(let n=0,i=e.length;n<i;n++){let i=e[n];if(i?.rowIndex==t-1)return n+1}return t},g5=e=>{e.group=!0,e.level=-1,e.id="ROOT_NODE_ID",e._leafs?.length!==0&&(e._leafs=[]);let t=[],n=[],i=[],r=[];e.childrenAfterGroup=t,e.childrenAfterSort=n,e.childrenAfterAggFilter=i,e.childrenAfterFilter=r;let o=e.sibling;return o&&(o.childrenAfterGroup=t,o.childrenAfterSort=n,o.childrenAfterAggFilter=i,o.childrenAfterFilter=r,o.childrenMapped=e.childrenMapped),e.updateHasChildren(),e},g4=(e,t)=>{if(e)for(let n=0,i=e.length;n<i;n++){let i=e[n];if(i.data===t)return i}return an(5,{data:t}),null},g6=(e,t,n,i,r)=>{t=Math.max(0,t);for(let o=t,a=e.length;o<a;++o){let a=e[o];o<=n&&(i.has(a)||r?.has(a))||(a.sourceRowIndex=t,e[t++]=a)}e.length=t},g8=(e,t)=>{e.length=t.size;let n=0,i=!1,r=!1;for(let o of t){let t=o.sourceRowIndex;t===n?r||(r=i):(t>=0?r=!0:i=!0,o.sourceRowIndex=n,e[n]=o),++n}return r},g7=(e,t,{removals:n,adds:i})=>{let r=e.length;e.length=t.size;let o=0;for(let t=0;t<r;++t){let i=e[t];!n.has(i)&&(o!==t&&(i.sourceRowIndex=o,e[o]=i),++o)}for(let t of i)t.sourceRowIndex<0&&(t.sourceRowIndex=o,e[o++]=t);e.length=o},g9=e=>{let t=e.childrenAfterSort,n=e.sibling;if(n&&(n.childrenAfterSort=t),t)for(let e=0,n=t.length-1;e<=n;e++){let i=t[e],r=0===e,o=e===n;i.firstChild!==r&&(i.firstChild=r,i.dispatchRowEvent("firstChildChanged")),i.lastChild!==o&&(i.lastChild=o,i.dispatchRowEvent("lastChildChanged")),i.childIndex!==e&&(i.childIndex=e,i.dispatchRowEvent("childIndexChanged"))}},me=class extends oI{constructor(){super(...arguments),this.beanName="sortStage",this.step="sort",this.refreshProps=["postSortRows","groupDisplayType","accentedSort"]}execute(e){let t=this.beans.sortSvc.getSortOptions(),n=t.length>0&&!!e.changedRowNodes&&this.gos.get("deltaSort");this.sort(t,n,e.changedRowNodes,e.changedPath)}sort(e,t,n,i){let r,{gos:o,colModel:a,rowGroupColsSvc:s,rowNodeSorter:l,rowRenderer:d,showRowGroupCols:u}=this.beans,c=o.get("groupMaintainOrder"),h=a.getCols().some(e=>e.isRowGroupActive()),p=s?.columns,f=a.isPivotMode(),g=o.getCallback("postSortRows"),m=!1,v=o=>{let a=f&&o.leafGroup,s=c&&h&&!o.leafGroup;s&&(r??(r=this.shouldSortContainsGroupCols(e)),s&&(s=!r));let d=null;if(s){let e=!1;if(p){let t=o.level+1;t<p.length&&(e=null===p[t].getSort())}e||(d=mi(o))}else!e.length||a||(d=t&&n?mt(l,o,n,i,e):l.doFullSort(o.childrenAfterAggFilter,e));d||(d=o.childrenAfterAggFilter?.slice(0)??[]),m||(m=o.childrenAfterSort?.[0]!==d[0]),o.childrenAfterSort=d,g9(o),g&&g({nodes:o.childrenAfterSort})};if(i?.forEachChangedNodeDepthFirst(v),m&&o.get("groupHideOpenParents")){let e=u?.getShowRowGroupCols();e?.length&&d.refreshCells({columns:e,force:!0})}}shouldSortContainsGroupCols(e){let t=e.length;if(!t)return!1;if(ay(this.gos)){for(let n=0;n<t;++n){let t=e[n].column;if(t.isPrimary()&&t.isRowGroupActive())return!0}return!1}for(let n=0;n<t;++n)if(e[n].column.getColDef().showRowGroup)return!0;return!1}},mt=(e,t,n,i,r)=>{let o=t.childrenAfterAggFilter,a=t.childrenAfterSort;if(!a)return e.doFullSort(o,r);let s=new Set,l=[],{updates:d,adds:u}=n;for(let e=0,t=o.length;e<t;++e){let t=o[e];d.has(t)||u.has(t)||i&&!i.canSkip(t)?l.push({currentPos:l.length,rowNode:t}):s.add(t)}let c=a.filter(e=>s.has(e)).map((e,t)=>({currentPos:t,rowNode:e}));return l.sort((t,n)=>e.compareRowNodes(r,t,n)),mn(e,r,l,c)},mn=(e,t,n,i)=>{let r=0,o=0,a=n.length,s=i.length,l=Array(a+s),d=0;for(;r<a&&o<s;){let a=n[r],s=i[o];0>e.compareRowNodes(t,a,s)?(l[d++]=a.rowNode,++r):(l[d++]=s.rowNode,++o)}for(;r<a;)l[d++]=n[r++].rowNode;for(;o<s;)l[d++]=i[o++].rowNode;return l},mi=e=>{let t=e.childrenAfterSort,n=e.childrenAfterAggFilter,i=t?.length,r=n?.length;if(!i||!r)return null;let o=Array(r),a=new Set;for(let e=0;e<r;++e)a.add(n[e]);let s=0;for(let e=0;e<i;++e){let n=t[e];a.delete(n)&&(o[s++]=n)}if(0===a.size&&s===i)return t;for(let e of a)o[s++]=e;return o.length=s,o},mr=class extends oI{constructor(){super(...arguments),this.beanName="rowModel",this.rootNode=null,this.rowCountReady=!1,this.nodeManager=void 0,this.rowsToDisplay=[],this.rowDataUpdatedPending=!1,this.asyncTransactions=null,this.asyncTransactionsTimer=0,this.started=!1,this.refreshingModel=!1,this.rowNodesCountReady=!1,this.stages=[],this.stagesRefreshPro
412ps=new Map,this.onRowHeightChanged_debounced=oO(this,this.onRowHeightChanged.bind(this),100)}postConstruct(){let e=new dB(this.beans);this.rootNode=e,this.nodeManager=this.createBean(new g2(e));let t=this.refreshModel.bind(this,{step:"group"}),n=this.refreshModel.bind(this,{step:"group",afterColumnsChanged:!0,keepRenderedRows:!0,animate:!this.gos.get("suppressAnimationFrame")});this.addManagedEventListeners({newColumnsLoaded:n,columnRowGroupChanged:t,columnValueChanged:this.onValueChanged.bind(this),columnPivotChanged:this.refreshModel.bind(this,{step:"pivot"}),filterChanged:this.onFilterChanged.bind(this),sortChanged:this.onSortChanged.bind(this),columnPivotModeChanged:t,gridStylesChanged:this.onGridStylesChanges.bind(this),gridReady:this.onGridReady.bind(this),rowExpansionStateChanged:this.onRowGroupOpened.bind(this)}),this.addPropertyListeners()}addPropertyListeners(){let{beans:e,stagesRefreshProps:t}=this,n=[e.groupStage,e.filterStage,e.pivotStage,e.aggStage,e.sortStage,e.filterAggStage,e.flattenStage].filter(e=>!!e);this.stages=n;for(let e=n.length-1;e>=0;--e)for(let i of n[e].refreshProps)t.set(i,e);this.addManagedPropertyListeners([...t.keys()],e=>{let t=e.changeSet?.properties;t&&this.onPropChange(t)}),this.addManagedPropertyListener("rowData",()=>this.onPropChange(["rowData"])),this.addManagedPropertyListener("rowHeight",()=>this.resetRowHeights())}start(){this.started=!0,this.rowNodesCountReady?this.refreshModel({step:"group",rowDataUpdated:!0,newData:!0}):this.setInitialData()}setInitialData(){this.gos.get("rowData")&&this.onPropChange(["rowData"])}ensureRowHeightsValid(e,t,n,i){let r,o=!1;do{r=!1;let a=this.getRowIndexAtPixel(e),s=this.getRowIndexAtPixel(t),l=Math.max(a,n),d=Math.min(s,i);for(let e=l;e<=d;e++){let t=this.getRow(e);if(t.rowHeightEstimated){let e=ac(this.beans,t);t.setRowHeight(e.height),r=!0,o=!0}}r&&this.setRowTopAndRowIndex()}while(r)return o}onPropChange(e){let t,{nodeManager:n,gos:i,beans:r}=this,o=r.groupStage;if(!n)return;let a=new Set(e),s=o?.onPropChange(a);a.has("rowData")?t=i.get("rowData"):s&&(t=o?.extractData()),t&&!Array.isArray(t)&&(t=null,at(1));let l={step:"nothing",changedProps:a};t&&(!s&&!this.isEmpty()&&t.length>0&&i.exists("getRowId")&&!i.get("resetRowDataOnUpdate")?(l.keepRenderedRows=!0,l.animate=!i.get("suppressAnimationFrame"),l.changedRowNodes=new c2,n.setImmutableRowData(l,t)):(l.rowDataUpdated=!0,l.newData=!0,n.setNewRowData(t),this.rowNodesCountReady=!0));let d=l.rowDataUpdated?"group":this.getRefreshedStage(e);d&&(l.step=d,this.refreshModel(l))}
412getRefreshedStage(e){let{stages:t,stagesRefreshProps:n}=this,i=t.length,r=i;for(let t=0,i=e.length;t<i&&r;++t)r=Math.min(r,n.get(e[t])??r);return r<i?t[r].step:null}setRowTopAndRowIndex(e){let{beans:t,rowsToDisplay:n}=this,i=t.environment.getDefaultRowHeight(),r=0,o=al(this.gos,"normal");for(let a=0,s=n.length;a<s;++a){let s=n[a],l=s.id;if(null!=l&&e?.add(l),null==s.rowHeight){let e=ac(t,s,o,i);s.setRowHeight(e.height,e.estimated)}s.setRowTop(r),s.setRowIndex(a),r+=s.rowHeight}}clearRowTopAndRowIndex(e,t){let n=e.active,i=e=>{e?.id==null||t.has(e.id)||e.clearRowTopAndRowIndex()},r=e=>{i(e),i(e.detailNode),i(e.sibling);let t=e.childrenAfterGroup;if(!e.hasChildren()||!t)return;let o=-1==e.level;if(!(n&&!o&&!e.expanded))for(let e=0,n=t.length;e<n;++e)r(t[e])},o=this.rootNode;o&&r(o)}isLastRowIndexKnown(){return!0}getRowCount(){return this.rowsToDisplay.length}getTopLevelRowCount(){let{rootNode:e,rowsToDisplay:t}=this;if(!e||!t.length)return 0;if(t[0]===e)return 1;let n=+!!e.sibling?.displayed;return(e.childrenAfterSort?.length??0)+n}getTopLevelRowDisplayedIndex(e){let{beans:t,rootNode:n,rowsToDisplay:i}=this;if(!n||!i.length||i[0]===n)return e;let r=n.childrenAfterSort,o=e=>{let t=r[e];if(this.gos.get("groupHideOpenParents"))for(;t.expanded&&t.childrenAfterSort&&t.childrenAfterSort.length>0;)t=t.childrenAfterSort[0];return t.rowIndex},a=t.footerSvc;return a?a?.getTopDisplayIndex(i,e,r,o):o(e)}getTopLevelIndexFromDisplayedIndex(e){let{rootNode:t,rowsToDisplay:n}=this;if(!t||!n.length||n[0]===t)return e;let i=this.getRow(e);i.footer&&(i=i.sibling);let r=i.parent;for(;r&&r!==t;)r=(i=r).parent;let o=t.childrenAfterSort?.indexOf(i)??-1;return o>=0?o:e}getRowBounds(e){let t=this.rowsToDisplay[e];return t?{rowTop:t.rowTop,rowHeight:t.rowHeight}:null}onRowGroupOpened(){this.refreshModel({step:"map",keepRenderedRows:!0,animate:am(this.gos)})}onFilterChanged({afterDataChange:e,columns:t}){if(!e){let e=0===t.length||t.some(e=>e.isPrimary());this.refreshModel({step:e?"filter":"filter_aggregates",keepRenderedRows:!0,animate:am(this.gos)})}}onSortChanged(){this.refreshModel({step:"sort",keepRenderedRows:!0,animate:am(this.gos)})}getType(){return"clientSide"}onValueChanged(){this.refreshModel({step:this.beans.colModel.isPivotActive()?"pivot":"aggregate"})}createChangePath(e){let t=new c9(!1,this.rootNode);return t.active=e,t}isSuppressModelUpdateAfterUpdateTransaction(e){if(!this.gos.get("suppressModelUpdateAfterUpdateTransaction"))return!1;let{changedRowNodes:t,newData:n,rowDataUpdated:i}=e;return!!t&&!n&&!!i&&!t.removals.size&&!t.adds.size}refreshModel(e){let{nodeManager:t,beans:n,eventSvc:i,started:r,refreshingModel:o}=this;if(!t)return;let a=!!e.rowDataUpdated,s=e.changedPath??(e.changedPath=this.createChangePath(!e.newData&&a));if(r&&a&&i.dispatchEvent({type:"rowDataUpdated"}),!r||o||n.colModel.changeEventsDispatching||this.isSuppressModelUpdateAfterUpdateTransaction(e)){this.rowDataUpdatedPending||(this.rowDataUpdatedPending=a);return}switch(this.rowDataUpdatedPending&&(this.rowDataUpdatedPending=!1,e.step="group"),this.refreshingModel=!0,n.masterDetailSvc?.refreshModel(e),a&&"group"!==e.step&&n.colFilter?.refreshModel(),e.step){case"group":this.doGrouping(e);case"filter":this.doFilter(s);case"pivot":this.doPivot(s);case"aggregate":this.doAggregate(s);case"filter_aggregates":this.doFilterAggregates(s);case"sort":this.doSort(e.changedRowNodes,s);case"map":this.doRowsToDisplay()}let l=new Set;this.setRowTopAndRowIndex(l),this.clearRowTopAndRowIndex(s,l),this.refreshingModel=!1,i.dispatchEvent({type:"modelUpdated",animate:e.animate,keepRenderedRows:e.keepRenderedRows,newData:e.newData,newPage:!1,keepUndoRedoStack:e.keepUndoRedoStack})}isEmpty(){return!this.rootNode?._leafs?.length||!this.beans.colModel?.ready}isRowsToRender(){return this.rowsToDisplay.length>0}getNodesInRangeForSelection(e,t){let n=!1,i=!1,r=[],o=aL(this.gos);return this.forEachNodeAfterFilterAndSort(a=>{if(!i){if(n&&(a===t||a===e)&&(i=!0,o&&a.group))return void mo(r,a);if(!n){if(a!==t&&a!==e)return;n=!0,t===e&&(i=!0)}a.group&&o||r.push(a)}}),r}getTopLevelNodes(){return this.rootNode?.childrenAfterGroup??null}getRow(e){return this.rowsToDisplay[e]}isRowPresent(e){return this.rowsToDisplay.indexOf(e)>=0}getRowIndexAtPixel(e){let t=this.rowsToDisplay,n=t.length;if(this.isEmpty()||0===n)return -1;let i=0,r=n-1;if(e<=0)return 0;if(t[r].rowTop<=e)return r;let o=-1,a=-1;for(;;){let n=Math.floor((i+r)/2),s=t[n];if(this.isRowInPixel(s,e)||(s.rowTop<e?i=n+1:s.rowTop>e&&(r=n-1),o===i&&a===r))return n;o=i,a=r}}isRowInPixel(e,t){let n=e.rowTop,i=n+e.rowHeight;return n<=t&&i>t}forEachLeafNode(e){let t=this.rootNode?._leafs;if(t)for(let n=0,i=t.length;n<i;++n)e(t[n],n)}forEachNode(e,t=!1){this.depthFirstSearchRowNodes(e,t)}forEachDisplayedNode(e){let t=this.rowsToDisplay;for(let n=0,i=t.length;n<i;++n)e(t[n],n)}forEachNodeAfterFilter(e,t=!1){this.depthFirstSearchRowNodes(e,t,e=>e.childrenAfterAggFilter)}forEachNodeAfterFilterAndSort(e,t=!1){this.depthFirstSearchRowNodes(e,t,e=>e.childrenAfterSort)}forEachPivotNode(e,t,n){let{colModel:i,rowGroupColsSvc:r}=this.beans;if(!i.isPivotMode())return;if(!r?.columns.length)return void e(this.rootNode,0);let o=n?"childrenAfterSort":"childrenAfterGroup";this.depthFirstSearchRowNodes(e,t,e=>e.leafGroup?null:e[o])}depthFirstSearchRowNodes(e,t=!1,n=e=>e.childrenAfterGroup,i=this.rootNode,r=0){let o=r;if(!i)return o;let a=i===this.rootNode;if(a||e(i,o++),i.hasChildren()&&!i.footer){let r=n(i);if(r){let s=this.beans.footerSvc;for(let l of(o=s?.addTotalRows(o,i,e,t,a,"top")??o,r))o=this.depthFirstSearchRowNodes(e,t,n,l,o);return s?.addTotalRows(o,i,e,t,a,"bottom")??o}}return o}doAggregate(e){let t=this.rootNode;t&&this.beans.aggStage?.execute({rowNode:t,changedPath:e})}doFilterAggregates(e){let t=this.rootNode,n=this.beans.filterAggStage;n?n.execute({rowNode:t,changedPath:e}):t.childrenAfterAggFilter=t.childrenAfterFilter}doSort(e,t){let n=this.beans.sortStage;n?n.execute({rowNode:this.rootNode,changedRowNodes:e,changedPath:t}):t.forEachChangedNodeDepthFirst(e=>{e.childrenAfterSort=e.childrenAfterAggFilter.slice(0),g9(e)})}doGrouping(e){let t=this.rootNode,n=this.beans.groupStage,i=n?.execute({rowNode:t,changedRowNodes:e.changedRowNodes,changedPath:e.changedPath,afterColumnsChanged:!!e.afterColumnsChanged});if(void 0===i){let e=t._leafs;t.childrenAfterGroup=e,t.updateHasChildren();let n=t.sibling;n&&(n.childrenAfterGroup=e)}(i||e.rowDataUpdated)&&this.beans.colFilter?.refreshModel(),!this.rowCountReady&&this.rowNodesCountReady&&(this.rowCountReady=!0,this.eventSvc.dispatchEventOnce({type:"rowCountReady"}))}doFilter(e){let t=this.beans.filterStage;t?t.execute({rowNode:this.rootNode,changedPath:e}):e.forEachChangedNodeDepthFirst(e=>{e.childrenAfterFilter=e.childrenAfterGroup,gn(e)},!0)}doPivot(e){this.beans.pivotStage?.execute({rowNode:this.rootNode,changedPath:e})}getRowNode(e){let t=this.nodeManager?.getRowNode(e);return"object"==typeof t?t:"string"==typeof e&&0===e.indexOf(dO)?this.beans.groupStage?.getNode(e):void 0}batchUpdateRowData(e,t){if(!this.asyncTransactionsTimer){this.asyncTransactions=[];let e=this.gos.get("asyncTransactionWaitMillis");this.asyncTransactionsTimer=setTimeout(()=>this.executeBatchUpdateRowData(),e)}this.asyncTransactions.push({rowDataTransaction:e,callback:t})}flushAsyncTransactions(){let e=this.asyncTransactionsTimer;e&&(clearTimeout(e),this.executeBatchUpdateRowData())}executeBatchUpdateRowData(){let{nodeManager:e,beans:t,eventSvc:n,asyncTransactions:i}=this;if(!e)return;t.valueCache?.onDataChanged();let r=[],o=[],a=new c2;for(let{rowDataTransaction:t,callback:n}of i??[]){this.rowNodesCountReady=!0;let i=e.updateRowData(t,a);r.push(i),n&&o.push(n.bind(null,i))}this.commitTransactions(a),o.length>0&&setTimeout(()=>{for(let e=0,t=o.length;e<t;e++)o[e]()},0),r.length>0&&n.dispatchEvent({type:"asyncTransactionsFlushed",results:r}),this.asyncTransactionsTimer=0,this.asyncTransactions=null}updateRowData(e){let t=this.nodeManager;if(!t)return null;this.beans.valueCache?.onDataChanged(),this.rowNodesCountReady=!0;let n=new c2,i=t.updateRowData(e,n);return this.commitTransactions(n),i}commitTransactions(e){this.refreshModel({step:"group",rowDataUpdated:!0,keepRenderedRows:!0,animate:!this.gos.get("suppressAnimationFrame"),changedRowNodes:e,changedPath:this.createChangePath(!0)})}doRowsToDisplay(){let{beans:e,rootNode:t}=this,n=e.flattenStage;if(n){this.rowsToDisplay=n.execute({rowNode:t});return}let i=this.rootNode.childrenAfterSort??[];for(let e of i)e.setUiLevel(0);this.rowsToDisplay=i}onRowHeightChanged(){this.refreshModel({step:"map",keepRenderedRows:!0,keepUndoRedoStack:!0})}resetRowHeights(){let e=this.rootNode;if(!e)return;let t=this.resetRowHeightsForAllRowNodes();e.setRowHeight(e.rowHeight,!0);let n=e.sibling;n?.setRowHeight(n.rowHeight,!0),t&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode(t=>{t.setRowHeight(t.rowHeight,!0);let n=t.detailNode;n?.setRowHeight(n.rowHeight,!0);let i=t.sibling;i?.setRowHeight(i.rowHeight,!0),e=!0}),e}onGridStylesChanges(e){e.rowHeightChanged&&!this.beans.rowAutoHeight?.active&&this.resetRowHeights()}onGridReady(){this.started||this.setInitialData()}destroy(){super.destroy(),this.nodeManager=this.destroyBean(this.nodeManager),this.started=!1,this.rootNode=null,this.rowsToDisplay=[],this.asyncTransactions=null,clearTimeout(this.asyncTransactionsTimer)}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}},mo=(e,t)=>{let n=t.childrenAfterGroup;if(n)for(let t=0,i=n.length;t<i;++t){let i=n[t];i.data&&e.push(i),i.group&&mo(e,i)}},ma={moduleName:"ClientSideRowModel",version:o1,rowModels:["clientSide"],beans:[mr,me],dependsOn:[fD]},ms=class extends oI{constructor(){super(...arguments),this.beanName="gridSerializer"}wireBeans(e){this.visibleCols=e.visibleCols,this.colModel=e.colModel,this.rowModel=e.rowModel,this.pinnedRowModel=e.pinnedRowModel}serialize(e,t={}){let{allColumns:n,columnKeys:i,skipRowGroups:r,exportRowNumbers:o}=t,a=this.getColumnsToExport({allColumns:n,skipRowGroups:r,columnKeys:i,exportRowNumbers:o});return[this.prepareSession(a),this.prependContent(t),this.exportColumnGroups(t,a),this.exportHeaders(t,a),this.processPinnedTopRows(t,a),this.processRows(t,a),this.processPinnedBottomRows(t,a),this.appendContent(t)].reduce((e,t)=>
412t(e),e).parse()}processRow(e,t,n,i){var r;let o,a=t.shouldRowBeSkipped||(()=>!1),s=null!=t.rowPositions||!!t.onlySelected,l=this.gos.get("groupHideOpenParents")&&!s,d=this.colModel.isPivotMode()?i.leafGroup:!i.group,u=!!i.footer,c=1===i.allChildrenCount&&i.childrenAfterGroup?.length===1&&(r=this.gos,!!(!0===(o=r.get("groupHideParentOfSingleChild"))||"leafGroupsOnly"===o&&i.leafGroup||r.get("groupRemoveSingleChildren")||r.get("groupRemoveLowestSingleChildren")&&i.leafGroup));if(!d&&!u&&(t.skipRowGroups||c||l)||t.onlySelected&&!i.isSelected()||t.skipPinnedTop&&"top"===i.rowPinned||t.skipPinnedBottom&&"bottom"===i.rowPinned||i.stub||-1===i.level&&!d&&!u||a(aN(this.gos,{node:i})))return;let h=e.onNewBodyRow(i);if(n.forEach((e,t)=>{h.onColumn(e,t,i)}),t.getCustomContentBelowRow){let n=t.getCustomContentBelowRow(aN(this.gos,{node:i}));n&&e.addCustomContent(n)}}appendContent(e){return t=>{let n=e.appendContent;return n&&t.addCustomContent(n),t}}prependContent(e){return t=>{let n=e.prependContent;return n&&t.addCustomContent(n),t}}prepareSession(e){return t=>(t.prepare(e),t)}exportColumnGroups(e,t){return n=>{if(!e.skipColumnGroupHeaders){let i=new sy,{colGroupSvc:r}=this.beans,o=r?r.createColumnGroups({columns:t,idCreator:i,pinned:null,isStandaloneStructure:!0}):t;this.recursivelyAddHeaderGroups(o,n,e.processGroupHeaderCallback)}return n}}exportHeaders(e,t){return n=>{if(!e.skipColumnHeaders){let e=n.onNewHeaderRow();t.forEach((t,n)=>{e.onColumn(t,n,void 0)})}return n}}processPinnedTopRows(e,t){return n=>{let i=this.processRow.bind(this,n,e,t);return e.rowPositions?e.rowPositions.filter(e=>"top"===e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>this.pinnedRowModel?.getPinnedTopRow(e.rowIndex)).forEach(i):this.pinnedRowModel?.isManual()||this.pinnedRowModel?.forEachPinnedRow("top",i),n}}processRows(e,t){return n=>{let i=this.rowModel,r=aa(this.gos,i),o=as(this.gos,i),a=!r&&e.onlySelected,s=this.processRow.bind(this,n,e,t),{exportedRows:l="filteredAndSorted"}=e;if(e.rowPositions)e.rowPositions.filter(e=>null==e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>i.getRow(e.rowIndex)).forEach(s);else if(this.colModel.isPivotMode())r?i.forEachPivotNode(s,!0,"filteredAndSorted"===l):o?i.forEachNodeAfterFilterAndSort(s,!0):i.forEachNode(s);else if(e.onlySelectedAllPages||a){let e=this.beans.selectionSvc?.getSelectedNodes()??[];this.replicateSortedOrder(e),e.forEach(s)}else"all"===l?i.forEachNode(s):r||o?i.forEachNodeAfterFilterAndSort(s,!0):i.forEachNode(s);return n}}replicateSortedOrder(e){let{sortSvc:t,rowNodeSorter:n}=this.beans;if(!t||!n)return;let i=t.getSortOptions(),r=(e,t)=>null!=e.rowIndex&&null!=t.rowIndex?e.rowIndex-t.rowIndex:e.level===t.level?e.parent?.id===t.parent?.id?n.compareRowNodes(i,{rowNode:e,currentPos:e.rowIndex??-1},{rowNode:t,currentPos:t.rowIndex??-1}):r(e.parent,t.parent):e.level>t.level?r(e.parent,t):r(e,t.parent);e.sort(r)}processPinnedBottomRows(e,t){return n=>{let i=this.processRow.bind(this,n,e,t);return e.rowPositions?e.rowPositions.filter(e=>"bottom"===e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>this.pinnedRowModel?.getPinnedBottomRow(e.rowIndex)).forEach(i):this.pinnedRowModel?.isManual()||this.pinnedRowModel?.forEachPinnedRow("bottom",i),n}}getColumnsToExport(e){let{allColumns:t=!1,skipRowGroups:n=!1,exportRowNumbers:i=!1,columnKeys:r}=e,{colModel:o,gos:a,visibleCols:s}=this,l=o.isPivotMode(),d=e=>!a8(e)&&(!a7(e)||i);if(r?.length)return o.getColsForKeys(r).filter(d);let u=a.get("treeData");return(t&&!l?o.getCols():s.allCols).filter(e=>d(e)&&(!n||!!u||!a6(e)))}recursivelyAddHeaderGroups(e,t,n){let i=[];for(let t of e)if(t.getChildren)for(let e of t.getChildren()??[])i.push(e);e.length>0&&dL(e[0])&&this.doAddHeaderHeader(t,e,n),i&&i.length>0&&this.recursivelyAddHeaderGroups(i,t,n)}doAddHeaderHeader(e,t,n){let i=e.onNewHeaderGroupingRow(),r=0;for(let e of t){let t;t=n?n(aN(this.gos,{columnGroup:e})):this.beans.colNames.getDisplayNameForColumnGroup(e,"header");let o=(e.isExpandable()?e.getLeafColumns():[]).reduce((e,t,n,i)=>{let r=aY(e);return"open"===t.getColumnGroupShow()?r&&null==r[1]||(r=[n],e.push(r)):r&&null==r[1]&&(r[1]=n-1),n===i.length-1&&r&&null==r[1]&&(r[1]=n),e},[]);i.onColumn(e,t||"",r++,e.getLeafColumns().length-1,o)}}},ml=class extends fJ{constructor(e){super(e),this.config=e,this.isFirstLine=!0,this.result="";const{suppressQuotes:t,columnSeparator:n}=e;this.suppressQuotes=t,this.columnSeparator=n}
412addCustomContent(e){e&&("string"==typeof e?(/^\s*\n/.test(e)||this.beginNewLine(),e=e.replace(/\r?\n/g,"\r\n"),this.result+=e):e.forEach(e=>{this.beginNewLine(),e.forEach((e,t)=>{0!==t&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(e.data.value||""),e.mergeAcross&&this.appendEmptyCells(e.mergeAcross)})}))}onNewHeaderGroupingRow(){return this.beginNewLine(),{onColumn:this.onNewHeaderGroupingRowColumn.bind(this)}}onNewHeaderGroupingRowColumn(e,t,n,i){0!=n&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(t),this.appendEmptyCells(i)}appendEmptyCells(e){for(let t=1;t<=e;t++)this.result+=this.columnSeparator+this.putInQuotes("")}onNewHeaderRow(){return this.beginNewLine(),{onColumn:this.onNewHeaderRowColumn.bind(this)}}onNewHeaderRowColumn(e,t){0!=t&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(this.extractHeaderValue(e))}onNewBodyRow(){return this.beginNewLine(),{onColumn:this.onNewBodyRowColumn.bind(this)}}onNewBodyRowColumn(e,t,n){0!=t&&(this.result+=this.columnSeparator);
412let i=this.extractRowCellValue(e,t,t,"csv",n);this.result+=this.putInQuotes(i.valueFormatted??i.value)}putInQuotes(e){let t;return this.suppressQuotes?e:null==e?'""':("string"==typeof e?t=e:"function"==typeof e.toString?t=e.toString():(at(53),t=""),'"'+t.replace(/"/g,'""')+'"')}parse(){return this.result}beginNewLine(){this.isFirstLine||(this.result+="\r\n"),this.isFirstLine=!1}},md={moduleName:"CsvExport",version:o1,beans:[class extends fX{constructor(){super(...arguments),this.beanName="csvCreator"}wireBeans(e){this.colModel=e.colModel,this.colNames=e.colNames,this.rowGroupColsSvc=e.rowGroupColsSvc,this.valueSvc=e.valueSvc}getMergedParams(e){return Object.assign({},this.gos.get("defaultCsvExportParams"),e)}export(e){if(this.isExportSuppressed())return void at(51);let t=this.getMergedParams(e),n=new Blob(["\uFEFF",this.getData(t)],{type:"text/plain"}),i="function"==typeof t.fileName?t.fileName(aN(this.gos,{})):t.fileName;!function(e,t){let n=document.defaultView||window;if(!n)return at(52);let i=document.createElement("a"),r=n.URL.createObjectURL(t);i.setAttribute("href",r),i.setAttribute("download",e),i.style.display="none",document.body.appendChild(i),i.dispatchEvent(new MouseEvent("click",{bubbles:!1,cancelable:!0,view:n})),i.remove(),n.setTimeout(()=>{n.URL.revokeObjectURL(r)},0)}(this.getFileName(i),n)}exportDataAsCsv(e){this.export(e)}getDataAsCsv(e,t=!1){let n=t?Object.assign({},e):this.getMergedParams(e);return this.getData(n)}getDefaultFileExtension(){return"csv"}createSerializingSession(e){let{colModel:t,colNames:n,rowGroupColsSvc:i,valueSvc:r,gos:o}=this,{processCellCallback:a,processHeaderCallback:s,processGroupHeaderCallback:l,processRowGroupCallback:d,suppressQuotes:u,columnSeparator:c}=e;return new ml({colModel:t,colNames:n,valueSvc:r,gos:o,processCellCallback:a||void 0,processHeaderCallback:s||void 0,processGroupHeaderCallback:l||void 0,processRowGroupCallback:d||void 0,suppressQuotes:u||!1,columnSeparator:c||",",rowGroupColsSvc:i})}isExportSuppressed(){return this.gos.get("suppressCsvExport")}}],apiFunctions:{getDataAsCsv:function(e,t){return e.csvCreator?.getDataAsCsv(t)},exportDataAsCsv:function(e,t){e.csvCreator?.exportDataAsCsv(t)}},dependsOn:[{moduleName:"SharedExport",version:o1,beans:[ms]}]},mu={tag:"span",children:[{tag:"span",ref:"eDelta",cls:"ag-value-change-delta"},{tag:"span",ref:"eValue",cls:"ag-value-change-value"}]},mc={tag:"span",children:[{tag:"span",ref:"eCurrent",cls:"ag-value-slide-current"}]},mh=class extends oI{constructor(){super(...arguments),this.beanName="paginationAutoPageSizeSvc"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.centerRowsCtrl=e.center;let t=this.checkPageSize.bind(this);this.addManagedEventListeners({bodyHeightChanged:t,scrollVisibilityChanged:t}),this.addManagedPropertyListener("paginationAutoPageSize",this.onPaginationAutoSizeChanged.bind(this)),this.checkPageSize()})}notActive(){return!this.gos.get("paginationAutoPageSize")||null==this.centerRowsCtrl}onPaginationAutoSizeChanged(){this.notActive()?this.beans.pagination.unsetAutoCalculatedPageSize():this.checkPageSize()}checkPageSize(){if(this.notActive())return;let e=this.centerRowsCtrl.viewportSizeFeature.getBodyHeight();if(e>0){let t=this.beans,n=()=>{let n=Math.floor(e/Math.max(ah(t),1));t.pagination.setPageSize(n,"autoCalculated")};this.isBodyRendered?oO(this,n,50)():(n(),this.isBodyRendered=!0)}else this.isBodyRendered=!1}},mp="paginationPageSizeSelector",mf={tag:"span",cls:"ag-paging-page-size"},mg={selector:"AG-PAGE-SIZE-SELECTOR",component:class extends sk{constructor(){super(mf),this.hasEmptyOption=!1,this.handlePageSizeItemSelected=()=>{if(!this.selectPageSizeComp)return;let e=this.selectPageSizeComp.getValue();if(!e)return;let t=Number(e);isNaN(t)||t<1||t===this.pagination.getPageSize()||(this.pagination.setPageSize(t,"pageSizeSelector"),this.hasEmptyOption&&this.toggleSelectDisplay(!0),this.selectPageSizeComp.getFocusableElement().focus())}}wireBeans(e){this.pagination=e.pagination}postConstruct(){this.addManagedPropertyListener(mp,()=>{this.onPageSizeSelectorValuesChange()}),this.addManagedEventListeners({paginationChanged:e=>this.handlePaginationChanged(e)})}handlePaginationChanged(e){if(!this.selectPageSizeComp||!e?.newPageSize)return;let t=this.pagination.getPageSize();this.getPageSizeSelectorValues().includes(t)?this.selectPageSizeComp.setValue(t.toString()):this.hasEmptyOption?this.selectPageSizeComp.setValue(""):this.toggleSelectDisplay(!0)}toggleSelectDisplay(e){if(this.selectPageSizeComp&&!e&&this.reset(),e&&(this.reloadPageSizesSelector(),!this.selectPageSizeComp))return}reset(){r8(this.getGui()),this.selectPageSizeComp&&(this.selectPageSizeComp=this.destroyBean(this.selectPageSizeComp))}onPageSizeSelectorValuesChange(){this.selectPageSizeComp&&this.shouldShowPageSizeSelector()&&this.reloadPageSizesSelector()}shouldShowPageSizeSelector(){return this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel")&&!this.gos.get("paginationAutoPageSize")&&!1!==this.gos.get(mp)}reloadPageSizesSelector(){let e=this.getPageSizeSelectorValues(),t=this.pagination.getPageSize(),n=!t||!e.includes(t);if(n){let n=this.gos.exists("paginationPageSize"),i=!0!==this.gos.get(mp);at(94,{pageSizeSet:n,pageSizesSet:i,pageSizeOptions:e,paginationPageSizeOption:t}),i||at(95,{paginationPageSizeOption:t,paginationPageSizeSelector:mp}),e.unshift("")}let i=String(n?"":t);this.selectPageSizeComp?(aZ(this.pageSizeOptions,e)||(this.selectPageSizeComp.clearOptions().addOptions(this.createPageSizeSelectOptions(e)),this.pageSizeOptions=e),this.selectPageSizeComp.setValue(i,!0)):this.createPageSizeSelectorComp(e,i),this.hasEmptyOption=n}createPageSizeSelectOptions(e){return e.map(e=>({value:String(e)}))}createPageSizeSelectorComp(e,t){let n=this.getLocaleTextFunc(),i=n("pageSizeSelectorLabel","Page Size:"),r=n("ariaPageSizeSelectorLabel","Page Size");this.selectPageSizeComp=this.createManagedBean(new lj).addOptions(this.createPageSizeSelectOptions(e)).setValue(t).setAriaLabel(r).setLabel(i).onValueChange(()=>this.handlePageSizeItemSelected()),this.appendChild(this.selectPageSizeComp)}getPageSizeSelectorValues(){let e=this.gos.get(mp);return Array.isArray(e)&&e?.length?[...e].sort((e,t)=>
412e-t):[20,50,100]}destroy(){this.toggleSelectDisplay(!1),super.destroy()}}},mm={selector:"AG-PAGINATION",component:class extends cO{constructor(){super(),this.btFirst=null,this.btPrevious=null,this.btNext=null,this.btLast=null,this.lbRecordCount=null,this.lbFirstRowOnPage=null,this.lbLastRowOnPage=null,this.lbCurrent=null,this.lbTotal=null,this.pageSizeComp=null,this.previousAndFirstButtonsDisabled=!1,this.nextButtonDisabled=!1,this.lastButtonDisabled=!1,this.areListenersSetup=!1,this.allowFocusInnerElement=!1,this.registerCSS(".ag-paging-panel{align-items:center;border-top:var(--ag-footer-row-border);display:flex;gap:calc(var(--ag-spacing)*4);height:var(--ag-pagination-panel-height);justify-content:flex-end;padding:0 var(--ag-cell-horizontal-padding)}:where(.ag-paging-page-size) .ag-wrapper{min-width:50px}.ag-paging-page-summary-panel{align-items:center;display:flex;gap:var(--ag-cell-widget-spacing);.ag-disabled &{pointer-events:none}}.ag-paging-button{cursor:pointer;position:relative;&.ag-disabled{cursor:default;opacity:.5}}.ag-paging-number,.ag-paging-row-summary-panel-number{font-weight:500}")}wireBeans(e){this.rowModel=e.rowModel,this.pagination=e.pagination,this.ariaAnnounce=e.ariaAnnounce}postConstruct(){let e=this.gos.get("enableRtl");this.setTemplate(this.getTemplate(),[mg]);let{btFirst:t,btPrevious:n,btNext:i,btLast:r}=this;this.activateTabIndex([t,n,i,r]),t.insertAdjacentElement("afterbegin",cv(e?"last":"first",this.beans)),n.insertAdjacentElement("afterbegin",cv(e?"next":"previous",this.beans)),i.insertAdjacentElement("afterbegin",cv(e?"previous":"next",this.beans)),r.insertAdjacentElement("afterbegin",cv(e?"first":"last",this.beans)),this.addManagedPropertyListener("pagination",this.onPaginationChanged.bind(this)),this.addManagedPropertyListener("suppressPaginationPanel",this.onPaginationChanged.bind(this)),this.addManagedPropertyListeners(["paginationPageSizeSelector","paginationAutoPageSize","suppressPaginationPanel"],()=>this.onPageSizeRelatedOptionsChange()),this.pageSizeComp.toggleSelectDisplay(this.pageSizeComp.shouldShowPageSizeSelector()),this.initialiseTabGuard({onTabKeyDown:()=>{},focusInnerElement:e=>{var t;return this.allowFocusInnerElement?this.tabGuardFeature.getTabGuardCtrl().focusInnerElement(e):(t=this.beans,t.ctrlsSvc.get("gridCtrl").focusInnerElement(e))},forceFocusOutWhenTabGuardsAreEmpty:!0}),this.onPaginationChanged()}setAllowFocus(e){this.allowFocusInnerElement=e}onPaginationChanged(){let e=this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel");this.setDisplayed(e),e&&(this.setupListeners(),this.enableOrDisableButtons(),this.updateLabels(),this.onPageSizeRelatedOptionsChange())}onPageSizeRelatedOptionsChange(){this.pageSizeComp.toggleSelectDisplay(this.pageSizeComp.shouldShowPageSizeSelector())}setupListeners(){if(!this.areListenersSetup){var e,t;for(let e of(this.addManagedEventListeners({paginationChanged:this.onPaginationChanged.bind(this)}),[{el:this.btFirst,fn:this.onBtFirst.bind(this)},{el:this.btPrevious,fn:this.onBtPrevious.bind(this)},{el:this.btNext,fn:this.onBtNext.bind(this)},{el:this.btLast,fn:this.onBtLast.bind(this)}])){let{el:t,fn:n}=e;this.addManagedListeners(t,{click:n,keydown:e=>{(e.key===sJ||" "===e.key)&&(e.preventDefault(),n())}})}e=this.beans,t=this.getGui(),this.addManagedElementListeners(t,{keydown:n=>{if(!n.defaultPrevented&&"Tab"===n.key){let i=n.shiftKey;!lk(e,t,!1,i)&&u2(e,i)&&n.preventDefault()}}}),this.areListenersSetup=!0}}onBtFirst(){this.previousAndFirstButtonsDisabled||this.pagination.goToFirstPage()}formatNumber(e){let t=this.gos.getCallback("paginationNumberFormatter");return t?t({value:e}):function(e,t){if("number"!=typeof e)return"";let n=t(),i=n("thousandSeparator",","),r=n("decimalSeparator",".");return e.toString().replace(".",r).replace(/(\d)(?=(\d{3})+(?!\d))/g,`$1${i}`)}(e,this.getLocaleTextFunc.bind(this))}getTemplate(){let e=this.getLocaleTextFunc(),t=`ag-${this.getCompId()}`;return{tag:"div",cls:"ag-paging-panel ag-unselectable",attrs:{id:`${t}`},children:[{tag:"ag-page-size-selector",ref:"pageSizeComp"},{tag:"span",cls:"ag-paging-row-summary-panel",children:[{tag:"span",ref:"lbFirstRowOnPage",cls:"ag-paging-row-summary-panel-number",attrs:{id:`${t}-first-row`}},{tag:"span",attrs:{id:`${t}-to`},children:e("to","to")},{tag:"span",ref:"lbLastRowOnPage",cls:"ag-paging-row-summary-panel-number",attrs:{id:`${t}-last-row`}},{tag:"span",attrs:{id:`${t}-of`},children:e("of","of")},{tag:"span",ref:"lbRecordCount",cls:"ag-paging-row-summary-panel-number",attrs:{id:`${t}-row-count`}}]},{tag:"span",cls:"ag-paging-page-summary-panel",role:"presentation",children:[{tag:"div",ref:"btFirst",cls:"ag-button ag-paging-button",role:"button",attrs:{"aria-label":e("firstPage","First Page")}},{tag:"div",ref:"btPrevious",cls:"ag-button ag-paging-button",role:"button",attrs:{"aria-label":e("previousPage","Previous Page")}},{tag:"span",cls:"ag-paging-description",children:[{tag:"span",attrs:{id:`${t}-start-page`},children:e("page","Page")},{tag:"span",ref:"lbCurrent",cls:"ag-paging-number",attrs:{id:`${t}-start-page-number`}},{tag:"span",attrs:{id:`${t}-of-page`},children:e("of","of")},{tag:"span",ref:"lbTotal",cls:"ag-paging-number",attrs:{id:`${t}-of-page-number`}}]},{tag:"div",ref:"btNext",cls:"ag-button ag-paging-button",role:"button",attrs:{"aria-label":e("nextPage","Next Page")}},{tag:"div",ref:"btLast",cls:"ag-button ag-paging-button",role:"button",attrs:{"aria-label":e("lastPage","Last Page")}}]}]}}onBtNext(){this.nextButtonDisabled||this.pagination.goToNextPage()}onBtPrevious(){this.previousAndFirstButtonsDisabled||this.pagination.goToPreviousPage()}onBtLast(){this.lastButtonDisabled||this.pagination.goToLastPage()}enableOrDisableButtons(){let e=this.pagination.getCurrentPage(),t=this.rowModel.isLastRowIndexKnown(),n=this.pagination.getTotalPages();this.previousAndFirstButtonsDisabled=0===e,this.toggleButtonDisabled(this.btFirst,this.previousAndFirstButtonsDisabled),this.toggleButtonDisabled(this.btPrevious,this.previousAndFirstButtonsDisabled);let i=this.isZeroPagesToDisplay();this.nextButtonDisabled=e===n-1||i,this.lastButtonDisabled=!t||i||e===n-1,this.toggleButtonDisabled(this.btNext,this.nextButtonDisabled),this.toggleButtonDisabled(this.btLast,this.lastButtonDisabled)}toggleButtonDisabled(e,t){rO(e,"disabled",t),e.classList.toggle("ag-disabled",t)}isZeroPagesToDisplay(){let e=this.rowModel.isLastRowIndexKnown(),t=this.pagination.getTotalPages();return e&&0===t}updateLabels(){let e,t,n,i,r,o=this.rowModel.isLastRowIndexKnown(),a=this.pagination.getTotalPages(),s=this.pagination.getMasterRowCount(),l=o?s:null,d=this.pagination.getCurrentPage(),u=this.pagination.getPageSize();this.isZeroPagesToDisplay()?e=t=0:(t=(e=u*d+1)+u-1,o&&t>l&&(t=l));let c=e+u-1,h=this.formatNumber(e);this.lbFirstRowOnPage.textContent=h;let p=this.getLocaleTextFunc();n=!o&&s<c?p("pageLastRowUnknown","?"):this.formatNumber(t),this.lbLastRowOnPage.textContent=n;let f=a>0,g=this.formatNumber(f?d+1:0);if(this.lbCurrent.textContent=g,o)i=this.formatNumber(a),r=this.formatNumber(l);else{let e=p("more","more");i=e,r=e}this.lbTotal.textContent=i,this.lbRecordCount.textContent=r,this.announceAriaStatus(h,n,r,g,i)}announceAriaStatus(e,t,n,i,r){let o=this.getLocaleTextFunc(),a=o("page","Page"),s=o("to","to"),l=o("of","of"),d=`${e} ${s} ${t} ${l} ${n}`,u=`${a} ${i} ${l} ${r}`;d!==this.ariaRowStatus&&(this.ariaRowStatus=d,this.ariaAnnounce?.announceValue(d,"paginationRow")),u!==this.ariaPageStatus&&(this.ariaPageStatus=u,this.ariaAnnounce?.announceValue(u,"paginationPage"))}}},mv={moduleName:"Pagination",version:o1,beans:[class extends oI{constructor(){super(...arguments),this.beanName="pagination",this.currentPage=0,this.topDisplayedRowIndex=0,this.bottomDis
412playedRowIndex=0,this.masterRowCount=0}postConstruct(){let e=this.gos;this.active=e.get("pagination"),this.pageSizeFromGridOptions=e.get("paginationPageSize"),this.paginateChildRows=this.isPaginateChildRows(),this.addManagedPropertyListener("pagination",this.onPaginationGridOptionChanged.bind(this)),this.addManagedPropertyListener("paginationPageSize",this.onPageSizeGridOptionChanged.bind(this))}getPaginationSelector(){return mm}isPaginateChildRows(){let e=this.gos;return!!(e.get("groupHideParentOfSingleChild")||e.get("groupRemoveSingleChildren")||e.get("groupRemoveLowestSingleChildren"))||e.get("paginateChildRows")}onPaginationGridOptionChanged(){this.active=this.gos.get("pagination"),this.calculatePages(),this.dispatchPaginationChangedEvent({keepRenderedRows:!0})}onPageSizeGridOptionChanged(){this.setPageSize(this.gos.get("paginationPageSize"),"gridOptions")}goToPage(e){let t=this.currentPage;if(!this.active||t===e||"number"!=typeof t)return;let{editSvc:n}=this.beans;n?.isEditing()&&(n.isBatchEditing()?n.cleanupEditors():n.stopEditing(void 0,{source:"api"})),this.currentPage=e,this.calculatePages(),this.dispatchPaginationChangedEvent({newPage:!0})}goToPageWithIndex(e){if(!this.active)return;let t=e;this.paginateChildRows||(t=this.beans.rowModel.getTopLevelIndexFromDisplayedIndex?.(e)??e),this.goToPage(Math.floor(t/this.pageSize))}isRowInPage(e){return!this.active||e>=this.topDisplayedRowIndex&&e<=this.bottomDisplayedRowIndex}getCurrentPage(){return this.currentPage}goToNextPage(){this.goToPage(this.currentPage+1)}goToPreviousPage(){this.goToPage(this.currentPage-1)}goToFirstPage(){this.goToPage(0)}goToLastPage(){let e=Math.floor(this.beans.rowModel.getRowCount()/this.pageSize);this.goToPage(e)}getPageSize(){return this.pageSize}getTotalPages(){return this.totalPages}setPage(e){this.currentPage=e}get pageSize(){return rC(this.pageSizeAutoCalculated)&&this.gos.get("paginationAutoPageSize")?this.pageSizeAutoCalculated:rC(this.pageSizeFromPageSizeSelector)?this.pageSizeFromPageSizeSelector:rC(this.pageSizeFromInitialState)?this.pageSizeFromInitialState:rC(this.pageSizeFromGridOptions)?this.pageSizeFromGridOptions:this.defaultPageSize}calculatePages(){this.active?this.paginateChildRows?this.calculatePagesAllRows():this.calculatePagesMasterRowsOnly():this.calculatedPagesNotActive(),this.beans.pageBounds.calculateBounds(this.topDisplayedRowIndex,this.bottomDisplayedRowIndex)}unsetAutoCalculatedPageSize(){if(void 0===this.pageSizeAutoCalculated)return;let e=this.pageSizeAutoCalculated;this.pageSizeAutoCalculated=void 0,this.pageSize!==e&&(this.calculatePages(),this.dispatchPaginationChangedEvent({newPageSize:!0}))}setPageSize(e,t){let n=this.pageSize;switch(t){case"autoCalculated":this.pageSizeAutoCalculated=e;break;case"pageSizeSelector":this.pageSizeFromPageSizeSelector=e,0!==this.currentPage&&this.goToFirstPage();break;case"initialState":this.pageSizeFromInitialState=e;break;case"gridOptions":this.pageSizeFromGridOptions=e,this.pageSizeFromInitialState=void 0,this.pageSizeFromPageSizeSelector=void 0,0!==this.currentPage&&this.goToFirstPage()}n!==this.pageSize&&(this.calculatePages(),this.dispatchPaginationChangedEvent({newPageSize:!0,keepRenderedRows:!0}))}setZeroRows(){this.masterRowCount=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=-1,this.currentPage=0,this.totalPages=0}adjustCurrentPageIfInvalid(){let e=this.totalPages;this.currentPage>=e&&(this.currentPage=e-1);let t=this.currentPage;(!isFinite(t)||isNaN(t)||t<0)&&(this.currentPage=0)}calculatePagesMasterRowsOnly(){let e=this.beans.rowModel,t=e.getTopLevelRowCount();if(this.masterRowCount=t,t<=0)return void this.setZeroRows();let n=this.pageSize,i=t-1;this.totalPages=Math.floor(i/n)+1,this.adjustCurrentPageIfInvalid();let r=this.currentPage,o=n*(r+1)-1;if(o>i&&(o=i),this.topDisplayedRowIndex=e.getTopLevelRowDisplayedIndex(n*r),o===i)this.bottomDisplayedRowIndex=e.getRowCount()-1;else{let t=e.getTopLevelRowDisplayedIndex(o+1);this.bottomDisplayedRowIndex=t-1}}getMasterRowCount(){return this.masterRowCount}calculatePagesAllRows(){let e=this.beans.rowModel.getRowCount();if(this.masterRowCount=e,0===e)return void this.setZeroRows();let{pageSize:t,currentPage:n}=this,i=e-1;this.totalPages=Math.floor(i/t)+1,this.adjustCurrentPageIfInvalid(),this.topDisplayedRowIndex=t*n,this.bottomDis
412playedRowIndex=t*(n+1)-1,this.bottomDisplayedRowIndex>i&&(this.bottomDisplayedRowIndex=i)}calculatedPagesNotActive(){this.setPageSize(void 0,"autoCalculated"),this.totalPages=1,this.currentPage=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=this.beans.rowModel.getRowCount()-1}dispatchPaginationChangedEvent(e){let{keepRenderedRows:t=!1,newPage:n=!1,newPageSize:i=!1}=e;this.eventSvc.dispatchEvent({type:"paginationChanged",animate:!1,newData:!1,newPage:n,newPageSize:i,keepRenderedRows:t})}},mh],icons:{first:"first",previous:"previous",next:"next",last:"last"},apiFunctions:{paginationIsLastPageFound:function(e){return e.rowModel.isLastRowIndexKnown()},paginationGetPageSize:function(e){return e.pagination?.getPageSize()??100},paginationGetCurrentPage:function(e){return e.pagination?.getCurrentPage()??0},paginationGetTotalPages:function(e){return e.pagination?.getTotalPages()??1},paginationGetRowCount:function(e){return e.pagination?e.pagination.getMasterRowCount():e.rowModel.getRowCount()},paginationGoToNextPage:function(e){e.pagination?.goToNextPage()},paginationGoToPreviousPage:function(e){e.pagination?.goToPreviousPage()},paginationGoToFirstPage:function(e){e.pagination?.goToFirstPage()},paginationGoToLastPage:function(e){e.pagination?.goToLastPage()},paginationGoToPage:function(e,t){e.pagination?.goToPage(t)}},dependsOn:[go]},my={moduleName:"RowApi",version:o1,apiFunctions:{redrawRows:function(e,t={}){let n=t?t.rowNodes:void 0;e.frameworkOverrides.wrapIncoming(()=>e.rowRenderer.redrawRows(n))},setRowNodeExpanded:function e(t,n,i,r,o){n&&(r&&n.parent&&-1!==n.parent.level&&e(t,n.parent,i,r,o),n.setExpanded(i,void 0,o))},getRowNode:function(e,t){return e.rowModel.getRowNode(t)},addRenderedRowListener:function(e,t,n,i){e.rowRenderer.addRenderedRowListener(t,n,i)},getRenderedNodes:function(e){return e.rowRenderer.getRenderedNodes()},forEachNode:function(e,t,n){e.rowModel.forEachNode(t,n)},getFirstDisplayedRowIndex:function(e){return e.rowRenderer.firstRenderedRow},getLastDisplayedRowIndex:function(e){return e.rowRenderer.lastRenderedRow},getDisplayedRowAtIndex:function(e,t){return e.rowModel.getRow(t)},getDisplayedRowCount:function(e){return e.rowModel.getRowCount()}}};function mb({colAutosize:e,visibleCols:t},n,i){Array.isArray(n)?e?.autoSizeCols({colKeys:n,skipHeader:i,source:"api"}):e?.autoSizeCols({...n,colKeys:n.colIds??t.allCols,source:"api"})}function mx({ctrlsSvc:e,scrollVisibleSvc:t}){let n=e.getGridBodyCtrl(),i=n.isVerticalScrollShowing()?t.getScrollbarWidth():0;return r1(n.eGridBody)-i}var mw={moduleName:"ColumnAutoSize",version:o1,beans:[class extends oI{constructor(){super(...arguments),this.beanName="colAutosize",this.timesDelayed=0,this.shouldQueueResizeOperations=!1,this.resizeOperationQueue=[]}postConstruct(){let{gos:e}=this,t=e.get("autoSizeStrategy");if(t){let n=!1,i=t.type;if("fitGridWidth"===i||"fitProvidedWidth"===i)n=!0;else if("fitCellContents"===i){this.addManagedEventListeners({firstDataRendered:()=>this.onFirstDataRendered(t)});let i=e.get("rowData");n=null!=i&&i.length>0&&aa(e)}n&&this.beans.colDelayRenderSvc?.hideColumns(i)}}autoSizeCols(e){let{eventSvc:t,visibleCols:n}=this.beans;this.innerAutoSizeCols(e).then(i=>{let r=e=>sc(t,Array.from(e),!0,"autosizeColumns");if(!e.scaleUpToFitGridWidth)return r(i);let o=mx(this.beans),a=e.colKeys.filter(e=>!a8(e)&&!a7(e)&&!n.leftCols.some(t=>st(t,e))&&!n.rightCols.some(t=>st(t,e)));this.sizeColumnsToFit(o,e.source,!0,{defaultMaxWidth:e.defaultMaxWidth,defaultMinWidth:e.defaultMinWidth,columnLimits:e.columnLimits?.map(e=>({...e,key:e.colId})),colKeys:a,onlyScaleUp:!0}),r(i)})}innerAutoSizeCols(e){return new Promise((t,n)=>{if(this.shouldQueueResizeOperations)return this.pushResizeOperation(()=>this.innerAutoSizeCols(e).then(t,n));let{colKeys:i,skipHeader:r,skipHeaderGroups:o,stopAtGroup:a,defaultMaxWidth:s,defaultMinWidth:l,columnLimits:d=[],source:u="api"}=e,{animationFrameSvc:c,renderStatus:h,colModel:p,autoWidthCalc:f,visibleCols:g}=this.beans;if(c?.flushAllFrames(),this.timesDelayed<5&&h&&(!h.areHeaderCellsRendered()||!h.areCellsRendered())){this.timesDelayed++,setTimeout(()=>{this.isAlive()&&this.innerAutoSizeCols(e).then(t,n)});return}this.timesDelayed=0;let m=new Set,v=-1,y=Object.fromEntries(d.map(({colId:e,...t})=>[e,t])),b=r??this.gos.get("skipHeaderOnAutoSize"),x=o??b;for(;0!==v;){v=0;let e=[];for(let t of i){var w;if(!t||a8(w=t)||a7(w))continue;let n=p.getCol(t);if(!n||m.has(n))continue;let i=f.getPreferredWidthForColumn(n,b);
412if(i>0){let e=y[n.colId]??{};e.minWidth??(e.minWidth=l),e.maxWidth??(e.maxWidth=s);let t=function(e,t,n={}){let i=n.minWidth??e.getMinWidth();t<i&&(t=i);let r=n.maxWidth??e.getMaxWidth();return t>r&&(t=r),t}(n,i,e);n.setActualWidth(t,u),m.add(n),v++}e.push(n)}e.length&&g.refresh(u)}x||this.autoSizeColumnGroupsByColumns(i,u,a),t(m)})}autoSizeColumn(e,t,n){this.autoSizeCols({colKeys:[e],skipHeader:n,skipHeaderGroups:!0,source:t})}autoSizeColumnGroupsByColumns(e,t,n){let i,{colModel:r,ctrlsSvc:o}=this.beans,a=new Set;for(let t of r.getColsForKeys(e)){let e=t.getParent();for(;e&&e!=n;)e.isPadding()||a.add(e),e=e.getParent()}for(let e of a){for(let t of o.getHeaderRowContainerCtrls())if(i=t.getHeaderCtrlForColumn(e))break;i?.resizeLeafColumnsToFit(t)}}autoSizeAllColumns(e){this.shouldQueueResizeOperations?this.pushResizeOperation(()=>this.autoSizeAllColumns(e)):this.autoSizeCols({colKeys:this.beans.visibleCols.allCols,...e})}addColumnAutosizeListeners(e,t){let n=this.gos.get("skipHeaderOnAutoSize"),i=()=>{this.autoSizeColumn(t,"uiColumnResized",n)};e.addEventListener("dblclick",i);let r=new cN(e);return r.addEventListener("doubleTap",i),()=>{e.removeEventListener("dblclick",i),r.destroy()}}addColumnGroupResize(e,t,n){let i=this.gos.get("skipHeaderOnAutoSize"),r=()=>{let e=[];for(let n of t.getDisplayedLeafColumns())n.getColDef().suppressAutoSize||e.push(n.getColId());e.length>0&&this.autoSizeCols({colKeys:e,skipHeader:i,stopAtGroup:t,source:"uiColumnResized"}),n()};return e.addEventListener("dblclick",r),()=>e.removeEventListener("dblclick",r)}sizeColumnsToFitGridBody(e,t){if(!this.isAlive())return;let n=mx(this.beans);n>0?this.sizeColumnsToFit(n,"sizeColumnsToFit",!1,e):void 0===t?window.setTimeout(()=>{this.sizeColumnsToFitGridBody(e,100)},0):100===t?window.setTimeout(()=>{this.sizeColumnsToFitGridBody(e,500)},100):500===t?window.setTimeout(()=>{this.sizeColumnsToFitGridBody(e,-1)},500):at(29)}sizeColumnsToFit(e,t="sizeColumnsToFit",n,i){if(this.shouldQueueResizeOperations)return void this.pushResizeOperation(()=>this.sizeColumnsToFit(e,t,n,i));let r={};for(let{key:e,...t}of i?.columnLimits??[])r["string"==typeof e?e:e.getColId()]=t;let o=this.beans.visibleCols.allCols;if(e<=0||!o.length)return;let a=a5(o);if(i?.onlyScaleUp&&a>e||e===a&&o.every(e=>{if(e.colDef.suppressSizeToFit)return!0;let t=r?.[e.getId()],n=t?.minWidth??i?.defaultMinWidth,o=t?.maxWidth??i?.defaultMaxWidth,a=e.getActualWidth();return(null==n||a>=n)&&(null==o||a<=o)}))return;let s=[],l=[];for(let e of o){let t=i?.colKeys?.some(t=>st(e,t))??!0;e.getColDef().suppressSizeToFit||!t?l.push(e):s.push(e)}let d=s.slice(0),u=!1,c=e=>{aJ(s,e),l.push(e)};for(let e of s){e.resetActualWidth(t);let n=r?.[e.getId()],o=n?.minWidth??i?.defaultMinWidth,a=n?.maxWidth??i?.defaultMaxWidth,s=e.getActualWidth();"number"==typeof o&&s<o?e.setActualWidth(o,t,!0):"number"==typeof a&&s>a&&e.setActualWidth(a,t,!0)}for(;!u;){u=!0;let n=e-a5(l);if(n<=0)for(let e of s){let n=r?.[e.getId()]?.minWidth??i?.defaultMinWidth??e.minWidth;e.setActualWidth(n,t,!0)}else{let e=n/a5(s),o=n;for(let n=s.length-1;n>=0;n--){let a=s[n],l=r?.[a.getId()],d=l?.minWidth??i?.defaultMinWidth,h=l?.maxWidth??i?.defaultMaxWidth,p=a.getMinWidth(),f=a.getMaxWidth(),g="number"==typeof d&&d>p?d:p,m="number"==typeof h&&h<f?h:f,v=Math.round(a.getActualWidth()*e);v<g?(v=g,c(a),u=!1):v>m?(v=m,c(a),u=!1):0===n&&(v=o),a.setActualWidth(v,t,!0),o-=v}}}for(let e of d)e.fireColumnWidthChangedEvent(t);let h=this.beans.visibleCols;h.setLeftValues(t),h.updateBodyWidths(),n||sc(this.eventSvc,d,!0,t)}applyAutosizeStrategy(){let{gos:e,colDelayRenderSvc:t}=this.beans,n=e.get("autoSizeStrategy");(n?.type==="fitGridWidth"||n?.type==="fitProvidedWidth")&&setTimeout(()=>{if(!this.isAlive())return;let e=n.type;if("fitGridWidth"===e){let{columnLimits:e,defaultMinWidth:t,defaultMaxWidth:i}=n,r=e?.map(({colId:e,minWidth:t,maxWidth:n})=>({key:e,minWidth:t,maxWidth:n}));this.sizeColumnsToFitGridBody({defaultMinWidth:t,defaultMaxWidth:i,columnLimits:r})}else"fitProvidedWidth"===e&&this.sizeColumnsToFit(n.width,"sizeColumnsToFit");t?.revealColumns(e)})}onFirstDataRendered({colIds:e,...t}){setTimeout(()=>{if(!this.isAlive())return;let n="autosizeColumns";e?this.autoSizeCols({...t,source:n,colKeys:e}):this.autoSizeAllColumns({...t,source:n}),this.beans.colDelayRenderSvc?.revealColumns(t.type)})}processResizeOperations(){for(let e of(this.shouldQueueResizeOperations=!1,this.resizeOperation
412Queue))e();this.resizeOperationQueue=[]}pushResizeOperation(e){this.resizeOperationQueue.push(e)}destroy(){this.resizeOperationQueue.length=0,super.destroy()}}],apiFunctions:{sizeColumnsToFit:function(e,t){"number"==typeof t?e.colAutosize?.sizeColumnsToFit(t,"api"):e.colAutosize?.sizeColumnsToFitGridBody(t)},autoSizeColumns:mb,autoSizeAllColumns:function(e,t){t&&"object"==typeof t?mb(e,t):e.colAutosize?.autoSizeAllColumns({source:"api",skipHeader:t})}},dependsOn:[hc]},mC={moduleName:"RowStyle",version:o1,beans:[fs]},mS={moduleName:"RowAutoHeight",version:o1,beans:[class extends oI{constructor(){super(...arguments),this.beanName="rowAutoHeight",this.wasEverActive=!1,this._debouncedCalculateRowHeights=oO(this,this.calculateRowHeights.bind(this),1)}requestCheckAutoHeight(){this.wasEverActive&&this._debouncedCalculateRowHeights()}calculateRowHeights(){let{visibleCols:e,rowModel:t,rowSpanSvc:n,pinnedRowModel:i}=this.beans,r=e.autoHeightCols,o=!1,a=e=>{let t=e.__autoHeights,i=ac(this.beans,e).height;for(let o of r){let r=t?.[o.getColId()],a=n?.getCellSpan(o,e);if(a){if(a.getLastNode()!==e)continue;if(!(r=n?.getCellSpan(o,e)?.getLastNodeAutoHeight()))return}if(null==r){if(this.colSpanSkipCell(o,e))continue;return}i=Math.max(r,i)}i!==e.rowHeight&&(e.setRowHeight(i),o=!0)};i?.forEachPinnedRow?.("top",a),i?.forEachPinnedRow?.("bottom",a),t.forEachDisplayedNode?.(a),o&&t.onRowHeightChanged?.()}setRowAutoHeight(e,t,n){if(e.__autoHeights??(e.__autoHeights={}),void 0==t)return void delete e.__autoHeights[n.getId()];let i=e.__autoHeights[n.getId()];e.__autoHeights[n.getId()]=t,i!==t&&this.requestCheckAutoHeight()}colSpanSkipCell(e,t){let{colModel:n,colViewport:i,visibleCols:r}=this.beans;if(!n.colSpanActive)return!1;let o=[];switch(e.getPinned()){case"left":o=r.getLeftColsForRow(t);break;case"right":o=r.getRightColsForRow(t);break;case null:o=i.getColsWithinViewport(t)}return!o.includes(e)}setupCellAutoHeight(e,t,n){if(!e.column.isAutoHeight()||!t)return!1;this.wasEverActive=!0;let i=t.parentElement,{rowNode:r,column:o}=e,a=this.beans,s=l=>{if(this.beans.editSvc?.isEditing(e)||!e.isAlive()||!n.isAlive())return;let{paddingTop:d,paddingBottom:u,borderBottomWidth:c,borderTopWidth:h}=rQ(i),p=t.offsetHeight+(d+u+c+h);if(l<5){let e=rP(a),n=!e?.contains(t),i=0==p;if(n||i)return void window.setTimeout(()=>s(l+1),0)}this.setRowAutoHeight(r,p,o)},l=()=>s(0);l();let d=oh(a,t,l);return n.addDestroyFunc(()=>{d(),this.setRowAutoHeight(r,void 0,o)}),!0}setAutoHeightActive(e){this.active=e.list.some(e=>e.isVisible()&&e.isAutoHeight())}areRowsMeasured(){if(!this.active)return!0;let e=this.beans.rowRenderer.getAllRowCtrls(),t=null;for(let{rowNode:n}of e)if((!t||this.beans.colModel.colSpanActive)&&(t=this.beans.colViewport.getColsWithinViewport(n).filter(e=>e.isAutoHeight())),0!==t.length){if(!n.__autoHeights)return!1;for(let e of t){let t=n.__autoHeights[e.getColId()];if(!t||n.rowHeight<t)return!1}}return!0}}]},m_=rb.default.createContext({}),mk=rb.default.createContext("default"),mM=(e,t,n,i)=>{let r,o;if(!e||e.componentFromFramework||t.isDestroyed())return;let a=e.newAgStackInstance(),s=!1;return a.then(e=>{s?t.destroyBean(e):(o=(r=e).getGui(),n.appendChild(o),mT(i,r))}),()=>{s=!0,r&&(o?.remove(),t.destroyBean(r),i&&mT(i,void 0))}},mT=(e,t)=>{e&&(e instanceof Function?e(t):e.current=t)},mD=(...e)=>e.filter(e=>null!=e&&""!==e).join(" "),mR=class e{constructor(...e){for(const t of(this.classesMap={},e))this.classesMap[t]=!0}setClass(t,n){if(!!this.classesMap[t]==n)return this;let i=new e;return i.classesMap={...this.classesMap},i.classesMap[t]=n,i}toString(){return Object.keys(this.classesMap).filter(e=>this.classesMap[e]).join(" ")}},mI=e=>"function"==typeof e&&!(e.prototype&&e.prototype.isReactComponent)||"object"==typeof e&&e.$$typeof===("function"==typeof Symbol&&Symbol.for?Symbol.for("react.memo"):60115),mA=rb.default.version?.split(".")[0],mP="16"===mA||"17"===mA,mE=!1,mL=(e,t)=>{mP||!e||mE?t():nD.default.flushSync(t)};function mF(e,t,n){if(null==t||null==e)return t;if(e===t||0===t.length&&0===e.length)return e;if(n||0===e.length&&t.length>0||e.length>0&&0===t.length)return t;let i=[],r=[],o=new Map,a=new Map;for(let e=0;e<t.length;e++){let n=t[e];a.set(n.instanceId,n)}for(let t=0;t<e.length;t++){let n=e[t];o.set(n.instanceId,n),a.has(n.instanceId)&&i.push(n)}for(let e=0;e<t.length;e++){let n=t[e],i=n.instanceId;o.has(i)||r.push(n)}return i.length===e.length&&0===r.length?e:0===i.length&&r.length===t.length?t:0===i.length?r:0===r.length?
412i:[...i,...r]}var mO=(0,rb.forwardRef)((e,t)=>{let{registry:n,context:i}=(0,rb.useContext)(m_),r=(0,rb.useRef)(null),o=(0,rb.useRef)(null),a=(0,rb.useRef)(null),s=(0,rb.useRef)(null),l=(0,rb.useRef)(null),d=(0,rb.useRef)(),[u,c]=(0,rb.useState)(),[h,p]=(0,rb.useState)(),[f,g]=(0,rb.useState)(),[m,v]=(0,rb.useState)(()=>new mR),[y,b]=(0,rb.useState)(()=>new mR("ag-hidden")),[x,w]=(0,rb.useState)(()=>new mR("ag-hidden")),[C,S]=(0,rb.useState)(()=>new mR("ag-invisible"));(0,rb.useImperativeHandle)(t,()=>({refresh:()=>!1})),(0,rb.useLayoutEffect)(()=>mM(u,i,o.current),[u]);let _=(0,rb.useCallback)(t=>{if(r.current=t,!t||i.isDestroyed()){d.current=i.destroyBean(d.current);return}let o=n.createDynamicBean("groupCellRendererCtrl",!0);o&&(d.current=i.createBean(o),d.current.init({setInnerRenderer:(e,t)=>{c(e),g(t)},setChildCount:e=>p(e),toggleCss:(e,t)=>v(n=>n.setClass(e,t)),setContractedDisplayed:e=>w(t=>t.setClass("ag-hidden",!e)),setExpandedDisplayed:e=>b(t=>t.setClass("ag-hidden",!e)),setCheckboxVisible:e=>S(t=>t.setClass("ag-invisible",!e)),setCheckboxSpacing:e=>S(t=>t.setClass("ag-group-checkbox-spacing",e))},t,a.current,s.current,l.current,mO,e))},[]),k=(0,rb.useMemo)(()=>`ag-cell-wrapper ${m.toString()}`,[m]),M=(0,rb.useMemo)(()=>`ag-group-expanded ${y.toString()}`,[y]),T=(0,rb.useMemo)(()=>`ag-group-contracted ${x.toString()}`,[x]),D=(0,rb.useMemo)(()=>`ag-group-checkbox ${C.toString()}`,[C]),R=u?.componentFromFramework,I=R?u.componentClass:void 0,A=null==u&&null!=f,P=rD(f);return rb.default.createElement("span",{className:k,ref:_,...!e.colDef?{role:d.current?.getCellAriaRole()}:{}},rb.default.createElement("span",{className:M,ref:s}),rb.default.createElement("span",{className:T,ref:l}),rb.default.createElement("span",{className:D,ref:a}),rb.default.createElement("span",{className:"ag-group-value",ref:o},A?P:R?rb.default.createElement(I,{...u.params}):null),rb.default.createElement("span",{className:"ag-group-child-count"},h))}),mN=(0,rb.createContext)({setMethods:()=>{}}),mB=(0,rb.memo)(e=>{let{initialProps:t,addUpdateCallback:n,CustomComponentClass:i,setMethods:r}=e,[{key:o,...a},s]=(0,rb.useState)(t);return(0,rb.useEffect)(()=>{n(e=>s(e))},[]),rb.default.createElement(mN.Provider,{value:{setMethods:r}},rb.default.createElement(i,{key:o,...a}))}),mz=0;function mj(){return`agPortalKey_${++mz}`}var mV=class{constructor(e,t,n,i){this.portal=null,this.oldPortal=null,this.reactComponent=e,this.portalManager=t,this.componentType=n,this.suppressFallbackMethods=!!i,this.statelessComponent=this.isStateless(this.reactComponent),this.key=mj(),this.portalKey=mj(),this.instanceCreated=this.isStatelessComponent()?sT.resolve(!1):new sT(e=>{this.resolveInstanceCreated=e})}getGui(){return this.eParentElement}getRootElement(){return this.eParentElement.firstChild}destroy(){this.componentInstance&&"function"==typeof this.componentInstance.destroy&&this.componentInstance.destroy();let e=this.portal;e&&this.portalManager.destroyPortal(e)}createParentElement(e){let t=this.portalManager.getComponentWrappingElement(),n=document.createElement(t||"div");return n.classList.add("ag-react-container"),e.reactContainer=n,n}statelessComponentRendered(){return this.eParentElement.childElementCount>0||this.eParentElement.childNodes.length>0}getFrameworkComponentInstance(){return this.componentInstance}isStatelessComponent(){return this.statelessComponent}getReactComponentName(){return this.reactComponent.name}getMemoType(){return this.hasSymbol()?Symbol.for("react.memo"):60115}hasSymbol(){return"function"==typeof Symbol&&Symbol.for}isStateless(e){return"function"==typeof e&&!(e.prototype&&e.prototype.isReactComponent)||"object"==typeof e&&e.$$typeof===this.getMemoType()}hasMethod(e){let t=this.getFrameworkComponentInstance();return!!t&&null!=t[e]||this.fallbackMethodAvailable(e)}callMethod(e,t){let n=this.getFrameworkComponentInstance();if(this.isStatelessComponent())return this.fallbackMethod(e,t&&t[0]?t[0]:{});if(!n)return void setTimeout(()=>this.callMethod(e,t));let i=n[e];return i?i.apply(n,t):this.fallbackMethodAvailable(e)?this.fallbackMethod(e,t&&t[0]?t[0]:{}):void 0}
412addMethod(e,t){this[e]=t}init(e){return this.eParentElement=this.createParentElement(e),this.createOrUpdatePortal(e),new sT(e=>this.createReactComponent(e))}createOrUpdatePortal(e){this.isStatelessComponent()||(this.ref=e=>{this.componentInstance=e,this.resolveInstanceCreated?.(!0),this.resolveInstanceCreated=void 0},e.ref=this.ref),this.reactElement=this.createElement(this.reactComponent,{...e,key:this.key}),this.portal=(0,nD.createPortal)(this.reactElement,this.eParentElement,this.portalKey)}createElement(e,t){return(0,rb.createElement)(e,t)}createReactComponent(e){this.portalManager.mountReactPortal(this.portal,this,e)}rendered(){return this.isStatelessComponent()&&this.statelessComponentRendered()||!!(!this.isStatelessComponent()&&this.getFrameworkComponentInstance())}refreshComponent(e){this.oldPortal=this.portal,this.createOrUpdatePortal(e),this.portalManager.updateReactPortal(this.oldPortal,this.portal)}fallbackMethod(e,t){let n=this[`${e}Component`];if(!this.suppressFallbackMethods&&n)return n.bind(this)(t)}fallbackMethodAvailable(e){return!this.suppressFallbackMethods&&!!this[`${e}Component`]}};function mH(e,t,n){for(let i of e){let e=t[i];e&&(n[i]=e)}}var mG=class extends mV{constructor(){super(...arguments),this.awaitUpdateCallback=new sT(e=>{this.resolveUpdateCallback=e}),this.wrapperComponent=mB}init(e){return this.sourceParams=e,super.init(this.getProps())}addMethod(){}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}getFrameworkComponentInstance(){return this}createElement(e,t){return super.createElement(this.wrapperComponent,{initialProps:t,CustomComponentClass:e,setMethods:e=>this.setMethods(e),addUpdateCallback:e=>{this.updateCallback=()=>(e(this.getProps()),new sT(e=>{setTimeout(()=>{e()})})),this.resolveUpdateCallback()}})}setMethods(e){this.providedMethods=e,mH(this.getOptionalMethods(),this.providedMethods,this)}getOptionalMethods(){return[]}getProps(){return{...this.sourceParams,key:this.key,ref:this.ref}}refreshProps(){return this.updateCallback?this.updateCallback():new sT(e=>this.awaitUpdateCallback.then(()=>{this.updateCallback().then(()=>e())}))}},mW=class extends mG{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},m$=class extends mG{constructor(){super(...arguments),this.date=null,this.onDateChange=e=>this.updateDate(e)}getDate(){return this.date}setDate(e){this.date=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled"]}updateDate(e){this.setDate(e),this.sourceParams.onDateChanged()}getProps(){let e=super.getProps();return e.date=this.date,e.onDateChange=this.onDateChange,delete e.onDateChanged,e}},mU=class extends mG{constructor(){super(...arguments),this.label="",this.icon=null,this.shake=!1}setIcon(e,t){this.icon=e,this.shake=t,this.refreshProps()}setLabel(e){this.label=e,this.refreshProps()}getProps(){let e=super.getProps(),{label:t,icon:n,shake:i}=this;return e.label=t,e.icon=n,e.shake=i,e}},mq=class extends mG{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e),this.onUiChange=()=>this.sourceParams.filterModifiedCallback(),this.expectingNewMethods=!0,this.hasBeenActive=!1,this.awaitSetMethodsCallback=new sT(e=>{this.resolveSetMethodsCallback=e})}isFilterActive(){return null!=this.model}doesFilterPass(e){return this.providedMethods.doesFilterPass(e)}getModel(){return this.model}setModel(e){return this.expectingNewMethods=!0,this.model=e,this.hasBeenActive||(this.hasBeenActive=this.isFilterActive()),this.refreshProps()}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}afterGuiAttached(e){let t=this.providedMethods;t?t.afterGuiAttached?.(e):this.awaitSetMethodsCallback.then(()=>this.providedMethods?.afterGuiAttached?.(e))}getOptionalMethods(){return["afterGuiDetached","onNewRowsLoaded","getModelAsString","onAnyFilterChanged"]}setMethods(e){!1===this.expectingNewMethods&&this.hasBeenActive&&this.providedMethods?.doesFilterPass!==e?.doesFilterPass&&setTimeout(()=>{this.sourceParams.filterChangedCallback()}),this.expectingNewMethods=!1,super.setMethods(e),this.resolveSetMethodsCallback(),this.resolveFilterPassCallback?.(),this.resolveFilterPassCallback=void 0}updateModel(e){this.resolveFilterPassCallback?.();let t=new sT(e=>{this.resolveFilterPassCallback=e});this.setModel(e).then(()=>{t.then(()=>{this.sourceParams.filterChangedCallback()})})}getProps(){let e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e.onUiChange=this.onUiChange,delete e.filterChangedCallback,e}},mK=class extends mG{constructor(){super(...arguments),this.awaitSetMethodsCallback=new sT(e=>{this.resolveSetMethodsCallback=e})}
412refresh(e){return this.sourceParams=e,this.refreshProps(),!0}afterGuiAttached(e){let t=this.providedMethods;t?t.afterGuiAttached?.(e):this.awaitSetMethodsCallback.then(()=>this.providedMethods?.afterGuiAttached?.(e))}getOptionalMethods(){return["afterGuiDetached","onNewRowsLoaded","onAnyFilterChanged"]}setMethods(e){super.setMethods(e),this.resolveSetMethodsCallback()}};function mY(e,t){e.parentFilterInstance(n=>{(n.setModel(t)||sT.resolve()).then(()=>{e.filterParams.filterChangedCallback()})})}var mZ=class{constructor(e,t){this.floatingFilterParams=e,this.refreshProps=t,this.model=null,this.onModelChange=e=>this.updateModel(e)}getProps(){return{...this.floatingFilterParams,model:this.model,onModelChange:this.onModelChange}}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.floatingFilterParams=e,this.refreshProps()}setMethods(e){mH(this.getOptionalMethods(),e,this)}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),mY(this.floatingFilterParams,e)}},mX=class extends mG{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e)}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),mY(this.sourceParams,e)}getProps(){let e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e}},mJ=class extends mG{refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached"]}},mQ=class extends mG{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},m0=class extends mG{refresh(e){this.sourceParams=e,this.refreshProps()}},m1=class extends mG{constructor(){super(...arguments),this.active=!1,this.expanded=!1,this.onActiveChange=e=>this.updateActive(e)}setActive(e){this.awaitSetActive(e)}setExpanded(e){this.expanded=e,this.refreshProps()}getOptionalMethods(){return["select","configureDefaults"]}awaitSetActive(e){return this.active=e,this.refreshProps()}updateActive(e){let t=this.awaitSetActive(e);e&&t.then(()=>this.sourceParams.onItemActivated())}getProps(){let e=super.getProps();return e.active=this.active,e.expanded=this.expanded,e.onActiveChange=this.onActiveChange,delete e.onItemActivated,e}},m2=class extends mG{refresh(e){this.sourceParams=e,this.refreshProps()}},m3=class extends mG{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},m5=class extends mG{constructor(){super(...arguments),this.onStateChange=e=>this.updateState(e)}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}getState(){return this.state}updateState(e){this.state=e,this.refreshProps(),this.sourceParams.onStateUpdated()}getProps(){let e=super.getProps();return e.state=this.state,e.onStateChange=this.onStateChange,e}};function m4(){at(231)}var m6=class{constructor(e,t,n){this.destroyed=!1,this.portals=[],this.hasPendingPortalUpdate=!1,this.wrappingElement=t||"div",this.refresher=e,this.maxComponentCreationTimeMs=n||1e3}getPortals(){return this.portals}destroy(){this.destroyed=!0}destroyPortal(e){this.portals=this.portals.filter(t=>t!==e),this.batchUpdate()}getComponentWrappingElement(){return this.wrappingElement}mountReactPortal(e,t,n){this.portals=[...this.portals,e],this.waitForInstance(t,n),this.batchUpdate()}updateReactPortal(e,t){this.portals[this.portals.indexOf(e)]=t,this.batchUpdate()}batchUpdate(){this.hasPendingPortalUpdate||(setTimeout(()=>{this.destroyed||(this.refresher(),this.hasPendingPortalUpdate=!1)}),this.hasPendingPortalUpdate=!0)}waitForInstance(e,t,n=Date.now()){if(this.destroyed)return void t(null);if(e.rendered())t(e);else{if(Date.now()-n>=this.maxComponentCreationTimeMs&&!this.hasPendingPortalUpdate){mL(!0,()=>this.refresher()),e.rendered()&&t(e);return}window.setTimeout(()=>{this.waitForInstance(e,t,n)})}}},m8=(0,rb.memo)(({ctrl:e})=>{let t=e.isAlive(),{context:n}=(0,rb.useContext)(m_),[i,r]=(0,rb.useState)(),[o,a]=(0,rb.useState)(),s=(0,rb.useRef)(),l=(0,rb.useRef)(null),d=(0,rb.useRef)(null),u=(0,rb.useRef)(null),c=(0,rb.useRef)(),h=(0,rb.useRef)();
412t&&!h.current&&(h.current=new sC(()=>l.current));let p=(0,rb.useCallback)(t=>{if(l.current=t,!t||!e.isAlive()||n.isDestroyed()){s.current=n.destroyBean(s.current);return}s.current=n.createBean(new sb);let i=()=>{let t=e.getSelectAllGui();t&&(d.current?.insertAdjacentElement("afterend",t),s.current.addDestroyFunc(()=>t.remove()))};e.setComp({setWidth:e=>{l.current&&(l.current.style.width=e)},toggleCss:(e,t)=>h.current.toggleCss(e,t),setUserStyles:e=>a(e),setAriaSort:e=>{l.current&&(e?rN(l.current,"sort",e):rB(l.current,"sort"))},setUserCompDetails:e=>r(e),getUserCompInstance:()=>c.current||void 0,refreshSelectAllGui:i,removeSelectAllGui:()=>e.getSelectAllGui()?.remove()},t,d.current,u.current,s.current),i()},[]);(0,rb.useLayoutEffect)(()=>mM(i,n,u.current,c),[i]),(0,rb.useEffect)(()=>{e.setDragSource(l.current)},[i]);let f=(0,rb.useMemo)(()=>!!(i?.componentFromFramework&&mI(i.componentClass)),[i]),g=i?.componentFromFramework,m=i?.componentClass;return rb.default.createElement("div",{ref:p,style:o,className:"ag-header-cell",role:"columnheader"},rb.default.createElement("div",{ref:d,className:"ag-header-cell-resize",role:"presentation"}),rb.default.createElement("div",{ref:u,className:"ag-header-cell-comp-wrapper",role:"presentation"},g?f?rb.default.createElement(m,{...i.params}):rb.default.createElement(m,{...i.params,ref:c}):null))}),m7=class{constructor(e,t){this.floatingFilterParams=e,this.refreshProps=t}getProps(){return this.floatingFilterParams}refresh(e){this.floatingFilterParams=e,this.refreshProps()}setMethods(e){mH(this.getOptionalMethods(),e,this)}getOptionalMethods(){return["afterGuiAttached"]}},m9=(0,rb.memo)(({ctrl:e})=>{let{context:t,gos:n}=(0,rb.useContext)(m_),[i,r]=(0,rb.useState)(),[o,a]=(0,rb.useState)(()=>new mR("ag-header-cell","ag-floating-filter")),[s,l]=(0,rb.useState)(()=>new mR),[d,u]=(0,rb.useState)(()=>new mR("ag-floating-filter-button","ag-hidden")),[c,h]=(0,rb.useState)("false"),[p,f]=(0,rb.useState)(),[,g]=(0,rb.useState)(1),m=(0,rb.useRef)(),v=(0,rb.useRef)(null),y=(0,rb.useRef)(null),b=(0,rb.useRef)(null),x=(0,rb.useRef)(null),w=(0,rb.useRef)(),C=(0,rb.useRef)(),S=e=>{null!=e&&w.current&&w.current(e)},_=(0,rb.useCallback)(n=>{if(v.current=n,!n||!e.isAlive()||t.isDestroyed()){m.current=t.destroyBean(m.current);return}m.current=t.createBean(new sb),C.current=new sT(e=>{w.current=e}),e.setComp({toggleCss:(e,t)=>a(n=>n.setClass(e,t)),setUserStyles:e=>r(e),addOrRemoveBodyCssClass:(e,t)=>l(n=>n.setClass(e,t)),setButtonWrapperDisplayed:e=>{u(t=>t.setClass("ag-hidden",!e)),h(e?"false":"true")},setWidth:e=>{v.current&&(v.current.style.width=e)},setCompDetails:e=>f(e),getFloatingFilterComp:()=>C.current?C.current:null,setMenuIcon:e=>x.current?.appendChild(e)},n,x.current,y.current,m.current)},[]);(0,rb.useLayoutEffect)(()=>mM(p,t,y.current,S),[p]);let k=(0,rb.useMemo)(()=>o.toString(),[o]),M=(0,rb.useMemo)(()=>s.toString(),[s]),T=(0,rb.useMemo)(()=>d.toString(),[d]),D=(0,rb.useMemo)(()=>!!(p&&p.componentFromFramework&&mI(p.componentClass)),[p]),R=(0,rb.useMemo)(()=>n.get("reactiveCustomComponents"),[]),I=(0,rb.useMemo)(()=>n.get("enableFilterHandlers"),[]),[A,P]=(0,rb.useState)();(0,rb.useEffect)(()=>{if(p?.componentFromFramework)if(R){let e=new(I?m7:mZ)(p.params,()=>g(e=>e+1));S(e),P(e)}else m4()},[p]);let E=A?.getProps(),L=p?.componentFromFramework,F=p?.componentClass;return rb.default.createElement("div",{ref:_,style:i,className:k,role:"gridcell"},rb.default.createElement("div",{ref:y,className:M,role:"presentation"},L?R?E&&rb.default.createElement(mN.Provider,{value:{setMethods:e=>A.setMethods(e)}},rb.default.createElement(F,{...E})):rb.default.createElement(F,{...p.params,ref:D?()=>{}:S}):null),rb.default.createElement("div",{ref:b,"aria-hidden":c,className:T,role:"presentation"},rb.default.createElement("button",{ref:x,type:"button",className:"ag-button ag-floating-filter-button-button",tabIndex:-1})))}),ve=(0,rb.memo)(({ctrl:e})=>{let{context:t}=(0,rb.useContext)(m_),[n,i]=(0,rb.useState)(),[r,o]=(0,rb.useState)(()=>new mR),[a,s]=(0,rb.useState)(()=>new mR),[l,d]=(0,rb.useState)("false"),[u,c]=(0,rb.useState)(),[h,p]=(0,rb.useState)(),f=(0,rb.useRef)(),g=(0,rb.useRef)(null),m=(0,rb.useRef)(null),v=(0,rb.useRef)(null),y=(0,rb.useRef)(),b=(0,rb.useCallback)(n=>{if(g.current=n,!n||!e.isAlive()||t.isDestroyed()){f.current=t.destroyBean(f.current);return}f.current=t.createBean(new sb),e.setComp({setWidth:e=>{g.current&&(g.current.style.width=e)},toggleCss:(e,t)=>o(n=>n.setClass(e,t)),setUserStyles:e=>i(e),setHeaderWrapperHidden:e=>{let t=v.current;t&&(e?t.style.setProperty("display","none"):t.style.removeProperty("display"))},setHeaderWrapperMaxHeight:e=>{let t=v.current;t&&(null!=e?t.style.setProperty("max-height",`${e}px`):t.style.removeProperty("max-height"),t.classList.toggle("ag-header-cell-comp-wrapper-limited-height",null!=e))}
412,setUserCompDetails:e=>p(e),setResizableDisplayed:e=>{s(t=>t.setClass("ag-hidden",!e)),d(e?"false":"true")},setAriaExpanded:e=>c(e),getUserCompInstance:()=>y.current||void 0},n,m.current,v.current,f.current)},[]);(0,rb.useLayoutEffect)(()=>mM(h,t,v.current),[h]),(0,rb.useEffect)(()=>{g.current&&e.setDragSource(g.current)},[h]);let x=(0,rb.useMemo)(()=>!!(h?.componentFromFramework&&mI(h.componentClass)),[h]),w=(0,rb.useMemo)(()=>"ag-header-group-cell "+r.toString(),[r]),C=(0,rb.useMemo)(()=>"ag-header-cell-resize "+a.toString(),[a]),S=h?.componentFromFramework,_=h?.componentClass;return rb.default.createElement("div",{ref:b,style:n,className:w,role:"columnheader","aria-expanded":u},rb.default.createElement("div",{ref:v,className:"ag-header-cell-comp-wrapper",role:"presentation"},S?x?rb.default.createElement(_,{...h.params}):rb.default.createElement(_,{...h.params,ref:y}):null),rb.default.createElement("div",{ref:m,"aria-hidden":l,className:C}))}),vt=(0,rb.memo)(({ctrl:e})=>{let{gos:t,context:n}=(0,rb.useContext)(m_),{topOffset:i,rowHeight:r}=(0,rb.useMemo)(()=>e.getTopAndHeight(),[]),o=(0,rb.useMemo)(()=>t.get("tabIndex"),[]),[a,s]=(0,rb.useState)(()=>e.getAriaRowIndex()),l=e.headerRowClass,[d,u]=(0,rb.useState)(()=>r+"px"),[c,h]=(0,rb.useState)(()=>i+"px"),p=(0,rb.useRef)(null),[f,g]=(0,rb.useState)(()=>e.getUpdatedHeaderCtrls()),m=(0,rb.useRef)(),v=(0,rb.useRef)(null),y=(0,rb.useCallback)(t=>{if(v.current=t,!t||!e.isAlive()||n.isDestroyed()){m.current=n.destroyBean(m.current);return}m.current=n.createBean(new sb),e.setComp({setHeight:e=>u(e),setTop:e=>h(e),setHeaderCtrls:(e,t,n)=>{let i=p.current,r=mF(i,e,t);r!==i&&(p.current=r,mL(n,()=>g(r)))},setWidth:e=>{v.current&&(v.current.style.width=e)},setRowIndex:e=>{s(e)}},m.current,!1)},[]),b=(0,rb.useMemo)(()=>({height:d,top:c}),[d,c]),x=(0,rb.useCallback)(t=>{switch(e.type){case"group":return rb.default.createElement(ve,{ctrl:t,key:t.instanceId});case"filter":return rb.default.createElement(m9,{ctrl:t,key:t.instanceId});default:return rb.default.createElement(m8,{ctrl:t,key:t.instanceId})}},[]);return rb.default.createElement("div",{ref:y,className:l,role:"row",style:b,tabIndex:o,"aria-rowindex":a},f.map(x))}),vn=(0,rb.memo)(({pinned:e})=>{let[t,n]=(0,rb.useState)(!0),[i,r]=(0,rb.useState)([]),{context:o}=(0,rb.useContext)(m_),a=(0,rb.useRef)(null),s=(0,rb.useRef)(null),l=(0,rb.useRef)(),d="left"===e,u="right"===e,c=(0,rb.useCallback)(t=>{if(a.current=t,!t||o.isDestroyed()){l.current=o.destroyBean(l.current);return}l.current=o.createBean(new cl(e)),l.current.setComp({setDisplayed:n,setCtrls:e=>r(e),setCenterWidth:e=>{s.current&&(s.current.style.width=e)},setViewportScrollLeft:e=>{a.current&&(a.current.scrollLeft=e)},setPinnedContainerWidth:e=>{a.current&&(a.current.style.width=e,a.current.style.minWidth=e,a.current.style.maxWidth=e)}},a.current)},[]),h=t?"":"ag-hidden",p=()=>i.map(e=>rb.default.createElement(vt,{ctrl:e,key:e.instanceId}));return d?rb.default.createElement("div",{ref:c,className:"ag-pinned-left-header "+h,"aria-hidden":!t,role:"rowgroup"},p()):u?rb.default.createElement("div",{ref:c,className:"ag-pinned-right-header "+h,"aria-hidden":!t,role:"rowgroup"},p()):d||u?null:rb.default.createElement("div",{ref:c,className:"ag-header-viewport "+h,role:"rowgroup",tabIndex:-1},rb.default.createElement("div",{ref:s,className:"ag-header-container",role:"presentation"},p()))}),vi=(0,rb.memo)(()=>{let[e,t]=(0,rb.useState)(()=>new mR),[n,i]=(0,rb.useState)(),{context:r}=(0,rb.useContext)(m_),o=(0,rb.useRef)(null),a=(0,rb.useRef)(),s=(0,rb.useCallback)(e=>{if(o.current=e,!e||r.isDestroyed()){a.current=r.destroyBean(a.current);return}a.current=r.createBean(new u9),a.current.setComp({toggleCss:(e,n)=>t(t=>t.setClass(e,n)),setHeightAndMinHeight:e=>i(e)},e,e)},[]),l=(0,rb.useMemo)(()=>"ag-header "+e.toString(),[e]),d=(0,rb.useMemo)(()=>({height:n,minHeight:n}),[n]);return rb.default.createElement("div",{ref:s,className:l,style:d,role:"presentation"},rb.default.createElement(vn,{pinned:"left"}),rb.default.createElement(vn,{pinned:null}),rb.default.createElement(vn,{pinned:"right"}))}),vr=(e,t)=>{(0,rb.useEffect)(()=>{let n=t.current;if(n){let t=n.parentElement;if(t){let i=document.createComment(e);return t.insertBefore(i,n),()=>{i.remove()}}}},[e])},vo=class{constructor(e,t){this.cellEditorParams=e,this.refreshPro
412ps=t,this.instanceCreated=new sT(e=>{this.resolveInstanceCreated=e}),this.onValueChange=e=>this.updateValue(e),this.value=e.value}getProps(){return{...this.cellEditorParams,initialValue:this.cellEditorParams.value,value:this.value,onValueChange:this.onValueChange}}getValue(){return this.value}refresh(e){this.cellEditorParams=e,this.refreshProps()}setMethods(e){mH(this.getOptionalMethods(),e,this)}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}setRef(e){this.componentInstance=e,this.resolveInstanceCreated?.(),this.resolveInstanceCreated=void 0}getOptionalMethods(){return["isCancelBeforeStart","isCancelAfterEnd","focusIn","focusOut","afterGuiAttached","getValidationErrors","getValidationElement"]}updateValue(e){this.value=e,this.refreshProps()}},va=(0,rb.memo)(e=>{let[t,n]=(0,rb.useState)(),i=(0,rb.useContext)(m_),{context:r,popupSvc:o,gos:a,editSvc:s}=i,{editDetails:l,cellCtrl:d,eParentCell:u}=e;return(e=>{let t=(0,rb.useRef)(e),n=(0,rb.useRef)(),i=(0,rb.useRef)(!1),r=(0,rb.useRef)(!1),[,o]=(0,rb.useState)(0);i.current&&(r.current=!0),(0,rb.useEffect)(()=>(i.current||(n.current=t.current(),i.current=!0),o(e=>e+1),()=>{r.current&&n.current?.()}),[])})(()=>{let t,i,{compDetails:c}=l,h=a.get("stopEditingWhenCellsLoseFocus");if(!r.isDestroyed()){let a=(t=r.createBean(s.createPopupEditorWrapper(c.params))).getGui();if(e.jsChildComp){let t=e.jsChildComp.getGui();t&&a.appendChild(t)}let{column:p,rowNode:f}=d,g={column:p,rowNode:f,type:"popupCellEditor",eventSource:u,ePopup:a,position:l.popupPosition,keepWithinBounds:!0},m=o?.positionPopupByComponent.bind(o,g),v=o?.addPopup({modal:h,eChild:a,closeOnEsc:!0,closedCallback:()=>{d.onPopupEditorClosed()},anchorToElement:u,positionCallback:m,ariaOwns:u});i=v?v.hideFunc:void 0,n(t),e.jsChildComp?.afterGuiAttached?.()}return()=>{i?.(),r.destroyBean(t)}}),(0,rb.useLayoutEffect)(()=>()=>{d.isCellFocused()&&t?.getGui().contains(rA(i))&&u.focus({preventScroll:!0})},[t]),t&&e.wrappedContent?(0,nD.createPortal)(e.wrappedContent,t.getGui()):null}),vs=(e,t,n)=>e.compProxy?((e,t,n)=>{let{compProxy:i}=e;n(i);let r=i.getProps(),o=mI(t);return rb.default.createElement(mN.Provider,{value:{setMethods:e=>i.setMethods(e)}},o?rb.default.createElement(t,{...r}):rb.default.createElement(t,{...r,ref:e=>i.setRef(e)}))})(e,t,n):rb.default.createElement(t,{...e.compDetails.params,ref:n}),vl=(e,t,n,i,r,o)=>{let{context:a}=(0,rb.useContext)(m_),s=(0,rb.useCallback)(()=>{let e=r.current;if(!e)return;let t=e.getGui();t&&t.parentElement&&t.remove(),a.destroyBean(e),r.current=void 0},[]);(0,rb.useEffect)(()=>{let i=null!=e,a=e?.compDetails&&!e.compDetails.componentFromFramework,l=t&&null==n;if(!(i&&a&&!l))return void s();let d=e.compDetails;if(r.current){let t=r.current,n=null!=t.refresh&&!1==e.force&&t.refresh(d.params);if(!0===n||void 0===n)return;s()}d.newAgStackInstance().then(e=>{if(!e)return;let i=e.getGui();i&&((t?n:o.current).appendChild(i),r.current=e)})},[e,t,i]),(0,rb.useEffect)(()=>s,[])},vd=({cellCtrl:e,parent:t})=>{let n=(0,rb.useRef)(),i=(0,rb.useMemo)(()=>{let{loadingComp:t}=e.getDeferLoadingCellRenderer();return t?{value:void 0,compDetails:t,force:!1}:void 0},[e]);if(vl(i,!1,void 0,1,n,t),i?.compDetails?.componentFromFramework){let e=i.compDetails.componentClass;return rb.default.createElement(e,{...i.compDetails.params})}return rb.default.createElement(rb.default.Fragment,null)},vu=(0,rb.memo)(({cellCtrl:e,printLayout:t,editingCell:n})=>{let{context:i}=(0,rb.useContext)(m_),{column:{colIdSanitised:r},instanceId:o}=e,a=(0,rb.useRef)(),[s,l]=(0,rb.useState)(()=>e.isCellRenderer()?void 0:{compDetails:void 0,value:e.getValueToDisplay(),force:!1}),[d,u]=(0,rb.useState)(),[c,h]=(0,rb.useState)(1),[p,f]=(0,rb.useState)(),[g,m]=(0,rb.useState)(!1),[v,y]=(0,rb.useState)(!1),[b,x]=(0,rb.useState)(!1),[w,C]=(0,rb.useState)(),S=(0,rb.useMemo)(()=>e.isForceWrapper(),[e]),_=(0,rb.useMemo)(()=>e.getCellAriaRole(),[e]),k=(0,rb.useRef)(null),M=(0,rb.useRef)(null),T=(0,rb.useRef)(null),D=(0,rb.useRef)(),R=(0,rb.useRef)(),I=(0,rb.useRef)(),A=(0,rb.useRef)([]),P=(0,rb.useRef)(),E=(0,rb.useRef)(),[L,F]=(0,rb.useState)(0),O
412=(0,rb.useCallback)(e=>{E.current=e,F(e=>e+1)},[]),N=null!=s&&(g||b||v)&&(null==d||!!d.popup),B=S||N,z=(0,rb.useMemo)(()=>e.getCellValueClass(),[e]),j=(0,rb.useCallback)(t=>{if(R.current=t,t){let n=t.isCancelBeforeStart&&t.isCancelBeforeStart();setTimeout(()=>{n?(e.stopEditing(!0),e.focusCell(!0)):(e.cellEditorAttached(),e.enableEditorTooltipFeature(t))})}},[e]),V=(0,rb.useRef)();V.current||(V.current=new sC(()=>k.current)),vl(s,B,E.current,L,D,k);let H=(0,rb.useRef)();(0,rb.useLayoutEffect)(()=>{let e=H.current;if(H.current=s,null==e||null==e.compDetails||null==s||null==s.compDetails)return;P.current?.refreshVisibility();let t=e.compDetails,n=s.compDetails;t.componentClass!=n.componentClass||T.current?.refresh==null||!0!=T.current.refresh(n.params)&&h(e=>e+1)},[s]),(0,rb.useLayoutEffect)(()=>{if(!(d&&!d.compDetails.componentFromFramework)||i.isDestroyed())return;let t=d.compDetails,n=!0===d.popup,r=t.newAgStackInstance();return r.then(e=>{if(!e)return;let t=e.getGui();if(j(e),!n){let n=(S?I:k).current;n?.appendChild(t),e.afterGuiAttached?.()}C(e)}),()=>{r.then(t=>{let n=t.getGui();e.disableEditorTooltipFeature(),i.destroyBean(t),j(void 0),C(void 0),n?.remove()})}},[d]);let G=(0,rb.useCallback)(t=>{let n;if(I.current=t,!t||i.isDestroyed()||!e.isAlive()){let e=A.current;for(let t of(A.current=[],e))t();return}let r=e=>{e&&(t.insertAdjacentElement("afterbegin",e.getGui()),A.current.push(()=>{r7(e.getGui()),i.destroyBean(e),P.current===n&&(P.current=void 0)}))};g&&r(e.createSelectionCheckbox()),b&&r(e.createDndSource()),v&&(P.current=n=e.createRowDragComp(),n&&(r(n),n.refreshVisibility()))},[e,i,b,v,g]),W=(0,rb.useCallback)(()=>{let r=!e.isCellSpanning()||M.current,o=k.current;if(!o||!r||!e||!e.isAlive()||i.isDestroyed()){a.current=i.destroyBean(a.current);return}a.current=i.createBean(new sb);let s={toggleCss:(e,t)=>V.current.toggleCss(e,t),setUserStyles:e=>f(e),getFocusableElement:()=>k.current,setIncludeSelection:e=>m(e),setIncludeRowDrag:e=>y(e),setIncludeDndSource:e=>x(e),getCellEditor:()=>R.current??null,getCellRenderer:()=>T.current??D.current,getParentOfValue:()=>E.current??I.current??k.current,setRenderDetails:(t,n,i)=>{let r=()=>{l(e=>e?.compDetails!==t||e?.value!==n||e?.force!==i?{value:n,compDetails:t,force:i}:e)};if(t?.params?.deferRender&&!e.rowNode.group){let{loadingComp:t,onReady:n}=e.getDeferLoadingCellRenderer();if(t){l({value:void 0,compDetails:t,force:!1}),n.then(()=>{mP?r():rb.default.startTransition(r)});return}}r()},setEditDetails:(t,n,i,r)=>{if(t){let e;t.componentFromFramework&&(r?e=new vo(t.params,()=>h(e=>e+1)):m4()),u({compDetails:t,popup:n,popupPosition:i,compProxy:e}),n||l(void 0)}else e.hasBrowserFocus()&&s.getFocusableElement().focus({preventScroll:!0}),R.current=void 0,u(void 0)},refreshEditStyles:(e,t)=>{if(!k.current)return;let{current:n}=V;n.toggleCss("ag-cell-value",!B),n.toggleCss("ag-cell-inline-editing",!!e&&!t),n.toggleCss("ag-cell-popup-editing",!!e&&!!t),n.toggleCss("ag-cell-not-inline-editing",!e||!!t)}},d=I.current||void 0;e.setComp(s,o,M.current??void 0,d,t,n,a.current)},[]),$=(0,rb.useCallback)(e=>{k.current=e,W()},[]),U=(0,rb.useCallback)(e=>{M.current=e,W()},[]),q=(0,rb.useMemo)(()=>!!(s?.compDetails?.componentFromFramework&&mI(s.compDetails.componentClass)),[s]);(0,rb.useLayoutEffect)(()=>{if(!k.current)return;let{current:e}=V;e.toggleCss("ag-cell-value",!B),e.toggleCss("ag-cell-inline-editing",!!d&&!d.popup),e.toggleCss("ag-cell-popup-editing",!!d&&!!d.popup),e.toggleCss("ag-cell-not-inline-editing",!d||!!d.popup)});let K=()=>{let{compDetails:t,value:n}=s;if(!t)return n?.toString?.()??n;if(t.componentFromFramework){let n=t.componentClass;return rb.default.createElement(rb.Suspense,{fallback:rb.default.createElement(vd,{cellCtrl:e,parent:k})},q?rb.default.createElement(n,{...t.params,key:c}):rb.default.createElement(n,{...t.params,key:c,ref:T}))}},Y=()=>{let t=()=>null==s?null:B?rb.default.createElement("span",{role:"presentation",id:`cell-${o}`,className:z,ref:O},K()):K(),n=t=>{var n;let i,r,o,a,s;return n=k.current,r=(i=t.compDetails).componentClass,o=i.componentFromFramework&&!t.popup,a=i.componentFromFramework&&t.popup,s=!i.componentFromFramework&&t.popup,o?vs(t,r,j):a?rb.default.createElement(va,{editDetails:t,cellCtrl:e,eParentCell:n,wrappedContent:vs(t,r,j)}):s&&w?rb.default.createElement(va,{editDetails:t,cellCtrl:e,eParentCell:n,jsChildComp:w}):null};return null!=d?d.popup?rb.default.createElement(rb.default.Fragment,null,t(),n(d)):n(d):t()},Z=()=>rb.default.createElement("div",{ref:$,style:p,role:_,"col-id":r},B?rb.default.createElement("div",{className:"ag-cell-wrapper",role:"presentation",ref:G},Y()):Y());return e.isCellSpanning()?rb.default.createElement("div",{ref:U,className:"ag-spanned-cell-wrapper",role:"presentation"},Z()):Z()}),vc=(0,rb.memo)(({rowCtrl:e,containerType:t})=>{var n,i,r;let o,{context:a,gos:s,editSvc:l}=(0,rb.useContext)(m_),d="default"===(0,rb.useContext)(mk),u=(0,rb.useRef)(),c=(0,rb.useRef)(e.getDomOrder()),h=e.isFullWidth(),p=e.rowNode.dis
412played,[f,g]=(0,rb.useState)(()=>p?e.rowNode.getRowIndexString():null),[m,v]=(0,rb.useState)(()=>e.rowId),[y,b]=(0,rb.useState)(()=>e.businessKey),[x,w]=(0,rb.useState)(()=>e.rowStyles),C=(0,rb.useRef)(null),[S,_]=(0,rb.useState)(()=>null),[k,M]=(0,rb.useState)(),[T,D]=(0,rb.useState)(()=>p?e.getInitialRowTop(t):void 0),[R,I]=(0,rb.useState)(()=>p?e.getInitialTransform(t):void 0),A=(0,rb.useRef)(null),P=(0,rb.useRef)(),E=(0,rb.useRef)(),L=(0,rb.useRef)(!1),[F,O]=(0,rb.useState)(0);(0,rb.useEffect)(()=>{if(L.current||!k||F>10)return;let t=A.current?.firstChild;t?(e.setupDetailRowAutoHeight(t),L.current=!0):O(e=>e+1)},[k,F]);let N=(0,rb.useRef)();N.current||(N.current=new sC(()=>A.current));let B=(0,rb.useRef)(()=>{}),z=(n=(0,rb.useCallback)(e=>(B.current=e,()=>{B.current=()=>{}}),[]),i=()=>C.current,r=[],rb.default.useSyncExternalStore?rb.default.useSyncExternalStore(n,i):r),j=d?z:S,V=(0,rb.useCallback)(n=>{(A.current=n,u.current=n?a.createBean(new sb):a.destroyBean(u.current),n)?!e.isAlive()||a.isDestroyed()||e.setComp({setTop:D,setTransform:I,toggleCss:(e,t)=>N.current.toggleCss(e,t),setDomOrder:e=>c.current=e,setRowIndex:g,setRowId:v,setRowBusinessKey:b,setUserStyles:w,setCellCtrls:(e,t)=>{let n=C.current,i=mF(n,e,c.current);i!==n&&(C.current=i,d?B.current():mL(t,()=>_(i)))},showFullWidth:e=>{E.current=e.params,M(e)},getFullWidthCellRenderer:()=>P.current,getFullWidthCellRendererParams:()=>E.current,refreshFullWidth:e=>{let t=e();return(E.current=t,U.current)?(M(e=>({...e,params:t})),!0):!!P.current&&!!P.current.refresh&&P.current.refresh(t)}},n,t,u.current):e.unsetComp(t)},[]);(0,rb.useLayoutEffect)(()=>mM(k,a,A.current,P),[k]);let H=(0,rb.useMemo)(()=>{let e={top:T,transform:R};return Object.assign(e,x),e},[T,R,x]),G=h&&k?.componentFromFramework,W=!h&&null!=j,$=(0,rb.useMemo)(()=>!!(k?.componentFromFramework&&mI(k.componentClass)),[k]),U=(0,rb.useRef)(!1);return(0,rb.useEffect)(()=>{U.current=$&&!!k&&!!s.get("reactiveCustomComponents")},[$,k]),rb.default.createElement("div",{ref:V,role:"row",style:H,"row-index":f,"row-id":m,"row-business-key":y},W?j?.map(t=>rb.default.createElement(vu,{cellCtrl:t,editingCell:l?.isEditing(t,{withOpenEditor:!0})??!1,printLayout:e.printLayout,key:t.instanceId})):G?(o=k.componentClass,$?rb.default.createElement(o,{...k.params}):rb.default.createElement(o,{...k.params,ref:P})):null)}),vh=(0,rb.memo)(({name:e})=>{let{context:t,gos:n}=(0,rb.useContext)(m_),i=(0,rb.useMemo)(()=>uL[e],[e]),r=(0,rb.useRef)(null),o=(0,rb.useRef)(null),a=(0,rb.useRef)(null),s=(0,rb.useRef)([]),l=(0,rb.useRef)([]),[d,u]=(0,rb.useState)(()=>[]),c=!!n.get("enableCellSpan")&&!!i.getSpannedRowCtrls,h=(0,rb.useRef)([]),p=(0,rb.useRef)([]),[f,g]=(0,rb.useState)(()=>[]),m=(0,rb.useRef)(!1),v=(0,rb.useRef)(),y=(0,rb.useMemo)(()=>mD("ag-viewport",uF(e)),[e]),b=(0,rb.useMemo)(()=>mD(uO(e)),[e]),x=(0,rb.useMemo)(()=>{let t;return mD("ag-spanning-container",(t=uL[e],`ag-${t.name}-spanned-cells-container`))},[e]),w="center"===i.type||c;vr(" AG Row Container "+e+" ",w?r:o);let C=(0,rb.useCallback)(()=>{let e=!w||null!=r.current,t=null!=o.current,n=!c||null!=a.current;return e&&t&&n},[]),S=(0,rb.useCallback)(()=>null==r.current&&null==o.current&&null==a.current,[]),_=(0,rb.useCallback)(()=>{if(S()&&(v.current=t.destroyBean(v.current)),!t.isDestroyed()&&C()){let n=e=>{let t=mF(l.current,s.current,m.current);t!==l.current&&(l.current=t,mL(e,()=>u(t)))};v.current=t.createBean(new u$(e)),v.current.setComp({setHorizontalScroll:e=>{r.current&&(r.current.scrollLeft=e)},setViewportHeight:e=>{r.current&&(r.current.style.height=e)},setRowCtrls:({rowCtrls:e,useFlushSync:t})=>{let i=!!t&&s.current.length>0&&e.length>0;s.current=e,n(i)},setSpannedRowCtrls:(e,t)=>{let n,i=!!t&&h.current.length>0&&e.length>0;h.current=e,(n=mF(p.current,h.current,m.current))!==p.current&&(p.current=n,mL(i,()=>g(n)))},setDomOrder:e=>{m.current!=e&&(m.current=e,n(!1))},setContainerWidth:e=>{o.current&&(o.current.style.width=e)},setOffsetTop:e=>{o.current&&(o.current.style.transform=`translateY(${e})`)}},o.current,a.current??void 0,r.current)}},[C,S]),k=(0,rb.useCallback)(e=>{o.current=e,_()},[_]),M=(0,rb.useCallback)(e=>{a.current=e,_()},[_]),T=(0,rb.useCallback)(e=>{r.current=e,_()},[_]),D=()=>rb.default.createElement("div",{className:b,ref:k,role:w?"presentation":"rowgroup"},d.map(e=>rb.default.createElement(vc,{rowCtrl:e,containerType:i.type,key:e.instanceId})));return w?rb.default.createElement("div",{className:y,ref:T,role:"rowgroup"},D(),c?rb.default.createElement("div",{className:x,ref:M,role:"presentation"},f.map(e=>rb.default.createElement(vc,{rowCtrl:e,containerType:i.type,key:e.instanceId}))):null):D()}),vp=(0,rb.memo)(()=>{let e=(0,rb.useContext)(m_),{context:t,overlays:n}=e,[i,r]=(0,rb.useState)(""),[o,a]=(0,rb.useState)(0),[s,l]=(0,rb.useState)(0),[d,u]=(0,rb.useState)("0px"),[c,h]=(0,rb.useState)("0px"),[p,f]=(0,rb.useState)("100%"),[g,m]=(0,rb.useState)("0px"),[v,y]=(0,rb.useState)("0px"),[b,x]=(0,rb.useState)("100%"),[w,C]=(0,rb.useState)(!0),[S,_]=(0,rb.useState)(!0),[k,M]=(0,rb.useState)(null),[T,D]=(0,rb.useState)(""),[R,I]=(0,rb.useState)(null),[A,P]=(0,rb.useState)("ag-layout-normal"),E=(0,rb.useRef)();
412E.current||(E.current=new sC(()=>L.current));let L=(0,rb.useRef)(null),F=(0,rb.useRef)(null),O=(0,rb.useRef)(null),N=(0,rb.useRef)(null),B=(0,rb.useRef)(null),z=(0,rb.useRef)(null),j=(0,rb.useRef)(null),V=(0,rb.useRef)([]),H=(0,rb.useRef)([]);vr(" AG Grid Body ",L),vr(" AG Pinned Top ",F),vr(" AG Sticky Top ",O),vr(" AG Middle ",z),vr(" AG Pinned Bottom ",j);let G=(0,rb.useCallback)(i=>{if(L.current=i,!i||t.isDestroyed()){for(let e of(V.current=t.destroyBeans(V.current),H.current))e();H.current=[];return}let o=(e,t)=>{e.appendChild(t),H.current.push(()=>t.remove())},s=(e,n,i)=>{let r;o(e,document.createComment(i)),o(e,(r=t.createBean(new n),V.current.push(r),r).getGui())};s(i,uY," AG Fake Horizontal Scroll ");let d=n?.getOverlayWrapperCompClass();d&&s(i,d," AG Overlay Wrapper "),B.current&&s(B.current,uX," AG Fake Vertical Scroll ");let c=t.createBean(new uU);V.current.push(c),c.setComp({setRowAnimationCssOnBodyViewport:r,setColumnCount:e=>{L.current&&rN(L.current,"colcount",e)},setRowCount:e=>{L.current&&rN(L.current,"rowcount",e)},setTopHeight:a,setBottomHeight:l,setStickyTopHeight:u,setStickyTopTop:h,setStickyTopWidth:f,setTopInvisible:C,setBottomInvisible:_,setColumnMovingCss:(e,t)=>E.current.toggleCss(e,t),updateLayoutClasses:P,setAlwaysVerticalScrollClass:M,setPinnedTopBottomOverflowY:D,setCellSelectableCss:(e,t)=>I(t?e:null),setBodyViewportWidth:e=>{z.current&&(z.current.style.width=e)},registerBodyViewportResizeListener:t=>{if(z.current){let n=oh(e,z.current,t);H.current.push(()=>n())}},setStickyBottomHeight:m,setStickyBottomBottom:y,setStickyBottomWidth:x,setGridRootRole:e=>i.setAttribute("role",e)},i,z.current,F.current,j.current,O.current,N.current)},[]),W=(0,rb.useMemo)(()=>mD("ag-root","ag-unselectable",A),[A]),$=(0,rb.useMemo)(()=>mD("ag-body-viewport",i,A,k,R),[i,A,k,R]),U=(0,rb.useMemo)(()=>mD("ag-body",A),[A]),q=(0,rb.useMemo)(()=>mD("ag-floating-top",w?"ag-invisible":null,R),[R,w]),K=(0,rb.useMemo)(()=>mD("ag-sticky-top",R),[R]),Y=(0,rb.useMemo)(()=>mD("ag-sticky-bottom","0px"===g?"ag-invisible":null,R),[R,g]),Z=(0,rb.useMemo)(()=>mD("ag-floating-bottom",S?"ag-invisible":null,R),[R,S]),X=(0,rb.useMemo)(()=>({height:o,minHeight:o,overflowY:T}),[o,T]),J=(0,rb.useMemo)(()=>({height:d,top:c,width:p}),[d,c,p]),Q=(0,rb.useMemo)(()=>({height:g,bottom:v,width:b}),[g,v,b]),ee=(0,rb.useMemo)(()=>({height:s,minHeight:s,overflowY:T}),[s,T]),et=e=>rb.default.createElement(vh,{name:e,key:`${e}-container`}),en=({section:e,children:t,className:n,style:i})=>rb.default.createElement("div",{ref:e,className:n,role:"presentation",style:i},t.map(et));return rb.default.createElement("div",{ref:G,className:W},rb.default.createElement(vi,null),en({section:F,className:q,style:X,children:["topLeft","topCenter","topRight","topFullWidth"]}),rb.default.createElement("div",{className:U,ref:B,role:"presentation"},en({section:z,className:$,children:["left","center","right","fullWidth"]})),en({section:O,className:K,style:J,children:["stickyTopLeft","stickyTopCenter","stickyTopRight","stickyTopFullWidth"]}),en({section:N,className:Y,style:Q,children:["stickyBottomLeft","stickyBottomCenter","stickyBottomRight","stickyBottomFullWidth"]}),en({section:j,className:Z,style:ee,children:["bottomLeft","bottomCenter","bottomRight","bottomFullWidth"]}))}),vf=(0,rb.forwardRef)((e,t)=>{let{children:n,eFocusableElement:i,onTabKeyDown:r,gridCtrl:o,forceFocusOutWhenTabGuardsAreEmpty:a,isEmpty:s}=e,{context:l}=(0,rb.useContext)(m_),d=(0,rb.useRef)(null),u=(0,rb.useRef)(null),c=(0,rb.useRef)(),h=e=>{let t=null==e?void 0:parseInt(e,10).toString();for(let e of[d,u])void 0===t?e.current?.removeAttribute("tabindex"):e.current?.setAttribute("tabindex",t)};(0,rb.useImperativeHandle)(t,()=>({forceFocusOutOfContainer(e){c.current?.forceFocusOutOfContainer(e)}}));let p=(0,rb.useCallback)(()=>{let e=d.current,t=u.current;if(!e&&!t||l.isDestroyed()){c.current=l.destroyBean(c.current);return}e&&t&&(c.current=l.createBean(new cL({comp:{setTabIndex:h},eTopGuard:e,eBottomGuard:t,eFocusableElement:i,onTabKeyDown:r,forceFocusOutWhenTabGuardsAreEmpty:a,focusInnerElement:e=>o.focusInnerElement(e),isEmpty:s}
412)))},[]),f=(0,rb.useCallback)(e=>{d.current=e,p()},[p]),g=(0,rb.useCallback)(e=>{u.current=e,p()},[p]),m=e=>rb.default.createElement("div",{className:`${cA} ${"top"===e?cP:cE}`,role:"presentation",ref:"top"===e?f:g});return rb.default.createElement(rb.default.Fragment,null,m("top"),n,m("bottom"))}),vg=(0,rb.memo)(vf),vm=(0,rb.memo)(({context:e})=>{let[t,n]=(0,rb.useState)(""),[i,r]=(0,rb.useState)(""),[o,a]=(0,rb.useState)(null),[s,l]=(0,rb.useState)(null),[d,u]=(0,rb.useState)(!1),[c,h]=(0,rb.useState)(),p=(0,rb.useRef)(),f=(0,rb.useRef)(null),g=(0,rb.useRef)(),[m,v]=(0,rb.useState)(null),y=(0,rb.useRef)(()=>void 0),b=(0,rb.useRef)(),x=(0,rb.useRef)([]),w=(0,rb.useCallback)(()=>void 0,[]);vr(" AG Grid ",f);let C=(0,rb.useCallback)(t=>{if(f.current=t,p.current=t?e.createBean(new cW):e.destroyBean(p.current),!t||e.isDestroyed())return;let i=p.current;y.current=i.focusInnerElement.bind(i),i.setComp({destroyGridUi:()=>{},setRtlClass:n,forceFocusOutOfContainer:e=>{!e&&b.current?.isDisplayed()?b.current.forceFocusOutOfContainer(e):g.current?.forceFocusOutOfContainer(e)},updateLayoutClasses:r,getFocusableContainers:()=>{let e=[],t=f.current?.querySelector(".ag-root");for(let n of(t&&e.push({getGui:()=>t}),x.current))n.isDisplayed()&&e.push(n);return e},setCursor:a,setUserSelect:l},t,t),u(!0)},[]);(0,rb.useEffect)(()=>{let t=p.current,n=f.current;if(!c||!t||!m||!n||e.isDestroyed())return;let i=[],{watermarkSelector:r,paginationSelector:o,sideBarSelector:a,statusBarSelector:s,gridHeaderDropZonesSelector:l}=t.getOptionalSelectors(),d=[];if(l){let t=e.createBean(new l.component),r=t.getGui();n.insertAdjacentElement("afterbegin",r),d.push(r),i.push(t)}if(a){let t=e.createBean(new a.component),n=t.getGui(),r=m.querySelector(".ag-tab-guard-bottom");r&&(r.insertAdjacentElement("beforebegin",n),d.push(n)),i.push(t),x.current.push(t)}let u=t=>{let r=e.createBean(new t),o=r.getGui();return n.insertAdjacentElement("beforeend",o),d.push(o),i.push(r),r};if(s&&u(s.component),o){let e=u(o.component);b.current=e,x.current.push(e)}return r&&u(r.component),()=>{for(let t of(e.destroyBeans(i),d))t.remove()}},[c,m,e]);let S=(0,rb.useMemo)(()=>mD("ag-root-wrapper",t,i),[t,i]),_=(0,rb.useMemo)(()=>mD("ag-root-wrapper-body","ag-focus-managed",i),[i]),k=(0,rb.useMemo)(()=>({userSelect:null!=s?s:"",WebkitUserSelect:null!=s?s:"",cursor:null!=o?o:""}),[s,o]),M=(0,rb.useCallback)(e=>{g.current=e,h(null!==e)},[]),T=(0,rb.useCallback)(()=>!p.current?.isFocusable(),[]);return rb.default.createElement("div",{ref:C,className:S,style:k,role:"presentation"},rb.default.createElement("div",{className:_,ref:v,role:"presentation"},d&&m&&!e.isDestroyed()&&rb.default.createElement(m_.Provider,{value:e.getBeans()},rb.default.createElement(vg,{ref:M,eFocusableElement:m,onTabKeyDown:w,gridCtrl:p.current,forceFocusOutWhenTabGuardsAreEmpty:!0,isEmpty:T},rb.default.createElement(vp,null)))))}),vv=class extends oI{postConstruct(){if(this.beans.colAutosize){let e=this.queueResizeOperationsForTick.bind(this);this.addManagedEventListeners({rowExpansionStateChanged:e,expandOrCollapseAll:e,cellValueChanged:e,rowNodeDataChanged:e,rowDataUpdated:e})}}queueResizeOperationsForTick(){let e=this.beans.colAutosize;e.shouldQueueResizeOperations=!0,setTimeout(()=>{e.processResizeOperations()},0)}areHeaderCellsRendered(){return this.beans.ctrlsSvc.getHeaderRowContainerCtrls().every(e=>e.getAllCtrls().every(e=>e.areCellsRendered()))}areCellsRendered(){return this.beans.rowRenderer.getAllRowCtrls().every(e=>e.isRowRendered()&&e.getAllCellCtrls().every(e=>!!e.eGui))}},vy={setGridApi:void 0,maxComponentCreationTimeMs:void 0,children:void 0},vb=new Set(Object.keys({gridOptions:void 0,modules:void 0,containerStyle:void 0,className:void 0,passGridApi:void 0,componentWrappingElement:void 0,...vy})),vx=new Set(Object.keys(vy)),vw=e=>{let t=(0,rb.useRef)(),n=(0,rb.useRef)(null),i=(0,rb.useRef)(null),r=(0,rb.useRef)([]),o=(0,rb.useRef)([]),a=(0,rb.useRef)(e),s=(0,rb.useRef)(),l=(0,rb.useRef)(),d=(0,rb.useRef)(!1),[u,c]=(0,rb.useState)(void 0),[,h]=(0,rb.useState)(0),p=(0,rb.useCallback)(a=>
412{if(n.current=a,!a){for(let e of r.current)e();r.current.length=0;return}let u=e.modules||[];i.current||(i.current=new m6(()=>h(e=>e+1),e.componentWrappingElement,e.maxComponentCreationTimeMs),r.current.push(()=>{i.current?.destroy(),i.current=null}));let p=function(e,t,n){"object"!=typeof e&&(e={});let i={...e};for(let e of n){let n=t[e];void 0!==n&&(i[e]=n)}return i}(e.gridOptions,e,Object.keys(e).filter(e=>!vb.has(e))),f=new v_(()=>{if(d.current){let e=()=>s.current?.shouldQueueUpdates()?void 0:o.current.shift(),t=e();for(;t;)t(),t=e()}});s.current=f;let g=new vv,m={providedBeanInstances:{frameworkCompWrapper:new vC(i.current,p),renderStatus:g},modules:u,frameworkOverrides:f,setThemeOnGridDiv:!0},v=new fK;p.gridId??(p.gridId=l.current),t.current=v.create(a,p,n=>{c(n),n.createBean(g),r.current.push(()=>{n.destroy()}),n.getBean("ctrlsSvc").whenReady({addDestroyFunc:e=>{r.current.push(e)}},()=>{if(n.isDestroyed())return;let i=t.current;i&&e.passGridApi?.(i)})},e=>{e.getBean("ctrlsSvc").whenReady({addDestroyFunc:e=>{r.current.push(e)}},()=>{for(let e of o.current)e();o.current.length=0,d.current=!0})},m),r.current.push(()=>{t.current=void 0}),t.current&&(l.current=t.current.getGridId())},[]),f=(0,rb.useMemo)(()=>({height:"100%",...e.containerStyle||{}}),[e.containerStyle]),g=(0,rb.useCallback)(e=>{d.current&&!s.current?.shouldQueueUpdates()?e():o.current.push(e)},[]);(0,rb.useEffect)(()=>{let n=function(e,t){let n={};for(let i of Object.keys(t)){if(vb.has(i)){vx.has(i)&&at(274,{prop:i});continue}let r=t[i];e[i]!==r&&(n[i]=r)}return n}(a.current,e);a.current=e,g(()=>{t.current&&function(e,t){if(!e)return;let n={},i=!1;for(let t of Object.keys(e))n[t]=e[t],i=!0;if(!i)return;t.dispatchEvent({type:"gridOptionsChanged",options:n});let r={type:"componentStateChanged",...n};t.dispatchEvent(r)}(n,t.current)})},[e]);let m=rb.default.useSyncExternalStore&&"legacy"!==aB(e,"renderingMode")?"default":"legacy";return rb.default.createElement("div",{style:f,className:e.className,ref:p},rb.default.createElement(mk.Provider,{value:m},u&&!u.isDestroyed()?rb.default.createElement(vm,{key:u.instanceId,context:u}):null,i.current?.getPortals()??null))},vC=class extends fZ{constructor(e,t){super(),this.parent=e,this.gridOptions=t}createWrapper(e,t){let n=this.gridOptions;if(aB(n,"reactiveCustomComponents")){let i=(e=>{switch(e){case"filter":return aB(n,"enableFilterHandlers")?mK:mq;case"floatingFilterComponent":return aB(n,"enableFilterHandlers")?mJ:mX;case"dateComponent":return m$;case"dragAndDropImageComponent":return mU;case"loadingOverlayComponent":return m0;case"noRowsOverlayComponent":return m2;case"statusPanel":return m3;case"toolPanel":return m5;case"menuItem":return m1;case"cellRenderer":return mW;case"innerHeaderComponent":return mQ}})(t.name);if(i)return new i(e,this.parent,t)}else switch(t.name){case"filter":case"floatingFilterComponent":case"dateComponent":case"dragAndDropImageComponent":case"loadingOverlayComponent":case"noRowsOverlayComponent":case"statusPanel":case"toolPanel":case"menuItem":case"cellRenderer":m4()}let i=!t.cellRenderer&&"toolPanel"!==t.name;return new mV(e,this.parent,t,i)}},vS=(0,rb.forwardRef)((e,t)=>{let n=(0,rb.useContext)(m_),{registry:i,context:r,gos:o,rowModel:a}=n,[s,l]=(0,rb.useState)(()=>new mR),[d,u]=(0,rb.useState)(()=>new mR),[c,h]=(0,rb.useState)(),[p,f]=(0,rb.useState)(),g=(0,rb.useRef)(),m=(0,rb.useRef)(null),v=(0,rb.useRef)(),y=(0,rb.useMemo)(()=>{var t,n;let i;return t=e.api.getGridId(),n=c?.rowModelType??"clientSide",[...Object.values((i=oZ[t]??{}).all??{}),...Object.values(i[n]??{})]},[e]),b=(0,rb.useMemo)(()=>s.toString()+" ag-details-row",[s]),x=(0,rb.useMemo)(()=>d.toString()+" ag-details-grid",[d]);t&&(0,rb.useImperativeHandle)(t,()=>({refresh:()=>g.current?.refresh()??!1})),e.template&&at(230);let w=(0,rb.useCallback)(t=>{if(m.current=t,!t||r.isDestroyed()){g.current=r.destroyBean(g.current),v.current?.();return}let s=i.createDynamicBean("detailCellRendererCtrl",!0);if(s&&(r.createBean(s),s.init({toggleCss:(e,t)=>l(n=>n.setClass(e,t)),toggleDetailGridCss:(e,t)=>u(n=>n.setClass(e,t)),setDetailGrid:e=>h(e),setRowData:e=>f(e),getGui:()=>m.current},e),g.current=s,o.get("detailRowAutoHeight"))){let i=()=>
412{if(null==m.current)return;let t=m.current.clientHeight;null!=t&&t>0&&setTimeout(()=>{e.node.setRowHeight(t),(aa(o,a)||as(o,a))&&a.onRowHeightChanged()},0)};v.current=oh(n,t,i),i()}},[]),C=(0,rb.useCallback)(e=>{g.current?.registerDetailWithMaster(e)},[]);return rb.default.createElement("div",{className:b,ref:w},c&&rb.default.createElement(vw,{className:x,...c,modules:y,rowData:p,passGridApi:C}))}),v_=class extends cz{constructor(e){super("react"),this.processQueuedUpdates=e,this.queueUpdates=!1,this.renderingEngine="react",this.frameworkComponents={agGroupCellRenderer:mO,agGroupRowRenderer:mO,agDetailCellRenderer:vS},this.wrapIncoming=(e,t)=>{if("ensureVisible"===t)return mE||setTimeout(()=>mE=!1,0),mE=!0,e();return e()}}frameworkComponent(e){return this.frameworkComponents[e]}isFrameworkComponent(e){if(!e)return!1;let t=e.prototype;return!(t&&"getGui"in t)}getLockOnRefresh(){this.queueUpdates=!0}releaseLockOnRefresh(){this.queueUpdates=!1,this.processQueuedUpdates()}shouldQueueUpdates(){return this.queueUpdates}runWhenReadyAsync(){return"19"===mA}},vk=class extends rb.Component{constructor(){super(...arguments),this.apiListeners=[],this.setGridApi=e=>{for(let t of(this.api=e,this.apiListeners))t(e)}}registerApiListener(e){this.apiListeners.push(e)}componentWillUnmount(){this.apiListeners.length=0}render(){return rb.default.createElement(vw,{...this.props,passGridApi:this.setGridApi})}},vM=e.i(30156),vT=e.i(48159);let vD=[],vR=I.default.memo(function({tableArea:e,delimiter:t=";",firstRowIsHeader:n=!0,headerColor:i,headerTextColor:r,rowColor:o=null,opacity:a=10,withBorder:s,rowBorders:l,bandedRows:d,rowHeight:u=55,fitContent:c,pageSize:h,stickyHeader:p,defaultColumnWidth:f,maxColumnWidth:g,showFilters:m,sortable:v,resizable:y,columns:b=vD}){let[x,w]=(0,I.useState)([]),C=(0,I.useRef)(null),S=(0,I.useRef)(null),[_,k]=(0,I.useState)(void 0),[M,T]=(0,I.useState)(0),[D,A]=(0,I.useState)(!1),P=(0,I.useRef)(null),E=(0,I.useRef)(null);I.default.useEffect(()=>{let e=S.current;if(!e)return;let t=()=>{let t=e.offsetWidth;if(A(null!==e.closest('[data-block="collapsible"]')),t===E.current)return;E.current=t,T(t);let n=P.current;if(n)if(c){n.autoSizeAllColumns();let e=n.getAllDisplayedColumns()?.reduce((e,t)=>e+t.getActualWidth(),0)||0;k(e<t?e:t)}else n.sizeColumnsToFit()};t();let n=new ResizeObserver(t);return n.observe(e),()=>n.disconnect()},[c]);let L=(0,I.useMemo)(()=>ry({csvData:e,delimiter:t??void 0}),[e,t]),F=(0,I.useMemo)(()=>o&&"transparent"!==o?`color-mix(in srgb, var(--c-${o}) ${a}%, transparent)`:"transparent",[o,a]),{data:O,headers:N,rowData:B}=(0,I.useMemo)(()=>{if("string"==typeof L||!L.data.length)return{data:[],headers:[],rowData:[]};let{data:e}=L,t=n?e[0]:e[0].map((e,t)=>`Column ${t+1}`),i=+!!n,r=e.slice(i).map(e=>{let n={};return t.forEach((t,i)=>{n[t]=e[i]}),n});return{data:e,headers:t,rowData:r}},[L,n]),z=(0,I.useCallback)(e=>{if("string"==typeof L||!L.data.length)return!1;let t=+!!n;return L.data.slice(t).some(t=>t[e]&&""!==t[e].toString().trim())},[L,n]),j=(0,I.useMemo)(()=>N.map((e,t)=>{let n=b?.[t]||{},i=!z(t);return n.hideIfEmpty&&i?null:{field:e,headerName:e,width:n.columnWidth??f,maxWidth:n.columnWidth??void 0,suppressSizeToFit:n.suppressSizeToFit,filter:!0===n.showColumnFilters||m,sortable:!0===n.columnSortable||v,resizable:!0===n.columnResizable||y,pinned:n.pinned?"left":void 0,cellRenderer:e=>(0,R.jsx)("div",{dangerouslySetInnerHTML:{__html:e.value}})}}).filter(Boolean),[N,b,f,m,v,y,z]),V=(0,I.useMemo)(()=>({flex:+!c,minWidth:100,maxWidth:g??void 0,wrapText:!0,wrapHeaderText:!0,autoHeaderHeight:!0,autoHeight:!0}),[c,g]),H=(0,I.useCallback)(e=>{let t={};return d?t.backgroundColor=null!==e.node.rowIndex&&e.node.rowIndex%2==0?"var(--c-white)":F:t.backgroundColor=F,l||(t.borderBottom="none"),Object.keys(t).length>0?t:void 0},[d,F,l]),G=()=>{if(C.current){let e=P.current?.getAllDisplayedColumns()?.reduce((e,t)=>e+t.getActualWidth(),0)||0;k(e<M?e:M)}},W=e=>{P.current?.setColumnsVisible([e],!0)};return"string"==typeof L?(0,R.jsx)("div",{children:L}):0===O.length?(0,R.jsx)("div",{children:"No table data available"}
412):(0,R.jsxs)("div",{className:vM.default.tableContainer,ref:S,children:[x.length>0&&(0,R.jsx)("div",{style:{marginBottom:"10px",display:"flex",gap:"5px",flexWrap:"wrap"},children:x.filter(e=>""!==e).map(e=>(0,R.jsx)(vT.Pill,{variant:"contrast",withRemoveButton:!0,removeButtonProps:{icon:"+","aria-label":`Restore ${e}`,onClick:()=>W(e)},onClick:()=>W(e),children:e},e))}),(0,R.jsx)("div",{ref:C,className:vM.default.table,style:{width:c&&_?`${_}px`:void 0,"--ag-header-background-color":`var(--c-${i||o||"lightGray"})`,"--ag-header-text-color":n?`var(--c-${r||"black"})`:`var(--c-${i||o||"lightGray"})`,"--ag-wrapper-border":s?void 0:"none","--ag-header-row-border":l?void 0:"none","--header-sticky":p?"sticky":"static","--header-top":D?"0px":void 0},children:(0,R.jsx)(vk,{domLayout:"autoHeight",modules:[ma,hE,md,mv,gt,gN,mw,my,g1,mC,mS],pagination:!!h,paginationPageSize:h??void 0,paginationPageSizeSelector:!1,rowData:B,columnDefs:j,defaultColDef:V,rowHeight:u??void 0,headerHeight:50*!!n,animateRows:!0,enableCellTextSelection:!0,getRowStyle:H,onGridReady:e=>{P.current=e.api,c?e.api.autoSizeAllColumns():e.api.sizeColumnsToFit()},onFirstDataRendered:e=>{var t;let n;t=e.api,(n=j.filter(e=>{let t=N.indexOf(e.field);return b?.[t]?.initiallyHidden}).map(e=>e.field)).length>0&&t.setColumnsVisible(n,!1),w(n),c?(e.api.autoSizeAllColumns(),G()):e.api.sizeColumnsToFit()},onModelUpdated:e=>{B.length>0&&!e.api.isAnyFilterPresent()&&0===e.api.getDisplayedRowCount()&&e.api.hideOverlay()},onColumnVisible:e=>{let{visible:t,columns:n}=e;if(n&&!1===t){let e=n.map(e=>e.getColId());w(t=>[...new Set([...t,...e])])}else if(n&&!0===t){let e=n.map(e=>e.getColId());w(t=>t.filter(t=>!e.includes(t)))}G()},onColumnResized:e=>{c&&e.finished&&G()}})})]})});var vI=e.i(45530),vA=e.i(5298);e.s(["default",0,e=>{let{introText:t,width:n=100}=e,i=(0,vA.hasRichTextContent)(t);return(0,R.jsx)(vI.MantineProvider,{children:(0,R.jsxs)("div",{className:vM.default.container,style:{width:`${n}%`},children:[i&&(0,R.jsx)("div",{className:vM.default.introContent,children:(0,R.jsx)(ne.default,{content:t})}),(0,R.jsx)(vR,{...e})]})})}],23039);var vP=e.i(21636),vE=e.i(47973);let vL=({className:e})=>(0,R.jsx)("svg",{className:e,width:"1em",height:"1em",viewBox:"0 0 30 30",xmlns:"http://www.w3.org/2000/svg",children:(0,R.jsx)("path",{fill:"currentColor",d:"M6 4l22 11L6 26z"})});e.s(["VideoBlock",0,e=>{let{width:t,autoplay:n,loop:i,mute:r,controls:o,videoUrl:a,videoBlockPosition:s,videoBlockAlignment:l,placeholderImage:d,caption:u}=e,{tenant:c}=(0,e_.useTenant)(),[h,p]=(0,I.useState)(!1),f=(0,vA.hasRichTextContent)(u),[g,m]=(0,I.useState)(f),v=(0,I.useRef)(null),[y,b]=(0,I.useState)(0),[x,w]=(0,I.useState)(!1);(0,I.useEffect)(()=>{if(!v.current)return;let e=new ResizeObserver(()=>{if(!v.current)return;let e=v.current.firstElementChild;if(e){let t=e.scrollHeight+32,n=v.current.clientHeight;b(t),w(t>n)}});return e.observe(v.current),()=>e.disconnect()},[u,h]);let C=a?(0,vE.getEmbedUrl)({url:a,autoplay:!!h||n,loop:i,mute:n||r,controls:o}):"",S=[vP.default.videoBlock,"default"===s&&vP.default.default,"default"===s&&"left"===l&&vP.default.left,"default"===s&&"right"===l&&vP.default.right].filter(Boolean).join(" ");return(0,R.jsxs)(eE.Paper,{className:S,style:{width:`${t}%`},radius:(0,t2.getRadius)(c.Theme?.borderRadius),bg:"transparent",children:[!h&&(0,R.jsxs)("div",{className:vP.default.placeholderWrapper,children:[d?(0,R.jsx)(n_.Media,{resource:d,htmlElement:"div"}):(0,R.jsx)("iframe",{className:vP.default.iframe,src:C,title:"Embedded Video",style:{border:"none"},allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0}),(d||g)&&(0,R.jsxs)(R.Fragment,{children:[!n&&(0,R.jsx)("button",{className:vP.default.playButton,onClick:()=>p(!0),"aria-label":"Play video",children:(0,R.jsx)(vL,{})}),g&&(0,R.jsxs)("div",{className:`${vP.default.richTextWrapper} ${x?vP.default.overflowing:""}`,ref:v,style:{"--content-height":`${y}px`},children:[(0,R.jsx)(ne.default,{content:u,className:vP.default.caption,bgColor:"white",withRadius:!1,excludeFromToc:!0}
412),n&&(0,R.jsx)("button",{className:vP.default.closeButton,onClick:()=>m(!1),"aria-label":"Close caption",children:(0,R.jsx)(tZ.default,{})})]})]})]}),h&&(0,R.jsx)("iframe",{className:vP.default.iframe,src:C,title:"Embedded Video",style:{border:"none"},allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0})]})}],25499)},6865,e=>{e.v({block:"index-module-scss-module__Odgd3q__block","block--black":"index-module-scss-module__Odgd3q__block--black","block--primary":"index-module-scss-module__Odgd3q__block--primary","block--quaternary":"index-module-scss-module__Odgd3q__block--quaternary","block--quinary":"index-module-scss-module__Odgd3q__block--quinary","block--secondary":"index-module-scss-module__Odgd3q__block--secondary","block--senary":"index-module-scss-module__Odgd3q__block--senary","block--stretch":"index-module-scss-module__Odgd3q__block--stretch","block--tertiary":"index-module-scss-module__Odgd3q__block--tertiary","block--white":"index-module-scss-module__Odgd3q__block--white",column:"index-module-scss-module__Odgd3q__column","column--black":"index-module-scss-module__Odgd3q__column--black","column--full":"index-module-scss-module__Odgd3q__column--full","column--half":"index-module-scss-module__Odgd3q__column--half","column--oneThird":"index-module-scss-module__Odgd3q__column--oneThird","column--primary":"index-module-scss-module__Odgd3q__column--primary","column--quaternary":"index-module-scss-module__Odgd3q__column--quaternary","column--quinary":"index-module-scss-module__Odgd3q__column--quinary","column--secondary":"index-module-scss-module__Odgd3q__column--secondary","column--senary":"index-module-scss-module__Odgd3q__column--senary","column--tertiary":"index-module-scss-module__Odgd3q__column--tertiary","column--twoThirds":"index-module-scss-module__Odgd3q__column--twoThirds","column--white":"index-module-scss-module__Odgd3q__column--white",container:"index-module-scss-module__Odgd3q__container","container--lg":"index-module-scss-module__Odgd3q__container--lg","container--md":"index-module-scss-module__Odgd3q__container--md","container--none":"index-module-scss-module__Odgd3q__container--none","container--sm":"index-module-scss-module__Odgd3q__container--sm","container--xl":"index-module-scss-module__Odgd3q__container--xl"})},79651,e=>{e.v({bottom:"index-module-scss-module__YRPNjq__bottom",root:"index-module-scss-module__YRPNjq__root",top:"index-module-scss-module__YRPNjq__top"})},71906,e=>{"use strict";var t=e.i(48277),n=e.i(79651),i=e.i(3218),r=e.i(90388);e.s(["VerticalPadding",0,({top:e=!0,bottom:o=!0,className:a,backgroundColor:s,children:l,radius:d,...u})=>{let{tenant:c}=(0,r.useTenant)();return(0,t.jsx)(i.Paper,{radius:d||c?.Theme?.borderRadius||"md",className:[n.default.root,e&&n.default.top,o&&n.default.bottom,a].filter(Boolean).join(" "),style:s?{backgroundColor:`var(--c-${s})`}:{backgroundColor:"transparent"},...u,children:l})}])},31514,e=>{e.v({badge:"index-module-scss-module__R01Okq__badge",badgeInsurer:"index-module-scss-module__R01Okq__badgeInsurer",badgeNegative:"index-module-scss-module__R01Okq__badgeNegative",badgePositive:"index-module-scss-module__R01Okq__badgePositive",badgeWachttijd:"index-module-scss-module__R01Okq__badgeWachttijd",card:"index-module-scss-module__R01Okq__card",cardBadgeRow:"index-module-scss-module__R01Okq__cardBadgeRow",cardFooter:"index-module-scss-module__R01Okq__cardFooter",cardHeader:"index-module-scss-module__R01Okq__cardHeader",cardHeaderBadges:"index-module-scss-module__R01Okq__cardHeaderBadges",cardName:"index-module-scss-module__R01Okq__cardName",cardNameRow:"index-module-scss-module__R01Okq__cardNameRow",cardRow:"index-module-scss-module__R01Okq__cardRow",cardSummary:"index-module-scss-module__R01Okq__cardSummary",clearFiltersButton:"index-module-scss-module__R01Okq__clearFiltersButton",directoryBlock:"index-module-scss-module__R01Okq__directoryBlock",empty:"index-module-scss-module__R01Okq__empty",favicon:"index-module-scss-module__R01Okq__favicon",filterAccordion:"index-module-scss-module__R01Okq__filterAccordion",filterSection:"index-module-scss-module__R01Okq__filterSection",filterSectionContent:"index-module-scss-module__R01Okq__filterSectionContent",filterSectionControl:"index-module-scss-module__R01Okq__filterSectionControl","filterSectionControl--black":"index-module-scss-module__R01Okq__filterSectionControl--black","filterSectionControl--primary":"index-module-scss-module__R01Okq__filterSectionControl--primary","filterSectionControl--quaternary":"index-module-scss-module__R01Okq__filterSectionControl--quaternary","filterSectionControl--quinary":"index-module-scss-module__R01Okq__filterSectionControl--quinary","filterSectionControl--secondary":"index-module-scss-module__R01Okq__filterSectionControl--secondary","filterSectionControl--senary":"index-module-scss-module__R01Okq__filterSectionControl--senary","filterSectionControl--tertiary":"index-module-scss-module__R01Okq__filterSectionControl--tertiary","filterSectionControl--white":"index-module-scss-module__R01Okq__filterSectionControl--white",f
412ilterSectionLabel:"index-module-scss-module__R01Okq__filterSectionLabel",filterSectionPanel:"index-module-scss-module__R01Okq__filterSectionPanel",filters:"index-module-scss-module__R01Okq__filters","filters--black":"index-module-scss-module__R01Okq__filters--black","filters--primary":"index-module-scss-module__R01Okq__filters--primary","filters--quaternary":"index-module-scss-module__R01Okq__filters--quaternary","filters--quinary":"index-module-scss-module__R01Okq__filters--quinary","filters--secondary":"index-module-scss-module__R01Okq__filters--secondary","filters--senary":"index-module-scss-module__R01Okq__filters--senary","filters--tertiary":"index-module-scss-module__R01Okq__filters--tertiary","filters--white":"index-module-scss-module__R01Okq__filters--white",filtersBackdrop:"index-module-scss-module__R01Okq__filtersBackdrop",filtersCloseButton:"index-module-scss-module__R01Okq__filtersCloseButton",filtersCollapsed:"index-module-scss-module__R01Okq__filtersCollapsed",filtersFooter:"index-module-scss-module__R01Okq__filtersFooter",filtersHeader:"index-module-scss-module__R01Okq__filtersHeader",filtersScroll:"index-module-scss-module__R01Okq__filtersScroll",filtersTitle:"index-module-scss-module__R01Okq__filtersTitle",filtersToggleChevron:"index-module-scss-module__R01Okq__filtersToggleChevron",filtersToggleDot:"index-module-scss-module__R01Okq__filtersToggleDot",grid:"index-module-scss-module__R01Okq__grid",heading:"index-module-scss-module__R01Okq__heading",insurerOptionAliases:"index-module-scss-module__R01Okq__insurerOptionAliases",layout:"index-module-scss-module__R01Okq__layout",modalRow:"index-module-scss-module__R01Okq__modalRow",modalRowLabel:"index-module-scss-module__R01Okq__modalRowLabel",modalRowValue:"index-module-scss-module__R01Okq__modalRowValue",modalScroll:"index-module-scss-module__R01Okq__modalScroll",modalTitle:"index-module-scss-module__R01Okq__modalTitle",modalTitleRow:"index-module-scss-module__R01Okq__modalTitleRow",pagination:"index-module-scss-module__R01Okq__pagination",results:"index-module-scss-module__R01Okq__results",resultsHeader:"index-module-scss-module__R01Okq__resultsHeader",resultsHeaderRight:"index-module-scss-module__R01Okq__resultsHeaderRight",sidebarColumn:"index-module-scss-module__R01Okq__sidebarColumn",sortSelect:"index-module-scss-module__R01Okq__sortSelect",stack:"index-module-scss-module__R01Okq__stack",statItem:"index-module-scss-module__R01Okq__statItem",statLabel:"index-module-scss-module__R01Okq__statLabel",statValue:"index-module-scss-module__R01Okq__statValue",statsBar:"index-module-scss-module__R01Okq__statsBar","statsBar--black":"index-module-scss-module__R01Okq__statsBar--black","statsBar--primary":"index-module-scss-module__R01Okq__statsBar--primary","statsBar--quaternary":"index-module-scss-module__R01Okq__statsBar--quaternary","statsBar--quinary":"index-module-scss-module__R01Okq__statsBar--quinary","statsBar--secondary":"index-module-scss-module__R01Okq__statsBar--secondary","statsBar--senary":"index-module-scss-module__R01Okq__statsBar--senary","statsBar--tertiary":"index-module-scss-module__R01Okq__statsBar--tertiary","statsBar--white":"index-module-scss-module__R01Okq__statsBar--white",statsBarFiltersHint:"index-module-scss-module__R01Okq__statsBarFiltersHint",statsBarTrigger:"index-module-scss-module__R01Okq__statsBarTrigger",tab:"index-module-scss-module__R01Okq__tab",tabActive:"index-module-scss-module__R01Okq__tabActive",tabs:"index-module-scss-module__R01Okq__tabs",termSearchField:"index-module-scss-module__R01Okq__termSearchField",veraCheck:"index-module-scss-module__R01Okq__veraCheck",veraCheckDate:"index-module-scss-module__R01Okq__veraCheckDate",veraCheckSummary:"index-module-scss-module__R01Okq__veraCheckSummary",veraChecks:"index-module-scss-module__R01Okq__veraChecks",veraChecksHeading:"index-module-scss-module__R01Okq__veraChecksHeading",viewToggle:"index-module-scss-module__R01Okq__viewToggle",viewToggleButton:"index-module-scss-module__R01Okq__viewToggleButton",viewToggleButtonActive:"index-module-scss-module__R01Okq__viewToggleButtonActive"})},30755,e=>{e.v({embedContainer:"index-module-scss-module__HGBdfG__embedContainer"})},78113,(e,t,n)=>{var i={675:function(e,t){"use strict";t.byteLength=function(e){var t=l(e),n=t[0],i=t[1];return(n+i)*3/4-i},t.toByteArray=function(e){var t,n,o=l(e),a=o[0],s=o[1],d=new r((a+s)*3/4-s),u=0,c=s>0?a-4:a;for(n=0;n<c;n+=4)t=i[e.charCodeAt(n)]<<18|i[e.charCodeAt(n+1)]<<12|i[e.charCodeAt(n+2)]<<6|i[e.charCodeAt(n+3)],d[u++]=t>>16&255,d[u++]=t>>8&255,d[u++]=255&t;return 2===s&&(t=i[e.charCodeAt(n)]<<2|i[e.charCodeAt(n+1)]>>4,d[u++]=255&t),1===s&&(t=i[e.charCodeAt(n)]<<10|i[e.charCodeAt(n+1)]<<4|i[e.charCodeAt(n+2)]>>2,d[u++]=t>>8&255,d[u++]=255&t),d},t.fromByteArray=function(e){for(var t,i=e.length,r=i%3,o=[],a=0,s=i-r;a<s;a+=16383)o.push(function(e,t,i){for(var r,o=[],a=t;a<i;a+=3)r=(e[a]<<16&0xff0000)+(e[a+1]<<8&65280)+(255&e[a+2]),o.push(n[r>>18&63]+n[r>>12&63]+n[r>>6&63]+n[63&r]);return o.join("")}(e,a,a+16383>
412s?s:a+16383));return 1===r?o.push(n[(t=e[i-1])>>2]+n[t<<4&63]+"=="):2===r&&o.push(n[(t=(e[i-2]<<8)+e[i-1])>>10]+n[t>>4&63]+n[t<<2&63]+"="),o.join("")};for(var n=[],i=[],r="u">typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=o.length;a<s;++a)n[a]=o[a],i[o.charCodeAt(a)]=a;function l(e){var t=e.length;if(t%4>0)throw Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var i=n===t?0:4-n%4;return[n,i]}i[45]=62,i[95]=63},72:function(e,t,n){"use strict";var i=n(675),r=n(783),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function a(e){if(e>0x7fffffff)throw RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,s.prototype),t}function s(e,t,n){if("number"==typeof e){if("string"==typeof t)throw TypeError('The "string" argument must be of type string. Received type number');return u(e)}return l(e,t,n)}function l(e,t,n){if("string"==typeof e){var i=e,r=t;if(("string"!=typeof r||""===r)&&(r="utf8"),!s.isEncoding(r))throw TypeError("Unknown encoding: "+r);var o=0|p(i,r),l=a(o),d=l.write(i,r);return d!==o&&(l=l.slice(0,d)),l}if(ArrayBuffer.isView(e))return c(e);if(null==e)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(R(e,ArrayBuffer)||e&&R(e.buffer,ArrayBuffer)||"u">typeof SharedArrayBuffer&&(R(e,SharedArrayBuffer)||e&&R(e.buffer,SharedArrayBuffer)))return function(e,t,n){var i;if(t<0||e.byteLength<t)throw RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(n||0))throw RangeError('"length" is outside of buffer bounds');return Object.setPrototypeOf(i=void 0===t&&void 0===n?new Uint8Array(e):void 0===n?new Uint8Array(e,t):new Uint8Array(e,t,n),s.prototype),i}(e,t,n);if("number"==typeof e)throw TypeError('The "value" argument must not be of type number. Received type number');var u=e.valueOf&&e.valueOf();if(null!=u&&u!==e)return s.from(u,t,n);var f=function(e){if(s.isBuffer(e)){var t=0|h(e.length),n=a(t);return 0===n.length||e.copy(n,0,0,t),n}return void 0!==e.length?"number"!=typeof e.length||function(e){return e!=e}(e.length)?a(0):c(e):"Buffer"===e.type&&Array.isArray(e.data)?c(e.data):void 0}(e);if(f)return f;if("u">typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return s.from(e[Symbol.toPrimitive]("string"),t,n);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function d(e){if("number"!=typeof e)throw TypeError('"size" argument must be of type number');if(e<0)throw RangeError('The value "'+e+'" is invalid for option "size"')}function u(e){return d(e),a(e<0?0:0|h(e))}function c(e){for(var t=e.length<0?0:0|h(e.length),n=a(t),i=0;i<t;i+=1)n[i]=255&e[i];return n}t.Buffer=s,t.SlowBuffer=function(e){return+e!=e&&(e=0),s.alloc(+e)},t.INSPECT_MAX_BYTES=50,t.kMaxLength=0x7fffffff,s.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}(),!s.TYPED_ARRAY_SUPPORT&&"u">typeof console&&"function"==typeof console.error&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(s.prototype,"parent",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.buffer}}),Object.defineProperty(s.prototype,"offset",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.byteOffset}}),s.poolSize=8192,s.from=function(e,t,n){return l(e,t,n)},Object.setPrototypeOf(s.prototype,Uint8Array.prototype),Object.setPrototypeOf(s,Uint8Array),s.alloc=function(e,t,n){return(d(e),e<=0)?a(e):void 0!==t?"string"==typeof n?a(e).fill(t,n):a(e).fill(t):a(e)},s.allocUnsafe=function(e){return u(e)},s.allocUnsafeSlow=function(e){return u(e)};function h(e){if(e>=0x7fffffff)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|e}function p(e,t){if(s.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||R(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var n=e.length,i=arguments.length>2&&!0===arguments[2];if(!i&&0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return k(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return T(e).length;default:if(r)return i?-1:k(e).length;t=(""+t).toLowerCase(),r=!0}}function f(e,t,n){var r,o,a,s=!1;if((void 0===t||t<0)&&(t=0),t>this.length||((void 0===n||n>this.length)&&(n=this.length),n<=0||(n>>>=0)<=(t>>>=0)))return"";for(e||(e="utf8");;)switch(e){case"hex":return function(e,t,n){var i=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>i)&&(n=i);for(var r="",o=t;o<n;++o)r+=I[e[o]];return r}(this,t,n);case"utf8":case"utf-8":return y(this,t,n);case"ascii":return function(e,t,n){var i="";n=Math.min(e.length,n);for(var r=t;r<n;++r)i+=String.fromCharCode(127&e[r]);return i}(this,t,n);case"latin1":case"binary":return function(e,t,n){var i="";n=Math.min(e.length,n);for(var r=t;r<n;++r)i+=String.fromCharCode(e[r]);return i}(this,t,n);
vendor: 13,696 bytes, line 412
412case"base64":return r=this,o=t,a=n,0===o&&a===r.length?i.fromByteArray(r):i.fromByteArray(r.slice(o,a));case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return function(e,t,n){for(var i=e.slice(t,n),r="",o=0;o<i.length;o+=2)r+=String.fromCharCode(i[o]+256*i[o+1]);return r}(this,t,n);default:if(s)throw TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),s=!0}}function g(e,t,n){var i=e[t];e[t]=e[n],e[n]=i}function m(e,t,n,i,r){var o;if(0===e.length)return -1;if("string"==typeof n?(i=n,n=0):n>0x7fffffff?n=0x7fffffff:n<-0x80000000&&(n=-0x80000000),(o=n*=1)!=o&&(n=r?0:e.length-1),n<0&&(n=e.length+n),n>=e.length)if(r)return -1;else n=e.length-1;else if(n<0)if(!r)return -1;else n=0;if("string"==typeof t&&(t=s.from(t,i)),s.isBuffer(t))return 0===t.length?-1:v(e,t,n,i,r);if("number"==typeof t){if(t&=255,"function"==typeof Uint8Array.prototype.indexOf)if(r)return Uint8Array.prototype.indexOf.call(e,t,n);else return Uint8Array.prototype.lastIndexOf.call(e,t,n);return v(e,[t],n,i,r)}throw TypeError("val must be string, number or Buffer")}function v(e,t,n,i,r){var o,a=1,s=e.length,l=t.length;if(void 0!==i&&("ucs2"===(i=String(i).toLowerCase())||"ucs-2"===i||"utf16le"===i||"utf-16le"===i)){if(e.length<2||t.length<2)return -1;a=2,s/=2,l/=2,n/=2}function d(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(r){var u=-1;for(o=n;o<s;o++)if(d(e,o)===d(t,-1===u?0:o-u)){if(-1===u&&(u=o),o-u+1===l)return u*a}else -1!==u&&(o-=o-u),u=-1}else for(n+l>s&&(n=s-l),o=n;o>=0;o--){for(var c=!0,h=0;h<l;h++)if(d(e,o+h)!==d(t,h)){c=!1;break}if(c)return o}return -1}s.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==s.prototype},s.compare=function(e,t){if(R(e,Uint8Array)&&(e=s.from(e,e.offset,e.byteLength)),R(t,Uint8Array)&&(t=s.from(t,t.offset,t.byteLength)),!s.isBuffer(e)||!s.isBuffer(t))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;for(var n=e.length,i=t.length,r=0,o=Math.min(n,i);r<o;++r)if(e[r]!==t[r]){n=e[r],i=t[r];break}return n<i?-1:+(i<n)},s.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},s.concat=function(e,t){if(!Array.isArray(e))throw TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return s.alloc(0);if(void 0===t)for(n=0,t=0;n<e.length;++n)t+=e[n].length;var n,i=s.allocUnsafe(t),r=0;for(n=0;n<e.length;++n){var o=e[n];if(R(o,Uint8Array)&&(o=s.from(o)),!s.isBuffer(o))throw TypeError('"list" argument must be an Array of Buffers');o.copy(i,r),r+=o.length}return i},s.byteLength=p,s.prototype._isBuffer=!0,s.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)g(this,t,t+1);return this},s.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)g(this,t,t+3),g(this,t+1,t+2);return this},s.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)g(this,t,t+7),g(this,t+1,t+6),g(this,t+2,t+5),g(this,t+3,t+4);return this},s.prototype.toString=function(){var e=this.length;return 0===e?"":0==arguments.length?y(this,0,e):f.apply(this,arguments)},s.prototype.toLocaleString=s.prototype.toString,s.prototype.equals=function(e){if(!s.isBuffer(e))throw TypeError("Argument must be a Buffer");return this===e||0===s.compare(this,e)},s.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,n).replace(/(.{2})/g,"$1 ").trim(),this.length>n&&(e+=" ... "),"<Buffer "+e+">"},o&&(s.prototype[o]=s.prototype.inspect),s.prototype.compare=function(e,t,n,i,r){if(R(e,Uint8Array)&&(e=s.from(e,e.offset,e.byteLength)),!s.isBuffer(e))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===i&&(i=0),void 0===r&&(r=this.length),t<0||n>e.length||i<0||r>this.length)throw RangeError("out of range index");if(i>=r&&t>=n)return 0;if(i>=r)return -1;if(t>=n)return 1;if(t>>>=0,n>>>=0,i>>>=0,r>>>=0,this===e)return 0;for(var o=r-i,a=n-t,l=Math.min(o,a),d=this.slice(i,r),u=e.slice(t,n),c=0;c<l;++c)if(d[c]!==u[c]){o=d[c],a=u[c];break}return o<a?-1:+(a<o)},s.prototype.includes=function(e,t,n){return -1!==this.indexOf(e,t,n)},s.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},s.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)};function y(e,t,n){n=Math.min(e.length,n);for(var i=[],r=t;r<n;){var o,a,s,l,d=e[r],u=null,c=d>239?4:d>223?3:d>191?2:1;if(r+c<=n)switch(c){case 1:d<128&&(u=d);break;case 2:(192&(o=e[r+1]))==128&&(l=(31&d)<<6|63&o)>127&&(u=l);break;case 3:o=e[r+1],a=e[r+2],(192&o)==128&&(192&a)==128&&(l=(15&d)<<12|(63&o)<<6|63&a)>2047&&(l<55296||l>57343)&&(u=l);break;case 4:o=e[r+1],a=e[r+2],s=e[r+3],(192&o)==128&&(192&a)==128&&(192&s)==128&&(l=(15&d)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&l<1114112&&(u=l)}null===u?(u=65533,c=1):u>65535&&(u-=65536,i.push(u>>>10&1023|55296),u=56320|1023&u),i.push(u),r+=c}var h=i,p=h.length;if(p<=4096)return String.fromCharCode.apply(String,h);for(var f="",g=0;g<p;)f+=String.fromCharCode.apply(String,h.slice(g,g+=4096));return f}function b(e,t,n){if(e%1!=0||e<0)throw RangeError("offset is not uint");if(e+t>n)throw RangeError("Trying to access beyond buffer length")}function x(e,t,n,i,r,o){if(!s.isBuffer(e))throw TypeError('"buffer" argument must be a Buffer instance');if(t>r||t<o)throw RangeError('"value" argument is out of bounds');if(n+i>e.length)throw RangeError("Index out of range")}function w(e,t,n,i,r,o){if(n+i>e.length||n<0)throw RangeError("Index out of range")}function C(e,t,n,i,o){return t*=1,n>>>=0,o||w(e,t,n,4,34028234663852886e22,-34028234663852886e22),r.write(e,t,n,i,23,4),n+4}function S(e,t,n,i,o){return t*=1,n>>>=0,o||w(e,t,n,8,17976931348623157e292,-17976931348623157e292),r.write(e,t,n,i,52,8),n+8}s.prototype.write=function(e,t,n,i){if(void 0===t)i="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)i=t,n=this.length,t=0;else if(isFinite(t))t>>>=0,isFinite(n)?(n>>>=0,void 0===i&&(i="utf8")):(i=n,n=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var r,o,a,s,l,d,u,c,h=this.length-t;if((void 0===n||n>h)&&(n=h),e.length>0&&(n<0||t<0)||t>this.length)throw RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var p=!1;;)switch(i){case"hex":return function(e,t,n,i){n=Number(n)||0;var r=e.length-n;i?(i=Number(i))>r&&(i=r):i=r;var o=t.length;i>o/2&&(i=o/2);for(var a=0;a<i;++a){var s,l=parseInt(t.substr(2*a,2),16);if((s=l)!=s)break;e[n+a]=l}return a}(this,e,t,n);case"utf8":case"utf-8":return r=t,o=n,D(k(e,this.length-r),this,r,o);case"ascii":return a=t,s=n,D(M(e),this,a,s);case"latin1":case"binary":return function(e,t,n,i){return D(M(t),e,n,i)}(this,e,t,n);case"base64":return l=t,d=n,D(T(e),this,l,d);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return u=t,c=n,D(function(e,t){for(var n,i,r=[],o=0;o<e.length&&!((t-=2)<0);++o)i=(n=e.charCodeAt(o))>>8,r.push(n%256),r.push(i);return r}(e,this.length-u),this,u,c);default:if(p)throw TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),p=!0}},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},s.prototype.slice=function(e,t){var n=this.length;e=~~e,t=void 0===t?n:~~t,e<0?(e+=n)<0&&(e=0):e>n&&(e=n),t<0?(t+=n)<0&&(t=0):t>n&&(t=n),t<e&&(t=e);var i=this.subarray(e,t);return Object.setPrototypeOf(i,s.prototype),i},s.prototype.readUIntLE=function(e,t,n){e>>>=0,t>>>=0,n||b(e,t,this.length);for(var i=this[e],r=1,o=0;++o<t&&(r*=256);)i+=this[e+o]*r;return i},s.prototype.readUIntBE=function(e,t,n){e>>>=0,t>>>=0,n||b(e,t,this.length);for(var i=this[e+--t],r=1;t>0&&(r*=256);)i+=this[e+--t]*r;return i},s.prototype.readUInt8=function(e,t){return e>>>=0,t||b(e,1,this.length),this[e]},s.prototype.readUInt16LE=function(e,t){return e>>>=0,t||b(e,2,this.length),this[e]|this[e+1]<<8},s.prototype.readUInt16BE=function(e,t){return e>>>=0,t||b(e,2,this.length),this[e]<<8|this[e+1]},s.prototype.readUInt32LE=function(e,t){return e>>>=0,t||b(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+0x1000000*this[e+3]},s.prototype.readUInt32BE=function(e,t){return e>>>=0,t||b(e,4,this.length),0x1000000*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},s.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||b(e,t,this.length);for(var i=this[e],r=1,o=0;++o<t&&(r*=256);)i+=this[e+o]*r;return i>=(r*=128)&&(i-=Math.pow(2,8*t)),i},s.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||b(e,t,this.length);for(var i=t,r=1,o=this[e+--i];i>0&&(r*=256);)o+=this[e+--i]*r;return o>=(r*=128)&&(o-=Math.pow(2,8*t)),o},s.prototype.readInt8=function(e,t){return(e>>>=0,t||b(e,1,this.length),128&this[e])?-((255-this[e]+1)*1):this[e]},s.prototype.readInt16LE=function(e,t){e>>>=0,t||b(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?0xffff0000|n:n},s.prototype.readInt16BE=function(e,t){e>>>=0,t||b(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?0xffff0000|n:n},s.prototype.readInt32LE=function(e,t){return e>>>=0,t||b(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},s.prototype.readInt32BE=function(e,t){return e>>>=0,t||b(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},s.prototype.readFloatLE=function(e,t){return e>>>=0,t||b(e,4,this.length),r.read(this,e,!0,23,4)},s.prototype.readFloatBE=function(e,t){return e>>>=0,t||b(e,4,this.length),r.read(this,e,!1,23,4)},s.prototype.readDoubleLE=function(e,t){return e>>>=0,t||b(e,8,this.length),r.read(this,e,!0,52,8)},s.prototype.readDoubleBE=function(e,t){return e>>>=0,t||b(e,8,this.length),r.read(this,e,!1,52,8)},s.prototype.writeUIntLE=function(e,t,n,i){if(e*=1,t>>>=0,n>>>=0,!i){var r=Math.pow(2,8*n)-1;x(this,e,t,n,r,0)}var o=1,a=0;for(this[t]=255&e;++a<n&&(o*=256);)this[t+a]=e/o&255;return t+n},s.prototype.writeUIntBE=function(e,t,n,i){if(e*=1,t>>>=0,n>>>=0,!i){var r=Math.pow(2,8*n)-1;x(this,e,t,n,r,0)}var o=n-1,a=1;for(this[t+o]=255&e;--o>=0&&(a*=256);)this[t+o]=e/a&255;return t+n},s.prototype.writeUInt8=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,1,255,0),this[t]=255&e,t+1},s.prototype.writeUInt16LE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},s.prototype.writeUInt16BE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},s.prototype.writeUInt32LE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,4,0xffffffff,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},s.prototype.writeUInt32BE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,4,0xffffffff,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},s.prototype.writeIntLE=function(e,t,n,i){if(e*=1,t>>>=0,!i){var r=Math.pow(2,8*n-1);x(this,e,t,n,r-1,-r)}var o=0,a=1,s=0;for(this[t]=255&e;++o<n&&(a*=256);)e<0&&0===s&&0!==this[t+o-1]&&(s=1),this[t+o]=(e/a|0)-s&255;return t+n},s.prototype.writeIntBE=function(e,t,n,i){if(e*=1,t>>>=0,!i){var r=Math.pow(2,8*n-1);x(this,e,t,n,r-1,-r)}var o=n-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a|0)-s&255;return t+n},s.prototype.writeInt8=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},s.prototype.writeInt16LE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},s.prototype.writeInt16BE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},s.prototype.writeInt32LE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,4,0x7fffffff,-0x80000000),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},s.prototype.writeInt32BE=function(e,t,n){return e*=1,t>>>=0,n||x(this,e,t,4,0x7fffffff,-0x80000000),e<0&&(e=0xffffffff+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},s.prototype.writeFloatLE=function(e,t,n){return C(this,e,t,!0,n)},s.prototype.writeFloatBE=function(e,t,n){return C(this,e,t,!1,n)},s.prototype.writeDoubleLE=function(e,t,n){return S(this,e,t,!0,n)},s.prototype.writeDoubleBE=function(e,t,n){return S(this,e,t,!1,n)},s.prototype.copy=function(e,t,n,i){if(!s.isBuffer(e))throw TypeError("argument should be a Buffer");if(n||(n=0),i||0===i||(i=this.length),t>=e.length&&(t=e.length),t||(t=0),i>0&&i<n&&(i=n),i===n||0===e.length||0===this.length)return 0;if(t<0)throw RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw RangeError("Index out of range");if(i<0)throw RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-t<i-n&&(i=e.length-t+n);var r=i-n;if(this===e&&"function"==typeof Uint8Array.prototype.copyWithin)this.copyWithin(t,n,i);else if(this===e&&n<t&&t<i)for(var o=r-1;o>=0;--o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,i),t);return r},s.prototype.fill=function(e,t,n,i){if("string"==typeof e){if("string"==typeof t?(i=t,t=0,n=this.length):"string"==typeof n&&(i=n,n=this.length),void 0!==i&&"string"!=typeof i)throw TypeError("encoding must be a string");if("string"==typeof i&&!s.isEncoding(i))throw TypeError("Unknown encoding: "+i);if(1===e.length){var r,o=e.charCodeAt(0);("utf8"===i&&o<128||"latin1"===i)&&(e=o)}}else"number"==typeof e?e&=255:"boolean"==typeof e&&(e=Number(e));if(t<0||this.length<t||this.length<n)throw RangeError("Out of range index");if(n<=t)return this;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(r=t;r<n;++r)this[r]=e;
412else{var a=s.isBuffer(e)?e:s.from(e,i),l=a.length;if(0===l)throw TypeError('The value "'+e+'" is invalid for argument "value"');for(r=0;r<n-t;++r)this[r+t]=a[r%l]}return this};var _=/[^+/0-9A-Za-z-_]/g;function k(e,t){t=t||1/0;for(var n,i=e.length,r=null,o=[],a=0;a<i;++a){if((n=e.charCodeAt(a))>55295&&n<57344){if(!r){if(n>56319||a+1===i){(t-=3)>-1&&o.push(239,191,189);continue}r=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),r=n;continue}n=(r-55296<<10|n-56320)+65536}else r&&(t-=3)>-1&&o.push(239,191,189);if(r=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else if(n<1114112){if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}else throw Error("Invalid code point")}return o}function M(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}function T(e){return i.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(_,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function D(e,t,n,i){for(var r=0;r<i&&!(r+n>=t.length)&&!(r>=e.length);++r)t[r+n]=e[r];return r}function R(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}var I=function(){for(var e="0123456789abcdef",t=Array(256),n=0;n<16;++n)for(var i=16*n,r=0;r<16;++r)t[i+r]=e[n]+e[r];return t}()},783:function(e,t){t.read=function(e,t,n,i,r){var o,a,s=8*r-i-1,l=(1<<s)-1,d=l>>1,u=-7,c=n?r-1:0,h=n?-1:1,p=e[t+c];for(c+=h,o=p&(1<<-u)-1,p>>=-u,u+=s;u>0;o=256*o+e[t+c],c+=h,u-=8);for(a=o&(1<<-u)-1,o>>=-u,u+=i;u>0;a=256*a+e[t+c],c+=h,u-=8);if(0===o)o=1-d;else{if(o===l)return a?NaN:1/0*(p?-1:1);a+=Math.pow(2,i),o-=d}return(p?-1:1)*a*Math.pow(2,o-i)},t.write=function(e,t,n,i,r,o){var a,s,l,d=8*o-r-1,u=(1<<d)-1,c=u>>1,h=5960464477539062e-23*(23===r),p=i?0:o-1,f=i?1:-1,g=+(t<0||0===t&&1/t<0);for(isNaN(t=Math.abs(t))||t===1/0?(s=+!!isNaN(t),a=u):(a=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-a))<1&&(a--,l*=2),a+c>=1?t+=h/l:t+=h*Math.pow(2,1-c),t*l>=2&&(a++,l/=2),a+c>=u?(s=0,a=u):a+c>=1?(s=(t*l-1)*Math.pow(2,r),a+=c):(s=t*Math.pow(2,c-1)*Math.pow(2,r),a=0));r>=8;e[n+p]=255&s,p+=f,s/=256,r-=8);for(a=a<<r|s,d+=r;d>0;e[n+p]=255&a,p+=f,a/=256,d-=8);e[n+p-f]|=128*g}}},r={};function o(e){var t=r[e];if(void 0!==t)return t.exports;var n=r[e]={exports:{}},a=!0;try{i[e](n,n.exports,o),a=!1}finally{a&&delete r[e]}return n.exports}o.ab="/ROOT/frontend/node_modules/next/dist/compiled/buffer/",t.exports=o(72)},66501,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=1;n.default=function(){return"".concat(i++)}},42243,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0,n.default=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:60,n=null;return function(){for(var i=this,r=arguments.length,o=Array(r),a=0;a<r;a++)o[a]=arguments[a];clearTimeout(n),n=setTimeout(function(){e.apply(i,o)},t)}}},14351,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.SizeSensorId=n.SensorTabIndex=n.SensorClassName=void 0,n.SizeSensorId="size-sensor-id",n.SensorClassName="size-sensor-object",n.SensorTabIndex="-1"},52972,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.createSensor=void 0;var i,r=(i=e.r(42243))&&i.__esModule?i:{default:i},o=e.r(14351);n.createSensor=function(e,t){var n=void 0,i=[],a=function(){"static"===getComputedStyle(e).position&&(e.style.position="relative");var t=document.createElement("object");return t.onload=function(){t.contentDocument.defaultView.addEventListener("resize",s),s()},t.style.display="block",t.style.position="absolute",t.style.top="0",t.style.left="0",t.style.height="100%",t.style.width="100%",t.style.overflow="hidden",t.style.pointerEvents="none",t.style.zIndex="-1",t.style.opacity="0",t.setAttribute("class",o.SensorClassName),t.setAttribute("tabindex",o.SensorTabIndex),t.type="text/html",e.appendChild(t),t.data="about:blank",t},s=(0,r.default)(function(){i.forEach(function(t){t(e)})}),l=function(){n&&n.parentNode&&(n.contentDocument&&n.contentDocument.defaultView.removeEventListener("resize",s),n.parentNode.removeChild(n),e.removeAttribute(o.SizeSensorId),n=void 0,i=[],t&&t())};return{element:e,bind:function(e){n||(n=a()),-1===i.indexOf(e)&&i.push(e)},destroy:l,unbind:function(e){var t=i.indexOf(e);-1!==t&&i.splice(t,1),0===i.length&&n&&l()}}}},66119,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.createSensor=void 0;var i,r=e.r(14351),o=(i=e.r(42243))&&i.__esModule?i:{default:i};n.createSensor=function(e,t){var n=void 0,i=[],a=(0,o.default)(function(){i.forEac
412h(function(t){t(e)})}),s=function(){var t=new ResizeObserver(a);return t.observe(e),a(),t},l=function(){n&&n.disconnect(),i=[],n=void 0,e.removeAttribute(r.SizeSensorId),t&&t()};return{element:e,bind:function(e){n||(n=s()),-1===i.indexOf(e)&&i.push(e)},destroy:l,unbind:function(e){var t=i.indexOf(e);-1!==t&&i.splice(t,1),0===i.length&&n&&l()}}}},98232,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.createSensor=void 0;var i=e.r(52972),r=e.r(66119);n.createSensor="u">typeof ResizeObserver?r.createSensor:i.createSensor},57646,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.removeSensor=n.getSensor=n.Sensors=void 0;var i,r=(i=e.r(66501))&&i.__esModule?i:{default:i},o=e.r(98232),a=e.r(14351),s=n.Sensors={};function l(e){e&&s[e]&&delete s[e]}n.getSensor=function(e){var t=e.getAttribute(a.SizeSensorId);if(t&&s[t])return s[t];var n=(0,r.default)();e.setAttribute(a.SizeSensorId,n);var i=(0,o.createSensor)(e,function(){return l(n)});return s[n]=i,i},n.removeSensor=function(e){var t=e.element.getAttribute(a.SizeSensorId);e.destroy(),l(t)}},11381,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.ver=n.clear=n.bind=void 0;var i=e.r(57646);n.bind=function(e,t){var n=(0,i.getSensor)(e);return n.bind(t),function(){n.unbind(t)}},n.clear=function(e){var t=(0,i.getSensor)(e);(0,i.removeSensor)(t)},n.ver="1.0.3"},10971,e=>{e.v({block:"index-module-scss-module__3Mi2fW__block","block--black":"index-module-scss-module__3Mi2fW__block--black","block--hasBackgroundColor":"index-module-scss-module__3Mi2fW__block--hasBackgroundColor","block--primary":"index-module-scss-module__3Mi2fW__block--primary","block--quaternary":"index-module-scss-module__3Mi2fW__block--quaternary","block--quinary":"index-module-scss-module__3Mi2fW__block--quinary","block--secondary":"index-module-scss-module__3Mi2fW__block--secondary","block--senary":"index-module-scss-module__3Mi2fW__block--senary","block--tertiary":"index-module-scss-module__3Mi2fW__block--tertiary","block--white":"index-module-scss-module__3Mi2fW__block--white",content:"index-module-scss-module__3Mi2fW__content","fade-in":"index-module-scss-module__3Mi2fW__fade-in",optionsBlock:"index-module-scss-module__3Mi2fW__optionsBlock",question:"index-module-scss-module__3Mi2fW__question",questionContainer:"index-module-scss-module__3Mi2fW__questionContainer",resetButtonContainer:"index-module-scss-module__3Mi2fW__resetButtonContainer"})},20949,e=>{e.v({tocBlock:"index-module-scss-module__7pM5Za__tocBlock",tocBlockWrapper:"index-module-scss-module__7pM5Za__tocBlockWrapper"})},55357,e=>{e.v({placeholderBlock:"index-module-scss-module__56Y0BW__placeholderBlock"})},14932,e=>{"use strict";e.s(["blockComponents",()=>Fy,"getBlockBackgroundColor",()=>Fv],14932);var t,n,i,r,o,a,s,l,d,u,c,h,p,f,g,m,v,y,b,x,w,C,S,_,k,M,T,D,R,I,A,P,E,L,F,O,N,B,z,j,V,H,G,W,$,U,q,K,Y,Z,X,J,Q,ee,et,en=e.i(15332),ei=e.i(68033),er=e.i(29690),eo=e.i(52999),ea=e.i(4352),es=e.i(94576),el=e.i(4698),ed=e.i(34852),eu=e.i(20633),ec=e.i(23039),eh=e.i(25499),ep=e.i(48277),ef=e.i(6865),eg=e.i(62612),em=e.i(84395),ev=e.i(3218),ey=e.i(10395),eb=e.i(90388),ex=e.i(60872),ew=e.i(71906),eC=e.i(30668),eS=e.i(57472),e_=e.i(99850),ek=e.i(15502),eM=e.i(499),eT=e.i(90112),eD=e.i(73596);e.i(99325);var eR=e.i(1584),eI=e.i(24133),eA=e.i(56297),eP=e.i(77219),eE=e.i(20826);let[eL,eF]=(0,eE.createSafeContext)("Accordion component was not found in the tree");var eO={root:"m_9bdbb667",panel:"m_df78851f",content:"m_4ba554d4",itemTitle:"m_8fa820a0",control:"m_4ba585b8","control--default":"m_6939a5e9","control--contained":"m_4271d21b",label:"m_df3ffa0f",chevron:"m_3f35ae96",icon:"m_9bd771fe",item:"m_9bd7b098","item--default":"m_fe19b709","item--contained":"m_1f921b3b","item--filled":"m_2cdf939a","item--separated":"m_9f59b069"},eN=e.i(23414),eB=e.i(57922),ez=e.i(20425);let[ej,eV]=(0,eE.createSafeContext)("Accordion.Item component was not found in the tree"),eH=(0,eP.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,chevron:s,icon:l,onClick:d,onKeyDown:u,children:c,disabled:h,mod:p,...f}=(0,eR.useProps)("AccordionControl",null,e),{value:g}=eV(),m=eF(),v=m.isItemActive(g),y="number"==typeof m.order,b=`h${m.order}`,x=(0,ep.jsxs)(ez.UnstyledButton,{...f,...m.getStyles("control",{className:i,classNames:n,style:r,styles:o,variant:m.variant}),unstyled:m.unstyled,mod:["accordion-control",{active:v,"chevron-position":m.chevronPosition,disabled:h},p],ref:t,onClick:e=>{d?.(e),m.onChange(g)},type:"button",disabled:h,"aria-expanded":v,"aria-controls":m.getRegionId(g),id:m.getControlId(g),onKeyDown:(0,eB.createScopedKeydownHandler)({siblingSelector:"[data-accordion-control]",parentSelector:"[data-accordion]",activateOnFocus:!1,loop:m.loop,orientation:"vertical",onKeyDown:u}),children:[(0,ep.jsx)(eA.Box,{component:"span",mod:{rotate:!m.disableChevronRotation&&v,position:m.chevronPosition},...m.getStyles("chevron",{classNames:n,styles:o}),children:s||m.chevron}),(0,ep.jsx)("span",{...m.getStyles("label",{classNames:n,styles:o}),children:c}),l&&(0,ep.jsx)(eA.Box,{component:"span",mod:{"chevron-position":m.chevronPosition},...m.getStyles("icon",{classNames:n,styles:o}),children:l})]});return y?(0,ep.jsx)(b,{...m.getStyles("itemTitle",{classNames:n,styles:o}),children:x}):x});
412eH.displayName="@mantine/core/AccordionControl",eH.classes=eO;let eG=(0,eP.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,value:s,mod:l,...d}=(0,eR.useProps)("AccordionItem",null,e),u=eF();return(0,ep.jsx)(ej,{value:{value:s},children:(0,ep.jsx)(eA.Box,{ref:t,mod:[{active:u.isItemActive(s)},l],...u.getStyles("item",{className:i,classNames:n,styles:o,style:r,variant:u.variant}),...d})})});eG.displayName="@mantine/core/AccordionItem",eG.classes=eO;var eW=e.i(7223),e$=e.i(11920),eU=e.i(44249),eq=e.i(69941),eK=e.i(79352),eY=e.i(12824);function eZ(e){return e?.current?e.current.scrollHeight:"auto"}let eX="u">typeof window&&window.requestAnimationFrame,eJ={transitionDuration:200,transitionTimingFunction:"ease",animateOpacity:!0},eQ=(0,eP.factory)((e,t)=>{let{children:n,in:i,transitionDuration:r,transitionTimingFunction:o,style:a,onTransitionEnd:s,animateOpacity:l,keepMounted:d,...u}=(0,eR.useProps)("Collapse",eJ,e),c=(0,e$.useMantineTheme)(),h=(0,eW.useReducedMotion)(),p=c.respectReducedMotion&&h?0:r,f=function({transitionDuration:e,transitionTimingFunction:t="ease",onTransitionEnd:n=()=>{},opened:i,keepMounted:r=!1}){let o=(0,eC.useRef)(null),a={height:0,overflow:"hidden",...r?{}:{display:"none"}},[s,l]=(0,eC.useState)(i?{}:a),d=e=>{(0,eq.flushSync)(()=>l(e))},u=e=>{d(t=>({...t,...e}))};function c(n){let i=e||function(e){if(!e||"string"==typeof e)return 0;let t=e/36;return Math.round((4+15*t**.25+t/5)*10)}(n);return{transition:`height ${i}ms ${t}, opacity ${i}ms ${t}`}}(0,eK.useDidUpdate)(()=>{"function"==typeof eX&&(i?eX(()=>{u({willChange:"height",display:"block",overflow:"hidden"}),eX(()=>{let e=eZ(o);u({...c(e),height:e})})}):eX(()=>{let e=eZ(o);u({...c(e),willChange:"height",height:e}),eX(()=>u({height:0,overflow:"hidden"}))}))},[i]);let h=e=>{if(e.target===o.current&&"height"===e.propertyName)if(i){let e=eZ(o);e===s.height?d({}):u({height:e}),n()}else 0===s.height&&(d(a),n())};return function({style:e={},refKey:t="ref",...n}={}){let r=n[t],a={"aria-hidden":!i,...n,[t]:(0,eY.mergeRefs)(o,r),onTransitionEnd:h,style:{boxSizing:"border-box",...e,...s}};return eC.default.version.startsWith("18")?i||(a.inert=""):a.inert=!i,a}}({opened:i,transitionDuration:p,transitionTimingFunction:o,onTransitionEnd:s,keepMounted:d});return 0===p?i?(0,ep.jsx)(eA.Box,{...u,children:n}):null:(0,ep.jsx)(eA.Box,{...f({style:{opacity:i||!l?1:0,transition:l?`opacity ${p}ms ${o}`:"none",...(0,eU.getStyleObject)(a,c)},ref:t,...u}),children:n})});eQ.displayName="@mantine/core/Collapse";let e0=(0,eP.factory)((e,t)=>{let{classNames:n,className:i,style:r,styles:o,vars:a,children:s,...l}=(0,eR.useProps)("AccordionPanel",null,e),{value:d}=eV(),u=eF();return(0,ep.jsx)(eQ,{ref:t,...u.getStyles("panel",{className:i,classNames:n,style:r,styles:o}),...l,in:u.isItemActive(d),transitionDuration:u.transitionDuration??200,role:"region",id:u.getRegionId(d),"aria-labelledby":u.getControlId(d),children:(0,ep.jsx)("div",{...u.getStyles("content",{classNames:n,styles:o}),children:s})})});e0.displayName="@mantine/core/AccordionPanel",e0.classes=eO;let e1={multiple:!1,disableChevronRotation:!1,chevronPosition:"right",variant:"default",chevronSize:"auto",chevronIconSize:16},e2=(0,eD.createVarsResolver)((e,{transitionDuration:t,chevronSize:n,radius:i})=>({root:{"--accordion-transition-duration":void 0===t?void 0:`${t}ms`,"--accordion-chevron-size":void 0===n?void 0:(0,ek.rem)(n),"--accordion-radius":void 0===i?void 0:(0,eT.getRadius)(i)}}));function e3(e){let t=(0,eR.useProps)("Accordion",e1,e),{classNames:n,className:i,style:r,styles:o,unstyled:a,vars:s,children:l,multiple:d,value:u,defaultValue:c,onChange:h,id:p,loop:f,transitionDuration:g,disableChevronRotation:m,chevronPosition:v,chevronSize:y,order:b,chevron:x,variant:w,radius:C,chevronIconSize:S,attributes:_,...k}=t,M=(0,eS.useId)(p),[T,D]=(0,e_.useUncontrolled)({value:u,defaultValue:c,finalValue:d?[]:null,onChange:h}),R=(0,eI.useStyles)({name:"Accordion",classes:eO,props:t,className:i,style:r,classNames:n,styles:o,unstyled:a,attributes:_,vars:s,varsResolver:e2});return(0,ep.jsx)(eL,{value:{isItemActive:e=>Array.isArray(T)?T.includes(e):e===T,onChange:e=>{D(Array.isArray(T)?T.includes(e)?T.filter(t=>t!==e):[...T,e]:e===T?null:e)},getControlId:(0,eM.getSafeId)(`${M}
412-control`,"Accordion.Item component was rendered with invalid value or without value"),getRegionId:(0,eM.getSafeId)(`${M}-panel`,"Accordion.Item component was rendered with invalid value or without value"),chevron:null===x?null:x||(0,ep.jsx)(eN.AccordionChevron,{size:S}),transitionDuration:g,disableChevronRotation:m,chevronPosition:v,order:b,loop:f,getStyles:R,variant:w,unstyled:a},children:(0,ep.jsx)(eA.Box,{...R("root"),id:M,...k,variant:w,"data-accordion":!0,children:l})})}e3.extend=e=>e,e3.withProps=(0,eP.getWithProps)(e3),e3.classes=eO,e3.displayName="@mantine/core/Accordion",e3.Item=eG,e3.Panel=e0,e3.Control=eH,e3.Chevron=eN.AccordionChevron;var e5=e.i(40867),e4=e.i(50096),e6=e.i(68998),e8=e.i(12112),e7=e.i(1483),e9={root:"m_96b553a6"},te=e.i(52574),tt=e.i(37012),tn=e.i(45017);let ti=(0,eD.createVarsResolver)((e,{transitionDuration:t})=>({root:{"--transition-duration":"number"==typeof t?`${t}ms`:t}})),tr=(0,eP.factory)((e,t)=>{let n=(0,eR.useProps)("FloatingIndicator",null,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,target:d,parent:u,transitionDuration:c,mod:h,displayAfterTransitionEnd:p,attributes:f,...g}=n,m=(0,eI.useStyles)({name:"FloatingIndicator",classes:e9,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:f,vars:l,varsResolver:ti}),v=(0,eC.useRef)(null),{initialized:y,hidden:b}=function({target:e,parent:t,ref:n,displayAfterTransitionEnd:i}){let r=(0,eC.useRef)(-1),[o,a]=(0,eC.useState)(!1),[s,l]=(0,eC.useState)("boolean"==typeof i&&i),d=()=>{if(!e||!t||!n.current)return;let i=e.getBoundingClientRect(),r=t.getBoundingClientRect(),o=window.getComputedStyle(e),a=window.getComputedStyle(t),s=(0,tn.toInt)(o.borderTopWidth)+(0,tn.toInt)(a.borderTopWidth),l=(0,tn.toInt)(o.borderLeftWidth)+(0,tn.toInt)(a.borderLeftWidth),d={top:i.top-r.top-s,left:i.left-r.left-l,width:i.width,height:i.height};n.current.style.transform=`translateY(${d.top}px) translateX(${d.left}px)`,n.current.style.width=`${d.width}px`,n.current.style.height=`${d.height}px`},u=()=>{window.clearTimeout(r.current),n.current&&(n.current.style.transitionDuration="0ms"),d(),r.current=window.setTimeout(()=>{n.current&&(n.current.style.transitionDuration="")},30)},c=(0,eC.useRef)(null),h=(0,eC.useRef)(null);return(0,eC.useEffect)(()=>{if(d(),e)return c.current=new ResizeObserver(u),c.current.observe(e),t&&(h.current=new ResizeObserver(u),h.current.observe(t)),()=>{c.current?.disconnect(),h.current?.disconnect()}},[t,e]),(0,eC.useEffect)(()=>{if(t){let e=e=>{(function(e,t){if(!t||!e)return!1;let n=t.parentNode;for(;null!=n;){if(n===e)return!0;n=n.parentNode}return!1})(e.target,t)&&(u(),l(!1))};return t.addEventListener("transitionend",e),()=>{t.removeEventListener("transitionend",e)}}},[t]),!function(e,t,n={autoInvoke:!1}){let i=(0,eC.useRef)(null),r=(0,eC.useCallback)((...t)=>{i.current||(i.current=window.setTimeout(()=>{e(t),i.current=null},20))},[20]),o=(0,eC.useCallback)(()=>{i.current&&(window.clearTimeout(i.current),i.current=null)},[]);(0,eC.useEffect)(()=>(n.autoInvoke&&r(),o),[o,r])}(()=>{"test"!==(0,tt.getEnv)()&&a(!0)},0,{autoInvoke:!0}),(0,te.useMutationObserver)(e=>{e.forEach(e=>{"attributes"===e.type&&"dir"===e.attributeName&&u()})},{attributes:!0,attributeFilter:["dir"]},()=>document.documentElement),{initialized:o,hidden:s}}({target:d,parent:u,ref:v,displayAfterTransitionEnd:p}),x=(0,eY.useMergedRef)(t,v);return d&&u?(0,ep.jsx)(eA.Box,{ref:x,mod:[{initialized:y,hidden:b},h],...m("root"),...g}):null});tr.displayName="@mantine/core/FloatingIndicator",tr.classes=e9;var to={root:"m_cf365364",indicator:"m_9e182ccd",label:"m_1738fcb2",input:"m_1714d588",control:"m_69686b9b",innerLabel:"m_78882f40"};let ta={withItemsBorders:!0},ts=(0,eD.createVarsResolver)((e,{radius:t,color:n,transitionDuration:i,size:r,transitionTimingFunction:o})=>({root:{"--sc-radius":void 0===t?void 0:(0,eT.getRadius)(t),"--sc-color":n?(0,e8.getThemeColor)(n,e):void 0,"--sc-shadow":n?void 0:"var(--mantine-shadow-xs)","--sc-transition-duration":void 0===i?void 0:`${i}ms`,"--sc-transition-timing-function":o,"--sc-padding":(0,eT.getSize)(r,"sc-padding"),"--sc-font-size":(0,eT.getFontSize)(r)}})),tl=(0,eP.factory)((e,t)=>{var n,i;let r,o,a=(0,eR.useProps)("SegmentedControl",ta,e),{classNames:s,className:l,style:d,styles:u,unstyled:c,vars:h,data:p,value:f,defaultValue:g,onChange:m,size:v,name:y,disabled:b,readOnly:x,fullWidth:w,orientation:C,radius:S,color:_,transitionDuration:k,transitionTimingFunction:M,variant:T,autoContrast:D,withItemsBorders:R,mod:I,attributes:A,...P}=a,E=(0,eI.useStyles)({name:"SegmentedControl",props:a,classes:to,className:l,style:d,classNames:s,styles:u,unstyled:c,attributes:A,vars:h,varsResolver:ts}),L=(0,e$.useMantineTheme)(),F=p.map(e=>"string"==typeof e?{label:e,value:e}:e),O=function(){let[e,t]=(0,eC.useState)(!1);return(0,eC.useEffect)(()=>t(!0),[]),e}(),[N,B]=(0,eC.useState)((0,e6.randomId)()),[z,j]=(0,eC.useState)(null),[V,H]=(0,eC.useState)({}),[G,W]=(0,e_.useUncontrolled)({value:f,defaultValue:g,finalValue:Array.isArray(p)?F.find(e=>!e.disabled)?.value??p[0]?.value??null:null,onChange:m}),$=(0,eS.useId)(y),U=F.map(e=>(0,eC.createElement)(eA.Box,{...E("control"),mod:{active:G===e.value,orientation:C},key:e.value},(0,eC.createElement)("input",{...E("input"),disabled:b||e.disabled,type:"radio",name:$,value:e.value,id:`${$}-${e.value}`,checked:G===e.value,onChange:()=>!x&&W(e.value),"data-focus-ring":L.focusRing,key:`${e.value}-input`}),(0,eC.createElement)(eA.Box,{component:"label",...E("label"),mod:{active:G===e.value&&!(b||e.disabled),disabled:b||e.disabled,"read-only":x},htmlFor:`${$}-${e.value}`,ref:t=>{V[e.value]=t,H(V)},__vars:{"--sc-label-color":void 0!==_?(0,e7.getContrastColor)({color:_,theme:L,autoContrast:D}):void 0},key:`${e.value}-label`}
412,(0,ep.jsx)("span",{...E("innerLabel"),children:e.label})))),q=(0,eY.useMergedRef)(t,e=>j(e));return(n=()=>{B((0,e6.randomId)())},i=[p.length],(0,eC.useEffect)(n,(r=(0,eC.useRef)([]),o=(0,eC.useRef)(0),!function(e,t){if(!e||!t)return!1;if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n+=1)if(!function(e,t){if(e===t||Number.isNaN(e)&&Number.isNaN(t))return!0;if(!(e instanceof Object)||!(t instanceof Object))return!1;let n=Object.keys(e),{length:i}=n;if(i!==Object.keys(t).length)return!1;for(let r=0;r<i;r+=1){let i=n[r];if(!(i in t)||e[i]!==t[i]&&!(Number.isNaN(e[i])&&Number.isNaN(t[i])))return!1}return!0}(e[n],t[n]))return!1;return!0}(r.current,i)&&(r.current=i,o.current+=1),[o.current])),0===p.length)?null:(0,ep.jsxs)(eA.Box,{...E("root"),variant:T,size:v,ref:q,mod:[{"full-width":w,orientation:C,initialized:O,"with-items-borders":R},I],...P,role:"radiogroup","data-disabled":b,children:["string"==typeof G&&(0,ep.jsx)(tr,{target:V[G],parent:z,component:"span",transitionDuration:"var(--sc-transition-duration)",...E("indicator")},N),U]})});tl.classes=to,tl.displayName="@mantine/core/SegmentedControl";var td=e.i(29730),tu=e.i(63797),tc=e.i(61426),th=e.i(92448),tp=e.i(80202),tf=e.i(63584),tg=e.i(19250),tm=e.i(79908),tv=e.i(4160);let ty=` 413 query Insurers($limit: Int) { 414 Insurers(limit: $limit) { 415 docs { 416 id 417 name 418 aliases 419 } 420 } 421 } 422`;var tb=e.i(69363),tx=e.i(55807),tw=e.i(95317);let tC=[{label:"BGGZ",value:"bggz"},{label:"SGGZ",value:"sggz"},{label:"Generalistische basis jeugd-GGZ",value:"generalistischeBasisJeugdGgz"},{label:"Gespecialiseerde jeugd-GGZ",value:"gespecialiseerdeJeugdGgz"}],tS=[{label:"Online",value:"online"},{label:"Poliklinisch",value:"poliklinisch"},{label:"Klinisch",value:"klinisch"},{label:"Outreachend",value:"outreachend"},{label:"Ambulant",value:"ambulant"},{label:"FACT",value:"fact"},{label:"IHT",value:"iht"},{label:"Dagbehandeling",value:"dagbehandeling"},{label:"Deeltijd",value:"deeltijd"},{label:"Blended",value:"blended"},{label:"Fysiek",value:"fysiek"},{label:"Consultatie",value:"consultatie"}],t_=[{label:"Individueel",value:"individueel"},{label:"Groep",value:"groep"},{label:"Relatie",value:"relatie"},{label:"Gezin",value:"gezin"},{label:"Systeem",value:"systeem"}],tk=[{label:"Engels",value:"engels"},{label:"Duits",value:"duits"},{label:"Frans",value:"frans"},{label:"Spaans",value:"spaans"},{label:"Turks",value:"turks"},{label:"Arabisch",value:"arabisch"},{label:"Farsi",value:"farsi"},{label:"Pools",value:"pools"},{label:"Russisch",value:"russisch"},{label:"Berbers",value:"berbers"},{label:"Dari",value:"dari"},{label:"Gebarentaal",value:"gebarentaal"}],tM=[{label:"Onder treeknorm",value:"onderTreeknorm"},{label:"Boven treeknorm",value:"bovenTreeknorm"},{label:"Afwisselend",value:"afwisselend"},{label:"Stop",value:"stop"}],tT=e=>e?/^https?:\/\//i.test(e)?e:`https://${e}`:null,tD=(e,t)=>{switch(e){case"ggzOrganisation":return t("directoryTypeBehandeling");case"begeleiding":return t("directoryTypeBegeleiding");case"zelfhulp":return t("directoryTypeZelfhulp");default:return e}},tR=e=>{let t=[e.ggzWachttijd?.wachttijdBggzWeken,e.ggzWachttijd?.wachttijdSggzWeken,e.ggzWachttijd?.wachttijdKindWeken].filter(e=>"number"==typeof e);return t.length>0?Math.min(...t):null},tI=({website:e,className:t})=>{let[n,i]=(0,eC.useState)(!1),r=(e=>{let t=tT(e);if(!t)return null;try{let e=new URL(t).hostname;return`https://www.google.com/s2/favicons?sz=32&domain=${encodeURIComponent(e)}`}catch{return null}})(e);return!r||n?null:(0,ep.jsx)("img",{src:r,alt:"",className:t,onError:()=>i(!0)})};var tA=e.i(31514);let tP=new Map(tk.map(e=>[e.value,e.label])),tE=e=>e?e[0].toUpperCase()+e.slice(1):e,tL=e=>e.split(/[,\r\n]+/).map(e=>tE(e.trim())).filter(Boolean).join(", "),tF=({item:e,onClick:t})=>{let n,{tenant:i}=(0,eb.useTenant)(),{t:r}=(0,tm.useTranslations)(),{currentLang:o}=(0,tw.useLanguage)(),a=((e,t)=>{let n=e.ggzWachttijd;if(!n)return null;let i=[{label:"BGGZ",weken:n.wachttijdBggzWeken,status:n.wachttijdBggzStatus},{label:"SGGZ",weken:n.wachttijdSggzWeken,status:n.wachttijdSggzStatus},{label:t,weken:n.wachttijdKindWeken,status:n.wachttijdKindStatus}].map(({label:e,weken:t,status:n})=>"number"==typeof t?`${e} ${t}
422 wk`:"stop"===n?`${e} Stop`:"afwisselend"===n?`${e} Afwisselend`:null).filter(e=>null!==e);return i.length>0?i.join(" · "):null})(e,r("directoryWachttijdKindShort")),s=e.ggzProfiel?.locatie||e.begeleidingProfiel?.locatie||null,l=(e=>{if(e.ggzProfiel?.extraTaal?.length)return e.ggzProfiel.extraTaal.map(e=>tP.get(e)??tE(e)).join(", ");let t=e.ggzProfiel?.extraTaalRaw||e.begeleidingProfiel?.extraTaal||null;return t?tL(t):null})(e),d=(n=(()=>{switch(e.type){case"ggzOrganisation":return e.ggzAanbod?.klachtenDiagnoses||null;case"begeleiding":return e.begeleidingAanbod?.hulpvragenThemas||null;case"zelfhulp":return e.zelfhulpAanbod?.thema||null;default:return null}})())?tL(n):null,u=(e.verzekeringen?.insurerStatuses||[]).filter(e=>"ja"===e.status&&e.insurer?.name);return(0,ep.jsxs)(ev.Paper,{radius:(0,ex.getRadius)(i?.Theme?.borderRadius),className:tA.default.card,onClick:t,role:"button",tabIndex:0,onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&t()},children:[(0,ep.jsxs)("div",{className:tA.default.cardHeader,children:[(0,ep.jsxs)("div",{className:tA.default.cardNameRow,children:[(0,ep.jsx)(tI,{website:e.website,className:tA.default.favicon}),e.website?(0,ep.jsx)("a",{className:tA.default.cardName,href:tT(e.website)??void 0,target:"_blank",rel:"noopener noreferrer",onClick:e=>e.stopPropagation(),children:e.name}):(0,ep.jsx)("span",{className:tA.default.cardName,children:e.name})]}),(0,ep.jsxs)("div",{className:tA.default.cardHeaderBadges,children:[(0,ep.jsx)("span",{className:tA.default.badge,children:tD(e.type,r)}),a&&(0,ep.jsx)("span",{className:[tA.default.badge,tA.default.badgeWachttijd].join(" "),children:a})]})]}),"ggzOrganisation"===e.type&&e.ggzAanbod?.typeZorg&&e.ggzAanbod.typeZorg.length>0&&(0,ep.jsxs)("div",{className:tA.default.cardBadgeRow,children:[e.ggzAanbod.typeZorg.map(e=>(0,ep.jsx)("span",{className:tA.default.badge,children:e.toUpperCase()},e)),e.ggzProfiel?.zorgdomein&&(0,ep.jsxs)("span",{className:[tA.default.badge,"ja"===e.ggzProfiel.zorgdomein?tA.default.badgePositive:tA.default.badgeNegative].join(" "),children:["ja"===e.ggzProfiel.zorgdomein?"â":"â"," ",r("directoryZorgdomein")]})]}),s&&(0,ep.jsxs)("div",{className:tA.default.cardRow,children:["ð ",s]}),u.length>0&&(0,ep.jsxs)("div",{className:tA.default.cardBadgeRow,children:["ð¡ï¸",u.map(e=>(0,ep.jsx)("span",{className:tA.default.badgeInsurer,children:e.insurer?.name},e.insurer?.id))]}),d&&(0,ep.jsxs)("div",{className:[tA.default.cardRow,tA.default.cardSummary].join(" "),children:["ð ",d]}),l&&(0,ep.jsxs)("div",{className:tA.default.cardRow,children:["ð ",l]}),(0,ep.jsxs)("div",{className:tA.default.cardFooter,children:[r("directoryUpdated"),":"," ",new Date(e.updatedAt).toLocaleDateString(o)]})]})};var tO={root:"m_18320242","skeleton-fade":"m_299c329c"};let tN={visible:!0,animate:!0},tB=(0,eD.createVarsResolver)((e,{width:t,height:n,radius:i,circle:r})=>({root:{"--skeleton-height":(0,ek.rem)(n),"--skeleton-width":r?(0,ek.rem)(n):(0,ek.rem)(t),"--skeleton-radius":r?"1000px":void 0===i?void 0:(0,eT.getRadius)(i)}})),tz=(0,eP.factory)((e,t)=>{let n=(0,eR.useProps)("Skeleton",tN,e),{classNames:i,className:r,style:o,styles:a,unstyled:s,vars:l,width:d,height:u,circle:c,visible:h,radius:p,animate:f,mod:g,attributes:m,...v}=n,y=(0,eI.useStyles)({name:"Skeleton",classes:tO,props:n,className:r,style:o,classNames:i,styles:a,unstyled:s,attributes:m,vars:l,varsResolver:tB});return(0,ep.jsx)(eA.Box,{ref:t,...y("root"),mod:[{visible:h,animate:f},g],...v})});tz.classes=tO,tz.displayName="@mantine/core/Skeleton";let tj=()=>{let{tenant:e}=(0,eb.useTenant)();return(0,ep.jsxs)(ev.Paper,{radius:(0,ex.getRadius)(e?.Theme?.borderRadius),className:tA.default.card,children:[(0,ep.jsxs)("div",{className:tA.default.cardHeader,children:[(0,ep.jsx)(tz,{height:16,width:"60%"}),(0,ep.jsx)("div",{className:tA.default.cardHeaderBadges,children:(0,ep.jsx)(tz,{height:20,width:70,radius:"xl"})})]}),(0,ep.jsx)(tz,{height:12,width:"30%"}),(0,ep.jsx)(tz,{height:12,width:"80%"}),(0,ep.jsx)(tz,{height:12,width:"50%"}),(0,ep.jsx)(tz,{height:10,width:"25%",style:{alignSelf:"flex-end"}})]})};var tV=e.i(11116);let tH=(e,t)=>null==t||""===t||"x"===t||Array.isArray(t)&&0===t.length?null:{label:e,value:Array.isArray(t)?t.join(", "):String(t)},tG=[{group:e=>e.ggzWachttijd,labelKey:"directoryWachttijdLabel"},{group:e=>e.ggzAanbod,labelKey:"directoryVeraTopicAanbod"},{group:e=>e.verzekeringen,labelKey:"directoryVerzekeraars"}],tW=({item:e,onClose:t})=>{let{t:n}=(0,tm.useTranslations)(),{currentLang:i}=(0,tw.useLanguage)();if(!e)return null;let r=(e=>{if("ggzOrganisation"!==e.type)return[];let t=new Set,n=[];for(let{group:i,labelKey:r}of tG){let o=i(e),a=o?.lastCheckPublicSummary?.trim();!a||o?.lastCheckOutcome!=="verified"||!o.lastCheckedAt||t.has(a)||(t.add(a),n.push({checkedAt:o.lastCheckedAt,summary:a,labelKey:r}))}return n})(e);return(0,ep.jsxs)(tV.Modal,{isOpen:!!e,onClose:t,children:[(0,ep.jsxs)("div",{className:tA.default.modalTitleRow,children:[(0,ep.jsx)(tI,{website:e.website,className:tA.default.favicon}),(0,ep.jsx)("h2",{className:tA.default.modalTitle,children:e.name})]}),(0,ep.jsxs)("div",{className:tA.default.modalScroll,children:[((e,t,n)=>{let i=[e.website?{label:t("directoryWebsite"),value:(0,ep.jsx)("a",{href:tT(e.website)??void 0,target:"_blank",rel:"noopener noreferrer",children:e.website})}:null,tH(t("directoryFieldType"),tD(e.type,t))];if("ggzOrganisation"===e.type&&i.push(tH(t("directoryLocatie"),e.ggzProfiel?.locatie),tH(t("directoryExtraTaalLabel"),e.ggzProfiel?.extraTaal),tH(t("directoryExtraTaalBron"),e.ggzProfiel?.extraTaalRaw),tH(t("directoryZorgdomein"),e.ggzProfiel?.zorgdomein),tH(t("directoryTypeZorg"),e.ggzAanbod?.typeZorg),tH(t("directoryZorgsettingLabel"),e.ggzAanbod?.zorgsetting),tH(t("directoryZorgvormLabel"),e.ggzAanbod?.zorgvorm),tH(t("directoryDiagnostiekLabel"),e.ggzAanbod?.diagnostiek),tH(t("directoryDoelgroepLeeftijd"),e.ggzAanbod?.doelgroepLeeftijd),tH(t("directoryPrimaireBehandelkader"),e.ggzAanbod?.primaireBehandelkader),tH(t("directoryExpertise"),e.ggzAanbod?.expertise),tH(t("directoryKlachtenDiagnoses"),e.ggzAanbod?.klachtenDiagnoses),tH(t("directoryExclusiecriteria"),e.ggzAanbod?.exclusiecriteria),tH(t("directoryBehandelmethode"),e.ggzAanbod?.behandelmethode),tH(t("directoryWachttijdBggz"),e.ggzWachttijd?.wachttijdBggz),tH(t("directoryWachttijdSggz"),e.ggzWachttijd?.wachttijdSggz),tH(t("directoryWachttijdKind"),e.ggzWachttijd?.wachttijdKind),tH(t("directoryContractJeugdzorgGemeente"),e.verzekeringen?.contractJeugdzorgGemeente)),"begeleiding"===e.type&&i.push(tH(t("directoryLocatie"),e.begeleidingProfiel?.locatie),tH(t("directoryExtraTaalLabel"),e.begeleidingProfiel?.extraTaal),tH(t("directoryLeeftijd"),e.begeleidingAanbod?.leeftijd),tH(t("directoryDoelgroep"),e.begeleidingAanbod?.doelgroep),tH(t("directoryHulpvragenThemas"),e.begeleidingAanbod?.hulpvragenThemas),tH(t("directoryTypeBegeleidingField"),e.begeleidingAanbod?.typeBegeleiding),tH(t("directoryZorgvormLabel"),e.begeleidingAanbod?.zorgvorm),tH(t("directoryBegeleidingsmethode"),e.begeleidingAanbod?.begeleidingsmethode),tH(t("directorySetting"),e.begeleidingAanbod?.setting),tH(t("directoryFinanciering"),e.financiering?.financiering),tH(t("directoryWachttijdLabel"),e.begeleidingWachttijd?.wachttijd)),"zelfhulp"===e.type&&i.push(tH(t("directoryThema"),e.zelfhulpAanbod?.thema),tH(t("directorySpecifiekeDoelgroep"),e.zelfhulpAanbod?.specifiekeDoelgroep),tH(t("directoryWelkMiddel"),e.zelfhulpAanbod?.welkMiddel),tH(t("directoryWat"),e.zelfhulpAanbod?.wat)),"ggzOrganisation"===e.type&&e.verzekeringen?.insurerStatuses){let n=e.verzekeringen.insurerStatuses.filter(e=>"ja"===e.status&&e.insurer?.name).map(e=>`${e.insurer?.name}${e.note?` -- ${e.note}`:""}`).join(", ");i.push(tH(t("directoryVerzekeraars"),n))}return i.push(tH(t("directoryUpdated"),new Date(e.updatedAt).toLocaleDateString(n))),i.filter(e=>null!==e)})(e,n,i).map(e=>(0,ep.jsxs)("div",{className:tA.default.modalRow,children:[(0,ep.jsx)("div",{className:tA.default.modalRowLabel,children:e.label}),(0,ep.jsx)("div",{className:tA.default.modalRowValue,children:e.value})]},e.label)),r.length>0&&(0,ep.jsxs)("div",{className:tA.default.veraChecks,children:[(0,ep.jsx)("div",{className:tA.default.veraChecksHeading,children:n("directoryVeraChecked")}),r.map(e=>(0,ep.jsxs)("div",{className:tA.default.veraCheck,children:[(0,ep.jsxs)("div",{className:tA.default.veraCheckDate,children:[n(e.labelKey)," ·"," ",new Date(e.checkedAt).toLocaleDateString(i)]}),(0,ep.jsx)("div",{className:tA.default.veraCheckSummary,children:e.summary})]},e.summary))]})]})]})};var t$=e.i(86918);let tU=e=>e.split(/[,\r\n]+/).map(e=>
422e.trim()).filter(Boolean),tq=e=>{let t=new Set;return e.forEach(e=>{e&&tU(e).forEach(e=>t.add(e))}),[...t].sort((e,t)=>e.localeCompare(t))},tK=(e,t,n)=>{let i=t.map(t=>({[e]:{contains:t}}));return 1===i.length?i[0]:{[n]:i}};var tY=e.i(98604),tZ=e.i(30755),tX=e.i(29915),tJ=e.i(25363),tQ=e.i(69152);e.i(39057);var t0=function(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1},t1=new function(){this.browser=new t0,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow="u">typeof window};"object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?(t1.wxa=!0,t1.touchEventsSupported=!0):"u"<typeof document&&"u">typeof self?t1.worker=!0:!t1.hasGlobalWindow||"Deno"in window?(t1.node=!0,t1.svgSupported=!0):(t=navigator.userAgent,i=(n=t1).browser,r=t.match(/Firefox\/([\d.]+)/),o=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),a=t.match(/Edge?\/([\d.]+)/),s=/micromessenger/i.test(t),r&&(i.firefox=!0,i.version=r[1]),o&&(i.ie=!0,i.version=o[1]),a&&(i.edge=!0,i.version=a[1],i.newEdge=+a[1].split(".")[0]>18),s&&(i.weChat=!0),n.svgSupported="u">typeof SVGRect,n.touchEventsSupported="ontouchstart"in window&&!i.ie&&!i.edge,n.pointerEventsSupported="onpointerdown"in window&&(i.edge||i.ie&&+i.version>=11),n.domSupported="u">typeof document,l=document.documentElement.style,n.transform3dSupported=(i.ie&&"transition"in l||i.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in l)&&!("OTransition"in l),n.transformSupported=n.transform3dSupported||i.ie&&+i.version>=9);var t2="sans-serif",t3="12px "+t2,t5=function(e){var t={};if("u"<typeof JSON)return t;for(var n=0;n<e.length;n++){var i=String.fromCharCode(n+32),r=(e.charCodeAt(n)-20)/100;t[i]=r}return t}("007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N"),t4={createCanvas:function(){return"u">typeof document&&document.createElement("canvas")},measureText:function(e,t){if(!d){var n=t4.createCanvas();d=n&&n.getContext("2d")}if(d)return u!==t&&(u=d.font=t||t3),d.measureText(e);e=e||"",t=t||t3;var i=/((?:\d+)?\.?\d*)px/.exec(t),r=i&&+i[1]||12,o=0;if(t.indexOf("mono")>=0)o=r*e.length;else for(var a=0;a<e.length;a++){var s=t5[e[a]];o+=null==s?r:s*r}return{width:o}},loadImage:function(e,t,n){var i=new Image;return i.onload=t,i.onerror=n,i.src=e,i}};function t6(e){for(var t in t4)e[t]&&(t4[t]=e[t])}var t8=nS(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(e,t){return e["[object "+t+"]"]=!0,e},{}),t7=nS(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(e,t){return e["[object "+t+"Array]"]=!0,e},{}),t9=Object.prototype.toString,ne=Array.prototype,nt=ne.forEach,nn=ne.filter,ni=ne.slice,nr=ne.map,no=(function(){}
vendor: 7,150 bytes, line 422
422).constructor,na=no?no.prototype:null,ns="__proto__",nl=2311;function nd(){return nl++}function nu(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];"u">typeof console&&console.error.apply(console,e)}function nc(e){if(null==e||"object"!=typeof e)return e;var t=e,n=t9.call(e);if("[object Array]"===n){if(!e[nY]){t=[];for(var i=0,r=e.length;i<r;i++)t[i]=nc(e[i])}}else if(t7[n]){if(!e[nY]){var o=e.constructor;if(o.from)t=o.from(e);else{t=new o(e.length);for(var i=0,r=e.length;i<r;i++)t[i]=e[i]}}}else if(!t8[n]&&!e[nY]&&!nN(e))for(var a in t={},e)e.hasOwnProperty(a)&&a!==ns&&(t[a]=nc(e[a]));return t}function nh(e,t,n){if(!nL(t)||!nL(e))return n?nc(t):e;for(var i in t)if(t.hasOwnProperty(i)&&i!==ns){var r=e[i],o=t[i];!(nL(o)&&nL(r))||nR(o)||nR(r)||nN(o)||nN(r)||nF(o)||nF(r)||o[nY]||r[nY]?!n&&i in e||(e[i]=nc(t[i])):nh(r,o,n)}return e}function np(e,t){for(var n=e[0],i=1,r=e.length;i<r;i++)n=nh(n,e[i],t);return n}function nf(e,t){return Object.assign(e,t),e}function ng(e,t,n){for(var i=nM(t),r=0,o=i.length;r<o;r++){var a=i[r];(n?null!=t[a]:null==e[a])&&(e[a]=t[a])}return e}var nm=t4.createCanvas;function nv(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var n=0,i=e.length;n<i;n++)if(e[n]===t)return n}return -1}function ny(e,t){var n=e.prototype;function i(){}for(var r in i.prototype=t.prototype,e.prototype=new i,n)n.hasOwnProperty(r)&&(e.prototype[r]=n[r]);e.prototype.constructor=e,e.superClass=t}function nb(e,t,n){if(e="prototype"in e?e.prototype:e,t="prototype"in t?t.prototype:t,Object.getOwnPropertyNames)for(var i=Object.getOwnPropertyNames(t),r=0;r<i.length;r++){var o=i[r];"constructor"!==o&&(n?null!=t[o]:null==e[o])&&(e[o]=t[o])}else ng(e,t,n)}function nx(e){return!!e&&"string"!=typeof e&&"number"==typeof e.length}function nw(e,t,n){if(e&&t)if(e.forEach&&e.forEach===nt)e.forEach(t,n);else if(e.length===+e.length)for(var i=0,r=e.length;i<r;i++)t.call(n,e[i],i,e);else for(var o in e)e.hasOwnProperty(o)&&t.call(n,e[o],o,e)}function nC(e,t,n){if(!e)return[];if(!t)return n$(e);if(e.map&&e.map===nr)return e.map(t,n);for(var i=[],r=0,o=e.length;r<o;r++)i.push(t.call(n,e[r],r,e));return i}function nS(e,t,n,i){if(e&&t){for(var r=0,o=e.length;r<o;r++)n=t.call(i,n,e[r],r,e);return n}}function n_(e,t,n){if(!e)return[];if(!t)return n$(e);if(e.filter&&e.filter===nn)return e.filter(t,n);for(var i=[],r=0,o=e.length;r<o;r++)t.call(n,e[r],r,e)&&i.push(e[r]);return i}function nk(e,t,n){if(e&&t){for(var i=0,r=e.length;i<r;i++)if(t.call(n,e[i],i,e))return e[i]}}function nM(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}var nT=na&&nI(na.bind)?na.call.bind(na.bind):function(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];return function(){return e.apply(t,n.concat(ni.call(arguments)))}};function nD(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return function(){return e.apply(this,t.concat(ni.call(arguments)))}}function nR(e){return Array.isArray?Array.isArray(e):"[object Array]"===t9.call(e)}function nI(e){return"function"==typeof e}function nA(e){return"string"==typeof e}function nP(e){return"[object String]"===t9.call(e)}function nE(e){return"number"==typeof e}function nL(e){var t=typeof e;return"function"===t||!!e&&"object"===t}function nF(e){return!!t8[t9.call(e)]}function nO(e){return!!t7[t9.call(e)]}function nN(e){return"object"==typeof e&&"number"==typeof e.nodeType&&"object"==typeof e.ownerDocument}function nB(e){return null!=e.colorStops}function nz(e){return null!=e.image}function nj(e){return"[object RegExp]"===t9.call(e)}function nV(e){return e!=e}function nH(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=0,i=e.length;n<i;n++)if(null!=e[n])return e[n]}function nG(e,t){return null!=e?e:t}function nW(e,t,n){return null!=e?e:null!=t?t:n}function n$(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return ni.apply(e,t)}function nU(e){if("number"==typeof e)return[e,e,e,e];var t=e.length;return 2===t?[e[0],e[1],e[0],e[1]]:3===t?[e[0],e[1],e[2],e[1]]:e}function nq(e,t){if(!e)throw Error(t)}function nK(e){return null==e?null:"function"==typeof e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var nY="__ec_primitive__";function nZ(e){e[nY]=!0}function nX(e){return e[nY]}var nJ=function(){function e(){this.data={}}return e.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},e.prototype.has=function(e){return this.data.hasOwnProperty(e)},e.prototype.get=function(e){return this.data[e]},e.prototype.set=function(e,t){return this.data[e]=t,this},e.prototype.keys=function(){return nM(this.data)},e.prototype.forEach=function(e){var t=this.data;for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)},e}(),nQ="function"==typeof Map,n0=function(){function e(t){var n=nR(t);this.data=nQ?new Map:new nJ;var i=this;function r(e,t){n?i.set(e,t):i.set(t,e)}t instanceof e?t.each(r):t&&nw(t,r)}return e.prototype.hasKey=function(e){return this.data.has(e)},e.prototype.get=function(e){return this.data.get(e)},e.prototype.set=function(e,t){return this.data.set(e,t),t},e.prototype.each=function(e,t){this.data.forEach(function(n,i){e.call(t,n,i)})},e.prototype.keys=function(){var e=this.data.keys();return nQ?Array.from(e):e},e.prototype.removeKey=function(e){this.data.delete(e)},e}();function n1(e){return new n0(e)}function n2(e,t){for(var n=new e.constructor(e.length+t.length),i=0;i<e.length;i++)n[i]=e[i];for(var r=e.length,i=0;i<t.length;i++)n[i+r]=t[i];return n}function n3(e,t){var n;if(Object.create)n=Object.create(e);else{var i=function(){};i.prototype=e,n=new i}return t&&nf(n,t),n}function n5(e){var t=e.style;t.webkitUserSelect="none",t.userSelect="none",t.webkitTapHighlightColor="rgba(0,0,0,0)",t["-webkit-touch-callout"]="none"}function n4(e,t){return e.hasOwnProperty(t)}function n6(){}var n8=180/Math.PI;function n7(e,t){return null==e&&(e=0),null==t&&(t=0),[e,t]}function n9(e,t){return e[0]=t[0],e[1]=t[1],e}function ie(e){return[e[0],e[1]]}function it(e,t,n){return e[0]=t,e[1]=n,e}function ii(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function ir(e,t,n,i){return e[0]=t[0]+n[0]*i,e[1]=t[1]+n[1]*i,e}function io(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function ia(e){return Math.sqrt(is(e))}function is(e){return e[0]*e[0]+e[1]*e[1]}function il(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e}function id(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e}function iu(e,t){return e[0]*t[0]+e[1]*t[1]}function ic(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function ih(e,t){var n=ia(t);return 0===n?(e[0]=0,e[1]=0):(e[0]=t[0]/n,e[1]=t[1]/n),e}function ip(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}function ig(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}function im(e,t){return e[0]=-t[0],e[1]=-t[1],e}function iv(e,t,n,i){return e[0]=t[0]+i*(n[0]-t[0]),e[1]=t[1]+i*(n[1]-t[1]),e}function iy(e,t,n){var i=t[0],r=t[1];return e[0]=n[0]*i+n[2]*r+n[4],e[1]=n[1]*i+n[3]*r+n[5],e}function ib(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function ix(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}e.s(["HashMap",()=>
vendor: 5,690 bytes, line 422
422n0,"RADIAN_TO_DEGREE",()=>n8,"assert",()=>nq,"bind",()=>nT,"clone",()=>nc,"concatArray",()=>n2,"createCanvas",()=>nm,"createHashMap",()=>n1,"createObject",()=>n3,"curry",()=>nD,"defaults",()=>ng,"disableUserSelect",()=>n5,"each",()=>nw,"eqNaN",()=>nV,"extend",()=>nf,"filter",()=>n_,"find",()=>nk,"guid",()=>nd,"hasOwn",()=>n4,"indexOf",()=>nv,"inherits",()=>ny,"isArray",()=>nR,"isArrayLike",()=>nx,"isBuiltInObject",()=>nF,"isDom",()=>nN,"isFunction",()=>nI,"isGradientObject",()=>nB,"isImagePatternObject",()=>nz,"isNumber",()=>nE,"isObject",()=>nL,"isPrimitive",()=>nX,"isRegExp",()=>nj,"isString",()=>nA,"isStringSafe",()=>nP,"isTypedArray",()=>nO,"keys",()=>nM,"logError",()=>nu,"map",()=>nC,"merge",()=>nh,"mergeAll",()=>np,"mixin",()=>nb,"noop",()=>n6,"normalizeCssArray",()=>nU,"reduce",()=>nS,"retrieve",()=>nH,"retrieve2",()=>nG,"retrieve3",()=>nW,"setAsPrimitive",()=>nZ,"slice",()=>n$,"trim",()=>nK],27928),e.s(["add",()=>ii,"applyTransform",()=>iy,"clone",()=>ie,"copy",()=>n9,"create",()=>n7,"dist",()=>ip,"distSquare",()=>ig,"distance",()=>ip,"distanceSquare",()=>ig,"div",()=>id,"dot",()=>iu,"len",()=>ia,"lenSquare",()=>is,"length",()=>ia,"lengthSquare",()=>is,"lerp",()=>iv,"max",()=>ix,"min",()=>ib,"mul",()=>il,"negate",()=>im,"normalize",()=>ih,"scale",()=>ic,"scaleAndAdd",()=>ir,"set",()=>it,"sub",()=>io],45330);var iw=function(e,t){this.target=e,this.topTarget=t&&t.topTarget},iC=function(){function e(e){this.handler=e,e.on("mousedown",this._dragStart,this),e.on("mousemove",this._drag,this),e.on("mouseup",this._dragEnd,this)}return e.prototype._dragStart=function(e){for(var t=e.target;t&&!t.draggable;)t=t.parent||t.__hostTarget;t&&(this._draggingTarget=t,t.dragging=!0,this._x=e.offsetX,this._y=e.offsetY,this.handler.dispatchToElement(new iw(t,e),"dragstart",e.event))},e.prototype._drag=function(e){var t=this._draggingTarget;if(t){var n=e.offsetX,i=e.offsetY,r=n-this._x,o=i-this._y;this._x=n,this._y=i,t.drift(r,o,e),this.handler.dispatchToElement(new iw(t,e),"drag",e.event);var a=this.handler.findHover(n,i,t).target,s=this._dropTarget;this._dropTarget=a,t!==a&&(s&&a!==s&&this.handler.dispatchToElement(new iw(s,e),"dragleave",e.event),a&&a!==s&&this.handler.dispatchToElement(new iw(a,e),"dragenter",e.event))}},e.prototype._dragEnd=function(e){var t=this._draggingTarget;t&&(t.dragging=!1),this.handler.dispatchToElement(new iw(t,e),"dragend",e.event),this._dropTarget&&this.handler.dispatchToElement(new iw(this._dropTarget,e),"drop",e.event),this._draggingTarget=null,this._dropTarget=null},e}(),iS=function(){function e(e){e&&(this._$eventProcessor=e)}return e.prototype.on=function(e,t,n,i){this._$handlers||(this._$handlers={});var r=this._$handlers;if("function"==typeof t&&(i=n,n=t,t=null),!n||!e)return this;var o=this._$eventProcessor;null!=t&&o&&o.normalizeQuery&&(t=o.normalizeQuery(t)),r[e]||(r[e]=[]);for(var a=0;a<r[e].length;a++)if(r[e][a].h===n)return this;var s={h:n,query:t,ctx:i||this,callAtLast:n.zrEventfulCallAtLast},l=r[e].length-1,d=r[e][l];return d&&d.callAtLast?r[e].splice(l,0,s):r[e].push(s),this},e.prototype.isSilent=function(e){var t=this._$handlers;return!t||!t[e]||!t[e].length},e.prototype.off=function(e,t){var n=this._$handlers;if(!n)return this;if(!e)return this._$handlers={},this;if(t){if(n[e]){for(var i=[],r=0,o=n[e].length;r<o;r++)n[e][r].h!==t&&i.push(n[e][r]);n[e]=i}n[e]&&0===n[e].length&&delete n[e]}else delete n[e];return this},e.prototype.trigger=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];if(!this._$handlers)return this;var i=this._$handlers[e],r=this._$eventProcessor;if(i)for(var o=t.length,a=i.length,s=0;s<a;s++){var l=i[s];if(!r||!r.filter||null==l.query||r.filter(e,l.query))switch(o){case 0:l.h.call(l.ctx);break;case 1:l.h.call(l.ctx,t[0]);break;case 2:l.h.call(l.ctx,t[0],t[1]);break;default:l.h.apply(l.ctx,t)}}return r&&r.afterTrigger&&r.afterTrigger(e),this},e.prototype.triggerWithContext=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];if(!this._$handlers)return this;var i=this._$handlers[e],r=this._$eventProcessor;if(i)for(var o=t.length,a=t[o-1],s=i.length,l=0;l<s;l++){var d=i[l];if(!r||!r.filter||null==d.query||r.filter(e,d.query))switch(o){case 0:d.h.call(a);break;case 1:d.h.call(a,t[0]);break;case 2:d.h.call(a,t[0],t[1]);break;default:d.h.apply(a,t.slice(1,o-1))}}return r&&r.afterTrigger&&r.afterTrigger(e),this},e}(),i_=Math.log(2);function ik(e,t,n,i,r,o){var a=i+"-"+r,s=e.length;if(o.hasOwnProperty(a))return o[a];if(1===t){var l=Math.round(Math.log((1<<s)-1&~r)/i_);return e[n][l]}for(var d=i|1<<n,u=n+1;i&1<<u;)u++;for(var c=0,h=0,p=0;h<s;h++){var f=1<<h;!(f&r)&&(c+=(p%2?-1:1)*e[n][h]*ik(e,t-1,u,d,r|f,o),p++)}return o[a]=c,c}function iM(e,t){var n=[[e[0],e[1],1,0,0,0,-t[0]*e[0],-t[0]*e[1]],[0,0,0,e[0],e[1],1,-t[1]*e[0],-t[1]*e[1]],[e[2],e[3],1,0,0,0,-t[2]*e[2],-t[2]*e[3]],[0,0,0,e[2],e[3],1,-t[3]*e[2],-t[3]*e[3]],[e[4],e[5],1,0,0,0,-t[4]*e[4],-t[4]*e[5]],[0,0,0,e[4],e[5],1,-t[5]*e[4],-t[5]*e[5]],[e[6],e[7],1,0,0,0,-t[6]*e[6],-t[6]*e[7]],[0,0,0,e[6],e[7],1,-t[7]*e[6],-t[7]*e[7]]],i={},r=ik(n,8,0,0,0,i);if(0!==r){for(var o=[],a=0;a<8;a++)for(var s=0;s<8;s++)null==o[s]&&(o[s]=0),o[s]+=((a+s)%2?-1:1)*ik(n,7,+(0===a),1<<a,1<<s,i)/r*t[a];return function(e,t,n){var i=t*o[6]+n*o[7]+1;e[0]=(t*o[0]+n*o[1]+o[2])/i,e[1]=(t*o[3]+n*o[4]+o[5])/i}}}var iT="___zrEVENTSAVED",iD=[];function iR(e,t,n,i,r){if(t.getBoundingClientRect&&t1.domSupported&&!iI(t)){var o=t[iT]||(t[iT]={}),a=function(e,t,n){for(var i=n?"invTrans":"trans",r=t[i],o=t.srcCoords,a=[],s=[],l=!0,d=0;d<4;d++){var u=e[d].getBoundingClientRect(),c=2*d,h=u.left,p=u.top;a.push(h,p),l=l&&o&&h===o[c]&&p===o[c+1],s.push(e[d].offsetLeft,e[d].offsetTop)}
422return l&&r?r:(t.srcCoords=a,t[i]=n?iM(s,a):iM(a,s))}(function(e,t){var n=t.markers;if(n)return n;n=t.markers=[];for(var i=["left","right"],r=["top","bottom"],o=0;o<4;o++){var a=document.createElement("div"),s=a.style,l=o%2,d=(o>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[l]+":0",r[d]+":0",i[1-l]+":auto",r[1-d]+":auto",""].join("!important;"),e.appendChild(a),n.push(a)}return n}(t,o),o,r);if(a)return a(e,n,i),!0}return!1}function iI(e){return"CANVAS"===e.nodeName.toUpperCase()}var iA=/([&<>"'])/g,iP={"&":"&","<":"<",">":">",'"':""","'":"'"};function iE(e){return null==e?"":(e+"").replace(iA,function(e,t){return iP[t]})}var iL=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,iF=[],iO=t1.browser.firefox&&39>+t1.browser.version.split(".")[0];function iN(e,t,n,i){return n=n||{},i?iB(e,t,n):iO&&null!=t.layerX&&t.layerX!==t.offsetX?(n.zrX=t.layerX,n.zrY=t.layerY):null!=t.offsetX?(n.zrX=t.offsetX,n.zrY=t.offsetY):iB(e,t,n
vendor: 5,593 bytes, line 422
422),n}function iB(e,t,n){if(t1.domSupported&&e.getBoundingClientRect){var i=t.clientX,r=t.clientY;if(iI(e)){var o=e.getBoundingClientRect();n.zrX=i-o.left,n.zrY=r-o.top;return}if(iR(iF,e,i,r)){n.zrX=iF[0],n.zrY=iF[1];return}}n.zrX=n.zrY=0}function iz(e){return e||window.event}function ij(e,t,n){if(null!=(t=iz(t)).zrX)return t;var i=t.type;if(i&&i.indexOf("touch")>=0){var r="touchend"!==i?t.targetTouches[0]:t.changedTouches[0];r&&iN(e,r,t,n)}else{iN(e,t,t,n);var o=function(e){var t=e.wheelDelta;if(t)return t;var n=e.deltaX,i=e.deltaY;return null==n||null==i?t:3*(0!==i?Math.abs(i):Math.abs(n))*(i>0?-1:i<0?1:n>0?-1:1)}(t);t.zrDelta=o?o/120:-(t.detail||0)/3}var a=t.button;return null==t.which&&void 0!==a&&iL.test(t.type)&&(t.which=1&a?1:2&a?3:4&a?2:0),t}function iV(e,t,n,i){e.addEventListener(t,n,i)}var iH=function(e){e.preventDefault(),e.stopPropagation(),e.cancelBubble=!0};function iG(e){return 2===e.which||3===e.which}var iW=function(){function e(){this._track=[]}return e.prototype.recognize=function(e,t,n){return this._doTrack(e,t,n),this._recognize(e)},e.prototype.clear=function(){return this._track.length=0,this},e.prototype._doTrack=function(e,t,n){var i=e.touches;if(i){for(var r={points:[],touches:[],target:t,event:e},o=0,a=i.length;o<a;o++){var s=i[o],l=iN(n,s,{});r.points.push([l.zrX,l.zrY]),r.touches.push(s)}this._track.push(r)}},e.prototype._recognize=function(e){for(var t in iU)if(iU.hasOwnProperty(t)){var n=iU[t](this._track,e);if(n)return n}},e}();function i$(e){var t=e[1][0]-e[0][0],n=e[1][1]-e[0][1];return Math.sqrt(t*t+n*n)}var iU={pinch:function(e,t){var n=e.length;if(n){var i=(e[n-1]||{}).points,r=(e[n-2]||{}).points||i;if(r&&r.length>1&&i&&i.length>1){var o=i$(i)/i$(r);isFinite(o)||(o=1),t.pinchScale=o;var a=[(i[0][0]+i[1][0])/2,(i[0][1]+i[1][1])/2];return t.pinchX=a[0],t.pinchY=a[1],{type:"pinch",target:e[0].target,event:t}}}}};function iq(){return[1,0,0,1,0,0]}function iK(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function iY(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function iZ(e,t,n){var i=t[0]*n[0]+t[2]*n[1],r=t[1]*n[0]+t[3]*n[1],o=t[0]*n[2]+t[2]*n[3],a=t[1]*n[2]+t[3]*n[3],s=t[0]*n[4]+t[2]*n[5]+t[4],l=t[1]*n[4]+t[3]*n[5]+t[5];return e[0]=i,e[1]=r,e[2]=o,e[3]=a,e[4]=s,e[5]=l,e}function iX(e,t,n){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+n[0],e[5]=t[5]+n[1],e}function iJ(e,t,n,i){void 0===i&&(i=[0,0]);var r=t[0],o=t[2],a=t[4],s=t[1],l=t[3],d=t[5],u=Math.sin(n),c=Math.cos(n);return e[0]=r*c+s*u,e[1]=-r*u+s*c,e[2]=o*c+l*u,e[3]=-o*u+c*l,e[4]=c*(a-i[0])+u*(d-i[1])+i[0],e[5]=c*(d-i[1])-u*(a-i[0])+i[1],e}function iQ(e,t,n){var i=n[0],r=n[1];return e[0]=t[0]*i,e[1]=t[1]*r,e[2]=t[2]*i,e[3]=t[3]*r,e[4]=t[4]*i,e[5]=t[5]*r,e}function i0(e,t){var n=t[0],i=t[2],r=t[4],o=t[1],a=t[3],s=t[5],l=n*a-o*i;return l?(l=1/l,e[0]=a*l,e[1]=-o*l,e[2]=-i*l,e[3]=n*l,e[4]=(i*s-a*r)*l,e[5]=(o*r-n*s)*l,e):null}function i1(e){var t=iq();return iY(t,e),t}e.s(["clone",()=>i1,"copy",()=>iY,"create",()=>iq,"identity",()=>iK,"invert",()=>i0,"mul",()=>iZ,"rotate",()=>iJ,"scale",()=>iQ,"translate",()=>iX],43727);var i2=function(){function e(e,t){this.x=e||0,this.y=t||0}return e.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},e.prototype.clone=function(){return new e(this.x,this.y)},e.prototype.set=function(e,t){return this.x=e,this.y=t,this},e.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},e.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},e.prototype.scale=function(e){this.x*=e,this.y*=e},e.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},e.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},e.prototype.dot=function(e){return this.x*e.x+this.y*e.y},e.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},e.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},e.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},e.prototype.distance=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},e.prototype.distanceSquare=function(e){var t=this.x-e.x,n=this.y-e.y;return t*t+n*n},e.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},e.prototype.transform=function(e){if(e){var t=this.x,n=this.y;return this.x=e[0]*t+e[2]*n+e[4],this.y=e[1]*t+e[3]*n+e[5],this}},e.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},e.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},e.set=function(e,t,n){e.x=t,e.y=n},e.copy=function(e,t){e.x=t.x,e.y=t.y},e.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},e.lenSquare=function(e){return e.x*e.x+e.y*e.y},e.dot=function(e,t){return e.x*t.x+e.y*t.y},e.add=function(e,t,n){e.x=t.x+n.x,e.y=t.y+n.y},e.sub=function(e,t,n){e.x=t.x-n.x,e.y=t.y-n.y},e.scale=function(e,t,n){e.x=t.x*n,e.y=t.y*n},e.scaleAndAdd=function(e,t,n,i){e.x=t.x+n.x*i,e.y=t.y+n.y*i},e.lerp=function(e,t,n,i){var r=1-i;e.x=r*t.x+i*n.x,e.y=r*t.y+i*n.y},e}(),i3=Math.min,i5=Math.max,i4=new i2,i6=new i2,i8=new i2,i7=new i2,i9=new i2,re=new i2,rt=function(){function e(e,t,n,i){n<0&&(e+=n,n=-n),i<0&&(t+=i,i=-i),this.x=e,this.y=t,this.width=n,this.height=i}return e.prototype.union=function(e){var t=i3(e.x,this.x),n=i3(e.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=i5(e.x+e.width,this.x+this.width)-t:this.width=e.width,isFinite(this.y)&&isFinite(this.height)?this.height=i5(e.y+e.height,this.y+this.height)-n:this.height=e.height,this.x=t,this.y=n},e.prototype.applyTransform=function(t){e.applyTransform(this,this,t)},e.prototype.calculateTransform=function(e){var t=e.width/this.width,n=e.he
422ight/this.height,i=iq();return iX(i,i,[-this.x,-this.y]),iQ(i,i,[t,n]),iX(i,i,[e.x,e.y]),i},e.prototype.intersect=function(t,n){if(!t)return!1;t instanceof e||(t=e.create(t));var i=this.x,r=this.x+this.width,o=this.y,a=this.y+this.height,s=t.x,l=t.x+t.width,d=t.y,u=t.y+t.height,c=!(r<s||l<i||a<d||u<o);if(n){var h=1/0,p=0,f=Math.abs(r-s),g=Math.abs(l-i),m=Math.abs(a-d),v=Math.abs(u-o),y=Math.min(f,g),b=Math.min(m,v);r<s||l<i?y>p&&(p=y,f<g?i2.set(re,-f,0):i2.set(re,g,0)):y<h&&(h=y,f<g?i2.set(i9,f,0):i2.set(i9,-g,0)),a<d||u<o?b>p&&(p=b,m<v?i2.set(re,0,-m):i2.set(re,0,v)):y<h&&(h=y,m<v?i2.set(i9,0,m):i2.set(i9,0,-v))}return n&&i2.copy(n,c?i9:re),c},e.prototype.contain=function(e,t){return e>=this.x&&e<=this.x+this.width&&t>=this.y&&t<=this.y+this.height},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.copy=function(t){e.copy(this,t)},e.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},e.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},e.prototype.isZero=function(){return 0===this.width||0===this.height},e.create=function(t){return new e(t.x,t.y,t.width,t.height)},e.copy=function(e,t){e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height},e.applyTransform=function(t,n,i){if(!i){t!==n&&e.copy(t,n);return}if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var r=i[0],o=i[3],a=i[4],s=i[5];t.x=n.x*r+a,t.y=n.y*o+s,t.width=n.width*r,t.height=n.height*o,t.width<0&&(t.x+=t.width,t.width=-t.width),t.height<0&&(t.y+=t.height,t.height=-t.height);return}i4.x=i8.x=n.x,i4.y=i7.y=n.y,i6.x=i7.x=n.x+n.width,i6.y=i8.y=n.y+n.height,i4.transform(i),i7.transform(i),i6.transform(i),i8.transform(i),t.x=i3(i4.x,i6.x,i8.x,i7.x),t.y=i3(i4.y,i6.y,i8.y,i7.y);var l=i5(i4.x,i6.x,i8.x,i7.x),d=i5(i4.y,i6.y,i8.y,i7.y);t.width=l-t.x,t.height=d-t.y},e}(),rn="silent";function ri(){iH(this.event)}var rr=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handler=null,t}return(0,tQ.__extends)(t,e),t.prototype.dispose=function(){},t.prototype.setCursor=function(){},t}(iS),ro=function(e,t){this.x=e,this.y=t},ra=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],rs=new rt(0,0,0,0),rl=function(e){function t(t,n,i,r,o){var a=e.call(this)||this;return a._hovered=new ro(0,0),a.storage=t,a.painter=n,a.painterRoot=r,a._pointerSize=o,i=i||new rr,a.proxy=null,a.setHandlerProxy(i),a._draggingMgr=new iC(a),a}return(0,tQ.__extends)(t,e),t.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(nw(ra,function(t){e.on&&e.on(t,this[t],this)},this),e.handler=this),this.proxy=e},t.prototype.mousemove=function(e){var t=e.zrX,n=e.zrY,i=ru(this,t,n),r=this._hovered,o=r.target;o&&!o.__zr&&(o=(r=this.findHover(r.x,r.y)).target);var a=this._hovered=i?new ro(t,n):this.findHover(t,n),s=a.target,l=this.proxy;l.setCursor&&l.setCursor(s?s.cursor:"default"),o&&s!==o&&this.dispatchToElement(r,"mouseout",e),this.dispatchToElement(a,"mousemove",e),s&&s!==o&&this.dispatchToElement(a,"mouseover",e)},t.prototype.mouseout=function(e){var t=e.zrEventControl;"only_globalout"!==t&&this.dispatchToElement(this._hovered,"mouseout",e),"no_globalout"!==t&&this.trigger("globalout",{type:"globalout",event:e})},t.prototype.resize=function(){this._hovered=new ro(0,0)},t.prototype.dispatch=function(e,t){var n=this[e];n&&n.call(this,t)},t.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},t.prototype.setCursorStyle=function(e){var t=this.proxy;t.setCursor&&t.setCursor(e)},t.prototype.dispatchToElement=function(e,t,n){var i=(e=e||{}).target;if(!i||!i.silent){for(var r,o="on"+t,a={type:t,event:n,target:(r=e).target,topTarget:r.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:ri};i&&(i[o]&&(a.cancelBubble=!!i[o].call(i,a)),i.trigger(t,a),i=i.__hostTarget?i.__hostTarget:i.parent,!a.cancelBubble););!a.cancelBubble&&(this.trigger(t,a),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(e){"function"==typeof e[o]&&e[o].call(e,a),e.trigger&&e.trigger(t,a)}))}},t.prototype.findHover=function(e,t,n){var i=this.storage.getDisplayList(),r=new ro(e,t);if(rd(i,r,e,t,n),this._pointerSize&&!r.target){for(var o=[],a=this._pointerSize,s=a/2,l=ne
422w rt(e-s,t-s,a,a),d=i.length-1;d>=0;d--){var u=i[d];u===n||u.ignore||u.ignoreCoarsePointer||u.parent&&u.parent.ignoreCoarsePointer||(rs.copy(u.getBoundingRect()),u.transform&&rs.applyTransform(u.transform),rs.intersect(l)&&o.push(u))}if(o.length){for(var c=Math.PI/12,h=2*Math.PI,p=0;p<s;p+=4)for(var f=0;f<h;f+=c)if(rd(o,r,e+p*Math.cos(f),t+p*Math.sin(f),n),r.target)return r}}return r},t.prototype.processGesture=function(e,t){this._gestureMgr||(this._gestureMgr=new iW);var n=this._gestureMgr;"start"===t&&n.clear();var i=n.recognize(e,this.findHover(e.zrX,e.zrY,null).target,this.proxy.dom);if("end"===t&&n.clear(),i){var r=i.type;e.gestureEvent=r;var o=new ro;o.target=i.target,this.dispatchToElement(o,r,i.event)}},t}(iS);function rd(e,t,n,i,r){for(var o=e.length-1;o>=0;o--){var a=e[o],s=void 0;if(a!==r&&!a.ignore&&(s=function(e,t,n){if(e[e.rectHover?"rectContain":"contain"](t,n)){for(var i=e,r=void 0,o=!1;i;){if(i.ignoreClip&&(o=!0),!o){var a=i.getClipPath();if(a&&!a.contain(t,n))return!1}i.silent&&(r=!0),i=i.__hostTarget||i.parent}return!r||rn}return!1}(a,n,i))&&(t.topTarget||(t.topTarget=a),s!==rn)){t.target=a;break}}}function ru(e,t,n){var i=e.painter;return t<0||t>i.getWidth()||n<0||n>i.getHeight()}function rc(e,t,n,i){var r=t+1;if(r===n)return 1;if(0>i(e[r++],e[t])){for(;r<n&&0>i(e[r],e[r-1]);)r++;var o=e,a=t,s=r;for(s--;a<s;){var l=o[a];o[a++]=o[s],o[s--]=l}}else for(;r<n&&i(e[r],e[r-1])>=0;)r++;return r-t}function rh(e,t,n,i,r){for(i===t&&i++;i<n;i++){for(var o,a=e[i],s=t,l=i;s<l;)0>r(a,e[o=s+l>>>1])?l=o:s=o+1;var d=i-s;switch(d){case 3:e[s+3]=e[s+2];case 2:e[s+2]=e[s+1];case 1:e[s+1]=e[s];break;default:for(;d>0;)e[s+d]=e[s+d-1],d--}e[s]=a}}function rp(e,t,n,i,r,o){var a=0,s=0,l=1;if(o(e,t[n+r])>0){for(s=i-r;l<s&&o(e,t[n+r+l])>0;)a=l,(l=(l<<1)+1)<=0&&(l=s);l>s&&(l=s),a+=r,l+=r}else{for(s=r+1;l<s&&0>=o(e,t[n+r-l]);)a=l,(l=(l<<1)+1)<=0&&(l=s);l>s&&(l=s);var d=a;a=r-l,l=r-d}for(a++;a<l;){var u=a+(l-a>>>1);o(e,t[n+u])>0?a=u+1:l=u}return l}function rf(e,t,n,i,r,o){var a=0,s=0,l=1;if(0>o(e,t[n+r])){for(s=r+1;l<s&&0>o(e,t[n+r-l]);)a=l,(l=(l<<1)+1)<=0&&(l=s);l>s&&(l=s);var d=a;a=r-l,l=r-d}else{for(s=i-r;l<s&&o(e,t[n+r+l])>=0;)a=l,(l=(l<<1)+1)<=0&&(l=s);l>s&&(l=s),a+=r,l+=r}for(a++;a<l;){var u=a+(l-a>>>1);0>o(e,t[n+u])?l=u:a=u+1}return l}function rg(e,t,n,i){n||(n=0),i||(i=e.length);var r=i-n;if(!(r<2)){var o=0;if(r<32){o=rc(e,n,i,t),rh(e,n,i,n+o,t);return}var a=function(e,t){var n,i,r=7,o=0,a=[];function s(s){var l=n[s],d=i[s],u=n[s+1],c=i[s+1];i[s]=d+c,s===o-3&&(n[s+1]=n[s+2],i[s+1]=i[s+2]),o--;var h=rf(e[u],e,l,d,0,t);l+=h,0==(d-=h)||0!==(c=rp(e[l+d-1],e,u,c,c-1,t))&&(d<=c?function(n,i,o,s){var l,d,u,c=0;for(c=0;c<i;c++)a[c]=e[n+c];var h=0,p=o,f=n;if(e[f++]=e[p++],0==--s){for(c=0;c<i;c++)e[f+c]=a[h+c];return}if(1===i){for(c=0;c<s;c++)e[f+c]=e[p+c];e[f+s]=a[h];return}for(var g=r;;){l=0,d=0,u=!1;do if(0>t(e[p],a[h])){if(e[f++]=e[p++],d++,l=0,0==--s){u=!0;break}}else if(e[f++]=a[h++],l++,d=0,1==--i){u=!0;break}while((l|d)<g)if(u)break;
422do{if(0!==(l=rf(e[p],a,h,i,0,t))){for(c=0;c<l;c++)e[f+c]=a[h+c];if(f+=l,h+=l,(i-=l)<=1){u=!0;break}}if(e[f++]=e[p++],0==--s){u=!0;break}if(0!==(d=rp(a[h],e,p,s,0,t))){for(c=0;c<d;c++)e[f+c]=e[p+c];if(f+=d,p+=d,0==(s-=d)){u=!0;break}}if(e[f++]=a[h++],1==--i){u=!0;break}g--}while(l>=7||d>=7)if(u)break;g<0&&(g=0),g+=2}if((r=g)<1&&(r=1),1===i){for(c=0;c<s;c++)e[f+c]=e[p+c];e[f+s]=a[h]}else if(0===i)throw Error();else for(c=0;c<i;c++)e[f+c]=a[h+c]}(l,d,u,c):function(n,i,o,s){var l=0;for(l=0;l<s;l++)a[l]=e[o+l];var d=n+i-1,u=s-1,c=o+s-1,h=0,p=0;if(e[c--]=e[d--],0==--i){for(l=0,h=c-(s-1);l<s;l++)e[h+l]=a[l];return}if(1===s){for(c-=i,d-=i,p=c+1,h=d+1,l=i-1;l>=0;l--)e[p+l]=e[h+l];e[c]=a[u];return}for(var f=r;;){var g=0,m=0,v=!1;do if(0>t(a[u],e[d])){if(e[c--]=e[d--],g++,m=0,0==--i){v=!0;break}}else if(e[c--]=a[u--],m++,g=0,1==--s){v=!0;break}while((g|m)<f)if(v)break;do{if(0!=(g=i-rf(a[u],e,n,i,i-1,t))){for(c-=g,d-=g,i-=g,p=c+1,h=d+1,l=g-1;l>=0;l--)e[p+l]=e[h+l];if(0===i){v=!0;break}}if(e[c--]=a[u--],1==--s){v=!0;break}if(0!=(m=s-rp(e[d],a,0,s,s-1,t))){for(c-=m,u-=m,s-=m,p=c+1,h=u+1,l=0;l<m;l++)e[p+l]=a[h+l];if(s<=1){v=!0;break}}if(e[c--]=e[d--],0==--i){v=!0;break}f--}while(g>=7||m>=7)if(v)break;f<0&&(f=0),f+=2}if((r=f)<1&&(r=1),1===s){for(c-=i,d-=i,p=c+1,h=d+1,l=i-1;l>=0;l--)e[p+l]=e[h+l];e[c]=a[u]}else if(0===s)throw Error();else for(l=0,h=c-(s-1);l<s;l++)e[h+l]=a[l]}(l,d,u,c))}return n=[],i=[],{mergeRuns:function(){for(;o>1;){var e=o-2;if(e>=1&&i[e-1]<=i[e]+i[e+1]||e>=2&&i[e-2]<=i[e]+i[e-1])i[e-1]<i[e+1]&&e--;else if(i[e]>i[e+1])break;s(e)}},forceMergeRuns:function(){for(;o>1;){var e=o-2;e>0&&i[e-1]<i[e+1]&&e--,s(e)}},pushRun:function(e,t){n[o]=e,i[o]=t,o+=1}}}(e,t),s=function(e){for(var t=0;e>=32;)t|=1&e,e>>=1;return e+t}(r);do{if((o=rc(e,n,i,t))<s){var l=r;l>s&&(l=s),rh(e,n,n+l,n+o,t),o=l}a.pushRun(n,o),a.mergeRuns(),r-=o,n+=o}while(0!==r)a.forceMergeRuns()}}nw(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(e){rl.prototype[e]=function(t){var n,i,r=t.zrX,o=t.zrY,a=ru(this,r,o);if("mouseup"===e&&a||(i=(n=this.findHover(r,o)).target),"mousedown"===e)this._downEl=i,this._downPoint=[t.zrX,t.zrY],this._upEl=i;else if("mouseup"===e)this._upEl=i;else if("click"===e){if(this._downEl!==this._upEl||!this._downPoint||ip(this._downPoint,[t.zrX,t.zrY])>4)return;this._downPoint=null}this.dispatchToElement(n,e,t)}});var rm=!1;function rv(){rm||(rm=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function ry(e,t){return e.zlevel===t.zlevel?e.z===t.z?e.z2-t.z2:e.z-t.z:e.zlevel-t.zlevel}var rb=function(){function e(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=ry}return e.prototype.traverse=function(e,t){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(e,t)},e.prototype.getDisplayList=function(e,t){t=t||!1;var n=this._displayList;return(e||!n.length)&&this.updateDisplayList(t),n},e.prototype.updateDisplayList=function(e){this._displayListLen=0;for(var t=this._roots,n=this._displayList,i=0,r=t.length;i<r;i++)this._updateAndAddDisplayable(t[i],null,e);n.length=this._displayListLen,rg(n,ry)},e.prototype._updateAndAddDisplayable=function(e,t,n){if(!e.ignore||n){e.beforeUpdate(),e.update(),e.afterUpdate();var i=e.getClipPath();if(e.ignoreClip)t=null;else if(i){t=t?t.slice():[];for(var r=i,o=e;r;)r.parent=o,r.updateTransform(),t.push(r),o=r,r=r.getClipPath()}if(e.childrenRef){for(var a=e.childrenRef(),s=0;s<a.length;s++){var l=a[s];e.__dirty&&(l.__dirty|=1),this._updateAndAddDisplayable(l,t,n)}e.__dirty=0}else t&&t.length?e.__clipPaths=t:e.__clipPaths&&e.__clipPaths.length>0&&(e.__clipPaths=[]),isNaN(e.z)&&(rv(),e.z=0),isNaN(e.z2)&&(rv(),e.z2=0),isNaN(e.zlevel)&&(rv(),e.zlevel=0),this._displayList[this._displayListLen++]=e;var d=e.getDecalElement&&e.getDecalElement();d&&this._updateAndAddDisplayable(d,t,n);var u=e.getTextGuideLine();u&&this._updateAndAddDisplayable(u,t,n);var c=e.getTextContent();c&&this._updateAndAddDisplayable(c,t,n)}},e.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},e.prototype.delRoot=function(e){if(e instanceof Array){for(var t=0,n=e.length;t<n;t++)this.delRoot(e[t]);return}var i=nv(this._roots,e);i>=0&&this._roots.splice(i,1)},e.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},e.prototype.getRoots=function(){return this._roots},e.prototype.dispose=function(){this._displayList=null,this._roots=null},e}();y=t1.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(e){return setTimeout(e,16)};var rx={linear:function(e){return e},quadraticIn:function(e){return e*e},quadraticOut:function(e){return e*(2-e)},quadraticInOut:function(e){return(e*=2)<1?.5*e*e:-.5*(--e*(e-2)-1)},cubicIn:function(e){return e*e*e},cubicOut:function(e){return--e*e*e+1},cubicInOut:function(e){return(e*=2)<1?.5*e*e*e:.5*((e-=2)*e*e+2)},quarticIn:function(e){return e*e*e*e},quarticOut:function(e){return 1- --e*e*e*e},quarticInOut:function(e){return(e*=2)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2)},quinticIn:function(e){return e*e*e*e*e},quinticOut:function(e){return--e*e*e*e*e+1},quinticInOut:function(e){return(e*=2)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2)},sinusoidalIn:function(e){return 1-Math.cos(e*Math.PI/2)},sinusoidalOut:function(e){return Math.sin(e*Math.PI/2)},sinusoidalInOut:function(e){return .5*(1-Math.cos(Math.PI*e))},exponentialIn:function(e){return 0===e?0:Math.pow(1024,e-1)},exponentialOut:function(e){return 1===e?1:1-Math.pow(2,-10*e)},exponentialInOut:function(e){return 0===e?0:1===e?1:(e*=2)<1?.5*Math.pow(1024,e-1):.5*(-Math.pow(2,-10*(e-1))+2)},circularIn:function(e){return 1-Math.sqrt(1-e*e)},circularOut:function(e){return Math.sqrt(1- --e*e)},circularInOut:function(e){return(e*=2)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1)},elasticIn:function(e){var t,n=.1;return 0===e?0:1===e?1:(!n||n<1?(n=1,t=.1):t=.4*Math.asin(1/n)/(2*Math.PI),-(n*Math.pow(2,10*(e-=1))*Math.sin(2*Math.PI*(e-t)/.4)))},elasticOut:function(e){var t,n=.1;return 0===e?0:1===e?1:(!n||n<1?(n=1,t=.1):t=.4*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*e)*Math.sin(2*Math.PI*(e-t)/.4)+1)},elasticInOut:function(e){var t,n=.1;return 0===e?0:1===e?1:(!n||n<1?(n=1,t=.1):t=.4*Math.asin(1/n)/(2*Math.PI),(e*=2)<1)?-.5*(n*Math.pow(2,10*(e-=1))*Math.sin(2*Math.PI*(e-t)/.4)):n*Math.pow(2,-10*(e-=1))*Math.sin(2*Math.PI*(e-t)/.4)*.5+1},backIn:function(e){return e*e*(2.70158*e-1.70158)},backOut:function(e){return--e*e*(2.70158*e+1.70158)+1},backInOut:function(e){return(e*=2)<1?e*e*(3.5949095*e-2.5949095)*.5:.5*((e-=2)*e*(3.5949095*e+2.5949095)+2)},bounceIn:function(e){return 1-rx.bounceOut(1-e)},bounceOut:function(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},bounceInOut:function(e){return e<.5?.5*rx.bounceIn(2*e):.5*rx.bounceOut(2*e-1)+.5}},rw=Math.pow,rC=Math.sqrt,rS=rC(3),r_=1/3,rk=n7(),rM=n7(),rT=n7();function rD(e){return e>-1e-8&&e<1e-8}function rR(e){return e>1e-8||e<-1e-8}function rI(e,t,n,i,r){var o=1-r;return o*o*(o*e+3*r*t)+r*r*(r*i+3*o*n)}function rA(e,t,n,i,r){var o=1-r;return 3*(((t-e)*o+2*(n-t)*r)*o+(i-n)*r*r)}
422function rP(e,t,n,i,r,o){var a=i+3*(t-n)-e,s=3*(n-2*t+e),l=3*(t-e),d=e-r,u=s*s-3*a*l,c=s*l-9*a*d,h=l*l-3*s*d,p=0;if(rD(u)&&rD(c))if(rD(s))o[0]=0;else{var f=-l/s;f>=0&&f<=1&&(o[p++]=f)}else{var g=c*c-4*u*h;if(rD(g)){var m=c/u,f=-s/a+m,v=-m/2;f>=0&&f<=1&&(o[p++]=f),v>=0&&v<=1&&(o[p++]=v)}else if(g>0){var y=rC(g),b=u*s+1.5*a*(-c+y),x=u*s+1.5*a*(-c-y),f=(-s-((b=b<0?-rw(-b,r_):rw(b,r_))+(x=x<0?-rw(-x,r_):rw(x,r_))))/(3*a);f>=0&&f<=1&&(o[p++]=f)}else{var w=Math.acos((2*u*s-3*a*c)/(2*rC(u*u*u)))/3,C=rC(u),S=Math.cos(w),f=(-s-2*C*S)/(3*a),v=(-s+C*(S+rS*Math.sin(w)))/(3*a),_=(-s+C*(S-rS*Math.sin(w)))/(3*a);f>=0&&f<=1&&(o[p++]=f),v>=0&&v<=1&&(o[p++]=v),_>=0&&_<=1&&(o[p++]=_)}}return p}function rE(e,t,n,i,r){var o=6*n-12*t+6*e,a=9*t+3*i-3*e-9*n,s=3*t-3*e,l=0;if(rD(a)){if(rR(o)){var d=-s/o;d>=0&&d<=1&&(r[l++]=d)}}else{var u=o*o-4*a*s;if(rD(u))r[0]=-o/(2*a);else if(u>0){var c=rC(u),d=(-o+c)/(2*a),h=(-o-c)/(2*a);d>=0&&d<=1&&(r[l++]=d),h>=0&&h<=1&&(r[l++]=h)}}return l}function rL(e,t,n,i,r,o){var a=(t-e)*r+e,s=(n-t)*r+t,l=(i-n)*r+n,d=(s-a)*r+a,u=(l-s)*r+s,c=(u-d)*r+d;o[0]=e,o[1]=a,o[2]=d,o[3]=c,o[4]=c,o[5]=u,o[6]=l,o[7]=i}function rF(e,t,n,i,r,o,a,s,l,d,u){var c,h,p,f,g,m=.005,v=1/0;rk[0]=l,rk[1]=d;for(var y=0;y<1;y+=.05)rM[0]=rI(e,n,r,a,y),rM[1]=rI(t,i,o,s,y),(f=ig(rk,rM))<v&&(c=y,v=f);v=1/0;for(var b=0;b<32&&!(m<1e-4);b++)h=c-m,p=c+m,rM[0]=rI(e,n,r,a,h),rM[1]=rI(t,i,o,s,h),f=ig(rM,rk),h>=0&&f<v?(c=h,v=f):(rT[0]=rI(e,n,r,a,p),rT[1]=rI(t,i,o,s,p),g=ig(rT,rk),p<=1&&g<v?(c=p,v=g):m*=.5);return u&&(u[0]=rI(e,n,r,a,c),u[1]=rI(t,i,o,s,c)),rC(v)}function rO(e,t,n,i){var r=1-i;return r*(r*e+2*i*t)+i*i*n}function rN(e,t,n,i){return 2*((1-i)*(t-e)+i*(n-t))}function rB(e,t,n){var i=e+n-2*t;return 0===i?.5:(e-t)/i}function rz(e,t,n,i,r){var o=(t-e)*i+e,a=(n-t)*i+t,s=(a-o)*i+o;r[0]=e,r[1]=o,r[2]=s,r[3]=s,r[4]=a,r[5]=n}function rj(e,t,n,i,r,o,a,s,l){var d,u=.005,c=1/0;rk[0]=a,rk[1]=s;for(var h=0;h<1;h+=.05){rM[0]=rO(e,n,r,h),rM[1]=rO(t,i,o,h);var p=ig(rk,rM);p<c&&(d=h,c=p)}c=1/0;for(var f=0;f<32&&!(u<1e-4);f++){var g=d-u,m=d+u;rM[0]=rO(e,n,r,g),rM[1]=rO(t,i,o,g);var p=ig(rM,rk);if(g>=0&&p<c)d=g,c=p;else{rT[0]=rO(e,n,r,m),rT[1]=rO(t,i,o,m);var v=ig(rT,rk);m<=1&&v<c?(d=m,c=v):u*=.5}}return l&&(l[0]=rO(e,n,r,d),l[1]=rO(t,i,o,d)),rC(c)}var rV=/cubic-bezier\(([0-9,\.e ]+)\)/;function rH(e){var t=e&&rV.exec(e);if(t){var n=t[1].split(","),i=+nK(n[0]),r=+nK(n[1]),o=+nK(n[2]),a=+nK(n[3]);if(isNaN(i+r+o+a))return;var s=[];return function(e){return e<=0?0:e>=1?1:rP(0,i,o,1,e,s)&&rI(0,r,a,1,s[0])}}}var rG=function(){function e(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||n6,this.ondestroy=e.ondestroy||n6,this.onrestart=e.onrestart||n6,e.easing&&this.setEasing(e.easing)}return e.prototype.step=function(e,t){if(this._inited||(this._startTime=e+this._delay,this._inited=!0),this._paused){this._pausedTime+=t;return}var n=this._life,i=e-this._startTime-this._pausedTime,r=i/n;r<0&&(r=0),r=Math.min(r,1);var o=this.easingFunc,a=o?o(r):r;if(this.onframe(a),1===r)if(!this.loop)return!0;else this._startTime=e-i%n,this._pausedTime=0,this.onrestart();return!1},e.prototype.pause=function(){this._paused=!0},e.prototype.resume=function(){this._paused=!1},e.prototype.setEasing=function(e){this.easing=e,this.easingFunc=nI(e)?e:rx[e]||rH(e)},e}(),rW=function(e){this.value=e},r$=function(){function e(){this._len=0}return e.prototype.insert=function(e){var t=new rW(e);return this.insertEntry(t),t},e.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},e.prototype.remove=function(e){var t=e.prev,n=e.next;t?t.next=n:this.head=n,n?n.prev=t:this.tail=t,e.next=e.prev=null,this._len--},e.prototype.len=function(){return this._len},e.prototype.clear=function(){this.head=this.tail=null,this._len=0},e}(),rU=function(){function e(e){this._list=new r$,this._maxSize=10,this._map={},this._maxSize=e}return e.prototype.put=function(e,t){var n=this._list,i=this._map,r=null;if(null==i[e]){var o=n.len(),a=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var s=n.head;n.remove(s),delete i[s.key],r=s.value,this._lastRemovedEntry=s}a?a.value=t:a=new rW(t),a.key=e,n.insertEntry(a),i[e]=a}return r},e.prototype.get=function(e){var t=this._map[e],n=this._list;if(null!=t)return t!==n.tail&&(n.remove(t),n.insertEntry(t)),t.value},e.prototype.clear=function(){this._list.clear(),this._map={}},e.prototype.len=function(){return this._list.len()},e}(),rq={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function rK(e){return(e=Math.round(e))<0?0:e>255?255:e}function rY(e){return e<0?0:e>1?1:e}function rZ(e){return e.length&&"%"===e.charAt(e.length-1)?rK(parseFloat(e)/100*255):rK(parseInt(e,10))}function rX(e){return e.length&&"%"===e.charAt(e.length-1)?rY(parseFloat(e)/100):rY(parseFloat(e))}function rJ(e,t,n){return(n<0?n+=1:n>1&&(n-=1),6*n<1)?e+(t-e)*n*6:2*n<1?t:3*n<2?e+(t-e)*(2/3-n)*6:e}function rQ(e,t,n,i,r){return e[0]=t,e[1]=n,e[2]=i,e[3]=r,e}function r0(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}var r1=new rU(20),r2=null;function r3(e,t){r2&&r0(r2,t),r2=r1.put(e,r2||t.slice())}function r5(e,t){if(e){t=t||[];var n=r1.get(e);if(n)return r0(t,n);var i=(e+="").replace(/ /g,"").toLowerCase();if(i in rq)return r0(t,rq[i]),r3(e,t),t;var r=i.length;if("#"===i.charAt(0)){if(4===r||5===r){var o=parseInt(i.slice(1,4),16);return o>=0&&o<=4095?(rQ(t,(3840&o)>>4|(3840&o)>>8,240&o|(240&o)>>4,15&o|(15&o)<<4,5===r?parseInt(i.slice(4),16)/15:1),r3(e,t),t):void rQ(t,0,0,0,1)}if(7===r||9===r){var o=parseInt(i.slice(1,7),16);return o>=0&&o<=0xffffff?(rQ(t,(0xff0000&o)>>16,(65280&o)>>8,255&o,9===r?parseInt(i.slice(7),16)/255:1),r3(e,t),t):void rQ(t,0,0,0,1)}return}var a=i.indexOf("("),s=i.indexOf(")");if(-1!==a&&s+1===r){var l=i.substr(0,a),d=i.substr(a+1,s-(a+1)).split(","),u=1;switch(l){case"rgba":if(4!==d.length)return 3===d.length?rQ(t,+d[0],+d[1],+d[2],1):rQ(t,0,0,0,1);u=rX(d.pop());case"rgb":if(d.length>=3)return rQ(t,rZ(d[0]),rZ(d[1]),rZ(d[2]),3===d.length?u:rX(d[3])),r3(e,t),t;return void rQ(t,0,0,0,1);case"hsla":if(4!==d.length)return void rQ(t,0,0,0,1);return d[3]=rX(d[3]),r4(d,t),r3(e,t),t;case"hsl":if(3!==d.length)return void rQ(t,0,0,0,1);return r4(d,t),r3(e,t),t;default:return}}rQ(t,0,0,0,1)}}function r4(e,t){var n=(parseFloat(e[0])%360+360)%360/360,i=rX(e[1]),r=rX(e[2]),o=r<=.5?r*(i+1):r+i-r*i,a=2*r-o;return rQ(t=t||[],rK(255*rJ(a,o,n+1/3)),rK(255*rJ(a,o,n)),rK(255*rJ(a,o,n-1/3)),1),4===e.length&&(t[3]=e[3]),t}function r6(e,t){var n=r5(e);if(n){for(var i=0;i<3;i++)t<0?n[i]=n[i]*(1-t)|0:n[i]=(255-n[i])*t+n[i]|0,n[i]>255?n[i]=255:n[i]<0&&(n[i]=0);return on(n,4===n.length?"rgba":"rgb")}}function r8(e){var t=r5(e);if(t)return(0x1000000+(t[0]<<16)+(t[1]<<8)+ +t[2]).toString(16).slice(1)}function r7(e,t,n){if(t&&t.length&&e>=0&&e<=1){n=n||[];var i,r,o,a,s=e*(t.length-1),l=Math.floor(s),d=Math.ceil(s),u=t[l],c=t[d],h=s-l;return n[0]=rK((i=u[0],i+(c[0]-i)*h)),n[1]=rK((r=u[1],r+(c[1]-r)*h)),n[2]=rK((o=u[2],o+(c[2]-o)*h)),n[3]=rY((a=u[3],a+(c[3]-a)*h)),n}}function r9(e,t,n){if(t&&t.length&&e>=0&&e<=1){var i,r,o,a,s=e*(t.length-1),l=Math.floor(s),d=Math.ceil(s),u=r5(t[l]),c=r5(t[d]),h=s-l,p=on([rK((i=u[0],i+(c[0]-i)*h)),rK((r=u[1],r+(c[1]-r)*h)),rK((o=u[2],o+(c[2]-o)*h)),rY((a=u[3],a+(c[3]-a)*h))],"rgba");return n?{color:p,leftIndex:l,rightIndex:d,value:s}:p}}function oe(e,t,n,i){var r,o=r5(e);if(e)return o=function(e){if(e){var t,n,i=e[0]/255,r=e[1]/255,o=e[2]/255,a=Math.min(i,r,o),s=Math.max(i,r,o),l=s-a,d=(s+a)/2;if(0===l)t=0,n=0;else{n=d<.5?l/(s+a):l/(2-s-a);var u=((s-i)/6+l/2)/l,c=((s-r)/6+l/2)/l,h=((s-o)/6+l/2)/l;i===s?t=h-c:r===s?t=1/3+u-h:o===s&&(t=2/3+c-u),t<0&&(t+=1),t>1&&(t-=1)}var p=[360*t,n,d];return null!=e[3]&&p.push(e[3]),p}}(o),null!=t&&(o[0]=(r=Math.round(r=t))<0?0:r>360?360:r),null!=n&&(o[1]=rX(n)),null!=i&&(o[2]=rX(i)),on(r4(o),"rgba")}function ot(e,t){var n=r5(e);if(n&&null!=t)return n[3]=rY(t),on(n,"rgba")}function on(e,t){if(e&&e.length){var n=e[0]+","+e[1]+","+e[2];return("rgba"===t||"hsva"===t||"hsla"===t)&&(n+=","+e[3]),t+"("+n+")"}}function oi(e,t){var n=r5(e);return n?(.299*n[0]+.587*n[1]+.114*n[2])*n[3]/255+(1-n[3])*t:0}function or(){return on([Math.round(255*Math.random()),Math.round(255*Math.random()),Math.round(255*Math.random())],"rgb")}var oo=new rU(100);function oa(e){if(nA(e)){var t=oo.get(e);return t||(t=r6(e,-.1),oo.put(e,t)),t}if(nB(e)){var n=nf({},e);return n.colorStops=nC(e.colorStops,function(e){return{offset:e.offset,color:r6(e.color,-.1)}}),n}return e}e.s(["fastLerp",()=>r7,"fastMapToColor",()=>r7,"lerp",()=>r9,"lift",()=>r6,"liftColor",()=>oa,"lum",()=>oi,"mapToColor",()=>r9,"modifyAlpha",()=>ot,"modifyHSL",()=>oe,"parse",()=>r5,"random",()=>or,"stringify",()=>on,"toHex",()=>r8],40224);var ol=e.i(78113),od=Math.round;function ou(e){var t;if(e&&"transparent"!==e){if("string"==typeof e&&e.indexOf("rgba")>-1){var n=r5(e);n&&(e="rgb("+n[0]+","+n[1]+","+n[2]+")",t=n[3])}}else e="none";return{color:e,opacity:null==t?1:t}}function oc(e){return e<1e-4&&e>-1e-4}function oh(e){return od(1e3*e)/1e3}function op(e){return od(1e4*e)/1e4}var of={left:"start",right:"end",center:"middle",middle:"middle"};function og(e){return e&&!!e.image}function om(e){return og(e)||e&&!!e.svgElement}function ov(e){return"linear"===e.type}function oy(e){return"radial"===e.type}function ob(e){return e&&("linear"===e.type||"radial"===e.type)}
422function ox(e){return"url(#"+e+")"}function ow(e){var t=e.getGlobalScale();return Math.max(Math.ceil(Math.log(Math.max(t[0],t[1]))/Math.log(10)),1)}function oC(e){var t=e.x||0,n=e.y||0,i=(e.rotation||0)*n8,r=nG(e.scaleX,1),o=nG(e.scaleY,1),a=e.skewX||0,s=e.skewY||0,l=[];return(t||n)&&l.push("translate("+t+"px,"+n+"px)"),i&&l.push("rotate("+i+")"),(1!==r||1!==o)&&l.push("scale("+r+","+o+")"),(a||s)&&l.push("skew("+od(a*n8)+"deg, "+od(s*n8)+"deg)"),l.join(" ")}var oS=t1.hasGlobalWindow&&nI(window.btoa)?function(e){return window.btoa(unescape(encodeURIComponent(e)))}:void 0!==ol.Buffer?function(e){return ol.Buffer.from(e).toString("base64")}:function(e){return null},o_=Array.prototype.slice;function ok(e,t,n,i){for(var r,o=t.length,a=0;a<o;a++)e[a]=(r=t[a],(n[a]-r)*i+r);return e}function oM(e,t,n,i){for(var r=t.length,o=0;o<r;o++)e[o]=t[o]+n[o]*i;return e}function oT(e,t,n,i){for(var r=t.length,o=r&&t[0].length,a=0;a<r;a++){e[a]||(e[a]=[]);for(var s=0;s<o;s++)e[a][s]=t[a][s]+n[a][s]*i}return e}function oD(e){if(nx(e)){var t=e.length;if(nx(e[0])){for(var n=[],i=0;i<t;i++)n.push(o_.call(e[i]));return n}return o_.call(e)}return e}function oR(e){return e[0]=Math.floor(e[0])||0,e[1]=Math.floor(e[1])||0,e[2]=Math.floor(e[2])||0,e[3]=null==e[3]?1:e[3],"rgba("+e.join(",")+")"}function oI(e){return 4===e||5===e}function oA(e){return 1===e||2===e}var oP=[0,0,0,0],oE=function(){function e(e){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=e}return e.prototype.isFinished=function(){return this._finished},e.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},e.prototype.needsAnimate=function(){return this.keyframes.length>=1},e.prototype.getAdditiveTrack=function(){return this._additiveTrack},e.prototype.addKeyframe=function(e,t,n){this._needsSort=!0;var i=this.keyframes,r=i.length,o=!1,a=6,s=t;if(nx(t)){var l=nx(t&&t[0])?2:1;a=l,(1!==l||nE(t[0]))&&(2!==l||nE(t[0][0]))||(o=!0)}else if(nE(t)&&t==t)a=0;else if(nA(t))if(isNaN(+t)){var d=r5(t);d&&(s=d,a=3)}else a=0;else if(nB(t)){var u=nf({},s);u.colorStops=nC(t.colorStops,function(e){return{offset:e.offset,color:r5(e.color)}}),ov(t)?a=4:oy(t)&&(a=5),s=u}0===r?this.valType=a:(a!==this.valType||6===a)&&(o=!0),this.discrete=this.discrete||o;var c={time:e,value:s,rawValue:t,percent:0};return n&&(c.easing=n,c.easingFunc=nI(n)?n:rx[n]||rH(n)),i.push(c),c},e.prototype.prepare=function(e,t){var n=this.keyframes;this._needsSort&&n.sort(function(e,t){return e.time-t.time});for(var i=this.valType,r=n.length,o=n[r-1],a=this.discrete,s=oA(i),l=oI(i),d=0;d<r;d++){var u=n[d],c=u.value,h=o.value;u.percent=u.time/e,!a&&(s&&d!==r-1?function(e,t,n){if(e.push&&t.push){var i=e.length,r=t.length;if(i!==r)if(i>r)e.length=r;else for(var o=i;o<r;o++)e.push(1===n?t[o]:o_.call(t[o]));for(var a=e[0]&&e[0].length,o=0;o<e.length;o++)if(1===n)isNaN(e[o])&&(e[o]=t[o]);else for(var s=0;s<a;s++)isNaN(e[o][s])&&(e[o][s]=t[o][s])}}(c,h,i):l&&function(e,t){for(var n=e.length,i=t.length,r=n>i?t:e,o=Math.min(n,i),a=r[o-1]||{color:[0,0,0,0],offset:0},s=o;s<Math.max(n,i);s++)r.push({offset:a.offset,color:a.color.slice()})}(c.colorStops,h.colorStops))}if(!a&&5!==i&&t&&this.needsAnimate()&&t.needsAnimate()&&i===t.valType&&!t._finished){this._additiveTrack=t;for(var p=n[0].value,d=0;d<r;d++)0===i?n[d].additiveValue=n[d].value-p:3===i?n[d].additiveValue=oM([],n[d].value,p,-1):oA(i)&&(n[d].additiveValue=1===i?oM([],n[d].value,p,-1):oT([],n[d].value,p,-1))}},e.prototype.step=function(e,t){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n,i,r,o=null!=this._additiveTrack,a=o?"additiveValue":"value",s=this.valType,l=this.keyframes,d=l.length,u=this.propName,c=3===s,h=this._lastFr,p=Math.min;if(1===d)i=r=l[0];else{if(t<0)n=0;else if(t<this._lastFrP){for(n=p(h+1,d-1);n>=0&&!(l[n].percent<=t);n--);n=p(n,d-2)}else{for(n=h;n<d&&!(l[n].percent>t);n++);n=p(n-1,d-2)}r=l[n+1],i=l[n]}if(i&&r){this._lastFr=n,this._lastFrP=t;var f=r.percent-i.percent,g=0===f?1:p((t-i.percent)/f,1);r.easingFunc&&(g=r.easingFunc(g));var m=o?this._additiveValue:c?oP:e[u];if((oA(s)||c)&&!m&&(m=this._additiveValue=[]),this.discrete)e[u]=g<1?i.rawValue:r.rawValue;else if(oA(s))1===s?ok(m,i[a],r[a],g):function(e,t,n,i){for(var r=t.length,o=r&&t[0].length,a=0;a<r;a++){e[a]||(e[a]=[]);for(var s,l=0;l<o;l++)e[a][l]=(s=t[a][l],(n[a][l]-s)*i+s)}}(m,i[a],r[a],g);else if(oI(s)){var v,y,b,x,w,C=i[a],S=r[a],_=4===s;(e[u]={type:_?"linear":"radial",x:(v=C.x,(S.x-v)*g+v),y:(y=C.y,(S.y-y)*g+y),colorStops:nC(C.colorStops,function(e,t){var n,i=S.colorStops[t];return{offset:(n=e.offset,(i.offset-n)*g+n),color:oR(ok([],e.color,i.color,g))}}),global:S.global},_)?(e[u].x2=(b=C.x2,(S.x2-b)*g+b),e[u].y2=(x=C.y2,(S.y2-x)*g+x)):e[u].r=(w=C.r,(S.r-w)*g+w)}else if(c)ok(m,i[a],r[a],g),o||(e[u]=oR(m));else{var k,M=(k=i[a],(r[a]-k)*g+k);o?this._additiveValue=M:e[u]=M}o&&this._addToTarget(e)}}},e.prototype._addToTarget=function(e){var t=this.valType,n=this.propName,i=this._additiveValue;0===t?e[n]=e[n]+i:3===t?(r5(e[n],oP),oM(oP,oP,i,1),e[n]=oR(oP)):1===t?oM(e[n],e[n],i,1):2===t&&oT(e[n],e[n],i,1)},e}(),oL=function(){function e(e,t,n,i){(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=e,this._loop=t,t&&i)?nu("Can' use additive animation on looped animation."):(this._additiveAnimators=i,this._allowDiscrete=n)}return e.prototype.getMaxTime=function(){return this._maxTime},e.prototype.getDelay=function(){return this._delay},e.prototype.getLoop=function(){return this._loop},e.prototype.getTarget=function(){return this._target},e.prototype.changeTarget=function(e){this._target=e},e.prototype.when=function(e,t,n){return this.whenWithKeys(e,t,nM(t),n)},e.prototype.whenWithKeys=function(e,t,n,i){for(var r=this._tracks,o=0;o<n.length;o++){var a=n[o],s=r[a];if(!s){s=r[a]=new oE(a);var l=void 0,d=this._getAdditiveTrack(a);if(d){var u=d.keyframes,c=u[u.length-1];l=c&&c.value,3===d.valType&&l&&(l=oR(l))}else l=this._target[a];if(null==l)continue;e>0&&s.addKeyframe(0,oD(l),i),this._trackKeys.push(a)}s.addKeyframe(e,oD(t[a]),i)}return this._maxTime=Math.max(this._maxTime,e),this},e.prototype.pause=function(){this._clip.pause(),this._paused=!0},e.prototype.resume=function(){this._clip.resume(),this._paused=!1},e.prototype.isPaused=function(){return!!this._paused},e.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},e.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var e=this._doneCbs;if(e)for(var t=e.length,n=0;n<t;n++)e[n].call(this)},e.prototype._abortedCallback=function(){this._setTracksFinished();var e=this.animation,t=this._abortedCbs;if(e&&e.removeClip(this._clip),this._clip=null,t)for(var n=0;n<t.length;n++)t[n].call(this)},e.prototype._setTracksFinished=function(){for(var e=this._tracks,t=this._trackKeys,n=0;n<t.length;n++)e[t[n]].setFinished()},e.prototype._getAdditiveTrack=function(e){var t,n=this._additiveAnimators;if(n)for(var i=0;i<n.length;i++){var r=n[i].getTrack(e);r&&(t=r)}return t},e.prototype.start=function(e){if(!(this._started>0)){this._started=1;
422for(var t=this,n=[],i=this._maxTime||0,r=0;r<this._trackKeys.length;r++){var o=this._trackKeys[r],a=this._tracks[o],s=this._getAdditiveTrack(o),l=a.keyframes,d=l.length;if(a.prepare(i,s),a.needsAnimate())if(!this._allowDiscrete&&a.discrete){var u=l[d-1];u&&(t._target[a.propName]=u.rawValue),a.setFinished()}else n.push(a)}if(n.length||this._force){var c=new rG({life:i,loop:this._loop,delay:this._delay||0,onframe:function(e){t._started=2;var i=t._additiveAnimators;if(i){for(var r=!1,o=0;o<i.length;o++)if(i[o]._clip){r=!0;break}r||(t._additiveAnimators=null)}for(var o=0;o<n.length;o++)n[o].step(t._target,e);var a=t._onframeCbs;if(a)for(var o=0;o<a.length;o++)a[o](t._target,e)},ondestroy:function(){t._doneCallback()}});this._clip=c,this.animation&&this.animation.addClip(c),e&&c.setEasing(e)}else this._doneCallback();return this}},e.prototype.stop=function(e){if(this._clip){var t=this._clip;e&&t.onframe(1),this._abortedCallback()}},e.prototype.delay=function(e){return this._delay=e,this},e.prototype.during=function(e){return e&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(e)),this},e.prototype.done=function(e){return e&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(e)),this},e.prototype.aborted=function(e){return e&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(e)),this},e.prototype.getClip=function(){return this._clip},e.prototype.getTrack=function(e){return this._tracks[e]},e.prototype.getTracks=function(){var e=this;return nC(this._trackKeys,function(t){return e._tracks[t]})},e.prototype.stopTracks=function(e,t){if(!e.length||!this._clip)return!0;for(var n=this._tracks,i=this._trackKeys,r=0;r<e.length;r++){var o=n[e[r]];o&&!o.isFinished()&&(t?o.step(this._target,1):1===this._started&&o.step(this._target,0),o.setFinished())}for(var a=!0,r=0;r<i.length;r++)if(!n[i[r]].isFinished()){a=!1;break}return a&&this._abortedCallback(),a},e.prototype.saveTo=function(e,t,n){if(e){t=t||this._trackKeys;for(var i=0;i<t.length;i++){var r=t[i],o=this._tracks[r];if(!(!o||o.isFinished())){var a=o.keyframes,s=a[n?0:a.length-1];s&&(e[r]=oD(s.rawValue))}}}},e.prototype.__changeFinalValue=function(e,t){t=t||nM(e);for(var n=0;n<t.length;n++){var i=t[n],r=this._tracks[i];if(r){var o=r.keyframes;if(o.length>1){var a=o.pop();r.addKeyframe(a.time,e[i]),r.prepare(this._maxTime,r.getAdditiveTrack())}}}},e}();function oF(){return new Date().getTime()}var oO=function(e){function t(t){var n=e.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,n.stage=(t=t||{}).stage||{},n}return(0,tQ.__extends)(t,e),t.prototype.addClip=function(e){e.animation&&this.removeClip(e),this._head?(this._tail.next=e,e.prev=this._tail,e.next=null,this._tail=e):this._head=this._tail=e,e.animation=this},t.prototype.addAnimator=function(e){e.animation=this;var t=e.getClip();t&&this.addClip(t)},t.prototype.removeClip=function(e){if(e.animation){var t=e.prev,n=e.next;t?t.next=n:this._head=n,n?n.prev=t:this._tail=t,e.next=e.prev=e.animation=null}},t.prototype.removeAnimator=function(e){var t=e.getClip();t&&this.removeClip(t),e.animation=null},t.prototype.update=function(e){for(var t=oF()-this._pausedTime,n=t-this._time,i=this._head;i;){var r=i.next;i.step(t,n)&&(i.ondestroy(),this.removeClip(i)),i=r}this._time=t,!e&&(this.trigger("frame",n),this.stage.update&&this.stage.update())},t.prototype._startLoop=function(){var e=this;this._running=!0,y(function t(){e._running&&(y(t),e._paused||e.update())})},t.prototype.start=function(){this._running||(this._time=oF(),this._pausedTime=0,this._startLoop())},t.prototype.stop=function(){this._running=!1},t.prototype.pause=function(){this._paused||(this._pauseStart=oF(),this._paused=!0)},t.prototype.resume=function(){this._paused&&(this._pausedTime+=oF()-this._pauseStart,this._paused=!1)},t.prototype.clear=function(){for(var e=this._head;e;){var t=e.next;e.prev=e.next=e.animation=null,e=t}this._head=this._tail=null},t.prototype.isFinished=function(){return null==this._head},t.prototype.animate=function(e,t){t=t||{},this.start();var n=new oL(e,t.loop);return this.addAnimator(n),n},t}(iS),oN=t1.domSupported,oB=(h={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},p=nC(c=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],function(e){var t=e.replace("mouse","pointer");return h.hasOwnProperty(t)?t:e}),{mouse:c,touch:["touchstart","touchend","touchmove"],pointer:p}),oz=["mousemove","mouseup"],oj=["pointermove","pointerup"],oV=!1;function oH(e){var t=e.pointerType;return"pen"===t||"touch"===t}function oG(e){e&&(e.zrByTouch=!0)}function oW(e,t){for(var n=t,i=!1;n&&9!==n.nodeType&&!(i=n.domBelongToZr||n!==t&&n===e.painterRoot);)n=n.parentNode;return i}var o$=function(e,t){this.stopPropagation=n6,this.stopImmediatePropagation=n6,this.preventDefault=n6,this.type=t.type,this.target=this.currentTarget=e.dom,this.pointerType=t.pointerType,this.clientX=t.clientX,this.clientY=t.clientY},oU={mousedown:function(e){e=ij(this.dom,e),this.__mayPointerCapture=[e.zrX,e.zrY],this.trigger("mousedown",e)},mousemove:function(e){e=ij(this.dom,e);var t=this.__mayPointerCapture;t&&(e.zrX!==t[0]||e.zrY!==t[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",e)},mouseup:function(e){e=ij(this.dom,e),this.__togglePointerCapture(!1),this.trigger("mouseup",e)},mouseout:function(e){oW(this,(e=ij(this.dom,e)).toElement||e.relatedTarget)||(this.__pointerCapturing&&(e.zrEventC
422ontrol="no_globalout"),this.trigger("mouseout",e))},wheel:function(e){oV=!0,e=ij(this.dom,e),this.trigger("mousewheel",e)},mousewheel:function(e){oV||(e=ij(this.dom,e),this.trigger("mousewheel",e))},touchstart:function(e){oG(e=ij(this.dom,e)),this.__lastTouchMoment=new Date,this.handler.processGesture(e,"start"),oU.mousemove.call(this,e),oU.mousedown.call(this,e)},touchmove:function(e){oG(e=ij(this.dom,e)),this.handler.processGesture(e,"change"),oU.mousemove.call(this,e)},touchend:function(e){oG(e=ij(this.dom,e)),this.handler.processGesture(e,"end"),oU.mouseup.call(this,e),new Date-this.__lastTouchMoment<300&&oU.click.call(this,e)},pointerdown:function(e){oU.mousedown.call(this,e)},pointermove:function(e){oH(e)||oU.mousemove.call(this,e)},pointerup:function(e){oU.mouseup.call(this,e)},pointerout:function(e){oH(e)||oU.mouseout.call(this,e)}};nw(["click","dblclick","contextmenu"],function(e){oU[e]=function(t){t=ij(this.dom,t),this.trigger(e,t)}});var oq={pointermove:function(e){oH(e)||oq.mousemove.call(this,e)},pointerup:function(e){oq.mouseup.call(this,e)},mousemove:function(e){this.trigger("mousemove",e)},mouseup:function(e){var t=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",e),t&&(e.zrEventControl="only_globalout",this.trigger("mouseout",e))}};function oK(e,t,n,i){e.mounted[t]=n,e.listenerOpts[t]=i,iV(e.domTarget,t,n,i)}function oY(e){var t,n,i,r=e.mounted;for(var o in r)r.hasOwnProperty(o)&&(t=e.domTarget,n=r[o],i=e.listenerOpts[o],t.removeEventListener(o,n,i));e.mounted={}}var oZ=function(e,t){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=e,this.domHandlers=t},oX=function(e){function t(t,n){var i,r,o=e.call(this)||this;return o.__pointerCapturing=!1,o.dom=t,o.painterRoot=n,o._localHandlerScope=new oZ(t,oU),oN&&(o._globalHandlerScope=new oZ(document,oq)),r=(i=o._localHandlerScope).domHandlers,t1.pointerEventsSupported?nw(oB.pointer,function(e){oK(i,e,function(t){r[e].call(o,t)})}):(t1.touchEventsSupported&&nw(oB.touch,function(e){oK(i,e,function(t){r[e].call(o,t),i.touching=!0,null!=i.touchTimer&&(clearTimeout(i.touchTimer),i.touchTimer=null),i.touchTimer=setTimeout(function(){i.touching=!1,i.touchTimer=null},700)})}),nw(oB.mouse,function(e){oK(i,e,function(t){t=iz(t),i.touching||r[e].call(o,t)})})),o}return(0,tQ.__extends)(t,e),t.prototype.dispose=function(){oY(this._localHandlerScope),oN&&oY(this._globalHandlerScope)},t.prototype.setCursor=function(e){this.dom.style&&(this.dom.style.cursor=e||"default")},t.prototype.__togglePointerCapture=function(e){if(this.__mayPointerCapture=null,oN&&this.__pointerCapturing^e){this.__pointerCapturing=e;var t=this._globalHandlerScope;e?function(e,t){t1.pointerEventsSupported?nw(oj,n):t1.touchEventsSupported||nw(oz,n);function n(n){oK(t,n,function(i){if(!oW(e,(i=iz(i)).target)){var r;r=i,i=ij(e.dom,new o$(e,r),!0),t.domHandlers[n].call(e,i)}},{capture:!0})}}(this,t):oY(t)}},t}(iS),oJ=1;t1.hasGlobalWindow&&(oJ=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var oQ=oJ,o0="#333",o1="#ccc";function o2(e){return e>5e-5||e<-5e-5}var o3=[],o5=[],o4=iq(),o6=Math.abs,o8=function(){var e;function t(){}return t.prototype.getLocalTransform=function(e){return t.getLocalTransform(this,e)},t.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},t.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},t.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},t.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},t.prototype.needLocalTransform=function(){return o2(this.rotation)||o2(this.x)||o2(this.y)||o2(this.scaleX-1)||o2(this.scaleY-1)||o2(this.skewX)||o2(this.skewY)},t.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),n=this.transform;if(!(t||e)){n&&(iK(n),this.invTransform=null);return}n=n||iq(),t?this.getLocalTransform(n):iK(n),e&&(t?iZ(n,e,n):iY(n,e)),this.transform=n,this._resolveGlobalScaleRatio(n)},t.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(null!=t&&1!==t){this.getGlobalScale(o3);var n=o3[0]<0?-1:1,i=o3[1]<0?-1:1,r=((o3[0]-n)*t+n)/o3[0]||0,o=((o3[1]-i)*t+i)/o3[1]||0;e[0]*=r,e[1]*=r,e[2]*=o,e[3]*=o}this.invTransform=this.invTransform||iq(),i0(this.invTransform,e)},t.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},t.prototype.setLocalTransform=function(e){if(e){var t=e[0]*e[0]+e[1]*e[1],n=e[2]*e[2]+e[3]*e[3],i=Math.atan2(e[1],e[0]),r=Math.PI/2+i-Math.atan2(e[3],e[2]);
422n=Math.sqrt(n)*Math.cos(r),t=Math.sqrt(t),this.skewX=r,this.skewY=0,this.rotation=-i,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=n,this.originX=0,this.originY=0}},t.prototype.decomposeTransform=function(){if(this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(e.invTransform=e.invTransform||iq(),iZ(o5,e.invTransform,t),t=o5);var n=this.originX,i=this.originY;(n||i)&&(o4[4]=n,o4[5]=i,iZ(o5,t,o4),o5[4]-=n,o5[5]-=i,t=o5),this.setLocalTransform(t)}},t.prototype.getGlobalScale=function(e){var t=this.transform;return(e=e||[],t)?(e[0]=Math.sqrt(t[0]*t[0]+t[1]*t[1]),e[1]=Math.sqrt(t[2]*t[2]+t[3]*t[3]),t[0]<0&&(e[0]=-e[0]),t[3]<0&&(e[1]=-e[1])):(e[0]=1,e[1]=1),e},t.prototype.transformCoordToLocal=function(e,t){var n=[e,t],i=this.invTransform;return i&&iy(n,n,i),n},t.prototype.transformCoordToGlobal=function(e,t){var n=[e,t],i=this.transform;return i&&iy(n,n,i),n},t.prototype.getLineScale=function(){var e=this.transform;return e&&o6(e[0]-1)>1e-10&&o6(e[3]-1)>1e-10?Math.sqrt(o6(e[0]*e[3]-e[2]*e[1])):1},t.prototype.copyTransform=function(e){o9(this,e)},t.getLocalTransform=function(e,t){t=t||[];var n=e.originX||0,i=e.originY||0,r=e.scaleX,o=e.scaleY,a=e.anchorX,s=e.anchorY,l=e.rotation||0,d=e.x,u=e.y,c=e.skewX?Math.tan(e.skewX):0,h=e.skewY?Math.tan(-e.skewY):0;if(n||i||a||s){var p=n+a,f=i+s;t[4]=-p*r-c*f*o,t[5]=-f*o-h*p*r}else t[4]=t[5]=0;return t[0]=r,t[3]=o,t[1]=h*r,t[2]=c*o,l&&iJ(t,t,l),t[4]+=n+d,t[5]+=i+u,t},t.initDefaultProps=void((e=t.prototype).scaleX=e.scaleY=e.globalScaleRatio=1,e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0),t}(),o7=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function o9(e,t){for(var n=0;n<o7.length;n++){var i=o7[n];e[i]=t[i]}}var ae={};function at(e,t){var n=ae[t=t||t3];n||(n=ae[t]=new rU(500));var i=n.get(e);return null==i&&(i=t4.measureText(e,t).width,n.put(e,i)),i}function an(e,t,n,i){var r=at(e,t),o=aa(t);return new rt(ar(0,r,n),ao(0,o,i),r,o)}function ai(e,t,n,i){var r=((e||"")+"").split("\n");if(1===r.length)return an(r[0],t,n,i);for(var o=new rt(0,0,0,0),a=0;a<r.length;a++){var s=an(r[a],t,n,i);0===a?o.copy(s):o.union(s)}return o}function ar(e,t,n){return"right"===n?e-=t:"center"===n&&(e-=t/2),e}function ao(e,t,n){return"middle"===n?e-=t/2:"bottom"===n&&(e-=t),e}function aa(e){return at("å½",e)}function as(e,t){return"string"==typeof e?e.lastIndexOf("%")>=0?parseFloat(e)/100*t:parseFloat(e):e}function al(e,t,n){var i=t.position||"inside",r=null!=t.distance?t.distance:5,o=n.height,a=n.width,s=o/2,l=n.x,d=n.y,u="left",c="top";if(i instanceof Array)l+=as(i[0],n.width),d+=as(i[1],n.height),u=null,c=null;else switch(i){case"left":l-=r,d+=s,u="right",c="middle";break;case"right":l+=r+a,d+=s,c="middle";break;case"top":l+=a/2,d-=r,u="center",c="bottom";break;case"bottom":l+=a/2,d+=o+r,u="center";break;case"inside":l+=a/2,d+=s,u="center",c="middle";break;case"insideLeft":l+=r,d+=s,c="middle";break;case"insideRight":l+=a-r,d+=s,u="right",c="middle";break;case"insideTop":l+=a/2,d+=r,u="center";break;case"insideBottom":l+=a/2,d+=o-r,u="center",c="bottom";break;case"insideTopLeft":l+=r,d+=r;break;case"insideTopRight":l+=a-r,d+=r,u="right";break;case"insideBottomLeft":l+=r,d+=o-r,c="bottom";break;case"insideBottomRight":l+=a-r,d+=o-r,u="right",c="bottom"}return(e=e||{}).x=l,e.y=d,e.align=u,e.verticalAlign=c,e}var ad="__zr_normal__",au=o7.concat(["ignore"]),ac=nS(o7,function(e,t){return e[t]=!0,e},{ignore:!1}),ah={},ap=new rt(0,0,0,0),af=function(){function e(e){this.id=nd(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return e.prototype._init=function(e){this.attr(e)},e.prototype.drift=function(e,t,n){switch(this.draggable){case"horizontal":t=0;break;case"vertical":e=0}var i=this.transform;i||(i=this.transform=[1,0,0,1,0,0]),i[4]+=e,i[5]+=t,this.decomposeTransform(),this.markRedraw()},e.prototype.beforeUpdate=function(){},e.prototype.afterUpdate=function(){},e.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},e.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||(this.textConfig={});var n=this.textConfig,i=n.local,r=t.innerTransformable,o=void 0,a=void 0,s=!1;r.parent=i?this:null;var l=!1;if(r.copyTransform(t),null!=n.position){n.layoutRect?ap.copy(n.layoutRect):ap.copy(this.getBoundingRect
vendor: 10,695 bytes, line 422
422()),i||ap.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(ah,n,ap):al(ah,n,ap),r.x=ah.x,r.y=ah.y,o=ah.align,a=ah.verticalAlign;var d=n.origin;if(d&&null!=n.rotation){var u=void 0,c=void 0;"center"===d?(u=.5*ap.width,c=.5*ap.height):(u=as(d[0],ap.width),c=as(d[1],ap.height)),l=!0,r.originX=-r.x+u+(i?0:ap.x),r.originY=-r.y+c+(i?0:ap.y)}}null!=n.rotation&&(r.rotation=n.rotation);var h=n.offset;h&&(r.x+=h[0],r.y+=h[1],l||(r.originX=-h[0],r.originY=-h[1]));var p=null==n.inside?"string"==typeof n.position&&n.position.indexOf("inside")>=0:n.inside,f=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),g=void 0,m=void 0,v=void 0;p&&this.canBeInsideText()?(g=n.insideFill,m=n.insideStroke,(null==g||"auto"===g)&&(g=this.getInsideTextFill()),(null==m||"auto"===m)&&(m=this.getInsideTextStroke(g),v=!0)):(g=n.outsideFill,m=n.outsideStroke,(null==g||"auto"===g)&&(g=this.getOutsideFill()),(null==m||"auto"===m)&&(m=this.getOutsideStroke(g),v=!0)),((g=g||"#000")!==f.fill||m!==f.stroke||v!==f.autoStroke||o!==f.align||a!==f.verticalAlign)&&(s=!0,f.fill=g,f.stroke=m,f.autoStroke=v,f.align=o,f.verticalAlign=a,t.setDefaultTextStyle(f)),t.__dirty|=1,s&&t.dirtyStyle(!0)}},e.prototype.canBeInsideText=function(){return!0},e.prototype.getInsideTextFill=function(){return"#fff"},e.prototype.getInsideTextStroke=function(e){return"#000"},e.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?o1:o0},e.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),n="string"==typeof t&&r5(t);n||(n=[255,255,255,1]);for(var i=n[3],r=this.__zr.isDarkMode(),o=0;o<3;o++)n[o]=n[o]*i+255*!r*(1-i);return n[3]=1,on(n,"rgba")},e.prototype.traverse=function(e,t){},e.prototype.attrKV=function(e,t){"textConfig"===e?this.setTextConfig(t):"textContent"===e?this.setTextContent(t):"clipPath"===e?this.setClipPath(t):"extra"===e?(this.extra=this.extra||{},nf(this.extra,t)):this[e]=t},e.prototype.hide=function(){this.ignore=!0,this.markRedraw()},e.prototype.show=function(){this.ignore=!1,this.markRedraw()},e.prototype.attr=function(e,t){if("string"==typeof e)this.attrKV(e,t);else if(nL(e))for(var n=nM(e),i=0;i<n.length;i++){var r=n[i];this.attrKV(r,e[r])}return this.markRedraw(),this},e.prototype.saveCurrentToNormalState=function(e){this._innerSaveToNormal(e);for(var t=this._normalState,n=0;n<this.animators.length;n++){var i=this.animators[n],r=i.__fromStateTransition;if(!i.getLoop()&&(!r||r===ad)){var o=i.targetName,a=o?t[o]:t;i.saveTo(a)}}},e.prototype._innerSaveToNormal=function(e){var t=this._normalState;t||(t=this._normalState={}),e.textConfig&&!t.textConfig&&(t.textConfig=this.textConfig),this._savePrimaryToNormal(e,t,au)},e.prototype._savePrimaryToNormal=function(e,t,n){for(var i=0;i<n.length;i++){var r=n[i];null==e[r]||r in t||(t[r]=this[r])}},e.prototype.hasState=function(){return this.currentStates.length>0},e.prototype.getState=function(e){return this.states[e]},e.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},e.prototype.clearStates=function(e){this.useState(ad,!1,e)},e.prototype.useState=function(e,t,n,i){var r,o=e===ad;if(this.hasState()||!o){var a=this.currentStates,s=this.stateTransition;if(!(nv(a,e)>=0)||!t&&1!==a.length){if(this.stateProxy&&!o&&(r=this.stateProxy(e)),r||(r=this.states&&this.states[e]),!r&&!o)return void nu("State "+e+" not exists.");o||this.saveCurrentToNormalState(r);var l=!!(r&&r.hoverLayer||i);l&&this._toggleHoverLayerFlag(!0),this._applyStateObj(e,r,this._normalState,t,!n&&!this.__inHover&&s&&s.duration>0,s);var d=this._textContent,u=this._textGuide;return d&&d.useState(e,t,n,l),u&&u.useState(e,t,n,l),o?(this.currentStates=[],this._normalState={}):t?this.currentStates.push(e):this.currentStates=[e],this._updateAnimationTargets(),this.markRedraw(),!l&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=-2),r}}},e.prototype.useStates=function(e,t,n){if(e.length){var i=[],r=this.currentStates,o=e.length,a=o===r.length;if(a){for(var s=0;s<o;s++)if(e[s]!==r[s]){a=!1;break}}if(!a){for(var s=0;s<o;s++){var l=e[s],d=void 0;this.stateProxy&&(d=this.stateProxy(l,e)),d||(d=this.states[l]),d&&i.push(d)}var u=i[o-1],c=!!(u&&u.hoverLayer||n);c&&this._toggleHoverLayerFlag(!0);var h=this._mergeStates(i),p=this.stateTransition;this.saveCurrentToNormalState(h),this._applyStateObj(e.join(","),h,this._normalState,!1,!t&&!this.__inHover&&p&&p.duration>0,p);var f=this._textContent,g=this._textGuide;f&&f.useStates(e,t,c),g&&g.useStates(e,t,c),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=-2)}}else this.clearStates()},e.prototype.isSilent=function(){for(var e=this.silent,t=this.parent;!e&&t;){if(t.silent){e=!0;break}t=t.parent}return e},e.prototype._updateAnimationTargets=function(){for(var e=0;e<this.animators.length;e++){var t=this.animators[e];t.targetName&&t.changeTarget(this[t.targetName])}},e.prototype.removeState=function(e){var t=nv(this.currentStates,e);if(t>=0){var n=this.currentStates.slice();n.splice(t,1),this.useStates(n)}},e.prototype.replaceState=function(e,t,n){var i=this.currentStates.slice(),r=nv(i,e),o=nv(i,t)>=0;r>=0?o?i.splice(r,1):i[r]=t:n&&!o&&i.push(t),this.useStates(i)},e.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},e.prototype._mergeStates=function(e){for(var t,n={},i=0;i<e.length;i++){var r=e[i];nf(n,r),r.textConfig&&nf(t=t||{},r.textConfig)}return t&&(n.textConfig=t),n},e.prototype._applyStateObj=function(e,t,n,i,r,o){var a=!(t&&i);t&&t.textConfig?(this.textConfig=nf({},i?this.textConfig:n.textConfig),nf(this.textConfig,t.textConfig)):a&&n.textConfig&&(this.textConfig=n.textConfig);for(var s={},l=!1,d=0;d<au.length;d++){var u=au[d],c=r&&ac[u];t&&null!=t[u]?c?(l=!0,s[u]=t[u]):this[u]=t[u]:a&&null!=n[u]&&(c?(l=!0,s[u]=n[u]):this[u]=n[u])}if(!r)for(var d=0;d<this.animators.length;d++){var h=this.animators[d],p=h.targetName;h.getLoop()||h.__changeFinalValue(p?(t||n)[p]:t||n)}l&&this._transitionState(e,s,o)},e.prototype._attachComponent=function(e){if((!e.__zr||e.__hostTarget)&&e!==this){var t=this.__zr;t&&e.addSelfToZr(t),e.__zr=t,e.__hostTarget=this}},e.prototype._detachComponent=function(e){e.__zr&&e.removeSelfFromZr(e.__zr),e.__zr=null,e.__hostTarget=null},e.prototype.getClipPath=function(){return this._clipPath},e.prototype.setClipPath=function(e){this._clipPath&&this._clipPath!==e&&this.removeClipPath(),this._attachComponent(e),this._clipPath=e,this.markRedraw()},e.prototype.removeClipPath=function(){var e=this._clipPath;e&&(this._detachComponent(e),this._clipPath=null,this.markRedraw())},e.prototype.getTextContent=function(){return this._textContent},e.prototype.setTextContent=function(e){var t=this._textContent;t!==e&&(t&&t!==e&&this.removeTextContent(),e.innerTransformable=new o8,this._attachComponent(e),this._textContent=e,this.markRedraw())},e.prototype.setTextConfig=function(e){this.textConfig||(this.textConfig={}),nf(this.textConfig,e),this.markRedraw()},e.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},e.prototype.removeTextContent=function(){var e=this._textContent;e&&(e.innerTransformable=null,this._detachComponent(e),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},e.prototype.getTextGuideLine=function(){return this._textGuide},e.prototype.setTextGuideLine=function(e){this._textGuide&&this._textGuide!==e&&this.removeTextGuideLine(),this._attachComponent(e),this._textGuide=e,this.markRedraw()},e.prototype.removeTextGuideLine=function(){var e=this._textGuide;e&&(this._detachComponent(e),this._textGuide=null,this.markRedraw())},e.prototype.markRedraw=function(){this.__dirty|=1;var e=this.__zr;e&&(this.__inHover?e.refreshHover():e.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},e.prototype.dirty=function(){this.markRedraw()},e.prototype._toggleHoverLayerFlag=function(e){this.__inHover=e;var t=this._textContent,n=this._textGuide;t&&(t.__inHover=e),n&&(n.__inHover=e)},e.prototype.addSelfToZr=function(e){if(this.__zr!==e){this.__zr=e;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.addAnimator(t[n]);this._clipPath&&this._clipPath.addSelfToZr(e),this._textContent&&this._textContent.addSelfToZr(e),this._textGuide&&this._textGuide.addSelfToZr(e)}},e.prototype.removeSelfFromZr=function(e){if(this.__zr){this.__zr=null;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.removeAnimator(t[n]);this._clipPath&&this._clipPath.removeSelfFromZr(e),this._textContent&&this._textContent.removeSelfFromZr(e),this._textGuide&&this._textGuide.removeSelfFromZr(e)}},e.prototype.animate=function(e,t,n){var i=new oL(e?this[e]:this,t,n);return e&&(i.targetName=e),this.addAnimator(i,e),i},e.prototype.addAnimator=function(e,t){var n=this.__zr,i=this;e.during(function(){i.updateDuringAnimation(t)}).done(function(){var t=i.animators,n=nv(t,e);n>=0&&t.splice(n,1)}),this.animators.push(e),n&&n.animation.addAnimator(e),n&&n.wakeUp()},e.prototype.updateDuringAnimation=function(e){this.markRedraw()},e.prototype.stopAnimation=function(e,t){for(var n=this.animators,i=n.length,r=[],o=0;o<i;o++){var a=n[o];e&&e!==a.scope?r.push(a):a.stop(t)}return this.animators=r,this},e.prototype.animateTo=function(e,t,n){ag(this,e,t,n)},e.prototype.animateFrom=function(e,t,n){ag(this,e,t,n,!0)},e.prototype._transitionState=function(e,t,n,i){for(var r=ag(this,t,n,i),o=0;o<r.length;o++)r[o].__fromStateTransition=e},e.prototype.getBoundingRect=function(){return null},e.prototype.getPaintRect=function(){return null},e.initDefaultProps=function(){var t=e.prototype;function n(e,n,i,r){Object.defineProperty(t,e,{get:function(){return this[n]||o(this,this[n]=[]),this[n]},set:function(e){this[i]=e[0],this[r]=e[1],this[n]=e,o(this,e)}});function o(e,t){Object.defineProperty(t,0,{get:function(){return e[i]},set:function(t){e[i]=t}}),Object.defineProperty(t,1,{get:function(){return e[r]},set:function(t){e[r]=t}})}}t.type="element",t.name="",t.ignore=t.silent=t.isGroup=t.draggable=t.dragging=t.ignoreClip=t.__inHover=!1,t.__dirty=1,Object.defineProperty&&(n("position","_legacyPos","x","y"),n("scale","_legacyScale","scaleX","scaleY"),n("origin","_legacyOrigin","originX","originY"))}(),e}();function ag(e,t,n,i,r){var o=[];!function e(t,n,i,r,o,a,s,l){for(var d=nM(r),u=o.duration,c=o.delay,h=o.additive,p=o.setToFinal,f=!nL(a),g=t.animators,m=[],v=0;v<d.length;v++){var y=d[v],b=r[y];if(null!=b&&null!=i[y]&&(f||a[y]))if(!nL(b)||nx(b)||nB(b))m.push(y);else{if(n){l||(i[y]=b,t.updateDuringAnimation(n));continue}e(t,y,i[y],b,o,a&&a[y],s,l)}else l||(i[y]=b,t.updateDuringAnimation(n),m.push(y))}var x=m.length;
422if(!h&&x)for(var w=0;w<g.length;w++){var C=g[w];if(C.targetName===n&&C.stopTracks(m)){var S=nv(g,C);g.splice(S,1)}}if(o.force||(x=(m=n_(m,function(e){var t,n;return!((t=r[e])===(n=i[e])||nx(t)&&nx(n)&&function(e,t){var n=e.length;if(n!==t.length)return!1;for(var i=0;i<n;i++)if(e[i]!==t[i])return!1;return!0}(t,n))})).length),x>0||o.force&&!s.length){var _=void 0,k=void 0,M=void 0;if(l){k={},p&&(_={});for(var w=0;w<x;w++){var y=m[w];k[y]=i[y],p?_[y]=r[y]:i[y]=r[y]}}else if(p){M={};for(var w=0;w<x;w++){var y=m[w];M[y]=oD(i[y]),function(e,t,n){if(nx(t[n]))if(nx(e[n])||(e[n]=[]),nO(t[n])){var i=t[n].length;e[n].length!==i&&(e[n]=new t[n].constructor(i),am(e[n],t[n],i))}else{var r=t[n],o=e[n],a=r.length;if(nx(r[0]))for(var s=r[0].length,l=0;l<a;l++)o[l]?am(o[l],r[l],s):o[l]=Array.prototype.slice.call(r[l]);else am(o,r,a);o.length=r.length}else e[n]=t[n]}(i,r,y)}}var C=new oL(i,!1,!1,h?n_(g,function(e){return e.targetName===n}):null);C.targetName=n,o.scope&&(C.scope=o.scope),p&&_&&C.whenWithKeys(0,_,m),M&&C.whenWithKeys(0,M,m),C.whenWithKeys(null==u?500:u,l?k:r,m).delay(c||0),t.addAnimator(C,n),s.push(C)}}(e,"",e,t,n=n||{},i,o,r);var a=o.length,s=!1,l=n.done,d=n.aborted,u=function(){s=!0,--a<=0&&(s?l&&l():d&&d())},c=function(){--a<=0&&(s?l&&l():d&&d())};!a&&l&&l(),o.length>0&&n.during&&o[0].during(function(e,t){n.during(t)});for(var h=0;h<o.length;h++){var p=o[h];p.done(u),p.aborted(c),n.force&&p.duration(n.duration),p.start(n.easing)}return o}function am(e,t,n){for(var i=0;i<n;i++)e[i]=t[i]}nb(af,iS),nb(af,o8);var av=function(e){function t(t){var n=e.call(this)||this;return n.isGroup=!0,n._children=[],n.attr(t),n}return(0,tQ.__extends)(t,e),t.prototype.childrenRef=function(){return this._children},t.prototype.children=function(){return this._children.slice()},t.prototype.childAt=function(e){return this._children[e]},t.prototype.childOfName=function(e){for(var t=this._children,n=0;n<t.length;n++)if(t[n].name===e)return t[n]},t.prototype.childCount=function(){return this._children.length},t.prototype.add=function(e){return e&&e!==this&&e.parent!==this&&(this._children.push(e),this._doAdd(e)),this},t.prototype.addBefore=function(e,t){if(e&&e!==this&&e.parent!==this&&t&&t.parent===this){var n=this._children,i=n.indexOf(t);i>=0&&(n.splice(i,0,e),this._doAdd(e))}return this},t.prototype.replace=function(e,t){var n=nv(this._children,e);return n>=0&&this.replaceAt(t,n),this},t.prototype.replaceAt=function(e,t){var n=this._children,i=n[t];if(e&&e!==this&&e.parent!==this&&e!==i){n[t]=e,i.parent=null;var r=this.__zr;r&&i.removeSelfFromZr(r),this._doAdd(e)}return this},t.prototype._doAdd=function(e){e.parent&&e.parent.remove(e),e.parent=this;var t=this.__zr;t&&t!==e.__zr&&e.addSelfToZr(t),t&&t.refresh()},t.prototype.remove=function(e){var t=this.__zr,n=this._children,i=nv(n,e);return i<0||(n.splice(i,1),e.parent=null,t&&e.removeSelfFromZr(t),t&&t.refresh()),this},t.prototype.removeAll=function(){for(var e=this._children,t=this.__zr,n=0;n<e.length;n++){var i=e[n];t&&i.removeSelfFromZr(t),i.parent=null}return e.length=0,this},t.prototype.eachChild=function(e,t){for(var n=this._children,i=0;i<n.length;i++){var r=n[i];e.call(t,r,i)}return this},t.prototype.traverse=function(e,t){for(var n=0;n<this._children.length;n++){var i=this._children[n],r=e.call(t,i);i.isGroup&&!r&&i.traverse(e,t)}return this},t.prototype.addSelfToZr=function(t){e.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].addSelfToZr(t)},t.prototype.removeSelfFromZr=function(t){e.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].removeSelfFromZr(t)},t.prototype.getBoundingRect=function(e){for(var t=new rt(0,0,0,0),n=e||this._children,i=[],r=null,o=0;o<n.length;o++){var a=n[o];if(!a.ignore&&!a.invisible){var s=a.getBoundingRect(),l=a.getLocalTransform(i);l?(rt.applyTransform(t,s,l),(r=r||t.clone()).union(t)):(r=r||s.clone()).union(s)}}return r||t},t}(af);av.prototype.type="group";var ay={},ab={},ax=function(){function e(e,t,n){var i,r=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,n=n||{},this.dom=t,this.id=e;var o=new rb,a=n.renderer||"canvas";ay[a]||(a=nM(ay)[0]),n.useDirtyRect=null!=n.useDirtyRect&&n.useDirtyRect;var s=new ay[a](t,o,n,e),l=n.ssr||s.ssrOnly;this.storage=o,this.painter=s;var d=t1.node||t1.worker||l?null:new oX(s.getViewportRoot(),s.root),u=n.useCo
422arsePointer;(null==u||"auto"===u?t1.touchEventsSupported:!!u)&&(i=nG(n.pointerSize,44)),this.handler=new rl(o,s,d,s.root,i),this.animation=new oO({stage:{update:l?null:function(){return r._flush(!0)}}}),l||this.animation.start()}return e.prototype.add=function(e){!this._disposed&&e&&(this.storage.addRoot(e),e.addSelfToZr(this),this.refresh())},e.prototype.remove=function(e){!this._disposed&&e&&(this.storage.delRoot(e),e.removeSelfFromZr(this),this.refresh())},e.prototype.configLayer=function(e,t){this._disposed||(this.painter.configLayer&&this.painter.configLayer(e,t),this.refresh())},e.prototype.setBackgroundColor=function(e){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(e),this.refresh(),this._backgroundColor=e,this._darkMode=function(e){if(!e)return!1;if("string"==typeof e)return .4>oi(e,1);if(e.colorStops){for(var t=e.colorStops,n=0,i=t.length,r=0;r<i;r++)n+=oi(t[r].color,1);return(n/=i)<.4}return!1}(e))},e.prototype.getBackgroundColor=function(){return this._backgroundColor},e.prototype.setDarkMode=function(e){this._darkMode=e},e.prototype.isDarkMode=function(){return this._darkMode},e.prototype.refreshImmediately=function(e){this._disposed||(e||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1)},e.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},e.prototype.flush=function(){this._disposed||this._flush(!1)},e.prototype._flush=function(e){var t,n=oF();this._needsRefresh&&(t=!0,this.refreshImmediately(e)),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately());var i=oF();t?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:i-n})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},e.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},e.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},e.prototype.refreshHover=function(){this._needsRefreshHover=!0},e.prototype.refreshHoverImmediately=function(){!this._disposed&&(this._needsRefreshHover=!1,this.painter.refreshHover&&"canvas"===this.painter.getType()&&this.painter.refreshHover())},e.prototype.resize=function(e){this._disposed||(e=e||{},this.painter.resize(e.width,e.height),this.handler.resize())},e.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},e.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},e.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},e.prototype.setCursorStyle=function(e){this._disposed||this.handler.setCursorStyle(e)},e.prototype.findHover=function(e,t){if(!this._disposed)return this.handler.findHover(e,t)},e.prototype.on=function(e,t,n){return this._disposed||this.handler.on(e,t,n),this},e.prototype.off=function(e,t){this._disposed||this.handler.off(e,t)},e.prototype.trigger=function(e,t){this._disposed||this.handler.trigger(e,t)},e.prototype.clear=function(){if(!this._disposed){for(var e=this.storage.getRoots(),t=0;t<e.length;t++)e[t]instanceof av&&e[t].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},e.prototype.dispose=function(){if(!this._disposed){var e;this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,e=this.id,delete ab[e]}},e}();function aw(e,t){var n=new ax(nd(),e,t);return ab[n.id]=n,n}function aC(e){e.dispose()}function aS(){for(var e in ab)ab.hasOwnProperty(e)&&ab[e].dispose();ab={}}function a_(e){return ab[e]}function ak(e,t){ay[e]=t}function aM(e){if("function"==typeof b)return b(e)}function aT(e){b=e}function aD(e,t,n,i){var r=t[0],o=t[1],a=n[0],s=n[1],l=o-r,d=s-a;if(0===l)return 0===d?a:(a+s)/2;if(i){if(l>0){if(e<=r)return a;else if(e>=o)return s}else if(e>=r)return a;else if(e<=o)return s}else{if(e===r)return a;
422if(e===o)return s}return(e-r)/l*d+a}function aR(e,t){switch(e){case"center":case"middle":e="50%";break;case"left":case"top":e="0%";break;case"right":case"bottom":e="100%"}return nA(e)?e.replace(/^\s+|\s+$/g,"").match(/%$/)?parseFloat(e)/100*t:parseFloat(e):null==e?NaN:+e}function aI(e,t,n){return null==t&&(t=10),t=Math.min(Math.max(0,t),20),e=(+e).toFixed(t),n?e:+e}function aA(e){return e.sort(function(e,t){return e-t}),e}function aP(e){if(isNaN(e*=1))return 0;if(e>1e-14){for(var t=1,n=0;n<15;n++,t*=10)if(Math.round(e*t)/t===e)return n}return aE(e)}function aE(e){var t=e.toString().toLowerCase(),n=t.indexOf("e"),i=n>0?+t.slice(n+1):0,r=n>0?n:t.length,o=t.indexOf(".");return Math.max(0,(o<0?0:r-1-o)-i)}function aL(e,t){var n=Math.log,i=Math.LN10,r=Math.min(Math.max(-Math.floor(n(e[1]-e[0])/i)+Math.round(n(Math.abs(t[1]-t[0]))/i),0),20);return isFinite(r)?r:20}function aF(e,t,n){return e[t]&&aO(e,n)[t]||0}function aO(e,t){var n=nS(e,function(e,t){return e+(isNaN(t)?0:t)},0);if(0===n)return[];for(var i=Math.pow(10,t),r=nC(e,function(e){return(isNaN(e)?0:e)/n*i*100}),o=100*i,a=nC(r,function(e){return Math.floor(e)}),s=nS(a,function(e,t){return e+t},0),l=nC(r,function(e,t){return e-a[t]});s<o;){for(var d=-1/0,u=null,c=0,h=l.length;c<h;++c)l[c]>d&&(d=l[c],u=c);++a[u],l[u]=0,++s}return nC(a,function(e){return e/i})}function aN(e){var t=2*Math.PI;return(e%t+t)%t}function aB(e){return e>-1e-4&&e<1e-4}e.s(["dispose",()=>aC,"disposeAll",()=>aS,"getElementSSRData",()=>aM,"getInstance",()=>a_,"init",()=>aw,"registerPainter",()=>ak,"registerSSRDataGetter",()=>aT,"version",()=>"5.6.1"],65119);var az=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function aj(e){if(e instanceof Date)return e;if(nA(e)){var t=az.exec(e);if(!t)return new Date(NaN);if(!t[8])return new Date(+t[1],(t[2]||1)-1,+t[3]||1,+t[4]||0,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0);var n=+t[4]||0;return"Z"!==t[8].toUpperCase()&&(n-=t[8].slice(0,3)),new Date(Date.UTC(+t[1],(t[2]||1)-1,+t[3]||1,n,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0))}return null==e?new Date(NaN):new Date(Math.round(e))}function aV(e){return Math.pow(10,aH(e))}function aH(e){if(0===e)return 0;var t=Math.floor(Math.log(e)/Math.LN10);return e/Math.pow(10,t)>=10&&t++,t}function aG(e,t){var n=aH(e),i=Math.pow(10,n),r=e/i;return e=(t?r<1.5?1:r<2.5?2:r<4?3:r<7?5:10:r<1?1:r<2?2:r<3?3:r<5?5:10)*i,n>=-20?+e.toFixed(n<0?-n:0):e}function aW(e,t){var n=(e.length-1)*t+1,i=Math.floor(n),r=+e[i-1],o=n-i;return o?r+o*(e[i]-r):r}function a$(e){e.sort(function(e,t){return!function e(t,n,i){return t.interval[i]<n.interval[i]||t.interval[i]===n.interval[i]&&(t.close[i]-n.close[i]==(i?-1:1)||!i&&e(t,n,1))}(e,t,0)?1:-1});for(var t=-1/0,n=1,i=0;i<e.length;){for(var r=e[i].interval,o=e[i].close,a=0;a<2;a++)r[a]<=t&&(r[a]=t,o[a]=a?1:1-n),t=r[a],n=o[a];r[0]===r[1]&&o[0]*o[1]!=1?e.splice(i,1):i++}return e}function aU(e){var t=parseFloat(e);return t==e&&(0!==t||!nA(e)||0>=e.indexOf("x"))?t:NaN}function aq(e){return!isNaN(aU(e))}function aK(){return Math.round(9*Math.random())}function aY(e,t){return null==e?t:null==t?e:e*t/function e(t,n){return 0===n?t:e(n,t%n)}(e,t)}var aZ="series\0",aX="\0_ec_\0";function aJ(e){return e instanceof Array?e:null==e?[]:[e]}function aQ(e,t,n){if(e){e[t]=e[t]||{},e.emphasis=e.emphasis||{},e.emphasis[t]=e.emphasis[t]||{};for(var i=0,r=n.length;i<r;i++){var o=n[i];!e.emphasis[t].hasOwnProperty(o)&&e[t].hasOwnProperty(o)&&(e.emphasis[t][o]=e[t][o])}}}var a0=["fontStyle","fontWeight","fontSize","fontFamily","rich","tag","color","textBorderColor","textBorderWidth","width","height","lineHeight","align","verticalAlign","baseline","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY","backgroundColor","borderColor","borderWidth","borderRadius","padding"];function a1(e){return!nL(e)||nR(e)||e instanceof Date?e:e.value}function a2(e,t,n){var i,r,o,a,s,l,d,u,c,h,p,f,g="normalMerge"===n,m="replaceMerge"===n,v="replaceAll"===n;e=e||[],t=(t||[]).slice();var y=n1();nw(t,function(e,n){if(!nL(e)){t[n]=null;return}});var b=function(e,t,n){var i=[];if("replaceAll"===n)return i;for(var r=0;r<e.length;r++){var o=e[r];o&&null!=o.id&&t.set(o.id,r),i.push({existing:"replaceMerge"===n||a8(o)?null:o,newOption:null,keyInfo:null,brandNew:null})}return i}(e,y,n);return(g||m)&&(i=b,r=e,o=y,nw(a=t,function(e,t){if(e&&null!=e.id){var n=a5(e.id),s=o.get(n);if(null!=s){var l=i[s];nq(!l.newOption,'Duplicated option on id "'+n+'".'),l.newOption=e,l.existing=r[s],a[t]=null}}})),g&&(s=b,nw(l=t,function(e,t){if(e&&null!=e.name)for(var n=0;n<s.length;n++){var i=s[n].existing;if(!s[n].newOption&&i&&(null==i.id||null==e.id)&&!a8(e)&&!a8(i)&&a3("name",i,e)){s[n].newOption=e,l[t]=null;return}}})),g||m?(d=b,u=t,c=m,nw(u,function(e){if(e){for(var t,n=0;(t=d[n])&&(t.newOption||a8(t.existing)||t.existing&&null!=e.id&&!a3("id",e,t.existing));)n++;t?(t.newOption=e,t.brandNew=c):d.push({newOption:e,brandNew:c,existing:null,keyInfo:null}),n++}})):v&&(h=b,nw(t,function(e){h.push({newOption:e,brandNew:!0,existing:null,keyInfo:null})})),p=b,f=n1(),nw(p,function(e){var t=e.existing;
422t&&f.set(t.id,e)}),nw(p,function(e){var t=e.newOption;nq(!t||null==t.id||!f.get(t.id)||f.get(t.id)===e,"id duplicates: "+(t&&t.id)),t&&null!=t.id&&f.set(t.id,e),e.keyInfo||(e.keyInfo={})}),nw(p,function(e,t){var n=e.existing,i=e.newOption,r=e.keyInfo;if(nL(i)){if(r.name=null!=i.name?a5(i.name):n?n.name:aZ+t,n)r.id=a5(n.id);else if(null!=i.id)r.id=a5(i.id);else{var o=0;do r.id="\0"+r.name+"\0"+o++;while(f.get(r.id))}f.set(r.id,e)}}),b}function a3(e,t,n){var i=a4(t[e],null),r=a4(n[e],null);return null!=i&&null!=r&&i===r}function a5(e){return a4(e,"")}function a4(e,t){return null==e?t:nA(e)?e:nE(e)||nP(e)?e+"":t}function a6(e){var t=e.name;return!!(t&&t.indexOf(aZ))}function a8(e){return e&&null!=e.id&&0===a5(e.id).indexOf(aX)}function a7(e,t){return null!=t.dataIndexInside?t.dataIndexInside:null!=t.dataIndex?nR(t.dataIndex)?nC(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex):null!=t.name?nR(t.name)?nC(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name):void 0}function a9(){var e="__ec_inner_"+se++;return function(t){return t[e]||(t[e]={})}}var se=aK();function st(e,t,n){var i=sn(t,n),r=i.mainTypeSpecified,o=i.queryOptionMap,a=i.others,s=n?n.defaultMainType:null;return!r&&s&&o.set(s,{}),o.each(function(t,i){var r=so(e,i,t,{useDefault:s===i,enableAll:!n||null==n.enableAll||n.enableAll,enableNone:!n||null==n.enableNone||n.enableNone});a[i+"Models"]=r.models,a[i+"Model"]=r.models[0]}),a}function sn(e,t){if(nA(e)){var n,i={};i[e+"Index"]=0,n=i}else n=e;var r=n1(),o={},a=!1;return nw(n,function(e,n){if("dataIndex"===n||"dataIndexInside"===n){o[n]=e;return}var i=n.match(/^(\w+)(Index|Id|Name)$/)||[],s=i[1],l=(i[2]||"").toLowerCase();!s||!l||t&&t.includeMainTypes&&0>nv(t.includeMainTypes,s)||(a=a||!!s,(r.get(s)||r.set(s,{}))[l]=e)}),{mainTypeSpecified:a,queryOptionMap:r,others:o}}var si={useDefault:!0,enableAll:!1,enableNone:!1},sr={useDefault:!1,enableAll:!0,enableNone:!0};function so(e,t,n,i){i=i||si;var r=n.index,o=n.id,a=n.name,s={models:null,specified:null!=r||null!=o||null!=a};if(!s.specified){var l=void 0;return s.models=i.useDefault&&(l=e.getComponent(t))?[l]:[],s}return"none"===r||!1===r?(nq(i.enableNone,'`"none"` or `false` is not a valid value on index option.'),s.models=[]):("all"===r&&(nq(i.enableAll,'`"all"` is not a valid value on index option.'),r=o=a=null),s.models=e.queryComponents({mainType:t,index:r,id:o,name:a})),s}function sa(e,t,n){e.setAttribute?e.setAttribute(t,n):e[t]=n}function ss(e,t){var n=n1(),i=[];return nw(e,function(e){var r=t(e);(n.get(r)||(i.push(r),n.set(r,[]))).push(e)}),{keys:i,buckets:n}}function sl(e,t,n,i,r){var o=null==t||"auto"===t;if(null==i)return i;if(nE(i)){var a,s=(i-(a=n||0))*r+a;return aI(s,o?Math.max(aP(n||0),aP(i)):t)}if(nA(i))return r<1?n:i;for(var l=[],d=Math.max(n?n.length:0,i.length),u=0;u<d;++u){var c=e.getDimensionInfo(u);if(c&&"ordinal"===c.type)l[u]=(r<1&&n?n:i)[u];else{var h=n&&n[u]?n[u]:0,p=i[u],s=(p-h)*r+h;l[u]=aI(s,o?Math.max(aP(h),aP(p)):t)}}return l}var sd="___EC__COMPONENT__CONTAINER___",su="___EC__EXTENDED_CLASS___";function sc(e){var t={main:"",sub:""};if(e){var n=e.split(".");t.main=n[0]||"",t.sub=n[1]||""}return t}function sh(e,t){e.$constructor=e,e.extend=function(e){var t,n,i=this;return nI(t=i)&&/^class\s/.test(Function.prototype.toString.call(t))?n=function(e){function t(){return e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t}(i):ny(n=function(){(e.$constructor||i).apply(this,arguments)},this),nf(n.prototype,e),n[su]=!0,n.extend=this.extend,n.superCall=sg,n.superApply=sm,n.superClass=i,n}}function sp(e,t){e.extend=t.extend}var sf=Math.round(10*Math.random());function sg(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];return this.superClass.prototype[t].apply(e,n)}function sm(e,t,n){return this.superClass.prototype[t].apply(e,n)}function sv(e){var t={};e.registerClass=function(e){var n=e.type||e.prototype.type;if(n){nq(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(n),'componentType "'+n+'" illegal'),e.prototype.type=n;var i,r,o=sc(n);o.sub?o.sub!==sd&&(((r=t[(i=o).main])&&r[sd]||((r=t[i.main]={})[sd]=!0),r)[o.sub]=e):t[o.main]=e}return e},e.getClass=function(e,n,i){var r=t[e];if(r&&r[sd]&&(r=n?r[n]:null),i&&!r)throw Error(n?"Component "+e+"."+(n||"")+" is used but not imported.":e+".type should be specified.");return r},e.getClassesByMainType=function(e){var n=sc(e),i=[],r=t[n.main];return r&&r[sd]?nw(r,function(e,t){t!==sd&&i.push(e)}):i.push(r),i},e.hasClass=function(e){return!!t[sc(e).main]},e.getAllClassMainTypes=function(){var e=[];return nw(t,function(t,n){e.push(n)}),e},e.hasSubTypes=function(e){var n=t[sc(e).main];return n&&n[sd]}}function sy(e,t){for(var n=0;n<e.length;n++)e[n][1]||(e[n][1]=e[n][0]);return t=t||!1,function(n,i,r){for(var o={},a=0;a<e.length;a++){var s=e[a][1];if(!(i&&nv(i,s)>=0||r&&0>nv(r,s))){var l=n.getShallow(s,t);null!=l&&(o[e[a][0]]=l)}}return o}}var sb=sy([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["o
422pacity"],["shadowColor"]]),sx=function(){function e(){}return e.prototype.getAreaStyle=function(e,t){return sb(this,e,t)},e}(),sw=new rU(50);function sC(e,t,n,i,r){if(!e)return t;if("string"!=typeof e)return e;if(t&&t.__zrImageSrc===e||!n)return t;var o=sw.get(e),a={hostEl:n,cb:i,cbPayload:r};return o?s_(t=o.image)||o.pending.push(a):((t=t4.loadImage(e,sS,sS)).__zrImageSrc=e,sw.put(e,t.__cachedImgObj={image:t,pending:[a]})),t}function sS(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var n=e.pending[t],i=n.cb;i&&i(this,n.cbPayload),n.hostEl.dirty()}e.pending.length=0}function s_(e){return e&&e.width&&e.height}var sk=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function sM(e,t,n,i,r){var o={};return sT(o,e,t,n,i,r),o.text}function sT(e,t,n,i,r,o){if(!n){e.text="",e.isTruncated=!1;return}var a=(t+"").split("\n");o=sD(n,i,r,o);for(var s=!1,l={},d=0,u=a.length;d<u;d++)sR(l,a[d],o),a[d]=l.textLine,s=s||l.isTruncated;e.text=a.join("\n"),e.isTruncated=s}function sD(e,t,n,i){var r=nf({},i=i||{});r.font=t,n=nG(n,"..."),r.maxIterations=nG(i.maxIterations,2);var o=r.minChar=nG(i.minChar,0);r.cnCharWidth=at("å½",t);var a=r.ascCharWidth=at("a",t);r.placeholder=nG(i.placeholder,"");for(var s=e=Math.max(0,e-1),l=0;l<o&&s>=a;l++)s-=a;var d=at(n,t);return d>s&&(n="",d=0),s=e-d,r.ellipsis=n,r.ellipsisWidth=d,r.contentWidth=s,r.containerWidth=e,r}function sR(e,t,n){var i=n.containerWidth,r=n.font,o=n.contentWidth;if(!i){e.textLine="",e.isTruncated=!1;return}var a=at(t,r);if(a<=i){e.textLine=t,e.isTruncated=!1;return}for(var s=0;;s++){if(a<=o||s>=n.maxIterations){t+=n.ellipsis;break}var l=0===s?function(e,t,n,i){for(var r=0,o=0,a=e.length;o<a&&r<t;o++){var s=e.charCodeAt(o);r+=0<=s&&s<=127?n:i}return o}(t,o,n.ascCharWidth,n.cnCharWidth):a>0?Math.floor(t.length*o/a):0;a=at(t=t.substr(0,l),r)}""===t&&(t=n.placeholder),e.textLine=t,e.isTruncated=!0}var sI=function(){},sA=function(e){this.tokens=[],e&&(this.tokens=e)},sP=function(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1};function sE(e,t,n,i,r){var o,a,s=""===t,l=r&&n.rich[r]||{},d=e.lines,u=l.font||n.font,c=!1;if(i){var h=l.padding,p=h?h[1]+h[3]:0;if(null!=l.width&&"auto"!==l.width){var f=as(l.width,i.width)+p;d.length>0&&f+i.accumWidth>i.width&&(o=t.split("\n"),c=!0),i.accumWidth=f}else{var g=sF(t,u,i.width,i.breakAll,i.accumWidth);i.accumWidth=g.accumWidth+p,a=g.linesWidths,o=g.lines}}else o=t.split("\n");for(var m=0;m<o.length;m++){var v=o[m],y=new sI;if(y.styleName=r,y.text=v,y.isLineHolder=!v&&!s,"number"==typeof l.width?y.width=l.width:y.width=a?a[m]:at(v,u),m||c)d.push(new sA([y]));else{var b=(d[d.length-1]||(d[0]=new sA)).tokens,x=b.length;1===x&&b[0].isLineHolder?b[0]=y:(v||!x||s)&&b.push(y)}}}var sL=nS(",&?/;] ".split(""),function(e,t){return e[t]=!0,e},{});function sF(e,t,n,i,r){for(var o=[],a=[],s="",l="",d=0,u=0,c=0;c<e.length;c++){var h=e.charAt(c);if("\n"===h){l&&(s+=l,u+=d),o.push(s),a.push(u),s="",l="",d=0,u=0;continue}var p=at(h,t),f=!i&&!function(e){var t;return(!((t=e.charCodeAt(0))>=32)||!(t<=591))&&(!(t>=880)||!(t<=4351))&&(!(t>=4608)||!(t<=5119))&&(!(t>=7680)||!(t<=8303))||!!sL[e]}(h);if(o.length?u+p>n:r+u+p>n){u?(s||l)&&(f?(s||(s=l,l="",u=d=0),o.push(s),a.push(u-d),l+=h,d+=p,s="",u=d):(l&&(s+=l,l="",d=0),o.push(s),a.push(u),s=h,u=p)):f?(o.push(l),a.push(d),l=h,d=p):(o.push(h),a.push(p));continue}u+=p,f?(l+=h,d+=p):(l&&(s+=l,l="",d=0),s+=h)}return o.length||s||(s=e,l="",d=0),l&&(s+=l),s&&(o.push(s),a.push(u)),1===o.length&&(u+=r),{accumWidth:u,lines:o,linesWidths:a}}var sO="__zr_style_"+Math.round(10*Math.random()),sN={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},sB={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};sN[sO]=!0;var sz=["z","z2","invisible"],sj=["invisible"],sV=function(e){var t;function n(t){return e.call(this,t)||this}return(0,tQ.__extends)(n,e),n.prototype._init=function(t){for(var n=nM(t),i=0;i<n.length;i++){var r=n[i];"style"===r?this.useStyle(t[r]):e.prototype.attrKV.call(this,r,t[r])}this.style||this.useStyle({})},n.prototype.beforeBrush=function(){},n.prototype.afterBrush=function(){},n.prototype.innerBeforeBrush=function(){},n.prototype.innerAfterBrush=function(){},n.prototype.shouldBePainted=function(e,t,n,i){var r,o,a,s=this.transform;if(this.ignore||this.invisible||0===this.style.opacity||this.culling&&(r=this,o=e,a=t,sH.copy(r.getBoundingRect
422()),r.transform&&sH.applyTransform(r.transform),sG.width=o,sG.height=a,!sH.intersect(sG))||s&&!s[0]&&!s[3])return!1;if(n&&this.__clipPaths){for(var l=0;l<this.__clipPaths.length;++l)if(this.__clipPaths[l].isZeroArea())return!1}if(i&&this.parent)for(var d=this.parent;d;){if(d.ignore)return!1;d=d.parent}return!0},n.prototype.contain=function(e,t){return this.rectContain(e,t)},n.prototype.traverse=function(e,t){e.call(t,this)},n.prototype.rectContain=function(e,t){var n=this.transformCoordToLocal(e,t);return this.getBoundingRect().contain(n[0],n[1])},n.prototype.getPaintRect=function(){var e=this._paintRect;if(!this._paintRect||this.__dirty){var t=this.transform,n=this.getBoundingRect(),i=this.style,r=i.shadowBlur||0,o=i.shadowOffsetX||0,a=i.shadowOffsetY||0;e=this._paintRect||(this._paintRect=new rt(0,0,0,0)),t?rt.applyTransform(e,n,t):e.copy(n),(r||o||a)&&(e.width+=2*r+Math.abs(o),e.height+=2*r+Math.abs(a),e.x=Math.min(e.x,e.x+o-r),e.y=Math.min(e.y,e.y+a-r));var s=this.dirtyRectTolerance;e.isZero()||(e.x=Math.floor(e.x-s),e.y=Math.floor(e.y-s),e.width=Math.ceil(e.width+1+2*s),e.height=Math.ceil(e.height+1+2*s))}return e},n.prototype.setPrevPaintRect=function(e){e?(this._prevPaintRect=this._prevPaintRect||new rt(0,0,0,0),this._prevPaintRect.copy(e)):this._prevPaintRect=null},n.prototype.getPrevPaintRect=function(){return this._prevPaintRect},n.prototype.animateStyle=function(e){return this.animate("style",e)},n.prototype.updateDuringAnimation=function(e){"style"===e?this.dirtyStyle():this.markRedraw()},n.prototype.attrKV=function(t,n){"style"!==t?e.prototype.attrKV.call(this,t,n):this.style?this.setStyle(n):this.useStyle(n)},n.prototype.setStyle=function(e,t){return"string"==typeof e?this.style[e]=t:nf(this.style,e),this.dirtyStyle(),this},n.prototype.dirtyStyle=function(e){e||this.markRedraw(),this.__dirty|=2,this._rect&&(this._rect=null)},n.prototype.dirty=function(){this.dirtyStyle()},n.prototype.styleChanged=function(){return!!(2&this.__dirty)},n.prototype.styleUpdated=function(){this.__dirty&=-3},n.prototype.createStyle=function(e){return n3(sN,e)},n.prototype.useStyle=function(e){e[sO]||(e=this.createStyle(e)),this.__inHover?this.__hoverStyle=e:this.style=e,this.dirtyStyle()},n.prototype.isStyleObject=function(e){return e[sO]},n.prototype._innerSaveToNormal=function(t){e.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.style&&!n.style&&(n.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(t,n,sz)},n.prototype._applyStateObj=function(t,n,i,r,o,a){e.prototype._applyStateObj.call(this,t,n,i,r,o,a);var s,l=!(n&&r);if(n&&n.style?o?r?s=n.style:(s=this._mergeStyle(this.createStyle(),i.style),this._mergeStyle(s,n.style)):(s=this._mergeStyle(this.createStyle(),r?this.style:i.style),this._mergeStyle(s,n.style)):l&&(s=i.style),s)if(o){var d=this.style;if(this.style=this.createStyle(l?{}:d),l)for(var u=nM(d),c=0;c<u.length;c++){var h=u[c];h in s&&(s[h]=s[h],this.style[h]=d[h])}for(var p=nM(s),c=0;c<p.length;c++){var h=p[c];this.style[h]=this.style[h]}this._transitionState(t,{style:s},a,this.getAnimationStyleProps())}else this.useStyle(s);for(var f=this.__inHover?sj:sz,c=0;c<f.length;c++){var h=f[c];n&&null!=n[h]?this[h]=n[h]:l&&null!=i[h]&&(this[h]=i[h])}},n.prototype._mergeStates=function(t){for(var n,i=e.prototype._mergeStates.call(this,t),r=0;r<t.length;r++){var o=t[r];o.style&&(n=n||{},this._mergeStyle(n,o.style))}return n&&(i.style=n),i},n.prototype._mergeStyle=function(e,t){return nf(e,t),e},n.prototype.getAnimationStyleProps=function(){return sB},n.initDefaultProps=void((t=n.prototype).type="displayable",t.invisible=!1,t.z=0,t.z2=0,t.zlevel=0,t.culling=!1,t.cursor="pointer",t.rectHover=!1,t.incremental=!1,t._rect=null,t.dirtyRectTolerance=0,t.__dirty=3),n}(af),sH=new rt(0,0,0,0),sG=new rt(0,0,0,0),sW=Math.min,s$=Math.max,sU=Math.sin,sq=Math.cos,sK=2*Math.PI,sY=n7(),sZ=n7(),sX=n7();function sJ(e,t,n){if(0!==e.length){for(var i=e[0],r=i[0],o=i[0],a=i[1],s=i[1],l=1;l<e.length;l++)r=sW(r,(i=e[l])[0]),o=s$(o,i[0]),a=sW(a,i[1]),s=s$(s,i[1]);t[0]=r,t[1]=a,n[0]=o,n[1]=s}}function sQ(e,t,n,i,r,o){r[0]=sW(e,n),r[1]=sW(t,i),o[0]=s$(e,n),o[1]=s$(t,i)}var s0=[],s1=[],s2={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},s3=[],s5=[],s4=[],s6=[],s8=[],s7=[],s9=Math.min,le=Math.max,lt=Math.cos,ln=Math.sin,li=Math.abs,lr=M
vendor: 5,453 bytes, line 422
422ath.PI,lo=2*lr,la="u">typeof Float32Array,ls=[];function ll(e){return Math.round(e/lr*1e8)/1e8%2*lr}function ld(e,t){var n=ll(e[0]);n<0&&(n+=lo);var i=n-e[0],r=e[1];r+=i,!t&&r-n>=lo?r=n+lo:t&&n-r>=lo?r=n-lo:!t&&n>r?r=n+(lo-ll(n-r)):t&&n<r&&(r=n-(lo-ll(r-n))),e[0]=n,e[1]=r}var lu=function(){var e;function t(e){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,e&&(this._saveData=!1),this._saveData&&(this.data=[])}return t.prototype.increaseVersion=function(){this._version++},t.prototype.getVersion=function(){return this._version},t.prototype.setScale=function(e,t,n){(n=n||0)>0&&(this._ux=li(n/oQ/e)||0,this._uy=li(n/oQ/t)||0)},t.prototype.setDPR=function(e){this.dpr=e},t.prototype.setContext=function(e){this._ctx=e},t.prototype.getContext=function(){return this._ctx},t.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},t.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},t.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData(s2.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},t.prototype.lineTo=function(e,t){var n=li(e-this._xi),i=li(t-this._yi),r=n>this._ux||i>this._uy;if(this.addData(s2.L,e,t),this._ctx&&r&&this._ctx.lineTo(e,t),r)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var o=n*n+i*i;o>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=o)}return this},t.prototype.bezierCurveTo=function(e,t,n,i,r,o){return this._drawPendingPt(),this.addData(s2.C,e,t,n,i,r,o),this._ctx&&this._ctx.bezierCurveTo(e,t,n,i,r,o),this._xi=r,this._yi=o,this},t.prototype.quadraticCurveTo=function(e,t,n,i){return this._drawPendingPt(),this.addData(s2.Q,e,t,n,i),this._ctx&&this._ctx.quadraticCurveTo(e,t,n,i),this._xi=n,this._yi=i,this},t.prototype.arc=function(e,t,n,i,r,o){this._drawPendingPt(),ls[0]=i,ls[1]=r,ld(ls,o),i=ls[0];var a=(r=ls[1])-i;return this.addData(s2.A,e,t,n,n,i,a,0,+!o),this._ctx&&this._ctx.arc(e,t,n,i,r,o),this._xi=lt(r)*n+e,this._yi=ln(r)*n+t,this},t.prototype.arcTo=function(e,t,n,i,r){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,n,i,r),this},t.prototype.rect=function(e,t,n,i){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,n,i),this.addData(s2.R,e,t,n,i),this},t.prototype.closePath=function(){this._drawPendingPt(),this.addData(s2.Z);var e=this._ctx,t=this._x0,n=this._y0;return e&&e.closePath(),this._xi=t,this._yi=n,this},t.prototype.fill=function(e){e&&e.fill(),this.toStatic()},t.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},t.prototype.len=function(){return this._len},t.prototype.setData=function(e){var t=e.length;!(this.data&&this.data.length===t)&&la&&(this.data=new Float32Array(t));for(var n=0;n<t;n++)this.data[n]=e[n];this._len=t},t.prototype.appendPath=function(e){e instanceof Array||(e=[e]);for(var t=e.length,n=0,i=this._len,r=0;r<t;r++)n+=e[r].len();la&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n));for(var r=0;r<t;r++)for(var o=e[r].data,a=0;a<o.length;a++)this.data[i++]=o[a];this._len=i},t.prototype.addData=function(e,t,n,i,r,o,a,s,l){if(this._saveData){var d=this.data;this._len+arguments.length>d.length&&(this._expandData(),d=this.data);for(var u=0;u<arguments.length;u++)d[this._len++]=arguments[u]}},t.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},t.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var e=[],t=0;t<this._len;t++)e[t]=this.data[t];this.data=e}},t.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var e=this.data;e instanceof Array&&(e.length=this._len,la&&this._len>11&&(this.data=new Float32Array(e)))}},t.prototype.getBoundingRect=function(){s4[0]=s4[1]=s8[0]=s8[1]=Number.MAX_VALUE,s6[0]=s6[1]=s7[0]=s7[1]=-Number.MAX_VALUE;var e,t=this.data,n=0,i=0,r=0,o=0;for(e=0;e<this._len;){var a=t[e++],s=1===e;switch(s&&(n=t[e],i=t[e+1],r=n,o=i),a){case s2.M:n=r=t[e++],i=o=t[e++],s8[0]=r,s8[1]=o,s7[0]=r,s7[1]=o;break;case s2.L:sQ(n,i,t[e],t[e+1],s8,s7),n=t[e++],i=t[e++];break;case s2.C:!function(e,t,n,i,r,o,a,s,l,d){var u=rE(e,n,r,a,s0);l[0]=1/0,l[1]=1/0,d[0]=-1/0,d[1]=-1/0;for(var c=0;c<u;c++){var h=rI(e,n,r,a,s0[c]);l[0]=sW(h,l[0]),d[0]=s$(h,d[0])}u=rE(t,i,o,s,s1);for(var c=0;c<u;c++){var p=rI(t,i,o,s,s1[c]);l[1]=sW(p,l[1]),d[1]=s$(p,d[1])}l[0]=sW(e,l[0]),d[0]=s$(e,d[0]),l[0]=sW(a,l[0]),d[0]=s$(a,d[0]),l[1]=sW(t,l[1]),d[1]=s$(t,d[1]),l[1]=sW(s,l[1]),d[1]=s$(s,d[1])}(n,i,t[e++],t[e++],t[e++],t[e++],t[e],t[e+1],s8,s7),n=t[e++],i=t[e++];break;case s2.Q:!function(e,t,n,i,r,o,a,s){var l=s$(sW(rB(e,n,r),1),0),d=s$(sW(rB(t,i,o),1),0),u=rO(e,n,r,l),c=rO(t,i,o,d);a[0]=sW(e,r,u),a[1]=sW(t,o,c),s[0]=s$(e,r,u),s[1]=s$(t,o,c)}(n,i,t[e++],t[e++],t[e],t[e+1],s8,s7),n=t[e++],i=t[e++];break;case s2.A:var l=t[e++],d=t[e++],u=t[e++],c=t[e++],h=t[e++],p=t[e++]+h;e+=1;var f=!t[e++];s&&(r=lt(h)*u+l,o=ln(h)*c+d),function(e,t,n,i,r,o,a,s,l){var d=Math.abs(r-o);if(d%sK<1e-4&&d>1e-4){s[0]=e-n,s[1]=t-i,l[0]=e+n,l[1]=t+i;return}if(sY[0]=sq(r)*n+e,sY[1]=sU(r)*i+t,sZ[0]=sq(o)*n+e,sZ[1]=sU(o)*i+t,ib(s,sY,sZ),ix(l,sY,sZ),(r%=sK)<0&&(r+=sK),(o%=sK)<0&&(o+=sK),r>o&&!a?o+=sK:r<o&&a&&(r+=sK),a){var u=o;o=r,r=u}for(var c=0;c<o;c+=Math.PI/2)c>r&&(sX[0]=sq(c)*n+e,sX[1]=sU(c)*i+t,ib(s,sX,s),ix(l,sX,l))}(l,d,u,c,h,p,f,s8,s7),n=lt(p)*u+l,i=ln(p)*c+d;break;
422case s2.R:sQ(r=n=t[e++],o=i=t[e++],r+t[e++],o+t[e++],s8,s7);break;case s2.Z:n=r,i=o}ib(s4,s4,s8),ix(s6,s6,s7)}return 0===e&&(s4[0]=s4[1]=s6[0]=s6[1]=0),new rt(s4[0],s4[1],s6[0]-s4[0],s6[1]-s4[1])},t.prototype._calculateLength=function(){var e=this.data,t=this._len,n=this._ux,i=this._uy,r=0,o=0,a=0,s=0;this._pathSegLen||(this._pathSegLen=[]);for(var l=this._pathSegLen,d=0,u=0,c=0;c<t;){var h=e[c++],p=1===c;p&&(r=e[c],o=e[c+1],a=r,s=o);var f=-1;switch(h){case s2.M:r=a=e[c++],o=s=e[c++];break;case s2.L:var g=e[c++],m=e[c++],v=g-r,y=m-o;(li(v)>n||li(y)>i||c===t-1)&&(f=Math.sqrt(v*v+y*y),r=g,o=m);break;case s2.C:var b=e[c++],x=e[c++],g=e[c++],m=e[c++],w=e[c++],C=e[c++];f=function(e,t,n,i,r,o,a,s,l){for(var d=e,u=t,c=0,h=1;h<=10;h++){var p=.1*h,f=rI(e,n,r,a,p),g=rI(t,i,o,s,p),m=f-d,v=g-u;c+=Math.sqrt(m*m+v*v),d=f,u=g}return c}(r,o,b,x,g,m,w,C,0),r=w,o=C;break;case s2.Q:var b=e[c++],x=e[c++],g=e[c++],m=e[c++];f=function(e,t,n,i,r,o,a){for(var s=e,l=t,d=0,u=1;u<=10;u++){var c=.1*u,h=rO(e,n,r,c),p=rO(t,i,o,c),f=h-s,g=p-l;d+=Math.sqrt(f*f+g*g),s=h,l=p}return d}(r,o,b,x,g,m,0),r=g,o=m;break;case s2.A:var S=e[c++],_=e[c++],k=e[c++],M=e[c++],T=e[c++],D=e[c++],R=D+T;c+=1,p&&(a=lt(T)*k+S,s=ln(T)*M+_),f=le(k,M)*s9(lo,Math.abs(D)),r=lt(R)*k+S,o=ln(R)*M+_;break;case s2.R:a=r=e[c++],s=o=e[c++],f=2*e[c++]+2*e[c++];break;case s2.Z:var v=a-r,y=s-o;f=Math.sqrt(v*v+y*y),r=a,o=s}f>=0&&(l[u++]=f,d+=f)}return this._pathLen=d,d},t.prototype.rebuildPath=function(e,t){var n,i,r,o,a,s,l,d,u,c,h=this.data,p=this._ux,f=this._uy,g=this._len,m=t<1,v=0,y=0,b=0;if(!m||(this._pathSegLen||this._calculateLength(),l=this._pathSegLen,d=t*this._pathLen))r:for(var x=0;x<g;){var w=h[x++],C=1===x;switch(C&&(r=h[x],o=h[x+1],n=r,i=o),w!==s2.L&&b>0&&(e.lineTo(u,c),b=0),w){case s2.M:n=r=h[x++],i=o=h[x++],e.moveTo(r,o);break;case s2.L:a=h[x++],s=h[x++];var S=li(a-r),_=li(s-o);if(S>p||_>f){if(m){var k=l[y++];if(v+k>d){var M=(d-v)/k;e.lineTo(r*(1-M)+a*M,o*(1-M)+s*M);break r}v+=k}e.lineTo(a,s),r=a,o=s,b=0}else{var T=S*S+_*_;T>b&&(u=a,c=s,b=T)}break;case s2.C:var D=h[x++],R=h[x++],I=h[x++],A=h[x++],P=h[x++],E=h[x++];if(m){var k=l[y++];if(v+k>d){var M=(d-v)/k;rL(r,D,I,P,M,s3),rL(o,R,A,E,M,s5),e.bezierCurveTo(s3[1],s5[1],s3[2],s5[2],s3[3],s5[3]);break r}v+=k}e.bezierCurveTo(D,R,I,A,P,E),r=P,o=E;break;case s2.Q:var D=h[x++],R=h[x++],I=h[x++],A=h[x++];if(m){var k=l[y++];if(v+k>d){var M=(d-v)/k;rz(r,D,I,M,s3),rz(o,R,A,M,s5),e.quadraticCurveTo(s3[1],s5[1],s3[2],s5[2]);break r}v+=k}e.quadraticCurveTo(D,R,I,A),r=I,o=A;break;case s2.A:var L=h[x++],F=h[x++],O=h[x++],N=h[x++],B=h[x++],z=h[x++],j=h[x++],V=!h[x++],H=O>N?O:N,G=li(O-N)>.001,W=B+z,$=!1;if(m){var k=l[y++];v+k>d&&(W=B+z*(d-v)/k,$=!0),v+=k}if(G&&e.ellipse?e.ellipse(L,F,O,N,j,B,W,V):e.arc(L,F,H,B,W,V),$)break r;C&&(n=lt(B)*O+L,i=ln(B)*N+F),r=lt(W)*O+L,o=ln(W)*N+F;break;case s2.R:n=r=h[x],i=o=h[x+1],a=h[x++],s=h[x++];var U=h[x++],q=h[x++];if(m){var k=l[y++];if(v+k>d){var K=d-v;e.moveTo(a,s),e.lineTo(a+s9(K,U),s),(K-=U)>0&&e.lineTo(a+U,s+s9(K,q)),(K-=q)>0&&e.lineTo(a+le(U-K,0),s+q),(K-=U)>0&&e.lineTo(a,s+le(q-K,0));break r}v+=k}e.rect(a,s,U,q);break;case s2.Z:if(m){var k=l[y++];if(v+k>d){var M=(d-v)/k;e.lineTo(r*(1-M)+n*M,o*(1-M)+i*M);break r}v+=k}e.closePath(),r=n,o=i}}},t.prototype.clone=function(){var e=new t,n=this.data;return e.data=n.slice?n.slice():Array.prototype.slice.call(n),e._len=this._len,e},t.CMD=s2,t.initDefaultProps=void((e=t.prototype)._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0),t}();function lc(e,t,n,i,r,o,a){if(0===r)return!1;var s=0,l=e;if(a>t+r&&a>i+r||a<t-r&&a<i-r||o>e+r&&o>n+r||o<e-r&&o<n-r)return!1;if(e===n)return Math.abs(o-e)<=r/2;s=(t-i)/(e-n);var d=s*o-a+(l=(e*i-n*t)/(e-n));return d*d/(s*s+1)<=r/2*r/2}function lh(e,t,n,i,r,o,a,s,l){return 0!==a&&(!(l>t+a)||!(l>i+a)||!(l>o+a))&&(!(l<t-a)||!(l<i-a)||!(l<o-a))&&(!(s>e+a)||!(s>n+a)||!(s>r+a))&&(!(s<e-a)||!(s<n-a)||!(s<r-a))&&rj(e,t,n,i,r,o,s,l,null)<=a/2}var lp=2*Math.PI;function lf(e){return(e%=lp)<0&&(e+=lp),e}var lg=2*Math.PI;function lm(e,t,n,i,r,o){if(o>t&&o>i||o<t&&o<i||i===t)return 0;var a=(o-t)/(i-t),s=i<t?1:-1;(1===a||0===a)&&(s=i<t?.5:-.5);var l=a*(n-e)+e;return l===r?1/0:l>r?s:0}var lv=lu.CMD,ly=2*Math.PI,lb=[-1,-1,-1],lx=[-1,-1];function lw(e,t,n,i,r){for(var o,a,s=e.data,l=e.len(),d=0,u=0,c=0,h=0,p=0,f=0;f<l;){var g,m,v,y,b,x,w,C,S=s[f++],_=1===f;switch(S===lv.M&&f>1&&!n&&(d+=lm(u,c,h,p,i,r)),_&&(u=s[f],c=s[f+1],h=u,p=c),S){case lv.M:h=s[f++],p=s[f++],u=h,c=p;break;case lv.L:if(n){if(lc(u,c,s[f],s[f+1],t,i,r))return!0}else d+=lm(u,c,s[f],s[f+1],i,r)||0;u=s[f++],c=s[f++];break;case lv.C:if(n){if(g=u,m=c,v=s[f++],y=s[f++],b=s[f++],x=s[f++],w=s[f],C=s[f+1],0!==t&&(!(r>m+t)||!(r>y+t)||!(r>x+t)||!(r>C+t))&&(!(r<m-t)||!(r<y-t)||!(r<x-t)||!(r<C-t))&&(!(i>g+t)||!(i>v+t)||!(i>b+t)||!(i>w+t))&&(!(i<g-t)||!(i<v-t)||!(i<b-t)||!(i<w-t))&&rF(g,m,v,y,b,x,w,C,i,r,null)<=t/2)return!0}else d+=function(e,t,n,i,r,o,a,s,l,d){if(d>t&&d>i&&d>o&&d>s||d<t&&d<i&&d<o&&d<s)return 0;var u=rP(t,i,o,s,d,lb);if(0===u)return 0;for(var c=0,h=-1,p=void 0,f=void 0,g=0;g<u;g++){var m=lb[g],v=0===m||1===m?.5:1;rI(e,n,r,a,m)<l||(h<0&&(h=rE(t,i,o,s,lx),lx[1]<lx[0]&&h>1&&function(){var e=lx[0];lx[0]=lx[1],lx[1]=e}(),p=rI(t,i,o,s,lx[0]),h>1&&(f=rI(t,i,o,s,lx[1]))),2===h?m<lx[0]?c+=p<t?v:-v:m<lx[1]?c+=f<p?v:-v:c+=s<f?v:-v:m<lx[0]?c+=p<t?v:-v:c+=s<p?v:-v)}return c}(u,c,s[f++],s[f++],s[f++],s[f++],s[f],s[f+1],i,r)||0;u=s[f++],c=s[f++];break;case lv.Q:if(n){if(lh(u,c,s[f++],s[f++],s[f],s[f+1],t,i,r))return!0}
422else d+=function(e,t,n,i,r,o,a,s){if(s>t&&s>i&&s>o||s<t&&s<i&&s<o)return 0;var l=function(e,t,n,i,r){var o=e-2*t+n,a=2*(t-e),s=e-i,l=0;if(rD(o)){if(rR(a)){var d=-s/a;d>=0&&d<=1&&(r[l++]=d)}}else{var u=a*a-4*o*s;if(rD(u)){var d=-a/(2*o);d>=0&&d<=1&&(r[l++]=d)}else if(u>0){var c=rC(u),d=(-a+c)/(2*o),h=(-a-c)/(2*o);d>=0&&d<=1&&(r[l++]=d),h>=0&&h<=1&&(r[l++]=h)}}return l}(t,i,o,s,lb);if(0===l)return 0;var d=rB(t,i,o);if(d>=0&&d<=1){for(var u=0,c=rO(t,i,o,d),h=0;h<l;h++){var p=0===lb[h]||1===lb[h]?.5:1,f=rO(e,n,r,lb[h]);f<a||(lb[h]<d?u+=c<t?p:-p:u+=o<c?p:-p)}return u}var p=0===lb[0]||1===lb[0]?.5:1,f=rO(e,n,r,lb[0]);return f<a?0:o<t?p:-p}(u,c,s[f++],s[f++],s[f],s[f+1],i,r)||0;u=s[f++],c=s[f++];break;case lv.A:var k=s[f++],M=s[f++],T=s[f++],D=s[f++],R=s[f++],I=s[f++];f+=1;var A=!!(1-s[f++]);o=Math.cos(R)*T+k,a=Math.sin(R)*D+M,_?(h=o,p=a):d+=lm(u,c,o,a,i,r);var P=(i-k)*D/T+k;if(n){if(function(e,t,n,i,r,o,a,s,l){if(0===a)return!1;var d=Math.sqrt((s-=e)*s+(l-=t)*l);if(d-a>n||d+a<n)return!1;if(Math.abs(i-r)%lg<1e-4)return!0;if(o){var u=i;i=lf(r),r=lf(u)}else i=lf(i),r=lf(r);i>r&&(r+=lg);var c=Math.atan2(l,s);return c<0&&(c+=lg),c>=i&&c<=r||c+lg>=i&&c+lg<=r}(k,M,D,R,R+I,A,t,P,r))return!0}else d+=function(e,t,n,i,r,o,a,s){if((s-=t)>n||s<-n)return 0;var l=Math.sqrt(n*n-s*s);lb[0]=-l,lb[1]=l;var d=Math.abs(i-r);if(d<1e-4)return 0;if(d>=ly-1e-4){i=0,r=ly;var u=o?1:-1;return a>=lb[0]+e&&a<=lb[1]+e?u:0}if(i>r){var c=i;i=r,r=c}i<0&&(i+=ly,r+=ly);for(var h=0,p=0;p<2;p++){var f=lb[p];if(f+e>a){var g=Math.atan2(s,f),u=o?1:-1;g<0&&(g=ly+g),(g>=i&&g<=r||g+ly>=i&&g+ly<=r)&&(g>Math.PI/2&&g<1.5*Math.PI&&(u=-u),h+=u)}}return h}(k,M,D,R,R+I,A,P,r);u=Math.cos(R+I)*T+k,c=Math.sin(R+I)*D+M;break;case lv.R:h=u=s[f++],p=c=s[f++];var E=s[f++],L=s[f++];if(o=h+E,a=p+L,n){if(lc(h,p,o,p,t,i,r)||lc(o,p,o,a,t,i,r)||lc(o,a,h,a,t,i,r)||lc(h,a,h,p,t,i,r))return!0}else d+=lm(o,p,o,a,i,r),d+=lm(h,a,h,p,i,r);break;case lv.Z:if(n){if(lc(u,c,h,p,t,i,r))return!0}else d+=lm(u,c,h,p,i,r);u=h,c=p}}return n||1e-4>Math.abs(c-p)||(d+=lm(u,c,h,p,i,r)||0),0!==d}var lC=ng({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},sN),lS={style:ng({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},sB.style)},l_=o7.concat(["invisible","culling","z","z2","zlevel","parent"]),lk=function(e){var t;function n(t){return e.call(this,t)||this}return(0,tQ.__extends)(n,e),n.prototype.update=function(){var t=this;e.prototype.update.call(this);var i=this.style;if(i.decal){var r=this._decalEl=this._decalEl||new n;r.buildPath===n.prototype.buildPath&&(r.buildPath=function(e){t.buildPath(e,t.shape)}),r.silent=!0;var o=r.style;for(var a in i)o[a]!==i[a]&&(o[a]=i[a]);o.fill=i.fill?i.decal:null,o.decal=null,o.shadowColor=null,i.strokeFirst&&(o.stroke=null);for(var s=0;s<l_.length;++s)r[l_[s]]=this[l_[s]];r.__dirty|=1}else this._decalEl&&(this._decalEl=null)},n.prototype.getDecalElement=function(){return this._decalEl},n.prototype._init=function(t){var n=nM(t);this.shape=this.getDefaultShape();var i=this.getDefaultStyle();i&&this.useStyle(i);for(var r=0;r<n.length;r++){var o=n[r],a=t[o];"style"===o?this.style?nf(this.style,a):this.useStyle(a):"shape"===o?nf(this.shape,a):e.prototype.attrKV.call(this,o,a)}this.style||this.useStyle({})},n.prototype.getDefaultStyle=function(){return null},n.prototype.getDefaultShape=function(){return{}},n.prototype.canBeInsideText=function(){return this.hasFill()},n.prototype.getInsideTextFill=function(){var e=this.style.fill;if("none"!==e){if(nA(e)){var t=oi(e,0);return t>.5?o0:t>.2?"#eee":o1}else if(e)return o1}return o0},n.prototype.getInsideTextStroke=function(e){var t=this.style.fill;if(nA(t)){var n=this.__zr;if(!!(n&&n.isDarkMode())==.4>oi(e,0))return t}},n.prototype.buildPath=function(e,t,n){},n.prototype.pathUpdated=function(){this.__dirty&=-5},n.prototype.getUpdatedPathProxy=function(e){return this.path||this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,e),this.path},n.prototype.createPathProxy=function(){this.path=new lu(!1)},n.prototype.hasStroke=function(){var e=this.style,t=e.stroke;return null!=t&&"none"!==t&&e.lineWidth>0},n.prototype.hasFill=function(){var e=this.style.fill;return null!=e&&"none"!==e},n.prototype.getBoundingRect=function(){var e=this._rect,t=this.style,n=!e;if(n){var i=!1;this.path||(i=!0,this.createPathProxy());var r=this.path;(i||4&this.__dirty)&&(r.beginPath(),this.buildPath(r,this.shape,!1),this.pathUpdated()),e=r.getBoundingRect
vendor: 4,884 bytes, line 422
422()}if(this._rect=e,this.hasStroke()&&this.path&&this.path.len()>0){var o=this._rectStroke||(this._rectStroke=e.clone());if(this.__dirty||n){o.copy(e);var a=t.strokeNoScale?this.getLineScale():1,s=t.lineWidth;if(!this.hasFill()){var l=this.strokeContainThreshold;s=Math.max(s,null==l?4:l)}a>1e-10&&(o.width+=s/a,o.height+=s/a,o.x-=s/a/2,o.y-=s/a/2)}return o}return e},n.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t),i=this.getBoundingRect(),r=this.style;if(e=n[0],t=n[1],i.contain(e,t)){var o=this.path;if(this.hasStroke()){var a=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(this.hasFill()||(a=Math.max(a,this.strokeContainThreshold)),lw(o,a/s,!0,e,t)))return!0}if(this.hasFill())return lw(o,0,!1,e,t)}return!1},n.prototype.dirtyShape=function(){this.__dirty|=4,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},n.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},n.prototype.animateShape=function(e){return this.animate("shape",e)},n.prototype.updateDuringAnimation=function(e){"style"===e?this.dirtyStyle():"shape"===e?this.dirtyShape():this.markRedraw()},n.prototype.attrKV=function(t,n){"shape"===t?this.setShape(n):e.prototype.attrKV.call(this,t,n)},n.prototype.setShape=function(e,t){var n=this.shape;return n||(n=this.shape={}),"string"==typeof e?n[e]=t:nf(n,e),this.dirtyShape(),this},n.prototype.shapeChanged=function(){return!!(4&this.__dirty)},n.prototype.createStyle=function(e){return n3(lC,e)},n.prototype._innerSaveToNormal=function(t){e.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.shape&&!n.shape&&(n.shape=nf({},this.shape))},n.prototype._applyStateObj=function(t,n,i,r,o,a){e.prototype._applyStateObj.call(this,t,n,i,r,o,a);var s,l=!(n&&r);if(n&&n.shape?o?r?s=n.shape:(s=nf({},i.shape),nf(s,n.shape)):(s=nf({},r?this.shape:i.shape),nf(s,n.shape)):l&&(s=i.shape),s)if(o){this.shape=nf({},this.shape);for(var d={},u=nM(s),c=0;c<u.length;c++){var h=u[c];"object"==typeof s[h]?this.shape[h]=s[h]:d[h]=s[h]}this._transitionState(t,{shape:d},a)}else this.shape=s,this.dirtyShape()},n.prototype._mergeStates=function(t){for(var n,i=e.prototype._mergeStates.call(this,t),r=0;r<t.length;r++){var o=t[r];o.shape&&(n=n||{},this._mergeStyle(n,o.shape))}return n&&(i.shape=n),i},n.prototype.getAnimationStyleProps=function(){return lS},n.prototype.isZeroArea=function(){return!1},n.extend=function(e){var t=function(t){function n(n){var i=t.call(this,n)||this;return e.init&&e.init.call(i,n),i}return(0,tQ.__extends)(n,t),n.prototype.getDefaultStyle=function(){return nc(e.style)},n.prototype.getDefaultShape=function(){return nc(e.shape)},n}(n);for(var i in e)"function"==typeof e[i]&&(t.prototype[i]=e[i]);return t},n.initDefaultProps=void((t=n.prototype).type="path",t.strokeContainThreshold=5,t.segmentIgnoreThreshold=0,t.subPixelOptimize=!1,t.autoBatch=!1,t.__dirty=7),n}(sV),lM=ng({strokeFirst:!0,font:t3,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},lC),lT=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.hasStroke=function(){var e=this.style,t=e.stroke;return null!=t&&"none"!==t&&e.lineWidth>0},t.prototype.hasFill=function(){var e=this.style.fill;return null!=e&&"none"!==e},t.prototype.createStyle=function(e){return n3(lM,e)},t.prototype.setBoundingRect=function(e){this._rect=e},t.prototype.getBoundingRect=function(){var e=this.style;if(!this._rect){var t=e.text;null!=t?t+="":t="";var n=ai(t,e.font,e.textAlign,e.textBaseline);if(n.x+=e.x||0,n.y+=e.y||0,this.hasStroke()){var i=e.lineWidth;n.x-=i/2,n.y-=i/2,n.width+=i,n.height+=i}this._rect=n}return this._rect},t.initDefaultProps=void(t.prototype.dirtyRectTolerance=10),t}(sV);lT.prototype.type="tspan";var lD=ng({x:0,y:0},sN),lR={style:ng({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},sB.style)},lI=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.createStyle=function(e){return n3(lD,e)},t.prototype._getSize=function(e){var t,n=this.style,i=n[e];if(null!=i)return i;var r=(t=n.image)&&"string"!=typeof t&&t.width&&t.height?n.image:this.__image;if(!r)return 0;var o="width"===e?"height":"width",a=n[o];return null==a?r[e]:r[e]/r[o]*a},t.prototype.getWidth=function(){return this._getSize("width")},t.prototype.getHeight=function(){return this._getSize("height")},t.prototype.getAnimationStyleProps=function(){return lR},t.prototype.getBoundingRect=function(){var e=this.style;return this._rect||(this._rect=new rt(e.x||0,e.y||0,this.getWidth(),this.getHeight())),this._rect},t}(sV);lI.prototype.type="image";var lA=Math.round;function lP(e,t,n){if(t){var i=t.x1,r=t.x2,o=t.y1,a=t.y2;e.x1=i,e.x2=r,e.y1=o,e.y2=a;var s=n&&n.lineWidth;return s&&(lA(2*i)===lA(2*r)&&(e.x1=e.x2=lL(i,s,!0)),lA(2*o)===lA(2*a)&&(e.y1=e.y2=lL(o,s,!0))),e}}
422function lE(e,t,n){if(t){var i=t.x,r=t.y,o=t.width,a=t.height;e.x=i,e.y=r,e.width=o,e.height=a;var s=n&&n.lineWidth;return s&&(e.x=lL(i,s,!0),e.y=lL(r,s,!0),e.width=Math.max(lL(i+o,s,!1)-e.x,+(0!==o)),e.height=Math.max(lL(r+a,s,!1)-e.y,+(0!==a))),e}}function lL(e,t,n){if(!t)return e;var i=lA(2*e);return(i+lA(t))%2==0?i/2:(i+(n?1:-1))/2}var lF=function(){this.x=0,this.y=0,this.width=0,this.height=0},lO={},lN=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new lF},t.prototype.buildPath=function(e,t){if(this.subPixelOptimize){var n,i,r,o,a,s,l,d,u,c,h,p,f,g,m,v=lE(lO,t,this.style);p=v.x,f=v.y,g=v.width,m=v.height,v.r=t.r,t=v}else p=t.x,f=t.y,g=t.width,m=t.height;t.r?(l=(n=t).x,d=n.y,u=n.width,c=n.height,h=n.r,u<0&&(l+=u,u=-u),c<0&&(d+=c,c=-c),"number"==typeof h?i=r=o=a=h:h instanceof Array?1===h.length?i=r=o=a=h[0]:2===h.length?(i=o=h[0],r=a=h[1]):3===h.length?(i=h[0],r=a=h[1],o=h[2]):(i=h[0],r=h[1],o=h[2],a=h[3]):i=r=o=a=0,i+r>u&&(s=i+r,i*=u/s,r*=u/s),o+a>u&&(s=o+a,o*=u/s,a*=u/s),r+o>c&&(s=r+o,r*=c/s,o*=c/s),i+a>c&&(s=i+a,i*=c/s,a*=c/s),e.moveTo(l+i,d),e.lineTo(l+u-r,d),0!==r&&e.arc(l+u-r,d+r,r,-Math.PI/2,0),e.lineTo(l+u,d+c-o),0!==o&&e.arc(l+u-o,d+c-o,o,0,Math.PI/2),e.lineTo(l+a,d+c),0!==a&&e.arc(l+a,d+c-a,a,Math.PI/2,Math.PI),e.lineTo(l,d+i),0!==i&&e.arc(l+i,d+i,i,Math.PI,1.5*Math.PI)):e.rect(p,f,g,m)},t.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},t}(lk);lN.prototype.type="rect";var lB={fill:"#000"},lz={style:ng({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},sB.style)},lj=function(e){function t(t){var n=e.call(this)||this;return n.type="text",n._children=[],n._defaultStyle=lB,n.attr(t),n}return(0,tQ.__extends)(t,e),t.prototype.childrenRef=function(){return this._children},t.prototype.update=function(){e.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;t<this._children.length;t++){var n=this._children[t];n.zlevel=this.zlevel,n.z=this.z,n.z2=this.z2,n.culling=this.culling,n.cursor=this.cursor,n.invisible=this.invisible}},t.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):e.prototype.updateTransform.call(this)},t.prototype.getLocalTransform=function(t){var n=this.innerTransformable;return n?n.getLocalTransform(t):e.prototype.getLocalTransform.call(this,t)},t.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),e.prototype.getComputedTransform.call(this)},t.prototype._updateSubTexts=function(){var e;this._childCursor=0,lq(e=this.style),nw(e.rich,lq),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},t.prototype.addSelfToZr=function(t){e.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=t},t.prototype.removeSelfFromZr=function(t){e.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=null},t.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var e=new rt(0,0,0,0),t=this._children,n=[],i=null,r=0;r<t.length;r++){var o=t[r],a=o.getBoundingRect(),s=o.getLocalTransform(n);s?(e.copy(a),e.applyTransform(s),(i=i||e.clone()).union(e)):(i=i||a.clone()).union(a)}this._rect=i||e}return this._rect},t.prototype.setDefaultTextStyle=function(e){this._defaultStyle=e||lB},t.prototype.setTextContent=function(e){},t.prototype._mergeStyle=function(e,t){if(!t)return e;var n=t.rich,i=e.rich||n&&{};return nf(e,t),n&&i?(this._mergeRich(i,n),e.rich=i):i&&(e.rich=i),e},t.prototype._mergeRich=function(e,t){for(var n=nM(t),i=0;i<n.length;i++){var r=n[i];e[r]=e[r]||{},nf(e[r],t[r])}},t.prototype.getAnimationStyleProps=function(){return lz},t.prototype._getOrCreateChild=function(e){var t=this._children[this._childCursor];return t&&t instanceof e||(t=new e),this._children[this._childCursor++]=t,t.__zr=this.__zr,t.parent=this,t},t.prototype._updatePlainTexts=function(){var e=this.style,t=e.font||t3,n=e.padding,i=function(e,t){null!=e&&(e+="");var n,i=t.overflow,r=t.padding,o=t.font,a=aa(o),s=nG(t.lineHeight,a),l=!!t.backgroundColor,d="truncate"===t.lineOverflow,u=!1,c=t.width,h=(n=null!=c&&("break"===i||"breakAll"===i)?e?sF(e,t.font,c,"breakAll"===i,0).lines:[]:e?e.split("\n"):[]).length*s,p=nG(t.height,h);if(h>p&&d){var f=Math.floor(p/s);u=u||n.length>f,n=n.slice(0,f)}if(e&&"truncate"===i&&null!=c)for(var g=sD(c,o,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),m={},v=0;v<n.length;v++)sR(m,n[v],g),n[v]=m.textLine,u=u||m.isTruncated;for(var y=p,b=0,v=0;v<n.length;v++)b=Math.max(at(n[v],o),b);null==c&&(c=b);var x=b;return r&&(y+=r[0]+r[2],x+=r[1]+r[3],c+=r[1]+r[3]),l&&(x=c),{lines:n,height:p,outerWidth:x,outerHeight:y,lineHeight:s,calculatedLineHeight:a,contentWidth:b,contentHeight:h,width:c,isTruncated:u}}(lX(e),e),r=lJ(e),o=!!e.backgroundColor,a=i.outerHeight,s=i.outerWidth,l=i.contentWidth,d=i.lines,u=i.lineHeight,c=this._defaultStyle;this.isTruncated=!!i.isTruncated;var h=e.x||0,p=e.y||0,f=e.align||c.align||"left",g=e.verticalAlign||c.verticalAlign||"top",m=h,v=ao(p,i.contentHeight,g);if(r||n){var y=ar(h,s,f),b=ao(p,a,g);
422r&&this._renderBackground(e,e,y,b,s,a)}v+=u/2,n&&(m=lZ(h,f,n),"top"===g?v+=n[0]:"bottom"===g&&(v-=n[2]));for(var x=0,w=!1,C=lY("fill"in e?e.fill:(w=!0,c.fill)),S=lK("stroke"in e?e.stroke:o||c.autoStroke&&!w?null:(x=2,c.stroke)),_=e.textShadowBlur>0,k=null!=e.width&&("truncate"===e.overflow||"break"===e.overflow||"breakAll"===e.overflow),M=i.calculatedLineHeight,T=0;T<d.length;T++){var D=this._getOrCreateChild(lT),R=D.createStyle();D.useStyle(R),R.text=d[T],R.x=m,R.y=v,R.textAlign=f,R.textBaseline="middle",R.opacity=e.opacity,R.strokeFirst=!0,_&&(R.shadowBlur=e.textShadowBlur||0,R.shadowColor=e.textShadowColor||"transparent",R.shadowOffsetX=e.textShadowOffsetX||0,R.shadowOffsetY=e.textShadowOffsetY||0),R.stroke=S,R.fill=C,S&&(R.lineWidth=e.lineWidth||x,R.lineDash=e.lineDash,R.lineDashOffset=e.lineDashOffset||0),R.font=t,l$(R,e),v+=u,k&&D.setBoundingRect(new rt(ar(R.x,l,R.textAlign),ao(R.y,M,R.textBaseline),l,M))}},t.prototype._updateRichTexts=function(){var e=this.style,t=function(e,t){var n,i=new sP;if(null!=e&&(e+=""),!e)return i;for(var r=t.width,o=t.height,a=t.overflow,s=("break"===a||"breakAll"===a)&&null!=r?{width:r,accumWidth:0,breakAll:"breakAll"===a}:null,l=sk.lastIndex=0;null!=(n=sk.exec(e));){var d=n.index;d>l&&sE(i,e.substring(l,d),t,s),sE(i,n[2],t,s,n[1]),l=sk.lastIndex}l<e.length&&sE(i,e.substring(l,e.length),t,s);var u=[],c=0,h=0,p=t.padding,f="truncate"===a,g="truncate"===t.lineOverflow,m={};
vendor: 4,267 bytes, line 422
422function v(e,t,n){e.width=t,e.lineHeight=n,c+=n,h=Math.max(h,t)}n:for(var y=0;y<i.lines.length;y++){for(var b=i.lines[y],x=0,w=0,C=0;C<b.tokens.length;C++){var S=b.tokens[C],_=S.styleName&&t.rich[S.styleName]||{},k=S.textPadding=_.padding,M=k?k[1]+k[3]:0,T=S.font=_.font||t.font;S.contentHeight=aa(T);var D=nG(_.height,S.contentHeight);if(S.innerHeight=D,k&&(D+=k[0]+k[2]),S.height=D,S.lineHeight=nW(_.lineHeight,t.lineHeight,D),S.align=_&&_.align||t.align,S.verticalAlign=_&&_.verticalAlign||"middle",g&&null!=o&&c+S.lineHeight>o){var R=i.lines.length;C>0?(b.tokens=b.tokens.slice(0,C),v(b,w,x),i.lines=i.lines.slice(0,y+1)):i.lines=i.lines.slice(0,y),i.isTruncated=i.isTruncated||i.lines.length<R;break n}var I=_.width,A=null==I||"auto"===I;if("string"==typeof I&&"%"===I.charAt(I.length-1))S.percentWidth=I,u.push(S),S.contentWidth=at(S.text,T);else{if(A){var P=_.backgroundColor,E=P&&P.image;E&&s_(E=function(e){if("string"!=typeof e)return e;var t=sw.get(e);return t&&t.image}(E))&&(S.width=Math.max(S.width,E.width*D/E.height))}var L=f&&null!=r?r-w:null;null!=L&&L<S.width?!A||L<M?(S.text="",S.width=S.contentWidth=0):(sT(m,S.text,L-M,T,t.ellipsis,{minChar:t.truncateMinChar}),S.text=m.text,i.isTruncated=i.isTruncated||m.isTruncated,S.width=S.contentWidth=at(S.text,T)):S.contentWidth=at(S.text,T)}S.width+=M,w+=S.width,_&&(x=Math.max(x,S.lineHeight))}v(b,w,x)}i.outerWidth=i.width=nG(r,h),i.outerHeight=i.height=nG(o,c),i.contentHeight=c,i.contentWidth=h,p&&(i.outerWidth+=p[1]+p[3],i.outerHeight+=p[0]+p[2]);for(var y=0;y<u.length;y++){var S=u[y],F=S.percentWidth;S.width=parseInt(F,10)/100*i.width}return i}(lX(e),e),n=t.width,i=t.outerWidth,r=t.outerHeight,o=e.padding,a=e.x||0,s=e.y||0,l=this._defaultStyle,d=e.align||l.align,u=e.verticalAlign||l.verticalAlign;this.isTruncated=!!t.isTruncated;var c=ar(a,i,d),h=ao(s,r,u),p=c,f=h;o&&(p+=o[3],f+=o[0]);var g=p+n;lJ(e)&&this._renderBackground(e,e,c,h,i,r);for(var m=!!e.backgroundColor,v=0;v<t.lines.length;v++){for(var y=t.lines[v],b=y.tokens,x=b.length,w=y.lineHeight,C=y.width,S=0,_=p,k=g,M=x-1,T=void 0;S<x&&(!(T=b[S]).align||"left"===T.align);)this._placeToken(T,e,w,f,_,"left",m),C-=T.width,_+=T.width,S++;for(;M>=0&&"right"===(T=b[M]).align;)this._placeToken(T,e,w,f,k,"right",m),C-=T.width,k-=T.width,M--;for(_+=(n-(_-p)-(g-k)-C)/2;S<=M;)T=b[S],this._placeToken(T,e,w,f,_+T.width/2,"center",m),_+=T.width,S++;f+=w}},t.prototype._placeToken=function(e,t,n,i,r,o,a){var s=t.rich[e.styleName]||{};s.text=e.text;var l=e.verticalAlign,d=i+n/2;"top"===l?d=i+e.height/2:"bottom"===l&&(d=i+n-e.height/2),!e.isLineHolder&&lJ(s)&&this._renderBackground(s,t,"right"===o?r-e.width:"center"===o?r-e.width/2:r,d-e.height/2,e.width,e.height);var u=!!s.backgroundColor,c=e.textPadding;c&&(r=lZ(r,o,c),d-=e.height/2-c[0]-e.innerHeight/2);var h=this._getOrCreateChild(lT),p=h.createStyle();h.useStyle(p);var f=this._defaultStyle,g=!1,m=0,v=lY("fill"in s?s.fill:"fill"in t?t.fill:(g=!0,f.fill)),y=lK("stroke"in s?s.stroke:"stroke"in t?t.stroke:u||a||f.autoStroke&&!g?null:(m=2,f.stroke)),b=s.textShadowBlur>0||t.textShadowBlur>0;p.text=e.text,p.x=r,p.y=d,b&&(p.shadowBlur=s.textShadowBlur||t.textShadowBlur||0,p.shadowColor=s.textShadowColor||t.textShadowColor||"transparent",p.shadowOffsetX=s.textShadowOffsetX||t.textShadowOffsetX||0,p.shadowOffsetY=s.textShadowOffsetY||t.textShadowOffsetY||0),p.textAlign=o,p.textBaseline="middle",p.font=e.font||t3,p.opacity=nW(s.opacity,t.opacity,1),l$(p,s),y&&(p.lineWidth=nW(s.lineWidth,t.lineWidth,m),p.lineDash=nG(s.lineDash,t.lineDash),p.lineDashOffset=t.lineDashOffset||0,p.stroke=y),v&&(p.fill=v);var x=e.contentWidth,w=e.contentHeight;h.setBoundingRect(new rt(ar(p.x,x,p.textAlign),ao(p.y,w,p.textBaseline),x,w))},t.prototype._renderBackground=function(e,t,n,i,r,o){var a,s,l=e.backgroundColor,d=e.borderWidth,u=e.borderColor,c=l&&l.image,h=l&&!c,p=e.borderRadius,f=this;if(h||e.lineHeight||d&&u){(a=this._getOrCreateChild(lN)).useStyle(a.createStyle()),a.style.fill=null;var g=a.shape;g.x=n,g.y=i,g.width=r,g.height=o,g.r=p,a.dirtyShape()}if(h){var m=a.style;m.fill=l||null,m.fillOpacity=nG(e.fillOpacity,1)}else if(c){(s=this._getOrCreateChild(lI)).onload=function(){f.dirtyStyle()};var v=s.style;v.image=l.image,v.x=n,v.y=i,v.width=r,v.height=o}if(d&&u){var m=a.style;
422m.lineWidth=d,m.stroke=u,m.strokeOpacity=nG(e.strokeOpacity,1),m.lineDash=e.borderDash,m.lineDashOffset=e.borderDashOffset||0,a.strokeContainThreshold=0,a.hasFill()&&a.hasStroke()&&(m.strokeFirst=!0,m.lineWidth*=2)}var y=(a||s).style;y.shadowBlur=e.shadowBlur||0,y.shadowColor=e.shadowColor||"transparent",y.shadowOffsetX=e.shadowOffsetX||0,y.shadowOffsetY=e.shadowOffsetY||0,y.opacity=nW(e.opacity,t.opacity,1)},t.makeFont=function(e){var t="";return lU(e)&&(t=[e.fontStyle,e.fontWeight,lW(e.fontSize),e.fontFamily||"sans-serif"].join(" ")),t&&nK(t)||e.textFont||e.font},t}(sV),lV={left:!0,right:1,center:1},lH={top:1,bottom:1,middle:1},lG=["fontStyle","fontWeight","fontSize","fontFamily"];function lW(e){return"string"==typeof e&&(-1!==e.indexOf("px")||-1!==e.indexOf("rem")||-1!==e.indexOf("em"))?e:isNaN(+e)?"12px":e+"px"}function l$(e,t){for(var n=0;n<lG.length;n++){var i=lG[n],r=t[i];null!=r&&(e[i]=r)}}function lU(e){return null!=e.fontSize||e.fontFamily||e.fontWeight}function lq(e){if(e){e.font=lj.makeFont(e);var t=e.align;"middle"===t&&(t="center"),e.align=null==t||lV[t]?t:"left";var n=e.verticalAlign;"center"===n&&(n="middle"),e.verticalAlign=null==n||lH[n]?n:"top",e.padding&&(e.padding=nU(e.padding))}}function lK(e,t){return null==e||t<=0||"transparent"===e||"none"===e?null:e.image||e.colorStops?"#000":e}function lY(e){return null==e||"none"===e?null:e.image||e.colorStops?"#000":e}function lZ(e,t,n){return"right"===t?e-n[1]:"center"===t?e+n[3]/2-n[1]/2:e+n[3]}function lX(e){var t=e.text;return null!=t&&(t+=""),t}function lJ(e){return!!(e.backgroundColor||e.lineHeight||e.borderWidth&&e.borderColor)}var lQ=a9(),l0=function(e,t,n,i){if(i){var r=lQ(i);r.dataIndex=n,r.dataType=t,r.seriesIndex=e,r.ssrType="chart","group"===i.type&&i.traverse(function(i){var r=lQ(i);r.seriesIndex=e,r.dataIndex=n,r.dataType=t,r.ssrType="chart"})}},l1=1,l2={},l3=a9(),l5=a9(),l4=["emphasis","blur","select"],l6=["normal","emphasis","blur","select"],l8="highlight",l7="downplay",l9="select",de="unselect",dt="toggleSelect";function dn(e){return null!=e&&"none"!==e}function di(e,t,n){e.onHoverStateChange&&(e.hoverState||0)!==n&&e.onHoverStateChange(t),e.hoverState=n}function dr(e){di(e,"emphasis",2)}function da(e){2===e.hoverState&&di(e,"normal",0)}function ds(e){di(e,"blur",1)}function dl(e){1===e.hoverState&&di(e,"normal",0)}function dd(e){e.selected=!0}function du(e){e.selected=!1}function dc(e,t,n){t(e,n),e.isGroup&&e.traverse(function(e){t(e,n)})}function dh(e,t){switch(t){case"emphasis":e.hoverState=2;break;case"normal":e.hoverState=0;break;case"blur":e.hoverState=1;break;case"select":e.selected=!0}}function dp(e,t){var n,i,r,o,a,s=this.states[e];if(this.style){if("emphasis"===e)return function(e,t,n,i){var r=n&&nv(n,"select")>=0,o=!1;if(e instanceof lk){var a=l3(e),s=r&&a.selectFill||a.normalFill,l=r&&a.selectStroke||a.normalStroke;if(dn(s)||dn(l)){var d=(i=i||{}).style||{};"inherit"===d.fill?(o=!0,i=nf({},i),(d=nf({},d)).fill=s):!dn(d.fill)&&dn(s)?(o=!0,i=nf({},i),(d=nf({},d)).fill=oa(s)):!dn(d.stroke)&&dn(l)&&(o||(i=nf({},i),d=nf({},d)),d.stroke=oa(l)),i.style=d}}if(i&&null==i.z2){o||(i=nf({},i));var u=e.z2EmphasisLift;i.z2=e.z2+(null!=u?u:10)}return i}(this,0,t,s);else if("blur"===e)return n=s,i=nv(this.currentStates,e)>=0,r=this.style.opacity,o=i?null:function(e,t,n,i){for(var r=e.style,o={},a=0;a<t.length;a++){var s=t[a],l=r[s];o[s]=null==l?i&&i[s]:l}for(var a=0;a<e.animators.length;a++){var d=e.animators[a];d.__fromStateTransition&&0>d.__fromStateTransition.indexOf(n)&&"style"===d.targetName&&d.saveTo(o,t)}return o}(this,["opacity"],e,{opacity:1}),null==(a=(n=n||{}).style||{}).opacity&&(n=nf({},n),a=nf({opacity:i?r:.1*o.opacity},a),n.style=a),n;else if("select"===e){var l=s;if(l&&null==l.z2){l=nf({},l);var d=this.z2SelectLift;l.z2=this.z2+(null!=d?d:9)}return l}}return s}function df(e){e.stateProxy=dp;var t=e.getTextContent(),n=e.getTextGuideLine();t&&(t.stateProxy=dp),n&&(n.stateProxy=dp)}function dg(e,t){db(e,t)||e.__highByOuter||dc(e,dr)}function dm(e,t){db(e,t)||e.__highByOuter||dc(e,da)}function dv(e,t){e.__highByOuter|=1<<(t||0),dc(e,dr)}function dy(e,t){(e.__highByOuter&=~(1<<(t||0)))||dc(e,da)}function db(e,t){return e.__highDownSilentOnTouch&&t.zrByTouch}function dx(e){var t=e.getModel(),n=[],i=[];t.eachComponent(function(t,r){var o=l5(r),a="series"===t,s=a?e.getViewOfSeriesModel(r):e.getViewOfComponentModel(r);a||i.push(s),o.isBlured&&(s.group.traverse(function(e){dl(e)}),a&&n.push(r)),o.isBlured=!1}),nw(i,function(e){e&&e.toggleBlurSeries&&e.toggleBlurSeries(n,!1,t)})}function dw(e,t,n,i){var r=i.getModel();function o(e,t){for(var n=0;n<t.length;n++){var i=e.getItemGraphicEl(t[n]);i&&dc(i,dl)}}if((n=n||"coordinateSystem",null!=e)&&t&&"none"!==t){var a=r.getSeriesByIndex(e),s=a.coordinateSystem;s&&s.master&&(s=s.master);var l=[];r.eachSeries(function(e){var r=a===e,d=e.coordinateSystem;d&&d.master&&(d=d.master);var u=d&&s?d===s:r;if(!("series"===n&&!r||"coordinateSystem"===n&&!u||"series"===t&&r)){if(i.getViewOfSeriesModel(e).group.traverse(function(e){e.__highByOuter&&r&&"self"===t||ds(e)}),nx(t))o(e.getData(),t);else if(nL(t))for(var c=nM(t),h=0;h<c.length;h++)o(e.getData(c[h]),t[c[h]]);l.push(e),l5(e).isBlured=!0}}),r.eachComponent(function(e,t){if("series"!==e){var n=i.getViewOfComponentModel(t);n&&n.toggleBlurSeries&&n.toggleBlurSeries(l,!0,r)}})}}function dC(e,t,n){if(null!=e&&null!=t){var i=n.getModel().getComponent(e,t);if(i){l5(i).isBlured=!0;var r=n.getViewOfComponentModel(i);r&&r.focusBlurEnabled&&r.group.traverse(function(e){ds(e)})}}}function dS(e,t,n,i){var r,o={focusSelf:!1,dispatchers:null};if(null==e||"series"===e||null==t||null==n)return o;var a=i.getModel().getComponent(e,t);if(!a)return o;var s=i.getViewOfComponentModel(a);if(!s||!s.findHighDownDispatchers)return o;for(var l=s.findHighDownDispatchers(n),d=0;d<l.length;d++)if("self"===lQ(l[d]).focus){r=!0;break}return{focusSelf:r,dispatchers:l}}function d_(e){nw(e.getAllData(),function(t){var n=t.data,i=t.type;n.eachItemGraphicEl(function(t,n){e.isSelected(n,i)?dc(t,dd):dc(t,du)})})}function dk(e,t,n){dA(e,!0),dc(e,df),dT(e,t,n)}function dM(e,t,n,i){i?dA(e,!1):dk(e,t,n)}function dT(e,t,n){var i=lQ(e);null!=t?(i.focus=t,i.blurScope=n):i.focus&&(i.focus=null)}var dD=["emphasis","blur","select"],dR={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function dI(e,t,n,i){n=n||"itemStyle";for(var r=0;r<dD.length;r++){var o=dD[r],a=t.getModel([o,n]);
422e.ensureState(o).style=i?i(a):a[dR[n]]()}}function dA(e,t){var n=!1===t;e.highDownSilentOnTouch&&(e.__highDownSilentOnTouch=e.highDownSilentOnTouch),(!n||e.__highDownDispatcher)&&(e.__highByOuter=e.__highByOuter||0,e.__highDownDispatcher=!n)}function dP(e){return!!(e&&e.__highDownDispatcher)}function dE(e){var t=e.type;return t===l9||t===de||t===dt}function dL(e){var t=e.type;return t===l8||t===l7}var dF=a9();function dO(e,t,n,i,r){if(t&&t.ecModel){var o,a=t.ecModel.getUpdatePayload();o=a&&a.animation}var s=t&&t.isAnimationEnabled(),l="update"===e;if(!s)return null;var d=void 0,u=void 0,c=void 0;return i?(d=nG(i.duration,200),u=nG(i.easing,"cubicOut"),c=0):(d=t.getShallow(l?"animationDurationUpdate":"animationDuration"),u=t.getShallow(l?"animationEasingUpdate":"animationEasing"),c=t.getShallow(l?"animationDelayUpdate":"animationDelay")),o&&(null!=o.duration&&(d=o.duration),null!=o.easing&&(u=o.easing),null!=o.delay&&(c=o.delay)),nI(c)&&(c=c(n,r)),nI(d)&&(d=d(n)),{duration:d||0,delay:c,easing:u}}function dN(e,t,n,i,r,o,a){var s,l=!1;nI(r)?(a=o,o=r,r=null):nL(r)&&(o=r.cb,a=r.during,l=r.isFrom,s=r.removeOpt,r=r.dataIndex);var d="leave"===e;d||t.stopAnimation("leave");var u=dO(e,i,r,d?s||{}:null,i&&i.getAnimationDelayParams?i.getAnimationDelayParams(t,r):null);if(u&&u.duration>0){var c={duration:u.duration,delay:u.delay||0,easing:u.easing,done:o,force:!!o||!!a,setToFinal:!d,scope:e,during:a};l?t.animateFrom(n,c):t.animateTo(n,c)}else t.stopAnimation(),l||t.attr(n),a&&a(1),o&&o()}function dB(e,t,n,i,r,o){dN("update",e,t,n,i,r,o)}function dz(e,t,n,i,r,o){dN("enter",e,t,n,i,r,o)}function dj(e){if(!e.__zr)return!0;for(var t=0;t<e.animators.length;t++)if("leave"===e.animators[t].scope)return!0;return!1}function dV(e,t,n,i,r,o){dj(e)||dN("leave",e,t,n,i,r,o)}function dH(e,t,n,i){e.removeTextContent(),e.removeTextGuideLine(),dV(e,{style:{opacity:0}},t,n,i)}function dG(e,t,n){function i(){e.parent&&e.parent.remove(e)}e.isGroup?e.traverse(function(e){e.isGroup||dH(e,t,n,i)}):dH(e,t,n,i)}function dW(e){dF(e).oldStyle=e.style}var d$={};function dU(e,t){for(var n=0;n<l4.length;n++){var i=l4[n],r=t[i],o=e.ensureState(i);o.style=o.style||{},o.style.text=r}var a=e.currentStates.slice();e.clearStates(!0),e.setStyle({text:t.normal}),e.useStates(a,!0)}function dq(e,t,n){var i,r=e.labelFetcher,o=e.labelDataIndex,a=e.labelDimIndex,s=t.normal;r&&(i=r.getFormattedLabel(o,"normal",null,a,s&&s.get("formatter"),null!=n?{interpolatedValue:n}:null)),null==i&&(i=nI(e.defaultText)?e.defaultText(o,e,n):e.defaultText);for(var l={normal:i},d=0;d<l4.length;d++){var u=l4[d],c=t[u];l[u]=nG(r?r.getFormattedLabel(o,u,null,a,c&&c.get("formatter")):null,i)}return l}function dK(e,t,n,i){n=n||d$;for(var r=e instanceof lj,o=!1,a=0;a<l6.length;a++){var s=t[l6[a]];if(s&&s.getShallow("show")){o=!0;break}}var l=r?e:e.getTextContent();if(o){!r&&(l||(l=new lj,e.setTextContent(l)),e.stateProxy&&(l.stateProxy=e.stateProxy));var d=dq(n,t),u=t.normal,c=!!u.getShallow("show"),h=dZ(u,i&&i.normal,n,!1,!r);h.text=d.normal,r||e.setTextConfig(dX(u,n,!1));for(var a=0;a<l4.length;a++){var p=l4[a],s=t[p];if(s){var f=l.ensureState(p),g=!!nG(s.getShallow("show"),c);g!==c&&(f.ignore=!g),f.style=dZ(s,i&&i[p],n,!0,!r),f.style.text=d[p],r||(e.ensureState(p).textConfig=dX(s,n,!0))}}l.silent=!!u.getShallow("silent"),null!=l.style.x&&(h.x=l.style.x),null!=l.style.y&&(h.y=l.style.y),l.ignore=!c,l.useStyle(h),l.dirty(),n.enableTextSetter&&(d3(l).setLabelText=function(e){var i=dq(n,t,e);dU(l,i)})}else l&&(l.ignore=!0);e.dirty()}function dY(e,t){t=t||"label";for(var n={normal:e.getModel(t)},i=0;i<l4.length;i++){var r=l4[i];n[r]=e.getModel([r,t])}return n}function dZ(e,t,n,i,r){var o={};return function(e,t,n,i,r){n=n||d$;var o,a=t.ecModel,s=a&&a.option.textStyle,l=function(e){for(var t;e&&e!==e.ecModel;){var n=(e.option||d$).rich;if(n){t=t||{};for(var i=nM(n),r=0;r<i.length;r++)t[i[r]]=1}e=e.parentModel}return t}(t);if(l){for(var d in o={},l)if(l.hasOwnProperty(d)){var u=t.getModel(["rich",d]);d1(o[d]={},u,s,n,i,r,!1,!0)}}o&&(e.rich=o);var c=t.get("overflow");c&&(e.overflow=c);var h=t.get("minMargin");null!=h&&(e.margin=h),d1(e,t,s,n,i,r,!0,!1)}(o,e,n,i,r),t&&nf(o,t),o}function dX(e,t,n){t=t||{};var i,r={},o=e.getShallow("rotate"),a=nG(e.getShallow("distance"),n?null:5),s=e.getShallow("offset");return"outside"===(i=e.getShallow("position")||(n?null:"inside"))&&(i=t.defaultOutsidePosition||"top"),null!=i&&(r.position=i),null!=s&&(r.offset=s),null!=o&&(r.rotation=o*=Math.PI/180),null!=a&&(r.distance=a),r.outsideFill="inherit"===e.get("
422color")?t.inheritColor||null:"auto",r}var dJ=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],dQ=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],d0=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function d1(e,t,n,i,r,o,a,s){n=!r&&n||d$;var l=i&&i.inheritColor,d=t.getShallow("color"),u=t.getShallow("textBorderColor"),c=nG(t.getShallow("opacity"),n.opacity);("inherit"===d||"auto"===d)&&(d=l||null),("inherit"===u||"auto"===u)&&(u=l||null),o||(d=d||n.color,u=u||n.textBorderColor),null!=d&&(e.fill=d),null!=u&&(e.stroke=u);var h=nG(t.getShallow("textBorderWidth"),n.textBorderWidth);null!=h&&(e.lineWidth=h);var p=nG(t.getShallow("textBorderType"),n.textBorderType);null!=p&&(e.lineDash=p);var f=nG(t.getShallow("textBorderDashOffset"),n.textBorderDashOffset);null!=f&&(e.lineDashOffset=f),r||null!=c||s||(c=i&&i.defaultOpacity),null!=c&&(e.opacity=c),r||o||null!=e.fill||!i.inheritColor||(e.fill=i.inheritColor);for(var g=0;g<dJ.length;g++){var m=dJ[g],v=nG(t.getShallow(m),n[m]);null!=v&&(e[m]=v)}for(var g=0;g<dQ.length;g++){var m=dQ[g],v=t.getShallow(m);null!=v&&(e[m]=v)}if(null==e.verticalAlign){var y=t.getShallow("baseline");null!=y&&(e.verticalAlign=y)}if(!a||!i.disableBox){for(var g=0;g<d0.length;g++){var m=d0[g],v=t.getShallow(m);null!=v&&(e[m]=v)}var b=t.getShallow("borderType");null!=b&&(e.borderDash=b),("auto"===e.backgroundColor||"inherit"===e.backgroundColor)&&l&&(e.backgroundColor=l),("auto"===e.borderColor||"inherit"===e.borderColor)&&l&&(e.borderColor=l)}}function d2(e,t){var n=t&&t.getModel("textStyle");return nK([e.fontStyle||n&&n.getShallow("fontStyle")||"",e.fontWeight||n&&n.getShallow("fontWeight")||"",(e.fontSize||n&&n.getShallow("fontSize")||12)+"px",e.fontFamily||n&&n.getShallow("fontFamily")||"sans-serif"].join(" "))}var d3=a9();function d5(e,t,n,i){if(e){var r=d3(e);r.prevValue=r.value,r.value=n;var o=t.normal;r.valueAnimation=o.get("valueAnimation"),r.valueAnimation&&(r.precision=o.get("precision"),r.defaultInterpolatedText=i,r.statesModels=t)}}function d4(e,t,n,i,r){var o=d3(e);if(o.valueAnimation&&o.prevValue!==o.value){var a=o.defaultInterpolatedText,s=nG(o.interpolatedValue,o.prevValue),l=o.value;e.percent=0,(null==o.prevValue?dz:dB)(e,{percent:1},i,t,null,function(i){var d=sl(n,o.precision,s,l,i);o.interpolatedValue=1===i?null:d,dU(e,dq({labelDataIndex:t,labelFetcher:r,defaultText:a?a(d):d+""},o.statesModels,d))})}}var d6=["textStyle","color"],d8=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],d7=new lj,d9=function(){function e(){}return e.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow("color")||(!e&&t?t.get(d6):null)},e.prototype.getFont=function(){return d2({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},e.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},n=0;n<d8.length;n++)t[d8[n]]=this.getShallow(d8[n]);return d7.useStyle(t),d7.update(),d7.getBoundingRect()},e}(),ue=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],ut=sy(ue),un=function(){function e(){}return e.prototype.getLineStyle=function(e){return ut(this,e)},e}(),ui=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],ur=sy(ui),uo=function(){function e(){}return e.prototype.getItemStyle=function(e,t){return ur(this,e,t)},e}(),ua=function(){function e(e,t,n){this.parentModel=t,this.ecModel=n,this.option=e}return e.prototype.init=function(e,t,n){for(var i=[],r=3;r<arguments.length;r++)i[r-3]=arguments[r]},e.prototype.mergeOption=function(e,t){nh(this.option,e,!0)},e.prototype.get=function(e,t){return null==e?this.option:this._doGet(this.parsePath(e),!t&&this.parentModel)},e.prototype.getShallow=function(e,t){var n=this.option,i=null==n?n:n[e];if(null==i&&!t){var r=this.parentModel;r&&(i=r.getShallow(e))}return i},e.prototype.getModel=function(t,n){var i=null!=t,r=i?this.parsePath(t):null;return new e(i?this._doGet(r):this.option,n=n||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(r)),this.ecModel)},e.prototype.isEmpty=function(){return null==this.option},e.prototype.restoreData=function(){},e.prototype.clone=function(){return new this.constructor(nc(this.option))},e.prototype.parsePath=function(e){return"string"==typeof e?e.split("."):e},e.prototype.resolveParentPath=function(e){return e},e.prototype.isAnimationEnabled=function(){if(!t1.node&&this.option){if(null!=this.option.animation)return!!this.option.animation;else if(this.parentModel)return this.parentModel.isAnimationEnabled()}},e.prototype._doGet=function(e,t){var n=this.option;if(!e)return n;for(var i=0;
422i<e.length&&(!e[i]||null!=(n=n&&"object"==typeof n?n[e[i]]:null));i++);return null==n&&t&&(n=t._doGet(this.resolveParentPath(e),t.parentModel)),n},e}();sh(ua),f=["__\0is_clz",sf++].join("_"),ua.prototype[f]=!0,ua.isInstance=function(e){return!!(e&&e[f])},nb(ua,un),nb(ua,uo),nb(ua,sx),nb(ua,d9);var us=Math.round(10*Math.random());function ul(e){return[e||"",us++].join("_")}function ud(e,t){return nh(nh({},e,!0),t,!0)}var uu={},uc={},uh=t1.domSupported&&(document.documentElement.lang||navigator.language||navigator.browserLanguage||"EN").toUpperCase().indexOf("ZH")>-1?"ZH":"EN";function up(e,t){uc[e=e.toUpperCase()]=new ua(t),uu[e]=t}up("EN",{time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}}),up("ZH",{time:{month:["䏿","äºæ","䏿","åæ","äºæ","å
æ","䏿","å
«æ","乿","åæ","å䏿","åäºæ"],monthAbbr:["1æ","2æ","3æ","4æ","5æ","6æ","7æ","8æ","9æ","10æ","11æ","12æ"],dayOfWeek:["æææ¥","ææä¸","ææäº","ææä¸","ææå","ææäº","ææå
"],dayOfWeekAbbr:["æ¥","ä¸","äº","ä¸","å","äº","å
"]},legend:{selector:{all:"å
¨é",inverse:"åé"}},toolbox:{brush:{title:{rect:"ç©å½¢éæ©",polygon:"åé",lineX:"横åéæ©",lineY:"纵åéæ©",keep:"ä¿æéæ©",clear:"æ¸
é¤éæ©"}},dataView:{title:"æ°æ®è§å¾",lang:["æ°æ®è§å¾","å
³é","å·æ°"]},dataZoom:{title:{zoom:"åºå缩æ¾",back:"åºå缩æ¾è¿å"}},magicType:{title:{line:"åæ¢ä¸ºæçº¿å¾",bar:"åæ¢ä¸ºæ±ç¶å¾",stack:"åæ¢ä¸ºå å ",tiled:"åæ¢ä¸ºå¹³éº"}},restore:{title:"è¿å"},saveAsImage:{title:"ä¿å为å¾ç",lang:["å³é®å¦å为å¾ç"]}},series:{typeNames:{pie:"饼å¾",bar:"æ±ç¶å¾",line:"æçº¿å¾",scatter:"æ£ç¹å¾",effectScatter:"æ¶æ¼ªæ£ç¹å¾",radar:"é·è¾¾å¾",tree:"æ å¾",treemap:"ç©å½¢æ å¾",boxplot:"ç®±åå¾",candlestick:"K线å¾",k:"K线å¾",heatmap:"çåå¾",map:"å°å¾",parallel:"å¹³è¡åæ å¾",lines:"线å¾",graph:"å
³ç³»å¾",sankey:"æ¡åºå¾",funnel:"æ¼æå¾",gauge:"仪表çå¾",pictorialBar:"象形æ±å¾",themeRiver:"䏻颿²³æµå¾",sunburst:"ææ¥å¾",custom:"èªå®ä¹å¾è¡¨",chart:"å¾è¡¨"}},aria:{general:{withTitle:"è¿æ¯ä¸ä¸ªå
³äºâ{title}âçå¾è¡¨ã",withoutTitle:"è¿æ¯ä¸ä¸ªå¾è¡¨ï¼"},series:{single:{prefix:"",withName:"å¾è¡¨ç±»åæ¯{seriesType}ï¼è¡¨ç¤º{seriesName}ã",withoutName:"å¾è¡¨ç±»åæ¯{seriesType}ã"},multiple:{prefix:"å®ç±{seriesCount}个å¾è¡¨ç³»åç»æã",withName:"第{seriesId}ä¸ªç³»åæ¯ä¸ä¸ªè¡¨ç¤º{seriesName}ç{seriesType}
422ï¼",withoutName:"第{seriesId}ä¸ªç³»åæ¯ä¸ä¸ª{seriesType}ï¼",separator:{middle:"ï¼",end:"ã"}}},data:{allData:"å
¶æ°æ®æ¯ââ",partialData:"å
¶ä¸ï¼å{displayCnt}项æ¯ââ",withName:"{name}çæ°æ®æ¯{value}",withoutName:"{value}",separator:{middle:"ï¼",end:""}}}});var uf={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},ug="{yyyy}-{MM}-{dd}",um={year:"{yyyy}",month:"{yyyy}-{MM}",day:ug,hour:ug+" "+uf.hour,minute:ug+" "+uf.minute,second:ug+" "+uf.second,millisecond:uf.none},uv=["year","month","day","hour","minute","second","millisecond"],uy=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function ub(e,t){return e+="","0000".substr(0,t-e.length)+e}function ux(e){switch(e){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return e}}function uw(e,t,n,i){var r=aj(e),o=r[u_(n)](),a=r[uk(n)]()+1,s=Math.floor((a-1)/3)+1,l=r[uM(n)](),d=r["get"+(n?"UTC":"")+"Day"](),u=r[uT(n)](),c=(u-1)%12+1,h=r[uD(n)](),p=r[uR(n)](),f=r[uI(n)](),g=u>=12?"pm":"am",m=g.toUpperCase(),v=(i instanceof ua?i:uc[i||uh]||uc.EN).getModel("time"),y=v.get("month"),b=v.get("monthAbbr"),x=v.get("dayOfWeek"),w=v.get("dayOfWeekAbbr");return(t||"").replace(/{a}/g,g+"").replace(/{A}/g,m+"").replace(/{yyyy}/g,o+"").replace(/{yy}/g,ub(o%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,y[a-1]).replace(/{MMM}/g,b[a-1]).replace(/{MM}/g,ub(a,2)).replace(/{M}/g,a+"").replace(/{dd}/g,ub(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,x[d]).replace(/{ee}/g,w[d]).replace(/{e}/g,d+"").replace(/{HH}/g,ub(u,2)).replace(/{H}/g,u+"").replace(/{hh}/g,ub(c+"",2)).replace(/{h}/g,c+"").replace(/{mm}/g,ub(h,2)).replace(/{m}/g,h+"").replace(/{ss}/g,ub(p,2)).replace(/{s}/g,p+"").replace(/{SSS}/g,ub(f,3)).replace(/{S}/g,f+"")}function uC(e,t){var n=aj(e),i=n[uk(t)]()+1,r=n[uM(t)](),o=n[uT(t)](),a=n[uD(t)](),s=n[uR(t)](),l=0===n[uI(t)](),d=l&&0===s,u=d&&0===a,c=u&&0===o,h=c&&1===r;if(h&&1===i)return"year";if(h)return"month";if(c)return"day";if(u)return"hour";if(d)return"minute";else if(l)return"second";else return"millisecond"}function uS(e,t,n){var i=nE(e)?aj(e):e;switch(t=t||uC(e,n)){case"year":return i[u_(n)]();case"half-year":return+(i[uk(n)]()>=6);case"quarter":return Math.floor((i[uk(n)]()+1)/4);case"month":return i[uk(n)]();case"day":return i[uM(n)]();case"half-day":return i[uT(n)]()/24;case"hour":return i[uT(n)]();case"minute":return i[uD(n)]();case"second":return i[uR(n)]();case"millisecond":return i[uI(n)]()}}function u_(e){return e?"getUTCFullYear":"getFullYear"}function uk(e){return e?"getUTCMonth":"getMonth"}function uM(e){return e?"getUTCDate":"getDate"}function uT(e){return e?"getUTCHours":"getHours"}function uD(e){return e?"getUTCMinutes":"getMinutes"}function uR(e){return e?"getUTCSeconds":"getSeconds"}function uI(e){return e?"getUTCMilliseconds":"getMilliseconds"}function uA(e){return e?"setUTCMonth":"setMonth"}function uP(e){return e?"setUTCDate":"setDate"}function uE(e){return e?"setUTCHours":"setHours"}function uL(e){return e?"setUTCMinutes":"setMinutes"}function uF(e){return e?"setUTCSeconds":"setSeconds"}function uO(e){return e?"setUTCMilliseconds":"setMilliseconds"}function uN(e){if(!aq(e))return nA(e)?e:"-";var t=(e+"").split(".");return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:"")}function uB(e,t){return e=(e||"").toLowerCase().replace(/-(.)/g,function(e,t){return t.toUpperCase()}),t&&e&&(e=e.charAt(0).toUpperCase()+e.slice(1)),e}function uz(e,t,n){function i(e){return e&&nK(e)?e:"-"}function r(e){return!!(null!=e&&!isNaN(e)&&isFinite(e))}var o="time"===t,a=e instanceof Date;if(o||a){var s=o?aj(e):e;if(!isNaN(+s))return uw(s,"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}",n);if(a)return"-"}if("ordinal"===t)return nP(e)?i(e):nE(e)&&r(e)?e+"":"-";var l=aU(e);return r(l)?uN(l):nP(e)?i(e):"boolean"==typeof e?e+"":"-"}var uj=["a","b","c","d","e","f","g"],uV=function(e,t){return"{"+e+(null==t?"":t)+"}"};function uH(e,t,n){nR(t)||(t=[t]);var i=t.length;if(!i)return"";for(var r=t[0].$vars||[],o=0;o<r.length;o++){var a=uj[o];e=e.replace(uV(a),uV(a,0))}for(var s=0;s<i;s++)for(var l=0;l<r.length;l++){var d=t[s][r[l]];e=e.replace(uV(uj[l],s),n?iE(d):d)}return e}function uG(e,t){var n=nA(e)?{color:e,extraCssText:t}:e||{},i=n.color,r=n.type;t=n.extraCssText;var o=n.renderMode||"html";return i?"html"===o?"subItem"===r?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+iE(i)+";"+(t||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+iE(i)+";"+(t||"")+'"></span>':{renderMode:o,content:"{"+(n.markerId||"markerX")+"|} ",style:"subItem"===r?{width:4,height:4,borderRadius:2,backgroundColor:i}:{width:10,height:10,borderRadius:5,backgroundColor:i}}:""}function uW(e,t,n){("week"===e||"month"===e||"quarter"===e||"half-year"===e||"year"===e)&&(e="MM-dd\nyyyy");var i=aj(t),r=n?"getUTC":"get",o=i[r+"FullYear"](),a=i[r+"Month"]()+1,s=i[r+"Date"](),l=i[r+"Hours"](),d=i[r+"Minutes"](),u=i[r+"Seconds"](),c=i[r+"Milliseconds"]();return e.replace("MM",ub(a,2)).replace("M",a).replace("yyyy",o).replace("yy",ub(o%100+"",2)).replace("dd",ub(s,2)).replace("d",s).replace("hh",ub(l,2)).replace("h",l).replace("mm",ub(d,2)).replace("m",d).replace("ss",ub(u,2)).replace("s",u).replace("SSS",ub(c,3))}function u$(e){return e?e.charAt(0).toUpperCase()+e.substr(1):e}function uU(e,t){return t=t||"transparent",nA(e)?e:nL(e)&&e.colorStops&&(e.colorStops[0]||{}).color||t}function uq(e,t){if("_blank"===t||"blank"===t){var n=window.open();n.opener=null,n.location.href=e}else window.open(e,t)}var uK=["left","right","top","bottom","width","height"],uY=[["width","left","right"],["height","top","bottom"]];function uZ(e,t,n,i,r){var o=0,a=0;null==i&&(i=1/0),null==r&&(r=1/0);var s=0;
vendor: 2,807 bytes, line 422
422t.eachChild(function(l,d){var u,c,h=l.getBoundingRect(),p=t.childAt(d+1),f=p&&p.getBoundingRect();if("horizontal"===e){var g=h.width+(f?-f.x+h.x:0);(u=o+g)>i||l.newline?(o=0,u=g,a+=s+n,s=h.height):s=Math.max(s,h.height)}else{var m=h.height+(f?-f.y+h.y:0);(c=a+m)>r||l.newline?(o+=s+n,a=0,c=m,s=h.width):s=Math.max(s,h.width)}l.newline||(l.x=o,l.y=a,l.markRedraw(),"horizontal"===e?o=u+n:a=c+n)})}function uX(e,t,n){n=nU(n||0);var i=t.width,r=t.height,o=aR(e.left,i),a=aR(e.top,r),s=aR(e.right,i),l=aR(e.bottom,r),d=aR(e.width,i),u=aR(e.height,r),c=n[2]+n[0],h=n[1]+n[3],p=e.aspect;switch(isNaN(d)&&(d=i-s-h-o),isNaN(u)&&(u=r-l-c-a),null!=p&&(isNaN(d)&&isNaN(u)&&(p>i/r?d=.8*i:u=.8*r),isNaN(d)&&(d=p*u),isNaN(u)&&(u=d/p)),isNaN(o)&&(o=i-s-d-h),isNaN(a)&&(a=r-l-u-c),e.left||e.right){case"center":o=i/2-d/2-n[3];break;case"right":o=i-d-h}switch(e.top||e.bottom){case"middle":case"center":a=r/2-u/2-n[0];break;case"bottom":a=r-u-c}o=o||0,a=a||0,isNaN(d)&&(d=i-h-o-(s||0)),isNaN(u)&&(u=r-c-a-(l||0));var f=new rt(o+n[3],a+n[0],d,u);return f.margin=n,f}function uJ(e,t,n,i,r,o){var a,s=!r||!r.hv||r.hv[0],l=!r||!r.hv||r.hv[1],d=r&&r.boundingMode||"all";if((o=o||e).x=e.x,o.y=e.y,!s&&!l)return!1;if("raw"===d)a="group"===e.type?new rt(0,0,+t.width||0,+t.height||0):e.getBoundingRect();else if(a=e.getBoundingRect(),e.needLocalTransform()){var u=e.getLocalTransform();(a=a.clone()).applyTransform(u)}var c=uX(ng({width:a.width,height:a.height},t),n,i),h=s?c.x-a.x:0,p=l?c.y-a.y:0;return"raw"===d?(o.x=h,o.y=p):(o.x+=h,o.y+=p),o===e&&e.markRedraw(),!0}function uQ(e){var t=e.layoutMode||e.constructor.layoutMode;return nL(t)?t:t?{type:t}:null}function u0(e,t,n){var i=n&&n.ignoreSize;nR(i)||(i=[i,i]);var r=a(uY[0],0),o=a(uY[1],1);function a(n,r){var o={},a=0,d={},u=0;if(nw(n,function(t){d[t]=e[t]}),nw(n,function(e){s(t,e)&&(o[e]=d[e]=t[e]),l(o,e)&&a++,l(d,e)&&u++}),i[r])return l(t,n[1])?d[n[2]]=null:l(t,n[2])&&(d[n[1]]=null),d;if(2===u||!a)return d;if(a>=2)return o;for(var c=0;c<n.length;c++){var h=n[c];if(!s(o,h)&&s(e,h)){o[h]=e[h];break}}return o}function s(e,t){return e.hasOwnProperty(t)}function l(e,t){return null!=e[t]&&"auto"!==e[t]}function d(e,t,n){nw(e,function(e){t[e]=n[e]})}d(uY[0],e,r),d(uY[1],e,o)}function u1(e){return u2({},e)}function u2(e,t){return t&&e&&nw(uK,function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e}nD(uZ,"vertical"),nD(uZ,"horizontal");var u3=a9(),u5=function(e){var t;function n(t,n,i){var r=e.call(this,t,n,i)||this;return r.uid=ul("ec_cpt_model"),r}return(0,tQ.__extends)(n,e),n.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n)},n.prototype.mergeDefaultAndTheme=function(e,t){var n=uQ(this),i=n?u1(e):{};nh(e,t.getTheme().get(this.mainType)),nh(e,this.getDefaultOption()),n&&u0(e,i,n)},n.prototype.mergeOption=function(e,t){nh(this.option,e,!0);var n=uQ(this);
422n&&u0(this.option,e,n)},n.prototype.optionUpdated=function(e,t){},n.prototype.getDefaultOption=function(){var e=this.constructor;if(!(e&&e[su]))return e.defaultOption;var t=u3(this);if(!t.defaultOption){for(var n=[],i=e;i;){var r=i.prototype.defaultOption;r&&n.push(r),i=i.superClass}for(var o={},a=n.length-1;a>=0;a--)o=nh(o,n[a],!0);t.defaultOption=o}return t.defaultOption},n.prototype.getReferringComponents=function(e,t){return so(this.ecModel,e,{index:this.get(e+"Index",!0),id:this.get(e+"Id",!0)},t)},n.prototype.getBoxLayoutParams=function(){return{left:this.get("left"),top:this.get("top"),right:this.get("right"),bottom:this.get("bottom"),width:this.get("width"),height:this.get("height")}},n.prototype.getZLevelKey=function(){return""},n.prototype.setZLevel=function(e){this.option.zlevel=e},n.protoInitialize=void((t=n.prototype).type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0),n}(ua);sp(u5,ua),sv(u5),g={},u5.registerSubTypeDefaulter=function(e,t){g[sc(e).main]=t},u5.determineSubType=function(e,t){var n=t.type;if(!n){var i=sc(e).main;u5.hasSubTypes(e)&&g[i]&&(n=g[i](t))}return n};var u4=function(e){var t=[];return nw(u5.getClassesByMainType(e),function(e){t=t.concat(e.dependencies||e.prototype.depen
422dencies||[])}),t=nC(t,function(e){return sc(e).main}),"dataset"!==e&&0>=nv(t,"dataset")&&t.unshift("dataset"),t};function u6(e,t){return e[t]||(e[t]={predecessor:[],successor:[]}),e[t]}u5.topologicalTravel=function(e,t,n,i){if(e.length){var r,o,a,s=(o={},a=[],nw(r=t,function(e){var t,n,i,s=u6(o,e),l=(t=s.originalDeps=u4(e),n=r,i=[],nw(t,function(e){nv(n,e)>=0&&i.push(e)}),i);s.entryCount=l.length,0===s.entryCount&&a.push(e),nw(l,function(t){0>nv(s.predecessor,t)&&s.predecessor.push(t);var n=u6(o,t);0>nv(n.successor,t)&&n.successor.push(e)})}),{graph:o,noEntryList:a}),l=s.graph,d=s.noEntryList,u={};for(nw(e,function(e){u[e]=!0});d.length;){var c=d.pop(),h=l[c],p=!!u[c];p&&(n.call(i,c,h.originalDeps.slice()),delete u[c]),nw(h.successor,p?g:f)}nw(u,function(){throw Error("")})}function f(e){l[e].entryCount--,0===l[e].entryCount&&d.push(e)}function g(e){u[e]=!0,f(e)}};var u8="";"u">typeof navigator&&(u8=navigator.platform||"");var u7="rgba(0, 0, 0, 0.2)";let u9={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:u7,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:u7,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:u7,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:u7,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:u7,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:u7,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:u8.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1};var ce=n1(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),ct="original",cn="arrayRows",ci="objectRows",cr="keyedColumns",co="typedArray",ca="unknown",cs="column",cl=a9();function cd(e,t,n){var i,r,o={},a=cc(t);if(!a||!e)return o;var s=[],l=[],d=cl(t.ecModel).datasetMap,u=a.uid+"_"+n.seriesLayoutBy;nw(e=e.slice(),function(t,n){var a=nL(t)?t:e[n]={name:t};"ordinal"===a.type&&null==i&&(i=n,r=p(a)),o[a.name]=[]});var c=d.get(u)||d.set(u,{categoryWayDim:r,valueWayDim:0});function h(e,t,n){for(var i=0;i<n;i++)e.push(t+i)}function p(e){var t=e.dimsDef;return t?t.length:1}return nw(e,function(e,t){var n=e.name,r=p(e);if(null==i){var a=c.valueWayDim;h(o[n],a,r),h(l,a,r),c.valueWayDim+=r}else if(i===t)h(o[n],0,r),h(s,0,r);else{var a=c.categoryWayDim;h(o[n],a,r),h(l,a,r),c.categoryWayDim+=r}}),s.length&&(o.itemName=s),l.length&&(o.seriesName=l),o}function cu(e,t,n){var i,r={};if(!cc(e))return r;var o=t.sourceFormat,a=t.dimensionsDefine;(o===ci||o===cr)&&nw(a,function(e,t){(nL(e)?e.name:e)==="name"&&(i=t)});var s=function(){for(var e={},r={},s=[],l=0,d=Math.min(5,n);l<d;l++){var u=cp(t.data,o,t.seriesLayoutBy,a,t.startIndex,l);s.push(u);var c=3===u;if(c&&null==e.v&&l!==i&&(e.v=l),null!=e.n&&e.n!==e.v&&(c||3!==s[e.n])||(e.n=l),h(e)&&3!==s[e.n])return e;c||(2===u&&null==r.v&&l!==i&&(r.v=l),(null==r.n||r.n===r.v)&&(r.n=l))}function h(e){return null!=e.v&&null!=e.n}return h(e)?e:h(r)?r:null}();if(s){r.value=[s.v];var l=null!=i?i:s.n;r.itemName=[l],r.seriesName=[l]}return r}function cc(e){if(!e.get("data",!0))return so(e.ecModel,"dataset",{index:e.get("datasetIndex",!0),id:e.get("datasetId",!0)},si).models[0]}function ch(e,t){return cp(e.data,e.sourceFormat,e.seriesLayoutBy,e.dimensionsDefine,e.startIndex,t)}function cp(e,t,n,i,r,o){var a,s,l;if(nO(e))return 3;if(i){var d=i[o];nL(d)?(s=d.name,l=d.type):nA(d)&&(s=d)}if(null!=l)return"ordinal"===l?1:3;if(t===cn)if("row"===n){for(var u=e[o],c=0;c<(u||[]).length&&c<5;c++)if(null!=(a=g(u[r+c])))return a}else for(var c=0;c<e.length&&c<5;c++){var h=e[r+c];if(h&&null!=(a=g(h[o])))return a}else if(t===ci){if(!s)return 3;for(var c=0;c<e.length&&c<5;c++){var p=e[c];if(p&&null!=(a=g(p[s])))return a}}else if(t===cr){if(!s)return 3;var u=e[s];if(!u||nO(u))return 3;for(var c=0;c<u.length&&c<5;c++)if(null!=(a=g(u[c])))return a}else if(t===ct)for(var c=0;c<e.length&&c<5;c++){var p=e[c],f=a1(p);if(!nR(f))return 3;if(null!=(a=g(f[o])))return a}function g(e){var t=nA(e);return null!=e&&Number.isFinite(Number(e))&&""!==e?t?2:3:t&&"-"!==e?1:void 0}return 3}var cf=n1(),cg=a9(),cm=a9(),cv=function(){function e(){}return e.prototype.getColorFromPalette=function(e,t,n){return cb(this,cg,aJ(this.get("color",!0)),this.get("colorLayer",!0),e,t,n)},e.prototype.clearColorPalette=function(){var e,t;e=this,(t=cg)(e).paletteIdx=0,t(e).paletteNameMap={}},e}();function cy(e,t,n,i){var r=aJ(e.get(["aria","decal","decals"]));return cb(e,cm,r,null,t,n,i)}function cb(e,t,n,i,r,o,a){var s=t(o=o||e),l=s.paletteIdx||0,d=s.paletteNameMap=s.paletteNameMap||{};if(d.hasOwnProperty(r))return d[r];var u=null!=a&&i?function(e,t){for(var n=e.length,i=0;i<n;i++)if(e[i].length>t)return e[i];return e[n-1]}(i,a):n;if((u=u||n)&&u.length){var c=u[l];return r&&(d[r]=c),s.paletteIdx=(l+1)%u.length,c}}function cx(e){}function cw(e){throw Error(e)}var cC="\0_ec_inner",cS=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t,n,i,r,o){i=i||{},this.option=null,this._theme=new ua(i),this._locale=new ua(r),this._optionManager=o},t.prototype.setOption=function(e,t,n){var i=cM(t);this._optionManager.setOption(e,n,i),this._resetOption(null,i)},t.prototype.resetOption=function(e,t){return this._resetOption(e,cM(t))},t.prototype._resetOption=function(e,t){var n=!1,i=this._optionManager;if(!e||"recreate"===e){var r=i.mountOption("recreate"===e);this.option&&"recreate"!==e?(this.restoreData(),this._mergeOption(r,t)):C(this,r),n=!0}if(("timeline"===e||"media"===e)&&this.restoreData(),!e||"recreate"===e||"timeline"===e){var o=i.getTimelineOption(this);o&&(n=!0,this._mergeOption(o,t))}if(!e||"recreate"===e||"media"===e){var a=i.getMediaOption(this);a.length&&nw(a,function(e){n=!0,this._mergeOption(e,t)},this)}return n},t.prototype.mergeOption=function(e){this._mergeOption(e,null)},t.prototype._mergeOption=function(e,t){var n=this.option,i=this._componentsMap,r=this._componentsCount,o=[],a=n1(),s=t&&t.replaceMergeMainTypeMap;cl(this).datasetMap=n1(),nw(e,function(e,t){null!=e&&(u5.hasClass(t)?t&&(o.push(t),a.set(t,!0)):n[t]=null==n[t]?nc(e):nh(n[t],e,!0))}),s&&s.each(function(e,t){u5.hasClass(t)&&!a.get(t)&&(o.push(t),a.set(t,!0))}),u5.topologicalTravel(o,u5.getAllClassMainTypes(),function(t){var o,a=function(e,t,n){var i=cf.get(t);if(!i)return n;var r=i(e);return r?n.concat(r):n}(this,t,aJ(e[t])),l=i.get(t),d=l?s&&s.get(t)?"replaceMerge":"normalMerge":"replaceAll",u=a2(l,a,d);nw(u,function(e){var n,i,r,o,a=e.newOption;nL(a)&&(e.keyInfo.mainType=t,e.keyInfo.subType=(n=t,i=a,r=e.existing,o=u5,i.type?i.type:r?r.subType:o.determineSubType(n,i)))}),n[t]=null,i.set(t,null),r.set(t,0);var c=[],h=[],p=0;nw(u,function(e,n){var i=e.existing,r=e.newOption;if(r){var a="series"===t,s=u5.getClass(t,e.keyInfo.subType,!a);if(!s)return;if("tooltip"===t){if(o)return;o=!0}if(i&&i.constructor===s)i.name=e.keyInfo.name,i.mergeOption(r,this),i.optionUpdated(r,!1);else{var l=nf({componentIndex:n},e.keyInfo);nf(i=new s(r,this,this,l),l),e.brandNew&&(i.__requireNewView=!0),i.init(r,this,this),i.optionUpdated(null,!0)}}else i&&(i.mergeOption({},this),i.optionUpdated({},!1));i?(c.push(i.option),h.push(i),p++):(c.push(void 0),h.push(void 0))},this),n[t]=c,i.set(t,h),r.set(t,p),"series"===t&&x(this)},this),this._seriesIndices||x(this)},t.prototype.getOption=function(){var e=nc(this.option);return nw(e,function(t,n){if(u5.hasClass(n)){for(var i=aJ(t),r=i.length,o=!1,a=r-1;a>=0;a--)i[a]&&!a8(i[a])?o=!0:(i[a]=null,!o&&r--);i.length=r,e[n]=i}}),delete e[cC],e},t.prototype.getTheme=function(){return this._theme},t.prototype.getLocaleModel=function(){return this._locale},t.prototype.setUpdatePayload=function(e){this._payload=e},t.prototype.getUpdatePayload=function(){return this._payload},t.prototype.getComponent=function(e,t){var n=this._componentsMap.get(e);if(n){var i=n[t||0];if(i)return i;if(null==t){for(var r=0;r<n.length;r++)if(n[r])return n[r]}}},t.prototype.queryComponents=function(e){var t,n=e.mainType;if(!n)return[];var i=e.index,r=e.id,o=e.name,a=this._componentsMap.get(n);return a&&a.length?(null!=i?(t=[],nw(aJ(i),function(e){a[e]&&t.push(a[e])})):t=null!=r?c_("id",r,a):null!=o?c_("name",o,a):n_(a,function(e){return!!e}),ck(t,e)):[]},t.prototype.findComponents=function(e){var t,n,i,r,o,a=e.query,s=e.mainType,l=(t=a,n=s+"Index",i=s+"Id",r=s+"Name",t&&(null!=t[n]||null!=t[i]||null!=t[r])?{mainType:s,index:t[n],id:t[i],name:t[r]}:null);return o=ck(l?this.queryComponents(l):n_(this._componentsMap.get(s),function(e){return!!e}),e),e.filter?n_(o,e.filter):o},t.prototype.eachComponent=function(e,t,n){var i=this._componentsMap;if(nI(e))i.each(function(n,i){for(var r=0;n&&r<n.length;r++){var o=n[r];o&&e.call(t,i,o,o.componentIndex)}});else for(var r=nA(e)?i.get(e):nL(e)?this.findComponents(e):null,o=0;r&&o<r.length;o++){var a=r[o];a&&t.call(n,a,a.componentIndex)}},t.prototype.getSeriesByName=function(e){var t=a4(e,null);return n_(this._componentsMap.get("series"),function(e){return!!e&&null!=t&&e.name===t})},t.prototype.getSeriesByIndex=function(e){return this._componentsMap.get("series")[e]},t.prototype.getSeriesByType=function(e){return n_(this._componentsMap.get("series"),function(t){return!!t&&t.subType===e})},t.prototype.getSeries=function(){return n_(this._componentsMap.get("series"),function(e){return!!e})},t.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},t.prototype.eachSeries=function(e,t){w(this),nw(this._seriesIndices,function(n){var i=this._componentsMap.get("series")[n];e.call(t,i,n)},this)},t.prototype.eachRawSeries=function(e,t){nw(this._componentsMap.get("series"),function(n){n&&e.call(t,n,n.componentIndex)})},t.prototype.eachSeriesByType=function(e,t,n){w(this),nw(this._seriesIndices,function(i){var r=this._componentsMap.get("series")[i];r.subType===e&&t.call(n,r,i)},this)},t.prototype.eachRawSeriesByType=function(e,t,n){return nw(this.getSeriesByType(e),t,n)},t.prototype.isSeriesFiltered=function(e){return w(this),null==this._seriesIndicesMap.get(e.componentIndex)},t.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},t.prototype.filterSeries=function(e,t){w(this);var n=[];nw(this._seriesIndices,function(i){var r=this._componentsMap.get("series")[i];e.call(t,r,i)&&n.push(i)},this),this._seriesIndices=n,this._seriesIndicesMap=n1(n)},t.prototype.restoreData=function(e){x(this);var t=this._componentsMap,n=[];t.each(function(e,t){u5.hasClass(t)&&n.push(t)}),u5.topologicalTravel(n,u5.getAllClassMainTypes(),function(n){nw(t.get(n),function(t){t&&("series"!==n||!function(e,t){if(t){var n=t.seriesIndex,i=t.seriesId,r=t.seriesName;return null!=n&&e.componentIndex!==n||null!=i&&e.id!==i||null!=r&&e.name!==r}}(t,e))&&t.restoreData()})})},t.internalField=void(x=function(e){var t=e._seriesIndices=[];nw(e._componentsMap.get("series"),function(e){e&&t.push(e.componentIndex)}),e._seriesIndicesMap=n1(t)},w=function(e){},C=function(e,t){e.option={},e.option[cC]=1,e._componentsMap=n1({series:[]}),e._componentsCount=n1();var n,i,r,o=t.aria;nL(o)&&null==o.enabled&&(o.enabled=!0),n=t,i=e._theme.option,r=n.color&&!n.colorLayer,nw(i,function(e,t){("colorLayer"!==t||!r)&&(u5.hasClass(t)||("object"==typeof e?n[t]=n[t]?nh(n[t],e,!1):nc(e):null==n[t]&&(n[t]=e)))}),nh(t,u9,!1),e._mergeOption(t,null)}),t}(ua);function c_(e,t,n){if(nR(t)){var i=n1();return nw(t,function(e){null!=e&&null!=a4(e,null)&&i.set(e,!0)}),n_(n,function(t){return t&&i.get(t[e])})}var r=a4(t,null);return n_(n,function(t){return t&&null!=r&&t[e]===r})}function ck(e,t){return t.hasOwnProperty("subType")?n_(e,function(e){return e&&e.subType===t.subType}):e}function cM(e){var t=n1();return e&&nw(aJ(e.replaceMerge),function(e){t.set(e,!0)}),{replaceMergeMainTypeMap:t}}nb(cS,cv);var cT=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"];let cD=function(e){nw(cT,function(t){this[t]=nT(e[t],e)},this)};var cR={},cI=function(){function e(){this._coordinateSystems=[]}return e.prototype.create=function(e,t){var n=[];nw(cR,function(i,r){var o=i.create(e,t);n=n.concat(o||[])}),this._coordinateSystems=n},e.prototype.update=function(e,t){nw(this._coordinateSystems,function(n){n.update&&n.update(e,t)})},e.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},e.register=function(e,t){cR[e]=t},e.get=function(e){return cR[e]},e}(),cA=/^(min|max)?(.+)$/,cP=function(){function e(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return e.prototype.setOption=function(e,t,n){e&&(nw(aJ(e.series),function(e){e&&e.data&&nO(e.data)&&nZ(e.data)}),nw(aJ(e.dataset),function(e){e&&e.source&&nO(e.source)&&nZ(e.source)})),e=nc(e);var i=this._optionBackup,r=function(e,t,n){var i,r,o=[],a=e.baseOption,s=e.timeline,l=e.options,d=e.media,u=!!e.media,c=!!(l||s||a&&a.timeline);function h(e){nw(t,function(t){t(e,n)})}return a?(r=a).timeline||(r.timeline=s):((c||u)&&(e.options=e.media=null),r=e),u&&nR(d)&&nw(d,function(e){e&&e.option&&(e.query?o.push(e):i||(i=e))}),h(r),nw(l,function(e){return h(e)}),nw(o,function(e){return h(e.option)}),{baseOption:r,timelineOptions:l||[],mediaDefault:i,mediaList:o}}(e,t,!i);this._newBaseOption=r.baseOption,i?(r.timelineOptions.length&&(i.timelineOptions=r.timelineOptions),r.mediaList.length&&(i.mediaList=r.mediaList),r.mediaDefault&&(i.mediaDefault=r.mediaDefault)):this._optionBackup=r},e.prototype.mountOption=function(e){var t=this._optionBackup;return this._timelineOptions=t.timelineOptions,this._mediaList=t.mediaList,this._mediaDefault=t.mediaDefault,this._currentMediaIndices=[],nc(e?t.baseOption:this._newBaseOption)},e.prototype.getTimelineOption=function(e){var t,n=this._timelineOptions;if(n.length){var i=e.getComponent("timeline");
422i&&(t=nc(n[i.getCurrentIndex()]))}return t},e.prototype.getMediaOption=function(e){var t,n,i=this._api.getWidth(),r=this._api.getHeight(),o=this._mediaList,a=this._mediaDefault,s=[],l=[];if(!o.length&&!a)return l;for(var d=0,u=o.length;d<u;d++)(function(e,t,n){var i={width:t,height:n,aspectratio:t/n},r=!0;return nw(e,function(e,t){var n=t.match(cA);if(n&&n[1]&&n[2]){var o,a,s,l=n[1];o=i[n[2].toLowerCase()],a=e,("min"===(s=l)?o>=a:"max"===s?o<=a:o===a)||(r=!1)}}),r})(o[d].query,i,r)&&s.push(d);return!s.length&&a&&(s=[-1]),s.length&&(t=s,n=this._currentMediaIndices,t.join(",")!==n.join(","))&&(l=nC(s,function(e){return nc(-1===e?a.option:o[e].option)})),this._currentMediaIndices=s,l},e}(),cE=nL,cL=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function cF(e){var t=e&&e.itemStyle;if(t)for(var n=0,i=cL.length;n<i;n++){var r=cL[n],o=t.normal,a=t.emphasis;o&&o[r]&&(e[r]=e[r]||{},e[r].normal?nh(e[r].normal,o[r]):e[r].normal=o[r],o[r]=null),a&&a[r]&&(e[r]=e[r]||{},e[r].emphasis?nh(e[r].emphasis,a[r]):e[r].emphasis=a[r],a[r]=null)}}function cO(e,t,n){if(e&&e[t]&&(e[t].normal||e[t].emphasis)){var i=e[t].normal,r=e[t].emphasis;i&&(n?(e[t].normal=e[t].emphasis=null,ng(e[t],i)):e[t]=i),r&&(e.emphasis=e.emphasis||{},e.emphasis[t]=r,r.focus&&(e.emphasis.focus=r.focus),r.blurScope&&(e.emphasis.blurScope=r.blurScope))}}function cN(e){cO(e,"itemStyle"),cO(e,"lineStyle"),cO(e,"areaStyle"),cO(e,"label"),cO(e,"labelLine"),cO(e,"upperLabel"),cO(e,"edgeLabel")}function cB(e,t){var n=cE(e)&&e[t],i=cE(n)&&n.textStyle;if(i)for(var r=0,o=a0.length;r<o;r++){var a=a0[r];i.hasOwnProperty(a)&&(n[a]=i[a])}}function cz(e){e&&(cN(e),cB(e,"label"),e.emphasis&&cB(e.emphasis,"label"))}function cj(e){return nR(e)?e:e?[e]:[]}function cV(e){return(nR(e)?e[0]:e)||{}}function cH(e){e&&nw(cG,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var cG=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],cW=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],c$=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function cU(e){var t=e&&e.itemStyle;if(t)for(var n=0;n<c$.length;n++){var i=c$[n][1],r=c$[n][0];null!=t[i]&&(t[r]=t[i])}}function cq(e){e&&"edge"===e.alignTo&&null!=e.margin&&null==e.edgeDistance&&(e.edgeDistance=e.margin)}function cK(e){e&&e.downplay&&!e.blur&&(e.blur=e.downplay)}function cY(e,t){var n;nw(cj(e.series),function(e){cE(e)&&function(e){if(cE(e)){cF(e),cN(e),cB(e,"label"),cB(e,"upperLabel"),cB(e,"edgeLabel"),e.emphasis&&(cB(e.emphasis,"label"),cB(e.emphasis,"upperLabel"),cB(e.emphasis,"edgeLabel"));var t=e.markPoint;t&&(cF(t),cz(t));var n=e.markLine;n&&(cF(n),cz(n));var i=e.markArea;i&&cz(i);var r=e.data;if("graph"===e.type){r=r||e.nodes;var o=e.links||e.edges;if(o&&!nO(o))for(var a=0;a<o.length;a++)cz(o[a]);nw(e.categories,function(e){cN(e)})}if(r&&!nO(r))for(var a=0;a<r.length;a++)cz(r[a]);if((t=e.markPoint)&&t.data)for(var s=t.data,a=0;a<s.length;a++)cz(s[a]);if((n=e.markLine)&&n.data)for(var l=n.data,a=0;a<l.length;a++)nR(l[a])?(cz(l[a][0]),cz(l[a][1])):cz(l[a]);"gauge"===e.type?(cB(e,"axisLabel"),cB(e,"title"),cB(e,"detail")):"treemap"===e.type?(cO(e.breadcrumb,"itemStyle"),nw(e.levels,function(e){cN(e)})):"tree"===e.type&&cN(e.leaves)}}(e)}),n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"],t&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),nw(n,function(t){nw(cj(e[t]),function(e){e&&(cB(e,"axisLabel"),cB(e.axisPointer,"label"))})}),nw(cj(e.parallel),function(e){var t=e&&e.parallelAxisDefault;cB(t,"axisLabel"),cB(t&&t.axisPointer,"label")}),nw(cj(e.calendar),function(e){cO(e,"itemStyle"),cB(e,"dayLabel"),cB(e,"monthLabel"),cB(e,"yearLabel")}),nw(cj(e.radar),function(e){cB(e,"name"),e.name&&null==e.axisName&&(e.axisName=e.name,delete e.name),null!=e.nameGap&&null==e.axisNameGap&&(e.axisNameGap=e.nameGap,delete e.nameGap)}),nw(cj(e.geo),function(e){cE(e)&&(cz(e),nw(cj(e.regions),function(e){cz(e)}))}),nw(cj(e.timeline),function(e){cz(e),cO(e,"label"),cO(e,"itemStyle"),cO(e,"controlStyle",!0);var t=e.data;nR(t)&&nw(t,function(e){nL(e)&&(cO(e,"label"),cO(e,"itemStyle"))})}
422),nw(cj(e.toolbox),function(e){cO(e,"iconStyle"),nw(e.feature,function(e){cO(e,"iconStyle")})}),cB(cV(e.axisPointer),"label"),cB(cV(e.tooltip).axisPointer,"label"),e.series=aJ(e.series),nw(e.series,function(e){if(nL(e)){var t=e.type;if("line"===t)null!=e.clipOverflow&&(e.clip=e.clipOverflow);else if("pie"===t||"gauge"===t){null!=e.clockWise&&(e.clockwise=e.clockWise),cq(e.label);var n=e.data;if(n&&!nO(n))for(var i=0;i<n.length;i++)cq(n[i]);null!=e.hoverOffset&&(e.emphasis=e.emphasis||{},e.emphasis.scaleSize=null)}else if("gauge"===t){var r=function(e,t){for(var n=t.split(","),i=e,r=0;r<n.length&&null!=(i=i&&i[n[r]]);r++);return i}(e,"pointer.color");null!=r&&function(e,t,n,i){for(var r,o=t.split(","),a=e,s=0;s<o.length-1;s++)null==a[r=o[s]]&&(a[r]={}),a=a[r];null==a[o[s]]&&(a[o[s]]=n)}(e,"itemStyle.color",r)}else if("bar"===t){cU(e),cU(e.backgroundStyle),cU(e.emphasis);var n=e.data;if(n&&!nO(n))for(var i=0;i<n.length;i++)"object"==typeof n[i]&&(cU(n[i]),cU(n[i]&&n[i].emphasis))}else if("sunburst"===t){var o=e.highlightPolicy;o&&(e.emphasis=e.emphasis||{},e.emphasis.focus||(e.emphasis.focus=o)),cK(e),function e(t,n){if(t)for(var i=0;i<t.length;i++)n(t[i]),t[i]&&e(t[i].children,n)}(e.data,cK)}else"graph"===t||"sankey"===t?e&&null!=e.focusNodeAdjacency&&(e.emphasis=e.emphasis||{},null==e.emphasis.focus&&(e.emphasis.focus="adjacency")):"map"===t&&(e.mapType&&!e.map&&(e.map=e.mapType),e.mapLocation&&ng(e,e.mapLocation));null!=e.hoverAnimation&&(e.emphasis=e.emphasis||{}
422,e.emphasis&&null==e.emphasis.scale&&(e.emphasis.scale=e.hoverAnimation)),cH(e)}}),e.dataRange&&(e.visualMap=e.dataRange),nw(cW,function(t){var n=e[t];n&&(nR(n)||(n=[n]),nw(n,function(e){cH(e)}))})}function cZ(e){nw(e,function(t,n){var i=[],r=[NaN,NaN],o=[t.stackResultDimension,t.stackedOverDimension],a=t.data,s=t.isStackedByIndex,l=t.seriesModel.get("stackStrategy")||"samesign";a.modify(o,function(o,d,u){var c,h,p=a.get(t.stackedDimension,u);if(isNaN(p))return r;s?h=a.getRawIndex(u):c=a.get(t.stackedByDimension,u);for(var f=NaN,g=n-1;g>=0;g--){var m=e[g];if(s||(h=m.data.rawIndexOf(m.stackedByDimension,c)),h>=0){var v=m.data.getByRawIndex(m.stackResultDimension,h);if("all"===l||"positive"===l&&v>0||"negative"===l&&v<0||"samesign"===l&&p>=0&&v>0||"samesign"===l&&p<=0&&v<0){p=function(e,t){var n=Math.max(aP(e),aP(t)),i=e+t;return n>20?i:aI(i,n)}(p,v),f=v;break}}}return i[0]=p,i[1]=f,i})})}var cX=function(e){this.data=e.data||(e.sourceFormat===cr?{}:[]),this.sourceFormat=e.sourceFormat||ca,this.seriesLayoutBy=e.seriesLayoutBy||cs,this.startIndex=e.startIndex||
4220,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var t=this.dimensionsDefine=e.dimensionsDefine;if(t)for(var n=0;n<t.length;n++){var i=t[n];null==i.type&&1===ch(this,n)&&(i.type="ordinal")}};function cJ(e){return e instanceof cX}function cQ(e,t,n){n=n||c1(e);var i=t.seriesLayoutBy,r=function(e,t,n,i,r){if(!e)return{dimensionsDefine:c2(r),startIndex:a,dimensionsDetectedCount:o};if(t===cn){var o,a;"auto"===i||null==i?c3(function(e){null!=e&&"-"!==e&&(nA(e)?null==a&&(a=1):a=0)},n,e,10):a=nE(i)?i:+!!i,r||1!==a||(r=[],c3(function(e,t){r[t]=null!=e?e+"":""},n,e,1/0)),o=r?r.length:"row"===n?e.length:e[0]?e[0].length:null}else if(t===ci)r||(r=function(e){for(var t,n=0;n<e.length&&!(t=e[n++]););if(t)return nM(t)}(e));else if(t===cr)r||(r=[],nw(e,function(e,t){r.push(t)}));else if(t===ct){var s=a1(e[0]);o=nR(s)&&s.length||1}return{startIndex:a,dimensionsDefine:c2(r),dimensionsDetectedCount:o}}(e,n,i,t.sourceHeader,t.dimensions);return new cX({data:e,sourceFormat:n,seriesLayoutBy:i,dimensionsDefine:r.dimensionsDefine,startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount,metaRawOption:nc(t)})}function c0(e){return new cX({data:e,sourceFormat:nO(e)?co:ct})}function c1(e){var t=ca;if(nO(e))t=co;else if(nR(e)){0===e.length&&(t=cn);for(var n=0,i=e.length;n<i;n++){var r=e[n];if(null!=r){if(nR(r)||nO(r)){t=cn;break}else if(nL(r)){t=ci;break}}}}else if(nL(e)){for(var o in e)if(n4(e,o)&&nx(e[o])){t=cr;break}}return t}function c2(e){if(e){var t=n1();return nC(e,function(e,n){var i={name:(e=nL(e)?e:{name:e}).name,displayName:e.displayName,type:e.type};if(null==i.name)return i;i.name+="",null==i.displayName&&(i.displayName=i.name);var r=t.get(i.name);return r?i.name+="-"+r.count++:t.set(i.name,{count:1}),i})}}function c3(e,t,n,i){if("row"===t)for(var r=0;r<n.length&&r<i;r++)e(n[r]?n[r][0]:null,r);else for(var o=n[0]||[],r=0;r<o.length&&r<i;r++)e(o[r],r)}function c5(e){var t=e.sourceFormat;return t===ci||t===cr}var c4=function(){var e;function t(e,t){var n=cJ(e)?e:c0(e);this._source=n;var i=this._data=n.data;n.sourceFormat===co&&(this._offset=0,this._dimSize=t,this._data=i),T(this,i,n)}return t.prototype.getSource=function(){return this._source},t.prototype.count=function(){return 0},t.prototype.getItem=function(e,t){},t.prototype.appendData=function(e){},t.prototype.clean=function(){},t.protoInitialize=void((e=t.prototype).pure=!1,e.persistent=!0),t.internalField=function(){T=function(e,r,o){var a=o.sourceFormat,s=o.seriesLayoutBy,l=o.startIndex,d=o.dimensionsDefine;nf(e,M[hn(a,s)]),a===co?(e.getItem=t,e.count=i,e.fillStorage=n):(e.getItem=nT(function(e,t){return c8[hn(e,t)]}(a,s),null,r,l,d),e.count=nT(function(e,t){return c9[hn(e,t)]}(a,s),null,r,l,d))};var e,t=function(e,t){e-=this._offset,t=t||[];for(var n=this._data,i=this._dimSize,r=i*e,o=0;o<i;o++)t[o]=n[r+o];return t},n=function(e,t,n,i){for(var r=this._data,o=this._dimSize,a=0;a<o;a++){for(var s=i[a],l=null==s[0]?1/0:s[0],d=null==s[1]?-1/0:s[1],u=t-e,c=n[a],h=0;h<u;h++){var p=r[h*o+a];c[e+h]=p,p<l&&(l=p),p>d&&(d=p)}s[0]=l,s[1]=d}},i=function(){return this._data?this._data.length/this._dimSize:0};function r(e){for(var t=0;t<e.length;t++)this._data.push(e[t])}(e={})[cn+"_"+cs]={pure:!0,appendData:r},e[cn+"_row"]={pure:!0,appendData:function(){throw Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[ci]={pure:!0,appendData:r},e[cr]={pure:!0,appendData:function(e){var t=this._data;nw(e,function(e,n){for(var i=t[n]||(t[n]=[]),r=0;r<(e||[]).length;r++)i.push(e[r])})}},e[ct]={appendData:r},e[co]={persistent:!1,pure:!0,appendData:function(e){this._data=e},clean:function(){this._offset+=this.count(),this._data=null}},M=e}(),t}(),c6=function(e,t,n,i){return e[i]},c8=((S={})[cn+"_"+cs]=function(e,t,n,i){return e[i+t]},S[cn+"_row"]=function(e,t,n,i,r){i+=t;for(var o=r||[],a=0;a<e.length;a++){var s=e[a];o[a]=s?s[i]:null}return o},S[ci]=c6,S[cr]=function(e,t,n,i,r){for(var o=r||[],a=0;a<n.length;a++){var s=e[n[a].name];o[a]=s?s[i]:null}return o},S[ct]=c6,S),c7=function(e,t,n){return e.length},c9=((_={})[cn+"_"+cs]=function(e,t,n){return Math.max(0,e.length-t)},_[cn+"_row"]=function(e,t,n){var i=e[0];return i?Math.max(0,i.length-t):0}
422,_[ci]=c7,_[cr]=function(e,t,n){var i=e[n[0].name];return i?i.length:0},_[ct]=c7,_),he=function(e,t,n){return e[t]},ht=((k={})[cn]=he,k[ci]=function(e,t,n){return e[n]},k[cr]=he,k[ct]=function(e,t,n){var i=a1(e);return i instanceof Array?i[t]:i},k[co]=he,k);function hn(e,t){return e===cn?e+"_"+t:e}function hi(e,t,n){if(e){var i=e.getRawDataItem(t);if(null!=i){var r=e.getStore(),o=r.getSource().sourceFormat;if(null!=n){var a=e.getDimensionIndex(n),s=r.getDimensionProperty(a);return ht[o](i,a,s)}var l=i;return o===ct&&(l=a1(i)),l}}}var hr=/\{@(.+?)\}/g,ho=function(){function e(){}return e.prototype.getDataParams=function(e,t){var n=this.getData(t),i=this.getRawValue(e,t),r=n.getRawIndex(e),o=n.getName(e),a=n.getRawDataItem(e),s=n.getItemVisual(e,"style"),l=s&&s[n.getItemVisual(e,"drawType")||"fill"],d=s&&s.stroke,u=this.mainType,c="series"===u,h=n.userOutput&&n.userOutput.get();return{componentType:u,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:c?this.subType:null,seriesIndex:this.seriesIndex,seriesId:c?this.id:null,seriesName:c?this.name:null,name:o,dataIndex:r,data:a,dataType:t,value:i,color:l,borderColor:d,dimensionNames:h?h.fullDimensions:null,encode:h?h.encode:null,$vars:["seriesName","name","value"]}},e.prototype.getFormattedLabel=function(e,t,n,i,r,o){t=t||"normal";var a=this.getData(n),s=this.getDataParams(e,n);return(o&&(s.value=o.interpolatedValue),null!=i&&nR(s.value)&&(s.value=s.value[i]),r||(r=a.getItemModel(e).get("normal"===t?["label","formatter"]:[t,"label","formatter"])),nI(r))?(s.status=t,s.dimensionIndex=i,r(s)):nA(r)?uH(r,s).replace(hr,function(t,n){var i=n.length,r=n;"["===r.charAt(0)&&"]"===r.charAt(i-1)&&(r=+r.slice(1,i-1));var s=hi(a,e,r);if(o&&nR(o.interpolatedValue)){var l=a.getDimensionIndex(r);l>=0&&(s=o.interpolatedValue[l])}return null!=s?s+"":""}):void 0},e.prototype.getRawValue=function(e,t){return hi(this.getData(t),e)},e.prototype.formatTooltip=function(e,t,n){},e}();function ha(e){var t,n;return nL(e)?e.type&&(n=e):t=e,{text:t,frag:n}}function hs(e){return new hl(e)}var hl=function(){function e(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return e.prototype.perform=function(e){var t,n,i,r,o=this._upstream,a=e&&e.skip;if(this._dirty&&o){var s=this.context;s.data=s.outputData=o.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!a&&(i=this._plan(this.context));var l=((t=this._modBy)>=1||(t=1),t),d=this._modDataCount||0,u=((n=e&&e.modBy)>=1||(n=1),n),c=e&&e.modDataCount||0;(l!==u||d!==c)&&(i="reset"),(this._dirty||"reset"===i)&&(this._dirty=!1,r=this._doReset(a)),this._modBy=u,this._modDataCount=c;var h=e&&e.step;if(o?this._dueEnd=o._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var p=this._dueIndex,f=Math.min(null!=h?this._dueIndex+h:1/0,this._dueEnd);if(!a&&(r||p<f)){var g=this._progress;if(nR(g))for(var m=0;m<g.length;m++)this._doProgress(g[m],p,f,u,c);else this._doProgress(g,p,f,u,c)}this._dueIndex=f;var v=null!=this._settedOutputEnd?this._settedOutputEnd:f;this._outputDueEnd=v}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()},e.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},e.prototype._doProgress=function(e,t,n,i,r){hd.reset(t,n,i,r),this._callingProgress=e,this._callingProgress({start:t,end:n,count:n-t,next:hd.next},this.context)},e.prototype._doReset=function(e){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null,!e&&this._reset&&((t=this._reset(this.context))&&t.progress&&(n=t.forceFirstProgress,t=t.progress),nR(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var t,n,i=this._downstream;return i&&i.dirty(),n},e.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},e.prototype.pipe=function(e){(this._downstream!==e||this._dirty)&&(this._downstream=e,e._upstream=this,e.dirty())},e.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},e.prototype.getUpstream=function(){return this._upstream},e.prototype.getDownstream=function(){return this._downstream},e.prototype.setOutputEnd=function(e){this._outputDueEnd=this._settedOutputEnd=e},e}(),hd=function(){var e,t,n,i,r,o={reset:function(l,d,u,c){t=l,e=d,n=u,r=Math.ceil((i=c)/n),o.next=n>1&&i>0?s:a}};return o;function a(){return t<e?t++:null}function s(){var o=t%r*n+Math.ceil(t/r),a=t>=e?null:o<i?o:t;return t++,a}}();function hu(e,t){var n=t&&t.type;return"ordinal"===n?e:("time"!==n||nE(e)||null==e||"-"===e||(e=+aj(e)),null==e||""===e?NaN:Number(e))}var hc=n1({number:function(e){return parseFloat(e)},time:function(e){return+aj(e)},trim:function(e){return nA(e)?nK(e):e}}),hh={lt:function(e,t){return e<t},lte:function(e,t){return e<=t},gt:function(e,t){return e>t},gte:function(e,t){return e>=t}},hp=function(){function e(e,t){nE(t)||cw(""),this._opFn=hh[e],this._rvalFloat=aU(t)}return e.prototype.evaluate=function(e){return nE(e)?this._opFn(e,this._rvalFloat):this._opFn(aU(e),this._rvalFloat)},e}(),hf=function(){function e(e,t){var n="desc"===e;this._resultLT=n?1:-1,null==t&&(t=n?"min":"max"),this._incomparable="min"===t?-1/0:1/0}return e.prototype.evaluate=function(e,t){var n=nE(e)?e:aU(e),i=nE(t)?t:aU(t),r=isNaN(n),o=isNaN(i);if(r&&(n=this._incomparable),o&&(i=this._incomparable),r&&o){var a=nA(e),s=nA(t);a&&(n=s?e:0),s&&(i=a?t:0)}return n<i?this._resultLT:n>i?-this._resultLT:0},e}(),hg=function(){function e(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=aU(t)}return e.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var n=typeof e;n!==this._rvalTypeof&&("number"===n||"number"===this._rvalTypeof)&&(t=aU(e)===this._rvalFloat)}return this._isEQ?t:!t},e}(),hm=function(){function e(){}return e.prototype.getRawData=function(){throw Error("not supported")},e.prototype.getRawDataItem=function(e){throw Error("not supported")},e.prototype.cloneRawData=function(){},e.prototype.getDimensionInfo=function(e){},e.prototype.cloneAllDimensionInfo=function(){},e.prototype.count=function(){},e.prototype.retrieveValue=function(e,t){},e.prototype.retrieveValueFromItem=function(e,t){},e.prototype.convertValue=function(e,t){return hu(e,t)},e}();function hv(e){return hC(e.sourceFormat)||cw(""),e.data}function hy(e){var t=e.sourceFormat,n=e.data;if(hC(t)||cw(""),t===cn){for(var i=[],r=0,o=n.length;r<o;r++)i.push(n[r].slice());return i}if(t===ci){for(var i=[],r=0,o=n.length;r<o;r++)i.push(nf({},n[r]));return i}}
422function hb(e,t,n){if(null!=n){if(nE(n)||!isNaN(n)&&!n4(t,n))return e[n];else if(n4(t,n))return t[n]}}function hx(e){return nc(e)}var hw=n1();function hC(e){return e===cn||e===ci}var hS="undefined",h_=typeof Uint32Array===hS?Array:Uint32Array,hk=typeof Uint16Array===hS?Array:Uint16Array,hM=typeof Int32Array===hS?Array:Int32Array,hT=typeof Float64Array===hS?Array:Float64Array,hD={float:hT,int:hM,ordinal:Array,number:Array,time:hT};function hR(e){return e>65535?h_:hk}function hI(){return[1/0,-1/0]}function hA(e,t,n,i,r){var o=hD[n||"float"];if(r){var a=e[t],s=a&&a.length;if(s!==i){for(var l=new o(i),d=0;d<s;d++)l[d]=a[d];e[t]=l}}else e[t]=new o(i)}var hP=function(){function e(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=n1()}return e.prototype.initData=function(e,t,n){this._provider=e,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var i=e.getSource(),r=this.defaultDimValueGetter=D[i.sourceFormat];this._dimValueGetter=n||r,this._rawExtent=[],c5(i),this._dimensions=nC(t,function(e){return{type:e.type,property:e.property}}),this._initDataFromProvider(0,e.count())},e.prototype.getProvider=function(){return this._provider},e.prototype.getSource=function(){return this._provider.getSource()},e.prototype.ensureCalculationDimension=function(e,t){var n=this._calcDimNameToIdx,i=this._dimensions,r=n.get(e);if(null!=r){if(i[r].type===t)return r}else r=i.length;return i[r]={type:t},n.set(e,r),this._chunks[r]=new hD[t||"float"](this._rawCount),this._rawExtent[r]=hI(),r},e.prototype.collectOrdinalMeta=function(e,t){var n=this._chunks[e],i=this._dimensions[e],r=this._rawExtent,o=i.ordinalOffset||0,a=n.length;0===o&&(r[e]=hI());for(var s=r[e],l=o;l<a;l++){var d=n[l]=t.parseAndCollect(n[l]);isNaN(d)||(s[0]=Math.min(d,s[0]),s[1]=Math.max(d,s[1]))}i.ordinalMeta=t,i.ordinalOffset=a,i.type="ordinal"},e.prototype.getOrdinalMeta=function(e){return this._dimensions[e].ordinalMeta},e.prototype.getDimensionProperty=function(e){var t=this._dimensions[e];return t&&t.property},e.prototype.appendData=function(e){var t=this._provider,n=this.count();t.appendData(e);var i=t.count();return t.persistent||(i+=n),n<i&&this._initDataFromProvider(n,i,!0),[n,i]},e.prototype.appendValues=function(e,t){for(var n=this._chunks,i=this._dimensions,r=i.length,o=this._rawExtent,a=this.count(),s=a+Math.max(e.length,t||0),l=0;l<r;l++){var d=i[l];hA(n,l,d.type,s,!0)}for(var u=[],c=a;c<s;c++)for(var h=c-a,p=0;p<r;p++){var d=i[p],f=D.arrayRows.call(this,e[h]||u,d.property,h,p);n[p][c]=f;var g=o[p];f<g[0]&&(g[0]=f),f>g[1]&&(g[1]=f)}return this._rawCount=this._count=s,{start:a,end:s}},e.prototype._initDataFromProvider=function(e,t,n){for(var i=this._provider,r=this._chunks,o=this._dimensions,a=o.length,s=this._rawExtent,l=nC(o,function(e){return e.property}),d=0;d<a;d++){var u=o[d];s[d]||(s[d]=hI()),hA(r,d,u.type,t,n)}if(i.fillStorage)i.fillStorage(e,t,r,s);else for(var c=[],h=e;h<t;h++){c=i.getItem(h,c);for(var p=0;p<a;p++){var f=r[p],g=this._dimValueGetter(c,l[p],h,p);f[h]=g;var m=s[p];g<m[0]&&(m[0]=g),g>m[1]&&(m[1]=g)}}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=t,this._extent=[]},e.prototype.count=function(){return this._count},e.prototype.get=function(e,t){if(!(t>=0&&t<this._count))return NaN;var n=this._chunks[e];return n?n[this.getRawIndex(t)]:NaN},e.prototype.getValues=function(e,t){var n=[],i=[];if(null==t){t=e,e=[];for(var r=0;r<this._dimensions.length;r++)i.push(r)}else i=e;for(var r=0,o=i.length;r<o;r++)n.push(this.get(i[r],t));return n},e.prototype.getByRawIndex=function(e,t){if(!(t>=0&&t<this._rawCount))return NaN;var n=this._chunks[e];return n?n[t]:NaN},e.prototype.getSum=function(e){var t=this._chunks[e],n=0;if(t)for(var i=0,r=this.count();i<r;i++){var o=this.get(e,i);isNaN(o)||(n+=o)}return n},e.prototype.getMedian=function(e){var t=[];this.each([e],function(e){isNaN(e)||t.push(e)});var n=t.sort(function(e,t){return e-t}),i=this.count();return 0===i?0:i%2==1?n[(i-1)/2]:(n[i/2]+n[i/2-1])/2},e.prototype.indexOfRawIndex=function(e){if(e>=this._rawCount||e<0)return -1;if(!this._indices)return e;var t=this._indices,n=t[e];if(null!=n&&n<this._count&&n===e)return e;for(var i=0,r=this._count-1;i<=r;){var o=(i+r)/2|0;if(t[o]<e)i=o+1;else{if(!(t[o]>e))return o;r=o-1}}return -1},e.prototype.indicesOfNearest=function(e,t,n){var i=this._chunks[e],r=[];if(!i)return r;null==n&&(n=1/0);for(var o=1/0,a=-1,s=0,l=0,d=this.count();l<d;l++){var u=t-i[this.getRawIndex(l)],c=Math.abs(u);c<=n&&((c<o||c===o&&u>=0&&a<0)&&(o=c,a=u,s=0),u===a&&(r[s++]=l))}return r.length=s,r},e.prototype.getIndices=function(){var e,t=this._indices;if(t){var n=t.constructor,i=this._count;
422if(n===Array){e=new n(i);for(var r=0;r<i;r++)e[r]=t[r]}else e=new n(t.buffer,0,i)}else{var n=hR(this._rawCount);e=new n(this.count());for(var r=0;r<e.length;r++)e[r]=r}return e},e.prototype.filter=function(e,t){if(!this._count)return this;for(var n=this.clone(),i=n.count(),r=new(hR(n._rawCount))(i),o=[],a=e.length,s=0,l=e[0],d=n._chunks,u=0;u<i;u++){var c=void 0,h=n.getRawIndex(u);if(0===a)c=t(u);else if(1===a)c=t(d[l][h],u);else{for(var p=0;p<a;p++)o[p]=d[e[p]][h];o[p]=u,c=t.apply(null,o)}c&&(r[s++]=h)}return s<i&&(n._indices=r),n._count=s,n._extent=[],n._updateGetRawIdx(),n},e.prototype.selectRange=function(e){var t=this.clone(),n=t._count;if(!n)return this;var i=nM(e),r=i.length;if(!r)return this;var o=t.count(),a=new(hR(t._rawCount))(o),s=0,l=i[0],d=e[l][0],u=e[l][1],c=t._chunks,h=!1;if(!t._indices){var p=0;if(1===r){for(var f=c[i[0]],g=0;g<n;g++){var m=f[g];(m>=d&&m<=u||isNaN(m))&&(a[s++]=p),p++}h=!0}else if(2===r){for(var f=c[i[0]],v=c[i[1]],y=e[i[1]][0],b=e[i[1]][1],g=0;g<n;g++){var m=f[g],x=v[g];(m>=d&&m<=u||isNaN(m))&&(x>=y&&x<=b||isNaN(x))&&(a[s++]=p),p++}h=!0}}if(!h)if(1===r)for(var g=0;g<o;g++){var w=t.getRawIndex(g),m=c[i[0]][w];(m>=d&&m<=u||isNaN(m))&&(a[s++]=w)}else for(var g=0;g<o;g++){for(var C=!0,w=t.getRawIndex(g),S=0;S<r;S++){var _=i[S],m=c[_][w];(m<e[_][0]||m>e[_][1])&&(C=!1)}C&&(a[s++]=t.getRawIndex(g))}return s<o&&(t._indices=a),t._count=s,t._extent=[],t._updateGetRawIdx(),t},e.prototype.map=function(e,t){var n=this.clone(e);return this._updateDims(n,e,t),n},e.prototype.modify=function(e,t){this._updateDims(this,e,t)},e.prototype._updateDims=function(e,t,n){for(var i=e._chunks,r=[],o=t.length,a=e.count(),s=[],l=e._rawExtent,d=0;d<t.length;d++)l[t[d]]=hI();for(var u=0;u<a;u++){for(var c=e.getRawIndex(u),h=0;h<o;h++)s[h]=i[t[h]][c];s[o]=u;var p=n&&n.apply(null,s);if(null!=p){"object"!=typeof p&&(r[0]=p,p=r);for(var d=0;d<p.length;d++){var f=t[d],g=p[d],m=l[f],v=i[f];v&&(v[c]=g),g<m[0]&&(m[0]=g),g>m[1]&&(m[1]=g)}}}},e.prototype.lttbDownSample=function(e,t){var n,i,r,o=this.clone([e],!0),a=o._chunks[e],s=this.count(),l=0,d=Math.floor(1/t),u=this.getRawIndex(0),c=new(hR(this._rawCount))(Math.min((Math.ceil(s/d)+2)*2,s));c[l++]=u;for(var h=1;h<s-1;h+=d){for(var p=Math.min(h+d,s-1),f=Math.min(h+2*d,s),g=(f+p)/2,m=0,v=p;v<f;v++){var y=this.getRawIndex(v),b=a[y];isNaN(b)||(m+=b)}m/=f-p;var x=h,w=Math.min(h+d,s),C=h-1,S=a[u];n=-1,r=x;for(var _=-1,k=0,v=x;v<w;v++){var y=this.getRawIndex(v),b=a[y];if(isNaN(b)){k++,_<0&&(_=y);continue}(i=Math.abs((C-g)*(b-S)-(C-v)*(m-S)))>n&&(n=i,r=y)}k>0&&k<w-x&&(c[l++]=Math.min(_,r),r=Math.max(_,r)),c[l++]=r,u=r}return c[l++]=this.getRawIndex(s-1),o._count=l,o._indices=c,o.getRawIndex=this._getRawIdx,o},e.prototype.minmaxDownSample=function(e,t){for(var n=this.clone([e],!0),i=n._chunks,r=Math.floor(1/t),o=i[e],a=this.count(),s=new(hR(this._rawCount))(2*Math.ceil(a/r)),l=0,d=0;d<a;d+=r){var u=d,c=o[this.getRawIndex(u)],h=d,p=o[this.getRawIndex(h)],f=r;d+r>a&&(f=a-d);for(var g=0;g<f;g++){var m=o[this.getRawIndex(d+g)];m<c&&(c=m,u=d+g),m>p&&(p=m,h=d+g)}var v=this.getRawIndex(u),y=this.getRawIndex(h);u<h?(s[l++]=v,s[l++]=y):(s[l++]=y,s[l++]=v)}return n._count=l,n._indices=s,n._updateGetRawIdx(),n},e.prototype.downSample=function(e,t,n,i){for(var r=this.clone([e],!0),o=r._chunks,a=[],s=Math.floor(1/t),l=o[e],d=this.count(),u=r._rawExtent[e]=hI(),c=new(hR(this._rawCount))(Math.ceil(d/s)),h=0,p=0;p<d;p+=s){s>d-p&&(a.length=s=d-p);for(var f=0;f<s;f++){var g=this.getRawIndex(p+f);a[f]=l[g]}var m=n(a),v=this.getRawIndex(Math.min(p+i(a,m)||0,d-1));l[v]=m,m<u[0]&&(u[0]=m),m>u[1]&&(u[1]=m),c[h++]=v}return r._count=h,r._indices=c,r._updateGetRawIdx(),r},e.prototype.each=function(e,t){if(this._count)for(var n=e.length,i=this._chunks,r=0,o=this.count();r<o;r++){var a=this.getRawIndex(r);switch(n){case 0:t(r);break;case 1:t(i[e[0]][a],r);break;case 2:t(i[e[0]][a],i[e[1]][a],r);break;default:for(var s=0,l=[];s<n;s++)l[s]=i[e[s]][a];l[s]=r,t.apply(null,l)}}},e.prototype.getDataExtent=function(e){var t,n=this._chunks[e],i=hI();if(!n)return i;var r=this.count();if(!this._indices)return this._rawExtent[e].slice();if(t=this._extent[e])return t.slice();for(var o=(t=i)[0],a=t[1],s=0;s<r;s++){var l=n[this.getRawIndex(s)];l<o&&(o=l),l>a&&(a=l)}return t=[o,a],this._extent[e]=t,t},e.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var n=[],i=this._chunks,r=0;r<i.length;r++)n.push(i[r][t]);return n},e.prototype.clone=function(t,n){var i=new e,r=this._chunks,o=t&&nS(t,function(e,t){return e[t]=!0,e},{});if(o)for(var a=0;a<r.length;a++)i._chunks[a]=o[a]?function(e){var t=e.constructor;return t===Array?e.slice():new t(e)}(r[a]):r[a];else i._chunks=r;return this._copyCommonProps(i),n||(i._indices=this._cloneIndices()),i._updateGetRawIdx(),i},e.prototype._copyCommonProps=function(e){e._count=this._count,e._rawCount=this._rawCount,e._provider=this._provider,e._dimensions=this._dimensions,e._extent=nc(this._extent),e._rawExtent=nc(this._rawExtent)},e.prototype._cloneIndices=function(){if(this._indices){var e=this._indices.constructor,t=void 0;if(e===Array){var n=this._indices.length;t=new e(n);for(var i=0;i<n;i++)t[i]=this._indices[i]}else t=new e(this._indices);return t}return null},e.prototype._getRawIdxIdentity=function(e){return e},e.prototype._getRawIdx=function(e){return e<this._count&&e>=0?this._indices[e]:-1},e.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},e.internalField=function(){function e(e,t,n,i){return hu(e[i],this._dimensions[i])}D={arrayRows:e,objectRows:function(e,t,n,i){return hu(e[t],this._dimensions[i])},keyedColumns:e,original:function(e,t,n,i){var r=e&&(null==e.value?e:e.value);return hu(r instanceof Array?r[i]:r,this._dimensions[i])},typedArray:function(e,t,n,i){return e[i]}}}(),e}(),hE=function(){function e(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return e.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},e.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},e.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},e.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},e.prototype._createSource=function(){this._setLocalSource([],[]);var e,t,n=this._sourceHost,i=this._getUpstreamSourceManagers(),r=!!i.length;if(hF(n)){var o=void 0,a=void 0,s=void 0;if(r){var l=i[0];l.prepareSource(),o=(s=l.getSource()).data,a=s.sourceFormat,t=[l._getVersionSign()]}else a=nO(o=n.get("data",!0))?co:ct,t=[];var d=this._getSourceMetaRawOption()||{},u=s&&s.metaRawOption||{},c=nG(d.seriesLayoutBy,u.seriesLayoutBy)||null,h=nG(d.sourceHeader,u.sourceHeader),p=nG(d.dimensions,u.dimensions);e=c!==u.seriesLayoutBy||!!h!=!!u.sourceHeader||p?[cQ(o,{seriesLayoutBy:c,sourceHeader:h,dimensions:p},a)]:[]}else if(r){var f=this._applyTransform(i);e=f.sourceList,t=f.upstreamSignList}else e=[cQ(n.get("source",!0),this._getSourceMetaRawOption(),null)],t=[];this._setLocalSource(e,t)},e.prototype._applyTransform=function(e){var t,n,i=this._sourceHost,r=i.get("transform",!0),o=i.get("fromTransformResult",!0);null!=o&&1!==e.length&&hO("");var a=[],s=[];return(nw(e,function(e){e.prepareSource();var t=e.getSource(o||0);null==o||t||hO(""),a.push(t),s.push(e._getVersionSign())}),r)?n=function(e,t,n){var i=aJ(e),r=i.length;r||cw("");for(var o=0;o<r;o++)t=function(e,t,n,i){t.length||cw(""),nL(e)||cw("");var r=e.type,o=hw.get(r);o||cw("");var a=nC(t,function(e){return function(e,t){var n=new hm,i=e.data,r=n.sourceFormat=e.sourceFormat,o=e.startIndex;e.seriesLayoutBy!==cs&&cw("");var a=[],s={},l=e.dimensionsDefine;if(l)nw(l,function(e,t){var n=e.name,i={index:t,name:n,displayName:e.displayName};a.push(i),null!=n&&(n4(s,n)&&cw(""),s[n]=i)});else for(var d=0;d<e.dimensionsDetectedCount||0;d++)a.push({index:d});var u=c8[hn(r,cs)];t.__isBuiltIn&&(n.getRawDataItem=function(e){return u(i,o,a,e)},n.getRawData=nT(hv,null,e)),n.cloneRawData=nT(hy,null,e),n.count=nT(c9[hn(r,cs)],null,i,o,a);var c=ht[r];n.retrieveValue=function(e,t){return h(u(i,o,a,e),t)};var h=n.retrieveValueFromItem=function(e,t){if(null!=e){var n=a[t];if(n)return c(e,t,n.name)}};return n.getDimensionInfo=nT(hb,null,a,s),n.cloneAllDimensionInfo=nT(hx,null,a),n}(e,o)});return nC(aJ(o.transform({upstream:a[0],upstreamList:a,config:nc(e.config)}
422)),function(e,n){nL(e)||cw(""),e.data||cw(""),hC(c1(e.data))||cw("");var i,r=t[0];if(r&&0===n&&!e.dimensions){var o=r.startIndex;o&&(e.data=r.data.slice(0,o).concat(e.data)),i={seriesLayoutBy:cs,sourceHeader:o,dimensions:r.metaRawOption.dimensions}}else i={seriesLayoutBy:cs,sourceHeader:0,dimensions:e.dimensions};return cQ(e.data,i,null)})}(i[o],t,0,0),o!==r-1&&(t.length=Math.max(t.length,1));return t}(r,a,{datasetIndex:i.componentIndex}):null!=o&&(n=[new cX({data:(t=a[0]).data,sourceFormat:t.sourceFormat,seriesLayoutBy:t.seriesLayoutBy,dimensionsDefine:nc(t.dimensionsDefine),startIndex:t.startIndex,dimensionsDetectedCount:t.dimensionsDetectedCount})]),{sourceList:n,upstreamSignList:s}},e.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),t=0;t<e.length;t++){var n=e[t];if(n._isDirty()||this._upstreamSignList[t]!==n._getVersionSign())return!0}},e.prototype.getSource=function(e){e=e||0;var t=this._sourceList[e];if(!t){var n=this._getUpstreamSourceManagers();return n[0]&&n[0].getSource(e)}return t},e.prototype.getSharedDataStore=function(e){var t=e.makeStoreSchema();return this._innerGetDataStore(t.dimensions,e.source,t.hash)},e.prototype._innerGetDataStore=function(e,t,n){var i=this._storeList,r=i[0];r||(r=i[0]={});var o=r[n];if(!o){var a=this._getUpstreamSourceManagers()[0];hF(this._sourceHost)&&a?o=a._innerGetDataStore(e,t,n):(o=new hP).initData(new c4(t,e.length),e),r[n]=o}return o},e.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if(hF(e)){var t=cc(e);return t?[t.getSourceManager()]:[]}return nC(e.get("transform",!0)||e.get("fromTransformResult",!0)?so(e.ecModel,"dataset",{index:e.get("fromDatasetIndex",!0),id:e.get("fromDatasetId",!0)},si).models:[],function(e){return e.getSourceManager()})},e.prototype._getSourceMetaRawOption=function(){var e,t,n,i=this._sourceHost;return hF(i)?(e=i.get("seriesLayoutBy",!0),t=i.get("sourceHeader",!0),n=i.get("dimensions",!0)):this._getUpstreamSourceManagers().length||(e=i.get("seriesLayoutBy",!0),t=i.get("sourceHeader",!0),n=i.get("dimensions",!0)),{seriesLayoutBy:e,sourceHeader:t,dimensions:n}},e}();function hL(e){e.option.transform&&nZ(e.option.transform)}function hF(e){return"series"===e.mainType}function hO(e){throw Error(e)}function hN(e){var t=e.lineHeight;return null==t?"line-height:1":"line-height:"+iE(t+"")+"px"}function hB(e,t){var n=e.color||"#6e7079",i=e.fontSize||12,r=e.fontWeight||"400",o=e.color||"#464646",a=e.fontSize||14,s=e.fontWeight||"900";return"html"===t?{nameStyle:"font-size:"+iE(i+"")+"px;color:"+iE(n)+";font-weight:"+iE(r+""),valueStyle:"font-size:"+iE(a+"")+"px;color:"+iE(o)+";font-weight:"+iE(s+"")}:{nameStyle:{fontSize:i,fill:n,fontWeight:r},valueStyle:{fontSize:a,fill:o,fontWeight:s}}}var hz=[0,10,20,30],hj=["","\n","\n\n","\n\n\n"];function hV(e,t){return t.type=e,t}function hH(e){return"section"===e.type}function hG(e,t,n,i){var r,o=t.noHeader,a={html:hz[r=function e(t){if(hH(t)){var n=0,i=t.blocks.length,r=i>1||i>0&&!t.noHeader;return nw(t.blocks,function(t){var i=e(t);i>=n&&(n=i+ +(r&&(!i||hH(t)&&!t.noHeader)))}),n}return 0}(t)],richText:hj[r]},s=[],l=t.blocks||[];nq(!l||nR(l)),l=l||[];var d=e.orderMode;if(t.sortBlocks&&d){l=l.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(n4(u,d)){var c=new hf(u[d],null);l.sort(function(e,t){return c.evaluate(e.sortParam,t.sortParam)})}else"seriesDesc"===d&&l.reverse()}nw(l,function(n,r){var o=t.valueFormatter,l=(hH(n)?hG:hW)(o?nf(nf({},e),{valueFormatter:o}):e,n,r>0?a.html:0,i);null!=l&&s.push(l)});var h="richText"===e.renderMode?s.join(a.richText):hU(i,s.join(""),o?n:a.html);if(o)return h;var p=uz(t.header,"ordinal",e.useUTC),f=hB(i,e.renderMode).nameStyle,g=hN(i);return"richText"===e.renderMode?hq(e,p,f)+a.richText+h:hU(i,'<div style="'+f+";"+g+';">'+iE(p)+"</div>"+h,n)}function hW(e,t,n,i){var r=e.renderMode,o=t.noName,a=t.noValue,s=!t.markerType,l=t.name,d=e.useUTC,u=t.valueFormatter||e.valueFormatter||function(e){return nC(e=nR(e)?e:[e],function(e,t){return uz(e,nR(w)?w[t]:w,d)})};if(!o||!a){var c,h,p,f,g,m,v,y,b=s?"":e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||"#333",r),x=o?"":uz(l,"ordinal",d),w=t.valueType,C=a?[]:u(t.value,t.dataIndex),S=!s||!o,_=!s&&o,k=hB(i,r),M=k.nameStyle,T=k.valueStyle;return"richText"===r?(s?"":b)+(o?"":hq(e,x,M))+(a?"":(c=e,h=C,p=S,f=_,g=[T],p&&g.push({padding:[0,0,0,f?10:20],align:"right"}),c.markupStyleCreator.wrapRichTextStyle(nR(h)?h.join(" "):h,g))):hU(i,(s?"":b)+(o?"":'<span style="'+M+";"+(s?"":"margin-left:2px")+'">'+iE(x)+"</span>")+(a?"":(m=C,v=S,y=_,'<span style="'+(v?"float:right;margin-left:"+(y?"10px":"20px"):"")+";"+T+'">
422'+nC(m=nR(m)?m:[m],function(e){return iE(e)}).join(" ")+"</span>")),n)}}function h$(e,t,n,i,r,o){if(e)return(hH(e)?hG:hW)({useUTC:r,renderMode:n,orderMode:i,markupStyleCreator:t,valueFormatter:e.valueFormatter},e,0,o)}function hU(e,t,n){return'<div style="margin: '+n+"px 0 0;"+hN(e)+';">'+t+'<div style="clear:both"></div></div>'}function hq(e,t,n){return e.markupStyleCreator.wrapRichTextStyle(t,n)}function hK(e,t){return uU(e.getData().getItemVisual(t,"style")[e.visualDrawType])}function hY(e,t){var n=e.get("padding");return null!=n?n:"richText"===t?[8,10]:10}var hZ=function(){function e(){this.richTextStyles={},this._nextStyleNameId=aK()}return e.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},e.prototype.makeTooltipMarker=function(e,t,n){var i="richText"===n?this._generateStyleName():null,r=uG({color:t,type:e,renderMode:n,markerId:i});return nA(r)?r:(this.richTextStyles[i]=r.style,r.content)},e.prototype.wrapRichTextStyle=function(e,t){var n={};nR(t)?nw(t,function(e){return nf(n,e)}):nf(n,t);var i=this._generateStyleName();return this.richTextStyles[i]=n,"{"+i+"|"+e+"}"},e}();function hX(e){var t,n,i,r,o=e.series,a=e.dataIndex,s=e.multipleSeries,l=o.getData(),d=l.mapDimensionsAll("defaultedTooltip"),u=d.length,c=o.getRawValue(a),h=nR(c),p=hK(o,a);if(u>1||h&&!u){var f=function(e,t,n,i,r){var o=t.getData(),a=nS(e,function(e,t,n){var i=o.getDimensionInfo(n);return e||i&&!1!==i.tooltip&&null!=i.displayName},!1),s=[],l=[],d=[];function u(e,t){var n=o.getDimensionInfo(t);n&&!1!==n.otherDims.tooltip&&(a?d.push(hV("nameValue",{markerType:"subItem",markerColor:r,name:n.displayName,value:e,valueType:n.type})):(s.push(e),l.push(n.type)))}return i.length?nw(i,function(e){u(hi(o,n,e),e)}):nw(e,u),{inlineValues:s,inlineValueTypes:l,blocks:d}}(c,o,a,d,p);t=f.inlineValues,n=f.inlineValueTypes,i=f.blocks,r=f.inlineValues[0]}else if(u){var g=l.getDimensionInfo(d[0]);r=t=hi(l,a,d[0]),n=g.type}else r=t=h?c[0]:c;var m=a6(o),v=m&&o.name||"",y=l.getName(a),b=s?v:y;return hV("section",{header:v,noHeader:s||!m,sortParam:r,blocks:[hV("nameValue",{markerType:"item",markerColor:p,name:b,noName:!nK(b),value:t,valueType:n,dataIndex:a})].concat(i||[])})}var hJ=a9();function hQ(e,t){return e.getName(t)||e.getId(t)}var h0="__universalTransitionEnabled",h1=function(e){var t;function n(){var t=null!==e&&e.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return(0,tQ.__extends)(n,e),n.prototype.init=function(e,t,n){this.seriesIndex=this.componentIndex,this.dataTask=hs({count:h3,reset:h5}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(e,n),(hJ(this).sourceManager=new hE(this)).prepareSource();var i=this.getInitialData(e,n);h6(i,this),this.dataTask.context.data=i,hJ(this).dataBeforeProcessed=i,h2(this),this._initSelectedMapFromData(i)},n.prototype.mergeDefaultAndTheme=function(e,t){var n=uQ(this),i=n?u1(e):{},r=this.subType;u5.hasClass(r)&&(r+="Series"),nh(e,t.getTheme().get(this.subType)),nh(e,this.getDefaultOption()),aQ(e,"label",["show"]),this.fillDataTextStyle(e.data),n&&u0(e,i,n)},n.prototype.mergeOption=function(e,t){e=nh(this.option,e,!0),this.fillDataTextStyle(e.data);var n=uQ(this);
422n&&u0(this.option,e,n);var i=hJ(this).sourceManager;i.dirty(),i.prepareSource();var r=this.getInitialData(e,t);h6(r,this),this.dataTask.dirty(),this.dataTask.context.data=r,hJ(this).dataBeforeProcessed=r,h2(this),this._initSelectedMapFromData(r)},n.prototype.fillDataTextStyle=function(e){if(e&&!nO(e))for(var t=["show"],n=0;n<e.length;n++)e[n]&&e[n].label&&aQ(e[n],"label",t)},n.prototype.getInitialData=function(e,t){},n.prototype.appendData=function(e){this.getRawData().appendData(e.data)},n.prototype.getData=function(e){var t=h7(this);if(!t)return hJ(this).data;var n=t.context.data;return null!=e&&n.getLinkedData?n.getLinkedData(e):n},n.prototype.getAllData=function(){var e=this.getData();return e&&e.getLinkedDataAll?e.getLinkedDataAll():[{data:e}]},n.prototype.setData=function(e){var t=h7(this);if(t){var n=t.context;n.outputData=e,t!==this.dataTask&&(n.data=e)}hJ(this).data=e},n.prototype.getEncode=function(){var e=this.get("encode",!0);if(e)return n1(e)},n.prototype.getSourceManager=function(){return hJ(this).sourceManager},n.prototype.getSource=function(){return this.getSourceManager().getSource()},n.prototype.getRawData=function(){return hJ(this).dataBeforeProcessed},n.prototype.getColorBy=function(){return this.get("colorBy")||"series"},n.prototype.isColorBySeries=function(){return"series"===this.getColorBy()},n.prototype.getBaseAxis=function(){var e=this.coordinateSystem;return e&&e.getBaseAxis&&e.getBaseAxis()},n.prototype.formatTooltip=function(e,t,n){return hX({series:this,dataIndex:e,multipleSeries:t})},n.prototype.isAnimationEnabled=function(){var e=this.ecModel;if(t1.node&&!(e&&e.ssr))return!1;var t=this.getShallow("animation");return t&&this.getData().count()>this.getShallow("animationThreshold")&&(t=!1),!!t},n.prototype.restoreData=function(){this.dataTask.dirty()},n.prototype.getColorFromPalette=function(e,t,n){var i=this.ecModel,r=cv.prototype.getColorFromPalette.call(this,e,t,n);return r||(r=i.getColorFromPalette(e,t,n)),r},n.prototype.coordDimToDataDim=function(e){return this.getRawData().mapDimensionsAll(e)},n.prototype.getProgressive=function(){return this.get("progressive")},n.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},n.prototype.select=function(e,t){this._innerSelect(this.getData(t),e)},n.prototype.unselect=function(e,t){var n=this.option.selectedMap;if(n){var i=this.option.selectedMode,r=this.getData(t);if("series"===i||"all"===n){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var o=0;o<e.length;o++){var a=hQ(r,e[o]);n[a]=!1,this._selectedDataIndicesMap[a]=-1}}},n.prototype.toggleSelect=function(e,t){for(var n=[],i=0;i<e.length;i++)n[0]=e[i],this.isSelected(e[i],t)?this.unselect(n,t):this.select(n,t)},n.prototype.getSelectedDataIndices=function(){if("all"===this.option.selectedMap)return[].slice.call(this.getData().getIndices());for(var e=this._selectedDataIndicesMap,t=nM(e),n=[],i=0;i<t.length;i++){var r=e[t[i]];r>=0&&n.push(r)}return n},n.prototype.isSelected=function(e,t){var n=this.option.selectedMap;if(!n)return!1;var i=this.getData(t);return("all"===n||n[hQ(i,e)])&&!i.getItemModel(e).get(["select","disabled"])},n.prototype.isUniversalTransitionEnabled=function(){if(this[h0])return!0;var e=this.option.universalTransition;return!!e&&(!0===e||e&&e.enabled)},n.prototype._innerSelect=function(e,t){var n,i,r=this.option,o=r.selectedMode,a=t.length;if(o&&a){if("series"===o)r.selectedMap="all";else if("multiple"===o){nL(r.selectedMap)||(r.selectedMap={});for(var s=r.selectedMap,l=0;l<a;l++){var d=t[l],u=hQ(e,d);s[u]=!0,this._selectedDataIndicesMap[u]=e.getRawIndex(d)}}else if("single"===o||!0===o){var c=t[a-1],u=hQ(e,c);(n={})[u]=!0,r.selectedMap=n,this._selectedDataIndicesMap=((i={})[u]=e.getRawIndex(c),i)}}},n.prototype._initSelectedMapFromData=function(e){if(!this.option.selectedMap){var t=[];e.hasItemOption&&e.each(function(n){var i=e.getRawDataItem(n);i&&i.selected&&t.push(n)}),t.length>0&&this._innerSelect(e,t)}},n.registerClass=function(e){return u5.registerClass(e)},n.protoInitialize=void((t=n.prototype).type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"),n}(u5);function h2(e){var t,n,i,r=e.name;a6(e)||(e.name=(n=(t=e.getRawData()).mapDimensionsAll("seriesName"),i=[],nw(n,function(e){var n=t.getDimensionInfo(e);n.displayName&&i.push(n.displayName)}),i.join(" ")||r))}function h3(e){return e.model.getRawData().count()}function h5(e){var t=e.model;return t.setData(t.getRawData().cloneShallow()),h4}function h4(e,t){t.outputData&&e.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function h6(e,t){nw(n2(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(n){e.wrapMethod(n,nD(h8,t))})}function h8(e,t){var n=h7(e);return n&&n.setOutputEnd((t||this).count()),t}function h7(e){var t=(e.ecModel||{}).scheduler,n=t&&t.getPipeline(e.uid);if(n){var i=n.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(e.uid))}return i}}nb(h1,ho),nb(h1,cv),sp(h1,u5);var h9=function(){function e(){this.group=new av,this.uid=ul("viewComponent")}return e.prototype.init=function(e,t){},e.prototype.render=function(e,t,n,i){},e.prototype.dispose=function(e,t){},e.prototype.updateView=function(e,t,n,i){},e.prototype.updateLayout=function(e,t,n,i){},e.prototype.updateVisual=function(e,t,n,i){},e.prototype.toggleBlurSeries=function(e,t,n){},e.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},e}();function pe(){var e=a9();return function(t){var n=e(t),i=t.pipelineContext,r=!!n.large,o=!!n.progressiveRen
422der,a=n.large=!!(i&&i.large),s=n.progressiveRender=!!(i&&i.progressiveRender);return(r!==a||o!==s)&&"reset"}}sh(h9),sv(h9);var pt=lu.CMD,pn=[[],[],[]],pi=Math.sqrt,pr=Math.atan2;function po(e,t){if(t){var n,i,r,o,a,s,l=e.data,d=e.len(),u=pt.M,c=pt.C,h=pt.L,p=pt.R,f=pt.A,g=pt.Q;for(r=0,o=0;r<d;){switch(n=l[r++],o=r,i=0,n){case u:case h:i=1;break;case c:i=3;break;case g:i=2;break;case f:var m=t[4],v=t[5],y=pi(t[0]*t[0]+t[1]*t[1]),b=pi(t[2]*t[2]+t[3]*t[3]),x=pr(-t[1]/b,t[0]/y);l[r]*=y,l[r++]+=m,l[r]*=b,l[r++]+=v,l[r++]*=y,l[r++]*=b,l[r++]+=x,l[r++]+=x,r+=2,o=r;break;case p:s[0]=l[r++],s[1]=l[r++],iy(s,s,t),l[o++]=s[0],l[o++]=s[1],s[0]+=l[r++],s[1]+=l[r++],iy(s,s,t),l[o++]=s[0],l[o++]=s[1]}for(a=0;a<i;a++){var w=pn[a];w[0]=l[r++],w[1]=l[r++],iy(w,w,t),l[o++]=w[0],l[o++]=w[1]}}e.increaseVersion()}}var pa=Math.sqrt,ps=Math.sin,pl=Math.cos,pd=Math.PI;function pu(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function pc(e,t){return(e[0]*t[0]+e[1]*t[1])/(pu(e)*pu(t))}function ph(e,t){return(e[0]*t[1]<e[1]*t[0]?-1:1)*Math.acos(pc(e,t))}function pp(e,t,n,i,r,o,a,s,l,d,u){var c=pd/180*l,h=pl(c)*(e-n)/2+ps(c)*(t-i)/2,p=-1*ps(c)*(e-n)/2+pl(c)*(t-i)/2,f=h*h/(a*a)+p*p/(s*s);f>1&&(a*=pa(f),s*=pa(f));var g=(r===o?-1:1)*pa((a*a*(s*s)-a*a*(p*p)-s*s*(h*h))/(a*a*(p*p)+s*s*(h*h)))||0,m=g*a*p/s,v=-(g*s)*h/a,y=(e+n)/2+pl(c)*m-ps(c)*v,b=(t+i)/2+ps(c)*m+pl(c)*v,x=ph([1,0],[(h-m)/a,(p-v)/s]),w=[(h-m)/a,(p-v)/s],C=[(-1*h-m)/a,(-1*p-v)/s],S=ph(w,C);if(-1>=pc(w,C)&&(S=pd),pc(w,C)>=1&&(S=0),S<0){var _=Math.round(S/pd*1e6)/1e6;S=2*pd+_%2*pd}u.addData(d,y,b,a,s,x,S,c,o)}var pf=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,pg=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g,pm=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.applyTransform=function(e){},t}(lk);function pv(e){return null!=e.setData}function py(e,t){var n=function(e){var t,n=new lu;if(!e)return n;var i=0,r=0,o=0,a=0,s=lu.CMD,l=e.match(pf);if(!l)return n;for(var d=0;d<l.length;d++){for(var u=l[d],c=u.charAt(0),h=void 0,p=u.match(pg)||[],f=p.length,g=0;g<f;g++)p[g]=parseFloat(p[g]);for(var m=0;m<f;){var v=void 0,y=void 0,b=void 0,x=void 0,w=void 0,C=void 0,S=void 0,_=i,k=r,M=void 0,T=void 0;switch(c){case"l":i+=p[m++],r+=p[m++],h=s.L,n.addData(h,i,r);break;case"L":i=p[m++],r=p[m++],h=s.L,n.addData(h,i,r);break;case"m":i+=p[m++],r+=p[m++],h=s.M,n.addData(h,i,r),o=i,a=r,c="l";break;case"M":i=p[m++],r=p[m++],h=s.M,n.addData(h,i,r),o=i,a=r,c="L";break;case"h":i+=p[m++],h=s.L,n.addData(h,i,r);break;case"H":i=p[m++],h=s.L,n.addData(h,i,r);break;case"v":r+=p[m++],h=s.L,n.addData(h,i,r);break;case"V":r=p[m++],h=s.L,n.addData(h,i,r);break;case"C":h=s.C,n.addData(h,p[m++],p[m++],p[m++],p[m++],p[m++],p[m++]),i=p[m-2],r=p[m-1];break;case"c":h=s.C,n.addData(h,p[m++]+i,p[m++]+r,p[m++]+i,p[m++]+r,p[m++]+i,p[m++]+r),i+=p[m-2],r+=p[m-1];break;case"S":v=i,y=r,M=n.len(),T=n.data,t===s.C&&(v+=i-T[M-4],y+=r-T[M-3]),h=s.C,_=p[m++],k=p[m++],i=p[m++],r=p[m++],n.addData(h,v,y,_,k,i,r);break;case"s":v=i,y=r,M=n.len(),T=n.data,t===s.C&&(v+=i-T[M-4],y+=r-T[M-3]),h=s.C,_=i+p[m++],k=r+p[m++],i+=p[m++],r+=p[m++],n.addData(h,v,y,_,k,i,r);break;case"Q":_=p[m++],k=p[m++],i=p[m++],r=p[m++],h=s.Q,n.addData(h,_,k,i,r);break;case"q":_=p[m++]+i,k=p[m++]+r,i+=p[m++],r+=p[m++],h=s.Q,n.addData(h,_,k,i,r);break;case"T":v=i,y=r,M=n.len(),T=n.data,t===s.Q&&(v+=i-T[M-4],y+=r-T[M-3]),i=p[m++],r=p[m++],h=s.Q,n.addData(h,v,y,i,r);break;case"t":v=i,y=r,M=n.len(),T=n.data,t===s.Q&&(v+=i-T[M-4],y+=r-T[M-3]),i+=p[m++],r+=p[m++],h=s.Q,n.addData(h,v,y,i,r);break;case"A":b=p[m++],x=p[m++],w=p[m++],C=p[m++],S=p[m++],_=i,k=r,i=p[m++],pp(_,k,i,r=p[m++],C,S,b,x,w,h=s.A,n);break;case"a":b=p[m++],x=p[m++],w=p[m++],C=p[m++],S=p[m++],_=i,k=r,i+=p[m++],pp(_,k,i,r+=p[m++],C,S,b,x,w,h=s.A,n)}}("z"===c||"Z"===c)&&(h=s.Z,n.addData(h),i=o,r=a),t=h}return n.toStatic(),n}(e),i=nf({},t);return i.buildPath=function(e){if(pv(e)){e.setData(n.data);var t=e.getContext();t&&e.rebuildPath(t,1)}else{var t=e;n.rebuildPath(t,1)}},i.applyTransform=function(e){po(n,e),this.dirtyShape()},i}function pb(e,t){t=t||{};var n=new lk;return e.shape&&n.setShape(e.shape),n.setStyle(e.style),t.bakeTransform?po(n.path,e.getComputedTransform()):t.toLocal?n.setLocalTransform(e.getComputedTransform()):n.
422copyTransform(e),n.buildPath=e.buildPath,n.applyTransform=n.applyTransform,n.z=e.z,n.z2=e.z2,n.zlevel=e.zlevel,n}var px=function(){this.cx=0,this.cy=0,this.r=0},pw=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new px},t.prototype.buildPath=function(e,t){e.moveTo(t.cx+t.r,t.cy),e.arc(t.cx,t.cy,t.r,0,2*Math.PI)},t}(lk);pw.prototype.type="circle";var pC=function(){this.cx=0,this.cy=0,this.rx=0,this.ry=0},pS=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new pC},t.prototype.buildPath=function(e,t){var n=t.cx,i=t.cy,r=t.rx,o=t.ry,a=.5522848*r,s=.5522848*o;e.moveTo(n-r,i),e.bezierCurveTo(n-r,i-s,n-a,i-o,n,i-o),e.bezierCurveTo(n+a,i-o,n+r,i-s,n+r,i),e.bezierCurveTo(n+r,i+s,n+a,i+o,n,i+o),e.bezierCurveTo(n-a,i+o,n-r,i+s,n-r,i),e.closePath()},t}(lk);pS.prototype.type="ellipse";var p_=Math.PI,pk=2*p_,pM=Math.sin,pT=Math.cos,pD=Math.acos,pR=Math.atan2,pI=Math.abs,pA=Math.sqrt,pP=Math.max,pE=Math.min;function pL(e,t,n,i,r,o,a){var s=e-n,l=t-i,d=(a?o:-o)/pA(s*s+l*l),u=d*l,c=-d*s,h=e+u,p=t+c,f=n+u,g=i+c,m=(h+f)/2,v=(p+g)/2,y=f-h,b=g-p,x=y*y+b*b,w=r-o,C=h*g-f*p,S=(b<0?-1:1)*pA(pP(0,w*w*x-C*C)),_=(C*b-y*S)/x,k=(-C*y-b*S)/x,M=(C*b+y*S)/x,T=(-C*y+b*S)/x,D=_-m,R=k-v,I=M-m,A=T-v;return D*D+R*R>I*I+A*A&&(_=M,k=T),{cx:_,cy:k,x0:-u,y0:-c,x1:_*(r/w-1),y1:k*(r/w-1)}}var pF=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0,this.cornerRadius=0},pO=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new pF},t.prototype.buildPath=function(e,t){!function(e,t){var n,i=pP(t.r,0),r=pP(t.r0||0,0),o=i>0,a=r>0;if(o||a){if(o||(i=r,r=0),r>i){var s=i;i=r,r=s}var l=t.startAngle,d=t.endAngle;if(!(isNaN(l)||isNaN(d))){var u=t.cx,c=t.cy,h=!!t.clockwise,p=pI(d-l),f=p>pk&&p%pk;if(f>1e-4&&(p=f),i>1e-4)if(p>pk-1e-4)e.moveTo(u+i*pT(l),c+i*pM(l)),e.arc(u,c,i,l,d,!h),r>1e-4&&(e.moveTo(u+r*pT(d),c+r*pM(d)),e.arc(u,c,r,d,l,h));else{var g=void 0,m=void 0,v=void 0,y=void 0,b=void 0,x=void 0,w=void 0,C=void 0,S=void 0,_=void 0,k=void 0,M=void 0,T=void 0,D=void 0,R=void 0,I=void 0,A=i*pT(l),P=i*pM(l),E=r*pT(d),L=r*pM(d),F=p>1e-4;if(F){var O=t.cornerRadius;O&&(g=(n=function(e){var t;if(nR(e)){var n=e.length;if(!n)return e;t=1===n?[e[0],e[0],0,0]:2===n?[e[0],e[0],e[1],e[1]]:3===n?e.concat(e[2]):e}else t=[e,e,e,e];return t}(O))[0],m=n[1],v=n[2],y=n[3]);var N=pI(i-r)/2;if(b=pE(N,v),x=pE(N,y),w=pE(N,g),C=pE(N,m),k=S=pP(b,x),M=_=pP(w,C),(S>1e-4||_>1e-4)&&(T=i*pT(d),D=i*pM(d),R=r*pT(l),I=r*pM(l),p<p_)){var B=function(e,t,n,i,r,o,a,s){var l=n-e,d=i-t,u=a-r,c=s-o,h=c*l-u*d;if(!(h*h<1e-4))return h=(u*(t-o)-c*(e-r))/h,[e+h*l,t+h*d]}(A,P,R,I,T,D,E,L);if(B){var z=A-B[0],j=P-B[1],V=T-B[0],H=D-B[1],G=1/pM(pD((z*V+j*H)/(pA(z*z+j*j)*pA(V*V+H*H)))/2),W=pA(B[0]*B[0]+B[1]*B[1]);k=pE(S,(i-W)/(G+1)),M=pE(_,(r-W)/(G-1))}}}if(F)if(k>1e-4){var $=pE(v,k),U=pE(y,k),q=pL(R,I,A,P,i,$,h),K=pL(T,D,E,L,i,U,h);e.moveTo(u+q.cx+q.x0,c+q.cy+q.y0),k<S&&$===U?e.arc(u+q.cx,c+q.cy,k,pR(q.y0,q.x0),pR(K.y0,K.x0),!h):($>0&&e.arc(u+q.cx,c+q.cy,$,pR(q.y0,q.x0),pR(q.y1,q.x1),!h),e.arc(u,c,i,pR(q.cy+q.y1,q.cx+q.x1),pR(K.cy+K.y1,K.cx+K.x1),!h),U>0&&e.arc(u+K.cx,c+K.cy,U,pR(K.y1,K.x1),pR(K.y0,K.x0),!h))}else e.moveTo(u+A,c+P),e.arc(u,c,i,l,d,!h);else e.moveTo(u+A,c+P);if(r>1e-4&&F)if(M>1e-4){var $=pE(g,M),U=pE(m,M),q=pL(E,L,T,D,r,-U,h),K=pL(A,P,R,I,r,-$,h);e.lineTo(u+q.cx+q.x0,c+q.cy+q.y0),M<_&&$===U?e.arc(u+q.cx,c+q.cy,M,pR(q.y0,q.x0),pR(K.y0,K.x0),!h):(U>0&&e.arc(u+q.cx,c+q.cy,U,pR(q.y0,q.x0),pR(q.y1,q.x1),!h),e.arc(u,c,r,pR(q.cy+q.y1,q.cx+q.x1),pR(K.cy+K.y1,K.cx+K.x1),h),$>0&&e.arc(u+K.cx,c+K.cy,$,pR(K.y1,K.x1),pR(K.y0,K.x0),!h))}else e.lineTo(u+E,c+L),e.arc(u,c,r,d,l,h);else e.lineTo(u+E,c+L)}else e.moveTo(u,c);e.closePath()}}}(e,t)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t}(lk);pO.prototype.type="sector";var pN=function(){this.cx=0,this.cy=0,this.r=0,this.r0=0},pB=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new pN},t.prototype.buildPath=function(e,t){var n=t.cx,i=t.cy,r=2*Math.PI;e.moveTo(n+t.r,i),e.arc(n,i,t.r,0,r,!1),e.moveTo(n+t.r0,i),e.arc(n,i,t.r0,0,r,!0)},t}(lk);function pz(e,t,n){var i=t.smooth,r=t.points;if(r&&r.length>=2){if(i){var o=function(e,t,n,i){var r,o,a,s,l=[],d=[],u=[],c=[];if(i){a=[1/0,1/0],s=[-1/0,-1/0];for(var h=0,p=e.length;h<p;
vendor: 5,285 bytes, line 422
422h++)ib(a,a,e[h]),ix(s,s,e[h]);ib(a,a,i[0]),ix(s,s,i[1])}for(var h=0,p=e.length;h<p;h++){var f=e[h];if(n)r=e[h?h-1:p-1],o=e[(h+1)%p];else if(0===h||h===p-1){l.push(ie(e[h]));continue}else r=e[h-1],o=e[h+1];io(d,o,r),ic(d,d,t);var g=ip(f,r),m=ip(f,o),v=g+m;0!==v&&(g/=v,m/=v),ic(u,d,-g),ic(c,d,m);var y=ii([],f,u),b=ii([],f,c);i&&(ix(y,y,a),ib(y,y,s),ix(b,b,a),ib(b,b,s)),l.push(y),l.push(b)}return n&&l.push(l.shift()),l}(r,i,n,t.smoothConstraint);e.moveTo(r[0][0],r[0][1]);for(var a=r.length,s=0;s<(n?a:a-1);s++){var l=o[2*s],d=o[2*s+1],u=r[(s+1)%a];e.bezierCurveTo(l[0],l[1],d[0],d[1],u[0],u[1])}}else{e.moveTo(r[0][0],r[0][1]);for(var s=1,c=r.length;s<c;s++)e.lineTo(r[s][0],r[s][1])}n&&e.closePath()}}pB.prototype.type="ring";var pj=function(){this.points=null,this.smooth=0,this.smoothConstraint=null},pV=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new pj},t.prototype.buildPath=function(e,t){pz(e,t,!0)},t}(lk);pV.prototype.type="polygon";var pH=function(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null},pG=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new pH},t.prototype.buildPath=function(e,t){pz(e,t,!1)},t}(lk);pG.prototype.type="polyline";var pW={},p$=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1},pU=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new p$},t.prototype.buildPath=function(e,t){if(this.subPixelOptimize){var n,i,r,o,a=lP(pW,t,this.style);n=a.x1,i=a.y1,r=a.x2,o=a.y2}else n=t.x1,i=t.y1,r=t.x2,o=t.y2;var s=t.percent;0!==s&&(e.moveTo(n,i),s<1&&(r=n*(1-s)+r*s,o=i*(1-s)+o*s),e.lineTo(r,o))},t.prototype.pointAt=function(e){var t=this.shape;return[t.x1*(1-e)+t.x2*e,t.y1*(1-e)+t.y2*e]},t}(lk);pU.prototype.type="line";var pq=[],pK=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1};function pY(e,t,n){var i=e.cpx2,r=e.cpy2;return null!=i||null!=r?[(n?rA:rI)(e.x1,e.cpx1,e.cpx2,e.x2,t),(n?rA:rI)(e.y1,e.cpy1,e.cpy2,e.y2,t)]:[(n?rN:rO)(e.x1,e.cpx1,e.x2,t),(n?rN:rO)(e.y1,e.cpy1,e.y2,t)]}var pZ=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new pK},t.prototype.buildPath=function(e,t){var n=t.x1,i=t.y1,r=t.x2,o=t.y2,a=t.cpx1,s=t.cpy1,l=t.cpx2,d=t.cpy2,u=t.percent;0!==u&&(e.moveTo(n,i),null==l||null==d?(u<1&&(rz(n,a,r,u,pq),a=pq[1],r=pq[2],rz(i,s,o,u,pq),s=pq[1],o=pq[2]),e.quadraticCurveTo(a,s,r,o)):(u<1&&(rL(n,a,l,r,u,pq),a=pq[1],l=pq[2],r=pq[3],rL(i,s,d,o,u,pq),s=pq[1],d=pq[2],o=pq[3]),e.bezierCurveTo(a,s,l,d,r,o)))},t.prototype.pointAt=function(e){return pY(this.shape,e,!1)},t.prototype.tangentAt=function(e){var t=pY(this.shape,e,!0);return ih(t,t)},t}(lk);pZ.prototype.type="bezier-curve";var pX=function(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},pJ=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new pX},t.prototype.buildPath=function(e,t){var n=t.cx,i=t.cy,r=Math.max(t.r,0),o=t.startAngle,a=t.endAngle,s=t.clockwise,l=Math.cos(o),d=Math.sin(o);e.moveTo(l*r+n,d*r+i),e.arc(n,i,r,o,a,!s)},t}(lk);pJ.prototype.type="arc";var pQ=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="compound",t}return(0,tQ.__extends)(t,e),t.prototype._updatePathDirty=function(){for(var e=this.shape.paths,t=this.shapeChanged(),n=0;n<e.length;n++)t=t||e[n].shapeChanged();t&&this.dirtyShape()},t.prototype.beforeBrush=function(){this._updatePathDirty();for(var e=this.shape.paths||[],t=this.getGlobalScale(),n=0;n<e.length;n++)e[n].path||e[n].createPathProxy(),e[n].path.setScale(t[0],t[1],e[n].segmentIgnoreThreshold)},t.prototype.buildPath=function(e,t){for(var n=t.paths||[],i=0;i<n.length;i++)n[i].buildPath(e,n[i].shape,!0)},t.prototype.afterBrush=function(){for(var e=this.shape.paths||[],t=0;t<e.length;t++)e[t].pathUpdated()},t.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),lk.prototype.getBoundingRect.call(this)},t}(lk),p0=function(){function e(e){this.colorStops=e||[]}return e.prototype.addColorStop=function(e,t){this.colorStops.push({offset:e,color:t})},e}(),p1=function(e){function t(t,n,i,r,o,a){var s=e.call(this,o)||this;return s.x=null==t?0:t,s.y=null==n?0:n,s.x2=null==i?1:i,s.y2=null==r?0:r,s.type="linear",s.global=a||!1,s}return(0,tQ.__extends)(t,e),t}(p0),p2=function(e){function t(t,n,i,r,o){var a=e.call(this,r)||this;return a.x=null==t?.5:t,a.y=null==n?.5:n,a.r=null==i?.5:i,a.type="radial",a.global=o||!1,a}return(0,tQ.__extends)(t,e),t}(p0),p3=[0,0],p5=[0,0],p4=new i2,p6=new i2,p8=function(){function e(e,t){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new i2;for(var n=0;n<2;n++)this._axes[n]=new i2;
422e&&this.fromBoundingRect(e,t)}return e.prototype.fromBoundingRect=function(e,t){var n=this._corners,i=this._axes,r=e.x,o=e.y,a=r+e.width,s=o+e.height;if(n[0].set(r,o),n[1].set(a,o),n[2].set(a,s),n[3].set(r,s),t)for(var l=0;l<4;l++)n[l].transform(t);i2.sub(i[0],n[1],n[0]),i2.sub(i[1],n[3],n[0]),i[0].normalize(),i[1].normalize();for(var l=0;l<2;l++)this._origin[l]=i[l].dot(n[0])},e.prototype.intersect=function(e,t){var n=!0,i=!t;return(p4.set(1/0,1/0),p6.set(0,0),!this._intersectCheckOneSide(this,e,p4,p6,i,1)&&(n=!1,i)||!this._intersectCheckOneSide(e,this,p4,p6,i,-1)&&(n=!1,i))?n:(i||i2.copy(t,n?p4:p6),n)},e.prototype._intersectCheckOneSide=function(e,t,n,i,r,o){for(var a=!0,s=0;s<2;s++){var l=this._axes[s];if(this._getProjMinMaxOnAxis(s,e._corners,p3),this._getProjMinMaxOnAxis(s,t._corners,p5),p3[1]<p5[0]||p3[0]>p5[1]){if(a=!1,r)return a;var d=Math.abs(p5[0]-p3[1]),u=Math.abs(p3[0]-p5[1]);Math.min(d,u)>i.len()&&(d<u?i2.scale(i,l,-d*o):i2.scale(i,l,u*o))}else if(n){var d=Math.abs(p5[0]-p3[1]),u=Math.abs(p3[0]-p5[1]);Math.min(d,u)<n.len()&&(d<u?i2.scale(n,l,d*o):i2.scale(n,l,-u*o))}}return a},e.prototype._getProjMinMaxOnAxis=function(e,t,n){for(var i=this._axes[e],r=this._origin,o=t[0].dot(i)+r[e],a=o,s=o,l=1;l<t.length;l++){var d=t[l].dot(i)+r[e];a=Math.min(d,a),s=Math.max(d,s)}n[0]=a,n[1]=s},e}(),p7=[],p9=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.notClear=!0,t.incremental=!0,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}return(0,tQ.__extends)(t,e),t.prototype.traverse=function(e,t){e.call(t,this)},t.prototype.useStyle=function(){this.style={}},t.prototype.getCursor=function(){return this._cursor},t.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},t.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},t.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},t.prototype.addDisplayable=function(e,t){t?this._temporaryDisplayables.push(e):this._displayables.push(e),this.markRedraw()},t.prototype.addDisplayables=function(e,t){t=t||!1;for(var n=0;n<e.length;n++)this.addDisplayable(e[n],t)},t.prototype.getDisplayables=function(){return this._displayables},t.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},t.prototype.eachPendingDisplayable=function(e){for(var t=this._cursor;t<this._displayables.length;t++)e&&e(this._displayables[t]);for(var t=0;t<this._temporaryDisplayables.length;t++)e&&e(this._temporaryDisplayables[t])},t.prototype.update=function(){this.updateTransform();for(var e=this._cursor;e<this._displayables.length;e++){var t=this._displayables[e];t.parent=this,t.update(),t.parent=null}for(var e=0;e<this._temporaryDisplayables.length;e++){var t=this._temporaryDisplayables[e];t.parent=this,t.update(),t.parent=null}},t.prototype.getBoundingRect=function(){if(!this._rect){for(var e=new rt(1/0,1/0,-1/0,-1/0),t=0;t<this._displayables.length;t++){var n=this._displayables[t],i=n.getBoundingRect().clone();
422n.needLocalTransform()&&i.applyTransform(n.getLocalTransform(p7)),e.union(i)}this._rect=e}return this._rect},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t);if(this.getBoundingRect().contain(n[0],n[1])){for(var i=0;i<this._displayables.length;i++)if(this._displayables[i].contain(e,t))return!0}return!1},t}(sV),fe=Math.max,ft=Math.min,fn={};function fi(e){return lk.extend(e)}var fr=function(e,t){var n=py(e,t),i=pm;function r(e){var t=i.call(this,e)||this;return t.applyTransform=n.applyTransform,t.buildPath=n.buildPath,t}return(0,tQ.__extends)(r,i),r};function fo(e,t){return fr(e,t)}function fa(e,t){fn[e]=t}function fs(e){if(fn.hasOwnProperty(e))return fn[e]}function fl(e,t,n,i){var r=new pm(py(e,t));return n&&("center"===i&&(n=fu(n,r.getBoundingRect())),fh(r,n)),r}function fd(e,t,n){var i=new lI({style:{image:e,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(e){if("center"===n){var r={width:e.width,height:e.height};i.setStyle(fu(t,r))}}});return i}function fu(e,t){var n,i=t.width/t.height,r=e.height*i;return n=r<=e.width?e.height:(r=e.width)/i,{x:e.x+e.width/2-r/2,y:e.y+e.height/2-n/2,width:r,height:n}}var fc=function(e,t){for(var n=[],i=e.length,r=0;r<i;r++){var o=e[r];n.push(o.getUpdatedPathProxy(!0))}var a=new lk(t);return a.createPathProxy(),a.buildPath=function(e){if(pv(e)){e.appendPath(n);var t=e.getContext();t&&e.rebuildPath(t,1)}},a};function fh(e,t){if(e.applyTransform){var n=e.getBoundingRect().calculateTransform(t);e.applyTransform(n)}}function fp(e,t){return lP(e,e,{lineWidth:t}),e}function ff(e){return lE(e.shape,e.shape,e.style),e}var fg=lL;function fm(e,t){for(var n=iK([]);e&&e!==t;)iZ(n,e.getLocalTransform(),n),e=e.parent;return n}function fv(e,t,n){return t&&!nx(t)&&(t=o8.getLocalTransform(t)),n&&(t=i0([],t)),iy([],e,t)}function fy(e,t,n){var i=0===t[4]||0===t[5]||0===t[0]?1:Math.abs(2*t[4]/t[0]),r=0===t[4]||0===t[5]||0===t[2]?1:Math.abs(2*t[4]/t[2]),o=["left"===e?-i:"right"===e?i:0,"top"===e?-r:"bottom"===e?r:0];return Math.abs((o=fv(o,t,n))[0])>Math.abs(o[1])?o[0]>0?"right":"left":o[1]>0?"bottom":"top"}function fb(e,t,n){if(e&&t){var i,r=(i={},e.traverse(function(e){!e.isGroup&&e.anid&&(i[e.anid]=e)}),i);t.traverse(function(e){if(!e.isGroup&&e.anid){var t=r[e.anid];if(t){var i=o(e);e.attr(o(t)),dB(e,i,n,lQ(e).dataIndex)}}})}function o(e){var t={x:e.x,y:e.y,rotation:e.rotation};return null!=e.shape&&(t.shape=nf({},e.shape)),t}}function fx(e,t){return nC(e,function(e){var n=e[0];n=ft(n=fe(n,t.x),t.x+t.width);var i=e[1];return[n,i=ft(i=fe(i,t.y),t.y+t.height)]})}function fw(e,t){var n=fe(e.x,t.x),i=ft(e.x+e.width,t.x+t.width),r=fe(e.y,t.y),o=ft(e.y+e.height,t.y+t.height);if(i>=n&&o>=r)return{x:n,y:r,width:i-n,height:o-r}}function fC(e,t,n){var i=nf({rectHover:!0},t),r=i.style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},e)return 0===e.indexOf("image://")?(r.image=e.slice(8),ng(r,n),new lI(i)):fl(e.replace("path://",""),i,n,"center")}function fS(e,t,n,i,r){for(var o=0,a=r[r.length-1];o<r.length;o++){var s=r[o];if(f_(e,t,n,i,s[0],s[1],a[0],a[1]))return!0;a=s}}function f_(e,t,n,i,r,o,a,s){var l,d=n-e,u=i-t,c=a-r,h=s-o,p=c*u-d*h;if((l=p)<=1e-6&&l>=-1e-6)return!1;var f=e-r,g=t-o,m=(f*u-d*g)/p;if(m<0||m>1)return!1;var v=(f*h-c*g)/p;return!(v<0)&&!(v>1)}function fk(e){var t=e.itemTooltipOption,n=e.componentModel,i=e.itemName,r=nA(t)?{formatter:t}:t,o=n.mainType,a=n.componentIndex,s={componentType:o,name:i,$vars:["name"]};s[o+"Index"]=a;var l=e.formatterParamsExtra;l&&nw(nM(l),function(e){n4(s,e)||(s[e]=l[e],s.$vars.push(e))});var d=lQ(e.el);d.componentMainType=o,d.componentIndex=a,d.tooltipConfig={name:i,option:ng({content:i,encodeHTMLContent:!0,formatterParams:s},r)}}function fM(e,t){var n;e.isGroup&&(n=t(e)),n||e.traverse(t)}function fT(e,t){if(e)if(nR(e))for(var n=0;n<e.length;n++)fM(e[n],t);else fM(e,t)}fn.circle=pw,fn.ellipse=pS,fn.sector=pO,fn.ring=pB,fn.polygon=pV,fn.polyline=pG,fn.rect=lN,fn.line=pU,fn.bezierCurve=pZ,fn.arc=pJ,e.s(["applyTransform",()=>fv,"clipPointsByRect",()=>fx,"clipRectByRect",()=>fw,"createIcon",()=>fC,"extendPath",()=>fo,"extendShape",()=>fi,"getShapeClass",()=>fs,"getTransform",()=>fm,"groupTransition",()=>fb,"lineLineIntersect",()=>f_,"linePolygonIntersect",()=>fS,"makeImage",()=>fd,"makePath",()=>fl,"mergePath",()=>fc,"registerShape",()=>fa,"resizePath",()=>fh,"setTooltipConfig",()=>fk,"subPixelOptimize",()=>fg,"subPixelOptimizeLine",()=>fp,"subPixelOptimizeRect",()=>ff,"transformDirection",()=>fy,"traverseElements",()=>fT],50142);var fD=a9(),fR=pe(),fI=function(){function e(){this.group=new av,this.uid=ul("viewChart"),this.renderTask=hs({plan:fE,reset:fL}),this.renderTask.context={view:this}}return e.prototype.init=function(e,t){},e.prototype.render=function(e,t,n,i){},e.prototype.highlight=function(e,t,n,i){var r=e.getData(i&&i.dataType);r&&fP(r,i,"emphasis")},e.prototype.downplay=function(e,t,n,i){var r=e.getData(i&&i.dataType);r&&fP(r,i,"normal")},e.prototype.remove=function(e,t){this.group.removeAll()},e.prototype.dispose=function(e,t){},e.prototype.updateView=function(e,t,n,i){this.render(e,t,n,i)},e.prototype.updateLayout=function(e,t,n,i){this.render(e,t,n,i)},e.prototype.updateVisual=function(e,t,n,i){this.render(e,t,n,i)},e.prototype.eachRendered=function(e){fT(this.group,e)},e.markUpdateMethod=function(e,t){fD(e).updateMethod=t},e.protoInitialize=void(e.prototype.type="chart"),e}();function fA(e,t,n){e&&dP(e)&&("emphasis"===t?dv:dy)(e,n)}function fP(e,t,n){var i,r,o=a7(e,t),a=t&&null!=t.highlightKey?(null==(r=l2[i=t.highlightKey])&&l1<=32&&(r=l2[i]=l1++),r):null;null!=o?nw(aJ(o),function(t){fA(e.getItemGraphicEl(t),n,a)}):e.eachItemGraphicEl(function(e){fA(e,n,a)})}function fE(e){return fR(e.model)}
422function fL(e){var t=e.model,n=e.ecModel,i=e.api,r=e.payload,o=t.pipelineContext.progressiveRender,a=e.view,s=r&&fD(r).updateMethod,l=o?"incrementalPrepareRender":s&&a[s]?s:"render";return"render"!==l&&a[l](t,n,i,r),fF[l]}sh(fI,["dispose"]),sv(fI);var fF={incrementalPrepareRender:{progress:function(e,t){t.view.incrementalRender(e,t.model,t.ecModel,t.api,t.payload)}},render:{forceFirstProgress:!0,progress:function(e,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}},fO="\0__throttleOriginMethod",fN="\0__throttleRate",fB="\0__throttleType";function fz(e,t,n){var i,r,o,a,s,l=0,d=0,u=null;function c(){d=new Date().getTime(),u=null,e.apply(o,a||[])}t=t||0;var h=function(){for(var e=[],h=0;h<arguments.length;h++)e[h]=arguments[h];i=new Date().getTime(),o=this,a=e;var p=s||t,f=s||n;s=null,r=i-(f?l:d)-p,clearTimeout(u),f?u=setTimeout(c,p):r>=0?c():u=setTimeout(c,-r),l=i};return h.clear=function(){u&&(clearTimeout(u),u=null)},h.debounceNextCall=function(e){s=e},h}function fj(e,t,n,i){var r=e[t];if(r){var o=r[fO]||r,a=r[fB];if(r[fN]!==n||a!==i){if(null==n||!i)return e[t]=o;(r=e[t]=fz(o,n,"debounce"===i))[fO]=o,r[fB]=i,r[fN]=n}return r}}function fV(e,t){var n=e[t];n&&n[fO]&&(n.clear&&n.clear(),e[t]=n[fO])}var fH=a9(),fG={itemStyle:sy(ui,!0),lineStyle:sy(ue,!0)},fW={lineStyle:"stroke",itemStyle:"fill"};function f$(e,t){var n=e.visualStyleMapper||fG[t];return n||(console.warn("Unknown style type '"+t+"'."),fG.itemStyle)}function fU(e,t){var n=e.visualDrawType||fW[t];return n||(console.warn("Unknown style type '"+t+"'."),"fill")}var fq=new ua,fK=Math.PI,fY=function(){function e(e,t,n,i){this._stageTaskMap=n1(),this.ecInstance=e,this.api=t,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}return e.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(e){var t=e.overallTask;t&&t.dirty()})},e.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var n=this._pipelineMap.get(e.__pipeline.id),i=n.context,r=!t&&n.progressiveEnabled&&(!i||i.progressiveRender)&&e.__idxInPipeline>n.blockIndex?n.step:null,o=i&&i.modDataCount,a=null!=o?Math.ceil(o/r):null;return{step:r,modBy:a,modDataCount:o}}},e.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},e.prototype.updateStreamModes=function(e,t){var n=this._pipelineMap.get(e.uid),i=e.getData().count(),r=n.progressiveEnabled&&t.incrementalPrepareRender&&i>=n.threshold,o=e.get("large")&&i>=e.get("largeThreshold"),a="mod"===e.get("progressiveChunkMode")?i:null;e.pipelineContext=n.context={progressiveRender:r,modDataCount:a,large:o}},e.prototype.restorePipelines=function(e){var t=this,n=t._pipelineMap=n1();e.eachSeries(function(e){var i=e.getProgressive(),r=e.uid;n.set(r,{id:r,head:null,tail:null,threshold:e.getProgressiveThreshold(),progressiveEnabled:i&&!(e.preventIncremental&&e.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),t._pipe(e,e.dataTask)})},e.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),n=this.api;nw(this._allHandlers,function(i){var r=e.get(i.uid)||e.set(i.uid,{});nq(!(i.reset&&i.overallReset),""),i.reset&&this._createSeriesStageTask(i,r,t,n),i.overallReset&&this._createOverallStageTask(i,r,t,n)},this)},e.prototype.prepareView=function(e,t,n,i){var r=e.renderTask,o=r.context;o.model=t,o.ecModel=n,o.api=i,r.__block=!e.incrementalPrepareRender,this._pipe(t,r)},e.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},e.prototype.performVisualTasks=function(e,t,n){this._performStageTasks(this._visualHandlers,e,t,n)},e.prototype._performStageTasks=function(e,t,n,i){i=i||{};var r=!1,o=this;function a(e,t){return e.setDirty&&(!e.dirtyMap||e.dirtyMap.get(t.__pipeline.id))}nw(e,function(e,s){if(!i.visualType||i.visualType===e.visualType){var l=o._stageTaskMap.get(e.uid),d=l.seriesTaskMap,u=l.overallTask;if(u){var c,h=u.agentStubMap;h.each(function(e){a(i,e)&&(e.dirty(),c=!0)}),c&&u.dirty(),o.updatePayload(u,n);var p=o.getPerformArgs(u,i.block);h.each(function(e){e.perform(p)}),u.perform(p)&&(r=!0)}else d&&d.each(function(s,l){a(i,s)&&s.dirty();var d=o.getPerformArgs(s,i.block);
422d.skip=!e.performRawSeries&&t.isSeriesFiltered(s.context.model),o.updatePayload(s,n),s.perform(d)&&(r=!0)})}}),this.unfinished=r||this.unfinished},e.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(e){t=e.dataTask.perform()||t}),this.unfinished=t||this.unfinished},e.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},e.prototype.updatePayload=function(e,t){"remain"!==t&&(e.context.payload=t)},e.prototype._createSeriesStageTask=function(e,t,n,i){var r=this,o=t.seriesTaskMap,a=t.seriesTaskMap=n1(),s=e.seriesType,l=e.getTargetSeries;function d(t){var s=t.uid,l=a.set(s,o&&o.get(s)||hs({plan:f0,reset:f1,count:f5}));l.context={model:t,ecModel:n,api:i,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:r},r._pipe(t,l)}e.createOnAllSeries?n.eachRawSeries(d):s?n.eachRawSeriesByType(s,d):l&&l(n,i).each(d)},e.prototype._createOverallStageTask=function(e,t,n,i){var r=this,o=t.overallTask=t.overallTask||hs({reset:fZ});o.context={ecModel:n,api:i,overallReset:e.overallReset,scheduler:r};var a=o.agentStubMap,s=o.agentStubMap=n1(),l=e.seriesType,d=e.getTargetSeries,u=!0,c=!1;function h(e){var t=e.uid,n=s.set(t,a&&a.get(t)||(c=!0,hs({reset:fX,onDirty:fQ})));n.context={model:e,overallProgress:u},n.agent=o,n.__block=u,r._pipe(e,n)}nq(!e.createOnAllSeries,""),l?n.eachRawSeriesByType(l,h):d?d(n,i).each(h):(u=!1,nw(n.getSeries(),h)),c&&o.dirty()},e.prototype._pipe=function(e,t){var n=e.uid,i=this._pipelineMap.get(n);i.head||(i.head=t),i.tail&&i.tail.pipe(t),i.tail=t,t.__idxInPipeline=i.count++,t.__pipeline=i},e.wrapStageHandler=function(e,t){return nI(e)&&(e={overallReset:e,seriesType:function(e){R=null;try{e(f4,f6)}catch(e){}return R}(e)}),e.uid=ul("stageHandler"),t&&(e.visualType=t),e},e}();function fZ(e){e.overallReset(e.ecModel,e.api,e.payload)}function fX(e){return e.overallProgress&&fJ}function fJ(){this.agent.dirty(),this.getDownstream().dirty()}function fQ(){this.agent&&this.agent.dirty()}function f0(e){return e.plan?e.plan(e.model,e.ecModel,e.api,e.payload):null}function f1(e){e.useClearVisual&&e.data.clearAllVisual();var t=e.resetDefines=aJ(e.reset(e.model,e.ecModel,e.api,e.payload));return t.length>1?nC(t,function(e,t){return f3(t)}):f2}var f2=f3(0);function f3(e){return function(t,n){var i=n.data,r=n.resetDefines[e];if(r&&r.dataEach)for(var o=t.start;o<t.end;o++)r.dataEach(i,o);else r&&r.progress&&r.progress(t,i)}}function f5(e){return e.data.count()}var f4={},f6={};function f8(e,t){for(var n in t.prototype)e[n]=n6}f8(f4,cS),f8(f6,cD),f4.eachSeriesByType=f4.eachRawSeriesByType=function(e){R=e},f4.eachComponent=function(e){"series"===e.mainType&&e.subType&&(R=e.subType)};var f7=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],f9="#B9B8CE",ge="#100C2A",gt=function(){return{axisLine
422:{lineStyle:{color:f9}},splitLine:{lineStyle:{color:"#484753"}},splitArea:{areaStyle:{color:["rgba(255,255,255,0.02)","rgba(255,255,255,0.05)"]}},minorSplitLine:{lineStyle:{color:"#20203B"}}}},gn=["#4992ff","#7cffb2","#fddd60","#ff6e76","#58d9f9","#05c091","#ff8a45","#8d48e3","#dd79ff"],gi={darkMode:!0,color:gn,backgroundColor:ge,axisPointer:{lineStyle:{color:"#817f91"},crossStyle:{color:"#817f91"},label:{color:"#fff"}},legend:{textStyle:{color:f9},pageTextStyle:{color:f9}},textStyle:{color:f9},title:{textStyle:{color:"#EEF1FA"},subtextStyle:{color:"#B9B8CE"}},toolbox:{iconStyle:{borderColor:f9}},dataZoom:{borderColor:"#71708A",textStyle:{color:f9},brushStyle:{color:"rgba(135,163,206,0.3)"},handleStyle:{color:"#353450",borderColor:"#C5CBE3"},moveHandleStyle:{color:"#B0B6C3",opacity:.3},fillerColor:"rgba(135,163,206,0.2)",emphasis:{handleStyle:{borderColor:"#91B7F2",color:"#4D587D"},moveHandleStyle:{color:"#636D9A",opacity:.7}},dataBackground:{lineStyle:{color:"#71708A",width:1},areaStyle:{color:"#71708A"}},selectedDataBackground:{lineStyle:{color:"#87A3CE"},areaStyle:{color:"#87A3CE"}}},visualMap:{textStyle:{color:f9}},timeline:{lineStyle:{color:f9},label:{color:f9},controlStyle:{color:f9,borderColor:f9}},calendar:{itemStyle:{color:ge},dayLabel:{color:f9},monthLabel:{color:f9},yearLabel:{color:f9}},timeAxis:gt(),logAxis:gt(),valueAxis:gt(),categoryAxis:gt(),line:{symbol:"circle"},graph:{color:gn},gauge:{title:{color:f9},axisLine:{lineStyle:{color:[[1,"rgba(207,212,219,0.2)"]]}},axisLabel:{color:f9},detail:{color:"#EEF1FA"}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}}};gi.categoryAxis.splitLine.show=!1;var gr=function(){function e(){}return e.prototype.normalizeQuery=function(e){var t={},n={},i={};if(nA(e)){var r=sc(e);t.mainType=r.main||null,t.subType=r.sub||null}else{var o=["Index","Name","Id"],a={name:1,dataIndex:1,dataType:1};nw(e,function(e,r){for(var s=!1,l=0;l<o.length;l++){var d=o[l],u=r.lastIndexOf(d);if(u>0&&u===r.length-d.length){var c=r.slice(0,u);"data"!==c&&(t.mainType=c,t[d.toLowerCase()]=e,s=!0)}}a.hasOwnProperty(r)&&(n[r]=e,s=!0),s||(i[r]=e)})}return{cptQuery:t,dataQuery:n,otherQuery:i}},e.prototype.filter=function(e,t){var n=this.eventInfo;if(!n)return!0;var i=n.targetEl,r=n.packedEvent,o=n.model,a=n.view;if(!o||!a)return!0;var s=t.cptQuery,l=t.dataQuery;return d(s,o,"mainType")&&d(s,o,"subType")&&d(s,o,"index","componentIndex")&&d(s,o,"name")&&d(s,o,"id")&&d(l,r,"name")&&d(l,r,"dataIndex")&&d(l,r,"dataType")&&(!a.filterForExposedEvent||a.filterForExposedEvent(e,t.otherQuery,i,r));function d(e,t,n,i){return null==e[n]||t[i||n]===e[n]}},e.prototype.afterTrigger=function(){this.eventInfo=null},e}(),go=["symbol","symbolSize","symbolRotate","symbolOffset"],ga=go.concat(["symbolKeepAspect"]);function gs(e,t,n){switch(n){case"color":return e.getItemVisual(t,"style")[e.getVisual("drawType")];case"opacity":return e.getItemVisual(t,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return e.getItemVisual(t,n)}}function gl(e,t){switch(t){case"color":return e.getVisual("style")[e.getVisual("drawType")];case"opacity":return e.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return e.getVisual(t)}}function gd(e,t,n,i){switch(n){case"color":e.ensureUniqueItemVisual(t,"style")[e.getVisual("drawType")]=i,e.setItemVisual(t,"colorFromPalette",!1);break;case"opacity":e.ensureUniqueItemVisual(t,"style").opacity=i;break;case"symbol":case"symbolSize":case"liftZ":e.setItemVisual(t,n,i)}}function gu(e,t){nw([[e+"ToggleSelect","toggleSelect"],[e+"Select","select"],[e+"UnSelect","unselect"]],function(n){t(n[0],function(t,i,r){var o,a;t=nf({},t),r.dispatchAction(nf(t,{type:n[1],seriesIndex:(o=t,a=[],i.eachComponent({mainType:"series",subType:e,query:o},function(e){a.push(e.seriesIndex)}),a)}))})})}function gc(e,t,n,i,r){var o=e+t;n.isSilent(o)||i.eachComponent({mainType:"series",subType:"pie"},function(e){for(var t=e.seriesIndex,i=e.option.selectedMap,a=r.selected,s=0;s<a.length;s++)if(a[s].seriesIndex===t){var l=e.getData(),d=a7(l,r.fromActionPayload);n.trigger(o,{type:o,seriesId:e.id,name:nR(d)?l.getName(d[0]):l.getName(d),selected:nA(i)?i:nf({},i)})}})}function gh(e,t,n){for(var i;e&&(!t(e)||(i=e,!n));)e=e.__hostTarget||e.parent;return i}var gp=Math.round(9*Math.random()),gf="function"==typeof Object.defineProperty,gg=function(){function e(){this._id="__ec_inner_"+gp++}return e.prototype.get=function(e){return this._guard(e)[this._id]},e.prototype.set=function(e,t){var n=this._guard(e);return gf?Object.defineProperty(n,this._id,{value:t,enumerable:!1,
vendor: 7,267 bytes, line 422
422configurable:!0}):n[this._id]=t,this},e.prototype.delete=function(e){return!!this.has(e)&&(delete this._guard(e)[this._id],!0)},e.prototype.has=function(e){return!!this._guard(e)[this._id]},e.prototype._guard=function(e){if(e!==Object(e))throw TypeError("Value of WeakMap is not a non-null object.");return e},e}(),gm=lk.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var n=t.cx,i=t.cy,r=t.width/2,o=t.height/2;e.moveTo(n,i-o),e.lineTo(n+r,i+o),e.lineTo(n-r,i+o),e.closePath()}}),gv=lk.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var n=t.cx,i=t.cy,r=t.width/2,o=t.height/2;e.moveTo(n,i-o),e.lineTo(n+r,i),e.lineTo(n,i+o),e.lineTo(n-r,i),e.closePath()}}),gy=lk.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var n=t.x,i=t.y,r=t.width/5*3,o=Math.max(r,t.height),a=r/2,s=a*a/(o-a),l=i-o+a+s,d=Math.asin(s/a),u=Math.cos(d)*a,c=Math.sin(d),h=Math.cos(d),p=.6*a,f=.7*a;e.moveTo(n-u,l+s),e.arc(n,l,a,Math.PI-d,2*Math.PI+d),e.bezierCurveTo(n+u-c*p,l+s+h*p,n,i-f,n,i),e.bezierCurveTo(n,i-f,n-u+c*p,l+s+h*p,n-u,l+s),e.closePath()}}),gb=lk.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var n=t.height,i=t.width,r=t.x,o=t.y,a=i/3*2;e.moveTo(r,o),e.lineTo(r+a,o+n),e.lineTo(r,o+n/4*3),e.lineTo(r-a,o+n),e.lineTo(r,o),e.closePath()}}),gx={line:function(e,t,n,i,r){r.x1=e,r.y1=t+i/2,r.x2=e+n,r.y2=t+i/2},rect:function(e,t,n,i,r){r.x=e,r.y=t,r.width=n,r.height=i},roundRect:function(e,t,n,i,r){r.x=e,r.y=t,r.width=n,r.height=i,r.r=Math.min(n,i)/4},square:function(e,t,n,i,r){var o=Math.min(n,i);r.x=e,r.y=t,r.width=o,r.height=o},circle:function(e,t,n,i,r){r.cx=e+n/2,r.cy=t+i/2,r.r=Math.min(n,i)/2},diamond:function(e,t,n,i,r){r.cx=e+n/2,r.cy=t+i/2,r.width=n,r.height=i},pin:function(e,t,n,i,r){r.x=e+n/2,r.y=t+i/2,r.width=n,r.height=i},arrow:function(e,t,n,i,r){r.x=e+n/2,r.y=t+i/2,r.width=n,r.height=i},triangle:function(e,t,n,i,r){r.cx=e+n/2,r.cy=t+i/2,r.width=n,r.height=i}},gw={};nw({line:pU,rect:lN,roundRect:lN,square:lN,circle:pw,diamond:gv,pin:gy,arrow:gb,triangle:gm},function(e,t){gw[t]=new e});var gC=lk.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(e,t,n){var i=al(e,t,n),r=this.shape;return r&&"pin"===r.symbolType&&"inside"===t.position&&(i.y=n.y+.4*n.height),i},buildPath:function(e,t,n){var i=t.symbolType;if("none"!==i){var r=gw[i];r||(r=gw[i="rect"]),gx[i](t.x,t.y,t.width,t.height,r.shape),r.buildPath(e,r.shape,n)}}});function gS(e,t){if("image"!==this.type){var n=this.style;this.__isEmptyBrush?(n.stroke=e,n.fill=t||"#fff",n.lineWidth=2):"line"===this.shape.symbolType?n.stroke=e:n.fill=e,this.markRedraw()}}function g_(e,t,n,i,r,o,a){var s,l=0===e.indexOf("empty");return l&&(e=e.substr(5,1).toLowerCase()+e.substr(6)),(s=0===e.indexOf("image://")?fd(e.slice(8),new rt(t,n,i,r),a?"center":"cover"):0===e.indexOf("path://")?fl(e.slice(7),{},new rt(t,n,i,r),a?"center":"cover"):new gC({shape:{symbolType:e,x:t,y:n,width:i,height:r}})).__isEmptyBrush=l,s.setColor=gS,o&&s.setColor(o),s}function gk(e){return nR(e)||(e=[+e,+e]),[e[0]||0,e[1]||0]}function gM(e,t){if(null!=e)return nR(e)||(e=[e,e]),[aR(e[0],t[0])||0,aR(nG(e[1],e[0]),t[1])||0]}function gT(e){return isFinite(e)}function gD(e,t,n){for(var i,r,o,a,s,l,d,u,c,h,p="radial"===t.type?(o=Math.min(i=n.width,r=n.height),a=null==t.x?.5:t.x,s=null==t.y?.5:t.y,l=null==t.r?.5:t.r,t.global||(a=a*i+n.x,s=s*r+n.y,l*=o),a=gT(a)?a:.5,s=gT(s)?s:.5,l=l>=0&&gT(l)?l:.5,e.createRadialGradient(a,s,0,a,s,l)):(d=null==t.x?0:t.x,u=null==t.x2?1:t.x2,c=null==t.y?0:t.y,h=null==t.y2?0:t.y2,t.global||(d=d*n.width+n.x,u=u*n.width+n.x,c=c*n.height+n.y,h=h*n.height+n.y),d=gT(d)?d:0,u=gT(u)?u:1,c=gT(c)?c:0,h=gT(h)?h:0,e.createLinearGradient(d,c,u,h)),f=t.colorStops,g=0;g<f.length;g++)p.addColorStop(f[g].offset,f[g].color);return p}function gR(e){return parseInt(e,10)}function gI(e,t,n){var i=["width","height"][t],r=["clientWidth","clientHeight"][t],o=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=n[i]&&"auto"!==n[i])return parseFloat(n[i]);var s=document.defaultView.getComputedStyle(e);return(e[r]||gR(s[i])||gR(e.style[i]))-(gR(s[o])||0)-(gR(s[a])||0)|0}function gA(e){var t,n,i=e.style,r=i.lineDash&&i.lineWidth>0&&(t=i.lineDash,n=i.lineWidth,t&&"solid"!==t&&n>0?"dashed"===t?[4*n,2*n]:"dotted"===t?[n]:nE(t)?[t]:nR(t)?t:null:null),o=i.lineDashOffset;if(r){var a=i.strokeNoScale&&e.getLineScale?e.getLineScale():1;a&&1!==a&&(r=nC(r,function(e){return e/a}),o/=a)}return[r,o]}var gP=new lu(!0);function gE(e){var t=e.stroke;return null!=t&&"none"!==t&&e.lineWidth>0}function gL(e){return"string"==typeof e&&"none"!==e}function gF(e){var t=e.fill;return null!=t&&"none"!==t}function gO(e,t){if(null!=t.fillOpacity&&1!==t.fillOpacity){var n=e.globalAlpha;e.globalAlpha=t.fillOpacity*t.opacity,e.fill(),e.globalAlpha=n}else e.fill()}function gN(e,t){if(null!=t.strokeOpacity&&1!==t.strokeOpacity){var n=e.globalAlpha;e.globalAlpha=t.strokeOpacity*t.opacity,e.stroke(),e.globalAlpha=n}else e.stroke()}function gB(e,t,n){var i=sC(t.image,t.__image,n);if(s_(i)){var r=e.createPattern(i,t.repeat||"repeat");if("function"==typeof DOMMatrix&&r&&r.setTransform){var o=new DOMMatrix;o.translateSelf(t.x||0,t.y||0),o.rotateSelf(0,0,(t.rotation||0)*n8),o.scaleSelf(t.scaleX||1,t.scaleY||1),r.setTransform(o)}return r}}var gz=["shadowBlur","shadowOffsetX","shadowOffsetY"],gj=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function gV(e,t,n,i,r){var o=!1;if(!i&&t===(n=n||{}))return!1;if(i||t.opacity!==n.opacity){gW(e,r),o=!0;var a=Math.max(Math.min(t.opacity,1),0);e.globalAlpha=isNaN(a)?sN.opacity:a}(i||t.blend!==n.blend)&&(o||(gW(e,r),o=!0),e.globalCompositeOperation=t.blend||sN.blend);for(var s=0;s<gz.length;s++){var l=gz[s];(i||t[l]!==n[l])&&(o||(gW(e,r),o=!0),e[l]=e.dpr*(t[l]||0))}return(i||t.shadowColor!==n.shadowColor)&&(o||(gW(e,r),o=!0),e.shadowColor=t.shadowColor||sN.shadowColor),o}function gH(e,t,n,i,r){var o=g$(t,r.inHover),a=i?null:n&&g$(n,r.inHover)||{};if(o===a)return!1;var s=gV(e,o,a,i,r);if((i||o.fill!==a.fill)&&(s||(gW(e,r),s=!0),gL(o.fill)&&(e.fillStyle=o.fill)),(i||o.stroke!==a.stroke)&&(s||(gW(e,r),s=!0),gL(o.stroke)&&(e.strokeStyle=o.stroke)),(i||o.opacity!==a.opacity)&&(s||(gW(e,r),s=!0),e.globalAlpha=null==o.opacity?1:o.opacity),t.hasStroke()){var l=o.lineWidth/(o.strokeNoScale&&t.getLineScale?t.getLineScale():1);e.lineWidth!==l&&(s||(gW(e,r),s=!0),e.lineWidth=l)}for(var d=0;d<gj.length;d++){var u=gj[d],c=u[0];(i||o[c]!==a[c])&&(s||(gW(e,r),s=!0),e[c]=o[c]||u[1])}return s}function gG(e,t){var n=t.transform,i=e.dpr||1;n?e.setTransform(i*n[0],i*n[1],i*n[2],i*n[3],i*n[4],i*n[5]):e.setTransform(i,0,0,i,0,0)}function gW(e,t){t.batchFill&&e.fill(),t.batchStroke&&e.stroke(),t.batchFill="",t.batchStroke=""}function g$(e,t){return t&&e.__hoverStyle||e.style}function gU(e,t){gq(e,t,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function gq(e,t,n,i){var r,o=t.transform;if(!t.shouldBePainted(n.viewWidth,n.viewHeight,!1,!1)){t.__dirty&=-2,t.__isRendered=!1;return}var a=t.__clipPaths,s=n.prevElClipPaths,l=!1,d=!1;if(!s||function(e,t){if(e===t||!e&&!t)return!1;if(!e||!t||e.length!==t.length)return!0;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!0;return!1}
422(a,s)){if(s&&s.length&&(gW(e,n),e.restore(),d=l=!0,n.prevElClipPaths=null,n.allClipped=!1,n.prevEl=null),a&&a.length){gW(e,n),e.save();for(var u=!1,c=0;c<a.length;c++){var h=a[c];u=u||h.isZeroArea(),gG(e,h),e.beginPath(),h.buildPath(e,h.shape),e.clip()}n.allClipped=u,l=!0}n.prevElClipPaths=a}if(n.allClipped){t.__isRendered=!1;return}t.beforeBrush&&t.beforeBrush(),t.innerBeforeBrush();var p=n.prevEl;p||(d=l=!0);var f=t instanceof lk&&t.autoBatch&&(v=gF(m=t.style),y=gE(m),!(m.lineDash||!(v^y)||v&&"string"!=typeof m.fill||y&&"string"!=typeof m.stroke||m.strokePercent<1||m.strokeOpacity<1||m.fillOpacity<1));!l&&(b=p.transform,o&&b?o[0]===b[0]&&o[1]===b[1]&&o[2]===b[2]&&o[3]===b[3]&&o[4]===b[4]&&o[5]===b[5]:+(!o&&!b))?f||gW(e,n):(gW(e,n),gG(e,t));var g=g$(t,n.inHover);if(t instanceof lk)1!==n.lastDrawType&&(d=!0,n.lastDrawType=1),gH(e,t,p,d,n),f&&(n.batchFill||n.batchStroke)||e.beginPath(),function(e,t,n,i){var r,o,a,s=gE(n),l=gF(n),d=n.strokePercent,u=d<1,c=!t.path;(!t.silent||u)&&c&&t.createPathProxy();var h=t.path||gP,p=t.__dirty;if(!i){var f=n.fill,g=n.stroke,m=l&&!!f.colorStops,v=s&&!!g.colorStops,y=l&&!!f.image,b=s&&!!g.image,x=void 0,w=void 0,C=void 0,S=void 0,_=void 0;(m||v)&&(_=t.getBoundingRect()),m&&(x=p?gD(e,f,_):t.__canvasFillGradient,t.__canvasFillGradient=x),v&&(w=p?gD(e,g,_):t.__canvasStrokeGradient,t.__canvasStrokeGradient=w),y&&(C=p||!t.__canvasFillPattern?gB(e,f,t):t.__canvasFillPattern,t.__canvasFillPattern=C),b&&(S=p||!t.__canvasStrokePattern?gB(e,g,t):t.__canvasStrokePattern,t.__canvasStrokePattern=C),m?e.fillStyle=x:y&&(C?e.fillStyle=C:l=!1),v?e.strokeStyle=w:b&&(S?e.strokeStyle=S:s=!1)}var k=t.getGlobalScale();h.setScale(k[0],k[1],t.segmentIgnoreThreshold),e.setLineDash&&n.lineDash&&(o=(r=gA(t))[0],a=r[1]);var M=!0;(c||4&p)&&(h.setDPR(e.dpr),u?h.setContext(null):(h.setContext(e),M=!1),h.reset(),t.buildPath(h,t.shape,i),h.toStatic(),t.pathUpdated()),M&&h.rebuildPath(e,u?d:1),o&&(e.setLineDash(o),e.lineDashOffset=a),!i&&(n.strokeFirst?(s&&gN(e,n),l&&gO(e,n)):(l&&gO(e,n),s&&gN(e,n))),o&&e.setLineDash([])}(e,t,g,f),f&&(n.batchFill=g.fill||"",n.batchStroke=g.stroke||"");else if(t instanceof lT){3!==n.lastDrawType&&(d=!0,n.lastDrawType=3),gH(e,t,p,d,n);var m,v,y,b,x,w=g.text;if(null!=w&&(w+=""),w){e.font=g.font||t3,e.textAlign=g.textAlign,e.textBaseline=g.textBaseline;var C=void 0,S=void 0;e.setLineDash&&g.lineDash&&(C=(x=gA(t))[0],S=x[1]),C&&(e.setLineDash(C),e.lineDashOffset=S),g.strokeFirst?(gE(g)&&e.strokeText(w,g.x,g.y),gF(g)&&e.fillText(w,g.x,g.y)):(gF(g)&&e.fillText(w,g.x,g.y),gE(g)&&e.strokeText(w,g.x,g.y)),C&&e.setLineDash([])}}else t instanceof lI?(2!==n.lastDrawType&&(d=!0,n.lastDrawType=2),r=d,gV(e,g$(t,n.inHover),p&&g$(p,n.inHover),r,n),function(e,t,n){var i=t.__image=sC(n.image,t.__image,t,t.onload);if(i&&s_(i)){var r=n.x||0,o=n.y||0,a=t.getWidth(),s=t.getHeight(),l=i.width/i.height;if(null==a&&null!=s?a=s*l:null==s&&null!=a?s=a/l:null==a&&null==s&&(a=i.width,s=i.height),n.sWidth&&n.sHeight){var d=n.sx||0,u=n.sy||0;e.drawImage(i,d,u,n.sWidth,n.sHeight,r,o,a,s)}else if(n.sx&&n.sy){var d=n.sx,u=n.sy,c=a-d,h=s-u;e.drawImage(i,d,u,c,h,r,o,a,s)}else e.drawImage(i,r,o,a,s)}}(e,t,g)):t.getTemporalDisplayables&&(4!==n.lastDrawType&&(d=!0,n.lastDrawType=4),function(e,t,n){var i,r,o=t.getDisplayables(),a=t.getTemporalDisplayables();e.save();var s={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:n.viewWidth,viewHeight:n.viewHeight,inHover:n.inHover};for(i=t.getCursor(),r=o.length;i<r;i++){var l=o[i];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),gq(e,l,s,i===r-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),s.prevEl=l}for(var d=0,u=a.length;d<u;d++){var l=a[d];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),gq(e,l,s,d===u-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),s.prevEl=l}t.clearTemporalDisplayables(),t.notClear=!0,e.restore()}(e,t,n));f&&i&&gW(e,n),t.innerAfterBrush(),t.afterBrush&&t.afterBrush(),n.prevEl=t,t.__dirty=0,t.__isRendered=!0}var gK=new gg,gY=new rU(100),gZ=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function gX(e,t){if("none"===e)return null;var n=t.getDevicePixelRatio(),i=t.getZr(),r="svg"===i.painter.type;e.dirty&&gK.delete(e);var o=gK.get(e);if(o)return o;
422var a=ng(e,{symbol:"rect",symbolSize:1,symbolKeepAspect:!0,color:"rgba(0, 0, 0, 0.2)",backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});"none"===a.backgroundColor&&(a.backgroundColor=null);var s={repeat:"repeat"};return function(e){for(var t,o,s=[n],l=!0,d=0;d<gZ.length;++d){var u=a[gZ[d]];if(null!=u&&!nR(u)&&!nA(u)&&!nE(u)&&"boolean"!=typeof u){l=!1;break}s.push(u)}if(l){t=s.join(",")+(r?"-svg":"");var c=gY.get(t);c&&(r?e.svgElement=c:e.image=c)}var h=function e(t){if(!t||0===t.length)return[[0,0]];if(nE(t)){var n=Math.ceil(t);return[[n,n]]}for(var i=!0,r=0;r<t.length;++r)if(!nE(t[r])){i=!1;break}if(i)return e([t]);for(var o=[],r=0;r<t.length;++r)if(nE(t[r])){var n=Math.ceil(t[r]);o.push([n,n])}else{var n=nC(t[r],function(e){return Math.ceil(e)});n.length%2==1?o.push(n.concat(n)):o.push(n)}return o}(a.dashArrayX),p=function(e){if(!e||"object"==typeof e&&0===e.length)return[0,0];if(nE(e)){var t=Math.ceil(e);return[t,t]}var n=nC(e,function(e){return Math.ceil(e)});return e.length%2?n.concat(n):n}(a.dashArrayY),f=function e(t){if(!t||0===t.length)return[["rect"]];if(nA(t))return[[t]];for(var n=!0,i=0;i<t.length;++i)if(!nA(t[i])){n=!1;break}if(n)return e([t]);for(var r=[],i=0;i<t.length;++i)nA(t[i])?r.push([t[i]]):r.push(t[i]);return r}(a.symbol),g=nC(h,function(e){return gJ(e)}),m=gJ(p),v=!r&&t4.createCanvas(),y=r&&{tag:"g",attrs:{},key:"dcl",children:[]},b=function(){for(var e=1,t=0,n=g.length;t<n;++t)e=aY(e,g[t]);for(var i=1,t=0,n=f.length;t<n;++t)i=aY(i,f[t].length);e*=i;var r=m*g.length*f.length;return{width:Math.max(1,Math.min(e,a.maxTileWidth)),height:Math.max(1,Math.min(r,a.maxTileHeight))}}();v&&(v.width=b.width*n,v.height=b.height*n,o=v.getContext("2d")),function(){o&&(o.clearRect(0,0,v.width,v.height),a.backgroundColor&&(o.fillStyle=a.backgroundColor,o.fillRect(0,0,v.width,v.height)));for(var e=0,t=0;t<p.length;++t)e+=p[t];if(!(e<=0))for(var s=-m,l=0,d=0,u=0;s<b.height;){if(l%2==0){for(var c=d/2%f.length,g=0,x=0,w=0;g<2*b.width;){for(var C=0,t=0;t<h[u].length;++t)C+=h[u][t];if(C<=0)break;if(x%2==0){var S=(1-a.symbolSize)*.5,_=g+h[u][x]*S,k=s+p[l]*S,M=h[u][x]*a.symbolSize,T=p[l]*a.symbolSize,D=w/2%f[c].length;!function(e,t,s,l,d){var u=r?1:n,c=g_(d,e*u,t*u,s*u,l*u,a.color,a.symbolKeepAspect);if(r){var h=i.painter.renderOneToVNode(c);h&&y.children.push(h)}else gU(o,c)}(_,k,M,T,f[c][D])}g+=h[u][x],++w,++x===h[u].length&&(x=0)}++u===h.length&&(u=0)}s+=p[l],++d,++l===p.length&&(l=0)}}(),l&&gY.put(t,v||y),e.image=v,e.svgElement=y,e.svgWidth=b.width,e.svgHeight=b.height}(s),s.rotation=a.rotation,s.scaleX=s.scaleY=r?1:1/n,gK.set(e,s),e.dirty=!1,s}function gJ(e){for(var t=0,n=0;n<e.length;++n)t+=e[n];return e.length%2==1?2*t:t}var gQ=new iS,g0={},g1="5.6.0",g2={zrender:"5.6.1"},g3={PROCESSOR:{FILTER:1e3,SERIES_FILTER:800,STATISTIC:5e3},VISUAL:{LAYOUT:1e3,PROGRESSIVE_LAYOUT:1100,GLOBAL:2e3,CHART:3e3,POST_CHART_LAYOUT:4600,COMPONENT:4e3,BRUSH:5e3,CHART_ITEM:4500,ARIA:6e3,DECAL:7e3}},g5="__flagInMainProcess",g4="__pendingUpdate",g6="__needsUpdateStatus",g8=/^[a-zA-Z0-9_]+$/,g7="__connectUpdateStatus";function g9(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return this.isDisposed()?void ms(this.id):mt(this,e,t)}}function me(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return mt(this,e,t)}}function mt(e,t,n){return n[0]=n[0]&&n[0].toLowerCase(),iS.prototype[t].apply(e,n)}var mn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t}(iS),mi=mn.prototype;mi.on=me("on"),mi.off=me("off");var mr=function(e){function t(t,n,i){var r=e.call(this,new gr)||this;r._chartsViews=[],r._chartsMap={},r._componentsViews=[],r._componentsMap={},r._pendingActions=[],i=i||{},nA(n)&&(n=mp[n]),r._dom=t,i.ssr&&(b=function(e){var t=lQ(e),n=t.dataIndex;if(null!=n){var i=n1();return i.set("series_index",t.seriesIndex),i.set("data_index",n),t.ssrType&&i.set("ssr_type",t.ssrType),i}});var o=r._zr=aw(t,{renderer:i.renderer||"canvas",devicePixelRatio:i.devicePixelRatio,width:i.width,height:i.height,ssr:i.ssr,useDirtyRect:nG(i.useDirtyRect,!1),useCoarsePointer:nG(i.useCo
422arsePointer,"auto"),pointerSize:i.pointerSize});r._ssr=i.ssr,r._throttledZrFlush=fz(nT(o.flush,o),17),(n=nc(n))&&cY(n,!0),r._theme=n,r._locale=function(e){if(!nA(e))return nh(nc(e),nc(uu.EN),!1);var t=uu[e.toUpperCase()]||{};return"ZH"===e||"EN"===e?nc(t):nh(nc(t),nc(uu.EN),!1)}(i.locale||uh),r._coordSysMgr=new cI;var a=r._api=W(r);function s(e,t){return e.__prio-t.__prio}return rg(mh,s),rg(mu,s),r._scheduler=new fY(r,a,mu,mh),r._messageCenter=new mn,r._initEvents(),r.resize=nT(r.resize,r),o.animation.on("frame",r._onframe,r),z(o,r),j(o,r),nZ(r),r}return(0,tQ.__extends)(t,e),t.prototype._onframe=function(){if(!this._disposed){q(this);var e=this._scheduler;if(this[g4]){var t=this[g4].silent;this[g5]=!0;try{I(this),E.update.call(this,null,this[g4].updateParams)}catch(e){throw this[g5]=!1,this[g4]=null,e}this._zr.flush(),this[g5]=!1,this[g4]=null,N.call(this,t),B.call(this,t)}else if(e.unfinished){var n=1,i=this._model,r=this._api;e.unfinished=!1;do{var o=+new Date;e.performSeriesTasks(i),e.performDataProcessorTasks(i),F(this,i),e.performVisualTasks(i),G(this,this._model,r,"remain",{}),n-=new Date-o}while(n>0&&e.unfinished)e.unfinished||this._zr.flush()}}},t.prototype.getDom=function(){return this._dom},t.prototype.getId=function(){return this.id},t.prototype.getZr=function(){return this._zr},t.prototype.isSSR=function(){return this._ssr},t.prototype.setOption=function(e,t,n){if(!this[g5]){if(this._disposed)return void ms(this.id);if(nL(t)&&(n=t.lazyUpdate,i=t.silent,r=t.replaceMerge,o=t.transition,t=t.notMerge),this[g5]=!0,!this._model||t){var i,r,o,a=new cP(this._api),s=this._theme,l=this._model=new cS;l.scheduler=this._scheduler,l.ssr=this._ssr,l.init(null,null,null,s,this._locale,a)}this._model.setOption(e,{replaceMerge:r},mc);var d={seriesTransition:o,optionChanged:!0};if(n)this[g4]={silent:i,updateParams:d},this[g5]=!1,this.getZr().wakeUp();else{try{I(this),E.update.call(this,null,d)}catch(e){throw this[g4]=null,this[g5]=!1,e}this._ssr||this._zr.flush(),this[g4]=null,this[g5]=!1,N.call(this,i),B.call(this,i)}}},t.prototype.setTheme=function(){cx("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},t.prototype.getModel=function(){return this._model},t.prototype.getOption=function(){return this._model&&this._model.getOption()},t.prototype.getWidth=function(){return this._zr.getWidth()},t.prototype.getHeight=function(){return this._zr.getHeight()},t.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||t1.hasGlobalWindow&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(e){return this.renderToCanvas(e)},t.prototype.renderToCanvas=function(e){return e=e||{},this._zr.painter.getRenderedCanvas({backgroundColor:e.backgroundColor||this._model.get("backgroundColor"),pixelRatio:e.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(e){return e=e||{},this._zr.painter.renderToString({useViewBox:e.useViewBox})},t.prototype.getSvgDataURL=function(){if(t1.svgSupported){var e=this._zr;return nw(e.storage.getDisplayList(),function(e){e.stopAnimation(null,!0)}),e.painter.toDataURL()}},t.prototype.getDataURL=function(e){if(this._disposed)return void ms(this.id);var t=(e=e||{}).excludeComponents,n=this._model,i=[],r=this;nw(t,function(e){n.eachComponent({mainType:e},function(e){var t=r._componentsMap[e.__viewId];t.group.ignore||(i.push(t),t.group.ignore=!0)})});var o="svg"===this._zr.painter.getType()?this.getSvgDataURL():this.renderToCanvas(e).toDataURL("image/"+(e&&e.type||"png"));return nw(i,function(e){e.group.ignore=!1}),o},t.prototype.getConnectedDataURL=function(e){if(this._disposed)return void ms(this.id);var t="svg"===e.type,n=this.group,i=Math.min,r=Math.max,o=1/0;if(!mm[n])return this.getDataURL(e);var a=o,s=o,l=-o,d=-o,u=[],c=e&&e.pixelRatio||this.getDevicePixelRatio();nw(mg,function(o,c){if(o.group===n){var h=t?o.getZr().painter.getSvgDom().innerHTML:o.renderToCanvas(nc(e)),p=o.getDom().getBoundingClientRect();a=i(p.left,a),s=i(p.top,s),l=r(p.right,l),d=r(p.bottom,d),u.push({dom:h,left:p.left,top:p.top})}}),a*=c,s*=c,l*=c,d*=c;var h=l-a,p=d-s,f=t4.createCanvas(),g=aw(f,{renderer:t?"svg":"canvas"});if(g.resize({width:h,height:p}
422),!t)return e.connectedBackgroundColor&&g.add(new lN({shape:{x:0,y:0,width:h,height:p},style:{fill:e.connectedBackgroundColor}})),nw(u,function(e){var t=new lI({style:{x:e.left*c-a,y:e.top*c-s,image:e.dom}});g.add(t)}),g.refreshImmediately(),f.toDataURL("image/"+(e&&e.type||"png"));var m="";return nw(u,function(e){var t=e.left-a,n=e.top-s;m+='<g transform="translate('+t+","+n+')">'+e.dom+"</g>"}),g.painter.getSvgRoot().innerHTML=m,e.connectedBackgroundColor&&g.painter.setBackgroundColor(e.connectedBackgroundColor),g.refreshImmediately(),g.painter.toDataURL()},t.prototype.convertToPixel=function(e,t){return L(this,"convertToPixel",e,t)},t.prototype.convertFromPixel=function(e,t){return L(this,"convertFromPixel",e,t)},t.prototype.containPixel=function(e,t){var n;return this._disposed?void ms(this.id):(nw(st(this._model,e),function(e,i){i.indexOf("Models")>=0&&nw(e,function(e){var r=e.coordinateSystem;if(r&&r.containPoint)n=n||!!r.containPoint(t);else if("seriesModels"===i){var o=this._chartsMap[e.__viewId];o&&o.containPoint&&(n=n||o.containPoint(t,e))}},this)},this),!!n)},t.prototype.getVisual=function(e,t){var n=st(this._model,e,{defaultMainType:"series"}),i=n.seriesModel.getData(),r=n.hasOwnProperty("dataIndexInside")?n.dataIndexInside:n.hasOwnProperty("dataIndex")?i.indexOfRawIndex(n.dataIndex):null;return null!=r?gs(i,r,t):gl(i,t)},t.prototype.getViewOfComponentModel=function(e){return this._componentsMap[e.__viewId]},t.prototype.getViewOfSeriesModel=function(e){return this._chartsMap[e.__viewId]},t.prototype._initEvents=function(){var e,t,n,i=this;nw(ma,function(e){var t=function(t){var n,r=i.getModel(),o=t.target;if("globalout"===e?n={}:o&&gh(o,function(e){var t=lQ(e);if(t&&null!=t.dataIndex){var i=t.dataModel||r.getSeriesByIndex(t.seriesIndex);return n=i&&i.getDataParams(t.dataIndex,t.dataType,o)||{},!0}if(t.eventData)return n=nf({},t.eventData),!0},!0),n){var a=n.componentType,s=n.componentIndex;("markLine"===a||"markPoint"===a||"markArea"===a)&&(a="series",s=n.seriesIndex);var l=a&&null!=s&&r.getComponent(a,s),d=l&&i["series"===l.mainType?"_chartsMap":"_componentsMap"][l.__viewId];n.event=t,n.type=e,i._$eventProcessor.eventInfo={targetEl:o,packedEvent:n,model:l,view:d},i.trigger(e,n)}};t.zrEventfulCallAtLast=!0,i._zr.on(e,t,i)}),nw(md,function(e,t){i._messageCenter.on(t,function(e){this.trigger(t,e)},i)}),nw(["selectchanged"],function(e){i._messageCenter.on(e,function(t){this.trigger(e,t)},i)}),e=this._messageCenter,t=this,n=this._api,e.on("selectchanged",function(e){var i=n.getModel();e.isFromClick?(gc("map","selectchanged",t,i,e),gc("pie","selectchanged",t,i,e)):"select"===e.fromAction?(gc("map","selected",t,i,e),gc("pie","selected",t,i,e)):"unselect"===e.fromAction&&(gc("map","unselected",t,i,e),gc("pie","unselected",t,i,e))})},t.prototype.isDisposed=function(){return this._disposed},t.prototype.clear=function(){this._disposed?ms(this.id):this.setOption({series:[]},!0)},t.prototype.dispose=function(){if(this._disposed)return void ms(this.id);this._disposed=!0,this.getDom()&&sa(this.getDom(),mb,"");var e=this._api,t=this._model;nw(this._componentsViews,function(n){n.dispose(t,e)}),nw(this._chartsViews,function(n){n.dispose(t,e)}),this._zr.dispose(),this._dom=this._model=this._chartsMap=this._componentsMap=this._chartsViews=this._componentsViews=this._scheduler=this._api=this._zr=this._throttledZrFlush=this._theme=this._coordSysMgr=this._messageCenter=null,delete mg[this.id]},t.prototype.resize=function(e){if(!this[g5]){if(this._disposed)return void ms(this.id);this._zr.resize(e);var t=this._model;if(this._loadingFX&&this._loadingFX.resize(),t){var n=t.resetOption("media"),i=e&&e.silent;this[g4]&&(null==i&&(i=this[g4].silent),n=!0,this[g4]=null),this[g5]=!0;try{n&&I(this),E.update.call(this,{type:"resize",animation:nf({duration:0},e&&e.animation)})}catch(e){throw this[g5]=!1,e}this[g5]=!1,N.call(this,i),B.call(this,i)}}},t.prototype.showLoading=function(e,t){if(this._disposed)return void ms(this.id);if(nL(e)&&(t=e,e=""),e=e||"default",this.hideLoading(),mf[e]){var n=mf[e](this._api,t),i=this._zr;this._loadingFX=n,i.add(n)}},t.prototype.hideLoading=function(){this._disposed?ms(this.id):(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},t.prototype.makeActionFromEvent=function(e){var t=nf({},e);return t.type=md[e.type],t},t.prototype.dispatchAction=function(e,t){if(this._disposed)return void ms(this.id);if((nL(t)||(t={silent:!!t}),ml[e.type])&&this._model){if(this[g5])return void this._pendingActions.push(e);var n=t.silent;O.call(this,e,n);var i=t.flush;i?this._zr.flush():!1!==i&&t1.browser.weChat&&this._throttledZrFlush(),N.call(this,n),B.call(this,n)}},t.prototype.updateLabelLayout=function(){gQ.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(e){if(this._disposed)return void ms(this.id);var t=e.seriesIndex;this.getModel().getSeriesByIndex(t).appendData(e),this._scheduler.unfinished=!0,this.getZr().wakeUp()}
422,t.internalField=function(){function e(e){e.clearColorPalette(),e.eachSeries(function(e){e.clearColorPalette()})}function t(e){for(var t=[],n=e.currentStates,i=0;i<n.length;i++){var r=n[i];"emphasis"!==r&&"blur"!==r&&"select"!==r&&t.push(r)}e.selected&&e.states.select&&t.push("select"),2===e.hoverState&&e.states.emphasis?t.push("emphasis"):1===e.hoverState&&e.states.blur&&t.push("blur"),e.useStates(t)}function n(e,t){if(!e.preventAutoZ){var n=e.get("z")||0,i=e.get("zlevel")||0;t.eachRendered(function(e){return function e(t,n,i,r){var o=t.getTextContent(),a=t.getTextGuideLine();if(t.isGroup)for(var s=t.childrenRef(),l=0;l<s.length;l++)r=Math.max(e(s[l],n,i,r),r);else t.z=n,t.zlevel=i,r=Math.max(t.z2,r);if(o&&(o.z=n,o.zlevel=i,isFinite(r)&&(o.z2=r+2)),a){var d=t.textGuideLineConfig;a.z=n,a.zlevel=i,isFinite(r)&&(a.z2=r+(d&&d.showAbove?1:-1))}return r}(e,n,i,-1/0),!0})}}function i(e,t){t.eachRendered(function(e){if(!dj(e)){var t=e.getTextContent(),n=e.getTextGuideLine();e.stateTransition&&(e.stateTransition=null),t&&t.stateTransition&&(t.stateTransition=null),n&&n.stateTransition&&(n.stateTransition=null),e.hasState()?(e.prevStates=e.currentStates,e.clearStates()):e.prevStates&&(e.prevStates=null)}})}function r(e,n){var i=e.getModel("stateAnimation"),r=e.isAnimationEnabled(),o=i.get("duration"),a=o>0?{duration:o,delay:i.get("delay"),easing:i.get("easing")}:null;n.eachRendered(function(e){if(e.states&&e.states.emphasis&&!dj(e)){if(e instanceof lk&&((n=l3(e)).normalFill=e.style.fill,n.normalStroke=e.style.stroke,n.selectFill=(i=e.states.select||{}).style&&i.style.fill||null,n.selectStroke=i.style&&i.style.stroke||null),e.__dirty){var n,i,o=e.prevStates;o&&e.useStates(o)}if(r){e.stateTransition=a;var s=e.getTextContent(),l=e.getTextGuideLine();s&&(s.stateTransition=a),l&&(l.stateTransition=a)}e.__dirty&&t(e)}})}I=function(e){var t=e._scheduler;t.restorePipelines(e._model),t.prepareStageTasks(),A(e,!0),A(e,!1),t.plan()},A=function(e,t){for(var n=e._model,i=e._scheduler,r=t?e._componentsViews:e._chartsViews,o=t?e._componentsMap:e._chartsMap,a=e._zr,s=e._api,l=0;l<r.length;l++)r[l].__alive=!1;function d(e){var l=e.__requireNewView;e.__requireNewView=!1;var d="_ec_"+e.id+"_"+e.type,u=!l&&o[d];if(!u){var c=sc(e.type);(u=new(t?h9.getClass(c.main,c.sub):fI.getClass(c.sub))).init(n,s),o[d]=u,r.push(u),a.add(u.group)}e.__viewId=u.__id=d,u.__alive=!0,u.__model=e,u.group.__ecComponentInfo={mainType:e.mainType,index:e.componentIndex},t||i.prepareView(u,e,n,s)}t?n.eachComponent(function(e,t){"series"!==e&&d(t)}):n.eachSeries(d);for(var l=0;l<r.length;){var u=r[l];u.__alive?l++:(t||u.renderTask.dispose(),a.remove(u.group),u.dispose(n,s),r.splice(l,1),o[u.__id]===u&&delete o[u.__id],u.__id=u.group.__ecComponentInfo=null)}},P=function(e,t,n,i,r){var o,a=e._model;if(a.setUpdatePayload(n),!i)return void nw([].concat(e._componentsViews).concat(e._chartsViews),u);var s={};s[i+"Id"]=n[i+"Id"],s[i+"Index"]=n[i+"Index"],s[i+"Name"]=n[i+"Name"];var l={mainType:i,query:s};r&&(l.subType=r);var d=n.excludeSeriesId;function u(i){i&&i.__alive&&i[t]&&i[t](i.__model,a,e._api,n)}null!=d&&(o=n1(),nw(aJ(d),function(e){var t=a4(e,null);null!=t&&o.set(t,!0)})),a&&a.eachComponent(l,function(t){if(!(o&&null!=o.get(t.id))){if(dL(n))if(t instanceof h1)n.type!==l8||n.notBlur||t.get(["emphasis","disabled"])||function(e,t,n){var i=e.seriesIndex,r=e.getData(t.dataType);if(r){var o=a7(r,t);o=(nR(o)?o[0]:o)||0;var a=r.getItemGraphicEl(o);if(!a)for(var s=r.count(),l=0;!a&&l<s;)a=r.getItemGraphicEl(l++);if(a){var d=lQ(a);dw(i,d.focus,d.blurScope,n)}else{var u=e.get(["emphasis","focus"]),c=e.get(["emphasis","blurScope"]);null!=u&&dw(i,u,c,n)}}}(t,n,e._api);else{var i=dS(t.mainType,t.componentIndex,n.name,e._api),r=i.focusSelf,a=i.dispatchers;n.type===l8&&r&&!n.notBlur&&dC(t.mainType,t.componentIndex,e._api),a&&nw(a,function(e){n.type===l8?dv(e):dy(e)})}else if(dE(n)&&t instanceof h1){if(e._api,dE(n)){var s=n.dataType,l=a7(t.getData(s),n);nR(l)||(l=[l]),t[n.type===dt?"toggleSelect":n.type===l9?"select":"unselect"](l,s)}d_(t),U(e)}}},e),a&&a.eachComponent(l,function(t){o&&null!=o.get(t.id)||u(e["series"===i?"_chartsMap":"_componentsMap"][t.__viewId])},e)},E={prepareAndUpdate:function(e){I(this),E.update.call(this,e,{optionChanged:null!=e.newOption})},update:function(t,n){var i=this._model,r=this._api,o=this._zr,a=this._coordSysMgr,s=this._scheduler;if(i){i.setUpdatePayload(t),s.restoreData(i,t),s.performSeriesTasks(i),a.create(i,r),s.performDataProcessorTasks(i,t),F(this,i),a.update(i,r),e(i),s.performVisualTasks(i,t),V(this,i,r,t,n
422);var l=i.get("backgroundColor")||"transparent",d=i.get("darkMode");o.setBackgroundColor(l),null!=d&&"auto"!==d&&o.setDarkMode(d),gQ.trigger("afterupdate",i,r)}},updateTransform:function(t){var n=this,i=this._model,r=this._api;if(i){i.setUpdatePayload(t);var o=[];i.eachComponent(function(e,a){if("series"!==e){var s=n.getViewOfComponentModel(a);if(s&&s.__alive)if(s.updateTransform){var l=s.updateTransform(a,i,r,t);l&&l.update&&o.push(s)}else o.push(s)}});var a=n1();i.eachSeries(function(e){var o=n._chartsMap[e.__viewId];if(o.updateTransform){var s=o.updateTransform(e,i,r,t);s&&s.update&&a.set(e.uid,1)}else a.set(e.uid,1)}),e(i),this._scheduler.performVisualTasks(i,t,{setDirty:!0,dirtyMap:a}),G(this,i,r,t,{},a),gQ.trigger("afterupdate",i,r)}},updateView:function(t){var n=this._model;n&&(n.setUpdatePayload(t),fI.markUpdateMethod(t,"updateView"),e(n),this._scheduler.performVisualTasks(n,t,{setDirty:!0}),V(this,n,this._api,t,{}),gQ.trigger("afterupdate",n,this._api))},updateVisual:function(t){var n=this,i=this._model;i&&(i.setUpdatePayload(t),i.eachSeries(function(e){e.getData().clearAllVisual()}),fI.markUpdateMethod(t,"updateVisual"),e(i),this._scheduler.performVisualTasks(i,t,{visualType:"visual",setDirty:!0}),i.eachComponent(function(e,r){if("series"!==e){var o=n.getViewOfComponentModel(r);o&&o.__alive&&o.updateVisual(r,i,n._api,t)}}),i.eachSeries(function(e){n._chartsMap[e.__viewId].updateVisual(e,i,n._api,t)}),gQ.trigger("afterupdate",i,this._api))},updateLayout:function(e){E.update.call(this,e)}},L=function(e,t,n,i){if(e._disposed)return void ms(e.id);for(var r,o=e._model,a=e._coordSysMgr.getCoordinateSystems(),s=st(o,n),l=0;l<a.length;l++){var d=a[l];if(d[t]&&null!=(r=d[t](o,s,i)))return r}},F=function(e,t){var n=e._chartsMap,i=e._scheduler;t.eachSeries(function(e){i.updateStreamModes(e,n[e.__viewId])})},O=function(e,t){var n,i=this,r=this.getModel(),o=e.type,a=e.escapeConnect,s=ml[o],l=s.actionInfo,d=(l.update||"update").split(":"),u=d.pop(),c=null!=d[0]&&sc(d[0]);this[g5]=!0;var h=[e],p=!1;e.batch&&(p=!0,h=nC(e.batch,function(t){return(t=ng(nf({},t),e)).batch=null,t}));var f=[],g=dE(e),m=dL(e);if(m&&dx(this._api),nw(h,function(t){if((n=(n=s.action(t,i._model,i._api))||nf({},t)).type=l.event||n.type,f.push(n),m){var r=sn(e),o=r.queryOptionMap;P(i,u,t,r.mainTypeSpecified?o.keys()[0]:"series"),U(i)}else g?(P(i,u,t,"series"),U(i)):c&&P(i,u,t,c.main,c.sub)}),"none"!==u&&!m&&!g&&!c)try{this[g4]?(I(this),E.update.call(this,e),this[g4]=null):E[u].call(this,e)}catch(e){throw this[g5]=!1,e}if(n=p?{type:l.event||o,escapeConnect:a,batch:f}:f[0],this[g5]=!1,!t){var v=this._messageCenter;if(v.trigger(n.type,n),g){var y,b={type:"selectchanged",escapeConnect:a,selected:(y=[],r.eachSeries(function(e){nw(e.getAllData(),function(t){t.data;var n=t.type,i=e.getSelectedDataIndices();if(i.length>0){var r={dataIndex:i,seriesIndex:e.seriesIndex};null!=n&&(r.dataType=n),y.push(r)}})}),y),isFromClick:e.isFromClick||!1,fromAction:e.type,fromActionPayload:e};v.trigger(b.type,b)}}},N=function(e){for(var t=this._pendingActions;t.length;){var n=t.shift();O.call(this,n,e)}},B=function(e){e||this.trigger("updated")},z=function(e,t){e.on("rendered",function(n){t.trigger("rendered",n),!e.animation.isFinished()||t[g4]||t._scheduler.unfinished||t._pendingActions.length||t.trigger("finished")})},j=function(e,t){e.on("mouseover",function(e){var n,i,r,o,a,s=gh(e.target,dP);s&&(n=t._api,o=(r=dS((i=lQ(s)).componentMainType,i.componentIndex,i.componentHighDownName,n)).dispatchers,a=r.focusSelf,o?(a&&dC(i.componentMainType,i.componentIndex,n),nw(o,function(t){return dg(t,e)})):(dw(i.seriesIndex,i.focus,i.blurScope,n),"self"===i.focus&&dC(i.componentMainType,i.componentIndex,n),dg(s,e)),U(t))}).on("mouseout",function(e){var n,i,r,o=gh(e.target,dP);o&&(dx(n=t._api),(r=dS((i=lQ(o)).componentMainType,i.componentIndex,i.componentHighDownName,n).dispatchers)?nw(r,function(t){return dm(t,e)}):dm(o,e),U(t))}).on("click",function(e){var n=gh(e.target,function(e){return null!=lQ(e).dataIndex},!0);if(n){var i=n.selected?"unselect":"select",r=lQ(n);t._api.dispatchAction({type:i,dataType:r.dataType,dataIndexInside:r.dataIndex,seriesIndex:r.seriesIndex,isFromClick:!0})}})},V=function(e,t,n,i,r){!function(e){var t=[],n=[],i=!1;if(e.eachComponent(function(e,r){var o=r.get("zlevel")||0,a=r.get("z")||
4220,s=r.getZLevelKey();i=i||!!s,("series"===e?n:t).push({zlevel:o,z:a,idx:r.componentIndex,type:e,key:s})}),i){var r,o,a=t.concat(n);rg(a,function(e,t){return e.zlevel===t.zlevel?e.z-t.z:e.zlevel-t.zlevel}),nw(a,function(t){var n=e.getComponent(t.type,t.idx),i=t.zlevel,a=t.key;null!=r&&(i=Math.max(r,i)),a?(i===r&&a!==o&&i++,o=a):o&&(i===r&&i++,o=""),r=i,n.setZLevel(i)})}}(t),H(e,t,n,i,r),nw(e._chartsViews,function(e){e.__alive=!1}),G(e,t,n,i,r),nw(e._chartsViews,function(e){e.__alive||e.remove(t,n)})},H=function(e,t,o,a,s,l){nw(l||e._componentsViews,function(e){var s=e.__model;i(s,e),e.render(s,t,o,a),n(s,e),r(s,e)})},G=function(e,t,o,a,s,l){var d,u,c,h,p=e._scheduler;s=nf(s||{},{updatedSeries:t.getSeries()}),gQ.trigger("series:beforeupdate",t,o,s);var f=!1;t.eachSeries(function(t){var n,r,o,s=e._chartsMap[t.__viewId];s.__alive=!0;var d=s.renderTask;p.updatePayload(d,a),i(t,s),l&&l.get(t.uid)&&d.dirty(),d.perform(p.getPerformArgs(d))&&(f=!0),s.group.silent=!!t.get("silent"),n=t,r=s,o=n.get("blendMode")||null,r.eachRendered(function(e){e.isGroup||(e.style.blend=o)}),d_(t)}),p.unfinished=f||p.unfinished,gQ.trigger("series:layoutlabels",t,o,s),gQ.trigger("series:transition",t,o,s),t.eachSeries(function(t){var i=e._chartsMap[t.__viewId];n(t,i),r(t,i)}),d=e,u=t,c=d._zr.storage,h=0,c.traverse(function(e){!e.isGroup&&h++}),!(h>u.get("hoverLayerThreshold"))||t1.node||t1.worker||u.eachSeries(function(e){if(!e.preventUsingHoverLayer){var t=d._chartsMap[e.__viewId];t.__alive&&t.eachRendered(function(e){e.states.emphasis&&(e.states.emphasis.hoverLayer=!0)})}}),gQ.trigger("series:afterupdate",t,o,s)},U=function(e){e[g6]=!0,e.getZr().wakeUp()},q=function(e){e[g6]&&(e.getZr().storage.traverse(function(e){dj(e)||t(e)}),e[g6]=!1)},W=function(e){return new(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return(0,tQ.__extends)(n,t),n.prototype.getCoordinateSystems=function(){return e._coordSysMgr.getCoordinateSystems()},n.prototype.getComponentByElement=function(t){for(;t;){var n=t.__ecComponentInfo;if(null!=n)return e._model.getComponent(n.mainType,n.index);t=t.parent}},n.prototype.enterEmphasis=function(t,n){dv(t,n),U(e)},n.prototype.leaveEmphasis=function(t,n){dy(t,n),U(e)},n.prototype.enterBlur=function(t){dc(t,ds),U(e)},n.prototype.leaveBlur=function(t){dc(t,dl),U(e)},n.prototype.enterSelect=function(t){dc(t,dd),U(e)},n.prototype.leaveSelect=function(t){dc(t,du),U(e)},n.prototype.getModel=function(){return e.getModel()},n.prototype.getViewOfComponentModel=function(t){return e.getViewOfComponentModel(t)},n.prototype.getViewOfSeriesModel=function(t){return e.getViewOfSeriesModel(t)},n}(cD))(e)},$=function(e){function t(e,t){for(var n=0;n<e.length;n++)e[n][g7]=t}nw(md,function(n,i){e._messageCenter.on(i,function(n){if(mm[e.group]&&0!==e[g7]&&(!n||!n.escapeConnect)){var i=e.makeActionFromEvent(n),r=[];nw(mg,function(t){t!==e&&t.group===e.group&&r.push(t)}),t(r,0),nw(r,function(e){1!==e[g7]&&e.dispatchAction(i)}),t(r,2)}})})}}(),t}(iS),mo=mr.prototype;mo.on=g9("on"),mo.off=g9("off"),mo.one=function(e,t,n){var i=this;cx("ECharts#one is deprecated."),this.on.call(this,e,function n(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];t&&t.apply&&t.apply(this,r),i.off(e,n)},n)};var ma=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];function ms(e){}var ml={},md={},mu=[],mc=[],mh=[],mp={},mf={},mg={},mm={},mv=new Date-0,my=new Date-0,mb="_echarts_instance_";function mx(e,t,n){var i=!(n&&n.ssr);if(i){var r=m_(e);if(r)return r}var o=new mr(e,t,n);return o.id="ec_"+mv++,mg[o.id]=o,i&&sa(e,mb,o.id),$(o),gQ.trigger("afterinit",o),o}function mw(e){if(nR(e)){var t=e;e=null,nw(t,function(t){null!=t.group&&(e=t.group)}),e=e||"g_"+my++,nw(t,function(t){t.group=e})}return mm[e]=!0,e}function mC(e){mm[e]=!1}function mS(e){nA(e)?e=mg[e]:e instanceof mr||(e=m_(e)),e instanceof mr&&!e.isDisposed()&&e.dispose()}function m_(e){return mg[e.getAttribute?e.getAttribute(mb):e[mb]]}function mk(e){return mg[e]}function mM(e,t){mp[e]=t}function mT(e){0>nv(mc,e)&&mc.push(e)}function mD(e,t){mB(mu,e,t,2e3)}function mR(e){mA("afterinit",e)}function mI(e){mA("afterupdate",e)}function mA(e,t){gQ.on(e,t)}function mP(e,t,n){nI(t)&&(n=t,t="");var i=nL(e)?e.type:[e,e={event:t}][0];e.event=(e.event||i).toLowerCase(),md[t=e.event]||(nq(g8.test(i)&&g8.test(t)),ml[i]||(ml[i]={action:n,actionInfo:e}),md[t]=i)}function mE(e,t){cI.register(e,t)}function mL(e){var t=cI.get(e);if(t)return t.getDimensionsInfo?t.getDimensionsInfo():t.dimensions.slice()}function mF(e,t){mB(mh,e,t,1e3,"layout")}function mO(e,t){mB(mh,e,t,3e3,"visual")}var mN=[];function mB(e,t,n,i,r){if((nI(t)||nL(t))&&(n=t,t=i),!(nv(mN,n)>=0)){mN.push(n);var o=fY.wrapStageHandler(n,r);o.__prio=t,o.__raw=n,e.push(o)}}function mz(e,t){mf[e]=t}function mj(e){t6({createCanvas:e})}function mV(e,t,n){var i=g0.registerMap;
422i&&i(e,t,n)}function mH(e){var t=g0.getMap;return t&&t(e)}var mG=function(e){var t=(e=nc(e)).type;t||cw("");var n=t.split(":");2!==n.length&&cw("");var i=!1;"echarts"===n[0]&&(t=n[1],i=!0),e.__isBuiltIn=i,hw.set(t,e)};mO(2e3,{createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData(),i=e.visualStyleAccessPath||"itemStyle",r=e.getModel(i),o=f$(e,i)(r),a=r.getShallow("decal");a&&(n.setVisual("decal",a),a.dirty=!0);var s=fU(e,i),l=o[s],d=nI(l)?l:null,u="auto"===o.fill||"auto"===o.stroke;if(!o[s]||d||u){var c=e.getColorFromPalette(e.name,null,t.getSeriesCount());o[s]||(o[s]=c,n.setVisual("colorFromPalette",!0)),o.fill="auto"===o.fill||nI(o.fill)?c:o.fill,o.stroke="auto"===o.stroke||nI(o.stroke)?c:o.stroke}if(n.setVisual("style",o),n.setVisual("drawType",s),!t.isSeriesFiltered(e)&&d)return n.setVisual("colorFromPalette",!1),{dataEach:function(t,n){var i=e.getDataParams(n),r=nf({},o);r[s]=d(i),t.setItemVisual(n,"style",r)}}}}),mO(4500,{createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){if(!(e.ignoreStyleOnData||t.isSeriesFiltered(e))){var n=e.getData(),i=e.visualStyleAccessPath||"itemStyle",r=f$(e,i),o=n.getVisual("drawType");return{dataEach:n.hasItemOption?function(e,t){var n=e.getRawDataItem(t);if(n&&n[i]){fq.option=n[i];var a=r(fq);nf(e.ensureUniqueItemVisual(t,"style"),a),fq.option.decal&&(e.setItemVisual(t,"decal",fq.option.decal),fq.option.decal.dirty=!0),o in a&&e.setItemVisual(t,"colorFromPalette",!1)}}:null}}}}),mO(4500,{performRawSeries:!0,overallReset:function(e){var t=n1();e.eachSeries(function(e){var n=e.getColorBy();if(!e.isColorBySeries()){var i=e.type+"-"+n,r=t.get(i);r||(r={},t.set(i,r)),fH(e).scope=r}}),e.eachSeries(function(t){if(!(t.isColorBySeries()||e.isSeriesFiltered(t))){var n=t.getRawData(),i={},r=t.getData(),o=fH(t).scope,a=t.visualStyleAccessPath||"itemStyle",s=fU(t,a);r.each(function(e){i[r.getRawIndex(e)]=e}),n.each(function(e){var a=i[e];if(r.getItemVisual(a,"colorFromPalette")){var l=r.ensureUniqueItemVisual(a,"style"),d=n.getName(e)||e+"",u=n.count();l[s]=t.getColorFromPalette(d,o,u)}})}})}}),mO(2e3,{createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData();if(e.legendIcon&&n.setVisual("legendIcon",e.legendIcon),e.hasSymbolVisual){for(var i={},r={},o=!1,a=0;a<go.length;a++){var s=go[a],l=e.get(s);nI(l)?(o=!0,r[s]=l):i[s]=l}if(i.symbol=i.symbol||e.defaultSymbol,n.setVisual(nf({legendIcon:e.legendIcon||i.symbol,symbolKeepAspect:e.get("symbolKeepAspect")},i)),!t.isSeriesFiltered(e)){var d=nM(r);return{dataEach:o?function(t,n){for(var i=e.getRawValue(n),o=e.getDataParams(n),a=0;a<d.length;a++){var s=d[a];t.setItemVisual(n,s,r[s](i,o))}}:null}}}}}),mO(4500,{createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){if(e.hasSymbolVisual&&!t.isSeriesFiltered(e))return{dataEach:e.getData().hasItemOption?function(e,t){for(var n=e.getItemModel(t),i=0;i<ga.length;i++){var r=ga[i],o=n.getShallow(r,!0);null!=o&&e.setItemVisual(t,r,o)}}:null}}}),mO(7e3,function(e,t){e.eachRawSeries(function(n){if(!e.isSeriesFiltered(n)){var i=n.getData();i.hasItemVisual()&&i.each(function(e){var n=i.getItemVisual(e,"decal");n&&(i.ensureUniqueItemVisual(e,"style").decal=gX(n,t))});var r=i.getVisual("decal");r&&(i.getVisual("style").decal=gX(r,t))}})}),mT(cY),mD(900,function(e){var t=n1();e.eachSeries(function(e){var n=e.get("stack");if(n){var i=t.get(n)||t.set(n,[]),r=e.getData(),o={stackResultDimension:r.getCalculationInfo("stackResultDimension"),stackedOverDimension:r.getCalculationInfo("stackedOverDimension"),stackedDimension:r.getCalculationInfo("stackedDimension"),stackedByDimension:r.getCalculationInfo("stackedByDimension"),isStackedByIndex:r.getCalculationInfo("isStackedByIndex"),data:r,seriesModel:e};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;i.length&&r.setCalculationInfo("stackedOnSeries",i[i.length-1].seriesModel),i.push(o)}}),t.each(cZ)}),mf.default=function(e,t){ng(t=t||{},{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",
422spinnerRadius:10,lineWidth:5,zlevel:0});var n,i=new av,r=new lN({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});i.add(r);var o=new lj({style:{text:t.text,fill:t.textColor,fontSize:t.fontSize,fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:t.fontFamily},zlevel:t.zlevel,z:10001}),a=new lN({style:{fill:"none"},textContent:o,textConfig:{position:"right",distance:10},zlevel:t.zlevel,z:10001});return i.add(a),t.showSpinner&&((n=new pJ({shape:{startAngle:-fK/2,endAngle:-fK/2+.1,r:t.spinnerRadius},style:{stroke:t.color,lineCap:"round",lineWidth:t.lineWidth},zlevel:t.zlevel,z:10001})).animateShape(!0).when(1e3,{endAngle:3*fK/2}).start("circularInOut"),n.animateShape(!0).when(1e3,{startAngle:3*fK/2}).delay(300).start("circularInOut"),i.add(n)),i.resize=function(){var i=o.getBoundingRect().width,s=t.showSpinner?t.spinnerRadius:0,l=(e.getWidth()-2*s-(t.showSpinner&&i?10:0)-i)/2-(t.showSpinner&&i?0:5+i/2)+(t.showSpinner?0:i/2)+(i?0:s),d=e.getHeight()/2;t.showSpinner&&n.setShape({cx:l,cy:d}),a.setShape({x:l-s,y:d-s,width:2*s,height:2*s}),r.setShape({x:0,y:0,width:e.getWidth(),height:e.getHeight()})},i.resize(),i},mP({type:l8,event:l8,update:l8},n6),mP({type:l7,event:l7,update:l7},n6),mP({type:l9,event:l9,update:l9},n6),mP({type:de,event:de,update:de},n6),mP({type:dt,event:dt,update:dt},n6),mp.light={color:f7,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],f7]},mp.dark=gi;var mW={};e.s(["PRIORITY",()=>g3,"connect",()=>mw,"dataTool",()=>mW,"dependencies",()=>g2,"disConnect",()=>mC,"disconnect",()=>mC,"dispose",()=>mS,"getCoordinateSystemDimensions",()=>mL,"getInstanceByDom",()=>m_,"getInstanceById",()=>mk,"getMap",()=>mH,"init",()=>mx,"registerAction",()=>mP,"registerCoordinateSystem",()=>mE,"registerLayout",()=>mF,"registerLoading",()=>mz,"registerMap",()=>mV,"registerPostInit",()=>mR,"registerPostUpdate",()=>mI,"registerPreprocessor",()=>mT,"registerProcessor",()=>mD,"registerTheme",()=>mM,"registerTransform",()=>mG,"registerUpdateLifecycle",()=>mA,"registerVisual",()=>mO,"setCanvasCreator",()=>mj,"version",()=>g1],49613);var m$=[],mU={registerPreprocessor:mT,registerProcessor:mD,registerPostInit:mR,registerPostUpdate:mI,registerUpdateLifecycle:mA,registerAction:mP,registerCoordinateSystem:mE,registerLayout:mF,registerVisual:mO,registerTransform:mG,registerLoading:mz,registerMap:mV,registerImpl:function(e,t){g0[e]=t},PRIORITY:g3,ComponentModel:u5,ComponentView:h9,SeriesModel:h1,ChartView:fI,registerComponentModel:function(e){u5.registerClass(e)},registerComponentView:function(e){h9.registerClass(e)},registerSeriesModel:function(e){h1.registerClass(e)},registerChartView:function(e){fI.registerClass(e)},registerSubTypeDefaulter:function(e,t){u5.registerSubTypeDefaulter(e,t)},registerPainter:function(e,t){ay[e]=t}};function mq(e){nR(e)?nw(e,function(e){mq(e)}):nv(m$,e)>=0||(m$.push(e),nI(e)&&(e={install:e}),e.install(mU))}var mK=Math.sin,mY=Math.cos,mZ=Math.PI,mX=2*Math.PI,mJ=180/mZ,mQ=function(){function e(){}return e.prototype.reset=function(e){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,e||4)},e.prototype.moveTo=function(e,t){this._add("M",e,t)},e.prototype.lineTo=function(e,t){this._add("L",e,t)},e.prototype.bezierCurveTo=function(e,t,n,i,r,o){this._add("C",e,t,n,i,r,o)},e.prototype.quadraticCurveTo=function(e,t,n,i){this._add("Q",e,t,n,i)},e.prototype.arc=function(e,t,n,i,r,o){this.ellipse(e,t,n,n,0,i,r,o)},e.prototype.ellipse=function(e,t,n,i,r,o,a,s){var l=a-o,d=!s,u=Math.abs(l),c=oc(u-mX)||(d?l>=mX:-l>=mX),h=l>0?l%mX:l%mX+mX,p=!1;p=!!c||!oc(u)&&h>=mZ==!!d;var f=e+n*mY(o),g=t+i*mK(o);this._start&&this._add("M",f,g);var m=Math.round(r*mJ);if(c){var v=1/this._p,y=(d?1:-1)*(mX-v);this._add("A",n,i,m,1,+d,e+n*mY(o+y),t+i*mK(o+y)),v>
422.01&&this._add("A",n,i,m,0,+d,f,g)}else{var b=e+n*mY(a),x=t+i*mK(a);this._add("A",n,i,m,+p,+d,b,x)}},e.prototype.rect=function(e,t,n,i){this._add("M",e,t),this._add("l",n,0),this._add("l",0,i),this._add("l",-n,0),this._add("Z")},e.prototype.closePath=function(){this._d.length>0&&this._add("Z")},e.prototype._add=function(e,t,n,i,r,o,a,s,l){for(var d=[],u=this._p,c=1;c<arguments.length;c++){var h=arguments[c];if(isNaN(h)){this._invalid=!0;return}d.push(Math.round(h*u)/u)}this._d.push(e+d.join(" ")),this._start="Z"===e},e.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(""),this._d=[]},e.prototype.getStr=function(){return this._str},e}(),m0="none",m1=Math.round,m2=["lineCap","miterLimit","lineJoin"],m3=nC(m2,function(e){return"stroke-"+e.toLowerCase()}),m5="http://www.w3.org/2000/svg",m4="http://www.w3.org/1999/xlink",m6="ecmeta_";function m8(e){return document.createElementNS(m5,e)}function m7(e,t,n,i,r){return{tag:e,attrs:n||{},children:i,text:r,key:t}}function m9(e,t){var n=(t=t||{}).newline?"\n":"";return function e(t){var i=t.children,r=t.tag,o=t.attrs,a=t.text;return function(e,t){var n=[];if(t)for(var i in t){var r=t[i],o=i;!1!==r&&(!0!==r&&null!=r&&(o+='="'+r+'"'),n.push(o))}return"<"+e+" "+n.join(" ")+">"}(r,o)+("style"!==r?iE(a):a||"")+(i?""+n+nC(i,function(t){return e(t)}).join(n)+n:"")+"</"+r+">"}(e)}function ve(e){return{zrId:e,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function vt(e,t,n,i){return m7("svg","root",{width:e,height:t,xmlns:m5,"xmlns:xlink":m4,version:"1.1",baseProfile:"full",viewBox:!!i&&"0 0 "+e+" "+t},n)}var vn=0,vi={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},vr="transform-origin",vo={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function va(e,t){var n=t.zrId+"-ani-"+t.cssAnimIdx++;return t.cssAnims[n]=e,n}function vs(e){return nA(e)?vi[e]?"cubic-bezier("+vi[e]+")":rH(e)?e:"":""}function vl(e,t,n,i){var r=e.animators,o=r.length,a=[];if(e instanceof pQ){var s=function(e,t,n){var i,r,o=e.shape.paths,a={};if(nw(o,function(e){var t=ve(n.zrId);t.animation=!0,vl(e,{},t,!0);var o=t.cssAnims,s=t.cssNodes,l=nM(o),d=l.length;if(d){var u=o[r=l[d-1]];for(var c in u){var h=u[c];a[c]=a[c]||{d:""},a[c].d+=h.d||""}for(var p in s){var f=s[p].animation;f.indexOf(r)>=0&&(i=f)}}}),i){t.d=!1;var s=va(a,n);return i.replace(r,s)}}(e,t,n);if(s)a.push(s);else if(!o)return}else if(!o)return;for(var l={},d=0;d<o;d++){var u=r[d],c=[u.getMaxTime()/1e3+"s"],h=vs(u.getClip().easing),p=u.getDelay();h?c.push(h):c.push("linear"),p&&c.push(p/1e3+"s"),u.getLoop()&&c.push("infinite");var f=c.join(" ");l[f]=l[f]||[f,[]],l[f][1].push(u)}for(var g in l){var s=function(r){var o,a,s=r[1],l=s.length,d={},u={},c={},h="animation-timing-function";function p(e,t,n){for(var i=e.getTracks(),r=e.getMaxTime(),o=0;o<i.length;o++){var a=i[o];if(a.needsAnimate()){var s=a.keyframes,l=a.propName;if(n&&(l=n(l)),l)for(var d=0;d<s.length;d++){var u=s[d],c=Math.round(u.time/r*100)+"%",p=vs(u.easing),f=u.rawValue;(nA(f)||nE(f))&&(t[c]=t[c]||{},t[c][l]=u.rawValue,p&&(t[c][h]=p))}}}}for(var f=0;f<l;f++){var g=s[f],m=g.targetName;m?"shape"===m&&p(g,u):i||p(g,d)}for(var v in d){var y={};o9(y,e),nf(y,d[v]);var b=oC(y),x=d[v][h];c[v]=b?{transform:b}:{},function(e,t){var n=t.originX,i=t.originY;(n||i)&&(e[vr]=n+"px "+i+"px")}(c[v],y),x&&(c[v][h]=x)}var w=!0;for(var v in u){c[v]=c[v]||{};var C=!o,x=u[v][h];C&&(o=new lu);var S=o.len();o.reset(),c[v].d=function(e,t,n){var i=nf({},e.shape);nf(i,t),e.buildPath(n,i);var r=new mQ;return r.reset(ow(e)),n.rebuildPath(r,1),r.generateStr(),r.getStr()}(e,u[v],o);var _=o.len();if(!C&&S!==_){w=!1;break}x&&(c[v][h]=x)}if(!w)for(var v in c)delete c[v].d;if(!i)for(var f=0;f<l;f++){var g=s[f],m=g.targetName;"style"===m&&p(g,c,function(e){return vo[e]})}for(var k=nM(c),M=!0,f=1;f<k.length;f++){var T=k[f-1],D=k[f];
422if(c[T][vr]!==c[D][vr]){M=!1;break}a=c[T][vr]}if(M&&a){for(var v in c)c[v][vr]&&delete c[v][vr];t[vr]=a}if(n_(k,function(e){return nM(c[e]).length>0}).length)return va(c,n)+" "+r[0]+" both"}(l[g]);s&&a.push(s)}if(a.length){var m=n.zrId+"-cls-"+vn++;n.cssNodes["."+m]={animation:a.join(",")},t.class=m}}function vd(e,t,n,i){var r=JSON.stringify(e),o=n.cssStyleCache[r];o||(o=n.zrId+"-cls-"+vn++,n.cssStyleCache[r]=o,n.cssNodes["."+o+(i?":hover":"")]=e),t.class=t.class?t.class+" "+o:o}var vu=Math.round;function vc(e){return e&&nI(e.toDataURL)}function vh(e,t,n,i){!function(e,t,n,i){var r,o,a=null==t.opacity?1:t.opacity;if(n instanceof lI)return e("opacity",a);if(null!=(r=t.fill)&&r!==m0){var s=ou(t.fill);e("fill",s.color);var l=null!=t.fillOpacity?t.fillOpacity*s.opacity*a:s.opacity*a;(i||l<1)&&e("fill-opacity",l)}else e("fill",m0);if(null!=(o=t.stroke)&&o!==m0){var d=ou(t.stroke);e("stroke",d.color);var u=t.strokeNoScale?n.getLineScale():1,c=u?(t.lineWidth||0)/u:0,h=null!=t.strokeOpacity?t.strokeOpacity*d.opacity*a:d.opacity*a,p=t.strokeFirst;if((i||1!==c)&&e("stroke-width",c),(i||p)&&e("paint-order",p?"stroke":"fill"),(i||h<1)&&e("stroke-opacity",h),t.lineDash){var f=gA(n),g=f[0],m=f[1];g&&(m=m1(m||0),e("stroke-dasharray",g.join(",")),(m||i)&&e("stroke-dashoffset",m))}else i&&e("stroke-dasharray",m0);for(var v=0;v<m2.length;v++){var y=m2[v];if(i||t[y]!==lC[y]){var b=t[y]||lC[y];b&&e(m3[v],b)}}}else i&&e("stroke",m0)}(function(r,o){var a="fill"===r||"stroke"===r;a&&ob(o)?vw(t,e,r,i):a&&om(o)?vC(n,e,r,i):e[r]=o,a&&i.ssr&&"none"===o&&(e["pointer-events"]="visible")},t,n,!1),function(e,t,n){var i=e.style;if(i&&(i.shadowBlur||i.shadowOffsetX||i.shadowOffsetY)){var r,o,a=(r=e.style,o=e.getGlobalScale(),[r.shadowColor,(r.shadowBlur||0).toFixed(2),(r.shadowOffsetX||0).toFixed(2),(r.shadowOffsetY||0).toFixed(2),o[0],o[1]].join(",")),s=n.shadowCache,l=s[a];if(!l){var d=e.getGlobalScale(),u=d[0],c=d[1];if(!u||!c)return;var h=i.shadowOffsetX||0,p=i.shadowOffsetY||0,f=i.shadowBlur,g=ou(i.shadowColor),m=g.opacity,v=g.color;l=n.zrId+"-s"+n.shadowIdx++,n.defs[l]=m7("filter",l,{id:l,x:"-100%",y:"-100%",width:"300%",height:"300%"},[m7("feDropShadow","",{dx:h/u,dy:p/c,stdDeviation:f/2/u+" "+f/2/c,"flood-color":v,"flood-opacity":m})]),s[a]=l}t.filter=ox(l)}}(n,e,i)}function vp(e,t){var n=aM(t);n&&(n.each(function(t,n){null!=t&&(e[(m6+n).toLowerCase()]=t+"")}),t.isSilent()&&(e[m6+"silent"]="true"))}function vf(e){return oc(e[0]-1)&&oc(e[1])&&oc(e[2])&&oc(e[3]-1)}function vg(e,t,n){if(t&&!(oc(t[4])&&oc(t[5])&&vf(t))){var i=n?10:1e4;e.transform=vf(t)?"translate("+vu(t[4]*i)/i+" "+vu(t[5]*i)/i+")":"matrix("+oh(t[0])+","+oh(t[1])+","+oh(t[2])+","+oh(t[3])+","+op(t[4])+","+op(t[5])+")"}}function vm(e,t,n){for(var i=e.points,r=[],o=0;o<i.length;o++)r.push(vu(i[o][0]*n)/n),r.push(vu(i[o][1]*n)/n);t.points=r.join(" ")}function vv(e){return!e.smooth}var vy={circle:[(m=nC(["cx","cy","r"],function(e){return"string"==typeof e?[e,e]:e}),function(e,t,n){for(var i=0;i<m.length;i++){var r=m[i],o=e[r[0]];null!=o&&(t[r[1]]=vu(o*n)/n)}})],polyline:[vm,vv],polygon:[vm,vv]};function vb(e,t){var n=e.style,i=e.shape,r=vy[e.type],o={},a=t.animation,s="path",l=e.style.strokePercent,d=t.compress&&ow(e)||4;if(!r||t.willUpdate||r[1]&&!r[1](i)||a&&function(e){for(var t=e.animators,n=0;n<t.length;n++)if("shape"===t[n].targetName)return!0;return!1}(e)||l<1){var u=!e.path||e.shapeChanged();e.path||e.createPathProxy();var c=e.path;u&&(c.beginPath(),e.buildPath(c,e.shape),e.pathUpdated());var h=c.getVersion(),p=e.__svgPathBuilder;e.__svgPathVersion===h&&p&&l===e.__svgPathStrokePercent||(p||(p=e.__svgPathBuilder=new mQ),p.reset(d),c.rebuildPath(p,l),p.generateStr(),e.__svgPathVersion=h,e.__svgPathStrokePercent=l),o.d=p.getStr()}else{s=e.type;var f=Math.pow(10,d);r[0](i,o,f)}return vg(o,e.transform),vh(o,n,e,t),vp(o,e),t.animation&&vl(e,o,t),t.emphasis&&function(e,t,n){if(!e.ignore)if(e.isSilent()){var i={"pointer-events":"none"};vd(i,t,n,!0)}else{var r=e.states.emphasis&&e.states.emphasis.style?e.states.emphasis.style:{},o=r.fill;if(!o){var a=e.style&&e.style.fill,s=e.states.select&&e.states.select.style&&e.states.select.style.fill,l=e.currentStates.indexOf("select")>=0&&s||a;l&&(o=oa(l))}var d=r.lineWidth;d&&(d/=!r.strokeNoScale&&e.transform?e.transform[0]:1);var i={cursor:"pointer"};o&&(i.fill=o),r.stroke&&(i.stroke=r.stroke),d&&(i["stroke-width"]=d),vd(i,t,n,!0)}}(e,o,t),m7(s,e.id+"",o)}function vx(e,t){return e instanceof lk?vb(e,t):e instanceof lI?function(e,t){var n,i=e.style,r=i.image;if(r&&!nA(r)&&((n=r)&&nA(n.src)?r=r.src:vc(r)&&(r=r.toDataURL())),r){var o=i.x||0,a=i.y||0,s={href:r,width:i.width,height:i.height};return o&&(s.x=o),a&&(s.y=a),vg(s,e.transform),vh(s,i,e,t),vp(s,e),t.animation&&vl(e,s,t),m7("image",e.id+"",s)}}(e,t):e instanceof lT?function(e,t){var n=e.style,i=n.text;
422if(null!=i&&(i+=""),!(!i||isNaN(n.x)||isNaN(n.y))){var r,o,a,s=n.font||t3,l=n.x||0,d=(r=n.y||0,o=aa(s),"top"===(a=n.textBaseline)?r+=o/2:"bottom"===a&&(r-=o/2),r),u={"dominant-baseline":"central","text-anchor":of[n.textAlign]||n.textAlign};if(lU(n)){var c="",h=n.fontStyle,p=lW(n.fontSize);if(!parseFloat(p))return;var f=n.fontFamily||t2,g=n.fontWeight;c+="font-size:"+p+";font-family:"+f+";",h&&"normal"!==h&&(c+="font-style:"+h+";"),g&&"normal"!==g&&(c+="font-weight:"+g+";"),u.style=c}else u.style="font: "+s;return i.match(/\s/)&&(u["xml:space"]="preserve"),l&&(u.x=l),d&&(u.y=d),vg(u,e.transform),vh(u,n,e,t),vp(u,e),t.animation&&vl(e,u,t),m7("text",e.id+"",u,void 0,i)}}(e,t):void 0}function vw(e,t,n,i){var r,o=e[n],a={gradientUnits:o.global?"userSpaceOnUse":"objectBoundingBox"};if(ov(o))r="linearGradient",a.x1=o.x,a.y1=o.y,a.x2=o.x2,a.y2=o.y2;else{if(!oy(o))return;r="radialGradient",a.cx=nG(o.x,.5),a.cy=nG(o.y,.5),a.r=nG(o.r,.5)}for(var s=o.colorStops,l=[],d=0,u=s.length;d<u;++d){var c=100*op(s[d].offset)+"%",h=ou(s[d].color),p=h.color,f=h.opacity,g={offset:c};g["stop-color"]=p,f<1&&(g["stop-opacity"]=f),l.push(m7("stop",d+"",g))}var m=m9(m7(r,"",a,l)),v=i.gradientCache,y=v[m];y||(y=i.zrId+"-g"+i.gradientIdx++,v[m]=y,a.id=y,i.defs[y]=m7(r,y,a,l)),t[n]=ox(y)}function vC(e,t,n,i){var r,o,a,s=e.style[n],l=e.getBoundingRect(),d={},u=s.repeat,c="no-repeat"===u,h="repeat-x"===u,p="repeat-y"===u;if(og(s)){var f=s.imageWidth,g=s.imageHeight,m=void 0,v=s.image;if(nA(v)?m=v:v&&nA(v.src)?m=v.src:vc(v)&&(m=v.toDataURL()),"u"<typeof Image){var y="Image width/height must been given explictly in svg-ssr renderer.";nq(f,y),nq(g,y)}else if(null==f||null==g){var b=function(e,t){if(e){var n=e.elm,i=f||t.width,r=g||t.height;"pattern"===e.tag&&(h?(r=1,i/=l.width):p&&(i=1,r/=l.height)),e.attrs.width=i,e.attrs.height=r,n&&(n.setAttribute("width",i),n.setAttribute("height",r))}},x=sC(m,null,e,function(e){c||b(C,e),b(r,e)});x&&x.width&&x.height&&(f=f||x.width,g=g||x.height)}r=m7("image","img",{href:m,width:f,height:g}),d.width=f,d.height=g}else s.svgElement&&(r=nc(s.svgElement),d.width=s.svgWidth,d.height=s.svgHeight);if(r){c?o=a=1:h?(a=1,o=d.width/l.width):p?(o=1,a=d.height/l.height):d.patternUnits="userSpaceOnUse",null==o||isNaN(o)||(d.width=o),null==a||isNaN(a)||(d.height=a);var w=oC(s);w&&(d.patternTransform=w);var C=m7("pattern","",d,[r]),S=m9(C),_=i.patternCache,k=_[S];k||(k=i.zrId+"-p"+i.patternIdx++,_[S]=k,d.id=k,C=i.defs[k]=m7("pattern",k,d,[r])),t[n]=ox(k)}}function vS(e){return document.createTextNode(e)}function v_(e,t,n){e.insertBefore(t,n)}function vk(e,t){e.removeChild(t)}function vM(e,t){e.appendChild(t)}function vT(e){return e.parentNode}function vD(e){return e.nextSibling}function vR(e,t){e.textContent=t}var vI=m7("","");function vA(e){return void 0===e}function vP(e){return void 0!==e}function vE(e,t){var n=e.key===t.key;return e.tag===t.tag&&n}function vL(e){var t,n=e.children,i=e.tag;if(vP(i)){var r=e.elm=m8(i);if(vN(vI,e),nR(n))for(t=0;t<n.length;++t){var o=n[t];null!=o&&vM(r,vL(o))}else vP(e.text)&&!nL(e.text)&&vM(r,vS(e.text))}else e.elm=vS(e.text);return e.elm}function vF(e,t,n,i,r){for(;i<=r;++i){var o=n[i];null!=o&&v_(e,vL(o),t)}}function vO(e,t,n,i){for(;n<=i;++n){var r=t[n];null!=r&&(vP(r.tag)?vk(vT(r.elm),r.elm):vk(e,r.elm))}}function vN(e,t){var n,i=t.elm,r=e&&e.attrs||{},o=t.attrs||{};if(r!==o){for(n in o){var a=o[n];r[n]!==a&&(!0===a?i.setAttribute(n,""):!1===a?i.removeAttribute(n):"style"===n?i.style.cssText=a:120!==n.charCodeAt(0)?i.setAttribute(n,a):"xmlns:xlink"===n||"xmlns"===n?i.setAttributeNS("http://www.w3.org/2000/xmlns/",n,a):58===n.charCodeAt(3)?i.setAttributeNS("http://www.w3.org/XML/1998/namespace",n,a):58===n.charCodeAt(5)?i.setAttributeNS(m4,n,a):i.setAttribute(n,a))}for(n in r)n in o||i.removeAttribute(n)}}var vB=0,vz=function(){function e(e,t,n){if(this.type="svg",this.refreshHover=vj("refreshHover"),this.configLayer=vj("configLayer"),this.storage=t,this._opts=n=nf({},n),this.root=e,this._id="zr"+vB++,this._oldVNode=vt(n.width,n.height),e&&!n.ssr){var i=this._viewport=document.createElement("div");i.style.cssText="position:relative;overflow:hidden";var r=this._svgDom=this._oldVNode.elm=m8("svg");
vendor: 5,138 bytes, line 422
422vN(null,this._oldVNode),i.appendChild(r),e.appendChild(i)}this.resize(n.width,n.height)}return e.prototype.getType=function(){return this.type},e.prototype.getViewportRoot=function(){return this._viewport},e.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},e.prototype.getSvgDom=function(){return this._svgDom},e.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style="position:absolute;left:0;top:0;user-select:none",function(e,t){if(vE(e,t))!function e(t,n){var i=n.elm=t.elm,r=t.children,o=n.children;t!==n&&(vN(t,n),vA(n.text)?vP(r)&&vP(o)?r!==o&&function(t,n,i){for(var r,o,a,s=0,l=0,d=n.length-1,u=n[0],c=n[d],h=i.length-1,p=i[0],f=i[h];s<=d&&l<=h;)null==u?u=n[++s]:null==c?c=n[--d]:null==p?p=i[++l]:null==f?f=i[--h]:vE(u,p)?(e(u,p),u=n[++s],p=i[++l]):vE(c,f)?(e(c,f),c=n[--d],f=i[--h]):vE(u,f)?(e(u,f),v_(t,u.elm,vD(c.elm)),u=n[++s],f=i[--h]):(vE(c,p)?(e(c,p),v_(t,c.elm,u.elm),c=n[--d]):(vA(r)&&(r=function(e,t,n){for(var i={},r=t;r<=n;++r){var o=e[r].key;void 0!==o&&(i[o]=r)}return i}(n,s,d)),vA(o=r[p.key])||(a=n[o]).tag!==p.tag?v_(t,vL(p),u.elm):(e(a,p),n[o]=void 0,v_(t,a.elm,u.elm))),p=i[++l]);(s<=d||l<=h)&&(s>d?vF(t,null==i[h+1]?null:i[h+1].elm,i,l,h):vO(t,n,s,d))}(i,r,o):vP(o)?(vP(t.text)&&vR(i,""),vF(i,null,o,0,o.length-1)):vP(r)?vO(i,r,0,r.length-1):vP(t.text)&&vR(i,""):t.text!==n.text&&(vP(r)&&vO(i,r,0,r.length-1),vR(i,n.text)))}(e,t);else{var n=e.elm,i=vT(n);vL(t),null!==i&&(v_(i,t.elm,vD(n)),vO(i,[e],0,0))}}(this._oldVNode,e),this._oldVNode=e}},e.prototype.renderOneToVNode=function(e){return vx(e,ve(this._id))},e.prototype.renderToVNode=function(e){e=e||{};var t=this.storage.getDisplayList(!0),n=this._width,i=this._height,r=ve(this._id);r.animation=e.animation,r.willUpdate=e.willUpdate,r.compress=e.compress,r.emphasis=e.emphasis,r.ssr=this._opts.ssr;var o=[],a=this._bgVNode=function(e,t,n,i){var r;if(n&&"none"!==n)if(r=m7("rect","bg",{width:e,height:t,x:"0",y:"0"}),ob(n))vw({fill:n},r.attrs,"fill",i);else if(om(n))vC({style:{fill:n},dirty:n6,getBoundingRect:function(){return{width:e,height:t}}},r.attrs,"fill",i);else{var o=ou(n),a=o.color,s=o.opacity;r.attrs.fill=a,s<1&&(r.attrs["fill-opacity"]=s)}return r}(n,i,this._backgroundColor,r);a&&o.push(a);var s=e.compress?null:this._mainVNode=m7("g","main",{},[]);this._paintList(t,r,s?s.children:o),s&&o.push(s);var l=nC(nM(r.defs),function(e){return r.defs[e]});if(l.length&&o.push(m7("defs","defs",{},l)),e.animation){var d,u,c,h,p,f,g,m,v=(d=r.cssNodes,u=r.cssAnims,p=" {"+(h=(c={newline:!0}).newline?"\n":""),f=h+"}",g=nC(nM(d),function(e){return e+p+nC(nM(d[e]),function(t){return t+":"+d[e][t]+";"}).join(h)+f}).join(h),m=nC(nM(u),function(e){return"@keyframes "+e+p+nC(nM(u[e]),function(t){return t+p+nC(nM(u[e][t]),function(n){var i=u[e][t][n];return"d"===n&&(i='path("'+i+'")'),n+":"+i+";"}).join(h)+f}).join(h)+f}).join(h),g||m?["<![CDATA[",g,m,"]]>"].join(h):"");if(v){var y=m7("style","stl",{},[],v);o.push(y)}}return vt(n,i,o,e.useViewBox)},e.prototype.renderToString=function(e){return e=e||{},m9(this.renderToVNode({animation:nG(e.cssAnimation,!0),emphasis:nG(e.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:nG(e.useViewBox,!0)}),{newline:!0})},e.prototype.setBackgroundColor=function(e){this._backgroundColor=e},e.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},e.prototype._paintList=function(e,t,n){for(var i,r,o=e.length,a=[],s=0,l=0,d=0;d<o;d++){var u=e[d];if(!u.invisible){var c=u.__clipPaths,h=c&&c.length||0,p=r&&r.length||0,f=void 0;for(f=Math.max(h-1,p-1);f>=0&&(!c||!r||c[f]!==r[f]);f--);for(var g=p-1;g>f;g--)i=a[--s-1];for(var m=f+1;m<h;m++){var v={};!function(e,t,n){var i=n.clipPathCache,r=n.defs,o=i[e.id];if(!o){var a={id:o=n.zrId+"-c"+n.clipPathIdx++};i[e.id]=o,r[o]=m7("clipPath",o,a,[vb(e,n)])}t["clip-path"]=ox(o)}(c[m],v,t);var y=m7("g","clip-g-"+l++,v,[]);(i?i.children:n).push(y),a[s++]=y,i=y}r=c;var b=vx(u,t);b&&(i?i.children:n).push(b)}}},e.prototype.resize=function(e,t){var n=this._opts,i=this.root,r=this._viewport;if(null!=e&&(n.width=e),null!=t&&(n.height=t),i&&r&&(r.style.display="none",e=gI(i,0,n),t=gI(i,1,n),r.style.display=""),this._width!==e||this._height!==t){if(this._width=e,this._height=t,r){var o=r.style;o.width=e+"px",o.height=t+"px"}if(om(this._backgroundColor))this.refresh();else{var a=this._svgDom;a&&(a.setAttribute("width",e),a.setAttribute("height",t));var s=this._bgVNode&&this._bgVNode.elm;s&&(s.setAttribute("width",e),s.setAttribute("height",t))}}},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e.prototype.dispose=function(){this.root&&(this.root.innerHTML=""),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},e.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},e.prototype.toDataURL=function(e){var t=this.renderToString(),n="data:image/svg+xml;";return e?(t=oS(t))&&n+"base64,"+t:n+"charset=UTF-8,"+encodeURIComponent(t)},e}();function vj(e){return function(){}}
422function vV(e,t,n){var i=t4.createCanvas(),r=t.getWidth(),o=t.getHeight(),a=i.style;return a&&(a.position="absolute",a.left="0",a.top="0",a.width=r+"px",a.height=o+"px",i.setAttribute("data-zr-dom-id",e)),i.width=r*n,i.height=o*n,i}var vH=function(e){function t(t,n,i){var r,o=e.call(this)||this;o.motionBlur=!1,o.lastFrameAlpha=.7,o.dpr=1,o.virtual=!1,o.config={},o.incremental=!1,o.zlevel=0,o.maxRepaintRectCount=5,o.__dirty=!0,o.__firstTimePaint=!0,o.__used=!1,o.__drawIndex=0,o.__startIndex=0,o.__endIndex=0,o.__prevStartIndex=null,o.__prevEndIndex=null,i=i||oQ,"string"==typeof t?r=vV(t,n,i):nL(t)&&(t=(r=t).id),o.id=t,o.dom=r;var a=r.style;return a&&(n5(r),r.onselectstart=function(){return!1},a.padding="0",a.margin="0",a.borderWidth="0"),o.painter=n,o.dpr=i,o}return(0,tQ.__extends)(t,e),t.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},t.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},t.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},t.prototype.setUnpainted=function(){this.__firstTimePaint=!0},t.prototype.createBackBuffer=function(){var e=this.dpr;this.domBack=vV("back-"+this.id,this.painter,e),this.ctxBack=this.domBack.getContext("2d"),1!==e&&this.ctxBack.scale(e,e)},t.prototype.createRepaintRects=function(e,t,n,i){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var r,o=[],a=this.maxRepaintRectCount,s=!1,l=new rt(0,0,0,0);function d(e){if(!(!e.isFinite()||e.isZero()))if(0===o.length){var t=new rt(0,0,0,0);t.copy(e),o.push(t)}else{for(var n=!1,i=1/0,r=0,d=0;d<o.length;++d){var u=o[d];if(u.intersect(e)){var c=new rt(0,0,0,0);c.copy(u),c.union(e),o[d]=c,n=!0;break}if(s){l.copy(e),l.union(u);var h=e.width*e.height,p=u.width*u.height,f=l.width*l.height-h-p;f<i&&(i=f,r=d)}}if(s&&(o[r].union(e),n=!0),!n){var t=new rt(0,0,0,0);t.copy(e),o.push(t)}s||(s=o.length>=a)}}for(var u=this.__startIndex;u<this.__endIndex;++u){var c=e[u];if(c){var h=c.shouldBePainted(n,i,!0,!0),p=c.__isRendered&&(1&c.__dirty||!h)?c.getPrevPaintRect():null;p&&d(p);var f=h&&(1&c.__dirty||!c.__isRendered)?c.getPaintRect():null;f&&d(f)}}for(var u=this.__prevStartIndex;u<this.__prevEndIndex;++u){var c=t[u],h=c&&c.shouldBePainted(n,i,!0,!0);if(c&&(!h||!c.__zr)&&c.__isRendered){var p=c.getPrevPaintRect();p&&d(p)}}do{r=!1;for(var u=0;u<o.length;){if(o[u].isZero()){o.splice(u,1);continue}for(var g=u+1;g<o.length;)o[u].intersect(o[g])?(r=!0,o[u].union(o[g]),o.splice(g,1)):g++;u++}}while(r)return this._paintRects=o,o},t.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},t.prototype.resize=function(e,t){var n=this.dpr,i=this.dom,r=i.style,o=this.domBack;r&&(r.width=e+"px",r.height=t+"px"),i.width=e*n,i.height=t*n,o&&(o.width=e*n,o.height=t*n,1!==n&&this.ctxBack.scale(n,n))},t.prototype.clear=function(e,t,n){var i=this.dom,r=this.ctx,o=i.width,a=i.height;t=t||this.clearColor;var s=this.motionBlur&&!e,l=this.lastFrameAlpha,d=this.dpr,u=this;s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(i,0,0,o/d,a/d));var c=this.domBack;function h(e,n,i,o){if(r.clearRect(e,n,i,o),t&&"transparent"!==t){var a=void 0;nB(t)?(a=(t.global||t.__width===i&&t.__height===o)&&t.__canvasGradient||gD(r,t,{x:0,y:0,width:i,height:o}),t.__canvasGradient=a,t.__width=i,t.__height=o):nz(t)&&(t.scaleX=t.scaleX||d,t.scaleY=t.
422scaleY||d,a=gB(r,t,{dirty:function(){u.setUnpainted(),u.painter.refresh()}})),r.save(),r.fillStyle=a||t,r.fillRect(e,n,i,o),r.restore()}s&&(r.save(),r.globalAlpha=l,r.drawImage(c,e,n,i,o),r.restore())}!n||s?h(0,0,o,a):n.length&&nw(n,function(e){h(e.x*d,e.y*d,e.width*d,e.height*d)})},t}(iS),vG=function(){function e(e,t,n,i){this.type="canvas",this._zlevelList=[],this._prevDisplayList=[],this._layers={},this._layerConfig={},this._needsManuallyCompositing=!1,this.type="canvas";var r=!e.nodeName||"CANVAS"===e.nodeName.toUpperCase();this._opts=n=nf({},n||{}),this.dpr=n.devicePixelRatio||oQ,this._singleCanvas=r,this.root=e,e.style&&(n5(e),e.innerHTML=""),this.storage=t;var o=this._zlevelList;this._prevDisplayList=[];var a=this._layers;if(r){var s=e.width,l=e.height;null!=n.width&&(s=n.width),null!=n.height&&(l=n.height),this.dpr=n.devicePixelRatio||1,e.width=s*this.dpr,e.height=l*this.dpr,this._width=s,this._height=l;var d=new vH(e,this,this.dpr);d.__builtin__=!0,d.initContext(),a[314159]=d,d.zlevel=314159,o.push(314159),this._domRoot=e}else{this._width=gI(e,0,n),this._height=gI(e,1,n);var u,c,h,p=this._domRoot=(u=this._width,c=this._height,(h=document.createElement("div")).style.cssText=["position:relative","width:"+u+"px","height:"+c+"px","padding:0;margin:0;border-width:0"].join(";")+";",h);e.appendChild(p)}}return e.prototype.getType=function(){return"canvas"},e.prototype.isSingleCanvas=function(){return this._singleCanvas},e.prototype.getViewportRoot=function(){return this._domRoot},e.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},e.prototype.refresh=function(e){var t=this.storage.getDisplayList(!0),n=this._prevDisplayList,i=this._zlevelList;this._redrawId=Math.random(),this._paintList(t,n,e,this._redrawId);for(var r=0;r<i.length;r++){var o=i[r],a=this._layers[o];if(!a.__builtin__&&a.refresh){var s=0===r?this._backgroundColor:null;a.refresh(s)}}return this._opts.useDirtyRect&&(this._prevDisplayList=t.slice()),this},e.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},e.prototype._paintHoverList=function(e){var t,n=e.length,i=this._hoverlayer;if(i&&i.clear(),n){for(var r={inHover:!0,viewWidth:this._width,viewHeight:this._height},o=0;o<n;o++){var a=e[o];a.__inHover&&(i||(i=this._hoverlayer=this.getLayer(1e5)),t||(t=i.ctx).save(),gq(t,a,r,o===n-1))}t&&t.restore()}},e.prototype.getHoverLayer=function(){return this.getLayer(1e5)},e.prototype.paintOne=function(e,t){gU(e,t)},e.prototype._paintList=function(e,t,n,i){if(this._redrawId===i){n=n||!1,this._updateLayerStatus(e);var r=this._doPaintList(e,t,n),o=r.finished,a=r.needsRefreshHover;if(this._needsManuallyCompositing&&this._compositeManually(),a&&this._paintHoverList(e),o)this.eachLayer(function(e){e.afterBrush&&e.afterBrush()});else{var s=this;y(function(){s._paintList(e,t,n,i)})}}},e.prototype._compositeManually=function(){var e=this.getLayer(314159).ctx,t=this._domRoot.width,n=this._domRoot.height;e.clearRect(0,0,t,n),this.eachBuiltinLayer(function(i){i.virtual&&e.drawImage(i.dom,0,0,t,n)})},e.prototype._doPaintList=function(e,t,n){for(var i=this,r=[],o=this._opts.useDirtyRect,a=0;a<this._zlevelList.length;a++){var s=this._zlevelList[a],l=this._layers[s];l.__builtin__&&l!==this._hoverlayer&&(l.__dirty||n)&&r.push(l)}for(var d=!0,u=!1,c=this,h=0;h<r.length;h++)!function(a){var s,l=r[a],h=l.ctx,p=o&&l.createRepaintRects(e,t,c._width,c._height),f=n?l.__startIndex:l.__drawIndex,g=!n&&l.incremental&&Date.now,m=g&&Date.now(),v=l.zlevel===c._zlevelList[0]?c._backgroundColor:null;if(l.__startIndex===l.__endIndex)l.clear(!1,v,p);else if(f===l.__startIndex){var y=e[f];y.incremental&&y.notClear&&!n||l.clear(!1,v,p)}-1===f&&(console.error("For some unknown reason. drawIndex is -1"),f=l.__startIndex);var b=function(t){var n={inHover:!1,allClipped:!1,prevEl:null,viewWidth:i._width,viewHeight:i._height};for(s=f;s<l.__endIndex;s++){var r=e[s];if(r.__inHover&&(u=!0),i._doPaintEl(r,l,o,t,n,s===l.__endIndex-1),g&&Date.now()-m>15)break}
422n.prevElClipPaths&&h.restore()};if(p)if(0===p.length)s=l.__endIndex;else for(var x=c.dpr,w=0;w<p.length;++w){var C=p[w];h.save(),h.beginPath(),h.rect(C.x*x,C.y*x,C.width*x,C.height*x),h.clip(),b(C),h.restore()}else h.save(),b(),h.restore();l.__drawIndex=s,l.__drawIndex<l.__endIndex&&(d=!1)}(h);return t1.wxa&&nw(this._layers,function(e){e&&e.ctx&&e.ctx.draw&&e.ctx.draw()}),{finished:d,needsRefreshHover:u}},e.prototype._doPaintEl=function(e,t,n,i,r,o){var a=t.ctx;if(n){var s=e.getPaintRect();(!i||s&&s.intersect(i))&&(gq(a,e,r,o),e.setPrevPaintRect(s))}else gq(a,e,r,o)},e.prototype.getLayer=function(e,t){this._singleCanvas&&!this._needsManuallyCompositing&&(e=314159);var n=this._layers[e];return n||((n=new vH("zr_"+e,this,this.dpr)).zlevel=e,n.__builtin__=!0,this._layerConfig[e]?nh(n,this._layerConfig[e],!0):this._layerConfig[e-.01]&&nh(n,this._layerConfig[e-.01],!0),t&&(n.virtual=t),this.insertLayer(e,n),n.initContext()),n},e.prototype.insertLayer=function(e,t){var n=this._layers,i=this._zlevelList,r=i.length,o=this._domRoot,a=null,s=-1;if(!n[e]){if(t&&(t.__builtin__||"function"==typeof t.resize&&"function"==typeof t.refresh&&1)){if(r>0&&e>i[0]){for(s=0;s<r-1&&(!(i[s]<e)||!(i[s+1]>e));s++);a=n[i[s]]}if(i.splice(s+1,0,e),n[e]=t,!t.virtual)if(a){var l=a.dom;l.nextSibling?o.insertBefore(t.dom,l.nextSibling):o.appendChild(t.dom)}else o.firstChild?o.insertBefore(t.dom,o.firstChild):o.appendChild(t.dom);t.painter||(t.painter=this)}}},e.prototype.eachLayer=function(e,t){for(var n=this._zlevelList,i=0;i<n.length;i++){var r=n[i];e.call(t,this._layers[r],r)}},e.prototype.eachBuiltinLayer=function(e,t){for(var n=this._zlevelList,i=0;i<n.length;i++){var r=n[i],o=this._layers[r];o.__builtin__&&e.call(t,o,r)}},e.prototype.eachOtherLayer=function(e,t){for(var n=this._zlevelList,i=0;i<n.length;i++){var r=n[i],o=this._layers[r];o.__builtin__||e.call(t,o,r)}},e.prototype.getLayers=function(){return this._layers},e.prototype._updateLayerStatus=function(e){function t(e){a&&(a.__endIndex!==e&&(a.__dirty=!0),a.__endIndex=e)}if(this.eachBuiltinLayer(function(e,t){e.__dirty=e.__used=!1}),this._singleCanvas)for(var n,i,r=1;r<e.length;r++){var o=e[r];if(o.zlevel!==e[r-1].zlevel||o.incremental){this._needsManuallyCompositing=!0;break}}var a=null,s=0;for(i=0;i<e.length;i++){var o=e[i],l=o.zlevel,d=void 0;n!==l&&(n=l,s=0),o.incremental?((d=this.getLayer(l+.001,this._needsManuallyCompositing)).incremental=!0,s=1):d=this.getLayer(l+.01*(s>0),this._needsManuallyCompositing),d.__builtin__||nu("ZLevel "+l+" has been used by unkown layer "+d.id),d!==a&&(d.__used=!0,d.__startIndex!==i&&(d.__dirty=!0),d.__startIndex=i,d.incremental?d.__drawIndex=-1:d.__drawIndex=i,t(i),a=d),1&o.__dirty&&!o.__inHover&&(d.__dirty=!0,d.incremental&&d.__drawIndex<0&&(d.__drawIndex=i))}t(i),this.eachBuiltinLayer(function(e,t){!e.__used&&e.getElementCount()>0&&(e.__dirty=!0,e.__startIndex=e.__endIndex=e.__drawIndex=0),e.__dirty&&e.__drawIndex<0&&(e.__drawIndex=e.__startIndex)})},e.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},e.prototype._clearLayer=function(e){e.clear()},e.prototype.setBackgroundColor=function(e){this._backgroundColor=e,nw(this._layers,function(e){e.setUnpainted()})},e.prototype.configLayer=function(e,t){if(t){var n=this._layerConfig;n[e]?nh(n[e],t,!0):n[e]=t;for(var i=0;i<this._zlevelList.length;i++){var r=this._zlevelList[i];(r===e||r===e+.01)&&nh(this._layers[r],n[e],!0)}}},e.prototype.delLayer=function(e){var t=this._layers,n=this._zlevelList,i=t[e];i&&(i.dom.parentNode.removeChild(i.dom),delete t[e],n.splice(nv(n,e),1))},e.prototype.resize=function(e,t){if(this._domRoot.style){var n=this._domRoot;n.style.display="none";var i=this._opts,r=this.root;if(null!=e&&(i.width=e),null!=t&&(i.height=t),e=gI(r,0,i),t=gI(r,1,i),n.style.display="",this._width!==e||t!==this._height){for(var o in n.style.width=e+"px",n.style.height=t+"px",this._layers)this._layers.hasOwnProperty(o)&&this._layers[o].resize(e,t);this.refresh(!0)}this._width=e,this._height=t}else{if(null==e||null==t)return;this._width=e,this._height=t,this.getLayer(314159).resize(e,t)}return this},e.prototype.clearLayer=function(e){var t=this._layers[e];t&&t.clear()},e.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},e.prototype.getRenderedCanvas=function(e){if(e=e||{},this._singleCanvas&&!this._compositeManually)return this._layers[314159].dom;var t=new vH("image",this,e.pixelRatio||this.dpr);t.initContext(),t.clear(!1,e.backgroundColor||this._backgroundColor);var n=t.ctx;if(e.pixelRatio<=this.dpr){this.refresh();var i=t.dom.width,r=t.dom.height;this.eachLayer(function(e){e.__builtin__?n.drawImage(e.dom,0,0,i,r):e.renderToCanvas&&(n.save(),e.renderToCanvas(n),n.restore(
vendor: 5,346 bytes, line 422
422))})}else for(var o={inHover:!1,viewWidth:this._width,viewHeight:this._height},a=this.storage.getDisplayList(!0),s=0,l=a.length;s<l;s++)gq(n,a[s],o,s===l-1);return t.dom},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e}();function vW(e){return null==e?0:e.length||1}function v$(e){return e}var vU=function(){function e(e,t,n,i,r,o){this._old=e,this._new=t,this._oldKeyGetter=n||v$,this._newKeyGetter=i||v$,this.context=r,this._diffModeMultiple="multiple"===o}return e.prototype.add=function(e){return this._add=e,this},e.prototype.update=function(e){return this._update=e,this},e.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},e.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},e.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},e.prototype.remove=function(e){return this._remove=e,this},e.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},e.prototype._executeOneToOne=function(){var e=this._old,t=this._new,n={},i=Array(e.length),r=Array(t.length);this._initIndexMap(e,null,i,"_oldKeyGetter"),this._initIndexMap(t,n,r,"_newKeyGetter");for(var o=0;o<e.length;o++){var a=i[o],s=n[a],l=vW(s);if(l>1){var d=s.shift();1===s.length&&(n[a]=s[0]),this._update&&this._update(d,o)}else 1===l?(n[a]=null,this._update&&this._update(s,o)):this._remove&&this._remove(o)}this._performRestAdd(r,n)},e.prototype._executeMultiple=function(){var e=this._old,t=this._new,n={},i={},r=[],o=[];this._initIndexMap(e,n,r,"_oldKeyGetter"),this._initIndexMap(t,i,o,"_newKeyGetter");for(var a=0;a<r.length;a++){var s=r[a],l=n[s],d=i[s],u=vW(l),c=vW(d);if(u>1&&1===c)this._updateManyToOne&&this._updateManyToOne(d,l),i[s]=null;else if(1===u&&c>1)this._updateOneToMany&&this._updateOneToMany(d,l),i[s]=null;else if(1===u&&1===c)this._update&&this._update(d,l),i[s]=null;else if(u>1&&c>1)this._updateManyToMany&&this._updateManyToMany(d,l),i[s]=null;else if(u>1)for(var h=0;h<u;h++)this._remove&&this._remove(l[h]);else this._remove&&this._remove(l)}this._performRestAdd(o,i)},e.prototype._performRestAdd=function(e,t){for(var n=0;n<e.length;n++){var i=e[n],r=t[i],o=vW(r);if(o>1)for(var a=0;a<o;a++)this._add&&this._add(r[a]);else 1===o&&this._add&&this._add(r);t[i]=null}},e.prototype._initIndexMap=function(e,t,n,i){for(var r=this._diffModeMultiple,o=0;o<e.length;o++){var a="_ec_"+this[i](e[o],o);if(r||(n[o]=a),t){var s=t[a],l=vW(s);0===l?(t[a]=o,r&&n.push(a)):1===l?t[a]=[s,o]:s.push(o)}}},e}(),vq=function(){function e(e,t){this._encode=e,this._schema=t}return e.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},e.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},e}();function vK(e,t){return e.hasOwnProperty(t)||(e[t]=[]),e[t]}function vY(e){return"category"===e?"ordinal":"time"===e?"time":"float"}let vZ=function(e){this.otherDims={},null!=e&&nf(this,e)};var vX=a9(),vJ={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},vQ=function(){function e(e){this.dimensions=e.dimensions,this._dimOmitted=e.dimensionOmitted,this.source=e.source,this._fullDimCount=e.fullDimensionCount,this._updateDimOmitted(e.dimensionOmitted)}return e.prototype.isDimensionOmitted=function(){return this._dimOmitted},e.prototype._updateDimOmitted=function(e){this._dimOmitted=e,e&&(this._dimNameMap||(this._dimNameMap=v2(this.source)))},e.prototype.getSourceDimensionIndex=function(e){return nG(this._dimNameMap.get(e),-1)},e.prototype.getSourceDimension=function(e){var t=this.source.dimensionsDefine;if(t)return t[e]},e.prototype.makeStoreSchema=function(){for(var e=this._fullDimCount,t=c5(this.source),n=!(e>30),i="",r=[],o=0,a=0;o<e;o++){var s=void 0,l=void 0,d=void 0,u=this.dimensions[a];if(u&&u.storeDimIndex===o)s=t?u.name:null,l=u.type,d=u.ordinalMeta,a++;else{var c=this.getSourceDimension(o);c&&(s=t?c.name:null,l=c.type)}r.push({property:s,type:l,ordinalMeta:d}),!t||null==s||u&&u.isCalculationCoord||(i+=n?s.replace(/\`/g,"`1").replace(/\$/g,"`2"):s),i+="$",i+=vJ[l]||"f",d&&(i+=d.uid),i+="$"}var h=this.source;return{dimensions:r,hash:[h.seriesLayoutBy,h.startIndex,i].join("$$")}},e.prototype.makeOutputDimensionNames=function(){for(var e=[],t=0,n=0;t<this._fullDimCount;t++){var i=void 0,r=this.dimensions[n];if(r&&r.storeDimIndex===t)r.isCalculationCoord||(i=r.name),n++;else{var o=this.getSourceDimension(t);o&&(i=o.name)}e.push(i)}return e},e.prototype.appendCalculationDimension=function(e){this.dimensions.push(e),e.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},e}();function v0(e){return e instanceof vQ}function v1(e){for(var t=n1(),n=0;n<(e||[]).length;n++){var i=e[n],r=nL(i)?i.name:i;null!=r&&null==t.get(r)&&t.set(r,n)}return t}function v2(e){var t=vX(e);return t.dimNameMap||(t.dimNameMap=v1(e.dimensionsDefine))}var v3=nL,v5="u"<typeof Int32Array?Array:Int32Array,v4=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],v6=["_approximateExtent"],v8=function(){function e(e,t){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual
422={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var n,i=!1;v0(e)?(n=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(i=!0,n=e),n=n||["x","y"];for(var r={},o=[],a={},s=!1,l={},d=0;d<n.length;d++){var u=n[d],c=nA(u)?new vZ({name:u}):u instanceof vZ?u:new vZ(u),h=c.name;c.type=c.type||"float",c.coordDim||(c.coordDim=h,c.coordDimIndex=0);var p=c.otherDims=c.otherDims||{};o.push(h),r[h]=c,null!=l[h]&&(s=!0),c.createInvertedIndices&&(a[h]=[]),0===p.itemName&&(this._nameDimIdx=d),0===p.itemId&&(this._idDimIdx=d),i&&(c.storeDimIndex=d)}if(this.dimensions=o,this._dimInfos=r,this._initGetDimensionInfo(s),this.hostModel=t,this._invertedIndicesMap=a,this._dimOmitted){var f=this._dimIdxToName=n1();nw(o,function(e){f.set(r[e].storeDimIndex,e)})}}return e.prototype.getDimension=function(e){var t=this._recognizeDimIndex(e);if(null==t)return e;if(t=e,!this._dimOmitted)return this.dimensions[t];var n=this._dimIdxToName.get(t);if(null!=n)return n;var i=this._schema.getSourceDimension(t);if(i)return i.name},e.prototype.getDimensionIndex=function(e){var t=this._recognizeDimIndex(e);if(null!=t)return t;if(null==e)return -1;var n=this._getDimInfo(e);return n?n.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(e):-1},e.prototype._recognizeDimIndex=function(e){if(nE(e)||null!=e&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||0>this._schema.getSourceDimensionIndex(e)))return+e},e.prototype._getStoreDimIndex=function(e){return this.getDimensionIndex(e)},e.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},e.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(e){return t.hasOwnProperty(e)?t[e]:void 0}:function(e){return t[e]}},e.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},e.prototype.mapDimension=function(e,t){var n=this._dimSummary;if(null==t)return n.encodeFirstDimNotExtra[e];var i=n.encode[e];return i?i[t]:null},e.prototype.mapDimensionsAll=function(e){return(this._dimSummary.encode[e]||[]).slice()},e.prototype.getStore=function(){return this._store},e.prototype.initData=function(e,t,n){var i,r,o,a,s,l,d,u,c,h,p,f,g,m=this;if(e instanceof hP&&(g=e),!g){var v=this.dimensions,y=cJ(e)||nx(e)?new c4(e,v.length):e;g=new hP;var b=nC(v,function(e){return{type:m._dimInfos[e].type,property:e}});g.initData(y,b,n)}this._store=g,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,g.count()),this._dimSummary=(i=this,r=this._schema,a=(o={}).encode={},s=n1(),l=[],d=[],u={},nw(i.dimensions,function(e){var t=i.getDimensionInfo(e),n=t.coordDim;if(n){var r,o=t.coordDimIndex;vK(a,n)[o]=e,t.isExtraCoord||(s.set(n,1),"ordinal"!==(r=t.type)&&"time"!==r&&(l[0]=e),vK(u,n)[o]=i.getDimensionIndex(t.name)),t.defaultTooltip&&d.push(e)}ce.each(function(e,n){var i=vK(a,n),r=t.otherDims[n];null!=r&&!1!==r&&(i[r]=t.name)})}),c=[],h={},s.each(function(e,t){var n=a[t];h[t]=n[0],c=c.concat(n)}),o.dataDimsOnCoord=c,o.dataDimIndicesOnCoord=nC(c,function(e){return i.getDimensionInfo(e).storeDimIndex}),o.encodeFirstDimNotExtra=h,(p=a.label)&&p.length&&(l=p.slice()),(f=a.tooltip)&&f.length?d=f.slice():d.length||(d=l.slice()),a.defaultedLabel=l,a.defaultedTooltip=d,o.userOutput=new vq(u,r),o),this.userOutput=this._dimSummary.userOutput},e.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},e.prototype.appendValues=function(e,t){var n=this._store.appendValues(e,t&&t.length),i=n.start,r=n.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var a=i;a<r;a++){var s=a-i;this._nameList[a]=t[s],o&&ee(this,a)}},e.prototype._updateOrdinalMeta=function(){for(var e=this._store,t=this.dimensions,n=0;n<t.length;n++){var i=this._dimInfos[t[n]];i.ordinalMeta&&e.collectOrdinalMeta(i.storeDimIndex,i.ordinalMeta)}},e.prototype._shouldMakeIdFromName=function(){var e=this._store.getProvider();return null==this._idDimIdx&&e.getSource().sourceFormat!==co&&!e.fillStorage},e.prototype._doInit=function(e,t){if(!(e>=t)){var n=this._store.getProvider();this._updateOrdinalMeta();var i=this._nameList,r=this._idList;if(n.getSource().sourceFormat===ct&&!n.pure)for(var o=[],a=e;a<t;a++){var s,l=n.getItem(a,o);if(!(!this.hasItemOption&&nL(s=l))||s instanceof Array||(this.hasItemOption=!0),l){var d=l.name;null==i[a]&&null!=d&&(i[a]=a4(d,null));var u=l.id;
vendor: 4,088 bytes, line 422
422null==r[a]&&null!=u&&(r[a]=a4(u,null))}}if(this._shouldMakeIdFromName())for(var a=e;a<t;a++)ee(this,a);K(this)}},e.prototype.getApproximateExtent=function(e){return this._approximateExtent[e]||this._store.getDataExtent(this._getStoreDimIndex(e))},e.prototype.setApproximateExtent=function(e,t){t=this.getDimension(t),this._approximateExtent[t]=e.slice()},e.prototype.getCalculationInfo=function(e){return this._calculationInfo[e]},e.prototype.setCalculationInfo=function(e,t){v3(e)?nf(this._calculationInfo,e):this._calculationInfo[e]=t},e.prototype.getName=function(e){var t=this.getRawIndex(e),n=this._nameList[t];return null==n&&null!=this._nameDimIdx&&(n=Z(this,this._nameDimIdx,t)),null==n&&(n=""),n},e.prototype._getCategory=function(e,t){var n=this._store.get(e,t),i=this._store.getOrdinalMeta(e);return i?i.categories[n]:n},e.prototype.getId=function(e){return Y(this,this.getRawIndex(e))},e.prototype.count=function(){return this._store.count()},e.prototype.get=function(e,t){var n=this._store,i=this._dimInfos[e];if(i)return n.get(i.storeDimIndex,t)},e.prototype.getByRawIndex=function(e,t){var n=this._store,i=this._dimInfos[e];if(i)return n.getByRawIndex(i.storeDimIndex,t)},e.prototype.getIndices=function(){return this._store.getIndices()},e.prototype.getDataExtent=function(e){return this._store.getDataExtent(this._getStoreDimIndex(e))},e.prototype.getSum=function(e){return this._store.getSum(this._getStoreDimIndex(e))},e.prototype.getMedian=function(e){return this._store.getMedian(this._getStoreDimIndex(e))},e.prototype.getValues=function(e,t){var n=this,i=this._store;return nR(e)?i.getValues(nC(e,function(e){return n._getStoreDimIndex(e)}),t):i.getValues(e)},e.prototype.hasValue=function(e){for(var t=this._dimSummary.dataDimIndicesOnCoord,n=0,i=t.length;n<i;n++)if(isNaN(this._store.get(t[n],e)))return!1;return!0},e.prototype.indexOfName=function(e){for(var t=0,n=this._store.count();t<n;t++)if(this.getName(t)===e)return t;return -1},e.prototype.getRawIndex=function(e){return this._store.getRawIndex(e)},e.prototype.indexOfRawIndex=function(e){return this._store.indexOfRawIndex(e)},e.prototype.rawIndexOf=function(e,t){var n=e&&this._invertedIndicesMap[e],i=n&&n[t];return null==i||isNaN(i)?-1:i},e.prototype.indicesOfNearest=function(e,t,n){return this._store.indicesOfNearest(this._getStoreDimIndex(e),t,n)},e.prototype.each=function(e,t,n){nI(e)&&(n=t,t=e,e=[]);var i=n||this,r=nC(X(e),this._getStoreDimIndex,this);this._store.each(r,i?nT(t,i):t)},e.prototype.filterSelf=function(e,t,n){nI(e)&&(n=t,t=e,e=[]);var i=n||this,r=nC(X(e),this._getStoreDimIndex,this);return this._store=this._store.filter(r,i?nT(t,i):t),this},e.prototype.selectRange=function(e){var t=this,n={},i=nM(e),r=[];return nw(i,function(i){var o=t._getStoreDimIndex(i);n[o]=e[i],r.push(o)}),this._store=this._store.selectRange(n),this},e.prototype.mapArray=function(e,t,n){nI(e)&&(n=t,t=e,e=[]),n=n||this;var i=[];return this.each(e,function(){i.push(t&&t.apply(this,arguments))},n),i},e.prototype.map=function(e,t,n,i){var r=n||i||this,o=nC(X(e),this._getStoreDimIndex,this),a=Q(this);return a._store=this._store.map(o,r?nT(t,r):t),a},e.prototype.modify=function(e,t,n,i){var r=n||i||this,o=nC(X(e),this._getStoreDimIndex,this);this._store.modify(o,r?nT(t,r):t)},e.prototype.downSample=function(e,t,n,i){var r=Q(this);return r._store=this._store.downSample(this._getStoreDimIndex(e),t,n,i),r},e.prototype.minmaxDownSample=function(e,t){var n=Q(this);return n._store=this._store.minmaxDownSample(this._getStoreDimIndex(e),t),n},e.prototype.lttbDownSample=function(e,t){var n=Q(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(e),t),n},e.prototype.getRawDataItem=function(e){return this._store.getRawDataItem(e)},e.prototype.getItemModel=function(e){var t=this.hostModel;return new ua(this.getRawDataItem(e),t,t&&t.ecModel)},e.prototype.diff=function(e){var t=this;return new vU(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(t){return Y(e,t)},function(e){return Y(t,e)})},e.prototype.getVisual=function(e){var t=this._visual;return t&&t[e]}
422,e.prototype.setVisual=function(e,t){this._visual=this._visual||{},v3(e)?nf(this._visual,e):this._visual[e]=t},e.prototype.getItemVisual=function(e,t){var n=this._itemVisuals[e],i=n&&n[t];return null==i?this.getVisual(t):i},e.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},e.prototype.ensureUniqueItemVisual=function(e,t){var n=this._itemVisuals,i=n[e];i||(i=n[e]={});var r=i[t];return null==r&&(nR(r=this.getVisual(t))?r=r.slice():v3(r)&&(r=nf({},r)),i[t]=r),r},e.prototype.setItemVisual=function(e,t,n){var i=this._itemVisuals[e]||{};this._itemVisuals[e]=i,v3(t)?nf(i,t):i[t]=n},e.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},e.prototype.setLayout=function(e,t){v3(e)?nf(this._layout,e):this._layout[e]=t},e.prototype.getLayout=function(e){return this._layout[e]},e.prototype.getItemLayout=function(e){return this._itemLayouts[e]},e.prototype.setItemLayout=function(e,t,n){this._itemLayouts[e]=n?nf(this._itemLayouts[e]||{},t):t},e.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},e.prototype.setItemGraphicEl=function(e,t){l0(this.hostModel&&this.hostModel.seriesIndex,this.dataType,e,t),this._graphicEls[e]=t},e.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},e.prototype.eachItemGraphicEl=function(e,t){nw(this._graphicEls,function(n,i){n&&e&&e.call(t,n,i)})},e.prototype.cloneShallow=function(t){return t||(t=new e(this._schema?this._schema:nC(this.dimensions,this._getDimInfo,this),this.hostModel)),J(t,this),t._store=this._store,t},e.prototype.wrapMethod=function(e,t){var n=this[e];nI(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var e=n.apply(this,arguments);return t.apply(this,[e].concat(n$(arguments)))})},e.internalField=void(K=function(e){var t=e._invertedIndicesMap;nw(t,function(n,i){var r=e._dimInfos[i],o=r.ordinalMeta,a=e._store;if(o){n=t[i]=new v5(o.categories.length);for(var s=0;s<n.length;s++)n[s]=-1;for(var s=0;s<a.count();s++)n[a.get(r.storeDimIndex,s)]=s}})},Z=function(e,t,n){return a4(e._getCategory(t,n),null)},Y=function(e,t){var n=e._idList[t];return null==n&&null!=e._idDimIdx&&(n=Z(e,e._idDimIdx,t)),null==n&&(n="e\0\0"+t),n},X=function(e){return nR(e)||(e=null!=e?[e]:[]),e},Q=function(t){var n=new e(t._schema?t._schema:nC(t.dimensions,t._getDimInfo,t),t.hostModel);return J(n,t),n},J=function(e,t){nw(v4.concat(t.__wrappedMethods||[]),function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e.__wrappedMethods=t.__wrappedMethods,nw(v6,function(n){e[n]=nc(t[n])}),e._calculationInfo=nf({},t._calculationInfo)},ee=function(e,t){var n=e._nameList,i=e._idList,r=e._nameDimIdx,o=e._idDimIdx,a=n[t],s=i[t];if(null==a&&null!=r&&(n[t]=a=Z(e,r,t)),null==s&&null!=o&&(i[t]=s=Z(e,o,t)),null==s&&null!=a){var l=e._nameRepeatCount,d=l[a]=(l[a]||0)+1;s=a,d>1&&(s+="__ec__"+d),i[t]=s}}),e}();function v7(e,t){return v9(e,t).dimensions}function v9(e,t){cJ(e)||(e=c0(e));var n,i,r,o,a,s=(t=t||{}).coordDimensions||[],l=t.dimensionsDefine||e.dimensionsDefine||[],d=n1(),u=[],c=(n=e,i=s,r=l,o=t.dimensionsCount,a=Math.max(n.dimensionsDetectedCount||1,i.length,r.length,o||0),nw(i,function(e){var t;nL(e)&&(t=e.dimsDef)&&(a=Math.max(a,t.length))}),a),h=t.canOmitUnusedDimensions&&c>30,p=l===e.dimensionsDefine,f=p?v2(e):v1(l),g=t.encodeDefine;!g&&t.encodeDefaulter&&(g=t.encodeDefaulter(e,c));for(var m=n1(g),v=new hM(c),y=0;y<v.length;y++)v[y]=-1;function b(e){var t=v[e];if(t<0){var n=l[e],i=nL(n)?n:{name:n},r=new vZ,o=i.name;null!=o&&null!=f.get(o)&&(r.name=r.displayName=o),null!=i.type&&(r.type=i.type),null!=i.displayName&&(r.displayName=i.displayName);var a=u.length;return v[e]=a,r.storeDimIndex=e,u.push(r),r}return u[t]}if(!h)for(var y=0;y<c;y++)b(y);m.each(function(e,t){var n=aJ(e).slice();if(1===n.length&&!nA(n[0])&&n[0]<0)return void m.set(t,!1);var i=m.set(t,[]);nw(n,function(e,n){var r=nA(e)?f.get(e):e;null!=r&&r<c&&(i[n]=r,w(b(r),t,n))})});var x=0;function w(e,t,n){null!=ce.get(t)?e.otherDims[t]=n:(e.coordDim=t,e.coordDimIndex=n,d.set(t,!0))}nw(s,function(e){if(nA(e))r=e,i={};else{var t,n,i,r=(i=e).name,o=i.ordinalMeta;i.ordinalMeta=null,(i=nf({},i)).ordinalMeta=o,t=i.dimsDef,n=i.otherDims,i.name=i.coordDim=i.coordDimIndex=i.dimsDef=i.otherDims=null}var a=m.get(r);if(!1!==a){if(!(a=aJ(a)).length)for(var s=0;s<(t&&t.length||1);s++){for(;x<c&&null!=b(x).coordDim;)x++;x<c&&a.push(x++)}nw(a,function(e,o){var a=b(e);if(p&&null!=i.type&&(a.type=i.type),w(ng(a,i),r,o),null==a.name&&t){var s=t[o];nL(s)||(s={name:s}),a.name=a.displayName=s.name,a.defaultTooltip=s.defaultTooltip}n&&ng(a.otherDims,n)})}});var C=t.generateCoord,S=t.generateCoordCount,_=null!=S;S=C?S||1:0;var k=C||"value";function M(e){null==e.name&&(e.name=e.coordDim)}if(h)nw(u,function(e){M(e)}),u.sort(function(e,t){return e.storeDimIndex-t.storeDimIndex});else for(var T=0;T<c;T++){var D=b(T);null==D.coordDim&&(D.coordDim=function(e,t,n){if(n||t.hasKey(e)){for(var i=0;t.hasKey(e+i);)i++;e+=i}return t.set(e,!0),e}(k,d,_),D.coordDimIndex=0,(!C||S<=0)&&(D.isExtraCoord=!0),S--),M(D),null==D.type&&(1===ch(e,T)||D.isExtraCoord&&(null!=D.otherDims.itemName||null!=D.otherDims.seriesName))&&(D.type="ordinal")}return function(e){for(var t=n1(),n=0;n<e.length;n++){var i=e[n],r=i.name,o=t.get(r)||0;o>0&&(i.name=r+(o-1)),o++,t.set(r,o)}}(u),new vQ({source:e,dimensions:u,fullDimensionCount:c,dimensionOmitted:h})}var ye=function(e){this.coordSysDims=[],this.axisMap=n1(),this.categoryAxisMap=n1(),this.coordSysName=e},yt={cartesian2d:function(e,t,n,i){var r=e.getReferringComponents("xAxis",si).models[0],o=e.getReferringComponents("yAxis",si).models[0];t.coordSysDims=["x","y"],n.set("x",r),n.set("y",o),yn(r)&&(i.set("x",r),t.firstCategoryDimIndex=0),yn(o)&&(i.set("y",o),null==t.firstCategoryDimIndex&&(t.firstCategoryDimIndex=1))},singleAxis:function(e,t,n,i){var r=e.getReferringComponents("singleAxis",si).models[0];t.coordSysDims=["single"],n.set("single",r),yn(r)&&(i.set("single",r),t.firstCategoryDimIndex=0)},polar:function(e,t,n,i){var r=e.getReferringComponents("polar",si).models[0],o=r.findAxisModel("radiusAxis"),a=r.findAxisModel("angleAxis");t.coordSysDims=["radius","angle"],n.set("radius",o),n.set("angle",a),yn(o)&&(i.set("radius",o),t.firstCategoryDimIndex=0),yn(a)&&(i.set("angle",a),null==t.firstCategoryDimIndex&&(t.firstCategoryDimIndex=1))},geo:function(e,t,n,i){t.coordSysDims=["lng","lat"]},parallel:function(e,t,n,i){var r=e.ecModel,o=r.getComponent("parallel",e.get("parallelIndex")),a=t.coordSysDims=o.dimensions.slice();nw(o.parallelAxisIndex,function(e,o){var s=r.getComponent("parallelAxis",e),l=a[o];n.set(l,s),yn(s)&&(i.set(l,s),null==t.firstCategoryDimIndex&&(t.firstCategoryDimIndex=o))})}};function yn(e){return"category"===e.get("type")}function yi(e,t,n){var i,r,o,a,s,l,d,u=(n=n||{}).byIndex,c=n.stackedCoordDimension;v0(t.schema)?(i=(r=t.schema).dimensions,o=t.store):i=t;var h=!!(e&&e.get("stack"));if(nw(i,function(e,t){nA(e)&&(i[t]=e={name:e}),h&&!e.isExtraCoord&&(u||a||!e.ordinalMeta||(a=e),s||"ordinal"===e.type||"time"===e.type||c&&c!==e.coordDim||(s=e))}),!s||u||a||(u=!0),s){l="__\0ecstackresult_"+e.id,d="__\0ecstackedover_"+e.id,a&&(a.createInvertedIndices=!0);var p=s.coordDim,f=s.type,g=0;nw(i,function(e){e.coordDim===p&&g++});var m={name:l,coordDim:p,coordDimIndex:g,type:f,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},v={name:d,coordDim:d,coordDimIndex:g+1,type:f,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};r?(o&&(m.storeDimIndex=o.ensureCalculationDimension(d,f),v.storeDimIndex=o.ensureCalculationDimension(l,f)),r.appendCalculationDimension(m),r.appendCalculationDimension(v)):(i.push(m),i.push(v))}return{stackedDimension:s&&s.name,stackedByDimension:a&&a.name,isStackedByIndex:u,stackedOverDimension:d,stackResultDimension:l}}function yr(e,t){return!!t&&t===e.getCalculationInfo("stackedDimension")}function yo(e,t){return yr(e,t)?e.getCalculationInfo("stackResultDimension"):t}let ya=function(e,t,n){n=n||{};var i,r,o,a,s,l,d,u,c=t.getSourceManager(),h=!1;
vendor: 6,353 bytes, line 422
422e?(h=!0,u=c0(e)):h=(u=c.getSource()).sourceFormat===ct;var p=function(e){var t=e.get("coordinateSystem"),n=new ye(t),i=yt[t];if(i)return i(e,n,n.axisMap,n.categoryAxisMap),n}(t),f=(r=t.get("coordinateSystem"),o=cI.get(r),p&&p.coordSysDims&&(i=nC(p.coordSysDims,function(e){var t={name:e},n=p.axisMap.get(e);return n&&(t.type=vY(n.get("type"))),t})),i||(i=o&&(o.getDimensionsInfo?o.getDimensionsInfo():o.dimensions.slice())||["x","y"]),i),g=n.useEncodeDefaulter,m=nI(g)?g:g?nD(cd,f,t):null,v=v9(u,{coordDimensions:f,generateCoord:n.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:m,canOmitUnusedDimensions:!h}),y=(a=v.dimensions,s=n.createInvertedIndices,p&&nw(a,function(e,t){var n=e.coordDim,i=p.categoryAxisMap.get(n);i&&(null==l&&(l=t),e.ordinalMeta=i.getOrdinalMeta(),s&&(e.createInvertedIndices=!0)),null!=e.otherDims.itemName&&(d=!0)}),d||null==l||(a[l].otherDims.itemName=0),l),b=h?null:c.getSharedDataStore(v),x=yi(t,{schema:v,store:b}),w=new v8(v,t);w.setCalculationInfo(x);var C=null!=y&&function(e){if(e.sourceFormat===ct)return!nR(a1(function(e){for(var t=0;t<e.length&&null==e[t];)t++;return e[t]}(e.data||[])))}(u)?function(e,t,n,i){return i===y?n:this.defaultDimValueGetter(e,t,n,i)}:null;return w.hasItemOption=!1,w.initData(h?u:b,null,C),w};var ys=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e){return ya(null,this,{useEncodeDefaulter:!0})},t.prototype.getLegendIcon=function(e){var t=new av,n=g_("line",0,e.itemHeight/2,e.itemWidth,0,e.lineStyle.stroke,!1);t.add(n),n.setStyle(e.lineStyle);var i=this.getData().getVisual("symbol"),r=this.getData().getVisual("symbolRotate"),o="none"===i?"circle":i,a=.8*e.itemHeight,s=g_(o,(e.itemWidth-a)/2,(e.itemHeight-a)/2,a,a,e.itemStyle.fill);return t.add(s),s.setStyle(e.itemStyle),s.rotation=("inherit"===e.iconRotate?r:e.iconRotate||0)*Math.PI/180,s.setOrigin([e.itemWidth/2,e.itemHeight/2]),o.indexOf("empty")>-1&&(s.style.stroke=s.style.fill,s.style.fill="#fff",s.style.lineWidth=2),t},t.type="series.line",t.dependencies=["grid","polar"],t.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},t}(h1);function yl(e,t){var n=e.mapDimensionsAll("defaultedLabel"),i=n.length;if(1===i){var r=hi(e,t,n[0]);return null!=r?r+"":null}if(i){for(var o=[],a=0;a<n.length;a++)o.push(hi(e,t,n[a]));return o.join(" ")}}function yd(e,t){var n=e.mapDimensionsAll("defaultedLabel");if(!nR(t))return t+"";for(var i=[],r=0;r<n.length;r++){var o=e.getDimensionIndex(n[r]);o>=0&&i.push(t[o])}return i.join(" ")}var yu=function(e){function t(t,n,i,r){var o=e.call(this)||this;return o.updateData(t,n,i,r),o}return(0,tQ.__extends)(t,e),t.prototype._createSymbol=function(e,t,n,i,r){this.removeAll();var o=g_(e,-1,-1,2,2,null,r);o.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),o.drift=yc,this._symbolType=e,this.add(o)},t.prototype.stopSymbolAnimation=function(e){this.childAt(0).stopAnimation(null,e)},t.prototype.getSymbolType=function(){return this._symbolType},t.prototype.getSymbolPath=function(){return this.childAt(0)},t.prototype.highlight=function(){dv(this.childAt(0))},t.prototype.downplay=function(){dy(this.childAt(0))},t.prototype.setZ=function(e,t){var n=this.childAt(0);n.zlevel=e,n.z=t},t.prototype.setDraggable=function(e,t){var n=this.childAt(0);n.draggable=e,n.cursor=!t&&e?"move":n.cursor},t.prototype.updateData=function(e,n,i,r){this.silent=!1;var o=e.getItemVisual(n,"symbol")||"circle",a=e.hostModel,s=t.getSymbolSize(e,n),l=o!==this._symbolType,d=r&&r.disableAnimation;if(l){var u=e.getItemVisual(n,"symbolKeepAspect");this._createSymbol(o,e,n,s,u)}else{var c=this.childAt(0);c.silent=!1;var h={scaleX:s[0]/2,scaleY:s[1]/2};d?c.attr(h):dB(c,h,a,n),dW(c)}if(this._updateCommon(e,n,s,i,r),l){var c=this.childAt(0);if(!d){var h={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:c.style.opacity}};c.scaleX=c.scaleY=0,c.style.opacity=0,dz(c,h,a,n)}}d&&this.childAt(0).stopAnimation("leave")},t.prototype._updateCommon=function(e,t,n,i,r){var o,a,s,l,d,u,c,h,p,f=this.childAt(0),g=e.hostModel;if(i&&(o=i.emphasisItemStyle,a=i.blurItemStyle,s=i.selectItemStyle,l=i.focus,d=i.blurScope,c=i.labelStatesModels,h=i.hoverScale,p=i.cursorStyle,u=i.emphasisDisabled),!i||e.hasItemOption){var m=i&&i.itemModel?i.itemModel:e.getItemModel(t),v=m.getModel("emphasis");o=v.getModel("itemStyle").getItemStyle(),s=m.getModel(["select","itemStyle"]).getItemStyle(),a=m.getModel(["blur","itemStyle"]).getItemStyle(),l=v.get("focus"),d=v.get("blurScope"),u=v.get("disabled"),c=dY(m),h=v.getShallow("scale"),p=m.getShallow("cursor")}var y=e.getItemVisual(t,"symbolRotate");f.attr("rotation",(y||0)*Math.PI/180||0);var b=gM(e.getItemVisual(t,"symbolOffset"),n);b&&(f.x=b[0],f.y=b[1]),p&&f.attr("cursor",p);var x=e.getItemVisual(t,"style"),w=x.fill;if(f instanceof lI){var C=f.style;f.useStyle(nf({image:C.image,x:C.x,y:C.y,width:C.width,height:C.height},x))}else f.__isEmptyBrush?f.useStyle(nf({},x)):f.useStyle(x),f.style.decal=null,f.setColor(w,r&&r.symbolInnerColor),f.style.strokeNoScale=!0;var S=e.getItemVisual(t,"liftZ"),_=this._z2;null!=S?null==_&&(this._z2=f.z2,f.z2+=S):null!=_&&(f.z2=_,this._z2=null);var k=r&&r.useNameLabel;dK(f,c,{labelFetcher:g,labelDataIndex:t,defaultText:function(t){return k?e.getName(t):yl(e,t)},inheritColor:w,defaultOpacity:x.opacity}),this._sizeX=n[0]/2,this._sizeY=n[1]/2;var M=f.ensureState("emphasis");M.style=o,f.ensureState("select").style=s,f.ensureState("blur").style=a;var T=null==h||!0===h?Math.max(1.1,3/this._sizeY):isFinite(h)&&h>0?+h:1;M.scaleX=this._sizeX*T,M.scaleY=this._sizeY*T,this.setSymbolScale(1),dM(this,l,d,u)},t.prototype.setSymbolScale=function(e){this.scaleX=this.scaleY=e},t.prototype.fadeOut=function(e,t,n){var i=this.childAt(0),r=lQ(this).dataIndex,o=n&&n.animation;if(this.silent=i.silent=!0,n&&n.fadeLabel){var a=i.getTextContent();a&&dV(a,{style:{opacity:0}
422},t,{dataIndex:r,removeOpt:o,cb:function(){i.removeTextContent()}})}else i.removeTextContent();dV(i,{style:{opacity:0},scaleX:0,scaleY:0},t,{dataIndex:r,cb:e,removeOpt:o})},t.getSymbolSize=function(e,t){return gk(e.getItemVisual(t,"symbolSize"))},t}(av);function yc(e,t){this.parent.drift(e,t)}function yh(e,t,n,i){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(i.isIgnore&&i.isIgnore(n))&&!(i.clipShape&&!i.clipShape.contain(t[0],t[1]))&&"none"!==e.getItemVisual(n,"symbol")}function yp(e){return null==e||nL(e)||(e={isIgnore:e}),e||{}}function yf(e){var t=e.hostModel,n=t.getModel("emphasis");return{emphasisItemStyle:n.getModel("itemStyle").getItemStyle(),blurItemStyle:t.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:t.getModel(["select","itemStyle"]).getItemStyle(),focus:n.get("focus"),blurScope:n.get("blurScope"),emphasisDisabled:n.get("disabled"),hoverScale:n.get("scale"),labelStatesModels:dY(t),cursorStyle:t.get("cursor")}}var yg=function(){function e(e){this.group=new av,this._SymbolCtor=e||yu}return e.prototype.updateData=function(e,t){this._progressiveEls=null,t=yp(t);var n=this.group,i=e.hostModel,r=this._data,o=this._SymbolCtor,a=t.disableAnimation,s=yf(e),l={disableAnimation:a},d=t.getSymbolPoint||function(t){return e.getItemLayout(t)};r||n.removeAll(),e.diff(r).add(function(i){var r=d(i);if(yh(e,r,i,t)){var a=new o(e,i,s,l);a.setPosition(r),e.setItemGraphicEl(i,a),n.add(a)}}).update(function(u,c){var h=r.getItemGraphicEl(c),p=d(u);if(!yh(e,p,u,t))return void n.remove(h);var f=e.getItemVisual(u,"symbol")||"circle",g=h&&h.getSymbolType&&h.getSymbolType();if(!h||g&&g!==f)n.remove(h),(h=new o(e,u,s,l)).setPosition(p);else{h.updateData(e,u,s,l);var m={x:p[0],y:p[1]};a?h.attr(m):dB(h,m,i)}n.add(h),e.setItemGraphicEl(u,h)}).remove(function(e){var t=r.getItemGraphicEl(e);t&&t.fadeOut(function(){n.remove(t)},i)}).execute(),this._getSymbolPoint=d,this._data=e},e.prototype.updateLayout=function(){var e=this,t=this._data;t&&t.eachItemGraphicEl(function(t,n){var i=e._getSymbolPoint(n);t.setPosition(i),t.markRedraw()})},e.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=yf(e),this._data=null,this.group.removeAll()},e.prototype.incrementalUpdate=function(e,t,n){function i(e){e.isGroup||(e.incremental=!0,e.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[],n=yp(n);for(var r=e.start;r<e.end;r++){var o=t.getItemLayout(r);if(yh(t,o,r,n)){var a=new this._SymbolCtor(t,r,this._seriesScope);a.traverse(i),a.setPosition(o),this.group.add(a),t.setItemGraphicEl(r,a),this._progressiveEls.push(a)}}},e.prototype.eachRendered=function(e){fT(this._progressiveEls||this.group,e)},e.prototype.remove=function(e){var t=this.group,n=this._data;n&&e?n.eachItemGraphicEl(function(e){e.fadeOut(function(){t.remove(e)},n.hostModel)}):t.removeAll()},e}();function ym(e,t,n){var i,r,o,a,s=e.getBaseAxis(),l=e.getOtherAxis(s),d=(i=l,r=n,o=0,a=i.scale.getExtent(),"start"===r?o=a[0]:"end"===r?o=a[1]:nE(r)&&!isNaN(r)?o=r:a[0]>0?o=a[0]:a[1]<0&&(o=a[1]),o),u=s.dim,c=l.dim,h=t.mapDimension(c),p=t.mapDimension(u),f=+("x"===c||"radius"===c),g=nC(e.dimensions,function(e){return t.mapDimension(e)}),m=!1,v=t.getCalculationInfo("stackResultDimension");return yr(t,g[0])&&(m=!0,g[0]=v),yr(t,g[1])&&(m=!0,g[1]=v),{dataDimsForPoint:g,valueStart:d,valueAxisDim:c,baseAxisDim:u,stacked:!!m,valueDim:h,baseDim:p,baseDataOffset:f,stackedOverDimension:t.getCalculationInfo("stackedOverDimension")}}function yv(e,t,n,i){var r=NaN;e.stacked&&(r=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(r)&&(r=e.valueStart);var o=e.baseDataOffset,a=[];return a[o]=n.get(e.baseDim,i),a[1-o]=r,t.dataToPoint(a)}var yy="u">typeof Float32Array,yb=yy?Float32Array:Array;function yx(e){return nR(e)?yy?new Float32Array(e):e:new yb(e)}var yw=Math.min,yC=Math.max;function yS(e,t){return isNaN(e)||isNaN(t)}function y_(e,t,n,i,r,o,a,s,l){for(var d,u,c,h,p,f,g=n,m=0;m<i;m++){var v=t[2*g],y=t[2*g+1];if(g>=r||g<0)break;if(yS(v,y)){if(l){g+=o;continue}break}if(g===n)e[o>0?"moveTo":"lineTo"](v,y),c=v,h=y;else{var b=v-d,x=y-u;if(b*b+x*x<.5){g+=o;continue}if(a>0){for(var w=g+o,C=t[2*w],S=t[2*w+1];C===v&&S===y&&m<i;)m++,w+=o,g+=o,C=t[2*w],S=t[2*w+1],v=t[2*g],y=t[2*g+1],b=v-d,x=y-u;var _=m+1;if(l)for(;yS(C,S)&&_<i;)_++,w+=o,C=t[2*w],S=t[2*w+1];var k=.5,M=0,T=0,D=void 0,R=void 0;if(_>=i||yS(C,S))p=v,f=y;else{M=C-d,T=S-u;var I=v-d,A=C-v,P=y-u,E=S-y,L=void 0,F=void 0;if("x"===s){L=Math.abs(I),F=Math.abs(A);var O=M>0?1:-1;p=v-O*L*a,f=y,D=v+O*F*a,R=y}else if("y"===s){L=Math.abs(P),F=Math.abs(E);var N=T>0?1:-1;p=v,f=y-N*L*a,D=v,R=y+N*F*a}else L=Math.sqrt(I*I+P*P),p=v-M*a*(1-(k=(F=Math.sqrt(A*A+E*E))/(F+L))),f=y-T*a*(1-k),D=v+M*a*k,R=y+T*a*k,D=yw(D,yC(C,v)),R=yw(R,yC(S,y)),D=yC(D,yw(C,v)),R=yC(R,yw(S,y)),M=D-v,T=R-y,p=v-M*L/F,f=y-T*L/F,p=yw(p,yC(d,v)),f=yw(f,yC(u,y)),p=yC(p,yw(d,v)),f=yC(f,yw(u,y)),M=v-p,T=y-f,D=v+M*F/L,R=y+T*F/L}
422e.bezierCurveTo(c,h,p,f,v,y),c=D,h=R}else e.lineTo(v,y)}d=v,u=y,g+=o}return m}var yk=function(){this.smooth=0,this.smoothConstraint=!0},yM=function(e){function t(t){var n=e.call(this,t)||this;return n.type="ec-polyline",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new yk},t.prototype.buildPath=function(e,t){var n=t.points,i=0,r=n.length/2;if(t.connectNulls){for(;r>0&&yS(n[2*r-2],n[2*r-1]);r--);for(;i<r&&yS(n[2*i],n[2*i+1]);i++);}for(;i<r;)i+=y_(e,n,i,r,r,1,t.smooth,t.smoothMonotone,t.connectNulls)+1},t.prototype.getPointOn=function(e,t){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n,i,r=this.path.data,o=lu.CMD,a="x"===t,s=[],l=0;l<r.length;){var d=r[l++],u=void 0,c=void 0,h=void 0,p=void 0,f=void 0,g=void 0,m=void 0;switch(d){case o.M:n=r[l++],i=r[l++];break;case o.L:if(u=r[l++],c=r[l++],(m=a?(e-n)/(u-n):(e-i)/(c-i))<=1&&m>=0){var v=a?(c-i)*m+i:(u-n)*m+n;return a?[e,v]:[v,e]}n=u,i=c;break;case o.C:u=r[l++],c=r[l++],h=r[l++],p=r[l++],f=r[l++],g=r[l++];var y=a?rP(n,u,h,f,e,s):rP(i,c,p,g,e,s);if(y>0)for(var b=0;b<y;b++){var x=s[b];if(x<=1&&x>=0){var v=a?rI(i,c,p,g,x):rI(n,u,h,f,x);return a?[e,v]:[v,e]}}n=f,i=g}}},t}(lk),yT=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t}(yk),yD=function(e){function t(t){var n=e.call(this,t)||this;return n.type="ec-polygon",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new yT},t.prototype.buildPath=function(e,t){var n=t.points,i=t.stackedOnPoints,r=0,o=n.length/2,a=t.smoothMonotone;if(t.connectNulls){for(;o>0&&yS(n[2*o-2],n[2*o-1]);o--);for(;r<o&&yS(n[2*r],n[2*r+1]);r++);}for(;r<o;){var s=y_(e,n,r,o,o,1,t.smooth,a,t.connectNulls);y_(e,i,r+s-1,s,o,-1,t.stackedOnSmooth,a,t.connectNulls),r+=s+1,e.closePath()}},t}(lk);function yR(e,t,n,i,r){var o=e.getArea(),a=o.x,s=o.y,l=o.width,d=o.height,u=n.get(["lineStyle","width"])||0;a-=u/2,s-=u/2,l+=u,d+=u,l=Math.ceil(l),a!==Math.floor(a)&&(a=Math.floor(a),l++);var c=new lN({shape:{x:a,y:s,width:l,height:d}});if(t){var h=e.getBaseAxis(),p=h.isHorizontal(),f=h.inverse;p?(f&&(c.shape.x+=l),c.shape.width=0):(f||(c.shape.y+=d),c.shape.height=0);var g=nI(r)?function(e){r(e,c)}:null;dz(c,{shape:{width:l,height:d,x:a,y:s}},n,null,i,g)}return c}function yI(e,t,n){var i=e.getArea(),r=aI(i.r0,1),o=aI(i.r,1),a=new pO({shape:{cx:aI(e.cx,1),cy:aI(e.cy,1),r0:r,r:o,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}});return t&&("angle"===e.getBaseAxis().dim?a.shape.endAngle=i.startAngle:a.shape.r=r,dz(a,{shape:{endAngle:i.endAngle,r:o}},n)),a}function yA(e,t,n,i,r){if(e){if("polar"===e.type)return yI(e,t,n);else if("cartesian2d"===e.type)return yR(e,t,n,i,r)}return null}function yP(e,t){return e.type===t}function yE(e,t){if(e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return;return!0}}function yL(e){for(var t=1/0,n=1/0,i=-1/0,r=-1/0,o=0;o<e.length;){var a=e[o++],s=e[o++];isNaN(a)||(t=Math.min(a,t),i=Math.max(a,i)),isNaN(s)||(n=Math.min(s,n),r=Math.max(s,r))}return[[t,n],[i,r]]}function yF(e,t){var n=yL(e),i=n[0],r=n[1],o=yL(t),a=o[0],s=o[1];return Math.max(Math.abs(i[0]-a[0]),Math.abs(i[1]-a[1]),Math.abs(r[0]-s[0]),Math.abs(r[1]-s[1]))}function yO(e){return nE(e)?e:.5*!!e}function yN(e,t,n,i,r){var o=n.getBaseAxis(),a=+("x"!==o.dim&&"radius"!==o.dim),s=[],l=0,d=[],u=[],c=[],h=[];if(r){for(l=0;l<e.length;l+=2){var p=t||e;isNaN(p[l])||isNaN(p[l+1])||h.push(e[l],e[l+1])}e=h}for(l=0;l<e.length-2;l+=2)switch(c[0]=e[l+2],c[1]=e[l+3],u[0]=e[l],u[1]=e[l+1],s.push(u[0],u[1]),i){case"end":d[a]=c[a],d[1-a]=u[1-a],s.push(d[0],d[1]);break;case"middle":var f=(u[a]+c[a])/2,g=[];d[a]=g[a]=f,d[1-a]=u[1-a],g[1-a]=c[1-a],s.push(d[0],d[1]),s.push(g[0],g[1]);break;default:d[a]=u[a],d[1-a]=c[1-a],s.push(d[0],d[1])}return s.push(e[l++],e[l++]),s}function yB(e,t){return[e[2*t],e[2*t+1]]}function yz(e){if(e.get(["endLabel","show"]))return!0;for(var t=0;t<l4.length;t++)if(e.get([l4[t],"endLabel","show"]))return!0;return!1}function yj(e,t,n,i){if(!yP(t,"cartesian2d"))return yI(t,n,i);var r=i.getModel("endLabel"),o=r.get("valueAnimation"),a=i.getData(),s={lastFrameIndex:0},l=yz(i)?function(n,i){e._endLabelOnDuring(n,i,a,s,o,r,t)}:null,d=t.getBaseAxis().isHorizontal(),u=yR(t,n,i,function(){var t=e._endLabel;t&&n&&null!=s.originalX&&t.attr({x:s.originalX,y:s.originalY})},l);if(!i.get("clip",!0)){var c=u.shape,h=Math.max(c.width,c.height);
422d?(c.y-=h,c.height+=2*h):(c.x-=h,c.width+=2*h)}return l&&l(1,u),u}var yV=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.init=function(){var e=new av,t=new yg;this.group.add(t.group),this._symbolDraw=t,this._lineGroup=e,this._changePolyState=nT(this._changePolyState,this)},t.prototype.render=function(e,t,n){var i,r=e.coordinateSystem,o=this.group,a=e.getData(),s=e.getModel("lineStyle"),l=e.getModel("areaStyle"),d=a.getLayout("points")||[],u="polar"===r.type,c=this._coordSys,h=this._symbolDraw,p=this._polyline,f=this._polygon,g=this._lineGroup,m=!t.ssr&&e.get("animation"),v=!l.isEmpty(),y=l.get("origin"),b=ym(r,a,y),x=v&&function(e,t,n){if(!n.valueDim)return[];for(var i=t.count(),r=yx(2*i),o=0;o<i;o++){var a=yv(n,e,t,o);r[2*o]=a[0],r[2*o+1]=a[1]}return r}(r,a,b),w=e.get("showSymbol"),C=e.get("connectNulls"),S=w&&!u&&function(e,t,n){var i=e.get("showAllSymbol"),r="auto"===i;if(!i||r){var o=n.getAxesByScale("ordinal")[0];if(o&&!(r&&function(e,t){var n=e.getExtent(),i=Math.abs(n[1]-n[0])/e.scale.count();isNaN(i)&&(i=0);for(var r=t.count(),o=Math.max(1,Math.round(r/5)),a=0;a<r;a+=o)if(1.5*yu.getSymbolSize(t,a)[+!!e.isHorizontal()]>i)return!1;return!0}(o,t))){var a=t.mapDimension(o.dim),s={};return nw(o.getViewLabels(),function(e){s[o.scale.getRawOrdinalNumber(e.tickValue)]=1}),function(e){return!s.hasOwnProperty(t.get(a,e))}}}}(e,a,r),_=this._data;_&&_.eachItemGraphicEl(function(e,t){e.__temp&&(o.remove(e),_.setItemGraphicEl(t,null))}),w||h.remove(),o.add(g);var k=!u&&e.get("step");r&&r.getArea&&e.get("clip",!0)&&(null!=(i=r.getArea()).width?(i.x-=.1,i.y-=.1,i.width+=.2,i.height+=.2):i.r0&&(i.r0-=.5,i.r+=.5)),this._clipShapeForSymbol=i;var M=function(e,t,n){var i,r,o=e.getVisual("visualMeta");if(o&&o.length&&e.count()){if("cartesian2d"!==t.type)return;for(var a=o.length-1;a>=0;a--){var s=e.getDimensionInfo(o[a].dimension);if("x"===(i=s&&s.coordDim)||"y"===i){r=o[a];break}}if(!r)return;var l=t.getAxis(i),d=nC(r.stops,function(e){return{coord:l.toGlobalCoord(l.dataToCoord(e.value)),color:e.color}}),u=d.length,c=r.outerColors.slice();u&&d[0].coord>d[u-1].coord&&(d.reverse(),c.reverse());var h=function(e,t){var n,i,r=[],o=e.length;function a(e,t,n){var i=e.coord,r=r9((n-i)/(t.coord-i),[e.color,t.color]);return{coord:n,color:r}}for(var s=0;s<o;s++){var l=e[s],d=l.coord;if(d<0)n=l;else if(d>t){i?r.push(a(i,l,t)):n&&r.push(a(n,l,0),a(n,l,t));break}else n&&(r.push(a(n,l,0)),n=null),r.push(l),i=l}return r}(d,"x"===i?n.getWidth():n.getHeight()),p=h.length;if(!p&&u)return d[0].coord<0?c[1]?c[1]:d[u-1].color:c[0]?c[0]:d[0].color;var f=h[0].coord-10,g=h[p-1].coord+10,m=g-f;if(m<.001)return"transparent";nw(h,function(e){e.offset=(e.coord-f)/m}),h.push({offset:p?h[p-1].offset:.5,color:c[1]||"transparent"}),h.unshift({offset:p?h[0].offset:.5,color:c[0]||"transparent"});var v=new p1(0,0,0,0,h,!0);return v[i]=f,v[i+"2"]=g,v}}(a,r,n)||a.getVisual("style")[a.getVisual("drawType")];if(p&&c.type===r.type&&k===this._step){v&&!f?f=this._newPolygon(d,x):f&&!v&&(g.remove(f),f=this._polygon=null),u||this._initOrUpdateEndLabel(e,r,uU(M));var T=g.getClipPath();T?dz(T,{shape:yj(this,r,!1,e).shape},e):g.setClipPath(yj(this,r,!0,e)),w&&h.updateData(a,{isIgnore:S,clipShape:i,disableAnimation:!0,getSymbolPoint:function(e){return[d[2*e],d[2*e+1]]}}),yE(this._stackedOnPoints,x)&&yE(this._points,d)||(m?this._doUpdateAnimation(a,x,r,n,k,y,C):(k&&(x&&(x=yN(x,d,r,k,C)),d=yN(d,null,r,k,C)),p.setShape({points:d}),f&&f.setShape({points:d,stackedOnPoints:x})))}else w&&h.updateData(a,{isIgnore:S,clipShape:i,disableAnimation:!0,getSymbolPoint:function(e){return[d[2*e],d[2*e+1]]}}),m&&this._initSymbolLabelAnimation(a,r,i),k&&(x&&(x=yN(x,d,r,k,C)),d=yN(d,null,r,k,C)),p=this._newPolyline(d),v?f=this._newPolygon(d,x):f&&(g.remove(f),f=this._polygon=null),u||this._initOrUpdateEndLabel(e,r,uU(M)),g.setClipPath(yj(this,r,!0,e));var D=e.getModel("emphasis"),R=D.get("focus"),I=D.get("blurScope"),A=D.get("disabled");p.useStyle(ng(s.getLineStyle(),{fill:"none",stroke:M,lineJoin:"bevel"})),dI(p,e,"lineStyle"),p.style.lineWidth>
4220&&"bolder"===e.get(["emphasis","lineStyle","width"])&&(p.getState("emphasis").style.lineWidth=+p.style.lineWidth+1),lQ(p).seriesIndex=e.seriesIndex,dM(p,R,I,A);var P=yO(e.get("smooth")),E=e.get("smoothMonotone");if(p.setShape({smooth:P,smoothMonotone:E,connectNulls:C}),f){var L=a.getCalculationInfo("stackedOnSeries"),F=0;f.useStyle(ng(l.getAreaStyle(),{fill:M,opacity:.7,lineJoin:"bevel",decal:a.getVisual("style").decal})),L&&(F=yO(L.get("smooth"))),f.setShape({smooth:P,stackedOnSmooth:F,smoothMonotone:E,connectNulls:C}),dI(f,e,"areaStyle"),lQ(f).seriesIndex=e.seriesIndex,dM(f,R,I,A)}var O=this._changePolyState;a.eachItemGraphicEl(function(e){e&&(e.onHoverStateChange=O)}),this._polyline.onHoverStateChange=O,this._data=a,this._coordSys=r,this._stackedOnPoints=x,this._points=d,this._step=k,this._valueOrigin=y,e.get("triggerLineEvent")&&(this.packEventData(e,p),f&&this.packEventData(e,f))},t.prototype.packEventData=function(e,t){lQ(t).eventData={componentType:"series",componentSubType:"line",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"line"}},t.prototype.highlight=function(e,t,n,i){var r=e.getData(),o=a7(r,i);if(this._changePolyState("emphasis"),o instanceof Array||null==o||!(o>=0))fI.prototype.highlight.call(this,e,t,n,i);else{var a=r.getLayout("points"),s=r.getItemGraphicEl(o);if(!s){var l=a[2*o],d=a[2*o+1];if(isNaN(l)||isNaN(d)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(l,d))return;var u=e.get("zlevel")||0,c=e.get("z")||0;(s=new yu(r,o)).x=l,s.y=d,s.setZ(u,c);var h=s.getSymbolPath().getTextContent();h&&(h.zlevel=u,h.z=c,h.z2=this._polyline.z2+1),s.__temp=!0,r.setItemGraphicEl(o,s),s.stopSymbolAnimation(!0),this.group.add(s)}s.highlight()}},t.prototype.downplay=function(e,t,n,i){var r=e.getData(),o=a7(r,i);if(this._changePolyState("normal"),null!=o&&o>=0){var a=r.getItemGraphicEl(o);a&&(a.__temp?(r.setItemGraphicEl(o,null),this.group.remove(a)):a.downplay())}else fI.prototype.downplay.call(this,e,t,n,i)},t.prototype._changePolyState=function(e){var t=this._polygon;dh(this._polyline,e),t&&dh(t,e)},t.prototype._newPolyline=function(e){var t=this._polyline;return t&&this._lineGroup.remove(t),t=new yM({shape:{points:e},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(t),this._polyline=t,t},t.prototype._newPolygon=function(e,t){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new yD({shape:{points:e,stackedOnPoints:t},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},t.prototype._initSymbolLabelAnimation=function(e,t,n){var i,r,o=t.getBaseAxis(),a=o.inverse;"cartesian2d"===t.type?(i=o.isHorizontal(),r=!1):"polar"===t.type&&(i="angle"===o.dim,r=!0);var s=e.hostModel,l=s.get("animationDuration");nI(l)&&(l=l(null));var d=s.get("animationDelay")||0,u=nI(d)?d(null):d;e.eachItemGraphicEl(function(e,o){if(e){var s=[e.x,e.y],c=void 0,h=void 0,p=void 0;if(n)if(r){var f=t.pointToCoord(s);i?(c=n.startAngle,h=n.endAngle,p=-f[1]/180*Math.PI):(c=n.r0,h=n.r,p=f[0])}else i?(c=n.x,h=n.x+n.width,p=e.x):(c=n.y+n.height,h=n.y,p=e.y);var g=h===c?0:(p-c)/(h-c);a&&(g=1-g);var m=nI(d)?d(o):l*g+u,v=e.getSymbolPath(),y=v.getTextContent();e.attr({scaleX:0,scaleY:0}),e.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:m}),y&&y.animateFrom({style:{opacity:0}},{duration:300,delay:m}),v.disableLabelAnimation=!0}})},t.prototype._initOrUpdateEndLabel=function(e,t,n){var i=e.getModel("endLabel");if(yz(e)){var r,o,a,s=e.getData(),l=this._polyline,d=s.getLayout("points");if(!d){l.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||((u=this._endLabel=new lj({z2:200})).ignoreClip=!0,l.setTextContent(this._endLabel),l.disableLabelAnimation=!0);var c=function(e){for(var t,n,i=e.length/2;i>0&&(t=e[2*i-2],n=e[2*i-1],isNaN(t)||isNaN(n));i--);return i-1}(d);c>=0&&(dK(l,dY(e,"endLabel"),{inheritColor:n,labelFetcher:e,labelDataIndex:c,defaultText:function(e,t,n){return null!=n?yd(s,n):yl(s,e)},enableTextSetter:!0},(o=(r=t.getBaseAxis()).isHorizontal(),a=r.inverse,{normal:{align:i.get("align")||(o?a?"right":"left":"center"),verticalAlign:i.get("verticalAlign")||(o?"middle":a?"top":"bottom")}})),l.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},t.prototype._endLabelOnDuring=function(e,t,n,i,r,o,a){var s=this._endLabel,l=this._polyline;if(s){e<1&&null==i.originalX&&(i.originalX=s.x,i.originalY=s.y);
422var d=n.getLayout("points"),u=n.hostModel,c=u.get("connectNulls"),h=o.get("precision"),p=o.get("distance")||0,f=a.getBaseAxis(),g=f.isHorizontal(),m=f.inverse,v=t.shape,y=m?g?v.x:v.y+v.height:g?v.x+v.width:v.y,b=(g?p:0)*(m?-1:1),x=(g?0:-p)*(m?-1:1),w=g?"x":"y",C=function(e,t,n){for(var i,r,o=e.length/2,a=+("x"!==n),s=0,l=-1,d=0;d<o;d++)if(!(isNaN(r=e[2*d+a])||isNaN(e[2*d+1-a]))){if(0===d){i=r;continue}if(i<=t&&r>=t||i>=t&&r<=t){l=d;break}s=d,i=r}return{range:[s,l],t:(t-i)/(r-i)}}(d,y,w),S=C.range,_=S[1]-S[0],k=void 0;if(_>=1){if(_>1&&!c){var M=yB(d,S[0]);s.attr({x:M[0]+b,y:M[1]+x}),r&&(k=u.getRawValue(S[0]))}else{var M=l.getPointOn(y,w);M&&s.attr({x:M[0]+b,y:M[1]+x});var T=u.getRawValue(S[0]),D=u.getRawValue(S[1]);r&&(k=sl(n,h,T,D,C.t))}i.lastFrameIndex=S[0]}else{var R=1===e||i.lastFrameIndex>0?S[0]:0,M=yB(d,R);r&&(k=u.getRawValue(R)),s.attr({x:M[0]+b,y:M[1]+x})}if(r){var I=d3(s);"function"==typeof I.setLabelText&&I.setLabelText(k)}}},t.prototype._doUpdateAnimation=function(e,t,n,i,r,o,a){var s=this._polyline,l=this._polygon,d=e.hostModel,u=function(e,t,n,i,r,o,a,s){for(var l,d=(l=[],t.diff(e).add(function(e){l.push({cmd:"+",idx:e})}).update(function(e,t){l.push({cmd:"=",idx:t,idx1:e})}).remove(function(e){l.push({cmd:"-",idx:e})}).execute(),l),u=[],c=[],h=[],p=[],f=[],g=[],m=[],v=ym(r,t,a),y=e.getLayout("points")||[],b=t.getLayout("points")||[],x=0;x<d.length;x++){var w=d[x],C=!0,S=void 0,_=void 0;switch(w.cmd){case"=":S=2*w.idx,_=2*w.idx1;var k=y[S],M=y[S+1],T=b[_],D=b[_+1];(isNaN(k)||isNaN(M))&&(k=T,M=D),u.push(k,M),c.push(T,D),h.push(n[S],n[S+1]),p.push(i[_],i[_+1]),m.push(t.getRawIndex(w.idx1));break;case"+":var R=w.idx,I=v.dataDimsForPoint,A=r.dataToPoint([t.get(I[0],R),t.get(I[1],R)]);_=2*R,u.push(A[0],A[1]),c.push(b[_],b[_+1]);var P=yv(v,r,t,R);h.push(P[0],P[1]),p.push(i[_],i[_+1]),m.push(t.getRawIndex(R));break;case"-":C=!1}C&&(f.push(w),g.push(g.length))}g.sort(function(e,t){return m[e]-m[t]});for(var E=u.length,L=yx(E),F=yx(E),O=yx(E),N=yx(E),B=[],x=0;x<g.length;x++){var z=g[x],j=2*x,V=2*z;L[j]=u[V],L[j+1]=u[V+1],F[j]=c[V],F[j+1]=c[V+1],O[j]=h[V],O[j+1]=h[V+1],N[j]=p[V],N[j+1]=p[V+1],B[x]=f[z]}return{current:L,next:F,stackedOnCurrent:O,stackedOnNext:N,status:B}}(this._data,e,this._stackedOnPoints,t,this._coordSys,0,this._valueOrigin,0),c=u.current,h=u.stackedOnCurrent,p=u.next,f=u.stackedOnNext;if(r&&(h=yN(u.stackedOnCurrent,u.current,n,r,a),c=yN(u.current,null,n,r,a),f=yN(u.stackedOnNext,u.next,n,r,a),p=yN(u.next,null,n,r,a)),yF(c,p)>3e3||l&&yF(h,f)>3e3){s.stopAnimation(),s.setShape({points:p}),l&&(l.stopAnimation(),l.setShape({points:p,stackedOnPoints:f}));return}s.shape.__points=u.current,s.shape.points=c;var g={shape:{points:p}};u.current!==c&&(g.shape.__points=u.next),s.stopAnimation(),dB(s,g,d),l&&(l.setShape({points:c,stackedOnPoints:h}),l.stopAnimation(),dB(l,{shape:{stackedOnPoints:f}},d),s.shape.points!==l.shape.points&&(l.shape.points=s.shape.points));for(var m=[],v=u.status,y=0;y<v.length;y++)if("="===v[y].cmd){var b=e.getItemGraphicEl(v[y].idx1);b&&m.push({el:b,ptIdx:y})}s.animators&&s.animators.length&&s.animators[0].during(function(){l&&l.dirtyShape();for(var e=s.shape.__points,t=0;t<m.length;t++){var n=m[t].el,i=2*m[t].ptIdx;n.x=e[i],n.y=e[i+1],n.markRedraw()}})},t.prototype.remove=function(e){var t=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(e,i){e.__temp&&(t.remove(e),n.setItemGraphicEl(i,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},t.type="line",t}(fI);function yH(e,t){return{seriesType:e,plan:pe(),reset:function(e){var n=e.getData(),i=e.coordinateSystem,r=e.pipelineContext,o=t||r.large;if(i){var a=nC(i.dimensions,function(e){return n.mapDimension(e)}).slice(0,2),s=a.length,l=n.getCalculationInfo("stackResultDimension");yr(n,a[0])&&(a[0]=l),yr(n,a[1])&&(a[1]=l);var d=n.getStore(),u=n.getDimensionIndex(a[0]),c=n.getDimensionIndex(a[1]);return s&&{progress:function(e,t){for(var n=e.end-e.start,r=o&&yx(n*s),a=[],l=[],h=e.start,p=0;h<e.end;h++){var f=void 0;if(1===s){var g=d.get(u,h);f=i.dataToPoint(g,null,l)}else a[0]=d.get(u,h),a[1]=d.get(c,h),f=i.dataToPoint(a,null,l);o?(r[p++]=f[0],r[p++]=f[1]):t.setItemLayout(h,f.slice())}o&&t.setLayout("points",r)}}}}}}var yG={average:function(e){for(var t=0,n=0,i=0;i<e.length;i++)!isNaN(e[i])&&(t+=e[i],n++);return 0===n?NaN:t/n},sum:function(e){for(var t=0,n=0;n<e.length;n++)t+=e[n]||0;return t},max:function(e){for(var t=-1/0,n=0;n<e.length;n++)e[n]>t&&(t=e[n]);return isFinite(t)?t:NaN},min:function(e){for(var t=1/0,n=0;n<e.length;n++)e[n]<t&&(t=e[n]);return isFinite(t)?t:NaN},nearest:function(e){return e[0]}},yW=function(e){return Math.round(e.length/2)};function y$(e){return{seriesType:e,reset:function(e,t,n){var i=e.getData(),r=e.get("sampling"),o=e.coordinateSystem,a=i.count();if(a>10&&"cartesian2d"===o.type&&r){var s=o.getBaseAxis(),l=o.getOtherAxis(s),d=s.getExtent(),u=n.getDevicePixelRatio(),c=Math.round(a/(Math.abs(d[1]-d[0])*(u||1)));if(isFinite(c)&&c>1){"lttb"===r?e.setData(i.lttbDownSample(i.mapDimension(l.dim),1/c)):"minmax"===r&&e.setData(i.minmaxDownSample(i.mapDimension(l.dim),1/c));var h=void 0;nA(r)?h=yG[r]:nI(r)&&(h=r),h&&e.setData(i.downSample(i.mapDimension(l.dim),1/c,h,yW))}}}}}var yU="__ec_stack_";function yq(e){return e.get("stack")||yU+e.seriesIndex}function yK(e){return e.dim+e.index}function yY(e,t){var n=[];return t.eachSeriesByType(e,function(e){y0(e)&&n.push(e)}),n}function yZ(e){var t=function(e){var t={};nw(e,function(e){var n=e.coordinateSystem.getBaseAxis();if("time"===n.type||"value"===n.type)for(var i=e.getData(),r=n.dim+"_"+n.index,o=i.getDimensionIndex(i.mapDimension(n.dim)),a=i.getStore(),s=0,l=a.count();s<l;++s){var d=a.get(o,s);t[r]?t[r].push(d):t[r]=[d]}});var n={};for(var i in t)if(t.hasOwnProperty(i)){var r=t[i];if(r){r.sort(function(e,t){return e-t});for(var o=null,a=1;a<r.length;++a){var s=r[a]-r[a-1];s>0&&(o=null===o?s:Math.min(o,s))}n[i]=o}}return n}(e),n=[];return nw(e,function(e){var i,r=e.coordinateSystem.getBaseAxis(),o=r.getExtent();if("category"===r.type)i=r.getBandWidth();else if("value"===r.type||"time"===r.type){var a=t[r.dim+"_"+r.index],s=Math.abs(o[1]-o[0]),l=r.scale.getExtent(),d=Math.abs(l[1]-l[0]);i=a?s/d*a:s}else{var u=e.getData();i=Math.abs(o[1]-o[0])/u.count()}var c=aR(e.get("barWidth"),i),h=aR(e.get("barMaxWidth"),i),p=aR(e.get("barMinWidth")||(y1(e)?.5:1),i),f=e.get("barGap"),g=e.get("barCategoryGap");n.push({bandWidth:i,barWidth:c,barMaxWidth:h,barMinWidth:p,barGap:f,barCategoryGap:g,axisKey:yK(r),stackId:yq(e)})}),yX(n)}function yX(e){var t={};nw(e,function(e,n){var i=e.axisKey,r=e.bandWidth,o=t[i]||{bandWidth:r,remainedWidth:r,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},a=o.stacks;t[i]=o;var s=e.stackId;!a[s]&&o.autoWidthCount++,a[s]=a[s]||{width:0,maxWidth:0};var l=e.barWidth;l&&!a[s].width&&(a[s].width=l,l=Math.min(o.remainedWidth,l),o.remainedWidth-=l);var d=e.barMaxWidth;d&&(a[s].maxWidth=d);var u=e.barMinWidth;u&&(a[s].minWidth=u);var c=e.barGap;null!=c&&(o.gap=c);var h=e.barCategoryGap;
422null!=h&&(o.categoryGap=h)});var n={};return nw(t,function(e,t){n[t]={};var i,r=e.stacks,o=e.bandWidth,a=e.categoryGap;null==a&&(a=Math.max(35-4*nM(r).length,15)+"%");var s=aR(a,o),l=aR(e.gap,1),d=e.remainedWidth,u=e.autoWidthCount,c=(d-s)/(u+(u-1)*l);c=Math.max(c,0),nw(r,function(e){var t=e.maxWidth,n=e.minWidth;if(e.width){var i=e.width;t&&(i=Math.min(i,t)),n&&(i=Math.max(i,n)),e.width=i,d-=i+l*i,u--}else{var i=c;t&&t<i&&(i=Math.min(t,d)),n&&n>i&&(i=n),i!==c&&(e.width=i,d-=i+l*i,u--)}}),c=Math.max(c=(d-s)/(u+(u-1)*l),0);var h=0;nw(r,function(e,t){e.width||(e.width=c),i=e,h+=e.width*(1+l)}),i&&(h-=i.width*l);var p=-h/2;nw(r,function(e,i){n[t][i]=n[t][i]||{bandWidth:o,offset:p,width:e.width},p+=e.width*(1+l)})}),n}function yJ(e,t){var n=yY(e,t),i=yZ(n);nw(n,function(e){var t=e.getData(),n=e.coordinateSystem.getBaseAxis(),r=yq(e),o=i[yK(n)][r],a=o.offset,s=o.width;t.setLayout({bandWidth:o.bandWidth,offset:a,size:s})})}function yQ(e){return{seriesType:e,plan:pe(),reset:function(e){if(y0(e)){var t,n,i=e.getData(),r=e.coordinateSystem,o=r.getBaseAxis(),a=r.getOtherAxis(o),s=i.getDimensionIndex(i.mapDimension(a.dim)),l=i.getDimensionIndex(i.mapDimension(o.dim)),d=e.get("showBackground",!0),u=i.mapDimension(a.dim),c=i.getCalculationInfo("stackResultDimension"),h=yr(i,u)&&!!i.getCalculationInfo("stackedOnSeries"),p=a.isHorizontal(),f=((n=(t=a).model.get("startValue"))||(n=0),t.toGlobalCoord(t.dataToCoord("log"===t.type?n>0?n:1:n))),g=y1(e),m=e.get("barMinHeight")||0,v=c&&i.getDimensionIndex(c),y=i.getLayout("size"),b=i.getLayout("offset");return{progress:function(e,t){for(var n,i=e.count,o=g&&yx(3*i),a=g&&d&&yx(3*i),u=g&&yx(i),c=r.master.getRect(),x=p?c.width:c.height,w=t.getStore(),C=0;null!=(n=e.next());){var S=w.get(h?v:s,n),_=w.get(l,n),k=f,M=void 0;h&&(M=S-w.get(s,n));var T=void 0,D=void 0,R=void 0,I=void 0;if(p){var A=r.dataToPoint([S,_]);if(h){var P=r.dataToPoint([M,_]);k=P[0]}T=k,D=A[1]+b,R=A[0]-k,I=y,Math.abs(R)<m&&(R=(R<0?-1:1)*m)}else{var A=r.dataToPoint([_,S]);if(h){var P=r.dataToPoint([_,M]);k=P[1]}T=A[0]+b,D=k,R=y,Math.abs(I=A[1]-k)<m&&(I=(I<=0?-1:1)*m)}g?(o[C]=T,o[C+1]=D,o[C+2]=p?R:I,a&&(a[C]=p?c.x:T,a[C+1]=p?D:c.y,a[C+2]=x),u[n]=n):t.setItemLayout(n,{x:T,y:D,width:R,height:I}),C+=3}g&&t.setLayout({largePoints:o,largeDataIndices:u,largeBackgroundPoints:a,valueAxisHorizontal:p})}}}}}}function y0(e){return e.coordinateSystem&&"cartesian2d"===e.coordinateSystem.type}function y1(e){return e.pipelineContext&&e.pipelineContext.large}var y2=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){return ya(null,this,{useEncodeDefaulter:!0})},t.prototype.getMarkerPosition=function(e,t,n){var i=this.coordinateSystem;if(i&&i.clampData){var r=i.clampData(e),o=i.dataToPoint(r);if(n)nw(i.getAxes(),function(e,n){if("category"===e.type&&null!=t){var i=e.getTicksCoords(),a=e.getTickModel().get("alignWithLabel"),s=r[n],l="x1"===t[n]||"y1"===t[n];if(l&&!a&&(s+=1),!(i.length<2)){if(2===i.length){o[n]=e.toGlobalCoord(e.getExtent()[+!!l]);return}for(var d=void 0,u=void 0,c=1,h=0;h<i.length;h++){var p=i[h].coord,f=h===i.length-1?i[h-1].tickValue+c:i[h].tickValue;if(f===s){u=p;break}if(f<s)d=p;else if(null!=d&&f>s){u=(p+d)/2;break}1===h&&(c=f-i[0].tickValue)}null==u&&(d?d&&(u=i[i.length-1].coord):u=i[0].coord),o[n]=e.toGlobalCoord(u)}}});else{var a=this.getData(),s=a.getLayout("offset"),l=a.getLayout("size"),d=+!i.getBaseAxis().isHorizontal();o[d]+=s+l/2}return o}return[NaN,NaN]},t.type="series.__base_bar__",t.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},t}(h1);h1.registerClass(y2);var y3=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(){return ya(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},t.prototype.getProgressive=function(){return!!this.get("large")&&this.get("progressive")},t.prototype.getProgressiveThreshold=function(){var e=this.get("progressiveThreshold"),t=this.get("largeThreshold");return t>e&&(e=t),e},t.prototype.brushSelector=function(e,t,n){return n.rect(t.getItemLayout(e))},t.type="series.bar",t.dependencies=["grid","polar"],t.defaultOption=ud(y2.defaultOption,{clip:!0,roundCap:!1,showBackgroun
422d:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),t}(y2),y5=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},y4=function(e){function t(t){var n=e.call(this,t)||this;return n.type="sausage",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new y5},t.prototype.buildPath=function(e,t){var n=t.cx,i=t.cy,r=Math.max(t.r0||0,0),o=Math.max(t.r,0),a=(o-r)*.5,s=r+a,l=t.startAngle,d=t.endAngle,u=t.clockwise,c=2*Math.PI,h=u?d-l<c:l-d<c;h||(l=d-(u?c:-c));var p=Math.cos(l),f=Math.sin(l),g=Math.cos(d),m=Math.sin(d);h?(e.moveTo(p*r+n,f*r+i),e.arc(p*s+n,f*s+i,a,-Math.PI+l,l,!u)):e.moveTo(p*o+n,f*o+i),e.arc(n,i,o,l,d,!u),e.arc(g*s+n,m*s+i,a,d-2*Math.PI,d-Math.PI,!u),0!==r&&e.arc(n,i,r,d,l,u)},t}(lk);function y6(e,t,n){return t*Math.sin(e)*(n?-1:1)}function y8(e,t,n){return t*Math.cos(e)*(n?1:-1)}function y7(e,t,n){var i=e.get("borderRadius");if(null==i)return n?{cornerRadius:0}:null;nR(i)||(i=[i,i,i,i]);var r=Math.abs(t.r||0-t.r0||0);return{cornerRadius:nC(i,function(e){return as(e,r)})}}var y9=Math.max,be=Math.min,bt=function(e){function t(){var n=e.call(this)||this;return n.type=t.type,n._isFirstFrame=!0,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){this._model=e,this._removeOnRenderedListener(n),this._updateDrawMode(e);var r=e.get("coordinateSystem");("cartesian2d"===r||"polar"===r)&&(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(e,t,n):this._renderNormal(e,t,n,i))},t.prototype.incrementalPrepareRender=function(e){this._clear(),this._updateDrawMode(e),this._updateLargeClip(e)},t.prototype.incrementalRender=function(e,t){this._progressiveEls=[],this._incrementalRenderLarge(e,t)},t.prototype.eachRendered=function(e){fT(this._progressiveEls||this.group,e)},t.prototype._updateDrawMode=function(e){var t=e.pipelineContext.large;(null==this._isLargeDraw||t!==this._isLargeDraw)&&(this._isLargeDraw=t,this._clear())},t.prototype._renderNormal=function(e,t,n,i){var r,o=this.group,a=e.getData(),s=this._data,l=e.coordinateSystem,d=l.getBaseAxis();"cartesian2d"===l.type?r=d.isHorizontal():"polar"===l.type&&(r="angle"===d.dim);var u=e.isAnimationEnabled()?e:null,c=function(e,t){var n=e.get("realtimeSort",!0),i=t.getBaseAxis();if(n&&"category"===i.type&&"cartesian2d"===t.type)return{baseAxis:i,otherAxis:t.getOtherAxis(i)}}(e,l);c&&this._enableRealtimeSort(c,a,n);var h=e.get("clip",!0)||c,p=function(e,t){var n=e.getArea&&e.getArea();if(yP(e,"cartesian2d")){var i=e.getBaseAxis();if("category"!==i.type||!i.onBand){var r=t.getLayout("bandWidth");i.isHorizontal()?(n.x-=r,n.width+=2*r):(n.y-=r,n.height+=2*r)}}return n}(l,a);o.removeClipPath();var f=e.get("roundCap",!0),g=e.get("showBackground",!0),m=e.getModel("backgroundStyle"),v=m.get("borderRadius")||0,y=[],b=this._backgroundEls,x=i&&i.isInitSort,w=i&&"changeAxisOrder"===i.type;function C(e){var t,n,i,o=bd[l.type](a,e),s=(t=l,n=r,i=o,new("polar"===t.type?pO:lN)({shape:bm(n,i,t),silent:!0,z2:0}));return s.useStyle(m.getItemStyle()),"cartesian2d"===l.type?s.setShape("r",v):s.setShape("cornerRadius",v),y[e]=s,s}a.diff(s).add(function(t){var n=a.getItemModel(t),i=bd[l.type](a,t,n);if(g&&C(t),a.hasValue(t)&&bl[l.type](i)){var s=!1;h&&(s=bn[l.type](p,i));var m=bi[l.type](e,a,t,i,r,u,d.model,!1,f);c&&(m.forceLabelAnimation=!0),bc(m,a,t,n,i,e,r,"polar"===l.type),x?m.attr({shape:i}):c?br(c,u,m,i,t,r,!1,!1):dz(m,{shape:i},e,t),a.setItemGraphicEl(t,m),o.add(m),m.ignore=s}}).update(function(t,n){var i=a.getItemModel(t),S=bd[l.type](a,t,i);if(g){var _=void 0;0===b.length?_=C(n):((_=b[n]).useStyle(m.getItemStyle()),"cartesian2d"===l.type?_.setShape("r",v):_.setShape("cornerRadius",v),y[t]=_);var k=bd[l.type](a,t);dB(_,{shape:bm(r,k,l)},u,t)}var M=s.getItemGraphicEl(n);if(!a.hasValue(t)||!bl[l.type](S))return void o.remove(M);var T=!1;if(h&&(T=bn[l.type](p,S))&&o.remove(M),M?dW(M):M=bi[l.type](e,a,t,S,r,u,d.model,!!M,f),c&&
vendor: 2,980 bytes, line 422
422(M.forceLabelAnimation=!0),w){var D=M.getTextContent();if(D){var R=d3(D);null!=R.prevValue&&(R.prevValue=R.value)}}else bc(M,a,t,i,S,e,r,"polar"===l.type);x?M.attr({shape:S}):c?br(c,u,M,S,t,r,!0,w):dB(M,{shape:S},e,t,null),a.setItemGraphicEl(t,M),M.ignore=T,o.add(M)}).remove(function(t){var n=s.getItemGraphicEl(t);n&&dG(n,e,t)}).execute();var S=this._backgroundGroup||(this._backgroundGroup=new av);S.removeAll();for(var _=0;_<y.length;++_)S.add(y[_]);o.add(S),this._backgroundEls=y,this._data=a},t.prototype._renderLarge=function(e,t,n){this._clear(),bf(e,this.group),this._updateLargeClip(e)},t.prototype._incrementalRenderLarge=function(e,t){this._removeBackground(),bf(t,this.group,this._progressiveEls,!0)},t.prototype._updateLargeClip=function(e){var t=e.get("clip",!0)&&yA(e.coordinateSystem,!1,e),n=this.group;t?n.setClipPath(t):n.removeClipPath()},t.prototype._enableRealtimeSort=function(e,t,n){var i=this;if(t.count()){var r=e.baseAxis;if(this._isFirstFrame)this._dispatchInitSort(t,e,n),this._isFirstFrame=!1;else{var o=function(e){var n=t.getItemGraphicEl(e),i=n&&n.shape;return i&&Math.abs(r.isHorizontal()?i.height:i.width)||0};this._onRendered=function(){i._updateSortWithinSameData(t,o,r,n)},n.getZr().on("rendered",this._onRendered)}}},t.prototype._dataSort=function(e,t,n){var i=[];return e.each(e.mapDimension(t.dim),function(e,t){var r=n(t);r=null==r?NaN:r,i.push({dataIndex:t,mappedValue:r,ordinalNumber:e})}),i.sort(function(e,t){return t.mappedValue-e.mappedValue}),{ordinalNumbers:nC(i,function(e){return e.ordinalNumber})}},t.prototype._isOrderChangedWithinSameData=function(e,t,n){for(var i=n.scale,r=e.mapDimension(n.dim),o=Number.MAX_VALUE,a=0,s=i.getOrdinalMeta().categories.length;a<s;++a){var l=e.rawIndexOf(r,i.getRawOrdinalNumber(a)),d=l<0?5e-324:t(e.indexOfRawIndex(l));if(d>o)return!0;o=d}return!1},t.prototype._isOrderDifferentInView=function(e,t){for(var n=t.scale,i=n.getExtent(),r=Math.max(0,i[0]),o=Math.min(i[1],n.getOrdinalMeta().categories.length-1);r<=o;++r)if(e.ordinalNumbers[r]!==n.getRawOrdinalNumber(r))return!0},t.prototype._updateSortWithinSameData=function(e,t,n,i){if(this._isOrderChangedWithinSameData(e,t,n)){var r=this._dataSort(e,n,t);this._isOrderDifferentInView(r,n)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:r}))}},t.prototype._dispatchInitSort=function(e,t,n){var i=t.baseAxis,r=this._dataSort(e,i,function(n){return e.get(e.mapDimension(t.otherAxis.dim),n)});n.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:r})},t.prototype.remove=function(e,t){this._clear(this._model),this._removeOnRenderedListener(t)},t.prototype.dispose=function(e,t){this._removeOnRenderedListener(t)},t.prototype._removeOnRenderedListener=function(e){this._onRendered&&(e.getZr().off("rendered",this._onRendered),this._onRendered=null)},t.prototype._clear=function(e){var t=this.group,n=this._data;
422e&&e.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl(function(t){dG(t,e,lQ(t).dataIndex)})):t.removeAll(),this._data=null,this._isFirstFrame=!0},t.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},t.type="bar",t}(fI),bn={cartesian2d:function(e,t){var n=t.width<0?-1:1,i=t.height<0?-1:1;n<0&&(t.x+=t.width,t.width=-t.width),i<0&&(t.y+=t.height,t.height=-t.height);var r=e.x+e.width,o=e.y+e.height,a=y9(t.x,e.x),s=be(t.x+t.width,r),l=y9(t.y,e.y),d=be(t.y+t.height,o),u=s<a,c=d<l;return t.x=u&&a>r?s:a,t.y=c&&l>o?d:l,t.width=u?0:s-a,t.height=c?0:d-l,n<0&&(t.x+=t.width,t.width=-t.width),i<0&&(t.y+=t.height,t.height=-t.height),u||c},polar:function(e,t){var n=t.r0<=t.r?1:-1;if(n<0){var i=t.r;t.r=t.r0,t.r0=i}var r=be(t.r,e.r),o=y9(t.r0,e.r0);t.r=r,t.r0=o;var a=r-o<0;if(n<0){var i=t.r;t.r=t.r0,t.r0=i}return a}},bi={cartesian2d:function(e,t,n,i,r,o,a,s,l){var d=new lN({shape:nf({},i),z2:1});return d.__dataIndex=n,d.name="item",o&&(d.shape[r?"height":"width"]=0),d},polar:function(e,t,n,i,r,o,a,s,l){var d,u,c=!r&&l?y4:pO,h=new c({shape:i,z2:1});if(h.name="item",d=bu(r),u=c===y4,h.calculateTextPosition=function(e,t,n){var i=t.position;if(!i||i instanceof Array)return al(e,t,n);var r=d(i),o=null!=t.distance?t.distance:5,a=this.shape,s=a.cx,l=a.cy,c=a.r,h=a.r0,p=(c+h)/2,f=a.startAngle,g=a.endAngle,m=(f+g)/2,v=u?Math.abs(c-h)/2:0,y=Math.cos,b=Math.sin,x=s+c*y(f),w=l+c*b(f),C="left",S="top";switch(r){case"startArc":x=s+(h-o)*y(m),w=l+(h-o)*b(m),C="center",S="top";break;case"insideStartArc":x=s+(h+o)*y(m),w=l+(h+o)*b(m),C="center",S="bottom";break;case"startAngle":x=s+p*y(f)+y6(f,o+v,!1),w=l+p*b(f)+y8(f,o+v,!1),C="right",S="middle";break;case"insideStartAngle":x=s+p*y(f)+y6(f,-o+v,!1),w=l+p*b(f)+y8(f,-o+v,!1),C="left",S="middle";break;case"middle":x=s+p*y(m),w=l+p*b(m),C="center",S="middle";break;case"endArc":x=s+(c+o)*y(m),w=l+(c+o)*b(m),C="center",S="bottom";break;case"insideEndArc":x=s+(c-o)*y(m),w=l+(c-o)*b(m),C="center",S="top";break;case"endAngle":x=s+p*y(g)+y6(g,o+v,!0),w=l+p*b(g)+y8(g,o+v,!0),C="left",S="middle";break;case"insideEndAngle":x=s+p*y(g)+y6(g,-o+v,!0),w=l+p*b(g)+y8(g,-o+v,!0),C="right",S="middle";break;default:return al(e,t,n)}return(e=e||{}).x=x,e.y=w,e.align=C,e.verticalAlign=S,e},o){var p=h.shape,f=r?"r":"endAngle",g={};p[f]=r?i.r0:i.startAngle,g[f]=i[f],(s?dB:dz)(h,{shape:g},o)}return h}};function br(e,t,n,i,r,o,a,s){var l,d;o?(d={x:i.x,width:i.width},l={y:i.y,height:i.height}):(d={y:i.y,height:i.height},l={x:i.x,width:i.width}),s||(a?dB:dz)(n,{shape:l},t,r,null),(a?dB:dz)(n,{shape:d},t?e.baseAxis.model:null,r)}function bo(e,t){for(var n=0;n<t.length;n++)if(!isFinite(e[t[n]]))return!0;return!1}var ba=["x","y","width","height"],bs=["cx","cy","r","startAngle","endAngle"],bl={cartesian2d:function(e){return!bo(e,ba)},polar:function(e){return!bo(e,bs)}},bd={cartesian2d:function(e,t,n){var i,r,o,a=e.getItemLayout(t),s=n?(i=n,r=a,(o=i.get(["itemStyle","borderColor"]))&&"none"!==o?Math.min(i.get(["itemStyle","borderWidth"])||0,isNaN(r.width)?Number.MAX_VALUE:Math.abs(r.width),isNaN(r.height)?Number.MAX_VALUE:Math.abs(r.height)):0):0,l=a.width>0?1:-1,d=a.height>0?1:-1;return{x:a.x+l*s/2,y:a.y+d*s/2,width:a.width-l*s,height:a.height-d*s}},polar:function(e,t,n){var i=e.getItemLayout(t);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}}};function bu(e){var t;return t=e?"Arc":"Angle",function(e){switch(e){case"start":case"insideStart":case"end":case"insideEnd":return e+t;default:return e}}}function bc(e,t,n,i,r,o,a,s){var l=t.getItemVisual(n,"style");if(s){if(!o.get("roundCap")){var d=e.shape,u=y7(i.getModel("itemStyle"),d,!0);nf(d,u),e.setShape(d)}}else{var c=i.get(["itemStyle","borderRadius"])||0;e.setShape("r",c)}e.useStyle(l);
422var h=i.getShallow("cursor");h&&e.attr("cursor",h);var p=s?a?r.r>=r.r0?"endArc":"startArc":r.endAngle>=r.startAngle?"endAngle":"startAngle":a?r.height>=0?"bottom":"top":r.width>=0?"right":"left",f=dY(i);dK(e,f,{labelFetcher:o,labelDataIndex:n,defaultText:yl(o.getData(),n),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:p});var g=e.getTextContent();if(s&&g){var m=i.get(["label","position"]);e.textConfig.inside="middle"===m||null,function(e,t,n,i){if(nE(i))return e.setTextConfig({rotation:i});if(nR(t))return e.setTextConfig({rotation:0});var r,o=e.shape,a=o.clockwise?o.startAngle:o.endAngle,s=o.clockwise?o.endAngle:o.startAngle,l=n(t);switch(l){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":r=(a+s)/2;break;case"startAngle":case"insideStartAngle":r=a;break;case"endAngle":case"insideEndAngle":r=s;break;default:e.setTextConfig({rotation:0});return}var d=1.5*Math.PI-r;"middle"===l&&d>Math.PI/2&&d<1.5*Math.PI&&(d-=Math.PI),e.setTextConfig({rotation:d})}(e,"outside"===m?p:m,bu(a),i.get(["label","rotate"]))}d5(g,f,o.getRawValue(n),function(e){return yd(t,e)});var v=i.getModel(["emphasis"]);dM(e,v.get("focus"),v.get("blurScope"),v.get("disabled")),dI(e,i),null!=r.startAngle&&null!=r.endAngle&&r.startAngle===r.endAngle&&(e.style.fill="none",e.style.stroke="none",nw(e.states,function(e){e.style&&(e.style.fill=e.style.stroke="none")}))}var bh=function(){},bp=function(e){function t(t){var n=e.call(this,t)||this;return n.type="largeBar",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new bh},t.prototype.buildPath=function(e,t){for(var n=t.points,i=this.baseDimIdx,r=1-this.baseDimIdx,o=[],a=[],s=this.barWidth,l=0;l<n.length;l+=3)a[i]=s,a[r]=n[l+2],o[i]=n[l+i],o[r]=n[l+r],e.rect(o[0],o[1],a[0],a[1])},t}(lk);function bf(e,t,n,i){var r=e.getData(),o=+!!r.getLayout("valueAxisHorizontal"),a=r.getLayout("largeDataIndices"),s=r.getLayout("size"),l=e.getModel("backgroundStyle"),d=r.getLayout("largeBackgroundPoints");if(d){var u=new bp({shape:{points:d},incremental:!!i,silent:!0,z2:0});u.baseDimIdx=o,u.largeDataIndices=a,u.barWidth=s,u.useStyle(l.getItemStyle()),t.add(u),n&&n.push(u)}var c=new bp({shape:{points:r.getLayout("largePoints")},incremental:!!i,ignoreCoarsePointer:!0,z2:1});c.baseDimIdx=o,c.largeDataIndices=a,c.barWidth=s,t.add(c),c.useStyle(r.getVisual("style")),c.style.stroke=null,lQ(c).seriesIndex=e.seriesIndex,e.get("silent")||(c.on("mousedown",bg),c.on("mousemove",bg)),n&&n.push(c)}var bg=fz(function(e){var t=function(e,t,n){for(var i=e.baseDimIdx,r=1-i,o=e.shape.points,a=e.largeDataIndices,s=[],l=[],d=e.barWidth,u=0,c=o.length/3;u<c;u++){var h=3*u;if(l[i]=d,l[r]=o[h+2],s[i]=o[h+i],s[r]=o[h+r],l[r]<0&&(s[r]+=l[r],l[r]=-l[r]),t>=s[0]&&t<=s[0]+l[0]&&n>=s[1]&&n<=s[1]+l[1])return a[u]}return -1}(this,e.offsetX,e.offsetY);lQ(this).dataIndex=t>=0?t:null},30,!1);function bm(e,t,n){if(yP(n,"cartesian2d")){var i=n.getArea();return{x:e?t.x:i.x,y:e?i.y:t.y,width:e?t.width:i.width,height:e?i.height:t.height}}var i=n.getArea();return{cx:i.cx,cy:i.cy,r0:e?i.r0:t.r0,r:e?i.r:t.r,startAngle:e?t.startAngle:0,endAngle:e?t.endAngle:2*Math.PI}}var bv=2*Math.PI,by=Math.PI/180;function bb(e,t){return uX(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()})}function bx(e,t){var n,i,r=bb(e,t),o=e.get("center"),a=e.get("radius");nR(a)||(a=[0,a]);var s=aR(r.width,t.getWidth()),l=aR(r.height,t.getHeight()),d=Math.min(s,l),u=aR(a[0],d/2),c=aR(a[1],d/2),h=e.coordinateSystem;if(h){var p=h.dataToPoint(o);n=p[0]||0,i=p[1]||0}else nR(o)||(o=[o,o]),n=aR(o[0],s)+r.x,i=aR(o[1],l)+r.y;return{cx:n,cy:i,r0:u,r:c}}function bw(e,t,n){t.eachSeriesByType(e,function(e){var t=e.getData(),i=t.mapDimension("value"),r=bb(e,n),o=bx(e,n),a=o.cx,s=o.cy,l=o.r,d=o.r0,u=-e.get("startAngle")*by,c=e.get("endAngle"),h=e.get("padAngle")*by;c="auto"===c?u-bv:-c*by;var p=e.get("minAngle")*by+h,f=0;t.each(i,function(e){!isNaN(e)&&f++});var g=t.getSum(i),m=Math.PI/(g||f)*2,v=e.get("clockwise"),y=e.get("roseType"),b=e.get("stillShowZeroSum"),x=t.getDataExtent(i);x[0]=0;var w=v?1:-1,C=[u,c],S=w*h/2;ld(C,!v),u=C[0],c=C[1];var _=bC(e);_.startAngle=u,_.endAngle=c,_.clockwise=v;var k=Math.abs(c-u),M=k,T=0,D=u;if(t.setLayout({viewRect:r,r:l}),t.each(i,function(e,n){if(isNaN(e))return void t.setItemLayout(n,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:v,cx:a,cy:s,r0:d,r:y?NaN:l});(i="area"!==y?0===g&&b?m:e*m:k/f)<p?(i=p,M-=p):T+=e;var i,r=D+w*i,o=0,u=0;h>i?u=o=D+w*i/2:(o=D+S,u=r-S),t.setItemLayout(n,{angle:i,startAngle:o,endAngle:u,clockwise:v,cx:a,cy:s,r0:d,r:y?aD(e,x,[d,l]):l}),D=r}),M<bv&&f)if(M<=.001){var R=k/f;t.each(i,function(e,n){if(!isNaN(e)){var i=t.getItemLayout(n);i.angle=R;var r=0,o=0;R<h?o=r=u+w*(n+.5)*R:(r=u+w*n*R+S,o=u+w*(n+1)*R-S),i.startAngle=r,i.endAngle=o}})}else m=M/T,D=u,t.each(i,function(e,n){if(!isNaN(e)){var i=t.getItemLayout(n),r=i.angle===p?p:e*m,o=0,a=0;r<h?a=o=D+w*r/2:(o=D+S,a=D+w*r-S),i.startAngle=o,i.endAngle=a,D+=w*r}})})}var bC=a9();function bS(e){return{seriesType:e,reset:function(e,t){var n=t.findComponents({mainType:"legend"});if(n&&n.length){var i=e.getData();i.filterSelf(function(e){for(var t=i.getName(e),r=0;r<n.length;r++)if(!n[r].isSelected(t))return!1;return!0})}}}}var b_=2*Math.PI,bk=lu.CMD,bM=["top","right","bottom","left"];function bT(e,t,n,i,r,o,a,s){var l=n-e,d=i-t,u=Math.sqrt(l*l+d*d),c=((r-e)*(l/=u)+(o-t)*(d/=u))/u;s&&(c=Math.min(Math.max(c,0),1)),c*=u;var h=a[0]=e+c*l,p=a[1]=t+c*d;return Math.sqrt((h-r)*(h-r)+(p-o)*(p-o))}function bD(e,t,n,i,r,o,a){n<0&&(e+=n,n=-n),i<0&&(t+=i,i=-i);var s=e+n,l=t+i,d=a[0]=Math.min(Math.max(r,e),s),u=a[1]=Math.min(Math.max(o,t),l);return Math.sqrt((d-r)*(d-r)+(u-o)*(u-o))}var bR=[],bI=new i2,bA=new i2,bP=new i2,bE=new i2,bL=new i2;function bF(e,t){if(e){var n=e.getTextGuideLine(),i=e.getTextContent();if(i&&n){var r=e.textGuideLineConfig||{}
422,o=[[0,0],[0,0],[0,0]],a=r.candidates||bM,s=i.getBoundingRect().clone();s.applyTransform(i.getComputedTransform());var l=1/0,d=r.anchor,u=e.getComputedTransform(),c=u&&i0([],u),h=t.get("length2")||0;d&&bP.copy(d);for(var p=0;p<a.length;p++){!function(e,t,n,i,r){var o=n.width,a=n.height;switch(e){case"top":i.set(n.x+o/2,n.y-0),r.set(0,-1);break;case"bottom":i.set(n.x+o/2,n.y+a+0),r.set(0,1);break;case"left":i.set(n.x-0,n.y+a/2),r.set(-1,0);break;case"right":i.set(n.x+o+0,n.y+a/2),r.set(1,0)}}(a[p],0,s,bI,bE),i2.scaleAndAdd(bA,bI,bE,h),bA.transform(c);var f=e.getBoundingRect(),g=d?d.distance(bA):e instanceof lk?function(e,t,n){for(var i,r,o=0,a=0,s=0,l=0,d=1/0,u=t.data,c=e.x,h=e.y,p=0;p<u.length;){var f=u[p++];1===p&&(o=u[p],a=u[p+1],s=o,l=a);var g=d;switch(f){case bk.M:s=u[p++],l=u[p++],o=s,a=l;break;case bk.L:g=bT(o,a,u[p],u[p+1],c,h,bR,!0),o=u[p++],a=u[p++];break;case bk.C:g=rF(o,a,u[p++],u[p++],u[p++],u[p++],u[p],u[p+1],c,h,bR),o=u[p++],a=u[p++];break;case bk.Q:g=rj(o,a,u[p++],u[p++],u[p],u[p+1],c,h,bR),o=u[p++],a=u[p++];break;case bk.A:var m=u[p++],v=u[p++],y=u[p++],b=u[p++],x=u[p++],w=u[p++];p+=1;var C=!!(1-u[p++]);i=Math.cos(x)*y+m,r=Math.sin(x)*b+v,p<=1&&(s=i,l=r);var S=(c-m)*b/y+m;g=function(e,t,n,i,r,o,a,s,l){var d=Math.sqrt((a-=e)*a+(s-=t)*s),u=(a/=d)*n+e,c=(s/=d)*n+t;if(Math.abs(i-r)%b_<1e-4)return l[0]=u,l[1]=c,d-n;if(o){var h=i;i=lf(r),r=lf(h)}else i=lf(i),r=lf(r);i>r&&(r+=b_);var p=Math.atan2(s,a);if(p<0&&(p+=b_),p>=i&&p<=r||p+b_>=i&&p+b_<=r)return l[0]=u,l[1]=c,d-n;var f=n*Math.cos(i)+e,g=n*Math.sin(i)+t,m=n*Math.cos(r)+e,v=n*Math.sin(r)+t,y=(f-a)*(f-a)+(g-s)*(g-s),b=(m-a)*(m-a)+(v-s)*(v-s);return y<b?(l[0]=f,l[1]=g,Math.sqrt(y)):(l[0]=m,l[1]=v,Math.sqrt(b))}(m,v,b,x,x+w,C,S,h,bR),o=Math.cos(x+w)*y+m,a=Math.sin(x+w)*b+v;break;case bk.R:g=bD(s=o=u[p++],l=a=u[p++],u[p++],u[p++],c,h,bR);break;case bk.Z:g=bT(o,a,s,l,c,h,bR,!0),o=s,a=l}g<d&&(d=g,n.set(bR[0],bR[1]))}return d}(bA,e.path,bP):function(e,t,n){var i=bD(t.x,t.y,t.width,t.height,e.x,e.y,bR);return n.set(bR[0],bR[1]),i}(bA,f,bP);g<l&&(l=g,bA.transform(u),bP.transform(u),bP.toArray(o[0]),bA.toArray(o[1]),bI.toArray(o[2]))}bB(o,t.get("minTurnAngle")),n.setShape({points:o})}}}var bO=[],bN=new i2;function bB(e,t){if(t<=180&&t>0){t=t/180*Math.PI,bI.fromArray(e[0]),bA.fromArray(e[1]),bP.fromArray(e[2]),i2.sub(bE,bI,bA),i2.sub(bL,bP,bA);var n=bE.len(),i=bL.len();if(!(n<.001)&&!(i<.001)&&(bE.scale(1/n),bL.scale(1/i),Math.cos(t)<bE.dot(bL))){var r=bT(bA.x,bA.y,bP.x,bP.y,bI.x,bI.y,bO,!1);bN.fromArray(bO),bN.scaleAndAdd(bL,r/Math.tan(Math.PI-t));var o=bP.x!==bA.x?(bN.x-bA.x)/(bP.x-bA.x):(bN.y-bA.y)/(bP.y-bA.y);if(isNaN(o))return;o<0?i2.copy(bN,bA):o>1&&i2.copy(bN,bP),bN.toArray(e[1])}}}function bz(e,t,n,i){var r="normal"===n,o=r?e:e.ensureState(n);o.ignore=t;var a=i.get("smooth");a&&!0===a&&(a=.3),o.shape=o.shape||{},a>0&&(o.shape.smooth=a);var s=i.getModel("lineStyle").getLineStyle();r?e.useStyle(s):o.style=s}function bj(e,t){var n=t.smooth,i=t.points;if(i)if(e.moveTo(i[0][0],i[0][1]),n>0&&i.length>=3){var r=ip(i[0],i[1]),o=ip(i[1],i[2]);if(!r||!o){e.lineTo(i[1][0],i[1][1]),e.lineTo(i[2][0],i[2][1]);return}var a=Math.min(r,o)*n,s=iv([],i[1],i[0],a/r),l=iv([],i[1],i[2],a/o),d=iv([],s,l,.5);e.bezierCurveTo(s[0],s[1],s[0],s[1],d[0],d[1]),e.bezierCurveTo(l[0],l[1],l[0],l[1],i[2][0],i[2][1])}else for(var u=1;u<i.length;u++)e.lineTo(i[u][0],i[u][1])}function bV(e,t,n){var i=e.getTextGuideLine(),r=e.getTextContent();if(!r){i&&e.removeTextGuideLine();return}for(var o=t.normal,a=o.get("show"),s=r.ignore,l=0;l<l6.length;l++){var d=l6[l],u=t[d],c="normal"===d;if(u){var h=u.get("show");if((c?s:nG(r.states[d]&&r.states[d].ignore,s))||!nG(h,a)){var p=c?i:i&&i.states[d];p&&(p.ignore=!0),i&&bz(i,!0,d,u);continue}!i&&(i=new pG,e.setTextGuideLine(i),c||!s&&a||bz(i,!0,"normal",t.normal),e.stateProxy&&(i.stateProxy=e.stateProxy)),bz(i,!1,d,u)}}if(i){ng(i.style,n),i.style.fill=null;var f=o.get("showAbove");(e.textGuideLineConfig=e.textGuideLineConfig||{}).showAbove=f||!1,i.buildPath=bj}}function bH(e,t){t=t||"labelLine";for(var n={normal:e.getModel(t)},i=0;i<l4.length;i++){var r=l4[i];n[r]=e.getModel([r,t])}return n}function bG(e){for(var t=[],n=0;n<e.length;n++){var i=e[n];if(!i.defaultAttr.ignore){var r=i.label,o=r.getComputedTransform(),a=r.getBoundingRect
422(),s=!o||o[1]<1e-5&&o[2]<1e-5,l=r.style.margin||0,d=a.clone();d.applyTransform(o),d.x-=l/2,d.y-=l/2,d.width+=l,d.height+=l;var u=s?new p8(a,o):null;t.push({label:r,labelLine:i.labelLine,rect:d,localRect:a,obb:u,priority:i.priority,defaultAttr:i.defaultAttr,layoutOption:i.computedLayoutOption,axisAligned:s,transform:o})}}return t}function bW(e,t,n,i,r,o){var a,s,l,d=e.length;if(!(d<2)){e.sort(function(e,n){return e.rect[t]-n.rect[t]});for(var u=0,c=!1,h=[],p=0,f=0;f<d;f++){var g=e[f],m=g.rect;(a=m[t]-u)<0&&(m[t]-=a,g.label[t]-=a,c=!0);var v=Math.max(-a,0);h.push(v),p+=v,u=m[t]+m[n]}p>0&&o&&C(-p/d,0,d);var y=e[0],b=e[d-1];return x(),s<0&&S(-s,.8),l<0&&S(l,.8),x(),w(s,l,1),w(l,s,-1),x(),s<0&&_(-s),l<0&&_(l),c}function x(){s=y.rect[t]-i,l=r-b.rect[t]-b.rect[n]}function w(e,t,n){if(e<0){var i=Math.min(t,-e);if(i>0){C(i*n,0,d);var r=i+e;r<0&&S(-r*n,1)}else S(-e*n,1)}}function C(n,i,r){0!==n&&(c=!0);for(var o=i;o<r;o++){var a=e[o],s=a.rect;s[t]+=n,a.label[t]+=n}}function S(i,r){for(var o=[],a=0,s=1;s<d;s++){var l=e[s-1].rect,u=Math.max(e[s].rect[t]-l[t]-l[n],0);o.push(u),a+=u}if(a){var c=Math.min(Math.abs(i)/a,r);if(i>0)for(var s=0;s<d-1;s++){var h=o[s]*c;C(h,0,s+1)}else for(var s=d-1;s>0;s--){var h=o[s-1]*c;C(-h,s,d)}}}function _(e){for(var t=e<0?-1:1,n=Math.ceil((e=Math.abs(e))/(d-1)),i=0;i<d-1;i++)if(t>0?C(n,0,i+1):C(-n,d-i-1,d),(e-=n)<=0)return}}function b$(e,t,n,i){return bW(e,"y","height",t,n,i)}function bU(e){var t=[];e.sort(function(e,t){return t.priority-e.priority});var n=new rt(0,0,0,0);function i(e){if(!e.ignore){var t=e.ensureState("emphasis");null==t.ignore&&(t.ignore=!1)}e.ignore=!0}for(var r=0;r<e.length;r++){var o=e[r],a=o.axisAligned,s=o.localRect,l=o.transform,d=o.label,u=o.labelLine;n.copy(o.rect),n.width-=.1,n.height-=.1,n.x+=.05,n.y+=.05;for(var c=o.obb,h=!1,p=0;p<t.length;p++){var f=t[p];if(n.intersect(f.rect)&&(a&&f.axisAligned||(f.obb||(f.obb=new p8(f.localRect,f.transform)),c||(c=new p8(s,l)),c.intersect(f.obb)))){h=!0;break}}h?(i(d),u&&i(u)):(d.attr("ignore",o.defaultAttr.ignore),u&&u.attr("ignore",o.defaultAttr.labelGuideIgnore),t.push(o))}}var bq=Math.PI/180;function bK(e,t,n,i,r,o,a,s,l,d){if(!(e.length<2)){for(var u=e.length,c=0;c<u;c++)if("outer"===e[c].position&&"labelLine"===e[c].labelAlignTo){var h=e[c].label.x-d;e[c].linePoints[1][0]+=h,e[c].label.x=d}b$(e,l,l+a)&&function(e){for(var o={list:[],maxY:0},a={list:[],maxY:0},s=0;s<e.length;s++)if("none"===e[s].labelAlignTo){var l=e[s],d=l.label.y>n?a:o,u=Math.abs(l.label.y-n);if(u>=d.maxY){var c=l.label.x-t-l.len2*r,h=i+l.len;d.rB=Math.abs(c)<h?Math.sqrt(u*u/(1-c*c/h/h)):h,d.maxY=u}d.list.push(l)}p(o),p(a)}(e)}function p(e){for(var o=e.rB,a=o*o,s=0;s<e.list.length;s++){var l=e.list[s],d=Math.abs(l.label.y-n),u=i+l.len,c=t+(Math.sqrt(Math.abs(u*u*(1-d*d/a)))+l.len2)*r,h=c-l.label.x,p=l.targetTextWidth-h*r;bY(l,p,!0),l.label.x=c}}}function bY(e,t,n){if(void 0===n&&(n=!1),null==e.labelStyleWidth){var i=e.label,r=i.style,o=e.rect,a=r.backgroundColor,s=r.padding,l=s?s[1]+s[3]:0,d=r.overflow,u=o.width+(a?0:l);if(t<u||n){var c=o.height;if(d&&d.match("break")){i.setStyle("backgroundColor",null),i.setStyle("width",t-l);var h=i.getBoundingRect();i.setStyle("width",Math.ceil(h.width)),i.setStyle("backgroundColor",a)}else{var p=t-l,f=t<u?p:n?p>e.unconstrainedWidth?null:p:null;i.setStyle("width",f)}var g=i.getBoundingRect();o.width=g.width;var m=(i.style.margin||0)+2.1;o.height=g.height+m,o.y-=(o.height-c)/2}}}function bZ(e){return"center"===e.position}var bX=function(e){function t(t,n,i){var r=e.call(this)||this;r.z2=2;var o=new lj;return r.setTextContent(o),r.updateData(t,n,i,!0),r}return(0,tQ.__extends)(t,e),t.prototype.updateData=function(e,t,n,i){var r=e.hostModel,o=e.getItemModel(t),a=o.getModel("emphasis"),s=e.getItemLayout(t),l=nf(y7(o.getModel("itemStyle"),s,!0),s);if(isNaN(l.startAngle))return void this.setShape(l);if(i){this.setShape(l);var d=r.getShallow("animationType");r.ecModel.ssr?(dz(this,{scaleX:0,scaleY:0},r,{dataIndex:t,isFrom:!0}),this.originX=l.cx,this.originY=l.cy):"scale"===d?(this.shape.r=s.r0,dz(this,{shape:{r:s.r}},r,t)):null!=n?(this.setShape({startAngle:n,endAngle:n}),dz(this,{shape:{startAngle:s.startAngle,endAngle:s.endAngle}},r,t)):(this.shape.endAngle=s.startAngle,dB(this,{shape:{endAngle:s.endAngle}},r,t))}else dW(this),dB(this,{shape:l},r,t);this.useStyle(e.getItemVisual(t,"style")),dI(this,o);var u=(s.startAngle+s.endAngle)/2,c=r.get("selectedOffset"),h=Math.cos(u)*c,p=Math.sin(u)*c,f=o.getShallow("cursor");f&&this.attr("cursor",f),this._updateLabel(r,e,t),this.ensureState("emphasis").shape=nf({r:s.r+(a.get("scale")&&a.get("scaleSize")||0)},y7(a.getModel("itemStyle"),s)),nf(this.ensureState("select"),{x:h,y:p,shape:y7(o.getModel(["select","itemStyle"]),s)}),nf(this.ensureState("blur"),{shape:y7(o.getModel(["blur","itemStyle"]),s)});var g=this.getTextGuideLine(),m=this.getTextContent();g&&nf(g.ensureState("select"),{x:h,y:p}),nf(m.ensureState("select"),{x:h,y:p}),dM(this,a.get("focus"),a.get("blurScope"),a.get("disabled"))},t.prototype._updateLabel=function(e,t,n){var i=t.getItemModel(n),r=i.getModel("labelLine"),o=t.getItemVisual(n,"style"),a=o&&o.fill,s=o&&o.opacity;dK(this,dY(i),{labelFetcher:t.hostModel,labelDataIndex:n,inheritColor:a,defaultOpacity:s,defaultText:e.getFormattedLabel(n,"normal")||t.getName(n)});var l=this.getTextContent();this.setTextConfig({position:null,rotation:null}),l.attr({z2:10});var d=e.get(["label","position"]);if("outside"!==d&&"outer"!==d)this.removeTextGuideLine();else{var u=this.getTextGuideLine();u||(u=new pG,this.setTextGuideLine(u)),bV(this,bH(i),{stroke:a,opacity:nW(r.get(["lineStyle","opacity"]),s,1)})}},t}(pO),bJ=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.ignoreLabelLineUpdate=!0,t}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){var r,o=e.getData(),a=this._data,s=this.group;if(!a&&o.count()>0){for(var l=o.getItemLayout(0),d=1;isNaN(l&&l.startAngle)&&d<o.count();++d)l=o.getItemLayout(d);l&&(r=l.startAngle)}if(this._emptyCircleSector&&s.remove(this._emptyCircleSector),0===o.count()&&e.get("showEmptyCircle")){var u=bC(e),c=new pO({shape:nf(bx(e,n),u)});
422c.useStyle(e.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=c,s.add(c)}o.diff(a).add(function(e){var t=new bX(o,e,r);o.setItemGraphicEl(e,t),s.add(t)}).update(function(e,t){var n=a.getItemGraphicEl(t);n.updateData(o,e,r),n.off("click"),s.add(n),o.setItemGraphicEl(e,n)}).remove(function(t){dG(a.getItemGraphicEl(t),e,t)}).execute(),function(e){var t,n,i=e.getData(),r=[],o=!1,a=(e.get("minShowLabelAngle")||0)*bq,s=i.getLayout("viewRect"),l=i.getLayout("r"),d=s.width,u=s.x,c=s.y,h=s.height;function p(e){e.ignore=!0}i.each(function(e){var s,c,h,f,g=i.getItemGraphicEl(e),m=g.shape,v=g.getTextContent(),y=g.getTextGuideLine(),b=i.getItemModel(e),x=b.getModel("label"),w=x.get("position")||b.get(["emphasis","label","position"]),C=x.get("distanceToLabelLine"),S=x.get("alignTo"),_=aR(x.get("edgeDistance"),d),k=x.get("bleedMargin"),M=b.getModel("labelLine"),T=M.get("length");T=aR(T,d);var D=M.get("length2");if(D=aR(D,d),Math.abs(m.endAngle-m.startAngle)<a){nw(v.states,p),v.ignore=!0,y&&(nw(y.states,p),y.ignore=!0);return}if(function(e){if(!e.ignore)return!0;for(var t in e.states)if(!1===e.states[t].ignore)return!0;return!1}(v)){var R=(m.startAngle+m.endAngle)/2,I=Math.cos(R),A=Math.sin(R);t=m.cx,n=m.cy;var P="inside"===w||"inner"===w;if("center"===w)s=m.cx,c=m.cy,f="center";else{var E=(P?(m.r+m.r0)/2*I:m.r*I)+t,L=(P?(m.r+m.r0)/2*A:m.r*A)+n;if(s=E+3*I,c=L+3*A,!P){var F=E+I*(T+l-m.r),O=L+A*(T+l-m.r),N=F+(I<0?-1:1)*D;s="edge"===S?I<0?u+_:u+d-_:N+(I<0?-C:C),c=O,h=[[E,L],[F,O],[N,O]]}f=P?"center":"edge"===S?I>0?"right":"left":I>0?"left":"right"}var B=Math.PI,z=0,j=x.get("rotate");if(nE(j))z=B/180*j;else if("center"===w)z=0;else if("radial"===j||!0===j)z=I<0?-R+B:-R;else if("tangential"===j&&"outside"!==w&&"outer"!==w){var V=Math.atan2(I,A);V<0&&(V=2*B+V),A>0&&(V=B+V),z=V-B}if(o=!!z,v.x=s,v.y=c,v.rotation=z,v.setStyle({verticalAlign:"middle"}),P){v.setStyle({align:f});var H=v.states.select;H&&(H.x+=v.x,H.y+=v.y)}else{var G=v.getBoundingRect().clone();G.applyTransform(v.getComputedTransform());var W=(v.style.margin||0)+2.1;G.y-=W/2,G.height+=W,r.push({label:v,labelLine:y,position:w,len:T,len2:D,minTurnAngle:M.get("minTurnAngle"),maxSurfaceAngle:M.get("maxSurfaceAngle"),surfaceNormal:new i2(I,A),linePoints:h,textAlign:f,labelDistance:C,labelAlignTo:S,edgeDistance:_,bleedMargin:k,rect:G,unconstrainedWidth:G.width,labelStyleWidth:v.style.width})}g.setTextConfig({inside:P})}}),!o&&e.get("avoidLabelOverlap")&&function(e,t,n,i,r,o,a,s){for(var l=[],d=[],u=Number.MAX_VALUE,c=-Number.MAX_VALUE,h=0;h<e.length;h++){var p=e[h].label;bZ(e[h])||(p.x<t?(u=Math.min(u,p.x),l.push(e[h])):(c=Math.max(c,p.x),d.push(e[h])))}for(var h=0;h<e.length;h++){var f=e[h];if(!bZ(f)&&f.linePoints){if(null!=f.labelStyleWidth)continue;var p=f.label,g=f.linePoints,m=void 0;m="edge"===f.labelAlignTo?p.x<t?g[2][0]-f.labelDistance-a-f.edgeDistance:a+r-f.edgeDistance-g[2][0]-f.labelDistance:"labelLine"===f.labelAlignTo?p.x<t?u-a-f.bleedMargin:a+r-c-f.bleedMargin:p.x<t?p.x-a-f.bleedMargin:a+r-p.x-f.bleedMargin,f.targetTextWidth=m,bY(f,m)}}bK(d,t,n,i,1,r,o,a,s,c),bK(l,t,n,i,-1,r,o,a,s,u);for(var h=0;h<e.length;h++){var f=e[h];if(!bZ(f)&&f.linePoints){var p=f.label,g=f.linePoints,v="edge"===f.labelAlignTo,y=p.style.padding,b=y?y[1]+y[3]:0,x=p.style.backgroundColor?0:b,w=f.rect.width+x,C=g[1][0]-g[2][0];v?p.x<t?g[2][0]=a+f.edgeDistance+w+f.labelDistance:g[2][0]=a+r-f.edgeDistance-w-f.labelDistance:(p.x<t?g[2][0]=p.x+f.labelDistance:g[2][0]=p.x-f.labelDistance,g[1][0]=g[2][0]+C),g[1][1]=g[2][1]=p.y}}}(r,t,n,l,d,h,u,c);for(var f=0;f<r.length;f++){var g=r[f],m=g.label,v=g.labelLine,y=isNaN(m.x)||isNaN(m.y);if(m){m.setStyle({align:g.textAlign}),y&&(nw(m.states,p),m.ignore=!0);var b=m.states.select;b&&(b.x+=m.x,b.y+=m.y)}if(v){var x=g.linePoints;y||!x?(nw(v.states,p),v.ignore=!0):(bB(x,g.minTurnAngle),function(e,t,n){if(n<=180&&n>0){n=n/180*Math.PI,bI.fromArray(e[0]),bA.fromArray(e[1]),bP.fromArray(e[2]),i2.sub(bE,bA,bI),i2.sub(bL,bP,bA);var i=bE.len(),r=bL.len();if(!(i<.001)&&!(r<.001)&&(bE.scale(1/i),bL.scale(1/r),bE.dot(t)<Math.cos(n))){var o=bT(bA.x,bA.y,bP.x,bP.y,bI.x,bI.y,bO,!1);bN.fromArray(bO);var a=Math.PI/2,s=a+Math.acos(bL.dot(t))-n;if(s>=a)i2.copy(bN,bP);else{bN.scaleAndAdd(bL,o/Math.tan(Math.PI/2-s));var l=bP.x!==bA.x?(bN.x-bA.x)/(bP.x-bA.x):(bN.y-bA.y)/(bP.y-bA.y);if(isNaN(l))return;l<0?i2.copy(bN,bA):l>1&&i2.copy(bN,bP)}bN.toArray(e[1])}}}(x,g.surfaceNormal,g.maxSurfaceAngle),v.setShape({points:x}),m.__hostTarget.textGuideLineConfig={anchor:new i2(x[0][0],x[0][1])})}}}(e),"expansion"!==e.get("animationTypeUpdate")&&(this._data=o)},t.prototype.dispose=function(){},t.prototype.containPoint=function(e,t){var n=t.getData().getItemLayout(0);if(n){var i=e[0]-n.cx,r=e[1]-n.cy,o=Math.sqrt(i*i+r*r);return o<=n.r&&o>=n.r0}},t.type="pie",t}(fI);function bQ(e,t,n){t=nR(t)&&{coordDimensions:t}||nf({encodeDefine:e.getEncode()},t);
422var i=e.getSource(),r=new v8(v9(i,t).dimensions,e);return r.initData(i,n),r}var b0=function(){function e(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return e.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},e.prototype.containName=function(e){return this._getRawData().indexOfName(e)>=0},e.prototype.indexOfName=function(e){return this._getDataWithEncodedVisual().indexOfName(e)},e.prototype.getItemVisual=function(e,t){return this._getDataWithEncodedVisual().getItemVisual(e,t)},e}(),b1=a9(),b2=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.init=function(t){e.prototype.init.apply(this,arguments),this.legendVisualProvider=new b0(nT(this.getData,this),nT(this.getRawData,this)),this._defaultLabelLine(t)},t.prototype.mergeOption=function(){e.prototype.mergeOption.apply(this,arguments)},t.prototype.getInitialData=function(){return bQ(this,{coordDimensions:["value"],encodeDefaulter:nD(cu,this)})},t.prototype.getDataParams=function(t){var n=this.getData(),i=b1(n),r=i.seats;if(!r){var o=[];n.each(n.mapDimension("value"),function(e){o.push(e)}),r=i.seats=aO(o,n.hostModel.get("percentPrecision"))}var a=e.prototype.getDataParams.call(this,t);return a.percent=r[t]||0,a.$vars.push("percent"),a},t.prototype._defaultLabelLine=function(e){aQ(e,"labelLine",["show"]);var t=e.labelLine,n=e.emphasis.labelLine;t.show=t.show&&e.label.show,n.show=n.show&&e.emphasis.label.show},t.type="series.pie",t.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},t}(h1),b3=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){return ya(null,this,{useEncodeDefaulter:!0})},t.prototype.getProgressive=function(){var e=this.option.progressive;return null==e?this.option.large?5e3:this.get("progressive"):e},t.prototype.getProgressiveThreshold=function(){var e=this.option.progressiveThreshold;return null==e?this.option.large?1e4:this.get("progressiveThreshold"):e},t.prototype.brushSelector=function(e,t,n){return n.point(t.getItemLayout(e))},t.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},t.type="series.scatter",t.dependencies=["grid","polar","geo","singleAxis","calendar"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}},t}(h1),b5=function(){},b4=function(e){function t(t){var n=e.call(this,t)||this;return n._off=0,n.hoverDataIdx=-1,n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new b5},t.prototype.reset=function(){this.notClear=!1,this._off=0},t.prototype.buildPath=function(e,t){var n,i=t.points,r=t.size,o=this.symbolProxy,a=o.shape,s=e.getContext?e.getContext():e,l=s&&r[0]<4,d=this.softClipShape;if(l){this._ctx=s;return}for(this._ctx=null,n=this._off;n<i.length;){var u=i[n++],c=i[n++];!(isNaN(u)||isNaN(c))&&(!d||d.contain(u,c))&&(a.x=u-r[0]/2,a.y=c-r[1]/2,a.width=r[0],a.height=r[1],o.buildPath(e,a,!0))}this.incremental&&(this._off=n,this.notClear=!0)},t.prototype.afterBrush=function(){var e,t=this.shape,n=t.points,i=t.size,r=this._ctx,o=this.softClipShape;if(r){for(e=this._off;e<n.length;){var a=n[e++],s=n[e++];!(isNaN(a)||isNaN(s))&&(!o||o.contain(a,s))&&r.fillRect(a-i[0]/2,s-i[1]/2,i[0],i[1])}this.incremental&&(this._off=e,this.notClear=!0)}},t.prototype.findDataIndex=function(e,t){for(var n=this.shape,i=n.points,r=n.size,o=Math.max(r[0],4),a=Math.max(r[1],4),s=i.length/2-1;s>=0;s--){var l=2*s,d=i[l]-o/2,u=i[l+1]-a/2;if(e>=d&&t>=u&&e<=d+o&&t<=u+a)return s}return -1},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t),i=this.getBoundingRect
422();return(e=n[0],t=n[1],i.contain(e,t))?(this.hoverDataIdx=this.findDataIndex(e,t))>=0:(this.hoverDataIdx=-1,!1)},t.prototype.getBoundingRect=function(){var e=this._rect;if(!e){for(var t=this.shape,n=t.points,i=t.size,r=i[0],o=i[1],a=1/0,s=1/0,l=-1/0,d=-1/0,u=0;u<n.length;){var c=n[u++],h=n[u++];a=Math.min(c,a),l=Math.max(c,l),s=Math.min(h,s),d=Math.max(h,d)}e=this._rect=new rt(a-r/2,s-o/2,l-a+r,d-s+o)}return e},t}(lk),b6=function(){function e(){this.group=new av}return e.prototype.updateData=function(e,t){this._clear();var n=this._create();n.setShape({points:e.getLayout("points")}),this._setCommon(n,e,t)},e.prototype.updateLayout=function(e){var t=e.getLayout("points");this.group.eachChild(function(e){if(null!=e.startIndex){var n=(e.endIndex-e.startIndex)*2,i=4*e.startIndex*2;t=new Float32Array(t.buffer,i,n)}e.setShape("points",t),e.reset()})},e.prototype.incrementalPrepareUpdate=function(e){this._clear()},e.prototype.incrementalUpdate=function(e,t,n){var i=this._newAdded[0],r=t.getLayout("points"),o=i&&i.shape.points;if(o&&o.length<2e4){var a=o.length,s=new Float32Array(a+r.length);s.set(o),s.set(r,a),i.endIndex=e.end,i.setShape({points:s})}else{this._newAdded=[];var l=this._create();l.startIndex=e.start,l.endIndex=e.end,l.incremental=!0,l.setShape({points:r}),this._setCommon(l,t,n)}},e.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},e.prototype._create=function(){var e=new b4({cursor:"default"});return e.ignoreCoarsePointer=!0,this.group.add(e),this._newAdded.push(e),e},e.prototype._setCommon=function(e,t,n){var i=t.hostModel;n=n||{};var r=t.getVisual("symbolSize");e.setShape("size",r instanceof Array?r:[r,r]),e.softClipShape=n.clipShape||null,e.symbolProxy=g_(t.getVisual("symbol"),0,0,0,0),e.setColor=e.symbolProxy.setColor;var o=e.shape.size[0]<4;e.useStyle(i.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var a=t.getVisual("style"),s=a&&a.fill;s&&e.setColor(s);var l=lQ(e);l.seriesIndex=i.seriesIndex,e.on("mousemove",function(t){l.dataIndex=null;var n=e.hoverDataIdx;n>
vendor: 6,100 bytes, line 422
422=0&&(l.dataIndex=n+(e.startIndex||0))})},e.prototype.remove=function(){this._clear()},e.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},e}(),b8=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=e.getData();this._updateSymbolDraw(i,e).updateData(i,{clipShape:this._getClipShape(e)}),this._finished=!0},t.prototype.incrementalPrepareRender=function(e,t,n){var i=e.getData();this._updateSymbolDraw(i,e).incrementalPrepareUpdate(i),this._finished=!1},t.prototype.incrementalRender=function(e,t,n){this._symbolDraw.incrementalUpdate(e,t.getData(),{clipShape:this._getClipShape(t)}),this._finished=e.end===t.getData().count()},t.prototype.updateTransform=function(e,t,n){var i=e.getData();if(this.group.dirty(),!this._finished||i.count()>1e4)return{update:!0};var r=yH("").reset(e,t,n);r.progress&&r.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},t.prototype.eachRendered=function(e){this._symbolDraw&&this._symbolDraw.eachRendered(e)},t.prototype._getClipShape=function(e){if(e.get("clip",!0)){var t=e.coordinateSystem;return t&&t.getArea&&t.getArea(.1)}},t.prototype._updateSymbolDraw=function(e,t){var n=this._symbolDraw,i=t.pipelineContext.large;return n&&i===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=i?new b6:new yg,this._isLargeDraw=i,this.group.removeAll()),this.group.add(n.group),n},t.prototype.remove=function(e,t){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},t.prototype.dispose=function(){},t.type="scatter",t}(fI),b7=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.type="grid",t.dependencies=["xAxis","yAxis"],t.layoutMode="box",t.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},t}(u5),b9=function(){function e(){}return e.prototype.getNeedCrossZero=function(){return!this.option.scale},e.prototype.getCoordSysModel=function(){},e}(),xe=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",si).models[0]},t.type="cartesian2dAxis",t}(u5);nb(xe,b9);var xt={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},xn=nh({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},xt),xi=nh({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},xt),xr=nh({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},xi),xo=ng({logBase:10},xi);let xa={category:xn,value:xi,time:xr,log:xo};var xs=0,xl=function(){function e(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++xs}return e.createByAxisModel=function(t){var n=t.option,i=n.data,r=i&&nC(i,xd);return new e({categories:r,needCollect:!r,deduplication:!1!==n.dedplication})},e.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},e.prototype.parseAndCollect=function(e){var t,n=this._needCollect;if(!nA(e)&&!n)return e;if(n&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,t;var i=this._getOrCreateMap();return null==(t=i.get(e))&&(n?(t=this.categories.length,this.categories[t]=e,i.set(e,t)):t=NaN),t},e.prototype._getOrCreateMap=function(){return this._map||(this._map=n1(this.categories))},e}();function xd(e){return nL(e)&&null!=e.value?e.value:e+""}var xu={value:1,category:1,time:1,log:1};function xc(e,t,n,i){nw(xu,function(r,o){var a=nh(nh({},xa[o],!0),i,!0),s=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t+"Axis."+o,n}return(0,tQ.__extends)(n,e),n.prototype.mergeDefaultAndTheme=function(e,t){var n=uQ(this),i=n?u1(e):{};nh(e,t.getTheme().get(o+"Axis")),nh(e,this.getDefaultOption()),e.type=xh(e),n&&u0(e,i,n)},n.prototype.optionUpdated=function(){"category"===this.option.type&&(this.__ordinalMeta=xl.createByAxisModel(this))},n.prototype.getCategories=function(e){var t=this.option;if("category"===t.type)return e?t.data:this.__ordinalMeta.categories},n.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},n.type=t+"Axis."+o,n.defaultOption=a,n}(n);e.registerComponentModel(s)}),e.registerSubTypeDefaulter(t+"Axis",xh)}function xh(e){return e.type||(e.data?"category":"value")}var xp=function(){function e(e){this._setting=e||{},this._extent=[1/0,-1/0]}return e.prototype.getSetting=function(e){return this._setting[e]},e.prototype.unionExtent=function(e){var t=this._extent;e[0]<t[0]&&(t[0]=e[0]),e[1]>t[1]&&(t[1]=e[1])},e.prototype.unionExtentFromData=function(e,t){this.unionExtent(e.getApproximateExtent(t))},e.prototype.getExtent=function(){return this._extent.slice()},e.prototype.setExtent=function(e,t){var n=this._extent;isNaN(e)||(n[0]=e),isNaN(t)||(n[1]=t)},e.prototype.isInExtentRange=function(e){return this._extent[0]<=e&&this._extent[1]>=e},e.prototype.isBlank=function(){return this._isBlank},e.prototype.setBlank=function(e){this._isBlank=e},e}();function xf(e){return"interval"===e.type||"log"===e.type}function xg(e){var t=Math.pow(10,aH(e)),n=e/t;
422return n?2===n?n=3:3===n?n=5:n*=2:n=1,aI(n*t)}sv(xp);function xm(e,t,n){e[t]=Math.max(Math.min(e[t],n[1]),n[0])}function xv(e,t){return e>=t[0]&&e<=t[1]}function xy(e,t){return t[1]===t[0]?.5:(e-t[0])/(t[1]-t[0])}function xb(e,t){return e*(t[1]-t[0])+t[0]}var xx=function(e){function t(t){var n=e.call(this,t)||this;n.type="ordinal";var i=n.getSetting("ordinalMeta");return i||(i=new xl({})),nR(i)&&(i=new xl({categories:nC(i,function(e){return nL(e)?e.value:e})})),n._ordinalMeta=i,n._extent=n.getSetting("extent")||[0,i.categories.length-1],n}return(0,tQ.__extends)(t,e),t.prototype.parse=function(e){return null==e?NaN:nA(e)?this._ordinalMeta.getOrdinal(e):Math.round(e)},t.prototype.contain=function(e){return xv(e=this.parse(e),this._extent)&&null!=this._ordinalMeta.categories[e]},t.prototype.normalize=function(e){return xy(e=this._getTickNumber(this.parse(e)),this._extent)},t.prototype.scale=function(e){return e=Math.round(xb(e,this._extent)),this.getRawOrdinalNumber(e)},t.prototype.getTicks=function(){for(var e=[],t=this._extent,n=t[0];n<=t[1];)e.push({value:n}),n++;return e},t.prototype.getMinorTicks=function(e){},t.prototype.setSortInfo=function(e){if(null==e){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var t=e.ordinalNumbers,n=this._ordinalNumbersByTick=[],i=this._ticksByOrdinalNumber=[],r=0,o=this._ordinalMeta.categories.length,a=Math.min(o,t.length);r<a;++r){var s=t[r];n[r]=s,i[s]=r}for(var l=0;r<o;++r){for(;null!=i[l];)l++;n.push(l),i[l]=r}},t.prototype._getTickNumber=function(e){var t=this._ticksByOrdinalNumber;return t&&e>=0&&e<t.length?t[e]:e},t.prototype.getRawOrdinalNumber=function(e){var t=this._ordinalNumbersByTick;return t&&e>=0&&e<t.length?t[e]:e},t.prototype.getLabel=function(e){if(!this.isBlank()){var t=this.getRawOrdinalNumber(e.value),n=this._ordinalMeta.categories[t];return null==n?"":n+""}},t.prototype.count=function(){return this._extent[1]-this._extent[0]+1},t.prototype.unionExtentFromData=function(e,t){this.unionExtent(e.getApproximateExtent(t))},t.prototype.isInExtentRange=function(e){return e=this._getTickNumber(e),this._extent[0]<=e&&this._extent[1]>=e},t.prototype.getOrdinalMeta=function(){return this._ordinalMeta},t.prototype.calcNiceTicks=function(){},t.prototype.calcNiceExtent=function(){},t.type="ordinal",t}(xp);xp.registerClass(xx);var xw=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}return(0,tQ.__extends)(t,e),t.prototype.parse=function(e){return e},t.prototype.contain=function(e){return xv(e,this._extent)},t.prototype.normalize=function(e){return xy(e,this._extent)},t.prototype.scale=function(e){return xb(e,this._extent)},t.prototype.setExtent=function(e,t){var n=this._extent;isNaN(e)||(n[0]=parseFloat(e)),isNaN(t)||(n[1]=parseFloat(t))},t.prototype.unionExtent=function(e){var t=this._extent;e[0]<t[0]&&(t[0]=e[0]),e[1]>t[1]&&(t[1]=e[1]),this.setExtent(t[0],t[1])},t.prototype.getInterval=function(){return this._interval},t.prototype.setInterval=function(e){this._interval=e,this._niceExtent=this._extent.slice(),this._intervalPrecision=aP(e)+2},t.prototype.getTicks=function(e){var t=this._interval,n=this._extent,i=this._niceExtent,r=this._intervalPrecision,o=[];if(!t)return o;n[0]<i[0]&&(e?o.push({value:aI(i[0]-t,r)}):o.push({value:n[0]}));for(var a=i[0];a<=i[1]&&(o.push({value:a}),(a=aI(a+t,r))!==o[o.length-1].value);)if(o.length>1e4)return[];var s=o.length?o[o.length-1].value:i[1];return n[1]>s&&(e?o.push({value:aI(s+t,r)}):o.push({value:n[1]})),o},t.prototype.getMinorTicks=function(e){for(var t=this.getTicks(!0),n=[],i=this.getExtent(),r=1;r<t.length;r++){for(var o=t[r],a=t[r-1],s=0,l=[],d=(o.value-a.value)/e;s<e-1;){var u=aI(a.value+(s+1)*d);u>i[0]&&u<i[1]&&l.push(u),s++}n.push(l)}return n},t.prototype.getLabel=function(e,t){if(null==e)return"";var n=t&&t.precision;return null==n?n=aP(e.value)||0:"auto"===n&&(n=this._intervalPrecision),uN(aI(e.value,n,!0))},t.prototype.calcNiceTicks=function(e,t,n){e=e||5;var i=this._extent,r=i[1]-i[0];if(isFinite(r)){r<0&&(r=-r,i.reverse());var o,a,s,l,d,u,c=(s=e,d=(l={}).interval=aG((i[1]-i[0])/s,!0),null!=t&&d<t&&(d=l.interval=t),null!=n&&d>n&&(d=l.interval=n),u=l.intervalPrecision=aP(d)+2,o=l.niceTickExtent=[aI(Math.ceil(i[0]/d)*d,u),aI(Math.floor(i[1]/d)*d,u)],a=i,isFinite(o[0])||(o[
4220]=a[0]),isFinite(o[1])||(o[1]=a[1]),xm(o,0,a),xm(o,1,a),o[0]>o[1]&&(o[0]=o[1]),l);this._intervalPrecision=c.intervalPrecision,this._interval=c.interval,this._niceExtent=c.niceTickExtent}},t.prototype.calcNiceExtent=function(e){var t=this._extent;if(t[0]===t[1])if(0!==t[0]){var n=Math.abs(t[0]);e.fixMax||(t[1]+=n/2),t[0]-=n/2}else t[1]=1;isFinite(t[1]-t[0])||(t[0]=0,t[1]=1),this.calcNiceTicks(e.splitNumber,e.minInterval,e.maxInterval);var i=this._interval;e.fixMin||(t[0]=aI(Math.floor(t[0]/i)*i)),e.fixMax||(t[1]=aI(Math.ceil(t[1]/i)*i))},t.prototype.setNiceExtent=function(e,t){this._niceExtent=[e,t]},t.type="interval",t}(xp);xp.registerClass(xw);var xC=function(e,t,n,i){for(;n<i;){var r=n+i>>>1;e[r][1]<t?n=r+1:i=r}return n},xS=function(e){function t(t){var n=e.call(this,t)||this;return n.type="time",n}return(0,tQ.__extends)(t,e),t.prototype.getLabel=function(e){var t=this.getSetting("useUTC");return uw(e.value,um[function(e){switch(e){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}(ux(this._minLevelUnit))]||um.second,t,this.getSetting("locale"))},t.prototype.getFormattedLabel=function(e,t,n){var i=this.getSetting("useUTC");return function(e,t,n,i,r){var o=null;if(nA(n))o=n;else if(nI(n))o=n(e.value,t,{level:e.level});else{var a=nf({},uf);if(e.level>0)for(var s=0;s<uv.length;++s)a[uv[s]]="{primary|"+a[uv[s]]+"}";var l=n?!1===n.inherit?n:ng(n,a):a,d=uC(e.value,r);if(l[d])o=l[d];else if(l.inherit){for(var u=uy.indexOf(d),s=u-1;s>=0;--s)if(l[d]){o=l[d];break}o=o||a.none}if(nR(o)){var c=null==e.level?0:e.level>=0?e.level:o.length+e.level;c=Math.min(c,o.length-1),o=o[c]}}return uw(new Date(e.value),o,r,i)}(e,t,n,this.getSetting("locale"),i)},t.prototype.getTicks=function(){var e=this._interval,t=this._extent,n=[];if(!e)return n;n.push({value:t[0],level:0});var i=this.getSetting("useUTC"),r=function(e,t,n,i){for(var r=0,o=[],a=[],s=0,l=0,d=0;d<uy.length&&r++<1e4;++d){var u,c=ux(uy[d]);if((u=uy[d])===ux(u)&&(!function(e,r,o){var a=[],s=!r.length;if(!function(e,t,n,i){var r=aj(t),o=aj(n),a=function(e){return uS(r,e,i)===uS(o,e,i)},s=function(){return a("year")},l=function(){return s()&&a("month")},d=function(){return l()&&a("day")},u=function(){return d()&&a("hour")},c=function(){return u()&&a("minute")},h=function(){return c()&&a("second")};switch(e){case"year":return s();case"month":return l();case"day":return d();case"hour":return u();case"minute":return c();case"second":return h();case"millisecond":return h()&&a("millisecond")}}(ux(e),i[0],i[1],n)){s&&(r=[{value:function(e,t,n){var i=new Date(e);switch(ux(t)){case"year":case"month":i[uA(n)](0);case"day":i[uP(n)](1);case"hour":i[uE(n)](0);case"minute":i[uL(n)](0);case"second":i[uF(n)](0),i[uO(n)](0)}return i.getTime()}(new Date(i[0]),e,n)},{value:i[1]}]);for(var l=0;l<r.length-1;l++){var d=r[l].value,u=r[l+1].value;if(d!==u){var c,h,p,f=void 0,g=void 0,m=void 0;switch(e){case"year":f=Math.max(1,Math.round(t/864e5/365)),g=u_(n),m=n?"setUTCFullYear":"setFullYear";break;case"half-year":case"quarter":case"month":f=(c=t/2592e6)>6?6:c>3?3:c>2?2:1,g=uk(n),m=uA(n);break;case"week":case"half-week":case"day":f=(h=t/864e5)>16?16:h>7.5?7:h>3.5?4:h>1.5?2:1,g=uM(n),m=uP(n);break;case"half-day":case"quarter-day":case"hour":f=(p=t/36e5)>12?12:p>6?6:p>3.5?4:p>2?2:1,g=uT(n),m=uE(n);break;case"minute":f=xk(t,!0),g=uD(n),m=uL(n);break;case"second":f=xk(t,!1),g=uR(n),m=uF(n);break;case"millisecond":f=aG(t,!0),g=uI(n),m=uO(n)}!function(e,t,n,r,o,a,s){for(var l=new Date(t),d=t,u=l[r]();d<n&&d<=i[1];)s.push({value:d}),u+=e,l[o](u),d=l.getTime();s.push({value:d,notAdd:!0})}(f,d,u,g,m,0,a),"year"===e&&o.length>1&&0===l&&o.unshift({value:o[0].value-f})}}for(var l=0;l<a.length;l++)o.push(a[l])}}(uy[d],o[o.length-1]||[],a),c!==(uy[d+1]?ux(uy[d+1]):null))){if(a.length){l=s,a.sort(function(e,t){return e.value-t.value});for(var h=[],p=0;p<a.length;++p){var f=a[p].value;(0===p||a[p-1].value!==f)&&(h.push(a[p]),f>=i[0]&&f<=i[1]&&s++)}var g=(i[1]-i[0])/t;if(s>1.5*g&&l>g/1.5||(o.push(h),s>g||e===uy[d]))break}a=[]}}for(var m=n_(nC(o,function(e){return n_(e,function(e){return e.value>=i[0]&&e.value<=i[1]&&!e.notAdd})}),function(e){return e.length>0}),v=[],y=m.length-1,d=0;d<m.length;++d)for(var b=m[d],x=0;x<b.length;++x)v.push({value:b[x].value,level:y-d});v.sort(function(e,t){return e.value-t.value});for(var w=[],d=0;d<v.length;++d)(0===d||v[d].value!==v[d-1].value)&&w.push(v[d]);return w}(this._minLevelUnit,this._approxInterval,i,t);return(n=n.concat(r)).push({value:t[1],level:0}),n},t.prototype.calcNiceExtent=function(e){var t=this._extent;if(t[0]===t[1]&&(t[0]-=864e5,t[1]+=864e5),t[1]===-1/0&&t[0]===1/0){var n=new Date;t[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),t[0]=t[1]-864e5}this.calcNiceTicks(e.splitNumber,e.minInterval,e.maxInterval)},t.prototype.calcNiceTicks=function(e,t,n){e=e||10;var i=this._extent,r=i[1]-i[0];this._approxInterval=r/e,null!=t&&this._approxInterval<t&&(this._approxInterval=t),null!=n&&this._approxInterval>n&&(this._approxInterval=n);var o=x_.length,a=Math.min(xC(x_,this._approxInterval,0,o),o-1);this._interval=x_[a][1],this._minLevelUnit=x_[Math.max(a-1,0)][0]},t.prototype.parse=function(e){return nE(e)?e:+aj(e)},t.prototype.contain=function(e){return xv(this.parse(e),this._extent)},t.prototype.normalize=function(e){return xy(this.parse(e),this._extent)},t.prototype.scale=function(e){return xb(e,this._extent)},t.type="time",t}(xw),x_=[["second",1e3],["minute",6e4],["hour",36e5],["quarter-day",216e5],["half-day",432e5],["day",10368e4],["half-week",3024e5],["week",6048e5],["month",26784e5],["quarter",8208e6],["half-year",15768e
4226],["year",31536e6]];function xk(e,t){return(e/=t?6e4:1e3)>30?30:e>20?20:e>15?15:e>10?10:e>5?5:e>2?2:1}xp.registerClass(xS);var xM=xp.prototype,xT=xw.prototype,xD=Math.floor,xR=Math.ceil,xI=Math.pow,xA=Math.log,xP=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new xw,t._interval=0,t}return(0,tQ.__extends)(t,e),t.prototype.getTicks=function(e){var t=this._originalScale,n=this._extent,i=t.getExtent();return nC(xT.getTicks.call(this,e),function(e){var t=e.value,r=aI(xI(this.base,t));return r=t===n[0]&&this._fixMin?aI(r,aP(i[0])):r,{value:r=t===n[1]&&this._fixMax?aI(r,aP(i[1])):r}},this)},t.prototype.setExtent=function(e,t){var n=xA(this.base);e=xA(Math.max(0,e))/n,t=xA(Math.max(0,t))/n,xT.setExtent.call(this,e,t)},t.prototype.getExtent=function(){var e,t,n=this.base,i=xM.getExtent.call(this);i[0]=xI(n,i[0]),i[1]=xI(n,i[1]);var r=this._originalScale.getExtent();return this._fixMin&&(i[0]=(e=i[0],aI(e,aP(r[0])))),this._fixMax&&(i[1]=(t=i[1],aI(t,aP(r[1])))),i},t.prototype.unionExtent=function(e){this._originalScale.unionExtent(e);var t=this.base;e[0]=xA(e[0])/xA(t),e[1]=xA(e[1])/xA(t),xM.unionExtent.call(this,e)},t.prototype.unionExtentFromData=function(e,t){this.unionExtent(e.getApproximateExtent(t))},t.prototype.calcNiceTicks=function(e){e=e||10;var t=this._extent,n=t[1]-t[0];if(n!==1/0&&!(n<=0)){var i=aV(n);for(e/n*i<=.5&&(i*=10);!isNaN(i)&&1>Math.abs(i)&&Math.abs(i)>0;)i*=10;var r=[aI(xR(t[0]/i)*i),aI(xD(t[1]/i)*i)];this._interval=i,this._niceExtent=r}},t.prototype.calcNiceExtent=function(e){xT.calcNiceExtent.call(this,e),this._fixMin=e.fixMin,this._fixMax=e.fixMax},t.prototype.parse=function(e){return e},t.prototype.contain=function(e){return xv(e=xA(e)/xA(this.base),this._extent)},t.prototype.normalize=function(e){return xy(e=xA(e)/xA(this.base),this._extent)},t.prototype.scale=function(e){return e=xb(e,this._extent),xI(this.base,e)},t.type="log",t}(xp),xE=xP.prototype;xE.getMinorTicks=xT.getMinorTicks,xE.getLabel=xT.getLabel,xp.registerClass(xP);var xL=function(){function e(e,t,n){this._prepareParams(e,t,n)}return e.prototype._prepareParams=function(e,t,n){n[1]<n[0]&&(n=[NaN,NaN]),this._dataMin=n[0],this._dataMax=n[1];var i=this._isOrdinal="ordinal"===e.type;this._needCrossZero="interval"===e.type&&t.getNeedCrossZero&&t.getNeedCrossZero();var r=t.get("min",!0);null==r&&(r=t.get("startValue",!0));var o=this._modelMinRaw=r;nI(o)?this._modelMinNum=xB(e,o({min:n[0],max:n[1]})):"dataMin"!==o&&(this._modelMinNum=xB(e,o));var a=this._modelMaxRaw=t.get("max",!0);if(nI(a)?this._modelMaxNum=xB(e,a({min:n[0],max:n[1]})):"dataMax"!==a&&(this._modelMaxNum=xB(e,a)),i)this._axisDataLen=t.getCategories().length;else{var s=t.get("boundaryGap"),l=nR(s)?s:[s||0,s||0];"boolean"==typeof l[0]||"boolean"==typeof l[1]?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[as(l[0],1),as(l[1],1)]}},e.prototype.calculate=function(){var e,t,n=this._isOrdinal,i=this._dataMin,r=this._dataMax,o=this._axisDataLen,a=this._boundaryGapInner,s=n?null:r-i||Math.abs(i),l="dataMin"===this._modelMinRaw?i:this._modelMinNum,d="dataMax"===this._modelMaxRaw?r:this._modelMaxNum,u=null!=l,c=null!=d;null==l&&(l=n?o?0:NaN:i-a[0]*s),null==d&&(d=n?o?o-1:NaN:r+a[1]*s),null!=l&&isFinite(l)||(l=NaN),null!=d&&isFinite(d)||(d=NaN);var h=(e=l)!=e||(t=d)!=t||n&&!o;this._needCrossZero&&(l>0&&d>0&&!u&&(l=0),l<0&&d<0&&!c&&(d=0));var p=this._determinedMin,f=this._determinedMax;return null!=p&&(l=p,u=!0),null!=f&&(d=f,c=!0),{min:l,max:d,minFixed:u,maxFixed:c,isBlank:h}},e.prototype.modifyDataMinMax=function(e,t){this[xO[e]]=t},e.prototype.setDeterminedMinMax=function(e,t){this[xF[e]]=t},e.prototype.freeze=function(){this.frozen=!0},e}(),xF={min:"_determinedMin",max:"_determinedMax"},xO={min:"_dataMin",max:"_dataMax"};function xN(e,t,n){var i=e.rawExtentInfo;return i||(i=new xL(e,t,n),e.rawExtentInfo=i),i}function xB(e,t){return null==t?null:t!=t?NaN:e.parse(t)}function xz(e,t){var n=e.type,i=xN(e,t,e.getExtent()).calculate();e.setBlank(i.isBlank);var r=i.min,o=i.max,a=t.ecModel;if(a&&"time"===n){var s=yY("bar",a),l=!1;if(nw(s,function(e){l=l||e.getBaseAxis()===t.axis}),l){var d=function(e,t,n,i){var r=n.axis.getExtent(),o=Math.abs(r[1]-r[0]),a=function(e,t,n){if(e&&t)return e[yK(t)]}(i,n.axis);if(void 0===a)return{min:e,max:t};var s=1/0;nw(a,function(e){s=Math.min(e.offset,s)});var l=-1/0;nw(a,function(e){l=Math.max(e.offset+e.width,l)});var d=(s=Math.abs(s))+(l=Math.abs(l)),u=t-e,c=u/(1-(s+l)/o)-u;return t+=l/d*c,{min:e-=s/d*c,max:t}}(r,o,t,yZ(s));r=d.min,o=d.max}}return{extent:[r,o],fixMin:i.minFixed,fixMax:i.maxFixed}}function xj(e,t){var n=xz(e,t),i=n.extent,r=t.get("splitNumber");e instanceof xP&&(e.base=t.get("logBase"));var o=e.type,a=t.get("interval"),s="interval"===o||"time"===o;e.setExtent(i[0],i[1]),e.calcNiceExtent({splitNumber:r,fixMin:n.fixMin,fixMax:n.fixMax,minInterval:s?t.get("minInterval"):null,maxInterval:s?t.get("maxInterval"):null}),null!=a&&e.setInterval&&e.setInterval(a)}function xV(e,t){if(t=t||e.get("type"))switch(t){case"category":return new xx({ordinalMeta:e.getOrdinalMeta?e.getOrdinalMeta():e.getCategories(),extent:[1/0,-1/0]});case"time":return new xS({locale:e.ecModel.getLocaleModel(),useUTC:e.ecModel.get("useUTC")});default:return new(xp.getClass(t)||xw)}}function xH(e){var t=e.getLabelModel().get("formatter"),n="category"===e.type?e.scale.getExtent()[0]:null;return"time"===e.scale.type?function(n,i){return e.scale.getFormattedLabel(n,i,t)}:nA(t)?function(n){var i=e.scale.getLabel(n);return t.replace("{value}",null!=i?i:"")}:nI(t)?function(i,r){return null!=n&&(r=i.value-n),t(xG(e,i),r,null!=i.level?{level:i.level}:null)}:function(t){return e.scale.getLabel(t)}}function xG(e,t){return"category"===e.type?e.scale.getLabel(t):t.value}function xW(e){var t=e.get("interval");return null==t?"auto":t}function x$(e){return"category"===e.type&&0===xW(e.getLabelModel())}function xU(e,t){var n={};return nw(e.mapDimensionsAll(t),function(t){n[yo(e,t)]=!0}),nM(n)}var xq=function(){function e(e){this.type="cartesian",this._dimList=[],this._axes={},this.name=e||""}return e.prototype.getAxis=function(e){return this._axes[e]},e.prototype.getAxes=function(){return nC(this._dimList,function(e){return this._axes[e]},this)},e.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),n_(this.getAxes(),function(t){return t.scale.type===e})},e.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},e}(),xK=["x","y"];function xY(e){return"interval"===e.type||"time"===e.type}var xZ=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=xK,t}return(0,tQ.__extends)(t,e),t.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var e=this.getAxis("x").scale,t=this.getAxis("y").scale;if(xY(e)&&xY(t)){var n=e.getExtent(),i=t.getExtent(),r=this.dataToPoint([n[0],i[0]]),o=this.dataToPoint([n[1],i[1]]),a=n[1]-n[0],s=i[1]-i[0];if(a&&s){var l=(o[0]-r[0])/a,d=(o[1]-r[1])/s,u=r[0]-n[0]*l,c=r[1]-i[0]*d,h=this._transform=[l,0,0,d,u,c];this._invTransform=i0([],h)}}},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},t.prototype.containPoint=function(e){var t=this.getAxis("x"),n=this.getAxis("y");return t.contain(t.toLocalCoord(e[0]))&&n.contain(n.toLocalCoord(e[1]))},t.prototype.containData=function(e){return this.getAxis("x").containData(e[0])&&this.getAxis("y").containData(e[1])},t.prototype.containZone=function(e,t){var n=this.dataToPoint(e),i=this.dataToPoint(t),r=this.getArea(),o=new rt(n[0],n[1],i[0]-n[0],i[1]-n[1]);return r.intersect(o)},t.prototype.dataToPoint=function(e,t,n){n=n||[];var i=e[0],r=e[1];if(this._transform&&null!=i&&isFinite(i)&&null!=r&&isFinite(r))return iy(n,e,this._transform);var o=this.getAxis("x"),a=this.getAxis("y");return n[0]=o.toGlobalCoord(o.dataToCoord(i,t)),n[1]=a.toGlobalCoord(a.dataToCoord(r,t)),n},t.prototype.clampData=function(e,t){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,r=n.getExtent(),o=i.getExtent(),a=n.parse(e[0]),s=i.parse(e[1]);return(t=t||[])[0]=Math.min(Math.max(Math.min(r[0],r[1]),a),Math.max(r[0],r[1])),t[1]=Math.min(Math.max(Math.min(o[0],o[1]),s),Math.max(o[0],o[1])),t},t.prototype.pointToData=function(e,t){var n=[];if(this._invTransform)return iy(n,e,this._invTransform);var i=this.getAxis("x"),r=this.getAxis("y");return n[0]=i.coordToData(i.toLocalCoord(e[0]),t),n[1]=r.coordToData(r.toLocalCoord(e[1]),t),n},t.prototype.getOtherAxis=function(e){return this.getAxis("x"===e.dim?"y":"x")},t.prototype.getArea=function(e){e=e||0;var t=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),i=Math.min(t[0],t[1])-e,r=Math.min(n[0],n[1])-e,o=Math.max(t[0],t[1])-i+e,a=Math.max(n[0],n[1])-r+e;return new rt(i,r,o,a)},t}(xq),xX=a9();function xJ(e,t){var n=nC(t,function(t){return e.scale.parse(t)});return"time"===e.type&&n.length>0&&(n.sort(),n.unshift(n[0]),n.push(n[n.length-1])),n}function xQ(e,t){var n,i,r,o,a=x0(e,"labels"),s=xW(t),l=x1(a,s);return l||(nI(s)?r=x5(e,s):(o="auto"===s?null!=(i=xX(n=e).autoInterval)?i:xX(n).autoInterval=n.calculateCategoryInterval():s,r=x3(e,o)),x2(a,s,{labels:r,labelCategoryInterval:o}))}function x0(e,t){return xX(e)[t]||(xX(e)[t]=[])}function x1(e,t){for(var n=0;n<e.length;n++)if(e[n].key===t)return e[n].value}function x2(e,t,n){return e.push({key:t,value:n}),n}function x3(e,t,n){var i=xH(e),r=e.scale,o=r.getExtent(),a=e.getLabelModel(),s=[],l=Math.max((t||0)+1,1),d=o[0],u=r.count();0!==d&&l>1&&u/l>2&&(d=Math.round(Math.ceil(d/l)*l));var c=x$(e),h=a.get("showMinLabel")||c,p=a.get("showMaxLabel")||c;h&&d!==o[0]&&g(o[0]);for(var f=d;f<=o[1];f+=l)g(f);function g(e){var t={value:e};s.push(n?e:{formattedLabel:i(t),rawLabel:r.getLabel(t),tickValue:e})}return p&&f-l!==o[1]&&g(o[1]),s}function x5(e,t,n){var i=e.scale,r=xH(e),o=[];return nw(i.getTicks(),function(e){var a=i.getLabel(e),s=e.value;t(e.value,a)&&o.push(n?s:{formattedLabel:r(e),rawLabel:a,tickValue:s})}),o}var x4=[0,1],x6=function(){function e(e,t,n){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=n||[0,0]}return e.prototype.contain=function(e){var t=this._extent,n=Math.min(t[0],t[1]),i=Math.max(t[0],t[1]);return e>=n&&e<=i},e.prototype.containData=function(e){return this.scale.contain(e)},e.prototype.getExtent=function(){return this._extent.slice()},e.prototype.getPixelPrecision=function(e){return aL(e||this.scale.getExtent(),this._extent)},e.prototype.setExtent=function(e,t){var n=this._extent;n[0]=e,n[1]=t},e.prototype.dataToCoord=function(e,t){var n=this._extent,i=this.scale;return e=i.normalize(e),this.onBand&&"ordinal"===i.type&&x8(n=n.slice(),i.count()),aD(e,x4,n,t)},e.prototype.coordToData=function(e,t){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&x8(n=n.slice(),i.count());var r=aD(e,n,x4,t);return this.scale.scale(r)},e.prototype.pointToData=function(e,t){},e.prototype.getTicksCoords=function(e){var t=(e=e||{}).tickModel||this.getTickModel(),n=function(e,t){var n=e.getTickModel().get("customValues");if(n){var i=e.scale.getExtent();
422return{ticks:n_(xJ(e,n),function(e){return e>=i[0]&&e<=i[1]})}}return"category"===e.type?function(e,t){var n,i,r=x0(e,"ticks"),o=xW(t),a=x1(r,o);if(a)return a;if((!t.get("show")||e.scale.isBlank())&&(n=[]),nI(o))n=x5(e,o,!0);else if("auto"===o){var s=xQ(e,e.getLabelModel());i=s.labelCategoryInterval,n=nC(s.labels,function(e){return e.tickValue})}else n=x3(e,i=o,!0);return x2(r,o,{ticks:n,tickCategoryInterval:i})}(e,t):{ticks:nC(e.scale.getTicks(),function(e){return e.value})}}(this,t).ticks,i=nC(n,function(e){return{coord:this.dataToCoord("ordinal"===this.scale.type?this.scale.getRawOrdinalNumber(e):e),tickValue:e}},this);return function(e,t,n,i){var r,o,a=t.length;if(e.onBand&&!n&&a){var s=e.getExtent();if(1===a)t[0].coord=s[0],r=t[1]={coord:s[1],tickValue:t[0].tickValue};else{var l=t[a-1].tickValue-t[0].tickValue,d=(t[a-1].coord-t[0].coord)/l;nw(t,function(e){e.coord-=d/2});var u=e.scale.getExtent();o=1+u[1]-t[a-1].tickValue,r={coord:t[a-1].coord+d*o,tickValue:u[1]+1},t.push(r)}var c=s[0]>s[1];h(t[0].coord,s[0])&&(i?t[0].coord=s[0]:t.shift()),i&&h(s[0],t[0].coord)&&t.unshift({coord:s[0]}),h(s[1],r.coord)&&(i?r.coord=s[1]:t.pop()),i&&h(r.coord,s[1])&&t.push({coord:s[1]})}function h(e,t){return e=aI(e),t=aI(t),c?e>t:e<t}}(this,i,t.get("alignWithLabel"),e.clamp),i},e.prototype.getMinorTicksCoords=function(){if("ordinal"===this.scale.type)return[];var e=this.model.getModel("minorTick").get("splitNumber");return e>0&&e<100||(e=5),nC(this.scale.getMinorTicks(e),function(e){return nC(e,function(e){return{coord:this.dataToCoord(e),tickValue:e}},this)},this)},e.prototype.getViewLabels=function(){return function(e){var t,n,i,r,o,a,s=e.getLabelModel().get("customValues");if(s){var l=xH(e),d=e.scale.getExtent();return{labels:nC(n_(xJ(e,s),function(e){return e>=d[0]&&e<=d[1]}),function(t){var n={value:t};return{formattedLabel:l(n),rawLabel:e.scale.getLabel(n),tickValue:t}})}}return"category"===e.type?(n=(t=e).getLabelModel(),i=xQ(t,n),!n.get("show")||t.scale.isBlank()?{labels:[],labelCategoryInterval:i.labelCategoryInterval}:i):(o=(r=e).scale.getTicks(),a=xH(r),{labels:nC(o,function(e,t){return{level:e.level,formattedLabel:a(e,t),rawLabel:r.scale.getLabel(e),tickValue:e.value}})})}(this).labels},e.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},e.prototype.getTickModel=function(){return this.model.getModel("axisTick")},e.prototype.getBandWidth=function(){var e=this._extent,t=this.scale.getExtent(),n=t[1]-t[0]+ +!!this.onBand;return 0===n&&(n=1),Math.abs(Math.abs(e[1]-e[0]))/n},e.prototype.calculateCategoryInterval=function(){return function(e){var t,n,i=(n=(t=e).getLabelModel(),{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:n.get("rotate")||0,font:n.getFont()}),r=xH(e),o=(i.axisRotate-i.labelRotate)/180*Math.PI,a=e.scale,s=a.getExtent(),l=a.count();if(s[1]-s[0]<1)return 0;var d=1;l>40&&(d=Math.max(1,Math.floor(l/40)));for(var u=s[0],c=e.dataToCoord(u+1)-e.dataToCoord(u),h=Math.abs(c*Math.cos(o)),p=Math.abs(c*Math.sin(o)),f=0,g=0;u<=s[1];u+=d){var m=0,v=0,y=ai(r({value:u}),i.font,"center","top");m=1.3*y.width,v=1.3*y.height,f=Math.max(f,m,7),g=Math.max(g,v,7)}var b=f/h,x=g/p;isNaN(b)&&(b=1/0),isNaN(x)&&(x=1/0);var w=Math.max(0,Math.floor(Math.min(b,x))),C=xX(e.model),S=e.getExtent(),_=C.lastAutoInterval,k=C.lastTickCount;return null!=_&&null!=k&&1>=Math.abs(_-w)&&1>=Math.abs(k-l)&&_>w&&C.axisExtent0===S[0]&&C.axisExtent1===S[1]?w=_:(C.lastTickCount=l,C.lastAutoInterval=w,C.axisExtent0=S[0],C.axisExtent1=S[1]),w}(this)},e}();function x8(e,t){var n=(e[1]-e[0])/t/2;e[0]+=n,e[1]-=n}var x7=function(e){function t(t,n,i,r,o){var a=e.call(this,t,n,i)||this;return a.index=0,a.type=r||"value",a.position=o||"bottom",a}return(0,tQ.__extends)(t,e),t.prototype.isHorizontal=function(){var e=this.position;return"top"===e||"bottom"===e},t.prototype.getGlobalExtent=function(e){var t=this.getExtent();return t[0]=this.toGlobalCoord(t[0]),t[1]=this.toGlobalCoord(t[1]),e&&t[0]>t[1]&&t.reverse(),t},t.prototype.pointToData=function(e,t){return this.coordToData(this.toLocalCoord(e[+("x"!==this.dim)]),t)},t.prototype.setCategorySortInfo=function(e){if("category"!==this.type)return!1;this.model.option.categorySortInfo=e,this.scale.setSortInfo(e)},t}(x6);function x9(e,t,n){n=n||{};var i=e.coordinateSystem,r=t.axis,o={},a=r.getAxesOnZeroOf()[0],s=r.position,l=a?"onZero":s,d=r.dim,u=i.getRect(),c=[u.x,u.x+u.width,u.y,u.y+u.he
422ight],h={left:0,right:1,top:0,bottom:1,onZero:2},p=t.get("offset")||0,f="x"===d?[c[2]-p,c[3]+p]:[c[0]-p,c[1]+p];if(a){var g=a.toGlobalCoord(a.dataToCoord(0));f[h.onZero]=Math.max(Math.min(g,f[1]),f[0])}o.position=["y"===d?f[h[l]]:c[0],"x"===d?f[h[l]]:c[3]],o.rotation=Math.PI/2*("x"!==d),o.labelDirection=o.tickDirection=o.nameDirection=({top:-1,bottom:1,left:-1,right:1})[s],o.labelOffset=a?f[h[s]]-f[h.onZero]:0,t.get(["axisTick","inside"])&&(o.tickDirection=-o.tickDirection),nH(n.labelInside,t.get(["axisLabel","inside"]))&&(o.labelDirection=-o.labelDirection);var m=t.get(["axisLabel","rotate"]);return o.labelRotate="top"===l?-m:m,o.z2=1,o}function we(e){return"cartesian2d"===e.get("coordinateSystem")}function wt(e){var t={xAxisModel:null,yAxisModel:null};return nw(t,function(n,i){var r=i.replace(/Model$/,""),o=e.getReferringComponents(r,si).models[0];t[i]=o}),t}var wn=Math.log;function wi(e,t,n){var i=xw.prototype,r=i.getTicks.call(n),o=i.getTicks.call(n,!0),a=r.length-1,s=i.getInterval.call(n),l=xz(e,t),d=l.extent,u=l.fixMin,c=l.fixMax;if("log"===e.type){var h=wn(e.base);d=[wn(d[0])/h,wn(d[1])/h]}e.setExtent(d[0],d[1]),e.calcNiceExtent({splitNumber:a,fixMin:u,fixMax:c});var p=i.getExtent.call(e);u&&(d[0]=p[0]),c&&(d[1]=p[1]);var f=i.getInterval.call(e),g=d[0],m=d[1];if(u&&c)f=(m-g)/a;else if(u)for(m=d[0]+f*a;m<d[1]&&isFinite(m)&&isFinite(d[1]);)f=xg(f),m=d[0]+f*a;else if(c)for(g=d[1]-f*a;g>d[0]&&isFinite(g)&&isFinite(d[0]);)f=xg(f),g=d[1]-f*a;else{e.getTicks().length-1>a&&(f=xg(f));var v=f*a;(g=aI((m=Math.ceil(d[1]/f)*f)-v))<0&&d[0]>=0?(g=0,m=aI(v)):m>0&&d[1]<=0&&(m=0,g=-aI(v))}var y=(r[0].value-o[0].value)/s,b=(r[a].value-o[a].value)/s;i.setExtent.call(e,g+f*y,m+f*b),i.setInterval.call(e,f),(y||b)&&i.setNiceExtent.call(e,g+f,m-f)}var wr=function(){function e(e,t,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=xK,this._initCartesian(e,t,n),this.model=e}return e.prototype.getRect=function(){return this._rect},e.prototype.update=function(e,t){var n=this._axesMap;function i(e){var t,n=nM(e),i=n.length;if(i){for(var r=[],o=i-1;o>=0;o--){var a=e[+n[o]],s=a.model,l=a.scale;xf(l)&&s.get("alignTicks")&&null==s.get("interval")?r.push(a):(xj(l,s),xf(l)&&(t=a))}r.length&&(t||xj((t=r.pop()).scale,t.model),nw(r,function(e){wi(e.scale,e.model,t.scale)}))}}this._updateScale(e,this.model),i(n.x),i(n.y);var r={};nw(n.x,function(e){wa(n,"y",e,r)}),nw(n.y,function(e){wa(n,"x",e,r)}),this.resize(this.model,t)},e.prototype.resize=function(e,t,n){var i=e.getBoxLayoutParams(),r=!n&&e.get("containLabel"),o=uX(i,{width:t.getWidth(),height:t.getHeight()});this._rect=o;var a=this._axesList;function s(){nw(a,function(e){var t,n,i,r,a=e.isHorizontal(),s=a?[0,o.width]:[0,o.height],l=+!!e.inverse;e.setExtent(s[l],s[1-l]),t=e,n=a?o.x:o.y,r=(i=t.getExtent())[0]+i[1],t.toGlobalCoord="x"===t.dim?function(e){return e+n}:function(e){return r-e+n},t.toLocalCoord="x"===t.dim?function(e){return e-n}:function(e){return r-e+n}})}s(),r&&(nw(a,function(e){if(!e.model.get(["axisLabel","inside"])){var t=function(e){var t,n,i,r=e.model,o=e.scale;if(!(!r.get(["axisLabel","show"])||o.isBlank())){var a=o.getExtent();n=o instanceof xx?o.count():(t=o.getTicks()).length;var s=e.getLabelModel(),l=xH(e),d=1;n>40&&(d=Math.ceil(n/40));for(var u=0;u<n;u+=d){var c=l(t?t[u]:{value:a[0]+u},u),h=function(e,t){var n=t*Math.PI/180,i=e.width,r=e.height,o=i*Math.abs(Math.cos(n))+Math.abs(r*Math.sin(n)),a=i*Math.abs(Math.sin(n))+Math.abs(r*Math.cos(n));return new rt(e.x,e.y,o,a)}(s.getTextRect(c),s.get("rotate")||0);i?i.union(h):i=h}return i}}(e);if(t){var n=e.isHorizontal()?"height":"width",i=e.model.get(["axisLabel","margin"]);o[n]-=t[n]+i,"top"===e.position?o.y+=t.height+i:"left"===e.position&&(o.x+=t.width+i)}}}),s()),nw(this._coordsList,function(e){e.calcAffineTransform()})},e.prototype.getAxis=function(e,t){var n=this._axesMap[e];if(null!=n)return n[t||0]},e.prototype.getAxes=function(){return this._axesList.slice()},e.prototype.getCartesian=function(e,t){if(null!=e&&null!=t){var n="x"+e+"y"+t;return this._coordsMap[n]}nL(e)&&(t=e.yAxisIndex,e=e.xAxisIndex);for(var i=0,r=this._coordsList;i<r.length;i++)if(r[i].getAxis("x").index===e||r[i].getAxis("y").index===t)return r[i]},e.prototype.getCartesians=function(){return this._coordsList.slice()},e.prototype.convertToPixel=function(e,t,n){var i=this._findConvertTarget(t);return i.cartesian?i.cartesian.dataToPoint(n):i.axis?i.axis.toGlobalCoord(i.axis.dataToCoord(n)):null},e.prototype.convertFromPixel=function(e,t,n){var i=this._findConvertTarget(t);return i.cartesian?i.cartesian.pointToData(n):i.axis?i.axis.coordToData(i.axis.toLocalCoord(n)):null},e.prototype._findConvertTarget=function(e){var t,n,i=e.seriesModel,r=e.xAxisModel||i&&i.getReferringComponents("xAxis",si).models[0],o=e.yAxisModel||i&&i.getReferringComponents("yAxis",si).models[0],a=e.gridModel,s=this._coordsList;return i?0>nv(s,t=i.coordinateSystem)&&(t=null):r&&o?t=this.getCartesian(r.componentIndex,o.componentIndex):r?n=this.getAxis("x",r.componentIndex):o?n=this.getAxis("y",o.componentIndex):a&&a.coordinateSystem===this&&(t=this._coordsList[0]),{cartesian:t,axis:n}},e.prototype.containPoint=function(e){var t=this._coordsList[0];if(t)return t.containPoint(e)},e.prototype._initCartesian=function(e,t,n){var i=this,r=this,o={left:!1,right:!1,top:!1,bottom:!1},a={x:{},y:{}},s={x:0,y:0};if(t.eachComponent("xAxis",l("x"),this),t.eachComponent("yAxis",l("y"),this),!s.x||!s.y){this._axesMap={},this._axesList=[];return}
422function l(t){return function(n,i){if(wo(n,e)){var l=n.get("position");"x"===t?"top"!==l&&"bottom"!==l&&(l=o.bottom?"top":"bottom"):"left"!==l&&"right"!==l&&(l=o.left?"right":"left"),o[l]=!0;var d=new x7(t,xV(n),[0,0],n.get("type"),l),u="category"===d.type;d.onBand=u&&n.get("boundaryGap"),d.inverse=n.get("inverse"),n.axis=d,d.model=n,d.grid=r,d.index=i,r._axesList.push(d),a[t][i]=d,s[t]++}}}this._axesMap=a,nw(a.x,function(t,n){nw(a.y,function(r,o){var a="x"+n+"y"+o,s=new xZ(a);s.master=i,s.model=e,i._coordsMap[a]=s,i._coordsList.push(s),s.addAxis(t),s.addAxis(r)})})},e.prototype._updateScale=function(e,t){function n(e,t){nw(xU(e,t.dim),function(n){t.scale.unionExtentFromData(e,n)})}nw(this._axesList,function(e){if(e.scale.setExtent(1/0,-1/0),"category"===e.type){var t=e.model.get("categorySortInfo");e.scale.setSortInfo(t)}}),e.eachSeries(function(e){if(we(e)){var i=wt(e),r=i.xAxisModel,o=i.yAxisModel;if(wo(r,t)&&wo(o,t)){var a=this.getCartesian(r.componentIndex,o.componentIndex),s=e.getData(),l=a.getAxis("x"),d=a.getAxis("y");n(s,l),n(s,d)}}},this)},e.prototype.getTooltipAxes=function(e){var t=[],n=[];return nw(this.getCartesians(),function(i){var r=null!=e&&"auto"!==e?i.getAxis(e):i.getBaseAxis(),o=i.getOtherAxis(r);0>nv(t,r)&&t.push(r),0>nv(n,o)&&n.push(o)}),{baseAxes:t,otherAxes:n}},e.create=function(t,n){var i=[];return t.eachComponent("grid",function(r,o){var a=new e(r,t,n);a.name="grid_"+o,a.resize(r,n,!0),r.coordinateSystem=a,i.push(a)}),t.eachSeries(function(e){if(we(e)){var t=wt(e),n=t.xAxisModel,i=t.yAxisModel;e.coordinateSystem=n.getCoordSysModel().coordinateSystem.getCartesian(n.componentIndex,i.componentIndex)}}),i},e.dimensions=xK,e}();function wo(e,t){return e.getCoordSysModel()===t}function wa(e,t,n,i){n.getAxesOnZeroOf=function(){return r?[r]:[]};var r,o=e[t],a=n.model,s=a.get(["axisLine","onZero"]),l=a.get(["axisLine","onZeroAxisIndex"]);if(s){if(null!=l)ws(o[l])&&(r=o[l]);else for(var d in o)if(o.hasOwnProperty(d)&&ws(o[d])&&!i[u(o[d])]){r=o[d];break}r&&(i[u(r)]=!0)}function u(e){return e.dim+"_"+e.index}}function ws(e){var t,n,i;return e&&"category"!==e.type&&"time"!==e.type&&(n=(t=e.scale.getExtent())[0],i=t[1],!(n>0&&i>0||n<0&&i<0))}var wl=Math.PI,wd=function(){function e(e,t){this.group=new av,this.opt=t,this.axisModel=e,ng(t,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var n=new av({x:t.position[0],y:t.position[1],rotation:t.rotation});n.updateTransform(),this._transformGroup=n}return e.prototype.hasBuilder=function(e){return!!wu[e]},e.prototype.add=function(e){wu[e](this.opt,this.axisModel,this.group,this._transformGroup)},e.prototype.getGroup=function(){return this.group},e.innerTextLayout=function(e,t,n){var i,r,o=aN(t-e);return aB(o)?(r=n>0?"top":"bottom",i="center"):aB(o-wl)?(r=n>0?"bottom":"top",i="center"):(r="middle",i=o>0&&o<wl?n>0?"right":"left":n>0?"left":"right"),{rotation:o,textAlign:i,textVerticalAlign:r}},e.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+"Index"]=e.componentIndex,t},e.isLabelSilent=function(e){var t=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||t&&t.show)},e}(),wu={axisLine:function(e,t,n,i){var r=t.get(["axisLine","show"]);if("auto"===r&&e.handleAutoShown&&(r=e.handleAutoShown("axisLine")),r){var o=t.axis.getExtent(),a=i.transform,s=[o[0],0],l=[o[1],0],d=s[0]>l[0];a&&(iy(s,s,a),iy(l,l,a));var u=nf({lineCap:"round"},t.getModel(["axisLine","lineStyle"]).getLineStyle()),c=new pU({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:u,strokeContainThreshold:e.strokeContainThreshold||5,silent:!0,z2:1});fp(c.shape,c.style.lineWidth),c.anid="line",n.add(c);var h=t.get(["axisLine","symbol"]);if(null!=h){var p=t.get(["axisLine","symbolSize"]);nA(h)&&(h=[h,h]),(nA(p)||nE(p))&&(p=[p,p]);var f=gM(t.get(["axisLine","symbolOffset"])||0,p),g=p[0],m=p[1];nw([{rotate:e.rotation+Math.PI/2,offset:f[0],r:0},{rotate:e.rotation-Math.PI/2,offset:f[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],function(t,i){if("none"!==h[i]&&null!=h[i]){var r=g_(h[i],-g/2,-m/2,g,m,u.stroke,!0),o=t.r+t.offset,a=d?l:s;r.attr({rotation:t.rotate,x:a[0]+o*Math.cos(e.rotation),y:a[1]-o*Math.sin(e.rotation),silent:!0,z2:11}),n.add(r)}})}}},axisTickLabel:function(e,t,n,i){var r=function(e,t,n,i){var r=n.axis,o=n.getModel("axisTick"),a=o.get("show");if("auto"===a&&i.handleAutoShown&&(a=i.handleAutoShown("axisTick")),!(!a||r.scale.isBlank())){for(var s=o.getModel("lineStyle"),l=i.tickDirection*o.get("length"),d=wf(r.getTicksCoords(),t.transform,l,ng(s.getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])}),"ticks"),u=0;u<d.length;u++)e.add(d[u]);return d}}(n,i,t,e),o=function(e,t,n,i){var r=n.axis;if(!(!nH(i.axisLabelShow,n.get(["axisLabel","show"]))||r.scale.isBlank())){var o=n.getModel("axisLabel"),a=o.get("margin"),s=r.getViewLabels(),l=(nH(i.labelRotate,o.get("rotate"))||0)*wl/180,d=wd.innerTextLayout(i.rotation,l,i.labelDirection),u=n.getCategories&&n.getCategories(!0),c=[],h=wd.isLabelSilent(n),p=n.get("triggerEvent");return nw(s,function(l,f){var g="ordinal"===r.scale.type?r.scale.getRawOrdinalNumber(l.tickValue):l.tickValue,m=l.formattedLabel,v=l.rawLabel,y=o;if(u&&u[g]){var b=u[g];nL(b)&&b.textStyle&&(y=new ua(b.textStyle,o,n.ecModel))}var x=y.getTextColor()||n.get(["axisLine","lineStyle","color"]),w=r.dataToCoord(g),C=y.get
422Shallow("align",!0)||d.textAlign,S=nG(y.getShallow("alignMinLabel",!0),C),_=nG(y.getShallow("alignMaxLabel",!0),C),k=y.getShallow("verticalAlign",!0)||y.getShallow("baseline",!0)||d.textVerticalAlign,M=nG(y.getShallow("verticalAlignMinLabel",!0),k),T=nG(y.getShallow("verticalAlignMaxLabel",!0),k),D=new lj({x:w,y:i.labelOffset+i.labelDirection*a,rotation:d.rotation,silent:h,z2:10+(l.level||0),style:dZ(y,{text:m,align:0===f?S:f===s.length-1?_:C,verticalAlign:0===f?M:f===s.length-1?T:k,fill:nI(x)?x("category"===r.type?v:"value"===r.type?g+"":g,f):x})});if(D.anid="label_"+g,fk({el:D,componentModel:n,itemName:m,formatterParamsExtra:{isTruncated:function(){return D.isTruncated},value:v,tickIndex:f}}),p){var R=wd.makeAxisEventDataBase(n);R.targetType="axisLabel",R.value=v,R.tickIndex=f,"category"===r.type&&(R.dataIndex=g),lQ(D).eventData=R}t.add(D),D.updateTransform(),c.push(D),e.add(D),D.decomposeTransform()}),c}}(n,i,t,e);(function(e,t,n){if(!x$(e.axis)){var i=e.get(["axisLabel","showMinLabel"]),r=e.get(["axisLabel","showMaxLabel"]);n=n||[];var o=(t=t||[])[0],a=t[1],s=t[t.length-1],l=t[t.length-2],d=n[0],u=n[1],c=n[n.length-1],h=n[n.length-2];!1===i?(wc(o),wc(d)):wh(o,a)&&(i?(wc(a),wc(u)):(wc(o),wc(d))),!1===r?(wc(s),wc(c)):wh(l,s)&&(r?(wc(l),wc(h)):(wc(s),wc(c)))}})(t,o,r),function(e,t,n,i){var r=n.axis,o=n.getModel("minorTick");if(!(!o.get("show")||r.scale.isBlank())){var a=r.getMinorTicksCoords();if(a.length)for(var s=o.getModel("lineStyle"),l=i*o.get("length"),d=ng(s.getLineStyle(),ng(n.getModel("axisTick").getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])})),u=0;u<a.length;u++)for(var c=wf(a[u],t.transform,l,d,"minorticks_"+u),h=0;h<c.length;h++)e.add(c[h])}}(n,i,t,e.tickDirection),t.get(["axisLabel","hideOverlap"])&&bU(bG(nC(o,function(e){return{label:e,priority:e.z2,defaultAttr:{ignore:e.ignore}}})))},axisName:function(e,t,n,i){var r,o,a=nH(e.axisName,t.get("name"));if(a){var s,l,d,u,c,h,p,f,g,m=t.get("nameLocation"),v=e.nameDirection,y=t.getModel("nameTextStyle"),b=t.get("nameGap")||0,x=t.axis.getExtent(),w=x[0]>x[1]?-1:1,C=["start"===m?x[0]-w*b:"end"===m?x[1]+w*b:(x[0]+x[1])/2,wp(m)?e.labelOffset+v*b:0],S=t.get("nameRotate");null!=S&&(S=S*wl/180),wp(m)?r=wd.innerTextLayout(e.rotation,null!=S?S:e.rotation,v):(s=e.rotation,l=m,d=S||0,u=x,p=aN(d-s),f=u[0]>u[1],g="start"===l&&!f||"start"!==l&&f,aB(p-wl/2)?(h=g?"bottom":"top",c="center"):aB(p-1.5*wl)?(h=g?"top":"bottom",c="center"):(h="middle",c=p<1.5*wl&&p>wl/2?g?"left":"right":g?"right":"left"),r={rotation:p,textAlign:c,textVerticalAlign:h},null!=(o=e.axisNameAvailableWidth)&&(isFinite(o=Math.abs(o/Math.sin(r.rotation)))||(o=null)));var _=y.getFont(),k=t.get("nameTruncate",!0)||{},M=k.ellipsis,T=nH(e.nameTruncateMaxWidth,k.maxWidth,o),D=new lj({x:C[0],y:C[1],rotation:r.rotation,silent:wd.isLabelSilent(t),style:dZ(y,{text:a,font:_,overflow:"truncate",width:T,ellipsis:M,fill:y.getTextColor()||t.get(["axisLine","lineStyle","color"]),align:y.get("align")||r.textAlign,verticalAlign:y.get("verticalAlign")||r.textVerticalAlign}),z2:1});if(fk({el:D,componentModel:t,itemName:a}),D.__fullText=a,D.anid="name",t.get("triggerEvent")){var R=wd.makeAxisEventDataBase(t);R.targetType="axisName",R.name=a,lQ(D).eventData=R}i.add(D),D.updateTransform(),n.add(D),D.decomposeTransform()}}};function wc(e){e&&(e.ignore=!0)}function wh(e,t){var n=e&&e.getBoundingRect().clone(),i=t&&t.getBoundingRect().clone();if(n&&i){var r=iK([]);return iJ(r,r,-e.rotation),n.applyTransform(iZ([],r,e.getLocalTransform())),i.applyTransform(iZ([],r,t.getLocalTransform())),n.intersect(i)}}function wp(e){return"middle"===e||"center"===e}function wf(e,t,n,i,r){for(var o=[],a=[],s=[],l=0;l<e.length;l++){var d=e[l].coord;a[0]=d,a[1]=0,s[0]=d,s[1]=n,t&&(iy(a,a,t),iy(s,s,t));var u=new pU({shape:{x1:a[0],y1:a[1],x2:s[0],y2:s[1]},style:i,z2:2,autoBatch:!0,silent:!0});fp(u.shape,u.style.lineWidth),u.anid=r+"_"+e[l].tickValue,o.push(u)}return o}function wg(e,t){return"all"===e||nR(e)&&nv(e,t)>=0||e===t}function wm(e){var t=(e.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return t&&t.axesInfo[wy(e)]}function wv(e){return!!e.get(["handle","show"])}function wy(e){return e.type+"||"+e.id}var wb={},ww=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(t,n,i,r){this.axisPointerClass&&function(e){var t=wm(e);if(t){var n=t.axisPointerModel,i=t.axis.scale,r=n.option,o=n.get("status"),a=n.get("value");null!=a&&(a=i.parse(a));var s=wv(n);null==o&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==a||a>l[1])&&(a=l[1]),a<l[0]&&(a=l[0]),r.value=a,s&&(r.status=t.axis.scale.isBlank()?"hide":"show")}}(t),e.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,i,!0)},t.prototype.updateAxisPointer=function(e,t,n,i){this._doUpdateAxisPointerClass(e,n,!1)},t.prototype.remove=function(e,t){var n=this._axisPointer;n&&n.remove(t)},t.prototype.dispose=function(t,n){this._disposeAxisPointer(n),e.prototype.dispose.apply(this,arguments)},t.prototype._doUpdateAxisPointerClass=function(e,n,i){var r=t.getAxisPointerClass(this.axisPointerClass);if(r){var o,a=(o=wm(e))&&o.axisPointerModel;a?(this._axisPointer||(this._axisPointer=new r)).render(e,a,n,i):this._disposeAxisPointer(n)}},t.prototype._disposeAxisPointer=function(e){this._axisPointer&&this._axisPointer.dispose(e),this._axisPointer=null},t.registerAxisPointerClass=function(e,t){wb[e]=t},t.getAxisPointerClass=function(e){return e&&wb[e]},t.type="axis",t}(h9),wC=a9();function wS(e,t,n,i){var r=n.axis;if(!r.scale.isBlank()){var o=n.getModel("splitArea"),a=o.getModel("areaStyle"),s=a.get("color"),l=i.coordinateSystem.getRect(),d=r.getTicksCoords({tickModel:o,clamp:!0});if(d.length){var u=s.length,c=wC(e).splitAreaColors,h=n1(),p=0;if(c)for(var f=0;f<d.length;f++){var g=c.get(d[f].tickValue);if(null!=g){p=(g+(u-1)*f)%u;break}}var m=r.toGlobalCoord(d[0].coord),v=a.getAreaStyle();s=nR(s)?s:[s];for(var f=1;f<d.length;f++){var y=r.toGlobalCoord(d[f].coord),b=void 0,x=void 0,w=void 0,C=void 0;r.isHorizontal()?(b=m,x=l.y,w=y-b,C=l.height,m=b+w):(b=l.x,x=m,w=l.width,C=y-x,m=x+C);var S=d[f-1].tickValue;null!=S&&h.set(S,p),t.add(new lN({anid:null!=S?"area_"+S:null,shape:{x:b,y:x,width:w,height:C},style:ng({fill:s[p]},v),autoBatch:!0,silent:!0})),p=(p+1)%u}wC(e).splitAreaColors=h}}}function w_(e){wC(e).splitAreaColors=null}var wk=["axisLine","axisTickLabel","axisName"],wM=["splitArea","splitLine","minorSplitLine"],wT=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.axisPointerClass="CartesianAxisPointer",n}return(0,tQ.__extends)(t,e),t.prototype.render=function(t,n,i,r){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new av,this.group.add(this._axisGroup),t.get("show")){var a=t.getCoordSysModel(),s=x9(a,t),l=new wd(t,nf({handleAutoShown:function(e){for(var n=a.coordinateSystem.getCartesians(),i=0;i<n.length;i++)if(xf(n[i].getOtherAxis(t.axis).scale))return!0;return!1}},s));nw(wk,l.add,l),this._axisGroup.add(l.getGroup()),nw(wM,function(e){t.get([e,"
422show"])&&wD[e](this,this._axisGroup,t,a)},this),r&&"changeAxisOrder"===r.type&&r.isInitSort||fb(o,this._axisGroup,t),e.prototype.render.call(this,t,n,i,r)}},t.prototype.remove=function(){w_(this)},t.type="cartesianAxis",t}(ww),wD={splitLine:function(e,t,n,i){var r=n.axis;if(!r.scale.isBlank()){var o=n.getModel("splitLine"),a=o.getModel("lineStyle"),s=a.get("color"),l=!1!==o.get("showMinLine"),d=!1!==o.get("showMaxLine");s=nR(s)?s:[s];for(var u=i.coordinateSystem.getRect(),c=r.isHorizontal(),h=0,p=r.getTicksCoords({tickModel:o}),f=[],g=[],m=a.getLineStyle(),v=0;v<p.length;v++){var y=r.toGlobalCoord(p[v].coord);if((0!==v||l)&&(v!==p.length-1||d)){var b=p[v].tickValue;c?(f[0]=y,f[1]=u.y,g[0]=y,g[1]=u.y+u.height):(f[0]=u.x,f[1]=y,g[0]=u.x+u.width,g[1]=y);var x=h++%s.length,w=new pU({anid:null!=b?"line_"+b:null,autoBatch:!0,shape:{x1:f[0],y1:f[1],x2:g[0],y2:g[1]},style:ng({stroke:s[x]},m),silent:!0});fp(w.shape,m.lineWidth),t.add(w)}}}},minorSplitLine:function(e,t,n,i){var r=n.axis,o=n.getModel("minorSplitLine").getModel("lineStyle"),a=i.coordinateSystem.getRect(),s=r.isHorizontal(),l=r.getMinorTicksCoords();if(l.length)for(var d=[],u=[],c=o.getLineStyle(),h=0;h<l.length;h++)for(var p=0;p<l[h].length;p++){var f=r.toGlobalCoord(l[h][p].coord);s?(d[0]=f,d[1]=a.y,u[0]=f,u[1]=a.y+a.height):(d[0]=a.x,d[1]=f,u[0]=a.x+a.width,u[1]=f);var g=new pU({anid:"minor_line_"+l[h][p].tickValue,autoBatch:!0,shape:{x1:d[0],y1:d[1],x2:u[0],y2:u[1]},style:c,silent:!0});fp(g.shape,c.lineWidth),t.add(g)}},splitArea:function(e,t,n,i){wS(e,t,n,i)}},wR=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="xAxis",t}(wT),wI=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=wR.type,t}return(0,tQ.__extends)(t,e),t.type="yAxis",t}(wT),wA=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="grid",t}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t){this.group.removeAll(),e.get("show")&&this.group.add(new lN({shape:e.coordinateSystem.getRect(),style:ng({fill:e.get("backgroundColor")},e.getItemStyle()),silent:!0,z2:-1}))},t.type="grid",t}(h9),wP={offset:0};function wE(e){e.registerComponentView(wA),e.registerComponentModel(b7),e.registerCoordinateSystem("cartesian2d",wr),xc(e,"x",xe,wP),xc(e,"y",xe,wP),e.registerComponentView(wR),e.registerComponentView(wI),e.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function wL(e){e.eachSeriesByType("radar",function(e){var t=e.getData(),n=[],i=e.coordinateSystem;if(i){var r=i.getIndicatorAxes();nw(r,function(e,o){t.each(t.mapDimension(r[o].dim),function(e,t){n[t]=n[t]||[];var r,a=i.dataToPoint(e,o);n[t][o]=wF(a)?a:[(r=i).cx,r.cy]})}),t.each(function(e){var r,o=nk(n[e],function(e){return wF(e)})||[(r=i).cx,r.cy];n[e].push(o.slice()),t.setItemLayout(e,n[e])})}})}function wF(e){return!isNaN(e[0])&&!isNaN(e[1])}function wO(e){var t=e.polar;if(t){nR(t)||(t=[t]);var n=[];nw(t,function(t,i){t.indicator?(t.type&&!t.shape&&(t.shape=t.type),e.radar=e.radar||[],nR(e.radar)||(e.radar=[e.radar]),e.radar.push(t)):n.push(t)}),e.polar=n}nw(e.series,function(e){e&&"radar"===e.type&&e.polarIndex&&(e.radarIndex=e.polarIndex)})}e.i(50142),e.s(["Arc",0,pJ,"BezierCurve",0,pZ,"BoundingRect",0,rt,"Circle",0,pw,"CompoundPath",0,pQ,"Ellipse",0,pS,"Group",0,av,"Image",0,lI,"IncrementalDisplayable",0,p9,"Line",0,pU,"LinearGradient",0,p1,"OrientedBoundingRect",0,p8,"Path",0,lk,"Point",0,i2,"Polygon",0,pV,"Polyline",0,pG,"RadialGradient",0,p2,"Rect",0,lN,"Ring",0,pB,"Sector",0,pO,"Text",0,lj,"applyTransform",()=>fv,"clipPointsByRect",()=>fx,"clipRectByRect",()=>fw,"createIcon",()=>fC,"extendPath",()=>fo,"extendShape",()=>fi,"getShapeClass",()=>fs,"getTransform",()=>fm,"groupTransition",()=>fb,"initProps",()=>dz,"isElementRemoved",()=>dj,"lineLineIntersect",()=>f_,"linePolygonIntersect",()=>fS,"makeImage",()=>fd,"makePath",()=>fl,"mergePath",()=>fc,"registerShape",()=>fa,"removeElement",()=>dV,"removeElementWithFadeOut",()=>dG,"resizePath",()=>fh,"setTooltipConfig",()=>fk,"subPixelOptimize",()=>fg,"subPixelOptimizeLine",()=>fp,"subPixelOptimizeRect",()=>ff,"transformDirection",()=>fy,"traverseElements",()=>fT,"updateProps",()=>dB],35448);var wN=e.i(35448),wB=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=e.coordinateSystem,r=this.group,o=e.getData(),a=this._data;function s(t,n,i,r,o,a){i.removeAll();for(var s=0;s<n.length-1;s++){var l=function(e,t){var n=e.getItemVisual(t,"symbol")||"circle";if("none"!==n){var i=gk(e.getItemVisual(t,"symbolSize")),r=g_(n,-1,-1,2,2),o=e.getItemVisual(t,"symbolRotate")||0;return r.attr({style:{strokeNoScale:!0},z2:100,scaleX:i[0]/2,scaleY:i[1]/2,rotation:o*Math.PI/180||0}),r}}(r,o);l&&(l.__dimIdx=s,t[s]?(l.setPosition(t[s]),wN[a?"initProps":"updateProps"](l,{x:n[s][0],y:n[s][1]},e,o)):l.setPosition(n[s]),i.add(l))}}function l(e){return nC(e,function(e){return[i.cx,i.cy]})}o.diff(a).add(function(t){var n=o.getItemLayout(t);if(n){var i=new wN.Polygon,r=new wN.Polyline,a={shape:{points:n}};i.shape.points=l(n),r.shape.points=l(n),wN.initProps(i,a,e,t),wN.initProps(r,a,e,t);var d=new wN.Group,u=new wN.Group;d.add(r),d.add(i),d.add(u),s(r.shape.points,n,u,o,t,!0),o.setItemGraphicEl(t,d)}}).update(function(t,n){var i=a.getItemGraphicEl(n),r=i.childAt(0),l=i.childAt(1),d=i.childAt(2),u={shape:{points:o.getItemLayout(t)}};u.shape.points&&(s(r.shape.points,u.shape.points,d,o,t,!1),dW(l),dW(r),wN.updateProps(r,u,e),wN.updateProps(l,u,e),o.setItemGraphicEl(t,i))}).remove(function(e){r.remove(a.getItemGraphicEl(e))}).execute(),o.eachItemGraphicEl(function(e,t){var n=o.getItemModel(t),i=e.childAt(0),a=e.childAt(1),s=e.childAt(2),l=o.getItemVisual(t,"style"),d=l.fill;
422r.add(e),i.useStyle(ng(n.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:d})),dI(i,n,"lineStyle"),dI(a,n,"areaStyle");var u=n.getModel("areaStyle"),c=u.isEmpty()&&u.parentModel.isEmpty();a.ignore=c,nw(["emphasis","select","blur"],function(e){var t=n.getModel([e,"areaStyle"]),i=t.isEmpty()&&t.parentModel.isEmpty();a.ensureState(e).ignore=i&&c}),a.useStyle(ng(u.getAreaStyle(),{fill:d,opacity:.7,decal:l.decal}));var h=n.getModel("emphasis"),p=h.getModel("itemStyle").getItemStyle();s.eachChild(function(e){if(e instanceof lI){var i=e.style;e.useStyle(nf({image:i.image,x:i.x,y:i.y,width:i.width,height:i.height},l))}else e.useStyle(l),e.setColor(d),e.style.strokeNoScale=!0;e.ensureState("emphasis").style=nc(p);var r=o.getStore().get(o.getDimensionIndex(e.__dimIdx),t);(null==r||isNaN(r))&&(r=""),dK(e,dY(n),{labelFetcher:o.hostModel,labelDataIndex:t,labelDimIndex:e.__dimIdx,defaultText:r,inheritColor:d,defaultOpacity:l.opacity})}),dM(e,h.get("focus"),h.get("blurScope"),h.get("disabled"))}),this._data=o},t.prototype.remove=function(){this.group.removeAll(),this._data=null},t.type="radar",t}(fI),wz=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t){e.prototype.init.apply(this,arguments),this.legendVisualProvider=new b0(nT(this.getData,this),nT(this.getRawData,this))},t.prototype.getInitialData=function(e,t){return bQ(this,{generateCoord:"indicator_",generateCoordCount:1/0})},t.prototype.formatTooltip=function(e,t,n){var i=this.getData(),r=this.coordinateSystem.getIndicatorAxes(),o=this.getData().getName(e),a=""===o?this.name:o,s=hK(this,e);return hV("section",{header:a,sortBlocks:!0,blocks:nC(r,function(t){var n=i.get(i.mapDimension(t.dim),e);return hV("nameValue",{markerType:"subItem",markerColor:s,name:t.name,value:n,sortParam:n})})})},t.prototype.getTooltipPosition=function(e){if(null!=e){for(var t=this.getData(),n=this.coordinateSystem,i=t.getValues(nC(n.dimensions,function(e){return t.mapDimension(e)}),e),r=0,o=i.length;r<o;r++)if(!isNaN(i[r])){var a=n.getIndicatorAxes();return n.coordToPoint(a[r].dataToCoord(i[r]),r)}}},t.type="series.radar",t.dependencies=["radar"],t.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},t}(h1),wj=xa.value;function wV(e,t){return ng({show:t},e)}var wH=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.optionUpdated=function(){var e=this.get("boundaryGap"),t=this.get("splitNumber"),n=this.get("scale"),i=this.get("axisLine"),r=this.get("axisTick"),o=this.get("axisLabel"),a=this.get("axisName"),s=this.get(["axisName","show"]),l=this.get(["axisName","formatter"]),d=this.get("axisNameGap"),u=this.get("triggerEvent"),c=nC(this.get("indicator")||[],function(c){null!=c.max&&c.max>0&&!c.min?c.min=0:null!=c.min&&c.min<0&&!c.max&&(c.max=0);var h=a;null!=c.color&&(h=ng({color:c.color},a));var p=nh(nc(c),{boundaryGap:e,splitNumber:t,scale:n,axisLine:i,axisTick:r,axisLabel:o,name:c.text,showName:s,nameLocation:"end",nameGap:d,nameTextStyle:h,triggerEvent:u},!1);if(nA(l)){var f=p.name;p.name=l.replace("{value}",null!=f?f:"")}else nI(l)&&(p.name=l(p.name,p));var g=new ua(p,null,this.ecModel);return nb(g,b9.prototype),g.mainType="radar",g.componentIndex=this.componentIndex,g},this);this._indicatorModels=c},t.prototype.getIndicatorModels=function(){return this._indicatorModels},t.type="radar",t.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:nh({lineStyle:{color:"#bbb"}},wj.axisLine),axisLabel:wV(wj.axisLabel,!1),axisTick:wV(wj.axisTick,!1),splitLine:wV(wj.splitLine,!0),splitArea:wV(wj.splitArea,!0),indicator:[]},t}(u5),wG=["axisLine","axisTickLabel","axisName"],wW=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){this.group.removeAll(),this._buildAxes(e),this._buildSplitLineAndArea(e)},t.prototype._buildAxes=function(e){var t=e.coordinateSystem;nw(nC(t.getIndicatorAxes(),function(e){var n=e.model.get("showName")?e.name:"";return new wd(e.model,{axisName:n,position:[t.cx,t.cy],rotation:e.angle,labelDirection:-1,tickDirection:-1,nameDirection:1})}),function(e){nw(wG,e.add,e),this.group.add(e.getGroup())},this)},t.prototype._buildSplitLineAndArea=function(e){var t=e.coordinateSystem,n=t.getIndicatorAxes();if(n.length){var i=e.get("shape"),r=e.getModel("splitLine"),o=e.getModel("splitArea"),a=r.getModel("lineStyle"),s=o.getModel("areaStyle"),l=r.get("show"),d=o.get("show"),u=a.get("color"),c=s.get("color"),h=nR(u)?u:[u],p=nR(c)?c:[c],f=[],g=[];if("circle"===i)for(var m=n[0].getTicksCoords(),v=t.cx,y=t.cy,b=0;b<m.length;b++){if(l){var x=D(f,h,b);f[x].push(new pw({shape:{cx:v,cy:y,r:m[b].coord}}))}if(d&&b<m.length-1){var x=D(g,p,b);g[x].push(new pB({shape:{cx:v,cy:y,r0:m[b].coord,r:m[b+1].coord}}))}}else for(var w,C=nC(n,function(e,n){var i=e.getTicksCoords();return w=null==w?i.length-1:Math.min(i.length-1,w),nC(i,function(e){return t.coordToPoint(e.coord,n)})}),S=[],b=0;b<=w;b++){for(var _=[],k=0;k<n.length;k++)_.push(C[k][b]);if(_[0]&&_.push(_[0].slice()),l){var x=D(f,h,b);f[x].push(new pG({shape:{points:_}}))}if(d&&S){var x=D(g,p,b-1);g[x].push(new pV({shape:{points:_.concat(S)}}))}S=_.slice().reverse()}var M=a.getLineStyle(),T=s.getAreaStyle();nw(g,function(e,t){this.group.add(fc(e,{style:ng({stroke:"none",fill:p[t%p.length]},T),silent:!0}))},this),nw(f,function(e,t){this.group.add(fc(e,{style:ng({fill:"none",stroke:h[t%h.length]},M),silent:!0}))},this)}function D(e,t,n){var i=n%t.length;return e[i]=e[i]||[],i}},t.type="radar",t}(h9),w$=function(e){function t(t,n,i){var r=e.call(this,t,n,i)||this;return r.type="value",r.angle=0,r.name="",r}return(0,tQ.__extends)(t,e),t}(x6),wU=function(){function e(e,t,n){this.dimensions=[],this._model=e,this._indicatorAxes=nC(e.getIndicatorModels(),function(e,t){var n="indicator_"+t,i=new w$(n,new xw);return i.name=e.get("name"),i.model=e,e.axis=i,this.dimensions.push(n),i},this),this.resize(e,n)}return e.prototype.getIndicatorAxes=function(){return this._indicatorAxes},e.prototype.dataToPoint=function(e,t){var n=this._indicatorAxes[t];return this.coordToPoint(n.dataToCoord(e),t)},e.prototype.coordToPoint=function(e,t){var n=this._indicatorAxes[t].angle;return[this.cx+e*Math.cos(n),this.cy-e*Math.sin(n)]},e.prototype.pointToData=function(e){var t,n=e[0]-this.cx,i=e[1]-this.cy,r=Math.sqrt(n*n+i*i);n/=r;for(var o=Math.atan2(-(i/=r),n),a=1/0,s=-1,l=0;l<this._indicatorAxes.length;l++){var d=this._indicatorAxes[l],u=Math.abs(o-d.angle);u<a&&(t=d,s=l,a=u)}
422return[s,+(t&&t.coordToData(r))]},e.prototype.resize=function(e,t){var n=e.get("center"),i=t.getWidth(),r=t.getHeight(),o=Math.min(i,r)/2;this.cx=aR(n[0],i),this.cy=aR(n[1],r),this.startAngle=e.get("startAngle")*Math.PI/180;var a=e.get("radius");(nA(a)||nE(a))&&(a=[0,a]),this.r0=aR(a[0],o),this.r=aR(a[1],o),nw(this._indicatorAxes,function(e,t){e.setExtent(this.r0,this.r);var n=this.startAngle+t*Math.PI*2/this._indicatorAxes.length;e.angle=Math.atan2(Math.sin(n),Math.cos(n))},this)},e.prototype.update=function(e,t){var n=this._indicatorAxes,i=this._model;nw(n,function(e){e.scale.setExtent(1/0,-1/0)}),e.eachSeriesByType("radar",function(t,r){if("radar"===t.get("coordinateSystem")&&e.getComponent("radar",t.get("radarIndex"))===i){var o=t.getData();nw(n,function(e){e.scale.unionExtentFromData(o,o.mapDimension(e.dim))})}},this);var r=i.get("splitNumber"),o=new xw;o.setExtent(0,r),o.setInterval(1),nw(n,function(e,t){wi(e.scale,e.model,o)})},e.prototype.convertToPixel=function(e,t,n){return console.warn("Not implemented."),null},e.prototype.convertFromPixel=function(e,t,n){return console.warn("Not implemented."),null},e.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},e.create=function(t,n){var i=[];return t.eachComponent("radar",function(r){var o=new e(r,t,n);i.push(o),r.coordinateSystem=o}),t.eachSeriesByType("radar",function(e){"radar"===e.get("coordinateSystem")&&(e.coordinateSystem=i[e.get("radarIndex")||0])}),i},e.dimensions=[],e}();function wq(e){e.registerCoordinateSystem("radar",wU),e.registerComponentModel(wH),e.registerComponentView(wW),e.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(e){t.setItemVisual(e,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}var wK="\0_ec_interaction_mutex";function wY(e){return e[wK]||(e[wK]={})}mP({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},n6);var wZ=function(e){function t(t){var n=e.call(this)||this;n._zr=t;var i=nT(n._mousedownHandler,n),r=nT(n._mousemoveHandler,n),o=nT(n._mouseupHandler,n),a=nT(n._mousewheelHandler,n),s=nT(n._pinchHandler,n);return n.enable=function(e,n){this.disable(),this._opt=ng(nc(n)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),null==e&&(e=!0),(!0===e||"move"===e||"pan"===e)&&(t.on("mousedown",i),t.on("mousemove",r),t.on("mouseup",o)),(!0===e||"scale"===e||"zoom"===e)&&(t.on("mousewheel",a),t.on("pinch",s))},n.disable=function(){t.off("mousedown",i),t.off("mousemove",r),t.off("mouseup",o),t.off("mousewheel",a),t.off("pinch",s)},n}return(0,tQ.__extends)(t,e),t.prototype.isDragging=function(){return this._dragging},t.prototype.isPinching=function(){return this._pinching},t.prototype.setPointerChecker=function(e){this.pointerChecker=e},t.prototype.dispose=function(){this.disable()},t.prototype._mousedownHandler=function(e){if(!iG(e)){for(var t=e.target;t;){if(t.draggable)return;t=t.__hostTarget||t.parent}var n=e.offsetX,i=e.offsetY;this.pointerChecker&&this.pointerChecker(e,n,i)&&(this._x=n,this._y=i,this._dragging=!0)}},t.prototype._mousemoveHandler=function(e){if(!(!this._dragging||!wQ("moveOnMouseMove",e,this._opt)||"pinch"===e.gestureEvent||wY(this._zr).globalPan)){var t=e.offsetX,n=e.offsetY,i=this._x,r=this._y;this._x=t,this._y=n,this._opt.preventDefaultMouseMove&&iH(e.event),wJ(this,"pan","moveOnMouseMove",e,{dx:t-i,dy:n-r,oldX:i,oldY:r,newX:t,newY:n,isAvailableBehavior:null})}},t.prototype._mouseupHandler=function(e){iG(e)||(this._dragging=!1)},t.prototype._mousewheelHandler=function(e){var t=wQ("zoomOnMouseWheel",e,this._opt),n=wQ("moveOnMouseWheel",e,this._opt),i=e.wheelDelta,r=Math.abs(i),o=e.offsetX,a=e.offsetY;if(0!==i&&(t||n)){if(t){var s=r>3?1.4:r>1?1.2:1.1;wX(this,"zoom","zoomOnMouseWheel",e,{scale:i>0?s:1/s,originX:o,originY:a,isAvailableBehavior:null})}if(n){var l=Math.abs(i);wX(this,"scrollMove","moveOnMouseWheel",e,{scrollDelta:(i>0?1:-1)*(l>3?.4:l>1?.15:.05),originX:o,originY:a,isAvailableBehavior:null})}}},t.prototype._pinchHandler=function(e){if(!wY(this._zr).globalPan){var t=e.pinchScale>1?1.1:1/1.1;wX(this,"zoom",null,e,{scale:t,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},t}(iS);function wX(e,t,n,i,r){e.pointerChecker&&e.pointerChecker(i,r.originX,r.originY)&&(iH(i.event),wJ(e,t,n,i,r))}function wJ(e,t,n,i,r){r.isAvailableBehavior=nT(wQ,null,n,i),e.trigger(t,r)}
vendor: 4,980 bytes, line 422
422function wQ(e,t,n){var i=n[e];return!e||i&&(!nA(i)||t.event[i+"Key"])}function w0(e,t,n){var i=e.target;i.x+=t,i.y+=n,i.dirty()}function w1(e,t,n,i){var r=e.target,o=e.zoomLimit,a=e.zoom=e.zoom||1;if(a*=t,o){var s=o.min||0;a=Math.max(Math.min(o.max||1/0,a),s)}var l=a/e.zoom;e.zoom=a,r.x-=(n-r.x)*(l-1),r.y-=(i-r.y)*(l-1),r.scaleX*=l,r.scaleY*=l,r.dirty()}var w2={axisPointer:1,tooltip:1,brush:1};function w3(e,t,n){var i=t.getComponentByElement(e.topTarget),r=i&&i.coordinateSystem;return i&&i!==n&&!w2.hasOwnProperty(i.mainType)&&r&&r.model!==n}function w5(e){nA(e)&&(e=new DOMParser().parseFromString(e,"text/xml"));var t=e;for(9===t.nodeType&&(t=t.firstChild);"svg"!==t.nodeName.toLowerCase()||1!==t.nodeType;)t=t.nextSibling;return t}var w4={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},w6=nM(w4),w8={"alignment-baseline":"textBaseline","stop-color":"stopColor"},w7=nM(w8),w9=function(){function e(){this._defs={},this._root=null}return e.prototype.parse=function(e,t){t=t||{};var n,i,r=w5(e);this._defsUsePending=[];var o=new av;this._root=o;var a=[],s=r.getAttribute("viewBox")||"",l=parseFloat(r.getAttribute("width")||t.width),d=parseFloat(r.getAttribute("height")||t.height);isNaN(l)&&(l=null),isNaN(d)&&(d=null),Co(r,o,null,!0,!1);for(var u=r.firstChild;u;)this._parseNode(u,o,a,null,!1,!1),u=u.nextSibling;if(function(e,t){for(var n=0;n<t.length;n++){var i=t[n];i[0].style[i[1]]=e[i[2]]}}(this._defs,this._defsUsePending),this._defsUsePending=[],s){var c=Cd(s);c.length>=4&&(n={x:parseFloat(c[0]||0),y:parseFloat(c[1]||0),width:parseFloat(c[2]),height:parseFloat(c[3])})}if(n&&null!=l&&null!=d&&(i=Cf(n,{x:0,y:0,width:l,height:d}),!t.ignoreViewBox)){var h=o;(o=new av).add(h),h.scaleX=h.scaleY=i.scale,h.x=i.x,h.y=i.y}return t.ignoreRootClip||null==l||null==d||o.setClipPath(new lN({shape:{x:0,y:0,width:l,height:d}})),{root:o,width:l,height:d,viewBoxRect:n,viewBoxTransform:i,named:a}},e.prototype._parseNode=function(e,t,n,i,r,o){var a,s=e.nodeName.toLowerCase(),l=i;if("defs"===s&&(r=!0),"text"===s&&(o=!0),"defs"===s||"switch"===s)a=t;else{if(!r){var d=et[s];if(d&&n4(et,s)){a=d.call(this,e,t);var u=e.getAttribute("name");if(u){var c={name:u,namedFrom:null,svgNodeTagLower:s,el:a};n.push(c),"g"===s&&(l=c)}else i&&n.push({name:i.name,namedFrom:i,svgNodeTagLower:s,el:a});t.add(a)}}var h=Ce[s];if(h&&n4(Ce,s)){var p=h.call(this,e),f=e.getAttribute("id");f&&(this._defs[f]=p)}}if(a&&a.isGroup)for(var g=e.firstChild;g;)1===g.nodeType?this._parseNode(g,a,n,l,r,o):3===g.nodeType&&o&&this._parseText(g,a),g=g.nextSibling},e.prototype._parseText=function(e,t){var n=new lT({style:{text:e.textContent},silent:!0,x:this._textX||0,y:this._textY||0});Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),function(e,t){var n=t.__selfStyle;if(n){var i=n.textBaseline,r=i;i&&"auto"!==i?"baseline"===i?r="alphabetic":"before-edge"===i||"text-before-edge"===i?r="top":"after-edge"===i||"text-after-edge"===i?r="bottom":("central"===i||"mathematical"===i)&&(r="middle"):r="alphabetic",e.style.textBaseline=r}var o=t.__inheritedStyle;if(o){var a=o.textAlign,s=a;a&&("middle"===a&&(s="center"),e.style.textAlign=s)}}(n,t);var i=n.style,r=i.fontSize;r&&r<9&&(i.fontSize=9,n.scaleX*=r/9,n.scaleY*=r/9);var o=(i.fontSize||i.fontFamily)&&[i.fontStyle,i.fontWeight,(i.fontSize||12)+"px",i.fontFamily||"sans-serif"].join(" ");i.font=o;var a=n.getBoundingRect();return this._textX+=a.width,t.add(n),n},e.internalField=void(et={g:function(e,t){var n=new av;return Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),n},rect:function(e,t){var n=new lN;return Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),n.setShape({x:parseFloat(e.getAttribute("x")||"0"),y:parseFloat(e.getAttribute("y")||"0"),width:parseFloat(e.getAttribute("width")||"0"),height:parseFloat(e.getAttribute("height")||"0")}),n.silent=!0,n},circle:function(e,t){var n=new pw;return Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),r:parseFloat(e.getAttribute("r")||"0")}),n.silent=!0,n},line:function(e,t){var n=new pU;return Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),n.setShape({x1:parseFloat(e.getAttribute("x1")||"0"),y1:parseFloat(e.getAttribute("y1")||"0"),x2:parseFloat(e.getAttribute("x2")||"0"),y2:parseFloat(e.getAttribute("y2")||"0")}),n.silent=!0,n},ellipse:function(e,t){var n=new pS;return Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),rx:parseFloat(e.getAttribute("rx")||"0"),ry:parseFloat(e.getAttribute("ry")||"0")}),n.silent=!0,n}
422,polygon:function(e,t){var n,i=e.getAttribute("points");i&&(n=Cr(i));var r=new pV({shape:{points:n||[]},silent:!0});return Ci(t,r),Co(e,r,this._defsUsePending,!1,!1),r},polyline:function(e,t){var n,i=e.getAttribute("points");i&&(n=Cr(i));var r=new pG({shape:{points:n||[]},silent:!0});return Ci(t,r),Co(e,r,this._defsUsePending,!1,!1),r},image:function(e,t){var n=new lI;return Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),n.setStyle({image:e.getAttribute("xlink:href")||e.getAttribute("href"),x:+e.getAttribute("x"),y:+e.getAttribute("y"),width:+e.getAttribute("width"),height:+e.getAttribute("height")}),n.silent=!0,n},text:function(e,t){var n=e.getAttribute("x")||"0",i=e.getAttribute("y")||"0",r=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0";this._textX=parseFloat(n)+parseFloat(r),this._textY=parseFloat(i)+parseFloat(o);var a=new av;return Ci(t,a),Co(e,a,this._defsUsePending,!1,!0),a},tspan:function(e,t){var n=e.getAttribute("x"),i=e.getAttribute("y");null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i));var r=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0",a=new av;return Ci(t,a),Co(e,a,this._defsUsePending,!1,!0),this._textX+=parseFloat(r),this._textY+=parseFloat(o),a},path:function(e,t){var n=new pm(py(e.getAttribute("d")||"",void 0));return Ci(t,n),Co(e,n,this._defsUsePending,!1,!1),n.silent=!0,n}}),e}(),Ce={lineargradient:function(e){var t=new p1(parseInt(e.getAttribute("x1")||"0",10),parseInt(e.getAttribute("y1")||"0",10),parseInt(e.getAttribute("x2")||"10",10),parseInt(e.getAttribute("y2")||"0",10));return Ct(e,t),Cn(e,t),t},radialgradient:function(e){var t=new p2(parseInt(e.getAttribute("cx")||"0",10),parseInt(e.getAttribute("cy")||"0",10),parseInt(e.getAttribute("r")||"0",10));return Ct(e,t),Cn(e,t),t}};function Ct(e,t){"userSpaceOnUse"===e.getAttribute("gradientUnits")&&(t.global=!0)}function Cn(e,t){for(var n=e.firstChild;n;){if(1===n.nodeType&&"stop"===n.nodeName.toLocaleLowerCase()){var i=n.getAttribute("offset"),r=void 0;r=i&&i.indexOf("%")>0?parseInt(i,10)/100:i?parseFloat(i):0;var o={};Cp(n,o,o);var a=o.stopColor||n.getAttribute("stop-color")||"#000000";t.colorStops.push({offset:r,color:a})}n=n.nextSibling}}function Ci(e,t){e&&e.__inheritedStyle&&(t.__inheritedStyle||(t.__inheritedStyle={}),ng(t.__inheritedStyle,e.__inheritedStyle))}function Cr(e){for(var t=Cd(e),n=[],i=0;i<t.length;i+=2){var r=parseFloat(t[i]),o=parseFloat(t[i+1]);n.push([r,o])}return n}function Co(e,t,n,i,r){var o=t.__inheritedStyle=t.__inheritedStyle||{},a={};1===e.nodeType&&(function(e,t){var n=e.getAttribute("transform");if(n){n=n.replace(/,/g," ");var i=[],r=null;n.replace(Cu,function(e,t,n){return i.push(t,n),""});for(var o=i.length-1;o>0;o-=2){var a=i[o],s=i[o-1],l=Cd(a);switch(r=r||iq(),s){case"translate":iX(r,r,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":iQ(r,r,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":iJ(r,r,-parseFloat(l[0])*Cc,[parseFloat(l[1]||"0"),parseFloat(l[2]||"0")]);break;case"skewX":iZ(r,[1,0,Math.tan(parseFloat(l[0])*Cc),1,0,0],r);break;case"skewY":iZ(r,[1,Math.tan(parseFloat(l[0])*Cc),0,1,0,0],r);break;case"matrix":r[0]=parseFloat(l[0]),r[1]=parseFloat(l[1]),r[2]=parseFloat(l[2]),r[3]=parseFloat(l[3]),r[4]=parseFloat(l[4]),r[5]=parseFloat(l[5])}}t.setLocalTransform(r)}}(e,t),Cp(e,o,a),i||function(e,t,n){for(var i=0;i<w6.length;i++){var r=w6[i],o=e.getAttribute(r);null!=o&&(t[w4[r]]=o)}for(var i=0;i<w7.length;i++){var r=w7[i],o=e.getAttribute(r);null!=o&&(n[w8[r]]=o)}}(e,o,a)),t.style=t.style||{},null!=o.fill&&(t.style.fill=Cs(t,"fill",o.fill,n)),null!=o.stroke&&(t.style.stroke=Cs(t,"stroke",o.stroke,n)),nw(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(e){null!=o[e]&&(t.style[e]=parseFloat(o[e]))}),nw(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign"],function(e){null!=o[e]&&(t.style[e]=o[e])}),r&&(t.__selfStyle=a),o.lineDash&&(t.style.lineDash=nC(Cd(o.lineDash),function(e){return parseFloat(e)})),("hidden"===o.visibility||"collapse"===o.visibility)&&(t.invisible=!0),"none"===o.display&&(t.ignore=!0)}var Ca=/^url\(\s*#(.*?)\)/;function Cs(e,t,n,i){var r=n&&n.match(Ca);if(r){var o=nK(r[1]);i.push([e,t,o]);return}return"none"===n&&(n=null),n}var Cl=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function Cd(e){return e.match(Cl)||[]}
vendor: 4,108 bytes, line 422
422var Cu=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.eE,]*)\)/g,Cc=Math.PI/180,Ch=/([^\s:;]+)\s*:\s*([^:;]+)/g;function Cp(e,t,n){var i,r=e.getAttribute("style");if(r)for(Ch.lastIndex=0;null!=(i=Ch.exec(r));){var o=i[1],a=n4(w4,o)?w4[o]:null;a&&(t[a]=i[2]);var s=n4(w8,o)?w8[o]:null;s&&(n[s]=i[2])}}function Cf(e,t){var n=Math.min(t.width/e.width,t.height/e.height);return{scale:n,x:-(e.x+e.width/2)*n+(t.x+t.width/2),y:-(e.y+e.height/2)*n+(t.y+t.height/2)}}function Cg(e,t){return 1e-8>Math.abs(e-t)}function Cm(e,t,n){var i=0,r=e[0];if(!r)return!1;for(var o=1;o<e.length;o++){var a=e[o];i+=lm(r[0],r[1],a[0],a[1],t,n),r=a}var s=e[0];return Cg(r[0],s[0])&&Cg(r[1],s[1])||(i+=lm(r[0],r[1],s[0],s[1],t,n)),0!==i}var Cv=[];function Cy(e,t){for(var n=0;n<e.length;n++)iy(e[n],e[n],t)}function Cb(e,t,n,i){for(var r=0;r<e.length;r++){var o=e[r];i&&(o=i.project(o)),o&&isFinite(o[0])&&isFinite(o[1])&&(ib(t,t,o),ix(n,n,o))}}var Cx=function(){function e(e){this.name=e}return e.prototype.setCenter=function(e){this._center=e},e.prototype.getCenter=function(){var e=this._center;return e||(e=this._center=this.calcCenter()),e},e}(),Cw=function(e,t){this.type="polygon",this.exterior=e,this.interiors=t},CC=function(e){this.type="linestring",this.points=e},CS=function(e){function t(t,n,i){var r=e.call(this,t)||this;return r.type="geoJSON",r.geometries=n,r._center=i&&[i[0],i[1]],r}return(0,tQ.__extends)(t,e),t.prototype.calcCenter=function(){for(var e,t=this.geometries,n=0,i=0;i<t.length;i++){var r=t[i],o=r.exterior,a=o&&o.length;a>n&&(e=r,n=a)}if(e)return function(e){for(var t=0,n=0,i=0,r=e.length,o=e[r-1][0],a=e[r-1][1],s=0;s<r;s++){var l=e[s][0],d=e[s][1],u=o*d-l*a;t+=u,n+=(o+l)*u,i+=(a+d)*u,o=l,a=d}return t?[n/t/3,i/t/3,t]:[e[0][0]||0,e[0][1]||0]}(e.exterior);var s=this.getBoundingRect();return[s.x+s.width/2,s.y+s.height/2]},t.prototype.getBoundingRect=function(e){var t=this._rect;if(t&&!e)return t;var n=[1/0,1/0],i=[-1/0,-1/0];return nw(this.geometries,function(t){"polygon"===t.type?Cb(t.exterior,n,i,e):nw(t.points,function(t){Cb(t,n,i,e)})}),isFinite(n[0])&&isFinite(n[1])&&isFinite(i[0])&&isFinite(i[1])||(n[0]=n[1]=i[0]=i[1]=0),t=new rt(n[0],n[1],i[0]-n[0],i[1]-n[1]),e||(this._rect=t),t},t.prototype.contain=function(e){var t=this.getBoundingRect(),n=this.geometries;if(!t.contain(e[0],e[1]))return!1;o:for(var i=0,r=n.length;i<r;i++){var o=n[i];if("polygon"===o.type){var a=o.exterior,s=o.interiors;if(Cm(a,e[0],e[1])){for(var l=0;l<(s?s.length:0);l++)if(Cm(s[l],e[0],e[1]))continue o;return!0}}}return!1},t.prototype.transformTo=function(e,t,n,i){var r=this.getBoundingRect(),o=r.width/r.height;n?i||(i=n/o):n=o*i;for(var a=new rt(e,t,n,i),s=r.calculateTransform(a),l=this.geometries,d=0;d<l.length;d++){var u=l[d];"polygon"===u.type?(Cy(u.exterior,s),nw(u.interiors,function(e){Cy(e,s)})):nw(u.points,function(e){Cy(e,s)})}(r=this._rect).copy(a),this._center=[r.x+r.width/2,r.y+r.height/2]},t.prototype.cloneShallow=function(e){null==e&&(e=this.name);var n=new t(e,this.geometries,this._center);return n._rect=this._rect,n.transformTo=null,n},t}(Cx),C_=function(e){function t(t,n){var i=e.call(this,t)||this;return i.type="geoSVG",i._elOnlyForCalculate=n,i}return(0,tQ.__extends)(t,e),t.prototype.calcCenter=function(){for(var e=this._elOnlyForCalculate,t=e.getBoundingRect(),n=[t.x+t.width/2,t.y+t.height/2],i=iK(Cv),r=e;r&&!r.isGeoSVGGraphicRoot;)iZ(i,r.getLocalTransform(),i),r=r.parent;return i0(i,i),iy(n,n,i),n},t}(Cx),Ck=n1(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),CM=function(){function e(e,t){this.type="geoSVG",this._usedGraphicMap=n1(),this._freedGraphics=[],this._mapName=e,this._parsedXML=w5(t)}return e.prototype.load=function(){var e=this._firstGraphic;if(!e){e=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(e),this._boundingRect=this._firstGraphic.boundingRect.clone();var t,n,i,r=(t=e.named,n=[],i=n1(),nw(t,function(e){if(null==e.namedFrom){var t=new C_(e.name,e.el);n.push(t),i.set(e.name,t)}}),{regions:n,regionsMap:i}),o=r.regions,a=r.regionsMap;this._regions=o,this._regionsMap=a}
422return{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},e.prototype._buildGraphic=function(e){try{var t;i=(n=e&&(t={ignoreViewBox:!0,ignoreRootClip:!0},new w9().parse(e,t))||{}).root,nq(null!=i)}catch(e){throw Error("Invalid svg format\n"+e.message)}var n,i,r=new av;r.add(i),r.isGeoSVGGraphicRoot=!0;var o=n.width,a=n.height,s=n.viewBoxRect,l=this._boundingRect;if(!l){var d=void 0,u=void 0,c=void 0,h=void 0;if(null!=o?(d=0,c=o):s&&(d=s.x,c=s.width),null!=a?(u=0,h=a):s&&(u=s.y,h=s.height),null==d||null==u){var p=i.getBoundingRect();null==d&&(d=p.x,c=p.width),null==u&&(u=p.y,h=p.height)}l=this._boundingRect=new rt(d,u,c,h)}if(s){var f=Cf(s,l);i.scaleX=i.scaleY=f.scale,i.x=f.x,i.y=f.y}r.setClipPath(new lN({shape:l.plain()}));var g=[];return nw(n.named,function(e){var t;null!=Ck.get(e.svgNodeTagLower)&&(g.push(e),(t=e.el).silent=!1,t.isGroup&&t.traverse(function(e){e.silent=!1}))}),{root:r,boundingRect:l,named:g}},e.prototype.useGraphic=function(e){var t=this._usedGraphicMap,n=t.get(e);return n||(n=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),t.set(e,n)),n},e.prototype.freeGraphic=function(e){var t=this._usedGraphicMap,n=t.get(e);n&&(t.removeKey(e),this._freedGraphics.push(n))},e}();function CT(e,t,n){for(var i=0;i<e.length;i++)e[i]=CD(e[i],t[i],n)}function CD(e,t,n){for(var i=[],r=t[0],o=t[1],a=0;a<e.length;a+=2){var s=e.charCodeAt(a)-64,l=e.charCodeAt(a+1)-64;l=l>>1^-(1&l),s=(s>>1^-(1&s))+r,l+=o,r=s,o=l,i.push([s/n,l/n])}return i}function CR(e,t){return nC(n_((e=function(e){if(!e.UTF8Encoding)return e;var t=e.UTF8Scale;return null==t&&(t=1024),nw(e.features,function(e){var n=e.geometry,i=n.encodeOffsets,r=n.coordinates;if(i)switch(n.type){case"LineString":n.coordinates=CD(r,i,t);break;case"Polygon":case"MultiLineString":CT(r,i,t);break;case"MultiPolygon":nw(r,function(e,n){return CT(e,i[n],t)})}}),e.UTF8Encoding=!1,e}(e)).features,function(e){return e.geometry&&e.properties&&e.geometry.coordinates.length>0}),function(e){var n=e.properties,i=e.geometry,r=[];switch(i.type){case"Polygon":var o=i.coordinates;r.push(new Cw(o[0],o.slice(1)));break;case"MultiPolygon":nw(i.coordinates,function(e){e[0]&&r.push(new Cw(e[0],e.slice(1)))});break;case"LineString":r.push(new CC([i.coordinates]));break;case"MultiLineString":r.push(new CC(i.coordinates))}var a=new CS(n[t||"name"],r,n.cp);return a.properties=n,a})}for(var CI=[126,25],CA="åæµ·è¯¸å²",CP=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]],CE=0;CE<CP.length;CE++)for(var CL=0;CL<CP[CE].length;CL++)CP[CE][CL][0]/=10.5,CP[CE][CL][1]/=-14,CP[CE][CL][0]+=CI[0],CP[CE][CL][1]+=CI[1];var CF={åæµ·è¯¸å²:[32,80],广ä¸:[0,-10],馿¸¯:[10,5],æ¾³é¨:[-10,10],天津:[5,5]},CO=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]],CN=function(){function e(e,t,n){var i;this.type="geoJSON",this._parsedMap=n1(),this._mapName=e,this._specialAreas=n,this._geoJSON=nA(i=t)?"u">typeof JSON&&JSON.parse?JSON.parse(i):Function("return ("+i+");")():i}return e.prototype.load=function(e,t){t=t||"name";var n=this._parsedMap.get(t);if(!n){var i=this._parseToRegions(t);n=this._parsedMap.set(t,{regions:i,boundingRect:function(e){for(var t,n=0;n<e.length;n++){var i=e[n].getBoundingRect();(t=t||i.clone()).union(i)}return t}(i)})}var r=n1(),o=[];return nw(n.regions,function(t){var n=t.name;e&&n4(e,n)&&(t=t.cloneShallow(n=e[n])),o.push(t),r.set(n,t)}),{regions:o,boundingRect:n.boundingRect||new rt(0,0,0,0),regionsMap:r}},e.prototype._parseToRegions=function(e){var t,n=this._mapName,i=this._geoJSON;try{t=i?CR(i,e):[]}catch(e){throw Error("Invalid geoJson format\n"+e.message)}return!function(e,t){if("china"===e){for(var n=0;n<t.length;n++)if(t[n].name===CA)return;t.push(new CS(CA,nC(CP,function(e){return{type:"polygon",exterior:e}}),CI))}}(n,t),nw(t,function(e){var t=e.name;if("china"===n){var i=CF[e.name];if(i){var r=e.getCenter();r[0]+=i[0]/10.5,r[1]+=-i[1]/14,e.setCenter(r)}}"china"===n&&"å°æ¹¾"===e.name&&e.geometries.push({type:"polygon",exterior:CO[0]});var o=this._specialAreas&&this._specialAreas[t];o&&e.transformTo(o.left,o.top,o.width,o.height)},this),t},e.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}},e}(),CB=n1();let Cz=function(e,t,n){if(t.svg){var i=new CM(e,t.svg);CB.set(e,i)}else{var r=t.geoJson||t.geoJSON;r&&!t.features?n=t.specialAreas:r=t;var i=new CN(e,r,n);CB.set(e,i)}},Cj=function(e){return CB.get(e)},CV=function(e){var t=CB.get(e);return t&&"geoJSON"===t.type&&t.getMapForUser()},CH=function(e,t,n){var i=CB.get(e);return i?i.load(t,n):void 0};var CG=["rect","circle","line","ellipse","polygon","polyline","path"],CW=n1(CG),C$=n1(CG.concat(["g"])),CU=n1(CG.concat(["g"])),Cq=a9();function CK(e){var t=e.getItemStyle(),n=e.get("areaColor");return null!=n&&(t.fill=n),t}function CY(e){var t=e.style;t&&(t.stroke=t.stroke||t.fill,t.fill=null)}var CZ=function(){function e(e){var t=new av;this.uid=ul("ec_map_draw"),this._controller=new wZ(e.getZr()),this._controllerHost={target:t},this.group=t,t.add(this._regionsGroup=new av),t.add(this._svgGroup=new av)}return e.prototype.draw=function(e,t,n,i,r){var o="geo"===e.mainType,a=e.getData&&e.getData();o&&t.eachComponent({mainType:"series",subType:"map"},function(t){a||t.getHostGeoModel()!==e||(a=t.getData())});var s=e.coordinateSystem,l=this._regionsGroup,d=this.group,u=s.getTransformInfo(),c=u.raw,h=u.roam;!l.childAt(0)||r?(d.x=h.x,d.y=h.y,d.scaleX=h.scaleX,d.scaleY=h.scaleY,d.dirty()):dB(d,h,e);var p=a&&a.getVisual("visualMeta")&&a.getVisual("visualMeta").length>0,f={api:n,geo:s,mapOrGeoModel:e,data:a,isVisualEncodedByVisualMap:p,isGeo:o,transformInfoRaw:c};"geoJSON"===s.resourceType?this._buildGeoJSON(f):"geoSVG"===s.resourceType&&this._buildSVG(f),this._updateController(e,t,n),this._updateMapSelectHandler(e,l,n,i)},e.prototype._buildGeoJSON=function(e){var t=this._regionsGroupByName=n1(),n=n1(),i=this._regionsGroup,r=e.transformInfoRaw,o=e.mapOrGeoModel,a=e.data,s=e.geo.projection,l=s&&s.stream;function d(e,t){return t&&(e=t(e)),e&&[e[0]*r.scaleX+r.x,e[1]*r.scaleY+r.y]}function u(e){return{shape:{points:function(e){for(var t=[],n=!l&&s&&s.project,i=0;i<e.length;++i){var r=d(e[i],n);r&&t.push(r)}return t}(e)}}}i.removeAll(),nw(e.geo.regions,function(r){var c=r.name,h=t.get(c),p=n.get(c)||{},f=p.dataIdx,g=p.regionModel;if(!h){h=t.set(c,new av),i.add(h),f=a?a.indexOfName(c):null;var m=(g=e.isGeo?o.getRegionModel(c):a?a.getItemModel(f):null).get("silent",!0);null!=m&&(h.silent=m),n.set(c,{dataIdx:f,regionModel:g})}var v=[],y=[];nw(r.geometries,function(e){if("polygon"===e.type){var t=[e.exterior].concat(e.interiors||[]);l&&(t=C2(t,l)),nw(t,function(e){v.push(new pV(u(e)))})}else{var n=e.points;l&&(n=C2(n,l,!0)),nw(n,function(e){y.push(new pG(u(e)))})}});var b=d(r.getCenter(),s&&s.project);function x(t,n){if(t.length){var i=new pQ({culling:!0,segmentIgnoreThreshold:1,shape:{paths:t}});h.add(i),CX(e,i,f,g),CJ(e,i,c,g,o,f,b),n&&(CY(i),nw(i.states,CY))}}x(v),x(y,!0)}),t.each(function(t,i){var r=n.get(i),a=r.dataIdx,s=r.regionModel;CQ(e,t,i,s,o,a),C0(e,t,i,s,o),C1(e,t,i,s,o)},this)},e.prototype._buildSVG=function(e){var t=e.geo.map,n=e.transformInfoRaw;this._svgGroup.x=n.x,this._svgGroup.y=n.y,this._svgGroup.scaleX=n.scaleX,this._svgGroup.scaleY=n.scaleY,this._svgResourceChanged(t)&&(this._freeSVG(),this._useSVG(t));var i=this._svgDispatcherMap=n1(),r=!1;nw(this._svgGraphicRecord.named,function(t){var n=t.name,o=e.mapOrGeoModel,a=e.data,s=t.svgNodeTagLower,l=t.el,d=a?a.indexOfName(n):null,u=o.getRegionModel(n);null!=CW.get(s)&&l instanceof sV&&CX(e,l,d,u),l instanceof sV&&(l.culling=!0);var c=u.get("silent",!0);null!=c&&(l.silent=c),l.z2EmphasisLift=0,t.namedFrom||(null!=CU.get(s)&&CJ(e,l,n,u,o,d,null),CQ(e,l,n,u,o,d),C0(e,l,n,u,o),null!=C$.get(s)&&("self"===C1(e,l,n,u,o)&&(r=!0),(i.get(n)||i.set(n,[])).push(l)))},this),this._enableBlurEntireSVG(r,e)},e.prototype._enableBlurEntireSVG=function(e,t){if(e&&t.isGeo){var n=t.mapOrGeoModel.getModel(["blur","itemStyle"]).getItemStyle().opacity;this._svgGraphicRecord.root.traverse(function(e){if(!e.isGroup){df(e);var t=e.ensureState("blur").style||{};null==t.opacity&&null!=n&&(t.opacity=n),e.ensureState("emphasis")}})}},e.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.dispose(),this._controllerHost=null},e.prototype.findHighDownDispatchers=function(e,t){if(null==e)return[];var n=t.coordinateSystem;if("geoJSON"===n.resourceType){var i=this._regionsGroupByName;if(i){var r=i.get(e);return r?[r]:[]}}else if("geoSVG"===n.resourceType)return this._svgDispatcherMap&&this._svgDispatcherMap.get(e)||[]},e.prototype._svgResourceChanged=function(e){return this._svgMapName!==e},e.prototype._useSVG=function(e){var t=Cj(e);if(t&&"geoSVG"===t.type){var n=t.useGraphic(this.uid);this._svgGroup.add(n.root),this._svgGraphicRecord=n,this._svgMapName=e}},e.prototype._freeSVG=function(){var e=this._svgMapName;if(null!=e){var t=Cj(e);t&&"geoSVG"===t.type&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null}},e.prototype._updateController=function(e,t,n){var i=e.coordinateSystem,r=this._controller,o=this._controllerHost;o.zoomLimit=e.get("scaleLimit"),o.zoom=i.getZoom(),r.enable(e.get("roam")||!1);var a=e.mainType;function s(){var t={type:"geoRoam",componentType:a};return t[a+"Id"]=e.id,t}r.off("pan").on("pan",function(e){this._mouseDownFlag=!1,w0(o,e.dx,e.dy),n.dispatchAction(nf(s(),{dx:e.dx,dy:e.dy,animation:{duration:0}}))},this),r.off("zoom").on("zoom",function(e){this._mouseDownFlag=!1,w1(o,e.scale,e.originX,e.originY),n.dispatchAction(nf(s(),{totalZoom:o.zoom,zoom:e.scale,originX:e.originX,originY:e.originY,animation:{duration:0}}))},this),r.setPointerChecker(function(t,r,o){return i.containPoint([r,o])&&!w3(t,n,e)})},e.prototype.resetForLabelLayout=function(){this.group.traverse(function(e){var t=e.getTextContent();t&&(t.ignore=Cq(t).ignore)})},e.prototype._updateMapSelectHandler=function(e,t,n,i){var r=this;t.off("mousedown"),t.off("click"),e.get("selectedMode")&&(t.on("mousedown",function(){r._mou
422seDownFlag=!0}),t.on("click",function(e){r._mouseDownFlag&&(r._mouseDownFlag=!1)}))},e}();function CX(e,t,n,i){var r=i.getModel("itemStyle"),o=i.getModel(["emphasis","itemStyle"]),a=i.getModel(["blur","itemStyle"]),s=i.getModel(["select","itemStyle"]),l=CK(r),d=CK(o),u=CK(s),c=CK(a),h=e.data;if(h){var p=h.getItemVisual(n,"style"),f=h.getItemVisual(n,"decal");e.isVisualEncodedByVisualMap&&p.fill&&(l.fill=p.fill),f&&(l.decal=gX(f,e.api))}t.setStyle(l),t.style.strokeNoScale=!0,t.ensureState("emphasis").style=d,t.ensureState("select").style=u,t.ensureState("blur").style=c,df(t)}function CJ(e,t,n,i,r,o,a){var s=e.data,l=e.isGeo,d=s&&isNaN(s.get(s.mapDimension("value"),o)),u=s&&s.getItemLayout(o);if(l||d||u&&u.showLabel){var c=l?n:o,h=void 0;(!s||o>=0)&&(h=r);var p=a?{normal:{align:"center",verticalAlign:"middle"}}:null;dK(t,dY(i),{labelFetcher:h,labelDataIndex:c,defaultText:n},p);var f=t.getTextContent();if(f&&(Cq(f).ignore=f.ignore,t.textConfig&&a)){var g=t.getBoundingRect().clone();t.textConfig.layoutRect=g,t.textConfig.position=[(a[0]-g.x)/g.width*100+"%",(a[1]-g.y)/g.height*100+"%"]}t.disableLabelAnimation=!0}else t.removeTextContent(),t.removeTextConfig(),t.disableLabelAnimation=null}function CQ(e,t,n,i,r,o){e.data?e.data.setItemGraphicEl(o,t):lQ(t).eventData={componentType:"geo",componentIndex:r.componentIndex,geoIndex:r.componentIndex,name:n,region:i&&i.option||{}}}function C0(e,t,n,i,r){e.data||fk({el:t,componentModel:r,itemName:n,itemTooltipOption:i.get("tooltip")})}function C1(e,t,n,i,r){t.highDownSilentOnTouch=!!r.get("selectedMode");var o,a=i.getModel("emphasis"),s=a.get("focus");return dM(t,s,a.get("blurScope"),a.get("disabled")),e.isGeo&&((o=lQ(t)).componentMainType=r.mainType,o.componentIndex=r.componentIndex,o.componentHighDownName=n),s}function C2(e,t,n){var i,r=[];function o(){i=[]}function a(){i.length&&(r.push(i),i=[])}var s=t({polygonStart:o,polygonEnd:a,lineStart:o,lineEnd:a,point:function(e,t){isFinite(e)&&isFinite(t)&&i.push([e,t])},sphere:function(){}});return n||s.polygonStart(),nw(e,function(e){s.lineStart();for(var t=0;t<e.length;t++)s.point(e[t][0],e[t][1]);s.lineEnd()}),n||s.polygonEnd(),r}var C3=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){if(!i||"mapToggleSelect"!==i.type||i.from!==this.uid){var r=this.group;if(r.removeAll(),!e.getHostGeoModel()){if(this._mapDraw&&i&&"geoRoam"===i.type&&this._mapDraw.resetForLabelLayout(),i&&"geoRoam"===i.type&&"series"===i.componentType&&i.seriesId===e.id){var o=this._mapDraw;o&&r.add(o.group)}else if(e.needsDrawMap){var o=this._mapDraw||new CZ(n);r.add(o.group),o.draw(e,t,n,this,i),this._mapDraw=o}else this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;e.get("showLegendSymbol")&&t.getComponent("legend")&&this._renderSymbols(e,t,n)}}},t.prototype.remove=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},t.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},t.prototype._renderSymbols=function(e,t,n){var i=e.originalData,r=this.group;i.each(i.mapDimension("value"),function(t,n){if(!isNaN(t)){var o=i.getItemLayout(n);if(o&&o.point){var a=o.point,s=o.offset,l=new pw({style:{fill:e.getData().getVisual("style").fill},shape:{cx:a[0]+9*s,cy:a[1],r:3},silent:!0,z2:8+11*!s});if(!s){var d=e.mainSeries.getData(),u=i.getName(n),c=d.indexOfName(u),h=i.getItemModel(n),p=h.getModel("label"),f=d.getItemGraphicEl(c);dK(l,dY(h),{labelFetcher:{getFormattedLabel:function(t,n){return e.getFormattedLabel(c,n)}},defaultText:u}),l.disableLabelAnimation=!0,p.get("position")||l.setTextConfig({position:"bottom"}),f.onHoverStateChange=function(e){dh(l,e)}}r.add(l)}}})},t.type="map",t}(fI),C5=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.needsDrawMap=!1,n.seriesGroup=[],n.getTooltipPosition=function(e){if(null!=e){var t=this.getData().getName(e),n=this.coordinateSystem,i=n.getRegion(t);return i&&n.dataToPoint(i.getCenter())}},n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e){for(var t=bQ(this,{coordDimensions:["value"],encodeDefaulter:nD(cu,this)}),n=n1(),i=[],r=0,o=t.count();r<o;r++){var a=t.getName(r);n.set(a,r)}return nw(CH(this.getMapType(),this.option.nameMap,this.option.nameProperty).regions,function(e){var r,o=e.name,a=n.get(o),s=e.properties&&e.properties.echartsStyle;null==a?(r={name:o},i.push(r)):r=t.getRawDataItem(a),s&&nh(r,s)}),t.appendData(i),t},t.prototype.getHostGeoModel=function(){var e=this.option.geoIndex;return null!=e?this.ecModel.getComponent("geo",e):null},t.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},t.prototype.getRawValue=function(e){var t=this.getData();return t.get(t.mapDimension("value"),e)},t.prototype.getRegionModel=function(e){var t=this.getData();return t.getItemModel(t.indexOfName(e))},t.prototype.formatTooltip=function(e,t,n){for(var i=this.getData(),r=this.getRawValue(e),o=i.getName(e),a=this.seriesGroup,s=[],l=0;l<a.length;l++){var d=a[l].originalData.indexOfName(o),u=i.mapDimension("value");isNaN(a[l].originalData.get(u,d))||s.push(a[l].name)}return hV("section",{header:s.join(", "),noHeader:!s.length,blocks:[hV("nameValue",{name:o,value:r})]})},t.prototype.setZoom=function(e){this.option.zoom=e},t.prototype.setCenter=function(e){this.option.center=e},t.prototype.getLegendIcon=function(e){var t=e.icon||"roundRect",n=g_(t,0,0,e.
422itemWidth,e.itemHeight,e.itemStyle.fill);return n.setStyle(e.itemStyle),n.style.stroke="none",t.indexOf("empty")>-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n},t.type="series.map",t.dependencies=["geo"],t.layoutMode="box",t.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},t}(h1);function C4(e){var t={};e.eachSeriesByType("map",function(e){var n=e.getHostGeoModel(),i=n?"o"+n.id:"i"+e.getMapType();(t[i]=t[i]||[]).push(e)}),nw(t,function(e,t){for(var n,i,r,o=(n=nC(e,function(e){return e.getData()}),i=e[0].get("mapValueCalculation"),r={},nw(n,function(e){e.each(e.mapDimension("value"),function(t,n){var i="ec-"+e.getName(n);r[i]=r[i]||[],isNaN(t)||r[i].push(t)})}),n[0].map(n[0].mapDimension("value"),function(e,t){for(var o,a="ec-"+n[0].getName(t),s=0,l=1/0,d=-1/0,u=r[a].length,c=0;c<u;c++)l=Math.min(l,r[a][c]),d=Math.max(d,r[a][c]),s+=r[a][c];return o="min"===i?l:"max"===i?d:"average"===i?s/u:s,0===u?NaN:o})),a=0;a<e.length;a++)e[a].originalData=e[a].getData();for(var a=0;a<e.length;a++)e[a].seriesGroup=e,e[a].needsDrawMap=0===a&&!e[a].getHostGeoModel(),e[a].setData(o.cloneShallow()),e[a].mainSeries=e[0]})}function C6(e){var t={};e.eachSeriesByType("map",function(n){var i=n.getMapType();if(!n.getHostGeoModel()&&!t[i]){var r={};nw(n.seriesGroup,function(t){var n=t.coordinateSystem,i=t.originalData;t.get("showLegendSymbol")&&e.getComponent("legend")&&i.each(i.mapDimension("value"),function(e,t){var o=i.getName(t),a=n.getRegion(o);if(!(!a||isNaN(e))){var s=r[o]||0,l=n.dataToPoint(a.getCenter());r[o]=s+1,i.setItemLayout(t,{point:l,offset:s})}})});var o=n.getData();o.each(function(e){var t=o.getName(e),n=o.getItemLayout(e)||{};n.showLabel=!r[t],o.setItemLayout(e,n)}),t[i]=!0}})}var C8=function(e){function t(t){var n=e.call(this)||this;return n.type="view",n.dimensions=["x","y"],n._roamTransformable=new o8,n._rawTransformable=new o8,n.name=t,n}return(0,tQ.__extends)(t,e),t.prototype.setBoundingRect=function(e,t,n,i){return this._rect=new rt(e,t,n,i),this._rect},t.prototype.getBoundingRect=function(){return this._rect},t.prototype.setViewRect=function(e,t,n,i){this._transformTo(e,t,n,i),this._viewRect=new rt(e,t,n,i)},t.prototype._transformTo=function(e,t,n,i){var r=this.getBoundingRect(),o=this._rawTransformable;o.transform=r.calculateTransform(new rt(e,t,n,i));var a=o.parent;o.parent=null,o.decomposeTransform(),o.parent=a,this._updateTransform()},t.prototype.setCenter=function(e,t){e&&(this._center=[aR(e[0],t.getWidth()),aR(e[1],t.getHeight())],this._updateCenterAndZoom())},t.prototype.setZoom=function(e){e=e||1;var t=this.zoomLimit;t&&(null!=t.max&&(e=Math.min(t.max,e)),null!=t.min&&(e=Math.max(t.min,e))),this._zoom=e,this._updateCenterAndZoom()},t.prototype.getDefaultCenter=function(){var e=this.getBoundingRect();return[e.x+e.width/2,e.y+e.height/2]},t.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},t.prototype.getZoom=function(){return this._zoom||1},t.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},t.prototype._updateCenterAndZoom=function(){var e=this._rawTransformable.getLocalTransform(),t=this._roamTransformable,n=this.getDefaultCenter(),i=this.getCenter(),r=this.getZoom();i=iy([],i,e),n=iy([],n,e),t.originX=i[0],t.originY=i[1],t.x=n[0]-i[0],t.y=n[1]-i[1],t.scaleX=t.scaleY=r,this._updateTransform()},t.prototype._updateTransform=function(){var e=this._roamTransformable,t=this._rawTransformable;t.parent=e,e.updateTransform(),t.updateTransform(),iY(this.transform||(this.transform=[]),t.transform||iq()),this._rawTransform=t.getLocalTransform(),this.invTransform=this.invTransform||[],i0(this.invTransform,this.transform),this.decomposeTransform()},t.prototype.getTransformInfo=function(){var e=this._rawTransformable,t=this._roamTransformable,n=new o8;return n.transform=t.transform,n.decomposeTransform(),{roam:{x:n.x,y:n.y,scaleX:n.scaleX,scaleY:n.scaleY},raw:{x:e.x,y:e.y,scaleX:e.scaleX,scaleY:e.scaleY}}},t.prototype.getViewRect=function(){return this._viewRect},t.prototype.getViewRectAfterRoam=function(){var e=this.getBoundingRect
vendor: 4,313 bytes, line 422
422().clone();return e.applyTransform(this.transform),e},t.prototype.dataToPoint=function(e,t,n){var i=t?this._rawTransform:this.transform;return n=n||[],i?iy(n,e,i):n9(n,e)},t.prototype.pointToData=function(e){var t=this.invTransform;return t?iy([],e,t):[e[0],e[1]]},t.prototype.convertToPixel=function(e,t,n){var i=C7(t);return i===this?i.dataToPoint(n):null},t.prototype.convertFromPixel=function(e,t,n){var i=C7(t);return i===this?i.pointToData(n):null},t.prototype.containPoint=function(e){return this.getViewRectAfterRoam().contain(e[0],e[1])},t.dimensions=["x","y"],t}(o8);function C7(e){var t=e.seriesModel;return t?t.coordinateSystem:null}var C9={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},Se=["lng","lat"],St=function(e){function t(t,n,i){var r,o=e.call(this,t)||this;o.dimensions=Se,o.type="geo",o._nameCoordMap=n1(),o.map=n;var a=i.projection,s=CH(n,i.nameMap,i.nameProperty),l=Cj(n);o.resourceType=l?l.type:null;var d=o.regions=s.regions,u=C9[l.type];if(o._regionsMap=s.regionsMap,o.regions=s.regions,o.projection=a,a)for(var c=0;c<d.length;c++){var h=d[c].getBoundingRect(a);(r=r||h.clone()).union(h)}else r=s.boundingRect;return o.setBoundingRect(r.x,r.y,r.width,r.height),o.aspectScale=a?1:nG(i.aspectScale,u.aspectScale),o._invertLongitute=!a&&u.invertLongitute,o}return(0,tQ.__extends)(t,e),t.prototype._transformTo=function(e,t,n,i){var r=this.getBoundingRect(),o=this._invertLongitute;r=r.clone(),o&&(r.y=-r.y-r.height);var a=this._rawTransformable;a.transform=r.calculateTransform(new rt(e,t,n,i));var s=a.parent;a.parent=null,a.decomposeTransform(),a.parent=s,o&&(a.scaleY=-a.scaleY),this._updateTransform()},t.prototype.getRegion=function(e){return this._regionsMap.get(e)},t.prototype.getRegionByCoord=function(e){for(var t=this.regions,n=0;n<t.length;n++){var i=t[n];if("geoJSON"===i.type&&i.contain(e))return t[n]}},t.prototype.addGeoCoord=function(e,t){this._nameCoordMap.set(e,t)},t.prototype.getGeoCoord=function(e){var t=this._regionsMap.get(e);return this._nameCoordMap.get(e)||t&&t.getCenter()},t.prototype.dataToPoint=function(e,t,n){if(nA(e)&&(e=this.getGeoCoord(e)),e){var i=this.projection;return i&&(e=i.project(e)),e&&this.projectedToPoint(e,t,n)}},t.prototype.pointToData=function(e){var t=this.projection;return t&&(e=t.unproject(e)),e&&this.pointToProjected(e)},t.prototype.pointToProjected=function(t){return e.prototype.pointToData.call(this,t)},t.prototype.projectedToPoint=function(t,n,i){return e.prototype.dataToPoint.call(this,t,n,i)},t.prototype.convertToPixel=function(e,t,n){var i=Sn(t);return i===this?i.dataToPoint(n):null},t.prototype.convertFromPixel=function(e,t,n){var i=Sn(t);return i===this?i.pointToData(n):null},t}(C8);function Sn(e){var t=e.geoModel,n=e.seriesModel;return t?t.coordinateSystem:n?n.coordinateSystem||(n.getReferringComponents("geo",si).models[0]||{}).coordinateSystem:null}function Si(e,t){var n,i,r,o=e.get("boundingCoords");if(null!=o){var a=o[0],s=o[1];if(isFinite(a[0])&&isFinite(a[1])&&isFinite(s[0])&&isFinite(s[1])){var l=this.projection;if(l){var d=a[0],u=a[1],c=s[0],h=s[1];a=[1/0,1/0],s=[-1/0,-1/0];var p=function(e,t,n,i){for(var r=n-e,o=i-t,d=0;d<=100;d++){var u=d/100,c=l.project([e+r*u,t+o*u]);ib(a,a,c),ix(s,s,c)}};p(d,u,c,u),p(c,u,c,h),p(c,h,d,h),p(d,h,c,u)}this.setBoundingRect(a[0],a[1],s[0]-a[0],s[1]-a[1])}}var f=this.getBoundingRect(),g=e.get("layoutCenter"),m=e.get("layoutSize"),v=t.getWidth(),y=t.getHeight(),b=f.width/f.height*this.aspectScale,x=!1;if(g&&m&&(n=[aR(g[0],v),aR(g[1],y)],i=aR(m,Math.min(v,y)),isNaN(n[0])||isNaN(n[1])||isNaN(i)||(x=!0)),x)r={},b>1?(r.width=i,r.height=i/b):(r.height=i,r.width=i*b),r.y=n[1]-r.height/2,r.x=n[0]-r.width/2;else{var w=e.getBoxLayoutParams();w.aspect=b,r=uX(w,{width:v,height:y})}this.setViewRect(r.x,r.y,r.width,r.height),this.setCenter(e.get("center"),t),this.setZoom(e.get("zoom"))}nb(St,C8);var Sr=new(function(){function e(){this.dimensions=Se}return e.prototype.create=function(e,t){var n=[];function i(e){return{nameProperty:e.get("nameProperty"),aspectScale:e.get("aspectScale"),projection:e.get("projection")}}e.eachComponent("geo",function(e,r){var o=e.get("map"),a=new St(o+r,o,nf({nameMap:e.get("nameMap")},i(e)));a.zoomLimit=e.get("scaleLimit"),n.push(a),e.coordinateSystem=a,a.model=e,a.resize=Si,a.resize(e,t)}
422),e.eachSeries(function(e){if("geo"===e.get("coordinateSystem")){var t=e.get("geoIndex")||0;e.coordinateSystem=n[t]}});var r={};return e.eachSeriesByType("map",function(e){if(!e.getHostGeoModel()){var t=e.getMapType();r[t]=r[t]||[],r[t].push(e)}}),nw(r,function(e,r){var o=new St(r,r,nf({nameMap:np(nC(e,function(e){return e.get("nameMap")}))},i(e[0])));o.zoomLimit=nH.apply(null,nC(e,function(e){return e.get("scaleLimit")})),n.push(o),o.resize=Si,o.resize(e[0],t),nw(e,function(e){e.coordinateSystem=o,nw(e.get("geoCoord"),function(e,t){o.addGeoCoord(t,e)})})}),n},e.prototype.getFilledRegions=function(e,t,n,i){for(var r=(e||[]).slice(),o=n1(),a=0;a<r.length;a++)o.set(r[a].name,r[a]);return nw(CH(t,n,i).regions,function(e){var t=e.name,n=o.get(t),i=e.properties&&e.properties.echartsStyle;n||(n={name:t},r.push(n)),i&&nh(n,i)}),r},e}()),So=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t,n){var i=Cj(e.map);if(i&&"geoJSON"===i.type){var r=e.itemStyle=e.itemStyle||{};"color"in r||(r.color="#eee")}this.mergeDefaultAndTheme(e,n),aQ(e,"label",["show"])},t.prototype.optionUpdated=function(){var e=this,t=this.option;t.regions=Sr.getFilledRegions(t.regions,t.map,t.nameMap,t.nameProperty);var n={};this._optionModelMap=nS(t.regions||[],function(t,i){var r=i.name;return r&&(t.set(r,new ua(i,e,e.ecModel)),i.selected&&(n[r]=!0)),t},n1()),t.selectedMap||(t.selectedMap=n)},t.prototype.getRegionModel=function(e){return this._optionModelMap.get(e)||new ua(null,this,this.ecModel)},t.prototype.getFormattedLabel=function(e,t){var n=this.getRegionModel(e),i="normal"===t?n.get(["label","formatter"]):n.get(["emphasis","label","formatter"]),r={name:e};return nI(i)?(r.status=t,i(r)):nA(i)?i.replace("{a}",null!=e?e:""):void 0},t.prototype.setZoom=function(e){this.option.zoom=e},t.prototype.setCenter=function(e){this.option.center=e},t.prototype.select=function(e){var t=this.option,n=t.selectedMode;n&&("multiple"!==n&&(t.selectedMap=null),(t.selectedMap||(t.selectedMap={}))[e]=!0)},t.prototype.unSelect=function(e){var t=this.option.selectedMap;t&&(t[e]=!1)},t.prototype.toggleSelected=function(e){this[this.isSelected(e)?"unSelect":"select"](e)},t.prototype.isSelected=function(e){var t=this.option.selectedMap;return!!(t&&t[e])},t.type="geo",t.layoutMode="box",t.defaultOption={z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},regions:[]},t}(u5);function Sa(e,t){return e.pointToProjected?e.pointToProjected(t):e.pointToData(t)}function Ss(e,t,n,i){var r=e.getZoom(),o=e.getCenter(),a=t.zoom,s=e.projectedToPoint?e.projectedToPoint(o):e.dataToPoint(o);if(null!=t.dx&&null!=t.dy&&(s[0]-=t.dx,s[1]-=t.dy,e.setCenter(Sa(e,s),i)),null!=a){if(n){var l=n.min||0;a=Math.max(Math.min(r*a,n.max||1/0),l)/r}e.scaleX*=a,e.scaleY*=a;var d=(t.originX-e.x)*(a-1),u=(t.originY-e.y)*(a-1);e.x-=d,e.y-=u,e.updateTransform(),e.setCenter(Sa(e,s),i),e.setZoom(a*r)}return{center:e.getCenter(),zoom:e.getZoom()}}var Sl=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.focusBlurEnabled=!0,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){this._api=t},t.prototype.render=function(e,t,n,i){if(this._model=e,!e.get("show")){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;return}this._mapDraw||(this._mapDraw=new CZ(n));var r=this._mapDraw;r.draw(e,t,n,this,i),r.group.on("click",this._handleRegionClick,this),r.group.silent=e.get("silent"),this.group.add(r.group),this.updateSelectStatus(e,t,n)},t.prototype._handleRegionClick=function(e){var t;gh(e.target,function(e){return null!=(t=lQ(e).eventData)},!0),t&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:t.name})},t.prototype.updateSelectStatus=function(e,t,n){var i=this;this._mapDraw.group.traverse(function(e){var t=lQ(e).eventData;if(t)return i._model.isSelected(t.name)?n.enterSelect(e):n.leaveSelect(e),!0})},t.prototype.findHighDownDispatchers=function(e){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(e,this._model)},t.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},t.type="geo",t}(h9);function Sd(e,t,n){Cz(e,t,n)}function Su(e){function t(t,n){n.update="geo:updateSelectStatus",e.registerAction(n,function(e,n){var i={},r=[];return n.eachComponent({mainType:"geo",query:e},function(n){n[t](e.name),nw(n.coordinateSystem.regions,function(e){i[e.name]=n.isSelected(e.name)||!1});var o=[];nw(i,function(e,t){i[t]&&o.push(t)}),r.push({geoIndex:n.componentIndex,name:o})}),{selected:i,allSelected:r,name:e.name}})}e.registerCoordinateSystem("geo",Sr),e.registerComponentModel(So),e.registerComponentView(Sl),e.registerImpl("registerMap",Sd),e.registerImpl("getMap",function(e){return CV(e)}),t("toggleSelected",{type:"geoToggleSelect",event:"geoselectchanged"}),t("select",{type:"geoSelect",event:"geoselected"}),t("unSelect",{type:"geoUnSelect",event:"geounselected"}),e.registerAction({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(e,t,n){var i=e.componentType||"series";t.eachComponent({mainType:i,query:e},function(t){var r=t.coordinateSystem;if("geo"===r.type){var o=Ss(r,e,t.get("scaleLimit"),n);t.setCenter&&t.setCenter(o.center),t.setZoom&&t.setZoom(o.zoom),"series"===i&&nw(t.seriesGroup,function(e){e.setCenter(o.center),e.setZoom(o.zoom)})}})})}function Sc(e,t){var n=e.isExpand?e.children:[],i=e.parentNode.children,r=e.hierNode.i?i[e.hierNode.i-1]:null;if(n.length){!function(e){for(var t=e.children,n=t.length,i=0,r=0;--n>=0;){var o=t[n];o.hierNode.prelim+=i,o.hierNode.modifier+=i,r+=o.hierNode.change,i+=o.hierNode.shift+r}}(e);var o=(n[0].hierNode.prelim+n[n.length-1].hierNode.prelim)/2;r?(e.hierNode.prelim=r.hierNode.prelim+t(e,r),e.hierNode.modifier=e.hierNode.prelim-o):e.hierNode.prelim=o}else r&&(e.hierNode.prelim=r.hierNode.prelim+t(e,r));e.parentNode.hierNode.defaultAncestor=function(e,t,n,i){if(t){for(var r=e,o=e,a=o.parentNode.children[0],s=t,l=r.hierNode.modifier,d=o.hierNode.modifier,u=a.hierNode.modifier,c=s.hierNode.modifier;s=Sg(s),o=Sm(o),s&&o;){r=Sg(r),a=Sm(a),r.hierNode.ancestor=e;var h,p,f,g=s.hierNode.prelim+c-o.hierNode.prelim-d+i(s,o);g>0&&(function(e,t,n){var i=n/(t.hierNode.i-e.hierNode.i);t.hierNode.change-=i,t.hierNode.shift+=n,t.hierNode.modifier+=n,t.hierNode.prelim+=n,e.hierNode.change+=i}((h=s,p=e,f=n,h.hierNode.ancestor.parentNode===p.parentNode?h.hierNode.ancestor:f),e,g),d+=g,l+=g),c+=s.hierNode.modifier,d+=o.hierNode.modifier,l+=r.hier
422Node.modifier,u+=a.hierNode.modifier}s&&!Sg(r)&&(r.hierNode.thread=s,r.hierNode.modifier+=c-l),o&&!Sm(a)&&(a.hierNode.thread=o,a.hierNode.modifier+=d-u,n=e)}return n}(e,r,e.parentNode.hierNode.defaultAncestor||i[0],t)}function Sh(e){var t=e.hierNode.prelim+e.parentNode.hierNode.modifier;e.setLayout({x:t},!0),e.hierNode.modifier+=e.parentNode.hierNode.modifier}function Sp(e){return arguments.length?e:Sv}function Sf(e,t){return{x:t*Math.cos(e-=Math.PI/2),y:t*Math.sin(e)}}function Sg(e){var t=e.children;return t.length&&e.isExpand?t[t.length-1]:e.hierNode.thread}function Sm(e){var t=e.children;return t.length&&e.isExpand?t[0]:e.hierNode.thread}function Sv(e,t){return e.parentNode===t.parentNode?1:2}var Sy=function(){this.parentPoint=[],this.childPoints=[]},Sb=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new Sy},t.prototype.buildPath=function(e,t){var n=t.childPoints,i=n.length,r=t.parentPoint,o=n[0],a=n[i-1];if(1===i){e.moveTo(r[0],r[1]),e.lineTo(o[0],o[1]);return}var s=t.orient,l=+("TB"!==s&&"BT"!==s),d=1-l,u=aR(t.forkPosition,1),c=[];c[l]=r[l],c[d]=r[d]+(a[d]-r[d])*u,e.moveTo(r[0],r[1]),e.lineTo(c[0],c[1]),e.moveTo(o[0],o[1]),c[l]=o[l],e.lineTo(c[0],c[1]),c[l]=a[l],e.lineTo(c[0],c[1]),e.lineTo(a[0],a[1]);for(var h=1;h<i-1;h++){var p=n[h];e.moveTo(p[0],p[1]),c[l]=p[l],e.lineTo(c[0],c[1])}},t}(lk),Sx=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._mainGroup=new av,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){this._controller=new wZ(t.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},t.prototype.render=function(e,t,n){var i=e.getData(),r=e.layoutInfo,o=this._mainGroup;"radial"===e.get("layout")?(o.x=r.x+r.width/2,o.y=r.y+r.height/2):(o.x=r.x,o.y=r.y),this._updateViewCoordSys(e,n),this._updateController(e,t,n);var a=this._data;i.diff(a).add(function(t){Sw(i,t)&&SC(i,t,null,o,e)}).update(function(t,n){var r=a.getItemGraphicEl(n);if(!Sw(i,t)){r&&Sk(a,n,r,o,e);return}SC(i,t,r,o,e)}).remove(function(t){var n=a.getItemGraphicEl(t);n&&Sk(a,t,n,o,e)}).execute(),this._nodeScaleRatio=e.get("nodeScaleRatio"),this._updateNodeAndLinkScale(e),!0===e.get("expandAndCollapse")&&i.eachItemGraphicEl(function(t,i){t.off("click").on("click",function(){n.dispatchAction({type:"treeExpandAndCollapse",seriesId:e.id,dataIndex:i})})}),this._data=i},t.prototype._updateViewCoordSys=function(e,t){var n=e.getData(),i=[];n.each(function(e){var t=n.getItemLayout(e);!t||isNaN(t.x)||isNaN(t.y)||i.push([+t.x,+t.y])});var r=[],o=[];sJ(i,r,o);var a=this._min,s=this._max;o[0]-r[0]==0&&(r[0]=a?a[0]:r[0]-1,o[0]=s?s[0]:o[0]+1),o[1]-r[1]==0&&(r[1]=a?a[1]:r[1]-1,o[1]=s?s[1]:o[1]+1);var l=e.coordinateSystem=new C8;l.zoomLimit=e.get("scaleLimit"),l.setBoundingRect(r[0],r[1],o[0]-r[0],o[1]-r[1]),l.setCenter(e.get("center"),t),l.setZoom(e.get("zoom")),this.group.attr({x:l.x,y:l.y,scaleX:l.scaleX,scaleY:l.scaleY}),this._min=r,this._max=o},t.prototype._updateController=function(e,t,n){var i=this,r=this._controller,o=this._controllerHost,a=this.group;r.setPointerChecker(function(t,i,r){var o=a.getBoundingRect();return o.applyTransform(a.transform),o.contain(i,r)&&!w3(t,n,e)}),r.enable(e.get("roam")),o.zoomLimit=e.get("scaleLimit"),o.zoom=e.coordinateSystem.getZoom(),r.off("pan").off("zoom").on("pan",function(t){w0(o,t.dx,t.dy),n.dispatchAction({seriesId:e.id,type:"treeRoam",dx:t.dx,dy:t.dy})}).on("zoom",function(t){w1(o,t.scale,t.originX,t.originY),n.dispatchAction({seriesId:e.id,type:"treeRoam",zoom:t.scale,originX:t.originX,originY:t.originY}),i._updateNodeAndLinkScale(e),n.updateLabelLayout()})},t.prototype._updateNodeAndLinkScale=function(e){var t=e.getData(),n=this._getNodeGlobalScale(e);t.eachItemGraphicEl(function(e,t){e.setSymbolScale(n)})},t.prototype._getNodeGlobalScale=function(e){var t=e.coordinateSystem;if("view"!==t.type)return 1;var n=this._nodeScaleRatio,i=t.scaleX||1;return((t.getZoom()-1)*n+1)/i},t.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},t.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},t.type="tree",t}(fI);function Sw(e,t){var n=e.getItemLayout(t);return n&&!isNaN(n.x)&&!isNaN(n.y)}function SC(e,t,n,i,r){var o=!n,a=e.tree.getNodeByDataIndex(t),s=a.getModel(),l=a.getVisual("style").fill,d=!1===a.isExpand&&0!==a.children.length?l:"#fff",u=e.tree.root,c=a.parentNode===u?a:a.parentNode||a,h=e.getItemGraphicEl(c.dataIndex),p=c.getLayout(),f=h?{x:h.__oldX,y:h.__oldY,rawX:h.__radialOldRawX,rawY:h.__radialOldRawY}:p,g=a.getLayout();o?((n=new yu(e,t,null,{symbolInnerColor:d,useNameLabel:!0})).x=f.x,n.y=f.y):n.updateData(e,t,null,{symbolInnerColor:d,useNameLabel:!0}),n.__radialOldRawX=n.__radialRawX,n.__radialOldRawY=n.__radialRawY,n.__radialRawX=g.rawX,n.__radialRawY=g.rawY,i.add(n),e.setItemGraphicEl(t,n),n.__oldX=n.x,n.__oldY=n.y,dB(n,{x:g.x,y:g.y},r);var m=n.getSymbolPath();if("radial"===r.get("layout")){var v=u.children[0],y=v.getLayout(),b=v.children.length,x=void 0,w=void 0;if(g.x===y.x&&!0===a.isExpand&&v.children.length){var C={x:(v.children[0].getLayout().x+v.children[b-1].getLayout().x)/2,y:(v.children[0].getLayout().y+v.children[b-1].getLayout().y)/2};
vendor: 12,658 bytes, line 422
422(x=Math.atan2(C.y-y.y,C.x-y.x))<0&&(x=2*Math.PI+x),(w=C.x<y.x)&&(x-=Math.PI)}else(x=Math.atan2(g.y-y.y,g.x-y.x))<0&&(x=2*Math.PI+x),0===a.children.length||0!==a.children.length&&!1===a.isExpand?(w=g.x<y.x)&&(x-=Math.PI):(w=g.x>y.x)||(x-=Math.PI);var S=w?"left":"right",_=s.getModel("label"),k=_.get("rotate"),M=Math.PI/180*k,T=m.getTextContent();T&&(m.setTextConfig({position:_.get("position")||S,rotation:null==k?-x:M,origin:"center"}),T.setStyle("verticalAlign","middle"))}var D=s.get(["emphasis","focus"]),R="relative"===D?n2(a.getAncestorsIndices(),a.getDescendantIndices()):"ancestor"===D?a.getAncestorsIndices():"descendant"===D?a.getDescendantIndices():null;R&&(lQ(n).focus=R),function(e,t,n,i,r,o,a,s){var l=t.getModel(),d=e.get("edgeShape"),u=e.get("layout"),c=e.getOrient(),h=e.get(["lineStyle","curveness"]),p=e.get("edgeForkPosition"),f=l.getModel("lineStyle").getLineStyle(),g=i.__edge;if("curve"===d)t.parentNode&&t.parentNode!==n&&(g||(g=i.__edge=new pZ({shape:SM(u,c,h,r,r)})),dB(g,{shape:SM(u,c,h,o,a)},e));else if("polyline"===d&&"orthogonal"===u&&t!==n&&t.children&&0!==t.children.length&&!0===t.isExpand){for(var m=t.children,v=[],y=0;y<m.length;y++){var b=m[y].getLayout();v.push([b.x,b.y])}g||(g=i.__edge=new Sb({shape:{parentPoint:[a.x,a.y],childPoints:[[a.x,a.y]],orient:c,forkPosition:p}})),dB(g,{shape:{parentPoint:[a.x,a.y],childPoints:v}},e)}g&&!("polyline"===d&&!t.isExpand)&&(g.useStyle(ng({strokeNoScale:!0,fill:null},f)),dI(g,l,"lineStyle"),df(g),s.add(g))}(r,a,u,n,f,p,g,i),n.__edge&&(n.onHoverStateChange=function(t){if("blur"!==t){var i=a.parentNode&&e.getItemGraphicEl(a.parentNode.dataIndex);i&&1===i.hoverState||dh(n.__edge,t)}})}function SS(e,t,n,i,r){var o=S_(t.tree.root,e),a=o.source,s=o.sourceLayout,l=t.getItemGraphicEl(e.dataIndex);if(l){var d=t.getItemGraphicEl(a.dataIndex).__edge,u=l.__edge||(!1===a.isExpand||1===a.children.length?d:void 0),c=i.get("edgeShape"),h=i.get("layout"),p=i.get("orient"),f=i.get(["lineStyle","curveness"]);u&&("curve"===c?dV(u,{shape:SM(h,p,f,s,s),style:{opacity:0}},i,{cb:function(){n.remove(u)},removeOpt:r}):"polyline"===c&&"orthogonal"===i.get("layout")&&dV(u,{shape:{parentPoint:[s.x,s.y],childPoints:[[s.x,s.y]]},style:{opacity:0}},i,{cb:function(){n.remove(u)},removeOpt:r}))}}function S_(e,t){for(var n,i=t.parentNode===e?t:t.parentNode||t;null==(n=i.getLayout());)i=i.parentNode===e?i:i.parentNode||i;return{source:i,sourceLayout:n}}function Sk(e,t,n,i,r){var o=e.tree.getNodeByDataIndex(t),a=S_(e.tree.root,o).sourceLayout,s={duration:r.get("animationDurationUpdate"),easing:r.get("animationEasingUpdate")};dV(n,{x:a.x+1,y:a.y+1},r,{cb:function(){i.remove(n),e.setItemGraphicEl(t,null)},removeOpt:s}),n.fadeOut(null,e.hostModel,{fadeLabel:!0,animation:s}),o.children.forEach(function(t){SS(t,e,i,r,s)}),SS(o,e,i,r,s)}function SM(e,t,n,i,r){if("radial"===e){d=i.rawX,c=i.rawY,u=r.rawX;var o,a,s,l,d,u,c,h=r.rawY,p=Sf(d,c),f=Sf(d,c+(h-c)*n),g=Sf(u,h+(c-h)*n),m=Sf(u,h);return{x1:p.x||0,y1:p.y||0,x2:m.x||0,y2:m.y||0,cpx1:f.x||0,cpy1:f.y||0,cpx2:g.x||0,cpy2:g.y||0}}return d=i.x,c=i.y,u=r.x,h=r.y,("LR"===t||"RL"===t)&&(o=d+(u-d)*n,a=c,s=u+(d-u)*n,l=h),("TB"===t||"BT"===t)&&(o=d,a=c+(h-c)*n,s=u,l=h+(c-h)*n),{x1:d,y1:c,x2:u,y2:h,cpx1:o,cpy1:a,cpx2:s,cpy2:l}}var ST=a9();function SD(e,t){var n;if(n=this,ST(n).mainData===n){var i=nf({},ST(this).datas);i[this.dataType]=t,SE(t,i,e)}else SL(t,this.dataType,ST(this).mainData,e);return t}function SR(e,t){return e.struct&&e.struct.update(),t}function SI(e,t){return nw(ST(t).datas,function(n,i){n!==t&&SL(n.cloneShallow(),i,t,e)}),t}function SA(e){var t=ST(this).mainData;return null==e||null==t?t:ST(t).datas[e]}function SP(){var e=ST(this).mainData;return null==e?[{data:e}]:nC(nM(ST(e).datas),function(t){return{type:t,data:ST(e).datas[t]}})}function SE(e,t,n){ST(e).datas={},nw(t,function(t,i){SL(t,i,e,n)})}function SL(e,t,n,i){ST(n).datas[t]=e,ST(e).mainData=n,e.dataType=t,i.struct&&(e[i.structAttr]=i.struct,i.struct[i.datasAttr[t]]=e),e.getLinkedData=SA,e.getLinkedDataAll=SP}let SF=function(e){var t=e.mainData,n=e.datas;n||(n={main:t},e.datasAttr={main:"data"}),e.datas=e.mainData=null,SE(t,n,e),nw(n,function(n){nw(t.TRANSFERABLE_METHODS,function(t){n.wrapMethod(t,nD(SD,e))})}),t.wrapMethod("cloneShallow",nD(SI,e)),nw(t.CHANGABLE_METHODS,function(n){t.wrapMethod(n,nD(SR,e))}),nq(n[t.dataType]===t)};var SO=function(){function e(e,t){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=e||"",this.hostTree=t}return e.prototype.isRemoved=function(){return this.dataIndex<0},e.prototype.eachNode=function(e,t,n){nI(e)&&(n=t,t=e,e=null),nA(e=e||{})&&(e={order:e});var i,r=e.order||"preorder",o=this[e.attr||"children"];"preorder"===r&&(i=t.call(n,this));for(var a=0;!i&&a<o.length;a++)o[a].eachNode(e,t,n);"postorder"===r&&t.call(n,this)},e.prototype.updateDepthAndHeight=function(e){var t=0;this.depth=e;for(var n=0;n<this.children.length;n++){var i=this.children[n];i.updateDepthAndHeight(e+1),i.height>t&&(t=i.height)}this.height=t+1},e.prototype.getNodeById=function(e){if(this.getId()===e)return this;for(var t=0,n=this.children,i=n.length;t<i;t++){var r=n[t].getNodeById(e);if(r)return r}},e.prototype.contains=function(e){if(e===this)return!0;for(var t=0,n=this.children,i=n.length;t<i;t++){var r=n[t].contains(e);if(r)return r}},e.prototype.getAncestors=function(e){for(var t=[],n=e?this:this.parentNode;n;)t.push(n),n=n.parentNode;return t.reverse(),t},e.prototype.getAncestorsIndices=function(){for(var e=[],t=this;t;)e.push(t.dataIndex),t=t.parentNode;return e.reverse(),e},e.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},e.prototype.getValue=function(e){var t=this.hostTree.data;return t.getStore().get(t.getDimensionIndex(e||"value"),this.dataIndex)},e.prototype.setLayout=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemLayout(this.dataIndex,e,t)},e.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},e.prototype.getModel=function(e){if(!(this.dataIndex<0))return this.hostTree.data.getItemModel(this.dataIndex).getModel(e)},e.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},e.prototype.setVisual=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,e,t)},e.prototype.getVisual=function(e){return this.hostTree.data.getItemVisual(this.dataIndex,e)},e.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},e.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},e.prototype.getChildIndex=function(){if(this.parentNode){for(var e=this.parentNode.children,t=0;t<e.length;++t)if(e[t]===this)return t}return -1},e.prototype.isAncestorOf=function(e){for(var t=e.parentNode;t;){if(t===this)return!0;t=t.parentNode}return!1},e.prototype.isDescendantOf=function(e){return e!==this&&e.isAncestorOf(this)},e}(),SN=function(){function e(e){this.type="tree",this._nodes=[],this.hostModel=e}return e.prototype.eachNode=function(e,t,n){this.root.eachNode(e,t,n)},e.prototype.getNodeByDataIndex=function(e){var t=this.data.getRawIndex(e);return this._nodes[t]},e.prototype.getNodeById=function(e){return this.root.getNodeById(e)},e.prototype.update=function(){for(var e=this.data,t=this._nodes,n=0,i=t.length;n<i;n++)t[n].dataIndex=-1;for(var n=0,i=e.count();n<i;n++)t[e.getRawIndex(n)].dataIndex=n},e.prototype.clearLayouts=function(){this.data.clearItemLayouts()},e.createTree=function(t,n,i){var r=new e(n),o=[],a=1;!function e(t,n){var i,s,l,d=t.value;a=Math.max(a,nR(d)?d.length:1),o.push(t);var u=new SO(a4(t.name,""),r);n?(i=u,l=(s=n).children,i.parentNode!==s&&(l.push(i),i.parentNode=s)):r.root=u,r._nodes.push(u);var c=t.children;if(c)for(var h=0;h<c.length;h++)e(c[h],u)}(t),r.root.updateDepthAndHeight(0);var s=new v8(v9(o,{coordDimensions:["value"],dimensionsCount:a}).dimensions,n);return s.initData(o),i&&i(s),SF({mainData:s,struct:r,structAttr:"tree"}),r.update(),r},e}();function SB(e,t,n){if(e&&nv(t,e.type)>=0){var i=n.getData().tree.root,r=e.targetNode;if(nA(r)&&(r=i.getNodeById(r)),r&&i.contains(r))return{node:r};var o=e.targetNodeId;if(null!=o&&(r=i.getNodeById(o)))return{node:r}}}function Sz(e){for(var t=[];e;)(e=e.parentNode)&&t.push(e);return t.reverse()}function Sj(e,t){return nv(Sz(e),t)>=0}function SV(e,t){for(var n=[];e;){var i=e.dataIndex;n.push({name:e.name,dataIndex:i,value:t.getRawValue(i)}),e=e.parentNode}return n.reverse(),n}var SH=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e){var t={name:e.name,children:e.data},n=new ua(e.leaves||{},this,this.ecModel),i=SN.createTree(t,this,function(e){e.wrapMethod("getItemModel",function(e,t){var r=i.getNodeByDataIndex(t);return r&&r.children.length&&r.isExpand||(e.parentModel=n),e})}),r=0;i.eachNode("preorder",function(e){e.depth>r&&(r=e.depth)});var o=e.expandAndCollapse&&e.initialTreeDepth>=0?e.initialTreeDepth:r;return i.root.eachNode("preorder",function(e){var t=e.hostTree.data.getRawDataItem(e.dataIndex);e.isExpand=t&&null!=t.collapsed?!t.collapsed:e.depth<=o}),i.data},t.prototype.getOrient=function(){var e=this.get("orient");return"horizontal"===e?e="LR":"vertical"===e&&(e="TB"),e},t.prototype.setZoom=function(e){this.option.zoom=e},t.prototype.setCenter=function(e){this.option.center=e},t.prototype.formatTooltip=function(e,t,n){for(var i=this.getData().tree,r=i.root.children[0],o=i.getNodeByDataIndex(e),a=o.getValue(),s=o.name;o&&o!==r;)s=o.parentNode.name+"."+s,o=o.parentNode;return hV("nameValue",{name:s,value:a,noValue:isNaN(a)||null==a})},t.prototype.getDataParams=function(t){var n=e.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(t);return n.treeAncestors=SV(i,this),n.collapsed=!i.isExpand,n},t.type="series.tree",t.layoutMode="box",t.defaultOption={z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},t}(h1);function SG(e,t){for(var n,i=[e];n=i.pop();)if(t(n),n.isExpand){var r=n.children;if(r.length)for(var o=r.length-1;o>=0;o--)i.push(r[o])}}function SW(e,t){e.eachSeriesByType("tree",function(e){!function(e,t){var n=uX(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()});e.layoutInfo=n;var i=e.get("layout"),r=0,o=0,a=null;"radial"===i?(r=2*Math.PI,o=Math.min(n.height,n.width)/2,a=Sp(function(e,t){return(e.parentNode===t.parentNode?1:2)/e.depth})):(r=n.width,o=n.height,a=Sp());var s=e.getData().tree.root,l=s.children[0];if(l){!function(e){e.hierNode={defaultAncestor:null,ancestor:e,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var t,n,i=[e];t=i.pop();)if(n=t.children,t.isExpand&&n.length)for(var r=n.length,o=r-1;o>=0;o--){var a=n[o];a.hierNode={defaultAncestor:null,ancestor:a,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},i.push(a)}}(s),function(e,t,n){for(var i,r=[e],o=[];i=r.pop();)if(o.push(i),i.isExpand){var a=i.children;if(a.length)for(var s=0;s<a.length;s++)r.push(a[s])}for(;i=o.pop();)t(i,n)}(l,Sc,a),s.hierNode.modifier=-l.hierNode.prelim,SG(l,Sh);var d=l,u=l,c=l;SG(l,function(e){var t=e.getLayout().x;t<d.getLayout().x&&(d=e),t>u.getLayout().x&&(u=e),e.depth>c.depth&&(c=e)});var h=d===u?1:a(d,u)/2,p=h-d.getLayout().x,f=0,g=0,m=0,v=0;if("radial"===i)f=r/(u.getLayout().x+h+p),g=o/(c.depth-1||1),SG(l,function(e){m=(e.getLayout().x+p)*f,v=(e.depth-1)*g;var t=Sf(m,v);e.setLayout({x:t.x,y:t.y,rawX:m,rawY:v},!0)});else{var y=e.getOrient();"RL"===y||"LR"===y?(g=o/(u.getLayout().x+h+p),f=r/(c.depth-1||1),SG(l,function(e){v=(e.getLayout().x+p)*g,m="LR"===y?(e.depth-1)*f:r-(e.depth-1)*f,e.setLayout({x:m,y:v},!0)})):("TB"===y||"BT"===y)&&(f=r/(u.getLayout().x+h+p),g=o/(c.depth-1||1),SG(l,function(e){m=(e.getLayout().x+p)*f,v="TB"===y?(e.depth-1)*g:o-(e.depth-1)*g,e.setLayout({x:m,y:v},!0)}))}}}(e,t)})}function S$(e){e.eachSeriesByType("tree",function(e){var t=e.getData();t.tree.eachNode(function(e){var n=e.getModel().getModel("itemStyle").getItemStyle();nf(t.ensureUniqueItemVisual(e.dataIndex,"style"),n)})})}var SU=["treemapZoomToNode","treemapRender","treemapMove"];function Sq(e){var t=e.getData().tree,n={};t.eachNode(function(t){for(var i=t;i&&i.depth>
4221;)i=i.parentNode;var r=cy(e.ecModel,i.name||i.dataIndex+"",n);t.setVisual("decal",r)})}var SK=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.preventUsingHoverLayer=!0,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){var n={name:e.name,children:e.data};!function e(t){var n=0;nw(t.children,function(t){e(t);var i=t.value;nR(i)&&(i=i[0]),n+=i});var i=t.value;nR(i)&&(i=i[0]),(null==i||isNaN(i))&&(i=n),i<0&&(i=0),nR(t.value)?t.value[0]=i:t.value=i}(n);var i=e.levels||[],r=new ua({itemStyle:this.designatedVisualItemStyle={}},this,t),o=nC((i=e.levels=function(e,t){var n,i,r=aJ(t.get("color")),o=aJ(t.get(["aria","decal","decals"]));if(r){nw(e=e||[],function(e){var t=new ua(e),r=t.get("color"),o=t.get("decal");(t.get(["itemStyle","color"])||r&&"none"!==r)&&(n=!0),(t.get(["itemStyle","decal"])||o&&"none"!==o)&&(i=!0)});var a=e[0]||(e[0]={});return n||(a.color=r.slice()),!i&&o&&(a.decal=o.slice()),e}}(i,t))||[],function(e){return new ua(e,r,t)},this),a=SN.createTree(n,this,function(e){e.wrapMethod("getItemModel",function(e,t){var n=a.getNodeByDataIndex(t);return e.parentModel=(n?o[n.depth]:null)||r,e})});return a.data},t.prototype.optionUpdated=function(){this.resetViewRoot()},t.prototype.formatTooltip=function(e,t,n){var i=this.getData(),r=this.getRawValue(e);return hV("nameValue",{name:i.getName(e),value:r})},t.prototype.getDataParams=function(t){var n=e.prototype.getDataParams.apply(this,arguments);return n.treeAncestors=SV(this.getData().tree.getNodeByDataIndex(t),this),n.treePathInfo=n.treeAncestors,n},t.prototype.setLayoutInfo=function(e){this.layoutInfo=this.layoutInfo||{},nf(this.layoutInfo,e)},t.prototype.mapIdToIndex=function(e){var t=this._idIndexMap;t||(t=this._idIndexMap=n1(),this._idIndexMapCount=0);var n=t.get(e);return null==n&&t.set(e,n=this._idIndexMapCount++),n},t.prototype.getViewRoot=function(){return this._viewRoot},t.prototype.resetViewRoot=function(e){e?this._viewRoot=e:e=this._viewRoot;var t=this.getRawData().tree.root;e&&(e===t||t.contains(e))||(this._viewRoot=t)},t.prototype.enableAriaDecal=function(){Sq(this)},t.type="series.treemap",t.layoutMode="box",t.defaultOption={progressive:0,left:"center",top:"middle",width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"â¶",zoomToNodeRatio:.1024,scaleLimit:null,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",textStyle:{color:"#fff"}},emphasis:{itemStyle:{color:"rgba(0,0,0,0.9)"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},t}(h1),SY=function(){function e(e){this.group=new av,e.add(this.group)}return e.prototype.render=function(e,t,n,i){var r=e.getModel("breadcrumb"),o=this.group;if(o.removeAll(),r.get("show")&&n){var a=r.getModel("itemStyle"),s=r.getModel("emphasis"),l=a.getModel("textStyle"),d=s.getModel(["itemStyle","textStyle"]),u={pos:{left:r.get("left"),right:r.get("right"),top:r.get("top"),bottom:r.get("bottom")},box:{width:t.getWidth(),height:t.getHeight()},emptyItemWidth:r.get("emptyItemWidth"),totalWidth:0,renderList:[]};this._prepare(n,u,l),this._renderContent(e,u,a,s,l,d,i),uJ(o,u.pos,u.box)}},e.prototype._prepare=function(e,t,n){for(var i=e;i;i=i.parentNode){var r=a4(i.getModel().get("name"),""),o=Math.max(n.getTextRect(r).width+16,t.emptyItemWidth);t.totalWidth+=o+8,t.renderList.push({node:i,text:r,width:o})}},e.prototype._renderContent=function(e,t,n,i,r,o,a){for(var s,l,d,u,c,h,p,f,g,m=0,v=t.emptyItemWidth,y=e.get(["breadcrumb","height"]),b=(s=t.pos,u=(l=t.box).width,c=l.height,h=aR(s.left,u),p=aR(s.top,c),f=aR(s.right,u),g=aR(s.bottom,c),(isNaN(h)||isNaN(parseFloat(s.left)))&&(h=0),(isNaN(f)||isNaN(parseFloat(s.right)))&&(f=u),(isNaN(p)||isNaN(parseFloat(s.top)))&&(p=0),(isNaN(g)||isNaN(parseFloat(s.bottom)))&&(g=c),{width:Math.max(f-h-(d=nU(d||0))[1]-d[3],0),height:Math.max(g-p-d[0]-d[2],0)}),x=t.totalWidth,w=t.renderList,C=i.getModel("itemStyle").getItemStyle(),S=w.length-1;S>=0;S--){var _,k,M,T=w[S],D=T.node,R=T.width,I=T.text;x>b.width&&(x-=R-v,R=v,I=null);var A=new pV({shape:{points:function(e,t,n,i,r,o){var a=[[r?e:e-5,0],[e+n,0],[e+n,0+i],[r?e:e-5,0+i]];return o||a.splice(2,0,[e+n+5,0+i/2]),r||a.push([e,0+i/2]),a}(m,0,R,y,S===w.length-1,0===S)},style:ng(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new lj({style:dZ(r,{text:I})}),textConfig:{position:"inside"},z2:1e5,onclick:nD(a,D)});A.disableLabelAnimation=!0,A.getTextContent().ensureState("emphasis").style=dZ(o,{text:I}),A.ensureState("emphasis").style=C,dM(A,i.get("focus"),i.get("blurScope"),i.get("disabled")),this.group.add(A),_=A,k=e,M=D,lQ(_).eventData={componentType:"series",componentSubType:"treemap",componentIndex:k.componentIndex,seriesIndex:k.seriesIndex,seriesName:k.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:M&&M.dataIndex,name:M&&M.name},treePathInfo:M&&SV(M,k)},m+=R+8}},e.prototype.remove=function(){this.group.removeAll()},e}(),SZ=function(){function e(){this._storage=[],this._elExistsMap={}}
vendor: 4,968 bytes, line 422
422return e.prototype.add=function(e,t,n,i,r){return!this._elExistsMap[e.id]&&(this._elExistsMap[e.id]=!0,this._storage.push({el:e,target:t,duration:n,delay:i,easing:r}),!0)},e.prototype.finished=function(e){return this._finishedCallback=e,this},e.prototype.start=function(){for(var e=this,t=this._storage.length,n=function(){--t<=0&&(e._storage.length=0,e._elExistsMap={},e._finishedCallback&&e._finishedCallback())},i=0,r=this._storage.length;i<r;i++){var o=this._storage[i];o.el.animateTo(o.target,{duration:o.duration,delay:o.delay,easing:o.easing,setToFinal:!0,done:n,aborted:n})}return this},e}(),SX="label",SJ="upperLabel",SQ=sy([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),S0=function(e){var t=SQ(e);return t.stroke=t.fill=t.lineWidth=null,t},S1=a9(),S2=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._state="ready",n._storage=S3(),n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){if(!(0>nv(t.findComponents({mainType:"series",subType:"treemap",query:i}),e))){this.seriesModel=e,this.api=n,this.ecModel=t;var r=SB(i,["treemapZoomToNode","treemapRootToNode"],e),o=i&&i.type,a=e.layoutInfo,s=!this._oldTree,l=this._storage,d="treemapRootToNode"===o&&r&&l?{rootNodeGroup:l.nodeGroup[r.node.getRawIndex()],direction:i.direction}:null,u=this._giveContainerGroup(a),c=e.get("animation"),h=this._doRender(u,e,d);!c||s||o&&"treemapZoomToNode"!==o&&"treemapRootToNode"!==o?h.renderFinally():this._doAnimation(u,h,e,d),this._resetController(n),this._renderBreadcrumb(e,n,r)}},t.prototype._giveContainerGroup=function(e){var t=this._containerGroup;return t||(t=this._containerGroup=new av,this._initEvents(t),this.group.add(t)),t.x=e.x,t.y=e.y,t},t.prototype._doRender=function(e,t,n){var i,r,o=t.getData().tree,a=this._oldTree,s=S3(),l=S3(),d=this._storage,u=[];!function e(i,r,o,a,c){function h(e){return e.getId()}function p(h,p){var f=null!=h?i[h]:null,g=null!=p?r[p]:null,m=function(e,t,n,i,r,o,a,s,l,d){if(a){var u=a.getLayout(),c=e.getData(),h=a.getModel();if(c.setItemGraphicEl(a.dataIndex,null),u&&u.isInView){var p=u.width,f=u.height,g=u.borderWidth,m=u.invisible,v=a.getRawIndex(),y=s&&s.getRawIndex(),b=a.viewChildren,x=u.upperHeight,w=b&&b.length,C=h.getModel("itemStyle"),S=h.getModel(["emphasis","itemStyle"]),_=h.getModel(["blur","itemStyle"]),k=h.getModel(["select","itemStyle"]),M=C.get("borderRadius")||0,T=z("nodeGroup",av);if(T){if(l.add(T),T.x=u.x||0,T.y=u.y||0,T.markRedraw(),S1(T).nodeWidth=p,S1(T).nodeHeight=f,u.isAboveViewRoot)return T;var D=z("background",lN,d,20);D&&function(t,n,i){var r=lQ(n);if(r.dataIndex=a.dataIndex,r.seriesIndex=e.seriesIndex,n.setShape({x:0,y:0,width:p,height:f,r:M}),m)O(n);else{n.invisible=!1;var o=a.getVisual("style"),s=o.stroke,l=S0(C);l.fill=s;var d=SQ(S);d.fill=S.get("borderColor");var u=SQ(_);u.fill=_.get("borderColor");var c=SQ(k);if(c.fill=k.get("borderColor"),i){var h=p-2*g;N(n,s,o.opacity,{x:g,y:0,width:h,height:x})}else n.removeTextContent();n.setStyle(l),n.ensureState("emphasis").style=d,n.ensureState("blur").style=u,n.ensureState("select").style=c,df(n)}t.add(n)}(T,D,w&&u.upperLabelHeight);var R=h.getModel("emphasis"),I=R.get("focus"),A=R.get("blurScope"),P=R.get("disabled"),E="ancestor"===I?a.getAncestorsIndices():"descendant"===I?a.getDescendantIndices():I;if(w)dP(T)&&dA(T,!1),D&&(dA(D,!P),c.setItemGraphicEl(a.dataIndex,D),dT(D,E,A));else{var L=z("content",lN,d,30);L&&function(t,n){var i=lQ(n);i.dataIndex=a.dataIndex,i.seriesIndex=e.seriesIndex;var r=Math.max(p-2*g,0),o=Math.max(f-2*g,0);if(n.culling=!0,n.setShape({x:g,y:g,width:r,height:o,r:M}),m)O(n);else{n.invisible=!1;var s=a.getVisual("style"),l=s.fill,d=S0(C);d.fill=l,d.decal=s.decal;var u=SQ(S),c=SQ(_),h=SQ(k);N(n,l,s.opacity,null),n.setStyle(d),n.ensureState("emphasis").style=u,n.ensureState("blur").style=c,n.ensureState("select").style=h,df(n)}t.add(n)}(T,L),D.disableMorphing=!0,D&&dP(D)&&dA(D,!1),dA(T,!P),c.setItemGraphicEl(a.dataIndex,T);var F=h.getShallow("cursor");F&&L.attr("cursor",F),dT(T,E,A)}return T}}}function O(e){e.invisible||o.push(e)}function N(t,n,i,r){var o=h.getModel(r?SJ:SX),s=a4(h.get("name"),null),l=o.getShallow("show");dK(t,dY(h,r?SJ:SX),{defaultText:l?s:null,inheritColor:n,defaultOpacity:i,labelFetcher:e,labelDataIndex:a.dataIndex});var d=t.getTextContent();if(d){var c=d.style,p=nU(c.padding||0);r&&(t.setTextConfig({layoutRect:r}),d.disableLabelLayout=!0),d.beforeUpdate=function(){var e=Math.max((r?r.width:t.shape.width)-p[1]-p[3],0),n=Math.max((r?r.height:t.shape.height)-p[0]-p[2],0);(c.width!==e||c.height!==n)&&d.setStyle({width:e,height:n})},c.truncateMinChar=2,c.lineOverflow="truncate",B(c,r,u);var f=d.getState("emphasis");B(f?f.style:null,r,u)}}function B(t,n,i){var r=t?t.text:null;if(!n&&i.isLeafRoot&&null!=r){var o=e.get("drillDownIcon",!0);t.text=o?o+" "+r:r}}function z(e,o,s,l){var d,u,c,h=null!=y&&n[e][y],p=r[e];
422return h?(n[e][y]=null,d=p,u=h,c=d[v]={},u instanceof av?(c.oldX=u.x,c.oldY=u.y):c.oldShape=nf({},u.shape)):m||((h=new o)instanceof sV&&(h.z2=100*s+l),function(e,t){var n=e[v]={},o=a.parentNode,s=t instanceof av;if(o&&(!i||"drillDown"===i.direction)){var l=0,d=0,u=r.background[o.getRawIndex()];!i&&u&&u.oldShape&&(l=u.oldShape.width,d=u.oldShape.height),s?(n.oldX=0,n.oldY=d):n.oldShape={x:l,y:d,width:0,height:0}}n.fadein=!s}(p,h)),t[e][v]=h}}(t,l,d,n,s,u,f,g,o,c);m&&e(f&&f.viewChildren||[],g&&g.viewChildren||[],m,a,c+1)}a?(r=i,nw(i,function(e,t){e.isRemoved()||p(t,t)})):new vU(r,i,h,h).add(p).update(p).remove(nD(p,null)).execute()}(o.root?[o.root]:[],a&&a.root?[a.root]:[],e,o===a||!a,0);var c=(i=d,r=S3(),i&&nw(i,function(e,t){var n=r[t];nw(e,function(e){e&&(n.push(e),S1(e).willDelete=!0)})}),r);if(this._oldTree=o,this._storage=l,this._controllerHost){var h=this.seriesModel.layoutInfo,p=o.root.getLayout();p.width===h.width&&p.height===h.height&&(this._controllerHost.zoom=1)}return{lastsForAnimation:s,willDeleteEls:c,renderFinally:function(){nw(c,function(e){nw(e,function(e){e.parent&&e.parent.remove(e)})}),nw(u,function(e){e.invisible=!0,e.dirty()})}}},t.prototype._doAnimation=function(e,t,n,i){var r=n.get("animationDurationUpdate"),o=n.get("animationEasing"),a=(nI(r)?0:r)||0,s=(nI(o)?null:o)||"cubicOut",l=new SZ;nw(t.willDeleteEls,function(e,t){nw(e,function(e,n){if(!e.invisible){var r,o=e.parent,d=S1(o);if(i&&"drillDown"===i.direction)r=o===i.rootNodeGroup?{shape:{x:0,y:0,width:d.nodeWidth,height:d.nodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var u=0,c=0;d.willDelete||(u=d.nodeWidth/2,c=d.nodeHeight/2),r="nodeGroup"===t?{x:u,y:c,style:{opacity:0}}:{shape:{x:u,y:c,width:0,height:0},style:{opacity:0}}}r&&l.add(e,r,a,0,s)}})}
422),nw(this._storage,function(e,n){nw(e,function(e,i){var r=t.lastsForAnimation[n][i],o={};r&&(e instanceof av?null!=r.oldX&&(o.x=e.x,o.y=e.y,e.x=r.oldX,e.y=r.oldY):(r.oldShape&&(o.shape=nf({},e.shape),e.setShape(r.oldShape)),r.fadein?(e.setStyle("opacity",0),o.style={opacity:1}):1!==e.style.opacity&&(o.style={opacity:1})),l.add(e,o,a,0,s))})},this),this._state="animating",l.finished(nT(function(){this._state="ready",t.renderFinally()},this)).start()},t.prototype._resetController=function(e){var t=this._controller,n=this._controllerHost;n||(this._controllerHost={target:this.group},n=this._controllerHost),t||((t=this._controller=new wZ(e.getZr())).enable(this.seriesModel.get("roam")),n.zoomLimit=this.seriesModel.get("scaleLimit"),n.zoom=this.seriesModel.get("zoom"),t.on("pan",nT(this._onPan,this)),t.on("zoom",nT(this._onZoom,this)));var i=new rt(0,0,e.getWidth(),e.getHeight());t.setPointerChecker(function(e,t,n){return i.contain(t,n)})},t.prototype._clearController=function(){var e=this._controller;this._controllerHost=null,e&&(e.dispose(),e=null)},t.prototype._onPan=function(e){if("animating"!==this._state&&(Math.abs(e.dx)>3||Math.abs(e.dy)>3)){var t=this.seriesModel.getData().tree.root;if(t){var n=t.getLayout();n&&this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+e.dx,y:n.y+e.dy,width:n.width,height:n.height}})}}},t.prototype._onZoom=function(e){var t=e.originX,n=e.originY,i=e.scale;if("animating"!==this._state){var r=this.seriesModel.getData().tree.root;if(!r)return;var o=r.getLayout();if(!o)return;var a=new rt(o.x,o.y,o.width,o.height),s=null,l=this._controllerHost;s=l.zoomLimit;var d=l.zoom=l.zoom||1;if(d*=i,s){var u=s.min||0;d=Math.max(Math.min(s.max||1/0,d),u)}var c=d/l.zoom;l.zoom=d;var h=this.seriesModel.layoutInfo;t-=h.x,n-=h.y;var p=iq();iX(p,p,[-t,-n]),iQ(p,p,[c,c]),iX(p,p,[t,n]),a.applyTransform(p),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:a.x,y:a.y,width:a.width,height:a.height}})}},t.prototype._initEvents=function(e){var t=this;e.on("click",function(e){if("ready"===t._state){var n=t.seriesModel.get("nodeClick",!0);if(n){var i=t.findTarget(e.offsetX,e.offsetY);if(i){var r=i.node;if(r.getLayout().isLeafRoot)t._rootToNode(i);else if("zoomToNode"===n)t._zoomToNode(i);else if("link"===n){var o=r.hostTree.data.getItemModel(r.dataIndex),a=o.get("link",!0),s=o.get("target",!0)||"blank";a&&uq(a,s)}}}}},this)},t.prototype._renderBreadcrumb=function(e,t,n){var i=this;!n&&((n=null!=e.get("leafDepth",!0)?{node:e.getViewRoot()}:this.findTarget(t.getWidth()/2,t.getHeight()/2))||(n={node:e.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new SY(this.group))).render(e,t,n.node,function(t){"animating"!==i._state&&(Sj(e.getViewRoot(),t)?i._rootToNode({node:t}):i._zoomToNode({node:t}))})},t.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=S3(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},t.prototype.dispose=function(){this._clearController()},t.prototype._zoomToNode=function(e){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:e.node})},t.prototype._rootToNode=function(e){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:e.node})},t.prototype.findTarget=function(e,t){var n;return this.seriesModel.getViewRoot().eachNode({attr:"viewChildren",order:"preorder"},function(i){var r=this._storage.background[i.getRawIndex()];if(r){var o=r.transformCoordToLocal(e,t),a=r.shape;if(!(a.x<=o[0])||!(o[0]<=a.x+a.width)||!(a.y<=o[1])||!(o[1]<=a.y+a.height))return!1;
422n={node:i,offsetX:o[0],offsetY:o[1]}}},this),n},t.type="treemap",t}(fI);function S3(){return{nodeGroup:[],background:[],content:[]}}var S5=function(){function e(t){var n,i,r=t.mappingMethod,o=t.type,a=this.option=nc(t);this.type=o,this.mappingMethod=r,this._normalizeData=_r[r];var s=e.visualHandlers[o];this.applyVisual=s.applyVisual,this.getColorMapper=s.getColorMapper,this._normalizedToVisual=s._normalizedToVisual[r],"piecewise"===r?(S4(a),i=(n=a).pieceList,n.hasSpecialVisual=!1,nw(i,function(e,t){e.originIndex=t,null!=e.visual&&(n.hasSpecialVisual=!0)})):"category"===r?a.categories?function(e){var t=e.categories,n=e.categoryMap={},i=e.visual;if(nw(t,function(e,t){n[e]=t}),!nR(i)){var r=[];nL(i)?nw(i,function(e,t){var i=n[t];r[null!=i?i:-1]=e}):r[-1]=i,i=_i(e,r)}for(var o=t.length-1;o>=0;o--)null==i[o]&&(delete n[t[o]],t.pop())}(a):S4(a,!0):(nq("linear"!==r||a.dataExtent),S4(a))}return e.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},e.prototype.getNormalizer=function(){return nT(this._normalizeData,this)},e.listVisualTypes=function(){return nM(e.visualHandlers)},e.isValidType=function(t){return e.visualHandlers.hasOwnProperty(t)},e.eachVisual=function(e,t,n){nL(e)?nw(e,t,n):t.call(n,e)},e.mapVisual=function(t,n,i){var r,o=nR(t)?[]:nL(t)?{}:(r=!0,null);return e.eachVisual(t,function(e,t){var a=n.call(i,e,t);r?o=a:o[t]=a}),o},e.retrieveVisuals=function(t){var n,i={};return t&&nw(e.visualHandlers,function(e,r){t.hasOwnProperty(r)&&(i[r]=t[r],n=!0)}),n?i:null},e.prepareVisualTypes=function(e){if(nR(e))e=e.slice();else{if(!nL(e))return[];var t=[];nw(e,function(e,n){t.push(n)}),e=t}return e.sort(function(e,t){return"color"===t&&"color"!==e&&0===e.indexOf("color")?1:-1}),e},e.dependsOn=function(e,t){return"color"===t?!!(e&&0===e.indexOf(t)):e===t},e.findPieceIndex=function(e,t,n){for(var i,r=1/0,o=0,a=t.length;o<a;o++){var s=t[o].value;if(null!=s){if(s===e||nA(s)&&s===e+"")return o;n&&S(s,o)}}for(var o=0,a=t.length;o<a;o++){var l,d,u,c,h,p,f,g,m,v,y,b,x=t[o],w=x.interval,C=x.close;if(w){if(w[0]===-1/0){if(l=C[1],d=e,u=w[1],l?d<=u:d<u)return o}else if(w[1]===1/0){if(c=C[0],h=w[0],p=e,c?h<=p:h<p)return o}else{if(f=C[0],g=w[0],m=e,(f?g<=m:g<m)&&(v=C[1],y=e,b=w[1],v?y<=b:y<b))return o}n&&S(w[0],o),n&&S(w[1],o)}}if(n)return e===1/0?t.length-1:e===-1/0?0:i;function S(t,n){var o=Math.abs(t-e);o<r&&(r=o,i=n)}},e.visualHandlers={color:{applyVisual:S7("color"),getColorMapper:function(){var e=this.option;return nT("category"===e.mappingMethod?function(e,t){return t||(e=this._normalizeData(e)),S9.call(this,e)}:function(t,n,i){var r=!!i;return n||(t=this._normalizeData(t)),i=r7(t,e.parsedVisual,i),r?i:on(i,"rgba")},this)},_normalizedToVisual:{linear:function(e){return on(r7(e,this.option.parsedVisual),"rgba")},category:S9,piecewise:function(e,t){var n=_n.call(this,t);return null==n&&(n=on(r7(e,this.option.parsedVisual),"rgba")),n},fixed:_e}},colorHue:S6(function(e,t){return oe(e,t)}),colorSaturation:S6(function(e,t){return oe(e,null,t)}),colorLightness:S6(function(e,t){return oe(e,null,null,t)}),colorAlpha:S6(function(e,t){return ot(e,t)}),decal:{applyVisual:S7("decal"),_normalizedToVisual:{linear:null,category:S9,piecewise:null,fixed:null}},opacity:{applyVisual:S7("opacity"),_normalizedToVisual:_t([0,1])},liftZ:{applyVisual:S7("liftZ"),_normalizedToVisual:{linear:_e,category:_e,piecewise:_e,fixed:_e}},symbol:{applyVisual:function(e,t,n){n("symbol",this.mapValueToVisual(e))},_normalizedToVisual:{linear:S8,category:S9,piecewise:function(e,t){var n=_n.call(this,t);return null==n&&(n=S8.call(this,e)),n},fixed:_e}},symbolSize:{applyVisual:S7("symbolSize"),_normalizedToVisual:_t([0,1])}},e}();function S4(e,t){var n=e.visual,i=[];nL(n)?nw(n,function(e){i.push(e)}):null!=n&&i.push(n),t||1!==i.length||({color:1,symbol:1}).hasOwnProperty(e.type)||(i[1]=i[0]),_i(e,i)}function S6(e){return{applyVisual:function(t,n,i){var r=this.mapValueToVisual(t);i("color",e(n("color"),r))},_normalizedToVisual:_t([0,1])}}function S8(e){var t=this.option.visual;return t[Math.round(aD(e,[0,1],[0,t.length-1],!0))]||{}}function S7(e){return function(t,n,i){i(e,this.mapValueToVisual(t))}}function S9(e){var t=this.option.visual;return t[this.option.loop&&-1!==e?e%t.length:e]}function _e(){return this.option.visual[0]}function _t(e){return{linear:function(t){return aD(t,e,this.option.visual,!0)},category:S9,piecewise:function(t,n){var i=_n.call(this,n);return null==i&&(i=aD(t,e,this.option.visual,!0)),i},fixed:_e}}function _n(e){var t=this.option,n=t.pieceList;if(t.hasSpecialVisual){var i=S5.findPieceIndex(e,n),r=n[i];if(r&&r.visual)return r.visual[this.type]}}function _i(e,t){return e.visual=t,"color"===e.type&&(e.parsedVisual=nC(t,function(e){return r5(e)||[0,0,0,1]})),t}var _r={linear:function(e){return aD(e,this.option.dataExtent,[0,1],!0)},piecewise:function(e){var t=this.option.pieceList,n=S5.findPieceIndex(e,t,!0);if(null!=n)return aD(n,[0,t.length-1],[0,1],!0)},category:function(e){var t=this.option.categories?this.option.categoryMap[e]:e;return null==t?-1:t},fixed:n6},_o=a9();let _a={seriesType:"treemap",reset:function(e){var t=e.getData().tree.root;t.isRemoved()||function e(t,n,i,r){var o=t.getModel(),a=t.getLayout(),s=t.hostTree.data;if(a&&!a.invisible&&a.isInView){var l,d,u,c,h,p,f,g=o.getModel("itemStyle"),m=(l=g,d=n,u=r,c=nf({},d),h=u.designatedVisualItemStyle,nw(["color","colorAlpha","colorSaturation"],function(e){h[e]=d[e];var t=l.get(e);h[e]=null,null!=t&&(c[e]=t)}),c),v=s.ensureUniqueItemVisual(t.dataIndex,"style"),y=g.get("borderColor"),b=g.get("borderColorSaturation");null!=b&&(p=b,y=null!=(f=_s(m))?oe(f,null,null,p):null),v.stroke=y;var x=t.viewChildren;if(x&&x.length){var w=function(e,t,n,i,r,o){if(o&&o.length){var a=_d(t,"color")||null!=r.color&&"none"!==r.color&&(_d(t,"colorAlpha")||_d(t,"colorSaturation"));
422if(a){var s=t.get("visualMin"),l=t.get("visualMax"),d=n.dataExtent.slice();null!=s&&s<d[0]&&(d[0]=s),null!=l&&l>d[1]&&(d[1]=l);var u=t.get("colorMappingBy"),c={type:a.name,dataExtent:d,visual:a.range};"color"===c.type&&("index"===u||"id"===u)?(c.mappingMethod="category",c.loop=!0):c.mappingMethod="linear";var h=new S5(c);return _o(h).drColorMappingBy=u,h}}}(0,o,a,0,m,x);nw(x,function(t,n){if(t.depth>=i.length||t===i[t.depth]){var a=function(e,t,n,i,r,o){var a=nf({},t);if(r){var s=r.type,l="color"===s&&_o(r).drColorMappingBy,d="index"===l?i:"id"===l?o.mapIdToIndex(n.getId()):n.getValue(e.get("visualDimension"));a[s]=r.mapValueToVisual(d)}return a}(o,m,t,n,w,r);e(t,a,i,r)}})}else v.fill=_s(m)}}(t,{},e.getViewRoot().getAncestors(),e)}};function _s(e){var t=_l(e,"color");if(t){var n=_l(e,"colorAlpha"),i=_l(e,"colorSaturation");return i&&(t=oe(t,null,null,i)),n&&(t=ot(t,n)),t}}function _l(e,t){var n=e[t];if(null!=n&&"none"!==n)return n}function _d(e,t){var n=e.get(t);return nR(n)&&n.length?{name:t,range:n}:null}var _u=Math.max,_c=Math.min,_h=["itemStyle","borderWidth"],_p=["itemStyle","gapWidth"],_f=["upperLabel","show"],_g=["upperLabel","height"];let _m={seriesType:"treemap",reset:function(e,t,n,i){var r=n.getWidth(),o=n.getHeight(),a=e.option,s=uX(e.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()}),l=a.size||[],d=aR(nH(s.width,l[0]),r),u=aR(nH(s.height,l[1]),o),c=i&&i.type,h=SB(i,["treemapZoomToNode","treemapRootToNode"],e),p="treemapRender"===c||"treemapMove"===c?i.rootRect:null,f=e.getViewRoot(),g=Sz(f);if("treemapMove"!==c){var m="treemapZoomToNode"===c?function(e,t,n,i,r){var o,a=(t||{}).node,s=[i,r];if(!a||a===n)return s;for(var l=i*r,d=l*e.option.zoomToNodeRatio;o=a.parentNode;){for(var u=0,c=o.children,h=0,p=c.length;h<p;h++)u+=c[h].getValue();var f=a.getValue();if(0===f)return s;d*=u/f;var g=o.getModel(),m=g.get(_h),v=Math.max(m,_y(g));(d+=4*m*m+(3*m+v)*Math.pow(d,.5))>0x1fffffffffffff&&(d=0x1fffffffffffff),a=o}d<l&&(d=l);var y=Math.pow(d/l,.5);return[i*y,r*y]}(e,h,f,d,u):p?[p.width,p.height]:[d,u],v=a.sort;v&&"asc"!==v&&"desc"!==v&&(v="desc");var y={squareRatio:a.squareRatio,sort:v,leafDepth:a.leafDepth};f.hostTree.clearLayouts();var b={x:0,y:0,width:m[0],height:m[1],area:m[0]*m[1]};f.setLayout(b),function e(t,n,i,r){if(!t.isRemoved()){var o,a,s=t.getLayout();o=s.width,a=s.height;var l=t.getModel(),d=l.get(_h),u=l.get(_p)/2,c=_y(l),h=Math.max(d,c),p=d-u,f=h-u;t.setLayout({borderWidth:d,upperHeight:h,upperLabelHeight:c},!0);var g=(o=_u(o-2*p,0))*(a=_u(a-p-f,0)),m=function(e,t,n,i,r,o){var a,s,l=e.children||[],d=i.sort;"asc"!==d&&"desc"!==d&&(d=null);var u=null!=i.leafDepth&&i.leafDepth<=o;if(r&&!u)return e.viewChildren=[];a=l=n_(l,function(e){return!e.isRemoved()}),(s=d)&&a.sort(function(e,t){var n="asc"===s?e.getValue()-t.getValue():t.getValue()-e.getValue();return 0===n?"asc"===s?e.dataIndex-t.dataIndex:t.dataIndex-e.dataIndex:n});var c=function(e,t,n){for(var i,r=0,o=0,a=t.length;o<a;o++)r+=t[o].getValue();var s=e.get("visualDimension");return t&&t.length?"value"===s&&n?(i=[t[t.length-1].getValue(),t[0].getValue()],"asc"===n&&i.reverse()):(i=[1/0,-1/0],nw(t,function(e){var t=e.getValue(s);t<i[0]&&(i[0]=t),t>i[1]&&(i[1]=t)})):i=[NaN,NaN],{sum:r,dataExtent:i}}(t,l,d);if(0===c.sum||(c.sum=function(e,t,n,i,r){if(!i)return n;for(var o=e.get("visibleMin"),a=r.length,s=a,l=a-1;l>=0;l--){var d=r["asc"===i?a-l-1:l].getValue();d/n*t<o&&(s=l,n-=d)}return"asc"===i?r.splice(0,a-s):r.splice(s,a-s),n}(t,n,c.sum,d,l),0===c.sum))return e.viewChildren=[];for(var h=0,p=l.length;h<p;h++){var f=l[h].getValue()/c.sum*n;l[h].setLayout({area:f})}return u&&(l.length&&e.setLayout({isLeafRoot:!0},!0),l.length=0),e.viewChildren=l,e.setLayout({dataExtent:c.dataExtent},!0),l}(t,l,g,n,i,r);if(m.length){var v={x:p,y:f,width:o,height:a},y=_c(o,a),b=1/0,x=[];x.area=0;for(var w=0,C=m.length;w<C;){var S=m[w];x.push(S),x.area+=S.getLayout().area;var _=function(e,t,n){for(var i=0,r=1/0,o=0,a=void 0,s=e.length;o<s;o++)(a=e[o].getLayout().area)&&(a<r&&(r=a),a>i&&(i=a));var l=e.area*e.area,d=t*t*n;return l?_u(d*i/l,l/(d*r)):1/0}(x,y,n.squareRatio);_<=b?(w++,b=_):(x.area-=x.pop().getLayout().area,_v(x,y,v,u,!1),y=_c(v.width,v.height),x.length=x.area=0,b=1/0)}
422if(x.length&&_v(x,y,v,u,!0),!i){var k=l.get("childrenVisibleMin");null!=k&&g<k&&(i=!0)}for(var w=0,C=m.length;w<C;w++)e(m[w],n,i,r+1)}}}(f,y,!1,0),b=f.getLayout(),nw(g,function(e,t){var n=(g[t+1]||f).getValue();e.setLayout(nf({dataExtent:[n,n],borderWidth:0,upperHeight:0},b))})}var x=e.getData().tree.root;x.setLayout(function(e,t,n){if(t)return{x:t.x,y:t.y};var i={x:0,y:0};if(!n)return i;var r=n.node,o=r.getLayout();if(!o)return i;for(var a=[o.width/2,o.height/2],s=r;s;){var l=s.getLayout();a[0]+=l.x,a[1]+=l.y,s=s.parentNode}return{x:e.width/2-a[0],y:e.height/2-a[1]}}(s,p,h),!0),e.setLayoutInfo(s),function e(t,n,i,r,o){var a=t.getLayout(),s=i[o],l=s&&s===t;if((!s||l)&&(o!==i.length||t===r)){t.setLayout({isInView:!0,invisible:!l&&!n.intersect(a),isAboveViewRoot:l},!0);var d=new rt(n.x-a.x,n.y-a.y,n.width,n.height);nw(t.viewChildren||[],function(t){e(t,d,i,r,o+1)})}}(x,new rt(-s.x,-s.y,r,o),g,f,0)}};function _v(e,t,n,i,r){var o=+(t!==n.width),a=1-o,s=["x","y"],l=["width","height"],d=n[s[o]],u=t?e.area/t:0;(r||u>n[l[a]])&&(u=n[l[a]]);for(var c=0,h=e.length;c<h;c++){var p=e[c],f={},g=u?p.getLayout().area/u:0,m=f[l[a]]=_u(u-2*i,0),v=n[s[o]]+n[l[o]]-d,y=c===h-1||v<g?v:g,b=f[l[o]]=_u(y-2*i,0);f[s[a]]=n[s[a]]+_c(i,m/2),f[s[o]]=d+_c(i,b/2),d+=y,p.setLayout(f,!0)}n[s[a]]+=u,n[l[a]]-=u}function _y(e){return e.get(_f)?e.get(_g):0}function _b(e){var t=e.findComponents({mainType:"legend"});t&&t.length&&e.eachSeriesByType("graph",function(e){var n=e.getCategoriesData(),i=e.getGraph().data,r=n.mapArray(n.getName);i.filterSelf(function(e){var n=i.getItemModel(e).getShallow("category");if(null!=n){nE(n)&&(n=r[n]);for(var o=0;o<t.length;o++)if(!t[o].isSelected(n))return!1}return!0})})}function _x(e){var t={};e.eachSeriesByType("graph",function(e){var n=e.getCategoriesData(),i=e.getData(),r={};n.each(function(i){var o=n.getName(i);r["ec-"+o]=i;var a=n.getItemModel(i),s=a.getModel("itemStyle").getItemStyle();s.fill||(s.fill=e.getColorFromPalette(o,t)),n.setItemVisual(i,"style",s);for(var l=["symbol","symbolSize","symbolKeepAspect"],d=0;d<l.length;d++){var u=a.getShallow(l[d],!0);null!=u&&n.setItemVisual(i,l[d],u)}}),n.count()&&i.each(function(e){var t=i.getItemModel(e).getShallow("category");if(null!=t){nA(t)&&(t=r["ec-"+t]);var o=n.getItemVisual(t,"style");nf(i.ensureUniqueItemVisual(e,"style"),o);for(var a=["symbol","symbolSize","symbolKeepAspect"],s=0;s<a.length;s++)i.setItemVisual(e,a[s],n.getItemVisual(t,a[s]))}})})}function _w(e){return e instanceof Array||(e=[e,e]),e}function _C(e){e.eachSeriesByType("graph",function(e){var t=e.getGraph(),n=e.getEdgeData(),i=_w(e.get("edgeSymbol")),r=_w(e.get("edgeSymbolSize"));n.setVisual("fromSymbol",i&&i[0]),n.setVisual("toSymbol",i&&i[1]),n.setVisual("fromSymbolSize",r&&r[0]),n.setVisual("toSymbolSize",r&&r[1]),n.setVisual("style",e.getModel("lineStyle").getLineStyle()),n.each(function(e){var i=n.getItemModel(e),r=t.getEdgeByIndex(e),o=_w(i.getShallow("symbol",!0)),a=_w(i.get
422Shallow("symbolSize",!0)),s=i.getModel("lineStyle").getLineStyle(),l=n.ensureUniqueItemVisual(e,"style");switch(nf(l,s),l.stroke){case"source":var d=r.node1.getVisual("style");l.stroke=d&&d.fill;break;case"target":var d=r.node2.getVisual("style");l.stroke=d&&d.fill}o[0]&&r.setVisual("fromSymbol",o[0]),o[1]&&r.setVisual("toSymbol",o[1]),a[0]&&r.setVisual("fromSymbolSize",a[0]),a[1]&&r.setVisual("toSymbolSize",a[1])})})}var _S=function(e){return e.get("autoCurveness")||null},__=function(e,t){var n=_S(e),i=20,r=[];if(nE(n))i=n;else if(nR(n)){e.__curvenessList=n;return}t>i&&(i=t);var o=i%2?i+2:i+3;r=[];for(var a=0;a<o;a++)r.push((a%2?a+1:a)/10*(a%2?-1:1));e.__curvenessList=r},_k=function(e,t,n){var i=[e.id,e.dataIndex].join("."),r=[t.id,t.dataIndex].join(".");return[n.uid,i,r].join("-->")},_M=function(e){var t=e.split("-->");return[t[0],t[2],t[1]].join("-->")},_T=function(e,t){var n=_k(e.node1,e.node2,t);return t.__edgeMap[n]},_D=function(e,t){var n=t.__edgeMap;return n[e]?n[e].length:0};function _R(e,t,n,i){var r=_S(t),o=nR(r);if(!r)return null;var a=_T(e,t);if(!a)return null;for(var s=-1,l=0;l<a.length;l++)if(a[l]===n){s=l;break}var d=_D(_k(e.node1,e.node2,t),t)+_D(_k(e.node2,e.node1,t),t);__(t,d),e.lineStyle=e.lineStyle||{};var u=_k(e.node1,e.node2,t),c=t.__curvenessList,h=o||d%2?0:1;if(a.isForward)return c[h+s];var p=_D(_M(u),t),f=c[s+p+h];return i?o?r&&0===r[0]?(p+h)%2?f:-f:((p%2?0:1)+h)%2?f:-f:(p+h)%2?f:-f:c[s+p+h]}function _I(e){var t=e.coordinateSystem;if(!t||"view"===t.type){var n=e.getGraph();n.eachNode(function(e){var t=e.getModel();e.setLayout([+t.get("x"),+t.get("y")])}),_A(n,e)}}function _A(e,t){e.eachEdge(function(e,n){var i=nW(e.getModel().get(["lineStyle","curveness"]),-_R(e,t,n,!0),0),r=ie(e.node1.getLayout()),o=ie(e.node2.getLayout()),a=[r,o];+i&&a.push([(r[0]+o[0])/2-(r[1]-o[1])*i,(r[1]+o[1])/2-(o[0]-r[0])*i]),e.setLayout(a)})}function _P(e,t){e.eachSeriesByType("graph",function(e){var t=e.get("layout"),n=e.coordinateSystem;if(n&&"view"!==n.type){var i=e.getData(),r=[];nw(n.dimensions,function(e){r=r.concat(i.mapDimensionsAll(e))});for(var o=0;o<i.count();o++){for(var a=[],s=!1,l=0;l<r.length;l++){var d=i.get(r[l],o);isNaN(d)||(s=!0),a.push(d)}s?i.setItemLayout(o,n.dataToPoint(a)):i.setItemLayout(o,[NaN,NaN])}_A(i.graph,e)}else t&&"none"!==t||_I(e)})}function _E(e){var t=e.coordinateSystem;if("view"!==t.type)return 1;var n=e.option.nodeScaleRatio,i=t.scaleX;return((t.getZoom()-1)*n+1)/i}function _L(e){var t=e.getVisual("symbolSize");return t instanceof Array&&(t=(t[0]+t[1])/2),+t}var _F=Math.PI,_O=[];function _N(e,t,n,i){var r=e.coordinateSystem;if(!r||"view"===r.type){var o=r.getBoundingRect(),a=e.getData(),s=a.graph,l=o.width/2+o.x,d=o.height/2+o.y,u=Math.min(o.width,o.height)/2,c=a.count();if(a.setLayout({cx:l,cy:d}),c){if(n){var h=r.pointToData(i),p=[h[0]-l,h[1]-d];ih(p,p),ic(p,p,u),n.setLayout([l+p[0],d+p[1]],!0),_z(n,e.get(["circular","rotateLabel"]),l,d)}_B[t](e,s,a,u,l,d,c),s.eachEdge(function(t,n){var i,r=nW(t.getModel().get(["lineStyle","curveness"]),_R(t,e,n),0),o=ie(t.node1.getLayout()),a=ie(t.node2.getLayout()),s=(o[0]+a[0])/2,u=(o[1]+a[1])/2;+r&&(r*=3,i=[l*r+s*(1-r),d*r+u*(1-r)]),t.setLayout([o,a,i])})}}}var _B={value:function(e,t,n,i,r,o,a){var s=0,l=n.getSum("value"),d=2*Math.PI/(l||a);t.eachNode(function(e){var t=e.getValue("value"),n=d*(l?t:1)/2;s+=n,e.setLayout([i*Math.cos(s)+r,i*Math.sin(s)+o]),s+=n})},symbolSize:function(e,t,n,i,r,o,a){var s=0;_O.length=a;var l=_E(e);t.eachNode(function(e){var t=_L(e);isNaN(t)&&(t=2),t<0&&(t=0);var n=Math.asin((t*=l)/2/i);isNaN(n)&&(n=_F/2),_O[e.dataIndex]=n,s+=2*n});var d=(2*_F-s)/a/2,u=0;t.eachNode(function(e){var t=d+_O[e.dataIndex];u+=t,e.getLayout()&&e.getLayout().fixed||e.setLayout([i*Math.cos(u)+r,i*Math.sin(u)+o]),u+=t})}};function _z(e,t,n,i){var r=e.getGraphicEl();if(r){var o=e.getModel().get(["label","rotate"])||0,a=r.getSymbolPath();if(t){var s=e.getLayout(),l=Math.atan2(s[1]-i,s[0]-n);l<0&&(l=2*Math.PI+l);var d=s[0]<n;d&&(l-=Math.PI);var u=d?"left":"right";a.setTextConfig({rotation:-l,position:u,origin:"center"});var c=a.ensureState("emphasis");nf(c.textConfig||(c.textConfig={}),{position:u})}else a.setTextConfig({rotation:o*=Math.PI/180})}}function _j(e){e.eachSeriesByType("graph",function(e){"circular"===e.get("layout")&&_N(e,"symbolSize")})}function _V(e){e.eachSeriesByType("graph",function(e){var t=e.coordinateSystem;if(!t||"view"===t.type)if("force"===e.get("layout")){var n=e.preservedPoints||{},i=e.getGraph(),r=i.data,o=i.edgeData,a=e.getModel("force"),s=a.get("initLayout");e.preservedPoints?r.each(function(e){var t=r.getId(e);r.setItemLayout(e,n[t]||[NaN,NaN])}):s&&"none"!==s?"circular"===s&&_N(e,"value"):_I(e);var l=r.getDataExtent("value"),d=o.getDataExtent("value"),u=a.get("repulsion"),c=a.get("edgeLength"),h=nR(u)?u:[u,u],p=nR(c)?c:[c,c];p=[p[1],p[0]];var f=r.mapArray("value",function(e,t){var n=r.getItemLayout(t),i=aD(e,l,h);return isNaN(i)&&(i=(h[0]+h[1])/2),{w:i,rep:i,fixed:r.getItemModel(t).get("fixed"),p:!n||isNaN(n[0])||isNaN(n[1])?null:n}}),g=o.mapArray("value",function(t,n){var r=i.getEdgeByIndex(n),o=aD(t,d,p);isNaN(o)&&(o=(p[0]+p[1])/2);var a=r.getModel(),s=nW(r.getModel().get(["lineStyle","curveness"]),-_R(r,e,n,!0),0);return{n1:f[r.node1.dataIndex],n2:f[r.node2.dataIndex],d:o,curveness:s,ignoreForceLayout:a.get("ignoreForceLayout")}}),m=function(e,t,n){for(var i,r,o=n.rect,a=o.width,s=o.height,l=[o.x+a/2,o.y+s/2],d=null==n.gravity?.1:n.gravity,u=0;u<e.length;u++){var c=e[u];c.p||(c.p=n7(a*(Math.random()-.5)+l[0],s*(Math.random()-.5)+l[1])),c.pp=ie(c.p),c.edges=null}var h=null==n.friction?.6:n.friction,p=h;return{warmUp:function(){p=.8*h},setFixed:function(t){e[t].fixed=!0},setUnfixed:function(t){e[t].fixed=!1},beforeStep:function(e){i=e},afterStep:function(e){r=e},step:function(n){i&&i(e,t);for(var o=[],a=e.length,s=0;s<t.length;s++){var u=t[s];if(!u.ignoreForceLayout){var c=u.n1,h=u.n2;io(o,h.p,c.p);var f=ia(o)-u.d,g=h.w/(c.w+h.w);isNaN(g)&&(g=0),ih(o,o),c.fixed||ir(c.p,c.p,o,g*f*p),h.fixed||ir(h.p,h.p,o,-(1-g)*f*p)}}for(var s=0;s<a;s++){var m=e[s];m.fixed||(io(o,l,m.p),ir(m.p,m.p,o,d*p))}for(var s=0;s<a;s++)for(var c=e[s],v=s+1;v<a;v++){var h=e[v];io(o,h.p,c.p);var f=ia(o);0===f&&(it(o,Math.random()-.5,Math.random()-.5),f=1);var y=(c.rep+h.rep)/f/f;c.fixed||ir(c.pp,c.pp,o,y),h.fixed||ir(h.pp,h.pp,o,-y)}for(var b=[],s=0;s<a;s++){var m=e[s];m.fixed||(io(b,m.p,m.pp),ir(m.p,m.p,b,p),n9(m.pp,m.p))}var x=(p*=.992)<.01;r&&r(e,t,x),n&&n(x)}}}
422(f,g,{rect:t.getBoundingRect(),gravity:a.get("gravity"),friction:a.get("friction")});m.beforeStep(function(e,t){for(var n=0,r=e.length;n<r;n++)e[n].fixed&&n9(e[n].p,i.getNodeByIndex(n).getLayout())}),m.afterStep(function(e,t,o){for(var a=0,s=e.length;a<s;a++)e[a].fixed||i.getNodeByIndex(a).setLayout(e[a].p),n[r.getId(a)]=e[a].p;for(var a=0,s=t.length;a<s;a++){var l=t[a],d=i.getEdgeByIndex(a),u=l.n1.p,c=l.n2.p,h=d.getLayout();(h=h?h.slice():[])[0]=h[0]||[],h[1]=h[1]||[],n9(h[0],u),n9(h[1],c),+l.curveness&&(h[2]=[(u[0]+c[0])/2-(u[1]-c[1])*l.curveness,(u[1]+c[1])/2-(c[0]-u[0])*l.curveness]),d.setLayout(h)}}),e.forceLayout=m,e.preservedPoints=n,m.step()}else e.forceLayout=null})}function _H(e,t){var n=[];return e.eachSeriesByType("graph",function(e){var i=e.get("coordinateSystem");if(!i||"view"===i){var r=e.getData(),o=r.mapArray(function(e){var t=r.getItemModel(e);return[+t.get("x"),+t.get("y")]}),a=[],s=[];sJ(o,a,s),s[0]-a[0]==0&&(s[0]+=1,a[0]-=1),s[1]-a[1]==0&&(s[1]+=1,a[1]-=1);var l=(s[0]-a[0])/(s[1]-a[1]),d=uX(nf(e.getBoxLayoutParams(),{aspect:l}),{width:t.getWidth(),height:t.getHeight()});isNaN(l)&&(a=[d.x,d.y],s=[d.x+d.width,d.y+d.height]);var u=s[0]-a[0],c=s[1]-a[1],h=d.width,p=d.height,f=e.coordinateSystem=new C8;f.zoomLimit=e.get("scaleLimit"),f.setBoundingRect(a[0],a[1],u,c),f.setViewRect(d.x,d.y,h,p),f.setCenter(e.get("center"),t),f.setZoom(e.get("zoom")),n.push(f)}}),n}var _G=pU.prototype,_W=pZ.prototype,_$=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1};function _U(e){return isNaN(+e.cpx1)||isNaN(+e.cpy1)}(0,tQ.__extends)(function(){return null!==_$&&_$.apply(this,arguments)||this},_$);var _q=function(e){function t(t){var n=e.call(this,t)||this;return n.type="ec-line",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new _$},t.prototype.buildPath=function(e,t){_U(t)?_G.buildPath.call(this,e,t):_W.buildPath.call(this,e,t)},t.prototype.pointAt=function(e){return _U(this.shape)?_G.pointAt.call(this,e):_W.pointAt.call(this,e)},t.prototype.tangentAt=function(e){var t=this.shape,n=_U(t)?[t.x2-t.x1,t.y2-t.y1]:_W.tangentAt.call(this,e);return ih(n,n)},t}(lk),_K=["fromSymbol","toSymbol"];function _Y(e){return"_"+e+"Type"}function _Z(e,t,n){var i=t.getItemVisual(n,e);if(!i||"none"===i)return i;var r=t.getItemVisual(n,e+"Size"),o=t.getItemVisual(n,e+"Rotate"),a=t.getItemVisual(n,e+"Offset"),s=t.getItemVisual(n,e+"KeepAspect"),l=gk(r),d=gM(a||0,l);return i+l+d+(o||"")+(s||"")}function _X(e,t,n){var i=t.getItemVisual(n,e);if(i&&"none"!==i){var r=t.getItemVisual(n,e+"Size"),o=t.getItemVisual(n,e+"Rotate"),a=t.getItemVisual(n,e+"Offset"),s=t.getItemVisual(n,e+"KeepAspect"),l=gk(r),d=gM(a||0,l),u=g_(i,-l[0]/2+d[0],-l[1]/2+d[1],l[0],l[1],null,s);return u.__specifiedRotation=null==o||isNaN(o)?void 0:o*Math.PI/180||0,u.name=e,u}}function _J(e,t){e.x1=t[0][0],e.y1=t[0][1],e.x2=t[1][0],e.y2=t[1][1],e.percent=1;var n=t[2];n?(e.cpx1=n[0],e.cpy1=n[1]):(e.cpx1=NaN,e.cpy1=NaN)}var _Q=function(e){function t(t,n,i){var r=e.call(this)||this;return r._createLine(t,n,i),r}return(0,tQ.__extends)(t,e),t.prototype._createLine=function(e,t,n){var i,r,o=e.hostModel,a=(i=e.getItemLayout(t),_J((r=new _q({name:"line",subPixelOptimize:!0})).shape,i),r);a.shape.percent=0,dz(a,{shape:{percent:1}},o,t),this.add(a),nw(_K,function(n){var i=_X(n,e,t);this.add(i),this[_Y(n)]=_Z(n,e,t)},this),this._updateCommonStl(e,t,n)},t.prototype.updateData=function(e,t,n){var i=e.hostModel,r=this.childOfName("line"),o=e.getItemLayout(t),a={shape:{}};_J(a.shape,o),dB(r,a,i,t),nw(_K,function(n){var i=_Z(n,e,t),r=_Y(n);if(this[r]!==i){this.remove(this.childOfName(n));var o=_X(n,e,t);this.add(o)}this[r]=i},this),this._updateCommonStl(e,t,n)},t.prototype.getLinePath=function(){return this.childAt(0)},t.prototype._updateCommonStl=function(e,t,n){var i=e.hostModel,r=this.childOfName("line"),o=n&&n.emphasisLineStyle,a=n&&n.blurLineStyle,s=n&&n.selectLineStyle,l=n&&n.labelStatesModels,d=n&&n.emphasisDisabled,u=n&&n.focus,c=n&&n.blurScope;if(!n||e.hasItemOption){var h=e.getItemModel(t),p=h.getModel("emphasis");o=p.getModel("lineStyle").getLineStyle(),a=h.getModel(["blur","lineStyle"]).getLineStyle(),s=h.getModel(["select","lineStyle"]).getLineStyle(),d=p.get("disabled"),u=p.get("focus"),c=p.get("blurScope"),l=dY(h)}var f=e.getItemVisual(t,"style"),g=f.stroke;r.useStyle(f),r.style.fill=null,r.style.strokeNoScale=!0,r.ensureState("emphasis").style=o,r.ensureState("blur").style=a,r.ensureState("select").style=s,nw(_K,function(e){var t=this.childOfName(e);
vendor: 6,363 bytes, line 422
422if(t){t.setColor(g),t.style.opacity=f.opacity;for(var n=0;n<l4.length;n++){var i=l4[n],o=r.getState(i);if(o){var a=o.style||{},s=t.ensureState(i),l=s.style||(s.style={});null!=a.stroke&&(l[t.__isEmptyBrush?"stroke":"fill"]=a.stroke),null!=a.opacity&&(l.opacity=a.opacity)}}t.markRedraw()}},this);var m=i.getRawValue(t);dK(this,l,{labelDataIndex:t,labelFetcher:{getFormattedLabel:function(t,n){return i.getFormattedLabel(t,n,e.dataType)}},inheritColor:g||"#000",defaultOpacity:f.opacity,defaultText:(null==m?e.getName(t):isFinite(m)?aI(m):m)+""});var v=this.getTextContent();if(v){var y=l.normal;v.__align=v.style.align,v.__verticalAlign=v.style.verticalAlign,v.__position=y.get("position")||"middle";var b=y.get("distance");nR(b)||(b=[b,b]),v.__labelDistance=b}this.setTextConfig({position:null,local:!0,inside:!1}),dM(this,u,c,d)},t.prototype.highlight=function(){dv(this)},t.prototype.downplay=function(){dy(this)},t.prototype.updateLayout=function(e,t){this.setLinePoints(e.getItemLayout(t))},t.prototype.setLinePoints=function(e){var t=this.childOfName("line");_J(t.shape,e),t.dirty()},t.prototype.beforeUpdate=function(){var e=this.childOfName("fromSymbol"),t=this.childOfName("toSymbol"),n=this.getTextContent();if(e||t||n&&!n.ignore){for(var i=1,r=this.parent;r;)r.scaleX&&(i/=r.scaleX),r=r.parent;var o=this.childOfName("line");if(this.__dirty||o.__dirty){var a=o.shape.percent,s=o.pointAt(0),l=o.pointAt(a),d=io([],l,s);if(ih(d,d),e&&(e.setPosition(s),C(e,0),e.scaleX=e.scaleY=i*a,e.markRedraw()),t&&(t.setPosition(l),C(t,1),t.scaleX=t.scaleY=i*a,t.markRedraw()),n&&!n.ignore){n.x=n.y=0,n.originX=n.originY=0;var u=void 0,c=void 0,h=n.__labelDistance,p=h[0]*i,f=h[1]*i,g=a/2,m=o.tangentAt(g),v=[m[1],-m[0]],y=o.pointAt(g);v[1]>0&&(v[0]=-v[0],v[1]=-v[1]);var b=m[0]<0?-1:1;if("start"!==n.__position&&"end"!==n.__position){var x=-Math.atan2(m[1],m[0]);l[0]<s[0]&&(x=Math.PI+x),n.rotation=x}var w=void 0;switch(n.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":w=-f,c="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":w=f,c="top";break;default:w=0,c="middle"}switch(n.__position){case"end":n.x=d[0]*p+l[0],n.y=d[1]*f+l[1],u=d[0]>.8?"left":d[0]<-.8?"right":"center",c=d[1]>.8?"top":d[1]<-.8?"bottom":"middle";break;case"start":n.x=-d[0]*p+s[0],n.y=-d[1]*f+s[1],u=d[0]>.8?"right":d[0]<-.8?"left":"center",c=d[1]>.8?"bottom":d[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":n.x=p*b+s[0],n.y=s[1]+w,u=m[0]<0?"right":"left",n.originX=-p*b,n.originY=-w;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":n.x=y[0],n.y=y[1]+w,u="center",n.originY=-w;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":n.x=-p*b+l[0],n.y=l[1]+w,u=m[0]>=0?"right":"left",n.originX=p*b,n.originY=-w}n.scaleX=n.scaleY=i,n.setStyle({verticalAlign:n.__verticalAlign||c,align:n.__align||u})}}}function C(e,t){var n=e.__specifiedRotation;if(null==n){var i=o.tangentAt(t);e.attr("rotation",(1===t?-1:1)*Math.PI/2-Math.atan2(i[1],i[0]))}else e.attr("rotation",n)}},t}(av),_0=function(){function e(e){this.group=new av,this._LineCtor=e||_Q}return e.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var n=this.group,i=this._lineData;this._lineData=e,i||n.removeAll();var r=_1(e);e.diff(i).add(function(n){t._doAdd(e,n,r)}).update(function(n,o){t._doUpdate(i,e,o,n,r)}).remove(function(e){n.remove(i.getItemGraphicEl(e))}).execute()},e.prototype.updateLayout=function(){var e=this._lineData;e&&e.eachItemGraphicEl(function(t,n){t.updateLayout(e,n)},this)},e.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=_1(e),this._lineData=null,this.group.removeAll()},e.prototype.incrementalUpdate=function(e,t){function n(e){var t;e.isGroup||(t=e).animators&&t.animators.length>0||(e.incremental=!0,e.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[];for(var i=e.start;i<e.end;i++)if(_3(t.getItemLayout(i))){var r=new this._LineCtor(t,i,this._seriesScope);r.traverse(n),this.group.add(r),t.setItemGraphicEl(i,r),this._progressiveEls.push(r)}},e.prototype.remove=function(){this.group.removeAll()},e.prototype.eachRendered=function(e){fT(this._progressiveEls||this.group,e)},e.prototype._doAdd=function(e,t,n){if(_3(e.getItemLayout(t))){var i=new this._LineCtor(e,t,n);e.setItemGraphicEl(t,i),this.group.add(i)}},e.prototype._doUpdate=function(e,t,n,i,r){var o=e.getItemGraphicEl(n);_3(t.getItemLayout(i))?(o?o.updateData(t,i,r):o=new this._LineCtor(t,i,r),t.setItemGraphicEl(i,o),this.group.add(o)):this.group.remove(o)},e}();function _1(e){var t=e.hostModel,n=t.getModel("emphasis");return{lineStyle:t.getModel("lineStyle").getLineStyle(),emphasisLineStyle:n.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:t.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:t.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:n.get("disabled"),blurScope:n.get("blurScope"),focus:n.get("focus"),labelStatesModels:dY(t)}}function _2(e){return isNaN(e[0])||isNaN(e[1])}function _3(e){return e&&!_2(e[0])&&!_2(e[1])}var _5=[],_4=[],_6=[],_8=Math.abs;function _7(e,t,n){for(var i,r=e[0],o=e[1],a=e[2],s=1/0,l=n*n,d=.1,u=.1;u<=.9;u+=.1){_5[0]=rO(r[0],o[0],a[0],u),_5[1]=rO(r[1],o[1],a[1],u);var c=_8(ig(_5,t)-l);c<s&&(s=c,i=u)}for(var h=0;h<32;h++){var p=i+d;_4[0]=rO(r[0],o[0],a[0],i),_4[1]=rO(r[1],o[1],a[1],i),_6[0]=rO(r[0],o[0],a[0],p),_6[1]=rO(r[1],o[1],a[1],p);var c=ig(_4,t)-l;if(.01>_8(c))break;var f=ig(_6,t)-l;d/=2,c<0?f>=0?i+=d:i-=d:f>=0?i-=d:i+=d}return i}function _9(e,t){var n=[],i=[[],[],[]],r=[[],[]],o=[];t/=2,e.eachEdge(function(e,a){var s=e.getLayout(),l=e.getVisual("fromSymbol"),d=e.getVisual("toSymbol");!s.__original&&(s.__original=[ie(s[0]),ie(s[1])],s[2]&&s.__original.push(ie(s[2])));var u=s.__original;if(null!=s[2]){if(n9(i[0],u[0]),n9(i[1],u[2]),n9(i[2],u[1]),l&&"none"!==l){var c=_L(e.node1),h=_7(i,u[0],c*t);rz(i[0][0],i[1][0],i[2][0],h,n),i[0][0]=n[3],i[1][0]=n[4],rz(i[0][1],i[1][1],i[2][1],h,n),i[0][1]=n[3],i[1][1]=n[4]}if(d&&"none"!==d){var c=_L(e.node2),h=_7(i,u[1],c*t);rz(i[0][0],i[1][0],i[2][0],h,n),i[1][0]=n[1],i[2][0]=n[2],rz(i[0][1],i[1][1],i[2][1],h,n),i[1][1]=n[1],i[2][1]=n[2]}n9(s[0],i[0]),n9(s[1],i[2]),n9(s[2],i[1])}else{if(n9(r[0],u[0]),n9(r[1],u[1]),io(o,r[1],r[0]),ih(o,o),l&&"none"!==l){var c=_L(e.node1);ir(r[0],r[0],o,c*t)}
422if(d&&"none"!==d){var c=_L(e.node2);ir(r[1],r[1],o,-c*t)}n9(s[0],r[0]),n9(s[1],r[1])}})}function ke(e){return"view"===e.type}var kt=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){var n=new yg,i=new _0,r=this.group;this._controller=new wZ(t.getZr()),this._controllerHost={target:r},r.add(n.group),r.add(i.group),this._symbolDraw=n,this._lineDraw=i,this._firstRender=!0},t.prototype.render=function(e,t,n){var i=this,r=e.coordinateSystem;this._model=e;var o=this._symbolDraw,a=this._lineDraw,s=this.group;if(ke(r)){var l={x:r.x,y:r.y,scaleX:r.scaleX,scaleY:r.scaleY};this._firstRender?s.attr(l):dB(s,l,e)}_9(e.getGraph(),_E(e));var d=e.getData();o.updateData(d);var u=e.getEdgeData();a.updateData(u),this._updateNodeAndLinkScale(),this._updateController(e,t,n),clearTimeout(this._layoutTimeout);var c=e.forceLayout,h=e.get(["force","layoutAnimation"]);c&&this._startForceLayoutIteration(c,h);var p=e.get("layout");d.graph.eachNode(function(t){var n=t.dataIndex,r=t.getGraphicEl(),o=t.getModel();if(r){r.off("drag").off("dragend");var a=o.get("draggable");a&&r.on("drag",function(o){switch(p){case"force":c.warmUp(),i._layouting||i._startForceLayoutIteration(c,h),c.setFixed(n),d.setItemLayout(n,[r.x,r.y]);break;case"circular":d.setItemLayout(n,[r.x,r.y]),t.setLayout({fixed:!0},!0),_N(e,"symbolSize",t,[o.offsetX,o.offsetY]),i.updateLayout(e);break;default:d.setItemLayout(n,[r.x,r.y]),_A(e.getGraph(),e),i.updateLayout(e)}}).on("dragend",function(){c&&c.setUnfixed(n)}),r.setDraggable(a,!!o.get("cursor")),"adjacency"===o.get(["emphasis","focus"])&&(lQ(r).focus=t.getAdjacentDataIndices())}}),d.graph.eachEdge(function(e){var t=e.getGraphicEl(),n=e.getModel().get(["emphasis","focus"]);t&&"adjacency"===n&&(lQ(t).focus={edge:[e.dataIndex],node:[e.node1.dataIndex,e.node2.dataIndex]})});var f="circular"===e.get("layout")&&e.get(["circular","rotateLabel"]),g=d.getLayout("cx"),m=d.getLayout("cy");d.graph.eachNode(function(e){_z(e,f,g,m)}),this._firstRender=!1},t.prototype.dispose=function(){this.remove(),this._controller&&this._controller.dispose(),this._controllerHost=null},t.prototype._startForceLayoutIteration=function(e,t){var n=this;!function i(){e.step(function(e){n.updateLayout(n._model),(n._layouting=!e)&&(t?n._layoutTimeout=setTimeout(i,16):i())})}()},t.prototype._updateController=function(e,t,n){var i=this,r=this._controller,o=this._controllerHost,a=this.group;(r.setPointerChecker(function(t,i,r){var o=a.getBoundingRect();return o.applyTransform(a.transform),o.contain(i,r)&&!w3(t,n,e)}),ke(e.coordinateSystem))?(r.enable(e.get("roam")),o.zoomLimit=e.get("scaleLimit"),o.zoom=e.coordinateSystem.getZoom(),r.off("pan").off("zoom").on("pan",function(t){w0(o,t.dx,t.dy),n.dispatchAction({seriesId:e.id,type:"graphRoam",dx:t.dx,dy:t.dy})}).on("zoom",function(t){w1(o,t.scale,t.originX,t.originY),n.dispatchAction({seriesId:e.id,type:"graphRoam",zoom:t.scale,originX:t.originX,originY:t.originY}),i._updateNodeAndLinkScale(),_9(e.getGraph(),_E(e)),i._lineDraw.updateLayout(),n.updateLabelLayout()})):r.disable()},t.prototype._updateNodeAndLinkScale=function(){var e=this._model,t=e.getData(),n=_E(e);t.eachItemGraphicEl(function(e,t){e&&e.setSymbolScale(n)})},t.prototype.updateLayout=function(e){_9(e.getGraph(),_E(e)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},t.prototype.remove=function(){clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},t.type="graph",t}(fI);function kn(e){return"_EC_"+e}var ki=function(){function e(e){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=e||!1}return e.prototype.isDirected=function(){return this._directed},e.prototype.addNode=function(e,t){e=null==e?""+t:""+e;var n=this._nodesMap;if(!n[kn(e)]){var i=new kr(e,t);return i.hostGraph=this,this.nodes.push(i),n[kn(e)]=i,i}},e.prototype.getNodeByIndex=function(e){var t=this.data.getRawIndex(e);return this.nodes[t]},e.prototype.getNodeById=function(e){return this._nodesMap[kn(e)]},e.prototype.addEdge=function(e,t,n){var i=this._nodesMap,r=this._edgesMap;if(nE(e)&&(e=this.nodes[e]),nE(t)&&(t=this.nodes[t]),e instanceof kr||(e=i[kn(e)]),t instanceof kr||(t=i[kn(t)]),e&&t){var o=e.id+"-"+t.id,a=new ko(e,t,n);return a.hostGraph=this,this._directed&&(e.outEdges.push(a),t.inEdges.push(a)),e.edges.push(a),e!==t&&t.edges.push(a),this.edges.push(a),r[o]=a,a}},e.prototype.getEdgeByIndex=function(e){var t=this.edgeData.getRawIndex(e);return this.edges[t]},e.prototype.getEdge=function(e,t){e instanceof kr&&(e=e.id),t instanceof kr&&(t=t.id);var n=this._edgesMap;return this._directed?n[e+"-"+t]:n[e+"-"+t]||n[t+"-"+e]},e.prototype.eachNode=function(e,t){for(var n=this.nodes,i=n.length,r=0;r<i;r++)n[r].dataIndex>=0&&e.call(t,n[r],r)},e.prototype.eachEdge=function(e,t){for(var n=this.edges,i=n.length,r=0;r<i;r++)n[r].dataIndex>=0&&n[r].node1.dataIndex>=0&&n[r].node2.dataIndex>=0&&e.call(t,n[r],r)},e.prototype.breadthFirstTraverse=function(e,t,n,i){if(t instanceof kr||(t=this._nodesMap[kn(t)]),t){for(var r="out"===n?"outEdges":"in"===n?"inEdges":"edges",o=0;o<this.nodes.length;o++)this.nodes[o].__visited=!1;if(!e.call(i,t,null))for(var a=[t];a.length;)for(var s=a.shift(),l=s[r],o=0;o<l.length;o++){var d=l[o],u=d.node1===s?d.node2:d.node1;if(!u.__visited){if(e.call(i,u,s))return;a.push(u),u.__visited=!0}}}},e.prototype.update=function(){for(var e=this.data,t=this.edgeData,n=this.nodes,i=this.edges,r=0,o=n.length;r<o;r++)n[r].dataIndex=-1;for(var r=0,o=e.count();r<o;r++)n[e.getRawIndex(r)].dataIndex=r;t.filterSelf(function(e){var n=i[t.getRawIndex(e)];return n.node1.dataIndex>=0&&n.node2.dataIndex>=0});for(var r=0,o=i.length;r<o;r++)i[r].dataIndex=-1;for(var r=0,o=t.count();r<o;r++)i[t.getRawIndex(r)].dataIndex=r},e.prototype.clone=function(){for(var t=new e(this._directed),n=this.nodes,i=this.edges,r=0;r<n.length;r++)t.addNode(n[r].id,n[r].dataIndex);for(var r=0;r<i.length;r++){var o=i[r];t.addEdge(o.node1.id,o.node2.id,o.dataIndex)}return t},e}(),kr=function(){function e(e,t){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=null==e?"":e,this.dataIndex=null==t?-1:t}return e.prototype.degree=function(){return this.edges.length},e.prototype.inDegree=function(){return this.inEdges.length},e.prototype.outDegree=function(){return this.outEdges.length},e.prototype.getModel=function(e){if(!(this.dataIndex<0))return this.hostGraph.data.getItemModel(this.dataIndex).getModel(e)},e.prototype.getAdjacentDataIndices=function(){for(var e={edge:[],node:[]},t=0;t<this.edges.length;t++){var n=this.edges[t];n.dataIndex<0||(e.edge.push(n.dataIndex),e.node.push(n.node1.dataIndex,n.node2.dataIndex))}return e},e.prototype.getTrajectoryDataIndices=function(){for(var e=n1(),t=n1(),n=0;n<this.edges.length;n++){var i=this.edges[n];if(!(i.dataIndex<0)){e.set(i.dataIndex,!0);for(var r=[i.node1],o=[i.node2],a=0;a<r.length;){var s=r[a];a++,t.set(s.dataIndex,!0);for(var l=0;l<s.inEdges.length;l++)e.set(s.inEdges[l].dataIndex,!0),r.push(s.inEdges[l].node1)}for(a=0;a<o.length;){var d=o[a];a++,t.set(d.dataIndex,!0);for(var l=0;l<d.outEdges.length;l++)e.set(d.outEdges[l].dataIndex,!0),o.push(d.outEdges[l].node2)}}}return{edge:e.keys(),node:t.keys()}},e}(),ko=function(){function e(e,t,n){this.dataIndex=-1,this.node1=e,this.node2=t,this.dataIndex=null==n?-1:n}return e.prototype.getModel=function(e){if(!(this.dataIndex<0))return this.hostGraph.edgeData.getItemModel(this.dataIndex).getModel(e)},e.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},e.prototype.getTrajectoryDataIndices=function(){var e=n1(),t=n1();e.set(this.dataIndex,!0);for(var n=[this.node1],i=[this.node2],r=0;r<n.length;){var o=n[r];r++,t.set(o.dataIndex,!0);for(var a=0;a<o.inEdges.length;a++)e.set(o.inEdges[a].dataIndex,!0),n.push(o.inEdges[a].node1)}for(r=0;r<i.length;){var s=i[r];r++,t.set(s.dataIndex,!0);for(var a=0;a<s.outEdges.length;a++)e.set(s.outEdges[a].dataIndex,!0),i.push(s.outEdges[a].node2)}return{edge:e.keys(),node:t.keys()}},e}();function ka(e,t){return{getValue:function(n){var i=this[e][t];return i.getStore().get(i.getDimensionIndex(n||"value"),this.dataIndex)},setVisual:function(n,i){this.dataIndex>=0&&this[e][t].setItemVisual(this.dataIndex,n,i)},getVisual:function(n){return this[e][t].getItemVisual(this.dataIndex,n)}
422,setLayout:function(n,i){this.dataIndex>=0&&this[e][t].setItemLayout(this.dataIndex,n,i)},getLayout:function(){return this[e][t].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[e][t].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[e][t].getRawIndex(this.dataIndex)}}}function ks(e,t,n,i,r){for(var o,a=new ki(i),s=0;s<e.length;s++)a.addNode(nH(e[s].id,e[s].name,s),s);for(var l=[],d=[],u=0,s=0;s<t.length;s++){var c=t[s],h=c.source,p=c.target;a.addEdge(h,p,u)&&(d.push(c),l.push(nH(a4(c.id,null),h+" > "+p)),u++)}var f=n.get("coordinateSystem");if("cartesian2d"===f||"polar"===f)o=ya(e,n);else{var g=cI.get(f),m=g&&g.dimensions||[];0>nv(m,"value")&&m.concat(["value"]),(o=new v8(v9(e,{coordDimensions:m,encodeDefine:n.getEncode()}).dimensions,n)).initData(e)}var v=new v8(["value"],n);return v.initData(d,l),r&&r(o,v),SF({mainData:o,struct:a,structAttr:"graph",datas:{node:o,edge:v},datasAttr:{node:"data",edge:"edgeData"}}),a.update(),a}nb(kr,ka("hostGraph","data")),nb(ko,ka("hostGraph","edgeData"));var kl=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t){e.prototype.init.apply(this,arguments);var n=this;function i(){return n._categoriesData}this.legendVisualProvider=new b0(i,i),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},t.prototype.mergeOption=function(t){e.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},t.prototype.mergeDefaultAndTheme=function(t){e.prototype.mergeDefaultAndTheme.apply(this,arguments),aQ(t,"edgeLabel",["show"])},t.prototype.getInitialData=function(e,t){var n=e.edges||e.links||[],i=e.data||e.nodes||[],r=this;_S(this)&&(this.__curvenessList=[],this.__edgeMap={},__(this));var o=ks(i,n,this,!0,function(e,t){e.wrapMethod("getItemModel",function(e){var t=r._categoriesModels[e.getShallow("category")];return t&&(t.parentModel=e.parentModel,e.parentModel=t),e});var n=ua.prototype.getModel;function i(e,t){var i=n.call(this,e,t);return i.resolveParentPath=o,i}function o(e){if(e&&("label"===e[0]||"label"===e[1])){var t=e.slice();return"label"===e[0]?t[0]="edgeLabel":"label"===e[1]&&(t[1]="edgeLabel"),t}return e}t.wrapMethod("getItemModel",function(e){return e.resolveParentPath=o,e.getModel=i,e})});return nw(o.edges,function(e){!function(e,t,n,i){if(_S(n)){var r=_k(e,t,n),o=n.__edgeMap,a=o[_M(r)];o[r]&&!a?o[r].isForward=!0:a&&o[r]&&(a.isForward=!0,o[r].isForward=!1),o[r]=o[r]||[],o[r].push(i)}}(e.node1,e.node2,this,e.dataIndex)},this),o.data},t.prototype.getGraph=function(){return this.getData().graph},t.prototype.getEdgeData=function(){return this.getGraph().edgeData},t.prototype.getCategoriesData=function(){return this._categoriesData},t.prototype.formatTooltip=function(e,t,n){if("edge"===n){var i=this.getData(),r=this.getDataParams(e,n),o=i.graph.getEdgeByIndex(e),a=i.getName(o.node1.dataIndex),s=i.getName(o.node2.dataIndex),l=[];return null!=a&&l.push(a),null!=s&&l.push(s),hV("nameValue",{name:l.join(" > "),value:r.value,noValue:null==r.value})}return hX({series:this,dataIndex:e,multipleSeries:t})},t.prototype._updateCategoriesData=function(){var e=nC(this.option.categories||[],function(e){return null!=e.value?e:nf({value:0},e)}),t=new v8(["value"],this);t.initData(e),this._categoriesData=t,this._categoriesModels=t.mapArray(function(e){return t.getItemModel(e)})},t.prototype.setZoom=function(e){this.option.zoom=e},t.prototype.setCenter=function(e){this.option.center=e},t.prototype.isAnimationEnabled=function(){return e.prototype.isAnimationEnabled.call(this)&&!("force"===this.get("layout")&&this.get(["force","layoutAnimation"]))},t.type="series.graph",t.dependencies=["grid","polar","geo","singleAxis","calendar"],t.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},t}(h1),kd={type:"graphRoam",event:"graphRoam",update:"none"},ku=function(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0},kc=function(e){function t(t){var n=e.call(this,t)||this;return n.type="pointer",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new ku},t.prototype.buildPath=function(e,t){var n=Math.cos,i=Math.sin,r=t.r,o=t.width,a=t.angle,s=t.x-n(a)*o*(o>=r/3?1:2),l=t.y-i(a)*o*(o>=r/3?1:2);a=t.angle-Math.PI/2,e.moveTo(s,l),e.lineTo(t.x+n(a)*o,t.y+i(a)*o),e.lineTo(t.x+n(t.angle)*r,t.y+i(t.angle)*r),e.lineTo(t.x-n(a)*o,t.y-i(a)*o),e.lineTo(s,l)},t}(lk);function kh(e,t){var n=null==e?"":e+"";return t&&(nA(t)?n=t.replace("{value}",n):nI(t)&&(n=t(e))),n}var kp=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){this.group.removeAll();
422var i,r,o=e.get(["axisLine","lineStyle","color"]),a=(i=e.get("center"),r=Math.min(n.getWidth(),n.getHeight()),{cx:aR(i[0],n.getWidth()),cy:aR(i[1],n.getHeight()),r:aR(e.get("radius"),r/2)});this._renderMain(e,t,n,o,a),this._data=e.getData()},t.prototype.dispose=function(){},t.prototype._renderMain=function(e,t,n,i,r){var o=this.group,a=e.get("clockwise"),s=-e.get("startAngle")/180*Math.PI,l=-e.get("endAngle")/180*Math.PI,d=e.getModel("axisLine"),u=d.get("roundCap")?y4:pO,c=d.get("show"),h=d.getModel("lineStyle"),p=h.get("width"),f=[s,l];ld(f,!a),s=f[0];for(var g=(l=f[1])-s,m=s,v=[],y=0;c&&y<i.length;y++){var b=new u({shape:{startAngle:m,endAngle:l=s+g*Math.min(Math.max(i[y][0],0),1),cx:r.cx,cy:r.cy,clockwise:a,r0:r.r-p,r:r.r},silent:!0});b.setStyle({fill:i[y][1]}),b.setStyle(h.getLineStyle(["color","width"])),v.push(b),m=l}v.reverse(),nw(v,function(e){return o.add(e)});var x=function(e){var t;if(e<=0)return i[0][1];for(t=0;t<i.length;t++)if(i[t][0]>=e&&(0===t?0:i[t-1][0])<e)return i[t][1];return i[t-1][1]};this._renderTicks(e,t,n,x,r,s,l,a,p),this._renderTitleAndDetail(e,t,n,x,r),this._renderAnchor(e,r),this._renderPointer(e,t,n,x,r,s,l,a,p)},t.prototype._renderTicks=function(e,t,n,i,r,o,a,s,l){for(var d,u,c=this.group,h=r.cx,p=r.cy,f=r.r,g=+e.get("min"),m=+e.get("max"),v=e.getModel("splitLine"),y=e.getModel("axisTick"),b=e.getModel("axisLabel"),x=e.get("splitNumber"),w=y.get("splitNumber"),C=aR(v.get("length"),f),S=aR(y.get("length"),f),_=o,k=(a-o)/x,M=k/w,T=v.getModel("lineStyle").getLineStyle(),D=y.getModel("lineStyle").getLineStyle(),R=v.get("distance"),I=0;I<=x;I++){if(d=Math.cos(_),u=Math.sin(_),v.get("show")){var A=R?R+l:l,P=new pU({shape:{x1:d*(f-A)+h,y1:u*(f-A)+p,x2:d*(f-C-A)+h,y2:u*(f-C-A)+p},style:T,silent:!0});"auto"===T.stroke&&P.setStyle({stroke:i(I/x)}),c.add(P)}if(b.get("show")){var A=b.get("distance")+R,E=kh(aI(I/x*(m-g)+g),b.get("formatter")),L=i(I/x),F=d*(f-C-A)+h,O=u*(f-C-A)+p,N=b.get("rotate"),B=0;"radial"===N?(B=-_+2*Math.PI)>Math.PI/2&&(B+=Math.PI):"tangential"===N?B=-_-Math.PI/2:nE(N)&&(B=N*Math.PI/180),0===B?c.add(new lj({style:dZ(b,{text:E,x:F,y:O,verticalAlign:u<-.8?"top":u>.8?"bottom":"middle",align:d<-.4?"left":d>.4?"right":"center"},{inheritColor:L}),silent:!0})):c.add(new lj({style:dZ(b,{text:E,x:F,y:O,verticalAlign:"middle",align:"center"},{inheritColor:L}),silent:!0,originX:F,originY:O,rotation:B}))}if(y.get("show")&&I!==x){var A=y.get("distance");A=A?A+l:l;for(var z=0;z<=w;z++){var j=new pU({shape:{x1:(d=Math.cos(_))*(f-A)+h,y1:(u=Math.sin(_))*(f-A)+p,x2:d*(f-S-A)+h,y2:u*(f-S-A)+p},silent:!0,style:D});"auto"===D.stroke&&j.setStyle({stroke:i((I+z/w)/x)}),c.add(j),_+=M}_-=M}else _+=k}},t.prototype._renderPointer=function(e,t,n,i,r,o,a,s,l){var d=this.group,u=this._data,c=this._progressEls,h=[],p=e.get(["pointer","show"]),f=e.getModel("progress"),g=f.get("show"),m=e.getData(),v=m.mapDimension("value"),y=+e.get("min"),b=+e.get("max"),x=[y,b],w=[o,a];function C(t,n){var i,o=m.getItemModel(t).getModel("pointer"),a=aR(o.get("width"),r.r),s=aR(o.get("length"),r.r),l=e.get(["pointer","icon"]),d=o.get("offsetCenter"),u=aR(d[0],r.r),c=aR(d[1],r.r),h=o.get("keepAspect");return(i=l?g_(l,u-a/2,c-s,a,s,null,h):new kc({shape:{angle:-Math.PI/2,width:a,r:s,x:u,y:c}})).rotation=-(n+Math.PI/2),i.x=r.cx,i.y=r.cy,i}function S(e,t){var n=f.get("roundCap")?y4:pO,i=f.get("overlap"),a=i?f.get("width"):l/m.count(),d=i?r.r-a:r.r-(e+1)*a,u=i?r.r:r.r-e*a,c=new n({shape:{startAngle:o,endAngle:t,cx:r.cx,cy:r.cy,clockwise:s,r0:d,r:u}});return i&&(c.z2=aD(m.get(v,e),[y,b],[100,0],!0)),c}(g||p)&&(m.diff(u).add(function(t){var n=m.get(v,t);if(p){var i=C(t,o);dz(i,{rotation:-((isNaN(+n)?w[0]:aD(n,x,w,!0))+Math.PI/2)},e),d.add(i),m.setItemGraphicEl(t,i)}if(g){var r=S(t,o);dz(r,{shape:{endAngle:aD(n,x,w,f.get("clip"))}},e),d.add(r),l0(e.seriesIndex,m.dataType,t,r),h[t]=r}}).update(function(t,n){var i=m.get(v,t);if(p){var r=u.getItemGraphicEl(n),a=r?r.rotation:o,s=C(t,a);s.rotation=a,dB(s,{rotation:-((isNaN(+i)?w[0]:aD(i,x,w,!0))+Math.PI/2)},e),d.add(s),m.setItemGraphicEl(t,s)}if(g){var l=c[n],y=S(t,l?l.shape.endAngle:o);dB(y,{shape:{endAngle:aD(i,x,w,f.get("clip"))}},e),d.add(y),l0(e.seriesIndex,m.dataType,t,y),h[t]=y}}).execute(),m.each(function(e){var t=m.getItemModel(e),n=t.getModel("emphasis"),r=n.get("focus"),o=n.get("blurScope"),a=n.get("disabled");if(p){var s=m.getItemGraphicEl(e),l=m.getItemVisual(e,"style"),d=l.fill;if(s instanceof lI){var u=s.style;s.useStyle(nf({image:u.image,x:u.x,y:u.y,width:u.width,height:u.height},l))}
422else s.useStyle(l),"pointer"!==s.type&&s.setColor(d);s.setStyle(t.getModel(["pointer","itemStyle"]).getItemStyle()),"auto"===s.style.fill&&s.setStyle("fill",i(aD(m.get(v,e),x,[0,1],!0))),s.z2EmphasisLift=0,dI(s,t),dM(s,r,o,a)}if(g){var c=h[e];c.useStyle(m.getItemVisual(e,"style")),c.setStyle(t.getModel(["progress","itemStyle"]).getItemStyle()),c.z2EmphasisLift=0,dI(c,t),dM(c,r,o,a)}}),this._progressEls=h)},t.prototype._renderAnchor=function(e,t){var n=e.getModel("anchor");if(n.get("show")){var i=n.get("size"),r=n.get("icon"),o=n.get("offsetCenter"),a=n.get("keepAspect"),s=g_(r,t.cx-i/2+aR(o[0],t.r),t.cy-i/2+aR(o[1],t.r),i,i,null,a);s.z2=+!!n.get("showAbove"),s.setStyle(n.getModel("itemStyle").getItemStyle()),this.group.add(s)}},t.prototype._renderTitleAndDetail=function(e,t,n,i,r){var o=this,a=e.getData(),s=a.mapDimension("value"),l=+e.get("min"),d=+e.get("max"),u=new av,c=[],h=[],p=e.isAnimationEnabled(),f=e.get(["pointer","showAbove"]);a.diff(this._data).add(function(e){c[e]=new lj({silent:!0}),h[e]=new lj({silent:!0})}).update(function(e,t){c[e]=o._titleEls[t],h[e]=o._detailEls[t]}).execute(),a.each(function(t){var n=a.getItemModel(t),o=a.get(s,t),g=new av,m=i(aD(o,[l,d],[0,1],!0)),v=n.getModel("title");if(v.get("show")){var y=v.get("offsetCenter"),b=r.cx+aR(y[0],r.r),x=r.cy+aR(y[1],r.r),w=c[t];w.attr({z2:2*!f,style:dZ(v,{x:b,y:x,text:a.getName(t),align:"center",verticalAlign:"middle"},{inheritColor:m})}),g.add(w)}var C=n.getModel("detail");if(C.get("show")){var S=C.get("offsetCenter"),_=r.cx+aR(S[0],r.r),k=r.cy+aR(S[1],r.r),M=aR(C.get("width"),r.r),T=aR(C.get("height"),r.r),D=e.get(["progress","show"])?a.getItemVisual(t,"style").fill:m,w=h[t],R=C.get("formatter");w.attr({z2:2*!f,style:dZ(C,{x:_,y:k,text:kh(o,R),width:isNaN(M)?null:M,height:isNaN(T)?null:T,align:"center",verticalAlign:"middle"},{inheritColor:D})}),d5(w,{normal:C},o,function(e){return kh(e,R)}),p&&d4(w,t,a,e,{getFormattedLabel:function(e,t,n,i,r,a){return kh(a?a.interpolatedValue:o,R)}}),g.add(w)}u.add(g)}),this.group.add(u),this._titleEls=c,this._detailEls=h},t.type="gauge",t}(fI),kf=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.visualStyleAccessPath="itemStyle",n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){return bQ(this,["value"])},t.type="series.gauge",t.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},t}(h1),kg=["itemStyle","opacity"],km=function(e){function t(t,n){var i=e.call(this)||this,r=new pG,o=new lj;return i.setTextContent(o),i.setTextGuideLine(r),i.updateData(t,n,!0),i}return(0,tQ.__extends)(t,e),t.prototype.updateData=function(e,t,n){var i=e.hostModel,r=e.getItemModel(t),o=e.getItemLayout(t),a=r.getModel("emphasis"),s=r.get(kg);s=null==s?1:s,n||dW(this),this.useStyle(e.getItemVisual(t,"style")),this.style.lineJoin="round",n?(this.setShape({points:o.points}),this.style.opacity=0,dz(this,{style:{opacity:s}},i,t)):dB(this,{style:{opacity:s},shape:{points:o.points}},i,t),dI(this,r),this._updateLabel(e,t),dM(this,a.get("focus"),a.get("blurScope"),a.get("disabled"))},t.prototype._updateLabel=function(e,t){var n=this.getTextGuideLine(),i=this.getTextContent(),r=e.hostModel,o=e.getItemModel(t),a=e.getItemLayout(t).label,s=e.getItemVisual(t,"style"),l=s.fill;dK(i,dY(o),{labelFetcher:e.hostModel,labelDataIndex:t,defaultOpacity:s.opacity,defaultText:e.getName(t)},{normal:{align:a.textAlign,verticalAlign:a.verticalAlign}}),this.setTextConfig({local:!0,inside:!!a.inside,insideStroke:l,outsideFill:l});var d=a.linePoints;n.setShape({points:d}),this.textGuideLineConfig={anchor:d?new i2(d[0][0],d[0][1]):null},dB(i,{style:{x:a.x,y:a.y}},r,t),i.attr({rotation:a.rotation,originX:a.x,originY:a.y,z2:10}),bV(this,bH(o),{stroke:l})},t}(pV),kv=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.ignoreLabelLineUpdate=!0,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=e.getData(),r=this._data,o=this.group;i.diff(r).add(function(e){var t=new km(i,e);i.setItemGraphicEl(e,t),o.add(t)}).update(function(e,t){var n=r.getItemGraphicEl(t);n.updateData(i,e),o.add(n),i.setItemGraphicEl(e,n)}).remove(function(t){dG(r.getItemGraphicEl(t),e,t)}).execute(),this._data=i},t.prototype.remove=function(){this.group.removeAll(),this._data=null},t.prototype.dispose=function(){},t.type="funnel",t}(fI),ky=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t){e.prototype.init.a
422pply(this,arguments),this.legendVisualProvider=new b0(nT(this.getData,this),nT(this.getRawData,this)),this._defaultLabelLine(t)},t.prototype.getInitialData=function(e,t){return bQ(this,{coordDimensions:["value"],encodeDefaulter:nD(cu,this)})},t.prototype._defaultLabelLine=function(e){aQ(e,"labelLine",["show"]);var t=e.labelLine,n=e.emphasis.labelLine;t.show=t.show&&e.label.show,n.show=n.show&&e.emphasis.label.show},t.prototype.getDataParams=function(t){var n=this.getData(),i=e.prototype.getDataParams.call(this,t),r=n.mapDimension("value"),o=n.getSum(r);return i.percent=o?+(n.get(r,t)/o*100).toFixed(2):0,i.$vars.push("percent"),i},t.type="series.funnel",t.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},t}(h1);function kb(e,t){e.eachSeriesByType("funnel",function(e){var n,i=e.getData(),r=i.mapDimension("value"),o=e.get("sort"),a=uX(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),s=e.get("orient"),l=a.width,d=a.height,u=function(e,t){for(var n=e.mapDimension("value"),i=e.mapArray(n,function(e){return e}),r=[],o="ascending"===t,a=0,s=e.count();a<s;a++)r[a]=a;return nI(t)?r.sort(t):"none"!==t&&r.sort(function(e,t){return o?i[e]-i[t]:i[t]-i[e]}),r}(i,o),c=a.x,h=a.y,p="horizontal"===s?[aR(e.get("minSize"),d),aR(e.get("maxSize"),d)]:[aR(e.get("minSize"),l),aR(e.get("maxSize"),l)],f=i.getDataExtent(r),g=e.get("min"),m=e.get("max");null==g&&(g=Math.min(f[0],0)),null==m&&(m=f[1]);var v=e.get("funnelAlign"),y=e.get("gap"),b=(("horizontal"===s?l:d)-y*(i.count()-1))/i.count(),x=function(e,t){if("horizontal"===s){var n,o=aD(i.get(r,e)||0,[g,m],p,!0),a=void 0;switch(v){case"top":a=h;break;case"center":a=h+(d-o)/2;break;case"bottom":a=h+(d-o)}return[[t,a],[t,a+o]]}var u=aD(i.get(r,e)||0,[g,m],p,!0);switch(v){case"left":n=c;break;case"center":n=c+(l-u)/2;break;case"right":n=c+l-u}return[[n,t],[n+u,t]]};"ascending"===o&&(b=-b,y=-y,"horizontal"===s?c+=l:h+=d,u=u.reverse());for(var w=0;w<u.length;w++){var C=u[w],S=u[w+1],_=i.getItemModel(C);if("horizontal"===s){var k=_.get(["itemStyle","width"]);null==k?k=b:(k=aR(k,l),"ascending"===o&&(k=-k));var M=x(C,c),T=x(S,c+k);c+=k+y,i.setItemLayout(C,{points:M.concat(T.slice().reverse())})}else{var D=_.get(["itemStyle","height"]);null==D?D=b:(D=aR(D,d),"ascending"===o&&(D=-D));var M=x(C,h),T=x(S,h+D);h+=D+y,i.setItemLayout(C,{points:M.concat(T.slice().reverse())})}}n=i.hostModel.get("orient"),i.each(function(e){var t,r,o,a,s=i.getItemModel(e),l=s.getModel("label").get("position"),d=s.getModel("labelLine"),u=i.getItemLayout(e),c=u.points,h="inner"===l||"inside"===l||"center"===l||"insideLeft"===l||"insideRight"===l;if(h)"insideLeft"===l?(r=(c[0][0]+c[3][0])/2+5,o=(c[0][1]+c[3][1])/2,t="left"):"insideRight"===l?(r=(c[1][0]+c[2][0])/2-5,o=(c[1][1]+c[2][1])/2,t="right"):(r=(c[0][0]+c[1][0]+c[2][0]+c[3][0])/4,o=(c[0][1]+c[1][1]+c[2][1]+c[3][1])/4,t="center"),a=[[r,o],[r,o]];else{var p=void 0,f=void 0,g=void 0,m=void 0,v=d.get("length");"left"===l?(p=(c[3][0]+c[0][0])/2,f=(c[3][1]+c[0][1])/2,r=(g=p-v)-5,t="right"):"right"===l?(p=(c[1][0]+c[2][0])/2,f=(c[1][1]+c[2][1])/2,r=(g=p+v)+5,t="left"):"top"===l?(p=(c[3][0]+c[0][0])/2,o=(m=(f=(c[3][1]+c[0][1])/2)-v)-5,t="center"):"bottom"===l?(p=(c[1][0]+c[2][0])/2,o=(m=(f=(c[1][1]+c[2][1])/2)+v)+5,t="center"):"rightTop"===l?(p="horizontal"===n?c[3][0]:c[1][0],f="horizontal"===n?c[3][1]:c[1][1],"horizontal"===n?(o=(m=f-v)-5,t="center"):(r=(g=p+v)+5,t="top")):"rightBottom"===l?(p=c[2][0],f=c[2][1],"horizontal"===n?(o=(m=f+v)+5,t="center"):(r=(g=p+v)+5,t="bottom")):"leftTop"===l?(p=c[0][0],f="horizontal"===n?c[0][1]:c[1][1],"horizontal"===n?(o=(m=f-v)-5,t="center"):(r=(g=p-v)-5,t="right")):"leftBottom"===l?(p="horizontal"===n?c[1][0]:c[3][0],f="horizontal"===n?c[1][1]:c[2][1],"horizontal"===n?(o=(m=f+v)+5,t="center"):(r=(g=p-v)-5,t="right")):(p=(c[1][0]+c[2][0])/2,f=(c[1][1]+c[2][1])/2,"horizontal"===n?(o=(m=f+v)+5,t="center"):(r=(g=p+v)+5,t="left")),"horizontal"===n?r=g=p:o=m=f,a=[[p,f],[g,m]]}u.label={linePoints:a,x:r,y:o,verticalAlign:"middle",textAlign:t,inside:h}})})}var kx=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._dataGroup=new av,n._initialized=!1,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(){this.group.add(this._dataGroup)},t.prototype.render=function(e,t,n,i){this._progressiveEls=null;var r=this._dataGroup,o=e.getData(),a=this._data,s=e.coordinateSystem,l=s.dimensions,d=kS(e);if(o.diff(a).add(function(e){k_(kC(o,r,e,l,s),o,e,d)}).update(function(t,n){var i=a.getItemGraphicEl(n),r=kw(o,t,l,s);o.setItemGraphicEl(t,i),dB(i,{shape:{points:r}},e,t),dW(i),k_(i,o,t,d)}).remove(function(e){var t=a.getItemGraphicEl(e);r.remove(t)}).execute(),!this._initialized){this._initialized=!0;var u,c,h,p,f,g,m,v=(u=s,c=e,h=function(){setTimeout(function(){r.removeClipPath()})},p=u.model,g=new lN({shape:{x:(f=u.getRect()).x,y:f.y,width:f.width,height:f.height}}),m="horizontal"===p.get("layout")?"width":"height",g.setShape(m,0),dz(g,{shape:{width:f.width,height:f.height}},c,h),g);r.setClipPath(v)}this._data=o},t.prototype.incrementalPrepareRender=function(e,t,n){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},t.prototype.incrementalRender=function(e,t,n){for(var i=t.getData(),r=t.coordinateSystem,o=r.dimensions,a=kS(t),s=this._progressiveEls=[],l=e.start;l<e.end;l++){var d=kC(i,this._dataGroup,l,o,r);d.incremental=!0,k_(d,i,l,a),s.push(d)}},t.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},t.type="parallel",t}(fI);function kw(e,t,n,i){for(var r=[],o=0;o<n.length;o++){var a,s=n[o],l=e.get(e.mapDimension(s),t);a=l,("category"===i.getAxis(s).type?null==a:null==a||isNaN(a))||r.push(i.dataToPoint(l,s))}return r}function kC(e,t,n,i,r){var o=new pG({shape:{points:kw(e,n,i,r)},z2:10});return t.add(o),e.setItemGraphicEl(n,o),o}function kS(e){var t,n=e.get("smooth",!0);return!0===n&&(n=.3),(t=n=aU(n))!=t&&(n=0),{smooth:n}}function k_(e,t,n,i){e.useStyle(t.getItemVisual(n,"style")),e.style.fill=null,e.setShape("smooth",i.smooth);var r=t.getItemModel(n),o=r.getModel("emphasis");dI(e,r,"lineStyle"),dM(e,o.get("focus"),o.get("blurScope"),o.get("disabled"))}var kk=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.visualStyleAccessPath="lineStyle",n.visualDrawType="stroke",n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){return ya(null,this,{useEncodeDefaulter:nT(kM,null,this)})},t.prototype.getRawIndicesByActiveState=function(e){var t=this.coordinateSystem,n=this.getData(),i=[];return t.eachActiveState(n,function(t,r){e===t&&i.push(n.getRawIndex(r))}),i},t.type="series.parallel",t.dependencies=["parallel"],t.defaultOption={z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:500,smooth:!1,animationEasing:"linear"},t}(h1);function kM(e){var t=e.ecModel.getComponent("parallel",e.get("parallelIndex"));if(t){var n={};return nw(t.dimensions,function(e){var t=+e.replace("dim","");n[e]=t}),n}}var kT=["lineStyle","opacity"];let kD={seriesType:"parallel",reset:function(e,t){var n=e.coordinateSystem,i={normal:e.get(["lineStyle","opacity"]),active:e.get("activeOpacity"),inactive:e.get("inactiveOpacity")};return{progress:function(e,t){n.eachActiveState(t,function(e,n){var r=i[e];if("normal"===e&&t.hasItemOption){var o=t.getItemModel(n).get(kT,!0);null!=o&&(r=o)}t.ensureUniqueItemVisual(n,"style").opacity=r},e.start,e.end)}}}};function kR(e){var t;(function(e){if(!e.parallel){var t=!1;nw(e.series,function(e){e&&"parallel"===e.type&&(t=!0)}),t&&(e.parallel=[{}])}})(e),nw(aJ((t=e).parallelAxis),function(e){if(nL(e)){var n=e.parallelIndex||0,i=aJ(t.parallel)[n];i&&i.parallelAxisDefault&&nh(e,i.parallelAxisDefault,!1)}})}var kI=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){this._model=e,this._api=n,this._handlers||(this._handlers={},nw(kA,function(e,t){n.getZr().on(t,this._handlers[t]=nT(e,this))},this)),fj(this,"_throttledDispatchExpand",e.get("axisExpandRate"),"fixRate")},t.prototype.dispose=function(e,t){fV(this,"_throttledDispatchExpand"),nw(this._handlers,function(e,n){t.getZr().off(n,e)}),this._handlers=null},t.prototype._throttledDispatchExpand=function(e){this._dispatchExpand(e)},t.prototype._dispatchExpand=function(e){e&&this._api.dispatchAction(nf({type:"parallelAxisExpand"},e))},t.type="parallel",t}(h9),kA={mousedown:function(e){kP(this,"click")&&(this._mouseDownPoint=[e.offsetX,e.offsetY])},mouseup:function(e){var t=this._mouseDownPoint;if(kP(this,"click")&&t){var n=[e.offsetX,e.offsetY];if(Math.pow(t[0]-n[0],2)+Math.pow(t[1]-n[1],2)>5)return;var i=this._model.coordinateSystem.getSlidedAxisExpandWindow([e.offsetX,e.offsetY]);"none"!==i.behavior&&this._dispatchExpand({axisExpandWindow:i.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(e){if(!this._mouseDownPoint&&kP(this,"mousemove")){var t=this._model,n=t.coordinateSystem.getSlidedAxisExpandWindow([e.offsetX,e.offsetY]),i=n.behavior;"jump"===i&&this._throttledDispatchExpand.debounceNextCall(t.get("axisExpandDebounce")),this._throttledDispatchExpand("none"===i?null:{axisExpandWindow:n.axisExpandWindow,animation:"jump"===i?null:{duration:0}})}}};function kP(e,t){var n=e._model;return n.get("axisExpandable")&&n.get("axisExpandTriggerOn")===t}var kE=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(){e.prototype.init.a
422pply(this,arguments),this.mergeOption({})},t.prototype.mergeOption=function(e){var t=this.option;e&&nh(t,e,!0),this._initDimensions()},t.prototype.contains=function(e,t){var n=e.get("parallelIndex");return null!=n&&t.getComponent("parallel",n)===this},t.prototype.setAxisExpand=function(e){nw(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(t){e.hasOwnProperty(t)&&(this.option[t]=e[t])},this)},t.prototype._initDimensions=function(){var e=this.dimensions=[],t=this.parallelAxisIndex=[];nw(n_(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(e){return(e.get("parallelIndex")||0)===this.componentIndex},this),function(n){e.push("dim"+n.get("dim")),t.push(n.componentIndex)})},t.type="parallel",t.dependencies=["parallelAxis"],t.layoutMode="box",t.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},t}(u5),kL=function(e){function t(t,n,i,r,o){var a=e.call(this,t,n,i)||this;return a.type=r||"value",a.axisIndex=o,a}return(0,tQ.__extends)(t,e),t.prototype.isHorizontal=function(){return"horizontal"!==this.coordinateSystem.getModel().get("layout")},t}(x6);function kF(e,t,n,i,r,o){e=e||0;var a,s=n[1]-n[0];if(null!=r&&(r=kN(r,[0,s])),null!=o&&(o=Math.max(o,null!=r?r:0)),"all"===i){var l=Math.abs(t[1]-t[0]);l=kN(l,[0,s]),r=o=kN(l,[r,o]),i=0}t[0]=kN(t[0],n),t[1]=kN(t[1],n);var d=kO(t,i);t[i]+=e;var u=r||0,c=n.slice();return d.sign<0?c[0]+=u:c[1]-=u,t[i]=kN(t[i],c),a=kO(t,i),null!=r&&(a.sign!==d.sign||a.span<r)&&(t[1-i]=t[i]+d.sign*r),a=kO(t,i),null!=o&&a.span>o&&(t[1-i]=t[i]+a.sign*o),t}function kO(e,t){var n=e[t]-e[1-t];return{span:Math.abs(n),sign:n>0?-1:n<0?1:t?-1:1}}function kN(e,t){return Math.min(null!=t[1]?t[1]:1/0,Math.max(null!=t[0]?t[0]:-1/0,e))}var kB=Math.min,kz=Math.max,kj=Math.floor,kV=Math.ceil,kH=Math.PI,kG=function(){function e(e,t,n){this.type="parallel",this._axesMap=n1(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,n)}return e.prototype._init=function(e,t,n){var i=e.dimensions,r=e.parallelAxisIndex;nw(i,function(e,n){var i=r[n],o=t.getComponent("parallelAxis",i),a=this._axesMap.set(e,new kL(e,xV(o),[0,0],o.get("type"),i)),s="category"===a.type;a.onBand=s&&o.get("boundaryGap"),a.inverse=o.get("inverse"),o.axis=a,a.model=o,a.coordinateSystem=o.coordinateSystem=this},this)},e.prototype.update=function(e,t){this._updateAxesFromSeries(this._model,e)},e.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),n=t.axisBase,i=t.layoutBase,r=t.pixelDimIndex,o=e[1-r],a=e[r];return o>=n&&o<=n+t.axisLength&&a>=i&&a<=i+t.layoutLength},e.prototype.getModel=function(){return this._model},e.prototype._updateAxesFromSeries=function(e,t){t.eachSeries(function(n){if(e.contains(n,t)){var i=n.getData();nw(this.dimensions,function(e){var t=this._axesMap.get(e);t.scale.unionExtentFromData(i,i.mapDimension(e)),xj(t.scale,t.model)},this)}},this)},e.prototype.resize=function(e,t){this._rect=uX(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),this._layoutAxes()},e.prototype.getRect=function(){return this._rect},e.prototype._makeLayoutInfo=function(){var e,t=this._model,n=this._rect,i=["x","y"],r=["width","height"],o=t.get("layout"),a=+("horizontal"!==o),s=n[r[a]],l=[0,s],d=this.dimensions.length,u=kW(t.get("axisExpandWidth"),l),c=kW(t.get("axisExpandCount")||0,[0,d]),h=t.get("axisExpandable")&&d>3&&d>c&&c>1&&u>0&&s>0,p=t.get("axisExpandWindow");p?(e=kW(p[1]-p[0],l),p[1]=p[0]+e):(e=kW(u*(c-1),l),(p=[u*(t.get("axisExpandCenter")||kj(d/2))-e/2])[1]=p[0]+e);var f=(s-e)/(d-c);f<3&&(f=0);var g=[kj(aI(p[0]/u,1))+1,kV(aI(p[1]/u,1))-1],m=f/u*p[0];return{layout:o,pixelDimIndex:a,layoutBase:n[i[a]],layoutLength:s,axisBase:n[i[1-a]],axisLength:n[r[1-a]],axisExpandable:h,axisExpandWidth:u,axisCollapseWidth:f,axisExpandWindow:p,axisCount:d,winInnerIndices:g,axisExpandWindow0Pos:m}},e.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,n=this.dimensions,i=this._makeLayoutInfo(),r=i.layout;t.each(function(e){var t=[0,i.axisLength],n=+!!e.inverse;e.setExtent(t[n],t[1-n])}),nw(n,function(t,n){var o=(i.axisExpandable?function(e,t){var n,i,r=t.layoutLength,o=t.axisExpandWidth,a=t.axisCount,s=t.axisCollapseWidth,l=t.winInnerIndices,d=s,u=!1;return e<l[0]?(n=e*s,i=s):e<=l[1]?(n=t.axisExpandWindow0Pos+e*o-t.axisExpandWindow[0],d=o,u=!0):(n=r-(a-1-e)*s,i=s),{position:n,axisNameAvailableWidth:d,axisLabelShow:u,nameTruncateMaxWidth:i}}:function(e,t){var n=t.layoutLength/(t.axisCount-1);return{position:n*e,axisNameAvailableWidth:n,axisLabelShow:!0}})(n,i),a={horizontal:{x:o.position,y:i.axisLength},vertical:{x:0,y:o.position}}
422,s=[a[r].x+e.x,a[r].y+e.y],l={horizontal:kH/2,vertical:0}[r],d=iq();iJ(d,d,l),iX(d,d,s),this._axesLayout[t]={position:s,rotation:l,transform:d,axisNameAvailableWidth:o.axisNameAvailableWidth,axisLabelShow:o.axisLabelShow,nameTruncateMaxWidth:o.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},e.prototype.getAxis=function(e){return this._axesMap.get(e)},e.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},e.prototype.eachActiveState=function(e,t,n,i){null==n&&(n=0),null==i&&(i=e.count());var r=this._axesMap,o=this.dimensions,a=[],s=[];nw(o,function(t){a.push(e.mapDimension(t)),s.push(r.get(t).model)});for(var l=this.hasAxisBrushed(),d=n;d<i;d++){var u=void 0;if(l){u="active";for(var c=e.getValues(a,d),h=0,p=o.length;h<p;h++)if("inactive"===s[h].getActiveState(c[h])){u="inactive";break}}else u="normal";t(u,d)}},e.prototype.hasAxisBrushed=function(){for(var e=this.dimensions,t=this._axesMap,n=!1,i=0,r=e.length;i<r;i++)"normal"!==t.get(e[i]).model.getActiveState()&&(n=!0);return n},e.prototype.axisCoordToPoint=function(e,t){return fv([e,0],this._axesLayout[t].transform)},e.prototype.getAxisLayout=function(e){return nc(this._axesLayout[e])},e.prototype.getSlidedAxisExpandWindow=function(e){var t,n=this._makeLayoutInfo(),i=n.pixelDimIndex,r=n.axisExpandWindow.slice(),o=r[1]-r[0],a=[0,n.axisExpandWidth*(n.axisCount-1)];if(!this.containPoint(e))return{behavior:"none",axisExpandWindow:r};var s=e[i]-n.layoutBase-n.axisExpandWindow0Pos,l="slide",d=n.axisCollapseWidth,u=this._model.get("axisExpandSlideTriggerArea"),c=null!=u[0];if(d)c&&d&&s<o*u[0]?(l="jump",t=s-o*u[2]):c&&d&&s>o*(1-u[0])?(l="jump",t=s-o*(1-u[2])):(t=s-o*u[1])>=0&&(t=s-o*(1-u[1]))<=0&&(t=0),(t*=n.axisExpandWidth/d)?kF(t,r,a,"all"):l="none";else{var h=r[1]-r[0];(r=[kz(0,a[1]*s/h-h/2)])[1]=kB(a[1],r[0]+h),r[0]=r[1]-h}return{axisExpandWindow:r,behavior:l}},e}();function kW(e,t){return kB(kz(e,t[0]),t[1])}let k$={create:function(e,t){var n=[];return e.eachComponent("parallel",function(i,r){var o=new kG(i,e,t);o.name="parallel_"+r,o.resize(i,t),i.coordinateSystem=o,o.model=i,n.push(o)}),e.eachSeries(function(e){if("parallel"===e.get("coordinateSystem")){var t=e.getReferringComponents("parallel",si).models[0];e.coordinateSystem=t.coordinateSystem}}),n}};var kU=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.activeIntervals=[],n}return(0,tQ.__extends)(t,e),t.prototype.getAreaSelectStyle=function(){return sy([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},t.prototype.setActiveIntervals=function(e){var t=this.activeIntervals=nc(e);if(t)for(var n=t.length-1;n>=0;n--)aA(t[n])},t.prototype.getActiveState=function(e){var t=this.activeIntervals;if(!t.length)return"normal";if(null==e||isNaN(+e))return"inactive";if(1===t.length){var n=t[0];if(n[0]<=e&&e<=n[1])return"active"}else for(var i=0,r=t.length;i<r;i++)if(t[i][0]<=e&&e<=t[i][1])return"active";return"inactive"},t}(u5);nb(kU,b9);var kq=Math.min,kK=Math.max,kY=Math.pow,kZ="globalPan",kX={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},kJ={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},kQ={brushStyle:{lineWidth:2,stroke:"rgba(210,219,238,0.3)",fill:"#D2DBEE"},transformable:!0,brushMode:"single",removeOnClick:!1},k0=0,k1=function(e){function t(t){var n=e.call(this)||this;return n._track=[],n._covers=[],n._handlers={},n._zr=t,n.group=new av,n._uid="brushController_"+k0++,nw(My,function(e,t){this._handlers[t]=nT(e,this)},n),n}return(0,tQ.__extends)(t,e),t.prototype.enableBrush=function(e){return this._brushType&&this._doDisableBrush(),e.brushType&&this._doEnableBrush(e),this},t.prototype._doEnableBrush=function(e){var t,n=this._zr;this._enableGlobalPan||(t=this._uid,wY(n)[kZ]=t),nw(this._handlers,function(e,t){n.on(t,e)}),this._brushType=e.brushType,this._brushOption=nh(nc(kQ),e,!0)},t.prototype._doDisableBrush=function(){var e,t,n=this._zr;e=this._uid,(t=wY(n))[kZ]===e&&(t[kZ]=null),nw(this._handlers,function(e,t){n.off(t,e)}),this._brushType=this._brushOption=null},t.prototype.setPanels=function(e){if(e&&e.length){var t=this._panels={};nw(e,function(e){t[e.panelId]=nc(e)})}else this._panels=null;return this},t.prototype.mount=function(e){e=e||{},this._enableGlobalPan=e.enableGlobalPan;var t=this.group;return this._zr.add(t),t.attr({x:e.x||0,y:e.y||0,rotation:e.rotation||0,scaleX:e.scaleX||1,scaleY:e.scaleY||1}),this._transform=t.getLocalTransform(),this},t.prototype.updateCovers=function(e){e=nC(e,function(e){return nh(nc(kQ),e,!0)});var t=this._covers,n=this._covers=[],i=this,r=this._creatingCover;return new vU(t,e,function(e,t){return o(e.__brushOption,t)},o).add(a).update(a).remove(function(e){t[e]!==r&&i.group.remove(t[e])}).execute(),this;function o(e,t){return(null!=e.id?e.id:"\0-brush-index-"+t)+"-"+e.brushType}function a(o,a){var s=e[o];if(null!=a&&t[a]===r)n[o]=t[a];else{var l=n[o]=null!=a?(t[a].__brushOption=s,t[a]):k3(i,k2(i,s));k6(i,l)}}},t.prototype.unmount=function(){return this.enableBrush(!1),Me(this),this._zr.remove(this.group),this},t.prototype.dispose=function(){this.unmount(),this.off()},t}(iS);function k2(e,t){var n=Mx[t.brushType].createCover(e,t);return n.__brushOption=t,k4(n,t),e.group.add(n),n}function k3(e,t){var n=k8(t);return n.endCreating&&(n.endCreating(e,t),k4(t,t.__brushOption)),t}function k5(e,t){var n=t.__brushOption;k8(t).updateCoverShape(e,t,n.range,n)}function k4(e,t){var n=t.z;null==n&&(n=1e4),e.traverse(function(e){e.z=n,e.z2=n})}function k6(e,t){k8(t).updateCommon(e,t),k5(e,t)}function k8(e){return Mx[e.__brushOption.brushType]}
422function k7(e,t,n){var i,r=e._panels;if(!r)return!0;var o=e._transform;return nw(r,function(e){e.isTargetByCursor(t,n,o)&&(i=e)}),i}function k9(e,t){var n=e._panels;if(!n)return!0;var i=t.__brushOption.panelId;return null==i||n[i]}function Me(e){var t=e._covers,n=t.length;return nw(t,function(t){e.group.remove(t)},e),t.length=0,!!n}function Mt(e,t){var n=nC(e._covers,function(e){var t=e.__brushOption,n=nc(t.range);return{brushType:t.brushType,panelId:t.panelId,range:n}});e.trigger("brush",{areas:n,isEnd:!!t.isEnd,removeOnClick:!!t.removeOnClick})}function Mn(e){var t=e.length-1;return t<0&&(t=0),[e[0],e[t]]}function Mi(e,t,n,i){var r=new av;return r.add(new lN({name:"main",style:Ms(n),silent:!0,draggable:!0,cursor:"move",drift:nD(Mu,e,t,r,["n","s","w","e"]),ondragend:nD(Mt,t,{isEnd:!0})})),nw(i,function(n){r.add(new lN({name:n.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:nD(Mu,e,t,r,n),ondragend:nD(Mt,t,{isEnd:!0})}))}),r}function Mr(e,t,n,i){var r=i.brushStyle.lineWidth||0,o=kK(r,6),a=n[0][0],s=n[1][0],l=a-r/2,d=s-r/2,u=n[0][1],c=n[1][1],h=u-o+r/2,p=c-o+r/2,f=u-a,g=c-s,m=f+r,v=g+r;Ma(e,t,"main",a,s,f,g),i.transformable&&(Ma(e,t,"w",l,d,o,v),Ma(e,t,"e",h,d,o,v),Ma(e,t,"n",l,d,m,o),Ma(e,t,"s",l,p,m,o),Ma(e,t,"nw",l,d,o,o),Ma(e,t,"ne",h,d,o,o),Ma(e,t,"sw",l,p,o,o),Ma(e,t,"se",h,p,o,o))}function Mo(e,t){var n=t.__brushOption,i=n.transformable,r=t.childAt(0);r.useStyle(Ms(n)),r.attr({silent:!i,cursor:i?"move":"default"}),nw([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(n){var r,o,a,s=t.childOfName(n.join("")),l=1===n.length?Md(e,n[0]):(("e"===(a=[Md(r=e,(o=n)[0]),Md(r,o[1])])[0]||"w"===a[0])&&a.reverse(),a.join(""));s&&s.attr({silent:!i,invisible:!i,cursor:i?kJ[l]+"-resize":null})})}function Ma(e,t,n,i,r,o,a){var s,l,d,u=t.childOfName(n);u&&u.setShape((l=kq((s=Mp(e,t,[[i,r],[i+o,r+a]]))[0][0],s[1][0]),{x:l,y:d=kq(s[0][1],s[1][1]),width:kK(s[0][0],s[1][0])-l,height:kK(s[0][1],s[1][1])-d}))}function Ms(e){return ng({strokeNoScale:!0},e.brushStyle)}function Ml(e,t,n,i){var r=[kq(e,n),kq(t,i)],o=[kK(e,n),kK(t,i)];return[[r[0],o[0]],[r[1],o[1]]]}function Md(e,t){return({left:"w",right:"e",top:"n",bottom:"s"})[fy({w:"left",e:"right",n:"top",s:"bottom"}[t],fm(e.group))]}function Mu(e,t,n,i,r,o){var a=n.__brushOption,s=e.toRectRange(a.range),l=Mh(t,r,o);nw(i,function(e){var t=kX[e];s[t[0]][t[1]]+=l[t[0]]}),a.range=e.fromRectRange(Ml(s[0][0],s[1][0],s[0][1],s[1][1])),k6(t,n),Mt(t,{isEnd:!1})}function Mc(e,t,n,i){var r=t.__brushOption.range,o=Mh(e,n,i);nw(r,function(e){e[0]+=o[0],e[1]+=o[1]}),k6(e,t),Mt(e,{isEnd:!1})}function Mh(e,t,n){var i=e.group,r=i.transformCoordToLocal(t,n),o=i.transformCoordToLocal(0,0);return[r[0]-o[0],r[1]-o[1]]}function Mp(e,t,n){var i=k9(e,t);return i&&!0!==i?i.clipPath(n,e._transform):nc(n)}function Mf(e){var t=e.event;t.preventDefault&&t.preventDefault()}function Mg(e,t,n){return e.childOfName("main").contain(t,n)}function Mm(e,t,n,i){var r,o=e._creatingCover,a=e._creatingPanel,s=e._brushOption;if(e._track.push(n.slice()),function(e){var t=e._track;if(!t.length)return!1;var n=t[t.length-1],i=t[0],r=n[0]-i[0],o=n[1]-i[1];return kY(r*r+o*o,.5)>6}(e)||o){if(a&&!o){"single"===s.brushMode&&Me(e);var l=nc(s);l.brushType=Mv(l.brushType,a),l.panelId=!0===a?null:a.panelId,o=e._creatingCover=k2(e,l),e._covers.push(o)}if(o){var d=Mx[Mv(e._brushType,a)];o.__brushOption.range=d.getCreatingRange(Mp(e,o,e._track)),i&&(k3(e,o),d.updateCommon(e,o)),k5(e,o),r={isEnd:i}}}else i&&"single"===s.brushMode&&s.removeOnClick&&k7(e,t,n)&&Me(e)&&(r={isEnd:i,removeOnClick:!0});return r}function Mv(e,t){return"auto"===e?t.defaultBrushType:e}var My={mousedown:function(e){if(this._dragging)Mb(this,e);else if(!e.target||!e.target.draggable){Mf(e);var t=this.group.transformCoordToLocal(e.offsetX,e.offsetY);this._creatingCover=null,(this._creatingPanel=k7(this,e,t))&&(this._dragging=!0,this._track=[t.slice()])}},mousemove:function(e){var t=e.offsetX,n=e.offsetY,i=this.group.transformCoordToLocal(t,n);if(!function(e,t,n){if(!(!e._brushType||(i=e,r=t.offsetX,o=t.offsetY,a=i._zr,r<0||r>a.getWidth()||o<0||o>a.getHeight()))){var i,r,o,a,s=e._zr,l=e._covers,d=k7(e,t,n);if(!e._dragging)for(var u=0;u<l.length;u++){var c=l[u].__brushOption;if(d&&(!0===d||c.panelId===d.panelId)&&Mx[c.brushType].contain(l[u],n[0],n[1]))return}d&&s.setCursorStyle("crosshair")}}(this,e,i),this._dragging){Mf(e);var r=Mm(this,e,i,!1);r&&Mt(this,r)}},mouseup:function(e){Mb(this,e)}};function Mb(e,t){if(e._dragging){Mf(t);var n=t.offsetX,i=t.offsetY,r=e.group.transformCoordToLocal(n,i),o=Mm(e,t,r,!0);e._dragging=!1,e._track=[],e._creatingCover=null,o&&Mt(e,o)}}var Mx={lineX:Mw(0),lineY:Mw(1),rect:{createCover:function(e,t){function n(e){return e}return Mi({toRectRange:n,fromRectRange:n},e,t,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(e){var t=Mn(e);return Ml(t[1][0],t[1][1],t[0][0],t[0][1])},updateCoverShape:function(e,t,n,i){Mr(e,t,n,i)},updateCommon:Mo,contain:Mg},polygon:{createCover:function(e,t){var n=new av;return n.add(new pG({name:"main",style:Ms(t),silent:!0})),n},getCreatingRange:function(e){return e},endCreating:function(e,t){t.remove(t.childAt(0)),t.add(new pV({name:"main",draggable:!0,drift:nD(Mc,e,t),ondragend:nD(Mt,e,{isEnd:!0})}))},updateCoverShape:function(e,t,n,i){t.childAt(0).setShape({points:Mp(e,t,n
422)})},updateCommon:Mo,contain:Mg}};function Mw(e){return{createCover:function(t,n){return Mi({toRectRange:function(t){var n=[t,[0,100]];return e&&n.reverse(),n},fromRectRange:function(t){return t[e]}},t,n,[[["w"],["e"]],[["n"],["s"]]][e])},getCreatingRange:function(t){var n=Mn(t);return[kq(n[0][e],n[1][e]),kK(n[0][e],n[1][e])]},updateCoverShape:function(t,n,i,r){var o,a=k9(t,n);if(!0!==a&&a.getLinearBrushOtherExtent)o=a.getLinearBrushOtherExtent(e);else{var s=t._zr;o=[0,[s.getWidth(),s.getHeight()][1-e]]}var l=[i,o];e&&l.reverse(),Mr(t,n,l,r)},updateCommon:Mo,contain:Mg}}function MC(e){return e=Mk(e),function(t){return fx(t,e)}}function MS(e,t){return e=Mk(e),function(n){var i=null!=t?t:n,r=i?e.width:e.height,o=i?e.x:e.y;return[o,o+(r||0)]}}function M_(e,t,n){var i=Mk(e);return function(e,r){return i.contain(r[0],r[1])&&!w3(e,t,n)}}function Mk(e){return rt.create(e)}var MM=["axisLine","axisTickLabel","axisName"],MT=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t,n){e.prototype.init.apply(this,arguments),(this._brushController=new k1(n.getZr())).on("brush",nT(this._onBrush,this))},t.prototype.render=function(e,t,n,i){var r,o,a;if(r=e,o=t,!(a=i)||"axisAreaSelect"!==a.type||o.findComponents({mainType:"parallelAxis",query:a})[0]!==r){this.axisModel=e,this.api=n,this.group.removeAll();var s=this._axisGroup;if(this._axisGroup=new av,this.group.add(this._axisGroup),e.get("show")){var l,d=(l=e,t.getComponent("parallel",l.get("parallelIndex"))),u=d.coordinateSystem,c=e.getAreaSelectStyle(),h=c.width,p=e.axis.dim,f=nf({strokeContainThreshold:h},u.getAxisLayout(p)),g=new wd(e,f);nw(MM,g.add,g),this._axisGroup.add(g.getGroup()),this._refreshBrushController(f,c,e,d,h,n),fb(s,this._axisGroup,e)}}},t.prototype._refreshBrushController=function(e,t,n,i,r,o){var a,s,l=n.axis.getExtent(),d=l[1]-l[0],u=Math.min(30,.1*Math.abs(d)),c=rt.create({x:l[0],y:-r/2,width:d,height:r});c.x-=u,c.width+=2*u,this._brushController.mount({enableGlobalPan:!0,rotation:e.rotation,x:e.position[0],y:e.position[1]}).setPanels([{panelId:"pl",clipPath:MC(c),isTargetByCursor:M_(c,o,i),getLinearBrushOtherExtent:MS(c,0)}]).enableBrush({brushType:"lineX",brushStyle:t,removeOnClick:!0}).updateCovers((s=(a=n).axis,nC(a.activeIntervals,function(e){return{brushType:"lineX",panelId:"pl",range:[s.dataToCoord(e[0],!0),s.dataToCoord(e[1],!0)]}})))},t.prototype._onBrush=function(e){var t=e.areas,n=this.axisModel,i=n.axis,r=nC(t,function(e){return[i.coordToData(e.range[0],!0),i.coordToData(e.range[1],!0)]});(!n.option.realtime===e.isEnd||e.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:n.id,intervals:r})},t.prototype.dispose=function(){this._brushController.dispose()},t.type="parallelAxis",t}(h9),MD={type:"axisAreaSelect",event:"axisAreaSelected"},MR={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function MI(e){e.registerComponentView(kI),e.registerComponentModel(kE),e.registerCoordinateSystem("parallel",k$),e.registerPreprocessor(kR),e.registerComponentModel(kU),e.registerComponentView(MT),xc(e,"parallel",kU,MR),e.registerAction(MD,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(t){t.axis.model.setActiveIntervals(e.intervals)})}),e.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(t){t.setAxisExpand(e)})})}var MA=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0},MP=function(e){function t(t){return e.call(this,t)||this}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new MA},t.prototype.buildPath=function(e,t){var n=t.extent;e.moveTo(t.x1,t.y1),e.bezierCurveTo(t.cpx1,t.cpy1,t.cpx2,t.cpy2,t.x2,t.y2),"vertical"===t.orient?(e.lineTo(t.x2+n,t.y2),e.bezierCurveTo(t.cpx2+n,t.cpy2,t.cpx1+n,t.cpy1,t.x1+n,t.y1)):(e.lineTo(t.x2,t.y2+n),e.bezierCurveTo(t.cpx2,t.cpy2+n,t.cpx1,t.cpy1+n,t.x1,t.y1+n)),e.closePath()},t.prototype.highlight=function(){dv(this)},t.prototype.downplay=function(){dy(this)},t}(lk),ME=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._focusAdjacencyDisabled=!1,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i,r,o,a,s=this,l=e.getGraph(),d=this.group,u=e.layoutInfo,c=u.width,h=u.height,p=e.getData(),f=e.getData("edge"),g=e.get("orient");this._model=e,d.removeAll(),d.x=u.x,d.y=u.y,l.eachEdge(function(t){var n,i,r,o,a,s,l,u,p=new MP,m=lQ(p);m.dataIndex=t.dataIndex,m.seriesIndex=e.seriesIndex,m.dataType="edge";var v=t.getModel(),y=v.getModel("lineStyle"),b=y.get("curveness"),x=t.node1.getLayout(),w=t.node1.getModel(),C=w.get("localX"),S=w.get("localY"),_=t.
422node2.getLayout(),k=t.node2.getModel(),M=k.get("localX"),T=k.get("localY"),D=t.getLayout();p.shape.extent=Math.max(1,D.dy),p.shape.orient=g,"vertical"===g?(n=(null!=C?C*c:x.x)+D.sy,i=(null!=S?S*h:x.y)+x.dy,r=(null!=M?M*c:_.x)+D.ty,o=null!=T?T*h:_.y,a=n,s=i*(1-b)+o*b,l=r,u=i*b+o*(1-b)):(n=(null!=C?C*c:x.x)+x.dx,i=(null!=S?S*h:x.y)+D.sy,r=null!=M?M*c:_.x,o=(null!=T?T*h:_.y)+D.ty,a=n*(1-b)+r*b,s=i,l=n*b+r*(1-b),u=o),p.setShape({x1:n,y1:i,x2:r,y2:o,cpx1:a,cpy1:s,cpx2:l,cpy2:u}),p.useStyle(y.getItemStyle()),ML(p.style,g,t);var R=""+v.get("value"),I=dY(v,"edgeLabel");dK(p,I,{labelFetcher:{getFormattedLabel:function(t,n,i,r,o,a){return e.getFormattedLabel(t,n,"edge",r,nW(o,I.normal&&I.normal.get("formatter"),R),a)}},labelDataIndex:t.dataIndex,defaultText:R}),p.setTextConfig({position:"inside"});var A=v.getModel("emphasis");dI(p,v,"lineStyle",function(e){var n=e.getItemStyle();return ML(n,g,t),n}),d.add(p),f.setItemGraphicEl(t.dataIndex,p);var P=A.get("focus");dM(p,"adjacency"===P?t.getAdjacentDataIndices():"trajectory"===P?t.getTrajectoryDataIndices():P,A.get("blurScope"),A.get("disabled"))}),l.eachNode(function(t){var n=t.getLayout(),i=t.getModel(),r=i.get("localX"),o=i.get("localY"),a=i.getModel("emphasis"),s=i.get(["itemStyle","borderRadius"])||0,l=new lN({shape:{x:null!=r?r*c:n.x,y:null!=o?o*h:n.y,width:n.dx,height:n.dy,r:s},style:i.getModel("itemStyle").getItemStyle(),z2:10});dK(l,dY(i),{labelFetcher:{getFormattedLabel:function(t,n){return e.getFormattedLabel(t,n,"node")}},labelDataIndex:t.dataIndex,defaultText:t.id}),l.disableLabelAnimation=!0,l.setStyle("fill",t.getVisual("color")),l.setStyle("decal",t.getVisual("style").decal),dI(l,i),d.add(l),p.setItemGraphicEl(t.dataIndex,l),lQ(l).dataType="node";var u=a.get("focus");dM(l,"adjacency"===u?t.getAdjacentDataIndices():"trajectory"===u?t.getTrajectoryDataIndices():u,a.get("blurScope"),a.get("disabled"))}),p.eachItemGraphicEl(function(t,i){p.getItemModel(i).get("draggable")&&(t.drift=function(t,r){s._focusAdjacencyDisabled=!0,this.shape.x+=t,this.shape.y+=r,this.dirty(),n.dispatchAction({type:"dragNode",seriesId:e.id,dataIndex:p.getRawIndex(i),localX:this.shape.x/c,localY:this.shape.y/h})},t.ondragend=function(){s._focusAdjacencyDisabled=!1},t.draggable=!0,t.cursor="move")}),!this._data&&e.isAnimationEnabled()&&d.setClipPath((i=d.getBoundingRect(),r=e,o=function(){d.removeClipPath()},dz(a=new lN({shape:{x:i.x-10,y:i.y-10,width:0,height:i.height+20}}),{shape:{width:i.width+20}},r,o),a)),this._data=e.getData()},t.prototype.dispose=function(){},t.type="sankey",t}(fI);function ML(e,t,n){switch(e.fill){case"source":e.fill=n.node1.getVisual("color"),e.decal=n.node1.getVisual("style").decal;break;case"target":e.fill=n.node2.getVisual("color"),e.decal=n.node2.getVisual("style").decal;break;case"gradient":var i=n.node1.getVisual("color"),r=n.node2.getVisual("color");nA(i)&&nA(r)&&(e.fill=new p1(0,0,+("horizontal"===t),+("vertical"===t),[{color:i,offset:0},{color:r,offset:1}]))}}var MF=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){var n=e.edges||e.links||[],i=e.data||e.nodes||[],r=e.levels||[];this.levelModels=[];for(var o=this.levelModels,a=0;a<r.length;a++)null!=r[a].depth&&r[a].depth>=0&&(o[r[a].depth]=new ua(r[a],this,t));return ks(i,n,this,!0,function(e,t){e.wrapMethod("getItemModel",function(e,t){var n=e.parentModel,i=n.getData().getItemLayout(t);if(i){var r=i.depth,o=n.levelModels[r];o&&(e.parentModel=o)}return e}),t.wrapMethod("getItemModel",function(e,t){var n=e.parentModel,i=n.getGraph().getEdgeByIndex(t).node1.getLayout();if(i){var r=i.depth,o=n.levelModels[r];o&&(e.parentModel=o)}return e})}).data},t.prototype.setNodePosition=function(e,t){var n=(this.option.data||this.option.nodes)[e];n.localX=t[0],n.localY=t[1]},t.prototype.getGraph=function(){return this.getData().graph},t.prototype.getEdgeData=function(){return this.getGraph().edgeData},t.prototype.formatTooltip=function(e,t,n){function i(e){return isNaN(e)||null==e}if("edge"===n){var r=this.getDataParams(e,n),o=r.data,a=r.value;return hV("nameValue",{name:o.source+" -- "+o.target,value:a,noValue:i(a)})}var s=this.getGraph().getNodeByIndex(e).getLayout().value,l=this.getDataParams(e,n).data.name;return hV("nameValue",{name:null!=l?l+"":null,value:s,noValue:i(s)})},t.prototype.optionUpdated=function(){},t.prototype.getDataParams=function(t,n){var i=e.prototype.getDataParams.call(this,t,n);return null==i.value&&"node"===n&&(i.value=this.getGraph().getNodeByIndex(t).getLayout().value),i},t.type="series.sankey",t.defaultOption={z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3},t}(h1);function MO(e,t){e.eachSeriesByType("sankey",function(e){var n,i,r,o,a,s,l,d,u,c,h,p,f=e.get("nodeWidth"),g=e.get("nodeGap"),m=(n=e,i=t,uX(n.getBoxLayoutParams(),{width:i.getWidth(),height:i.getHeight()}));e.layoutInfo=m;var v=m.width,y=m.height,b=e.getGraph(),x=b.nodes,w=b.edges;nw(x,function(e){var t=Math.max(M$(e.outEdges,MW),M$(e.inEdges,MW),e.getValue()||0);e.setLayout({value:t},!0)});
422var C=0!==n_(x,function(e){return 0===e.getLayout().value}).length?0:e.get("layoutIterations");r=x,o=w,a=f,s=g,l=v,d=y,u=C,c=e.get("orient"),function(e,t,n,i,r,o,a){for(var s,l,d,u=[],c=[],h=[],p=[],f=0,g=0;g<t.length;g++)u[g]=1;for(var g=0;g<e.length;g++)c[g]=e[g].inEdges.length,0===c[g]&&h.push(e[g]);for(var m=-1;h.length;){for(var v=0;v<h.length;v++){var y=h[v],b=y.hostGraph.data.getRawDataItem(y.dataIndex),x=null!=b.depth&&b.depth>=0;x&&b.depth>m&&(m=b.depth),y.setLayout({depth:x?b.depth:f},!0),"vertical"===o?y.setLayout({dy:n},!0):y.setLayout({dx:n},!0);for(var w=0;w<y.outEdges.length;w++){var C=y.outEdges[w];u[t.indexOf(C)]=0;var S=C.node2,_=e.indexOf(S);0==--c[_]&&0>p.indexOf(S)&&p.push(S)}}++f,h=p,p=[]}for(var g=0;g<u.length;g++)if(1===u[g])throw Error("Sankey is a DAG, the original data has cycle!");var k=m>f-1?m:f-1;a&&"left"!==a&&function(e,t,n,i){if("right"===t){for(var r,o,a=[],s=e,l=0;s.length;){for(var d=0;d<s.length;d++){var u=s[d];u.setLayout({skNodeHeight:l},!0);for(var c=0;c<u.inEdges.length;c++){var h=u.inEdges[c];0>a.indexOf(h.node1)&&a.push(h.node1)}}s=a,a=[],++l}nw(e,function(e){MN(e)||e.setLayout({depth:Math.max(0,i-e.getLayout().skNodeHeight)},!0)})}else{"justify"===t&&(r=e,o=i,nw(r,function(e){MN(e)||e.outEdges.length||e.setLayout({depth:o},!0)}))}}(e,a,0,k),s=e,l="vertical"===o?(r-n)/k:(i-n)/k,d=o,nw(s,function(e){var t=e.getLayout().depth*l;"vertical"===d?e.setLayout({y:t},!0):e.setLayout({x:t},!0)})}(r,o,a,l,d,c,e.get("nodeAlign")),function(e,t,n,i,r,o,a){var s,l,d,u,c,h,p,f,g,m,v,y=(s=e,l=[],d="vertical"===a?"y":"x",(u=ss(s,function(e){return e.getLayout()[d]})).keys.sort(function(e,t){return e-t}),nw(u.keys,function(e){l.push(u.buckets.get(e))}),l);c=y,h=t,p=n,f=i,g=r,m=a,v=1/0,nw(c,function(e){var t=e.length,n=0;nw(e,function(e){n+=e.getLayout().value});var i="vertical"===m?(f-(t-1)*g)/n:(p-(t-1)*g)/n;i<v&&(v=i)}),nw(c,function(e){nw(e,function(e,t){var n=e.getLayout().value*v;"vertical"===m?(e.setLayout({x:t},!0),e.setLayout({dx:n},!0)):(e.setLayout({y:t},!0),e.setLayout({dy:n},!0))})}),nw(h,function(e){var t=e.getValue()*v;e.setLayout({dy:t},!0)}),MB(y,r,n,i,a);for(var b=1;o>0;o--)(function(e,t,n){nw(e.slice().reverse(),function(e){nw(e,function(e){if(e.outEdges.length){var i=M$(e.outEdges,Mz,n)/M$(e.outEdges,MW);if(isNaN(i)){var r=e.outEdges.length;i=r?M$(e.outEdges,Mj,n)/r:0}if("vertical"===n){var o=e.getLayout().x+(i-MG(e,n))*t;e.setLayout({x:o},!0)}else{var a=e.getLayout().y+(i-MG(e,n))*t;e.setLayout({y:a},!0)}}})})})(y,b*=.99,a),MB(y,r,n,i,a),function(e,t,n){nw(e,function(e){nw(e,function(e){if(e.inEdges.length){var i=M$(e.inEdges,MV,n)/M$(e.inEdges,MW);if(isNaN(i)){var r=e.inEdges.length;i=r?M$(e.inEdges,MH,n)/r:0}if("vertical"===n){var o=e.getLayout().x+(i-MG(e,n))*t;e.setLayout({x:o},!0)}else{var a=e.getLayout().y+(i-MG(e,n))*t;e.setLayout({y:a},!0)}}})})}(y,b,a),MB(y,r,n,i,a)}(r,o,d,l,s,u,c),h=r,p="vertical"===c?"x":"y",nw(h,function(e){e.outEdges.sort(function(e,t){return e.node2.getLayout()[p]-t.node2.getLayout()[p]}),e.inEdges.sort(function(e,t){return e.node1.getLayout()[p]-t.node1.getLayout()[p]})}),nw(h,function(e){var t=0,n=0;nw(e.outEdges,function(e){e.setLayout({sy:t},!0),t+=e.getLayout().dy}),nw(e.inEdges,function(e){e.setLayout({ty:n},!0),n+=e.getLayout().dy})})})}function MN(e){var t=e.hostGraph.data.getRawDataItem(e.dataIndex);return null!=t.depth&&t.depth>=0}function MB(e,t,n,i,r){var o="vertical"===r?"x":"y";nw(e,function(e){e.sort(function(e,t){return e.getLayout()[o]-t.getLayout()[o]});for(var a,s,l,d=0,u=e.length,c="vertical"===r?"dx":"dy",h=0;h<u;h++)(l=d-(s=e[h]).getLayout()[o])>0&&(a=s.getLayout()[o]+l,"vertical"===r?s.setLayout({x:a},!0):s.setLayout({y:a},!0)),d=s.getLayout()[o]+s.getLayout()[c]+t;if((l=d-t-("vertical"===r?i:n))>0){a=s.getLayout()[o]-l,"vertical"===r?s.setLayout({x:a},!0):s.setLayout({y:a},!0),d=a;for(var h=u-2;h>=0;--h)(l=(s=e[h]).getLayout()[o]+s.getLayout()[c]+t-d)>0&&(a=s.getLayout()[o]-l,"vertical"===r?s.setLayout({x:a},!0):s.setLayout({y:a},!0)),d=s.getLayout()[o]}})}function Mz(e,t){return MG(e.node2,t)*e.getValue()}function Mj(e,t){return MG(e.node2,t)}function MV(e,t){return MG(e.node1,t)*e.getValue()}function MH(e,t){return MG(e.node1,t)}function MG(e,t){return"vertical"===t?e.getLayout().x+e.getLayout().dx/2:e.getLayout().y+e.getLayout().dy/2}function MW(e){return e.getValue()}function M$(e,t,n){for(var i=0,r=e.length,o=-1;++o<r;){var a=+t(e[o],n);
422isNaN(a)||(i+=a)}return i}function MU(e){e.eachSeriesByType("sankey",function(e){var t=e.getGraph(),n=t.nodes,i=t.edges;if(n.length){var r=1/0,o=-1/0;nw(n,function(e){var t=e.getLayout().value;t<r&&(r=t),t>o&&(o=t)}),nw(n,function(t){var n=new S5({type:"color",mappingMethod:"linear",dataExtent:[r,o],visual:e.get("color")}).mapValueToVisual(t.getLayout().value),i=t.getModel().get(["itemStyle","color"]);null!=i?(t.setVisual("color",i),t.setVisual("style",{fill:i})):(t.setVisual("color",n),t.setVisual("style",{fill:n}))})}i.length&&nw(i,function(e){var t=e.getModel().get("lineStyle");e.setVisual("style",t)})})}var Mq=function(){function e(){}return e.prototype._hasEncodeRule=function(e){var t=this.getEncode();return t&&null!=t.get(e)},e.prototype.getInitialData=function(e,t){var n,i,r=t.getComponent("xAxis",this.get("xAxisIndex")),o=t.getComponent("yAxis",this.get("yAxisIndex")),a=r.get("type"),s=o.get("type");"category"===a?(e.layout="horizontal",n=r.getOrdinalMeta(),i=!this._hasEncodeRule("x")):"category"===s?(e.layout="vertical",n=o.getOrdinalMeta(),i=!this._hasEncodeRule("y")):e.layout=e.layout||"horizontal";var l=["x","y"],d=+("horizontal"!==e.layout),u=this._baseAxisDim=l[d],c=l[1-d],h=[r,o],p=h[d].get("type"),f=h[1-d].get("type"),g=e.data;if(g&&i){var m=[];nw(g,function(e,t){var n;nR(e)?(n=e.slice(),e.unshift(t)):nR(e.value)?((n=nf({},e)).value=n.value.slice(),e.value.unshift(t)):n=e,m.push(n)}),e.data=m}var v=this.defaultValueDimensions,y=[{name:u,type:vY(p),ordinalMeta:n,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:c,type:vY(f),dimsDef:v.slice()}];return bQ(this,{coordDimensions:y,dimensionsCount:v.length+1,encodeDefaulter:nD(cd,y,this)})},e.prototype.getBaseAxis=function(){var e=this._baseAxisDim;return this.ecModel.getComponent(e+"Axis",this.get(e+"AxisIndex")).axis},e}(),MK=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],n.visualDrawType="stroke",n}return(0,tQ.__extends)(t,e),t.type="series.boxplot",t.dependencies=["xAxis","yAxis","grid"],t.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800},t}(h1);nb(MK,Mq,!0);var MY=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=e.getData(),r=this.group,o=this._data;this._data||r.removeAll();var a=+("horizontal"===e.get("layout"));i.diff(o).add(function(e){if(i.hasValue(e)){var t=MJ(i.getItemLayout(e),i,e,a,!0);i.setItemGraphicEl(e,t),r.add(t)}}).update(function(e,t){var n=o.getItemGraphicEl(t);if(!i.hasValue(e))return void r.remove(n);var s=i.getItemLayout(e);n?(dW(n),MQ(s,n,i,e)):n=MJ(s,i,e,a),r.add(n),i.setItemGraphicEl(e,n)}).remove(function(e){var t=o.getItemGraphicEl(e);t&&r.remove(t)}).execute(),this._data=i},t.prototype.remove=function(e){var t=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl(function(e){e&&t.remove(e)})},t.type="boxplot",t}(fI),MZ=function(){},MX=function(e){function t(t){var n=e.call(this,t)||this;return n.type="boxplotBoxPath",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new MZ},t.prototype.buildPath=function(e,t){var n=t.points,i=0;for(e.moveTo(n[i][0],n[i][1]),i++;i<4;i++)e.lineTo(n[i][0],n[i][1]);for(e.closePath();i<n.length;i++)e.moveTo(n[i][0],n[i][1]),i++,e.lineTo(n[i][0],n[i][1])},t}(lk);function MJ(e,t,n,i,r){var o,a,s,l=e.ends,d=new MX({shape:{points:r?(o=l,a=i,s=e,nC(o,function(e){return(e=e.slice())[a]=s.initBaseline,e})):l}});return MQ(e,d,t,n,r),d}function MQ(e,t,n,i,r){var o=n.hostModel;(0,wN[r?"initProps":"updateProps"])(t,{shape:{points:e.ends}},o,i),t.useStyle(n.getItemVisual(i,"style")),t.style.strokeNoScale=!0,t.z2=100;var a=n.getItemModel(i),s=a.getModel("emphasis");dI(t,a),dM(t,s.get("focus"),s.get("blurScope"),s.get("disabled"))}function M0(e){var t,n;nw((t=[],n=[],e.eachSeriesByType("boxplot",function(e){var i=e.getBaseAxis(),r=nv(n,i);r<0&&(r=n.length,n[r]=i,t[r]={axis:i,seriesModels:[]}),t[r].seriesModels.push(e)}),t),function(e){var t=e.seriesModels;t.length&&(function(e){var t,n=e.axis,i=e.seriesModels,r=i.length,o=e.boxWidthList=[],a=e.boxOffsetList=[],s=[];if("category"===n.type)t=n.getBandWidth();else{var l=0;nw(i,function(e){l=Math.max(l,e.getData().count())});var d=n.getExtent();t=Math.abs(d[1]-d[0])/l}nw(i,function(e){var n=e.get("boxWidth");nR(n)||(n=[n,n]),s.push([aR(n[0],t)||0,aR(n[1],t)||0])});var u=.8*t-2,c=u/r*.3,h=(u-c*(r-1))/r,p=h/2-u/2;nw(i,function(e,t){a.push(p),p+=c+h,o.push(Math.min(Math.max(h,s[t][0]),s[t][1]))})}(e),nw(t,function(t,n){!function(e,t,n){var i=e.coordinateSystem,r=e.getData(),o=n/2,a=+("horizontal"!==e.get("layout")),s=1-a,l=["x","y"],d=r.mapDimension(l[a]),u=r.mapDimensionsAll(l[s]);if(null!=d&&!(u.length<5))for(var c=0;c<r.count();c++){var h=r.get(d,c),p=b(h,u[2],c),f=b(h,u[0],c),g=b(h,u[1],c),m=b(h,u[3],c),v=b(h,u[4],c),y=[];x(y,g,!1),x(y,m,!0),y.push(f,g,v,m),w(y,f),w(y,v),w(y,p),r.setItemLayout(c,{initBaseline:p[s],ends:y})}function b(e,n,o){var l,d=r.get(n,o),u=[];return u[a]=e,u[s]=d,isNaN(e)||isNaN(d)?l=[NaN,NaN]:(l=i.dataToPoint(u),l[a
422]+=t),l}function x(e,t,n){var i=t.slice(),r=t.slice();i[a]+=o,r[a]-=o,n?e.push(i,r):e.push(r,i)}function w(e,t){var n=t.slice(),i=t.slice();n[a]-=o,i[a]+=o,e.push(n,i)}}(t,e.boxOffsetList[n],e.boxWidthList[n])}))})}var M1={type:"echarts:boxplot",transform:function(e){var t=e.upstream;t.sourceFormat!==cn&&cw("");var n=function(e,t){for(var n=[],i=[],r=(t=t||{}).boundIQR,o="none"===r||0===r,a=0;a<e.length;a++){var s=aA(e[a].slice()),l=aW(s,.25),d=aW(s,.5),u=aW(s,.75),c=s[0],h=s[s.length-1],p=(null==r?1.5:r)*(u-l),f=o?c:Math.max(c,l-p),g=o?h:Math.min(h,u+p),m=t.itemNameFormatter,v=nI(m)?m({value:a}):nA(m)?m.replace("{value}",a+""):a+"";n.push([v,f,l,d,u,g]);for(var y=0;y<s.length;y++){var b=s[y];if(b<f||b>g){var x=[v,b];i.push(x)}}}return{boxData:n,outliers:i}}(t.getRawData(),e.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:n.boxData},{data:n.outliers}]}},M2=["itemStyle","borderColor"],M3=["itemStyle","borderColor0"],M5=["itemStyle","borderColorDoji"],M4=["itemStyle","color"],M6=["itemStyle","color0"];function M8(e,t){return t.get(e>0?M4:M6)}function M7(e,t){return t.get(0===e?M5:e>0?M2:M3)}var M9={seriesType:"candlestick",plan:pe(),performRawSeries:!0,reset:function(e,t){if(!t.isSeriesFiltered(e))return!e.pipelineContext.large&&{progress:function(e,t){for(var n;null!=(n=e.next());){var i=t.getItemModel(n),r=t.getItemLayout(n).sign,o=i.getItemStyle();o.fill=M8(r,i),o.stroke=M7(r,i)||o.fill,nf(t.ensureUniqueItemVisual(n,"style"),o)}}}}},Te=["color","borderColor"],Tt=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(e),this._isLargeDraw?this._renderLarge(e):this._renderNormal(e)},t.prototype.incrementalPrepareRender=function(e,t,n){this._clear(),this._updateDrawMode(e)},t.prototype.incrementalRender=function(e,t,n,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(e,t):this._incrementalRenderNormal(e,t)},t.prototype.eachRendered=function(e){fT(this._progressiveEls||this.group,e)},t.prototype._updateDrawMode=function(e){var t=e.pipelineContext.large;(null==this._isLargeDraw||t!==this._isLargeDraw)&&(this._isLargeDraw=t,this._clear())},t.prototype._renderNormal=function(e){var t=e.getData(),n=this._data,i=this.group,r=t.getLayout("isSimpleBox"),o=e.get("clip",!0),a=e.coordinateSystem,s=a.getArea&&a.getArea();this._data||i.removeAll(),t.diff(n).add(function(n){if(t.hasValue(n)){var a=t.getItemLayout(n);if(!(o&&To(s,a))){var l=Tr(a,n,!0);dz(l,{shape:{points:a.ends}},e,n),Ta(l,t,n,r),i.add(l),t.setItemGraphicEl(n,l)}}}).update(function(a,l){var d=n.getItemGraphicEl(l);if(!t.hasValue(a))return void i.remove(d);var u=t.getItemLayout(a);o&&To(s,u)?i.remove(d):(d?(dB(d,{shape:{points:u.ends}},e,a),dW(d)):d=Tr(u,a),Ta(d,t,a,r),i.add(d),t.setItemGraphicEl(a,d))}).remove(function(e){var t=n.getItemGraphicEl(e);t&&i.remove(t)}).execute(),this._data=t},t.prototype._renderLarge=function(e){this._clear(),Td(e,this.group);var t=e.get("clip",!0)?yA(e.coordinateSystem,!1,e):null;t?this.group.setClipPath(t):this.group.removeClipPath()},t.prototype._incrementalRenderNormal=function(e,t){for(var n,i=t.getData(),r=i.getLayout("isSimpleBox");null!=(n=e.next());){var o=Tr(i.getItemLayout(n),n);Ta(o,i,n,r),o.incremental=!0,this.group.add(o),this._progressiveEls.push(o)}},t.prototype._incrementalRenderLarge=function(e,t){Td(t,this.group,this._progressiveEls,!0)},t.prototype.remove=function(e){this._clear()},t.prototype._clear=function(){this.group.removeAll(),this._data=null},t.type="candlestick",t}(fI),Tn=function(){},Ti=function(e){function t(t){var n=e.call(this,t)||this;return n.type="normalCandlestickBox",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new Tn},t.prototype.buildPath=function(e,t){var n=t.points;this.__simpleBox?(e.moveTo(n[4][0],n[4][1]),e.lineTo(n[6][0],n[6][1])):(e.moveTo(n[0][0],n[0][1]),e.lineTo(n[1][0],n[1][1]),e.lineTo(n[2][0],n[2][1]),e.lineTo(n[3][0],n[3][1]),e.closePath(),e.moveTo(n[4][0],n[4][1]),e.lineTo(n[5][0],n[5][1]),e.moveTo(n[6][0],n[6][1]),e.lineTo(n[7][0],n[7][1]))},t}(lk);function Tr(e,t,n){var i,r,o=e.ends;return new Ti({shape:{points:n?(i=o,r=e,nC(i,function(e){return(e=e.slice())[1]=r.initBaseline,e})):o},z2:100})}function To(e,t){for(var n=!0,i=0;i<t.ends.length;i++)if(e.contain(t.ends[i][0],t.ends[i][1])){n=!1;break}return n}function Ta(e,t,n,i){var r=t.getItemModel(n);e.useStyle(t.getItemVisual(n,"style")),e.style.strokeNoScale=!0,e.__simpleBox=i,dI(e,r);var o=t.getItemLayout(n).sign;nw(e.states,function(e,t){var n=r.getModel(t),i=M8(o,n),a=M7(o,n)||i,s=e.style||(e.style={});i&&(s.fill=i),a&&(s.stroke=a)});var a=r.getModel("emphasis");dM(e,a.get("focus"),a.get("blurScope"),a.get("disabled"))}var Ts=function(){},Tl=function(e){function t(t){var n=e.call(this,t)||this;return n.type="largeCandlestickBox",n}return(0,tQ.__extends)(t,e),t.prototype.getDefaultShape=function(){return new Ts},t.prototype.buildPath=function(e,t){for(var n=t.points,i=0;i<n.length;)if(this.__sign===n[i++]){var r=n[i++];e.moveTo(r,n[i++]),e.lineTo(r,n[i++])}else i+=3},t}(lk);function Td(e,t,n,i){var r=e.getData(),o=r.getLayout("largePoints"),a=new Tl({shape:{points:o},__sign:1,ignoreCoarsePointer:!0});t.add(a);var s=new Tl({shape:{points:o},__sign:-1,ignoreCoarsePointer:!0});t.add(s);var l=new Tl({shape:{points:o},__sign:0,ignoreCoarsePointer:!0});t.add(l),Tu(1,a,e,r),Tu(-1,s,e,r),Tu(0,l,e,r),i&&(a.incremental=!0,s.incremental=!0),n&&n.push(a,s)}function Tu(e,t,n,i){var r=M7(e,n)||M8(e,n),o=n.getModel("itemStyle").getItemStyle(Te);t.useStyle(o),t.style.fill=null,t.style.stroke=r}var Tc=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],n}return(0,tQ.__extends)(t,e),t.prototype.getShadowDim=function(){return"open"},t.prototype.brushSelector=function(e,t,n){var i=t.getItemLayout(e);return i&&n.rect(i.brushRect)},t.type="series.candlestick",t.dependencies=["xAxis","yAxis","grid"],t.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},t}(h1);function Th(e){e&&nR(e.series)&&nw(e.series,function(e){nL(e)&&"k"===e.type&&(e.type="candlestick")})}nb(Tc,Mq,!0);var Tp={seriesType:"candlestick",plan:pe(),reset:function(e){var t,n,i,r,o,a,s,l,d=e.coordinateSystem,u=e.getData(),c=(t=e,n=u,o="category"===(r=t.getBaseAxis()).type?r.getBandWidth():Math.abs((i=r.getExtent())[1]-i[0])/n.count(),a=aR(nG(t.get("barMaxWidth"),o),o),s=aR(nG(t.get("barMinWidth"),
vendor: 11,433 bytes, line 422
4221),o),null!=(l=t.get("barWidth"))?aR(l,o):Math.max(Math.min(o/2,a),s)),h=u.getDimensionIndex(u.mapDimension("x")),p=nC(u.mapDimensionsAll("y"),u.getDimensionIndex,u),f=p[0],g=p[1],m=p[2],v=p[3];if(u.setLayout({candleWidth:c,isSimpleBox:c<=1.3}),!(h<0)&&!(p.length<4))return{progress:e.pipelineContext.large?function(t,n){for(var i,r,o=yx(4*t.count),a=0,s=[],l=[],u=n.getStore(),c=!!e.get(["itemStyle","borderColorDoji"]);null!=(r=t.next());){var p=u.get(h,r),y=u.get(f,r),b=u.get(g,r),x=u.get(m,r),w=u.get(v,r);if(isNaN(p)||isNaN(x)||isNaN(w)){o[a++]=NaN,a+=3;continue}o[a++]=Tf(u,r,y,b,g,c),s[0]=p,s[1]=x,i=d.dataToPoint(s,null,l),o[a++]=i?i[0]:NaN,o[a++]=i?i[1]:NaN,s[1]=w,i=d.dataToPoint(s,null,l),o[a++]=i?i[1]:NaN}n.setLayout("largePoints",o)}:function(e,t){for(var n,i=t.getStore();null!=(n=e.next());){var r=i.get(h,n),o=i.get(f,n),a=i.get(g,n),s=i.get(m,n),l=i.get(v,n),u=Math.min(o,a),p=Math.max(o,a),y=_(u,r),b=_(p,r),x=_(s,r),w=_(l,r),C=[];k(C,b,0),k(C,y,1),C.push(M(w),M(b),M(x),M(y));var S=!!t.getItemModel(n).get(["itemStyle","borderColorDoji"]);t.setItemLayout(n,{sign:Tf(i,n,o,a,g,S),initBaseline:o>a?b[1]:y[1],ends:C,brushRect:function(e,t,n){var i=_(e,n),r=_(t,n);return i[0]-=c/2,r[0]-=c/2,{x:i[0],y:i[1],width:c,height:r[1]-i[1]}}(s,l,r)})}function _(e,t){var n=[];return n[0]=t,n[1]=e,isNaN(t)||isNaN(e)?[NaN,NaN]:d.dataToPoint(n)}function k(e,t,n){var i=t.slice(),r=t.slice();i[0]=fg(i[0]+c/2,1,!1),r[0]=fg(r[0]-c/2,1,!0),n?e.push(i,r):e.push(r,i)}function M(e){return e[0]=fg(e[0],1),e}}}}};function Tf(e,t,n,i,r,o){return n>i?-1:n<i?1:o?0:t>0?e.get(r,t-1)<=i?1:-1:1}function Tg(e,t){var n=t.rippleEffectColor||t.color;e.eachChild(function(e){e.attr({z:t.z,zlevel:t.zlevel,style:{stroke:"stroke"===t.brushType?n:null,fill:"fill"===t.brushType?n:null}})})}var Tm=function(e){function t(t,n){var i=e.call(this)||this,r=new yu(t,n),o=new av;return i.add(r),i.add(o),i.updateData(t,n),i}return(0,tQ.__extends)(t,e),t.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},t.prototype.startEffectAnimation=function(e){for(var t=e.symbolType,n=e.color,i=e.rippleNumber,r=this.childAt(1),o=0;o<i;o++){var a=g_(t,-1,-1,2,2,n);a.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5});var s=-o/i*e.period+e.effectOffset;a.animate("",!0).when(e.period,{scaleX:e.rippleScale/2,scaleY:e.rippleScale/2}).delay(s).start(),a.animateStyle(!0).when(e.period,{opacity:0}).delay(s).start(),r.add(a)}Tg(r,e)},t.prototype.updateEffectAnimation=function(e){for(var t=this._effectCfg,n=this.childAt(1),i=["symbolType","period","rippleScale","rippleNumber"],r=0;r<i.length;r++){var o=i[r];if(t[o]!==e[o]){this.stopEffectAnimation(),this.startEffectAnimation(e);return}}Tg(n,e)},t.prototype.highlight=function(){dv(this)},t.prototype.downplay=function(){dy(this)},t.prototype.getSymbolType=function(){var e=this.childAt(0);return e&&e.getSymbolType()},t.prototype.updateData=function(e,t){var n=this,i=e.hostModel;this.childAt(0).updateData(e,t);var r=this.childAt(1),o=e.getItemModel(t),a=e.getItemVisual(t,"symbol"),s=gk(e.getItemVisual(t,"symbolSize")),l=e.getItemVisual(t,"style"),d=l&&l.fill,u=o.getModel("emphasis");r.setScale(s),r.traverse(function(e){e.setStyle("fill",d)});var c=gM(e.getItemVisual(t,"symbolOffset"),s);c&&(r.x=c[0],r.y=c[1]),r.rotation=(e.getItemVisual(t,"symbolRotate")||0)*Math.PI/180||0;var h={};h.showEffectOn=i.get("showEffectOn"),h.rippleScale=o.get(["rippleEffect","scale"]),h.brushType=o.get(["rippleEffect","brushType"]),h.period=1e3*o.get(["rippleEffect","period"]),h.effectOffset=t/e.count(),h.z=i.getShallow("z")||0,h.zlevel=i.getShallow("zlevel")||0,h.symbolType=a,h.color=d,h.rippleEffectColor=o.get(["rippleEffect","color"]),h.rippleNumber=o.get(["rippleEffect","number"]),"render"===h.showEffectOn?(this._effectCfg?this.updateEffectAnimation(h):this.startEffectAnimation(h),this._effectCfg=h):(this._effectCfg=null,this.stopEffectAnimation(),this.onHoverStateChange=function(e){"emphasis"===e?"render"!==h.showEffectOn&&n.startEffectAnimation(h):"normal"===e&&"render"!==h.showEffectOn&&n.stopEffectAnimation()}),this._effectCfg=h,dM(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},t.prototype.fadeOut=function(e){e&&e()},t}(av),Tv=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(){this._symbolDraw=new yg(Tm)},t.prototype.render=function(e,t,n){var i=e.getData(),r=this._symbolDraw;r.updateData(i,{clipShape:this._getClipShape(e)}),this.group.add(r.group)},t.prototype._getClipShape=function(e){var t=e.coordinateSystem,n=t&&t.getArea&&t.getArea();return e.get("clip",!0)?n:null},t.prototype.updateTransform=function(e,t,n){var i=e.getData();this.group.dirty();var r=yH("").reset(e,t,n);r.progress&&r.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout()},t.prototype._updateGroupTransform=function(e){var t=e.coordinateSystem;t&&t.getRoamTransform&&(this.group.transform=i1(t.getRoamTransform()),this.group.decomposeTransform())},t.prototype.remove=function(e,t){this._symbolDraw&&this._symbolDraw.remove(!0)},t.type="effectScatter",t}(fI),Ty=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){return ya(null,this,{useEncodeDefaulter:!0})},t.prototype.brushSelector=function(e,t,n){return n.point(t.getItemLayout(e))},t.type="series.effectScatter",t.dependencies=["grid","polar"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10},t}(h1),Tb=function(e){function t(t,n,i){var r=e.call(this)||this;return r.add(r.createLine(t,n,i)),r._updateEffectSymbol(t,n),r}return(0,tQ.__extends)(t,e),t.prototype.createLine=function(e,t,n){return new _Q(e,t,n)},t.prototype._updateEffectSymbol=function(e,t){var n=e.getItemModel(t).getModel("effect"),i=n.get("symbolSize"),r=n.get("symbol");nR(i)||(i=[i,i]);var o=e.getItemVisual(t,"style"),a=n.get("color")||o&&o.stroke,s=this.childAt(1);this._symbolType!==r&&(this.remove(s),(s=g_(r,-.5,-.5,1,1,a)).z2=100,s.culling=!0,this.add(s)),s&&(s.setStyle("shadowColor",a),s.setStyle(n.getItemStyle(["color"])),s.scaleX=i[0],s.scaleY=i[1],s.setColor(a),this._symbolType=r,this._symbolScale=i,this._updateEffectAnimation(e,n,t))},t.prototype._updateEffectAnimation=function(e,t,n){var i=this.childAt(1);if(i){var r=e.getItemLayout(n),o=1e3*t.get("period"),a=t.get("loop"),s=t.get("roundTrip"),l=t.get("constantSpeed"),d=nH(t.get("delay"),function(t){return t/e.count()*o/3});if(i.ignore=!0,this._updateAnimationPoints(i,r),l>0&&(o=this._getLineLength(i)/l*1e3),o!==this._period||a!==this._loop||s!==this._roundTrip){i.stopAnimation();var u=void 0;u=nI(d)?d(n):d,i.__t>0&&(u=-o*i.__t),this._animateSymbol(i,o,u,a,s)}this._period=o,this._loop=a,this._roundTrip=s}},t.prototype._animateSymbol=function(e,t,n,i,r){if(t>0){e.__t=0;var o=this,a=e.animate("",i).when(r?2*t:t,{__t:r?2:1}).delay(n).during(function(){o._updateSymbolPosition(e)});i||a.done(function(){o.remove(e)}),a.start()}},t.prototype._getLineLength=function(e){return ip(e.__p1,e.__cp1)+ip(e.__cp1,e.__p2)},t.prototype._updateAnimationPoints=function(e,t){e.__p1=t[0],e.__p2=t[1],e.__cp1=t[2]||[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]},t.prototype.updateData=function(e,t,n){this.childAt(0).updateData(e,t,n),this._updateEffectSymbol(e,t)},t.prototype._updateSymbolPosition=function(e){var t=e.__p1,n=e.__p2,i=e.__cp1,r=e.__t<1?e.__t:2-e.__t,o=[e.x,e.y],a=o.slice();o[0]=rO(t[0],i[0],n[0],r),o[1]=rO(t[1],i[1],n[1],r);var s=e.__t<1?rN(t[0],i[0],n[0],r):rN(n[0],i[0],t[0],1-r),l=e.__t<1?rN(t[1],i[1],n[1],r):rN(n[1],i[1],t[1],1-r);e.rotation=-Math.atan2(l,s)-Math.PI/2,("line"===this._symbolType||"rect"===this._symbolType||"roundRect"===this._symbolType)&&(void 0!==e.__lastT&&e.__lastT<e.__t?(e.scaleY=1.05*ip(a,o),1===r&&(o[0]=a[0]+(o[0]-a[0])/2,o[1]=a[1]+(o[1]-a[1])/2)):1===e.__lastT?e.scaleY=2*ip(t,o):e.scaleY=this._symbolScale[1]),e.__lastT=e.__t,e.ignore=!1,e.x=o[0],e.y=o[1]},t.prototype.updateLayout=function(e,t){this.childAt(0).updateLayout(e,t);var n=e.getItemModel(t).getModel("effect");this._updateEffectAnimation(e,n,t)},t}(av),Tx=function(e){function t(t,n,i){var r=e.call(this)||this;return r._createPolyline(t,n,i),r}return(0,tQ.__extends)(t,e),t.prototype._createPolyline=function(e,t,n){var i=new pG({shape:{points:e.getItemLayout(t)}});this.add(i),this._updateCommonStl(e,t,n)},t.prototype.updateData=function(e,t,n){var i=e.hostModel;dB(this.childAt(0),{shape:{points:e.getItemLayout(t)}},i,t),this._updateCommonStl(e,t,n)},t.prototype._updateCommonStl=function(e,t,n){var i=this.childAt(0),r=e.getItemModel(t),o=n&&n.emphasisLineStyle,a=n&&n.focus,s=n&&n.blurScope,l=n&&n.emphasisDisabled;if(!n||e.hasItemOption){var d=r.getModel("emphasis");o=d.getModel("lineStyle").getLineStyle(),l=d.get("disabled"),a=d.get("focus"),s=d.get("blurScope")}i.useStyle(e.getItemVisual(t,"style")),i.style.fill=null,i.style.strokeNoScale=!0,i.ensureState("emphasis").style=o,dM(this,a,s,l)},t.prototype.updateLayout=function(e,t){this.childAt(0).setShape("points",e.getItemLayout(t))},t}(av),Tw=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._lastFrame=0,t._lastFramePercent=0,t}return(0,tQ.__extends)(t,e),t.prototype.createLine=function(e,t,n){return new Tx(e,t,n)},t.prototype._updateAnimationPoints=function(e,t){this._points=t;for(var n=[0],i=0,r=1;r<t.length;r++)i+=ip(t[r-1],t[r]),n.push(i);if(0===i){this._length=0;return}for(var r=0;r<n.length;r++)n[r]/=i;this._offsets=n,this._length=i},t.prototype._getLineLength=function(){return this._length},t.prototype._updateSymbolPosition=function(e){var t,n=e.__t<1?e.__t:2-e.__t,i=this._points,r=this._offsets,o=i.length;if(r){var a=this._lastFrame;if(n<this._lastFramePercent){for(t=Math.min(a+1,o-1);t>=0&&!(r[t]<=n);t--);t=Math.min(t,o-2)}else{for(t=a;t<o&&!(r[t]>n);t++);t=Math.min(t-1,o-2)}var s=(n-r[t])/(r[t+1]-r[t]),l=i[t],d=i[t+1];e.x=l[0]*(1-s)+s*d[0],e.y=l[1]*(1-s)+s*d[1];var u=e.__t<1?d[0]-l[0]:l[0]-d[0],c=e.__t<1?d[1]-l[1]:l[1]-d[1];e.rotation=-Math.atan2(c,u)-Math.PI/2,this._lastFrame=t,this._lastFramePercent=n,e.ignore=!1}},t}(Tb),TC=function(){this.polyline=!1,this.curveness=0,this.segs=[]},TS=function(e){function t(t){var n=e.call(this,t)||this;return n._off=0,n.hoverDataIdx=-1,n}return(0,tQ.__extends)(t,e),t.prototype.reset=function(){this.notClear=!1,this._off=0},t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new TC},t.prototype.buildPath=function(e,t){var n,i=t.segs,r=t.curveness;if(t.polyline)for(n=this._off;n<i.length;){var o=i[n++];if(o>0){e.moveTo(i[n++],i[n++]);for(var a=1;a<o;a++)e.lineTo(i[n++],i[n++])}}else for(n=this._off;n<i.length;){var s=i[n++],l=i[n++],d=i[n++],u=i[n++];if(e.moveTo(s,l),r>0){var c=(s+d)/2-(l-u)*r,h=(l+u)/2-(d-s)*r;e.quadraticCurveTo(c,h,d,u)}else e.lineTo(d,u)}this.incremental&&(this._off=n,this.notClear=!0)},t.prototype.findDataIndex=function(e,t){var n=this.shape,i=n.segs,r=n.curveness,o=this.style.lineWidth;if(n.polyline)for(var a=0,s=0;s<i.length;){var l=i[s++];if(l>0)for(var d=i[s++],u=i[s++],c=1;c<l;c++){var h=i[s++],p=i[s++];if(lc(d,u,h,p,o,e,t))return a}
422a++}else for(var a=0,s=0;s<i.length;){var d=i[s++],u=i[s++],h=i[s++],p=i[s++];if(r>0){var f=(d+h)/2-(u-p)*r,g=(u+p)/2-(h-d)*r;if(lh(d,u,f,g,h,p,o,e,t))return a}else if(lc(d,u,h,p,o,e,t))return a;a++}return -1},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t),i=this.getBoundingRect();return(e=n[0],t=n[1],i.contain(e,t))?(this.hoverDataIdx=this.findDataIndex(e,t))>=0:(this.hoverDataIdx=-1,!1)},t.prototype.getBoundingRect=function(){var e=this._rect;if(!e){for(var t=this.shape.segs,n=1/0,i=1/0,r=-1/0,o=-1/0,a=0;a<t.length;){var s=t[a++],l=t[a++];n=Math.min(s,n),r=Math.max(s,r),i=Math.min(l,i),o=Math.max(l,o)}e=this._rect=new rt(n,i,r,o)}return e},t}(lk),T_=function(){function e(){this.group=new av}return e.prototype.updateData=function(e){this._clear();var t=this._create();t.setShape({segs:e.getLayout("linesPoints")}),this._setCommon(t,e)},e.prototype.incrementalPrepareUpdate=function(e){this.group.removeAll(),this._clear()},e.prototype.incrementalUpdate=function(e,t){var n=this._newAdded[0],i=t.getLayout("linesPoints"),r=n&&n.shape.segs;if(r&&r.length<2e4){var o=r.length,a=new Float32Array(o+i.length);a.set(r),a.set(i,o),n.setShape({segs:a})}else{this._newAdded=[];var s=this._create();s.incremental=!0,s.setShape({segs:i}),this._setCommon(s,t),s.__startIndex=e.start}},e.prototype.remove=function(){this._clear()},e.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},e.prototype._create=function(){var e=new TS({cursor:"default",ignoreCoarsePointer:!0});return this._newAdded.push(e),this.group.add(e),e},e.prototype._setCommon=function(e,t,n){var i=t.hostModel;e.setShape({polyline:i.get("polyline"),curveness:i.get(["lineStyle","curveness"])}),e.useStyle(i.getModel("lineStyle").getLineStyle()),e.style.strokeNoScale=!0;var r=t.getVisual("style");r&&r.stroke&&e.setStyle("stroke",r.stroke),e.setStyle("fill",null);var o=lQ(e);o.seriesIndex=i.seriesIndex,e.on("mousemove",function(t){o.dataIndex=null;var n=e.hoverDataIdx;n>0&&(o.dataIndex=n+e.__startIndex)})},e.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},e}(),Tk={seriesType:"lines",plan:pe(),reset:function(e){var t=e.coordinateSystem;if(t){var n=e.get("polyline"),i=e.pipelineContext.large;return{progress:function(r,o){var a=[];if(i){var s=void 0,l=r.end-r.start;if(n){for(var d=0,u=r.start;u<r.end;u++)d+=e.getLineCoordsCount(u);s=new Float32Array(l+2*d)}else s=new Float32Array(4*l);for(var c=0,h=[],u=r.start;u<r.end;u++){var p=e.getLineCoords(u,a);n&&(s[c++]=p);for(var f=0;f<p;f++)h=t.dataToPoint(a[f],!1,h),s[c++]=h[0],s[c++]=h[1]}o.setLayout("linesPoints",s)}else for(var u=r.start;u<r.end;u++){var g=o.getItemModel(u),p=e.getLineCoords(u,a),m=[];if(n)for(var v=0;v<p;v++)m.push(t.dataToPoint(a[v]));else{m[0]=t.dataToPoint(a[0]),m[1]=t.dataToPoint(a[1]);var y=g.get(["lineStyle","curveness"]);+y&&(m[2]=[(m[0][0]+m[1][0])/2-(m[0][1]-m[1][1])*y,(m[0][1]+m[1][1])/2-(m[1][0]-m[0][0])*y])}o.setItemLayout(u,m)}}}}}},TM=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=e.getData(),r=this._updateLineDraw(i,e),o=e.get("zlevel"),a=e.get(["effect","trailLength"]),s=n.getZr(),l="svg"===s.painter.getType();l||s.painter.getLayer(o).clear(!0),null==this._lastZlevel||l||s.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(e)&&a>0&&(l||s.configLayer(o,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(a/10+.9,1),0)})),r.updateData(i);var d=e.get("clip",!0)&&yA(e.coordinateSystem,!1,e);d?this.group.setClipPath(d):this.group.removeClipPath(),this._lastZlevel=o,this._finished=!0},t.prototype.incrementalPrepareRender=function(e,t,n){var i=e.getData();this._updateLineDraw(i,e).incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},t.prototype.incrementalRender=function(e,t,n){this._lineDraw.incrementalUpdate(e,t.getData()),this._finished=e.end===t.getData().count()},t.prototype.eachRendered=function(e){this._lineDraw&&this._lineDraw.eachRendered(e)},t.prototype.updateTransform=function(e,t,n){var i=e.getData(),r=e.pipelineContext;
vendor: 8,588 bytes, line 422
422if(!this._finished||r.large||r.progressiveRender)return{update:!0};var o=Tk.reset(e,t,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(n)},t.prototype._updateLineDraw=function(e,t){var n=this._lineDraw,i=this._showEffect(t),r=!!t.get("polyline"),o=t.pipelineContext.large;return n&&i===this._hasEffet&&r===this._isPolyline&&o===this._isLargeDraw||(n&&n.remove(),n=this._lineDraw=o?new T_:new _0(r?i?Tw:Tx:i?Tb:_Q),this._hasEffet=i,this._isPolyline=r,this._isLargeDraw=o),this.group.add(n.group),n},t.prototype._showEffect=function(e){return!!e.get(["effect","show"])},t.prototype._clearLayer=function(e){var t=e.getZr();"svg"!==t.painter.getType()&&null!=this._lastZlevel&&t.painter.getLayer(this._lastZlevel).clear(!0)},t.prototype.remove=function(e,t){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(t)},t.prototype.dispose=function(e,t){this.remove(e,t)},t.type="lines",t}(fI),TT="u"<typeof Uint32Array?Array:Uint32Array,TD="u"<typeof Float64Array?Array:Float64Array;function TR(e){var t=e.data;t&&t[0]&&t[0][0]&&t[0][0].coord&&(e.data=nC(t,function(e){var t={coords:[e[0].coord,e[1].coord]};return e[0].name&&(t.fromName=e[0].name),e[1].name&&(t.toName=e[1].name),np([t,e[0],e[1]])}))}var TI=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.visualStyleAccessPath="lineStyle",n.visualDrawType="stroke",n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t){t.data=t.data||[],TR(t);var n=this._processFlatCoordsArray(t.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(t.data=new Float32Array(n.count)),e.prototype.init.apply(this,arguments)},t.prototype.mergeOption=function(t){if(TR(t),t.data){var n=this._processFlatCoordsArray(t.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(t.data=new Float32Array(n.count))}e.prototype.mergeOption.apply(this,arguments)},t.prototype.appendData=function(e){var t=this._processFlatCoordsArray(e.data);t.flatCoords&&(this._flatCoords?(this._flatCoords=n2(this._flatCoords,t.flatCoords),this._flatCoordsOffset=n2(this._flatCoordsOffset,t.flatCoordsOffset)):(this._flatCoords=t.flatCoords,this._flatCoordsOffset=t.flatCoordsOffset),e.data=new Float32Array(t.count)),this.getRawData().appendData(e.data)},t.prototype._getCoordsFromItemModel=function(e){var t=this.getData().getItemModel(e);return t.option instanceof Array?t.option:t.getShallow("coords")},t.prototype.getLineCoordsCount=function(e){return this._flatCoordsOffset?this._flatCoordsOffset[2*e+1]:this._getCoordsFromItemModel(e).length},t.prototype.getLineCoords=function(e,t){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[2*e],i=this._flatCoordsOffset[2*e+1],r=0;r<i;r++)t[r]=t[r]||[],t[r][0]=this._flatCoords[n+2*r],t[r][1]=this._flatCoords[n+2*r+1];return i}for(var o=this._getCoordsFromItemModel(e),r=0;r<o.length;r++)t[r]=t[r]||[],t[r][0]=o[r][0],t[r][1]=o[r][1];return o.length},t.prototype._processFlatCoordsArray=function(e){var t=0;if(this._flatCoords&&(t=this._flatCoords.length),nE(e[0])){for(var n=e.length,i=new TT(n),r=new TD(n),o=0,a=0,s=0,l=0;l<n;){s++;var d=e[l++];i[a++]=o+t,i[a++]=d;for(var u=0;u<d;u++){var c=e[l++],h=e[l++];r[o++]=c,r[o++]=h}}return{flatCoordsOffset:new Uint32Array(i.buffer,0,a),flatCoords:r,count:s}}return{flatCoordsOffset:null,flatCoords:null,count:e.length}},t.prototype.getInitialData=function(e,t){var n=new v8(["value"],this);return n.hasItemOption=!1,n.initData(e.data,[],function(e,t,i,r){if(e instanceof Array)return NaN;n.hasItemOption=!0;var o=e.value;if(null!=o)return o instanceof Array?o[r]:o}),n},t.prototype.formatTooltip=function(e,t,n){var i=this.getData().getItemModel(e),r=i.get("name");if(r)return r;var o=i.get("fromName"),a=i.get("toName"),s=[];return null!=o&&s.push(o),null!=a&&s.push(a),hV("nameValue",{name:s.join(" > ")})},t.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},t.prototype.getProgressive=function(){var e=this.option.progressive;return null==e?this.option.large?1e4:this.get("progressive"):e},t.prototype.getProgressiveThreshold=function(){var e=this.option.progressiveThreshold;return null==e?this.option.large?2e4:this.get("progressiveThreshold"):e},t.prototype.getZLevelKey=function(){var e=this.getModel("effect"),t=e.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:e.get("show")&&t>0?t+"":""},t.type="series.lines",t.dependencies=["grid","polar","geo","calendar"],t.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},t}(h1);function TA(e){return e instanceof Array||(e=[e,e]),e}let TP={seriesType:"lines",reset:function(e){var t=TA(e.get("symbol")),n=TA(e.get("symbolSize")),i=e.getData();return i.setVisual("fromSymbol",t&&t[0]),i.setVisual("toSymbol",t&&t[1]),i.setVisual("fromSymbolSize",n&&n[0]),i.setVisual("toSymbolSize",n&&n[1]),{dataEach:i.hasItemOption?function(e,t){var n=e.getItemModel(t),i=TA(n.getShallow("symbol",!0)),r=TA(n.getShallow("symbolSize",!0));i[0]&&e.setItemVisual(t,"fromSymbol",i[0]),i[1]&&e.setItemVisual(t,"toSymbol",i[1]),r[0]&&e.setItemVisual(t,"fromSymbolSize",r[0]),r[1]&&e.setItemVisual(t,"toSymbolSize",r[1])}:null}}};var TE=function(){function e(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var e=t4.createCanvas();this.canvas=e}return e.prototype.update=function(e,t,n,i,r,o){var a=this._getBrush(),s=this._getGradient(r,"inRange"),l=this._getGradient(r,"outOfRange"),d=this.pointSize+this.blurSize,u=this.canvas,c=u.getContext("2d"),h=e.length;u.width=t,u.height=n;for(var p=0;p<h;++p){var f=e[p],g=f[0],m=f[1],v=i(f[2]);c.globalAlpha=v,c.drawImage(a,g-d,m-d)}if(!u.width||!u.height)return u;for(var y=c.getImageData(0,0,u.width,u.height),b=y.data,x=0,w=b.length,C=this.minOpacity,S=this.maxOpacity-C;x<w;){var v=b[x+3]/256,_=4*Math.floor(255*v);if(v>0){var k=o(v)?s:l;v>0&&(v=v*S+C),b[x++]=k[_],b[x++]=k[_+1],b[x++]=k[_+2],b[x++]=k[_+3]*v*256}else x+=4}return c.putImageData(y,0,0),u},e.prototype._getBrush=function(){var e=this._brushCanvas||(this._brushCanvas=t4.createCanvas()),t=this.pointSize+this.blurSize,n=2*t;e.width=n,e.height=n;var i=e.getContext("2d");return i.clearRect(0,0,n,n),i.shadowOffsetX=n,i.shadowBlur=this.blurSize,i.shadowColor="#000",i.beginPath(),i.arc(-t,t,this.pointSize,0,2*Math.PI,!0),i.closePath(),i.fill(),e},e.prototype._getGradient=function(e,t){for(var n=this._gradientPixels,i=n[t]||(n[t]=new Uint8ClampedArray(1024)),r=[0,0,0,0],o=0,a=0;a<256;a++)e[t](a/255,!0,r),i[o++]=r[0],i[o++]=r[1],i[o++]=r[2],i[o++]=r[3];return i},e}();function TL(e){var t=e.dimensions;return"lng"===t[0]&&"lat"===t[1]}var TF=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){t.eachComponent("visualMap",function(t){t.eachTargetSeries(function(n){n===e&&(i=t)})}),this._progressiveEls=null,this.group.removeAll();var i,r=e.coordinateSystem;"cartesian2d"===r.type||"calendar"===r.type?this._renderOnCartesianAndCalendar(e,n,0,e.getData().count()):TL(r)&&this._renderOnGeo(r,e,i,n)},t.prototype.incrementalPrepareRender=function(e,t,n){this.group.removeAll()},t.prototype.incrementalRender=function(e,t,n,i){var r=t.coordinateSystem;r&&(TL(r)?this.render(t,n,i):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(t,i,e.start,e.end,!0)))},t.prototype.eachRendered=function(e){fT(this._progressiveEls||this.group,e)},t.prototype._renderOnCartesianAndCalendar=function(e,t,n,i,r){var o,a,s,l,d=e.coordinateSystem,u=yP(d,"cartesian2d");if(u){var c=d.getAxis("x"),h=d.getAxis("y");o=c.getBandWidth()+.5,a=h.getBandWidth()+.5,s=c.scale.getExtent(),l=h.scale.getExtent()}for(var p=this.group,f=e.getData(),g=e.getModel(["emphasis","itemStyle"]).getItemStyle(),m=e.getModel(["blur","itemStyle"]).getItemStyle(),v=e.getModel(["select","itemStyle"]).getItemStyle(),y=e.get(["itemStyle","borderRadius"]),b=dY(e),x=e.getModel("emphasis"),w=x.get("focus"),C=x.get("blurScope"),S=x.get("disabled"),_=u?[f.mapDimension("x"),f.mapDimension("y"),f.mapDimension("value")]:[f.mapDimension("time"),f.mapDimension("value")],k=n;k<i;k++){var M=void 0,T=f.getItemVisual(k,"style");
422if(u){var D=f.get(_[0],k),R=f.get(_[1],k);if(isNaN(f.get(_[2],k))||isNaN(D)||isNaN(R)||D<s[0]||D>s[1]||R<l[0]||R>l[1])continue;var I=d.dataToPoint([D,R]);M=new lN({shape:{x:I[0]-o/2,y:I[1]-a/2,width:o,height:a},style:T})}else{if(isNaN(f.get(_[1],k)))continue;M=new lN({z2:1,shape:d.dataToRect([f.get(_[0],k)]).contentShape,style:T})}if(f.hasItemOption){var A=f.getItemModel(k),P=A.getModel("emphasis");g=P.getModel("itemStyle").getItemStyle(),m=A.getModel(["blur","itemStyle"]).getItemStyle(),v=A.getModel(["select","itemStyle"]).getItemStyle(),y=A.get(["itemStyle","borderRadius"]),w=P.get("focus"),C=P.get("blurScope"),S=P.get("disabled"),b=dY(A)}M.shape.r=y;var E=e.getRawValue(k),L="-";E&&null!=E[2]&&(L=E[2]+""),dK(M,b,{labelFetcher:e,labelDataIndex:k,defaultOpacity:T.opacity,defaultText:L}),M.ensureState("emphasis").style=g,M.ensureState("blur").style=m,M.ensureState("select").style=v,dM(M,w,C,S),M.incremental=r,r&&(M.states.emphasis.hoverLayer=!0),p.add(M),f.setItemGraphicEl(k,M),this._progressiveEls&&this._progressiveEls.push(M)}},t.prototype._renderOnGeo=function(e,t,n,i){var r,o,a,s,l,d,u,c=n.targetVisuals.inRange,h=n.targetVisuals.outOfRange,p=t.getData(),f=this._hmLayer||this._hmLayer||new TE;f.blurSize=t.get("blurSize"),f.pointSize=t.get("pointSize"),f.minOpacity=t.get("minOpacity"),f.maxOpacity=t.get("maxOpacity");var g=e.getViewRect().clone(),m=e.getRoamTransform();g.applyTransform(m);var v=Math.max(g.x,0),y=Math.max(g.y,0),b=Math.min(g.width+g.x,i.getWidth()),x=Math.min(g.height+g.y,i.getHeight()),w=b-v,C=x-y,S=[p.mapDimension("lng"),p.mapDimension("lat"),p.mapDimension("value")],_=p.mapArray(S,function(t,n,i){var r=e.dataToPoint([t,n]);return r[0]-=v,r[1]-=y,r.push(i),r}),k=n.getExtent(),M="visualMap.continuous"===n.type?(r=n.option.range,o=k[1]-k[0],r=[(r[0]-k[0])/o,(r[1]-k[0])/o],function(e){return e>=r[0]&&e<=r[1]}):(a=n.getPieceList(),s=n.option.selected,l=k[1]-k[0],d=(a=nC(a,function(e){return{interval:[(e.interval[0]-k[0])/l,(e.interval[1]-k[0])/l]}})).length,u=0,function(e){var t;for(t=u;t<d;t++){var n=a[t].interval;if(n[0]<=e&&e<=n[1]){u=t;break}}if(t===d)for(t=u-1;t>=0;t--){var n=a[t].interval;if(n[0]<=e&&e<=n[1]){u=t;break}}return t>=0&&t<d&&s[t]});f.update(_,w,C,c.color.getNormalizer(),{inRange:c.color.getColorMapper(),outOfRange:h.color.getColorMapper()},M);var T=new lI({style:{width:w,height:C,x:v,y:y,image:f.canvas},silent:!0});this.group.add(T)},t.type="heatmap",t}(fI),TO=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){return ya(null,this,{generateCoord:"value"})},t.prototype.preventIncremental=function(){var e=cI.get(this.get("coordinateSystem"));if(e&&e.dimensions)return"lng"===e.dimensions[0]&&"lat"===e.dimensions[1]},t.type="series.heatmap",t.dependencies=["grid","geo","calendar"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:"#212121"}}},t}(h1),TN=["itemStyle","borderWidth"],TB=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],Tz=new wN.Circle,Tj=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=this.group,r=e.getData(),o=this._data,a=e.coordinateSystem,s=a.getBaseAxis().isHorizontal(),l=a.master.getRect(),d={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:e,coordSys:a,coordSysExtent:[[l.x,l.x+l.width],[l.y,l.y+l.height]],isHorizontal:s,valueDim:TB[+s],categoryDim:TB[1-s]};r.diff(o).add(function(e){if(r.hasValue(e)){var t=TK(r,e),n=TV(r,e,t,d),o=TX(r,d,n);r.setItemGraphicEl(e,o),i.add(o),T2(o,d,n)}}).update(function(e,t){var n,a,s,l,u,c,h=o.getItemGraphicEl(t);if(!r.hasValue(e))return void i.remove(h);var p=TK(r,e),f=TV(r,e,p,d),g=TQ(r,f);h&&g!==h.__pictorialShapeStr&&(i.remove(h),r.setItemGraphicEl(e,null),h=null),h?(n=h,a=d,l=(s=f).animationModel,u=s.dataIndex,c=n.__pictorialBundle,wN.updateProps(c,{x:s.bundlePosition[0],y:s.bundlePosition[1]},l,u),s.symbolRepeat?TW(n,a,s,!0):T$(n,a,s,!0),TU(n,s,!0),Tq(n,a,s,!0)):h=TX(r,d,f,!0),r.setItemGraphicEl(e,h),h.__pictorialSymbolMeta=f,i.add(h),T2(h,d,f)}
422).remove(function(e){var t=o.getItemGraphicEl(e);t&&TJ(o,e,t.__pictorialSymbolMeta.animationModel,t)}).execute();var u=e.get("clip",!0)?yA(e.coordinateSystem,!1,e):null;return u?i.setClipPath(u):i.removeClipPath(),this._data=r,this.group},t.prototype.remove=function(e,t){var n=this.group,i=this._data;e.get("animation")?i&&i.eachItemGraphicEl(function(t){TJ(i,lQ(t).dataIndex,e,t)}):n.removeAll()},t.type="pictorialBar",t}(fI);function TV(e,t,n,i){var r,o,a,s,l,d,u,c,h,p,f,g,m,v,y,b,x,w,C,S,_,k=e.getItemLayout(t),M=n.get("symbolRepeat"),T=n.get("symbolClip"),D=n.get("symbolPosition")||"start",R=(n.get("symbolRotate")||0)*Math.PI/180||0,I=n.get("symbolPatternSize")||2,A=n.isAnimationEnabled(),P={dataIndex:t,layout:k,itemModel:n,symbolType:e.getItemVisual(t,"symbol")||"circle",style:e.getItemVisual(t,"style"),symbolClip:T,symbolRepeat:M,symbolRepeatDirection:n.get("symbolRepeatDirection"),symbolPatternSize:I,rotation:R,animationModel:A?n:null,hoverScale:A&&n.get(["emphasis","scale"]),z2:n.getShallow("z",!0)||0};(function(e,t,n,i,r){var o,a=i.valueDim,s=e.get("symbolBoundingData"),l=i.coordSys.getOtherAxis(i.coordSys.getBaseAxis()),d=l.toGlobalCoord(l.dataToCoord(0)),u=1-(n[a.wh]<=0);if(nR(s)){var c=[TH(l,s[0])-d,TH(l,s[1])-d];c[1]<c[0]&&c.reverse(),o=c[u]}else o=null!=s?TH(l,s)-d:t?i.coordSysExtent[a.index][u]-d:n[a.wh];r.boundingLength=o,t&&(r.repeatCutLength=n[a.wh]);var h="x"===a.xy,p=l.inverse;r.pxSign=h&&!p||!h&&p?o>=0?1:-1:o>0?1:-1})(n,M,k,i,P),r=e,o=t,a=k,s=M,l=P.boundingLength,d=P.pxSign,u=I,c=i,h=P,f=c.valueDim,m=Math.abs(a[(g=c.categoryDim).wh]),(p=nR(v=r.getItemVisual(o,"symbolSize"))?v.slice():null==v?["100%","100%"]:[v,v])[g.index]=aR(p[g.index],m),p[f.index]=aR(p[f.index],s?m:Math.abs(l)),h.symbolSize=p,y=h.symbolScale=[p[0]/u,p[1]/u],y[f.index]*=(c.isHorizontal?-1:1)*d,b=n,x=P.symbolScale,w=R,C=i,S=P,(_=b.get(TN)||0)&&(Tz.attr({scaleX:x[0],scaleY:x[1],rotation:w}),Tz.updateTransform(),_/=Tz.getLineScale(),_*=x[C.valueDim.index]),S.valueLineWidth=_||0;var E=P.symbolSize,L=gM(n.get("symbolOffset"),E);return function(e,t,n,i,r,o,a,s,l,d,u,c){var h=u.categoryDim,p=u.valueDim,f=c.pxSign,g=Math.max(t[p.index]+s,0),m=g;if(i){var v=Math.abs(l),y=nH(e.get("symbolMargin"),"15%")+"",b=!1;y.lastIndexOf("!")===y.length-1&&(b=!0,y=y.slice(0,y.length-1));var x=aR(y,t[p.index]),w=Math.max(g+2*x,0),C=b?0:2*x,S=aq(i),_=S?i:T3((v+C)/w);x=(v-_*g)/2/(b?_:Math.max(_-1,1)),w=g+2*x,C=b?0:2*x,S||"fixed"===i||(_=d?T3((Math.abs(d)+C)/w):0),m=_*w-C,c.repeatTimes=_,c.symbolMargin=x}var k=m/2*f,M=c.pathPosition=[];M[h.index]=n[h.wh]/2,M[p.index]="start"===a?k:"end"===a?l-k:l/2,o&&(M[0]+=o[0],M[1]+=o[1]);var T=c.bundlePosition=[];T[h.index]=n[h.xy],T[p.index]=n[p.xy];var D=c.barRectShape=nf({},n);D[p.wh]=f*Math.max(Math.abs(n[p.wh]),Math.abs(M[p.index]+k)),D[h.wh]=n[h.wh];var R=c.clipShape={};R[h.xy]=-n[h.xy],R[h.wh]=u.ecSize[h.wh],R[p.xy]=0,R[p.wh]=n[p.wh]}(n,E,k,M,0,L,D,P.valueLineWidth,P.boundingLength,P.repeatCutLength,i,P),P}function TH(e,t){return e.toGlobalCoord(e.dataToCoord(e.scale.parse(t)))}function TG(e){var t=e.symbolPatternSize,n=g_(e.symbolType,-t/2,-t/2,t,t);return n.attr({culling:!0}),"image"!==n.type&&n.setStyle({strokeNoScale:!0}),n}function TW(e,t,n,i){var r=e.__pictorialBundle,o=n.symbolSize,a=n.valueLineWidth,s=n.pathPosition,l=t.valueDim,d=n.repeatTimes||0,u=0,c=o[t.valueDim.index]+a+2*n.symbolMargin;for(T0(e,function(e){e.__pictorialAnimationIndex=u,e.__pictorialRepeatTimes=d,u<d?T1(e,null,f(u),n,i):T1(e,null,{scaleX:0,scaleY:0},n,i,function(){r.remove(e)}),u++});u<d;u++){var h=TG(n);h.__pictorialAnimationIndex=u,h.__pictorialRepeatTimes=d,r.add(h);var p=f(u);T1(h,{x:p.x,y:p.y,scaleX:0,scaleY:0},{scaleX:p.scaleX,scaleY:p.scaleY,rotation:p.rotation},n,i)}function f(e){var t=s.slice(),i=n.pxSign,r=e;return("start"===n.symbolRepeatDirection?i>0:i<0)&&(r=d-1-e),t[l.index]=c*(r-d/2+.5)+s[l.index],{x:t[0],y:t[1],scaleX:n.symbolScale[0],scaleY:n.symbolScale[1],rotation:n.rotation}}}function T$(e,t,n,i){var r=e.__pictorialBundle,o=e.__pictorialMainPath;o?T1(o,null,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:n.symbolScale[0],scaleY:n.symbolScale[1],rotation:n.rotation},n,i):(o=e.__pictorialMainPath=TG(n),r.add(o),T1(o,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:0,scaleY:0,rotation:n.rotation},{scaleX:n.symbolScale[0],scaleY:n.symbolScale[1]},n,i))}
422function TU(e,t,n){var i=nf({},t.barRectShape),r=e.__pictorialBarRect;r?T1(r,null,{shape:i},t,n):((r=e.__pictorialBarRect=new wN.Rect({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}})).disableMorphing=!0,e.add(r))}function Tq(e,t,n,i){if(n.symbolClip){var r=e.__pictorialClipPath,o=nf({},n.clipShape),a=t.valueDim,s=n.animationModel,l=n.dataIndex;if(r)wN.updateProps(r,{shape:o},s,l);else{o[a.wh]=0,r=new wN.Rect({shape:o}),e.__pictorialBundle.setClipPath(r),e.__pictorialClipPath=r;var d={};d[a.wh]=n.clipShape[a.wh],wN[i?"updateProps":"initProps"](r,{shape:d},s,l)}}}function TK(e,t){var n=e.getItemModel(t);return n.getAnimationDelayParams=TY,n.isAnimationEnabled=TZ,n}function TY(e){return{index:e.__pictorialAnimationIndex,count:e.__pictorialRepeatTimes}}function TZ(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function TX(e,t,n,i){var r=new wN.Group,o=new wN.Group;return r.add(o),r.__pictorialBundle=o,o.x=n.bundlePosition[0],o.y=n.bundlePosition[1],n.symbolRepeat?TW(r,t,n):T$(r,t,n),TU(r,n,i),Tq(r,t,n,i),r.__pictorialShapeStr=TQ(e,n),r.__pictorialSymbolMeta=n,r}function TJ(e,t,n,i){var r=i.__pictorialBarRect;r&&r.removeTextContent();var o=[];T0(i,function(e){o.push(e)}),i.__pictorialMainPath&&o.push(i.__pictorialMainPath),i.__pictorialClipPath&&(n=null),nw(o,function(e){wN.removeElement(e,{scaleX:0,scaleY:0},n,t,function(){i.parent&&i.parent.remove(i)})}),e.setItemGraphicEl(t,null)}function TQ(e,t){return[e.getItemVisual(t.dataIndex,"symbol")||"none",!!t.symbolRepeat,!!t.symbolClip].join(":")}function T0(e,t,n){nw(e.__pictorialBundle.children(),function(i){i!==e.__pictorialBarRect&&t.call(n,i)})}function T1(e,t,n,i,r,o){t&&e.attr(t),i.symbolClip&&!r?n&&e.attr(n):n&&wN[r?"updateProps":"initProps"](e,n,i.animationModel,i.dataIndex,o)}function T2(e,t,n){var i=n.dataIndex,r=n.itemModel,o=r.getModel("emphasis"),a=o.getModel("itemStyle").getItemStyle(),s=r.getModel(["blur","itemStyle"]).getItemStyle(),l=r.getModel(["select","itemStyle"]).getItemStyle(),d=r.getShallow("cursor"),u=o.get("focus"),c=o.get("blurScope"),h=o.get("scale");T0(e,function(e){if(e instanceof lI){var t=e.style;e.useStyle(nf({image:t.image,x:t.x,y:t.y,width:t.width,height:t.height},n.style))}else e.useStyle(n.style);var i=e.ensureState("emphasis");i.style=a,h&&(i.scaleX=1.1*e.scaleX,i.scaleY=1.1*e.scaleY),e.ensureState("blur").style=s,e.ensureState("select").style=l,d&&(e.cursor=d),e.z2=n.z2});var p=t.valueDim.posDesc[+(n.boundingLength>0)],f=e.__pictorialBarRect;f.ignoreClip=!0,dK(f,dY(r),{labelFetcher:t.seriesModel,labelDataIndex:i,defaultText:yl(t.seriesModel.getData(),i),inheritColor:n.style.fill,defaultOpacity:n.style.opacity,defaultOutsidePosition:p}),dM(e,u,c,o.get("disabled"))}function T3(e){var t=Math.round(e);return 1e-4>Math.abs(e-t)?t:Math.ceil(e)}var T5=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n.defaultSymbol="roundRect",n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(t){return t.stack=null,e.prototype.getInitialData.apply(this,arguments)},t.type="series.pictorialBar",t.dependencies=["grid"],t.defaultOption=ud(y2.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",clip:!1,progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),t}(y2),T4=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._layers=[],n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=e.getData(),r=this,o=this.group,a=e.getLayerSeries(),s=i.getLayout("layoutInfo"),l=s.rect,d=s.boundaryGap;function u(e){return e.name}o.x=0,o.y=l.y+d[0];var c=new vU(this._layersSeries||[],a,u,u),h=[];function p(t,n,s){var l,d,u=r._layers;if("remove"===t)return void o.remove(u[n]);for(var c=[],p=[],f=a[n].indices,g=0;g<f.length;
vendor: 5,352 bytes, line 422
422g++){var m=i.getItemLayout(f[g]),v=m.x,y=m.y0,b=m.y;c.push(v,y),p.push(v,y+b),l=i.getItemVisual(f[g],"style")}var x=i.getItemLayout(f[0]),w=e.getModel("label").get("margin"),C=e.getModel("emphasis");if("add"===t){var S,_,k,M,T=h[n]=new av;d=new yD({shape:{points:c,stackedOnPoints:p,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),T.add(d),o.add(T),e.isAnimationEnabled()&&d.setClipPath((S=d.getBoundingRect(),_=e,k=function(){d.removeClipPath()},dz(M=new lN({shape:{x:S.x-10,y:S.y-10,width:0,height:S.height+20}}),{shape:{x:S.x-50,width:S.width+100,height:S.height+20}},_,k),M))}else{var T=u[s];d=T.childAt(0),o.add(T),h[n]=T,dB(d,{shape:{points:c,stackedOnPoints:p}},e),dW(d)}dK(d,dY(e),{labelDataIndex:f[g-1],defaultText:i.getName(f[g-1]),inheritColor:l.fill},{normal:{verticalAlign:"middle"}}),d.setTextConfig({position:null,local:!0});var D=d.getTextContent();D&&(D.x=x.x-w,D.y=x.y0+x.y/2),d.useStyle(l),i.setItemGraphicEl(n,d),dI(d,e),dM(d,C.get("focus"),C.get("blurScope"),C.get("disabled"))}c.add(nT(p,this,"add")).update(nT(p,this,"update")).remove(nT(p,this,"remove")).execute(),this._layersSeries=a,this._layers=h},t.type="themeRiver",t}(fI),T6=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t){e.prototype.init.apply(this,arguments),this.legendVisualProvider=new b0(nT(this.getData,this),nT(this.getRawData,this))},t.prototype.fixData=function(e){var t=e.length,n={},i=ss(e,function(e){return n.hasOwnProperty(e[0]+"")||(n[e[0]+""]=-1),e[2]}),r=[];i.buckets.each(function(e,t){r.push({name:t,dataList:e})});for(var o=r.length,a=0;a<o;++a){for(var s=r[a].name,l=0;l<r[a].dataList.length;++l){var d=r[a].dataList[l][0]+"";n[d]=a}for(var d in n)n.hasOwnProperty(d)&&n[d]!==a&&(n[d]=a,e[t]=[d,0,s],t++)}return e},t.prototype.getInitialData=function(e,t){for(var n=this.getReferringComponents("singleAxis",si).models[0].get("type"),i=n_(e.data,function(e){return void 0!==e[2]}),r=this.fixData(i||[]),o=[],a=this.nameMap=n1(),s=0,l=0;l<r.length;++l)o.push(r[l][2]),!a.get(r[l][2])&&(a.set(r[l][2],s),s++);var d=new v8(v9(r,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:vY(n)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,this);return d.initData(r),d},t.prototype.getLayerSeries=function(){for(var e=this.getData(),t=e.count(),n=[],i=0;i<t;++i)n[i]=i;var r=e.mapDimension("single"),o=ss(n,function(t){return e.get("name",t)}),a=[];return o.buckets.each(function(t,n){t.sort(function(t,n){return e.get(r,t)-e.get(r,n)}),a.push({name:n,indices:t})}),a},t.prototype.getAxisTooltipData=function(e,t,n){nR(e)||(e=e?[e]:[]);for(var i,r=this.getData(),o=this.getLayerSeries(),a=[],s=o.length,l=0;l<s;++l){for(var d=Number.MAX_VALUE,u=-1,c=o[l].indices.length,h=0;h<c;++h){var p=r.get(e[0],o[l].indices[h]),f=Math.abs(p-t);f<=d&&(i=p,d=f,u=o[l].indices[h])}a.push(u)}return{dataIndices:a,nestestValue:i}},t.prototype.formatTooltip=function(e,t,n){var i=this.getData();return hV("nameValue",{name:i.getName(e),value:i.get(i.mapDimension("value"),e)})},t.type="series.themeRiver",t.dependencies=["singleAxis"],t.defaultOption={z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}},t}(h1);function T8(e,t){e.eachSeriesByType("themeRiver",function(e){var t=e.getData(),n=e.coordinateSystem,i={},r=n.getRect();i.rect=r;var o=e.get("boundaryGap"),a=n.getAxis();i.boundaryGap=o,"horizontal"===a.orient?(o[0]=aR(o[0],r.height),o[1]=aR(o[1],r.height),T7(t,e,r.height-o[0]-o[1])):(o[0]=aR(o[0],r.width),o[1]=aR(o[1],r.width),T7(t,e,r.width-o[0]-o[1])),t.setLayout("layoutInfo",i)})}function T7(e,t,n){if(e.count())for(var i,r=t.coordinateSystem,o=t.getLayerSeries(),a=e.mapDimension("single"),s=e.mapDimension("value"),l=nC(o,function(t){return nC(t.indices,function(t){var n=r.dataToPoint(e.get(a,t));return n[1]=e.get(s,t),n})}),d=function(e){for(var t=e.length,n=e[0].length,i=[],r=[],o=0,a=0;a<n;++a){for(var s=0,l=0;l<t;++l)s+=e[l][a][1];s>o&&(o=s),i.push(s)}for(var d=0;d<n;++d)r[d]=(o-i[d])/2;o=0;for(var u=0;u<n;++u){var c=i[u]+r[u];c>o&&(o=c)}return{y0:r,max:o}}(l),u=d.y0,c=n/d.max,h=o.length,p=o[0].indices.length,f=0;f<p;++f){i=u[f]*c,e.setItemLayout(o[0].indices[f],{layerIndex:0,x:l[0][f][0],y0:i,y:l[0][f][1]*c});for(var g=1;g<h;++g)i+=l[g-1][f][1]*c,e.setItemLayout(o[g].indices[f],{layerIndex:g,x:l[g][f][0],y0:i,y:l[g][f][1]*c})}}var T9=function(e){function t(t,n,i,r){var o=e.call(this)||this;o.z2=2,o.textConfig={inside:!0},lQ(o).seriesIndex=n.seriesIndex;var a=new lj({z2:4,silent:t.getModel().get(["label","silent"])});return o.setTextContent(a),o.updateData(!0,t,n,i,r),o}return(0,tQ.__extends)(t,e),t.prototype.updateData=function(e,t,n,i,r){this.node=t,t.piece=this,n=n||this._seriesModel,i=i||this._ecModel;var o=this;lQ(o).dataIndex=t.dataIndex;var a=t.getModel(),s=a.getModel("emphasis"),l=t.getLayout(),d=nf({},l);d.label=null;var u=t.getVisual("style");u.lineJoin="bevel";var c=t.getVisual("decal");c&&(u.decal=gX(c,r));var h=y7(a.getModel("itemStyle"),d,!0);nf(d,h),nw(l4,function(e){var t=o.ensureState(e),n=a.getModel([e,"itemStyle"]);t.style=n.getItemStyle();var i=y7(n,d);i&&(t.shape=i)}
422),e?(o.setShape(d),o.shape.r=l.r0,dz(o,{shape:{r:l.r}},n,t.dataIndex)):(dB(o,{shape:d},n),dW(o)),o.useStyle(u),this._updateLabel(n);var p=a.getShallow("cursor");p&&o.attr("cursor",p),this._seriesModel=n||this._seriesModel,this._ecModel=i||this._ecModel;var f=s.get("focus");dM(this,"relative"===f?n2(t.getAncestorsIndices(),t.getDescendantIndices()):"ancestor"===f?t.getAncestorsIndices():"descendant"===f?t.getDescendantIndices():f,s.get("blurScope"),s.get("disabled"))},t.prototype._updateLabel=function(e){var t=this,n=this.node.getModel(),i=n.getModel("label"),r=this.node.getLayout(),o=r.endAngle-r.startAngle,a=(r.startAngle+r.endAngle)/2,s=Math.cos(a),l=Math.sin(a),d=this,u=d.getTextContent(),c=this.node.dataIndex,h=i.get("minAngle")/180*Math.PI;function p(e,t){var n=e.get(t);return null==n?i.get(t):n}u.ignore=!(i.get("show")&&!(null!=h&&Math.abs(o)<h)),nw(l6,function(i){var h,f="normal"===i?n.getModel("label"):n.getModel([i,"label"]),g="normal"===i,m=g?u:u.ensureState(i),v=e.getFormattedLabel(c,i);g&&(v=v||t.node.name),m.style=dZ(f,{},null,"normal"!==i,!0),v&&(m.style.text=v);var y=f.get("show");null==y||g||(m.ignore=!y);var b=p(f,"position"),x=g?d:d.states[i],w=x.style.fill;x.textConfig={outsideFill:"inherit"===f.get("color")?w:null,inside:"outside"!==b};var C=p(f,"distance")||0,S=p(f,"align"),_=p(f,"rotate"),k=.5*Math.PI,M=1.5*Math.PI,T=lf("tangential"===_?Math.PI/2-a:a),D=T>k&&!aB(T-k)&&T<M;"outside"===b?(h=r.r+C,S=D?"right":"left"):S&&"center"!==S?"left"===S?(h=r.r0+C,S=D?"right":"left"):"right"===S&&(h=r.r-C,S=D?"left":"right"):(h=o===2*Math.PI&&0===r.r0?0:(r.r+r.r0)/2,S="center"),m.style.align=S,m.style.verticalAlign=p(f,"verticalAlign")||"middle",m.x=h*s+r.cx,m.y=h*l+r.cy;var R=0;"radial"===_?R=lf(-a)+(D?Math.PI:0):"tangential"===_?R=lf(Math.PI/2-a)+(D?Math.PI:0):nE(_)&&(R=_*Math.PI/180),m.rotation=lf(R)}),u.dirtyStyle()},t}(pO),De="sunburstRootToNode",Dt="sunburstHighlight",Dn=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){var r,o,a=this;this.seriesModel=e,this.api=n,this.ecModel=t;var s=e.getData(),l=s.tree.root,d=e.getViewRoot(),u=this.group,c=e.get("renderLabelForZeroData"),h=[];d.eachNode(function(e){h.push(e)}),function(i,r){function o(e){return e.getId()}function a(o,a){!function(i,r){if(c||!i||i.getValue()||(i=null),i!==l&&r!==l){if(r&&r.piece){var o;i?(r.piece.updateData(!1,i,e,t,n),s.setItemGraphicEl(i.dataIndex,r.piece)):(o=r)&&o.piece&&(u.remove(o.piece),o.piece=null)}else if(i){var a=new T9(i,e,t,n);u.add(a),s.setItemGraphicEl(i.dataIndex,a)}}}(null==o?null:i[o],null==a?null:r[a])}(0!==i.length||0!==r.length)&&new vU(r,i,o,o).add(a).update(a).remove(nD(a,null)).execute()}(h,this._oldChildren||[]),r=l,(o=d).depth>0?(a.virtualPiece?a.virtualPiece.updateData(!1,r,e,t,n):(a.virtualPiece=new T9(r,e,t,n),u.add(a.virtualPiece)),o.piece.off("click"),a.virtualPiece.on("click",function(e){a._rootToNode(o.parentNode)})):a.virtualPiece&&(u.remove(a.virtualPiece),a.virtualPiece=null),this._initEvents(),this._oldChildren=h},t.prototype._initEvents=function(){var e=this;this.group.off("click"),this.group.on("click",function(t){var n=!1;e.seriesModel.getViewRoot().eachNode(function(i){if(!n&&i.piece&&i.piece===t.target){var r=i.getModel().get("nodeClick");if("rootToNode"===r)e._rootToNode(i);else if("link"===r){var o=i.getModel(),a=o.get("link");a&&uq(a,o.get("target",!0)||"_blank")}n=!0}})})},t.prototype._rootToNode=function(e){e!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:De,from:this.uid,seriesId:this.seriesModel.id,targetNode:e})},t.prototype.containPoint=function(e,t){var n=t.getData().getItemLayout(0);if(n){var i=e[0]-n.cx,r=e[1]-n.cy,o=Math.sqrt(i*i+r*r);return o<=n.r&&o>=n.r0}},t.type="sunburst",t}(fI),Di=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.ignoreStyleOnData=!0,n}return(0,tQ.__extends)(t,e),t.prototype.getInitialData=function(e,t){var n={name:e.name,children:e.data};!function e(t){var n=0;nw(t.children,function(t){e(t);var i=t.value;nR(i)&&(i=i[0]),n+=i});var i=t.value;nR(i)&&(i=i[0]),(null==i||isNaN(i))&&(i=n),i<0&&(i=0),nR(t.value)?t.value[0]=i:t.value=i}(n);var i=this._levelModels=nC(e.levels||[],function(e){return new ua(e,this,t)},this),r=SN.createTree(n,this,function(e){e.wrapMethod("getItemModel",function(e,t){var n=i[r.getNodeByDataIndex(t).depth];return n&&(e.parentModel=n),e})});return r.data},t.prototype.optionUpdated=function(){this.resetViewRoot()},t.prototype.getDataParams=function(t){var n=e.prototype.getDataParams.apply(this,arguments);return n.treePathInfo=SV(this.getData().tree.getNodeByDataIndex(t),this),n},t.prototype.getLevelModel=function(e){return this._levelModels&&this._levelModels[e.depth]},t.prototype.getViewRoot=function(){return this._viewRoot},t.prototype.resetViewRoot=function(e){e?this._viewRoot=e:e=this._viewRoot;var t=this.getRawData().tree.root;e&&(e===t||t.contains(e))||(this._viewRoot=t)},t.prototype.enableAriaDecal=function(){Sq(this)},t.type="series.sunburst",t.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}}
vendor: 5,038 bytes, line 422
422,animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},t}(h1),Dr=Math.PI/180;function Do(e,t,n){t.eachSeriesByType(e,function(e){var t=e.get("center"),i=e.get("radius");nR(i)||(i=[0,i]),nR(t)||(t=[t,t]);var r=n.getWidth(),o=n.getHeight(),a=Math.min(r,o),s=aR(t[0],r),l=aR(t[1],o),d=aR(i[0],a/2),u=aR(i[1],a/2),c=-e.get("startAngle")*Dr,h=e.get("minAngle")*Dr,p=e.getData().tree.root,f=e.getViewRoot(),g=f.depth,m=e.get("sort");null!=m&&function e(t,n){var i=t.children||[];t.children=function(e,t){if(nI(t)){var n=nC(e,function(e,t){var n=e.getValue();return{params:{depth:e.depth,height:e.height,dataIndex:e.dataIndex,getValue:function(){return n}},index:t}});return n.sort(function(e,n){return t(e.params,n.params)}),nC(n,function(t){return e[t.index]})}var i="asc"===t;return e.sort(function(e,t){var n=(e.getValue()-t.getValue())*(i?1:-1);return 0===n?(e.dataIndex-t.dataIndex)*(i?-1:1):n})}(i,n),i.length&&nw(t.children,function(t){e(t,n)})}(f,m);var v=0;nw(f.children,function(e){!isNaN(e.getValue())&&v++});var y=f.getValue(),b=Math.PI/(y||v)*2,x=f.depth>0,w=(u-d)/(f.height-(x?-1:1)||1),C=e.get("clockwise"),S=e.get("stillShowZeroSum"),_=C?1:-1,k=function(t,n){if(t){var i=n;if(t!==p){var r=t.getValue(),o=0===y&&S?b:r*b;o<h&&(o=h),i=n+_*o;var u=t.depth-g-(x?-1:1),c=d+w*u,f=d+w*(u+1),m=e.getLevelModel(t);if(m){var v=m.get("r0",!0),M=m.get("r",!0),T=m.get("radius",!0);null!=T&&(v=T[0],M=T[1]),null!=v&&(c=aR(v,a/2)),null!=M&&(f=aR(M,a/2))}t.setLayout({angle:o,startAngle:n,endAngle:i,clockwise:C,cx:s,cy:l,r0:c,r:f})}if(t.children&&t.children.length){var D=0;nw(t.children,function(e){D+=k(e,n+D)})}return i-n}};if(x){var M=2*Math.PI;p.setLayout({angle:M,startAngle:c,endAngle:c+M,clockwise:C,cx:s,cy:l,r0:d,r:d+w})}k(f,c)})}function Da(e){var t={};e.eachSeriesByType("sunburst",function(e){var n=e.getData(),i=n.tree;i.eachNode(function(r){var o=r.getModel().getModel("itemStyle").getItemStyle();o.fill||(o.fill=function(e,n,i){for(var r=e;r&&r.depth>1;)r=r.parentNode;var o=n.getColorFromPalette(r.name||r.dataIndex+"",t);return e.depth>1&&nA(o)&&(o=r6(o,(e.depth-1)/(i-1)*.5)),o}(r,e,i.root.height)),nf(n.ensureUniqueItemVisual(r.dataIndex,"style"),o)})})}var Ds={color:"fill",borderColor:"stroke"},Dl={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},Dd=a9(),Du=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},t.prototype.getInitialData=function(e,t){return ya(null,this)},t.prototype.getDataParams=function(t,n,i){var r=e.prototype.getDataParams.call(this,t,n);return i&&(r.info=Dd(i).info),r},t.type="series.custom",t.dependencies=["grid","polar","geo","singleAxis","calendar"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},t}(h1);function Dc(e,t){return t=t||[0,0],nC(["x","y"],function(n,i){var r=this.getAxis(n),o=t[i],a=e[i]/2;return"category"===r.type?r.getBandWidth():Math.abs(r.dataToCoord(o-a)-r.dataToCoord(o+a))},this)}function Dh(e,t){return t=t||[0,0],nC([0,1],function(n){var i=t[n],r=e[n]/2,o=[],a=[];return o[n]=i-r,a[n]=i+r,o[1-n]=a[1-n]=t[1-n],Math.abs(this.dataToPoint(o)[n]-this.dataToPoint(a)[n])},this)}function Dp(e,t){var n=this.getAxis(),i=t instanceof Array?t[0]:t,r=(e instanceof Array?e[0]:e)/2;return"category"===n.type?n.getBandWidth():Math.abs(n.dataToCoord(i-r)-n.dataToCoord(i+r))}function Df(e,t){return t=t||[0,0],nC(["Radius","Angle"],function(n,i){var r=this["get"+n+"Axis"](),o=t[i],a=e[i]/2,s="category"===r.type?r.getBandWidth():Math.abs(r.dataToCoord(o-a)-r.dataToCoord(o+a));return"Angle"===n&&(s=s*Math.PI/180),s},this)}function Dg(e,t,n,i){return e&&(e.legacy||!1!==e.legacy&&!n&&!i&&"tspan"!==t&&("text"===t||n4(e,"text")))}function Dm(e,t,n){var i,r,o;if("text"===t)o=e;else{o={},n4(e,"text")&&(o.text=e.text),n4(e,"rich")&&(o.rich=e.rich),n4(e,"textFill")&&(o.fill=e.textFill),n4(e,"textStroke")&&(o.stroke=e.textStroke),n4(e,"fontFamily")&&(o.fontFamily=e.fontFamily),n4(e,"fontSize")&&(o.fontSize=e.fontSize),n4(e,"fontStyle")&&(o.fontStyle=e.fontStyle),n4(e,"fontWeight")&&(o.fontWeight=e.fontWeight),r={type:"text",style:o,silent:!0},i={};var a=n4(e,"textPosition");n?i.position=a?e.textPosition:"inside":a&&(i.position=e.textPosition),n4(e,"textPosition")&&(i.position=e.textPosition),n4(e,"textOffset")&&(i.offset=e.textOffset),n4(e,"textRotation")&&(i.rotation=e.textRotation),n4(e,"textDistance")&&(i.distance=e.textDistance)}return Dv(o,e),nw(o.rich,function(e){Dv(e,e)}),{textConfig:i,textContent:r}}function Dv(e,t){t&&(t.font=t.textFont||t.font,n4(t,"textStrokeWidth")&&(e.lineWidth=t.textStrokeWidth),n4(t,"textAlign")&&(e.align=t.textAlign),n4(t,"textVerticalAlign")&&(e.verticalAlign=t.textVerticalAlign),n4(t,"textLineHeight")&&(e.lineHeight=t.textLineHeight),n4(t,"textWidth")&&(e.width=t.textWidth),n4(t,"textHeight")&&(e.height=t.textHeight),n4(t,"textBackgroun
422dColor")&&(e.backgroundColor=t.textBackgroundColor),n4(t,"textPadding")&&(e.padding=t.textPadding),n4(t,"textBorderColor")&&(e.borderColor=t.textBorderColor),n4(t,"textBorderWidth")&&(e.borderWidth=t.textBorderWidth),n4(t,"textBorderRadius")&&(e.borderRadius=t.textBorderRadius),n4(t,"textBoxShadowColor")&&(e.shadowColor=t.textBoxShadowColor),n4(t,"textBoxShadowBlur")&&(e.shadowBlur=t.textBoxShadowBlur),n4(t,"textBoxShadowOffsetX")&&(e.shadowOffsetX=t.textBoxShadowOffsetX),n4(t,"textBoxShadowOffsetY")&&(e.shadowOffsetY=t.textBoxShadowOffsetY))}function Dy(e,t,n){e.textPosition=e.textPosition||n.position||"inside",null!=n.offset&&(e.textOffset=n.offset),null!=n.rotation&&(e.textRotation=n.rotation),null!=n.distance&&(e.textDistance=n.distance);var i=e.textPosition.indexOf("inside")>=0,r=e.fill||"#000";Db(e,t);var o=null==e.textFill;return i?o&&(e.textFill=n.insideFill||"#fff",!e.textStroke&&n.insideStroke&&(e.textStroke=n.insideStroke),e.textStroke||(e.textStroke=r),null==e.textStrokeWidth&&(e.textStrokeWidth=2)):(o&&(e.textFill=e.fill||n.outsideFill||"#000"),!e.textStroke&&n.outsideStroke&&(e.textStroke=n.outsideStroke)),e.text=t.text,e.rich=t.rich,nw(t.rich,function(e){Db(e,e)}),e}function Db(e,t){t&&(n4(t,"fill")&&(e.textFill=t.fill),n4(t,"stroke")&&(e.textStroke=t.fill),n4(t,"lineWidth")&&(e.textStrokeWidth=t.lineWidth),n4(t,"font")&&(e.font=t.font),n4(t,"fontStyle")&&(e.fontStyle=t.fontStyle),n4(t,"fontWeight")&&(e.fontWeight=t.fontWeight),n4(t,"fontSize")&&(e.fontSize=t.fontSize),n4(t,"fontFamily")&&(e.fontFamily=t.fontFamily),n4(t,"align")&&(e.textAlign=t.align),n4(t,"verticalAlign")&&(e.textVerticalAlign=t.verticalAlign),n4(t,"lineHeight")&&(e.textLineHeight=t.lineHeight),n4(t,"width")&&(e.textWidth=t.width),n4(t,"height")&&(e.textHeight=t.height),n4(t,"backgroundColor")&&(e.textBackgroundColor=t.backgroundColor),n4(t,"padding")&&(e.textPadding=t.padding),n4(t,"borderColor")&&(e.textBorderColor=t.borderColor),n4(t,"borderWidth")&&(e.textBorderWidth=t.borderWidth),n4(t,"borderRadius")&&(e.textBorderRadius=t.borderRadius),n4(t,"shadowColor")&&(e.textBoxShadowColor=t.shadowColor),n4(t,"shadowBlur")&&(e.textBoxShadowBlur=t.shadowBlur),n4(t,"shadowOffsetX")&&(e.textBoxShadowOffsetX=t.shadowOffsetX),n4(t,"shadowOffsetY")&&(e.textBoxShadowOffsetY=t.shadowOffsetY),n4(t,"textShadowColor")&&(e.textShadowColor=t.textShadowColor),n4(t,"textShadowBlur")&&(e.textShadowBlur=t.textShadowBlur),n4(t,"textShadowOffsetX")&&(e.textShadowOffsetX=t.textShadowOffsetX),n4(t,"textShadowOffsetY")&&(e.textShadowOffsetY=t.textShadowOffsetY))}var Dx={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},Dw=nM(Dx);nS(o7,function(e,t){return e[t]=1,e},{}),o7.join(", ");var DC=["","style","shape","extra"],DS=a9();function D_(e,t,n,i,r){var o=e+"Animation",a=dO(e,i,r)||{},s=DS(t).userDuring;return a.duration>0&&(a.during=s?nT(DA,{el:t,userDuring:s}):null,a.setToFinal=!0,a.scope=e),nf(a,n[o]),a}function Dk(e,t,n,i){var r,o,a=(i=i||{}).dataIndex,s=i.isInit,l=i.clearStyle,d=n.isAnimationEnabled(),u=DS(e),c=t.style;u.userDuring=t.during;var h={},p={};if(function(e,t,n){for(var i=0;i<Dw.length;i++){var r=Dw[i],o=Dx[r],a=t[r];a&&(n[o[0]]=a[0],n[o[1]]=a[1])}for(var i=0;i<o7.length;i++){var s=o7[i];null!=t[s]&&(n[s]=t[s])}}(0,t,p),DE("shape",t,p),DE("extra",t,p),!s&&d&&(function(e,t,n){for(var i=t.transition,r=DD(i)?o7:aJ(i||[]),o=0;o<r.length;o++){var a=r[o];if("style"!==a&&"shape"!==a&&"extra"!==a){var s=e[a];n[a]=s}}}(e,t,h),DP("shape",e,t,h),DP("extra",e,t,h),function(e,t,n,i){if(n){var r,o=e.style;if(o){var a=n.transition,s=t.transition;if(a&&!DD(a)){var l=aJ(a);r||(r=i.style={});for(var d=0;d<l.length;d++){var u=l[d],c=o[u];r[u]=c}}else if(e.getAnimationStyleProps&&(DD(s)||DD(a)||nv(s,"style")>=0)){var h=e.getAnimationStyleProps(),p=h?h.style:null;if(p){r||(r=i.style={});for(var f=nM(n),d=0;d<f.length;d++){var u=f[d];if(p[u]){var c=o[u];r[u]=c}}}}}}}(e,t,c,h)),p.style=c,function(e,t,n){var i=t.style;if(!e.isGroup&&i){if(n){e.useStyle({});for(var r=e.animators,o=0;o<r.length;o++){var a=r[o];"style"===a.targetName&&a.changeTarget(e.style)}
422}e.setStyle(i)}t&&(t.style=null,t&&e.attr(t),t.style=i)}(e,p,l),r=e,n4(o=t,"silent")&&(r.silent=o.silent),n4(o,"ignore")&&(r.ignore=o.ignore),r instanceof sV&&n4(o,"invisible")&&(r.invisible=o.invisible),r instanceof lk&&n4(o,"autoBatch")&&(r.autoBatch=o.autoBatch),d)if(s){var f={};nw(DC,function(e){var n=e?t[e]:t;n&&n.enterFrom&&(e&&(f[e]=f[e]||{}),nf(e?f[e]:f,n.enterFrom))});var g=D_("enter",e,t,n,a);g.duration>0&&e.animateFrom(f,g)}else{var m=e,v=t,y=a||0,b=n,x=h;if(x){var w=D_("update",m,v,b,y);w.duration>0&&m.animateFrom(x,w)}}DM(e,t),c?e.dirty():e.markRedraw()}function DM(e,t){for(var n=DS(e).leaveToProps,i=0;i<DC.length;i++){var r=DC[i],o=r?t[r]:t;o&&o.leaveTo&&(n||(n=DS(e).leaveToProps={}),r&&(n[r]=n[r]||{}),nf(r?n[r]:n,o.leaveTo))}}function DT(e,t,n,i){if(e){var r=e.parent,o=DS(e).leaveToProps;if(o){var a=D_("update",e,t,n,0);a.done=function(){r.remove(e),i&&i()},e.animateTo(o,a)}else r.remove(e),i&&i()}}function DD(e){return"all"===e}var DR={},DI={setTransform:function(e,t){return DR.el[e]=t,this},getTransform:function(e){return DR.el[e]},setShape:function(e,t){var n=DR.el;return(n.shape||(n.shape={}))[e]=t,n.dirtyShape&&n.dirtyShape(),this},getShape:function(e){var t=DR.el.shape;if(t)return t[e]},setStyle:function(e,t){var n=DR.el,i=n.style;return i&&(i[e]=t,n.dirtyStyle&&n.dirtyStyle()),this},getStyle:function(e){var t=DR.el.style;if(t)return t[e]},setExtra:function(e,t){return(DR.el.extra||(DR.el.extra={}))[e]=t,this},getExtra:function(e){var t=DR.el.extra;if(t)return t[e]}};function DA(){var e=this.el;if(e){var t=DS(e).userDuring,n=this.userDuring;if(t!==n){this.el=this.userDuring=null;return}DR.el=e,n(DI)}}function DP(e,t,n,i){var r,o=n[e];if(o){var a=t[e];if(a){var s=n.transition,l=o.transition;if(l)if(r||(r=i[e]={}),DD(l))nf(r,a);else for(var d=aJ(l),u=0;u<d.length;u++){var c=d[u],h=a[c];r[c]=h}else if(DD(s)||nv(s,e)>=0){r||(r=i[e]={});for(var p=nM(a),u=0;u<p.length;u++){var f,g,c=p[u],h=a[c];f=o[c],g=h,(nx(f)?f!==g:null!=f&&isFinite(f))&&(r[c]=h)}}}}}function DE(e,t,n){var i=t[e];if(i)for(var r=n[e]={},o=nM(i),a=0;a<o.length;a++){var s=o[a];r[s]=oD(i[s])}}var DL=a9(),DF=["percent","easing","shape","style","extra"];function DO(e){e.stopAnimation("keyframe"),e.attr(DL(e))}function DN(e,t,n){if(n.isAnimationEnabled()&&t){if(nR(t))return void nw(t,function(t){DN(e,t,n)});var i=t.keyframes,r=t.duration;if(n&&null==r){var o=dO("enter",n,0);r=o&&o.duration}if(i&&r){var a=DL(e);nw(DC,function(n){var o;n&&!e[n]||(i.sort(function(e,t){return e.percent-t.percent}),nw(i,function(i){var s=e.animators,l=n?i[n]:i;if(l){var d=nM(l);if(n||(d=n_(d,function(e){return 0>nv(DF,e)})),d.length){o||((o=e.animate(n,t.loop,!0)).scope="keyframe");for(var u=0;u<s.length;u++)s[u]!==o&&s[u].targetName===o.targetName&&s[u].stopTracks(d);n&&(a[n]=a[n]||{});var c=n?a[n]:a;nw(d,function(t){c[t]=((n?e[n]:e)||{})[t]}),o.whenWithKeys(r*i.percent,l,d,i.easing)}}}),o&&o.delay(t.delay||0).duration(r).start(t.easing))})}}}var DB="emphasis",Dz="normal",Dj="blur",DV="select",DH=[Dz,DB,Dj,DV],DG={normal:["itemStyle"],emphasis:[DB,"itemStyle"],blur:[Dj,"itemStyle"],select:[DV,"itemStyle"]},DW={normal:["label"],emphasis:[DB,"label"],blur:[Dj,"label"],select:[DV,"label"]},D$=["x","y"],DU={normal:{},emphasis:{},blur:{},select:{}},Dq={cartesian2d:function(e){var t=e.master.getRect();return{coordSys:{type:"cartesian2d",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(t){return e.dataToPoint(t)},size:nT(Dc,e)}}},geo:function(e){var t=e.getBoundingRect();return{coordSys:{type:"geo",x:t.x,y:t.y,width:t.width,height:t.height,zoom:e.getZoom()},api:{coord:function(t){return e.dataToPoint(t)},size:nT(Dh,e)}}},single:function(e){var t=e.getRect();return{coordSys:{type:"singleAxis",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(t){return e.dataToPoint(t)},size:nT(Dp,e)}}},polar:function(e){var t=e.getRadiusAxis(),n=e.getAngleAxis(),i=t.getExtent();return i[0]>i[1]&&i.reverse(),{coordSys:{type:"polar",cx:e.cx,cy:e.cy,r:i[1],r0:i[0]},api:{coord:function(i){var r=t.dataToRadius(i[0]),o=n.dataToAngle(i[1]),a=e.coordToPoint([r,o]);return a.push(r,o*Math.PI/180),a},size:nT(Df,e)}}},calendar:function(e){var t=e.getRect(),n=e.getRangeInfo();return{coordSys:{type:"calendar",x:t.x,y:t.y,width:t.width,height:t.height,cellWidth:e.getCellWidth(),cellHeight:e.getCellHeight(),rangeInfo:{start:n.start,end:n.end,weeks:n.weeks,dayCount:n.allDay}},api:{coord:function(t,n){return e.dataToPoint(t,n)}}}}};function DK(e){return e instanceof lk}function DY(e){return e instanceof sV}var DZ=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){this._progressiveEls=null;var r=this._data,o=e.getData(),a=this.group,s=D0(e,o,t,n);r||a.removeAll(),o.diff(r).add(function(t){D1(n,null,t,s(t,i),e,a,o)}).remove(function(t){var n=r.getItemGraphicEl(t);n&&DT(n,Dd(n).option,e)}).update(function(t,l){D1(n,r.getItemGraphicEl(l),t,s(t,i),e,a,o)}).execute();
422var l=e.get("clip",!0)?yA(e.coordinateSystem,!1,e):null;l?a.setClipPath(l):a.removeClipPath(),this._data=o},t.prototype.incrementalPrepareRender=function(e,t,n){this.group.removeAll(),this._data=null},t.prototype.incrementalRender=function(e,t,n,i,r){var o=t.getData(),a=D0(t,o,n,i),s=this._progressiveEls=[];function l(e){e.isGroup||(e.incremental=!0,e.ensureState("emphasis").hoverLayer=!0)}for(var d=e.start;d<e.end;d++){var u=D1(null,null,d,a(d,r),t,this.group,o);u&&(u.traverse(l),s.push(u))}},t.prototype.eachRendered=function(e){fT(this._progressiveEls||this.group,e)},t.prototype.filterForExposedEvent=function(e,t,n,i){var r=t.element;if(null==r||n.name===r)return!0;for(;(n=n.__hostTarget||n.parent)&&n!==this.group;)if(n.name===r)return!0;return!1},t.type="custom",t}(fI);function DX(e){var t,n=e.type;if("path"===n){var i=e.shape,r=null!=i.width&&null!=i.height?{x:i.x||0,y:i.y||0,width:i.width,height:i.height}:null,o=Re(i);Dd(t=fl(o,null,r,i.layout||"center")).customPathData=o}else if("image"===n)Dd(t=new lI({})).customImagePath=e.style.image;else if("text"===n)t=new lj({});else if("group"===n)t=new av;else if("compoundPath"===n)throw Error('"compoundPath" is not supported yet.');else{var a=fs(n);a||cw(""),t=new a}return Dd(t).customGraphicType=n,t.name=e.name,t.z2EmphasisLift=1,t.z2SelectLift=1,t}function DJ(e,t,n,i,r,o,a){DO(t);var s=r&&r.normal.cfg;s&&t.setTextConfig(s),i&&null==i.transition&&(i.transition=D$);var l=i&&i.style;if(l){"text"===t.type&&(n4(l,"textFill")&&(l.fill=l.textFill),n4(l,"textStroke")&&(l.stroke=l.textStroke));var d=void 0,u=DK(t)?l.decal:null;e&&u&&(u.dirty=!0,d=gX(u,e)),l.__decalPattern=d}if(DY(t)&&l){var d=l.__decalPattern;d&&(l.decal=d)}Dk(t,i,o,{dataIndex:n,isInit:a,clearStyle:!0}),DN(t,i.keyframeAnimation,o)}function DQ(e,t,n,i,r){var o=t.isGroup?null:t,a=r&&r[e].cfg;if(o){var s=o.ensureState(e);if(!1===i){var l=o.getState(e);l&&(l.style=null)}else s.style=i||null;a&&(s.textConfig=a),df(o)}}function D0(e,t,n,i){var r,o,a,s,l=e.get("renderItem"),d=e.coordinateSystem,u={};d&&(u=d.prepareCustoms?d.prepareCustoms(d):Dq[d.type](d));for(var c=ng({getWidth:i.getWidth,getHeight:i.getHeight,getZr:i.getZr,getDevicePixelRatio:i.getDevicePixelRatio,value:function(e,n){return null==n&&(n=a),t.getStore().get(t.getDimensionIndex(e||0),n)},style:function(n,i){null==i&&(i=a);var r=t.getItemVisual(i,"style"),o=r&&r.fill,s=r&&r.opacity,l=x(i,Dz).getItemStyle();null!=o&&(l.fill=o),null!=s&&(l.opacity=s);var d={inheritColor:nA(o)?o:"#000"},u=w(i,Dz),c=dZ(u,null,d,!1,!0);c.text=u.getShallow("show")?nG(e.getFormattedLabel(i,Dz),yl(t,i)):null;var h=dX(u,d,!1);return S(n,l),l=Dy(l,c,h),n&&C(l,n),l.legacy=!0,l}
422,ordinalRawValue:function(e,n){null==n&&(n=a),e=e||0;var i=t.getDimensionInfo(e);if(!i){var r=t.getDimensionIndex(e);return r>=0?t.getStore().get(r,n):void 0}var o=t.get(i.name,n),s=i&&i.ordinalMeta;return s?s.categories[o]:o},styleEmphasis:function(n,i){null==i&&(i=a);var r=x(i,DB).getItemStyle(),o=w(i,DB),s=dZ(o,null,null,!0,!0);s.text=o.getShallow("show")?nW(e.getFormattedLabel(i,DB),e.getFormattedLabel(i,Dz),yl(t,i)):null;var l=dX(o,null,!0);return S(n,r),r=Dy(r,s,l),n&&C(r,n),r.legacy=!0,r},visual:function(e,n){if(null==n&&(n=a),n4(Ds,e)){var i=t.getItemVisual(n,"style");return i?i[Ds[e]]:null}if(n4(Dl,e))return t.getItemVisual(n,e)},barLayout:function(e){if("cartesian2d"===d.type)return function(e){var t=[],n=e.axis,i="axis0";if("category"===n.type){for(var r=n.getBandWidth(),o=0;o<e.count||0;o++)t.push(ng({bandWidth:r,axisKey:i,stackId:yU+o},e));for(var a=yX(t),s=[],o=0;o<e.count;o++){var l=a[i][yU+o];l.offsetCenter=l.offset+l.width/2,s.push(l)}return s}}(ng({axis:d.getBaseAxis()},e))},currentSeriesIndices:function(){return n.getCurrentSeriesIndices()},font:function(e){return d2(e,n)}},u.api||{}),h={context:{},seriesId:e.id,seriesName:e.name,seriesIndex:e.seriesIndex,coordSys:u.coordSys,dataInsideLength:t.count(),encode:(r=e.getData(),o={},nw(r.dimensions,function(e){var t=r.getDimensionInfo(e);if(!t.isExtraCoord){var n=t.coordDim;(o[n]=o[n]||[])[t.coordDimIndex]=r.getDimensionIndex(e)}}),o)},p={},f={},g={},m={},v=0;v<DH.length;v++){var y=DH[v];g[y]=e.getModel(DG[y]),m[y]=e.getModel(DW[y])}function b(e){return e===a?s||(s=t.getItemModel(e)):t.getItemModel(e)}function x(e,n){return t.hasItemOption?e===a?p[n]||(p[n]=b(e).getModel(DG[n])):b(e).getModel(DG[n]):g[n]}function w(e,n){return t.hasItemOption?e===a?f[n]||(f[n]=b(e).getModel(DW[n])):b(e).getModel(DW[n]):m[n]}return function(e,n){return a=e,s=null,p={},f={},l&&l(ng({dataIndexInside:e,dataIndex:t.getRawIndex(e),actionType:n?n.type:null},h),c)};function C(e,t){for(var n in t)n4(t,n)&&(e[n]=t[n])}function S(e,t){e&&(e.textFill&&(t.textFill=e.textFill),e.textPosition&&(t.textPosition=e.textPosition))}}function D1(e,t,n,i,r,o,a){if(!i)return void o.remove(t);var s=D2(e,t,n,i,r,o);return s&&a.setItemGraphicEl(n,s),s&&dM(s,i.focus,i.blurScope,i.emphasisDisabled),s}function D2(e,t,n,i,r,o){var a,s=-1,l=t;t&&D3(t,i,r)&&(s=nv(o.childrenRef(),t),t=null);var d=!t,u=t;u?u.clearStates():(u=DX(i),l&&((a=u).copyTransform(l),DY(a)&&DY(l)&&(a.setStyle(l.style),a.z=l.z,a.z2=l.z2,a.zlevel=l.zlevel,a.invisible=l.invisible,a.ignore=l.ignore,DK(a)&&DK(l)&&a.setShape(l.shape)))),!1===i.morph?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),DU.normal.cfg=DU.normal.conOpt=DU.emphasis.cfg=DU.emphasis.conOpt=DU.blur.cfg=DU.blur.conOpt=DU.select.cfg=DU.select.conOpt=null,DU.isLegacy=!1,function(e,t,n,i,r,o){if(!e.isGroup){D5(n,null,o),D5(n,DB,o);var a=o.normal.conOpt,s=o.emphasis.conOpt,l=o.blur.conOpt,d=o.select.conOpt;if(null!=a||null!=s||null!=d||null!=l){var u=e.getTextContent();if(!1===a)u&&e.removeTextContent();else{a=o.normal.conOpt=a||{type:"text"},u?u.clearStates():(u=DX(a),e.setTextContent(u)),DJ(null,u,t,a,null,i,r);for(var c=a&&a.style,h=0;h<DH.length;h++){var p=DH[h];if(p!==Dz){var f=o[p].conOpt;DQ(p,u,f,D6(a,f,p),null)}}c?u.dirty():u.markRedraw()}}}}(u,n,i,r,d,DU),function(e,t,n,i,r){var o=n.clipPath;if(!1===o)e&&e.getClipPath()&&e.removeClipPath();else if(o){var a=e.getClipPath();a&&D3(a,o,i)&&(a=null),a||(a=DX(o),e.setClipPath(a)),DJ(null,a,t,o,null,i,r)}}(u,n,i,r,d),DJ(e,u,n,i,DU,r,d),n4(i,"info")&&(Dd(u).info=i.info);for(var c=0;c<DH.length;c++){var h=DH[c];if(h!==Dz){var p=D4(i,h),f=D6(i,p,h);DQ(h,u,p,f,DU)}}var g=u;if(!g.isGroup){var m=r.currentZ,v=r.currentZLevel;g.z=m,g.zlevel=v;var y=i.z2;null!=y&&(g.z2=y||0);for(var b=0;b<DH.length;b++)!function(e,t,n){var i=n===Dz,r=i?t:D4(t,n),o=r?r.z2:null;null!=o&&((i?e:e.ensureState(n)).z2=o||0)}(g,i,DH[b])}return"group"===i.type&&function(e,t,n,i,r){var o=i.children,a=o?o.length:0,s=i.$mergeChildren,l="byName"===s||i.diffChildrenByName,d=!1===s;if(a||l||d){if(l){return new vU((f={api:e,oldChildren:t.children()||[],newChildren:o||[],dataIndex:n,seriesModel:r,group:t}).oldChildren,f.newChildren,D8,D8,f).add(D7).update(D7).remove(D9).execute()}d&&t.removeAll();for(var u=0;u<a;u++){var c=o[u],h=t.childAt(u);c?(null==c.ignore&&(c.ignore=!1),D2(e,h,n,c,r,t)):h.ignore=!0}for(var p=t.childCount()-1;p>=u;p--){var f,g,m,v,y=t.childAt(p);g=t,m=y,v=r,m&&DT(m,Dd(g).option,v)}}}(e,u,n,i,r),s>=0?o.replaceAt(u,s):o.add(u),u}function D3(e,t,n){var i,r=Dd(e),o=t.type,a=t.shape,s=t.style;return n.isUniversalTransitionEnabled()||null!=o&&o!==r.customGraphicType||"path"===o&&(i=a)&&(n4(i,"pathData")||n4(i,"d"))&&Re(a)!==r.customPathData||"image"===o&&n4(s,"image")&&s.image!==r.customImagePath}function D5(e,t,n){var i=t?D4(e,t):e,r=t?D6(e,i,DB):e.style,o=e.type,a=i?i.textConfig:null,s=e.textContent,l=s?t?D4(s,t):s:null;if(r&&(n.isLegacy||Dg(r,o,!!a,!!l))){n.isLegacy=!0;
vendor: 4,483 bytes, line 422
422var d=Dm(r,o,!t);!a&&d.textConfig&&(a=d.textConfig),!l&&d.textContent&&(l=d.textContent)}if(!t&&l){var u=l;u.type||(u.type="text")}var c=t?n[t]:n.normal;c.cfg=a,c.conOpt=l}function D4(e,t){return t?e?e[t]:null:e}function D6(e,t,n){var i=t&&t.style;return null==i&&n===DB&&e&&(i=e.styleEmphasis),i}function D8(e,t){var n=e&&e.name;return null!=n?n:"e\0\0"+t}function D7(e,t){var n=this.context,i=null!=e?n.newChildren[e]:null,r=null!=t?n.oldChildren[t]:null;D2(n.api,r,n.dataIndex,i,n.seriesModel,n.group)}function D9(e){var t=this.context,n=t.oldChildren[e];n&&DT(n,Dd(n).option,t.seriesModel)}function Re(e){return e&&(e.pathData||e.d)}var Rt=a9(),Rn=function(){function e(){this._dragging=!1,this.animationThreshold=15}return e.prototype.render=function(e,t,n,i){var r=t.get("value"),o=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=n,i||this._lastValue!==r||this._lastStatus!==o){this._lastValue=r,this._lastStatus=o;var a=this._group,s=this._handle;if(!o||"hide"===o){a&&a.hide(),s&&s.hide();return}a&&a.show(),s&&s.show();var l={};this.makeElOption(l,r,e,t,n);var d=l.graphicKey;d!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=d;var u=this._moveAnimation=this.determineAnimation(e,t);if(a){var c=nD(Ri,t,u);this.updatePointerEl(a,l,c),this.updateLabelEl(a,l,c,t)}else a=this._group=new wN.Group,this.createPointerEl(a,l,e,t),this.createLabelEl(a,l,e,t),n.getZr().add(a);Ra(a,t,!0),this._renderHandle(r)}},e.prototype.remove=function(e){this.clear(e)},e.prototype.dispose=function(e){this.clear(e)},e.prototype.determineAnimation=function(e,t){var n=t.get("animation"),i=e.axis,r="category"===i.type,o=t.get("snap");if(!o&&!r)return!1;if("auto"===n||null==n){var a=this.animationThreshold;if(r&&i.getBandWidth()>a)return!0;if(o){var s=wm(e).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>a}return!1}return!0===n},e.prototype.makeElOption=function(e,t,n,i,r){},e.prototype.createPointerEl=function(e,t,n,i){var r=t.pointer;if(r){var o=Rt(e).pointerEl=new wN[r.type](nc(t.pointer));e.add(o)}},e.prototype.createLabelEl=function(e,t,n,i){if(t.label){var r=Rt(e).labelEl=new wN.Text(nc(t.label));e.add(r),Rr(r,i)}},e.prototype.updatePointerEl=function(e,t,n){var i=Rt(e).pointerEl;i&&t.pointer&&(i.setStyle(t.pointer.style),n(i,{shape:t.pointer.shape}))},e.prototype.updateLabelEl=function(e,t,n,i){var r=Rt(e).labelEl;r&&(r.setStyle(t.label.style),n(r,{x:t.label.x,y:t.label.y}),Rr(r,i))},e.prototype._renderHandle=function(e){if(!this._dragging&&this.updateHandleTransform){var t,n=this._axisPointerModel,i=this._api.getZr(),r=this._handle,o=n.getModel("handle"),a=n.get("status");if(!o.get("show")||!a||"hide"===a){r&&i.remove(r),this._handle=null;return}this._handle||(t=!0,r=this._handle=wN.createIcon(o.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(e){iH(e.event)},onmousedown:nT(this._onHandleDragMove,this,0,0),drift:nT(this._onHandleDragMove,this),ondragend:nT(this._onHandleDragEnd,this)}),i.add(r)),Ra(r,n,!1),r.setStyle(o.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var s=o.get("size");nR(s)||(s=[s,s]),r.scaleX=s[0]/2,r.scaleY=s[1]/2,fj(this,"_doDispatchAxisPointer",o.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,t)}},e.prototype._moveHandleToValue=function(e,t){Ri(this._axisPointerModel,!t&&this._moveAnimation,this._handle,Ro(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},e.prototype._onHandleDragMove=function(e,t){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(Ro(n),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(Ro(i)),Rt(n).lastProp=null,this._doDispatchAxisPointer()}},e.prototype._doDispatchAxisPointer=function(){if(this._handle){var e=this._payloadInfo,t=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:t.axis.dim,axisIndex:t.componentIndex}]})}},e.prototype._onHandleDragEnd=function(){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},e.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),n=this._group,i=this._handle;t&&n&&(this._lastGraphicKey=null,n&&t.remove(n),i&&t.remove(i),this._group=null,this._handle=null,this._payloadInfo=null),fV(this,"_doDispat
422chAxisPointer")},e.prototype.doClear=function(){},e.prototype.buildLabel=function(e,t,n){return{x:e[n=n||0],y:e[1-n],width:t[n],height:t[1-n]}},e}();function Ri(e,t,n,i){!function e(t,n){if(!(nL(t)&&nL(n)))return t===n;var i=!0;return nw(n,function(n,r){i=i&&e(t[r],n)}),!!i}(Rt(n).lastProp,i)&&(Rt(n).lastProp=i,t?wN.updateProps(n,i,e):(n.stopAnimation(),n.attr(i)))}function Rr(e,t){e[t.get(["label","show"])?"show":"hide"]()}function Ro(e){return{x:e.x||0,y:e.y||0,rotation:e.rotation||0}}function Ra(e,t,n){var i=t.get("z"),r=t.get("zlevel");e&&e.traverse(function(e){"group"!==e.type&&(null!=i&&(e.z=i),null!=r&&(e.zlevel=r),e.silent=n)})}function Rs(e){var t,n=e.get("type"),i=e.getModel(n+"Style");return"line"===n?(t=i.getLineStyle()).fill=null:"shadow"===n&&((t=i.getAreaStyle()).stroke=null),t}function Rl(e,t,n,i,r){var o,a,s,l,d,u,c=Rd(n.get("value"),t.axis,t.ecModel,n.get("seriesDataIndices"),{precision:n.get(["label","precision"]),formatter:n.get(["label","formatter"])}),h=n.getModel("label"),p=nU(h.get("padding")||0),f=h.getFont(),g=ai(c,f),m=r.position,v=g.width+p[1]+p[3],y=g.height+p[0]+p[2],b=r.align;"right"===b&&(m[0]-=v),"center"===b&&(m[0]-=v/2);var x=r.verticalAlign;"bottom"===x&&(m[1]-=y),"middle"===x&&(m[1]-=y/2),o=m,a=v,s=y,d=(l=i).getWidth(),u=l.getHeight(),o[0]=Math.min(o[0]+a,d)-a,o[1]=Math.min(o[1]+s,u)-s,o[0]=Math.max(o[0],0),o[1]=Math.max(o[1],0);var w=h.get("backgroundColor");w&&"auto"!==w||(w=t.get(["axisLine","lineStyle","color"])),e.label={x:m[0],y:m[1],style:dZ(h,{text:c,font:f,fill:h.getTextColor(),padding:p,backgroundColor:w}),z2:10}}function Rd(e,t,n,i,r){e=t.scale.parse(e);var o=t.scale.getLabel({value:e},{precision:r.precision}),a=r.formatter;if(a){var s={value:xG(t,{value:e}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};nw(i,function(e){var t=n.getSeriesByIndex(e.seriesIndex),i=e.dataIndexInside,r=t&&t.getDataParams(i);r&&s.seriesData.push(r)}),nA(a)?o=a.replace("{value}",o):nI(a)&&(o=a(s))}return o}function Ru(e,t,n){var i=iq();return iJ(i,i,n.rotation),iX(i,i,n.position),fv([e.dataToCoord(t),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function Rc(e,t,n,i,r,o){var a=wd.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get(["label","margin"]),Rl(t,i,r,o,{position:Ru(i.axis,e,n),align:a.textAlign,verticalAlign:a.textVerticalAlign})}function Rh(e,t,n){return{x1:e[n=n||0],y1:e[1-n],x2:t[n],y2:t[1-n]}}function Rp(e,t,n){return{x:e[n=n||0],y:e[1-n],width:t[n],height:t[1-n]}}function Rf(e,t,n,i,r,o){return{cx:e,cy:t,r0:n,r:i,startAngle:r,endAngle:o,clockwise:!0}}var Rg=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.makeElOption=function(e,t,n,i,r){var o=n.axis,a=o.grid,s=i.get("type"),l=Rm(a,o).getOtherAxis(o).getGlobalExtent(),d=o.toGlobalCoord(o.dataToCoord(t,!0));if(s&&"none"!==s){var u=Rs(i),c=Rv[s](o,d,l);c.style=u,e.graphicKey=c.type,e.pointer=c}Rc(t,e,x9(a.model,n),n,i,r)},t.prototype.getHandleTransform=function(e,t,n){var i=x9(t.axis.grid.model,t,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var r=Ru(t.axis,e,i);return{x:r[0],y:r[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(e,t,n,i){var r=n.axis,o=r.grid,a=r.getGlobalExtent(!0),s=Rm(o,r).getOtherAxis(r).getGlobalExtent(),l=+("x"!==r.dim),d=[e.x,e.y];d[l]+=t[l],d[l]=Math.min(a[1],d[l]),d[l]=Math.max(a[0],d[l]);var u=(s[1]+s[0])/2,c=[u,u];return c[l]=d[l],{x:d[0],y:d[1],rotation:e.rotation,cursorPoint:c,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][l]}},t}(Rn);function Rm(e,t){var n={};return n[t.dim+"AxisIndex"]=t.index,e.getCartesian(n)}var Rv={line:function(e,t,n){return{type:"Line",subPixelOptimize:!0,shape:Rh([t,n[0]],[t,n[1]],Ry(e))}},shadow:function(e,t,n){var i=Math.max(1,e.getBandWidth()),r=n[1]-n[0];return{type:"Rect",shape:Rp([t-i/2,n[0]],[i,r],Ry(e))}}};function Ry(e){return+("x"!==e.dim)}var Rb=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="axisPointer",t.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},t}(u5),Rx=a9();function Rw(e,t,n){if(!t1.node){var i=t.getZr();Rx(i).records||(Rx(i).records={}),function(e,t){Rx(e).initialized||(Rx(e).initialized=!0,n("click",nD(RS,"click")),n("mousemove",nD(RS,"mousemove")),n("globalout",RC));function n(n,i){e.on(n,function(n){var r,o,a,s,l,d,u,c,h=(r=t,o={showTip:[],hideTip:[]},{dispatchAction:a=function(e){var t=o[e.type];t?t.push(e):(e.dispatchAction=a,r.dispatchAction(e))},pendings:o});nw(Rx(e).records,function(e){e&&i(e,n,h.dispatchAction)}),s=h.pendings,l=t,u=s.showTip.length,c=s.hideTip.length,u?d=s.showTip[u-1]:c&&(d=s.hideTip[c-1]),d&&(
422d.dispatchAction=null,l.dispatchAction(d))})}}(i,t),(Rx(i).records[e]||(Rx(i).records[e]={})).handler=n}}function RC(e,t,n){e.handler("leave",null,n)}function RS(e,t,n,i){t.handler(e,n,i)}function R_(e,t){if(!t1.node){var n=t.getZr();(Rx(n).records||{})[e]&&(Rx(n).records[e]=null)}}var Rk=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=t.getComponent("tooltip"),r=e.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";Rw("axisPointer",n,function(e,t,n){"none"!==r&&("leave"===e||r.indexOf(e)>=0)&&n({type:"updateAxisPointer",currTrigger:e,x:t&&t.offsetX,y:t&&t.offsetY})})},t.prototype.remove=function(e,t){R_("axisPointer",t)},t.prototype.dispose=function(e,t){R_("axisPointer",t)},t.type="axisPointer",t}(h9);function RM(e,t){var n,i=[],r=e.seriesIndex;if(null==r||!(n=t.getSeriesByIndex(r)))return{point:[]};var o=n.getData(),a=a7(o,e);if(null==a||a<0||nR(a))return{point:[]};var s=o.getItemGraphicEl(a),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(a)||[];else if(l&&l.dataToPoint)if(e.isStacked){var d=l.getBaseAxis(),u=l.getOtherAxis(d).dim,c=d.dim,h=+("x"===u||"radius"===u),p=o.mapDimension(c),f=[];f[h]=o.get(p,a),f[1-h]=o.get(o.getCalculationInfo("stackResultDimension"),a),i=l.dataToPoint(f)||[]}else i=l.dataToPoint(o.getValues(nC(l.dimensions,function(e){return o.mapDimension(e)}),a))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),i=[g.x+g.width/2,g.y+g.height/2]}return{point:i,el:s}}var RT=a9();function RD(e,t,n){var i=e.currTrigger,r=[e.x,e.y],o=e.dispatchAction||nT(n.dispatchAction,n),a=t.getComponent("axisPointer").coordSysAxesInfo;if(a){RE(r)&&(r=RM({seriesIndex:e.seriesIndex,dataIndex:e.dataIndex},t).point);var s,l,d,u,c,h,p,f,g,m,v,y=RE(r),b=e.axesInfo,x=a.axesInfo,w="leave"===i||RE(r),C={},S={},_={list:[],map:{}},k={showPointer:nD(RI,S),showTooltip:nD(RA,_)};nw(a.coordSysMap,function(e,t){var n=y||e.containPoint(r);nw(a.coordSysAxesInfo[t],function(e,t){var i=e.axis,o=function(e,t){for(var n=0;n<(e||[]).length;n++){var i=e[n];if(t.axis.dim===i.axisDim&&t.axis.model.componentIndex===i.axisIndex)return i}}(b,e);if(!w&&n&&(!b||o)){var a=o&&o.value;null!=a||y||(a=i.pointToData(r)),null!=a&&RR(e,a,k,!1,C)}})});var M={};return nw(x,function(e,t){var n=e.linkGroup;n&&!S[t]&&nw(n.axesInfo,function(t,i){var r=S[i];if(t!==e&&r){var o=r.value;n.mapper&&(o=e.axis.scale.parse(n.mapper(o,RP(t),RP(e)))),M[e.key]=o}})}),nw(M,function(e,t){RR(x[t],e,k,!0,C)}),s=S,l=x,d=C.axesInfo=[],nw(l,function(e,t){var n=e.axisPointerModel.option,i=s[t];i?(e.useHandle||(n.status="show"),n.value=i.value,n.seriesDataIndices=(i.payloadBatch||[]).slice()):e.useHandle||(n.status="hide"),"show"===n.status&&d.push({axisDim:e.axis.dim,axisIndex:e.axis.model.componentIndex,value:n.value})}),function(e,t,n,i){if(RE(t)||!e.list.length)return i({type:"hideTip"});var r=((e.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:t[0],y:t[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:r.dataIndexInside,dataIndex:r.dataIndex,seriesIndex:r.seriesIndex,dataByCoordSys:e.list})}(_,r,e,o),u=x,h=(c=n).getZr(),p="axisPointerLastHighlights",f=RT(h)[p]||{},g=RT(h)[p]={},nw(u,function(e,t){var n=e.axisPointerModel.option;"show"===n.status&&e.triggerEmphasis&&nw(n.seriesDataIndices,function(e){g[e.seriesIndex+" | "+e.dataIndex]=e})}),m=[],v=[],nw(f,function(e,t){g[t]||v.push(e)}),nw(g,function(e,t){f[t]||m.push(e)}),v.length&&c.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:v}),m.length&&c.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:m}),C}}function RR(e,t,n,i,r){var o=e.axis;if(!o.scale.isBlank()&&o.containData(t)){if(!e.involveSeries)return void n.showPointer(e,t);var a,s,l,d,u,c,h,p,f=(a=t,d=(l=(s=e).axis).dim,u=a,c=[],h=Number.MAX_VALUE,p=-1,nw(s.seriesModels,function(e,t){var n,i,r=e.getData().mapDimensionsAll(d);if(e.getAxisTooltipData){var o=e.getAxisTooltipData(r,a,l);i=o.dataIndices,n=o.nestestValue}else{if(!(i=e.getData().indicesOfNearest(r[0],a,"category"===l.type?.5:null)).length)return;n=e.getData().get(r[0],i[0])}if(null!=n&&isFinite(n)){var s=a-n,f=Math.abs(s);f<=h&&((f<h||s>=0&&p<0)&&(h=f,p=s,u=n,c.length=0),nw(i,function(t){c.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}}),{payloadBatch:c,snapToValue:u}),g=f.payloadBatch,m=f.snapToValue;g[0]&&null==r.seriesIndex&&nf(r,g[0]),!i&&e.snap&&o.containData(m)&&null!=m&&(t=m),n.showPointer(e,t,g),n.showTooltip(e,f,m)}}
422function RI(e,t,n,i){e[t.key]={value:n,payloadBatch:i}}function RA(e,t,n,i){var r=n.payloadBatch,o=t.axis,a=o.model,s=t.axisPointerModel;if(t.triggerTooltip&&r.length){var l=t.coordSys.model,d=wy(l),u=e.map[d];u||(u=e.map[d]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},e.list.push(u)),u.dataByAxis.push({axisDim:o.dim,axisIndex:a.componentIndex,axisType:a.type,axisId:a.id,value:i,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:r.slice()})}}function RP(e){var t=e.axis.model,n={},i=n.axisDim=e.axis.dim;return n.axisIndex=n[i+"AxisIndex"]=t.componentIndex,n.axisName=n[i+"AxisName"]=t.name,n.axisId=n[i+"AxisId"]=t.id,n}function RE(e){return!e||null==e[0]||isNaN(e[0])||null==e[1]||isNaN(e[1])}function RL(e){ww.registerAxisPointerClass("CartesianAxisPointer",Rg),e.registerComponentModel(Rb),e.registerComponentView(Rk),e.registerPreprocessor(function(e){if(e){e.axisPointer&&0!==e.axisPointer.length||(e.axisPointer={});var t=e.axisPointer.link;t&&!nR(t)&&(e.axisPointer.link=[t])}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,function(e,t){var n,i,r,o,a,s,l,d,u;e.getComponent("axisPointer").coordSysAxesInfo=(i=n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}},r=e,o=t,a=r.getComponent("tooltip"),l=(s=r.getComponent("axisPointer")).get("link",!0)||[],d=[],nw(o.getCoordinateSystems(),function(e){if(e.axisPointerEnabled){var t=wy(e.model),n=i.coordSysAxesInfo[t]={};i.coordSysMap[t]=e;var o=e.model.getModel("tooltip",a);if(nw(e.getAxes(),nD(p,!1,null)),e.getTooltipAxes&&a&&o.get("show")){var u="axis"===o.get("trigger"),c="cross"===o.get(["axisPointer","type"]),h=e.getTooltipAxes(o.get(["axisPointer","axis"]));(u||c)&&nw(h.baseAxes,nD(p,!c||"cross",u)),c&&nw(h.otherAxes,nD(p,"cross",!1))}}function p(t,a,u){var c=u.model.getModel("axisPointer",s),h=c.get("show");if(h&&("auto"!==h||t||wv(c))){null==a&&(a=c.get("triggerTooltip"));var p=(c=t?function(e,t,n,i,r,o){var a=t.getModel("axisPointer"),s={};nw(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(e){s[e]=nc(a.get(e))}),s.snap="category"!==e.type&&!!o,"cross"===a.get("type")&&(s.type="line");var l=s.label||(s.label={});if(null==l.show&&(l.show=!1),"cross"===r){var d=a.get(["label","show"]);if(l.show=null==d||d,!o){var u=s.lineStyle=a.get("crossStyle");u&&ng(l,u.textStyle)}}return e.model.getModel("axisPointer",new ua(s,n,i))}(u,o,s,r,t,a):c).get("snap"),f=c.get("triggerEmphasis"),g=wy(u.model),m=a||p||"category"===u.type,v=i.axesInfo[g]={key:g,axis:u,coordSys:e,axisPointerModel:c,triggerTooltip:a,triggerEmphasis:f,involveSeries:m,snap:p,useHandle:wv(c),seriesModels:[],linkGroup:null};n[g]=v,i.seriesInvolved=i.seriesInvolved||m;var y=function(e,t){for(var n=t.model,i=t.dim,r=0;r<e.length;r++){var o=e[r]||{};if(wg(o[i+"AxisId"],n.id)||wg(o[i+"AxisIndex"],n.componentIndex)||wg(o[i+"AxisName"],n.name))return r}}(l,u);if(null!=y){var b=d[y]||(d[y]={axesInfo:{}});b.axesInfo[g]=v,b.mapper=l[y].mapper,v.linkGroup=b}}}}),n.seriesInvolved&&(u=n,e.eachSeries(function(e){var t=e.coordinateSystem,n=e.get(["tooltip","trigger"],!0),i=e.get(["tooltip","show"],!0);t&&"none"!==n&&!1!==n&&"item"!==n&&!1!==i&&!1!==e.get(["axisPointer","show"],!0)&&nw(u.coordSysAxesInfo[wy(t.model)],function(n){var i=n.axis;t.getAxis(i.dim)===i&&(n.seriesModels.push(e),null==n.seriesDataCount&&(n.seriesDataCount=0),n.seriesDataCount+=e.getData().count())})})),n)}),e.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},RD)}var RF=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.makeElOption=function(e,t,n,i,r){var o=n.axis;"angle"===o.dim&&(this.animationThreshold=Math.PI/18);var a=o.polar,s=a.getOtherAxis(o).getExtent(),l=o.dataToCoord(t),d=i.get("type");if(d&&"none"!==d){var u=Rs(i),c=RO[d](o,a,l,s);c.style=u,e.graphicKey=c.type,e.pointer=c}var h=function(e,t,n,i,r){var o,a,s,l=t.axis,d=l.dataToCoord(e),u=i.getAngleAxis().getExtent()[0];u=u/180*Math.PI;var c=i.getRadiusAxis().getExtent();if("radius"===l.dim){var h=iq();iJ(h,h,u),iX(h,h,[i.cx,i.cy]),o=fv([d,-r],h);var p=t.getModel("axisLabel").get("rotate")||0,f=wd.innerTextLayout(u,p*Math.PI/180,-1);a=f.textAlign,s=f.textVerticalAlign}else{var g=c[1];o=i.coordToPoint([g+r,d]);var m=i.cx,v=i.cy;
422a=Math.abs(o[0]-m)/g<.3?"center":o[0]>m?"left":"right",s=Math.abs(o[1]-v)/g<.3?"middle":o[1]>v?"top":"bottom"}return{position:o,align:a,verticalAlign:s}}(t,n,0,a,i.get(["label","margin"]));Rl(e,n,i,r,h)},t}(Rn),RO={line:function(e,t,n,i){return"angle"===e.dim?{type:"Line",shape:Rh(t.coordToPoint([i[0],n]),t.coordToPoint([i[1],n]))}:{type:"Circle",shape:{cx:t.cx,cy:t.cy,r:n}}},shadow:function(e,t,n,i){var r=Math.max(1,e.getBandWidth()),o=Math.PI/180;return"angle"===e.dim?{type:"Sector",shape:Rf(t.cx,t.cy,i[0],i[1],(-n-r/2)*o,(-n+r/2)*o)}:{type:"Sector",shape:Rf(t.cx,t.cy,n-r/2,n+r/2,0,2*Math.PI)}}},RN=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.findAxisModel=function(e){var t;return this.ecModel.eachComponent(e,function(e){e.getCoordSysModel()===this&&(t=e)},this),t},t.type="polar",t.dependencies=["radiusAxis","angleAxis"],t.defaultOption={z:0,center:["50%","50%"],radius:"80%"},t}(u5),RB=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",si).models[0]},t.type="polarAxis",t}(u5);nb(RB,b9);var Rz=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="angleAxis",t}(RB),Rj=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="radiusAxis",t}(RB),RV=function(e){function t(t,n){return e.call(this,"radius",t,n)||this}return(0,tQ.__extends)(t,e),t.prototype.pointToData=function(e,t){return this.polar.pointToData(e,t)[+("radius"!==this.dim)]},t}(x6);RV.prototype.dataToRadius=x6.prototype.dataToCoord,RV.prototype.radiusToData=x6.prototype.coordToData;var RH=a9(),RG=function(e){function t(t,n){return e.call(this,"angle",t,n||[0,360])||this}return(0,tQ.__extends)(t,e),t.prototype.pointToData=function(e,t){return this.polar.pointToData(e,t)[+("radius"!==this.dim)]},t.prototype.calculateCategoryInterval=function(){var e=this.getLabelModel(),t=this.scale,n=t.getExtent(),i=t.count();if(n[1]-n[0]<1)return 0;var r=n[0],o=Math.abs(this.dataToCoord(r+1)-this.dataToCoord(r)),a=Math.max(ai(null==r?"":r+"",e.getFont(),"center","top").height,7)/o;isNaN(a)&&(a=1/0);var s=Math.max(0,Math.floor(a)),l=RH(this.model),d=l.lastAutoInterval,u=l.lastTickCount;return null!=d&&null!=u&&1>=Math.abs(d-s)&&1>=Math.abs(u-i)&&d>s?s=d:(l.lastTickCount=i,l.lastAutoInterval=s),s},t}(x6);RG.prototype.dataToAngle=x6.prototype.dataToCoord,RG.prototype.angleToData=x6.prototype.coordToData;var RW=["radius","angle"],R$=function(){function e(e){this.dimensions=RW,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new RV,this._angleAxis=new RG,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return e.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},e.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},e.prototype.getAxis=function(e){return this["_"+e+"Axis"]},e.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},e.prototype.getAxesByScale=function(e){var t=[],n=this._angleAxis,i=this._radiusAxis;return n.scale.type===e&&t.push(n),i.scale.type===e&&t.push(i),t},e.prototype.getAngleAxis=function(){return this._angleAxis},e.prototype.getRadiusAxis=function(){return this._radiusAxis},e.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},e.prototype.getTooltipAxes=function(e){var t=null!=e&&"auto"!==e?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},e.prototype.dataToPoint=function(e,t){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)])},e.prototype.pointToData=function(e,t){var n=this.pointToCoord(e);return[this._radiusAxis.radiusToData(n[0],t),this._angleAxis.angleToData(n[1],t)]},e.prototype.pointToCoord=function(e){var t=e[0]-this.cx,n=e[1]-this.cy,i=this.getAngleAxis(),r=i.getExtent(),o=Math.min(r[0],r[1]),a=Math.max(r[0],r[1]);i.inverse?o=a-360:a=o+360;var s=Math.sqrt(t*t+n*n);t/=s;for(var l=Math.atan2(-(n/=s),t)/Math.PI*180,d=l<o?1:-1;l<o||l>a;)l+=360*d;return[s,l]},e.prototype.coordToPoint=function(e){var t=e[0],n=e[1]/180*Math.PI;return[Math.cos(n)*t+this.cx,-Math.sin(n)*t+this.cy]},e.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis().getExtent().slice();t[0]>t[1]&&t.reverse();var n=e.getExtent(),i=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:t[0],r:t[1],startAngle:-n[0]*i,endAngle:-n[1]*i,clockwise:e.inverse,contain:function(e,t){var n=e-this.cx,i=t-this.cy,r=n*n+i*i,o=this.r,a=this.r0;return o!==a&&r-1e-4<=o*o&&r+1e-4>=a*a}}},e.prototype.convertToPixel=function(e,t,n){return RU(t)===this?this.dataToPoint(n):null},e.prototype.convertFromPixel=function(e,t,n){return RU(t)===this?this.pointToData(n):null},e}();function RU(e){var t=e.seriesModel,n=e.polarModel;return n&&n.coordinateSystem||t&&t.coordinateSystem}function Rq(e,t){var n=this,i=n.getAngleAxis(),r=n.getRadiusAxis();if(i.scale.setExtent(1/0,-1/0),r.scale.setExtent(1/0,-1/0),e.eachSeries(function(e){if(e.coordinateSystem===n){var t=e.getData();nw(xU(t,"radius"),function(e){r.scale.unionExtentFromData(t,e)}),nw(xU(t,"angle"),function(e){i.scale.unionExtentFromData(t,e)})}}),xj(i.scale,i.model),xj(r.scale,r.model),"category"===i.type&&!i.onBand){var o=i.getExtent(),a=360/i.scale.count();i.inverse?o[1]+=a:o[1]-=a,i.setExtent(o[0],o[1])}}function RK(e,t){var n;if(e.type=t.get("type"),e.scale=xV(t),e.onBand=t.get("boundaryGap")&&"category"===e.type,e.inverse=t.get("inverse"),"angleAxis"===t.mainType){e.inverse=e.inverse!==t.get("clockwise");var i=t.get("startAngle"),r=null!=(n=t.get("endAngle"))?n:i+(e.inverse?-360:360);e.setExtent(i,r)}t.axis=e,e.model=t}let RY={dimensions:RW,create:function(e,t){var n=[];return e.eachComponent("polar",function(e,i){var r,o,a,s,l,d,u,c=new R$(i+"");c.update=Rq;var h=c.getRadiusAxis(),p=c.getAngleAxis(),f=e.findAxisModel("radiusAxis"),g=e.findAxisModel("angleAxis");RK(h,f),RK(p,g),r=e.get("center"),o=t.getWidth(),a=t.getHeight(),c.cx=aR(r[0],o),c.cy=aR(r[1],a),s=c.getRadiusAxis(),l=Math.min(o,a)/2,null==(d=e.get("radius"))?d=[0,"100%"]:nR(d)||(d=[0,d]),u=[aR(d[0],l),aR(d[1],l)],s.inverse?s.setExtent(u[1],u[0]):s.setExtent(u[0],u[1]),n.push(c),e.coordinateSystem=c,c.model=e}
422),e.eachSeries(function(e){if("polar"===e.get("coordinateSystem")){var t=e.getReferringComponents("polar",si).models[0];e.coordinateSystem=t.coordinateSystem}}),n}};var RZ=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function RX(e,t,n){t[1]>t[0]&&(t=t.slice().reverse());var i=e.coordToPoint([t[0],n]),r=e.coordToPoint([t[1],n]);return{x1:i[0],y1:i[1],x2:r[0],y2:r[1]}}function RJ(e){return+!e.getRadiusAxis().inverse}function RQ(e){var t=e[0],n=e[e.length-1];t&&n&&1e-4>Math.abs(Math.abs(t.coord-n.coord)-360)&&e.pop()}var R0=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.axisPointerClass="PolarAxisPointer",n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t){if(this.group.removeAll(),e.get("show")){var n=e.axis,i=n.polar,r=i.getRadiusAxis().getExtent(),o=n.getTicksCoords(),a=n.getMinorTicksCoords(),s=nC(n.getViewLabels(),function(e){e=nc(e);var t=n.scale,i="ordinal"===t.type?t.getRawOrdinalNumber(e.tickValue):e.tickValue;return e.coord=n.dataToCoord(i),e});RQ(s),RQ(o),nw(RZ,function(t){e.get([t,"show"])&&(!n.scale.isBlank()||"axisLine"===t)&&R1[t](this.group,e,i,o,a,r,s)},this)}},t.type="angleAxis",t}(ww),R1={axisLine:function(e,t,n,i,r,o){var a,s=t.getModel(["axisLine","lineStyle"]),l=n.getAngleAxis(),d=Math.PI/180,u=l.getExtent(),c=RJ(n),h=+!c,p=360===Math.abs(u[1]-u[0])?"Circle":"Arc";(a=0===o[h]?new wN[p]({shape:{cx:n.cx,cy:n.cy,r:o[c],startAngle:-u[0]*d,endAngle:-u[1]*d,clockwise:l.inverse},style:s.getLineStyle(),z2:1,silent:!0}):new wN.Ring({shape:{cx:n.cx,cy:n.cy,r:o[c],r0:o[h]},style:s.getLineStyle(),z2:1,silent:!0})).style.fill=null,e.add(a)},axisTick:function(e,t,n,i,r,o){var a=t.getModel("axisTick"),s=(a.get("inside")?-1:1)*a.get("length"),l=o[RJ(n)],d=nC(i,function(e){return new wN.Line({shape:RX(n,[l,l+s],e.coord)})});e.add(wN.mergePath(d,{style:ng(a.getModel("lineStyle").getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])})}))},minorTick:function(e,t,n,i,r,o){if(r.length){for(var a=t.getModel("axisTick"),s=t.getModel("minorTick"),l=(a.get("inside")?-1:1)*s.get("length"),d=o[RJ(n)],u=[],c=0;c<r.length;c++)for(var h=0;h<r[c].length;h++)u.push(new wN.Line({shape:RX(n,[d,d+l],r[c][h].coord)}));e.add(wN.mergePath(u,{style:ng(s.getModel("lineStyle").getLineStyle(),ng(a.getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(e,t,n,i,r,o,a){var s=t.getCategories(!0),l=t.getModel("axisLabel"),d=l.get("margin"),u=t.get("triggerEvent");nw(a,function(i,r){var a=l,c=i.tickValue,h=o[RJ(n)],p=n.coordToPoint([h+d,i.coord]),f=n.cx,g=n.cy,m=Math.abs(p[0]-f)/h<.3?"center":p[0]>f?"left":"right",v=Math.abs(p[1]-g)/h<.3?"middle":p[1]>g?"top":"bottom";if(s&&s[c]){var y=s[c];nL(y)&&y.textStyle&&(a=new ua(y.textStyle,l,l.ecModel))}var b=new wN.Text({silent:wd.isLabelSilent(t),style:dZ(a,{x:p[0],y:p[1],fill:a.getTextColor()||t.get(["axisLine","lineStyle","color"]),text:i.formattedLabel,align:m,verticalAlign:v})});if(e.add(b),u){var x=wd.makeAxisEventDataBase(t);x.targetType="axisLabel",x.value=i.rawLabel,lQ(b).eventData=x}},this)},splitLine:function(e,t,n,i,r,o){var a=t.getModel("splitLine").getModel("lineStyle"),s=a.get("color"),l=0;s=s instanceof Array?s:[s];for(var d=[],u=0;u<i.length;u++){var c=l++%s.length;d[c]=d[c]||[],d[c].push(new wN.Line({shape:RX(n,o,i[u].coord)}))}for(var u=0;u<d.length;u++)e.add(wN.mergePath(d[u],{style:ng({stroke:s[u%s.length]},a.getLineStyle()),silent:!0,z:t.get("z")}))},minorSplitLine:function(e,t,n,i,r,o){if(r.length){for(var a=t.getModel("minorSplitLine").getModel("lineStyle"),s=[],l=0;l<r.length;l++)for(var d=0;d<r[l].length;d++)s.push(new wN.Line({shape:RX(n,o,r[l][d].coord)}));e.add(wN.mergePath(s,{style:a.getLineStyle(),silent:!0,z:t.get("z")}))}},splitArea:function(e,t,n,i,r,o){if(i.length){var a=t.getModel("splitArea").getModel("areaStyle"),s=a.get("color"),l=0;s=s instanceof Array?s:[s];for(var d=[],u=Math.PI/180,c=-i[0].coord*u,h=Math.min(o[0],o[1]),p=Math.max(o[0],o[1]),f=t.get("clockwise"),g=1,m=i.length;g<=m;g++){var v=g===m?i[0].coord:i[g].coord,y=l++%s.length;d[y]=d[y]||[],d[y].push(new wN.Sector({shape:{cx:n.cx,cy:n.cy,r0:h,r:p,startAngle:c,endAngle:-v*u,clockwise:f},silent:!0})),c=-v*u}for(var g=0;g<d.length;g++)e.add(wN.mergePath(d[g],{style:ng({fill:s[g%s.length]},a.getAreaStyle()),silent:!0}))}}},R2=["axisLine","axisTickLabel","axisName"],R3=["splitLine","splitArea","minorSplitLine"],R5=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.axisPointerClass="PolarAxisPointer",n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t){if(this.group.removeAll(),e.get("show")){var n,i,r,o=this._axisGroup,a=this._axisGroup=new wN.Group;this.group.add(a);var s=e.axis,l=s.polar,d=l.getAngleAxis(),u=s.getTicksCoords(),c=s.getMinorTicksCoords(),h=d.getExtent()[0],p=s.getExtent(),f=(n=l,i=e,r=h,{position:[n.cx,n.cy],rotation:r/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:i.getModel("axisLabel").get("rotate"),z2:1}),g=new wd(e,f);nw(R2,g.add,g),a.add(g.getGroup()),wN.groupTransition(o,a,e),nw(R3,function(t){e.get([t,"show"])&&!s.scale.isBlank()&&R4[t](this.group,e,l,h,p,u,c)},this)}},t.type="radiusAxis",t}(ww),R4={splitLine:function(e,t,n,i,r,o){var a=t.getModel("splitLine").getModel("lineStyle"),s=a.get("color"),l=0,d=n.getAngleAxis(),u=
422Math.PI/180,c=d.getExtent(),h=360===Math.abs(c[1]-c[0])?"Circle":"Arc";s=s instanceof Array?s:[s];for(var p=[],f=0;f<o.length;f++){var g=l++%s.length;p[g]=p[g]||[],p[g].push(new wN[h]({shape:{cx:n.cx,cy:n.cy,r:Math.max(o[f].coord,0),startAngle:-c[0]*u,endAngle:-c[1]*u,clockwise:d.inverse}}))}for(var f=0;f<p.length;f++)e.add(wN.mergePath(p[f],{style:ng({stroke:s[f%s.length],fill:null},a.getLineStyle()),silent:!0}))},minorSplitLine:function(e,t,n,i,r,o,a){if(a.length){for(var s=t.getModel("minorSplitLine").getModel("lineStyle"),l=[],d=0;d<a.length;d++)for(var u=0;u<a[d].length;u++)l.push(new wN.Circle({shape:{cx:n.cx,cy:n.cy,r:a[d][u].coord}}));e.add(wN.mergePath(l,{style:ng({fill:null},s.getLineStyle()),silent:!0}))}},splitArea:function(e,t,n,i,r,o){if(o.length){var a=t.getModel("splitArea").getModel("areaStyle"),s=a.get("color"),l=0;s=s instanceof Array?s:[s];for(var d=[],u=o[0].coord,c=1;c<o.length;c++){var h=l++%s.length;d[h]=d[h]||[],d[h].push(new wN.Sector({shape:{cx:n.cx,cy:n.cy,r0:u,r:o[c].coord,startAngle:0,endAngle:2*Math.PI},silent:!0})),u=o[c].coord}for(var c=0;c<d.length;c++)e.add(wN.mergePath(d[c],{style:ng({fill:s[c%s.length]},a.getAreaStyle()),silent:!0}))}}};function R6(e){return e.get("stack")||"__ec_stack_"+e.seriesIndex}function R8(e,t){return t.dim+e.model.componentIndex}let R7=function(e,t,n){var i,r,o,a={},s=(i=n_(t.getSeriesByType(e),function(e){return!t.isSeriesFiltered(e)&&e.coordinateSystem&&"polar"===e.coordinateSystem.type}),r={},nw(i,function(e,t){var n=e.getData(),i=e.coordinateSystem,o=i.getBaseAxis(),a=R8(i,o),s=o.getExtent(),l="category"===o.type?o.getBandWidth():Math.abs(s[1]-s[0])/n.count(),d=r[a]||{bandWidth:l,remainedWidth:l,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},u=d.stacks;r[a]=d;var c=R6(e);!u[c]&&d.autoWidthCount++,u[c]=u[c]||{width:0,maxWidth:0};var h=aR(e.get("barWidth"),l),p=aR(e.get("barMaxWidth"),l),f=e.get("barGap"),g=e.get("barCategoryGap");h&&!u[c].width&&(h=Math.min(d.remainedWidth,h),u[c].width=h,d.remainedWidth-=h),p&&(u[c].maxWidth=p),null!=f&&(d.gap=f),null!=g&&(d.categoryGap=g)}),o={},nw(r,function(e,t){o[t]={};var n,i=e.stacks,r=e.bandWidth,a=aR(e.categoryGap,r),s=aR(e.gap,1),l=e.remainedWidth,d=e.autoWidthCount,u=(l-a)/(d+(d-1)*s);u=Math.max(u,0),nw(i,function(e,t){var n=e.maxWidth;n&&n<u&&(n=Math.min(n,l),e.width&&(n=Math.min(n,e.width)),l-=n,e.width=n,d--)}),u=Math.max(u=(l-a)/(d+(d-1)*s),0);var c=0;nw(i,function(e,t){e.width||(e.width=u),n=e,c+=e.width*(1+s)}),n&&(c-=n.width*s);var h=-c/2;nw(i,function(e,n){o[t][n]=o[t][n]||{offset:h,width:e.width},h+=e.width*(1+s)})}),o);t.eachSeriesByType(e,function(e){if("polar"===e.coordinateSystem.type){var t=e.getData(),n=e.coordinateSystem,i=n.getBaseAxis(),r=R8(n,i),o=R6(e),l=s[r][o],d=l.offset,u=l.width,c=n.getOtherAxis(i),h=e.coordinateSystem.cx,p=e.coordinateSystem.cy,f=e.get("barMinHeight")||0,g=e.get("barMinAngle")||0;a[o]=a[o]||[];for(var m=t.mapDimension(c.dim),v=t.mapDimension(i.dim),y=yr(t,m),b="radius"!==i.dim||!e.get("roundCap",!0),x=c.model.get("startValue"),w=c.dataToCoord(x||0),C=0,S=t.count();C<S;C++){var _=t.get(m,C),k=t.get(v,C),M=_>=0?"p":"n",T=w;y&&(a[o][k]||(a[o][k]={p:w,n:w}),T=a[o][k][M]);var D=void 0,R=void 0,I=void 0,A=void 0;if("radius"===c.dim){var P=c.dataToCoord(_)-w,E=i.dataToCoord(k);Math.abs(P)<f&&(P=(P<0?-1:1)*f),D=T,R=T+P,A=(I=E-d)-u,y&&(a[o][k][M]=R)}else{var L=c.dataToCoord(_,b)-w,F=i.dataToCoord(k);Math.abs(L)<g&&(L=(L<0?-1:1)*g),R=(D=F+d)+u,I=T,A=T+L,y&&(a[o][k][M]=A)}t.setItemLayout(C,{cx:h,cy:p,r0:D,r:R,startAngle:-I*Math.PI/180,endAngle:-A*Math.PI/180,clockwise:I>=A})}}})};var R9={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},Ie={splitNumber:5},It=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="polar",t}(h9);function In(e,t){t=t||{};var n=e.coordinateSystem,i=e.axis,r={},o=i.position,a=i.orient,s=n.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],d={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};r.position=["vertical"===a?d.vertical[o]:l[0],"horizontal"===a?d.horizontal[o]:l[3]
422],r.rotation=Math.PI/2*({horizontal:0,vertical:1})[a],r.labelDirection=r.tickDirection=r.nameDirection=({top:-1,bottom:1,right:1,left:-1})[o],e.get(["axisTick","inside"])&&(r.tickDirection=-r.tickDirection),nH(t.labelInside,e.get(["axisLabel","inside"]))&&(r.labelDirection=-r.labelDirection);var u=t.rotate;return null==u&&(u=e.get(["axisLabel","rotate"])),r.labelRotation="top"===o?-u:u,r.z2=1,r}var Ii=["axisLine","axisTickLabel","axisName"],Ir=["splitArea","splitLine"],Io=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.axisPointerClass="SingleAxisPointer",n}return(0,tQ.__extends)(t,e),t.prototype.render=function(t,n,i,r){var o=this.group;o.removeAll();var a=this._axisGroup;this._axisGroup=new av;var s=In(t),l=new wd(t,s);nw(Ii,l.add,l),o.add(this._axisGroup),o.add(l.getGroup()),nw(Ir,function(e){t.get([e,"show"])&&Ia[e](this,this.group,this._axisGroup,t)},this),fb(a,this._axisGroup,t),e.prototype.render.call(this,t,n,i,r)},t.prototype.remove=function(){w_(this)},t.type="singleAxis",t}(ww),Ia={splitLine:function(e,t,n,i){var r=i.axis;if(!r.scale.isBlank()){var o=i.getModel("splitLine"),a=o.getModel("lineStyle"),s=a.get("color");s=s instanceof Array?s:[s];for(var l=a.get("width"),d=i.coordinateSystem.getRect(),u=r.isHorizontal(),c=[],h=0,p=r.getTicksCoords({tickModel:o}),f=[],g=[],m=0;m<p.length;++m){var v=r.toGlobalCoord(p[m].coord);u?(f[0]=v,f[1]=d.y,g[0]=v,g[1]=d.y+d.height):(f[0]=d.x,f[1]=v,g[0]=d.x+d.width,g[1]=v);var y=new pU({shape:{x1:f[0],y1:f[1],x2:g[0],y2:g[1]},silent:!0});fp(y.shape,l);var b=h++%s.length;c[b]=c[b]||[],c[b].push(y)}for(var x=a.getLineStyle(["color"]),m=0;m<c.length;++m)t.add(fc(c[m],{style:ng({stroke:s[m%s.length]},x),silent:!0}))}},splitArea:function(e,t,n,i){wS(e,n,i,i)}},Is=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.getCoordSysModel=function(){return this},t.type="singleAxis",t.layoutMode="box",t.defaultOption={left:"5%",top:"5%",right:"5%",bottom:"5%",type:"value",position:"bottom",orient:"horizontal",axisLine:{show:!0,lineStyle:{width:1,type:"solid"}},tooltip:{show:!0},axisTick:{show:!0,length:6,lineStyle:{width:1}},axisLabel:{show:!0,interval:"auto"},splitLine:{show:!0,lineStyle:{type:"dashed",opacity:.2}}},t}(u5);nb(Is,b9.prototype);var Il=function(e){function t(t,n,i,r,o){var a=e.call(this,t,n,i)||this;return a.type=r||"value",a.position=o||"bottom",a}return(0,tQ.__extends)(t,e),t.prototype.isHorizontal=function(){var e=this.position;return"top"===e||"bottom"===e},t.prototype.pointToData=function(e,t){return this.coordinateSystem.pointToData(e)[0]},t}(x6),Id=["single"],Iu=function(){function e(e,t,n){this.type="single",this.dimension="single",this.dimensions=Id,this.axisPointerEnabled=!0,this.model=e,this._init(e,t,n)}return e.prototype._init=function(e,t,n){var i=new Il(this.dimension,xV(e),[0,0],e.get("type"),e.get("position")),r="category"===i.type;i.onBand=r&&e.get("boundaryGap"),i.inverse=e.get("inverse"),i.orient=e.get("orient"),e.axis=i,i.model=e,i.coordinateSystem=this,this._axis=i},e.prototype.update=function(e,t){e.eachSeries(function(e){if(e.coordinateSystem===this){var t=e.getData();nw(t.mapDimensionsAll(this.dimension),function(e){this._axis.scale.unionExtentFromData(t,e)},this),xj(this._axis.scale,this._axis.model)}},this)},e.prototype.resize=function(e,t){this._rect=uX({left:e.get("left"),top:e.get("top"),right:e.get("right"),bottom:e.get("bottom"),width:e.get("width"),height:e.get("height")},{width:t.getWidth(),height:t.getHeight()}),this._adjustAxis()},e.prototype.getRect=function(){return this._rect},e.prototype._adjustAxis=function(){var e=this._rect,t=this._axis,n=t.isHorizontal(),i=n?[0,e.width]:[0,e.height],r=+!!t.inverse;t.setExtent(i[r],i[1-r]),this._updateAxisTransform(t,n?e.x:e.y)},e.prototype._updateAxisTransform=function(e,t){var n=e.getExtent(),i=n[0]+n[1],r=e.isHorizontal();e.toGlobalCoord=r?function(e){return e+t}:function(e){return i-e+t},e.toLocalCoord=r?function(e){return e-t}:function(e){return i-e+t}},e.prototype.getAxis=function(){return this._axis},e.prototype.getBaseAxis=function(){return this._axis},e.prototype.getAxes=function(){return[this._axis]},e.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},e.prototype.containPoint=function(e){var t=this.getRect(),n=this.getAxis();return"horizontal"===n.orient?n.contain(n.toLocalCoord(e[0]))&&e[1]>=t.y&&e[1]<=t.y+t.height:n.contain(n.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},e.prototype.pointToData=function(e){var t=this.getAxis();
422return[t.coordToData(t.toLocalCoord(e[+("horizontal"!==t.orient)]))]},e.prototype.dataToPoint=function(e){var t=this.getAxis(),n=this.getRect(),i=[],r=+("horizontal"!==t.orient);return e instanceof Array&&(e=e[0]),i[r]=t.toGlobalCoord(t.dataToCoord(+e)),i[1-r]=0===r?n.y+n.height/2:n.x+n.width/2,i},e.prototype.convertToPixel=function(e,t,n){return Ic(t)===this?this.dataToPoint(n):null},e.prototype.convertFromPixel=function(e,t,n){return Ic(t)===this?this.pointToData(n):null},e}();function Ic(e){var t=e.seriesModel,n=e.singleAxisModel;return n&&n.coordinateSystem||t&&t.coordinateSystem}let Ih={create:function(e,t){var n=[];return e.eachComponent("singleAxis",function(i,r){var o=new Iu(i,e,t);o.name="single_"+r,o.resize(i,t),i.coordinateSystem=o,n.push(o)}),e.eachSeries(function(e){if("singleAxis"===e.get("coordinateSystem")){var t=e.getReferringComponents("singleAxis",si).models[0];e.coordinateSystem=t&&t.coordinateSystem}}),n},dimensions:Id};var Ip=["x","y"],If=["width","height"],Ig=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.makeElOption=function(e,t,n,i,r){var o=n.axis,a=o.coordinateSystem,s=Iy(a,1-Iv(o)),l=a.dataToPoint(t)[0],d=i.get("type");if(d&&"none"!==d){var u=Rs(i),c=Im[d](o,l,s);c.style=u,e.graphicKey=c.type,e.pointer=c}Rc(t,e,In(n),n,i,r)},t.prototype.getHandleTransform=function(e,t,n){var i=In(t,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var r=Ru(t.axis,e,i);return{x:r[0],y:r[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(e,t,n,i){var r=n.axis,o=r.coordinateSystem,a=Iv(r),s=Iy(o,a),l=[e.x,e.y];l[a]+=t[a],l[a]=Math.min(s[1],l[a]),l[a]=Math.max(s[0],l[a]);var d=Iy(o,1-a),u=(d[1]+d[0])/2,c=[u,u];return c[a]=l[a],{x:l[0],y:l[1],rotation:e.rotation,cursorPoint:c,tooltipOption:{verticalAlign:"middle"}}},t}(Rn),Im={line:function(e,t,n){return{type:"Line",subPixelOptimize:!0,shape:Rh([t,n[0]],[t,n[1]],Iv(e))}},shadow:function(e,t,n){var i=e.getBandWidth(),r=n[1]-n[0];return{type:"Rect",shape:Rp([t-i/2,n[0]],[i,r],Iv(e))}}};function Iv(e){return+!e.isHorizontal()}function Iy(e,t){var n=e.getRect();return[n[Ip[t]],n[Ip[t]]+n[If[t]]]}var Ib=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="single",t}(h9),Ix=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t,n,i){var r=u1(t);e.prototype.init.apply(this,arguments),Iw(t,r)},t.prototype.mergeOption=function(t){e.prototype.mergeOption.apply(this,arguments),Iw(this.option,t)},t.prototype.getCellSize=function(){return this.option.cellSize},t.type="calendar",t.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},t}(u5);function Iw(e,t){var n,i=e.cellSize;1===(n=nR(i)?i:e.cellSize=[i,i]).length&&(n[1]=n[0]);var r=nC([0,1],function(e){return(null!=t[uY[e][0]]||null!=t[uY[e][1]]&&null!=t[uY[e][2]])&&(n[e]="auto"),null!=n[e]&&"auto"!==n[e]});u0(e,t,{type:"box",ignoreSize:r})}var IC=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i=this.group;i.removeAll();var r=e.coordinateSystem,o=r.getRangeInfo(),a=r.getOrient(),s=t.getLocaleModel();this._renderDayRect(e,o,i),this._renderLines(e,o,a,i),this._renderYearText(e,o,a,i),this._renderMonthText(e,s,a,i),this._renderWeekText(e,s,o,a,i)},t.prototype._renderDayRect=function(e,t,n){for(var i=e.coordinateSystem,r=e.getModel("itemStyle").getItemStyle(),o=i.getCellWidth(),a=i.getCellHeight(),s=t.start.time;s<=t.end.time;s=i.getNextNDay(s,1).time){var l=i.dataToRect([s],!1).tl,d=new lN({shape:{x:l[0],y:l[1],width:o,height:a},cursor:"default",style:r});n.add(d)}},t.prototype._renderLines=function(e,t,n,i){var r=this,o=e.coordinateSystem,a=e.getModel(["splitLine","lineStyle"]).getLineStyle(),s=e.get(["splitLine","show"]),l=a.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var d=t.start,u=0;d.time<=t.end.time;u++){h(d.formatedDate),0===u&&(d=o.getDateInfo(t.start.y+"-"+t.start.m));var c=d.date;c.setMonth(c.getMonth()+1),d=o.getDateInfo(c)}function h(t){r._firstDayOfMonth.push(o.getDateInfo(t)),r._firstDayPoints.push(o.dataToRect([t],!1).tl);var l=r._getLinePointsOfOneWeek(e,t,n);r._tlpoints.push(l[0]),r._blpoints.push(l[l.length-1]),s&&r._drawSplitline(l,a,i)}h(o.getNextNDay(t.end.time,1).formatedDate),s&&this._drawSplitline(r._getEdgesPoints(r._tlpoints,l,n),a,i),s&&this._drawSplitline(r._getEdgesPoints(r._blpoints,l,n),a,i)},t.prototype._getEdgesPoints=function(e,t,n){var i=[e[0].slice(),e[e.length-1].slice()],r=+("horizontal"!==n);return i[0][r]=i[0][r]-t/2,i[1][r]=i[1][r]+t/2,i},t.prototype._drawSplitline=function(e,t,n){var i=new pG({z2:20,shape:{points:e},style:t});n.add(i)},t.prototype._getLinePointsOfOneWeek=function(e,t,n){for(var i=e.coordinateSystem,r=i.getDateInfo(t),o=[],a=0;a<7;a++){var s=i.getNextNDay(r.time,a),l=i.dataToRect([s.time],!1);o[2*s.day]=l.tl,o[2*s.day+1]=l["horizontal"===n?"bl":"tr"]}return o},t.prototype._formatterLabel=function(e,t){if(nA(e)&&e){var n;return n=e,nw(t,function(e,t){n=n.replace("{"+t+"}",e)}),n}return nI(e)?e(t):t.nameMap}
422,t.prototype._yearTextPositionControl=function(e,t,n,i,r){var o=t[0],a=t[1],s=["center","bottom"];"bottom"===i?(a+=r,s=["center","top"]):"left"===i?o-=r:"right"===i?(o+=r,s=["center","top"]):a-=r;var l=0;return("left"===i||"right"===i)&&(l=Math.PI/2),{rotation:l,x:o,y:a,style:{align:s[0],verticalAlign:s[1]}}},t.prototype._renderYearText=function(e,t,n,i){var r=e.getModel("yearLabel");if(r.get("show")){var o=r.get("margin"),a=r.get("position");a||(a="horizontal"!==n?"top":"left");var s=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],l=(s[0][0]+s[1][0])/2,d=(s[0][1]+s[1][1])/2,u=+("horizontal"!==n),c={top:[l,s[u][1]],bottom:[l,s[1-u][1]],left:[s[1-u][0],d],right:[s[u][0],d]},h=t.start.y;+t.end.y>+t.start.y&&(h=h+"-"+t.end.y);var p=r.get("formatter"),f={start:t.start.y,end:t.end.y,nameMap:h},g=new lj({z2:30,style:dZ(r,{text:this._formatterLabel(p,f)}),silent:r.get("silent")});g.attr(this._yearTextPositionControl(g,c[a],n,a,o)),i.add(g)}},t.prototype._monthTextPositionControl=function(e,t,n,i,r){var o="left",a="top",s=e[0],l=e[1];return"horizontal"===n?(l+=r,t&&(o="center"),"start"===i&&(a="bottom")):(s+=r,t&&(a="middle"),"start"===i&&(o="right")),{x:s,y:l,align:o,verticalAlign:a}},t.prototype._renderMonthText=function(e,t,n,i){var r=e.getModel("monthLabel");if(r.get("show")){var o=r.get("nameMap"),a=r.get("margin"),s=r.get("position"),l=r.get("align"),d=[this._tlpoints,this._blpoints];(!o||nA(o))&&(o&&(t=uc[o]||t),o=t.get(["time","monthAbbr"])||[]);var u=+("start"!==s),c=+("horizontal"!==n);a="start"===s?-a:a;for(var h="center"===l,p=r.get("silent"),f=0;f<d[u].length-1;f++){var g=d[u][f].slice(),m=this._firstDayOfMonth[f];if(h){var v=this._firstDayPoints[f];g[c]=(v[c]+d[0][f+1][c])/2}var y=r.get("formatter"),b=o[m.m-1],x={yyyy:m.y,yy:(m.y+"").slice(2),MM:m.m,M:+m.m,nameMap:b},w=new lj({z2:30,style:nf(dZ(r,{text:this._formatterLabel(y,x)}),this._monthTextPositionControl(g,h,n,s,a)),silent:p});i.add(w)}}},t.prototype._weekTextPositionControl=function(e,t,n,i,r){var o="center",a="middle",s=e[0],l=e[1],d="start"===n;return"horizontal"===t?(s=s+i+(d?1:-1)*r[0]/2,o=d?"right":"left"):(l=l+i+(d?1:-1)*r[1]/2,a=d?"bottom":"top"),{x:s,y:l,align:o,verticalAlign:a}},t.prototype._renderWeekText=function(e,t,n,i,r){var o=e.getModel("dayLabel");if(o.get("show")){var a=e.coordinateSystem,s=o.get("position"),l=o.get("nameMap"),d=o.get("margin"),u=a.getFirstDayOfWeek();(!l||nA(l))&&(l&&(t=uc[l]||t),l=t.get(["time","dayOfWeekShort"])||nC(t.get(["time","dayOfWeekAbbr"]),function(e){return e[0]}));var c=a.getNextNDay(n.end.time,7-n.lweek).time,h=[a.getCellWidth(),a.getCellHeight()];d=aR(d,Math.min(h[1],h[0])),"start"===s&&(c=a.getNextNDay(n.start.time,-(7+n.fweek)).time,d=-d);for(var p=o.get("silent"),f=0;f<7;f++){var g=a.getNextNDay(c,f),m=a.dataToRect([g.time],!1).center,v=new lj({z2:30,style:nf(dZ(o,{text:l[Math.abs((f+u)%7)]}),this._weekTextPositionControl(m,i,s,d,h)),silent:p});r.add(v)}}},t.type="calendar",t}(h9),IS=function(){function e(t,n,i){this.type="calendar",this.dimensions=e.dimensions,this.getDimensionsInfo=e.getDimensionsInfo,this._model=t}return e.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},e.prototype.getRangeInfo=function(){return this._rangeInfo},e.prototype.getModel=function(){return this._model},e.prototype.getRect=function(){return this._rect},e.prototype.getCellWidth=function(){return this._sw},e.prototype.getCellHeight=function(){return this._sh},e.prototype.getOrient=function(){return this._orient},e.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},e.prototype.getDateInfo=function(e){var t=(e=aj(e)).getFullYear(),n=e.getMonth()+1,i=n<10?"0"+n:""+n,r=e.getDate(),o=r<10?"0"+r:""+r,a=e.getDay();return{y:t+"",m:i,d:o,day:a=Math.abs((a+7-this.getFirstDayOfWeek())%7),time:e.getTime(),formatedDate:t+"-"+i+"-"+o,date:e}},e.prototype.getNextNDay=function(e,t){return 0===(t=t||0)||(e=new Date(this.getDateInfo(e).time)).setDate(e.getDate()+t),this.getDateInfo(e)},e.prototype.update=function(e,t){this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var n=this._rangeInfo.weeks||1,i=["width","height"],r=this._model.getCellSize().slice(),o=this._model.getBoxLayoutParams(),a="horizontal"===this._orient?[n,7]:[7,n];nw([0,1],function(e){d(r,e)&&(o[i[e]]=r[e]*a[e])});var s={width:t.getWidth(),height:t.getHeight()},l=this._rect=uX(o,s);function d(e,t){return null!=e[t]&&"auto"!==e[t]}nw([0,1],function(e){d(r,e)||(r[e]=l[i[e]]/a[e])}),this._sw=r[0],this._sh=r[1]},e.prototype.dataToPoint=function(e,t){nR(e)&&(e=e[0]),null==t&&(t=!0);var n=this.getDateInfo(e),i=this._rangeInfo,r=n.formatedDate;if(t&&!(n.time>=i.start.time&&n.time<i.end.time+864e5))return[NaN,NaN];var o=n.day,a=this._getRangeInfo([i.start.time,r]).nthWeek;return"vertical"===this._orient?[this._rect.x+o*this._sw+this._sw/2,this._rect.y+a*this._sh+this._sh/2]:[this._rect.x+a*this._sw+this._sw/2,this._rect.y+o*this._sh+this._sh/2]},e.prototype.pointToData=function(e){var t=this.pointToDate(e);return t&&t.time},e.prototype.dataToRect=function(e,t){var n=this.dataToPoint(e,t);return{contentShape:{x:n[0]-(this._sw-this._lineWidth)/2,y:n[1]-(this._sh-this._lineWidth)/2,width:this._sw-this._lineWidth,height:this._sh-this._lineWidth},center:n,tl:[n[0]-this._sw/2,n[1]-this._sh/2],tr:[n[0]+this._sw/2,n[1]-this._sh/2],br:[n[0]+this._sw/2,n[1]+this._sh/2],bl:[n[0]-this._sw/2,n[1]+this._sh/2]}},e.prototype.pointToDate=function(e){var t=Math.floor((e[0]-this._rect.x)/this._sw)+1,n=Math.floor((e[1]-this._rect.y)/this._sh)+1,i=this._rangeInfo.range;return"vertical"===this._orient?this._getDateByWeeksAndDay(n,t-1,i):this._getDateByWeeksAndDay(t,n-1,i)},e.prototype.convertToPixel=function(e,t,n){var i=I_(t);return i===this?i.dataToPoint(n):null},e.prototype.convertFromPixel=function(e,t,n){var i=I_(t);return i===this?i.pointToData(n):null},e.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},e.prototype._initRangeOption=function(){var e,t=this._model.get("range");if(nR(t)&&1===t.length&&(t=t[0]),nR(t))e=t;else{var n=t.toString();if(/^\d{4}$/.test(n)&&(e=[n+"-01-01",n+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(n)){var i=this.getDateInfo(n),r=i.date;r.setMonth(r.getMonth()+1);var o=this.getNextNDay(r,-1);e=[i.formatedDate,o.formatedDate]}/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(n)&&(e=[n,n])}if(!e)return t;var a=this._getRangeInfo(e);return a.start.time>a.end.time&&e.reverse(),e},e.prototype._getRangeInfo=function(e){var t,n=[this.getDateInfo(e[0]),this.getDateInfo(e[1])];n[0].time>n[1].time&&(t=!0,n.reverse());var i=Math.floor(n[1].time/864e5)-Math.floor(n[0].time/864e5)+1,r=new Date(n[0].time),o=r.getDate(),a=n[1].date.getDate();r.setDate(o+i-1);var s=r.getDate();if(s!==a)for(var l=r.getTime()-n[1].time>0?1:-1;(s=r.getDate())!==a&&(r.getTime()-n[1].time)*l>0;)i-=l,r.setDate(s-l);var d=Math.floor((i+n[0].day+6)/7),u=t?-d+1:d-1;return t&&n.reverse(),{range:[n[0].formatedDate,n[1].formatedDate],start:n[0],end:n[1],allDay:i,weeks:d,nthWeek:u,fweek:n[0].day,lweek:n[1].day}},e.prototype._getDateByWeeksAndDay=function(e,t,n){var i=this._getRangeInfo(n);if(e>i.weeks||0===e&&t<i.fweek||e===i.weeks&&t>i.lweek)return null;var r=(e-1)*7-i.fweek+t,o=new Date(i.start.time);return o.setDate(+i.start.d+r),this.getDateInfo(o)},e.create=function(t,n){var i=[];return t.eachComponent("calendar",function(r){var o=new e(r,t,n);i.push(o),r.coordinateSystem=o}
vendor: 12,331 bytes, line 422
422),t.eachSeries(function(e){"calendar"===e.get("coordinateSystem")&&(e.coordinateSystem=i[e.get("calendarIndex")||0])}),i},e.dimensions=["time","value"],e}();function I_(e){var t=e.calendarModel,n=e.seriesModel;return t?t.coordinateSystem:n?n.coordinateSystem:null}function Ik(e,t){var n;return nw(t,function(t){null!=e[t]&&"auto"!==e[t]&&(n=!0)}),n}var IM=["transition","enterFrom","leaveTo"],IT=IM.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function ID(e,t,n){if(n&&(!e[n]&&t[n]&&(e[n]={}),e=e[n],t=t[n]),e&&t)for(var i=n?IM:IT,r=0;r<i.length;r++){var o=i[r];null==e[o]&&null!=t[o]&&(e[o]=t[o])}}var IR=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.preventAutoZ=!0,n}return(0,tQ.__extends)(t,e),t.prototype.mergeOption=function(t,n){var i=this.option.elements;this.option.elements=null,e.prototype.mergeOption.call(this,t,n),this.option.elements=i},t.prototype.optionUpdated=function(e,t){var n=this.option,i=(t?n:e).elements,r=n.elements=t?[]:n.elements,o=[];this._flatten(i,o,null);var a=a2(r,o,"normalMerge"),s=this._elOptionsToUpdate=[];nw(a,function(e,t){var n=e.newOption;if(n){s.push(n);var i,o,a,l,d=e.existing;if(n.id=e.keyInfo.id,!n.type&&d&&(n.type=d.type),null==n.parentId){var u=n.parentOption;u?n.parentId=u.id:d&&(n.parentId=d.parentId)}n.parentOption=null,i=nf({},n),o=r[t],"merge"===(a=n.$action||"merge")?o?(nh(o,i,!0),u0(o,i,{ignoreSize:!0}),u2(n,o),ID(n,o),ID(n,o,"shape"),ID(n,o,"style"),ID(n,o,"extra"),n.clipPath=o.clipPath):r[t]=i:"replace"===a?r[t]=i:"remove"===a&&o&&(r[t]=null),l=r[t],l&&(l.hv=n.hv=[Ik(n,["left","right"]),Ik(n,["top","bottom"])],"group"===l.type&&(null==l.width&&(l.width=n.width=0),null==l.height&&(l.height=n.height=0)))}},this),n.elements=n_(r,function(e){return e&&delete e.$action,null!=e})},t.prototype._flatten=function(e,t,n){nw(e,function(e){if(e){n&&(e.parentOption=n),t.push(e);var i=e.children;i&&i.length&&this._flatten(i,t,e),delete e.children}},this)},t.prototype.useElOptionsToUpdate=function(){var e=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,e},t.type="graphic",t.defaultOption={elements:[]},t}(u5),II={path:null,compoundPath:null,group:av,image:lI,text:lj},IA=a9(),IP=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(){this._elMap=n1()},t.prototype.render=function(e,t,n){e!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=e,this._updateElements(e),this._relocate(e,n)},t.prototype._updateElements=function(e){var t=e.useElOptionsToUpdate();if(t){var n=this._elMap,i=this.group,r=e.get("z"),o=e.get("zlevel");nw(t,function(t){var a=a4(t.id,null),s=null!=a?n.get(a):null,l=a4(t.parentId,null),d=null!=l?n.get(l):i,u=t.type,c=t.style;"text"===u&&c&&t.hv&&t.hv[1]&&(c.textVerticalAlign=c.textBaseline=c.verticalAlign=c.align=null);var h=t.textContent,p=t.textConfig;if(c&&Dg(c,u,!!p,!!h)){var f=Dm(c,u,!0);!p&&f.textConfig&&(p=t.textConfig=f.textConfig),!h&&f.textContent&&(h=f.textContent)}var g=(_=nf({},_=t),nw(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(uK),function(e){delete _[e]}),_),m=t.$action||"merge",v="merge"===m,y="replace"===m;if(v){var b=!s,x=s;b?x=IL(a,d,t.type,n):(x&&(IA(x).isNew=!1),DO(x)),x&&(Dk(x,g,e,{isInit:b}),IO(x,t,r,o))}else if(y){IF(s,t,n,e);var w=IL(a,d,t.type,n);w&&(Dk(w,g,e,{isInit:!0}),IO(w,t,r,o))}else"remove"===m&&(DM(s,t),IF(s,t,n,e));var C=n.get(a);if(C&&h)if(v){var S=C.getTextContent();S?S.attr(h):C.setTextContent(new lj(h))}else y&&C.setTextContent(new lj(h));if(C){var _,k,M,T,D,R=t.clipPath;if(R){var I=R.type,A=void 0,b=!1;if(v){var P=C.getClipPath();A=(b=!P||IA(P).type!==I)?IE(I):P}else y&&(b=!0,A=IE(I));C.setClipPath(A),Dk(A,R,e,{isInit:b}),DN(A,R.keyframeAnimation,e)}var E=IA(C);C.setTextConfig(p),E.option=t,k=C,M=e,T=t,D=lQ(k).eventData,k.silent||k.ignore||D||(D=lQ(k).eventData={componentType:"graphic",componentIndex:M.componentIndex,name:k.name}),D&&(D.info=T.info),fk({el:C,componentModel:e,itemName:C.name,itemTooltipOption:t.tooltip}),DN(C,t.keyframeAnimation,e)}})}},t.prototype._relocate=function(e,t){for(var n=e.option.elements,i=this.group,r=this._elMap,o=t.getWidth(),a=t.getHeight(),s=["x","y"],l=0;l<n.length;l++){var d=n[l],u=a4(d.id,null),c=null!=u?r.get(u):null;if(c&&c.isGroup){var h=c.parent,p=h===i,f=IA(c),g=IA(h);f.width=aR(f.option.width,p?o:g.width)||0,f.height=aR(f.option.height,p?a:g.height)||0}}for(var l=n.length-1;l>=0;l--){var d=n[l],u=a4(d.id,null),c=null!=u?r.get(u):null;if(c){var h=c.parent,g=IA(h),m=h===i?{width:o,height:a}:{width:g.width,height:g.height},v={},y=uJ(c,d,m,null,{hv:d.hv,boundingMode:d.bounding},v);if(!IA(c).isNew&&y){for(var b=d.transition,x={},w=0;w<s.length;w++){var C=s[w],S=v[C];b&&(DD(b)||nv(b,C)>=0)?x[C]=S:c[C]=S}dB(c,x,e,0)}else c.attr(v)}}},t.prototype._clear=function(){var e=this,t=this._elMap;t.each(function(n){IF(n,IA(n).option,t,e._lastGraphicModel)}),this._elMap=n1()},t.prototype.dispose=function(){this._clear()},t.type="graphic",t}(h9);function IE(e){var t=new(n4(II,e)?II[e]:fs(e))({});return IA(t).type=e,t}function IL(e,t,n,i){var r=IE(n);return t.add(r),i.set(e,r),IA(r).id=e,IA(r).isNew=!0,r}function IF(e,t,n,i){e&&e.parent&&("group"===e.type&&e.traverse(function(e){IF(e,t,n,i)}),DT(e,t,i),n.removeKey(IA(e).id))}function IO(e,t,n,i){e.isGroup||nw([["cursor",sV.prototype.cursor],["zlevel",i||0],["z",n||0],["z2",0]],function(n){var i=n[0];n4(t,i)?e[i]=nG(t[i],n[1]):null==e[i]&&(e[i]=n[1])}),nw(nM(t),function(n){if(0===n.indexOf("on")){var i=t[n];e[n]=nI(i)?i:null}}),n4(t,"draggable")&&(e.draggable=t.draggable),null!=t.name&&(e.name=t.name),null!=t.id&&(e.id=t.id)}var IN=["x","y","radius","angle","single"],IB=["cartesian2d","polar","singleAxis"];function Iz(e){return e+"Axis"}function Ij(e){var t=e.ecModel,n={infoList:[],infoMap:n1()};return e.eachTargetAxis(function(e,i){var r=t.getComponent(Iz(e),i);if(r){var o=r.getCoordSysModel();if(o){var a=o.uid,s=n.infoMap.get(a);s||(s={model:o,axisModels:[]},n.infoList.push(s),n.infoMap.set(a,s)),s.axisModels.push(r)}}}),n}var IV=function(){function e(){this.indexList=[],this.indexMap=[]}return e.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},e}(),IH=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._autoThrottle=!0,n._noTarget=!0,n._rangePropMode=["percent","percent"],n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t,n){var i=IG(e);this.settledOption=i,this.mergeDefaultAndTheme(e,n),this._doInit(i)},t.prototype.mergeOption=function(e){var t=IG(e);nh(this.option,e,!0),nh(this.settledOption,t,!0),this._doInit(t)},t.prototype._doInit=function(e){var t=this.option;this._setDefaultThrottle(e),this._updateRangeUse(e);var n=this.settledOption;nw([["start","startValue"],["end","endValue"]],function(e,i){"value"===this._rangePropMode[i]&&(t[e[0]]=n[e[0]]=null)},this),this._resetTarget()},t.prototype._resetTarget=function(){var e=this.get("orient",!0),t=this._targetAxisInfoMap=n1();this._fillSpecifiedTargetAxis(t)?this._orient=e||this._makeAutoOrientByTargetAxis():(this._orient=e||"horizontal",this._fillAutoTargetAxisByOrient(t,this._orient)),this._noTarget=!0,t.each(function(e){e.indexList.length&&(this._noTarget=!1)},this)},t.prototype._fillSpecifiedTargetAxis=function(e){var t=!1;return nw(IN,function(n){var i=this.getReferringComponents(Iz(n),sr);if(i.specified){t=!0;var r=new IV;nw(i.models,function(e){r.add(e.componentIndex)}),e.set(n,r)}},this),t},t.prototype._fillAutoTargetAxisByOrient=function(e,t){var n=this.ecModel,i=!0,r="vertical"===t?"y":"x",o=n.findComponents({mainType:r+"Axis"});if(a(o,r),i){var o=n.findComponents({mainType:"singleAxis",filter:function(e){return e.get("orient",!0)===t}});a(o,"single")}function a(t,n){var r=t[0];if(r){var o=new IV;if(o.add(r.componentIndex),e.set(n,o),i=!1,"x"===n||"y"===n){var a=r.getReferringComponents("grid",si).models[0];a&&nw(t,function(e){r.componentIndex!==e.componentIndex&&a===e.getReferringComponents("grid",si).models[0]&&o.add(e.componentIndex)})}}}i&&nw(IN,function(t){if(i){var r=n.findComponents({mainType:Iz(t),filter:function(e){return"category"===e.get("type",!0)}});if(r[0]){var o=new IV;o.add(r[0].componentIndex),e.set(t,o),i=!1}}},this)},t.prototype._makeAutoOrientByTargetAxis=function(){var e;return this.eachTargetAxis(function(t){e||(e=t)},this),"y"===e?"vertical":"horizontal"},t.prototype._setDefaultThrottle=function(e){if(e.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var t=this.ecModel.option;this.option.throttle=t.animation&&t.animationDurationUpdate>0?100:20}},t.prototype._updateRangeUse=function(e){var t=this._rangePropMode,n=this.get("rangeMode");nw([["start","startValue"],["end","endValue"]],function(i,r){var o=null!=e[i[0]],a=null!=e[i[1]];o&&!a?t[r]="percent":!o&&a?t[r]="value":n?t[r]=n[r]:o&&(t[r]="percent")})},t.prototype.noTarget=function(){return this._noTarget},t.prototype.getFirstTargetAxisModel=function(){var e;return this.eachTargetAxis(function(t,n){null==e&&(e=this.ecModel.getComponent(Iz(t),n))},this),e},t.prototype.eachTargetAxis=function(e,t){this._targetAxisInfoMap.each(function(n,i){nw(n.indexList,function(n){e.call(t,i,n)})})},t.prototype.getAxisProxy=function(e,t){var n=this.getAxisModel(e,t);if(n)return n.__dzAxisProxy},t.prototype.getAxisModel=function(e,t){var n=this._targetAxisInfoMap.get(e);if(n&&n.indexMap[t])return this.ecModel.getComponent(Iz(e),t)},t.prototype.setRawRange=function(e){var t=this.option,n=this.settledOption;nw([["start","startValue"],["end","endValue"]],function(i){(null!=e[i[0]]||null!=e[i[1]])&&(t[i[0]]=n[i[0]]=e[i[0]],t[i[1]]=n[i[1]]=e[i[1]])},this),this._updateRangeUse(e)},t.prototype.setCalculatedRange=function(e){var t=this.option;nw(["start","startValue","end","endValue"],function(n){t[n]=e[n]})},t.prototype.getPercentRange=function(){var e=this.findRepresentativeAxisProxy();if(e)return e.getDataPercentWindow()},t.prototype.getValueRange=function(e,t){if(null!=e||null!=t)return this.getAxisProxy(e,t).getDataValueWindow();var n=this.findRepresentativeAxisProxy();if(n)return n.getDataValueWindow()},t.prototype.findRepresentativeAxisProxy=function(e){if(e)return e.__dzAxisProxy;for(var t,n=this._targetAxisInfoMap.keys(),i=0;i<n.length;i++)for(var r=n[i],o=this._targetAxisInfoMap.get(r),a=0;a<o.indexList.length;a++){var s=this.getAxisProxy(r,o.indexList[a]);if(s.hostedBy(this))return s;t||(t=s)}return t},t.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},t.prototype.getOrient=function(){return this._orient},t.type="dataZoom",t.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],t.defaultOption={z:4,filterMode:"filter",start:0,end:100},t}(u5);function IG(e){var t={};return nw(["start","end","startValue","endValue","throttle"],function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}var IW=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="dataZoom.select",t}(IH),I$=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){this.dataZoomModel=e,this.ecModel=t,this.api=n},t.type="dataZoom",t}(h9),IU=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="dataZoom.select",t}(I$),Iq=function(){function e(e,t,n,i){this._dimName=e,this._axisIndex=t,this.ecModel=i,this._dataZoomModel=n}return e.prototype.hostedBy=function(e){return this._dataZoomModel===e},e.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},e.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},e.prototype.getTargetSeriesModels=function(){var e=[];return this.ecModel.eachSeries(function(t){if(nv(IB,t.get("coordinateSystem"))>=0){var n=Iz(this._dimName),i=t.getReferringComponents(n,si).models[0];i&&this._axisIndex===i.componentIndex&&e.push(t)}},this),e},e.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},e.prototype.getMinMaxSpan=function(){return nc(this._minMaxSpan)},e.prototype.calculateDataWindow=function(e){var t,n=this._dataExtent,
422i=this.getAxisModel().axis.scale,r=this._dataZoomModel.getRangePropMode(),o=[0,100],a=[],s=[];nw(["start","end"],function(l,d){var u=e[l],c=e[l+"Value"];"percent"===r[d]?(null==u&&(u=o[d]),c=i.parse(aD(u,o,n))):(t=!0,u=aD(c=null==c?n[d]:i.parse(c),n,o)),s[d]=null==c||isNaN(c)?n[d]:c,a[d]=null==u||isNaN(u)?o[d]:u}),aA(s),aA(a);var l=this._minMaxSpan;function d(e,t,n,r,o){var a=o?"Span":"ValueSpan";kF(0,e,n,"all",l["min"+a],l["max"+a]);for(var s=0;s<2;s++)t[s]=aD(e[s],n,r,!0),o&&(t[s]=i.parse(t[s]))}return t?d(s,a,n,o,!1):d(a,s,o,n,!0),{valueWindow:s,percentWindow:a}},e.prototype.reset=function(e){if(e===this._dataZoomModel){var t,n,i,r,o,a=this.getTargetSeriesModels();this._dataExtent=(t=this,n=this._dimName,i=[1/0,-1/0],nw(a,function(e){var t;t=e.getData(),t&&nw(xU(t,n),function(e){var n=t.getApproximateExtent(e);n[0]<i[0]&&(i[0]=n[0]),n[1]>i[1]&&(i[1]=n[1])})}),[(o=xN((r=t.getAxisModel()).axis.scale,r,i).calculate()).min,o.max]),this._updateMinMaxSpan();var s=this.calculateDataWindow(e.settledOption);this._valueWindow=s.valueWindow,this._percentWindow=s.percentWindow,this._setAxisModel()}},e.prototype.filterData=function(e,t){if(e===this._dataZoomModel){var n=this._dimName,i=this.getTargetSeriesModels(),r=e.get("filterMode"),o=this._valueWindow;"none"!==r&&nw(i,function(e){var t=e.getData(),i=t.mapDimensionsAll(n);if(i.length){if("weakFilter"===r){var a=t.getStore(),s=nC(i,function(e){return t.getDimensionIndex(e)},t);t.filterSelf(function(e){for(var t,n,r,l=0;l<i.length;l++){var d=a.get(s[l],e),u=!isNaN(d),c=d<o[0],h=d>o[1];if(u&&!c&&!h)return!0;u&&(r=!0),c&&(t=!0),h&&(n=!0)}return r&&t&&n})}else nw(i,function(n){if("empty"===r)e.setData(t=t.map(n,function(e){var t;return(t=e)>=o[0]&&t<=o[1]?e:NaN}));else{var i={};i[n]=o,t.selectRange(i)}});nw(i,function(e){t.setApproximateExtent(o,e)})}})}},e.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,n=this._dataExtent;nw(["min","max"],function(i){var r=t.get(i+"Span"),o=t.get(i+"ValueSpan");null!=o&&(o=this.getAxisModel().axis.scale.parse(o)),null!=o?r=aD(n[0]+o,n,[0,100],!0):null!=r&&(o=aD(r,[0,100],n,!0)-n[0]),e[i+"Span"]=r,e[i+"ValueSpan"]=o},this)},e.prototype._setAxisModel=function(){var e=this.getAxisModel(),t=this._percentWindow,n=this._valueWindow;if(t){var i=aL(n,[0,500]);i=Math.min(i,20);var r=e.axis.scale.rawExtentInfo;0!==t[0]&&r.setDeterminedMinMax("min",+n[0].toFixed(i)),100!==t[1]&&r.setDeterminedMinMax("max",+n[1].toFixed(i)),r.freeze()}},e}();let IK={getTargetSeries:function(e){function t(t){e.eachComponent("dataZoom",function(n){n.eachTargetAxis(function(i,r){var o=e.getComponent(Iz(i),r);t(i,r,o,n)})})}t(function(e,t,n,i){n.__dzAxisProxy=null});var n=[];t(function(t,i,r,o){r.__dzAxisProxy||(r.__dzAxisProxy=new Iq(t,i,o,e),n.push(r.__dzAxisProxy))});var i=n1();return nw(n,function(e){nw(e.getTargetSeriesModels(),function(e){i.set(e.uid,e)})}),i},overallReset:function(e,t){e.eachComponent("dataZoom",function(e){e.eachTargetAxis(function(t,n){e.getAxisProxy(t,n).reset(e)}),e.eachTargetAxis(function(n,i){e.getAxisProxy(n,i).filterData(e,t)})}),e.eachComponent("dataZoom",function(e){var t=e.findRepresentativeAxisProxy();if(t){var n=t.getDataPercentWindow(),i=t.getDataValueWindow();e.setCalculatedRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]})}})}};var IY=!1;function IZ(e){IY||(IY=!0,e.registerProcessor(e.PRIORITY.PROCESSOR.FILTER,IK),e.registerAction("dataZoom",function(e,t){nw(function(e,t){var n,i=n1(),r=[],o=n1();e.eachComponent({mainType:"dataZoom",query:t},function(e){o.get(e.uid)||s(e)});do n=!1,e.eachComponent("dataZoom",a);while(n)function a(e){var t;!o.get(e.uid)&&(t=!1,e.eachTargetAxis(function(e,n){var r=i.get(e);r&&r[n]&&(t=!0)}),t)&&(s(e),n=!0)}function s(e){o.set(e.uid,!0),r.push(e),e.eachTargetAxis(function(e,t){(i.get(e)||i.set(e,[]))[t]=!0})}return r}(t,e),function(t){t.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})}),e.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function IX(e){e.registerComponentModel(IW),e.registerComponentView(IU),IZ(e)}var IJ=function(){},IQ={},I0=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.optionUpdated=function(){e.prototype.optionUpdated.apply(this,arguments);var t=this.ecModel;nw(this.option.feature,function(e,n){var i=IQ[n];i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(t)),nh(e,i.defaultOption))})},t.type="toolbox",t.layoutMode={type:"box",ignoreSize:!0}
422,t.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}},t}(u5);function I1(e,t){var n=nU(t.get("padding")),i=t.getItemStyle(["color","opacity"]);return i.fill=t.get("backgroundColor"),e=new lN({shape:{x:e.x-n[3],y:e.y-n[0],width:e.width+n[1]+n[3],height:e.height+n[0]+n[2],r:t.get("borderRadius")},style:i,silent:!0,z2:-1})}var I2=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){var r=this.group;if(r.removeAll(),e.get("show")){var o,a,s,l,d=+e.get("itemSize"),u="vertical"===e.get("orient"),c=e.get("feature")||{},h=this._features||(this._features={}),p=[];nw(c,function(e,t){p.push(t)}),new vU(this._featureNames||[],p).add(f).update(f).remove(nD(f,null)).execute(),this._featureNames=p,o=e.getBoxLayoutParams(),a=e.get("padding"),l=uX(o,s={width:n.getWidth(),height:n.getHeight()},a),uZ(e.get("orient"),r,e.get("itemGap"),l.width,l.height),uJ(r,o,s,a),r.add(I1(r.getBoundingRect(),e)),u||r.eachChild(function(e){var t=e.__title,i=e.ensureState("emphasis"),o=i.textConfig||(i.textConfig={}),a=e.getTextContent(),s=a&&a.ensureState("emphasis");if(s&&!nI(s)&&t){var l=s.style||(s.style={}),u=ai(t,lj.makeFont(l)),c=e.x+r.x,h=e.y+r.y+d,p=!1;h+u.height>n.getHeight()&&(o.position="top",p=!0);var f=p?-5-u.height:d+10;c+u.width/2>n.getWidth()?(o.position=["100%",f],l.align="right"):c-u.width/2<0&&(o.position=[0,f],l.align="left")}})}function f(o,a){var s,l,f,g,m,v,y,b,x,w,C,S=p[o],_=p[a],k=c[S],M=new ua(k,e,e.ecModel);if(i&&null!=i.newTitle&&i.featureName===S&&(k.title=i.newTitle),S&&!_){if(0===S.indexOf("my"))C={onclick:M.option.onclick,featureName:S};else{var T=IQ[S];if(!T)return;C=new T}h[S]=C}else if(!(C=h[_]))return;C.uid=ul("toolbox-feature"),C.model=M,C.ecModel=t,C.api=n;var D=C instanceof IJ;if(!S&&_){D&&C.dispose&&C.dispose(t,n);return}if(!M.get("show")||D&&C.unusable){D&&C.remove&&C.remove(t,n);return}s=M,l=C,f=S,v=s.getModel("iconStyle"),y=s.getModel(["emphasis","iconStyle"]),b=l instanceof IJ&&l.getIcons?l.getIcons():s.get("icon"),x=s.get("title")||{},nA(b)?(g={})[f]=b:g=b,nA(x)?(m={})[f]=x:m=x,w=s.iconPaths={},nw(g,function(i,o){var a=fC(i,{},{x:-d/2,y:-d/2,width:d,height:d});a.setStyle(v.getItemStyle()),a.ensureState("emphasis").style=y.getItemStyle();var c=new lj({style:{text:m[o],align:y.get("textAlign"),borderRadius:y.get("textBorderRadius"),padding:y.get("textPadding"),fill:null,font:d2({fontStyle:y.get("textFontStyle"),fontFamily:y.get("textFontFamily"),fontSize:y.get("textFontSize"),fontWeight:y.get("textFontWeight")},t)},ignore:!0});a.setTextContent(c),fk({el:a,componentModel:e,itemName:o,formatterParamsExtra:{title:m[o]}}),a.__title=m[o],a.on("mouseover",function(){var t=y.getItemStyle(),i=u?null==e.get("right")&&"right"!==e.get("left")?"right":"left":null==e.get("bottom")&&"bottom"!==e.get("top")?"bottom":"top";c.setStyle({fill:y.get("textFill")||t.fill||t.stroke||"#000",backgroundColor:y.get("textBackgroundColor")}),a.setTextConfig({position:y.get("textPosition")||i}),c.ignore=!e.get("showTitle"),n.enterEmphasis(this)}).on("mouseout",function(){"emphasis"!==s.get(["iconStatus",o])&&n.leaveEmphasis(this),c.hide()}),("emphasis"===s.get(["iconStatus",o])?dv:dy)(a),r.add(a),a.on("click",nT(l.onclick,l,t,n,o)),w[o]=a}),M.setIconStatus=function(e,t){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[e]=t,i[e]&&("emphasis"===t?dv:dy)(i[e])},C instanceof IJ&&C.render&&C.render(M,t,n,i)}},t.prototype.updateView=function(e,t,n,i){nw(this._features,function(e){e instanceof IJ&&e.updateView&&e.updateView(e.model,t,n,i)})},t.prototype.remove=function(e,t){nw(this._features,function(n){n instanceof IJ&&n.remove&&n.remove(e,t)}),this.group.removeAll()},t.prototype.dispose=function(e,t){nw(this._features,function(n){n instanceof IJ&&n.dispose&&n.dispose(e,t)})},t.type="toolbox",t}(h9),I3=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.onclick=function(e,t){var n=this.model,i=n.get("name")||e.get("title.0.text")||"echarts",r="svg"===t.getZr().painter.getType(),o=r?"svg":n.get("type",!0)||"png",a=t.getConnectedDataURL({type:o,backgroundColor:n.get("backgroundColor",!0)||e.get("backgroundColor")||"#fff",connectedBackgroun
vendor: 1,361 bytes, line 422
422dColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")}),s=t1.browser;if("function"!=typeof MouseEvent||!s.newEdge&&(s.ie||s.edge))if(window.navigator.msSaveOrOpenBlob||r){var l=a.split(","),d=l[0].indexOf("base64")>-1,u=r?decodeURIComponent(l[1]):l[1];d&&(u=window.atob(u));var c=i+"."+o;if(window.navigator.msSaveOrOpenBlob){for(var h=u.length,p=new Uint8Array(h);h--;)p[h]=u.charCodeAt(h);var f=new Blob([p]);window.navigator.msSaveOrOpenBlob(f,c)}else{var g=document.createElement("iframe");document.body.appendChild(g);var m=g.contentWindow,v=m.document;v.open("image/svg+xml","replace"),v.write(u),v.close(),m.focus(),v.execCommand("SaveAs",!0,c),document.body.removeChild(g)}}else{var y=n.get("lang"),b='<body style="margin:0;"><img src="'+a+'" style="max-width:100%;" title="'+(y&&y[0]||"")+'" /></body>',x=window.open();x.document.write(b),x.document.title=i}else{var w=document.createElement("a");w.download=i+"."+o,w.target="_blank",w.href=a;var C=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});w.dispatchEvent(C)}},t.getDefaultOption=function(e){return{show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:e.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",n
422ame:"",excludeComponents:["toolbox"],lang:e.getLocaleModel().get(["toolbox","saveAsImage","lang"])}},t}(IJ),I5="__ec_magicType_stack__",I4=[["line","bar"],["stack"]],I6=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.getIcons=function(){var e=this.model,t=e.get("icon"),n={};return nw(e.get("type"),function(e){t[e]&&(n[e]=t[e])}),n},t.getDefaultOption=function(e){return{show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:e.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}}},t.prototype.onclick=function(e,t,n){var i,r=this.model,o=r.get(["seriesIndex",n]);if(I8[n]){var a={series:[]};nw(I4,function(e){nv(e,n)>=0&&nw(e,function(e){r.setIconStatus(e,"normal")})}),r.setIconStatus(n,"emphasis"),e.eachComponent({mainType:"series",query:null==o?null:{seriesIndex:o}},function(e){var t=e.subType,i=e.id,o=I8[n](t,i,e,r);o&&(ng(o,e.option),a.series.push(o));var s=e.coordinateSystem;if(s&&"cartesian2d"===s.type&&("line"===n||"bar"===n)){var l=s.getAxesByScale("ordinal")[0];if(l){var d=l.dim+"Axis",u=e.getReferringComponents(d,si).models[0].componentIndex;a[d]=a[d]||[];for(var c=0;c<=u;c++)a[d][u]=a[d][u]||{};a[d][u].boundaryGap="bar"===n}}});var s=n;"stack"===n&&(i=nh({stack:r.option.title.tiled,tiled:r.option.title.stack},r.option.title),"emphasis"!==r.get(["iconStatus",n])&&(s="tiled")),t.dispatchAction({type:"changeMagicType",currentType:s,newOption:a,newTitle:i,featureName:"magicType"})}},t}(IJ),I8={line:function(e,t,n,i){if("bar"===e)return nh({id:t,type:"line",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get(["option","line"])||{},!0)},bar:function(e,t,n,i){if("line"===e)return nh({id:t,type:"bar",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get(["option","bar"])||{},!0)},stack:function(e,t,n,i){var r=n.get("stack")===I5;if("line"===e||"bar"===e)return i.setIconStatus("stack",r?"normal":"emphasis"),nh({id:t,stack:r?"":I5},i.get(["option","stack"])||{},!0)}};mP({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(e,t){t.mergeOption(e.newOption)});var I7=Array(60).join("-");function I9(e){return e.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}var Ae=RegExp("[ ]+","g"),At=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.onclick=function(e,t){setTimeout(function(){t.dispatchAction({type:"hideTip"})});var n,i,r,o,a,s,l=t.getDom(),d=this.model;this._dom&&l.removeChild(this._dom);var u=document.createElement("div");u.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;padding:5px",u.style.backgroundColor=d.get("backgroundColor")||"#fff";var c=document.createElement("h4"),h=d.get("lang")||[];c.innerHTML=h[0]||d.get("title"),c.style.cssText="margin:10px 20px",c.style.color=d.get("textColor");var p=document.createElement("div"),f=document.createElement("textarea");p.style.cssText="overflow:auto";var g=d.get("optionToContent"),m=d.get("contentToOption"),v={value:n_([(o=(s=(n={},i=[],r=[],e.eachRawSeries(function(e){var t=e.coordinateSystem;if(t&&("cartesian2d"===t.type||"polar"===t.type)){var o=t.getBaseAxis();if("category"===o.type){var a=o.dim+"_"+o.index;n[a]||(n[a]={categoryAxis:o,valueAxis:t.getOtherAxis(o),series:[]},r.push({axisDim:o.dim,axisIndex:o.index})),n[a].series.push(e)}else i.push(e)}else i.push(e)}),{seriesGroupByCategoryAxis:n,other:i,meta:r})).seriesGroupByCategoryAxis,a=[],nw(o,function(e,t){var n=e.categoryAxis,i=e.valueAxis.dim,r=[" "].concat(nC(e.series,function(e){return e.name})),o=[n.model.getCategories()];nw(e.series,function(e){var t=e.getRawData();o.push(e.getRawData().mapArray(t.mapDimension(i),function(e){return e}))});for(var s=[r.join(" ")],l=0;l<o[0].length;l++){for(var d=[],u=0;u<o.length;u++)d.push(o[u][l]);s.push(d.join(" "))}a.push(s.join("\n"))}),a.join("\n\n"+I7+"\n\n")),nC(s.other,function(e){var t=e.getRawData(),n=[e.name],i=[];return t.each(t.dimensions,function(){for(var e=arguments.length,r=arguments[e-1],o=t.getName(r),a=0;a<e-1;a++)i[a]=arguments[a];n.push((o?o+" ":"")+i.join(" "))}),n.join("\n")}).join("\n\n"+I7+"\n\n")],function(e){return!!e.replace(/[\n\t\s]/g,"")}).join("\n\n"+I7+"\n\n"),meta:s.meta};if(nI(g)){var y=g(t.getOption());nA(y)?p.innerHTML=y:nN(y)&&p.appendChild(y)}else{f.readOnly=d.get("readOnly");var b=f.style;b.cssText="display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none",b.color=d.get("textColor"),b.borderColor=d.get("textareaBorderColor"),b.backgroundColor=d.get("textareaColor"),f.value=v.value,p.appendChild(f)}var x=v.meta,w=document.createElement("div");w.style.cssText="position:absolute;bottom:5px;left:0;right:0";var C="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",S=document.createElement("div"),_=document.createElement("div");C+=";background-color:"+d.get("buttonColor")+";color:"+d.get("buttonTextColor");var k=this;function M(){l.removeChild(u),k._dom=null}iV(S,"click",M),iV(_,"click",function(){var e,n,i,r;if(null==m&&null!=g||null!=m&&null==g)return void M();try{nI(m)?e=m(p,t.getOption()):(n=f.value,i=n.split(RegExp("\n*"+I7+"\n*","g")),r={series:[]},nw(i,function(e,t){if(function(e){if(e.slice(0,e.indexOf("\n")).indexOf(" ")>=0)return!0}(e)){var n=function(e){for(var t=e.split(/\n+/g),n=I9(t.shift()).split(Ae),i=[],r=nC(n,function(e){return{name:e,data:[]}}),o=0;o<t.length;o++){var a=I9(t[o]).split(Ae);i.push(a.shift());for(var s=0;s<a.length;s++)r[s]&&(r[s].data[o]=a[s])}return{series:r,categories:i}}(e),i=x[t],o=i.axisDim+"Axis";i&&(r[o]=r[o]||[],r[o][i.axisIndex]={data:n.categories},r.series=r.series.concat(n.series))}else{var n=function(e){for(var t=e.split(/\n+/g),n=I9(t.shift()),i=[],r=0;r<t.length;r++){var o=I9(t[r]);if(o){var a=o.split(Ae),s="",l=void 0,d=!1;isNaN(a[0])?(d=!0,s=a[0],a=a.slice(1),i[r]={name:s,value:[]},l=i[r].value):l=i[r]=[];for(var u=0;u<a.length;u++)l.push(+a[u]);1===l.length&&(d?i[r].value=l[0]:i[r]=l[0])}}return{name:n,data:i}}(e);r.series.push(n)}}),e=r)}catch(e){throw M(),Error("Data view format error "+e)}e&&t.dispatchAction({type:"changeDataView",newOption:e}),M()}),S.innerHTML=h[1],_.innerHTML=h[2],_.style.cssText=S.style.cssText=C,d.get("readOnly")||w.appendChild(_),w.appendChild(S),u.appendChild(c),u.appendChild(p),u.appendChild(w),p.style.height=l.clientHeight-80+"px",l.appendChild(u),this._dom=u},t.prototype.remove=function(e,t){this._dom&&t.getDom().removeChild(this._dom)},t.prototype.dispose=function(e,t){this.remove(e,t)},t.getDefaultOption=function(e){return{show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:e.getLocaleModel().get(["toolbox","dataView","title"]),lang:e.getLocaleModel().get(["toolbox","dataView","lang"]),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"}},t}(IJ);mP({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(e,t){var n=[];nw(e.newOption.series,function(e){var i=t.getSeriesByName(e.name)[0];if(i){var r,o=i.get("data");n.push({name:e.name,data:(r=e.data,nC(r,function(e,t){var n=o&&o[t];if(!nL(n)||nR(n))return e;nL(e)&&!nR(e)||(e={value:e});var i=null!=n.name&&null==e.name;return e=ng(e,n),i&&delete e.name,e}))})}else n.push(nf({type:"scatter"},e))}),t.mergeOption(ng({series:n},e.newOption))});var An=a9();function Ai(e){var t=An(e);return t.snapshots||(t.snapshots=[{}]),t.snapshots}var Ar=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.onclick=function(e,t){An(e).snapshots=null,t.dispatchAction({type:"restore",from:this.uid})},t.getDefaultOption=function(e){return{show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:e.getLocaleModel().get(["toolbox","restore","title"])}},t}(IJ);mP({type:"restore",event:"restore",update:"prepareAndUpdate"},function(e,t){t.resetOption("recreate")});var Ao=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],Aa=function(){function e(e,t,n){var i=this;this._targetInfoList=[];var r=Al(t,e);nw(Ad,function(e,t){(!n||!n.include||nv(n.include,t)>=0)&&e(r,i._targetInfoList)})}return e.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(e,t,n){if((e.coordRanges||(e.coordRanges=[])).push(t),!e.coordRange){e.coordRange=t;var i=Ah[e.brushType](0,n,t);e.__rangeOffset={offset:Af[e.brushType](i.values,e.range,[1,1]),xyMinMax:i.xyMinMax}}}),e},e.prototype.matchOutputRanges=function(e,t,n){nw(e,function(e){var i=this.findTargetInfo(e,t);i&&!0!==i&&nw(i.coordSyses,function(i){var r=Ah[e.brushType](1,i,e.range,!0);n(e,r.values,i,t)})},this)},e.prototype.setInputRanges=function(e,t){nw(e,function(e){var n=this.findTargetInfo(e,t);if(e.range=e.range||[],n&&!0!==n){e.panelId=n.panelId;var i,r,o,a,s,l=Ah[e.brushType](0,n.coordSys,e.coordRange),d=e.__rangeOffset;e.range=d?Af[e.brushType](l.values,d.offset,(i=l.xyMinMax,r=d.xyMinMax,o=Am(i),a=Am(r),isNaN((s=[o[0]/a[0],o[1]/a[1]])[0])&&(s[0]=1),isNaN(s[1])&&(s[1]=1),s)):l.values}},this)},e.prototype.makePanelOpts=function(e,t){return nC(this._targetInfoList,function(n){var i=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:t?t(n):null,clipPath:MC(i),isTargetByCursor:M_(i,e,n.coordSysModel),getLinearBrushOtherExtent:MS(i)}})},e.prototype.controlSeries=function(e,t,n){var i=this.findTargetInfo(e,n);return!0===i||i&&nv(i.coordSyses,t.coordinateSystem)>=0},e.prototype.findTargetInfo=function(e,t){for(var n=this._targetInfoList,i=Al(t,e),r=0;r<n.length;r++){var o=n[r],a=e.panelId;if(a){if(o.panelId===a)return o}else for(var s=0;s<Au.length;s++)if(Au[s](i,o))return o}return!0},e}();function As(e){return e[0]>e[1]&&e.reverse(),e}function Al(e,t){return st(e,t,{includeMainTypes:Ao})}var Ad={grid:function(e,t){var n=e.xAxisModels,i=e.yAxisModels,r=e.gridModels,o=n1(),a={},s={};(n||i||r)&&(nw(n,function(e){var t=e.axis.grid.model;o.set(t.id,t),a[t.id]=!0}),nw(i,function(e){var t=e.axis.grid.model;o.set(t.id,t),s[t.id]=!0}),nw(r,function(e){o.set(e.id,e),a[e.id]=!0,s[e.id]=!0}),o.each(function(e){var r=e.coordinateSystem,o=[];nw(r.getCartesians(),function(e,t){(nv(n,e.getAxis("x").model)>=0||nv(i,e.getAxis("y").model)>=0)&&o.push(e)}),t.push({panelId:"grid--"+e.id,gridModel:e,coordSysModel:e,coordSys:o[0],coordSyses:o,getPanelRect:Ac.grid,xAxisDeclared:a[e.id],yAxisDeclared:s[e.id]})}))},geo:function(e,t){nw(e.geoModels,function(e){var n=e.coordinateSystem;t.push({panelId:"geo--"+e.id,geoModel:e,coordSysModel:e,coordSys:n,coordSyses:[n],getPanelRect:Ac.geo})})}},Au=[function(e,t){var n=e.xAxisModel,i=e.yAxisModel,r=e.gridModel;return!r&&n&&(r=n.axis.grid.model),!r&&i&&(r=i.axis.grid.model),r&&r===t.gridModel},function(e,t){var n=e.geoModel;return n&&n===t.geoModel}],Ac={grid:function(){return this.coordSys.master.getRect().clone()}
422,geo:function(){var e=this.coordSys,t=e.getBoundingRect().clone();return t.applyTransform(fm(e)),t}},Ah={lineX:nD(Ap,0),lineY:nD(Ap,1),rect:function(e,t,n,i){var r=e?t.pointToData([n[0][0],n[1][0]],i):t.dataToPoint([n[0][0],n[1][0]],i),o=e?t.pointToData([n[0][1],n[1][1]],i):t.dataToPoint([n[0][1],n[1][1]],i),a=[As([r[0],o[0]]),As([r[1],o[1]])];return{values:a,xyMinMax:a}},polygon:function(e,t,n,i){var r=[[1/0,-1/0],[1/0,-1/0]];return{values:nC(n,function(n){var o=e?t.pointToData(n,i):t.dataToPoint(n,i);return r[0][0]=Math.min(r[0][0],o[0]),r[1][0]=Math.min(r[1][0],o[1]),r[0][1]=Math.max(r[0][1],o[0]),r[1][1]=Math.max(r[1][1],o[1]),o}),xyMinMax:r}}};function Ap(e,t,n,i){var r=n.getAxis(["x","y"][e]),o=As(nC([0,1],function(e){return t?r.coordToData(r.toLocalCoord(i[e]),!0):r.toGlobalCoord(r.dataToCoord(i[e]))})),a=[];return a[e]=o,a[1-e]=[NaN,NaN],{values:o,xyMinMax:a}}var Af={lineX:nD(Ag,0),lineY:nD(Ag,1),rect:function(e,t,n){return[[e[0][0]-n[0]*t[0][0],e[0][1]-n[0]*t[0][1]],[e[1][0]-n[1]*t[1][0],e[1][1]-n[1]*t[1][1]]]},polygon:function(e,t,n){return nC(e,function(e,i){return[e[0]-n[0]*t[i][0],e[1]-n[1]*t[i][1]]})}};function Ag(e,t,n,i){return[t[0]-i[e]*n[0],t[1]-i[e]*n[1]]}function Am(e){return e?[e[0][1]-e[0][0],e[1][1]-e[1][0]]:[NaN,NaN]}var Av=aX+"toolbox-dataZoom_",Ay=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n,i){var r,o,a,s,l,d,u,c,h;this._brushController||(this._brushController=new k1(n.getZr()),this._brushController.on("brush",nT(this._onBrush,this)).mount()),r=e,o=t,a=this,s=i,l=n,d=a._isZoomActive,s&&"takeGlobalCursor"===s.type&&(d="dataZoomSelect"===s.key&&s.dataZoomSelectActive),a._isZoomActive=d,r.setIconStatus("zoom",d?"emphasis":"normal"),u=new Aa(Ax(r),o,{include:["grid"]}).makePanelOpts(l,function(e){return e.xAxisDeclared&&!e.yAxisDeclared?"lineX":!e.xAxisDeclared&&e.yAxisDeclared?"lineY":"rect"}),a._brushController.setPanels(u).enableBrush(!!d&&!!u.length&&{brushType:"auto",brushStyle:r.getModel("brushStyle").getItemStyle()}),c=e,h=t,c.setIconStatus("back",Ai(h).length>1?"emphasis":"normal")},t.prototype.onclick=function(e,t,n){Ab[n].call(this)},t.prototype.remove=function(e,t){this._brushController&&this._brushController.unmount()},t.prototype.dispose=function(e,t){this._brushController&&this._brushController.dispose()},t.prototype._onBrush=function(e){var t=e.areas;if(e.isEnd&&t.length){var n,i,r,o={},a=this.ecModel;this._brushController.updateCovers([]),new Aa(Ax(this.model),a,{include:["grid"]}).matchOutputRanges(t,a,function(e,t,n){if("cartesian2d"===n.type){var i=e.brushType;"rect"===i?(s("x",n,t[0]),s("y",n,t[1])):s({lineX:"x",lineY:"y"}[i],n,t)}}),n=a,i=o,r=Ai(n),nw(i,function(e,t){for(var i=r.length-1;i>=0&&!r[i][t];i--);if(i<0){var o=n.queryComponents({mainType:"dataZoom",subType:"select",id:t})[0];if(o){var a=o.getPercentRange();r[0][t]={dataZoomId:t,start:a[0],end:a[1]}}}}),r.push(i),this._dispatchZoomAction(o)}function s(e,t,n){var i,r,s,l=t.getAxis(e),d=l.model,u=(i=e,r=d,a.eachComponent({mainType:"dataZoom",subType:"select"},function(e){e.getAxisModel(i,r.componentIndex)&&(s=e)}),s),c=u.findRepresentativeAxisProxy(d).getMinMaxSpan();(null!=c.minValueSpan||null!=c.maxValueSpan)&&(n=kF(0,n.slice(),l.scale.getExtent(),0,c.minValueSpan,c.maxValueSpan)),u&&(o[u.id]={dataZoomId:u.id,startValue:n[0],endValue:n[1]})}},t.prototype._dispatchZoomAction=function(e){var t=[];nw(e,function(e,n){t.push(nc(e))}),t.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:t})},t.getDefaultOption=function(e){return{show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:e.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}}},t}(IJ),Ab={zoom:function(){var e=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:e})},back:function(){var e,t,n;this._dispatchZoomAction((t=(e=Ai(this.ecModel))[e.length-1],e.length>1&&e.pop(),n={},nw(t,function(t,i){for(var r=e.length-1;r>=0;r--)if(t=e[r][i]){n[i]=t;break}}),n))}};function Ax(e){var t={xAxisIndex:e.get("xAxisIndex",!0),yAxisIndex:e.get("yAxisIndex",!0),xAxisId:e.get("xAxisId",!0),yAxisId:e.get("yAxisId",!0)};return null==t.xAxisIndex&&null==t.xAxisId&&(t.xAxisIndex="all"),null==t.yAxisIndex&&null==t.yAxisId&&(t.yAxisIndex="all"),t}v=function(e){var t=e.getComponent("toolbox",0),n=["feature","dataZoom"];if(t&&null!=t.get(n)){var i=t.getModel(n),r=[],o=st(e,Ax(i));return nw(o.xAxisModels,function(e){return a(e,"xAxis","xAxisIndex")}),nw(o.yAxisModels,function(e){return a(e,"yAxis","yAxisIndex")}),r}function a(e,t,n){var o=e.componentIndex,a={type:"select",$fromToolbox:!0,filterMode:i.get("filterMode",!0)||"filter",id:Av+t+o};a[n]=o,r.push(a)}},nq(null==cf.get("dataZoom")&&v),cf.set("dataZoom",v);var Aw=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="tooltip",t.dependencies=["axisPointer"],t.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},t}(u5);function AC(e){var t=e.get("confine");return null!=t?!!t:"richText"===e.get("renderMode")}function AS(e){if(t1.domSupported){for(var t=document.documentElement.style,n=0,i=e.length;n<i;n++)if(e[n]in t)return e[n]}}var A_=AS(["transform","webkitTransform","OTransform","MozTransform","msTransform"]);function Ak(e,t){if(!e)return t;t=uB(t,!0);var n=e.indexOf(t);return(e=-1===n?t:"-"+e.slice(0,n)+"-"+t).toLowerCase()}var AM=Ak(AS(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),"transition"),AT=Ak(A_,"transform"),AD="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(t1.transform3dSupported?"will-change:transform;":"");function AR(e,t,n){var i=e.toFixed(0)+"px",r=t.toFixed(0)+"px";if(!t1.transformSupported)return n?"top:"+r+";left:"+i+";":[["top",r],["left",i]];var o=t1.transform3dSupported,a="translate"+(o?"3d":"")+"("+i+","+r+(o?",0":"")+")";return n?"top:0;left:0;"+AT+":"+a+";":[["top",0],["left",0],[A_,a]]}function AI(e,t,n,i,r){var o=t&&t.painter;if(n){var a=o&&o.getViewportRoot();
422a&&iR(iD,a,i,r,!0)&&iR(e,n,iD[0],iD[1])}else{e[0]=i,e[1]=r;var s=o&&o.getViewportRootOffset();s&&(e[0]+=s.offsetLeft,e[1]+=s.offsetTop)}e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var AA=function(){function e(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,t1.wxa)return null;var n=document.createElement("div");n.domBelongToZr=!0,this.el=n;var i=this._zr=e.getZr(),r=t.appendTo,o=r&&(nA(r)?document.querySelector(r):nN(r)?r:nI(r)&&r(e.getDom()));AI(this._styleCoord,i,o,e.getWidth()/2,e.getHeight()/2),(o||e.getDom()).appendChild(n),this._api=e,this._container=o;var a=this;n.onmouseenter=function(){a._enterable&&(clearTimeout(a._hideTimeout),a._show=!0),a._inContent=!0},n.onmousemove=function(e){if(e=e||window.event,!a._enterable){var t=i.handler;ij(i.painter.getViewportRoot(),e,!0),t.dispatch("mousemove",e)}},n.onmouseleave=function(){a._inContent=!1,a._enterable&&a._show&&a.hideLater(a._hideDelay)}}return e.prototype.update=function(e){if(!this._container){var t,n,i=this._api.getDom(),r=(t="position",(n=i.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(i))?t?n[t]:n:null),o=i.style;"absolute"!==o.position&&"absolute"!==r&&(o.position="relative")}var a=e.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this.el.className=e.get("className")||""},e.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n,i,r,o,a,s,l,d,u,c,h,p,f,g,m,v,y,b,x,w,C,S,_=this.el,k=_.style,M=this._styleCoord;_.innerHTML?k.cssText=AD+(n=!this._firstShow,i=this._longHide,r=[],o=e.get("transitionDuration"),a=e.get("backgroundColor"),s=e.get("shadowBlur"),l=e.get("shadowColor"),d=e.get("shadowOffsetX"),u=e.get("shadowOffsetY"),c=e.getModel("textStyle"),h=hY(e,"html"),p=d+"px "+u+"px "+s+"px "+l,r.push("box-shadow:"+p),n&&o&&r.push((g="opacity"+(f=" "+o/2+"s cubic-bezier(0.23,1,0.32,1)")+",visibility"+f,i||(f=" "+o+"s cubic-bezier(0.23,1,0.32,1)",g+=t1.transformSupported?","+AT+f:",left"+f+",top"+f),AM+":"+g)),a&&r.push("background-color:"+a),nw(["width","color","radius"],function(t){var n="border-"+t,i=uB(n),o=e.get(i);null!=o&&r.push(n+":"+o+("color"===t?"":"px"))}),r.push((m=[],v=c.get("fontSize"),(y=c.getTextColor())&&m.push("color:"+y),m.push("font:"+c.getFont()),b=nG(c.get("lineHeight"),Math.round(3*v/2)),v&&m.push("line-height:"+b+"px"),x=c.get("textShadowColor"),w=c.get("textShadowBlur")||0,C=c.get("textShadowOffsetX")||0,S=c.get("textShadowOffsetY")||0,x&&w&&m.push("text-shadow:"+C+"px "+S+"px "+w+"px "+x),nw(["decoration","align"],function(e){var t=c.get(e);t&&m.push("text-"+e+":"+t)}),m.join(";"))),null!=h&&r.push("padding:"+nU(h).join("px ")+"px"),r.join(";")+";")+AR(M[0],M[1],!0)+"border-color:"+uU(t)+";"+(e.get("extraCssText")||"")+";pointer-events:"+(this._enterable?"auto":"none"):k.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},e.prototype.setContent=function(e,t,n,i,r){var o=this.el;if(null==e){o.innerHTML="";return}var a="";if(nA(r)&&"item"===n.get("trigger")&&!AC(n)&&(a=function(e,t,n){if(!nA(n)||"inside"===n)return"";var i,r,o=e.get("backgroundColor"),a=e.get("borderWidth");t=uU(t);var s=i="left"===(i=n)?"right":"right"===i?"left":"top"===i?"bottom":"top",l=Math.max(1.5*Math.round(a),6),d="",u=AT+":";nv(["left","right"],s)>-1?(d+="top:50%",u+="translateY(-50%) rotate("+(r="left"===s?-225:-45)+"deg)"):(d+="left:50%",u+="translateX(-50%) rotate("+(r="top"===s?225:45)+"deg)");var c=r*Math.PI/180,h=l+a,p=h*Math.abs(Math.cos(c))+h*Math.abs(Math.sin(c));d+=";"+s+":-"+Math.round(((p-Math.SQRT2*a)/2+Math.SQRT2*a-(p-h)/2)*100)/100+"px";var f=t+" solid "+a+"px;";return'<div style="'+["position:absolute;width:"+l+"px;height:"+l+"px;z-index:-1;",d+";"+u+";","border-bottom:"+f,"border-right:"+f,"background-color:"+o+";"].join("")+'"></div>'}(n,i,r)),nA(e))o.innerHTML=e+a;else if(e){o.innerHTML="",nR(e)||(e=[e]);for(var s=0;s<e.length;s++)nN(e[s])&&e[s].parentNode!==o&&o.appendChild(e[s]);if(a&&o.childNodes.length){var l=document.createElement("div");l.innerHTML=a,o.appendChild(l)}}},e.prototype.setEnterable=function(e){this._enterable=e},e.prototype.getSize=function(){var e=this.el;return e?[e.offsetWidth,e.offsetHeight]:[0,0]},e.prototype.moveTo=function(e,t){if(this.el){var n=this._styleCoord;if(AI(n,this._zr,this._container,e,t),null!=n[0]&&null!=n[1]){var i=this.el.style;nw(AR(n[0],n[1]),function(e){i[e[0]]=e[1]})}}},e.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},e.prototype.hide=function(){var e=this,t=this.el.style;t.visibility="hidden",t.opacity="0",t1.transform3dSupported&&(t.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},e.prototype.hideLater=function(e){!this._show||this._inContent&&this._enterable||this._alwaysShowContent||(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(nT(this.hide,this),e)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var e=this.el.parentNode;e&&e.removeChild(this.el),this.el=this._container=null},e}(),AP=function(){function e(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),AF(this._styleCoord,this._zr,e.getW
vendor: 10,416 bytes, line 422
422idth()/2,e.getHeight()/2)}return e.prototype.update=function(e){var t=e.get("alwaysShowContent");t&&this._moveIfResized(),this._alwaysShowContent=t},e.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},e.prototype.setContent=function(e,t,n,i,r){var o=this;nL(e)&&cw(""),this.el&&this._zr.remove(this.el);var a=n.getModel("textStyle");this.el=new lj({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:i,textShadowColor:a.get("textShadowColor"),fill:n.get(["textStyle","color"]),padding:hY(n,"richText"),verticalAlign:"top",align:"left"},z:n.get("z")}),nw(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(e){o.el.style[e]=n.get(e)}),nw(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(e){o.el.style[e]=a.get(e)||0}),this._zr.add(this.el);var s=this;this.el.on("mouseover",function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0}),this.el.on("mouseout",function(){s._enterable&&s._show&&s.hideLater(s._hideDelay),s._inContent=!1})},e.prototype.setEnterable=function(e){this._enterable=e},e.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),n=AL(e.style);return[t.width+n.left+n.right,t.height+n.top+n.bottom]},e.prototype.moveTo=function(e,t){var n=this.el;if(n){var i=this._styleCoord;AF(i,this._zr,e,t),e=i[0],t=i[1];var r=n.style,o=AE(r.borderWidth||0),a=AL(r);n.x=e+o+a.left,n.y=t+o+a.top,n.markRedraw()}},e.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},e.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},e.prototype.hideLater=function(e){!this._show||this._inContent&&this._enterable||this._alwaysShowContent||(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(nT(this.hide,this),e)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){this._zr.remove(this.el)},e}();function AE(e){return Math.max(0,e)}function AL(e){var t=AE(e.shadowBlur||0),n=AE(e.shadowOffsetX||0),i=AE(e.shadowOffsetY||0);return{left:AE(t-n),right:AE(t+n),top:AE(t-i),bottom:AE(t+i)}}function AF(e,t,n,i){e[0]=n,e[1]=i,e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var AO=new lN({shape:{x:-1,y:-1,width:2,height:2}}),AN=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){if(!t1.node&&t.getDom()){var n,i=e.getComponent("tooltip"),r=this._renderMode="auto"===(n=i.get("renderMode"))?t1.domSupported?"html":"richText":n||"html";this._tooltipContent="richText"===r?new AP(t):new AA(t,{appendTo:i.get("appendToBody",!0)?"body":i.get("appendTo",!0)})}},t.prototype.render=function(e,t,n){if(!t1.node&&n.getDom()){this.group.removeAll(),this._tooltipModel=e,this._ecModel=t,this._api=n;var i=this._tooltipContent;i.update(e),i.setEnterable(e.get("enterable")),this._initGlobalListener(),this._keepShow(),"richText"!==this._renderMode&&e.get("transitionDuration")?fj(this,"_updatePosition",50,"fixRate"):fV(this,"_updatePosition")}},t.prototype._initGlobalListener=function(){var e=this._tooltipModel.get("triggerOn");Rw("itemTooltip",this._api,nT(function(t,n,i){"none"!==e&&(e.indexOf(t)>=0?this._tryShow(n,i):"leave"===t&&this._hide(i))},this))},t.prototype._keepShow=function(){var e=this._tooltipModel,t=this._ecModel,n=this._api,i=e.get("triggerOn");if(null!=this._lastX&&null!=this._lastY&&"none"!==i&&"click"!==i){var r=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){n.isDisposed()||r.manuallyShowTip(e,t,n,{x:r._lastX,y:r._lastY,dataByCoordSys:r._lastDataByCoordSys})})}},t.prototype.manuallyShowTip=function(e,t,n,i){if(i.from!==this.uid&&!t1.node&&n.getDom()){var r=Az(i,n);this._ticket="";var o=i.dataByCoordSys,a=function(e,t,n){var i,r=sn(e).queryOptionMap,o=r.keys()[0];if(o&&"series"!==o){var a=so(t,o,r.get(o),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(a&&(n.getViewOfComponentModel(a).group.traverse(function(t){var n=lQ(t).tooltipConfig;if(n&&n.name===e.name)return i=t,!0}),i))return{componentMainType:o,componentIndex:a.componentIndex,el:i}}}(i,t,n);if(a){var s=a.el.getBoundingRect().clone();s.applyTransform(a.el.transform),this._tryShow({offsetX:s.x+s.width/2,offsetY:s.y+s.height/2,target:a.el,position:i.position,positionDefault:"bottom"},r)}else if(i.tooltip&&null!=i.x&&null!=i.y)AO.x=i.x,AO.y=i.y,AO.update(),lQ(AO).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:AO},r);else if(o)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:o,tooltipOption:i.tooltipOption},r);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(e,t,n,i))return;var l=RM(i,t),d=l.point[0],u=l.point[1];null!=d&&null!=u&&this._tryShow({offsetX:d,offsetY:u,target:l.el,position:i.position,positionDefault:"bottom"},r)}else null!=i.x&&null!=i.y&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target},r))}},t.prototype.manuallyHideTip=function(e,t,n,i){var r=this._tooltipContent;this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(Az(i,n))},t.prototype._manuallyAxisShowTip=function(e,t,n,i){var r=i.seriesIndex,o=i.dataIndex,a=t.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=o&&null!=a){var s=t.getSeriesByIndex(r);if(s&&"axis"===AB([s.getData().getItemModel(o),s,(s.coordinateSystem||{}).model],this._tooltipModel).get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:o,position:i.position}),!0}},t.prototype._tryShow=function(e,t){var n=e.target;if(this._tooltipModel){this._lastX=e.offsetX,this._lastY=e.offsetY;var i,r,o=e.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,e);else if(n){if("legend"===lQ(n).ssrType)return;this._lastDataByCoordSys=null,gh(n,function(e){return null!=lQ(e).dataIndex?(i=e,!0):null!=lQ(e).tooltipConfig?(r=e,!0):void 0},!0),i?this._showSeriesItemTooltip(e,i,t):r?this._showComponentItemTooltip(e,r,t):this._hide(t)}else this._lastDataByCoordSys=null,this._hide(t)}},t.prototype._showOrMove=function(e,t){var n=e.get("showDelay");t=nT(t,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(t,n):t()},t.prototype._showAxisTooltip=function(e,t){var n=this._ecModel,i=this._tooltipModel,r=[t.offsetX,t.offsetY],o=AB([t.tooltipOption],i),a=this._renderMode,s=[],l=hV("section",{blocks:[],noHeader:!0}),d=[],u=new hZ;nw(e,function(e){nw(e.dataByAxis,function(e){var t=n.getComponent(e.axisDim+"Axis",e.axisIndex),r=e.value;if(t&&null!=r){var o=Rd(r,t.axis,n,e.seriesDataIndices,e.valueLabelOpt),c=hV("section",{header:o,noHeader:!nK(o),sortBlocks:!0,blocks:[]});l.blocks.push(c),nw(e.seriesDataIndices,function(l){var h=n.getSeriesByIndex(l.seriesIndex),p=l.dataIndexInside,f=h.getDataParams(p);if(!(f.dataIndex<0)){f.axisDim=e.axisDim,f.axisIndex=e.axisIndex,f.axisType=e.axisType,f.axisId=e.axisId,f.axisValue=xG(t.axis,{value:r}),f.axisValueLabel=o,f.marker=u.makeTooltipMarker("item",uU(f.color),a);var g=ha(h.formatTooltip(p,!0,null)),m=g.frag;if(m){var v=AB([h],i).get("valueFormatter");c.blocks.push(v?nf({valueFormatter:v},m):m)}g.text&&d.push(g.text),s.push(f)}})}})}),l.blocks.reverse(),d.reverse();var c=t.position,h=h$(l,u,a,o.get("order"),n.get("useUTC"),o.get("textStyle"));h&&d.unshift(h);var p="richText"===a?"\n\n":"<br/>",f=d.join(p);this._showOrMove(o,function(){this._updateContentNotChangedOnAxis(e,s)?this._updatePosition(o,c,r[0],r[1],this._tooltipContent,s):this._showTooltipContent(o,f,s,Math.random()+"",r[0],r[1],c,null,u)})},t.prototype._showSeriesItemTooltip=function(e,t,n){var i=this._ecModel,r=lQ(t),o=r.seriesIndex,a=i.getSeriesByIndex(o),s=r.dataModel||a,l=r.dataIndex,d=r.dataType,u=s.getData(d),c=this._renderMode,h=e.positionDefault,p=AB([u.getItemModel(l),s,a&&(a.coordinateSystem||{}).model],this._tooltipModel,h?{position:h}:null),f=p.get("trigger");if(null==f||"item"===f){var g=s.getDataParams(l,d),m=new hZ;g.marker=m.makeTooltipMarker("item",uU(g.color),c);var v=ha(s.formatTooltip(l,!1,d)),y=p.get("order"),b=p.get("valueFormatter"),x=v.frag,w=x?h$(b?nf({valueFormatter:b},x):x,m,c,y,i.get("useUTC"),p.get("textStyle")):v.text,C="item_"+s.name+"_"+l;this._showOrMove(p,function(){this._showTooltipContent(p,w,g,C,e.offsetX,e.offsetY,e.position,e.target,m)}),n({type:"showTip",dataIndexInside:l,dataIndex:u.getRawIndex(l),seriesIndex:o,from:this.uid})}},t.prototype._showComponentItemTooltip=function(e,t,n){var i="html"===this._renderMode,r=lQ(t),o=r.tooltipConfig.option||{},a=o.encodeHTMLContent;if(nA(o)){var s=o;o={content:s,formatter:s},a=!0}a&&i&&o.content&&((o=nc(o)).content=iE(o.content));var l=[o],d=this._ecModel.getComponent(r.componentMainType,r.componentIndex);d&&l.push(d),l.push({formatter:o.content});var u=e.positionDefault,c=AB(l,this._tooltipModel,u?{position:u}:null),h=c.get("content"),p=Math.random()+"",f=new hZ;this._showOrMove(c,function(){var n=nc(c.get("formatterParams")||{});this._showTooltipContent(c,h,n,p,e.offsetX,e.offsetY,e.position,t,f)}),n({type:"showTip",from:this.uid})},t.prototype._showTooltipContent=function(e,t,n,i,r,o,a,s,l){if(this._ticket="",e.get("showContent")&&e.get("show")){var d=this._tooltipContent;d.setEnterable(e.get("enterable"));var u=e.get("formatter");a=a||e.get("position");var c=t,h=this._getNearestPoint([r,o],n,e.get("trigger"),e.get("borderColor")).color;if(u)if(nA(u)){var p=e.ecModel.get("useUTC"),f=nR(n)?n[0]:n,g=f&&f.axisType&&f.axisType.indexOf("time")>=0;c=u,g&&(c=uw(f.axisValue,c,p)),c=uH(c,n,!0)}else if(nI(u)){var m=nT(function(t,i){t===this._ticket&&(d.setContent(i,l,e,h,a),this._updatePosition(e,a,r,o,d,n,s))},this);this._ticket=i,c=u(n,i,m)}else c=u;d.setContent(c,l,e,h,a),d.show(e,h),this._updatePosition(e,a,r,o,d,n,s)}},t.prototype._getNearestPoint=function(e,t,n,i){return"axis"===n||nR(t)?{color:i||("html"===this._renderMode?"#fff":"none")}:nR(t)?void 0:{color:i||t.color||t.borderColor}},t.prototype._updatePosition=function(e,t,n,i,r,o,a){var s=this._api.getWidth(),l=this._api.getHeight();t=t||e.get("position");var d=r.getSize(),u=e.get("align"),c=e.get("verticalAlign"),h=a&&a.getBoundingRect
422().clone();if(a&&h.applyTransform(a.transform),nI(t)&&(t=t([n,i],o,r.el,h,{viewSize:[s,l],contentSize:d.slice()})),nR(t))n=aR(t[0],s),i=aR(t[1],l);else if(nL(t)){var p=t;p.width=d[0],p.height=d[1];var f=uX(p,{width:s,height:l});n=f.x,i=f.y,u=null,c=null}else if(nA(t)&&a){var g=function(e,t,n,i){var r=n[0],o=n[1],a=Math.ceil(Math.SQRT2*i)+8,s=0,l=0,d=t.width,u=t.height;switch(e){case"inside":s=t.x+d/2-r/2,l=t.y+u/2-o/2;break;case"top":s=t.x+d/2-r/2,l=t.y-o-a;break;case"bottom":s=t.x+d/2-r/2,l=t.y+u+a;break;case"left":s=t.x-r-a,l=t.y+u/2-o/2;break;case"right":s=t.x+d+a,l=t.y+u/2-o/2}return[s,l]}(t,h,d,e.get("borderWidth"));n=g[0],i=g[1]}else{var m,v,y,b,x,w,C,S,_,k,g=(m=n,v=i,y=r,b=s,x=l,w=u?null:20,C=c?null:20,_=(S=y.getSize())[0],k=S[1],null!=w&&(m+_+w+2>b?m-=_+w:m+=w),null!=C&&(v+k+C>x?v-=k+C:v+=C),[m,v]);n=g[0],i=g[1]}if(u&&(n-=Aj(u)?d[0]/2:"right"===u?d[0]:0),c&&(i-=Aj(c)?d[1]/2:"bottom"===c?d[1]:0),AC(e)){var M,T,D,R,I,A,P,E,g=(M=n,T=i,D=r,R=s,I=l,P=(A=D.getSize())[0],E=A[1],M=Math.min(M+P,R)-P,T=Math.min(T+E,I)-E,[M=Math.max(M,0),T=Math.max(T,0)]);n=g[0],i=g[1]}r.moveTo(n,i)},t.prototype._updateContentNotChangedOnAxis=function(e,t){var n=this._lastDataByCoordSys,i=this._cbParamsList,r=!!n&&n.length===e.length;return r&&nw(n,function(n,o){var a=n.dataByAxis||[],s=(e[o]||{}).dataByAxis||[];(r=r&&a.length===s.length)&&nw(a,function(e,n){var o=s[n]||{},a=e.seriesDataIndices||[],l=o.seriesDataIndices||[];(r=r&&e.value===o.value&&e.axisType===o.axisType&&e.axisId===o.axisId&&a.length===l.length)&&nw(a,function(e,t){var n=l[t];r=r&&e.seriesIndex===n.seriesIndex&&e.dataIndex===n.dataIndex}),i&&nw(e.seriesDataIndices,function(e){var n=e.seriesIndex,o=t[n],a=i[n];o&&a&&a.data!==o.data&&(r=!1)})})}),this._lastDataByCoordSys=e,this._cbParamsList=t,!!r},t.prototype._hide=function(e){this._lastDataByCoordSys=null,e({type:"hideTip",from:this.uid})},t.prototype.dispose=function(e,t){!t1.node&&t.getDom()&&(fV(this,"_updatePosition"),this._tooltipContent.dispose(),R_("itemTooltip",t))},t.type="tooltip",t}(h9);function AB(e,t,n){var i,r=t.ecModel;n?(i=new ua(n,r,r),i=new ua(t.option,i,r)):i=t;for(var o=e.length-1;o>=0;o--){var a=e[o];a&&(a instanceof ua&&(a=a.get("tooltip",!0)),nA(a)&&(a={formatter:a}),a&&(i=new ua(a,i,r)))}return i}function Az(e,t){return e.dispatchAction||nT(t.dispatchAction,t)}function Aj(e){return"center"===e||"middle"===e}var AV=["rect","polygon","keep","clear"];function AH(e,t){var n=aJ(e?e.brush:[]);if(n.length){var i,r,o=[];nw(n,function(e){var t=e.hasOwnProperty("toolbox")?e.toolbox:[];t instanceof Array&&(o=o.concat(t))});var a=e&&e.toolbox;nR(a)&&(a=a[0]),a||(e.toolbox=[a={feature:{}}]);var s=a.feature||(a.feature={}),l=s.brush||(s.brush={}),d=l.type||(l.type=[]);d.push.apply(d,o),r={},nw(i=d,function(e){r[e]=1}),i.length=0,nw(r,function(e,t){i.push(t)}),t&&!d.length&&d.push.apply(d,AV)}}function AG(e){if(e){for(var t in e)if(e.hasOwnProperty(t))return!0}}function AW(e,t,n){var i={};return nw(t,function(t){var r,o=i[t]=((r=function(){}).prototype.__hidden=r.prototype,new r);nw(e[t],function(e,i){if(S5.isValidType(i)){var r={type:i,visual:e};n&&n(r,t),o[i]=new S5(r),"opacity"===i&&((r=nc(r)).type="colorAlpha",o.__hidden.__alphaForOpacity=new S5(r))}})}),i}function A$(e,t,n){var i;nw(n,function(e){t.hasOwnProperty(e)&&AG(t[e])&&(i=!0)}),i&&nw(n,function(n){t.hasOwnProperty(n)&&AG(t[n])?e[n]=nc(t[n]):delete e[n]})}var AU={lineX:Aq(0),lineY:Aq(1),rect:{point:function(e,t,n){return e&&n.boundingRect.contain(e[0],e[1])},rect:function(e,t,n){return e&&n.boundingRect.intersect(e)}},polygon:{point:function(e,t,n){return e&&n.boundingRect.contain(e[0],e[1])&&Cm(n.range,e[0],e[1])},rect:function(e,t,n){var i=n.range;if(!e||i.length<=1)return!1;var r=e.x,o=e.y,a=e.width,s=e.height,l=i[0];if(Cm(i,r,o)||Cm(i,r+a,o)||Cm(i,r,o+s)||Cm(i,r+a,o+s)||rt.create(e).contain(l[0],l[1])||fS(r,o,r+a,o,i)||fS(r,o,r,o+s,i)||fS(r+a,o,r+a,o+s,i)||fS(r,o+s,r+a,o+s,i))return!0}}};function Aq(e){var t=["x","y"],n=["width","height"];return{point:function(t,n,i){if(t){var r=i.range;return AK(t[e],r)}},rect:function(i,r,o){if(i){var a=o.range,s=[i[t[e]],i[t[e]]+i[n[e]]];return s[1]<s[0]&&s.reverse(),AK(s[0],a)||AK(s[1],a)||AK(a[0],s)||AK(a[1],s)}}}}function AK(e,t){return t[0]<=e&&e<=t[1]}var AY=["inBrush","outOfBrush"],AZ="__ecBrushSelect",AX="__ecInBrushSelectEvent";function AJ(e){e.eachComponent({mainType:"brush"},function(t){(t.brushTargetManager=new Aa(t.option,e)).setInputRanges(t.areas,e)})}function AQ(e,t,n){var i,r,o=[];e.eachComponent({mainType:"brush"},function(e){n&&"takeGlobalCursor"===n.type&&e.setBrushOption("brush"===n.key?n.brushOption:{brushType:!1})}),AJ(e),e.eachComponent({mainType:"brush"}
422,function(t,n){var a={brushId:t.id,brushIndex:n,brushName:t.name,areas:nc(t.areas),selected:[]};o.push(a);var s=t.option,l=s.brushLink,d=[],u=[],c=[],h=!1;n||(i=s.throttleType,r=s.throttleDelay);var p=nC(t.areas,function(e){var t,n,i=A2[e.brushType],r=ng({boundingRect:i?i(e):void 0},e);return t=r.brushType,r.selectors=n={point:function(e){return AU[t].point(e,n,r)},rect:function(e){return AU[t].rect(e,n,r)}},r}),f=AW(t.option,AY,function(e){e.mappingMethod="fixed"});function g(e){return"all"===l||!!d[e]}function m(e){return!!e.length}nR(l)&&nw(l,function(e){d[e]=1}),e.eachSeries(function(n,i){var r,o,a,s=c[i]=[];"parallel"===n.subType?(r=n,o=i,a=r.coordinateSystem,h=h||a.hasAxisBrushed(),g(o)&&a.eachActiveState(r.getData(),function(e,t){"active"===e&&(u[t]=1)})):function(n,i,r){if(!(!n.brushSelector||(o=t,a=i,null!=(s=o.option.seriesIndex)&&"all"!==s&&(nR(s)?0>nv(s,a):a!==s)))&&(nw(p,function(i){t.brushTargetManager.controlSeries(i,n,e)&&r.push(i),h=h||m(r)}),g(i)&&m(r))){var o,a,s,l=n.getData();l.each(function(e){A1(n,r,l,e)&&(u[e]=1)})}}(n,i,s)}),e.eachSeries(function(e,t){var n={seriesId:e.id,seriesIndex:t,seriesName:e.name,dataIndex:[]};a.selected.push(n);var i=c[t],r=e.getData(),o=g(t)?function(e){return u[e]?(n.dataIndex.push(r.getRawIndex(e)),"inBrush"):"outOfBrush"}:function(t){return A1(e,i,r,t)?(n.dataIndex.push(r.getRawIndex(t)),"inBrush"):"outOfBrush"};(g(t)?h:m(i))&&function(e,t,n,i,r,o){var a,s={};function l(e){return gs(n,a,e)}function d(e,t){gd(n,a,e,t)}nw(e,function(e){var n=S5.prepareVisualTypes(t[e]);s[e]=n}),n.each(function(e,r){a=e;var o=n.getRawDataItem(a);if(!o||!1!==o.visualMap)for(var u=i.call(void 0,e),c=t[u],h=s[u],p=0,f=h.length;p<f;p++){var g=h[p];c[g]&&c[g].applyVisual(e,l,d)}})}(AY,f,r,o)})}),function(e,t,n,i,r){if(r){var o=e.getZr();o[AX]||(o[AZ]||(o[AZ]=A0),fj(o,AZ,n,t)(e,i))}}(t,i,r,o,n)}function A0(e,t){if(!e.isDisposed()){var n=e.getZr();n[AX]=!0,e.dispatchAction({type:"brushSelect",batch:t}),n[AX]=!1}}function A1(e,t,n,i){for(var r=0,o=t.length;r<o;r++){var a=t[r];if(e.brushSelector(i,n,a.selectors,a))return!0}}var A2={rect:function(e){return A3(e.range)},polygon:function(e){for(var t,n=e.range,i=0,r=n.length;i<r;i++){t=t||[[1/0,-1/0],[1/0,-1/0]];var o=n[i];o[0]<t[0][0]&&(t[0][0]=o[0]),o[0]>t[0][1]&&(t[0][1]=o[0]),o[1]<t[1][0]&&(t[1][0]=o[1]),o[1]>t[1][1]&&(t[1][1]=o[1])}return t&&A3(t)}};function A3(e){return new rt(e[0][0],e[1][0],e[0][1]-e[0][0],e[1][1]-e[1][0])}var A5=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){this.ecModel=e,this.api=t,this.model,(this._brushController=new k1(t.getZr())).on("brush",nT(this._onBrush,this)).mount()},t.prototype.render=function(e,t,n,i){this.model=e,this._updateController(e,t,n,i)},t.prototype.updateTransform=function(e,t,n,i){AJ(t),this._updateController(e,t,n,i)},t.prototype.updateVisual=function(e,t,n,i){this.updateTransform(e,t,n,i)},t.prototype.updateView=function(e,t,n,i){this._updateController(e,t,n,i)},t.prototype._updateController=function(e,t,n,i){i&&i.$from===e.id||this._brushController.setPanels(e.brushTargetManager.makePanelOpts(n)).enableBrush(e.brushOption).updateCovers(e.areas.slice())},t.prototype.dispose=function(){this._brushController.dispose()},t.prototype._onBrush=function(e){var t=this.model.id,n=this.model.brushTargetManager.setOutputRanges(e.areas,this.ecModel);(!e.isEnd||e.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:t,areas:nc(n),$from:t}),e.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:t,areas:nc(n),$from:t})},t.type="brush",t}(h9),A4=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.areas=[],n.brushOption={},n}return(0,tQ.__extends)(t,e),t.prototype.optionUpdated=function(e,t){var n=this.option;t||A$(n,e,["inBrush","outOfBrush"]);var i=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:"#ddd"},i.hasOwnProperty("liftZ")||(i.liftZ=5)},t.prototype.setAreas=function(e){e&&(this.areas=nC(e,function(e){return A6(this.option,e)},this))},t.prototype.setBrushOption=function(e){this.brushOption=A6(this.option,e),this.brushType=this.brushOption.brushType},t.type="brush",t.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],t.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},t}(u5);function A6(e,t){return nh({brushType:e.brushType,brushMode:e.brushMode,transformable:e.transformable,brushStyle:new ua(e.brushStyle).getItemStyle(),removeOnClick:e.removeOnClick,z:e.z},t,!0)}var A8=["rect","polygon","lineX","lineY","keep","clear"],A7=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){var i,r,o;t.eachComponent({mainType:"brush"},function(e){i=e.brushType,r=e.brushOption.brushMode||"single",o=o||!!e.areas.length}
vendor: 4,229 bytes, line 422
422),this._brushType=i,this._brushMode=r,nw(e.get("type",!0),function(t){e.setIconStatus(t,("keep"===t?"multiple"===r:"clear"===t?o:t===i)?"emphasis":"normal")})},t.prototype.updateView=function(e,t,n){this.render(e,t,n)},t.prototype.getIcons=function(){var e=this.model,t=e.get("icon",!0),n={};return nw(e.get("type",!0),function(e){t[e]&&(n[e]=t[e])}),n},t.prototype.onclick=function(e,t,n){var i=this._brushType,r=this._brushMode;"clear"===n?(t.dispatchAction({type:"axisAreaSelect",intervals:[]}),t.dispatchAction({type:"brush",command:"clear",areas:[]})):t.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:"keep"===n?i:i!==n&&n,brushMode:"keep"===n?"multiple"===r?"single":"multiple":r}})},t.getDefaultOption=function(e){return{show:!0,type:A8.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:e.getLocaleModel().get(["toolbox","brush","title"])}},t}(IJ),A9=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.layoutMode={type:"box",ignoreSize:!0},n}return(0,tQ.__extends)(t,e),t.type="title",t.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}},t}(u5),Pe=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.render=function(e,t,n){if(this.group.removeAll(),e.get("show")){var i=this.group,r=e.getModel("textStyle"),o=e.getModel("subtextStyle"),a=e.get("textAlign"),s=nG(e.get("textBaseline"),e.get("textVerticalAlign")),l=new lj({style:dZ(r,{text:e.get("text"),fill:r.getTextColor()},{disableBox:!0}),z2:10}),d=l.getBoundingRect(),u=e.get("subtext"),c=new lj({style:dZ(o,{text:u,fill:o.getTextColor(),y:d.height+e.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),h=e.get("link"),p=e.get("sublink"),f=e.get("triggerEvent",!0);l.silent=!h&&!f,c.silent=!p&&!f,h&&l.on("click",function(){uq(h,"_"+e.get("target"))}),p&&c.on("click",function(){uq(p,"_"+e.get("subtarget"))}),lQ(l).eventData=lQ(c).eventData=f?{componentType:"title",componentIndex:e.componentIndex}:null,i.add(l),u&&i.add(c);var g=i.getBoundingRect(),m=e.getBoxLayoutParams();m.width=g.width,m.height=g.height;var v=uX(m,{width:n.getWidth(),height:n.getHeight()},e.get("padding"));a||("middle"===(a=e.get("left")||e.get("right"))&&(a="center"),"right"===a?v.x+=v.width:"center"===a&&(v.x+=v.width/2)),s||("center"===(s=e.get("top")||e.get("bottom"))&&(s="middle"),"bottom"===s?v.y+=v.height:"middle"===s&&(v.y+=v.height/2),s=s||"top"),i.x=v.x,i.y=v.y,i.markRedraw();var y={align:a,verticalAlign:s};
422l.setStyle(y),c.setStyle(y),g=i.getBoundingRect();var b=v.margin,x=e.getItemStyle(["color","opacity"]);x.fill=e.get("backgroundColor");var w=new lN({shape:{x:g.x-b[3],y:g.y-b[0],width:g.width+b[1]+b[3],height:g.height+b[0]+b[2],r:e.get("borderRadius")},style:x,subPixelOptimize:!0,silent:!0});i.add(w)}},t.type="title",t}(h9),Pt=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.layoutMode="box",n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n),this._initData()},t.prototype.mergeOption=function(t){e.prototype.mergeOption.apply(this,arguments),this._initData()},t.prototype.setCurrentIndex=function(e){null==e&&(e=this.option.currentIndex);var t=this._data.count();this.option.loop?e=(e%t+t)%t:(e>=t&&(e=t-1),e<0&&(e=0)),this.option.currentIndex=e},t.prototype.getCurrentIndex=function(){return this.option.currentIndex},t.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},t.prototype.setPlayState=function(e){this.option.autoPlay=!!e},t.prototype.getPlayState=function(){return!!this.option.autoPlay},t.prototype._initData=function(){var e,t=this.option,n=t.data||[],i=t.axisType,r=this._names=[];"category"===i?(e=[],nw(n,function(t,n){var i,o=a4(a1(t),"");nL(t)?(i=nc(t)).value=n:i=n,e.push(i),r.push(o)})):e=n,(this._data=new v8([{name:"value",type:{category:"ordinal",time:"time",value:"number"}[i]||"number"}],this)).initData(e,r)},t.prototype.getData=function(){return this._data},t.prototype.getCategories=function(){if("category"===this.get("axisType"))return this._names.slice()},t.type="timeline",t.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},t}(u5),Pn=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="timeline.slider",t.defaultOption=ud(Pt.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),t}(Pt);nb(Pn,ho.prototype);var Pi=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="timeline",t}(h9),Pr=function(e){function t(t,n,i,r){var o=e.call(this,t,n,i)||this;return o.type=r||"value",o}return(0,tQ.__extends)(t,e),t.prototype.getLabelModel=function(){return this.model.getModel("label")},t.prototype.isHorizontal=function(){return"horizontal"===this.model.get("orient")},t}(x6),Po=Math.PI,Pa=a9(),Ps=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){this.api=t},t.prototype.render=function(e,t,n){if(this.model=e,this.api=n,this.ecModel=t,this.group.removeAll(),e.get("show",!0)){var i=this._layout(e,n),r=this._createGroup("_mainGroup"),o=this._createGroup("_labelGroup"),a=this._axis=this._createAxis(i,e);e.formatTooltip=function(e){return hV("nameValue",{noName:!0,value:a.scale.getLabel({value:e})})},nw(["AxisLine","AxisTick","Control","CurrentPointer"],function(t){this["_render"+t](i,r,a,e)},this),this._renderAxisLabel(i,o,a,e),this._position(i,e)}this._doPlayStop(),this._updateTicksStatus()},t.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},t.prototype.dispose=function(){this._clearTimer()},t.prototype._layout=function(e,t){var n,i,r,o,a,s,l=e.get(["label","position"]),d=e.get("orient"),u=(n=e,i=t,uX(n.getBoxLayoutParams(),{width:i.getWidth(),height:i.getHeight()},n.get("padding"))),c={horizontal:"center",vertical:(r=null==l||"auto"===l?"horizontal"===d?u.y+u.he
422ight/2<t.getHeight()/2?"-":"+":u.x+u.width/2<t.getWidth()/2?"+":"-":nA(l)?({horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}})[d][l]:l)>=0||"+"===r?"left":"right"},h="vertical"===d?u.height:u.width,p=e.getModel("controlStyle"),f=p.get("show",!0),g=f?p.get("itemSize"):0,m=f?p.get("itemGap"):0,v=g+m,y=e.get(["label","rotate"])||0;y=y*Po/180;var b=p.get("position",!0),x=f&&p.get("showPlayBtn",!0),w=f&&p.get("showPrevBtn",!0),C=f&&p.get("showNextBtn",!0),S=0,_=h;"left"===b||"bottom"===b?(x&&(o=[0,0],S+=v),w&&(a=[S,0],S+=v)):(x&&(o=[_-g,0],_-=v),w&&(a=[0,0],S+=v)),C&&(s=[_-g,0],_-=v);var k=[S,_];return e.get("inverse")&&k.reverse(),{viewRect:u,mainLength:h,orient:d,rotation:({horizontal:0,vertical:Po/2})[d],labelRotation:y,labelPosOpt:r,labelAlign:e.get(["label","align"])||c[d],labelBaseline:e.get(["label","verticalAlign"])||e.get(["label","baseline"])||({horizontal:r>=0||"+"===r?"top":"bottom",vertical:"middle"})[d],playPosition:o,prevBtnPosition:a,nextBtnPosition:s,axisExtent:k,controlSize:g,controlGap:m}},t.prototype._position=function(e,t){var n=this._mainGroup,i=this._labelGroup,r=e.viewRect;if("vertical"===e.orient){var o=iq(),a=r.x,s=r.y+r.height;iX(o,o,[-a,-s]),iJ(o,o,-Po/2),iX(o,o,[a,s]),(r=r.clone()).applyTransform(o)}var l=m(r),d=m(n.getBoundingRect()),u=m(i.getBoundingRect()),c=[n.x,n.y],h=[i.x,i.y];h[0]=c[0]=l[0][0];var p=e.labelPosOpt;if(null==p||nA(p)){var f=+("+"!==p);v(c,d,l,1,f),v(h,u,l,1,1-f)}else{var f=p>=0?0:1;v(c,d,l,1,f),h[1]=c[1]+p}function g(e){e.originX=l[0][0]-e.x,e.originY=l[1][0]-e.y}function m(e){return[[e.x,e.x+e.width],[e.y,e.y+e.height]]}function v(e,t,n,i,r){e[i]+=n[i][r]-t[i][r]}n.setPosition(c),i.setPosition(h),n.rotation=i.rotation=e.rotation,g(n),g(i)},t.prototype._createAxis=function(e,t){var n=t.getData(),i=t.get("axisType"),r=function(e,t){if(t=t||e.get("type"))switch(t){case"category":return new xx({ordinalMeta:e.getCategories(),extent:[1/0,-1/0]});case"time":return new xS({locale:e.ecModel.getLocaleModel(),useUTC:e.ecModel.get("useUTC")});default:return new xw}}(t,i);r.getTicks=function(){return n.mapArray(["value"],function(e){return{value:e}})};var o=n.getDataExtent("value");r.setExtent(o[0],o[1]),r.calcNiceTicks();
422var a=new Pr("value",r,e.axisExtent,i);return a.model=t,a},t.prototype._createGroup=function(e){var t=this[e]=new av;return this.group.add(t),t},t.prototype._renderAxisLine=function(e,t,n,i){var r=n.getExtent();if(i.get(["lineStyle","show"])){var o=new pU({shape:{x1:r[0],y1:0,x2:r[1],y2:0},style:nf({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});t.add(o);var a=this._progressLine=new pU({shape:{x1:r[0],x2:this._currentPointer?this._currentPointer.x:r[0],y1:0,y2:0},style:ng({lineCap:"round",lineWidth:o.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});t.add(a)}},t.prototype._renderAxisTick=function(e,t,n,i){var r=this,o=i.getData(),a=n.scale.getTicks();this._tickSymbols=[],nw(a,function(e){var a=n.dataToCoord(e.value),s=o.getItemModel(e.value),l=s.getModel("itemStyle"),d=s.getModel(["emphasis","itemStyle"]),u=s.getModel(["progress","itemStyle"]),c=Pl(s,l,t,{x:a,y:0,onclick:nT(r._changeTimeline,r,e.value)});c.ensureState("emphasis").style=d.getItemStyle(),c.ensureState("progress").style=u.getItemStyle(),dk(c);var h=lQ(c);s.get("tooltip")?(h.dataIndex=e.value,h.dataModel=i):h.dataIndex=h.dataModel=null,r._tickSymbols.push(c)})},t.prototype._renderAxisLabel=function(e,t,n,i){var r=this;if(n.getLabelModel().get("show")){var o=i.getData(),a=n.getViewLabels();this._tickLabels=[],nw(a,function(i){var a=i.tickValue,s=o.getItemModel(a),l=s.getModel("label"),d=s.getModel(["emphasis","label"]),u=s.getModel(["progress","label"]),c=new lj({x:n.dataToCoord(i.tickValue),y:0,rotation:e.labelRotation-e.rotation,onclick:nT(r._changeTimeline,r,a),silent:!1,style:dZ(l,{text:i.formattedLabel,align:e.labelAlign,verticalAlign:e.labelBaseline})});c.ensureState("emphasis").style=dZ(d),c.ensureState("progress").style=dZ(u),t.add(c),dk(c),Pa(c).dataIndex=a,r._tickLabels.push(c)})}},t.prototype._renderControl=function(e,t,n,i){var r=e.controlSize,o=e.rotation,a=i.getModel("controlStyle").getItemStyle(),s=i.getModel(["emphasis","controlStyle"]).getItemStyle(),l=i.getPlayState(),d=i.get("inverse",!0);function u(e,n,l,d){if(e){var u,c,h,p,f,g,m=as(nG(i.get(["controlStyle",n+"BtnSize"]),r),r),v=(u=i,c=n+"Icon",h=[0,-m/2,m,m],f=(p={x:e[0],y:e[1],originX:r/2,originY:0,rotation:d?-o:0,rectHover:!0,style:a,onclick:l}).style,g=fC(u.get(["controlStyle",c]),p||{},new rt(h[0],h[1],h[2],h[3])),f&&g.setStyle(f),g);v.ensureState("emphasis").style=s,t.add(v),dk(v)}}u(e.nextBtnPosition,"next",nT(this._changeTimeline,this,d?"-":"+")),u(e.prevBtnPosition,"prev",nT(this._changeTimeline,this,d?"+":"-")),u(e.playPosition,l?"stop":"play",nT(this._handlePlayClick,this,!l),!0)},t.prototype._renderCurrentPointer=function(e,t,n,i){var r=i.getData(),o=i.getCurrentIndex(),a=r.getItemModel(o).getModel("checkpointStyle"),s=this;this._currentPointer=Pl(a,a,this._mainGroup,{},this._currentPointer,{onCreate:function(e){e.draggable=!0,e.drift=nT(s._handlePointerDrag,s),e.ondragend=nT(s._handlePointerDragend,s),Pd(e,s._progressLine,o,n,i,!0)},onUpdate:function(e){Pd(e,s._progressLine,o,n,i)}})},t.prototype._handlePlayClick=function(e){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:e,from:this.uid})},t.prototype._handlePointerDrag=function(e,t,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},t.prototype._handlePointerDragend=function(e){this._pointerChangeTimeline([e.offsetX,e.offsetY],!0)},t.prototype._pointerChangeTimeline=function(e,t){var n=this._toAxisCoord(e)[0],i=aA(this._axis.getExtent().slice());n>i[1]&&(n=i[1]),n<i[0]&&(n=i[0]),this._currentPointer.x=n,this._currentPointer.markRedraw();var r=this._progressLine;r&&(r.shape.x2=n,r.dirty());var o=this._findNearestTick(n),a=this.model;(t||o!==a.getCurrentIndex()&&a.get("realtime"))&&this._changeTimeline(o)},t.prototype._doPlayStop=function(){var e=this;this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(function(){var t=e.model;e._changeTimeline(t.getCurrentIndex()+(t.get("rewind",!0)?-1:1))},this.model.get("playInterval")))},t.prototype._toAxisCoord=function(e){return fv(e,this._mainGroup.getL
vendor: 5,039 bytes, line 422
422ocalTransform(),!0)},t.prototype._findNearestTick=function(e){var t,n=this.model.getData(),i=1/0,r=this._axis;return n.each(["value"],function(n,o){var a=Math.abs(r.dataToCoord(n)-e);a<i&&(i=a,t=o)}),t},t.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},t.prototype._changeTimeline=function(e){var t=this.model.getCurrentIndex();"+"===e?e=t+1:"-"===e&&(e=t-1),this.api.dispatchAction({type:"timelineChange",currentIndex:e,from:this.uid})},t.prototype._updateTicksStatus=function(){var e=this.model.getCurrentIndex(),t=this._tickSymbols,n=this._tickLabels;if(t)for(var i=0;i<t.length;i++)t&&t[i]&&t[i].toggleState("progress",i<e);if(n)for(var i=0;i<n.length;i++)n&&n[i]&&n[i].toggleState("progress",Pa(n[i]).dataIndex<=e)},t.type="timeline.slider",t}(Pi);function Pl(e,t,n,i,r,o){var a=t.get("color");r?(r.setColor(a),n.add(r),o&&o.onUpdate(r)):((r=g_(e.get("symbol"),-1,-1,2,2,a)).setStyle("strokeNoScale",!0),n.add(r),o&&o.onCreate(r));var s=t.getItemStyle(["color"]);r.setStyle(s),i=nh({rectHover:!0,z2:100},i,!0);var l=gk(e.get("symbolSize"));i.scaleX=l[0]/2,i.scaleY=l[1]/2;var d=gM(e.get("symbolOffset"),l);d&&(i.x=(i.x||0)+d[0],i.y=(i.y||0)+d[1]);var u=e.get("symbolRotate");return i.rotation=(u||0)*Math.PI/180||0,r.attr(i),r.updateTransform(),r}function Pd(e,t,n,i,r,o){if(!e.dragging){var a=r.getModel("checkpointStyle"),s=i.dataToCoord(r.getData().get("value",n));if(o||!a.get("animation",!0))e.attr({x:s,y:0}),t&&t.attr({shape:{x2:s}});else{var l={duration:a.get("animationDuration",!0),easing:a.get("animationEasing",!0)};e.stopAnimation(null,!0),e.animateTo({x:s,y:0},l),t&&t.animateTo({shape:{x2:s}},l)}}}function Pu(e){var t=e&&e.timeline;nR(t)||(t=t?[t]:[]),nw(t,function(e){e&&function(e){var t=e.type,n={number:"value",time:"time"};if(n[t]&&(e.axisType=n[t],delete e.type),Pc(e),Ph(e,"controlPosition")){var i=e.controlStyle||(e.controlStyle={});Ph(i,"position")||(i.position=e.controlPosition),"none"!==i.position||Ph(i,"show")||(i.show=!1,delete i.position),delete e.controlPosition}nw(e.data||[],function(e){nL(e)&&!nR(e)&&(!Ph(e,"value")&&Ph(e,"name")&&(e.value=e.name),Pc(e))})}(e)})}function Pc(e){var t=e.itemStyle||(e.itemStyle={}),n=t.emphasis||(t.emphasis={}),i=e.label||e.label||{},r=i.normal||(i.normal={}),o={normal:1,emphasis:1};nw(i,function(e,t){o[t]||Ph(r,t)||(r[t]=e)}),n.label&&!Ph(i,"emphasis")&&(i.emphasis=n.label,delete n.label)}function Ph(e,t){return e.hasOwnProperty(t)}function Pp(e,t){if(!e)return!1;for(var n=nR(e)?e:[e],i=0;i<n.length;i++)if(n[i]&&n[i][t])return!0;return!1}function Pf(e){aQ(e,"label",["show"])}var Pg=a9(),Pm=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.createdBySelf=!1,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n),this._mergeOption(e,n,!1,!0)},t.prototype.isAnimationEnabled=function(){if(t1.node)return!1;var e=this.__hostSeries;return this.getShallow("animation")&&e&&e.isAnimationEnabled()},t.prototype.mergeOption=function(e,t){this._mergeOption(e,t,!1,!1)},t.prototype._mergeOption=function(e,t,n,i){var r=this.mainType;n||t.eachSeries(function(e){var n=e.get(this.mainType,!0),o=Pg(e)[r];if(!n||!n.data){Pg(e)[r]=null;return}o?o._mergeOption(n,t,!0):(i&&Pf(n),nw(n.data,function(e){e instanceof Array?(Pf(e[0]),Pf(e[1])):Pf(e)}),nf(o=this.createMarkerModelFromSeries(n,this,t),{mainType:this.mainType,seriesIndex:e.seriesIndex,name:e.name,createdBySelf:!0}),o.__hostSeries=e),Pg(e)[r]=o},this)},t.prototype.formatTooltip=function(e,t,n){var i=this.getData(),r=this.getRawValue(e),o=i.getName(e);return hV("section",{header:this.name,blocks:[hV("nameValue",{name:o,value:r,noName:!o,noValue:null==r})]})},t.prototype.getData=function(){return this._data},t.prototype.setData=function(e){this._data=e},t.prototype.getDataParams=function(e,t){var n=ho.prototype.getDataParams.call(this,e,t),i=this.__hostSeries;return i&&(n.seriesId=i.id,n.seriesName=i.name,n.seriesType=i.subType),n},t.getMarkerModelFromSeries=function(e,t){return Pg(e)[t]},t.type="marker",t.dependencies=["series","grid","polar","geo"],t}(u5);nb(Pm,ho.prototype);var Pv=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.createMarkerModelFromSeries=function(e,n,i){return new t(e,n,i)},t.type="markPoint",t.defaultOption={z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},t}(Pm);function Py(e){return!(isNaN(parseFloat(e.x))&&isNaN(parseFloat(e.y)))}function Pb(e,t,n,i,r,o){var a=[],s=yr(t,i)?t.getCalculationInfo("stackResultDimension"):i,l=Pk(t,s,e),d=t.indicesOfNearest(s,l)[0];a[r]=t.get(n,d),a[o]=t.get(s,d);var u=t.get(i,d),c=aP(t.get(i,d));return(c=Math.min(c,20))>=0&&(a[o]=+a[o].toFixed(c)),[a,u]}var Px={min:nD(Pb,"min"),max:nD(Pb,"max"),average:nD(Pb,"average"),median:nD(Pb,"median")};function Pw(e,t){if(t){var n,i=e.getData(),r=e.coordinateSystem,o=r&&r.dimensions;
422if(!(!isNaN(parseFloat((n=t).x))&&!isNaN(parseFloat(n.y)))&&!nR(t.coord)&&nR(o)){var a=PC(t,i,r,e);if((t=nc(t)).type&&Px[t.type]&&a.baseAxis&&a.valueAxis){var s=nv(o,a.baseAxis.dim),l=nv(o,a.valueAxis.dim),d=Px[t.type](i,a.baseDataDim,a.valueDataDim,s,l);t.coord=d[0],t.value=d[1]}else t.coord=[null!=t.xAxis?t.xAxis:t.radiusAxis,null!=t.yAxis?t.yAxis:t.angleAxis]}if(null!=t.coord&&nR(o))for(var u=t.coord,c=0;c<2;c++)Px[u[c]]&&(u[c]=Pk(i,i.mapDimension(o[c]),u[c]));else t.coord=[];return t}}function PC(e,t,n,i){var r,o,a,s={};return null!=e.valueIndex||null!=e.valueDim?(s.valueDataDim=null!=e.valueIndex?t.getDimension(e.valueIndex):e.valueDim,s.valueAxis=n.getAxis((r=i,o=s.valueDataDim,(a=r.getData().getDimensionInfo(o))&&a.coordDim)),s.baseAxis=n.getOtherAxis(s.valueAxis),s.baseDataDim=t.mapDimension(s.baseAxis.dim)):(s.baseAxis=i.getBaseAxis(),s.valueAxis=n.getOtherAxis(s.baseAxis),s.baseDataDim=t.mapDimension(s.baseAxis.dim),s.valueDataDim=t.mapDimension(s.valueAxis.dim)),s}function PS(e,t){return!e||!e.containData||!t.coord||!!Py(t)||e.containData(t.coord)}function P_(e,t){return e?function(e,n,i,r){return hu(r<2?e.coord&&e.coord[r]:e.value,t[r])}:function(e,n,i,r){return hu(e.value,t[r])}}function Pk(e,t,n){if("average"===n){var i=0,r=0;return e.each(t,function(e,t){!isNaN(e)&&(i+=e,r++)}),i/r}return"median"===n?e.getMedian(t):e.getDataExtent(t)[+("max"===n)]}var PM=a9(),PT=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(){this.markerGroupMap=n1()},t.prototype.render=function(e,t,n){var i=this,r=this.markerGroupMap;r.each(function(e){PM(e).keep=!1}),t.eachSeries(function(e){var r=Pm.getMarkerModelFromSeries(e,i.type);r&&i.renderSeries(e,r,t,n)}),r.each(function(e){PM(e).keep||i.group.remove(e.group)})},t.prototype.markKeep=function(e){PM(e).keep=!0},t.prototype.toggleBlurSeries=function(e,t){var n=this;nw(e,function(e){var i=Pm.getMarkerModelFromSeries(e,n.type);i&&i.getData().eachItemGraphicEl(function(e){e&&(t?dc(e,ds):dc(e,dl))})})},t.type="marker",t}(h9);function PD(e,t,n){var i=t.coordinateSystem;e.each(function(r){var o,a=e.getItemModel(r),s=aR(a.get("x"),n.getWidth()),l=aR(a.get("y"),n.getHeight());if(isNaN(s)||isNaN(l)){if(t.getMarkerPosition)o=t.getMarkerPosition(e.getValues(e.dimensions,r));else if(i){var d=e.get(i.dimensions[0],r),u=e.get(i.dimensions[1],r);o=i.dataToPoint([d,u])}}else o=[s,l];isNaN(s)||(o[0]=s),isNaN(l)||(o[1]=l),e.setItemLayout(r,o)})}var PR=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.updateTransform=function(e,t,n){t.eachSeries(function(e){var t=Pm.getMarkerModelFromSeries(e,"markPoint");t&&(PD(t.getData(),e,n),this.markerGroupMap.get(e.id).updateLayout())},this)},t.prototype.renderSeries=function(e,t,n,i){var r,o,a,s,l,d,u,c=e.coordinateSystem,h=e.id,p=e.getData(),f=this.markerGroupMap,g=f.get(h)||f.set(h,new yg),m=(r=c,o=e,a=t,l=new v8(s=r?nC(r&&r.dimensions,function(e){return nf(nf({},o.getData().getDimensionInfo(o.getData().mapDimension(e))||{}),{name:e,ordinalMeta:null})}):[{name:"value",type:"float"}],a),d=nC(a.get("data"),nD(Pw,o)),r&&(d=n_(d,nD(PS,r))),u=P_(!!r,s),l.initData(d,null,u),l);t.setData(m),PD(t.getData(),e,i),m.each(function(e){var n=m.getItemModel(e),i=n.getShallow("symbol"),r=n.getShallow("symbolSize"),o=n.getShallow("symbolRotate"),a=n.getShallow("symbolOffset"),s=n.getShallow("symbolKeepAspect");if(nI(i)||nI(r)||nI(o)||nI(a)){var l=t.getRawValue(e),d=t.getDataParams(e);nI(i)&&(i=i(l,d)),nI(r)&&(r=r(l,d)),nI(o)&&(o=o(l,d)),nI(a)&&(a=a(l,d))}var u=n.getModel("itemStyle").getItemStyle(),c=gl(p,"color");u.fill||(u.fill=c),m.setItemVisual(e,{symbol:i,symbolSize:r,symbolRotate:o,symbolOffset:a,symbolKeepAspect:s,style:u})}),g.updateData(m),this.group.add(g.group),m.eachItemGraphicEl(function(e){e.traverse(function(e){lQ(e).dataModel=t})}),this.markKeep(g),g.group.silent=t.get("silent")||e.get("silent")},t.type="markPoint",t}(PT),PI=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.createMarkerModelFromSeries=function(e,n,i){return new t(e,n,i)},t.type="markLine",t.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},t}(Pm),PA=a9(),PP=function(e,t,n,i){var r,o=e.getData();if(nR(i))r=i;
422else{var a=i.type;if("min"===a||"max"===a||"average"===a||"median"===a||null!=i.xAxis||null!=i.yAxis){var s=void 0,l=void 0;if(null!=i.yAxis||null!=i.xAxis)s=t.getAxis(null!=i.yAxis?"y":"x"),l=nH(i.yAxis,i.xAxis);else{var d=PC(i,o,t,e);s=d.valueAxis;var u=yo(o,d.valueDataDim);l=Pk(o,u,a)}var c=+("x"!==s.dim),h=1-c,p=nc(i),f={coord:[]};p.type=null,p.coord=[],p.coord[h]=-1/0,f.coord[h]=1/0;var g=n.get("precision");g>=0&&nE(l)&&(l=+l.toFixed(Math.min(g,20))),p.coord[c]=f.coord[c]=l,r=[p,f,{type:a,valueIndex:i.valueIndex,value:l}]}else r=[]}var m=[Pw(e,r[0]),Pw(e,r[1]),nf({},r[2])];return m[2].type=m[2].type||null,nh(m[2],m[0]),nh(m[2],m[1]),m};function PE(e){return!isNaN(e)&&!isFinite(e)}function PL(e,t,n,i){var r=1-e,o=i.dimensions[e];return PE(t[r])&&PE(n[r])&&t[e]===n[e]&&i.getAxis(o).containData(t[e])}function PF(e,t){if("cartesian2d"===e.type){var n=t[0].coord,i=t[1].coord;if(n&&i&&(PL(1,n,i,e)||PL(0,n,i,e)))return!0}return PS(e,t[0])&&PS(e,t[1])}function PO(e,t,n,i,r){var o,a=i.coordinateSystem,s=e.getItemModel(t),l=aR(s.get("x"),r.getWidth()),d=aR(s.get("y"),r.getHeight());if(isNaN(l)||isNaN(d)){if(i.getMarkerPosition)o=i.getMarkerPosition(e.getValues(e.dimensions,t));else{var u=a.dimensions,c=e.get(u[0],t),h=e.get(u[1],t);o=a.dataToPoint([c,h])}if(yP(a,"cartesian2d")){var p=a.getAxis("x"),f=a.getAxis("y"),u=a.dimensions;PE(e.get(u[0],t))?o[0]=p.toGlobalCoord(p.getExtent()[+!n]):PE(e.get(u[1],t))&&(o[1]=f.toGlobalCoord(f.getExtent()[+!n]))}isNaN(l)||(o[0]=l),isNaN(d)||(o[1]=d)}else o=[l,d];e.setItemLayout(t,o)}var PN=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.updateTransform=function(e,t,n){t.eachSeries(function(e){var t=Pm.getMarkerModelFromSeries(e,"markLine");if(t){var i=t.getData(),r=PA(t).from,o=PA(t).to;r.each(function(t){PO(r,t,!0,e,n),PO(o,t,!1,e,n)}),i.each(function(e){i.setItemLayout(e,[r.getItemLayout(e),o.getItemLayout(e)])}),this.markerGroupMap.get(e.id).updateLayout()}},this)},t.prototype.renderSeries=function(e,t,n,i){var r,o,a,s,l,d,u,c,h,p=e.coordinateSystem,f=e.id,g=e.getData(),m=this.markerGroupMap,v=m.get(f)||m.set(f,new _0);this.group.add(v.group);var y=(r=p,o=e,a=t,l=new v8(s=r?nC(r&&r.dimensions,function(e){return nf(nf({},o.getData().getDimensionInfo(o.getData().mapDimension(e))||{}),{name:e,ordinalMeta:null})}):[{name:"value",type:"float"}],a),d=new v8(s,a),u=new v8([],a),c=nC(a.get("data"),nD(PP,o,r,a)),r&&(c=n_(c,nD(PF,r))),h=P_(!!r,s),l.initData(nC(c,function(e){return e[0]}),null,h),d.initData(nC(c,function(e){return e[1]}),null,h),u.initData(nC(c,function(e){return e[2]})),u.hasItemOption=!0,{from:l,to:d,line:u}),b=y.from,x=y.to,w=y.line;PA(t).from=b,PA(t).to=x,t.setData(w);var C=t.get("symbol"),S=t.get("symbolSize"),_=t.get("symbolRotate"),k=t.get("symbolOffset");function M(t,n,r){var o=t.getItemModel(n);PO(t,n,r,e,i);var a=o.getModel("itemStyle").getItemStyle();null==a.fill&&(a.fill=gl(g,"color")),t.setItemVisual(n,{symbolKeepAspect:o.get("symbolKeepAspect"),symbolOffset:nG(o.get("symbolOffset",!0),k[+!r]),symbolRotate:nG(o.get("symbolRotate",!0),_[+!r]),symbolSize:nG(o.get("symbolSize"),S[+!r]),symbol:nG(o.get("symbol",!0),C[+!r]),style:a})}nR(C)||(C=[C,C]),nR(S)||(S=[S,S]),nR(_)||(_=[_,_]),nR(k)||(k=[k,k]),y.from.each(function(e){M(b,e,!0),M(x,e,!1)}),w.each(function(e){var t=w.getItemModel(e).getModel("lineStyle").getLineStyle();w.setItemLayout(e,[b.getItemLayout(e),x.getItemLayout(e)]),null==t.stroke&&(t.stroke=b.getItemVisual(e,"style").fill),w.setItemVisual(e,{fromSymbolKeepAspect:b.getItemVisual(e,"symbolKeepAspect"),fromSymbolOffset:b.getItemVisual(e,"symbolOffset"),fromSymbolRotate:b.getItemVisual(e,"symbolRotate"),fromSymbolSize:b.getItemVisual(e,"symbolSize"),fromSymbol:b.getItemVisual(e,"symbol"),toSymbolKeepAspect:x.getItemVisual(e,"symbolKeepAspect"),toSymbolOffset:x.getItemVisual(e,"symbolOffset"),toSymbolRotate:x.getItemVisual(e,"symbolRotate"),toSymbolSize:x.getItemVisual(e,"symbolSize"),toSymbol:x.getItemVisual(e,"symbol"),style:t})}),v.updateData(w),y.line.eachItemGraphicEl(function(e){lQ(e).dataModel=t,e.traverse(function(e){lQ(e).dataModel=t})}),this.markKeep(v),v.group.silent=t.get("silent")||e.get("silent")},t.type="markLine",t}(PT),PB=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.createMarkerModelFromSeries=function(e,n,i){return new t(e,n,i)},t.type="markArea",t.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},t}(Pm),Pz=a9(),Pj=function(e,t,n,i){var r=i[0],o=i[1];if(r&&o){var a=Pw(e,r),s=Pw(e,o),l=a.coord,d=s.coord;l[0]=nH(l[0],-1/0),l[1]=nH(l[1],-1/0),d[0]=nH(d[0],1/0),d[1]=nH(d[1],1/0);var u=np([{},a,s]);return u.coord=[a.coord,s.coord],u.x0=a.x,u.y0=a.y,u.x1=s.x,u.y1=s.y,u}};function PV(e){return!isNaN(e)&&!isFinite(e)}function PH(e,t,n,i){var r=1-e;return PV(t[r])&&PV(n[r])}function PG(e,t){var n=t.coord[0],i=t.coord[1],r={coord:n,x:t.x0,y:t.y0},o={coord:i,x:t.x1,y:t.y1};if(yP(e,"cartesian2d"))return!!(n&&i&&(PH(1,n,i,e)||PH(0,n,i,e)))||!e||!e.containZone||!r.coord||!o.coord||!!Py(r)||!!Py(o)||e.containZone(r.coord,o.coord);return PS(e,r)||PS(e,o)}function PW(e,t,n,i,r){var o,a=i.coordinateSystem,s=e.getItemModel(t),l=aR(s.get(n[0]),r.getWidth()),d=aR(s.get(n[1]),r.getHeight());if(isNaN(l)||isNaN(d)){if(i.getMarkerPosition){var u=e.getValues(["x0","y0"],t),c=e.getValues(["x1","y1"],t),h=a.clampData(u),p=a.clampData(c),f=[];"x0"===n[0]?f[0]=h[0]>p[0]?c[0]:u[0]:f[0]=h[0]>p[0]?u[0]:c[0],"y0"===n[1]?f[1]=h[1]>p[1]?c[1]:u[1]:f[1]=h[1]>p[1]?u[1]:c[1],o=i.getMarkerPosition(f,n,!0)}else{var g=e.get(n[0],t),m=e.get(n[1],t),v=[g,m];a.clampData&&a.clampData(v,v),o=a.dataToPoint(v,!0)}if(yP(a,"cartesian2d")){var y=a.getAxis("x"),b=a.getAxis("y"),g=e.get(n[0],t),m=e.get(n[1],t);PV(g)?o[0]=y.toGlobalCoord(y.getExtent()[+("x0"!==n[0])]):PV(m)&&(o[1]=b.toGlobalCoord(b.getExtent()[+("y0"!==n[1])]))}isNaN(l)||(o[0]=l),isNaN(d)||(o[1]=d)}else o=[l,d];return o}var P$=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],PU=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.updateTransform=function(e,t,n){t.eachSeries(function(e){var t=Pm.getMarkerModelFromSeries(e,"markArea");if(t){var i=t.getData();i.each(function(t){var r=nC(P$,function(r){return PW(i,t,r,e,n)});i.setItemLayout(t,r),i.getItemGraphicEl(t).setShape("points",r)})}},this)},t.prototype.renderSeries=function(e,t,n,i){var r=e.coordinateSystem,o=e.id,a=e.getData(),s=this.markerGroupMap,l=s.get(o)||s.set(o,{group:new av});this.group.add(l.group),this.markKeep(l);var d=function(e,t,n){if(e){var i,r,o=nC(e&&e.dimensions,function(e){var n=t.getData();return nf(nf({},n.getDimensionInfo(n.mapDimension(e))||{}),{name:e,ordinalMeta:null})});i=new v8(r=nC(["x0","y0","x1","y1"],function(e,t){return{name:e,type:o[t%2].type}}),n)}else i=new v8(r=[{name:"value",type:"float"}],n);var a=nC(n.get("data"),nD(Pj,t,e,n));e&&(a=n_(a,nD(PG,e)));
422var s=e?function(e,t,n,i){return hu(e.coord[Math.floor(i/2)][i%2],r[i])}:function(e,t,n,i){return hu(e.value,r[i])};return i.initData(a,null,s),i.hasItemOption=!0,i}(r,e,t);t.setData(d),d.each(function(t){var n=nC(P$,function(n){return PW(d,t,n,e,i)}),o=r.getAxis("x").scale,s=r.getAxis("y").scale,l=o.getExtent(),u=s.getExtent(),c=[o.parse(d.get("x0",t)),o.parse(d.get("x1",t))],h=[s.parse(d.get("y0",t)),s.parse(d.get("y1",t))];aA(c),aA(h);var p=!(l[0]>c[1]||l[1]<c[0]||u[0]>h[1]||u[1]<h[0]);d.setItemLayout(t,{points:n,allClipped:!p});var f=d.getItemModel(t).getModel("itemStyle").getItemStyle(),g=gl(a,"color");!f.fill&&(f.fill=g,nA(f.fill)&&(f.fill=ot(f.fill,.4))),f.stroke||(f.stroke=g),d.setItemVisual(t,"style",f)}),d.diff(Pz(l).data).add(function(e){var t=d.getItemLayout(e);if(!t.allClipped){var n=new pV({shape:{points:t.points}});d.setItemGraphicEl(e,n),l.group.add(n)}}).update(function(e,n){var i=Pz(l).data.getItemGraphicEl(n),r=d.getItemLayout(e);r.allClipped?i&&l.group.remove(i):(i?dB(i,{shape:{points:r.points}},t,e):i=new pV({shape:{points:r.points}}),d.setItemGraphicEl(e,i),l.group.add(i))}).remove(function(e){var t=Pz(l).data.getItemGraphicEl(e);l.group.remove(t)}).execute(),d.eachItemGraphicEl(function(e,n){var i=d.getItemModel(n),r=d.getItemVisual(n,"style");e.useStyle(d.getItemVisual(n,"style")),dK(e,dY(i),{labelFetcher:t,labelDataIndex:n,defaultText:d.getName(n)||"",inheritColor:nA(r.fill)?ot(r.fill,1):"#000"}),dI(e,i),dM(e,null,null,i.get(["emphasis","disabled"])),lQ(e).dataModel=t}),Pz(l).data=d,l.group.silent=t.get("silent")||e.get("silent")},t.type="markArea",t}(PT),Pq=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.layoutMode={type:"box",ignoreSize:!0},n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n),e.selected=e.selected||{},this._updateSelector(e)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),this._updateSelector(t)},t.prototype._updateSelector=function(e){var t=e.selector,n=this.ecModel;!0===t&&(t=e.selector=["all","inverse"]),nR(t)&&nw(t,function(e,i){var r;nA(e)&&(e={type:e}),t[i]=nh(e,"all"===(r=e.type)?{type:"all",title:n.getLocaleModel().get(["legend","selector","all"])}:"inverse"===r?{type:"inverse",title:n.getLocaleModel().get(["legend","selector","inverse"])}:void 0)})},t.prototype.optionUpdated=function(){this._updateData(this.ecModel);var e=this._data;if(e[0]&&"single"===this.get("selectedMode")){for(var t=!1,n=0;n<e.length;n++){var i=e[n].get("name");if(this.isSelected(i)){this.select(i),t=!0;break}}t||this.select(e[0].get("name"))}},t.prototype._updateData=function(e){var t=[],n=[];e.eachRawSeries(function(i){var r,o=i.name;if(n.push(o),i.legendVisualProvider){var a=i.legendVisualProvider.getAllNames();e.isSeriesFiltered(i)||(n=n.concat(a)),a.length?t=t.concat(a):r=!0}else r=!0;r&&a6(i)&&t.push(i.name)}),this._availableNames=n;var i=this.get("data")||t,r=n1(),o=nC(i,function(e){return((nA(e)||nE(e))&&(e={name:e}),r.get(e.name))?null:(r.set(e.name,!0),new ua(e,this,this.ecModel))},this);this._data=n_(o,function(e){return!!e})},t.prototype.getData=function(){return this._data},t.prototype.select=function(e){var t=this.option.selected;"single"===this.get("selectedMode")&&nw(this._data,function(e){t[e.get("name")]=!1}),t[e]=!0},t.prototype.unSelect=function(e){"single"!==this.get("selectedMode")&&(this.option.selected[e]=!1)},t.prototype.toggleSelected=function(e){var t=this.option.selected;t.hasOwnProperty(e)||(t[e]=!0),this[t[e]?"unSelect":"select"](e)},t.prototype.allSelect=function(){var e=this._data,t=this.option.selected;nw(e,function(e){t[e.get("name",!0)]=!0})},t.prototype.inverseSelect=function(){var e=this._data,t=this.option.selected;nw(e,function(e){var n=e.get("name",!0);t.hasOwnProperty(n)||(t[n]=!0),t[n]=!t[n]})},t.prototype.isSelected=function(e){var t=this.option.selected;return!(t.hasOwnProperty(e)&&!t[e])&&nv(this._availableNames,e)>=0},t.prototype.getOrient=function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},t.type="legend.plain",t.dependencies=["series"],t.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miter
422Limit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},t}(u5),PK=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!1,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(){this.group.add(this._contentGroup=new av),this.group.add(this._selectorGroup=new av),this._isFirstRender=!0},t.prototype.getContentGroup=function(){return this._contentGroup},t.prototype.getSelectorGroup=function(){return this._selectorGroup},t.prototype.render=function(e,t,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),e.get("show",!0)){var r=e.get("align"),o=e.get("orient");r&&"auto"!==r||(r="right"===e.get("left")&&"vertical"===o?"right":"left");var a=e.get("selector",!0),s=e.get("selectorPosition",!0);a&&(!s||"auto"===s)&&(s="horizontal"===o?"end":"start"),this.renderInner(r,e,t,n,a,o,s);var l=e.getBoxLayoutParams(),d={width:n.getWidth(),height:n.getHeight()},u=e.get("padding"),c=uX(l,d,u),h=this.layoutInner(e,r,c,i,a,s),p=uX(ng({width:h.width,height:h.height},l),d,u);this.group.x=p.x-h.x,this.group.y=p.y-h.y,this.group.markRedraw(),this.group.add(this._backgroundEl=I1(h,e))}},t.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},t.prototype.renderInner=function(e,t,n,i,r,o,a){var s=this.getContentGroup(),l=n1(),d=t.get("selectedMode"),u=[];n.eachRawSeries(function(e){e.get("legendHoverLink")||u.push(e.id)}),nw(t.getData(),function(r,o){var a=r.get("name");if(!this.newlineDisabled&&(""===a||"\n"===a)){var c=new av;c.newline=!0,s.add(c);return}var h=n.getSeriesByName(a)[0];if(!l.get(a))if(h){var p=h.getData(),f=p.getVisual("legendLineStyle")||{},g=p.getVisual("legendIcon"),m=p.getVisual("style"),v=this._createItem(h,a,o,r,t,e,f,m,g,d,i);v.on("click",nD(PY,a,null,i,u)).on("mouseover",nD(PX,h.name,null,i,u)).on("mouseout",nD(PJ,h.name,null,i,u)),n.ssr&&v.eachChild(function(e){var t=lQ(e);t.seriesIndex=h.seriesIndex,t.dataIndex=o,t.ssrType="legend"}),l.set(a,!0)}else n.eachRawSeries(function(s){if(!l.get(a)&&s.legendVisualProvider){var c=s.legendVisualProvider;if(c.containName(a)){var h=c.indexOfName(a),p=c.getItemVisual(h,"style"),f=c.getItemVisual(h,"legendIcon"),g=r5(p.fill);g&&0===g[3]&&(g[3]=.2,p=nf(nf({},p),{fill:on(g,"rgba")}));var m=this._createItem(s,a,o,r,t,e,{},p,f,d,i);m.on("click",nD(PY,null,a,i,u)).on("mouseover",nD(PX,null,a,i,u)).on("mouseout",nD(PJ,null,a,i,u)),n.ssr&&m.eachChild(function(e){var t=lQ(e);t.seriesIndex=s.seriesIndex,t.dataIndex=o,t.ssrType="legend"}),l.set(a,!0)}}},this)},this),r&&this._createSelector(r,t,i,o,a)},t.prototype._createSelector=function(e,t,n,i,r){var o=this.getSelectorGroup();nw(e,function(e){var i=e.type,r=new lj({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:"all"===i?"legendAllSelect":"legendInverseSelect",legendId:t.id})}});o.add(r),dK(r,{normal:t.getModel("selectorLabel"),emphasis:t.getModel(["emphasis","selectorLabel"])},{defaultText:e.title}),dk(r)})},t.prototype._createItem=function(e,t,n,i,r,o,a,s,l,d,u){var c=e.visualDrawType,h=r.get("itemWidth"),p=r.get("itemHeight"),f=r.isSelected(t),g=i.get("symbolRotate"),m=i.get("symbolKeepAspect"),v=i.get("icon"),y=function(e,t,n,i,r,o,a){function s(e,t){"auto"===e.lineWidth&&(e.lineWidth=2*(t.lineWidth>0)),nw(e,function(n,i){"inherit"===e[i]&&(e[i]=t[i])})}var l=t.getModel("itemStyle"),d=l.getItemStyle(),u=0===e.lastIndexOf("empty",0)?"fill":"stroke",c=l.getShallow("decal");d.decal=c&&"inherit"!==c?gX(c,a):i.decal,"inherit"===d.fill&&(d.fill=i[r]),"inherit"===d.stroke&&(d.stroke=i[u]),"inherit"===d.opacity&&(d.opacity=("fill"===r?i:n).opacity),s(d,i);var h=t.getModel("lineStyle"),p=h.getLineStyle();if(s(p,n),"auto"===d.fill&&(d.fill=i.fill),"auto"===d.stroke&&(d.stroke=i.fill),"auto"===p.stroke&&(p.stroke=i.fill),!o){var f=t.get("inactiveBorderWidth"),g=d[u];d.lineWidth="auto"===f?i.lineWidth>0&&g?2:0:d.lineWidth,d.fill=t.get("inactiveColor"),d.stroke=t.get("inactiveBorderColor"),p.stroke=h.get("inactiveColor"),p.lineWidth=h.get("inactiveWidth")}return{itemStyle:d,lineStyle:p}}(l=v||l||"roundRect",i,a,s,c,f,u),b=new av,x=i.getModel("textStyle");if(nI(e.getLegendIcon)&&(!v||"inherit"===v))b.add(e.getLegendIcon({itemWidth:h,itemHeight:p,icon:l,iconRotate:g,itemStyle:y.itemStyle,lineStyle:y.lineStyle,symbolKeepAspect:m}));else{var w,C,S,_="inherit"===v&&e.getData().getVisual("symbol")?"inherit"===g?e.getData().getVisual("symbolRotate"):g:0;b.add(((S=g_(C=(w={itemWidth:h,itemHeight:p,icon:l,iconRotate:_,itemStyle:y.itemStyle,lineStyle:y.lineStyle,symbolKeepAspect:m}).icon||"roundRect",0,0,w.itemWidth,w.itemHeight,w.itemStyle.fill,w.symbolKeepAspect)).setStyle(w.itemStyle),S.rotation=(w.iconRotate||0)*Math.PI/180,S.setOrigin([w.itemWidth/2,w.itemHeight/2]),C.indexOf("empty")>-1&&(S.style.stroke=S.style.fill,S.style.fill="#fff",S.style.lineWidth=2),S))}var k=r.get("formatter"),M=t;nA(k)&&k?M=k.replace("{name}",null!=t?t:""):nI(k)&&(M=k(t));var T=f?x.getTextColor():i.get("inactiveColor");b.add(new lj({style:dZ(x,{text:M,x:"left"===o?h+5:-5,y:p/2,fill:T,align:o,verticalAlign:"middle"},{inheritColor:T})}));
422var D=new lN({shape:b.getBoundingRect(),style:{fill:"transparent"}}),R=i.getModel("tooltip");return R.get("show")&&fk({el:D,componentModel:r,itemName:t,itemTooltipOption:R.option}),b.add(D),b.eachChild(function(e){e.silent=!0}),D.silent=!d,this.getContentGroup().add(b),dk(b),b.__legendDataIndex=n,b},t.prototype.layoutInner=function(e,t,n,i,r,o){var a=this.getContentGroup(),s=this.getSelectorGroup();uZ(e.get("orient"),a,e.get("itemGap"),n.width,n.height);var l=a.getBoundingRect(),d=[-l.x,-l.y];if(s.markRedraw(),a.markRedraw(),!r)return a.x=d[0],a.y=d[1],this.group.getBoundingRect();uZ("horizontal",s,e.get("selectorItemGap",!0));var u=s.getBoundingRect(),c=[-u.x,-u.y],h=e.get("selectorButtonGap",!0),p=e.getOrient().index,f=0===p?"width":"height",g=0===p?"height":"width",m=0===p?"y":"x";"end"===o?c[p]+=l[f]+h:d[p]+=u[f]+h,c[1-p]+=l[g]/2-u[g]/2,s.x=c[0],s.y=c[1],a.x=d[0],a.y=d[1];var v={x:0,y:0};return v[f]=l[f]+h+u[f],v[g]=Math.max(l[g],u[g]),v[m]=Math.min(0,u[m]+c[1-p]),v},t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type="legend.plain",t}(h9);function PY(e,t,n,i){PJ(e,t,n,i),n.dispatchAction({type:"legendToggleSelect",name:null!=e?e:t}),PX(e,t,n,i)}function PZ(e){for(var t,n=e.getZr().storage.getDisplayList(),i=0,r=n.length;i<r&&!(t=n[i].states.emphasis);)i++;return t&&t.hoverLayer}function PX(e,t,n,i){PZ(n)||n.dispatchAction({type:"highlight",seriesName:e,name:t,excludeSeriesId:i})}function PJ(e,t,n,i){PZ(n)||n.dispatchAction({type:"downplay",seriesName:e,name:t,excludeSeriesId:i})}function PQ(e){var t=e.findComponents({mainType:"legend"});t&&t.length&&e.filterSeries(function(e){for(var n=0;n<t.length;n++)if(!t[n].isSelected(e.name))return!1;return!0})}function P0(e,t,n){var i="allSelect"===e||"inverseSelect"===e,r={},o=[];n.eachComponent({mainType:"legend",query:t},function(n){i?n[e]():n[e](t.name),P1(n,r),o.push(n.componentIndex)});var a={};return n.eachComponent("legend",function(e){nw(r,function(t,n){e[t?"select":"unSelect"](n)}),P1(e,a)}),i?{selected:a,legendIndex:o}:{name:t.name,selected:a}}function P1(e,t){var n=t||{};return nw(e.getData(),function(t){var i=t.get("name");if("\n"!==i&&""!==i){var r=e.isSelected(i);n4(n,i)?n[i]=n[i]&&r:n[i]=r}}),n}function P2(e){e.registerComponentModel(Pq),e.registerComponentView(PK),e.registerProcessor(e.PRIORITY.PROCESSOR.SERIES_FILTER,PQ),e.registerSubTypeDefaulter("legend",function(){return"plain"}),e.registerAction("legendToggleSelect","legendselectchanged",nD(P0,"toggleSelected")),e.registerAction("legendAllSelect","legendselectall",nD(P0,"allSelect")),e.registerAction("legendInverseSelect","legendinverseselect",nD(P0,"inverseSelect")),e.registerAction("legendSelect","legendselected",nD(P0,"select")),e.registerAction("legendUnSelect","legendunselected",nD(P0,"unSelect"))}var P3=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.setScrollDataIndex=function(e){this.option.scrollDataIndex=e},t.prototype.init=function(t,n,i){var r=u1(t);e.prototype.init.call(this,t,n,i),P5(this,t,r)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),P5(this,this.option,t)},t.type="legend.scroll",t.defaultOption=ud(Pq.defaultOption,{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:"end",pageFormatter:"{current}/{total}",pageIcons:{horizontal:["M0,0L12,-10L12,10z","M0,0L-12,-10L-12,10z"],vertical:["M0,0L20,0L10,-20z","M0,0L20,0L10,20z"]},pageIconColor:"#2f4554",pageIconInactiveColor:"#aaa",pageIconSize:15,pageTextStyle:{color:"#333"},animationDurationUpdate:800}),t}(Pq);function P5(e,t,n){var i=e.getOrient(),r=[1,1];r[i.index]=0,u0(t,n,{type:"box",ignoreSize:!!r})}var P4=["width","height"],P6=["x","y"],P8=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!0,n._currentIndex=0,n}return(0,tQ.__extends)(t,e),t.prototype.init=function(){e.prototype.init.call(this),this.group.add(this._containerGroup=new av),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new av)},t.prototype.resetInner=function(){e.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},t.prototype.renderInner=function(t,n,i,r,o,a,s){var l=this;e.prototype.renderInner.call(this,t,n,i,r,o,a,s);var d=this._controllerGroup,u=n.get("pageIconSize",!0),c=nR(u)?u:[u,u];p("pagePrev",0);var h=n.getModel("pageTextStyle");function p(e,t){var i=fC(n.get("pageIcons",!0)[n.getOrient().name][t],{onclick:nT(l._pageGo,l,e+"DataIndex",n,r)},{x:-c[0]/2,y:-c[1]/2,width:c[0],height:c[1]});i.name=e,d.add(i)}d.add(new lj({name:"pageText",style:{text:"xx/xx",fill:h.getTextColor(),font:h.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),p("pageNext",1)},t.prototype.layoutInner=function(e,t,n,i,r,o){var a=this.getSelectorGroup(),s=e.getOrient().index,l=P4[s],d=P6[s],u=P4[1-s],c=P6[1-s];r&&uZ("horizontal",a,e.get("selectorItemGap",!0));
422var h=e.get("selectorButtonGap",!0),p=a.getBoundingRect(),f=[-p.x,-p.y],g=nc(n);r&&(g[l]=n[l]-p[l]-h);var m=this._layoutContentAndController(e,i,g,s,l,u,c,d);if(r){if("end"===o)f[s]+=m[l]+h;else{var v=p[l]+h;f[s]-=v,m[d]-=v}m[l]+=p[l]+h,f[1-s]+=m[c]+m[u]/2-p[u]/2,m[u]=Math.max(m[u],p[u]),m[c]=Math.min(m[c],p[c]+f[1-s]),a.x=f[0],a.y=f[1],a.markRedraw()}return m},t.prototype._layoutContentAndController=function(e,t,n,i,r,o,a,s){var l=this.getContentGroup(),d=this._containerGroup,u=this._controllerGroup;uZ(e.get("orient"),l,e.get("itemGap"),i?n.width:null,i?null:n.height),uZ("horizontal",u,e.get("pageButtonItemGap",!0));var c=l.getBoundingRect(),h=u.getBoundingRect(),p=this._showController=c[r]>n[r],f=[-c.x,-c.y];t||(f[i]=l[s]);var g=[0,0],m=[-h.x,-h.y],v=nG(e.get("pageButtonGap",!0),e.get("itemGap",!0));p&&("end"===e.get("pageButtonPosition",!0)?m[i]+=n[r]-h[r]:g[i]+=h[r]+v),m[1-i]+=c[o]/2-h[o]/2,l.setPosition(f),d.setPosition(g),u.setPosition(m);var y={x:0,y:0};if(y[r]=p?n[r]:c[r],y[o]=Math.max(c[o],h[o]),y[a]=Math.min(0,h[a]+m[1-i]),d.__rectSize=n[r],p){var b={x:0,y:0};b[r]=Math.max(n[r]-h[r]-v,0),b[o]=y[o],d.setClipPath(new lN({shape:b})),d.__rectSize=b[r]}else u.eachChild(function(e){e.attr({invisible:!0,silent:!0})});var x=this._getPageInfo(e);return null!=x.pageIndex&&dB(l,{x:x.contentPosition[0],y:x.contentPosition[1]},p?e:null),this._updatePageInfoView(e,x),y},t.prototype._pageGo=function(e,t,n){var i=this._getPageInfo(t)[e];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:t.id})},t.prototype._updatePageInfoView=function(e,t){var n=this._controllerGroup;nw(["pagePrev","pageNext"],function(i){var r=null!=t[i+"DataIndex"],o=n.childOfName(i);o&&(o.setStyle("fill",r?e.get("pageIconColor",!0):e.get("pageIconInactiveColor",!0)),o.cursor=r?"pointer":"default")});var i=n.childOfName("pageText"),r=e.get("pageFormatter"),o=t.pageIndex,a=null!=o?o+1:0,s=t.pageCount;i&&r&&i.setStyle("text",nA(r)?r.replace("{current}",null==a?"":a+"").replace("{total}",null==s?"":s+""):r({current:a,total:s}))},t.prototype._getPageInfo=function(e){var t=e.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,r=e.getOrient().index,o=P4[r],a=P6[r],s=this._findTargetItemIndex(t),l=n.children(),d=l[s],u=l.length,c=+!!u,h={contentPosition:[n.x,n.y],pageCount:c,pageIndex:c-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!d)return h;var p=y(d);h.contentPosition[r]=-p.s;for(var f=s+1,g=p,m=p,v=null;f<=u;++f)(!(v=y(l[f]))&&m.e>g.s+i||v&&!b(v,g.s))&&(g=m.i>g.i?m:v)&&(null==h.pageNextDataIndex&&(h.pageNextDataIndex=g.i),++h.pageCount),m=v;for(var f=s-1,g=p,m=p,v=null;f>=-1;--f)(!(v=y(l[f]))||!b(m,v.s))&&g.i<m.i&&(m=g,null==h.pagePrevDataIndex&&(h.pagePrevDataIndex=g.i),++h.pageCount,++h.pageIndex),g=v;return h;function y(e){if(e){var t=e.getBoundingRect(),n=t[a]+e[a];return{s:n,e:n+t[o],i:e.__legendDataIndex}}}function b(e,t){return e.e>=t&&e.s<=t+i}},t.prototype._findTargetItemIndex=function(e){var t,n;return this._showController?(this.getContentGroup().eachChild(function(i,r){var o=i.__legendDataIndex;null==n&&null!=o&&(n=r),o===e&&(t=r)}),null!=t?t:n):0},t.type="legend.scroll",t}(PK);function P7(e){mq(P2),e.registerComponentModel(P3),e.registerComponentView(P8),e.registerAction("legendScroll","legendscroll",function(e,t){var n=e.scrollDataIndex;null!=n&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(e){e.setScrollDataIndex(n)})})}var P9=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="dataZoom.inside",t.defaultOption=ud(IH.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),t}(IH),Ee=a9();function Et(e,t){if(t){e.removeKey(t.model.uid);var n=t.controller;n&&n.dispose()}}function En(e,t){e.isDisposed()||e.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:t})}function Ei(e,t,n,i){return e.coordinateSystem.containPoint([n,i])}var Er=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return(0,tQ.__extends)(t,e),t.prototype.render=function(t,n,i){var r;(e.prototype.render.apply(this,arguments),t.noTarget())?this._clear():(this.range=t.getPercentRange(),r={pan:nT(Eo.pan,this),zoom:nT(Eo.zoom,this),scrollMove:nT(Eo.scrollMove,this)},Ee(i).coordSysRecordMap.each(function(e){var n=e.dataZoomInfoMap.get(t.uid);n&&(n.getRange=r)}))},t.prototype.dispose=function(){this._clear(),e.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){!function(e,t){for(var n=Ee(e).coordSysRecordMap,i=n.keys(),r=0;r<i.length;r++){var o=i[r],a=n.get(o),s=a.dataZoomInfoMap;if(s){var l=t.uid;s.get(l)&&(s.removeKey(l),s.keys().length||Et(n,a))}}}(this.api,this.dataZoomModel),this.range=null},t.type="dataZoom.inside",t}(I$),Eo={zoom:function(e,t,n,i){var r=this.range,o=r.slice(),a=e.axisModels[0];
422if(a){var s=Es[t](null,[i.originX,i.originY],a,n,e),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(o[1]-o[0])+o[0],d=Math.max(1/i.scale,0);o[0]=(o[0]-l)*d+l,o[1]=(o[1]-l)*d+l;var u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(kF(0,o,[0,100],0,u.minSpan,u.maxSpan),this.range=o,r[0]!==o[0]||r[1]!==o[1])return o}},pan:Ea(function(e,t,n,i,r,o){var a=Es[i]([o.oldX,o.oldY],[o.newX,o.newY],t,r,n);return a.signal*(e[1]-e[0])*a.pixel/a.pixelLength}),scrollMove:Ea(function(e,t,n,i,r,o){return Es[i]([0,0],[o.scrollDelta,o.scrollDelta],t,r,n).signal*(e[1]-e[0])*o.scrollDelta})};function Ea(e){return function(t,n,i,r){var o=this.range,a=o.slice(),s=t.axisModels[0];if(s&&(kF(e(a,s,t,n,i,r),a,[0,100],"all"),this.range=a,o[0]!==a[0]||o[1]!==a[1]))return a}}var Es={grid:function(e,t,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem.getRect();return e=e||[0,0],"x"===o.dim?(a.pixel=t[0]-e[0],a.pixelLength=s.width,a.pixelStart=s.x,a.signal=o.inverse?1:-1):(a.pixel=t[1]-e[1],a.pixelLength=s.height,a.pixelStart=s.y,a.signal=o.inverse?-1:1),a},polar:function(e,t,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),d=s.getAngleAxis().getExtent();return e=e?s.pointToCoord(e):[0,0],t=s.pointToCoord(t),"radiusAxis"===n.mainType?(a.pixel=t[0]-e[0],a.pixelLength=l[1]-l[0],a.pixelStart=l[0],a.signal=o.inverse?1:-1):(a.pixel=t[1]-e[1],a.pixelLength=d[1]-d[0],a.pixelStart=d[0],a.signal=o.inverse?-1:1),a},singleAxis:function(e,t,n,i,r){var o=n.axis,a=r.model.coordinateSystem.getRect(),s={};return e=e||[0,0],"horizontal"===o.orient?(s.pixel=t[0]-e[0],s.pixelLength=a.width,s.pixelStart=a.x,s.signal=o.inverse?1:-1):(s.pixel=t[1]-e[1],s.pixelLength=a.height,s.pixelStart=a.y,s.signal=o.inverse?-1:1),s}};function El(e){IZ(e),e.registerComponentModel(P9),e.registerComponentView(Er),e.registerProcessor(e.PRIORITY.PROCESSOR.FILTER,function(e,t){var n=Ee(t),i=n.coordSysRecordMap||(n.coordSysRecordMap=n1());i.each(function(e){e.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(e){nw(Ij(e).infoList,function(n){var r,o,a,s=n.model.uid,l=i.get(s)||i.set(s,(a=(o={model:r=n.model,containsPoint:nD(Ei,r),dispatchAction:nD(En,t),dataZoomInfoMap:null,controller:null}).controller=new wZ(t.getZr()),nw(["pan","zoom","scrollMove"],function(e){a.on(e,function(t){var n=[];o.dataZoomInfoMap.each(function(i){if(t.isAvailableBehavior(i.model.option)){var r=(i.getRange||{})[e],a=r&&r(i.dzReferCoordSysInfo,o.model.mainType,o.controller,t);!i.model.get("disabled",!0)&&a&&n.push({dataZoomId:i.model.id,start:a[0],end:a[1]})}}),n.length&&o.dispatchAction(n)})}),o));(l.dataZoomInfoMap||(l.dataZoomInfoMap=n1())).set(e.uid,{dzReferCoordSysInfo:n,model:e,getRange:null})})}),i.each(function(e){var t,n,r,o,a,s=e.controller,l=e.dataZoomInfoMap;if(l){var d=l.keys()[0];null!=d&&(a=l.get(d))}if(!a)return void Et(i,e);var u=(n="type_",r={type_true:2,type_move:1,type_false:0,type_undefined:-1},o=!0,l.each(function(e){var i=e.model,a=!i.get("disabled",!0)&&(!i.get("zoomLock",!0)||"move");r[n+a]>r[n+t]&&(t=a),o=o&&i.get("preventDefaultMouseMove",!0)}),{controlType:t,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!o}});s.enable(u.controlType,u.opt),s.setPointerChecker(e.containsPoint),fj(e,"dispatchAction",a.model.get("throttle",!0),"fixRate")})})}var Ed=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.type="dataZoom.slider",t.layoutMode="box",t.defaultOption=ud(IH.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.
4221-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),t}(IH),Eu="horizontal",Ec="vertical",Eh=["line","bar","candlestick","scatter"],Ep={easing:"cubicOut",duration:100,delay:0},Ef=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._displayables={},n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){this.api=t,this._onBrush=nT(this._onBrush,this),this._onBrushEnd=nT(this._onBrushEnd,this)},t.prototype.render=function(t,n,i,r){if(e.prototype.render.apply(this,arguments),fj(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),!1===t.get("show"))return void this.group.removeAll();if(t.noTarget()){this._clear(),this.group.removeAll();return}r&&"dataZoom"===r.type&&r.from===this.uid||this._buildView(),this._updateView()},t.prototype.dispose=function(){this._clear(),e.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){fV(this,"_dispatchZoomAction");var e=this.api.getZr();e.off("mousemove",this._onBrush),e.off("mouseup",this._onBrushEnd)},t.prototype._buildView=function(){var e=this.group;e.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var t=this._displayables.sliderGroup=new av;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),e.add(t),this._positionGroup()},t.prototype._resetLocation=function(){var e=this.dataZoomModel,t=this.api,n=e.get("brushSelect"),i=this._findCoordRect(),r={width:t.getWidth(),height:t.getHeight()},o=this._orient===Eu?{right:r.width-i.x-i.width,top:r.height-30-7-7*!!n,width:i.width,height:30}:{right:7,top:i.y,width:30,height:i.height},a=u1(e.option);nw(["right","top","width","height"],function(e){"ph"===a[e]&&(a[e]=o[e])});var s=uX(a,r);this._location={x:s.x,y:s.y},this._size=[s.width,s.height],this._orient===Ec&&this._size.reverse()},t.prototype._positionGroup=function(){var e=this.group,t=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),r=i&&i.get("inverse"),o=this._displayables.sliderGroup,a=(this._dataShadowInfo||{}).otherAxisInverse;o.attr(n!==Eu||r?n===Eu&&r?{scaleY:a?1:-1,scaleX:-1}:n!==Ec||r?{scaleY:a?-1:1,scaleX:-1,rotation:Math.PI/2}:{scaleY:a?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:a?1:-1,scaleX:1});var s=e.getBoundingRect([o]);e.x=t.x-s.x,e.y=t.y-s.y,e.markRedraw()},t.prototype._getViewExtent=function(){return[0,this._size[0]]},t.prototype._renderBackground=function(){var e=this.dataZoomModel,t=this._size,n=this._displayables.sliderGroup,i=e.get("brushSelect");n.add(new lN({silent:!0,shape:{x:0,y:0,width:t[0],height:t[1]},style:{fill:e.get("backgroundColor")},z2:-40}));var r=new lN({shape:{x:0,y:0,width:t[0],height:t[1]},style:{fill:"transparent"},z2:0,onclick:nT(this._onClickPanel,this)}),o=this.api.getZr();i?(r.on("mousedown",this._onBrushStart,this),r.cursor="crosshair",o.on("mousemove",this._onBrush),o.on("mouseup",this._onBrushEnd)):(o.off("mousemove",this._onBrush),o.off("mouseup",this._onBrushEnd)),n.add(r)},t.prototype._renderDataShadow=function(){var e=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],e){var t=this._size,n=this._shadowSize||[],i=e.series,r=i.getRawData(),o=i.getShadowDim&&i.getShadowDim(),a=o&&r.getDimensionInfo(o)?i.getShadowDim():e.otherDim;if(null!=a){var s=this._shadowPolygonPts,l=this._shadowPolylinePts;if(r!==this._shadowData||a!==this._shadowDim||t[0]!==n[0]||t[1]!==n[1]){var d,u=r.getDataExtent(a),c=(u[1]-u[0])*.3;u=[u[0]-c,u[1]+c];var h=[0,t[1]],p=[0,t[0]],f=[[t[0],0],[0,0]],g=[],m=p[1]/(r.count()-1),v=0,y=Math.round(r.count()/t[0]);r.each([a],function(e,t){if(y>0&&t%y){v+=m;return}var n=null==e||isNaN(e)||""===e,i=n?0:aD(e,u,h,!0);
422n&&!d&&t?(f.push([f[f.length-1][0],0]),g.push([g[g.length-1][0],0])):!n&&d&&(f.push([v,0]),g.push([v,0])),f.push([v,i]),g.push([v,i]),v+=m,d=n}),s=this._shadowPolygonPts=f,l=this._shadowPolylinePts=g}this._shadowData=r,this._shadowDim=a,this._shadowSize=[t[0],t[1]];for(var b=this.dataZoomModel,x=0;x<3;x++){var w=function(e){var t=b.getModel(e?"selectedDataBackground":"dataBackground"),n=new av,i=new pV({shape:{points:s},segmentIgnoreThreshold:1,style:t.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),r=new pG({shape:{points:l},segmentIgnoreThreshold:1,style:t.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return n.add(i),n.add(r),n}(1===x);this._displayables.sliderGroup.add(w),this._displayables.dataShadowSegs.push(w)}}}},t.prototype._prepareDataShadowInfo=function(){var e,t=this.dataZoomModel,n=t.get("showDataShadow");if(!1!==n){var i=this.ecModel;return t.eachTargetAxis(function(r,o){nw(t.getAxisProxy(r,o).getTargetSeriesModels(),function(t){if(!e&&!(!0!==n&&0>nv(Eh,t.get("type")))){var a,s=i.getComponent(Iz(r),o).axis,l={x:"y",y:"x",radius:"angle",angle:"radius"}[r],d=t.coordinateSystem;null!=l&&d.getOtherAxis&&(a=d.getOtherAxis(s).inverse),l=t.getData().mapDimension(l),e={thisAxis:s,series:t,thisDim:r,otherDim:l,otherAxisInverse:a}}},this)},this),e}},t.prototype._renderHandle=function(){var e=this.group,t=this._displayables,n=t.handles=[null,null],i=t.handleLabels=[null,null],r=this._displayables.sliderGroup,o=this._size,a=this.dataZoomModel,s=this.api,l=a.get("borderRadius")||0,d=a.get("brushSelect"),u=t.filler=new lN({silent:d,style:{fill:a.get("fillerColor")},textConfig:{position:"inside"}});r.add(u),r.add(new lN({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:o[0],height:o[1],r:l},style:{stroke:a.get("dataBackgroundColor")||a.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}})),nw([0,1],function(t){var o=a.get("handleIcon");!gw[o]&&0>o.indexOf("path://")&&0>o.indexOf("image://")&&(o="path://"+o);var s=g_(o,-1,0,2,2,null,!0);s.attr({cursor:Eg(this._orient),draggable:!0,drift:nT(this._onDragMove,this,t),ondragend:nT(this._onDragEnd,this),onmouseover:nT(this._showDataInfo,this,!0),onmouseout:nT(this._showDataInfo,this,!1),z2:5});var l=s.getBoundingRect(),d=a.get("handleSize");this._handleHeight=aR(d,this._size[1]),this._handleWidth=l.width/l.height*this._handleHeight,s.setStyle(a.getModel("handleStyle").getItemStyle()),s.style.strokeNoScale=!0,s.rectHover=!0,s.ensureState("emphasis").style=a.getModel(["emphasis","handleStyle"]).getItemStyle(),dk(s);var u=a.get("handleColor");null!=u&&(s.style.fill=u),r.add(n[t]=s);var c=a.getModel("textStyle"),h=(a.get("handleLabel")||{}).show||!1;e.add(i[t]=new lj({silent:!0,invisible:!h,style:dZ(c,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:c.getTextColor(),font:c.getFont()}),z2:10}))},this);var c=u;if(d){var h=aR(a.get("moveHandleSize"),o[1]),p=t.moveHandle=new lN({style:a.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:o[1]-.5,height:h}}),f=.8*h,g=t.moveHandleIcon=g_(a.get("moveHandleIcon"),-f/2,-f/2,f,f,"#fff",!0);g.silent=!0,g.y=o[1]+h/2-.5,p.ensureState("emphasis").style=a.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(o[1]/2,Math.max(h,10));(c=t.moveZone=new lN({invisible:!0,shape:{y:o[1]-m,height:h+m}})).on("mouseover",function(){s.enterEmphasis(p)}).on("mouseout",function(){s.leaveEmphasis(p)}),r.add(p),r.add(g),r.add(c)}c.attr({draggable:!0,cursor:Eg(this._orient),drift:nT(this._onDragMove,this,"all"),ondragstart:nT(this._showDataInfo,this,!0),ondragend:nT(this._onDragEnd,this),onmouseover:nT(this._showDataInfo,this,!0),onmouseout:nT(this._showDataInfo,this,!1)})},t.prototype._resetInterval=function(){var e=this._range=this.dataZoomModel.getPercentRange(),t=this._getViewExtent();this._handleEnds=[aD(e[0],[0,100],t,!0),aD(e[1],[0,100],t,!0)]},t.prototype._updateInterval=function(e,t){var n=this.dataZoomModel,i=this._handleEnds,r=this._getViewExtent(),o=n.findRepresentativeAxisProxy().getMinMaxSpan(),a=[0,100];kF(t,i,r,n.get("zoomLock")?"all":e,null!=o.minSpan?aD(o.minSpan,a,r,!0):null,null!=o.maxSpan?aD(o.maxSpan,a,r,!0):null);var s=this._range,l=this._range=aA([aD(i[0],r,a,!0),aD(i[1],r,a,!0)]);return!s||s[0]!==l[0]||s[1]!==l[1]},t.prototype._updateView=function(e){var t=this._displayables,n=this._handleEnds,i=aA(n.slice()),r=this._size;nw([0,1],function(e){var i=t.handles[e],o=this._handleHeight;i.attr({scaleX:o/2,scaleY:o/2,x:n[e]+(e?-1:1),y:r[1]/2-o/2})},this),t.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:r[1]});var o={x:i[0],width:i[1]-i[0]};t.moveHandle&&(t.moveHandle.setShape(o),t.moveZone.setShape(o),t.moveZone.getBoundingRect
422(),t.moveHandleIcon&&t.moveHandleIcon.attr("x",o.x+o.width/2));for(var a=t.dataShadowSegs,s=[0,i[0],i[1],r[0]],l=0;l<a.length;l++){var d=a[l],u=d.getClipPath();u||(u=new lN,d.setClipPath(u)),u.setShape({x:s[l],y:0,width:s[l+1]-s[l],height:r[1]})}this._updateDataInfo(e)},t.prototype._updateDataInfo=function(e){var t=this.dataZoomModel,n=this._displayables,i=n.handleLabels,r=this._orient,o=["",""];if(t.get("showDetail")){var a=t.findRepresentativeAxisProxy();if(a){var s=a.getAxisModel().axis,l=this._range,d=e?a.calculateDataWindow({start:l[0],end:l[1]}).valueWindow:a.getDataValueWindow();o=[this._formatLabel(d[0],s),this._formatLabel(d[1],s)]}}var u=aA(this._handleEnds.slice());function c(e){var t=fm(n.handles[e].parent,this.group),a=fy(0===e?"right":"left",t),s=this._handleWidth/2+5,l=fv([u[e]+(0===e?-s:s),this._size[1]/2],t);i[e].setStyle({x:l[0],y:l[1],verticalAlign:r===Eu?"middle":a,align:r===Eu?a:"center",text:o[e]})}c.call(this,0),c.call(this,1)},t.prototype._formatLabel=function(e,t){var n=this.dataZoomModel,i=n.get("labelFormatter"),r=n.get("labelPrecision");(null==r||"auto"===r)&&(r=t.getPixelPrecision());var o=null==e||isNaN(e)?"":"category"===t.type||"time"===t.type?t.scale.getLabel({value:Math.round(e)}):e.toFixed(Math.min(r,20));return nI(i)?i(e,o):nA(i)?i.replace("{value}",o):o},t.prototype._showDataInfo=function(e){var t=(this.dataZoomModel.get("handleLabel")||{}).show||!1,n=this.dataZoomModel.getModel(["emphasis","handleLabel"]).get("show")||!1,i=e||this._dragging?n:t,r=this._displayables,o=r.handleLabels;o[0].attr("invisible",!i),o[1].attr("invisible",!i),r.moveHandle&&this.api[i?"enterEmphasis":"leaveEmphasis"](r.moveHandle,1)},t.prototype._onDragMove=function(e,t,n,i){this._dragging=!0,iH(i.event);var r=fv([t,n],this._displayables.sliderGroup.getLocalTransform(),!0),o=this._updateInterval(e,r[0]),a=this.dataZoomModel.get("realtime");this._updateView(!a),o&&a&&this._dispatchZoomAction(!0)},t.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1),this.dataZoomModel.get("realtime")||this._dispatchZoomAction(!1)},t.prototype._onClickPanel=function(e){var t=this._size,n=this._displayables.sliderGroup.transformCoordToLocal(e.offsetX,e.offsetY);if(!(n[0]<0)&&!(n[0]>t[0])&&!(n[1]<0)&&!(n[1]>t[1])){var i=this._handleEnds,r=(i[0]+i[1])/2,o=this._updateInterval("all",n[0]-r);this._updateView(),o&&this._dispatchZoomAction(!1)}},t.prototype._onBrushStart=function(e){var t=e.offsetX,n=e.offsetY;this._brushStart=new i2(t,n),this._brushing=!0,this._brushStartTime=+new Date},t.prototype._onBrushEnd=function(e){if(this._brushing){var t=this._displayables.brushRect;if(this._brushing=!1,t){t.attr("ignore",!0);var n=t.shape;if(!(new Date-this._brushStartTime<200&&5>Math.abs(n.width))){var i=this._getViewExtent(),r=[0,100];this._range=aA([aD(n.x,i,r,!0),aD(n.x+n.width,i,r,!0)]),this._handleEnds=[n.x,n.x+n.width],this._updateView(),this._dispatchZoomAction(!1)}}}},t.prototype._onBrush=function(e){this._brushing&&(iH(e.event),this._updateBrushRect(e.offsetX,e.offsetY))},t.prototype._updateBrushRect=function(e,t){var n=this._displayables,i=this.dataZoomModel,r=n.brushRect;r||(r=n.brushRect=new lN({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(r)),r.attr("ignore",!1);var o=this._brushStart,a=this._displayables.sliderGroup,s=a.transformCoordToLocal(e,t),l=a.transformCoordToLocal(o.x,o.y),d=this._size;s[0]=Math.max(Math.min(d[0],s[0]),0),r.setShape({x:l[0],y:0,width:s[0]-l[0],height:d[1]})},t.prototype._dispatchZoomAction=function(e){var t=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:e?Ep:null,start:t[0],end:t[1]})},t.prototype._findCoordRect=function(){var e,t=Ij(this.dataZoomModel).infoList;if(!e&&t.length){var n=t[0].model.coordinateSystem;e=n.getRect&&n.getRect()}if(!e){var i=this.api.getWidth(),r=this.api.getHeight();e={x:.2*i,y:.2*r,width:.6*i,height:.6*r}}return e},t.type="dataZoom.slider",t}(I$);function Eg(e){return"vertical"===e?"ns-resize":"ew-resize"}function Em(e){e.registerComponentModel(Ed),e.registerComponentView(Ef),IZ(e)}var Ev={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]}
422,colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}};let Ey=function(e,t,n){var i=nc((Ev[e]||{})[t]);return n&&nR(i)?i[i.length-1]:i};var Eb=S5.mapVisual,Ex=S5.eachVisual,Ew=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.stateList=["inRange","outOfRange"],n.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],n.layoutMode={type:"box",ignoreSize:!0},n.dataBound=[-1/0,1/0],n.targetVisuals={},n.controllerVisuals={},n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n)},t.prototype.optionUpdated=function(e,t){var n=this.option;t||A$(n,e,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},t.prototype.resetVisual=function(e){var t=this.stateList;e=nT(e,this),this.controllerVisuals=AW(this.option.controller,t,e),this.targetVisuals=AW(this.option.target,t,e)},t.prototype.getItemSymbol=function(){return null},t.prototype.getTargetSeriesIndices=function(){var e=this.option.seriesIndex,t=[];return null==e||"all"===e?this.ecModel.eachSeries(function(e,n){t.push(n)}):t=aJ(e),t},t.prototype.eachTargetSeries=function(e,t){nw(this.getTargetSeriesIndices(),function(n){var i=this.ecModel.getSeriesByIndex(n);i&&e.call(t,i)},this)},t.prototype.isTargetSeries=function(e){var t=!1;return this.eachTargetSeries(function(n){n===e&&(t=!0)}),t},t.prototype.formatValueText=function(e,t,n){var i,r=this.option,o=r.precision,a=this.dataBound,s=r.formatter;n=n||["<",">"],nR(e)&&(e=e.slice(),i=!0);var l=t?e:i?[d(e[0]),d(e[1])]:d(e);if(nA(s))return s.replace("{value}",i?l[0]:l).replace("{value2}",i?l[1]:l);if(nI(s))return i?s(e[0],e[1]):s(e);if(!i)return l;if(e[0]===a[0])return n[0]+" "+l[1];if(e[1]===a[1])return n[1]+" "+l[0];return l[0]+" - "+l[1];function d(e){return e===a[0]?"min":e===a[1]?"max":(+e).toFixed(Math.min(o,20))}},t.prototype.resetExtent=function(){var e=this.option,t=aA([e.min,e.max]);this._dataExtent=t},t.prototype.getDataDimensionIndex=function(e){var t=this.option.dimension;if(null!=t)return e.getDimensionIndex(t);for(var n=e.dimensions,i=n.length-1;i>=0;i--){var r=n[i],o=e.getDimensionInfo(r);if(!o.isCalculationCoord)return o.storeDimIndex}},t.prototype.getExtent=function(){return this._dataExtent.slice()},t.prototype.completeVisualOption=function(){var e=this.ecModel,t=this.option,n={inRange:t.inRange,outOfRange:t.outOfRange},i=t.target||(t.target={}),r=t.controller||(t.controller={});nh(i,n),nh(r,n);var o=this.isCategory();function a(n){nR(t.color)&&!n.inRange&&(n.inRange={color:t.color.slice().reverse()}),n.inRange=n.inRange||{color:e.get("gradientColor")}}a.call(this,i),a.call(this,r),(function(e,t,n){var i=e[t],r=e[n];i&&!r&&(r=e[n]={},nw(i,function(e,t){if(S5.isValidType(t)){var n=Ey(t,"inactive",o);null!=n&&(r[t]=n,"color"!==t||r.hasOwnProperty("opacity")||r.hasOwnProperty("colorAlpha")||(r.opacity=[0,0]))}}))}).call(this,i,"inRange","outOfRange"),(function(e){var t=(e.inRange||{}).symbol||(e.outOfRange||{}).symbol,n=(e.inRange||{}).symbolSize||(e.outOfRange||{}).symbolSize,i=this.get("inactiveColor"),r=this.getItemSymbol()||"roundRect";nw(this.stateList,function(a){var s=this.itemSize,l=e[a];l||(l=e[a]={color:o?i:[i]}),null==l.symbol&&(l.symbol=t&&nc(t)||(o?r:[r])),null==l.symbolSize&&(l.symbolSize=n&&nc(n)||(o?s[0]:[s[0],s[0]])),l.symbol=Eb(l.symbol,function(e){return"none"===e?r:e});var d=l.symbolSize;if(null!=d){var u=-1/0;Ex(d,function(e){e>u&&(u=e)}),l.symbolSize=Eb(d,function(e){return aD(e,[0,u],[0,s[0]],!0)})}},this)}).call(this,r)},t.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},t.prototype.isCategory=function(){return!!this.option.categories},t.prototype.setSelected=function(e){},t.prototype.getSelected=function(){return null},t.prototype.getValueState=function(e){return null},t.prototype.getVisualMeta=function(e){return null},t.type="visualMap",t.dependencies=["series"],t.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},t}(u5),EC=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.optionUpdated=function(t,n){e.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(e){e.mappingMethod="linear",e.dataExtent=this.getExtent()}),this._resetRange()},t.prototype.resetItemSize=function(){e.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(null==t[0]||isNaN(t[0]))&&(t[0]=20),(null==t[1]||isNaN(t[1]))&&(t[1]=140)},t.prototype._resetRange=function(){var e=this.getExtent(),t=this.option.range;!t||t.auto?(e.auto=1,this.option.range=e):nR(t)&&(t[0]>t[1]&&t.reverse(),t[0]=Math.max(t[0],e[0]),t[1]=Math.min(t[1],e[1]))},t.prototype.completeVisualOption=function(){e.prototype.completeVisualOption.apply(this,arguments),nw(this.stateList,function(e){var t=this.option.controller[e].symbolSize;t&&t[0]!==t[1]&&(t[0]=t[1]/3)},this)},t.prototype.setSelected=function(e){this.option.range=e.slice(),this._resetRange()},t.prototype.getSelected=function(){var e=this.getExtent(),t=aA((this.get("range")||[]).slice());return t[0]>e[1]&&(t[0]=e[1]),t[1]>e[1]&&(t[1]=e[1]),t[0]<e[0]&&(t[0]=e[0]),t[1]<e[0]&&(t[1]=e[0]),t},t.prototype.getValueState=function(e){var t=this.option.range,n=this.getExtent();return(t[0]<=n[0]||t[0]<=e)&&(t[1]>=n[1]||e<=t[1])?"inRange":"outOfRange"},t.prototype.findTargetDataIndices=function(e){var t=[];return this.eachTargetSeries(function(n){var i=[],r=n.getData();r.each(this.getDataDimensionIndex(r),function(t,n){e[0]<=t&&t<=e[1]&&i.push(n)},this),t.push({seriesId:n.id,dataIndex:i})},this),t},t.prototype.getVisualMeta=function(e){var t=ES(this,"outOfRange",this.getExtent()),n=ES(this,"inRange",this.option.range.slice()),i=[];function r(t,n){i.push({value:t,color:e(t,n)})}for(var o=0,a=0,s=n.length,l=t.length;a<l&&(!n.length||t[a]<=n[0]);a++)t[a]<n[o]&&r(t[a],"outOfRange");for(var d=1;o<s;o++,d=0)d&&i.length&&r(n[o],"outOfRange"),r(n[o],"inRange");for(var d=1;a<l;
vendor: 4,621 bytes, line 422
422a++)(!n.length||n[n.length-1]<t[a])&&(d&&(i.length&&r(i[i.length-1].value,"outOfRange"),d=0),r(t[a],"outOfRange"));var u=i.length;return{stops:i,outerColors:[u?i[0].color:"transparent",u?i[u-1].color:"transparent"]}},t.type="visualMap.continuous",t.defaultOption=ud(Ew.defaultOption,{align:"auto",calculable:!1,hoverLink:!0,realtime:!0,handleIcon:"path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z",handleSize:"120%",handleStyle:{borderColor:"#fff",borderWidth:1},indicatorIcon:"circle",indicatorSize:"50%",indicatorStyle:{borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}}),t}(Ew);function ES(e,t,n){if(n[0]===n[1])return n.slice();for(var i=(n[1]-n[0])/200,r=n[0],o=[],a=0;a<=200&&r<n[1];a++)o.push(r),r+=i;return o.push(n[1]),o}var E_=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.autoPositionValues={left:1,right:1,top:1,bottom:1},n}return(0,tQ.__extends)(t,e),t.prototype.init=function(e,t){this.ecModel=e,this.api=t},t.prototype.render=function(e,t,n,i){(this.visualMapModel=e,!1===e.get("show"))?this.group.removeAll():this.doRender(e,t,n,i)},t.prototype.renderBackground=function(e){var t=this.visualMapModel,n=nU(t.get("padding")||0),i=e.getBoundingRect();e.add(new lN({z2:-1,silent:!0,shape:{x:i.x-n[3],y:i.y-n[0],width:i.width+n[3]+n[1],height:i.height+n[0]+n[2]},style:{fill:t.get("backgroundColor"),stroke:t.get("borderColor"),lineWidth:t.get("borderWidth")}}))},t.prototype.getControllerVisual=function(e,t,n){var i=(n=n||{}).forceState,r=this.visualMapModel,o={};function a(e){return o[e]}function s(e,t){o[e]=t}"color"===t&&(o.color=r.get("contentColor"));var l=r.controllerVisuals[i||r.getValueState(e)];return nw(S5.prepareVisualTypes(l),function(i){var r=l[i];n.convertOpacityToAlpha&&"opacity"===i&&(i="colorAlpha",r=l.__alphaForOpacity),S5.dependsOn(i,t)&&r&&r.applyVisual(e,a,s)}),o[t]},t.prototype.positionGroup=function(e){var t=this.visualMapModel,n=this.api;uJ(e,t.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()})},t.prototype.doRender=function(e,t,n,i){},t.type="visualMap",t}(h9),Ek=[["left","right","width"],["top","bottom","height"]];function EM(e,t,n){var i=e.option,r=i.align;if(null!=r&&"auto"!==r)return r;for(var o={width:t.getWidth(),height:t.getHeight()},a=+("horizontal"===i.orient),s=Ek[a],l=[0,null,10],d={},u=0;u<3;u++)d[Ek[1-a][u]]=l[u],d[s[u]]=2===u?n[0]:i[s[u]];var c=[["x","width",3],["y","height",0]][a],h=uX(d,o,i.padding);return s[(h.margin[c[2]]||0)+h[c[0]]+.5*h[c[1]]<.5*o[c[1]]?0:1]}function ET(e,t){return nw(e||[],function(e){null!=e.dataIndex&&(e.dataIndexInside=e.dataIndex,e.dataIndex=null),e.highlightKey="visualMap"+(t?t.componentIndex:"")}),e}var ED=Math.min,ER=Math.max,EI=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._shapes={},n._dataInterval=[],n._handleEnds=[],n._hoverLinkDataIndices=[],n}return(0,tQ.__extends)(t,e),t.prototype.init=function(t,n){e.prototype.init.call(this,t,n),this._hoverLinkFromSeriesMouseOver=nT(this._hoverLinkFromSeriesMouseOver,this),this._hideIndicator=nT(this._hideIndicator,this)},t.prototype.doRender=function(e,t,n,i){i&&"selectDataRange"===i.type&&i.from===this.uid||this._buildView()},t.prototype._buildView=function(){this.group.removeAll();var e=this.visualMapModel,t=this.group;this._orient=e.get("orient"),this._useHandle=e.get("calculable"),this._resetInterval(),this._renderBar(t);var n=e.get("text");this._renderEndsText(t,n,0),this._renderEndsText(t,n,1),this._updateView(!0),this.renderBackground(t),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(t)},t.prototype._renderEndsText=function(e,t,n){if(t){var i=t[1-n];i=null!=i?i+"":"";var r=this.visualMapModel,o=r.get("textGap"),a=r.itemSize,s=this._shapes.mainGroup,l=this._applyTransform([a[0]/2,0===n?-o:a[1]+o],s),d=this._applyTransform(0===n?"bottom":"top",s),u=this._orient,c=this.visualMapModel.textStyleModel;this.group.add(new lj({style:dZ(c,{x:l[0],y:l[1],verticalAlign:"horizontal"===u?"middle":d,align:"horizontal"===u?d:"center",text:i})}))}},t.prototype._renderBar=function(e){var t=this.visualMapModel,n=this._shapes,i=t.itemSize,r=this._orient,o=this._useHandle,a=EM(t,this.api,i),s=n.mainGroup=this._createBarGroup(a),l=new av;s.add(l),l.add(n.outOfRange=EA()),l.add(n.inRange=EA(null,o?EE(this._orient):null,nT(this._dragHandle,this,"all",!1),nT(this._dragHandle,this,"all",!0))),l.setClipPath(new lN({shape:{x:0,y:0,width:i[0],height:i[1],r:3}}));
vendor: 18,774 bytes, line 422
422var d=t.textStyleModel.getTextRect("å½"),u=ER(d.width,d.height);o&&(n.handleThumbs=[],n.handleLabels=[],n.handleLabelPoints=[],this._createHandle(t,s,0,i,u,r),this._createHandle(t,s,1,i,u,r)),this._createIndicator(t,s,i,u,r),e.add(s)},t.prototype._createHandle=function(e,t,n,i,r,o){var a=nT(this._dragHandle,this,n,!1),s=nT(this._dragHandle,this,n,!0),l=as(e.get("handleSize"),i[0]),d=g_(e.get("handleIcon"),-l/2,-l/2,l,l,null,!0),u=EE(this._orient);d.attr({cursor:u,draggable:!0,drift:a,ondragend:s,onmousemove:function(e){iH(e.event)}}),d.x=i[0]/2,d.useStyle(e.getModel("handleStyle").getItemStyle()),d.setStyle({strokeNoScale:!0,strokeFirst:!0}),d.style.lineWidth*=2,d.ensureState("emphasis").style=e.getModel(["emphasis","handleStyle"]).getItemStyle(),dA(d,!0),t.add(d);var c=new lj({cursor:u,draggable:!0,drift:a,onmousemove:function(e){iH(e.event)},ondragend:s,style:dZ(this.visualMapModel.textStyleModel,{x:0,y:0,text:""})});c.ensureState("blur").style={opacity:.1},c.stateTransition={duration:200},this.group.add(c);var h=[l,0],p=this._shapes;p.handleThumbs[n]=d,p.handleLabelPoints[n]=h,p.handleLabels[n]=c},t.prototype._createIndicator=function(e,t,n,i,r){var o=as(e.get("indicatorSize"),n[0]),a=g_(e.get("indicatorIcon"),-o/2,-o/2,o,o,null,!0);a.attr({cursor:"move",invisible:!0,silent:!0,x:n[0]/2});var s=e.getModel("indicatorStyle").getItemStyle();if(a instanceof lI){var l=a.style;a.useStyle(nf({image:l.image,x:l.x,y:l.y,width:l.width,height:l.height},s))}else a.useStyle(s);t.add(a);var d=new lj({silent:!0,invisible:!0,style:dZ(this.visualMapModel.textStyleModel,{x:0,y:0,text:""})});this.group.add(d);var u=[("horizontal"===r?i/2:6)+n[0]/2,0],c=this._shapes;c.indicator=a,c.indicatorLabel=d,c.indicatorLabelPoint=u,this._firstShowIndicator=!0},t.prototype._dragHandle=function(e,t,n,i){if(this._useHandle){if(this._dragging=!t,!t){var r=this._applyTransform([n,i],this._shapes.mainGroup,!0);this._updateInterval(e,r[1]),this._hideIndicator(),this._updateView()}!this.visualMapModel.get("realtime")===t&&this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),t?this._hovering||this._clearHoverLinkToSeries():EP(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[e],!1)}},t.prototype._resetInterval=function(){var e=this.visualMapModel,t=this._dataInterval=e.getSelected(),n=e.getExtent(),i=[0,e.itemSize[1]];this._handleEnds=[aD(t[0],n,i,!0),aD(t[1],n,i,!0)]},t.prototype._updateInterval=function(e,t){t=t||0;var n=this.visualMapModel,i=this._handleEnds,r=[0,n.itemSize[1]];kF(t,i,r,e,0);var o=n.getExtent();this._dataInterval=[aD(i[0],r,o,!0),aD(i[1],r,o,!0)]},t.prototype._updateView=function(e){var t=this.visualMapModel,n=t.getExtent(),i=this._shapes,r=[0,t.itemSize[1]],o=e?r:this._handleEnds,a=this._createBarVisual(this._dataInterval,n,o,"inRange"),s=this._createBarVisual(n,n,r,"outOfRange");i.inRange.setStyle({fill:a.barColor}).setShape("points",a.barPoints),i.outOfRange.setStyle({fill:s.barColor}).setShape("points",s.barPoints),this._updateHandle(o,a)},t.prototype._createBarVisual=function(e,t,n,i){var r={forceState:i,convertOpacityToAlpha:!0},o=this._makeColorGradient(e,r),a=[this.getControllerVisual(e[0],"symbolSize",r),this.getControllerVisual(e[1],"symbolSize",r)],s=this._createBarPoints(n,a);return{barColor:new p1(0,0,0,1,o),barPoints:s,handlesColor:[o[0].color,o[o.length-1].color]}},t.prototype._makeColorGradient=function(e,t){var n=[],i=(e[1]-e[0])/100;n.push({color:this.getControllerVisual(e[0],"color",t),offset:0});for(var r=1;r<100;r++){var o=e[0]+i*r;if(o>e[1])break;n.push({color:this.getControllerVisual(o,"color",t),offset:r/100})}return n.push({color:this.getControllerVisual(e[1],"color",t),offset:1}),n},t.prototype._createBarPoints=function(e,t){var n=this.visualMapModel.itemSize;return[[n[0]-t[0],e[0]],[n[0],e[0]],[n[0],e[1]],[n[0]-t[1],e[1]]]},t.prototype._createBarGroup=function(e){var t=this._orient,n=this.visualMapModel.get("inverse");return new av("horizontal"===t&&!n?{scaleX:"bottom"===e?1:-1,rotation:Math.PI/2}:"horizontal"===t&&n?{scaleX:"bottom"===e?-1:1,rotation:-Math.PI/2}:"vertical"===t&&!n?{scaleX:"left"===e?1:-1,scaleY:-1}:{scaleX:"left"===e?1:-1})},t.prototype._updateHandle=function(e,t){if(this._useHandle){var n=this._shapes,i=this.visualMapModel,r=n.handleThumbs,o=n.handleLabels,a=i.itemSize,s=i.getExtent(),l=this._applyTransform("left",n.mainGroup);nw([0,1],function(d){var u=r[d];u.setStyle("fill",t.handlesColor[d]),u.y=e[d];var c=aD(e[d],[0,a[1]],s,!0),h=this.getControllerVisual(c,"symbolSize");u.scaleX=u.scaleY=h/a[0],u.x=a[0]-h/2;var p=fv(n.handleLabelPoints[d],fm(u,this.group));if("horizontal"===this._orient){var f="left"===l||"top"===l?(a[0]-h)/2:-((a[0]-h)/2);p[1]+=f}o[d].setStyle({x:p[0],y:p[1],text:i.formatValueText(this._dataInterval[d]),verticalAlign:"middle",align:"vertical"===this._orient?this._applyTransform("left",n.mainGroup):"center"})},this)}},t.prototype._showIndicator=function(e,t,n,i){var r=this.visualMapModel,o=r.getExtent(),a=r.itemSize,s=[0,a[1]],l=this._shapes,d=l.indicator;if(d){d.attr("invisible",!1);var u=this.getControllerVisual(e,"color",{convertOpacityToAlpha:!0}),c=this.getControllerVisual(e,"symbolSize"),h=aD(e,o,s,!0),p=a[0]-c/2,f={x:d.x,y:d.y};d.y=h,d.x=p;var g=fv(l.indicatorLabelPoint,fm(d,this.group)),m=l.indicatorLabel;m.attr("invisible",!1);var v=this._applyTransform("left",l.mainGroup),y="horizontal"===this._orient;m.setStyle({text:(n||"")+r.formatValueText(t),verticalAlign:y?v:"middle",align:y?"center":v});var b={x:p,y:h,style:{fill:u}},x={style:{x:g[0],y:g[1]}};if(r.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var w={duration:100,easing:"cubicInOut",additive:!0};d.x=f.x,d.y=f.y,d.animateTo(b,w),m.animateTo(x,w)}else d.attr(b),m.attr(x);this._firstShowIndicator=!1;var C=this._shapes.handleLabels;if(C)for(var S=0;S<C.length;S++)this.api.enterBlur(C[S])}},t.prototype._enableHoverLinkToSeries=function(){var e=this;this._shapes.mainGroup.on("mousemove",function(t){if(e._hovering=!0,!e._dragging){var n=e.visualMapModel.itemSize,i=e._applyTransform([t.offsetX,t.offsetY],e._shapes.mainGroup,!0,!0);i[1]=ED(ER(0,i[1]),n[1]),e._doHoverLinkToSeries(i[1],0<=i[0]&&i[0]<=n[0])}}).on("mouseout",function(){e._hovering=!1,e._dragging||e._clearHoverLinkToSeries()})},t.prototype._enableHoverLinkFromSeries=function(){var e=this.api.getZr();this.visualMapModel.option.hoverLink?(e.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),e.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},t.prototype._doHoverLinkToSeries=function(e,t){var n=this.visualMapModel,i=n.itemSize;if(n.option.hoverLink){var r,o,a,s,l,d=[0,i[1]],u=n.getExtent();e=ED(ER(d[0],e),d[1]);var c=(r=n,o=u,a=d,s=6,(l=r.get("hoverLinkDataSize"))&&(s=aD(l,o,a,!0)/2),s),h=[e-c,e+c],p=aD(e,d,u,!0),f=[aD(h[0],d,u,!0),aD(h[1],d,u,!0)];h[0]<d[0]&&(f[0]=-1/0),h[1]>d[1]&&(f[1]=1/0),t&&(f[0]===-1/0?this._showIndicator(p,f[1],"< ",c):f[1]===1/0?this._showIndicator(p,f[0],"> ",c):this._showIndicator(p,p,"â ",c));var g=this._hoverLinkDataIndices,m=[];(t||EP(n))&&(m=this._hoverLinkDataIndices=n.findTargetDataIndices(f));var v=function(e,t){var n={},i={};return r(e||[],n),r(t||[],i,n),[o(n),o(i)];function r(e,t,n){for(var i=0,r=e.length;i<r;i++){var o=a4(e[i].seriesId,null);if(null==o)return;for(var a=aJ(e[i].dataIndex),s=n&&n[o],l=0,d=a.length;l<d;l++){var u=a[l];s&&s[u]?s[u]=null:(t[o]||(t[o]={}))[u]=1}}}function o(e,t){var n=[];for(var i in e)if(e.hasOwnProperty(i)&&null!=e[i])if(t)n.push(+i);else{var r=o(e[i],!0);r.length&&n.push({seriesId:i,dataIndex:r})}return n}}(g,m);this._dispatchHighDown("downplay",ET(v[0],n)),this._dispatchHighDown("highlight",ET(v[1],n))}},t.prototype._hoverLinkFromSeriesMouseOver=function(e){if(gh(e.target,function(e){var n=lQ(e);if(null!=n.dataIndex)return t=n,!0},!0),t){var t,n=this.ecModel.getSeriesByIndex(t.seriesIndex),i=this.visualMapModel;if(i.isTargetSeries(n)){var r=n.getData(t.dataType),o=r.getStore().get(i.getDataDimensionIndex(r),t.dataIndex);isNaN(o)||this._showIndicator(o,o)}}},t.prototype._hideIndicator=function(){var e=this._shapes;e.indicator&&e.indicator.attr("invisible",!0),e.indicatorLabel&&e.indicatorLabel.attr("invisible",!0);var t=this._shapes.handleLabels;if(t)for(var n=0;n<t.length;n++)this.api.leaveBlur(t[n])},t.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var e=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",ET(e,this.visualMapModel)),e.length=0},t.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var e=this.api.getZr();e.off("mouseover",this._hoverLinkFromSeriesMouseOver),e.off("mouseout",this._hideIndicator)},t.prototype._applyTransform=function(e,t,n,i){var r=fm(t,i?null:this.group);return nR(e)?fv(e,r,n):fy(e,r,n)},t.prototype._dispatchHighDown=function(e,t){t&&t.length&&this.api.dispatchAction({type:e,batch:t})},t.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},t.type="visualMap.continuous",t}(E_);function EA(e,t,n,i){return new pV({shape:{points:e},draggable:!!n,cursor:t,drift:n,onmousemove:function(e){iH(e.event)},ondragend:i})}function EP(e){var t=e.get("hoverLinkOnHandle");return!!(null==t?e.get("realtime"):t)}function EE(e){return"vertical"===e?"ns-resize":"ew-resize"}var EL={type:"selectDataRange",event:"dataRangeSelected",update:"update"},EF=function(e,t){t.eachComponent({mainType:"visualMap",query:e},function(t){t.setSelected(e.selected)})},EO=[{createOnAllSeries:!0,reset:function(e,t){var n=[];return t.eachComponent("visualMap",function(t){var i,r,o,a,s,l=e.pipelineContext;!t.isTargetSeries(e)||l&&l.large||n.push((i=t.stateList,r=t.targetVisuals,o=nT(t.getValueState,t),a=t.getDataDimensionIndex(e.getData()),s={},nw(i,function(e){var t=S5.prepareVisualTypes(r[e]);s[e]=t}),{progress:function(e,t){function n(e){return gs(t,d,e)}function i(e,n){gd(t,d,e,n)}null!=a&&(l=t.getDimensionIndex(a));for(var l,d,u=t.getStore();null!=(d=e.next());){var c=t.getRawDataItem(d);if(!c||!1!==c.visualMap)for(var h=null!=a?u.get(l,d):d,p=o(h),f=r[p],g=s[p],m=0,v=g.length;m<v;m++){var y=g[m];f[y]&&f[y].applyVisual(h,n,i)}}}}))}),n}},{createOnAllSeries:!0,reset:function(e,t){var n=e.getData(),i=[];t.eachComponent("visualMap",function(t){if(t.isTargetSeries(e)){var r=t.getVisualMeta(nT(EN,null,e,t))||{stops:[],outerColors:[]},o=t.getDataDimensionIndex(n);o>=0&&(r.dimension=o,i.push(r))}}),e.getData().setVisual("visualMeta",i)}}];function EN(e,t,n,i){for(var r=t.targetVisuals[i],o=S5.prepareVisualTypes(r),a={color:gl(e.getData(),"color")},s=0,l=o.length;s<l;s++){var d=o[s],u=r["opacity"===d?"__alphaForOpacity":d];u&&u.applyVisual(n,c,h)}return a.color;function c(e){return a[e]}function h(e,t){a[e]=t}}function EB(e){var t=e&&e.visualMap;nR(t)||(t=t?[t]:[]),nw(t,function(e){if(e){Ez(e,"splitList")&&!Ez(e,"pieces")&&(e.pieces=e.splitList,delete e.splitList);var t=e.pieces;t&&nR(t)&&nw(t,function(e){nL(e)&&(Ez(e,"start")&&!Ez(e,"min")&&(e.min=e.start),Ez(e,"end")&&!Ez(e,"max")&&(e.max=e.end))})}})}function Ez(e,t){return e&&e.hasOwnProperty&&e.hasOwnProperty(t)}var Ej=!1;function EV(e){Ej||(Ej=!0,e.registerSubTypeDefaulter("visualMap",function(e){return e.categories||(e.pieces?e.pieces.length>0:e.splitNumber>0)&&!e.calculable?"piecewise":"continuous"}),e.registerAction(EL,EF),nw(EO,function(t){e.registerVisual(e.PRIORITY.VISUAL.COMPONENT,t)}),e.registerPreprocessor(EB))}function EH(e){e.registerComponentModel(EC),e.registerComponentView(EI),EV(e)}var EG=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n._pieceList=[],n}return(0,tQ.__extends)(t,e),t.prototype.optionUpdated=function(t,n){e.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var i=this._mode=this._determineMode();this._pieceList=[],EW[this._mode].call(this,this._pieceList),this._resetSelected(t,n);var r=this.option.categories;this.resetVisual(function(e,t){"categories"===i?(e.mappingMethod="category",e.categories=nc(r)):(e.dataExtent=this.getExtent(),e.mappingMethod="piecewise",e.pieceList=nC(this._pieceList,function(e){return e=nc(e),"inRange"!==t&&(e.visual=null),e}))})},t.prototype.completeVisualOption=function(){var t=this.option,n={},i=S5.listVisualTypes(),r=this.isCategory();function o(e,t,n){return e&&e[t]&&e[t].hasOwnProperty(n)}nw(t.pieces,function(e){nw(i,function(t){e.hasOwnProperty(t)&&(n[t]=1)})}),nw(n,function(e,n){var i=!1;nw(this.stateList,function(e){i=i||o(t,e,n)||o(t.target,e,n)},this),i||nw(this.stateList,function(e){(t[e]||(t[e]={}))[n]=Ey(n,"inRange"===e?"active":"inactive",r)})},this),e.prototype.completeVisualOption.apply(this,arguments)},t.prototype._resetSelected=function(e,t){var n=this.option,i=this._pieceList,r=(t?n:e).selected||{};if(n.selected=r,nw(i,function(e,t){var n=this.getSelectedMapKey(e);r.hasOwnProperty(n)||(r[n]=!0)},this),"single"===n.selectedMode){var o=!1;nw(i,function(e,t){var n=this.getSelectedMapKey(e);r[n]&&(o?r[n]=!1:o=!0)},this)}},t.prototype.getItemSymbol=function(){return this.get("itemSymbol")},t.prototype.getSelectedMapKey=function(e){return"categories"===this._mode?e.value+"":e.index+""},t.prototype.getPieceList=function(){return this._pieceList},t.prototype._determineMode=function(){var e=this.option;return e.pieces&&e.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},t.prototype.setSelected=function(e){this.option.selected=nc(e)},t.prototype.getValueState=function(e){var t=S5.findPieceIndex(e,this._pieceList);return null!=t&&this.option.selected[this.getSelectedMapKey(this._pieceList[t])]?"inRange":"outOfRange"},t.prototype.findTargetDataIndices=function(e){var t=[],n=this._pieceList;return this.eachTargetSeries(function(i){var r=[],o=i.getData();o.each(this.getDataDimensionIndex(o),function(t,i){S5.findPieceIndex(t,n)===e&&r.push(i)},this),t.push({seriesId:i.id,dataIndex:r})},this),t},t.prototype.getRepresentValue=function(e){var t;if(this.isCategory())t=e.value;else if(null!=e.value)t=e.value;else{var n=e.interval||[];t=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return t},t.prototype.getVisualMeta=function(e){if(!this.isCategory()){var t=[],n=["",""],i=this,r=this._pieceList.slice();if(r.length){var o=r[0].interval[0];o!==-1/0&&r.unshift({interval:[-1/0,o]}),(o=r[r.length-1].interval[1])!==1/0&&r.push({interval:[o,1/0]})}else r.push({interval:[-1/0,1/0]});var a=-1/0;return nw(r,function(e){var t=e.interval;t&&(t[0]>a&&s([a,t[0]],"outOfRange"),s(t.slice()),a=t[1])},this),{stops:t,outerColors:n}}function s(r,o){var a=i.getRepresentValue({interval:r});o||(o=i.getValueState(a));var s=e(a,o);r[0]===-1/0?n[0]=s:r[1]===1/0?n[1]=s:t.push({value:r[0],color:s},{value:r[1],color:s})}},t.type="visualMap.piecewise",t.defaultOption=ud(Ew.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),t}(Ew),EW={splitNumber:function(e){var t=this.option,n=Math.min(t.precision,20),i=this.getExtent(),r=t.splitNumber;t.splitNumber=r=Math.max(parseInt(r,10),1);for(var o=(i[1]-i[0])/r;+o.toFixed(n)!==o&&n<5;)n++;t.precision=n,o=+o.toFixed(n),t.minOpen&&e.push({interval:[-1/0,i[0]],close:[0,0]});for(var a=0,s=i[0];a<r;s+=o,a++){var l=a===r-1?i[1]:s+o;e.push({interval:[s,l],close:[1,1]})}t.maxOpen&&e.push({interval:[i[1],1/0],close:[0,0]}),a$(e),nw(e,function(e,t){e.index=t,e.text=this.formatValueText(e.interval)},this)},categories:function(e){var t=this.option;nw(t.categories,function(t){e.push({text:this.formatValueText(t,!0),value:t})},this),E$(t,e)},pieces:function(e){var t=this.option;nw(t.pieces,function(t,n){nL(t)||(t={value:t});var i={text:"",index:n};if(null!=t.label&&(i.text=t.label),t.hasOwnProperty("value")){var r=i.value=t.value;i.interval=[r,r],i.close=[1,1]}else{for(var o=i.interval=[],a=i.close=[0,0],s=[1,0,1],l=[-1/0,1/0],d=[],u=0;u<2;u++){for(var c=[["gte","gt","min"],["lte","lt","max"]][u],h=0;h<3&&null==o[u];h++)o[u]=t[c[h]],a[u]=s[h],d[u]=2===h;null==o[u]&&(o[u]=l[u])}d[0]&&o[1]===1/0&&(a[0]=0),d[1]&&o[0]===-1/0&&(a[1]=0),o[0]===o[1]&&a[0]&&a[1]&&(i.value=o[0])}i.visual=S5.retrieveVisuals(t),e.push(i)},this),E$(t,e),a$(e),nw(e,function(e){var t=e.close,n=[["<","â¤"][t[1]],[">","â¥"][t[0]]];e.text=e.text||this.formatValueText(null!=e.value?e.value:e.interval,!1,n)},this)}};function E$(e,t){var n=e.inverse;("vertical"===e.orient?!n:n)&&t.reverse()}var EU=function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,tQ.__extends)(t,e),t.prototype.doRender=function(){var e=this.group;e.removeAll();var t=this.visualMapModel,n=t.get("textGap"),i=t.textStyleModel,r=i.getFont(),o=i.getTextColor(),a=this._getItemAlign(),s=t.itemSize,l=this._getViewData(),d=l.endsText,u=nH(t.get("showLabel",!0),!d),c=!t.get("selectedMode");d&&this._renderEndsText(e,d[0],s,u,a),nw(l.viewPieceList,function(i){var l=i.piece,d=new av;d.onclick=nT(this._onItemClick,this,l),this._enableHoverLink(d,i.indexInModelPieceList);var h=t.getRepresentValue(l);if(this._createItemSymbol(d,h,[0,0,s[0],s[1]],c),u){var p=this.visualMapModel.getValueState(h);d.add(new lj({style:{x:"right"===a?-n:s[0]+n,y:s[1]/2,text:l.text,verticalAlign:"middle",align:a,font:r,fill:o,opacity:"outOfRange"===p?.5:1},silent:c}))}e.add(d)},this),d&&this._renderEndsText(e,d[1],s,u,a),uZ(t.get("orient"),e,t.get("itemGap")),this.renderBackground(e),this.positionGroup(e)},t.prototype._enableHoverLink=function(e,t){var n=this;e.on("mouseover",function(){return i("highlight")}).on("mouseout",function(){return i("downplay")});var i=function(e){var i=n.visualMapModel;i.option.hoverLink&&n.api.dispatchAction({type:e,batch:ET(i.findTargetDataIndices(t),i)})}},t.prototype._getItemAlign=function(){var e=this.visualMapModel,t=e.option;if("vertical"===t.orient)return EM(e,this.api,e.itemSize);var n=t.align;return n&&"auto"!==n||(n="left"),n},t.prototype._renderEndsText=function(e,t,n,i,r){if(t){var o=new av,a=this.visualMapModel.textStyleModel;o.add(new lj({style:dZ(a,{x:i?"right"===r?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:i?r:"center",text:t})})),e.add(o)}},t.prototype._getViewData=function(){var e=this.visualMapModel,t=nC(e.getPieceList(),function(e,t){return{piece:e,indexInModelPieceList:t}}),n=e.get("text"),i=e.get("orient"),r=e.get("inverse");return("horizontal"===i?r:!r)?t.reverse():n&&(n=n.slice().reverse()),{viewPieceList:t,endsText:n}},t.prototype._createItemSymbol=function(e,t,n,i){var r=g_(this.getControllerVisual(t,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(t,"color"));r.silent=i,e.add(r)},t.prototype._onItemClick=function(e){var t=this.visualMapModel,n=t.option,i=n.selectedMode;if(i){var r=nc(n.selected),o=t.getSelectedMapKey(e);
422"single"===i||!0===i?(r[o]=!0,nw(r,function(e,t){r[t]=t===o})):r[o]=!r[o],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:r})}},t.type="visualMap.piecewise",t}(E_);function Eq(e){e.registerComponentModel(EG),e.registerComponentView(EU),EV(e)}var EK={label:{enabled:!0},decal:{show:!1}},EY=a9(),EZ={};function EX(e,t){var n=e.getModel("aria");if(n.get("enabled")){var i=nc(EK);nh(i.label,e.getLocaleModel().get("aria"),!1),nh(n.option,i,!1),function(){if(n.getModel("decal").get("show")){var t=n1();e.eachSeries(function(e){if(!e.isColorBySeries()){var n=t.get(e.type);n||(n={},t.set(e.type,n)),EY(e).scope=n}}),e.eachRawSeries(function(t){if(!e.isSeriesFiltered(t)){if(nI(t.enableAriaDecal))return void t.enableAriaDecal();var n=t.getData();if(t.isColorBySeries()){var i=cy(t.ecModel,t.name,EZ,e.getSeriesCount()),r=n.getVisual("decal");n.setVisual("decal",d(r,i))}else{var o=t.getRawData(),a={},s=EY(t).scope;n.each(function(e){a[n.getRawIndex(e)]=e});var l=o.count();o.each(function(e){var i=a[e],r=o.getName(e)||e+"",u=cy(t.ecModel,r,s,l),c=n.getItemVisual(i,"decal");n.setItemVisual(i,"decal",d(c,u))})}}function d(e,t){var n=e?nf(nf({},t),e):t;return n.dirty=!0,n}})}}(),function(){var i,o=t.getZr().dom;if(o){var a=e.getLocaleModel().get("aria"),s=n.getModel("label");if(s.option=ng(s.option,a),s.get("enabled")){if(o.setAttribute("role","img"),s.get("description"))return o.setAttribute("aria-label",s.get("description"));var l,d=e.getSeriesCount(),u=s.get(["data","maxCount"])||10,c=Math.min(d,s.get(["series","maxCount"])||10);if(d<1)return;var h=((l=e.get("title"))&&l.length&&(l=l[0]),l&&l.text);i=h?r(s.get(["general","withTitle"]),{title:h}):s.get(["general","withoutTitle"]);var p=[];i+=r(d>1?s.get(["series","multiple","prefix"]):s.get(["series","single","prefix"]),{seriesCount:d}),e.eachSeries(function(t,n){if(n<c){var i,o,a=void 0,l=t.get("name")?"withName":"withoutName";a=r(a=d>1?s.get(["series","multiple",l]):s.get(["series","single",l]),{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:(i=t.subType,(o=e.getLocaleModel().get(["series","typeNames"]))[i]||o.chart)});var h=t.getData();h.count()>u?a+=r(s.get(["data","partialData"]),{displayCnt:u}):a+=s.get(["data","allData"]);for(var f=s.get(["data","separator","middle"]),g=s.get(["data","separator","end"]),m=s.get(["data","excludeDimensionId"]),v=[],y=0;y<h.count();y++)if(y<u){var b=h.getName(y),x=m?n_(h.getValues(y),function(e,t){return -1===nv(m,t)}):h.getValues(y),w=s.get(["data",b?"withName":"withoutName"]);v.push(r(w,{name:b,value:x.join(f)}))}a+=v.join(f)+g,p.push(a)}});var f=s.getModel(["series","multiple","separator"]),g=f.get("middle"),m=f.get("end");i+=p.join(g)+m,o.setAttribute("aria-label",i)}}}()}function r(e,t){if(!nA(e))return e;var n=e;return nw(t,function(e,t){n=n.replace(RegExp("\\{\\s*"+t+"\\s*\\}","g"),e)}),n}}function EJ(e){if(e&&e.aria){var t=e.aria;null!=t.show&&(t.enabled=t.show),t.label=t.label||{},nw(["description","general","series","data"],function(e){null!=t[e]&&(t.label[e]=t[e])})}}var EQ=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="dataset",t}return(0,tQ.__extends)(t,e),t.prototype.init=function(t,n,i){e.prototype.init.call(this,t,n,i),this._sourceManager=new hE(this),hL(this)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),hL(this)},t.prototype.optionUpdated=function(){this._sourceManager.dirty()},t.prototype.getSourceManager=function(){return this._sourceManager},t.type="dataset",t.defaultOption={seriesLayoutBy:cs},t}(u5),E0=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="dataset",t}return(0,tQ.__extends)(t,e),t.type="dataset",t}(h9),E1={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},E2=function(){function e(e){null==(this._condVal=nA(e)?new RegExp(e):nj(e)?e:null)&&cw("")}return e.prototype.evaluate=function(e){var t=typeof e;return nA(t)?this._condVal.test(e):!!nE(t)&&this._condVal.test(e+"")},e}(),E3=function(){function e(){}return e.prototype.evaluate=function(){return this.value},e}(),E5=function(){function e(){}return e.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(!e[t].evaluate())return!1;return!0},e}(),E4=function(){function e(){}return e.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(e[t].evaluate())return!0;return!1},e}(),E6=function(){function e(){}return e.prototype.evaluate=function(){return!this.child.evaluate()},e}(),E8=function(){function e(){}return e.prototype.evaluate=function(){for(var e=!!this.valueParser,t=(0,this.getValue)(this.valueGetterParam),n=e?this.valueParser(t):null,i=0;i<this.subCondList.length;i++)if(!this.subCondList[i].evaluate(e?n:t))return!1;return!0},e}();function E7(e,t){if(!0===e||!1===e){var n,i,r,o,a,s=new E3;return s.value=e,s}if(nL(n=e)&&!nx(n)||cw(""),e.and)return E9("and",e,t);if(e.or)return E9("or",e,t);if(e.not){return i=e,r=t,function(e){return nL(e)&&!nx(e)}(o=i.not)||cw(""),(a=new E6).child=E7(o,r),a.child||cw(""),a}return function(e,t){for(var n=t.prepareGetValue(e),i=[],r=nM(e),o=e.parser,a=o?hc.get(o):null,
422s=0;s<r.length;s++){var l=r[s];if(!("parser"===l||t.valueGetterAttrMap.get(l))){var d=n4(E1,l)?E1[l]:l,u=e[l],c=a?a(u):u,h=("eq"===d||"ne"===d?new hg("eq"===d,c):n4(hh,d)?new hp(d,c):null)||"reg"===d&&new E2(c);h||cw(""),i.push(h)}}i.length||cw("");var p=new E8;return p.valueGetterParam=n,p.valueParser=a,p.getValue=t.getValue,p.subCondList=i,p}(e,t)}function E9(e,t,n){var i=t[e];nR(i)||cw(""),i.length||cw("");var r="and"===e?new E5:new E4;return r.children=nC(i,function(e){return E7(e,n)}),r.children.length||cw(""),r}var Le=function(){function e(e,t){this._cond=E7(e,t)}return e.prototype.evaluate=function(){return this._cond.evaluate()},e}(),Lt={type:"echarts:filter",transform:function(e){for(var t,n=e.upstream,i=new Le(e.config,{valueGetterAttrMap:n1({dimension:!0}),prepareGetValue:function(e){var t=e.dimension;n4(e,"dimension")||cw("");var i=n.getDimensionInfo(t);return i||cw(""),{dimIdx:i.index}},getValue:function(e){return n.retrieveValueFromItem(t,e.dimIdx)}}),r=[],o=0,a=n.count();o<a;o++)t=n.getRawDataItem(o),i.evaluate()&&r.push(t);return{data:r}}},Ln={type:"echarts:sort",transform:function(e){var t=e.upstream,n=aJ(e.config);n.length||cw("");var i=[];nw(n,function(e){var n=e.dimension,r=e.order,o=e.parser,a=e.incomparable;null==n&&cw(""),"asc"!==r&&"desc"!==r&&cw(""),a&&"min"!==a&&"max"!==a&&cw(""),"asc"!==r&&"desc"!==r&&cw("");var s=t.getDimensionInfo(n);s||cw("");var l=o?hc.get(o):null;o&&!l&&cw(""),i.push({dimIdx:s.index,parser:l,comparator:new hf(r,a)})});var r=t.sourceFormat;r!==cn&&r!==ci&&cw("");for(var o=[],a=0,s=t.count();a<s;a++)o.push(t.getRawDataItem(a));return o.sort(function(e,n){for(var r=0;r<i.length;r++){var o=i[r],a=t.retrieveValueFromItem(e,o.dimIdx),s=t.retrieveValueFromItem(n,o.dimIdx);o.parser&&(a=o.parser(a),s=o.parser(s));var l=o.comparator.evaluate(a,s);if(0!==l)return l}return 0}),{data:o}}},Li=lu.CMD;function Lr(e,t){return 1e-5>Math.abs(e-t)}function Lo(e){var t,n,i,r,o,a=e.data,s=e.len(),l=[],d=0,u=0,c=0,h=0;function p(e,n){t&&t.length>2&&l.push(t),t=[e,n]}function f(e,n,i,r){Lr(e,i)&&Lr(n,r)||t.push(e,n,i,r,i,r)}for(var g=0;g<s;){var m=a[g++],v=1===g;switch(v&&(d=a[g],u=a[g+1],c=d,h=u,(m===Li.L||m===Li.C||m===Li.Q)&&(t=[c,h])),m){case Li.M:d=c=a[g++],u=h=a[g++],p(c,h);break;case Li.L:f(d,u,n=a[g++],i=a[g++]),d=n,u=i;break;case Li.C:t.push(a[g++],a[g++],a[g++],a[g++],d=a[g++],u=a[g++]);break;case Li.Q:n=a[g++],i=a[g++],r=a[g++],o=a[g++],t.push(d+2/3*(n-d),u+2/3*(i-u),r+2/3*(n-r),o+2/3*(i-o),r,o),d=r,u=o;break;case Li.A:var y=a[g++],b=a[g++],x=a[g++],w=a[g++],C=a[g++],S=a[g++]+C;g+=1;var _=!a[g++];n=Math.cos(C)*x+y,i=Math.sin(C)*w+b,v?p(c=n,h=i):f(d,u,n,i),d=Math.cos(S)*x+y,u=Math.sin(S)*w+b;for(var k=(_?-1:1)*Math.PI/2,M=C;_?M>S:M<S;M+=k){var T=_?Math.max(M+k,S):Math.min(M+k,S);!function(e,n,i,r,o,a){var s=4*Math.tan(Math.abs(n-e)/4)/3,l=n<e?-1:1,d=Math.cos(e),u=Math.sin(e),c=Math.cos(n),h=Math.sin(n),p=c*o+i,f=h*a+r,g=o*s*l,m=a*s*l;t.push(d*o+i-g*u,u*a+r+m*d,p+g*h,f-m*c,p,f)}(M,T,y,b,x,w)}break;case Li.R:c=d=a[g++],h=u=a[g++],n=c+a[g++],i=h+a[g++],p(n,h),f(n,h,n,i),f(n,i,c,i),f(c,i,c,h),f(c,h,n,h);break;case Li.Z:t&&f(d,u,c,h),d=c,u=h}}return t&&t.length>2&&l.push(t),l}function La(e,t,n){var i=Math.ceil(Math.sqrt(Math.abs(e[t]/e[1-t])*n)),r=Math.floor(n/i);0===r&&(r=1,i=n);for(var o=[],a=0;a<i;a++)o.push(r);var s=n-i*r;if(s>0)for(var a=0;a<s;a++)o[a%i]+=1;return o}function Ls(e,t,n){for(var i=e.r0,r=e.r,o=e.startAngle,a=Math.abs(e.endAngle-o),s=a*r,l=r-i,d=s>Math.abs(l),u=La([s,l],+!d,t),c=(d?a:l)/u.length,h=0;h<u.length;h++)for(var p=(d?l:a)/u[h],f=0;f<u[h];f++){var g={};d?(g.startAngle=o+c*h,g.endAngle=o+c*(h+1),g.r0=i+p*f,g.r=i+p*(f+1)):(g.startAngle=o+p*f,g.endAngle=o+p*(f+1),g.r0=i+c*h,g.r=i+c*(h+1)),g.clockwise=e.clockwise,g.cx=e.cx,g.cy=e.cy,n.push(g)}}function Ll(e,t){var n=e[e.length-1];n&&n[0]===t[0]&&n[1]===t[1]||e.push(t)}function Ld(e){var t=e.points,n=[],i=[];sJ(t,n,i);var r=new rt(n[0],n[1],i[0]-n[0],i[1]-n[1]),o=r.width,a=r.height,s=r.x,l=r.y,d=new i2,u=new i2;return o>a?(d.x=u.x=s+o/2,d.y=l,u.y=l+a):(d.y=u.y=l+a/2,d.x=s,u.x=s+o),function(e,t,n){for(var i=e.length,r=[],o=0;o<i;o++){var a=e[o],s=e[(o+1)%i],l=function(e,t,n,i,r,o,a,s){var l=n-e,d=i-t,u=a-r,c=s-o,h=u*d-l*c;if(1e-6>Math.abs(h))return null;var p=((e-r)*c-u*(t-o))/h;return p<0||p>1?null:new i2(p*l+e,p*d+t)}(a[0],a[1],s[0],s[1],t.x,t.y,n.x,n.y);l&&r.push({projPt:function(e,t,n){var i=new i2;i2.sub(i,n,t),i.normalize();var r=new i2;return i2.sub(r,e,t),r.dot(i)}
422(l,t,n),pt:l,idx:o})}if(r.length<2)return[{points:e},{points:e}];r.sort(function(e,t){return e.projPt-t.projPt});var d=r[0],u=r[r.length-1];if(u.idx<d.idx){var c=d;d=u,u=c}for(var h=[d.pt.x,d.pt.y],p=[u.pt.x,u.pt.y],f=[h],g=[p],o=d.idx+1;o<=u.idx;o++)Ll(f,e[o].slice());Ll(f,p),Ll(f,h);for(var o=u.idx+1;o<=d.idx+i;o++)Ll(g,e[o%i].slice());return Ll(g,h),Ll(g,p),[{points:f},{points:g}]}(t,d,u)}function Lu(e,t,n,i){if(1===n)i.push(t);else{var r=Math.floor(n/2),o=e(t);Lu(e,o[0],r,i),Lu(e,o[1],n-r,i)}return i}function Lc(e,t){for(var n=e.length,i=e[n-2],r=e[n-1],o=[],a=0;a<t.length;)o[a++]=i,o[a++]=r;return o}function Lh(e){for(var t=0,n=0,i=0,r=e.length,o=0,a=r-2;o<r;a=o,o+=2){var s=e[a],l=e[a+1],d=e[o],u=e[o+1],c=s*u-d*l;t+=c,n+=(s+d)*c,i+=(l+u)*c}return 0===t?[e[0]||0,e[1]||0]:[n/t/3,i/t/3,t]}function Lp(e){return e.__isCombineMorphing}var Lf="__mOriginal_";function Lg(e,t,n){var i=Lf+t,r=e[i]||e[t];e[i]||(e[i]=e[t]);var o=n.replace,a=n.after,s=n.before;e[t]=function(){var e,t=arguments;return s&&s.apply(this,t),e=o?o.apply(this,t):r.apply(this,t),a&&a.apply(this,t),e}}function Lm(e,t){var n=Lf+t;e[n]&&(e[t]=e[n],e[n]=null)}function Lv(e,t){for(var n=0;n<e.length;n++)for(var i=e[n],r=0;r<i.length;){var o=i[r],a=i[r+1];i[r++]=t[0]*o+t[2]*a+t[4],i[r++]=t[1]*o+t[3]*a+t[5]}}function Ly(e,t){var n=e.getUpdatedPathProxy(),i=t.getUpdatedPathProxy(),r=function(e,t){for(var n,i,r,o=[],a=[],s=0;s<Math.max(e.length,t.length);s++){var l=e[s],d=t[s],u=void 0,c=void 0;l?d?(u=(n=function(e,t){var n=e.length,i=t.length;if(n===i)return[e,t];for(var r=[],o=[],a=n<i?e:t,s=Math.min(n,i),l=Math.abs(i-n)/6,d=Math.ceil(l/((s-2)/6))+1,u=[a[0],a[1]],c=l,h=2;h<s;){var p=a[h-2],f=a[h-1],g=a[h++],m=a[h++],v=a[h++],y=a[h++],b=a[h++],x=a[h++];if(c<=0){u.push(g,m,v,y,b,x);continue}for(var w=Math.min(c,d-1)+1,C=1;C<=w;C++){var S=C/w;rL(p,g,v,b,S,r),rL(f,m,y,x,S,o),p=r[3],f=o[3],u.push(r[1],o[1],r[2],o[2],p,f),g=r[5],m=o[5],v=r[6],y=o[6]}c-=w-1}return a===e?[u,t]:[e,u]}(l,d))[0],c=n[1],i=u,r=c):(c=Lc(r||l,l),u=l):(u=Lc(i||d,d),c=d),o.push(u),a.push(c)}return[o,a]}(Lo(n),Lo(i)),o=r[0],a=r[1],s=e.getComputedTransform(),l=t.getComputedTransform();s&&Lv(o,s),l&&Lv(a,l),Lg(t,"updateTransform",{replace:function(){this.transform=null}}),t.transform=null;var d=function(e,t,n,i){for(var r,o=[],a=0;a<e.length;a++){var s=e[a],l=t[a],d=Lh(s),u=Lh(l);null==r&&(r=d[2]<0!=u[2]<0);var c=[],h=[],p=0,f=1/0,g=[],m=s.length;r&&(s=function(e){for(var t=[],n=e.length,i=0;i<n;i+=2)t[i]=e[n-i-2],t[i+1]=e[n-i-1];return t}(s));for(var v=6*function(e,t,n,i){for(var r=(e.length-2)/6,o=1/0,a=0,s=e.length,l=s-2,d=0;d<r;d++){for(var u=6*d,c=0,h=0;h<s;h+=2){var p=0===h?u:(u+h-2)%l+2,f=e[p]-n[0],g=e[p+1]-n[1],m=t[h]-i[0],v=t[h+1]-i[1],y=m-f,b=v-g;c+=y*y+b*b}c<o&&(o=c,a=d)}return a}(s,l,d,u),y=m-2,b=0;b<y;b+=2){var x=(v+b)%y+2;c[b+2]=s[x]-d[0],c[b+3]=s[x+1]-d[1]}c[0]=s[v]-d[0],c[1]=s[v+1]-d[1];for(var w=i/10,C=-i/2;C<=i/2;C+=w){for(var S=Math.sin(C),_=Math.cos(C),k=0,b=0;b<s.length;b+=2){var M=c[b],T=c[b+1],D=l[b]-u[0],R=l[b+1]-u[1],I=D*_-R*S,A=D*S+R*_;g[b]=I,g[b+1]=A;var P=I-M,E=A-T;k+=P*P+E*E}if(k<f){f=k,p=C;for(var L=0;L<g.length;L++)h[L]=g[L]}}o.push({from:c,to:h,fromCp:d,toCp:u,rotation:-p})}return o}(o,a,0,Math.PI),u=[];Lg(t,"buildPath",{replace:function(e){for(var n=t.__morphT,i=1-n,r=[],o=0;o<d.length;o++){var a=d[o],s=a.from,l=a.to,c=a.rotation*n,h=a.fromCp,p=a.toCp,f=Math.sin(c),g=Math.cos(c);iv(r,h,p,n);for(var m=0;m<s.length;m+=2){var v=s[m],y=s[m+1],b=l[m],x=l[m+1],w=v*i+b*n,C=y*i+x*n;u[m]=w*g-C*f+r[0],u[m+1]=w*f+C*g+r[1]}var S=u[0],_=u[1];e.moveTo(S,_);for(var m=2;m<s.length;){var b=u[m++],x=u[m++],k=u[m++],M=u[m++],T=u[m++],D=u[m++];S===b&&_===x&&k===T&&M===D?e.lineTo(T,D):e.bezierCurveTo(b,x,k,M,T,D),S=T,_=D}}}})}function Lb(e,t,n){if(!e||!t)return t;var i=n.done,r=n.during;return Ly(e,t),t.__morphT=0,t.animateTo({__morphT:1},ng({during:function(e){t.dirtyShape(),r&&r(e)},done:function(){Lm(t,"buildPath"),Lm(t,"updateTransform"),t.__morphT=-1,t.createPathProxy(),t.dirtyShape(),i&&i()}},n)),t}function Lx(e){var t=1/0,n=1/0,i=-1/0,r=-1/0,o=nC(e,function(e){var o=e.getBoundingRect
422(),a=e.getComputedTransform(),s=o.x+o.width/2+(a?a[4]:0),l=o.y+o.height/2+(a?a[5]:0);return t=Math.min(s,t),n=Math.min(l,n),i=Math.max(s,i),r=Math.max(l,r),[s,l]});return nC(o,function(o,a){return{cp:o,z:function(e,t,n,i,r,o){e=r===n?0:Math.round(32767*(e-n)/(r-n)),t=o===i?0:Math.round(32767*(t-i)/(o-i));for(var a,s=0,l=32768;l>0;l/=2){var d=0,u=0;(e&l)>0&&(d=1),(t&l)>0&&(u=1),s+=l*l*(3*d^u),0===u&&(1===d&&(e=l-1-e,t=l-1-t),a=e,e=t,t=a)}return s}(o[0],o[1],t,n,i,r),path:e[a]}}).sort(function(e,t){return e.z-t.z}).map(function(e){return e.path})}function Lw(e){return function(e,t){var n,i=[],r=e.shape;switch(e.type){case"rect":!function(e,t,n){for(var i=e.width,r=e.height,o=i>r,a=La([i,r],+!o,t),s=o?"width":"height",l=o?"height":"width",d=o?"x":"y",u=o?"y":"x",c=e[s]/a.length,h=0;h<a.length;h++)for(var p=e[l]/a[h],f=0;f<a[h];f++){var g={};g[d]=h*c,g[u]=f*p,g[s]=c,g[l]=p,g.x+=e.x,g.y+=e.y,n.push(g)}}(r,t,i),n=lN;break;case"sector":Ls(r,t,i),n=pO;break;case"circle":Ls({r0:0,r:r.r,startAngle:0,endAngle:2*Math.PI,cx:r.cx,cy:r.cy},t,i),n=pO;break;default:var o=e.getComputedTransform(),a=o?Math.sqrt(Math.max(o[0]*o[0]+o[1]*o[1],o[2]*o[2]+o[3]*o[3])):1,s=nC(function(e,t){var n=Lo(e),i=[];t=t||1;for(var r=0;r<n.length;r++){var o=n[r],a=[],s=o[0],l=o[1];a.push(s,l);for(var d=2;d<o.length;){var u=o[d++],c=o[d++],h=o[d++],p=o[d++],f=o[d++],g=o[d++];!function e(t,n,i,r,o,a,s,l,d,u){if(Lr(t,i)&&Lr(n,r)&&Lr(o,s)&&Lr(a,l))return void d.push(s,l);var c=2/u,h=c*c,p=s-t,f=l-n,g=Math.sqrt(p*p+f*f);p/=g,f/=g;var m=i-t,v=r-n,y=o-s,b=a-l,x=m*m+v*v,w=y*y+b*b;if(x<h&&w<h)return void d.push(s,l);var C=p*m+f*v,S=-p*y-f*b;if(x-C*C<h&&C>=0&&w-S*S<h&&S>=0)return void d.push(s,l);var _=[],k=[];rL(t,i,o,s,.5,_),rL(n,r,a,l,.5,k),e(_[0],k[0],_[1],k[1],_[2],k[2],_[3],k[3],d,u),e(_[4],k[4],_[5],k[5],_[6],k[6],_[7],k[7],d,u)}(s,l,u,c,h,p,f,g,a,t),s=f,l=g}i.push(a)}return i}(e.getUpdatedPathProxy(),a),function(e){for(var t=[],n=0;n<e.length;)t.push([e[n++],e[n++]]);return t}),l=s.length;if(0===l)Lu(Ld,{points:s[0]},t,i);else if(l===t)for(var d=0;d<l;d++)i.push({points:s[d]});else{var u=0,c=nC(s,function(e){var t=[],n=[];sJ(e,t,n);var i=(n[1]-t[1])*(n[0]-t[0]);return u+=i,{poly:e,area:i}});c.sort(function(e,t){return t.area-e.area});for(var h=t,d=0;d<l;d++){var p=c[d];if(h<=0)break;var f=d===l-1?h:Math.ceil(p.area/u*t);f<0||(Lu(Ld,{points:p.poly},f,i),h-=f)}}n=pV}if(!n){for(var g=[],m=0;m<t;m++)g.push(pb(e));return g}for(var v=[],d=0;d<i.length;d++){var y=new n;y.setShape(i[d]),y.setStyle(e.style),y.z=e.z,y.z2=e.z2,y.zlevel=e.zlevel,v.push(y)}return v}(e.path,e.count)}function LC(){return{fromIndividuals:[],toIndividuals:[],count:0}}function LS(e,t){for(var n=[],i=e.length,r=0;r<i;r++)n.push({one:e[r],many:[]});for(var r=0;r<t.length;r++){var o=t[r].length,a=void 0;for(a=0;a<o;a++)n[a%i].many.push(t[r][a])}for(var s=0,r=i-1;r>=0;r--)if(!n[r].many.length){var l=n[s].many;if(l.length<=1)if(!s)return n;else s=0;var o=l.length,d=Math.ceil(o/2);n[r].many=l.slice(d,o),n[s].many=l.slice(0,d),s++}return n}var L_={clone:function(e){for(var t=[],n=1-Math.pow(1-e.path.style.opacity,1/e.count),i=0;i<e.count;i++){var r=pb(e.path);r.setStyle("opacity",n),t.push(r)}return t},split:null};function Lk(e,t,n,i,r,o){if(e.length&&t.length){var a,s,l=dO("update",i,r);if(l&&l.duration>0){var d=i.getModel("universalTransition").get("delay"),u=Object.assign({setToFinal:!0},l);nR(e[0])&&(a=e,s=t),nR(t[0])&&(a=t,s=e);for(var c=a?a===e:e.length>t.length,h=a?LS(s,a):LS(c?t:e,[c?e:t]),p=0,f=0;f<h.length;f++)p+=h[f].many.length;for(var g=0,f=0;f<h.length;f++)(function e(t,i,r,a,s){var l=t.many,c=t.one;if(1!==l.length||s)for(var h=ng({dividePath:L_[n],individualDelay:d&&function(e,t,n,i){return d(e+r,a)}},u),p=i?function(e,t,n){var i=[];!function e(t){for(var n=0;n<t.length;n++){var r=t[n];Lp(r)?e(r.childrenRef()):r instanceof lk&&i.push(r)}}(e);var r=i.length;if(!r)return LC();var o=(n.dividePath||Lw)({path:t,count:r});if(o.length!==r)return console.error("Invalid morphing: unmatched splitted path"),LC();i=Lx(i),o=Lx(o);for(var a=n.done,s=n.during,l=n.individualDelay,d=new o8,u=0;u<r;u++){var c=i[u],h=o[u];h.parent=t,h.copyTransform(d),l||Ly(c,h)}function p(e){for(var t=0;t<o.length;t++)o[t].addSelfToZr(e)}
422function f(){t.__isCombineMorphing=!1,t.__morphT=-1,t.childrenRef=null,Lm(t,"addSelfToZr"),Lm(t,"removeSelfFromZr")}t.__isCombineMorphing=!0,t.childrenRef=function(){return o},Lg(t,"addSelfToZr",{after:function(e){p(e)}}),Lg(t,"removeSelfFromZr",{after:function(e){for(var t=0;t<o.length;t++)o[t].removeSelfFromZr(e)}});var g=o.length;if(l)for(var m=g,v=function(){0==--m&&(f(),a&&a())},u=0;u<g;u++){var y=l?ng({delay:(n.delay||0)+l(u,g,i[u],o[u]),done:v},n):n;Lb(i[u],o[u],y)}else t.__morphT=0,t.animateTo({__morphT:1},ng({during:function(e){for(var n=0;n<g;n++){var i=o[n];i.__morphT=t.__morphT,i.dirtyShape()}s&&s(e)},done:function(){f();for(var t=0;t<e.length;t++)Lm(e[t],"updateTransform");a&&a()}},n));return t.__zr&&p(t.__zr),{fromIndividuals:i,toIndividuals:o,count:g}}(l,c,h):function(e,t,n){var i=t.length,r=[],o=n.dividePath||Lw;if(Lp(e)){!function e(t){for(var n=0;n<t.length;n++){var i=t[n];Lp(i)?e(i.childrenRef()):i instanceof lk&&r.push(i)}}(e.childrenRef());var a=r.length;if(a<i)for(var s=0,l=a;l<i;l++)r.push(pb(r[s++%a]));r.length=i}else{r=o({path:e,count:i});for(var d=e.getComputedTransform(),l=0;l<r.length;l++)r[l].setLocalTransform(d);if(r.length!==i)return console.error("Invalid morphing: unmatched splitted path"),LC()}r=Lx(r),t=Lx(t);for(var u=n.individualDelay,l=0;l<i;l++){var c=u?ng({delay:(n.delay||0)+u(l,i,r[l],t[l])},n):n;Lb(r[l],t[l],c)}return{fromIndividuals:r,toIndividuals:t,count:t.length}}(c,l,h),f=p.fromIndividuals,g=p.toIndividuals,m=f.length,v=0;v<m;v++){var y=d?ng({delay:d(v,m)},u):u;o(f[v],g[v],i?l[v]:t.one,i?t.one:l[v],y)}else{var b=i?l[0]:c,x=i?c:l[0];if(Lp(b))e({many:[b],one:x},!0,r,a,!0);else{var y=d?ng({delay:d(r,a)},u):u;Lb(b,x,y),o(b,x,b,x,y)}}})(h[f],c,g,p),g+=h[f].many.length}}}function LM(e){if(!e)return[];if(nR(e)){for(var t=[],n=0;n<e.length;n++)t.push(LM(e[n]));return t}var i=[];return e.traverse(function(e){e instanceof lk&&!e.disableMorphing&&!e.invisible&&!e.ignore&&i.push(e)}),i}var LT=a9();function LD(e,t,n,i){var r=function(e,t){for(var n=e.dimensions,i=0;i<n.length;i++){var r=e.getDimensionInfo(n[i]);if(r&&0===r.otherDims[t])return n[i]}}(e,i?"itemChildGroupId":"itemGroupId");if(r){var o=e,a=t,s=r,l=o.getDimensionInfo(s),d=l&&l.ordinalMeta;if(l){var u=o.get(l.name,a);return d&&d.categories[u]||u+""}return}var c=e.getRawDataItem(t),h=i?"childGroupId":"groupId";return c&&c[h]?c[h]+"":i?void 0:n||e.getId(t)}function LR(e){var t=[];return nw(e,function(e){var n=e.data,i=e.dataGroupId;if(!(n.count()>1e4))for(var r=n.getIndices(),o=0;o<r.length;o++)t.push({data:n,groupId:LD(n,o,i,!1),childGroupId:LD(n,o,i,!0),divide:e.divide,dataIndex:o})}),t}function LI(e,t,n){e.traverse(function(e){e instanceof lk&&dz(e,{style:{opacity:0}},t,{dataIndex:n,isFrom:!0})})}function LA(e){if(e.parent){var t=e.getComputedTransform();e.setLocalTransform(t),e.parent.remove(e)}}function LP(e){e.stopAnimation(),e.isGroup&&e.traverse(function(e){e.stopAnimation()})}function LE(e,t,n){var i=LR(e),r=LR(t);function o(e,t,n,i,r){(n||e)&&t.animateFrom({style:n&&n!==e?nf(nf({},n.style),e.style):e.style},r)}var a=!1,s=0,l=n1(),d=n1();i.forEach(function(e){e.groupId&&l.set(e.groupId,!0),e.childGroupId&&d.set(e.childGroupId,!0)});for(var u=0;u<r.length;u++){var c=r[u].groupId;if(d.get(c)){s=1;break}var h=r[u].childGroupId;if(h&&l.get(h)){s=2;break}}function p(e,t){return function(n){var i=n.data,r=n.dataIndex;return t?i.getId(r):e?1===s?n.childGroupId:n.groupId:2===s?n.childGroupId:n.groupId}}var f=function(e,t){var n=e.length;if(n!==t.length)return!1;for(var i=0;i<n;i++){var r=e[i],o=t[i];if(r.data.getId(r.dataIndex)!==o.data.getId(o.dataIndex))return!1}return!0}(i,r),g={};if(!f)for(var u=0;u<r.length;u++){var m=r[u],v=m.data.getItemGraphicEl(m.dataIndex);v&&(g[v.id]=!0)}function y(e,t){var n,s=i[t],l=r[e],d=l.data.hostModel,u=s.data.getItemGraphicEl(s.dataIndex),c=l.data.getItemGraphicEl(l.dataIndex);if(u===c){c&&(n=dO("update",d,l.dataIndex))&&c.traverse(function(e){if(e instanceof sV){var t=dF(e).oldStyle;t&&e.animateFrom({style:t},n)}});return}u&&g[u.id]||c&&(LP(c),u?(LP(u),LA(u),a=!0,Lk(LM(u),LM(c),l.divide,d,e,o)):LI(c,d,e))}new vU(i,r,p(!0,f),p(!1,f),null,"multiple").update(y).updateManyToOne(function(e,t){var n=r[e],s=n.data,l=s.hostModel,d=s.getItemGraphicEl(n.dataIndex),u=n_(nC(t,function(e){return i[e].data.getItemGraphicEl(i[e].dataIndex)}),function(e){return e&&e!==d&&!g[e.id]});d&&(LP(d),u.length?(nw(u,function(e){LP(e),LA(e)}),a=!0,Lk(LM(u),LM(d),n.divide,l,e,o)):LI(d,l,n.dataIndex))}).updateOneToMany(function(e,t){var n=i[t],s=n.data.getItemGraphicEl(n.dataIndex);if(!s||!g[s.id]){var l=n_(nC(e,function(e){return r[e].data.getItemGraphicEl(r[e].dataIndex)}),function(e){return e&&e!==s}),d=r[e[0]].data.hostModel;l.length&&(nw(l,function(e){return LP(e)}),s?(LP(s),LA(s),a=!0,Lk(LM(s),LM(l),n.divide,d,e[0],o)):nw(l,function(t){return LI(t,d,e[0])}))}}).updateManyToMany(function(e,t){new vU(t,e,function(e){return i[e].data.getId(i[e].dataIndex)},function(e){return r[e].data.getId(r[e].dataIndex)}).update(function(n,i){y(e[n],t[i])}).execute()}).execute(),a&&nw(t,function(e){var t=e.data.hostModel,i=t&&n.getViewOfSeriesModel(t),r=dO("update",t,0);i&&t.isAnimationEnabled()&&r&&r.duration>0&&i.group.traverse(function(e){e instanceof lk&&!e.animators.length&&e.animateFrom({style:{opacity:0}
422},r)})})}function LL(e){var t=e.getModel("universalTransition").get("seriesKey");return t||e.id}function LF(e){return nR(e)?e.sort().join(","):e}function LO(e){if(e.hostModel)return e.hostModel.getModel("universalTransition").get("divideShape")}function LN(e,t){for(var n=0;n<e.length;n++)if(null!=t.seriesIndex&&t.seriesIndex===e[n].seriesIndex||null!=t.seriesId&&t.seriesId===e[n].id)return n}var LB=["align","verticalAlign","width","height","fontSize"],Lz=new o8,Lj=a9(),LV=a9();function LH(e,t,n){for(var i=0;i<n.length;i++){var r=n[i];null!=t[r]&&(e[r]=t[r])}}var LG=["x","y","rotation"],LW=function(){function e(){this._labelList=[],this._chartViewList=[]}return e.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},e.prototype._addLabel=function(e,t,n,i,r){var o,a=i.style,s=i.__hostTarget.textConfig||{},l=i.getComputedTransform(),d=i.getBoundingRect().plain();rt.applyTransform(d,d,l),l?Lz.setLocalTransform(l):(Lz.x=Lz.y=Lz.rotation=Lz.originX=Lz.originY=0,Lz.scaleX=Lz.scaleY=1),Lz.rotation=lf(Lz.rotation);var u=i.__hostTarget;if(u){o=u.getBoundingRect().plain();var c=u.getComputedTransform();rt.applyTransform(o,o,c)}var h=o&&u.getTextGuideLine();this._labelList.push({label:i,labelLine:h,seriesModel:n,dataIndex:e,dataType:t,layoutOption:r,computedLayoutOption:null,rect:d,hostRect:o,priority:o?o.width*o.height:0,defaultAttr:{ignore:i.ignore,labelGuideIgnore:h&&h.ignore,x:Lz.x,y:Lz.y,scaleX:Lz.scaleX,scaleY:Lz.scaleY,rotation:Lz.rotation,style:{x:a.x,y:a.y,align:a.align,verticalAlign:a.verticalAlign,width:a.width,height:a.height,fontSize:a.fontSize},cursor:i.cursor,attachedPos:s.position,attachedRot:s.rotation}})},e.prototype.addLabelsOfSeries=function(e){var t=this;this._chartViewList.push(e);var n=e.__model,i=n.get("labelLayout");(nI(i)||nM(i).length)&&e.group.traverse(function(e){if(e.ignore)return!0;var r=e.getTextContent(),o=lQ(e);r&&!r.disableLabelLayout&&t._addLabel(o.dataIndex,o.dataType,n,r,i)})},e.prototype.updateLayoutConfig=function(e){for(var t=e.getWidth(),n=e.getHeight(),i=0;i<this._labelList.length;i++){var r=this._labelList[i],o=r.label,a=o.__hostTarget,s=r.defaultAttr,l=void 0;l=(l=nI(r.layoutOption)?r.layoutOption(function(e,t){var n=e.label,i=t&&t.getTextGuideLine();return{dataIndex:e.dataIndex,dataType:e.dataType,seriesIndex:e.seriesModel.seriesIndex,text:e.label.style.text,rect:e.hostRect,labelRect:e.rect,align:n.style.align,verticalAlign:n.style.verticalAlign,labelLinePoints:function(e){if(e){for(var t=[],n=0;n<e.length;n++)t.push(e[n].slice());return t}}(i&&i.shape.points)}}(r,a)):r.layoutOption)||{},r.computedLayoutOption=l;var d=Math.PI/180;a&&a.setTextConfig({local:!1,position:null!=l.x||null!=l.y?null:s.attachedPos,rotation:null!=l.rotate?l.rotate*d:s.attachedRot,offset:[l.dx||0,l.dy||0]});var u=!1;if(null!=l.x?(o.x=aR(l.x,t),o.setStyle("x",0),u=!0):(o.x=s.x,o.setStyle("x",s.style.x)),null!=l.y?(o.y=aR(l.y,n),o.setStyle("y",0),u=!0):(o.y=s.y,o.setStyle("y",s.style.y)),l.labelLinePoints){var c=a.getTextGuideLine();c&&(c.setShape({points:l.labelLinePoints}),u=!1)}Lj(o).needsUpdateLabelLine=u,o.rotation=null!=l.rotate?l.rotate*d:s.rotation,o.scaleX=s.scaleX,o.scaleY=s.scaleY;for(var h=0;h<LB.length;h++){var p=LB[h];o.setStyle(p,null!=l[p]?l[p]:s.style[p])}if(l.draggable){if(o.draggable=!0,o.cursor="move",a){var f=r.seriesModel;null!=r.dataIndex&&(f=r.seriesModel.getData(r.dataType).getItemModel(r.dataIndex)),o.on("drag",function(e,t){return function(){bF(e,t)}}(a,f.getModel("labelLine")))}}else o.off("drag"),o.cursor=s.cursor}},e.prototype.layout=function(e){var t=e.getWidth(),n=e.getHeight(),i=bG(this._labelList),r=n_(i,function(e){return"shiftX"===e.layoutOption.moveOverlap}),o=n_(i,function(e){return"shiftY"===e.layoutOption.moveOverlap});bW(r,"x","width",0,t,void 0),b$(o,0,n),bU(n_(i,function(e){return e.layoutOption.hideOverlap}))},e.prototype.processLabelsOverall=function(){var e=this;nw(this._chartViewList,function(t){var n=t.__model,i=t.ignoreLabelLineUpdate,r=n.isAnimationEnabled();t.group.traverse(function(t){if(t.ignore&&!t.forceLabelAnimation)return!0;var o=!i,a=t.getTextContent();!o&&a&&(o=Lj(a).needsUpdateLabelLine),o&&e._updateLabelLine(t,n),r&&e._animateLabels(t,n)})})},e.prototype._updateLabelLine=function(e,t){var n=e.getTextContent(),i=lQ(e),r=i.dataIndex;if(n&&null!=r){var o=t.getData(i.dataType),a=o.getItemModel(r),s={},l=o.getItemVisual(r,"style");l&&(s.stroke=l[o.getVisual("drawType")]);var d=a.getModel("labelLine");bV(e,bH(a),s),bF(e,d)}},e.prototype._animateLabels=function(e,t){var n=e.getTextContent(),i=e.getTextGuideLine();if(n&&(e.forceLabelAnimation||!n.ignore&&!n.invisible&&!e.disableLabelAnimation&&!dj(e))){var r=Lj(n),o=r.oldLayout,a=lQ(e),s=a.dataIndex,l={x:n.x,y:n.y,rotation:n.rotation},d=t.getData(a.dataType);if(o){n.attr(o);var u=e.prevStates;u&&(nv(u,"select")>=0&&n.attr(r.oldLayoutSelect),nv(u,"emphasis")>=0&&n.attr(r.oldLayoutEmphasis)),dB(n,l,t,s)}else if(n.attr(l),!d3(n).valueAnimation){var c=nG(n.style.opacity,1);n.style.opacity=0,dz(n,{style:{opacity:c}},t,s)}if(r.oldLayout=l,n.states.select){var h=r.oldLayoutSelect={};LH(h,l,LG),LH(h,n.states.select,LG)}if(n.states.emphasis){var p=r.oldLayoutEmphasis={};LH(p,l,LG),LH(p,n.states.emphasis,LG)}d4(n,s,d,t,t)}if(i&&!i.ignore&&!i.invisible){var r=LV(i),o=r.oldLayout,f={points:i.shape.points};o?(i.attr({shape:o}),dB(i,{shape:f},t)):(i.setShape(f),i.style.strokePercent=0,dz(i,{style:{strokePercent:1}},t)),r.oldLayout=f}},e}(),L$=a9();function LU(e){e.registerUpdateLifecycle("series:beforeupdate",function(e,t,n){var i=L$(t).labelManager;i||(i=L$(t).labelManager=new LW),i.clearLabels()}),e.registerUpdateLifecycle("series:layoutlabels",function(e,t,n){var i=L$(t).labelManager;
422n.updatedSeries.forEach(function(e){i.addLabelsOfSeries(t.getViewOfSeriesModel(e))}),i.updateLayoutConfig(t),i.layout(t),i.processLabelsOverall()})}mq([function(e){e.registerPainter("canvas",vG)}]),mq([function(e){e.registerPainter("svg",vz)}]),mq([function(e){e.registerChartView(yV),e.registerSeriesModel(ys),e.registerLayout(yH("line",!0)),e.registerVisual({seriesType:"line",reset:function(e){var t=e.getData(),n=e.getModel("lineStyle").getLineStyle();n&&!n.stroke&&(n.stroke=t.getVisual("style").fill),t.setVisual("legendLineStyle",n)}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,y$("line"))},function(e){e.registerChartView(bt),e.registerSeriesModel(y3),e.registerLayout(e.PRIORITY.VISUAL.LAYOUT,nD(yJ,"bar")),e.registerLayout(e.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,yQ("bar")),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,y$("bar")),e.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(e,t){var n=e.componentType||"series";t.eachComponent({mainType:n,query:e},function(t){e.sortInfo&&t.axis.setCategorySortInfo(e.sortInfo)})})},function(e){e.registerChartView(bJ),e.registerSeriesModel(b2),gu("pie",e.registerAction),e.registerLayout(nD(bw,"pie")),e.registerProcessor(bS("pie")),e.registerProcessor({seriesType:"pie",reset:function(e,t){var n=e.getData();n.filterSelf(function(e){var t=n.mapDimension("value"),i=n.get(t,e);return!nE(i)||!!isNaN(i)||!(i<0)})}})},function(e){mq(wE),e.registerSeriesModel(b3),e.registerChartView(b8),e.registerLayout(yH("scatter"))},function(e){mq(wq),e.registerChartView(wB),e.registerSeriesModel(wz),e.registerLayout(wL),e.registerProcessor(bS("radar")),e.registerPreprocessor(wO)},function(e){mq(Su),e.registerChartView(C3),e.registerSeriesModel(C5),e.registerLayout(C6),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,C4),gu("map",e.registerAction)},function(e){e.registerChartView(Sx),e.registerSeriesModel(SH),e.registerLayout(SW),e.registerVisual(S$),e.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"tree",query:e},function(t){var n=e.dataIndex,i=t.getData().tree.getNodeByDataIndex(n);i.isExpand=!i.isExpand})}),e.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},function(e,t,n){t.eachComponent({mainType:"series",subType:"tree",query:e},function(t){var i=Ss(t.coordinateSystem,e,void 0,n);t.setCenter&&t.setCenter(i.center),t.setZoom&&t.setZoom(i.zoom)})})},function(e){e.registerSeriesModel(SK),e.registerChartView(S2),e.registerVisual(_a),e.registerLayout(_m);for(var t=0;t<SU.length;t++)e.registerAction({type:SU[t],update:"updateView"},n6);e.registerAction({type:"treemapRootToNode",update:"updateView"},function(e,t){t.eachComponent({mainType:"series",subType:"treemap",query:e},function(t,n){var i=SB(e,["treemapZoomToNode","treemapRootToNode"],t);if(i){var r=t.getViewRoot();r&&(e.direction=Sj(r,i.node)?"rollUp":"drillDown"),t.resetViewRoot(i.node)}})})},function(e){e.registerChartView(kt),e.registerSeriesModel(kl),e.registerProcessor(_b),e.registerVisual(_x),e.registerVisual(_C),e.registerLayout(_P),e.registerLayout(e.PRIORITY.VISUAL.POST_CHART_LAYOUT,_j),e.registerLayout(_V),e.registerCoordinateSystem("graphView",{dimensions:C8.dimensions,create:_H}),e.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},n6),e.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},n6),e.registerAction(kd,function(e,t,n){t.eachComponent({mainType:"series",query:e},function(t){var i=Ss(t.coordinateSystem,e,void 0,n);t.setCenter&&t.setCenter(i.center),t.setZoom&&t.setZoom(i.zoom)})})},function(e){e.registerChartView(kp),e.registerSeriesModel(kf)},function(e){e.registerChartView(kv),e.registerSeriesModel(ky),e.registerLayout(kb),e.registerProcessor(bS("funnel"))},function(e){mq(MI),e.registerChartView(kx),e.registerSeriesModel(kk),e.registerVisual(e.PRIORITY.VISUAL.BRUSH,kD)},function(e){e.registerChartView(ME),e.registerSeriesModel(MF),e.registerLayout(MO),e.registerVisual(MU),e.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"sankey",query:e},function(t){t.setNodePosition(e.dataIndex,[e.localX,e.localY])})})},function(e){e.registerSeriesModel(MK),e.registerChartView(MY),e.registerLayout(M0),e.registerTransform(M1)},function(e){e.registerChartView(Tt),e.registerSeriesModel(Tc),e.registerPreprocessor(Th),e.registerVisual(M9),e.registerLayout(Tp)},function(e){e.registerChartView(Tv),e.registerSeriesModel(Ty),e.registerLayout(yH("effectScatter"))},function(e){e.registerChartView(TM),e.registerSeriesModel(TI),e.registerLayout(Tk),e.registerVisual(TP)},function(e){e.registerChartView(TF),e.registerSeriesModel(TO)},function(e){e.registerChartView(Tj),e.registerSeriesModel(T5),e.registerLayout(e.PRIORITY.VISUAL.LAYOUT,nD(yJ,"pictorialBar")),e.registerLayout(e.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,yQ("pictorialBar"))},function(e){e.registerChartView(T4),e.registerSeriesModel(T6),e.registerLayout(T8),e.registerProcessor(bS("themeRiver"))},function(e){e.registerChartView(Dn),e.registerSeriesModel(Di),e.registerLayout(nD(Do,"sunburst")),e.registerProcessor(nD(bS,"sunburst")),e.registerVisual(Da),e.registerAction({type:De,update:"updateView"},function(e,t){t.eachComponent({mainType:"series",subType:"sunburst",query:e},function(t,n){var i=SB(e,[De],t);if(i){var r=t.getViewRoot();r&&(e.direction=Sj(r,i.node)?"rollUp":"drillDown"),t.resetViewRoot(i.node)}})}),e.registerAction({type:Dt,update:"none"},function(e,t,n){e=nf({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},function(t){var n=SB(e,[Dt],t);n&&(e.dataIndex=n.node.dataIndex)}),n.dispatchAction(nf(e,{type:"highlight"}))}),e.registerAction({type:"sunburstUnhighlight",update:"updateView"},function(e,t,n){e=nf({},e),n.dispatchAction(nf(e,{type:"downplay"}))})},function(e){e.registerChartView(DZ),e.registerSeriesModel(Du)}]),mq(function(e){mq(wE),mq(RL)}),mq(function(e){mq(RL),ww.registerAxisPointerClass("PolarAxisPointer",RF),e.registerCoordinateSystem("polar",RY),e.registerComponentModel(
422RN),e.registerComponentView(It),xc(e,"angle",Rz,R9),xc(e,"radius",Rj,Ie),e.registerComponentView(R0),e.registerComponentView(R5),e.registerLayout(nD(R7,"bar"))}),mq(Su),mq(function(e){mq(RL),ww.registerAxisPointerClass("SingleAxisPointer",Ig),e.registerComponentView(Ib),e.registerComponentView(Io),e.registerComponentModel(Is),xc(e,"single",Is,Is.defaultOption),e.registerCoordinateSystem("single",Ih)}),mq(MI),mq(function(e){e.registerComponentModel(Ix),e.registerComponentView(IC),e.registerCoordinateSystem("calendar",IS)}),mq(function(e){e.registerComponentModel(IR),e.registerComponentView(IP),e.registerPreprocessor(function(e){var t=e.graphic;nR(t)?t[0]&&t[0].elements?e.graphic=[e.graphic[0]]:e.graphic=[{elements:t}]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}),mq(function(e){e.registerComponentModel(I0),e.registerComponentView(I2),IQ.saveAsImage=I3,IQ.magicType=I6,IQ.dataView=At,IQ.dataZoom=Ay,IQ.restore=Ar,mq(IX)}),mq(function(e){mq(RL),e.registerComponentModel(Aw),e.registerComponentView(AN),e.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},n6),e.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},n6)}),mq(RL),mq(function(e){e.registerComponentView(A5),e.registerComponentModel(A4),e.registerPreprocessor(AH),e.registerVisual(e.PRIORITY.VISUAL.BRUSH,AQ),e.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(t){t.setAreas(e.areas)})}),e.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},n6),e.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},n6),IQ.brush=A7}),mq(function(e){e.registerComponentModel(A9),e.registerComponentView(Pe)}),mq(function(e){e.registerComponentModel(Pn),e.registerComponentView(Ps),e.registerSubTypeDefaulter("timeline",function(){return"slider"}),e.registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(e,t,n){var i=t.getComponent("timeline");return i&&null!=e.currentIndex&&(i.setCurrentIndex(e.currentIndex),!i.get("loop",!0)&&i.isIndexMax()&&i.getPlayState()&&(i.setPlayState(!1),n.dispatchAction({type:"timelinePlayChange",playState:!1,from:e.from}))),t.resetOption("timeline",{replaceMerge:i.get("replaceMerge",!0)}),ng({currentIndex:i.option.currentIndex},e)}),e.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(e,t){var n=t.getComponent("timeline");n&&null!=e.playState&&n.setPlayState(e.playState)}),e.registerPreprocessor(Pu)}),mq(function(e){e.registerComponentModel(Pv),e.registerComponentView(PR),e.registerPreprocessor(function(e){Pp(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}),mq(function(e){e.registerComponentModel(PI),e.registerComponentView(PN),e.registerPreprocessor(function(e){Pp(e.series,"markLine")&&(e.markLine=e.markLine||{})})}),mq(function(e){e.registerComponentModel(PB),e.registerComponentView(PU),e.registerPreprocessor(function(e){Pp(e.series,"markArea")&&(e.markArea=e.markArea||{})})}),mq(function(e){mq(P2),mq(P7)}),mq(function(e){mq(El),mq(Em)}),mq(El),mq(Em),mq(function(e){mq(EH),mq(Eq)}),mq(EH),mq(Eq),mq(function(e){e.registerPreprocessor(EJ),e.registerVisual(e.PRIORITY.VISUAL.ARIA,EX)}),mq(function(e){e.registerTransform(Lt),e.registerTransform(Ln)}),mq(function(e){e.registerComponentModel(EQ),e.registerComponentView(E0)}),mq(function(e){e.registerUpdateLifecycle("series:beforeupdate",function(e,t,n){nw(aJ(n.seriesTransition),function(e){nw(aJ(e.to),function(e){for(var t=n.updatedSeries,i=0;i<t.length;i++)(null!=e.seriesIndex&&e.seriesIndex===t[i].seriesIndex||null!=e.seriesId&&e.seriesId===t[i].id)&&(t[i][h0]=!0)})})}),e.registerUpdateLifecycle("series:transition",function(e,t,n){var i=LT(t);if(i.oldSeries&&n.updatedSeries&&n.optionChanged){var r=n.seriesTransition;if(r)nw(aJ(r),function(e){var r,o;r=[],o=[],nw(aJ(e.from),function(e){var t=LN(i.oldSeries,e);t>=0&&r.push({dataGroupId:i.oldDataGroupIds[t],data:i.oldData[t],divide:LO(i.oldData[t]),groupIdDim:e.dimension})}),nw(aJ(e.to),function(e){var t=LN(n.updatedSeries,e);if(t>=0){var r=n.updatedSeries[t].getData();o.push({dataGroupId:i.oldDataGroupIds[t],data:r,divide:LO(r),groupIdDim:e.dimension})}}),r.length>0&&o.length>0&&LE(r,o,t)});else{var o,a,s,l=(o=n1(),a=n1(),s=n1(),nw(i.oldSeries,function(e,t){var n=i.oldDataGroupIds[t],r=i.oldData[t],o=LL(e),l=LF(o);a.set(l,{dataGroupId:n,data:r}),nR(o)&&nw(o,function(e){s.set(e,{key:l,dataGroupId:n,data:r})})}),nw(n.updatedSeries,function(e){if(e.isUniversalTransitionEnabled()&&e.isAnimationEnabled()){var t=e.get("dataGroupId"),n=e.getData(),i=LL(e),r=LF(i),l=a.get(r);if(l)o.set(r,{oldSeries:[{dataGroupId:l.dataGroupId,divide:LO(l.data),data:l.data}],newSeries:[{dataGroupId:t,divide:LO(n),data:n}]});else if(nR(i)){var d=[];
422nw(i,function(e){var t=a.get(e);t.data&&d.push({dataGroupId:t.dataGroupId,divide:LO(t.data),data:t.data})}),d.length&&o.set(r,{oldSeries:d,newSeries:[{dataGroupId:t,data:n,divide:LO(n)}]})}else{var u=s.get(i);if(u){var c=o.get(u.key);c||(c={oldSeries:[{dataGroupId:u.dataGroupId,data:u.data,divide:LO(u.data)}],newSeries:[]},o.set(u.key,c)),c.newSeries.push({dataGroupId:t,data:n,divide:LO(n)})}}}}),o);nw(l.keys(),function(e){var n=l.get(e);LE(n.oldSeries,n.newSeries,t)})}nw(n.updatedSeries,function(e){e[h0]&&(e[h0]=!1)})}for(var d=e.getSeries(),u=i.oldSeries=[],c=i.oldDataGroupIds=[],h=i.oldData=[],p=0;p<d.length;p++){var f=d[p].getData();1e4>f.count()&&(u.push(d[p]),c.push(d[p].get("dataGroupId")),h.push(f))}})}),mq(LU),e.s([],17208),e.i(17208),mq(LU),e.s([],25791),e.i(25791),e.i(49613),e.s(["PRIORITY",()=>g3,"connect",()=>mw,"dataTool",()=>mW,"dependencies",()=>g2,"disConnect",()=>mC,"disconnect",()=>mC,"dispose",()=>mS,"getCoordinateSystemDimensions",()=>mL,"getInstanceByDom",()=>m_,"getInstanceById",()=>mk,"getMap",()=>mH,"init",()=>mx,"registerAction",()=>mP,"registerCoordinateSystem",()=>mE,"registerLayout",()=>mF,"registerLoading",()=>mz,"registerLocale",()=>up,"registerMap",()=>mV,"registerPostInit",()=>mR,"registerPostUpdate",()=>mI,"registerPreprocessor",()=>mT,"registerProcessor",()=>mD,"registerTheme",()=>mM,"registerTransform",()=>mG,"registerUpdateLifecycle",()=>mA,"registerVisual",()=>mO,"setCanvasCreator",()=>mj,"version",()=>g1],41467),e.i(41467);var Lq=e.i(65119),LK=e.i(43727),LY=e.i(45330),LZ=e.i(27928),LX=e.i(40224);function LJ(e){return ya(null,e)}var LQ={isDimensionStacked:yr,enableDataStack:yi,getStackedDimension:yo};function L0(e,t){var n=t;t instanceof ua||(n=new ua(t));var i=xV(n);return i.setExtent(e[0],e[1]),xj(i,n),i}function L1(e){nb(e,b9)}function L2(e,t){return dZ(e,null,null,"normal"!==(t=t||{}).state)}e.s(["createList",()=>LJ,"createScale",()=>L0,"createTextStyle",()=>L2,"dataStack",()=>LQ,"mixinAxisModelCommonMethods",()=>L1],66442),e.i(66442),e.s(["createDimensions",()=>v7,"createList",()=>LJ,"createScale",()=>L0,"createSymbol",()=>g_,"createTextStyle",()=>L2,"dataStack",()=>LQ,"enableHoverEmphasis",()=>dk,"getECData",()=>lQ,"getLayoutRect",()=>uX,"mixinAxisModelCommonMethods",()=>L1],11213);var L3=e.i(11213);e.s([],28819),e.i(28819),e.s(["MAX_SAFE_INTEGER",()=>0x1fffffffffffff,"asc",()=>aA,"getPercentWithPrecision",()=>aF,"getPixelPrecision",()=>aL,"getPrecision",()=>aP,"getPrecisionSafe",()=>aE,"isNumeric",()=>aq,"isRadianAroundZero",()=>aB,"linearMap",()=>aD,"nice",()=>aG,"numericToNumber",()=>aU,"parseDate",()=>aj,"quantile",()=>aW,"quantity",()=>aV,"quantityExponent",()=>aH,"reformIntervals",()=>a$,"remRadian",()=>aN,"round",()=>aI],75118);var L5=e.i(75118);e.s([],59670),e.i(59670),e.s(["format",()=>uw,"parse",()=>aj],23247);var L4=e.i(23247);e.s([],41456),e.i(41456),e.s(["Arc",0,pJ,"BezierCurve",0,pZ,"BoundingRect",0,rt,"Circle",0,pw,"CompoundPath",0,pQ,"Ellipse",0,pS,"Group",0,av,"Image",0,lI,"IncrementalDisplayable",0,p9,"Line",0,pU,"LinearGradient",0,p1,"Polygon",0,pV,"Polyline",0,pG,"RadialGradient",0,p2,"Rect",0,lN,"Ring",0,pB,"Sector",0,pO,"Text",0,lj,"clipPointsByRect",()=>fx,"clipRectByRect",()=>fw,"createIcon",()=>fC,"extendPath",()=>fo,"extendShape",()=>fi,"getShapeClass",()=>fs,"getTransform",()=>fm,"initProps",()=>dz,"makeImage",()=>fd,"makePath",()=>fl,"mergePath",()=>fc,"registerShape",()=>fa,"resizePath",()=>fh,"updateProps",()=>dB],35483);var L6=e.i(35483);function L8(e,t,n,i,r,o,a,s){return new lj({style:{text:e,font:t,align:n,verticalAlign:i,padding:r,rich:o,overflow:a?"truncate":null,lineHeight:s}}).getBoundingRect()}e.s([],4452),e.i(4452),e.s(["addCommas",()=>uN,"capitalFirst",()=>u$,"encodeHTML",()=>iE,"formatTime",()=>uW,"formatTpl",()=>uH,"getTextRect",()=>L8,"getTooltipMarker",()=>uG,"normalizeCssArray",()=>nU,"toCamelCase",()=>uB,"truncateText",()=>sM],80538);var L7=e.i(80538);e.s([],39296),e.i(39296),e.s(["bind",()=>nT,"clone",()=>nc,"curry",()=>nD,"defaults",()=>ng,"each",()=>nw,"extend",()=>nf,"filter",()=>n_,"indexOf",()=>nv,"inherits",()=>ny,"isArray",()=>nR,"isFunction",()=>nI,"isObject",()=>nL,"isString",()=>nA,"map",()=>nC,"merge",()=>nh,"reduce",()=>nS],75358);var L9=e.i(75358);function Fe(e){var t=u5.extend(e);return u5.registerClass(t),t}function Ft(e){var t=h9.extend(e);return h9.registerClass(t),t}function Fn(e){var t=h1.extend(e);return h1.registerClass(t),t}function Fi(e){var t=fI.extend(e);return fI.registerClass(t),t}e.s(["extendChartView",()=>Fi,"extendComponentModel",()=>Fe,"extendComponentView",()=>Ft,"extendSeriesModel",()=>Fn],48465),e.i(48465),e.s(["Axis",0,x6,"ChartView",0,fI,"ComponentModel",0,u5,"ComponentView",0,h9,"List",0,v8,"Model",0,ua,"SeriesModel",0,h1,"color",0,LX,"env",0,t1,"extendChartView",()=>Fi,"extendComponentModel",()=>Fe,"extendComponentView",()=>Ft,"extendSeriesModel",()=>Fn,"format",0,L7,"graphic",0,L6,"helper",0,L3,"innerDrawElementOnCanvas",()=>gU,"matrix",0,LK,"number",0,L5,"parseGeoJSON",()=>CR,"parseGeoJson",()=>CR,"setPlatformAPI",()=>t6,"throttle",()=>fz,"time",0,L4,"use",()=>mq,"util",0,L9,"vector",0,LY,"zrUtil",0,LZ,"zrender",0,Lq],40488),e.i(40488),e.s(["Axis",0,x6,"ChartView",0,fI,"ComponentModel",0,u5,"ComponentView",0,h9,"List",0,v8,"Model",0,ua,"PRIORITY",()=>g3,"SeriesModel",0,h1,"color",()=>LX,"connect",()=>mw,"dataTool",()=>mW,"dependencies",()=>g2,"disConnect",()=>mC,"disconnect",()=>mC,"dispose",()=>mS,"env",0,t1,"extendChartView",()=>Fi,"extendComponentModel",()=>Fe,"extendComponentView",()=>Ft,"extendSeriesModel",()=>Fn,"format",()=>L7,"getCoordinateSystemDimensions",()=>mL,"getInstanceByDom",()=>m_,"getInstanceById",()=>mk,"getMap",()=>mH,"graphic",()=>L6,"helper",()=>L3,"init",()=>mx,"innerDrawElementOnCanvas",()=>gU,"matrix",()=>LK,"number",()=>L5,"parseGeoJSON",()=>CR,"parseGeoJson",()=>CR,"registerAction",()=>mP,"registerCoordinateSystem",()=>mE,"registerLayout",()=>mF,"registerLoading",()=>mz,"registerLocale",()=>up,"registerMap",()=>mV,"registerPostInit",()=>mR,"registerPostUpdate",()=>mI,"registerPreprocessor",()=>mT,"registerProcessor",()=>mD,"registerTheme",()=>mM,"registerTransform",()=>mG,"registerUpdateLifecycle",()=>mA,"registerVisual",()=>mO,"setCanvasCreator",()=>mj,"setPlatformAPI",()=>t6,"throttle",()=>fz,"time",()=>L4,"use",()=>mq,"util",()=>L9,"vector",()=>
422LY,"version",()=>g1,"zrUtil",()=>LZ,"zrender",()=>Lq],32505),e.i(32505),e.s(["Axis",0,x6,"ChartView",0,fI,"ComponentModel",0,u5,"ComponentView",0,h9,"List",0,v8,"Model",0,ua,"PRIORITY",()=>g3,"SeriesModel",0,h1,"color",()=>LX,"connect",()=>mw,"dataTool",()=>mW,"dependencies",()=>g2,"disConnect",()=>mC,"disconnect",()=>mC,"dispose",()=>mS,"env",0,t1,"extendChartView",()=>Fi,"extendComponentModel",()=>Fe,"extendComponentView",()=>Ft,"extendSeriesModel",()=>Fn,"format",()=>L7,"getCoordinateSystemDimensions",()=>mL,"getInstanceByDom",()=>m_,"getInstanceById",()=>mk,"getMap",()=>mH,"graphic",()=>L6,"helper",()=>L3,"init",()=>mx,"innerDrawElementOnCanvas",()=>gU,"matrix",()=>LK,"number",()=>L5,"parseGeoJSON",()=>CR,"parseGeoJson",()=>CR,"registerAction",()=>mP,"registerCoordinateSystem",()=>mE,"registerLayout",()=>mF,"registerLoading",()=>mz,"registerLocale",()=>up,"registerMap",()=>mV,"registerPostInit",()=>mR,"registerPostUpdate",()=>mI,"registerPreprocessor",()=>mT,"registerProcessor",()=>mD,"registerTheme",()=>mM,"registerTransform",()=>mG,"registerUpdateLifecycle",()=>mA,"registerVisual",()=>mO,"setCanvasCreator",()=>mj,"setPlatformAPI",()=>t6,"throttle",()=>fz,"time",()=>L4,"use",()=>mq,"util",()=>L9,"vector",()=>LY,"version",()=>g1,"zrUtil",()=>LZ,"zrender",()=>Lq],68762);var Fr=e.i(68762),Fo=e.i(11381);function Fa(e,t){var n={};return t.forEach(function(t){n[t]=e[t]}),n}function Fs(e){return"function"==typeof e}var Fl=e.i(44700),Fd=function(e){function t(t){var n=e.call(this,t)||this;return n.echarts=Fr,n}return(0,tQ.__extends)(t,e),t}(function(e){function t(t){var n=e.call(this,t)||this;return n.echarts=t.echarts,n.ele=null,n.isInitialResize=!0,n.eventHandlerRefs={},n}return(0,tQ.__extends)(t,e),t.prototype.componentDidMount=function(){this.renderNewEcharts()},t.prototype.componentDidUpdate=function(e){var t=this.props.shouldSetOption;if(!Fs(t)||t(e,this.props)){if(!(0,Fl.default)(e.theme,this.props.theme)||!(0,Fl.default)(e.opts,this.props.opts)){this.dispose(),this.renderNewEcharts();return}var n=this.getEchartsInstance();(0,Fl.default)(e.onEvents,this.props.onEvents)||(this.unbindEvents(n),this.bindEvents(n,this.props.onEvents));var i=["option","notMerge","replaceMerge","lazyUpdate","showLoading","loadingOption"];(0,Fl.default)(Fa(this.props,i),Fa(e,i))||this.updateEChartsOption(),(0,Fl.default)(e.style,this.props.style)&&(0,Fl.default)(e.className,this.props.className)||this.resize()}},t.prototype.componentWillUnmount=function(){this.dispose()},t.prototype.initEchartsInstance=function(){return(0,tQ.__awaiter)(this,void 0,void 0,function(){var e=this;return(0,tQ.__generator)(this,function(t){return[2,new Promise(function(t){e.echarts.init(e.ele,e.props.theme,e.props.opts),e.getEchartsInstance().on("finished",function(){var n=e.ele.clientWidth,i=e.ele.clientHeight;e.echarts.dispose(e.ele);var r=(0,tQ.__assign)({width:n,height:i},e.props.opts);t(e.echarts.init(e.ele,e.props.theme,r))})})]})})},t.prototype.getEchartsInstance=function(){return this.echarts.getInstanceByDom(this.ele)},t.prototype.dispose=function(){if(this.ele){try{(0,Fo.clear)(this.ele)}catch(e){console.warn(e)}this.echarts.dispose(this.ele)}},t.prototype.renderNewEcharts=function(){return(0,tQ.__awaiter)(this,void 0,void 0,function(){var e,t,n,i,r,o,a=this;return(0,tQ.__generator)(this,function(s){switch(s.label){case 0:return t=(e=this.props).onEvents,n=e.onChartReady,r=void 0===(i=e.autoResize)||i,[4,this.initEchartsInstance()];case 1:return s.sent(),o=this.updateEChartsOption(),this.bindEvents(o,t||{}),Fs(n)&&n(o),this.ele&&r&&(0,Fo.bind)(this.ele,function(){a.resize()}),[2]}})})},t.prototype.bindEvents=function(e,t){var n=this,i=function(t,i){if("string"==typeof t&&Fs(i)){var r=function(t){i(t,e)};e.on(t,r),n.eventHandlerRefs[t]=r}};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&i(r,t[r])},t.prototype.unbindEvents=function(e){for(var t=0,n=Object.entries(this.eventHandlerRefs);t<n.length;t++){var i=n[t],r=i[0],o=i[1];e.off(r,o)}this.eventHandlerRefs={}},t.prototype.updateEChartsOption=function(){var e=this.props,t=e.option,n=e.notMerge,i=e.replaceMerge,r=e.lazyUpdate,o=e.showLoading,a=e.loadingOption,s=this.getEchartsInstance();return s.setOption(t,{notMerge:void 0!==n&&n,replaceMerge:void 0===i?null:i,lazyUpdate:void 0!==r&&r}),o?s.showLoading(void 0===a?null:a):s.hideLoading(),s},t.prototype.resize=function(){var e=this.getEchartsInstance();if(!this.isInitialResize)try{e.resize({width:"auto",height:"auto"})}catch(e){console.warn(e)}this.isInitialResize=!1},t.prototype.render=function(){var e=this,t=this.props,n=t.style,i=t.className,r=(t.echarts,t.option,t.theme,t.notMerge,t.replaceMerge,t.lazyUpdate,t.showLoading,t.loadingOption,t.opts,t.onChartReady,t.onEvents,t.shouldSetOption,t.autoResize,(0,tQ.__rest)(t,["style","className","echarts","option","theme","notMerge","replaceMerge","lazyUpdate","showLoading","loadingOption","opts","onChartReady","onEvents","shouldSetOption","autoResize"])),o=(0,tQ.__assign)({height:300},n);return eC.default.createElement("div",(0,tQ.__assign)({ref:function(t){e.ele=t},style:o,className:"echarts-for-react ".concat(void 0===i?"":i)},r))},t}
422(eC.PureComponent)),Fu=e.i(76603),Fc=e.i(95567),Fh=e.i(10971),Fp=e.i(86957),Ff=e.i(20949),Fg=e.i(86577),Fm=e.i(55357);let Fv=e=>e.mediaBlockBackgroundColor||e.echartsBlockBackgroundColor||e.tableBlockBackgroundColor||e.archiveBlockBackgroundColor||e.imgAndTextBackgroundColor||e.bgColor||e.carouselBackgroundColor||e.videoBlockBackgroundColor||e.columnBlockBackgroundColor||e.collapsibleBackgroundColor||e.formBlockBackgroundColor||e.richTextBlockBackgroundColor||e.gridBackgroundColor||e.cardBackgroundColor||e.optionsBlockBackgroundColor||e.tocBlockBackgroundColor||"",Fy={archive:en.ArchiveBlock,card:tX.Card,carousel:ei.CarouselBlock,collapsible:er.CollapsibleBlock,columnBlock:e=>{let{tenant:t}=(0,eb.useTenant)(),{columns:n,columnsGap:i,stretchColumns:r,columnsAlign:o}=e,a=(0,ey.useMediaQuery)("(max-width: 768px)"),s=(0,eg.getColorClasses)(ef.default,"block"),l=(0,eg.getColorClasses)(ef.default,"column");if(n){let d=i?"none"==i?0:i:"md",u=0===d,c=u?(0,ex.getRadius)(t.Theme?.borderRadius):0,h=n.map((e,n)=>{let i=[ef.default.column,ef.default[`column--${e.sizeColumns}`],e.columnBackgroundColor&&l[e.columnBackgroundColor]].filter(Boolean).join(" ");return(0,ep.jsx)(ev.Paper,{radius:t.Theme?.borderRadius||"md",bg:e.columnBackgroundColor?void 0:"transparent",className:i,children:e.layoutColumns?.map((e,t)=>{let{blockType:n}=e,i=Fv(e),o=i&&s[i]?[s[i],ef.default.block,ef.default["block--with-background"],r?ef.default["block--stretch"]:""].filter(Boolean).join(" ").trim():[ef.default.block,r?ef.default["block--stretch"]:""].filter(Boolean).join(" ").trim();if(n&&n in Fy){let r=Fy[n];if(r){let a=n.replace(/Block$/,"").replace(/([A-Z])/g,"-$1").toLowerCase().replace(/^-/,"");return(0,ep.jsx)(ew.VerticalPadding,{className:o,children:(0,ep.jsx)("div",{"data-block":a,...e.blockDataId?{"data-block-id":e.blockDataId}:{},children:(0,ep.jsx)(r,{...u?{padding:"xl",withRadius:!1}:{withRadius:!0},...i?{bgColor:i}:{},...e})})},t)}}return null})},n)});return(0,ep.jsx)(em.Flex,{"data-block":"column",...e.blockDataId?{"data-block-id":e.blockDataId}:{},direction:a?"column":"row",gap:d,justify:o||"flex-start",className:[ef.default.container,ef.default[`container--${c}`]].filter(Boolean).join(" "),children:h})}return(0,ep.jsx)(ep.Fragment,{})},directoryBlock:({heading:e,filterBackgroundColor:t})=>{let n,{tenant:i}=(0,eb.useTenant)(),{t:r}=(0,tm.useTranslations)(),o=(0,tg.useContrastingTextColor)("primary"),a=t||"",s=(0,eg.getColorClasses)(tA.default,"filters"),l=(0,eg.getColorClasses)(tA.default,"statsBar"),d=(0,eg.getColorClasses)(tA.default,"filterSectionControl"),u=(0,tg.getContrastingTextColorFromTheme)(a,i)||"var(--c-white)",c=(0,ex.getRadius)(i?.Theme?.borderRadius),h=void 0===c?void 0:0===c?"0":`var(--mantine-radius-${c})`,[p,f]=(0,eC.useState)({docs:[],page:1,totalPages:1,totalDocs:0}),[g,m]=(0,eC.useState)(null),[v,y]=(0,eC.useState)([]),[b,x]=(0,eC.useState)([]),[w,C]=(0,eC.useState)([]),[S,_]=(0,eC.useState)(!0),[k,M]=(0,eC.useState)(1),[T,D]=(0,t$.useLocalStorage)({key:"viewMode",defaultValue:"grid"}),[R,I]=(0,eC.useState)(null),[A,P]=(0,eC.useState)(!1);(0,eC.useEffect)(()=>{if(A)return document.body.style.overflow="hidden",()=>{document.body.style.overflow=""}},[A]);let E=[tA.default.filters,s[a],A?"":tA.default.filtersCollapsed].filter(Boolean).join(" "),[L,F]=(0,t$.useLocalStorage)({key:"type",defaultValue:""}),[O,N]=(0,eC.useState)(""),[B,z]=(0,eC.useState)(""),[j,V]=(0,eC.useState)([]),[H,G]=(0,eC.useState)([]),[W,$]=(0,eC.useState)([]),[U,q]=(0,eC.useState)([]),[K,Y]=(0,eC.useState)([]),[Z,X]=(0,eC.useState)([]),[J,Q]=(0,eC.useState)([]),[ee,et]=(0,eC.useState)([]),[en,ei]=(0,eC.useState)(""),[er,eo]=(0,eC.useState)(""),[ea,es]=(0,eC.useState)(""),[el,ed]=(0,eC.useState)("OR"),[eu,ec]=(0,eC.useState)(null),[eh,ef]=(0,t$.useLocalStorage)({key:"sort",defaultValue:"wachttijd"}),em=(0,eC.useRef)(0),ey=(0,eC.useRef)(null),ew=e=>t=>{e(t),M(1)},eS=""===L||"ggzOrganisation"===L,e_=""===B||B>=18,ek=!!O||""!==B||j.length>0||H.length>0||W.length>0||U.length>0||K.length>0||Z.length>0||J.length>0||ee.length>0||!!en||!!er||!!ea||null!==eu,eM=""!==B||j.length>0,eT=!!er||U.length>0||K.length>0||W.length>0||H.length>0||!!ea||Z.length>0,eD=!!O||!!en||ee.length>0||null!==eu,eR=ew(N),eI=ew(z),eA=ew(V),eP=ew(G),eE=ew($),eL=ew(q),eF=ew(Y),eO=ew(X);ew(Q);
422let eN=ew(et),eB=ew(ei),ez=ew(eo),ej=ew(es),eV=ew(ed),eH=ew(ec),eG=ew(ef);(0,eC.useEffect)(()=>{e_||V([])},[e_]),(0,eC.useEffect)(()=>{(async()=>{try{let e=await (0,tp.fetchWithRetry)(`${(0,th.getGraphqlApiUrl)()}/api/graphql`,{method:"POST",headers:{...await (0,th.getTenantHeaders)(),"Content-Type":"application/json"},body:JSON.stringify({query:ty,variables:{limit:200}})}),t=await e.json();if(t.errors)throw Error(t.errors[0]?.message??"GraphQL error");y(t.data?.Insurers?.docs??[])}catch(e){console.warn("Unable to load insurers",e)}})()},[]),(0,eC.useEffect)(()=>{(async()=>{try{let e=await (0,tp.fetchWithRetry)(`${(0,th.getGraphqlApiUrl)()}/api/graphql`,{method:"POST",headers:{...await (0,th.getTenantHeaders)(),"Content-Type":"application/json"},body:JSON.stringify({query:tv.DIRECTORY_TEXT_OPTIONS_QUERY,variables:{where:{type:{equals:"ggzOrganisation"}},limit:5e3}})}),t=await e.json();if(t.errors)throw Error(t.errors[0]?.message??"GraphQL error");let n=t.data?.Directories?.docs??[];x(tq(n.map(e=>e.ggzAanbod?.expertise))),C(tq(n.map(e=>e.ggzAanbod?.primaireBehandelkader)))}catch(e){console.warn("Unable to load expertise/doelgroep options",e)}})()},[]);let eW=i?.directoryEnabledTypes,e$=[{label:r("directoryTypeAll"),value:""},{label:r("directoryTypeBehandeling"),value:"ggzOrganisation"},{label:r("directoryTypeBegeleiding"),value:"begeleiding"},{label:r("directoryTypeZelfhulp"),value:"zelfhulp"}],eU=eW&&0!==eW.length?e$.filter(e=>""===e.value?eW.length>1:eW.includes(e.value)):e$;(0,eC.useEffect)(()=>{let e=++em.current;_(!0);let t=null;L?t={type:{equals:L}}:eW&&eW.length>0&&(t={type:{in:eW}});let n=[];t&&n.push(t),O&&n.push({name:{contains:O}});let r=e_&&j.length>0;if(r&&n.push({verzekeringen__insurerStatuses__insurer:{in:j}}),H.length&&n.push(tK("ggzAanbod__expertise",H,"OR")),W.length&&n.push(tK("ggzAanbod__primaireBehandelkader",W,"OR")),U.length&&n.push({ggzAanbod__typeZorg:{in:U}}),""!==B&&n.push({AND:[{ggzAanbod__doelgroepLeeftijdMin:{exists:!0}},{ggzAanbod__doelgroepLeeftijdMin:{less_than_equal:B}},{OR:[{ggzAanbod__doelgroepLeeftijdMax:{exists:!1}},{ggzAanbod__doelgroepLeeftijdMax:{greater_than_equal:B}}]}]}),K.length&&n.push({ggzAanbod__zorgsetting:{in:K}}),Z.length&&n.push({ggzAanbod__zorgvorm:{in:Z}}),J.length&&n.push({ggzAanbod__diagnostiek:{in:J}}),ee.length&&n.push({ggzProfiel__extraTaal:{in:ee}}),en&&n.push({OR:[{ggzWachttijd__wachttijdBggzStatus:{equals:en}},{ggzWachttijd__wachttijdSggzStatus:{equals:en}}]}),eu){let e=eu.toISOString();n.push({OR:[{ggzWachttijd__lastCheckedAt:{greater_than_equal:e}},{ggzAanbod__lastCheckedAt:{greater_than_equal:e}},{verzekeringen__lastCheckedAt:{greater_than_equal:e}}]})}let o=tU(er);o.length&&n.push(tK("ggzAanbod__klachtenDiagnoses",o,"AND"));let a=tU(ea);a.length&&n.push(tK("ggzAanbod__behandelmethode",a,el));let s=n.length>0?{AND:n}:void 0,l=t??void 0,d="wachttijd"===eh,u=d||r,c=async()=>{try{let t=await (0,tp.fetchWithRetry)(`${(0,th.getGraphqlApiUrl)()}/api/graphql`,{method:"POST",headers:{...await (0,th.getTenantHeaders)(),"Content-Type":"application/json"},body:JSON.stringify({query:tv.DIRECTORY_STATS,variables:{whereTotaal:l}})}),n=await t.json();if(n.errors)throw Error(n.errors[0]?.message??"GraphQL error");if(e!==em.current)return;m({totaal:n.data?.totaal?.totalDocs??0})}catch(e){console.warn("Unable to load directory stats",e)}};(async()=>{try{let t=await (0,tp.fetchWithRetry)(`${(0,th.getGraphqlApiUrl)()}/api/graphql`,{method:"POST",headers:{...await (0,th.getTenantHeaders)(),"Content-Type":"application/json"},body:JSON.stringify({query:tv.DIRECTORY_ARCHIVE,variables:{where:s,limit:u?5e3:20,page:u?1:k,sort:d?void 0:eh,locale:(0,tf.getLang)()??i.defaultLanguage,fallbackLocale:i.defaultLanguage}})}),n=await t.json();if(n.errors)throw Error(n.errors[0]?.message??"GraphQL error");if(e!==em.current)return;let o=n.data?.Directories;if(o?.docs){let e=o.docs;if(r){let t=new Set(j);e=e.filter(e=>e.verzekeringen?.insurerStatuses?.some(e=>"ja"===e.status&&e.insurer?.id&&t.has(e.insurer.id)))}if(d&&(e=[...e].sort((e,t)=>{let n=tR(e),i=tR(t);return null===n&&null===i?0:null===n?1:null===i?-1:n-i})),u){let t=e.length,n=Math.max(1,Math.ceil(t/20)),i=Math.min(k,n),r
422=(i-1)*20;f({docs:e.slice(r,r+20),page:i,totalPages:n,totalDocs:t})}else f({docs:o.docs,page:o.page,totalPages:o.totalPages,totalDocs:o.totalDocs})}}catch(e){console.warn("Unable to load directory",e)}finally{e===em.current&&_(!1)}})(),c()},[k,L,O,B,j,e_,H,W,U,K,Z,J,ee,en,er,ea,el,eu,eh,i.defaultLanguage]);let eq=(0,ep.jsx)(tu.TextInput,{label:r("directoryName"),placeholder:r("directorySearchPlaceholder"),value:O,onChange:e=>eR(e.currentTarget.value),radius:(0,ex.getRadius)(i?.Theme?.borderRadius)});return(0,ep.jsxs)("div",{className:tA.default.directoryBlock,ref:ey,children:[e&&(0,ep.jsx)("h2",{className:tA.default.heading,children:e}),(0,ep.jsxs)("div",{className:tA.default.layout,children:[(0,ep.jsxs)("div",{className:tA.default.sidebarColumn,children:[(0,ep.jsxs)(ev.Paper,{radius:(0,ex.getRadius)(i?.Theme?.borderRadius),className:[tA.default.statsBar,tA.default.statsBarTrigger,l[a]].filter(Boolean).join(" "),role:"button",tabIndex:0,"aria-expanded":A,"aria-controls":"directory-filters-panel",onClick:()=>P(!0),onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&(e.preventDefault(),P(!0))},children:[(0,ep.jsxs)("div",{className:tA.default.statItem,children:[(0,ep.jsx)("span",{className:tA.default.statValue,children:g?g.totaal:"â"}),(0,ep.jsx)("span",{className:tA.default.statLabel,children:r("directoryStatsTotal")})]}),(0,ep.jsxs)("div",{className:tA.default.statItem,children:[(0,ep.jsx)("span",{className:tA.default.statValue,children:p.totalDocs}),(0,ep.jsx)("span",{className:tA.default.statLabel,children:r("directoryStatsShown")})]}),(0,ep.jsxs)("span",{className:tA.default.statsBarFiltersHint,children:[r("directoryFilters"),ek&&(0,ep.jsx)("span",{className:tA.default.filtersToggleDot,"aria-hidden":"true"}),(0,ep.jsx)("span",{className:tA.default.filtersToggleChevron,"aria-hidden":"true",children:"â¾"})]})]}),A&&(0,ep.jsx)("div",{className:tA.default.filtersBackdrop,onClick:()=>P(!1),"aria-hidden":"true"}),(0,ep.jsxs)(ev.Paper,{component:"aside",id:"directory-filters-panel",radius:(0,ex.getRadius)(i?.Theme?.borderRadius),className:E,style:h?{"--filters-radius":h}:void 0,children:[(0,ep.jsxs)("div",{className:tA.default.filtersScroll,children:[(0,ep.jsxs)("div",{className:tA.default.filtersHeader,children:[(0,ep.jsx)("h3",{className:tA.default.filtersTitle,children:r("directoryFilters")}),(0,ep.jsx)("button",{type:"button",className:tA.default.filtersCloseButton,onClick:()=>P(!1),"aria-label":r("close"),children:"â¾"})]}),!eS&&eq,eS&&(0,ep.jsxs)(e3,{className:tA.default.filterAccordion,classNames:{item:tA.default.filterSection,control:[tA.default.filterSectionControl,d[a]].filter(Boolean).join(" "),label:tA.default.filterSectionLabel,panel:tA.default.filterSectionPanel,content:tA.default.filterSectionContent,chevron:tA.default.filterSectionChevron},radius:(0,ex.getRadius)(i?.Theme?.borderRadius),children:[(0,ep.jsxs)(e3.Item,{value:"patient",children:[(0,ep.jsxs)(e3.Control,{icon:"ð§",style:{color:u},children:[r("directoryFilterGroupPatient"),eM&&(0,ep.jsx)("span",{className:tA.default.filtersToggleDot,style:{background:u},"aria-hidden":"true"})]}),(0,ep.jsxs)(e3.Panel,{children:[(0,ep.jsx)(e4.NumberInput,{label:r("directoryLeeftijd"),placeholder:r("directoryLeeftijdPlaceholder"),value:B,onChange:e=>eI("number"==typeof e?e:""),min:0,clampBehavior:"strict",radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),e_&&(0,ep.jsx)(e5.MultiSelect,{label:r("directoryVerzekeraars"),placeholder:j.length?void 0:r("directoryVerzekeraarsPlaceholder"),data:v.map(e=>({value:e.id,label:e.name})),value:j,onChange:eA,searchable:!0,clearable:!0,filter:(n=new Map(v.map(e=>[e.id,e.aliases??[]])),({options:e,search:t})=>{let i=t.trim().toLowerCase();return i?e.filter(e=>{if("items"in e)return!0;let t=n.get(e.value)??[];return e.label.toLowerCase().includes(i)||t.some(e=>e.toLowerCase().includes(i))}):e}),renderOption:({option:e})=>{let t=v.find(t=>t.id===e.value);return(0,ep.jsxs)("span",{children:[e.label,t?.aliases?.length?(0,ep.jsxs)("span",{className:tA.default.insurerOptionAliases,children:[" ","(",t.aliases.join(", "),")"]}):null]})},radius:(0,ex.getRadius)(i?.Theme?.borderRadius)})]})]}),(0,ep.jsxs)(e3.Item,{value:"complaints",children:[(0,ep.jsxs)(e3.Control,{icon:"ð¯",style:{color:u},children:[r("directoryFilterGroupComplaints"),eT&&(0,ep.jsx)("span",{className:tA.default.filtersToggleDot,style:{background:u},"aria-hidden":"true"})]}),(0,ep.jsxs)(e3.Panel,{children:[(0,ep.jsx)(tu.TextInput,{label:r("directoryKlachtenDiagnoses"),placeholder:r("directoryKlachtenDiagnosesPlaceholder"),value:er,onCh
422ange:e=>ez(e.currentTarget.value),radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsx)(e5.MultiSelect,{label:r("directoryTypeZorg"),placeholder:U.length?void 0:r("directoryTypeZorgPlaceholder"),data:tC,value:U,onChange:eL,searchable:!0,clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsx)(e5.MultiSelect,{label:r("directoryZorgsettingLabel"),placeholder:K.length?void 0:r("directoryZorgsettingPlaceholder"),data:tS,value:K,onChange:eF,searchable:!0,clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsx)(e5.MultiSelect,{label:r("directoryPrimaireBehandelkader"),placeholder:W.length?void 0:r("directoryPrimaireBehandelkaderPlaceholder"),data:w,value:W,onChange:eE,searchable:!0,clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsx)(e5.MultiSelect,{label:r("directoryExpertise"),placeholder:H.length?void 0:r("directoryExpertisePlaceholder"),data:b,value:H,onChange:eP,searchable:!0,clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsxs)("div",{className:tA.default.termSearchField,children:[(0,ep.jsx)(tu.TextInput,{label:r("directoryBehandelmethode"),placeholder:r("directoryBehandelmethodePlaceholder"),value:ea,onChange:e=>ej(e.currentTarget.value),radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsx)(tl,{size:"xs",value:el,onChange:e=>eV(e),data:[{label:r("directorySearchModeOr"),value:"OR"},{label:r("directorySearchModeAnd"),value:"AND"}]})]}),(0,ep.jsx)(e5.MultiSelect,{label:r("directoryZorgvormLabel"),placeholder:Z.length?void 0:r("directoryZorgvormPlaceholder"),data:t_,value:Z,onChange:eO,searchable:!0,clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)})]})]}),(0,ep.jsxs)(e3.Item,{value:"aanbod",children:[(0,ep.jsxs)(e3.Control,{icon:"ð",style:{color:u},children:[r("directoryFilterGroupAanbod"),eD&&(0,ep.jsx)("span",{className:tA.default.filtersToggleDot,style:{background:u},"aria-hidden":"true"})]}),(0,ep.jsxs)(e3.Panel,{children:[eq,(0,ep.jsx)(td.Select,{label:r("directoryWachttijdLabel"),placeholder:r("directoryNoFilter"),data:tM,value:en||null,onChange:e=>eB(e??""),clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsx)(e5.MultiSelect,{label:r("directoryExtraTaalLabel"),placeholder:ee.length?void 0:r("directoryExtraTaalPlaceholder"),data:tk,value:ee,onChange:eN,searchable:!0,clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsx)(tc.DateInput,{label:"Last checked after (dev)",value:eu,onChange:e=>eH(e?new Date(e):null),clearable:!0,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)})]})]})]})]}),(0,ep.jsx)("div",{className:tA.default.filtersFooter,children:ek&&(0,ep.jsxs)(tx.Button,{el:"button",type:"button",appearance:"secondary",className:tA.default.clearFiltersButton,onClick:()=>{N(""),z(""),V([]),G([]),$([]),q([]),Y([]),X([]),Q([]),et([]),ei(""),eo(""),es(""),ed("OR"),ec(null),M(1)},children:["â ",r("directoryClearFilters")]})})]})]}),(0,ep.jsxs)("div",{className:tA.default.results,children:[(0,ep.jsxs)("div",{className:tA.default.resultsHeader,children:[(0,ep.jsx)("div",{className:tA.default.tabs,children:eU.map(e=>(0,ep.jsx)("button",{type:"button",className:[tA.default.tab,L===e.value?tA.default.tabActive:""].join(" "),style:L===e.value?{color:o}:void 0,onClick:()=>{var t;F(t=e.value),M(1),""!==t&&"ggzOrganisation"!==t&&(z(""),V([]),G([]),$([]),q([]),Y([]),X([]),Q([]),et([]),ei(""),eo(""),es(""),ed("OR"),ec(null))},children:e.label},e.value))}),(0,ep.jsxs)("div",{className:tA.default.resultsHeaderRight,children:[(0,ep.jsx)(td.Select,{"aria-label":r("sortBy"),className:tA.default.sortSelect,data:[{label:r("directorySortNameAsc"),value:"name"},{label:r("directorySortNameDesc"),value:"-name"},{label:r("directorySortWachttijd"),value:"wachttijd"}],value:eh,onChange:e=>eG(e??"name"),allowDeselect:!1,radius:(0,ex.getRadius)(i?.Theme?.borderRadius)}),(0,ep.jsxs)("div",{className:tA.default.viewToggle,children:[(0,ep.jsx)("button",{type:"button","aria-label":r("directoryListView"),className:[tA.default.viewToggleButton,"stack"===T?tA.default.viewToggleButtonActive:""].join(" "),style:"stack"===T?{color:o}:void 0,onClick:()=>D("stack"),children:"â°"}),(0,ep.jsx)("button",{type:"button","aria-label":r("directoryGr
422idView"),className:[tA.default.viewToggleButton,"grid"===T?tA.default.viewToggleButtonActive:""].join(" "),style:"grid"===T?{color:o}:void 0,onClick:()=>D("grid"),children:"â¦"})]})]})]}),S?(0,ep.jsx)("div",{className:"grid"===T?tA.default.grid:tA.default.stack,children:Array.from({length:8}).map((e,t)=>(0,ep.jsx)(tj,{},t))}):0===p.docs.length?(0,ep.jsx)("div",{className:tA.default.empty,children:r("noResultsFound")}):(0,ep.jsxs)(ep.Fragment,{children:[(0,ep.jsx)("div",{className:"grid"===T?tA.default.grid:tA.default.stack,children:p.docs.map(e=>(0,ep.jsx)(tF,{item:e,onClick:()=>I(e)},e.id))}),p.totalPages>1&&(0,ep.jsx)(tb.Pagination,{className:tA.default.pagination,page:p.page,totalPages:p.totalPages,onClick:e=>{M(e),ey.current?.scrollIntoView({behavior:"smooth",block:"start"})}})]})]})]}),(0,ep.jsx)(tW,{item:R,onClose:()=>I(null)})]})},echartsBlock:({width:e=100,echartsArea:t,csvDelimiter:n=";",chartType:i,showLegend:r,marklineYAxis:o,rotateAxis:a})=>{let s=(0,tJ.parseCsv)({csvData:t,delimiter:n??";"});if("string"==typeof s)return(0,ep.jsx)("div",{children:s});let{data:l}=s;if(0===l.length)return(0,ep.jsx)("div",{children:"No table data available"});let d=((e,t,n)=>{let i=e[0],r=e.slice(1),o={};switch(t){case"bar":case"line":let a,s;a={type:"category",data:i},s={type:"value"},o={...n.rotateAxis?{yAxis:a,xAxis:s}:{xAxis:a,yAxis:s},series:r.map(e=>({type:t,data:e,...n.marklineYAxis?{markLine:{data:[n.rotateAxis?{xAxis:Number(n.marklineYAxis)}:{yAxis:Number(n.marklineYAxis)}],silent:!0}}:{}}))};break;case"pie":o={...n.showLegend?{legend:{orient:"horizontal",bottom:"bottom"}}:{},series:{type:"pie",data:r[0].map((e,t)=>({value:Number(e),name:i[t]})),bottom:20}};break;default:throw Error("Unsupported chart type")}return{tooltip:{},...o}})(l,i,{showLegend:r,marklineYAxis:o,rotateAxis:a});return(0,ep.jsx)("div",{style:{width:`${e}%`},children:(0,ep.jsx)(Fd,{option:d})})},formBlock:eo.default,grid:ea.GridBlock,htmlEmbed:({embedTitle:e,embedCode:t,sandboxAttributes:n=["allow-scripts","allow-same-origin","allow-forms","allow-popups","allow-top-navigation"]})=>((0,eC.useEffect)(()=>{let i=document.createElement("div");i.innerHTML=t;let r=i.getElementsByTagName("script"),o=n.map(e=>e.replace(/_/g,"-"));
422Array.from(i.getElementsByTagName("iframe")).forEach(e=>{o.length>0&&e.setAttribute("sandbox",o.join(" "))}),Array.from(r).forEach(e=>{let t=document.createElement("script");Array.from(e.attributes).forEach(e=>{t.setAttribute(e.name,e.value)}),t.innerHTML=e.innerHTML,e.parentNode?.replaceChild(t,e)});let a=document.getElementById(`embed-container-${e}`);a&&(a.innerHTML="",a.appendChild(i))},[t,n,e]),(0,ep.jsx)("div",{id:`embed-container-${e}`,className:tZ.default.embedContainer})),imageAndTextBlock:es.ImageAndTextBlock,linksBlock:el.LinksBlock,mapBlock:ed.MapBlock,mediaBlock:eu.MediaBlock,optionsBlock:({questions:e,resetButton:t})=>{let n=(0,eg.getColorClasses)(Fh.default,"block"),[i,r]=(0,eC.useState)([]),[o,a]=(0,eC.useState)({});return(0,eC.useEffect)(()=>{e&&Array.isArray(e)&&r(e.map((e,t)=>t).filter(t=>{let n=e[t];return!n.previousQuestion||!n.previousQuestion.questionNumber}))},[e]),e&&Array.isArray(e)&&0!==e.length?(0,ep.jsxs)("div",{className:Fh.default.optionsBlock,children:[i.map(t=>{let i;return(0,ep.jsxs)("div",{className:`${Fh.default.questionContainer} ${void 0!==o[t]?Fh.default["block--opened"]:""}`,children:[(0,ep.jsx)("div",{className:Fh.default.question,children:(0,ep.jsx)(Fp.default,{content:e[t].questionText,excludeFromToc:!0})}),(0,ep.jsx)(Fu.RadioGroup,{value:o[t]?.toString()||"",onChange:n=>{var i;let s;return i=parseInt(n),void((s={...o})[t]=i,Object.keys(s).forEach(e=>{let n=parseInt(e);n>t&&delete s[n]}),a(s),(t=>{let n=e.map((e,t)=>t).filter(t=>{let n=e[t];return!n.previousQuestion||!n.previousQuestion.questionNumber}),i=!0,o=0;for(;i&&o<10;)i=!1,o++,e.forEach((e,r)=>{if(n.includes(r))return;let o=e.previousQuestion;if(!o)return;let a=o.questionNumber,s=o.optionNumber;if(!a||!s)return;let l=a-1,d=s-1;if(isNaN(l)||isNaN(d)||!n.includes(l))return;let u=t[l];void 0!==u&&u===d&&(n.push(r),i=!0)});r(n)})(s))},variant:"vertical",children:e[t].options.map((e,t)=>(0,ep.jsx)(Fc.Radio,{mb:"md",ml:"md",value:t.toString(),label:e.label},t))}),void 0!==o[t]&&(0,ep.jsx)("div",{className:Fh.default.content,children:(i=e[t].options[o[t]],i?.content&&i.content.length>0?i.content.map((e,t)=>{let{blockType:i}=e;if(i&&i in Fy){let r=Fy[i],o=Fv(e),a=o&&n[o]?[n[o],Fh.default["block--hasBackgroundColor"]].join(" "):"",s=[Fh.default.block,a].filter(Boolean).join(" ");if(r)return(0,ep.jsx)("div",{className:s,children:(0,ep.jsx)(r,{...e})},t)}return null}):null)})]},t)}),Object.keys(o).length>0&&t&&(0,ep.jsx)("div",{className:Fh.default.resetButtonContainer,children:(0,ep.jsx)(tx.Button,{onClick:()=>{a({}),r(e.map((e,t)=>t).filter(t=>{let n=e[t];return!n.previousQuestion||!n.previousQuestion.questionNumber}))},label:t.label,appearance:t.appearance})})]}):(0,ep.jsx)("div",{children:"No questions available"})},richTextBlock:tY.RichTextBlock,tableBlock:ec.default,tocBlock:e=>{let{TOCintro:t,depth:n,withArrows:i}=e,r=parseInt(n?n[1]:"1"),[o,a]=(0,eC.useState)([]);(0,eC.useEffect)(()=>{let e=[];document.querySelectorAll(".TOC-content").forEach(t=>{Array.from(t.querySelectorAll("h1, h2, h3")).filter(e=>parseInt(e.tagName.slice(1))<=r).forEach(t=>{let n=parseInt(t.tagName.slice(1)),i=t.textContent?t.textContent.trim():"",r=t.id||i.toLowerCase().replace(/\s+/g,"-").replace(/[^\w\-]/g,"");t.id||(t.id=r),e.push({el:t,heading:{id:r,text:i,level:n,children:[]}})})}),a((e=>{let t=[],n={},i=0,o=e.length>0?Math.min(...e.map(e=>e.heading.level)):1;for(let a of e){let e={el:a.el,id:a.heading.id,text:a.heading.text,level:a.heading.level,children:[]},s=a.heading.level;if(n[s]=e,s<i)for(let e=s+1;e<=r;e++)n[e]=null;if(s>o){for(let t=s-1;t>=o;t--)if(n[t]){n[t].children.push(e);break}}else t.push(e);i=s}return t})(e))},[r]);let s=(e,t)=>{e.preventDefault();let n=document.getElementById(t);n&&n.scrollIntoView({behavior:"smooth",block:"center"})},l=e=>(0,ep.jsx)("ul",{children:e.map((e,t)=>(0,ep.jsxs)("li",{children:[1===e.level?(0,ep.jsx)("strong",{style:{fontSize:"large"},onClick:t=>s(t,e.id),children:(0,ep.jsx)(Fg.CMSLink,{appearance:"default",linksWithArrowIcon:i,label:e.text,url:`#${e.id}`})}):2===e.level?(0,ep.jsx)("strong",{onClick:t=>s(t,e.id),children:(0,ep.jsx)(Fg.CMSLink,{appearance:"default",linksWithArrowIcon:i,label:e.text,url:`#${e.id}`})}):(0,ep.jsx)("span",{onClick:t=>s(t,e.id),children:(0,ep.jsx)(Fg.CMSLink,{appearance:"default",linksWithArrowIcon:i,label:e.text,url:`#${e.id}`})}),e.children.length>0&&l(e.children)]},`${e.id}-${t}`))});return(0,ep.jsxs)("div",{className:Ff.default.tocBlockWrapper,children:[t&&(0,ep.jsx)(Fp.default,{content:t,excludeFromToc:!0}
422),(0,ep.jsx)("div",{className:Ff.default.tocBlock,children:l(o)})]})},videoBlock:eh.VideoBlock,placeholderBlock:e=>{let{originId:t,elementDescription:n}=e;return(0,ep.jsx)("div",{id:t??void 0,className:Fm.default.placeholderBlock,children:n?.description??""})}}},20963,e=>{"use strict";var t=e.i(48277),n=e.i(66369),i=e.i(86577),r=e.i(17444),o=e.i(18756),a=e.i(19285),s=e.i(14932),l=e.i(90388);let d=["richTextBlock"],u=["Link","LinksBlock"],c=["linksBlock"];e.s(["Footer",0,()=>{let{tenant:e}=(0,l.useTenant)(),h=(0,a.useIsLinkActive)(),p=e.Footer,f=p?.backgroundColor,g=p?.logos,m=p?.navColumns||[],v=p?.colorTypography;v||(console.warn("Missing colorTypography in footer, using default primary color"),v="primary");let y=p?.linksWithArrowIcon,b={"--footer-text-color":`var(--c-${v})`},x=[n.default.footer,f?n.default[`footer--${String(f)}`]:n.default["footer--text-black"],n.default.footer__container].filter(Boolean).join(" ");return p?(0,t.jsxs)("footer",{id:"footer",style:b,className:x,"data-block":"footer",children:[(0,t.jsx)(()=>g&&0!==g.length?(0,t.jsx)("div",{className:n.default.footer__logos,children:g.map((e,i)=>(0,t.jsx)(r.Media,{className:n.default.footer__logo,resource:e.logo},i))}):(0,t.jsx)(t.Fragment,{}),{}),m.length>0&&(0,t.jsx)("div",{className:n.default.footer__nav,children:m.map(({title:e,columnTitle:r,link:o,blocks:a},l)=>{let p=o?.appearance&&o?.appearance!="default"?o.appearance:void 0;return(0,t.jsxs)("div",{className:n.default["footer__nav-column"],children:[(0,t.jsx)("div",{className:[n.default["footer__nav-column-title"],p?n.default["footer__nav-column-title--withAppearance"]:""].filter(Boolean).join(" "),children:"textTitle"===e&&r?r:"linkTitle"===e&&o?.label?(0,t.jsx)(i.CMSLink,{className:[n.default["footer__nav-column-links"],n.default["footer__nav-link-title"],h(o)?n.default["footer__nav-link--active"]:""].filter(Boolean).join(" "),...o,appearance:p}):null}),a&&a.length>0&&(0,t.jsx)(t.Fragment,{children:a.map((e,i)=>{let{blockName:r,blockType:o}=e;if(o&&o in s.blockComponents){let a=s.blockComponents[o],l=(0,s.getBlockBackgroundColor)(e),h="linksBlock"==o&&e.links?.[0]?.link?.appearance!="default"&&e.links?.[0]?.link?.appearance?{className:n.default["footer__nav-link-block"]}:{};return a?(0,t.jsx)("div",{children:(0,t.jsx)(a,{...e,id:`${r}-${i}`,...l&&d.includes(o)?{bgColor:l}:{},...v&&u.includes(o)?{colorTypography:v}:{},...v&&c.includes(o)?{linksWithArrowIcon:y}:{},...h})},i):null}return null})})]},l)})}),(0,t.jsx)(o.Branding,{bgColor:f})]}):(0,t.jsx)(o.Branding,{bgColor:f})}])}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.