HomeDashboard/.venv/lib/python3.12/site-packages/nicegui/elements/aggrid/dist/index.js
2026-01-03 14:54:18 +01:00

3 lines
1.0 MiB
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

var e=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,o){const i=t?this.allAsyncListeners:this.allSyncListeners;let s=i.get(e);return!s&&o&&(s=new Set,i.set(e,s)),s}noRegisteredListenersExist(){return 0===this.allSyncListeners.size&&0===this.allAsyncListeners.size&&0===this.globalSyncListeners.size&&0===this.globalAsyncListeners.size}addEventListener(e,t,o=!1){this.getListeners(e,o,!0).add(t)}removeEventListener(e,t,o=!1){const i=this.getListeners(e,o,!1);i&&(i.delete(t),0===i.size&&(o?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){const o=e.type;if(t&&"event"in e){const t=e.event;t instanceof Event&&(e.eventPath=t.composedPath())}const{frameworkOverrides:i}=this,s=e=>{const o=i?()=>i.wrapIncoming(e):e;t?this.dispatchAsync(o):o()},n=this.getListeners(o,t,!1);if((n?.size??0)>0){const t=new Set(n);for(const o of t)n?.has(o)&&s(()=>o(e))}const r=this.getGlobalListeners(t);if(r.size>0){const t=new Set(r);for(const i of t)s(()=>i(o,e))}}getGlobalListeners(e){return e?this.globalAsyncListeners:this.globalSyncListeners}dispatchAsync(e){if(this.asyncFunctionsQueue.push(e),!this.scheduled){const e=()=>{window.setTimeout(this.flushAsyncQueue.bind(this),0)};this.frameworkOverrides?this.frameworkOverrides.wrapIncoming(e):e(),this.scheduled=!0}}flushAsyncQueue(){this.scheduled=!1;const e=this.asyncFunctionsQueue.slice();this.asyncFunctionsQueue=[],e.forEach(e=>e())}};function t(e){return null==e||""===e?null:e}function o(e){return null!=e&&""!==e}function i(e){return!o(e)}function s(e){return null!=e&&"function"==typeof e.toString?e.toString():null}function n(e,t){return(e?JSON.stringify(e):null)===(t?JSON.stringify(t):null)}function r(e,t,o=!1){const i=null==e,s=null==t;if(e&&e.toNumber&&(e=e.toNumber()),t&&t.toNumber&&(t=t.toNumber()),i&&s)return 0;if(i)return-1;if(s)return 1;function n(e,t){return e>t?1:e<t?-1:0}if("string"!=typeof e)return n(e,t);if(!o)return n(e,t);try{return e.localeCompare(t)}catch(o){return n(e,t)}}var a=/[&<>"']/g,l={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function d(e){return e?.toString().toString()??null}function h(e){return d(e)?.replace(a,e=>l[e])??null}function c(e){return e.eRootDiv.getRootNode()}function u(e){return c(e).activeElement}function g(e){const{gos:t,eRootDiv:i}=e;let s=null;const n=t.get("getDocument");return n&&o(n)?s=n():i&&(s=i.ownerDocument),s&&o(s)?s:document}function p(e){const t=u(e);return null===t||t===g(e).body}function m(e){return g(e).defaultView||window}function f(e){let t=null,o=null;try{t=g(e).fullscreenElement}catch(e){}finally{t||(t=c(e));const i=t.querySelector("body");o=i||(t instanceof ShadowRoot?t:t instanceof Document?t?.documentElement:t)}return o}function C(e,t,o){null==o||"string"==typeof o&&""==o?w(e,t):v(e,t,o)}function v(e,t,o){e.setAttribute(b(t),o.toString())}function w(e,t){e.removeAttribute(b(t))}function b(e){return`aria-${e}`}function y(e,t){t?e.setAttribute("role",t):e.removeAttribute("role")}function S(e,t){C(e,"label",t)}function E(e,t){C(e,"labelledby",t)}function R(e,t){C(e,"live",t)}function x(e,t){C(e,"invalid",t)}function F(e,t){C(e,"hidden",t)}function P(e,t){v(e,"expanded",t)}function D(e,t){v(e,"rowindex",t)}function M(e,t){v(e,"colindex",t)}function k(e,t){C(e,"selected",t)}function T(e,t){!function(e,t){C(e,"controls",t)}(e,t.id),E(t,e.id)}function I(e,t){C(e,"owns",t)}function A(e,t){return void 0===t?e("ariaIndeterminate","indeterminate"):!0===t?e("ariaChecked","checked"):e("ariaUnchecked","unchecked")}var L="[disabled], .ag-disabled:not(.ag-button), .ag-disabled *";function B(e){const t=Element.prototype.matches||Element.prototype.msMatchesSelector,o=t.call(e,"input, select, button, textarea"),i=t.call(e,L),s=Q(e);return o&&!i&&s}function H(e,t,o={}){const{skipAriaHidden:i}=o;e.classList.toggle("ag-hidden",!t),i||F(e,!t)}function V(e,t){const o="disabled",i=t?e=>e.setAttribute(o,""):e=>e.removeAttribute(o);i(e);const s=e.querySelectorAll("input")??[];for(const e of s)i(e)}function G(e,t,o){let i=0;for(;e;){if(e.classList.contains(t))return!0;if(e=e.parentElement,"number"==typeof o){if(++i>o)break}else if(e===o)break}return!1}function N(e){const{height:t,width:o,borderTopWidth:i,borderRightWidth:s,borderBottomWidth:n,borderLeftWidth:r,paddingTop:a,paddingRight:l,paddingBottom:d,paddingLeft:h,marginTop:c,marginRight:u,marginBottom:g,marginLeft:p,boxSizing:m}=window.getComputedStyle(e);return{height:parseFloat(t||"0"),width:parseFloat(o||"0"),borderTopWidth:parseFloat(i||"0"),borderRightWidth:parseFloat(s||"0"),borderBottomWidth:parseFloat(n||"0"),borderLeftWidth:parseFloat(r||"0"),paddingTop:parseFloat(a||"0"),paddingRight:parseFloat(l||"0"),paddingBottom:parseFloat(d||"0"),paddingLeft:parseFloat(h||"0"),marginTop:parseFloat(c||"0"),marginRight:parseFloat(u||"0"),marginBottom:parseFloat(g||"0"),marginLeft:parseFloat(p||"0"),boxSizing:m}}function O(e){const t=N(e);return"border-box"===t.boxSizing?t.height-t.paddingTop-t.paddingBottom:t.height}function z(e){const t=N(e);return"border-box"===t.boxSizing?t.width-t.paddingLeft-t.paddingRight:t.width}function W(e){const{height:t,marginBottom:o,marginTop:i}=N(e);return Math.floor(t+o+i)}function U(e){const{width:t,marginLeft:o,marginRight:i}=N(e);return Math.floor(t+o+i)}function $(e){const t=e.getBoundingClientRect(),{borderTopWidth:o,borderLeftWidth:i,borderRightWidth:s,borderBottomWidth:n}=N(e);return{top:t.top+(o||0),left:t.left+(i||0),right:t.right+(s||0),bottom:t.bottom+(n||0)}}function K(e,t){let o=e.scrollLeft;return t&&(o=Math.abs(o)),o}function j(e,t,o){o&&(t*=-1),e.scrollLeft=t}function q(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}function _(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function Y(e){return!!e.offsetParent}function Q(e){const t=e;if(t.checkVisibility)return t.checkVisibility({checkVisibilityCSS:!0});return!(!Y(e)||"visible"!==window.getComputedStyle(e).visibility)}function Z(e){const t=document.createElement("div");return t.innerHTML=(e||"").trim(),t.firstChild}function J(e,t,o){o&&o.nextSibling===t||(e.firstChild?o?o.nextSibling?e.insertBefore(t,o.nextSibling):e.appendChild(t):e.firstChild&&e.firstChild!==t&&e.insertAdjacentElement("afterbegin",t):e.appendChild(t))}function X(e,t){for(let o=0;o<t.length;o++){const i=t[o],s=e.children[o];s!==i&&e.insertBefore(i,s)}}function ee(e){return e.replace(/[A-Z]/g,e=>`-${e.toLocaleLowerCase()}`)}function te(e,t){if(t)for(const o of Object.keys(t)){const i=t[o];if(!o||!o.length||null==i)continue;const s=ee(o),n=i.toString(),r=n.replace(/\s*!important/g,""),a=r.length!=n.length?"important":void 0;e.style.setProperty(s,r,a)}}function oe(e){return()=>{const t=e();return!t||(ie(t)||se(t))}}function ie(e){return e.clientWidth<e.scrollWidth}function se(e){return e.clientHeight<e.scrollHeight}function ne(e,t){"flex"===t?(e.style.removeProperty("width"),e.style.removeProperty("minWidth"),e.style.removeProperty("maxWidth"),e.style.flex="1 1 auto"):re(e,t)}function re(e,t){t=le(t),e.style.width=t,e.style.maxWidth=t,e.style.minWidth=t}function ae(e,t){t=le(t),e.style.height=t,e.style.maxHeight=t,e.style.minHeight=t}function le(e){return"number"==typeof e?`${e}px`:e}function de(e){return e instanceof Node||e instanceof HTMLElement}function he(e,t,o){null==o||""===o?e.removeAttribute(t):e.setAttribute(t,o.toString())}function ce(e,t,o){const i=m(e).ResizeObserver,s=i?new i(o):null;return s?.observe(t),()=>s?.disconnect()}function ue(e,t){const o=m(e);o.requestAnimationFrame?o.requestAnimationFrame(t):o.webkitRequestAnimationFrame?o.webkitRequestAnimationFrame(t):o.setTimeout(t,0)}var ge,pe="data-ref";function me(){return ge??(ge=document.createTextNode(" ")),ge.cloneNode()}function fe(e){const{attrs:t,children:o,cls:i,ref:s,role:n,tag:r}=e,a=document.createElement(r);if(i&&(a.className=i),s&&a.setAttribute(pe,s),n&&a.setAttribute("role",n),t)for(const e of Object.keys(t))a.setAttribute(e,t[e]);if(o)if("string"==typeof o)a.textContent=o;else{let e=!0;for(const t of o)t&&("string"==typeof t?(a.appendChild(document.createTextNode(t)),e=!1):"function"==typeof t?a.appendChild(t()):(e&&(a.appendChild(me()),e=!1),a.append(fe(t)),a.appendChild(me())))}return a}var Ce=["touchstart","touchend","touchmove","touchcancel","scroll"],ve=["wheel"],we={},be=(()=>{const e={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return t=>{if("boolean"==typeof we[t])return we[t];const o=document.createElement(e[t]||"div");return we[t="on"+t]=t in o}})();function ye(e,t){return!(!t||!e)&&function(e){const t=e;if(t.path)return t.path;if(t.composedPath)return t.composedPath();return function(e){const t=[];let o=e.target;for(;o;)t.push(o),o=o.parentElement;return t}(t)}(t).indexOf(e)>=0}var Se=e=>{const t=Ce.includes(e),o=ve.includes(e);return!!t||!o&&void 0};function Ee(e,t,o){if(0===o)return!1;const i=Math.abs(e.clientX-t.clientX),s=Math.abs(e.clientY-t.clientY);return Math.max(i,s)<=o}function Re(e,t){return e.gos.isElementInThisInstance(t.target)}function xe(e,t,o){const i=e.getBoundingClientRect().height,s=function(e){const t=f(e);return t?.clientWidth??(window.innerWidth||-1)}(o)-2,n=function(e){const t=f(e);return t?.clientHeight??(window.innerHeight||-1)}(o)-2;if(!e.offsetParent)return;const r=$(e.offsetParent),{clientY:a,clientX:l}=t;let d=a-r.top-i/2,h=l-r.left-10;const c=g(o),u=c.defaultView||window,p=u.pageYOffset||c.documentElement.scrollTop,m=u.pageXOffset||c.documentElement.scrollLeft;s>0&&h+e.clientWidth>s+m&&(h=s+m-e.clientWidth),h<0&&(h=0),n>0&&d+e.clientHeight>n+p&&(d=n+p-e.clientHeight),d<0&&(d=0),e.style.left=`${h}px`,e.style.top=`${d}px`}function Fe(e,t){return t}function Pe(e){return e?.getLocaleTextFunc()??Fe}var De=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(){const{destroyFunctions:e}=this;for(let t=0;t<e.length;t++)e[t]();e.length=0,this.destroyed=!0,this.dispatchLocalEvent({type:"destroyed"})}addEventListener(t,o,i){this.localEventService||(this.localEventService=new e),this.localEventService.addEventListener(t,o,i)}removeEventListener(e,t,o){this.localEventService?.removeEventListener(e,t,o)}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){const o=[];for(const i of Object.keys(t)){const s=t[i];s&&o.push(this._setupListener(e,i,s))}return o}_setupListener(e,t,o){if(this.destroyed)return()=>null;let i;if(function(e){return void 0!==e.__addEventListener}(e))e.__addEventListener(t,o),i=()=>(e.__removeEventListener(t,o),null);else{const s=function(e){return"global"===e.eventServiceType}(e);e instanceof HTMLElement?function(e,t,o){const i=Se(t);let s;null!=i&&(s={passive:i}),e.addEventListener(t,o,s)}(e,t,o):s?e.addListener(t,o):e.addEventListener(t,o),i=s?()=>(e.removeListener(t,o),null):()=>(e.removeEventListener(t,o),null)}return this.destroyFunctions.push(i),()=>(i(),this.destroyFunctions=this.destroyFunctions.filter(e=>e!==i),null)}setupPropertyListener(e,t){const{gos:o}=this;o.addPropertyEventListener(e,t);const i=()=>(o.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;const o=e.join("-")+this.propertyListenerId++,i=e=>{if(e.changeSet){if(e.changeSet&&e.changeSet.id===this.lastChangeSetIdLookup[o])return;this.lastChangeSetIdLookup[o]=e.changeSet.id}const i={type:"propertyChanged",changeSet:e.changeSet,source:e.source};t(i)};e.forEach(e=>this.setupPropertyListener(e,i))}getLocaleTextFunc(){return Pe(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){const o=this.createBean(e,t);return this.addDestroyFunc(this.destroyBean.bind(this,e,t)),o}createBean(e,t,o){return(t||this.stubContext).createBean(e,o)}destroyBean(e,t){return(t||this.stubContext).destroyBean(e)}destroyBeans(e,t){return(t||this.stubContext).destroyBeans(e)}};var Me=class extends De{},ke={};function Te(e,t){ke[t]||(e(),ke[t]=!0)}var Ie={pending:!1,funcs:[]},Ae={pending:!1,funcs:[]};function Le(e,t="setTimeout",o){const i="raf"===t?Ae:Ie;if(i.funcs.push(e),i.pending)return;i.pending=!0;const s=()=>{const e=i.funcs.slice();i.funcs.length=0,i.pending=!1,e.forEach(e=>e())};"raf"===t?ue(o,s):window.setTimeout(s,0)}function Be(e,t,o){let i;return function(...s){const n=this;window.clearTimeout(i),i=window.setTimeout(function(){e.isAlive()&&t.apply(n,s)},o)}}function He(e,t){let o=0;return function(...i){const s=Date.now();s-o<t||(o=s,e.apply(this,i))}}var Ve=new Set(["__proto__","constructor","prototype"]);function Ge(e,t,i=!0,s=!1){o(t)&&function(e,t){if(null!=e)if(Array.isArray(e))for(let o=0;o<e.length;o++)t(o.toString(),e[o]);else for(const o of Object.keys(e).filter(e=>!Ve.has(e)))t(o,e[o])}(t,(t,o)=>{let n=e[t];if(n!==o){if(s){if(null==n&&null!=o){"object"==typeof o&&o.constructor===Object&&(n={},e[t]=n)}}Ne(o)&&Ne(n)&&!Array.isArray(n)?Ge(n,o,i,s):(i||void 0!==o)&&(e[t]=o)}})}function Ne(e){return"object"==typeof e&&null!==e}var Oe=class e{static applyGlobalGridOptions(t){if(!e.gridOptions)return{...t};let o={};return Ge(o,e.gridOptions,!0,!0),"deep"===e.mergeStrategy?Ge(o,t,!0,!0):o={...o,...t},e.gridOptions.context&&(o.context=e.gridOptions.context),t.context&&("deep"===e.mergeStrategy&&o.context&&Ge(t.context,o.context,!0,!0),o.context=t.context),o}};Oe.gridOptions=void 0,Oe.mergeStrategy="shallow";var ze=Oe,We={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:"\t",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},Ue="https://www.ag-grid.com";function $e(e,t,...o){e.get("debug")&&console.log("AG Grid: "+t,...o)}function Ke(e,...t){Te(()=>console.warn("AG Grid: "+e,...t),e+t?.join(""))}function je(e,...t){Te(()=>console.error("AG Grid: "+e,...t),e+t?.join(""))}var qe="34.2.0",_e="_version_",Ye=null,Qe=`${Ue}/javascript-data-grid`;function Ze(e,t,o){return Ye?.(e,t)??[it(e,t,o)]}function Je(e,t,o,i,s){e(`${i?"warning":"error"} #${t}`,...Ze(t,o,s))}function Xe(e){let t=e;return e instanceof Error?t=e.toString():"object"==typeof e&&(t=function(e){if(!e)return String(e);const t={};for(const o of Object.keys(e))"object"!=typeof e[o]&&"function"!=typeof e[o]&&(t[o]=e[o]);return JSON.stringify(t)}(e)),t}function et(e){return void 0===e?"undefined":null===e?"null":e}function tt(e,t){return`${e}?${t.toString()}`}function ot(e,t){const o=new URLSearchParams;if(o.append(_e,qe),t)for(const e of Object.keys(t))o.append(e,Xe(t[e]));const i=`${Qe}/errors/${e}`,s=tt(i,o);return s.length<=2e3?s:function(e,t,o){const i=Array.from(t.entries()).sort((e,t)=>t[1].length-e[1].length);let s=tt(e,t);for(const[n,r]of i){if(n===_e)continue;const i=s.length-o;if(i<=0)break;const a="...",l=i+a.length,d=r.length-l>100?r.slice(0,r.length-l)+a:r.slice(0,100)+a;t.set(n,d),s=tt(e,t)}return s}(i,o,2e3)}var it=(e,t,o)=>`${o?o+" \n":""}Visit ${ot(e,t)}${o?"":" \n Alternatively register the ValidationModule to see the full message in the console."}`;function st(...e){Je(Ke,e[0],e[1],!0)}function nt(...e){Je(je,e[0],e[1],!1)}function rt(e,t,o){Je(je,e,t,!1,o)}function at(...e){return function(e,t){const o=t[0];return`error #${o} `+Ze(o,t[1],e).join(" ")}(void 0,e)}function lt(e,t){return e.get("rowModelType")===t}function dt(e,t){return lt(e,"clientSide")}function ht(e,t){return lt(e,"serverSide")}function ct(e,t){return e.get("domLayout")===t}function ut(e){return void 0!==Lt(e)}function gt(e){return"function"==typeof e.get("getRowHeight")}function pt(e,t,o=!1,i){const{gos:s,environment:n}=e;if(null==i&&(i=n.getDefaultRowHeight()),gt(s)){if(o)return{height:i,estimated:!0};const e={node:t,data:t.data},n=s.getCallback("getRowHeight")(e);if(ft(n))return 0===n&&st(23),{height:Math.max(1,n),estimated:!1}}if(t.detail&&s.get("masterDetail"))return function(e){if(e.get("detailRowAutoHeight"))return{height:1,estimated:!1};const t=e.get("detailRowHeight");if(ft(t))return{height:t,estimated:!1};return{height:300,estimated:!1}}(s);const r=s.get("rowHeight");return{height:r&&ft(r)?r:i,estimated:!1}}function mt(e){const{environment:t,gos:o}=e,s=o.get("rowHeight");if(!s||i(s))return t.getDefaultRowHeight();const n=t.refreshRowHeightVariable();return-1!==n?n:(st(24),t.getDefaultRowHeight())}function ft(e){return!isNaN(e)&&"number"==typeof e&&isFinite(e)}function Ct(e,t,o){const i=t[e.getDomDataKey()];return i?i[o]:void 0}function vt(e,t,o,s){const n=e.getDomDataKey();let r=t[n];i(r)&&(r={},t[n]=r),r[o]=s}function wt(e){return!e.get("ensureDomOrder")&&e.get("animateRows")}function bt(e){return!(e.get("paginateChildRows")||e.get("groupHideOpenParents")||ct(e,"print"))}function yt(e){const t=e.get("autoGroupColumnDef");return!t?.comparator&&!e.get("treeData")}function St(e){const t=e.get("groupAggFiltering");return"function"==typeof t?e.getCallback("groupAggFiltering"):!0===t?()=>!0:void 0}function Et(e){return e.get("grandTotalRow")}function Rt(e,t){return!t&&"groupRows"===e.get("groupDisplayType")}function xt(e,t,o){return!!t.group&&!t.footer&&Rt(e,o)}function Ft(e){const t=e.getCallback("getRowId");return void 0===t?t:e=>{let o=t(e);return"string"!=typeof o&&(Te(()=>st(25,{id:o}),"getRowIdString"),o=String(o)),o}}function Pt(e){return e?.checkboxes??!0}function Dt(e){return"multiRow"===e?.mode&&(e.headerCheckbox??!0)}function Mt(e){if("object"==typeof e)return e.checkboxLocation??"selectionColumn"}function kt(e){return e?.hideDisabledCheckboxes??!1}function Tt(e){const t=e.get("cellSelection");return void 0!==t?!!t:e.get("enableRangeSelection")}function It(e){const t=e.get("rowSelection")??"single";if("string"==typeof t){const t=e.get("suppressRowClickSelection"),o=e.get("suppressRowDeselection");return(!t||!o)&&(t?"enableDeselection":!o||"enableSelection")}return("singleRow"===t.mode||"multiRow"===t.mode)&&(t.enableClickSelection??!1)}function At(e){const t=e.get("rowSelection");return"string"==typeof t?e.get("isRowSelectable"):t?.isRowSelectable}function Lt(e){const 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 Bt(e){return"multiRow"===Lt(e)}function Ht(e){const t=e.get("rowSelection");if("string"==typeof t){const t=e.get("groupSelectsChildren"),o=e.get("groupSelectsFiltered");return t&&o?"filteredDescendants":t?"descendants":"self"}return"multiRow"===t?.mode?t.groupSelects:void 0}function Vt(e,t=!0){const o=e.get("rowSelection");return"object"!=typeof o?t?"all":void 0:"multiRow"===o.mode?o.selectAll:"all"}function Gt(e){const t=Ht(e);return"descendants"===t||"filteredDescendants"===t}function Nt(e){const t=e.get("rowSelection");return"object"==typeof t&&t.masterSelects||"self"}function Ot(e){return"legacy"===e.get("columnMenu")}function zt(e,t){return e.addCommon(t)}function Wt(e){return e.get("treeData")?e.get("treeDataParentIdField")?"treeSelfRef":e.get("treeDataChildrenField")?"treeNested":"treePath":"group"}function Ut({gos:e},t){return 2===t.button||t.ctrlKey&&e.get("allowContextMenuWithControlKey")}var $t={resizable:!0,sortable:!0},Kt=0;function jt(){return Kt++}function qt(e){return e instanceof _t}var _t=class extends Me{constructor(t,o,i,s){super(),this.colDef=t,this.userProvidedColDef=o,this.colId=i,this.primary=s,this.isColumn=!0,this.instanceId=jt(),this.autoHeaderHeight=null,this.moving=!1,this.resizing=!1,this.menuVisible=!1,this.lastLeftPinned=!1,this.firstRightPinned=!1,this.filterActive=!1,this.colEventSvc=new e,this.tooltipEnabled=!1,this.rowGroupActive=!1,this.pivotActive=!1,this.aggregationActive=!1,this.flex=null,this.colIdSanitised=h(i)}destroy(){super.destroy(),this.beans.rowSpanSvc?.deregister(this)}getInstanceId(){return this.instanceId}setState(){const{colDef:e,beans:{sortSvc:t,pinnedCols:o,colFlex:i}}=this;t?.initCol(this);const s=e.hide;this.visible=void 0!==s?!s:!e.initialHide,o?.initCol(this),i?.initCol(this)}setColDef(e,t,o){const 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",o)}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(){const{gos:e,colDef:{field:t,tooltipField:i}}=this,s=e.get("suppressFieldDotNotation");this.fieldContainsDots=o(t)&&t.indexOf(".")>=0&&!s,this.tooltipFieldContainsDots=o(i)&&i.indexOf(".")>=0&&!s}initMinAndMaxWidths(){const 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(){const e=this.beans.pivotColDefSvc,t=this.colDef.pivotValueColumn;e&&t&&this.addManagedListeners(t,{colDefChanged:t=>{const o=e.recreateColDef(this.colDef);this.setColDef(o,o,t.source)}})}resetActualWidth(e){const t=this.calculateColInitialWidth(this.colDef);this.setActualWidth(t,e,!0)}calculateColInitialWidth(e){let t;const o=e.width,i=e.initialWidth;return t=null!=o?o:null!=i?i:200,Math.max(Math.min(t,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);const o=this.frameworkEventListenerService?.wrap(e,t)??t;this.colEventSvc.addEventListener(e,o)}removeEventListener(e,t){const o=this.frameworkEventListenerService?.unwrap(e,t)??t;this.colEventSvc.removeEventListener(e,o)}createColumnFunctionCallbackParams(e){return zt(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]??$t[e]}isColumnFunc(e,t){if("boolean"==typeof t)return t;if("function"==typeof t){return t(this.createColumnFunctionCallbackParams(e))}return!1}createColumnEvent(e,t){return zt(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 i(this.sort)}isSorting(){return o(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 st(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){const o=!0===e;this.visible!==o&&(this.visible=o,this.dispatchColEvent("visibleChanged",t)),this.dispatchStateUpdatedEvent("hide")}isVisible(){return this.visible}isSpanHeaderHeight(){return!this.getColDef().suppressSpanHeaderHeight}getFirstRealParent(){let e=this.getOriginalParent();for(;e&&e.isPadding();)e=e.getOriginalParent();return e}getColumnGroupPaddingInfo(){let e=this.getParent();if(!e||!e.isPadding())return{numberOfParents:0,isSpanningTotal:!1};const t=e.getPaddingLevel()+1;let o=!0;for(;e;){if(!e.isPadding()){o=!1;break}e=e.getParent()}return{numberOfParents:t,isSpanningTotal:o}}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){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}createBaseColDefParams(e){return zt(this.gos,{node:e,data:e.data,colDef:this.colDef,column:this})}getColSpan(e){if(i(this.colDef.colSpan))return 1;const t=this.createBaseColDefParams(e),o=this.colDef.colSpan(t);return Math.max(o,1)}getRowSpan(e){if(i(this.colDef.rowSpan))return 1;const t=this.createBaseColDefParams(e),o=this.colDef.rowSpan(t);return Math.max(o,1)}setActualWidth(e,t,o=!1){e=Math.max(e,this.minWidth),e=Math.min(e,this.maxWidth),this.actualWidth!==e&&(this.actualWidth=e,null!=this.flex&&"flex"!==t&&"gridInitializing"!==t&&(this.flex=null),o||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,o){const i=this.createColumnEvent(e,t);o&&Ge(i,o),this.colEventSvc.dispatchEvent(i)}dispatchStateUpdatedEvent(e){this.colEventSvc.dispatchEvent({type:"columnStateUpdated",key:e})}};function Yt(e){return e instanceof Qt}var Qt=class extends Me{constructor(e,t,o,i){super(),this.colGroupDef=e,this.groupId=t,this.padding=o,this.level=i,this.isColumn=!1,this.expandable=!1,this.instanceId=jt(),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(){const e=[];return this.addLeafColumns(e),e}forEachLeafColumn(e){if(this.children)for(const t of this.children)qt(t)?e(t):Yt(t)&&t.forEachLeafColumn(e)}addLeafColumns(e){this.children&&this.children.forEach(t=>{qt(t)?e.push(t):Yt(t)&&t.addLeafColumns(e)})}getColumnGroupShow(){const e=this.colGroupDef;if(e)return e.columnGroupShow}setupExpandable(){this.setExpandable(),this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback();const e=this.onColumnVisibilityChanged.bind(this);this.getLeafColumns().forEach(t=>t.__addEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=()=>{this.getLeafColumns().forEach(t=>t.__removeEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=null}}setExpandable(){if(this.isPadding())return;let e=!1,t=!1,o=!1;const i=this.findChildrenRemovingPadding();for(let s=0,n=i.length;s<n;s++){const n=i[s];if(!n.isVisible())continue;const r=n.getColumnGroupShow();"open"===r?(e=!0,o=!0):"closed"===r?(t=!0,o=!0):(e=!0,t=!0)}const s=e&&t&&o;this.expandable!==s&&(this.expandable=s,this.dispatchLocalEvent({type:"expandableChanged"}))}findChildrenRemovingPadding(){const e=[],t=o=>{o.forEach(o=>{Yt(o)&&o.isPadding()?t(o.children):e.push(o)})};return t(this.children),e}onColumnVisibilityChanged(){this.setExpandable()}},Zt={numericColumn:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"},rightAligned:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"}};function Jt(e,t,o){const i={},s=e.gos;return Object.assign(i,s.get("defaultColGroupDef")),Object.assign(i,t),s.validateColDef(i,o),i}var Xt=class{constructor(){this.existingKeys={}}addExistingKeys(e){for(let t=0;t<e.length;t++)this.existingKeys[e[t]]=!0}getUniqueKey(e,t){e=s(e);let o=0;for(;;){let i=e??t;if(i?0!==o&&(i+="_"+o):i=o,!this.existingKeys[i]){const t=String(i);return e&&o>0&&st(273,{providedId:e,usedId:t}),this.existingKeys[t]=!0,t}o++}}},eo=Object.freeze([]);function to(e){if(e?.length)return e[e.length-1]}function oo(e,t,o){if(e===t)return!0;if(!e||!t)return null==e&&null==t;const i=e.length;if(i!==t.length)return!1;for(let s=0;s<i;s++)if(e[s]!==t[s]&&!o?.(e[s],t[s]))return!1;return!0}function io(e,t){if(e)for(const o of e)t(o)}function so(e,t){const o=e.indexOf(t);o>=0&&e.splice(o,1)}function no(e,t,o){for(let o=0;o<t.length;o++)so(e,t[o]);for(let i=t.length-1;i>=0;i--)e.splice(o,0,t[i])}var ro="ag-Grid-AutoColumn",ao="ag-Grid-SelectionColumn",lo="ag-Grid-RowNumbersColumn";function ho(e){const t=[],o=e=>{for(let i=0;i<e.length;i++){const s=e[i];qt(s)?t.push(s):Yt(s)&&o(s.getChildren())}};return o(e),t}function co(e){return e.reduce((e,t)=>e+t.getActualWidth(),0)}function uo(e,t,o){const i={};if(!t)return;xo(null,t,e=>{i[e.getInstanceId()]=e}),o&&xo(null,o,e=>{i[e.getInstanceId()]=null});const s=Object.values(i).filter(e=>null!=e);e.context.destroyBeans(s)}function go(e){return e.getId().startsWith(ro)}function po(e){const t="string"==typeof e?e:"getColId"in e?e.getColId():e.colId;return t?.startsWith(ao)??!1}function mo(e){const t="string"==typeof e?e:"getColId"in e?e.getColId():e.colId;return t?.startsWith(lo)??!1}function fo(e){let t=[];return e instanceof Array?t=e:"string"==typeof e&&(t=e.split(",")),t}function Co(e){return"optionsUpdated"===e?"gridOptionsChanged":e}function vo(e,t){const o=e===t,i=e.getColDef()===t,s=e.getColId()==t;return o||i||s}function wo(e,t=null,o,i,s){const n=new Xt,{existingCols:r,existingGroups:a,existingColKeys:l}=function(e){const t=[],o=[],i=[];e&&xo(null,e,e=>{if(Yt(e)){const t=e;o.push(t)}else{const o=e;i.push(o.getId()),t.push(o)}});return{existingCols:t,existingGroups:o,existingColKeys:i}}(i);n.addExistingKeys(l);const d=bo(e,t,0,o,r,n,a,s),{colGroupSvc:h}=e,c=h?.findMaxDepth(d,0)??0,u=h?h.balanceColumnTree(d,0,c,n):d;return xo(null,u,(e,t)=>{Yt(e)&&e.setupExpandable(),e.originalParent=t}),{columnTree:u,treeDepth:c}}function bo(e,t,o,i,s,n,r,a){if(!t)return[];const{colGroupSvc:l}=e,d=new Array(t.length);for(let h=0;h<d.length;h++){const c=t[h];l&&Ro(c)?d[h]=l.createProvidedColumnGroup(i,c,o,s,n,r,a):d[h]=yo(e,i,c,s,n,a)}return d}function yo(e,t,o,i,s,n){const r=function(e,t){if(!t)return;for(let o=0;o<t.length;o++){const i=t[o].getUserProvidedColDef();if(!i)continue;if(null!=e.colId){if(t[o].getId()===e.colId)return{idx:o,column:t[o]};continue}if(null!=e.field){if(i.field===e.field)return{idx:o,column:t[o]}}else if(i===e)return{idx:o,column:t[o]}}return}(o,i);r&&i?.splice(r.idx,1);let a=r?.column;if(a){const t=Eo(e,o,a.getColId());a.setColDef(t,o,n),function(e,t,o,i){So(e,t,o.hide,o.sort,o.sortIndex,o.pinned,o.flex,i);const s=t.getFlex();if(null!=s&&s>0)return;if(null!=o.width)t.setActualWidth(o.width,i);else{const e=t.getActualWidth();t.setActualWidth(e,i)}}(e,a,t,n)}else{const i=s.getUniqueKey(o.colId,o.field),n=Eo(e,o,i);a=new _t(n,o,i,t),e.context.createBean(a)}return e.dataTypeSvc?.addColumnListeners(a),a}function So(e,t,o,i,s,n,r,a){const{sortSvc:l,pinnedCols:d,colFlex:h}=e;void 0!==o&&t.setVisible(!o,a),l&&(l.updateColSort(t,i,a),void 0!==s&&l.setColSortIndex(t,s)),void 0!==n&&d?.setColPinned(t,n),void 0!==r&&h?.setColFlex(t,r)}function Eo(e,t,o,i){const{gos:s,dataTypeSvc:n}=e,r={};Ge(r,s.get("defaultColDef"),!1,!0);const a=function(e,t,o,i){const s=e.dataTypeSvc?.updateColDefAndGetColumnType(t,o,i),n=o.type??s??t.type;return t.type=n,n?fo(n):void 0}(e,r,t,o);a&&function(e,t,o){if(!t.length)return;const i=Object.assign({},Zt),s=e.gos.get("columnTypes")||{};for(const e of Object.keys(s)){const t=s[e];if(e in i)st(34,{key:e});else{t.type&&st(35),i[e]=t}}t.forEach(e=>{const t=i[e.trim()];t?Ge(o,t,!1,!0):st(36,{t:e})})}(e,a,r);const l=r.cellDataType;Ge(r,t,!1,!0),void 0!==l&&(r.cellDataType=l);const d=s.get("autoGroupColumnDef"),h=yt(s);return t.rowGroup&&d&&h&&Ge(r,{sort:d.sort,initialSort:d.initialSort},!1,!0),n&&(n.postProcess(r),n.validateColDef(r)),s.validateColDef(r,o,i),r}function Ro(e){return void 0!==e.children}function xo(e,t,o){if(t)for(let i=0;i<t.length;i++){const s=t[i];Yt(s)&&xo(s,s.getChildren(),o),o(s,e)}}function Fo(e,t){const o=[],i=[],s=[];e.forEach(e=>{const t=e.getColDef().lockPosition;"right"===t?s.push(e):"left"===t||!0===t?o.push(e):i.push(e)});return t.get("enableRtl")?[...s,...i,...o]:[...o,...i,...s]}function Po(e,t){let o=!0;return xo(null,t,t=>{if(!Yt(t))return;const i=t,s=i.getColGroupDef();if(!(s&&s.marryChildren))return;const n=[];i.getLeafColumns().forEach(t=>{const o=e.indexOf(t);n.push(o)});Math.max.apply(Math,n)-Math.min.apply(Math,n)>i.getLeafColumns().length-1&&(o=!1)}),o}function Do(e,t){if(!e||0==e.length)return;const o=t(e[0]);for(let i=1;i<e.length;i++)if(o!==t(e[i]))return;return o}function Mo(e,t,o){if(!t.length)return;const i=1===t.length?t[0]:null,s=Do(t,e=>e.getPinned());e.dispatchEvent({type:"columnPinned",pinned:null!=s?s:null,columns:t,column:i,source:o})}function ko(e,t,o,i,s=null){t?.length&&e.dispatchEvent({type:"columnResized",columns:t,column:1===t.length?t[0]:null,flexColumns:s,finished:o,source:i})}function To(e,t,i){const{colModel:s,rowGroupColsSvc:n,pivotColsSvc:r,autoColSvc:a,selectionColSvc:l,colAnimation:d,visibleCols:h,pivotResultCols:c,environment:u,valueColsSvc:g,eventSvc:p,gos:m}=e,f=s.getColDefCols()??[],C=l?.getColumns();if(!f.length&&!C?.length)return!1;if(t?.state&&!t.state.forEach)return st(32),!1;const v=(s,a,l,d,h)=>{if(!s)return;const c=((e,t)=>(i,s)=>{const n={value1:void 0,value2:void 0};let r=!1;return e&&(void 0!==e[i]&&(n.value1=e[i],r=!0),o(s)&&void 0!==e[s]&&(n.value2=e[s],r=!0)),!r&&t&&(void 0!==t[i]&&(n.value1=t[i]),o(s)&&void 0!==t[s]&&(n.value2=t[s])),n})(a,t.defaultState),p=c("flex").value1;if(So(e,s,c("hide").value1,c("sort").value1,c("sortIndex").value1,c("pinned").value1,p,i),null==p){const e=c("width").value1;if(null!=e){const t=s.getColDef().minWidth??u.getDefaultColumnMinWidth();null!=t&&e>=t&&s.setActualWidth(e,i)}}!h&&s.isPrimary()&&(g?.syncColumnWithState(s,i,c),n?.syncColumnWithState(s,i,c,l),r?.syncColumnWithState(s,i,c,d))},w=(o,d,c)=>{const u=Io(e,i),g=d.slice(),f={},C={},w=[],b=[],y=[];let S=0;const E=n?.columns.slice()??[],R=r?.columns.slice()??[];o.forEach(e=>{const t=e.colId;if(t.startsWith(ro))return w.push(e),void y.push(e);if(po(t))return b.push(e),void y.push(e);const o=c(t);o?(v(o,e,f,C,!1),so(g,o)):(y.push(e),S+=1)});const x=e=>v(e,null,f,C,!1);g.forEach(x),n?.sortColumns(Bo.bind(n,f,E)),r?.sortColumns(Bo.bind(r,C,R)),s.refreshCols(!1);const F=(e,t,o=[])=>{t.forEach(t=>{const i=e(t.colId);so(o,i),v(i,t,null,null,!0)}),o.forEach(x)};return F(e=>a?.getColumn(e)??null,w,a?.getColumns()?.slice()),F(e=>l?.getColumn(e)??null,b,l?.getColumns()?.slice()),function(e,t,o){if(!e.applyOrder||!e.state)return;const i=[];e.state.forEach(e=>{null!=e.colId&&i.push(e.colId)}),function(e,t,o,i){if(null==e)return;let s=[];const n={};t.forEach(t=>{if(n[t])return;const o=e.map[t];o&&(s.push(o),n[t]=!0)});let r=0;if(e.list.forEach(e=>{const t=e.getColId();if(null!=n[t])return;t.startsWith(ro)?s.splice(r++,0,e):s.push(e)}),s=Fo(s,i),!Po(s,o.getColTree()))return void st(39);e.list=s}(t.cols,i,t,o)}(t,s,m),h.refresh(i),p.dispatchEvent({type:"columnEverythingChanged",source:i}),u(),{unmatchedAndAutoStates:y,unmatchedCount:S}};d?.start();let{unmatchedAndAutoStates:b,unmatchedCount:y}=w(t.state||[],f,e=>s.getColDefCol(e));if(b.length>0||o(t.defaultState)){y=w(b,c?.getPivotResultCols()?.list??[],e=>c?.getPivotResultCol(e)??null).unmatchedCount}return d?.finish(),0===y}function Io(e,t){const{rowGroupColsSvc:o,pivotColsSvc:i,valueColsSvc:s,colModel:n,sortSvc:r,eventSvc:a}=e,l={rowGroupColumns:o?.columns.slice()??[],pivotColumns:i?.columns.slice()??[],valueColumns:s?.columns.slice()??[]},d=Ao(e),h={};return d.forEach(e=>{h[e.colId]=e}),()=>{const s=(e,o,i,s)=>{if(oo(o.map(s),i.map(s)))return;const n=new Set(o);i.forEach(e=>{n.delete(e)||n.add(e)});const r=[...n];a.dispatchEvent({type:e,columns:r,column:1===r.length?r[0]:null,source:t})},c=e=>{const t=[];return n.forAllCols(o=>{const i=h[o.getColId()];i&&e(i,o)&&t.push(o)}),t},u=e=>e.getColId();s("columnRowGroupChanged",l.rowGroupColumns,o?.columns??[],u),s("columnPivotChanged",l.pivotColumns,i?.columns??[],u);const g=c((e,t)=>{const o=null!=e.aggFunc,i=o!=t.isValueActive(),s=o&&e.aggFunc!=t.getAggFunc();return i||s});g.length>0&&function(e,t,o,i){e.dispatchEvent({type:t,columns:o,column:o&&1==o.length?o[0]:null,source:i})}(a,"columnValueChanged",g,t);ko(a,c((e,t)=>e.width!=t.getActualWidth()),!0,t);Mo(a,c((e,t)=>e.pinned!=t.getPinned()),t);!function(e,t,o){if(!t.length)return;const i=1===t.length?t[0]:null,s=Do(t,e=>e.isVisible());e.dispatchEvent({type:"columnVisible",visible:s,columns:t,column:i,source:o})}(a,c((e,t)=>e.hide==t.isVisible()),t);const p=c((e,t)=>e.sort!=t.getSort()||e.sortIndex!=t.getSortIndex());p.length>0&&r?.dispatchSortChangedEvents(t,p);const m=Ao(e);!function(e,t,o,i,s){const n={};t.forEach(e=>n[e.colId]=e);const r={};e.forEach(e=>{n[e.colId]&&(r[e.colId]=!0)});const a=e.filter(e=>r[e.colId]),l=t.filter(e=>r[e.colId]),d=[];if(l.forEach((e,t)=>{const o=a&&a[t];if(o&&o.colId!==e.colId){const e=i.getCol(o.colId);e&&d.push(e)}}),!d.length)return;s.dispatchEvent({type:"columnMoved",columns:d,column:1===d.length?d[0]:null,finished:!0,source:o})}(d,m,t,n,a)}}function Ao(e){const{colModel:t,rowGroupColsSvc:o,pivotColsSvc:s}=e;if(i(t.getColDefCols())||!t.isAlive())return[];const n=o?.columns,r=s?.columns,a=[];t.forAllCols(e=>(e=>{const t=e.isRowGroupActive()&&n?n.indexOf(e):null,o=e.isPivotActive()&&r?r.indexOf(e):null,i=e.isValueActive()?e.getAggFunc():null,s=null!=e.getSort()?e.getSort():null,l=null!=e.getSortIndex()?e.getSortIndex():null;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:o,flex:e.getFlex()??null})})(e));const l=new Map(t.getCols().map((e,t)=>[e.getColId(),t]));return a.sort((e,t)=>(l.has(e.colId)?l.get(e.colId):-1)-(l.has(t.colId)?l.get(t.colId):-1)),a}function Lo(e){const t=(e,t)=>null!=e?e:null!=t?t:null,o=e.getColDef(),i=t(o.sort,o.initialSort),s=t(o.sortIndex,o.initialSortIndex),n=t(o.hide,o.initialHide),r=t(o.pinned,o.initialPinned),a=t(o.width,o.initialWidth),l=t(o.flex,o.initialFlex);let d=t(o.rowGroupIndex,o.initialRowGroupIndex),h=t(o.rowGroup,o.initialRowGroup);null!=d||null!=h&&0!=h||(d=null,h=null);let c=t(o.pivotIndex,o.initialPivotIndex),u=t(o.pivot,o.initialPivot);null!=c||null!=u&&0!=u||(c=null,u=null);const g=t(o.aggFunc,o.initialAggFunc);return{colId:e.getColId(),sort:i,sortIndex:s,hide:n,pinned:r,width:a,flex:l,rowGroup:h,rowGroupIndex:d,pivot:u,pivotIndex:c,aggFunc:g}}var Bo=(e,t,o,i)=>{const s=e[o.getId()],n=e[i.getId()],r=null!=s,a=null!=n;if(r&&a)return s-n;if(r)return-1;if(a)return 1;const l=t.indexOf(o),d=t.indexOf(i),h=l>=0;return h&&d>=0?l-d:h?-1:1},Ho=class{constructor(){this.existingIds={}}getInstanceIdForKey(e){const t=this.existingIds[e];let o;return o="number"!=typeof t?0:t+1,this.existingIds[e]=o,o}};function Vo(e,t,o){return o&&e.addDestroyFunc(()=>t.destroyBean(o)),o??e}var Go=null;function No(e){return"function"==typeof e?.getGui}var Oo=class{constructor(e){this.cssClassStates={},this.getGui=e}toggleCss(e,t){if(!e)return;if(e.indexOf(" ")>=0){const o=(e||"").split(" ");if(o.length>1)return void o.forEach(e=>this.toggleCss(e,t))}this.cssClassStates[e]!==t&&e.length&&(this.getGui()?.classList.toggle(e,t),this.cssClassStates[e]=t)}},zo=0,Wo=class extends De{constructor(e,t){super(),this.suppressDataRefValidation=!1,this.displayed=!0,this.visible=!0,this.compId=zo++,this.cssManager=new Oo(()=>this.eGui),this.componentSelectors=new Map((t??[]).map(e=>[e.selector,e])),e&&this.setTemplate(e)}preConstruct(){this.wireTemplate(this.getGui());const e="component-"+Object.getPrototypeOf(this)?.constructor?.name;this.css?.forEach(t=>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(pe):null}applyElementsToComponent(e,t,o,i=null){if(void 0===t&&(t=this.getDataRefAttribute(e)),t){const s=this[t];if(s===Go)this[t]=i??e;else{const e=o&&o[t];if(!this.suppressDataRefValidation&&!e)throw new Error(`data-ref: ${t} on ${this.constructor.name} with ${s}`)}}}createChildComponentsFromTags(e,t){const o=[];for(const t of e.childNodes??[])o.push(t);o.forEach(o=>{if(!(o instanceof HTMLElement))return;const i=this.createComponentFromElement(o,e=>{const t=e.getGui();if(t)for(const e of o.attributes??[])t.setAttribute(e.name,e.value)},t);if(i){if(i.addItems&&o.children.length){this.createChildComponentsFromTags(o,t);const e=Array.prototype.slice.call(o.children);i.addItems(e)}this.swapComponentForNode(i,e,o)}else o.childNodes&&this.createChildComponentsFromTags(o,t)})}createComponentFromElement(e,t,o){const i=e.nodeName,s=this.getDataRefAttribute(e),n=0===i.indexOf("AG-"),r=n?this.componentSelectors.get(i):null;let a=null;if(r){const e=o&&s?o[s]:void 0;a=new r.component(e),a.setParentComponent(this),this.createBean(a,null,t)}else if(n)throw new Error(`selector: ${i}`);return this.applyElementsToComponent(e,s,o,a),a}swapComponentForNode(e,t,o){const i=e.getGui();t.replaceChild(i,o),t.insertBefore(document.createComment(o.nodeName),i),this.addDestroyFunc(this.destroyBean.bind(this,e))}activateTabIndex(e){const t=this.gos.get("tabIndex");e||(e=[]),e.length||e.push(this.getGui()),e.forEach(e=>e.setAttribute("tabindex",t.toString()))}setTemplate(e,t,o){let i;i="string"==typeof e||null==e?Z(e):fe(e),this.setTemplateFromElement(i,t,o)}setTemplateFromElement(e,t,o,i=!1){if(this.eGui=e,this.suppressDataRefValidation=i,t)for(let e=0;e<t.length;e++){const o=t[e];this.componentSelectors.set(o.selector,o)}this.wireTemplate(e,o)}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 o=t;return null==e?null:(o||(o=this.eGui),de(e)?{element:e,parent:o}:{element:e.getGui(),parent:o})}prependChild(e,t){const{element:o,parent:i}=this.getContainerAndElement(e,t)||{};o&&i&&i.insertAdjacentElement("afterbegin",o)}appendChild(e,t){const{element:o,parent:i}=this.getContainerAndElement(e,t)||{};o&&i&&i.appendChild(o)}isDisplayed(){return this.displayed}setVisible(e,t={}){if(e!==this.visible){this.visible=e;const{skipAriaHidden:o}=t;!function(e,t,o={}){const{skipAriaHidden:i}=o;e.classList.toggle("ag-invisible",!t),i||F(e,!t)}(this.eGui,e,{skipAriaHidden:o})}}setDisplayed(e,t={}){if(e!==this.displayed){this.displayed=e;const{skipAriaHidden:o}=t;H(this.eGui,e,{skipAriaHidden:o});const i={type:"displayChanged",visible:this.displayed};this.dispatchLocalEvent(i)}}destroy(){this.parentComponent&&(this.parentComponent=void 0),super.destroy()}addGuiEventListener(e,t,o){this.eGui.addEventListener(e,t,o),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)}},Uo=class extends Wo{};function $o(e){return"object"==typeof e&&!!e.component}var Ko=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 o=t.length;const i=new Array(o);t.forEach((t,s)=>{t.then(t=>{i[s]=t,o--,0===o&&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(o=>e(t(o)))})}onDone(e){this.status=1,this.resolution=e,this.waiters.forEach(t=>t(e))}onReject(e){}};function jo(e,t,o,i){const{name:s}=o;let n,r,a,l,d,h;if(t){const o=t,c=o[s+"Selector"],u=c?c(i):null,g=t=>{if("string"==typeof t)n=t;else if(null!=t&&!0!==t){e.isFrameworkComponent(t)?a=t:r=t}};u?(g(u.component),l=u.params,d=u.popup,h=u.popupPosition):g(o[s])}return{compName:n,jsComp:r,fwComp:a,paramsFromSelector:l,popupFromSelector:d,popupPositionFromSelector:h}}var qo={name:"dateComponent",mandatoryMethods:["getDate","setDate"],optionalMethods:["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled","refresh"]},_o={name:"dragAndDropImageComponent",mandatoryMethods:["setIcon","setLabel"]},Yo={name:"headerComponent",optionalMethods:["refresh"]},Qo={name:"innerHeaderComponent"},Zo={name:"innerHeaderGroupComponent"},Jo={name:"headerGroupComponent"},Xo={name:"cellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},ei={name:"loadingCellRenderer",cellRenderer:!0},ti={name:"cellEditor",mandatoryMethods:["getValue"],optionalMethods:["isPopup","isCancelBeforeStart","isCancelAfterEnd","getPopupPosition","focusIn","focusOut","afterGuiAttached","refresh"]},oi={name:"loadingOverlayComponent",optionalMethods:["refresh"]},ii={name:"noRowsOverlayComponent",optionalMethods:["refresh"]},si={name:"tooltipComponent"},ni={name:"filter",mandatoryMethods:["isFilterActive","doesFilterPass","getModel","setModel"],optionalMethods:["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onFloatingFilterChanged","onAnyFilterChanged","refresh"]},ri={name:"floatingFilterComponent",mandatoryMethods:["onParentModelChanged"],optionalMethods:["afterGuiAttached","refresh"]},ai={name:"fullWidthCellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},li={name:"loadingCellRenderer",cellRenderer:!0},di={name:"groupRowRenderer",optionalMethods:["afterGuiAttached"],cellRenderer:!0},hi={name:"detailCellRenderer",optionalMethods:["refresh"],cellRenderer:!0};function ci(e,t,o){return e.getCompDetails(t,Xo,void 0,o)}function ui(e,t,o){return e.getCompDetails(t,ei,"agSkeletonCellRenderer",o,!0)}function gi(e,t,o){return e.getCompDetails(t,ti,"agCellEditor",o,!0)}function pi(e,t){return jo(e,t,ni)}function mi(e,t,o){return e.mergeParams(t,ni,o)}function fi(e){const t=e;return null!=t&&null!=t.getFrameworkComponentInstance?t.getFrameworkComponentInstance():e}function Ci(e){return"object"==typeof e&&!!e.getComp}var vi,wi,bi,yi,Si,Ei,Ri,xi="Backspace",Fi="Tab",Pi="Enter",Di="Escape",Mi=" ",ki="ArrowLeft",Ti="ArrowUp",Ii="ArrowRight",Ai="ArrowDown",Li="Delete",Bi="F2",Hi="PageUp",Vi="PageDown",Gi="Home",Ni="End",Oi="KeyA",zi="KeyC",Wi="KeyD",Ui="KeyV",$i="KeyX",Ki="KeyY",ji="KeyZ",qi=class extends Wo{isPopup(){return!0}setParentComponent(e){e.addCss("ag-has-popup"),super.setParentComponent(e)}destroy(){const e=this.parentComponent;e&&e.isAlive()&&e.getGui().classList.remove("ag-has-popup"),super.destroy()}};function _i(){return void 0===vi&&(vi=/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),vi}function Yi(){return void 0===wi&&(wi=/(firefox)/i.test(navigator.userAgent)),wi}function Qi(){return void 0===bi&&(bi=/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform)),bi}function Zi(){return void 0===yi&&(yi=/iPad|iPhone|iPod/.test(navigator.platform)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1),yi}function Ji(e){if(!e)return null;const t=e.tabIndex,o=e.getAttribute("tabIndex");return-1!==t||null!==o&&(""!==o||Yi())?t.toString():null}function Xi(){const 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 o=t.offsetWidth-t.clientWidth;0===o&&0===t.clientWidth&&(o=null),t.parentNode&&t.parentNode.removeChild(t),null!=o&&(Ei=o,Si=0===o)}function es(){return null==Si&&Xi(),Si}var ts=new RegExp("[T ]"),os=new RegExp("^\\d{4}-\\d{2}-\\d{2}(T\\d{2}:\\d{2}:\\d{2}\\D?)?");function is(e,t){return e.toString().padStart(t,"0")}function ss(e,t=!0,o="T"){if(!e)return null;let i=[e.getFullYear(),e.getMonth()+1,e.getDate()].map(e=>is(e,2)).join("-");return t&&(i+=o+[e.getHours(),e.getMinutes(),e.getSeconds()].map(e=>is(e,2)).join(":")),i}function ns(e,t=!0){return e?t?[String(e.getFullYear()),String(e.getMonth()+1),is(e.getDate(),2),is(e.getHours(),2),`:${is(e.getMinutes(),2)}`,`:${is(e.getSeconds(),2)}`]:[e.getFullYear(),e.getMonth()+1,is(e.getDate(),2)].map(String):null}var rs=e=>{if(e>3&&e<21)return"th";switch(e%10){case 1:return"st";case 2:return"nd";case 3:return"rd"}return"th"},as=["January","February","March","April","May","June","July","August","September","October","November","December"],ls=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function ds(e,t){if(null==t)return ss(e,!1);const o=is(e.getFullYear(),4),i={YYYY:()=>o.slice(o.length-4,o.length),YY:()=>o.slice(o.length-2,o.length),Y:()=>`${e.getFullYear()}`,MMMM:()=>as[e.getMonth()],MMM:()=>as[e.getMonth()].slice(0,3),MM:()=>is(e.getMonth()+1,2),Mo:()=>`${e.getMonth()+1}${rs(e.getMonth()+1)}`,M:()=>`${e.getMonth()+1}`,Do:()=>`${e.getDate()}${rs(e.getDate())}`,DD:()=>is(e.getDate(),2),D:()=>`${e.getDate()}`,dddd:()=>ls[e.getDay()],ddd:()=>ls[e.getDay()].slice(0,3),dd:()=>ls[e.getDay()].slice(0,2),do:()=>`${e.getDay()}${rs(e.getDay())}`,d:()=>`${e.getDay()}`},s=new RegExp(Object.keys(i).join("|"),"g");return t.replace(s,e=>e in i?i[e]():e)}function hs(e,t=!1){return!!cs(e,t)}function cs(e,t=!1,o){if(!e)return null;if(!o&&!os.test(e))return null;const[i,s]=e.split(ts);if(!i)return null;const n=i.split("-").map(e=>parseInt(e,10));if(3!==n.filter(e=>!isNaN(e)).length)return null;const[r,a,l]=n,d=new Date(r,a-1,l);if(d.getFullYear()!==r||d.getMonth()!==a-1||d.getDate()!==l)return null;if(!s&&t)return null;if(!s||"00:00:00"===s)return d;const[h,c,u]=s.split(":").map(e=>parseInt(e,10));if(h>=0&&h<24)d.setHours(h);else if(t)return null;if(c>=0&&c<60)d.setMinutes(c);else if(t)return null;if(u>=0&&u<60)d.setSeconds(u);else if(t)return null;return d}function us(e){const{inputValue:t,allSuggestions:o,hideIrrelevant:i,filterByPercentageOfBestMatch:s}=e;let n=(o??[]).map((e,o)=>({value:e,relevance:gs(t,e),idx:o}));if(n.sort((e,t)=>e.relevance-t.relevance),i&&(n=n.filter(e=>e.relevance<Math.max(e.value.length,t.length))),n.length>0&&s&&s>0){const e=n[0].relevance*s;n=n.filter(t=>e-t.relevance<0)}const r=[],a=[];for(const e of n)r.push(e.value),a.push(e.idx);return{values:r,indices:a}}function gs(e,t){e.length<t.length&&([e,t]=[t,e]);let o=[],i=[];const s=e.length,n=t.length;for(let e=0;e<=n;e++)o[e]=e;let r=0;for(let a=1;a<=s;a++){i[0]=a;for(let l=1;l<=n;l++){const n=e[a-1],d=t[l-1];if(n.toLocaleLowerCase()===d.toLocaleLowerCase())++r,n===d&&++r,a>1&&l>1&&e[a-2].toLocaleLowerCase()===t[l-2].toLocaleLowerCase()&&(++r,e[a-2]===t[l-2]&&++r),a<s/2-10&&++r,i[l]=o[l-1];else{const e=i[l-1],t=o[l],s=o[l-1];i[l]=1+Math.min(e,t,s)}}[o,i]=[i,o]}return o[n]/(r+1)}function ps(e){if(e.altKey||e.ctrlKey||e.metaKey)return!1;return 1===e.key?.length}var ms=!1,fs=0;function Cs(e){const t=ms,o="keydown"===e.type;o&&(e.ctrlKey||e.metaKey||e.altKey)||t!==o&&(ms=o)}function vs(e){const t=g(e);var o;return o=t,fs>0||(o.addEventListener("keydown",Cs),o.addEventListener("mousedown",Cs)),fs++,()=>{fs--,function(e){fs>0||(e.removeEventListener("keydown",Cs),e.removeEventListener("mousedown",Cs))}(t)}}function ws(e,t,o=!1){let i=L;t&&(i+=", "+t),o&&(i+=', [tabindex="-1"]');const s=Array.prototype.slice.apply(e.querySelectorAll("[tabindex], input, select, button, textarea, [href]")).filter(e=>Q(e)),n=Array.prototype.slice.apply(e.querySelectorAll(i));if(!n.length)return s;return r=n,s.filter(e=>-1===r.indexOf(e));var r}function bs(e,t=!1,o=!1,i=!1){const s=ws(e,i?".ag-tab-guard":null,o),n=t?to(s):s[0];return!!n&&(n.focus({preventScroll:!0}),!0)}function ys(e,t,o,i){const s=ws(t,o?':not([tabindex="-1"])':null),n=u(e);let r;r=o?s.findIndex(e=>e.contains(n)):s.indexOf(n);const a=r+(i?-1:1);return a<0||a>=s.length?null:s[a]}function Ss(e,t=5){let o=0;for(;e&&null===Ji(e)&&++o<=t;)e=e.parentElement;return null===Ji(e)?null:e}var Es=class extends Wo{constructor(e,t,o){super(t,o),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");const{labelSeparator:e,label:t,labelWidth:o,labelAlignment:i,disabled:s}=this.config;null!=s&&this.setDisabled(s),null!=e&&this.setLabelSeparator(e),null!=t&&this.setLabel(t),null!=o&&this.setLabelWidth(o),this.setLabelAlignment(i||this.labelAlignment),this.refreshLabel()}refreshLabel(){const{label:e,eLabel:t}=this;q(t),"string"==typeof e?t.innerText=e+this.labelSeparator:e&&t.appendChild(e),""===e?(H(t,!1),y(t,"presentation")):(H(t,!0),y(t,null))}setLabelSeparator(e){return this.labelSeparator===e||(this.labelSeparator=e,null!=this.label&&this.refreshLabel()),this}getLabelId(){const 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){const 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||ne(this.eLabel,e),this}setDisabled(e){e=!!e;const t=this.getGui();return V(t,e),t.classList.toggle("ag-disabled",e),this.disabled=e,this}isDisabled(){return!!this.disabled}},Rs=class extends Es{constructor(e,t,o,i){super(e,t,o),this.className=i}postConstruct(){super.postConstruct();const{width:e,value:t,onValueChange:o}=this.config;null!=e&&this.setWidth(e),null!=t&&this.setValue(t),null!=o&&this.onValueChange(o),this.className&&this.addCss(this.className),this.refreshAriaLabelledBy()}setLabel(e){return super.setLabel(e),this.refreshAriaLabelledBy(),this}refreshAriaLabelledBy(){const e=this.getAriaElement(),t=this.getLabelId(),o=this.getLabel();null==o||""==o||null!==e.getAttribute("aria-label")?E(e,""):E(e,t??"")}setAriaLabel(e){return S(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 re(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}};var xs,Fs,Ps=class extends Rs{constructor(e,t,o="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=o,this.displayFieldTag=i,this.eLabel=Go,this.eWrapper=Go,this.eInput=Go}postConstruct(){super.postConstruct(),this.setInputType(this.inputType);const{eLabel:e,eWrapper:t,eInput:o,className:i}=this;e.classList.add(`${i}-label`),t.classList.add(`${i}-input-wrapper`),o.classList.add(`${i}-input`),this.addCss("ag-input-field"),o.id=o.id||`ag-${this.getCompId()}-input`;const{inputName:s,inputWidth:n}=this.config;null!=s&&this.setInputName(s),null!=n&&this.setInputWidth(n),this.addInputListeners(),this.activateTabIndex([o])}addInputListeners(){this.addManagedElementListeners(this.eInput,{input:e=>this.setValue(e.target.value)})}setInputType(e){"input"===this.displayFieldTag&&(this.inputType=e,he(this.eInput,"type",e))}getInputElement(){return this.eInput}setInputWidth(e){return ne(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 he(this.eInput,"placeholder",e),this}setInputAriaLabel(e){return S(this.eInput,e),this.refreshAriaLabelledBy(),this}setDisabled(e){return V(this.eInput,e),super.setDisabled(e)}setAutoComplete(e){if(!0===e)he(this.eInput,"autocomplete",null);else{const t="string"==typeof e?e:"off";he(this.eInput,"autocomplete",t)}return this}},Ds=class extends Ps{constructor(e,t="ag-checkbox",o="checkbox"){super(e,t,o),this.labelAlignment="right",this.selected=!1,this.readOnly=!1,this.passive=!1}postConstruct(){super.postConstruct();const{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;const 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;const o=this.eInput;o.checked=e,o.indeterminate=void 0===e,t||this.dispatchChange(this.selected,this.previousValue)}dispatchChange(e,t,o){this.dispatchLocalEvent({type:"fieldValueChanged",selected:e,previousValue:t,event:o});const 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;const t=this.isSelected(),o=this.selected=e.target.checked;this.refreshSelectedClass(o),this.dispatchChange(o,t,e)}refreshSelectedClass(e){const t=this.eWrapper.classList;t.toggle("ag-checked",!0===e),t.toggle("ag-indeterminate",null==e)}},Ms={selector:"AG-CHECKBOX",component:Ds},ks=class extends Ds{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){const t=this.eInput;e.selected&&e.name&&t.name&&t.name===e.name&&e.id&&t.id!==e.id&&this.setValue(!1,!0)}},Ts=class extends Ps{constructor(e,t="ag-text-field",o="text"){super(e,t,o)}postConstruct(){super.postConstruct(),this.config.allowedCharPattern&&this.preventDisallowedCharacters()}setValue(e,t){const i=this.eInput;return i.value!==e&&(i.value=o(e)?e:""),super.setValue(e,t)}setStartValue(e){this.setValue(e,!0)}preventDisallowedCharacters(){const e=new RegExp(`[${this.config.allowedCharPattern}]`);this.addManagedListeners(this.eInput,{keydown:t=>{ps(t)&&t.key&&!e.test(t.key)&&t.preventDefault()},paste:t=>{const o=t.clipboardData?.getData("text");o&&o.split("").some(t=>!e.test(t))&&t.preventDefault()}})}},Is={selector:"AG-INPUT-TEXT-FIELD",component:Ts},As={selector:"AG-INPUT-TEXT-AREA",component:class extends Ps{constructor(e){super(e,"ag-text-area",null,"textarea")}setValue(e,t){const o=super.setValue(e,t);return this.eInput.value=e,o}setCols(e){return this.eInput.cols=e,this}setRows(e){return this.eInput.rows=e,this}}},Ls=class extends Ts{constructor(e){super(e,"ag-number-field","number")}postConstruct(){super.postConstruct();const e=this.eInput;this.addManagedListeners(e,{blur:()=>{const t=parseFloat(e.value),o=isNaN(t)?"":this.normalizeValue(t.toString());this.value!==o&&this.setValue(o)},wheel:this.onWheel.bind(this)}),e.step="any";const{precision:t,min:o,max:i,step:s}=this.config;"number"==typeof t&&this.setPrecision(t),"number"==typeof o&&this.setMin(o),"number"==typeof i&&this.setMax(i),"number"==typeof s&&this.setStep(s)}onWheel(e){u(this.beans)===this.eInput&&e.preventDefault()}normalizeValue(e){return""===e?"":(null!=this.precision&&(e=this.adjustPrecision(e)),e)}adjustPrecision(e,t){const o=this.precision;if(null==o)return e;if(t){const t=parseFloat(e).toFixed(o);return parseFloat(t).toString()}const i=String(e).split(".");if(i.length>1){if(i[1].length<=o)return e;if(o>0)return`${i[0]}.${i[1].slice(0,o)}`}return i[0]}setMin(e){return this.min===e||(this.min=e,he(this.eInput,"min",e)),this}setMax(e){return this.max===e||(this.max=e,he(this.eInput,"max",e)),this}setPrecision(e){return this.precision=e,this}setStep(e){return this.step===e||(this.step=e,he(this.eInput,"step",e)),this}setValue(e,t){return this.setValueOrInputValue(e=>super.setValue(e,t),()=>this,e)}setStartValue(e){return this.setValueOrInputValue(e=>super.setValue(e,!0),e=>{this.eInput.value=e},e)}setValueOrInputValue(e,t,i){if(o(i)){let o=this.isScientificNotation(i);if(o&&this.eInput.validity.valid)return e(i);if(!o){o=(i=this.adjustPrecision(i))!=this.normalizeValue(i)}if(o)return t(i)}return e(i)}getValue(){const e=this.eInput;if(!e.validity.valid)return;const t=e.value;return this.isScientificNotation(t)?this.adjustPrecision(t,!0):super.getValue()}isScientificNotation(e){return"string"==typeof e&&e.includes("e")}},Bs={selector:"AG-INPUT-NUMBER-FIELD",component:Ls},Hs={selector:"AG-INPUT-DATE-FIELD",component:class extends Ts{constructor(e){super(e,"ag-date-field","date")}postConstruct(){super.postConstruct();const e=_i();this.addManagedListeners(this.eInput,{wheel:this.onWheel.bind(this),mousedown:()=>{this.isDisabled()||e||this.eInput.focus()}}),this.eInput.step="any"}onWheel(e){u(this.beans)===this.eInput&&e.preventDefault()}setMin(e){const t=e instanceof Date?ss(e??null,!!this.includeTime)??void 0:e;return this.min===t||(this.min=t,he(this.eInput,"min",t)),this}setMax(e){const t=e instanceof Date?ss(e??null,!!this.includeTime)??void 0:e;return this.max===t||(this.max=t,he(this.eInput,"max",t)),this}setStep(e){return this.step===e||(this.step=e,he(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 cs(this.getValue())??void 0}setDate(e,t){this.setValue(ss(e??null,this.includeTime),t)}}},Vs=class extends Wo{constructor(e,t,o){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=o,this.eText=Go}postConstruct(){this.createTooltip(),this.addEventListeners()}setHighlighted(e){const t=this.getGui();t.classList.toggle("ag-active-item",e),k(t,e),this.dispatchLocalEvent({type:"itemHighlighted",highlighted:e})}getHeight(){return this.getGui().clientHeight}setIndex(e,t){const o=this.getGui();v(o,"posinset",e),function(e,t){v(e,"setsize",t)}(o,t)}createTooltip(){const e={getTooltipValue:()=>this.label,getGui:()=>this.getGui(),getLocation:()=>"UNKNOWN",shouldDisplayTooltip:()=>ie(this.eText)},t=this.createOptionalManagedBean(this.beans.registry.createDynamicBean("highlightTooltipFeature",!1,e,this));t&&(this.tooltipFeature=t)}addEventListeners(){const e=this.getParentComponent();e&&(this.addGuiEventListener("mouseover",()=>{e.highlightItem(this)}),this.addGuiEventListener("mousedown",t=>{t.preventDefault(),t.stopPropagation(),e.setValue(this.value)}))}},Gs=class extends Wo{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(){const e=this.getGui();this.addManagedElementListeners(e,{mouseleave:()=>this.clearHighlighted()})}handleKeyDown(e){const t=e.key;switch(t){case Pi:if(this.highlightedItem){const e=this.listItems.indexOf(this.highlightedItem);this.setValueByIndex(e)}else this.setValue(this.getValue());break;case Ai:case Ti:e.preventDefault(),this.navigate(t);break;case Vi:case Hi:case Gi:case Ni:e.preventDefault(),this.navigateToPage(t)}}addOptions(e){return e.forEach(e=>this.addOption(e)),this}addOption(e){const{value:t,text:o}=e,i=o??t;return this.options.push({value:t,text:i}),this.renderOption(t,i),this.updateIndices(),this}clearOptions(){this.options=[],this.reset(!0),this.listItems.forEach(e=>{e.destroy()}),q(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;const o=this.options.findIndex(t=>t.value===e);if(-1!==o){const e=this.options[o];this.value=e.value,this.displayValue=e.text,this.highlightItem(this.listItems[o]),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();const e=this.options.findIndex(e=>e.value===this.value);-1!==e&&this.highlightItem(this.listItems[e])}highlightItem(e){const t=e.getGui();if(!Q(t))return;this.clearHighlighted(),e.setHighlighted(!0),this.highlightedItem=e;const o=this.getGui(),{scrollTop:i,clientHeight:s}=o,{offsetTop:n,offsetHeight:r}=t;(n+r>i+s||n<i)&&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){const o=new Vs(this.cssIdentifier,t,e);o.setParentComponent(this);const i=this.createManagedBean(o);this.listItems.push(i),this.getGui().appendChild(i.getGui())}navigate(e){const t=e===Ai;let o;const{listItems:i,highlightedItem:s}=this;if(s){let e=i.indexOf(s)+(t?1:-1);e=Math.min(Math.max(e,0),i.length-1),o=i[e]}else o=t?i[0]:to(i);this.highlightItem(o)}navigateToPage(e){const{listItems:t,highlightedItem:o}=this;if(!o||0===t.length)return;const i=t.indexOf(o),s=this.options.length-1,n=t[0].getHeight(),r=Math.floor(this.getGui().clientHeight/n);let a=-1;e===Gi?a=0:e===Ni?a=s:e===Vi?a=Math.min(i+r,s):e===Hi&&(a=Math.max(i-r,0)),-1!==a&&this.highlightItem(t[a])}refreshAriaRole(){y(this.getGui(),0===this.options.length?"presentation":"listbox")}updateIndices(){this.refreshAriaRole();const e=this.listItems,t=e.length;e.forEach((e,o)=>{e.setIndex(o+1,t)})}fireChangeEvent(){this.dispatchLocalEvent({type:"fieldValueChanged"}),this.fireItemSelected()}fireItemSelected(){this.dispatchLocalEvent({type:"selectedItem"})}},Ns={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"}}]}]},Os=class extends Rs{constructor(e){if(super(e,e?.template||Ns,e?.agComponents||[],e?.className),this.isPickerDisplayed=!1,this.skipClick=!1,this.pickerGap=4,this.hideCurrentPicker=null,this.eLabel=Go,this.eWrapper=Go,this.eDisplayField=Go,this.eIcon=Go,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:o,variableWidth:i,minPickerWidth:s,maxPickerWidth:n}=e;null!=t&&(this.pickerGap=t),this.variableWidth=!!i,null!=o&&this.setPickerMaxHeight(o),null!=s&&this.setPickerMinWidth(s),null!=n&&this.setPickerMaxWidth(n)}postConstruct(){super.postConstruct(),this.setupAria();const e=`ag-${this.getCompId()}-display`;this.eDisplayField.setAttribute("id",e);const 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)});const{pickerIcon:o,inputWidth:i}=this.config;if(o){const e=this.beans.iconSvc.createIconNoSpan(o);e&&this.eIcon.appendChild(e)}null!=i&&this.setInputWidth(i)}setupAria(){const e=this.getAriaElement();e.setAttribute("tabindex",this.gos.get("tabIndex").toString()),P(e,!1),this.ariaRole&&y(e,this.ariaRole)}onLabelOrWrapperMouseDown(e){if(e){const t=this.getFocusableElement();if(t!==this.eWrapper&&e?.target===t)return;e.preventDefault(),this.getFocusableElement().focus()}this.skipClick?this.skipClick=!1:this.isDisabled()||(this.isPickerDisplayed?this.hidePicker():this.showPicker())}onKeyDown(e){switch(e.key){case Ti:case Ai:case Pi:case Mi:e.preventDefault(),this.onLabelOrWrapperMouseDown();break;case Di:this.isPickerDisplayed&&(e.preventDefault(),e.stopPropagation(),this.hideCurrentPicker&&this.hideCurrentPicker())}}showPicker(){this.isPickerDisplayed=!0,this.pickerComponent||(this.pickerComponent=this.createPickerComponent());const e=this.pickerComponent.getGui();e.addEventListener("focusin",this.onPickerFocusIn),e.addEventListener("focusout",this.onPickerFocusOut),this.hideCurrentPicker=this.renderAndPositionPicker(),this.toggleExpandedStyles(!0)}renderAndPositionPicker(){const e=this.pickerComponent.getGui();this.gos.get("suppressScrollWhenPopupsAreOpen")||([this.destroyMouseWheelFunc]=this.addManagedEventListeners({bodyScroll:()=>{this.hidePicker()}}));const t=this.getLocaleTextFunc(),{config:{pickerAriaLabelKey:o,pickerAriaLabelValue:i,modalPicker:s=!0},maxPickerHeight:n,minPickerWidth:r,maxPickerWidth:a,variableWidth:l,beans:d,eWrapper:h}=this,c={modal:s,eChild:e,closeOnEsc:!0,closedCallback:()=>{const e=p(d);this.beforeHidePicker(),e&&this.isAlive()&&this.getFocusableElement().focus()},ariaLabel:t(o,i),anchorToElement:h};e.style.position="absolute";const u=d.popupSvc,g=u.addPopup(c);l?(r&&(e.style.minWidth=r),e.style.width=le(U(h)),a&&(e.style.maxWidth=a)):ne(e,a??U(h));const m=n??`${O(u.getPopupParent())}px`;return e.style.setProperty("max-height",m),this.alignPickerToComponent(),g.hideFunc}alignPickerToComponent(){if(!this.pickerComponent)return;const{pickerGap:e,config:{pickerType:t},beans:{popupSvc:o,gos:i},eWrapper:s,pickerComponent:n}=this,r=i.get("enableRtl")?"right":"left";o.positionPopupByComponent({type:t,eventSource:s,ePopup:n.getGui(),position:"under",alignSide:r,keepWithinBounds:!0,nudgeY:e})}beforeHidePicker(){this.destroyMouseWheelFunc&&(this.destroyMouseWheelFunc(),this.destroyMouseWheelFunc=void 0),this.toggleExpandedStyles(!1);const 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;P(this.getAriaElement(),e);const 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 ne(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()}},zs=class extends Os{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:oe(()=>this.eDisplayField),getGui:()=>this.getGui()})),super.postConstruct(),this.createListComponent(),this.eWrapper.tabIndex=this.gos.get("tabIndex");const{options:e,value:t,placeholder:o}=this.config;null!=e&&this.addOptions(e),null!=t&&this.setValue(t,!0),o&&null==t&&(this.eDisplayField.textContent=o),this.addManagedElementListeners(this.eWrapper,{focusout:this.onWrapperFocusOut.bind(this)})}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}createListComponent(){const e=this.createBean(new Gs("select"));this.listComponent=e,e.setParentComponent(this);const t=e.getAriaElement(),o=`ag-select-list-${e.getCompId()}`;t.setAttribute("id",o),T(this.getAriaElement(),t),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){const{key:t}=e;switch(t===Fi&&this.hidePicker(),t){case Pi:case Ti:case Ai:case Hi:case Vi:case Gi:case Ni:e.preventDefault(),this.isPickerDisplayed?this.listComponent?.handleKeyDown(e):super.onKeyDown(e);break;case Di:super.onKeyDown(e);break;case Mi:this.isPickerDisplayed?e.preventDefault():super.onKeyDown(e)}}showPicker(){const e=this.listComponent;e&&(super.showPicker(),e.refreshHighlighted())}addOptions(e){return e.forEach(e=>this.addOption(e)),this}addOption(e){return this.listComponent.addOption(e),this}clearOptions(){return this.listComponent?.clearOptions(),this.setValue(void 0,!0),this}setValue(e,t,o){const{listComponent:i,config:{placeholder:s},eDisplayField:n,tooltipFeature:r}=this;if(this.value===e||!i)return this;o||i.setValue(e,!0);if(i.getValue()===this.getValue())return this;let a=i.getDisplayValue();return null==a&&s&&(a=s),n.textContent=a,r?.setTooltipAndRefresh(a??null),super.setValue(e,t)}destroy(){this.listComponent=this.destroyBean(this.listComponent),super.destroy()}},Ws={selector:"AG-SELECT",component:zs},Us="object"!=typeof window||!window?.document?.fonts?.forEach,$s=(e,t,o,i,s,n)=>{if(Us)return;i&&(e=`@layer ${CSS.escape(i)} { ${e} }`);let r=js.map.get(t);if(r||(r=[],js.map.set(t,r)),r.find(t=>t.css===e))return;const a=document.createElement("style");n&&a.setAttribute("nonce",n),a.dataset.agGlobalCss=o,a.textContent=e;const l={css:e,el:a,priority:s};let d;for(const e of r){if(e.priority>s)break;d=e}if(d){d.el.insertAdjacentElement("afterend",a);const e=r.indexOf(d);r.splice(e+1,0,l)}else t.insertBefore(a,t.querySelector(":not(title, meta)")),r.push(l)},Ks=(e,t,o,i)=>{$s(':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,o),i?.forEach((i,s)=>i.forEach(i=>$s(i,e,s,t,0,o)))},js=(xs="object"==typeof window?window:{}).agStyleInjectionState??(xs.agStyleInjectionState={map:new WeakMap,grids:new Set}),qs=e=>new Qs(e),_s="$default",Ys=0,Qs=class{constructor({feature:e,params:t,modeParams:o={},css:i,cssImports:s}){this.feature=e,this.css=i,this.cssImports=s,this.modeParams={[_s]:{...o[_s]??{},...t??{}},...o}}use(e,t,o){let i=this._inject;if(null==i){let{css:e}=this;if(e){const t=`ag-theme-${this.feature??"part"}-${++Ys}`;"function"==typeof e&&(e=e()),e=`:where(.${t}) {\n${e}\n}\n`;for(const t of this.cssImports??[])e=`@import url(${JSON.stringify(t)});\n${e}`;i={css:e,class:t}}else i=!1;this._inject=i}return i&&e&&$s(i.css,e,i.class,t,1,o),!!i&&i.class}},Zs=e=>{return`--ag-${t=e,t.replace(/[A-Z]/g,e=>`-${e}`).toLowerCase()}`;var t},Js=e=>`var(${Zs(e)})`,Xs=e=>({ref:"accentColor",mix:e}),en=e=>({ref:"foregroundColor",mix:e}),tn=e=>({ref:"foregroundColor",mix:e,onto:"backgroundColor"}),on={ref:"backgroundColor"},sn={ref:"foregroundColor"},nn={ref:"accentColor"},rn={backgroundColor:"#fff",foregroundColor:"#181d1f",borderColor:en(.15),chromeBackgroundColor:tn(.02),browserColorScheme:"light"},an={...rn,textColor:sn,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:Xs(.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:on,dragAndDropImageBorder:!0,dragAndDropImageNotAllowedBorder:{color:{ref:"invalidColor",onto:"dragAndDropImageBackgroundColor",mix:.5}},dragAndDropImageShadow:{ref:"popupShadow"},iconSize:16,iconColor:"inherit",toggleButtonWidth:28,toggleButtonHeight:18,toggleButtonOnBackgroundColor:nn,toggleButtonOffBackgroundColor:tn(.3),toggleButtonSwitchBackgroundColor:on,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}}},ln=["colorScheme","color","length","scale","borderStyle","border","shadow","image","fontFamily","fontWeight","duration"],dn=(e=>{const t=new Map;return o=>{const i=o;return t.has(i)||t.set(i,e(o)),t.get(i)}})(e=>(e=e.toLowerCase(),ln.find(t=>e.endsWith(t.toLowerCase()))??"length")),hn=e=>"object"==typeof e&&e?.ref?Js(e.ref):"string"==typeof e?e:"number"==typeof e&&String(e),cn=e=>{if("string"==typeof e)return e;if(e&&"ref"in e){const t=Js(e.ref);if(null==e.mix)return t;return`color-mix(in srgb, ${e.onto?Js(e.onto):"transparent"}, ${t} ${((e,t,o)=>Math.max(t,Math.min(o,e)))(100*e.mix,0,100)}%)`}return!1},un=e=>{if("string"==typeof e)return e;if("number"==typeof e)return`${e}px`;if(e&&"calc"in e){return`calc(${e.calc.replace(/ ?[*/+] ?/g," $& ").replace(/-?\b[a-z][a-z0-9]*\b(?![-(])/gi,e=>"-"===e[0]?e:` ${Js(e)} `)})`}return!(!e||!("ref"in e))&&Js(e.ref)},gn=(e,t)=>"string"==typeof e?e:!0===e?gn({},t):!1===e?"columnBorder"===t?gn({color:"transparent"},t):"none":e&&"ref"in e?Js(e.ref):pn(e.style??"solid")+" "+un(e.width??{ref:"borderWidth"})+" "+cn(e.color??{ref:"borderColor"}),pn=hn,mn=e=>"string"==typeof e?e.includes(",")?e:fn(e):e&&"googleFont"in e?mn(e.googleFont):e&&"ref"in e?Js(e.ref):!!Array.isArray(e)&&e.map(e=>("object"==typeof e&&"googleFont"in e&&(e=e.googleFont),fn(e))).join(", "),fn=e=>/^[\w-]+$|\w\(/.test(e)?e:JSON.stringify(e),Cn=e=>"string"==typeof e?e:e&&"url"in e?`url(${JSON.stringify(e.url)})`:e&&"svg"in e?Cn({url:`data:image/svg+xml,${encodeURIComponent(e.svg)}`}):!(!e||!("ref"in e))&&Js(e.ref),vn={color:cn,colorScheme:hn,length:un,scale:hn,border:gn,borderStyle:pn,shadow:e=>"string"==typeof e?e:!1===e?"none":e&&"ref"in e?Js(e.ref):[un(e.offsetX??0),un(e.offsetY??0),un(e.radius??0),un(e.spread??0),cn(e.color??{ref:"foregroundColor"})].join(" "),image:Cn,fontFamily:mn,fontWeight:hn,duration:(e,t,o)=>"string"==typeof e?e:"number"==typeof e?(e>=10&&o.warn(104,{value:e,param:t}),`${e}s`):!(!e||!("ref"in e))&&Js(e.ref)},wn=(e,t,o)=>{const i=dn(e);return vn[i](t,e,o)},bn=class e{constructor(e,t=[]){this.themeLogger=e,this.parts=t}withPart(t){return"function"==typeof t&&(t=t()),t instanceof Qs?new e(this.themeLogger,[...this.parts,t]):(this.themeLogger.preInitErr(259,"Invalid part",{part:t}),this)}withoutPart(e){return this.withPart(qs({feature:e}))}withParams(e,t=_s){return this.withPart(qs({modeParams:{[t]:e}}))}_startUse({styleContainer:e,cssLayer:t,nonce:o,loadThemeGoogleFonts:i,moduleCss:s}){if(Us)return;Rn(),Ks(e,t,o,s);const n=Sn(this);if(n.length>0)for(const e of n)i&&Fn(e,o);for(const i of this.parts)i.use(e,t,o)}_getCssClass(){return this._cssClassCache??(this._cssClassCache=yn(this.parts).map(e=>e.use(void 0,void 0,void 0)).filter(Boolean).join(" "))}_getModeParams(){let e=this._paramsCache;if(!e){const t={[_s]:{...an}};for(const e of yn(this.parts))for(const o of Object.keys(e.modeParams)){const i=e.modeParams[o];if(i){const e=t[o]??(t[o]={}),s=new Set;for(const t of Object.keys(i)){const o=i[t];void 0!==o&&(e[t]=o,s.add(t))}if(o===_s)for(const e of Object.keys(t)){const o=t[e];if(e!==_s)for(const e of s)delete o[e]}}}this._paramsCache=e=t}return e}_getPerInstanceCss(e){const t="##SELECTOR##";let o=this._paramsCssCache;if(!o){let e="",i="";const s=this._getModeParams();for(const t of Object.keys(s)){const o=s[t];if(t!==_s){const o=`:where([data-ag-theme-mode="${"object"==typeof CSS?CSS.escape(t):t}"]) & {\n`;e+=o,i+=o}for(const t of Object.keys(o).sort()){const s=o[t],n=wn(t,s,this.themeLogger);if(!1===n)this.themeLogger.error(107,{key:t,value:s});else{const o=Zs(t),s=o.replace("--ag-","--ag-inherited-");e+=`\t${o}: var(${s}, ${n});\n`,i+=`\t${s}: var(${o});\n`}}t!==_s&&(e+="}\n",i+="}\n")}let n=`${t} {\n${e}}\n`;n+=`:has(> ${t}):not(${t}) {\n${i}}\n`,this._paramsCssCache=o=n}return o.replaceAll(t,`:where(.${e})`)}},yn=e=>{const t=new Map;for(const o of e)t.set(o.feature,o);const o=[];for(const i of e)i.feature&&t.get(i.feature)!==i||o.push(i);return o},Sn=e=>{const t=new Set,o=e=>{if(Array.isArray(e))e.forEach(o);else{const o=e?.googleFont;"string"==typeof o&&t.add(o)}};return Object.values(e._getModeParams()).flatMap(e=>Object.values(e)).forEach(o),Array.from(t).sort()},En=!1,Rn=()=>{if(!En){En=!0;for(const e of Array.from(document.head.querySelectorAll('style[data-ag-scope="legacy"]')))e.remove()}},xn=new Set,Fn=async(e,t)=>{xn.add(e);const o=`@import url('https://${Pn}/css2?family=${encodeURIComponent(e)}:wght@100;200;300;400;500;600;700;800;900&display=swap');\n`;$s(o,document.head,`googleFont:${e}`,void 0,0,t)},Pn="fonts.googleapis.com",Dn=1,Mn=class{constructor(e){this.beans={},this.createdBeans=[],this.destroyed=!1,this.instanceId=Dn++,e&&e.beanClasses&&(this.beanDestroyComparator=e.beanDestroyComparator,this.init(e))}init(e){this.id=e.id,this.beans.context=this,this.destroyCallback=e.destroyCallback;for(const t of Object.keys(e.providedBeanInstances))this.beans[t]=e.providedBeanInstances[t];e.beanClasses.forEach(e=>{const t=new e;t.beanName?this.beans[t.beanName]=t:console.error(`Bean ${e.name} is missing beanName`),this.createdBeans.push(t)}),e.derivedBeans?.forEach(e=>{const{beanName:t,bean:o}=e(this);this.beans[t]=o,this.createdBeans.push(o)}),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){const o=this.beans;e.forEach(e=>{e.preWireBeans?.(o),e.wireBeans?.(o)}),e.forEach(e=>e.preConstruct?.()),t&&e.forEach(t),e.forEach(e=>e.postConstruct?.())}getBeans(){return this.beans}getBean(e){return this.beans[e]}getId(){return this.id}destroy(){if(this.destroyed)return;this.destroyed=!0;const 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}},kn=0,Tn=class extends De{constructor(){super(...arguments),this.beanName="environment",this.paramsClass="ag-theme-params-"+ ++kn,this.globalCSS=[]}wireBeans(e){this.eRootDiv=e.eRootDiv}postConstruct(){const{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(js.grids.delete(e),0===js.grids.size){js.map=new WeakMap;for(const e of 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=[]){const{theme:o}=this;let i;i=o?`${this.paramsClass} ${o._getCssClass()}`:this.applyLegacyThemeClasses();for(const t of Array.from(e.classList))t.startsWith("ag-theme-")&&e.classList.remove(t);if(i){const o=e.className;e.className=`${o}${o?" ":""}${i}${t?.length?` ${t.join(" ")}`:""}`}}applyLegacyThemeClasses(){let e="";this.mutationObserver.disconnect();let t=this.eRootDiv;for(;t;){let o=!1;for(const i of Array.from(t.classList))i.startsWith("ag-theme-")&&(o=!0,e=e?`${e} ${i}`:i);o&&this.mutationObserver.observe(t,{attributes:!0,attributeFilter:["class"]}),t=t.parentElement}return e}addGlobalCSS(e,t){this.theme?$s(e,this.eStyleContainer,t,this.cssLayer,0,this.styleNonce):this.globalCSS.push([e,t])}handleThemeChange(){const{gos:e,theme:t}=this,o=e.get("theme");let i;if("legacy"===o)i=void 0;else{const e=o??this.getDefaultTheme();e instanceof bn?i=e:this.themeError(e)}i!==t&&this.handleNewTheme(i),this.postProcessThemeChange(i,o)}handleNewTheme(e){const{gos:t,eRootDiv:o,globalCSS:i}=this,s=this.getAdditionalCss();if(e){n=this,js.grids.add(n),Ks(this.eStyleContainer,this.cssLayer,this.styleNonce,s);for(const[e,t]of i)$s(e,this.eStyleContainer,t,this.cssLayer,0,this.styleNonce);i.length=0}var n;this.theme=e,e?._startUse({loadThemeGoogleFonts:t.get("loadThemeGoogleFonts"),styleContainer:this.eStyleContainer,cssLayer:this.cssLayer,nonce:this.styleNonce,moduleCss:s});let r=this.eParamsStyle;if(!r){r=this.eParamsStyle=fe({tag:"style"});const e=t.get("styleNonce");e&&r.setAttribute("nonce",e),o.appendChild(r)}Us||(r.textContent=e?._getPerInstanceCss(this.paramsClass)||""),this.applyThemeClasses(o),this.fireStylesChangedEvent("themeChanged")}},In=class extends De{constructor(){super(...arguments),this.beanName="registry"}registerDynamicBeans(e){if(e){this.dynamicBeans??(this.dynamicBeans={});for(const t of Object.keys(e))this.dynamicBeans[t]=e[t]}}createDynamicBean(e,t,...o){if(!this.dynamicBeans)throw new Error(this.getDynamicError(e,!0));const i=this.dynamicBeans[e];if(null!=i)return new i(...o);if(t)throw new Error(this.getDynamicError(e,!1))}},An=class extends De{constructor(){super(...arguments),this.beanName="eventSvc",this.eventServiceType="global",this.globalSvc=new e}addListener(e,t,o){this.globalSvc.addEventListener(e,t,o)}removeListener(e,t,o){this.globalSvc.removeEventListener(e,t,o)}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))}},Ln=class extends De{constructor(e,t){super(),this.ctrl=e,t&&(this.beans=t)}postConstruct(){this.refreshTooltip()}setBrowserTooltip(e,t){const o="title",i=this.ctrl.getGui();i&&(null==e||""==e&&!t?i.removeAttribute(o):i.setAttribute(o,e))}updateTooltipText(){const{getTooltipValue:e}=this.ctrl;e&&(this.tooltip=e())}createTooltipFeatureIfNeeded(){if(null==this.tooltipManager){const e=this.beans.registry.createDynamicBean("tooltipStateManager",!0,this.ctrl,()=>this.tooltip);e&&(this.tooltipManager=this.createBean(e,this.beans.context))}}attemptToShowTooltip(){this.tooltipManager?.prepareToShowTooltip()}attemptToHideTooltip(){this.tooltipManager?.hideTooltip()}setTooltipAndRefresh(e){this.tooltip=e,this.refreshTooltip()}refreshTooltip(e){this.browserTooltips=this.beans.gos.get("enableBrowserTooltips"),this.updateTooltipText(),this.browserTooltips?(this.setBrowserTooltip(this.tooltip),this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context)):(this.setBrowserTooltip(e?"":null,e),this.createTooltipFeatureIfNeeded())}destroy(){this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context),super.destroy()}},Bn=!1,Hn=class extends De{constructor(e,t){super(),this.tooltipCtrl=e,this.getTooltipValue=t,this.interactionEnabled=!1,this.isInteractingWithTooltip=!1,this.state=0,this.tooltipInstanceCount=0,this.tooltipMouseTrack=!1}wireBeans(e){this.popupSvc=e.popupSvc}postConstruct(){this.gos.get("tooltipInteraction")&&(this.interactionEnabled=!0),this.tooltipTrigger=this.getTooltipTrigger(),this.tooltipMouseTrack=this.gos.get("tooltipMouseTrack");const e=this.tooltipCtrl.getGui();0===this.tooltipTrigger&&this.addManagedListeners(e,{mouseenter:this.onMouseEnter.bind(this),mouseleave:this.onMouseLeave.bind(this)}),1===this.tooltipTrigger&&this.addManagedListeners(e,{focusin:this.onFocusIn.bind(this),focusout:this.onFocusOut.bind(this)}),this.addManagedListeners(e,{mousemove:this.onMouseMove.bind(this)}),this.interactionEnabled||this.addManagedListeners(e,{mousedown:this.onMouseDown.bind(this),keydown:this.onKeyDown.bind(this)})}getGridOptionsTooltipDelay(e){const t=this.gos.get(e);return Math.max(200,t)}getTooltipDelay(e){return"show"===e?this.tooltipCtrl.getTooltipShowDelayOverride?.()??this.getGridOptionsTooltipDelay("tooltipShowDelay"):this.tooltipCtrl.getTooltipHideDelayOverride?.()??this.getGridOptionsTooltipDelay("tooltipHideDelay")}destroy(){this.setToDoNothing(),super.destroy()}getTooltipTrigger(){const e=this.gos.get("tooltipTrigger");return e&&"hover"!==e?1:0}onMouseEnter(e){this.interactionEnabled&&this.interactiveTooltipTimeoutId&&(this.unlockService(),this.startHideTimeout()),Zi()||(Bn?this.showTooltipTimeoutId=window.setTimeout(()=>{this.prepareToShowTooltip(e)},100):this.prepareToShowTooltip(e))}onMouseMove(e){this.lastMouseEvent&&(this.lastMouseEvent=e),this.tooltipMouseTrack&&2===this.state&&this.tooltipComp&&this.positionTooltip()}onMouseDown(){this.setToDoNothing()}onMouseLeave(){this.interactionEnabled?this.lockService():this.setToDoNothing()}onFocusIn(){this.prepareToShowTooltip()}onFocusOut(e){const t=e.relatedTarget,o=this.tooltipCtrl.getGui(),i=this.tooltipComp?.getGui();this.isInteractingWithTooltip||o.contains(t)||this.interactionEnabled&&i?.contains(t)||this.setToDoNothing()}onKeyDown(){this.isInteractingWithTooltip&&(this.isInteractingWithTooltip=!1),this.setToDoNothing()}prepareToShowTooltip(e){if(0!=this.state||Bn)return;let t=0;e&&(t=this.isLastTooltipHiddenRecently()?200:this.getTooltipDelay("show")),this.lastMouseEvent=e||null,this.showTooltipTimeoutId=window.setTimeout(this.showTooltip.bind(this),t),this.state=1}isLastTooltipHiddenRecently(){return Date.now()-Fs<1e3}setToDoNothing(e){e||2!==this.state||this.hideTooltip(),this.onBodyScrollEventCallback&&(this.onBodyScrollEventCallback(),this.onBodyScrollEventCallback=void 0),this.clearEventHandlers(),this.onDocumentKeyDownCallback&&(this.onDocumentKeyDownCallback(),this.onDocumentKeyDownCallback=void 0),this.clearTimeouts(),this.state=0,this.lastMouseEvent=null}showTooltip(){const e=this.getTooltipValue(),t=this.tooltipCtrl;if(!o(e)||t.shouldDisplayTooltip&&!t.shouldDisplayTooltip())return void this.setToDoNothing();const i=this.gos.addCommon({location:t.getLocation?.()??"UNKNOWN",value:e,hideTooltipCallback:()=>this.hideTooltip(!0),...t.getAdditionalParams?.()});this.state=2,this.tooltipInstanceCount++;const s=this.newTooltipComponentCallback.bind(this,this.tooltipInstanceCount);this.createTooltipComp(i,s)}hideTooltip(e){!e&&this.isInteractingWithTooltip||(this.tooltipComp&&(this.destroyTooltipComp(),Fs=Date.now()),this.eventSvc.dispatchEvent({type:"tooltipHide",parentGui:this.tooltipCtrl.getGui()}),e&&(this.isInteractingWithTooltip=!1),this.setToDoNothing(!0))}newTooltipComponentCallback(e,t){if(2!==this.state||this.tooltipInstanceCount!==e)return void this.destroyBean(t);const o=t.getGui();this.tooltipComp=t,o.classList.contains("ag-tooltip")||o.classList.add("ag-tooltip-custom"),0===this.tooltipTrigger&&o.classList.add("ag-tooltip-animate"),this.interactionEnabled&&o.classList.add("ag-tooltip-interactive");const i=this.getLocaleTextFunc(),s=this.popupSvc?.addPopup({eChild:o,ariaLabel:i("ariaLabelTooltip","Tooltip")});if(s&&(this.tooltipPopupDestroyFunc=s.hideFunc),this.positionTooltip(),1===this.tooltipTrigger){const e=()=>this.setToDoNothing();[this.onBodyScrollEventCallback]=this.addManagedEventListeners({bodyScroll:e}),this.setEventHandlers(e)}this.interactionEnabled&&([this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener]=this.addManagedElementListeners(o,{mouseenter:this.onTooltipMouseEnter.bind(this),mouseleave:this.onTooltipMouseLeave.bind(this)}),[this.onDocumentKeyDownCallback]=this.addManagedElementListeners(g(this.beans),{keydown:e=>{o.contains(e?.target)||this.onKeyDown()}}),1===this.tooltipTrigger&&([this.tooltipFocusInListener,this.tooltipFocusOutListener]=this.addManagedElementListeners(o,{focusin:this.onTooltipFocusIn.bind(this),focusout:this.onTooltipFocusOut.bind(this)}))),this.eventSvc.dispatchEvent({type:"tooltipShow",tooltipGui:o,parentGui:this.tooltipCtrl.getGui()}),this.startHideTimeout()}onTooltipMouseEnter(){this.isInteractingWithTooltip=!0,this.unlockService()}onTooltipMouseLeave(){this.isTooltipFocused()||(this.isInteractingWithTooltip=!1,this.lockService())}onTooltipFocusIn(){this.isInteractingWithTooltip=!0}isTooltipFocused(){const e=this.tooltipComp?.getGui(),t=u(this.beans);return!!e&&e.contains(t)}onTooltipFocusOut(e){const t=this.tooltipCtrl.getGui();this.isTooltipFocused()||(this.isInteractingWithTooltip=!1,t.contains(e.relatedTarget)?this.startHideTimeout():this.hideTooltip())}positionTooltip(){const e={type:"tooltip",ePopup:this.tooltipComp.getGui(),nudgeY:18,skipObserver:this.tooltipMouseTrack};this.lastMouseEvent?this.popupSvc?.positionPopupUnderMouseEvent({...e,mouseEvent:this.lastMouseEvent}):this.popupSvc?.positionPopupByComponent({...e,eventSource:this.tooltipCtrl.getGui(),position:"under",keepWithinBounds:!0,nudgeY:5})}destroyTooltipComp(){this.tooltipComp.getGui().classList.add("ag-tooltip-hiding");const e=this.tooltipPopupDestroyFunc,t=this.tooltipComp,o=0===this.tooltipTrigger?1e3:0;window.setTimeout(()=>{e(),this.destroyBean(t)},o),this.clearTooltipListeners(),this.tooltipPopupDestroyFunc=void 0,this.tooltipComp=void 0}clearTooltipListeners(){[this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener,this.tooltipFocusInListener,this.tooltipFocusOutListener].forEach(e=>{e&&e()}),this.tooltipMouseEnterListener=this.tooltipMouseLeaveListener=this.tooltipFocusInListener=this.tooltipFocusOutListener=null}lockService(){Bn=!0,this.interactiveTooltipTimeoutId=window.setTimeout(()=>{this.unlockService(),this.setToDoNothing()},100)}unlockService(){Bn=!1,this.clearInteractiveTimeout()}startHideTimeout(){this.clearHideTimeout(),this.hideTooltipTimeoutId=window.setTimeout(this.hideTooltip.bind(this),this.getTooltipDelay("hide"))}clearShowTimeout(){this.showTooltipTimeoutId&&(window.clearTimeout(this.showTooltipTimeoutId),this.showTooltipTimeoutId=void 0)}clearHideTimeout(){this.hideTooltipTimeoutId&&(window.clearTimeout(this.hideTooltipTimeoutId),this.hideTooltipTimeoutId=void 0)}clearInteractiveTimeout(){this.interactiveTooltipTimeoutId&&(window.clearTimeout(this.interactiveTooltipTimeoutId),this.interactiveTooltipTimeoutId=void 0)}clearTimeouts(){this.clearShowTimeout(),this.clearHideTimeout(),this.clearInteractiveTimeout()}},Vn=0,Gn=class extends De{constructor(){super(...arguments),this.beanName="popupSvc",this.popupList=[]}getPopupParent(){const e=this.gos.get("popupParent");return e||this.getDefaultPopupParent()}positionPopupUnderMouseEvent(e){const{ePopup:t,nudgeX:o,nudgeY:i,skipObserver:s}=e;this.positionPopup({ePopup:t,nudgeX:o,nudgeY:i,keepWithinBounds:!0,skipObserver:s,updatePosition:()=>this.calculatePointerAlign(e.mouseEvent),postProcessCallback:()=>this.callPostProcessPopup(e,e.type,e.ePopup,null,e.mouseEvent)})}calculatePointerAlign(e){const t=this.getParentRect();return{x:e.clientX-t.left,y:e.clientY-t.top}}positionPopupByComponent(e){const{ePopup:t,nudgeX:o,nudgeY:i,keepWithinBounds:s,eventSource:n,alignSide:r="left",position:a="over",type:l}=e,d=n.getBoundingClientRect(),h=this.getParentRect();this.setAlignedTo(n,t);this.positionPopup({ePopup:t,nudgeX:o,nudgeY:i,keepWithinBounds:s,updatePosition:()=>{let o,s=d.left-h.left;if("right"===r&&(s-=t.offsetWidth-d.width),"over"===a)o=d.top-h.top,this.setAlignedStyles(t,"over");else{this.setAlignedStyles(t,"under");o="under"===this.shouldRenderUnderOrAbove(t,d,h,e.nudgeY||0)?d.top-h.top+d.height:d.top-t.offsetHeight-2*(i||0)-h.top}return{x:s,y:o}},postProcessCallback:()=>this.callPostProcessPopup(e,l,t,n,null)})}shouldRenderUnderOrAbove(e,t,o,i){const s=o.bottom-t.bottom,n=t.top-o.top,r=e.offsetHeight+i;return s>r?"under":n>r||n>s?"above":"under"}setAlignedStyles(e,t){const o=this.getPopupIndex(e);if(-1===o)return;const i=this.popupList[o],{alignedToElement:s}=i;if(!s)return;["right","left","over","above","under"].forEach(t=>{s.classList.remove(`ag-has-popup-positioned-${t}`),e.classList.remove(`ag-popup-positioned-${t}`)}),t&&(s.classList.add(`ag-has-popup-positioned-${t}`),e.classList.add(`ag-popup-positioned-${t}`))}setAlignedTo(e,t){const o=this.getPopupIndex(t);if(-1!==o){this.popupList[o].alignedToElement=e}}positionPopup(e){const{ePopup:t,keepWithinBounds:o,nudgeX:i,nudgeY:s,skipObserver:n,updatePosition:r}=e,a={width:0,height:0},l=(n=!1)=>{let{x:l,y:d}=r();n&&t.clientWidth===a.width&&t.clientHeight===a.height||(a.width=t.clientWidth,a.height=t.clientHeight,i&&(l+=i),s&&(d+=s),o&&(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(),!n){const e=ce(this.beans,t,()=>l(!0));setTimeout(()=>e(),200)}}getParentRect(){const e=g(this.beans);let t=this.getPopupParent();return t===e.body?t=e.documentElement:"static"===getComputedStyle(t).position&&(t=t.offsetParent),$(t)}keepXYWithinBounds(e,t,o){const i=0===o,s=i?"clientHeight":"clientWidth",n=i?"top":"left",r=i?"height":"width",a=i?"scrollTop":"scrollLeft",l=g(this.beans),d=l.documentElement,h=this.getPopupParent(),c=e.getBoundingClientRect(),u=h.getBoundingClientRect(),p=l.documentElement.getBoundingClientRect(),m=h===l.body,f=Math.ceil(c[r]);let C=m?(i?W:U)(d)+d[a]:h[s];m&&(C-=Math.abs(p[n]-u[n]));const v=C-f;return Math.min(Math.max(t,0),Math.abs(v))}addPopup(e){const{eChild:t,ariaLabel:o,ariaOwns:i,alwaysOnTop:s,positionCallback:n,anchorToElement:r}=e,a=this.getPopupIndex(t);if(-1!==a){return{hideFunc:this.popupList[a].hideFunc}}this.initialisePopupPosition(t);const l=this.createPopupWrapper(t,!!s,o,i),d=this.addEventListenersToPopup({...e,wrapperEl:l});return n&&n(),this.addPopupToPopupList(t,l,d,r),{hideFunc:d}}initialisePopupPosition(e){const t=this.getPopupParent().getBoundingClientRect();o(e.style.top)||(e.style.top=-1*t.top+"px"),o(e.style.left)||(e.style.left=-1*t.left+"px")}createPopupWrapper(e,t,o,i){const s=this.getPopupParent(),{environment:n,gos:r}=this.beans,a=fe({tag:"div"});return n.applyThemeClasses(a),a.classList.add("ag-popup"),e.classList.add(r.get("enableRtl")?"ag-rtl":"ag-ltr","ag-popup-child"),e.hasAttribute("role")||y(e,"dialog"),o?S(e,o):i&&(e.id||(e.id=`popup-component-${Vn}`),I(i,e.id)),a.appendChild(e),s.appendChild(a),t?this.setAlwaysOnTop(e,!0):this.bringPopupToFront(e),a}addEventListenersToPopup(e){const t=this.beans,o=g(t),i=this.getPopupParent(),{wrapperEl:s,eChild:n,closedCallback:r,afterGuiAttached:a,closeOnEsc:l,modal:d,ariaOwns:h}=e;let c=!1;const p=e=>{if(!s.contains(u(t)))return;e.key!==Di||this.isStopPropagation(e)||C({keyboardEvent:e})},m=e=>C({mouseEvent:e}),f=e=>C({touchEvent:e}),C=(e={})=>{const{mouseEvent:t,touchEvent:a,keyboardEvent:l,forceHide:d}=e;(d||!this.isEventFromCurrentPopup({mouseEvent:t,touchEvent:a},n)&&!c)&&(c=!0,i.removeChild(s),o.removeEventListener("keydown",p),o.removeEventListener("mousedown",m),o.removeEventListener("touchstart",f),o.removeEventListener("contextmenu",m),this.eventSvc.removeListener("dragStarted",m),r&&r(t||a||l),this.removePopupFromPopupList(n,h))};return a&&a({hidePopup:C}),window.setTimeout(()=>{l&&o.addEventListener("keydown",p),d&&(o.addEventListener("mousedown",m),this.eventSvc.addListener("dragStarted",m),o.addEventListener("touchstart",f),o.addEventListener("contextmenu",m))},0),C}addPopupToPopupList(e,t,o,i){this.popupList.push({element:e,wrapper:t,hideFunc:o,instanceId:Vn,isAnchored:!!i}),i&&this.setPopupPositionRelatedToElement(e,i),Vn+=1}getPopupIndex(e){return this.popupList.findIndex(t=>t.element===e)}setPopupPositionRelatedToElement(e,t){const o=this.getPopupIndex(e);if(-1===o)return;const i=this.popupList[o];if(i.stopAnchoringPromise&&i.stopAnchoringPromise.then(e=>e&&e()),i.stopAnchoringPromise=void 0,i.isAnchored=!1,!t)return;const s=this.keepPopupPositionedRelativeTo({element:t,ePopup:e,hidePopup:i.hideFunc});return i.stopAnchoringPromise=s,i.isAnchored=!0,s}removePopupFromPopupList(e,t){this.setAlignedStyles(e,null),this.setPopupPositionRelatedToElement(e,null),t&&I(t,null),this.popupList=this.popupList.filter(t=>t.element!==e)}keepPopupPositionedRelativeTo(e){const t=this.getPopupParent(),o=t.getBoundingClientRect(),{element:i,ePopup:s}=e,n=i.getBoundingClientRect(),r=e=>parseInt(e.substring(0,e.length-1),10),a=(e,t)=>{const i=o[e]-n[e],a=r(s.style[e]);return{initialDiff:i,lastDiff:i,initial:a,last:a,direction:t}},l=a("top",0),d=a("left",1),h=this.beans.frameworkOverrides;return new Ko(o=>{h.wrapIncoming(()=>{var n,a;(n=()=>{const o=t.getBoundingClientRect(),n=i.getBoundingClientRect();if(0==n.top&&0==n.left&&0==n.height&&0==n.width)return void e.hidePopup();const a=(e,t)=>{const i=r(s.style[t]);e.last!==i&&(e.initial=i,e.last=i);const a=o[t]-n[t];if(a!=e.lastDiff){const o=this.keepXYWithinBounds(s,e.initial+e.initialDiff-a,e.direction);s.style[t]=`${o}px`,e.last=o}e.lastDiff=a};a(l,"top"),a(d,"left")},a=200,new Ko(e=>{e(window.setInterval(n,a))})).then(e=>{o(()=>{null!=e&&window.clearInterval(e)})})},"popupPositioning")})}isEventFromCurrentPopup(e,t){const{mouseEvent:o,touchEvent:i}=e,s=o||i;if(!s)return!1;const n=this.getPopupIndex(t);if(-1===n)return!1;for(let e=n;e<this.popupList.length;e++){if(ye(this.popupList[e].element,s))return!0}return this.isElementWithinCustomPopup(s.target)}isElementWithinCustomPopup(e){const t=g(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){const o=this.getWrapper(e);o&&(o.classList.toggle("ag-always-on-top",!!t),t&&this.bringPopupToFront(o))}bringPopupToFront(e){const t=this.getPopupParent(),o=Array.prototype.slice.call(t.querySelectorAll(".ag-popup")),i=o.length,s=this.getWrapper(e);if(!s||i<=1||!t.contains(e))return;const n=[],r=[];for(const e of o)e!==s&&(e.classList.contains("ag-always-on-top")?r.push(e):n.push(e));const a=[],l=r.length,d=s.classList.contains("ag-always-on-top")||!l?[...n,...r,s]:[...n,s,...r];for(let e=0;e<=i;e++){const i=d[e];if(o[e]===d[e]||i===s)continue;i.querySelectorAll("div").forEach(e=>{0!==e.scrollTop&&a.push([e,e.scrollTop])}),0===e?t.insertAdjacentElement("afterbegin",i):d[e-1].insertAdjacentElement("afterend",i)}for(;a.length;){const e=a.pop();e[0].scrollTop=e[1]}}},Nn=class extends De{constructor(){super(...arguments),this.beanName="dragSvc",this.dragEndFunctions=[],this.dragSources=[]}destroy(){const{dragSources:e}=this;e.forEach(this.removeListener.bind(this)),e.length=0,super.destroy()}removeListener(e){const t=e.dragSource.eElement,o=e.mouseDownListener;if(t.removeEventListener("mousedown",o),e.touchEnabled){const o=e.touchStartListener;t.removeEventListener("touchstart",o,{passive:!0})}}removeDragSource(e){const{dragSources:t}=this,o=t.find(t=>t.dragSource===e);o&&(this.removeListener(o),so(t,o))}addDragSource(e){const t=this.onMouseDown.bind(this,e),{eElement:o,includeTouch:i,stopPropagationForTouch:s}=e;o.addEventListener("mousedown",t);let n=null;const r=this.gos.get("suppressTouch");i&&!r&&(n=t=>{B(t.target)||(s&&t.stopPropagation(),this.onTouchStart(e,t))},o.addEventListener("touchstart",n,{passive:!1})),this.dragSources.push({dragSource:e,mouseDownListener:t,touchStartListener:n,touchEnabled:!!i})}onTouchStart(e,t){this.currentDragParams=e,this.dragging=!1;const o=t.touches[0];this.touchLastTime=o,this.touchStart=o;const i=t=>this.onTouchUp(t,e.eElement),s=t.target,n=[{target:c(this.beans),type:"touchmove",listener:e=>{e.cancelable&&e.preventDefault()},options:{passive:!1}},{target:s,type:"touchmove",listener:t=>this.onTouchMove(t,e.eElement),options:{passive:!0}},{target:s,type:"touchend",listener:i,options:{passive:!0}},{target:s,type:"touchcancel",listener:i,options:{passive:!0}}];this.addTemporaryEvents(n),0===e.dragStartPixels&&this.onCommonMove(o,this.touchStart,e.eElement)}onMouseDown(e,t){const o=t;if(e.skipMouseEvent&&e.skipMouseEvent(t))return;if(o._alreadyProcessedByDragService)return;if(o._alreadyProcessedByDragService=!0,0!==t.button)return;this.shouldPreventMouseEvent(t)&&t.preventDefault(),this.currentDragParams=e,this.dragging=!1,this.mouseStartEvent=t,this.startTarget=t.target;const i=c(this.beans),s=[{target:i,type:"mousemove",listener:t=>this.onMouseMove(t,e.eElement)},{target:i,type:"mouseup",listener:t=>this.onMouseUp(t,e.eElement)},{target:i,type:"contextmenu",listener:e=>e.preventDefault()},{target:i,type:"keydown",listener:t=>{t.key===Di&&this.cancelDrag(e.eElement)}}];this.addTemporaryEvents(s),0===e.dragStartPixels&&this.onMouseMove(t,e.eElement)}addTemporaryEvents(e){e.forEach(e=>{const{target:t,type:o,listener:i,options:s}=e;t.addEventListener(o,i,s)}),this.dragEndFunctions.push(()=>{e.forEach(e=>{const{target:t,type:o,listener:i,options:s}=e;t.removeEventListener(o,i,s)})})}isEventNearStartEvent(e,t){const{dragStartPixels:i}=this.currentDragParams;return Ee(e,t,o(i)?i:4)}getFirstActiveTouch(e){for(let t=0;t<e.length;t++)if(e[t].identifier===this.touchStart.identifier)return e[t];return null}onCommonMove(e,t,o){if(!this.dragging){if(this.isEventNearStartEvent(e,t))return;if(this.dragging=!0,this.eventSvc.dispatchEvent({type:"dragStarted",target:o}),this.currentDragParams.onDragStart(t),!this.currentDragParams)return void(this.dragging=!1);this.currentDragParams.onDragging(t)}this.currentDragParams?.onDragging(e)}onTouchMove(e,t){const o=this.getFirstActiveTouch(e.touches);o&&this.onCommonMove(o,this.touchStart,t)}onMouseMove(e,t){if(_i()){const e=g(this.beans);e.getSelection()?.removeAllRanges()}this.shouldPreventMouseEvent(e)&&e.preventDefault(),this.onCommonMove(e,this.mouseStartEvent,t)}shouldPreventMouseEvent(e){return"mousemove"===e.type&&e.cancelable&&Re(this.beans,e)&&!(e=>{const t=e.target,o=t?.tagName.toLocaleLowerCase();return!!o?.match("^a$|textarea|input|select|button")})(e)}onTouchUp(e,t){let o=this.getFirstActiveTouch(e.changedTouches);o||(o=this.touchLastTime),this.onUpCommon(o,t)}onMouseUp(e,t){this.onUpCommon(e,t)}onUpCommon(e,t){this.dragging&&(this.dragging=!1,this.currentDragParams.onDragStop(e),this.eventSvc.dispatchEvent({type:"dragStopped",target:t})),this.resetDragProperties()}cancelDrag(e){this.eventSvc.dispatchEvent({type:"dragCancelled",target:e}),this.currentDragParams?.onDragCancel?.(),this.resetDragProperties()}resetDragProperties(){this.mouseStartEvent=null,this.startTarget=null,this.touchStart=null,this.touchLastTime=null,this.currentDragParams=null;const{dragEndFunctions:e}=this;e.forEach(e=>e()),e.length=0}},On=class extends De{constructor(){super(...arguments),this.beanName="dragAndDrop",this.dragSourceAndParamsList=[],this.dragItem=null,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){const o={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(o),this.beans.dragSvc.addDragSource(o)}setDragImageCompIcon(e,t=!1){const o=this.dragImageComp;o&&(t||this.dragImageLastIcon!==e)&&(this.dragImageLastIcon=e,o.setIcon(e,t))}removeDragSource(e){const{dragSourceAndParamsList:t,beans:o}=this,i=t.find(t=>t.dragSource===e);i&&(o.dragSvc?.removeDragSource(i),so(t,i))}destroy(){const{dragSourceAndParamsList:e,dropTargets:t,beans:o}=this,i=o.dragSvc;for(const t of e)i?.removeDragSource(t);e.length=0,t.length=0,this.clearDragAndDropProperties(),super.destroy()}nudge(){const e=this.lastMouseEvent;e&&this.onDragging(e,!0)}onDragStart(e,t){this.lastMouseEvent=t,this.dragSource=e,this.dragItem=e.getDragItem(),e.onDragStarted?.(),this.createAndUpdateDragImageComp(e)}onDragStop(e){const{dragSource:t,lastDropTarget:o}=this;if(t?.onDragStopped?.(),o){const t=this.dropTargetEvent(o,e,!1);o.onDragStop?.(t)}this.clearDragAndDropProperties()}onDragCancel(){const{dragSource:e,lastDropTarget:t,lastMouseEvent:o}=this;if(e?.onDragCancelled?.(),t&&o){const e=this.dropTargetEvent(t,o,!1);t.onDragCancel?.(e)}this.clearDragAndDropProperties()}onDragging(e,t=!1){this.positionDragImageComp(e);const o=this.findCurrentDropTarget(e),{lastDropTarget:i,dragSource:s,dragItem:n}=this;let r=!1;if(o!==i){if(r=!0,i){const o=this.dropTargetEvent(i,e,t);i.onDragLeave?.(o)}if(null===i||o?null===i&&o&&this.handleEnter(s,n):this.handleExit(s,n),o){const i=this.dropTargetEvent(o,e,t);o.onDragEnter?.(i)}this.lastDropTarget=o}else if(o){const i=this.dropTargetEvent(o,e,t);o.onDragging?.(i),i?.changed&&(r=!0)}this.lastMouseEvent=e,r&&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.dragSource=null}getAllContainersFromDropTarget(e){const t=e.getSecondaryContainers?e.getSecondaryContainers():null,o=[[e.getContainer()]];return t?o.concat(t):o}isMouseOnDropTarget(e,t){const o=this.getAllContainersFromDropTarget(t);let i=!1;const s=(e,t)=>{for(const o of t){const{width:t,height:i,left:s,right:n,top:r,bottom:a}=o.getBoundingClientRect();if(0===t||0===i)return!1;const l=e.clientX>=s&&e.clientX<n,d=e.clientY>=r&&e.clientY<a;if(!l||!d)return!1}return!0};for(const t of o)if(s(e,t)){i=!0;break}const{eElement:n,type:r}=this.dragSource;return!(t.targetContainsSource&&!t.getContainer().contains(n))&&(i&&t.isInterestedIn(r,n))}findCurrentDropTarget(e){const t=this.dropTargets.filter(t=>this.isMouseOnDropTarget(e,t)),o=t.length;if(0===o)return null;if(1===o)return t[0];const i=c(this.beans).elementsFromPoint(e.clientX,e.clientY);for(const e of i)for(const o of t){if(-1!==this.getAllContainersFromDropTarget(o).flatMap(e=>e).indexOf(e))return o}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,o){const{dragSource:i,dragItem:s,lastDraggingEvent:n,lastMouseEvent:r}=this,a=e.getContainer(),l=a.getBoundingClientRect(),{clientX:d,clientY:h}=t,c=d-(r?.clientX||0),u=h-(r?.clientY||0),g=this.createEvent({event:t,x:d-l.left,y:h-l.top,vDirection:u>0?"down":u<0?"up":null,hDirection:c<0?"left":c>0?"right":null,dragSource:i,fromNudge:o,dragItem:s,dropZoneTarget:a,dropTarget:n?.dropTarget??null,changed:!!n?.changed});return this.lastDraggingEvent=g,g}positionDragImageComp(e){const t=this.dragImageComp?.getGui();t&&xe(t,e,this.beans)}removeDragImageComp(e){if(this.dragImageComp===e&&(this.dragImageComp=null),e){const t=e.getGui();this.dragImageParent?.removeChild(t),this.destroyBean(e)}}createAndUpdateDragImageComp(e){const 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;const o=this.dragImageComp;o!==e&&(this.dragImageComp=e,this.removeDragImageComp(o)),e&&(this.appendDragImageComp(e),this.updateDragImageComp())})}appendDragImageComp(e){const t=e.getGui(),o=t.style;o.setProperty("position","absolute"),o.setProperty("z-index","9999"),this.gos.setInstanceDomData(t),this.beans.environment.applyThemeClasses(t),o.top="20px",o.left="20px";const i=f(this.beans);this.dragImageParent=i,i?i.appendChild(t):this.warnNoBody()}updateDragImageComp(){const{dragImageComp:e,dragSource:t,lastDropTarget:o,lastDraggingEvent:i,dragImageLastLabel:s}=this;if(!e)return;this.setDragImageCompIcon(o?.getIconName?.(i)??null);let n=t?.dragItemName;"function"==typeof n&&(n=n(i)),n||(n=""),s!==n&&(this.dragImageLastLabel=n,e.setLabel(n))}};function zn(e,t){return e+"_"+t}function Wn(e){return e instanceof Un}var Un=class extends Me{constructor(e,t,o,i){super(),this.providedColumnGroup=e,this.groupId=t,this.partId=o,this.pinned=i,this.isColumn=!1,this.displayedChildren=[],this.autoHeaderHeight=null,this.parent=null,this.colIdSanitised=h(this.getUniqueId())}reset(){this.parent=null,this.children=null,this.displayedChildren=null}getParent(){return this.parent}getUniqueId(){return zn(this.groupId,this.partId)}isEmptyGroup(){return 0===this.displayedChildren.length}isMoving(){const e=this.getProvidedColumnGroup().getLeafColumns();return!(!e||0===e.length)&&e.every(e=>e.isMoving())}checkLeft(){if(this.displayedChildren.forEach(e=>{Wn(e)&&e.checkLeft()}),this.displayedChildren.length>0)if(this.gos.get("enableRtl")){const e=to(this.displayedChildren).getLeft();this.setLeft(e)}else{const 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;return this.displayedChildren?.forEach(t=>{e+=t.getActualWidth()}),e}isResizable(){if(!this.displayedChildren)return!1;let e=!1;return this.displayedChildren.forEach(t=>{t.isResizable()&&(e=!0)}),e}getMinWidth(){let e=0;return this.displayedChildren.forEach(t=>{e+=t.getMinWidth()}),e}addChild(e){this.children||(this.children=[]),this.children.push(e)}getDisplayedChildren(){return this.displayedChildren}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}getDisplayedLeafColumns(){const 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){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}addDisplayedLeafColumns(e){this.displayedChildren.forEach(t=>{qt(t)?e.push(t):Wn(t)&&t.addDisplayedLeafColumns(e)})}addLeafColumns(e){this.children.forEach(t=>{qt(t)?e.push(t):Wn(t)&&t.addLeafColumns(e)})}getChildren(){return this.children}getColumnGroupShow(){return this.providedColumnGroup.getColumnGroupShow()}getProvidedColumnGroup(){return this.providedColumnGroup}getPaddingLevel(){const e=this.getParent();return this.isPadding()&&e&&e.isPadding()?1+e.getPaddingLevel():0}calculateDisplayedColumns(){this.displayedChildren=[];let e=this;for(;null!=e&&e.isPadding();)e=e.getParent();if(!(!!e&&e.getProvidedColumnGroup().isExpandable()))return this.displayedChildren=this.children,void this.dispatchLocalEvent({type:"displayedChildrenChanged"});this.children.forEach(t=>{if(Wn(t)&&!t.displayedChildren?.length)return;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"})}},$n="row-group-",Kn="t-",jn="b-",qn=0,_n=class{constructor(e){this.master=!1,this.detail=void 0,this.rowIndex=null,this.key=null,this.sourceRowIndex=-1,this.childrenMapped=null,this.treeParent=null,this.treeNodeFlags=0,this.displayed=!1,this.rowTop=null,this.oldRowTop=null,this.selectable=!0,this.__objectId=qn++,this.alreadyRendered=!1,this.hovered=!1,this.__selected=!1,this.beans=e}setData(e){this.setDataCommon(e,!1)}updateData(e){this.setDataCommon(e,!0)}setDataCommon(e,t){const{valueCache:o,eventSvc:i}=this.beans,s=this.data;this.data=e,o?.onDataChanged(),this.updateDataOnDetailNode(),this.resetQuickFilterAggregateText();const n=this.createDataChangedEvent(e,s,t);if(this.__localEventService?.dispatchEvent(n),this.sibling){this.sibling.data=e;const o=this.sibling.createDataChangedEvent(e,s,t);this.sibling.__localEventService?.dispatchEvent(o)}i.dispatchEvent({type:"rowNodeDataChanged",node:this});const r=this.pinnedSibling;r&&(r.data=e,r.__localEventService?.dispatchEvent(r.createDataChangedEvent(e,s,t)),i.dispatchEvent({type:"rowNodeDataChanged",node:r}))}updateDataOnDetailNode(){this.detailNode&&(this.detailNode.data=this.data)}createDataChangedEvent(e,t,o){return{type:"dataChanged",node:this,oldData:t,newData:e,update:o}}getRowIndexString(){return null==this.rowIndex?(nt(13),null):"top"===this.rowPinned?Kn+this.rowIndex:"bottom"===this.rowPinned?jn+this.rowIndex:this.rowIndex.toString()}setDataAndId(e,t){const{selectionSvc:o}=this.beans,i=o?.createDaemonNode?.(this),s=this.data;this.data=e,this.updateDataOnDetailNode(),this.setId(t),o&&(o.updateRowSelectable(this),o.syncInRowNode(this,i));const n=this.createDataChangedEvent(e,s,!1);this.__localEventService?.dispatchEvent(n)}setId(e){const t=Ft(this.beans.gos);if(t)if(this.data){const 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($n)&&nt(14,{groupPrefix:$n})}else this.id=void 0;else this.id=e}setRowTop(e){this.oldRowTop=this.rowTop,this.rowTop!==e&&(this.rowTop=e,this.dispatchRowEvent("topChanged"),this.setDisplayed(null!==e))}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,o){this.beans.expansionSvc?.setExpanded(this,e,t,o)}setDataValue(e,t,o){const{colModel:i,valueSvc:s,gos:n,editSvc:r}=this.beans,a="string"!=typeof e?e:i.getCol(e)??i.getColDefCol(e);if(!a)return!1;const l=s.getValueForDisplay(a,this,void 0,void 0,"api").value;if(n.get("readOnlyEdit")){const{beans:{eventSvc:e},data:i,rowIndex:s,rowPinned:n}=this;return e.dispatchEvent({type:"cellEditRequest",event:null,rowIndex:s,rowPinned:n,column:a,colDef:a.colDef,data:i,node:this,oldValue:l,newValue:t,value:t,source:o}),!1}if(r&&!r.committing){const e=r.setDataValue({rowNode:this,column:a},t,o);if(null!=e)return e}const d=s.setValue(this,a,t,o);this.dispatchCellChangedEvent(a,t,l);const h=this.pinnedSibling;return h&&d&&h.dispatchCellChangedEvent(a,t,l),d}updateHasChildren(){let e=this.group&&!this.footer||this.childrenAfterGroup&&this.childrenAfterGroup.length>0;const{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,o){const i={type:"cellChanged",node:this,column:e,newValue:t,oldValue:o};this.__localEventService?.dispatchEvent(i)}resetQuickFilterAggregateText(){this.quickFilterAggregateText=null}isExpandable(){return this.beans.expansionSvc?.isExpandable(this)??!1}isSelected(){return this.footer?this.sibling.isSelected():this.rowPinned&&this.pinnedSibling?this.pinnedSibling.isSelected():this.__selected}depthFirstSearch(e){this.childrenAfterGroup?.forEach(t=>t.depthFirstSearch(e)),e(this)}dispatchRowEvent(e){this.__localEventService?.dispatchEvent({type:e,node:this})}setSelected(e,t=!1,o="api"){this.beans.selectionSvc?.setNodesSelected({nodes:[this],newValue:e,clearSelection:t,source:o})}isRowPinned(){return!!this.rowPinned}__addEventListener(t,o){this.__localEventService||(this.__localEventService=new e),this.__localEventService.addEventListener(t,o)}__removeEventListener(e,t){this.removeLocalListener(e,t)}addEventListener(t,o){this.beans.validation?.checkRowEvents(t),this.__localEventService||(this.__localEventService=new e),this.frameworkEventListenerService=this.beans.frameworkOverrides.createLocalEventListenerWrapper?.(this.frameworkEventListenerService,this.__localEventService);const i=this.frameworkEventListenerService?.wrap(t,o)??o;this.__localEventService.addEventListener(t,i)}removeEventListener(e,t){const o=this.frameworkEventListenerService?.unwrap(e,t)??t;this.removeLocalListener(e,o)}removeLocalListener(e,t){this.__localEventService?.removeEventListener(e,t),this.__localEventService?.noRegisteredListenersExist()&&(this.__localEventService=null)}isFullWidthCell(){if(st(61),this.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return!!e&&e({rowNode:this})}getRoute(){if(-1===this.level)return[];if(null==this.key)return;const e=[];let t=this;for(;t&&null!=t.key;)e.push(t.key),t=t.parent;return e.reverse()}setDisplayed(e){this.displayed!==e&&(this.displayed=e,this.dispatchRowEvent("displayedChanged"))}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(){return this.childStore?this.childStore.getFirstNode():this.childrenAfterSort?.[0]??null}};function Yn(e,t,o){return zt(t,{type:o,node:e,data:e.data,rowIndex:e.rowIndex,rowPinned:e.rowPinned})}var Qn=new Set(["__localEventService","__objectId","sticky","__autoHeights","__checkAutoHeightsDebounced","childStore"]);var Zn={agSetColumnFilter:"agSetColumnFilterHandler",agMultiColumnFilter:"agMultiColumnFilterHandler",agGroupColumnFilter:"agGroupColumnFilterHandler",agNumberColumnFilter:"agNumberColumnFilterHandler",agDateColumnFilter:"agDateColumnFilterHandler",agTextColumnFilter:"agTextColumnFilterHandler"},Jn=new Set(Object.values(Zn));function Xn(e,t){const o=e.filterUi;if(!o)return null;if(o.created)return o.promise;if(t)return null;const i=o.create(o.refreshed),s=o;return s.created=!0,s.promise=i,i}function er(e,t,o,i,s){e?.refresh?.({...t,model:o,state:i,source:s})}function tr(e,t,o){const i=e();i?.created&&i.promise.then(e=>{const s=t();er(e,i.filterParams,s,o()??{model:s},"ui")})}function or(e,t,o,i,s,n,r){let a,l,d=!1;switch(e){case"apply":{const e=i();l=e?.model??null,r&&(l=r(l)),a={state:e?.state,model:l},d=!0;break}case"clear":a={model:null};break;case"reset":a={model:null},d=!0,l=null;break;case"cancel":a={model:o()}}s(a),d?n(l):tr(t,o,i)}function ir(e,t){return e[t]??null}function sr(e){return fe(e)}var nr=class extends Uo{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){const o=this.buttons;if(this.buttons=e,o===e)return;const i=this.getGui();let s;q(i),this.destroyListeners();const n=document.createDocumentFragment(),r=this.className,a=({type:e,label:o})=>{const i=t=>{this.dispatchLocalEvent({type:e,event:t})};["apply","clear","reset","cancel"].includes(e)||st(75);const a="apply"===e,l=sr({tag:"button",attrs:{type:a&&t?"submit":"button"},ref:`${e}FilterButton`,cls:`ag-button ag-standard-button ${r}-button${a?" "+r+"-apply-button":""}`,children:o});this.activateTabIndex([l]),a&&(s=l);const d=e=>{e.key===Pi&&(e.preventDefault(),i(e))},h=this.listeners;l.addEventListener("click",i),h.push(()=>l.removeEventListener("click",i)),l.addEventListener("keydown",d),h.push(()=>l.removeEventListener("keydown",d)),n.append(l)};e.forEach(e=>a(e)),this.eApply=s;const l=this.validationTooltipFeature;s&&!l?this.validationTooltipFeature=this.createOptionalManagedBean(this.beans.registry.createDynamicBean("tooltipFeature",!1,{getGui:()=>this.eApply,getLocation:()=>"advancedFilter",getTooltipShowDelayOverride:()=>1e3})):!s&&l&&(this.validationTooltipFeature=this.destroyBean(l)),i.append(n)}getApplyButton(){return this.eApply}updateValidity(e,t=null){const o=this.eApply;o&&(V(o,!1===e),this.validationMessage=t??null,this.validationTooltipFeature?.setTooltipAndRefresh(this.validationMessage))}destroyListeners(){this.listeners.forEach(e=>e()),this.listeners=[]}destroy(){this.destroyListeners(),super.destroy()}},rr={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 ar(e,t,o){return function(e,t,o,i){const s=t[o];return e.getLocaleTextFunc()(o,"function"==typeof s?s(i):s,i)}(e,rr,t,o)}function lr(e,t){const{debounceMs:o}=e;return dr(e)?(null!=o&&st(71),0):o??t}function dr(e){return(e.buttons?.indexOf("apply")??-1)>=0}var hr=class extends Uo{constructor(e,t,o,i,s,n){super(),this.column=e,this.wrapper=t,this.eventParent=o,this.updateModel=i,this.isGlobalButtons=s,this.enableGlobalButtonCheck=n,this.hidePopup=null,this.applyActive=!1}postConstruct(){const{comp:e,params:t}=this.wrapper,o=t,i=o.useForm,s=i?"form":"div";this.setTemplate({tag:s,cls:"ag-filter-wrapper"}),i&&this.addManagedElementListeners(this.getGui(),{submit:e=>{e?.preventDefault()},keydown:this.handleKeyDown.bind(this)}),this.appendChild(e.getGui()),this.params=o,this.resetButtonsPanel(o),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:o})=>{e===this.column&&this.afterAction(t,o)},...this.enableGlobalButtonCheck?{filterGlobalButtons:({isGlobal:e})=>{if(e!==this.isGlobalButtons){this.isGlobalButtons=e;const t=this.params;this.resetButtonsPanel(t,t,!0)}}}:void 0})}afterGuiAttached(e){e&&(this.hidePopup=e.hidePopup)}resetButtonsPanel(e,t,o){const{buttons:i,readOnly:s}=t??{},{buttons:r,readOnly:a,useForm:l}=e;if(!o&&s===a&&n(i,r))return;const d=r&&r.length>0&&!e.readOnly&&!this.isGlobalButtons;let h=this.eButtons;if(d){const e=r.map(e=>({type:e,label:ar(this,`${e}Filter`)}));if(this.applyActive=dr(this.params),!h){h=this.createBean(new nr),this.appendChild(h.getGui());const e=this.column,t=t=>({event:o})=>{this.updateModel(e,t),this.afterAction(t,o)};h?.addManagedListeners(h,{apply:t("apply"),clear:t("clear"),reset:t("reset"),cancel:t("cancel")}),this.eButtons=h}h.updateButtons(e,l)}else this.applyActive=!1,h&&(_(h.getGui()),this.eButtons=this.destroyBean(h))}close(e){const t=this.hidePopup;if(!t)return;const o=e,i=o&&o.key;let s;i!==Pi&&i!==Mi||(s={keyboardEvent:o}),t(s),this.hidePopup=null}afterAction(e,t){const{params:o,applyActive:i}=this,s=o?.closeOnApply;switch(e){case"apply":t?.preventDefault(),s&&i&&this.close(t);break;case"reset":s&&i&&this.close();break;case"cancel":s&&this.close(t)}}handleKeyDown(e){!e.defaultPrevented&&e.key===Pi&&this.applyActive&&(this.updateModel(this.column,"apply"),this.afterAction("apply",e))}destroy(){this.hidePopup=null,this.eButtons=this.destroyBean(this.eButtons)}},cr={tag:"div",cls:"ag-filter"},ur=class extends Uo{constructor(e,t,o){super(cr),this.column=e,this.source=t,this.enableGlobalButtonCheck=o,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(()=>{})??Ko.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){const{column:t,source:i,beans:{colFilter:s}}=this,n=s.getFilterUiForDisplay(t)??null;this.wrapper=n,n?.then(n=>{if(!n)return;const{isHandler:r,comp:a}=n;let l;if(r){const e=!!this.enableGlobalButtonCheck,o=this.createBean(new hr(t,n,s,s.updateModel.bind(s),e&&s.isGlobalButtons,e));this.comp=o,l=o.getGui()}else l=a.getGui(),o(l)||st(69,{guiFromFilter:l});this.appendChild(l),e?this.eventSvc.dispatchEvent({type:"filterOpened",column:t,source:i,eGui:this.getGui()}):a.afterGuiAttached?.(this.afterGuiAttachedParams)})}onFilterDestroyed(e){const{source:t,column:o}=e;"api"!==t&&"paramsUpdated"!==t||o.getId()!==this.column.getId()||!this.beans.colModel.getColDefCol(this.column)||(q(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()}},gr={january:"January",february:"February",march:"March",april:"April",may:"May",june:"June",july:"July",august:"August",september:"September",october:"October",november:"November",december:"December"},pr=["january","february","march","april","may","june","july","august","september","october","november","december"];function mr(e,t){return null==e?-1:null==t?1:parseFloat(e)-parseFloat(t)}function fr(e){return e instanceof Date&&!isNaN(e.getTime())}var Cr={number:()=>{},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:fr}),dateString:({dataTypeDefinition:e})=>({comparator:(t,o)=>{const i=e.dateParser(o);return null==o||i<t?-1:i>t?1:0},isValidDate:t=>"string"==typeof t&&fr(e.dateParser(t))}),dateTime:e=>Cr.date(e),dateTimeString:e=>Cr.dateString(e),object:()=>{},text:()=>{}},vr={number:()=>({comparator:mr}),boolean:({t:e})=>({valueFormatter:t=>o(t.value)?e(String(t.value),t.value?"True":"False"):e("blanks","(Blanks)")}),date:({formatValue:e,t:t})=>({valueFormatter:i=>{const s=e(i);return o(s)?s:t("blanks","(Blanks)")},treeList:!0,treeListFormatter:(e,o)=>{if("NaN"===e)return t("invalidDate","Invalid Date");if(1===o&&null!=e){const o=pr[Number(e)-1];return t(o,gr[o])}return e??t("blanks","(Blanks)")},treeListPathGetter:e=>ns(e,!1)}),dateString:({formatValue:e,dataTypeDefinition:t,t:i})=>({valueFormatter:t=>{const s=e(t);return o(s)?s:i("blanks","(Blanks)")},treeList:!0,treeListPathGetter:e=>ns(t.dateParser(e??void 0),!1),treeListFormatter:(e,t)=>{if(1===t&&null!=e){const t=pr[Number(e)-1];return i(t,gr[t])}return e??i("blanks","(Blanks)")}}),dateTime:e=>{const t=vr.date(e);return t.treeListPathGetter=ns,t},dateTimeString(e){const t=e.dataTypeDefinition.dateParser,o=vr.dateString(e);return o.treeListPathGetter=e=>ns(t(e??void 0)),o},object:({formatValue:e,t:t})=>({valueFormatter:i=>{const s=e(i);return o(s)?s:t("blanks","(Blanks)")}}),text:()=>{}};var wr={boolean:"agTextColumnFilter",date:"agDateColumnFilter",dateString:"agDateColumnFilter",dateTime:"agDateColumnFilter",dateTimeString:"agDateColumnFilter",number:"agNumberColumnFilter",object:"agTextColumnFilter",text:"agTextColumnFilter"},br={boolean:"agTextColumnFloatingFilter",date:"agDateColumnFloatingFilter",dateString:"agDateColumnFloatingFilter",dateTime:"agDateColumnFloatingFilter",dateTimeString:"agDateColumnFloatingFilter",number:"agNumberColumnFloatingFilter",object:"agTextColumnFloatingFilter",text:"agTextColumnFloatingFilter"};var yr="ag-resizer-wrapper",Sr=(e,t)=>({tag:"div",ref:`${e}Resizer`,cls:`ag-resizer ag-resizer-${t}`}),Er={tag:"div",cls:yr,children:[Sr("eTopLeft","topLeft"),Sr("eTop","top"),Sr("eTopRight","topRight"),Sr("eRight","right"),Sr("eBottomRight","bottomRight"),Sr("eBottom","bottom"),Sr("eBottomLeft","bottomLeft"),Sr("eLeft","left")]},Rr=class extends Me{constructor(e,t){super(),this.element=e,this.dragStartPosition={x:0,y:0},this.position={x:0,y:0},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){const{clientHeight:t,clientWidth:o}=this.offsetParent,i=o/2-this.getWidth()/2,s=t/2-this.getHeight()/2;this.offsetElement(i,s,e)}initialisePosition(e){if(this.positioned)return;const{centered:t,forcePopupParentAsOffsetParent:o,minWidth:i,width:s,minHeight:n,height:r,x:a,y:l}=this.config;this.offsetParent||this.setOffsetParent();let d=0,h=0;const c=Q(this.element);if(c){const e=this.findBoundaryElement(),t=window.getComputedStyle(e);if(null!=t.minWidth){const o=e.offsetWidth-this.element.offsetWidth;h=parseInt(t.minWidth,10)-o}if(null!=t.minHeight){const o=e.offsetHeight-this.element.offsetHeight;d=parseInt(t.minHeight,10)-o}}if(this.minHeight=n||d,this.minWidth=i||h,s&&this.setWidth(s),r&&this.setHeight(r),s&&r||this.refreshSize(),t)this.center(e);else if(a||l)this.offsetElement(a,l,e);else if(c&&o){let t=this.boundaryEl,o=!0;if(t||(t=this.findBoundaryElement(),o=!1),t){const i=parseFloat(t.style.top),s=parseFloat(t.style.left);o?this.offsetElement(isNaN(s)?0:s,isNaN(i)?0:i,e):this.setPosition(s,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;const o=this.moveElementDragListener||{eElement:t,onDragStart:this.onMoveStart.bind(this),onDragging:this.onMove.bind(this),onDragStop:this.onMoveEnd.bind(this)};e?(this.dragSvc?.addDragSource(o),this.moveElementDragListener=o):(this.dragSvc?.removeDragSource(o),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=>{const o=!!e[t],i=this.getResizerElement(t),s={dragStartPixels:0,eElement:i,onDragStart:e=>this.onResizeStart(e,t),onDragging:this.onResize.bind(this),onDragStop:e=>this.onResizeEnd(e,t)};(o||!this.isAlive()&&!o)&&(o?(this.dragSvc?.addDragSource(s),this.resizeListeners.push(s),i.style.pointerEvents="all"):i.style.pointerEvents="none",this.resizable[t]=o)})}removeSizeFromEl(){this.element.style.removeProperty("height"),this.element.style.removeProperty("width"),this.element.style.removeProperty("flex")}restoreLastSize(){this.element.style.flex="0 0 auto";const{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){const{popup:t}=this.config,o=this.element;let i=!1;if("string"==typeof e&&-1!==e.indexOf("%"))ae(o,e),e=W(o),i=!0;else if(e=Math.max(this.minHeight,e),this.positioned){const t=this.getAvailableHeight();t&&e>t&&(e=t)}this.getHeight()!==e&&(i?(o.style.maxHeight="unset",o.style.minHeight="unset"):t?ae(o,e):(o.style.height=`${e}px`,o.style.flex="0 0 auto",this.lastSize.height="number"==typeof e?e:parseFloat(e)))}getAvailableHeight(){const{popup:e,forcePopupParentAsOffsetParent:t}=this.config;this.positioned||this.initialisePosition();const{clientHeight:o}=this.offsetParent;if(!o)return null;const i=this.element.getBoundingClientRect(),s=this.offsetParent.getBoundingClientRect(),n=e?this.position.y:i.top,r=e?0:s.top;let a=0;if(t){const e=this.element.parentElement;if(e){const{bottom:t}=e.getBoundingClientRect();a=t-i.bottom}}return o+r-n-a}getWidth(){return this.element.offsetWidth}setWidth(e){const t=this.element,{popup:o}=this.config;let i=!1;if("string"==typeof e&&-1!==e.indexOf("%"))re(t,e),e=U(t),i=!0;else if(this.positioned){e=Math.max(this.minWidth,e);const{clientWidth:t}=this.offsetParent,i=o?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?re(t,e):(t.style.width=`${e}px`,t.style.flex=" unset",this.lastSize.width="number"==typeof e?e:parseFloat(e)))}offsetElement(e=0,t=0,o){const{forcePopupParentAsOffsetParent:i}=this.config,s=i?this.boundaryEl:this.element;s&&(this.popupSvc?.positionPopup({ePopup:s,keepWithinBounds:!0,skipObserver:this.movable||this.isResizable(),updatePosition:()=>({x:e,y:t}),postProcessCallback:o}),this.setPosition(parseFloat(s.style.left),parseFloat(s.style.top)))}constrainSizeToAvailableHeight(e){if(!this.config.forcePopupParentAsOffsetParent)return;const t=()=>{const e=this.getAvailableHeight();this.element.style.setProperty("max-height",`${e}px`)};e&&this.popupSvc?(this.resizeObserverSubscriber?.(),this.resizeObserverSubscriber=ce(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){const{e:t,isLeft:o,isTop:i,anywhereWithin:s,topBuffer:n}=e,r=t.clientX-this.dragStartPosition.x,a=t.clientY-this.dragStartPosition.y;return{movementX:this.shouldSkipX(t,!!o,!!s,r)?0:r,movementY:this.shouldSkipY(t,!!i,n,a)?0:a}}shouldSkipX(e,t,o,i){const s=this.element.getBoundingClientRect(),n=this.offsetParent.getBoundingClientRect(),r=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.x:s.left;let l=a<=0&&n.left>=e.clientX||n.right<=e.clientX&&n.right<=r.right;return!!l||(l=t?i<0&&e.clientX>a+n.left||i>0&&e.clientX<a+n.left:o?i<0&&e.clientX>r.right||i>0&&e.clientX<a+n.left:i<0&&e.clientX>r.right||i>0&&e.clientX<r.right,l)}shouldSkipY(e,t,o=0,i){const s=this.element.getBoundingClientRect(),n=this.offsetParent.getBoundingClientRect(),r=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.y:s.top;let l=a<=0&&n.top>=e.clientY||n.bottom<=e.clientY&&n.bottom<=r.bottom;return!!l||(l=t?i<0&&e.clientY>a+n.top+o||i>0&&e.clientY<a+n.top:i<0&&e.clientY>r.bottom||i>0&&e.clientY<r.bottom,l)}createResizeMap(){const 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;const e=this.element;e&&(e.appendChild(sr(Er)),this.createResizeMap(),this.resizersAdded=!0)}removeResizers(){this.resizerMap=void 0;const e=this.element.querySelector(`.${yr}`);e&&this.element.removeChild(e),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");const{popup:o,forcePopupParentAsOffsetParent:i}=this.config;o||i||this.applySizeToSiblings(this.currentResizer.isBottom||this.currentResizer.isTop),this.isResizing=!0,this.updateDragStartPosition(e.clientX,e.clientY)}getSiblings(){const e=this.element.parentElement;return e?Array.prototype.slice.call(e.children).filter(e=>!e.classList.contains("ag-hidden")):null}getMinSizeOfSiblings(){const e=this.getSiblings()||[];let t=0,o=0;for(let i=0;i<e.length;i++){const s=e[i],n=!!s.style.flex&&"0 0 auto"!==s.style.flex;if(s===this.element)continue;let r=this.minHeight||0,a=this.minWidth||0;if(n){const e=window.getComputedStyle(s);e.minHeight&&(r=parseInt(e.minHeight,10)),e.minWidth&&(a=parseInt(e.minWidth,10))}else r=s.offsetHeight,a=s.offsetWidth;t+=r,o+=a}return{height:t,width:o}}applySizeToSiblings(e){let t=null;const o=this.getSiblings();if(o){for(let i=0;i<o.length;i++){const s=o[i];s!==t&&(e?s.style.height=`${s.offsetHeight}px`:s.style.width=`${s.offsetWidth}px`,s.style.flex="0 0 auto",s===this.element&&(t=o[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;const{popup:t,forcePopupParentAsOffsetParent:o}=this.config,{isTop:i,isRight:s,isBottom:n,isLeft:r}=this.currentResizer,a=s||r,l=n||i,{movementX:d,movementY:h}=this.calculateMouseMovement({e:e,isLeft:r,isTop:i}),c=this.position.x,u=this.position.y;let g=0,p=0;if(a&&d){const e=r?-1:1,t=this.getWidth(),o=t+d*e;let i=!1;r&&(g=t-o,(c+g<=0||o<=this.minWidth)&&(i=!0,g=0)),i||this.setWidth(o)}if(l&&h){const e=i?-1:1,t=this.getHeight(),o=t+h*e;let s=!1;i?(p=t-o,(u+p<=0||o<=this.minHeight)&&(s=!0,p=0)):!this.config.popup&&!this.config.forcePopupParentAsOffsetParent&&t<o&&this.getMinSizeOfSiblings().height+o>this.element.parentElement.offsetHeight&&(s=!0),s||this.setHeight(o)}this.updateDragStartPosition(e.clientX,e.clientY),((t||o)&&g||p)&&this.offsetElement(c+g,u+p)}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(){const 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){if(!this.isMoving)return;const{x:t,y:o}=this.position;let i;this.config.calculateTopBuffer&&(i=this.config.calculateTopBuffer());const{movementX:s,movementY:n}=this.calculateMouseMovement({e:e,isTop:!0,anywhereWithin:!0,topBuffer:i});this.offsetElement(t+s,o+n),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;){const 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()}},xr="__ag_Grid_Stop_Propagation";function Fr(e){e[xr]=!0}function Pr(e){return!0===e[xr]}var Dr=class extends Me{constructor(e,t={}){super(),this.eFocusable=e,this.callbacks=t,this.callbacks={shouldStopEventPropagation:()=>!1,onTabKeyDown:e=>{if(e.defaultPrevented)return;const t=ys(this.beans,this.eFocusable,!1,e.shiftKey);t&&(t.focus(),e.preventDefault())},...t}}postConstruct(){const{eFocusable:e,callbacks:{onFocusIn:t,onFocusOut:o}}=this;e.classList.add("ag-focus-managed"),this.addKeyDownListeners(e),t&&this.addManagedElementListeners(e,{focusin:t}),o&&this.addManagedElementListeners(e,{focusout:o})}addKeyDownListeners(e){this.addManagedElementListeners(e,{keydown:e=>{if(e.defaultPrevented||Pr(e))return;const{callbacks:t}=this;t.shouldStopEventPropagation(e)?Fr(e):e.key===Fi?t.onTabKeyDown(e):t.handleKeyDown&&t.handleKeyDown(e)}})}},Mr=class extends Uo{constructor(e,t){super(),this.filterNameKey=e,this.cssIdentifier=t,this.applyActive=!1,this.debouncePending=!1,this.defaultDebounceMs=0}postConstruct(){const e={tag:"div",cls:`ag-filter-body-wrapper ag-${this.cssIdentifier}-body-wrapper`,children:[this.createBodyTemplate()]};this.setTemplate(e,this.getAgComponents()),this.createManagedBean(new Dr(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.positionableFeature=this.createBean(new Rr(this.getPositionableElement(),{forcePopupParentAsOffsetParent:!0}))}handleKeyDown(e){}init(e){const t=e;this.setParams(t),this.setModelIntoUi(t.state.model,!0).then(()=>this.updateUiVisibility())}refresh(e){const t=e,o=this.params;this.params=t;"colDef"===t.source&&this.updateParams(t,o);const i=t.state,s=this.state;return this.state=i,i.model===s.model&&i.state===s.state||this.setModelIntoUi(i.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=dr(e),this.setupApplyDebounced()}doesFilterPass(e){st(283);const{getHandler:t,model:o,column:i}=this.params;return t().doesFilterPass({...e,model:o,handlerParams:this.beans.colFilter.getHandlerParams(i)})}getFilterTitle(){return this.translate(this.filterNameKey)}isFilterActive(){return st(284),null!=this.params.model}setupApplyDebounced(){const e=lr(this.params,this.defaultDebounceMs),t=Be(this,this.checkApplyDebounce.bind(this),e);this.applyDebounced=()=>{this.debouncePending=!0,t()}}checkApplyDebounce(){this.debouncePending&&(this.debouncePending=!1,this.doApplyModel())}getModel(){return st(285),this.params.model}setModel(e){st(286);const{beans:t,params:o}=this;return t.colFilter.setModelForColumnLegacy(o.column,e)}applyModel(e="api"){return this.doApplyModel()}canApply(e){return!0}doApplyModel(e){const{params:t,state:o}=this,i=!this.areModelsEqual(t.model,o.model);return i&&t.onAction("apply",e),i}onNewRowsLoaded(){}onUiChanged(e,t=!1){this.updateUiVisibility();const o=this.getModelFromUi(),i={model:o,state:this.getState(),valid:this.canApply(o)};this.state=i;const s=this.params;s.onStateChange(i),s.onUiChange(this.getUiChangeEventParams()),this.gos.get("enableFilterHandlers")||this.eventSvc.dispatchEvent({type:"filterModified",column:s.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){const{positionableFeature:t,gos:o}=this;if(!t)return;const i="floatingFilter"===e||"columnFilter"===e;i?(t.restoreLastSize(),t.setResizable(o.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 ar(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 kr(e){return!!e.operator}var Tr={AUTO_HEIGHT:"ag-layout-auto-height",NORMAL:"ag-layout-normal",PRINT:"ag-layout-print"},Ir=class extends Me{constructor(e){super(),this.view=e}postConstruct(){this.addManagedPropertyListener("domLayout",this.updateLayoutClasses.bind(this)),this.updateLayoutClasses()}updateLayoutClasses(){const e=this.gos.get("domLayout"),t={autoHeight:"autoHeight"===e,normal:"normal"===e,print:"print"===e},o=t.autoHeight?Tr.AUTO_HEIGHT:t.print?Tr.PRINT:Tr.NORMAL;this.view.updateLayoutClasses(o,t)}},Ar="Viewport",Lr="fakeVScrollComp",Br=["fakeHScrollComp","centerHeader","topCenter","bottomCenter","stickyTopCenter","stickyBottomCenter"],Hr=class extends Me{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=Be(this,()=>this.lastScrollSource[1]=null,150),this.resetLastVScrollDebounced=Be(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");const e=this.invalidateVerticalScroll.bind(this),t=this.invalidateHorizontalScroll.bind(this);this.addManagedEventListeners({displayedColumnsWidthChanged:this.onDisplayedColumnsWidthChanged.bind(this),gridSizeChanged: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(){this.addManagedElementListeners(this.centerRowsCtrl.eViewport,{scroll:this.onHScroll.bind(this,Ar)});for(const e of Br){const t=this.ctrlsSvc.get(e);this.registerScrollPartner(t,this.onHScroll.bind(this,e))}}addVerticalScrollListeners(){const e=this.ctrlsSvc.get("fakeVScrollComp"),t=this.gos.get("debounceVerticalScrollbar"),o=t?Be(this,this.onVScroll.bind(this,Ar),100):this.onVScroll.bind(this,Ar),i=t?Be(this,this.onVScroll.bind(this,Lr),100):this.onVScroll.bind(this,Lr);this.addManagedElementListeners(this.eBodyViewport,{scroll:o}),this.registerScrollPartner(e,i)}registerScrollPartner(e,t){e.onScrollCallback(t)}onDisplayedColumnsWidthChanged(){this.enableRtl&&this.horizontallyScrollHeaderCenterAndFloatingCenter()}horizontallyScrollHeaderCenterAndFloatingCenter(e){null==this.centerRowsCtrl||(void 0===e&&(e=this.centerRowsCtrl.getCenterViewportScrollLeft()),this.setScrollLeftForAllContainersExceptCurrent(Math.abs(e)))}setScrollLeftForAllContainersExceptCurrent(e){for(const t of[...Br,Ar]){if(this.lastScrollSource[1]===t)continue;j(this.getViewportForSource(t),e,this.enableRtl)}}getViewportForSource(e){return e===Ar?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;const t=this.centerRowsCtrl.eViewport,{scrollLeft:o}=t;if(this.shouldBlockScrollUpdate(1,o,!0))return;const i=K(this.getViewportForSource(e),this.enableRtl);this.doHorizontalScroll(i),this.resetLastHScrollDebounced()}onVScroll(e){if(!this.isControllingScroll(e,0))return;let t;if(t=e===Ar?this.eBodyViewport.scrollTop:this.ctrlsSvc.get("fakeVScrollComp").getScrollPosition(),this.shouldBlockScrollUpdate(0,t,!0))return;const{animationFrameSvc:o}=this;o?.setScrollTop(t),this.nextScrollTop=t,e===Ar?this.ctrlsSvc.get("fakeVScrollComp").setScrollPosition(t):this.eBodyViewport.scrollTop=t,o?.active?o.schedule():this.scrollGridIfNeeded(!0),this.resetLastVScrollDebounced()}doHorizontalScroll(e){const 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){const 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,o=!1){return!(o&&!Zi())&&(0===e?this.shouldBlockVerticalScroll(t):this.shouldBlockHorizontalScroll(t))}shouldBlockVerticalScroll(e){const t=O(this.eBodyViewport),{scrollHeight:o}=this.eBodyViewport;return e<0||e+t>o}shouldBlockHorizontalScroll(e){const t=this.centerRowsCtrl.getCenterWidth(),{scrollWidth:o}=this.centerRowsCtrl.eViewport;if(this.enableRtl){if(e>0)return!0}else if(e<0)return!0;return Math.abs(e)+t>o}redrawRowsAfterScroll(){this.fireScrollEvent(0)}checkScrollLeft(){const e=this.scrollLeft;let t=!1;for(const o of Br){if(this.getViewportForSource(o).scrollLeft!==e){t=!0;break}}t&&this.onHScroll(Ar)}scrollGridIfNeeded(e=!1){const t=this.scrollTop!=this.nextScrollTop;return t&&(this.scrollTop=this.nextScrollTop,e&&this.invalidateVerticalScroll(),this.redrawRowsAfterScroll()),t}setHorizontalScrollPosition(e,t=!1){const o=this.centerRowsCtrl.eViewport.scrollWidth-this.centerRowsCtrl.getCenterWidth();!t&&this.shouldBlockScrollUpdate(1,e)&&(e=this.enableRtl?e>0?0:o:Math.min(Math.max(e,0),o)),j(this.centerRowsCtrl.eViewport,Math.abs(e),this.enableRtl),this.doHorizontalScroll(e)}setVerticalScrollPosition(e){this.invalidateVerticalScroll(),this.eBodyViewport.scrollTop=e}getVScrollPosition(){if(!this.isVerticalPositionInvalidated){const{lastOffsetHeight:e,lastScrollTop:t}=this;return{top:t,bottom:t+e}}this.isVerticalPositionInvalidated=!1;const{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){const t=this.centerRowsCtrl.eViewport.scrollLeft;return this.setHorizontalScrollPosition(t+e),this.centerRowsCtrl.eViewport.scrollLeft-t}scrollToTop(){this.eBodyViewport.scrollTop=0}ensureNodeVisible(e,t=null){const{rowModel:o}=this.beans,i=o.getRowCount();let s=-1;for(let t=0;t<i;t++){const i=o.getRow(t);if("function"==typeof e){if(i&&e(i)){s=t;break}}else if(e===i||e===i.data){s=t;break}}s>=0&&this.ensureIndexVisible(s,t)}ensureIndexVisible(e,t,o=0){if(ct(this.gos,"print"))return;const{rowModel:i}=this.beans,s=i.getRowCount();if("number"!=typeof e||e<0||e>=s)return void st(88,{index:e});this.clearRetryListeners();const{frameworkOverrides:n,pageBounds:r,rowContainerHeight:a,rowRenderer:l}=this.beans;n.wrapIncoming(()=>{const s=this.ctrlsSvc.getGridBodyCtrl(),n=i.getRow(e);let d,h,c=0;this.invalidateVerticalScroll();do{const{stickyTopHeight:e,stickyBottomHeight:o}=s,i=n.rowTop,u=n.rowHeight,g=r.getPixelOffset(),p=n.rowTop-g,m=p+n.rowHeight,f=this.getVScrollPosition(),C=a.divStretchOffset,v=f.top+C,w=f.bottom+C,b=w-v,y=a.getScrollPositionForPixel(p),S=a.getScrollPositionForPixel(m-b),E=Math.min((y+S)/2,p);let R=null;"top"===t?R=y-e:"bottom"===t?R=S+o:"middle"===t?R=E:v+e>p?R=y-e:w-o<m&&(R=S-y>b?y-e:S+o),null!==R&&(this.setVerticalScrollPosition(R),l.redraw({afterScroll:!0})),d=i!==n.rowTop||u!==n.rowHeight,h=e!==s.stickyTopHeight||o!==s.stickyBottomHeight,c++}while((d||h)&&c<10);if(this.animationFrameSvc?.flushAllFrames(),o<10&&(n?.stub||!this.beans.rowAutoHeight?.areRowsMeasured())){const s=this.getVScrollPosition().top;this.clearRetryListenerFncs=this.addManagedEventListeners({bodyScroll:()=>{const e=this.getVScrollPosition().top;s!==e&&this.clearRetryListeners()},modelUpdated:()=>{this.clearRetryListeners(),e>=i.getRowCount()||this.ensureIndexVisible(e,t,o+1)}})}})}clearRetryListeners(){this.clearRetryListenerFncs.forEach(e=>e()),this.clearRetryListenerFncs=[]}ensureColumnVisible(e,t="auto"){const{colModel:o,frameworkOverrides:i}=this.beans,s=o.getCol(e);if(!s)return;if(s.isPinned())return;if(!this.visibleCols.isColDisplayed(s))return;const n=this.getPositionedHorizontalScroll(s,t);i.wrapIncoming(()=>{null!==n&&this.centerRowsCtrl.setCenterViewportScrollLeft(n),this.centerRowsCtrl.onHorizontalViewportChanged(),this.animationFrameSvc?.flushAllFrames()})}getPositionedHorizontalScroll(e,t){const{columnBeforeStart:o,columnAfterEnd:i}=this.isColumnOutsideViewport(e),s=this.centerRowsCtrl.getCenterWidth()<e.getActualWidth(),n=this.centerRowsCtrl.getCenterWidth(),r=this.enableRtl;let a=(r?o:i)||s,l=r?i:o;"auto"!==t&&(a="start"===t,l="end"===t);const d="middle"===t;if(a||l||d){const{colLeft:t,colMiddle:o,colRight:i}=this.getColumnBounds(e);return d?o-n/2:a?r?i:t:r?t-n:i-n}return null}isColumnOutsideViewport(e){const{start:t,end:o}=this.getViewportBounds(),{colLeft:i,colRight:s}=this.getColumnBounds(e),n=this.enableRtl;return{columnBeforeStart:n?t>s:o<s,columnAfterEnd:n?o<i:t>i}}getColumnBounds(e){const t=this.enableRtl,o=this.visibleCols.bodyWidth,i=e.getActualWidth(),s=e.getLeft(),n=t?-1:1,r=t?o-s:s;return{colLeft:r,colMiddle:r+i/2*n,colRight:r+i*n}}getViewportBounds(){const e=this.centerRowsCtrl.getCenterWidth(),t=this.centerRowsCtrl.getCenterViewportScrollLeft();return{start:t,end:e+t,width:e}}},Vr=class extends Me{constructor(e,t=!1){super(),this.callback=e,this.addSpacer=t}postConstruct(){const 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(){const e=ct(this.gos,"print"),{visibleCols:t,scrollVisibleSvc:o}=this.beans,i=t.bodyWidth,s=t.getColsLeftWidth(),n=t.getDisplayedColumnsRightWidth();let r;if(e)r=i+s+n;else if(r=i,this.addSpacer){0===(this.gos.get("enableRtl")?s:n)&&o.verticalScrollShowing&&(r+=o.getScrollbarWidth())}this.callback(r)}},Gr=class extends Me{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(){const{beans:e,centerContainerCtrl:t,gridBodyCtrl:o}=this,i=()=>{ue(e,()=>{this.onCenterViewportResized()})};t.registerViewportResizeListener(i),o.registerBodyViewportResizeListener(i)}onScrollbarWidthChanged(){this.checkViewportAndScrolls()}onCenterViewportResized(){if(this.scrollVisibleSvc.updateScrollGap(),this.centerContainerCtrl.isViewportInTheDOMTree()){const{pinnedCols:e,colFlex:t}=this.beans;e?.keepPinnedColumnsNarrowerThanViewport(),this.checkViewportAndScrolls();const o=this.centerContainerCtrl.getCenterWidth();o!==this.centerWidth&&(this.centerWidth=o,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(){const e=O(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;const e={horizontalScrollShowing:this.centerContainerCtrl.isHorizontalScrollShowing(),verticalScrollShowing:this.gridBodyCtrl.isVerticalScrollShowing()};this.scrollVisibleSvc.setScrollsVisible(e)}onHorizontalViewportChanged(){const e=this.centerContainerCtrl.getCenterWidth(),t=this.centerContainerCtrl.getViewportScrollLeft();this.beans.colViewport.setScrollPosition(e,t)}};function Nr(e,t,o,i){const s=t.getColDef().cellRendererParams?.suppressMouseEventHandling;return Or(e,t,o,i,s)}function Or(e,t,o,i,s){return!!s&&s(zt(e,{column:t,node:o,event:i}))}function zr(e,t,o){let i=t;for(;i;){const t=Ct(e,i,o);if(t)return t;i=i.parentElement}return null}var Wr="cellCtrl";function Ur(e,t){return zr(e,t,Wr)}var $r="renderedRow";function Kr(e,t){return zr(e,t,$r)}function jr(e,t,o,i,s){const n=i?i.getColDef().suppressKeyboardEvent:void 0;if(!n)return!1;const r=zt(e,{event:t,editing:s,column:i,node:o,data:o.data,colDef:i.getColDef()});if(n){if(n(r))return!0}return!1}var qr=class extends Me{constructor(e){super(),this.element=e}postConstruct(){this.addKeyboardListeners(),this.addMouseListeners(),this.beans.touchSvc?.mockRowContextMenu(this),this.editSvc=this.beans.editSvc}addKeyboardListeners(){const e="keydown",t=this.processKeyboardEvent.bind(this,e);this.addManagedElementListeners(this.element,{[e]:t})}addMouseListeners(){["dblclick","contextmenu","mouseover","mouseout","click",be("touchstart")?"touchstart":"mousedown"].forEach(e=>{const t=this.processMouseEvent.bind(this,e);this.addManagedElementListeners(this.element,{[e]:t})})}processMouseEvent(e,t){if(!Re(this.beans,t)||Pr(t))return;const{cellCtrl:o,rowCtrl:i}=this.getControlsForEventTarget(t.target);"contextmenu"===e?(o?.column&&o.dispatchCellContextMenuEvent(t),this.beans.contextMenuSvc?.handleContextMenuMouseEvent(t,void 0,i,o)):(o&&o.onMouseEvent(e,t),i&&i.onMouseEvent(e,t))}getControlsForEventTarget(e){const{gos:t}=this;return{cellCtrl:Ur(t,e),rowCtrl:Kr(t,e)}}processKeyboardEvent(e,t){const{cellCtrl:o,rowCtrl:i}=this.getControlsForEventTarget(t.target);t.defaultPrevented||(o?this.processCellKeyboardEvent(o,e,t):i?.isFullWidth()&&this.processFullWidthRowKeyboardEvent(i,e,t))}processCellKeyboardEvent(e,t,o){const i=this.editSvc?.isEditing(e,{withOpenEditor:!0})??!1;if(!jr(this.gos,o,e.rowNode,e.column,i)&&"keydown"===t){!i&&this.beans.navigation?.handlePageScrollingKey(o)||e.onKeyDown(o),this.doGridOperations(o,i),ps(o)&&e.processCharacter(o)}"keydown"===t&&this.eventSvc.dispatchEvent(e.createEvent(o,"cellKeyDown"))}processFullWidthRowKeyboardEvent(e,t,o){const{rowNode:i}=e,{focusSvc:s,navigation:n}=this.beans,r=s.getFocusedCell(),a=r?.column;if(!jr(this.gos,o,i,a,!1)){const i=o.key;if("keydown"===t)switch(i){case Gi:case Ni:case Hi:case Vi:n?.handlePageScrollingKey(o,!0);break;case ki:case Ii:if(!this.gos.get("embedFullWidthRows"))break;case Ti:case Ai:e.onKeyboardNavigate(o);break;case Fi:e.onTabKeyDown(o)}}"keydown"===t&&this.eventSvc.dispatchEvent(e.createRowEvent("cellKeyDown",o))}doGridOperations(e,t){if(!e.ctrlKey&&!e.metaKey)return;if(t)return;if(!Re(this.beans,e))return;const o=function(e){const{keyCode:t}=e;let o;switch(t){case 65:o=Oi;break;case 67:o=zi;break;case 86:o=Ui;break;case 68:o=Wi;break;case 90:o=ji;break;case 89:o=Ki;break;default:o=e.code}return o}(e),{clipboardSvc:i,undoRedo:s}=this.beans;return o===Oi?this.onCtrlAndA(e):o===zi?this.onCtrlAndC(i,e):o===Wi?this.onCtrlAndD(i,e):o===Ui?this.onCtrlAndV(i,e):o===$i?this.onCtrlAndX(i,e):o===Ki?this.onCtrlAndY(s):o===ji?this.onCtrlAndZ(s,e):void 0}onCtrlAndA(e){const{beans:{rowModel:t,rangeSvc:o,selectionSvc:i},gos:s}=this;o&&Tt(s)&&t.isRowsToRender()?function(e){const{pinnedRowModel:t,rowModel:o}=e,[i,s]=[t?.isEmpty("top")??!0,t?.isEmpty("bottom")??!0],n=i?null:"top";let r,a;s?(r=null,a=o.getRowCount()-1):(r="bottom",a=t?.getPinnedBottomRowCount()??-1);const{visibleCols:l,rangeSvc:d}=e,h=l.allCols;d&&h?.length&&d.setCellRange({rowStartIndex:0,rowStartPinned:n,rowEndIndex:a,rowEndPinned:r})}(this.beans):i&&i?.selectAllRowNodes({source:"keyboardSelectAll",selectAll:Vt(s)}),e.preventDefault()}onCtrlAndC(e,t){if(!e||this.gos.get("enableCellTextSelection"))return;const{cellCtrl:o}=this.getControlsForEventTarget(t.target);this.editSvc?.isEditing(o,{withOpenEditor:!0})||(t.preventDefault(),e.copyToClipboard())}onCtrlAndX(e,t){if(!e||this.gos.get("enableCellTextSelection")||this.gos.get("suppressCutToClipboard"))return;const{cellCtrl:o}=this.getControlsForEventTarget(t.target);this.editSvc?.isEditing(o,{withOpenEditor:!0})||(t.preventDefault(),e.cutToClipboard(void 0,"ui"))}onCtrlAndV(e,t){const{cellCtrl:o}=this.getControlsForEventTarget(t.target);this.editSvc?.isEditing(o,{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")}},_r=class extends Me{constructor(e,t){super(),this.eContainer=e,this.eViewport=t}postConstruct(){this.addManagedEventListeners({rowContainerHeightChanged:this.onHeightChanged.bind(this,this.beans.rowContainerHeight)})}onHeightChanged(e){const t=e.uiContainerHeight,o=null!=t?`${t}px`:"";this.eContainer.style.height=o,this.eViewport&&(this.eViewport.style.height=o)}},Yr=e=>e.topRowCtrls,Qr=e=>e.getStickyTopRowCtrls(),Zr=e=>e.getStickyBottomRowCtrls(),Jr=e=>e.bottomRowCtrls,Xr=e=>e.allRowCtrls,ea=e=>e.getCtrls("top"),ta=e=>e.getCtrls("center"),oa=e=>e.getCtrls("bottom"),ia={center:{type:"center",name:"center-cols",getRowCtrls:Xr,getSpannedRowCtrls:ta},left:{type:"left",name:"pinned-left-cols",pinnedType:"left",getRowCtrls:Xr,getSpannedRowCtrls:ta},right:{type:"right",name:"pinned-right-cols",pinnedType:"right",getRowCtrls:Xr,getSpannedRowCtrls:ta},fullWidth:{type:"fullWidth",name:"full-width",fullWidth:!0,getRowCtrls:Xr},topCenter:{type:"center",name:"floating-top",getRowCtrls:Yr,getSpannedRowCtrls:ea},topLeft:{type:"left",name:"pinned-left-floating",container:"ag-pinned-left-floating-top",pinnedType:"left",getRowCtrls:Yr,getSpannedRowCtrls:ea},topRight:{type:"right",name:"pinned-right-floating",container:"ag-pinned-right-floating-top",pinnedType:"right",getRowCtrls:Yr,getSpannedRowCtrls:ea},topFullWidth:{type:"fullWidth",name:"floating-top-full-width",fullWidth:!0,getRowCtrls:Yr},stickyTopCenter:{type:"center",name:"sticky-top",getRowCtrls:Qr},stickyTopLeft:{type:"left",name:"pinned-left-sticky-top",container:"ag-pinned-left-sticky-top",pinnedType:"left",getRowCtrls:Qr},stickyTopRight:{type:"right",name:"pinned-right-sticky-top",container:"ag-pinned-right-sticky-top",pinnedType:"right",getRowCtrls:Qr},stickyTopFullWidth:{type:"fullWidth",name:"sticky-top-full-width",fullWidth:!0,getRowCtrls:Qr},stickyBottomCenter:{type:"center",name:"sticky-bottom",getRowCtrls:Zr},stickyBottomLeft:{type:"left",name:"pinned-left-sticky-bottom",container:"ag-pinned-left-sticky-bottom",pinnedType:"left",getRowCtrls:Zr},stickyBottomRight:{type:"right",name:"pinned-right-sticky-bottom",container:"ag-pinned-right-sticky-bottom",pinnedType:"right",getRowCtrls:Zr},stickyBottomFullWidth:{type:"fullWidth",name:"sticky-bottom-full-width",fullWidth:!0,getRowCtrls:Zr},bottomCenter:{type:"center",name:"floating-bottom",getRowCtrls:Jr,getSpannedRowCtrls:oa},bottomLeft:{type:"left",name:"pinned-left-floating-bottom",container:"ag-pinned-left-floating-bottom",pinnedType:"left",getRowCtrls:Jr,getSpannedRowCtrls:oa},bottomRight:{type:"right",name:"pinned-right-floating-bottom",container:"ag-pinned-right-floating-bottom",pinnedType:"right",getRowCtrls:Jr,getSpannedRowCtrls:oa},bottomFullWidth:{type:"fullWidth",name:"floating-bottom-full-width",fullWidth:!0,getRowCtrls:Jr}};function sa(e){return`ag-${aa(e).name}-viewport`}function na(e){const t=aa(e);return t.container??`ag-${t.name}-container`}function ra(e){return`ag-${aa(e).name}-spanned-cells-container`}function aa(e){return ia[e]}var la=["center","left","right","fullWidth"],da=["stickyTopCenter","stickyBottomCenter","center","topCenter","bottomCenter"],ha=["left","bottomLeft","topLeft","stickyTopLeft","stickyBottomLeft"],ca=["right","bottomRight","topRight","stickyTopRight","stickyBottomRight"],ua=["stickyTopCenter","stickyTopLeft","stickyTopRight"],ga=["stickyBottomCenter","stickyBottomLeft","stickyBottomRight"],pa=[...ua,"stickyTopFullWidth",...ga,"stickyBottomFullWidth"],ma=["topCenter","topLeft","topRight","bottomCenter","bottomLeft","bottomRight","center","left","right",...ua,...ga],fa=class extends Me{constructor(e){super(),this.name=e,this.visible=!0,this.EMPTY_CTRLS=[],this.options=aa(e)}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.forContainers(["center"],()=>{this.viewportSizeFeature=this.createManagedBean(new Gr(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,o,i){this.comp=e,this.eContainer=t,this.eSpannedContainer=o,this.eViewport=i,this.createManagedBean(new qr(this.eViewport??this.eContainer)),this.addPreventScrollWhileDragging(),this.listenOnDomOrder();const{pinnedCols:s,rangeSvc:n}=this.beans,r=()=>this.onPinnedWidthChanged();this.forContainers(ha,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(s?.createPinnedWidthFeature(!0,this.eContainer,this.eSpannedContainer)),this.addManagedEventListeners({leftPinnedWidthChanged:r})}),this.forContainers(ca,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(s?.createPinnedWidthFeature(!1,this.eContainer,this.eSpannedContainer)),this.addManagedEventListeners({rightPinnedWidthChanged:r})}),this.forContainers(la,()=>this.createManagedBean(new _r(this.eContainer,"center"===this.name?i:void 0))),n&&this.forContainers(ma,()=>this.createManagedBean(n.createDragListenerFeature(this.eContainer))),this.forContainers(da,()=>this.createManagedBean(new Vr(e=>this.comp.setContainerWidth(`${e}px`)))),this.visible=this.isContainerVisible(),this.addListeners(),this.registerWithCtrlsService()}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}addListeners(){const{spannedRowRenderer:e,gos:t}=this.beans,o=this.onDisplayedColumnsChanged.bind(this);this.addManagedEventListeners({displayedColumnsChanged:o,displayedColumnsWidthChanged:o,displayedRowsChanged:e=>this.onDisplayedRowsChanged(e.afterScroll)}),o(),this.onDisplayedRowsChanged(),e&&this.options.getSpannedRowCtrls&&t.get("enableCellSpan")&&this.addManagedListeners(e,{spannedRowsUpdated:()=>{const t=this.options.getSpannedRowCtrls(e);t&&this.comp.setSpannedRowCtrls(t,!1)}})}listenOnDomOrder(){if(pa.indexOf(this.name)>=0)return void this.comp.setDomOrder(!0);const e=()=>{const e=this.gos.get("ensureDomOrder"),t=ct(this.gos,"print");this.comp.setDomOrder(e||t)};this.addManagedPropertyListener("domLayout",e),e()}onDisplayedColumnsChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}addPreventScrollWhileDragging(){const{dragSvc:e}=this.beans;if(!e)return;const 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){const t=this.getCenterWidth(),o=this.getCenterViewportScrollLeft();this.beans.colViewport.setScrollPosition(t,o,e)}hasHorizontalScrollGap(){return this.eContainer.clientWidth-this.eViewport.clientWidth<0}hasVerticalScrollGap(){return this.eContainer.clientHeight-this.eViewport.clientHeight<0}getCenterWidth(){return z(this.eViewport)}getCenterViewportScrollLeft(){return K(this.eViewport,this.enableRtl)}registerViewportResizeListener(e){const t=ce(this.beans,this.eViewport,e);this.addDestroyFunc(()=>t())}isViewportInTheDOMTree(){return Y(this.eViewport)}getViewportScrollLeft(){return K(this.eViewport,this.enableRtl)}isHorizontalScrollShowing(){return this.gos.get("alwaysShowHorizontalScroll")||ie(this.eViewport)}setHorizontalScroll(e){this.comp.setHorizontalScroll(e)}getHScrollPosition(){return{left:this.eViewport.scrollLeft,right:this.eViewport.scrollLeft+this.eViewport.offsetWidth}}setCenterViewportScrollLeft(e){j(this.eViewport,e,this.enableRtl)}isContainerVisible(){return!(null!=this.options.pinnedType)||!!this.pinnedWidthFeature&&this.pinnedWidthFeature.getWidth()>0}onPinnedWidthChanged(){const e=this.isContainerVisible();this.visible!=e&&(this.visible=e,this.onDisplayedRowsChanged())}onDisplayedRowsChanged(e=!1){const t=this.options.getRowCtrls(this.beans.rowRenderer);if(!this.visible||0===t.length)return void this.comp.setRowCtrls({rowCtrls:this.EMPTY_CTRLS});const o=ct(this.gos,"print"),i=this.gos.get("embedFullWidthRows")||o,s=t.filter(e=>{const t=e.isFullWidth();return this.options.fullWidth?!i&&t:i||!t});this.comp.setRowCtrls({rowCtrls:s,useFlushSync:e})}},Ca="ag-force-vertical-scroll",va=class extends Me{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,o,i,s,n,r){this.comp=e,this.eGridBody=t,this.eBodyViewport=o,this.eTop=i,this.eBottom=s,this.eStickyTop=n,this.eStickyBottom=r,this.eCenterColsViewport=o.querySelector(`.${sa("center")}`),this.eFullWidthContainer=o.querySelector(`.${na("fullWidth")}`),this.eStickyTopFullWidthContainer=n.querySelector(`.${na("stickyTopFullWidth")}`),this.eStickyBottomFullWidthContainer=r.querySelector(`.${na("stickyBottomFullWidth")}`),this.setCellTextSelection(this.gos.get("enableCellTextSelection")),this.addManagedPropertyListener("enableCellTextSelection",e=>this.setCellTextSelection(e.currentValue)),this.createManagedBean(new Ir(this.comp)),this.scrollFeature=this.createManagedBean(new Hr(o)),this.beans.rowDragSvc?.setupRowDrag(o,this),this.setupRowAnimationCssClass(),this.addEventListeners(),this.addFocusListeners([i,o,s,n,r]),this.setGridRootRole(),this.onGridColumnsChanged(),this.addBodyViewportListener(),this.setFloatingHeights(),this.disableBrowserDragging(),this.addStopEditingWhenGridLosesFocus(),this.updateScrollingClasses(),this.filterManager?.setupAdvFilterHeaderComp(i),this.ctrlsSvc.register("gridBodyCtrl",this)}addEventListeners(){const e=this.setFloatingHeights.bind(this),t=this.setGridRootRole.bind(this),o=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:o,rowResizeEnded:o}),this.addManagedPropertyListener("treeData",t)}toggleRowResizeStyles(e){const t="rowResizeStarted"===e.type;this.eBodyViewport.classList.toggle("ag-prevent-animation",t)}onGridColumnsChanged(){const e=this.beans.colModel.getCols();this.comp.setColumnCount(e.length)}onScrollVisibilityChanged(){const{scrollVisibleSvc:e}=this,t=e.verticalScrollShowing;this.setVerticalScrollPaddingVisible(t),this.setStickyWidth(t),this.setStickyBottomOffsetBottom();const o=`calc(100% + ${(t&&e.getScrollbarWidth()||0)+(es()?16:0)}px)`;ue(this.beans,()=>this.comp.setBodyViewportWidth(o)),this.updateScrollingClasses()}setGridRootRole(){const{rowGroupColsSvc:e,colModel:t}=this;let o=this.gos.get("treeData");if(!o){const i=t.isPivotMode();o=(e?e.columns.length:0)>=(i?2:1)}this.comp.setGridRootRole(o?"treegrid":"grid")}addFocusListeners(e){e.forEach(e=>{this.addManagedElementListeners(e,{focusin:t=>{const{target:o}=t,i=G(o,"ag-root",e);e.classList.toggle("ag-has-focus",!i)},focusout:t=>{const{target:o,relatedTarget:i}=t,s=e.contains(i),n=G(i,"ag-root",e);G(o,"ag-root",e)||s&&!n||e.classList.remove("ag-has-focus")}})})}setColumnMovingCss(e){this.comp.setColumnMovingCss("ag-column-moving",e)}setCellTextSelection(e=!1){this.comp.setCellSelectableCss("ag-selectable",e)}updateScrollingClasses(){const{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(){const e=(this.ctrlsSvc.getHeaderRowContainerCtrl()?.getRowCount()??0)+(this.filterManager?.getHeaderRowCount()??0),{rowModel:t}=this.beans,o=t.isLastRowIndexKnown()?t.getRowCount():-1,i=-1===o?-1:e+o;this.comp.setRowCount(i)}registerBodyViewportResizeListener(e){this.comp.registerBodyViewportResizeListener(e)}setVerticalScrollPaddingVisible(e){const t=e?"scroll":"hidden";this.comp.setPinnedTopBottomOverflowY(t)}isVerticalScrollShowing(){const e=this.gos.get("alwaysShowVerticalScroll"),t=e?Ca:null,o=ct(this.gos,"normal");return this.comp.setAlwaysVerticalScrollClass(t,e),e||o&&se(this.eBodyViewport)}setupRowAnimationCssClass(){const{rowContainerHeight:e,environment:t}=this.beans;let o=t.sizesMeasured;const i=()=>{const t=o&&wt(this.gos)&&!e.stretching,i=t?"ag-row-animation":"ag-row-no-animation";this.comp.setRowAnimationCssOnBodyViewport(i,t)};i(),this.addManagedEventListeners({heightScaleChanged:i}),this.addManagedPropertyListener("animateRows",i),this.addManagedEventListeners({gridStylesChanged:()=>{!o&&t.sizesMeasured&&(o=!0,i())}})}addBodyViewportListener(){const{eBodyViewport:e,eStickyTop:t,eStickyBottom:o,eTop:i,eBottom:s,beans:{popupSvc:n,touchSvc:r}}=this,a=this.onBodyViewportContextMenu.bind(this);this.addManagedElementListeners(e,{contextmenu:a}),r?.mockBodyContextMenu(this,a),this.addManagedElementListeners(e,{wheel:this.onBodyViewportWheel.bind(this,n)});const l=this.onStickyWheel.bind(this);for(const e of[t,o,i,s])this.addManagedElementListeners(e,{wheel:l});const d=this.onHorizontalWheel.bind(this);for(const 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){const{deltaX:t,deltaY:o,shiftKey:i}=e;(i||Math.abs(t)>Math.abs(o))&&Re(this.beans,e)&&this.scrollGridBodyToMatchEvent(e)}onStickyWheel(e){const{deltaY:t}=e;this.scrollVertically(t)>0&&e.preventDefault()}onHorizontalWheel(e){const{deltaX:t,deltaY:o,shiftKey:i}=e;(i||Math.abs(t)>Math.abs(o))&&this.scrollGridBodyToMatchEvent(e)}scrollGridBodyToMatchEvent(e){const{deltaX:t,deltaY:o}=e;e.preventDefault(),this.eCenterColsViewport.scrollBy({left:t||o})}onBodyViewportContextMenu(e,t,o){if(!e&&!o)return;if(this.gos.get("preventDefaultOnContextMenu")){(e||o).preventDefault()}const{target:i}=e||t;i!==this.eBodyViewport&&i!==this.ctrlsSvc.get("center").eViewport||this.beans.contextMenuSvc?.showContextMenu({mouseEvent:e,touchEvent:o,value:null,anchorToElement:this.eGridBody,source:"ui"})}onBodyViewportWheel(e,t){this.gos.get("suppressScrollWhenPopupsAreOpen")&&e?.hasAnchoredPopup()&&t.preventDefault()}scrollVertically(e){const t=this.eBodyViewport.scrollTop;return this.scrollFeature.setVerticalScrollPosition(t+e),this.eBodyViewport.scrollTop-t}setFloatingHeights(){const{pinnedRowModel:e,beans:{environment:t}}=this,o=e?.getPinnedTopTotalHeight(),i=e?.getPinnedBottomTotalHeight(),s=t.getPinnedRowBorderWidth()-t.getRowBorderWidth(),n=o?s+o:0,r=i?s+i:0;this.comp.setTopHeight(n),this.comp.setBottomHeight(r),this.comp.setTopInvisible(n<=0),this.comp.setBottomInvisible(r<=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){const 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(){const e=this.ctrlsSvc.get("gridHeaderCtrl").headerHeight+(this.filterManager?.getHeaderHeight()??0),t=this.pinnedRowModel?.getPinnedTopTotalHeight()??0;let o=0;e>0&&(o+=e),t>0&&(o+=t),o>0&&(o+=1),this.comp.setStickyTopTop(`${o}px`)}setStickyBottomOffsetBottom(){const{pinnedRowModel:e,scrollVisibleSvc:t,comp:o}=this,i=(e?.getPinnedBottomTotalHeight()??0)+(t.horizontalScrollShowing&&t.getScrollbarWidth()||0);o.setStickyBottomBottom(`${i}px`)}};function wa(e,t){const o=ct(e.gos,"normal"),i=t;let s,n;null!=i.clientX||null!=i.clientY?(s=i.clientX,n=i.clientY):(s=i.x,n=i.y);const{pageFirstPixel:r}=e.pageBounds.getCurrentPagePixelRange();if(n+=r,o){const t=e.ctrlsSvc.getScrollFeature(),o=t.getVScrollPosition();s+=t.getHScrollPosition().left,n+=o.top}return{x:s,y:n}}var ba=class extends Uo{constructor(e,t){super(),this.direction=t,this.eViewport=Go,this.eContainer=Go,this.hideTimeout=0,this.setTemplate(e)}postConstruct(){this.addManagedEventListeners({scrollVisibilityChanged:this.onScrollVisibilityChanged.bind(this)}),this.onScrollVisibilityChanged(),this.toggleCss("ag-apple-scrollbar",Qi()||Zi())}destroy(){super.destroy(),window.clearTimeout(this.hideTimeout)}initialiseInvisibleScrollbar(){void 0===this.invisibleScrollbar&&(this.invisibleScrollbar=es(),this.invisibleScrollbar&&(this.hideAndShowInvisibleScrollAsNeeded(),this.addActiveListenerToggles()))}addActiveListenerToggles(){const e=this.getGui(),t=()=>this.toggleCss("ag-scrollbar-active",!0),o=()=>this.toggleCss("ag-scrollbar-active",!1);this.addManagedListeners(e,{mouseenter:t,mousedown:t,touchstart:t,mouseleave:o,touchend:o})}onScrollVisibilityChanged(){void 0===this.invisibleScrollbar&&this.initialiseInvisibleScrollbar(),ue(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){const t=this.eViewport;!function(e,t,o,i=100){const s=Date.now();let n=null,r=!1;const a=()=>{null!=n&&(window.clearInterval(n),n=null)};e.addDestroyFunc(a);const l=()=>{const e=Date.now()-s>i;(t()||e)&&(o(),r=!0,a())};l(),r||(n=window.setInterval(l,10))}(this,()=>Q(t),()=>this.setScrollPosition(e),100)}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}},ya={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"}]},Sa={selector:"AG-FAKE-HORIZONTAL-SCROLL",component:class extends ba{constructor(){super(ya,"horizontal"),this.eLeftSpacer=Go,this.eRightSpacer=Go,this.setScrollVisibleDebounce=0}wireBeans(e){this.visibleCols=e.visibleCols,this.scrollVisibleSvc=e.scrollVisibleSvc}postConstruct(){super.postConstruct();const 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 Vr(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;const e=this.beans.pinnedRowModel?.getPinnedBottomTotalHeight()??0;this.getGui().style.bottom=`${e}px`}onScrollVisibilityChanged(){super.onScrollVisibilityChanged(),this.setFakeHScrollSpacerWidths()}setFakeHScrollSpacerWidths(){const e=this.scrollVisibleSvc.verticalScrollShowing;let t=this.visibleCols.getDisplayedColumnsRightWidth();const o=!this.enableRtl&&e,i=this.scrollVisibleSvc.getScrollbarWidth();o&&(t+=i),re(this.eRightSpacer,t),this.eRightSpacer.classList.toggle("ag-scroller-corner",t<=i);let s=this.visibleCols.getColsLeftWidth();this.enableRtl&&e&&(s+=i),re(this.eLeftSpacer,s),this.eLeftSpacer.classList.toggle("ag-scroller-corner",s<=i)}setScrollVisible(){const e=this.scrollVisibleSvc.horizontalScrollShowing,t=this.invisibleScrollbar,o=this.gos.get("suppressHorizontalScroll"),i=e&&this.scrollVisibleSvc.getScrollbarWidth()||0,s=o?0:0===i&&t?16:i,n=()=>{this.setScrollVisibleDebounce=0,this.toggleCss("ag-scrollbar-invisible",t),ae(this.getGui(),s),ae(this.eViewport,s),ae(this.eContainer,s),s||this.eContainer.style.setProperty("min-height","1px"),this.setVisible(e,{skipAriaHidden:!0})};window.clearTimeout(this.setScrollVisibleDebounce),e?this.setScrollVisibleDebounce=window.setTimeout(n,100):n()}getScrollPosition(){return K(this.eViewport,this.enableRtl)}setScrollPosition(e){Q(this.eViewport)||this.attemptSettingScrollPosition(e),j(this.eViewport,e,this.enableRtl)}}},Ea={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"}]}]},Ra={selector:"AG-FAKE-VERTICAL-SCROLL",component:class extends ba{constructor(){super(Ea,"vertical")}postConstruct(){super.postConstruct(),this.createManagedBean(new _r(this.eContainer));const{ctrlsSvc:e}=this.beans;e.register("fakeVScrollComp",this),this.addManagedEventListeners({rowContainerHeightChanged:this.onRowContainerHeightChanged.bind(this,e)})}setScrollVisible(){const{scrollVisibleSvc:e}=this.beans,t=e.verticalScrollShowing,o=this.invisibleScrollbar,i=t&&e.getScrollbarWidth()||0,s=0===i&&o?16:i;this.toggleCss("ag-scrollbar-invisible",o),re(this.getGui(),s),re(this.eViewport,s),re(this.eContainer,s),this.setDisplayed(t,{skipAriaHidden:!0})}onRowContainerHeightChanged(e){const t=e.getGridBodyCtrl().eBodyViewport,o=this.getScrollPosition(),i=t.scrollTop;o!=i&&this.setScrollPosition(i,!0)}getScrollPosition(){return this.eViewport.scrollTop}setScrollPosition(e,t){t||Q(this.eViewport)||this.attemptSettingScrollPosition(e),this.eViewport.scrollTop=e}}};function xa(e,t,o,s){return i(e)?[]:function(e,t,o,s,n){if(i(e))return[];let r;if("function"==typeof e){const i=function(e,t,o,i){return zt(t,{colDef:e,column:o,columnGroup:i})}(t,o,s,n);r=e(i)}else r=e;if("string"==typeof r)return[r];if(Array.isArray(r))return[...r];return[]}(e.headerClass,e,t,o,s)}function Fa(e,t,o){e.toggleCss("ag-column-first",o.isColAtEdge(t,"first")),e.toggleCss("ag-column-last",o.isColAtEdge(t,"last"))}function Pa(e){return e.gos.get("suppressHeaderFocus")||!!e.overlays?.isExclusive()}function Da(e){return e.gos.get("suppressCellFocus")||!!e.overlays?.isExclusive()}function Ma(e,t,o=!1){const i=e.ctrlsSvc.get("gridCtrl");return!(o||!i.focusNextInnerContainer(t))||((o||!t&&!i.isDetailGrid())&&i.forceFocusOutOfContainer(t),!1)}function ka(e){return e.ctrlsSvc.getHeaderRowContainerCtrl()?.getRowCount()??0}function Ta(e){const t=[],o=e.ctrlsSvc.getHeaderRowContainerCtrls();for(const i of o){if(!i)continue;const o=i.getGroupRowCount()||0;for(let s=0;s<o;s++){const o=i.getGroupRowCtrlAtIndex(s),n=t[s];if(o){const i=Ia(e,o);(null==n||i>n)&&(t[s]=i)}}}return t}function Ia(e,t){let o=e.colModel.isPivotMode()?function(e){return e.gos.get("pivotGroupHeaderHeight")??Ha(e)}(e):Ha(e);const i=t.getHeaderCellCtrls();for(const e of i){const{column:t}=e,i=t.getAutoHeaderHeight();null!=i&&i>o&&t.isAutoHeaderHeight()&&(o=i)}return o}function Aa(e){let t=e.colModel.isPivotMode()?function(e){return e.gos.get("pivotHeaderHeight")??La(e)}(e):La(e);return e.colModel.forAllCols(e=>{const o=e.getAutoHeaderHeight();null!=o&&o>t&&e.isAutoHeaderHeight()&&(t=o)}),t}function La(e){return e.gos.get("headerHeight")??e.environment.getDefaultHeaderHeight()}function Ba(e){return e.gos.get("floatingFiltersHeight")??La(e)}function Ha(e){return e.gos.get("groupHeaderHeight")??La(e)}var Va=class extends Me{setComp(e,t,o){this.comp=e,this.eGui=t;const{beans:i}=this,{headerNavigation:s,touchSvc:n,ctrlsSvc:r}=i;s&&this.createManagedBean(new Dr(o,{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();const a=this.onHeaderContextMenu.bind(this);this.addManagedElementListeners(this.eGui,{contextmenu:a}),n?.mockHeaderContextMenu(this,a),r.register("gridHeaderCtrl",this)}setupHeaderHeight(){const e=this.setHeaderHeight.bind(this);e(),this.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],e),this.addManagedEventListeners({headerRowsChanged:e,columnHeaderHeightChanged:e,columnGroupHeaderHeightChanged:()=>ue(this.beans,()=>e()),gridStylesChanged:e,advancedFilterEnabledChanged:e})}setHeaderHeight(){const{beans:e}=this;let t=0;const o=Ta(e).reduce((e,t)=>e+t,0),i=Aa(e);if(e.filterManager?.hasFloatingFilters()&&(t+=Ba(e)),t+=o,t+=i,this.headerHeight===t)return;this.headerHeight=t;const s=`${t+1}px`;this.comp.setHeightAndMinHeight(s),this.eventSvc.dispatchEvent({type:"headerHeightChanged"})}onPivotModeChanged(e){const t=e.colModel.isPivotMode();this.comp.toggleCss("ag-pivot-on",t),this.comp.toggleCss("ag-pivot-off",!t)}onDisplayedColumnsChanged(e){const t=e.visibleCols.allCols.some(e=>e.isSpanHeaderHeight());this.comp.toggleCss("ag-header-allow-overflow",t)}onTabKeyDown(e){const t=this.gos.get("enableRtl"),o=e.shiftKey,i=o!==t?"LEFT":"RIGHT",{beans:s}=this,{headerNavigation:n,focusSvc:r}=s;(n.navigateHorizontally(i,!0,e)||!o&&r.focusOverlay(!1)||Ma(s,o,!0))&&e.preventDefault()}handleKeyDown(e){let t=null;const{headerNavigation:i}=this.beans;switch(e.key){case ki:t="LEFT";case Ii:o(t)||(t="RIGHT"),i.navigateHorizontally(t,!1,e)&&e.preventDefault();break;case Ti:t="UP";case Ai:o(t)||(t="DOWN"),i.navigateVertically(t,e)&&e.preventDefault();break;default:return}}onFocusOut(e){const{relatedTarget:t}=e,{eGui:o,beans:i}=this;!t&&o.contains(u(i))||o.contains(t)||(i.focusSvc.focusedHeader=null)}onHeaderContextMenu(e,t,o){const{menuSvc:i,ctrlsSvc:s}=this.beans;if(!e&&!o||!i?.isHeaderContextMenuEnabled())return;const{target:n}=e??t;n!==this.eGui&&n!==s.getHeaderRowContainerCtrl()?.eViewport||i.showHeaderContextMenu(void 0,e,o)}},Ga=class extends Uo{constructor(e,t){super(e),this.ctrl=t}getCtrl(){return this.ctrl}},Na={tag:"div",cls:"ag-header-cell",role:"columnheader",children:[{tag:"div",ref:"eResize",cls:"ag-header-cell-resize",role:"presentation"},{tag:"div",ref:"eHeaderCompWrapper",cls:"ag-header-cell-comp-wrapper",role:"presentation"}]},Oa=class extends Ga{constructor(e){super(Na,e),this.eResize=Go,this.eHeaderCompWrapper=Go,this.headerCompVersion=0}postConstruct(){const e=this.getGui(),t=()=>{const e=this.ctrl.getSelectAllGui();e&&(this.eResize.insertAdjacentElement("afterend",e),this.addDestroyFunc(()=>e.remove()))},o={setWidth:t=>e.style.width=t,toggleCss:(e,t)=>this.toggleCss(e,t),setUserStyles:t=>te(e,t),setAriaSort:t=>t?function(e,t){v(e,"sort",t)}(e,t):void w(e,"sort"),setUserCompDetails:e=>this.setUserCompDetails(e),getUserCompInstance:()=>this.headerComp,refreshSelectAllGui:t,removeSelectAllGui:()=>this.ctrl.getSelectAllGui()?.remove()};this.ctrl.setComp(o,this.getGui(),this.eResize,this.eHeaderCompWrapper,void 0),t()}destroy(){this.destroyHeaderComp(),super.destroy()}destroyHeaderComp(){this.headerComp&&(this.eHeaderCompWrapper.removeChild(this.headerCompGui),this.headerComp=this.destroyBean(this.headerComp),this.headerCompGui=void 0)}setUserCompDetails(e){this.headerCompVersion++;const t=this.headerCompVersion;e.newAgStackInstance().then(e=>this.afterCompCreated(t,e))}afterCompCreated(e,t){e==this.headerCompVersion&&this.isAlive()?(this.destroyHeaderComp(),this.headerComp=t,this.headerCompGui=t.getGui(),this.eHeaderCompWrapper.appendChild(this.headerCompGui),this.ctrl.setDragSource(this.getGui())):this.destroyBean(t)}},za={tag:"div",cls:"ag-header-group-cell",role:"columnheader",children:[{tag:"div",ref:"eHeaderCompWrapper",cls:"ag-header-cell-comp-wrapper",role:"presentation"},{tag:"div",ref:"eResize",cls:"ag-header-cell-resize",role:"presentation"}]},Wa=class extends Ga{constructor(e){super(za,e),this.eResize=Go,this.eHeaderCompWrapper=Go}postConstruct(){const e=this.getGui(),t={toggleCss:(e,t)=>this.toggleCss(e,t),setUserStyles:t=>te(e,t),setHeaderWrapperHidden:e=>{e?this.eHeaderCompWrapper.style.setProperty("display","none"):this.eHeaderCompWrapper.style.removeProperty("display")},setHeaderWrapperMaxHeight:e=>{null!=e?this.eHeaderCompWrapper.style.setProperty("max-height",`${e}px`):this.eHeaderCompWrapper.style.removeProperty("max-height"),this.eHeaderCompWrapper.classList.toggle("ag-header-cell-comp-wrapper-limited-height",null!=e)},setResizableDisplayed:e=>H(this.eResize,e),setWidth:t=>e.style.width=t,setAriaExpanded:t=>{return o="aria-expanded",null!=(i=t)?e.setAttribute(o,i):e.removeAttribute(o);var o,i},setUserCompDetails:e=>this.setUserCompDetails(e),getUserCompInstance:()=>this.headerGroupComp};this.ctrl.setComp(t,e,this.eResize,this.eHeaderCompWrapper,void 0)}setUserCompDetails(e){e.newAgStackInstance().then(e=>this.afterHeaderCompCreated(e))}afterHeaderCompCreated(e){const t=()=>this.destroyBean(e);if(!this.isAlive())return void t();const o=this.getGui(),i=e.getGui();this.eHeaderCompWrapper.appendChild(i),this.addDestroyFunc(t),this.headerGroupComp=e,this.ctrl.setDragSource(o)}},Ua={tag:"div",cls:"ag-header-cell ag-floating-filter",role:"gridcell",children:[{tag:"div",ref:"eFloatingFilterBody",role:"presentation"},{tag:"div",ref:"eButtonWrapper",cls:"ag-floating-filter-button ag-hidden",role:"presentation",children:[{tag:"button",ref:"eButtonShowMainFilter",cls:"ag-button ag-floating-filter-button-button",attrs:{type:"button",tabindex:"-1"}}]}]},$a=class extends Ga{constructor(e){super(Ua,e),this.eFloatingFilterBody=Go,this.eButtonWrapper=Go,this.eButtonShowMainFilter=Go}postConstruct(){const e=this.getGui(),t={toggleCss:(e,t)=>this.toggleCss(e,t),setUserStyles:t=>te(e,t),addOrRemoveBodyCssClass:(e,t)=>this.eFloatingFilterBody.classList.toggle(e,t),setButtonWrapperDisplayed:e=>H(this.eButtonWrapper,e),setCompDetails:e=>this.setCompDetails(e),getFloatingFilterComp:()=>this.compPromise,setWidth:t=>e.style.width=t,setMenuIcon:e=>this.eButtonShowMainFilter.appendChild(e)};this.ctrl.setComp(t,e,this.eButtonShowMainFilter,this.eFloatingFilterBody,void 0)}setCompDetails(e){if(!e)return this.destroyFloatingFilterComp(),void(this.compPromise=null);this.compPromise=e.newAgStackInstance(),this.compPromise.then(e=>this.afterCompCreated(e))}destroy(){this.destroyFloatingFilterComp(),super.destroy()}destroyFloatingFilterComp(){this.floatingFilterComp&&(this.eFloatingFilterBody.removeChild(this.floatingFilterComp.getGui()),this.floatingFilterComp=this.destroyBean(this.floatingFilterComp))}afterCompCreated(e){e&&(this.isAlive()?(this.destroyFloatingFilterComp(),this.floatingFilterComp=e,this.eFloatingFilterBody.appendChild(e.getGui()),e.afterGuiAttached&&e.afterGuiAttached()):this.destroyBean(e))}},Ka=class extends Uo{constructor(e){super({tag:"div",cls:e.headerRowClass,role:"row"}),this.ctrl=e,this.headerComps={}}postConstruct(){this.getGui().setAttribute("tabindex",String(this.gos.get("tabIndex"))),D(this.getGui(),this.ctrl.getAriaRowIndex());const e={setHeight:e=>this.getGui().style.height=e,setTop:e=>this.getGui().style.top=e,setHeaderCtrls:(e,t)=>this.setHeaderCtrls(e,t),setWidth:e=>this.getGui().style.width=e,setRowIndex:e=>D(this.getGui(),e)};this.ctrl.setComp(e,void 0)}destroy(){this.setHeaderCtrls([],!1),super.destroy()}setHeaderCtrls(e,t){if(!this.isAlive())return;const o=this.headerComps;if(this.headerComps={},e.forEach(e=>{const t=e.instanceId;let i=o[t];delete o[t],null==i&&(i=this.createHeaderComp(e),this.getGui().appendChild(i.getGui())),this.headerComps[t]=i}),Object.values(o).forEach(e=>{this.getGui().removeChild(e.getGui()),this.destroyBean(e)}),t){const e=Object.values(this.headerComps);e.sort((e,t)=>e.getCtrl().column.getLeft()-t.getCtrl().column.getLeft());const t=e.map(e=>e.getGui());X(this.getGui(),t)}}createHeaderComp(e){let t;switch(this.ctrl.type){case"group":t=new Wa(e);break;case"filter":t=new $a(e);break;default:t=new Oa(e)}return this.createBean(t),t.setParentComponent(this),t}},ja=class extends Me{constructor(e,t,o,i){super(),this.columnOrGroup=e,this.eCell=t,this.colsSpanning=i,this.columnOrGroup=e,this.ariaEl=t.querySelector("[role=columnheader]")||t,this.beans=o}setColsSpanning(e){this.colsSpanning=e,this.onLeftChanged()}getColumnOrGroup(){const{beans:e,colsSpanning:t}=this;return e.gos.get("enableRtl")&&t?to(t):this.columnOrGroup}postConstruct(){const e=this.onLeftChanged.bind(this);this.addManagedListeners(this.columnOrGroup,{leftChanged:e}),this.setLeftFirstTime(),this.addManagedEventListeners({displayedColumnsWidthChanged:e}),this.addManagedPropertyListener("domLayout",e)}setLeftFirstTime(){const{gos:e,colAnimation:t}=this.beans,i=e.get("suppressColumnMoveAnimation"),s=o(this.columnOrGroup.getOldLeft());t?.isActive()&&s&&!i?this.animateInLeft():this.onLeftChanged()}animateInLeft(){const e=this.getColumnOrGroup(),t=this.modifyLeftForPrintLayout(e,e.getOldLeft()),o=this.modifyLeftForPrintLayout(e,e.getLeft());this.setLeft(t),this.actualLeft=o,this.beans.colAnimation.executeNextVMTurn(()=>{this.actualLeft===o&&this.setLeft(o)})}onLeftChanged(){const e=this.getColumnOrGroup(),t=e.getLeft();this.actualLeft=this.modifyLeftForPrintLayout(e,t),this.setLeft(this.actualLeft)}modifyLeftForPrintLayout(e,t){const{gos:o,visibleCols:i}=this.beans;if(!ct(o,"print"))return t;if("left"===e.getPinned())return t;const s=i.getColsLeftWidth();if("right"===e.getPinned()){return s+i.bodyWidth+t}return s+t}setLeft(e){if(o(e)&&(this.eCell.style.left=`${e}px`),Wn(this.columnOrGroup)){const e=this.columnOrGroup.getLeafColumns();if(!e.length)return;e.length>1&&(t=this.ariaEl,i=e.length,v(t,"colspan",i))}var t,i}},qa=0,_a="headerCtrl",Ya=class extends Me{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()+"-"+qa++}postConstruct(){const e=this.refreshTabIndex.bind(this);this.addManagedPropertyListeners(["suppressHeaderFocus"],e),this.addManagedEventListeners({overlayExclusiveChanged:e})}setComp(e,t,o,i,s){t.setAttribute("col-id",this.column.colIdSanitised),this.wireComp(e,t,o,i,s),this.reAttemptToFocus&&(this.reAttemptToFocus=!1,this.focus(this.lastFocusEvent??void 0))}shouldStopEventPropagation(e){const{headerRowIndex:t,column:i}=this.beans.focusSvc.focusedHeader,s=i.getDefinition(),n=s&&s.suppressHeaderKeyboardEvent;if(!o(n))return!1;return!!n(zt(this.gos,{colDef:s,column:i,headerRowIndex:t,event:e}))}getWrapperHasFocus(){return u(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(){const e=this.column.getDefinition();if(!e)return;const{headerStyle:t}=e;let o;if("function"==typeof t){o=t(this.getHeaderClassParams())}else o=t;o&&this.comp.setUserStyles(o)}onGuiFocus(){this.eventSvc.dispatchEvent({type:"headerFocused",column:this.column})}setupAutoHeight(e){const{wrapperElement:t,checkMeasuringCallback:o,compBean:i}=e,{beans:s}=this,n=e=>{if(!this.isAlive()||!i.isAlive())return;const{paddingTop:o,paddingBottom:r,borderBottomWidth:a,borderTopWidth:l}=N(this.eGui),d=o+r+a+l,h=t.offsetHeight+d;if(e<5){const o=g(s);if(!o||!o.contains(t)||0==h)return void Le(()=>n(e+1),"raf",s)}this.setColHeaderHeight(this.column,h)};let r,a=!1;const l=()=>{const e=this.column.isAutoHeaderHeight();e&&!a&&d(),!e&&a&&h()},d=()=>{a=!0,this.comp.toggleCss("ag-header-cell-auto-height",!0),n(0),r=ce(this.beans,t,()=>n(0))},h=()=>{a=!1,r&&r(),this.comp.toggleCss("ag-header-cell-auto-height",!1),r=void 0};l(),i.addDestroyFunc(()=>h()),i.addManagedListeners(this.column,{widthChanged:()=>a&&n(0)}),i.addManagedEventListeners({sortChanged:()=>{a&&window.setTimeout(()=>n(0))}}),o&&o(l)}onDisplayedColumnsChanged(){const{comp:e,column:t,beans:o,eGui:i}=this;e&&t&&i&&(Fa(e,t,o.visibleCols),M(i,o.visibleCols.getAriaColIndex(t)))}addResizeAndMoveKeyboardListeners(e){e.addManagedListeners(this.eGui,{keydown:this.onGuiKeyDown.bind(this),keyup:this.onGuiKeyUp.bind(this)})}refreshTabIndex(){const e=Pa(this.beans);this.eGui&&he(this.eGui,"tabindex",e?null:"-1")}onGuiKeyDown(e){const t=u(this.beans),o=e.key===ki||e.key===Ii;if(this.isResizing&&(e.preventDefault(),e.stopImmediatePropagation()),t!==this.eGui||!e.shiftKey&&!e.altKey)return;if((this.isResizing||o)&&(e.preventDefault(),e.stopImmediatePropagation()),!o)return;const i=e.key===ki!==this.gos.get("enableRtl")?"left":"right";if(e.altKey){this.isResizing=!0,this.resizeMultiplier+=1;const t=this.getViewportAdjustedResizeDiff(e);this.resizeHeader(t,e.shiftKey),this.resizeFeature?.toggleColumnResizing(!0)}else this.moveHeader(i)}moveHeader(e){this.beans.colMoves?.moveHeader(e,this.eGui,this.column,this.rowCtrl.pinned,this)}getViewportAdjustedResizeDiff(e){const t=this.getResizeDiff(e),{pinnedCols:o}=this.beans;return o?o.getHeaderResizeDiff(t,this.column):t}getResizeDiff(e){const{gos:t,column:o}=this;let i=e.key===ki!==t.get("enableRtl");const s=o.getPinned(),n=t.get("enableRtl");return s&&n!==("right"===s)&&(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){const t=this.getWrapperHasFocus();switch(e.key){case Vi:case Hi:case Gi:case Ni:t&&e.preventDefault()}}addDomData(e){const t=_a,{eGui:o,gos:i}=this;vt(i,o,t,this),e.addDestroyFunc(()=>vt(i,o,t,null))}focus(e){if(!this.isAlive())return!1;const{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,o){const i=e??t,{menuSvc:s,gos:n}=this.beans;n.get("preventDefaultOnContextMenu")&&i.preventDefault(),s?.isHeaderContextMenuEnabled(o)&&s.showHeaderContextMenu(o,e,t),this.dispatchColumnMouseEvent("columnHeaderContextMenu",o)}dispatchColumnMouseEvent(e,t){this.eventSvc.dispatchEvent({type:e,column:t})}setColHeaderHeight(e,t){if(!e.setAutoHeaderHeight(t))return;const{eventSvc:o}=this;e.isColumn?o.dispatchEvent({type:"columnHeaderHeightChanged",column:e,columns:[e],source:"autosizeColumnHeaderHeight"}):o.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}},Qa=class extends Ya{constructor(){super(...arguments),this.refreshFunctions={},this.userHeaderClasses=new Set,this.ariaDescriptionProperties=new Map}wireComp(e,t,o,i,s){this.comp=e;const{rowCtrl:n,column:r,beans:a}=this,{colResize:l,context:d,colHover:h,rangeSvc:c}=a,u=Vo(this,d,s);this.setGui(t,u),this.updateState(),this.setupWidth(u),this.setupMovingCss(u),this.setupMenuClass(u),this.setupSortableClass(u),this.setupWrapTextClass(),this.refreshSpanHeaderHeight(),this.setupAutoHeight({wrapperElement:i,checkMeasuringCallback:e=>this.setRefreshFunction("measuring",e),compBean:u}),this.addColumnHoverListener(u),this.setupFilterClass(u),this.setupStylesFromColDef(),this.setupClassesFromColDef(),this.setupTooltip(),this.addActiveHeaderMouseListeners(u),this.setupSelectAll(u),this.setupUserComp(),this.refreshAria(),l?this.resizeFeature=u.createManagedBean(l.createResizeFeature(n.pinned,r,o,e,this)):H(o,!1),h?.createHoverFeature(u,[r],t),c?.createRangeHighlightFeature(u,r,e),u.createManagedBean(new ja(r,t,a)),u.createManagedBean(new Dr(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(u),u.addManagedPropertyListeners(["suppressMovableColumns","suppressMenuHide","suppressAggFuncInHeader","enableAdvancedFilter"],()=>this.refresh()),u.addManagedListeners(r,{colDefChanged:()=>this.refresh()}),u.addManagedListeners(r,{headerHighlightChanged:this.onHeaderHighlightChanged.bind(this)});const g=()=>this.checkDisplayName();u.addManagedEventListeners({columnValueChanged:g,columnRowGroupChanged:g,columnPivotChanged:g,headerHeightChanged:this.onHeaderHeightChanged.bind(this)}),u.addDestroyFunc(()=>{this.refreshFunctions={},this.selectAllFeature=null,this.dragSourceElement=void 0,this.userCompDetails=null,this.userHeaderClasses.clear(),this.ariaDescriptionProperties.clear(),this.clearComponent()})}resizeHeader(e,t){this.beans.colResize?.resizeHeader(this.column,e,t)}getHeaderClassParams(){const{column:e,beans:t}=this,o=e.colDef;return zt(t.gos,{colDef:o,column:e,floatingFilter:!1})}setupUserComp(){const e=this.lookupUserCompDetails();e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setUserCompDetails(e)}lookupUserCompDetails(){const e=this.createParams(),t=this.column.getColDef();return function(e,t,o){return e.getCompDetails(t,Yo,"agColumnHeader",o)}(this.beans.userCompFactory,t,e)}createParams(){const{menuSvc:e,sortSvc:t,colFilter:o,gos:i}=this.beans;return zt(i,{column:this.column,displayName:this.displayName,enableSorting:this.column.isSortable(),enableMenu:this.menuEnabled,enableFilterButton:this.openFilterEnabled&&!!e?.isHeaderFilterButtonEnabled(this.column),enableFilterIcon:!!o&&(!this.openFilterEnabled||Ot(this.gos)),showColumnMenu:(t,o)=>{e?.showColumnMenu({column:this.column,buttonElement:t,positionBy:"button",onClosedCallback:o})},showColumnMenuAfterMouseClick:(t,o)=>{e?.showColumnMenu({column:this.column,mouseEvent:t,positionBy:"mouse",onClosedCallback:o})},showFilter:t=>{e?.showFilterMenu({column:this.column,buttonElement:t,containerType:"columnFilter",positionBy:"button"})},progressSort:e=>{t?.progressSort(this.column,!!e,"uiColumnSorted")},setSort:(e,o)=>{t?.setSortForColumn(this.column,e,!!o,"uiColumnSorted")},eGridHeader:this.eGui,setTooltip:(e,t)=>{i.assertModuleRegistered("Tooltip",3),this.setupTooltip(e,t)}})}setupSelectAll(e){const{selectionSvc:t}=this.beans;t&&(this.selectAllFeature=e.createOptionalManagedBean(t.createSelectAllFeature(this.column)),this.selectAllFeature?.setComp(this),e.addManagedPropertyListener("rowSelection",()=>{const o=t.createSelectAllFeature(this.column);o&&!this.selectAllFeature?(this.selectAllFeature=e.createManagedBean(o),this.selectAllFeature?.setComp(this),this.comp.refreshSelectAllGui()):this.selectAllFeature&&!o&&(this.comp.removeSelectAllGui(),this.selectAllFeature=this.destroyBean(this.selectAllFeature))}))}getSelectAllGui(){return this.selectAllFeature?.getCheckboxGui()}handleKeyDown(e){super.handleKeyDown(e),e.key===Mi&&this.selectAllFeature?.onSpaceKeyDown(e),e.key===Pi&&this.onEnterKeyDown(e),e.key===Ai&&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){const o=this.comp.getUserCompInstance();Za(o)&&o.onMenuKeyboardShortcut(t)&&e.preventDefault()}onFocusIn(e){this.eGui.contains(e.relatedTarget)||(this.focusThis(),this.announceAriaDescription()),ms&&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(){const e=()=>{const e=xa(this.column.getColDef(),this.gos,this.column,null),t=this.userHeaderClasses;this.userHeaderClasses=new Set(e),e.forEach(e=>{t.has(e)?t.delete(e):this.comp.toggleCss(e,!0)}),t.forEach(e=>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(){const{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(){this.updateState(),this.refreshHeaderComp(),this.refreshAria(),Object.values(this.refreshFunctions).forEach(e=>e())}refreshHeaderComp(){const e=this.lookupUserCompDetails();if(!e)return;!!(null!=this.comp.getUserCompInstance()&&this.userCompDetails.componentClass==e.componentClass)&&this.attemptHeaderCompRefresh(e.params)?this.setDragSource(this.dragSourceElement):this.setCompDetails(e)}attemptHeaderCompRefresh(e){const t=this.comp.getUserCompInstance();if(!t)return!1;if(!t.refresh)return!1;return t.refresh(e)}calculateDisplayName(){return this.beans.colNames.getDisplayNameForColumn(this.column,"header",!0)}checkDisplayName(){this.displayName!==this.calculateDisplayName()&&this.refresh()}workOutDraggable(){const e=this.column.getColDef();return!!(!this.gos.get("suppressMovableColumns")&&!e.suppressMovable&&!e.lockPosition)||!!e.enableRowGroup||!!e.enablePivot}setupWidth(e){const t=()=>{const e=this.column.getActualWidth();this.comp.setWidth(`${e}px`)};e.addManagedListeners(this.column,{widthChanged:t}),t()}setupMovingCss(e){const t=()=>{this.comp.toggleCss("ag-header-cell-moving",this.column.isMoving())};e.addManagedListeners(this.column,{movingChanged:t}),t()}setupMenuClass(e){const t=()=>{this.comp?.toggleCss("ag-column-menu-visible",this.column.isMenuVisible())};e.addManagedListeners(this.column,{menuVisibleChanged:t}),t()}setupSortableClass(e){const t=()=>{this.comp.toggleCss("ag-header-cell-sortable",!!this.sortable)};t(),this.setRefreshFunction("updateSortable",t),e.addManagedEventListeners({sortChanged:this.refreshAriaSort.bind(this)})}setupFilterClass(e){const t=()=>{const e=this.column.isFilterActive();this.comp.toggleCss("ag-header-cell-filtered",e),this.refreshAria()};e.addManagedListeners(this.column,{filterActiveChanged:t}),t()}setupWrapTextClass(){const e=()=>{const e=!!this.column.getColDef().wrapHeaderText;this.comp.toggleCss("ag-header-cell-wrap-text",e)};e(),this.setRefreshFunction("wrapText",e)}onHeaderHighlightChanged(){const e=this.column.getHighlighted(),t=0===e,o=1===e;this.comp.toggleCss("ag-header-highlight-before",t),this.comp.toggleCss("ag-header-highlight-after",o)}onDisplayedColumnsChanged(){super.onDisplayedColumnsChanged(),this.isAlive()&&this.onHeaderHeightChanged()}onHeaderHeightChanged(){this.refreshSpanHeaderHeight()}refreshSpanHeaderHeight(){const{eGui:e,column:t,comp:o,beans:i}=this,s=Ta(this.beans),n=0===s.reduce((e,t)=>e+t,0);if(o.toggleCss("ag-header-parent-hidden",n),!t.isSpanHeaderHeight())return e.style.removeProperty("top"),e.style.removeProperty("height"),o.toggleCss("ag-header-span-height",!1),void o.toggleCss("ag-header-span-total",!1);const{numberOfParents:r,isSpanningTotal:a}=this.column.getColumnGroupPaddingInfo();o.toggleCss("ag-header-span-height",r>0);const l=Aa(i);if(0===r)return o.toggleCss("ag-header-span-total",!1),e.style.setProperty("top","0px"),void e.style.setProperty("height",`${l}px`);o.toggleCss("ag-header-span-total",a);const d=(this.column.getFirstRealParent()?.getLevel()??-1)+1,h=s.length-d;let c=0;for(let e=0;e<h;e++)c+=s[s.length-1-e];e.style.setProperty("top",-c+"px"),e.style.setProperty("height",`${l+c}px`)}refreshAriaSort(){if(this.sortable){const e=this.getLocaleTextFunc(),t=this.beans.sortSvc?.getDisplaySortForColumn(this.column)||null;this.comp.setAriaSort(function(e){let t;return t="asc"===e?"ascending":"desc"===e?"descending":"mixed"===e?"other":"none",t}(t)),this.setAriaDescriptionProperty("sort",e("ariaSortableColumn","Press ENTER to sort"))}else this.comp.setAriaSort(),this.setAriaDescriptionProperty("sort",null)}refreshAriaMenu(){if(this.menuEnabled){const e=this.getLocaleTextFunc();this.setAriaDescriptionProperty("menu",e("ariaMenuColumn","Press ALT DOWN to open column menu"))}else this.setAriaDescriptionProperty("menu",null)}refreshAriaFilterButton(){if(this.openFilterEnabled&&!Ot(this.gos)){const e=this.getLocaleTextFunc();this.setAriaDescriptionProperty("filterButton",e("ariaFilterColumn","Press CTRL ENTER to open filter"))}else this.setAriaDescriptionProperty("filterButton",null)}refreshAriaFiltered(){const 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(u(this.beans)))return;const e=Array.from(this.ariaDescriptionProperties.keys()).sort((e,t)=>"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){const t=e=>this.handleMouseOverChange("mouseenter"===e.type);e.addManagedListeners(this.eGui,{mouseenter:t,mouseleave:t,click:()=>{this.setActiveHeader(!0),this.dispatchColumnMouseEvent("columnHeaderClicked",this.column)},contextmenu:e=>this.handleContextMenuMouseEvent(e,void 0,this.column)})}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){const t=this.comp.getUserCompInstance();return Za(t)?t.getAnchorElementForMenu(e):this.eGui}destroy(){this.tooltipFeature=this.destroyBean(this.tooltipFeature),super.destroy()}};function Za(e){return"function"==typeof e?.getAnchorElementForMenu&&"function"==typeof e.onMenuKeyboardShortcut}var Ja=0,Xa=class extends Me{constructor(e,t,o){super(),this.rowIndex=e,this.pinned=t,this.type=o,this.instanceId=Ja++,this.comp=null,this.allCtrls=[];let i="ag-header-row-column";"group"===o?i="ag-header-row-group":"filter"===o&&(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=ct(this.gos,"print"),this.isEnsureDomOrder=this.gos.get("ensureDomOrder")}areCellsRendered(){return!!this.comp&&this.allCtrls.every(e=>null!=e.eGui)}setComp(e,t,o=!0){this.comp=e,t=Vo(this,this.beans.context,t),o&&(this.setRowIndex(this.rowIndex),this.onVirtualColumnsChanged()),this.setWidth(),this.addEventListeners(t)}getAriaRowIndex(){return this.rowIndex+1}addEventListeners(e){const t=this.onRowHeightChanged.bind(this),o=this.onDisplayedColumnsChanged.bind(this);e.addManagedEventListeners({columnResized:this.setWidth.bind(this),displayedColumnsChanged:o,virtualColumnsChanged:e=>this.onVirtualColumnsChanged(e.afterScroll),columnGroupHeaderHeightChanged:t,columnHeaderHeightChanged:t,gridStylesChanged:t,advancedFilterEnabledChanged:t}),e.addManagedPropertyListener("domLayout",o),e.addManagedPropertyListener("ensureDomOrder",e=>this.isEnsureDomOrder=e.currentValue),e.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],t)}onDisplayedColumnsChanged(){this.isPrintLayout=ct(this.gos,"print"),this.onVirtualColumnsChanged(),this.setWidth(),this.onRowHeightChanged()}setWidth(){if(!this.comp)return;const e=this.getWidthForRow();this.comp.setWidth(`${e}px`)}getWidthForRow(){const{visibleCols:e}=this.beans;if(this.isPrintLayout){return null!=this.pinned?0:e.getContainerWidth("right")+e.getContainerWidth("left")+e.getContainerWidth(null)}return e.getContainerWidth(this.pinned)}onRowHeightChanged(){if(!this.comp)return;const{topOffset:e,rowHeight:t}=this.getTopAndHeight();this.comp.setTop(e+"px"),this.comp.setHeight(t+"px")}getTopAndHeight(){let e=0;const t=Ta(this.beans);for(let o=0;o<t.length;o++){if(o===this.rowIndex&&"group"===this.type)return{topOffset:e,rowHeight:t[o]};e+=t[o]}const o=Aa(this.beans);if("column"===this.type)return{topOffset:e,rowHeight:o};e+=o;return{topOffset:e,rowHeight:Ba(this.beans)}}onVirtualColumnsChanged(e=!1){if(!this.comp)return;const t=this.getUpdatedHeaderCtrls(),o=this.isEnsureDomOrder||this.isPrintLayout;this.comp.setHeaderCtrls(t,o,e)}getUpdatedHeaderCtrls(){const e=this.ctrlsById;this.ctrlsById=new Map;const t=this.getColumnsInViewport();for(const o of t)this.recycleAndCreateHeaderCtrls(o,this.ctrlsById,e);const o=e=>{const{focusSvc:t,visibleCols:o}=this.beans;if(!t.isHeaderWrapperFocused(e))return!1;return o.isVisible(e.column)};if(e)for(const[t,i]of e){o(i)?this.ctrlsById.set(t,i):this.destroyBean(i)}return this.allCtrls=Array.from(this.ctrlsById.values()),this.allCtrls}getHeaderCellCtrls(){return this.allCtrls}recycleAndCreateHeaderCtrls(e,t,o){if(e.isEmptyGroup())return;const i=e.getUniqueId();let s;o&&(s=o.get(i),o.delete(i));if(s&&s.column!=e&&(this.destroyBean(s),s=void 0),null==s)switch(this.type){case"filter":s=this.createBean(this.beans.registry.createDynamicBean("headerFilterCellCtrl",!0,e,this));break;case"group":s=this.createBean(this.beans.registry.createDynamicBean("headerGroupCellCtrl",!0,e,this));break;default:s=this.createBean(new Qa(e,this))}t.set(i,s)}getColumnsInViewport(){if(!this.isPrintLayout)return this.getComponentsToRender();if(this.pinned)return[];const e=[];return["left",null,"right"].forEach(t=>{e.push(...this.getComponentsToRender(t))}),e}getComponentsToRender(e=this.pinned){return"group"===this.type?this.beans.colViewport.getHeadersToRender(e,this.rowIndex):this.beans.colViewport.getColumnHeadersToRender(e)}focusHeader(e,t){const o=this.allCtrls.find(t=>t.column==e);if(!o)return!1;return o.focus(t)}destroy(){this.allCtrls=this.destroyBeans(this.allCtrls),this.ctrlsById=void 0,this.comp=null,super.destroy()}},el=class extends Me{constructor(e){super(),this.pinned=e,this.hidden=!1,this.includeFloatingFilter=!1,this.groupsRowCtrls=[]}setComp(e,t){this.comp=e,this.eViewport=t;const{pinnedCols:o,ctrlsSvc:i,colModel:s,colMoves:n}=this.beans;this.setupCenterWidth(),o?.setupHeaderPinnedWidth(this),this.setupDragAndDrop(n,this.eViewport);const r=this.refresh.bind(this,!0);this.addManagedEventListeners({displayedColumnsChanged:r,advancedFilterEnabledChanged:r});const a=`${"string"==typeof this.pinned?this.pinned:"center"}Header`;i.register(a,this),s.ready&&this.refresh()}getAllCtrls(){const e=[...this.groupsRowCtrls];return this.columnsRowCtrl&&e.push(this.columnsRowCtrl),this.filtersRowCtrl&&e.push(this.filtersRowCtrl),e}refresh(e=!1){const{focusSvc:t,filterManager:o,visibleCols:i}=this.beans;let s=0;const n=t.getFocusHeaderToUseAfterRefresh(),r=this.getAllCtrls();(()=>{const e=i.headerGroupRowCount;s=e;const t=this.groupsRowCtrls.length;if(t!==e)if(t>e){for(let o=e;o<t;o++)this.destroyBean(this.groupsRowCtrls[o]);this.groupsRowCtrls.length=e}else for(let o=t;o<e;o++){const e=this.createBean(new Xa(o,this.pinned,"group"));this.groupsRowCtrls.push(e)}})(),(()=>{const t=s++;this.hidden?this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl):null!=this.columnsRowCtrl&&e?this.columnsRowCtrl.rowIndex!==t&&this.columnsRowCtrl.setRowIndex(t):(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl),this.columnsRowCtrl=this.createBean(new Xa(t,this.pinned,"column")))})(),(()=>{this.includeFloatingFilter=!!o?.hasFloatingFilters()&&!this.hidden;const t=()=>{this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)};if(!this.includeFloatingFilter)return void t();e||t();const i=s++;if(this.filtersRowCtrl){this.filtersRowCtrl.rowIndex!==i&&this.filtersRowCtrl.setRowIndex(i)}else this.filtersRowCtrl=this.createBean(new Xa(i,this.pinned,"filter"))})();const a=this.getAllCtrls();this.comp.setCtrls(a),this.restoreFocusOnHeader(t,n),r.length!==a.length&&this.beans.eventSvc.dispatchEvent({type:"headerRowsChanged"})}getHeaderCtrlForColumn(e){const t=t=>t?.getHeaderCellCtrls().find(t=>t.column===e);if(qt(e))return t(this.columnsRowCtrl);if(0!==this.groupsRowCtrls.length)for(let e=0;e<this.groupsRowCtrls.length;e++){const o=t(this.groupsRowCtrls[e]);if(o)return o}}getHtmlElementForColumnHeader(e){return this.getHeaderCtrlForColumn(e)?.eGui??null}getRowType(e){return this.getAllCtrls()[e]?.type}focusHeader(e,t,o){const i=this.getAllCtrls()[e];return!!i&&i.focusHeader(t,o)}getGroupRowCount(){return this.groupsRowCtrls.length}getGroupRowCtrlAtIndex(e){return this.groupsRowCtrls[e]}getRowCount(){return this.groupsRowCtrls.length+(this.columnsRowCtrl?1:0)+(this.filtersRowCtrl?1:0)}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){const o=e?.createBodyDropTarget(this.pinned,t);o&&this.createManagedBean(o)}restoreFocusOnHeader(e,t){if(!t)return;const{column:o}=t;o.getPinned()==this.pinned&&e.focusHeaderPosition({headerPosition:t})}setupCenterWidth(){null==this.pinned&&this.createManagedBean(new Vr(e=>this.comp.setCenterWidth(`${e}px`),!0))}};function tl(e,t,o){e.menuVisible!==t&&(e.menuVisible=t,e.dispatchColEvent("menuVisibleChanged",o))}function ol(e){const{enterpriseMenuFactory:t,filterMenuFactory:o,gos:i}=e;return t&&Ot(i)?t:o}var il=class extends qi{constructor(){super(...arguments),this.errorMessages=null}init(e){this.params=e,this.initialiseEditor(e),this.eEditor.onValueChange(()=>e.validate())}destroy(){this.errorMessages=null}},sl=class extends Uo{constructor(){super()}},nl={tag:"span",cls:"ag-overlay-loading-center"},rl={tag:"span",cls:"ag-overlay-no-rows-center"};function al(e,t,o){let i=null;"smallDown"===e?st(262):"smallLeft"===e?st(263):"smallRight"===e&&st(264);const s=o&&o.getColDef().icons;if(s&&(i=s[e]),t.gos&&!i){const o=t.gos.get("icons");o&&(i=o[e])}if(i){let t;if("function"==typeof i)t=i();else{if("string"!=typeof i)return void st(38,{iconName:e});t=i}return"string"==typeof t?Z(t):de(t)?t:void st(133,{iconName:e})}{const o=t.registry.getIcon(e);return o||t.validation?.validateIcon(e),sr({tag:"span",cls:`ag-icon ag-icon-${o??e}`,role:"presentation",attrs:{unselectable:"on"}})}}var ll={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"}]}]},dl={tag:"div",cls:"ag-cell-wrapper ag-checkbox-cell",role:"presentation",children:[{tag:"ag-checkbox",ref:"eCheckbox",role:"presentation"}]},hl=class{constructor(e,t){this.beans=e,this.floating=t,this.all=new Set,this.visible=new Set,this.order=[],this.queued=new Set}size(){return this.visible.size}add(e){const{all:t,visible:o,order:i}=this;t.has(e)||(t.add(e),o.add(e),i.push(e),this.sort())}delete(e){this.all.delete(e),this.visible.delete(e),this.queued.delete(e.id),so(this.order,e)}has(e){return this.visible.has(e)}forEach(e){this.order.forEach(e)}getByIndex(e){return this.order[e]}getById(e){for(const t of this.visible)if(t.id==e)return t}clear(){const{all:e,visible:t,order:o,queued:i}=this;e.clear(),i.clear(),t.clear(),o.length=0}sort(){const{sortSvc:e,rowNodeSorter:t,gos:o}=this.beans,i=e?.getSortOptions()??[],s=function(e){const t=e.findIndex(gl);if(t>-1)return e.splice(t,1)?.[0]}(this.order);if(this.order.sort((e,t)=>(e.pinnedSibling?.rowIndex??0)-(t.pinnedSibling?.rowIndex??0)),this.order=t?.doFullSort(this.order,i)??this.order,!s)return;const n=Et(o);"bottom"===n||"pinnedBottom"===n?this.order.push(s):this.order.unshift(s)}hide(e){const{all:t,visible:o}=this;t.forEach(t=>e(t)?o.delete(t):o.add(t)),this.order=Array.from(o),this.sort()}queue(e){this.queued.add(e)}unqueue(e){this.queued.delete(e)}forEachQueued(e){this.queued.forEach(e)}};function cl(e){if(-1===e.level)return!0;const t=e.parent;return!!t?.childrenAfterSort?.some(t=>t==e)&&cl(t)}function ul(e,t){const{gos:o,rowModel:i,filterManager:s}=e;return ht(o)?!i.getRowNode(t.id):s?.isAnyFilterPresent()?!cl(t):!!o.get("pivotMode")&&!t.group}function gl(e){return!!e.pinnedSibling&&function(e){return!!e.footer&&-1===e.level}(e.pinnedSibling)}var pl=class extends Me{postConstruct(){const{gos:e,beans:t}=this;this.top=new hl(t,"top"),this.bottom=new hl(t,"bottom");const o=e=>ul(t,e.pinnedSibling),i=()=>{const o=e.get("isRowPinned");o&&e.get("enableRowPinning")&&t.rowModel.forEachNode(e=>this.pinRow(e,o(e)),!0),this.refreshRowPositions(),this.dispatchRowPinnedEvents()};this.addManagedEventListeners({gridStylesChanged:this.onGridStylesChanges.bind(this),modelUpdated:({keepRenderedRows:e})=>{this.tryToEmptyQueues(),this.pinGrandTotalRow(),this.forContainers(e=>e.hide(o));const t=this.refreshRowPositions();e&&!t||this.dispatchRowPinnedEvents()},columnRowGroupChanged:()=>{this.forContainers(Cl),this.refreshRowPositions()},rowNodeDataChanged:({node:t})=>{const o=e.get("isRowPinnable");(o?.(t)??!0)||this.pinRow(t,null)},firstDataRendered:i}),this.addManagedPropertyListener("pivotMode",()=>{this.forContainers(e=>e.hide(o)),this.dispatchRowPinnedEvents()}),this.addManagedPropertyListener("grandTotalRow",({currentValue:e})=>{this._grandTotalPinned="pinnedBottom"===e?"bottom":"pinnedTop"===e?"top":null}),this.addManagedPropertyListener("isRowPinned",i)}destroy(){this.reset(!1),super.destroy()}reset(e=!0){this.forContainers(e=>{const t=[];e.forEach(e=>t.push(e)),t.forEach(e=>this.pinRow(e,null)),e.clear()}),e&&this.dispatchRowPinnedEvents()}pinRow(e,t,o){if(e.footer&&e.level>-1)return;if(e.footer&&-1===e.level)return this._grandTotalPinned=t,void function({gos:e,rowModel:t}){dt(e)&&t.refreshModel({step:"map"})}(this.beans);const i=e.rowPinned??e.pinnedSibling?.rowPinned;if(null!=i&&null!=t&&t!=i){const i=e.rowPinned?e:e.pinnedSibling,s=e.rowPinned?e.pinnedSibling:e;return this.pinRow(i,null,o),void this.pinRow(s,t,o)}const s=o&&function(e,t,o){const{rowSpanSvc:i}=e,s=(o&&i?.isCellSpanning(o,t))??!1;if(o&&s)return i?.getCellSpan(o,t)?.spannedNodes}(this.beans,e,o);if(s)s.forEach(e=>this.pinRow(e,t));else if(null==t){const o=e.rowPinned?e:e.pinnedSibling,i=this.findPinnedRowNode(o);if(!i)return;i.delete(o);const s=o.pinnedSibling;fl(o),this.refreshRowPositions(t),this.dispatchRowPinnedEvents(s)}else{const o=ml(this.beans,e,t),i=this.getContainer(t);i.add(o),ul(this.beans,e)&&i.hide(e=>ul(this.beans,e.pinnedSibling)),this.refreshRowPositions(t),this.dispatchRowPinnedEvents(e)}}isManual(){return!0}isEmpty(e){return 0===this.getContainer(e).size()}isRowsToRender(e){return!this.isEmpty(e)}ensureRowHeightsValid(){let e=!1,t=0;const o=o=>{if(o.rowHeightEstimated){const i=pt(this.beans,o);o.setRowTop(t),o.setRowHeight(i.height),t+=i.height,e=!0}};return this.bottom.forEach(o),t=0,this.top.forEach(o),this.eventSvc.dispatchEvent({type:"pinnedHeightChanged"}),e}getPinnedTopTotalHeight(){return vl(this.top)}getPinnedBottomTotalHeight(){return vl(this.bottom)}getPinnedTopRowCount(){return this.top.size()}getPinnedBottomRowCount(){return this.bottom.size()}getPinnedTopRow(e){return this.top.getByIndex(e)}getPinnedBottomRow(e){return this.bottom.getByIndex(e)}getPinnedRowById(e,t){return this.getContainer(t).getById(e)}forEachPinnedRow(e,t){this.getContainer(e).forEach(t)}getPinnedState(){const e=e=>{const t=[];return this.forEachPinnedRow(e,e=>t.push(e.pinnedSibling.id)),t};return{top:e("top"),bottom:e("bottom")}}setPinnedState(e){this.forContainers((t,o)=>{for(const i of e[o]){const e=this.beans.rowModel.getRowNode(i);e?this.pinRow(e,o):t.queue(i)}})}getGrandTotalPinned(){return this._grandTotalPinned}setGrandTotalPinned(e){this._grandTotalPinned=e}tryToEmptyQueues(){this.forContainers((e,t)=>{const o=new Set;e.forEachQueued(e=>{const t=this.beans.rowModel.getRowNode(e);t&&o.add(t)});for(const i of o)e.unqueue(i.id),this.pinRow(i,t)})}pinGrandTotalRow(){const{gos:e,beans:t,_grandTotalPinned:o}=this,i=t.rowModel;if(!dt(e))return;const s=i.rootNode?.sibling;if(!s)return;const n=s.pinnedSibling,r=n&&this.findPinnedRowNode(n);if(o){if(r&&r.floating!==o&&(r.delete(n),fl(n)),!r||r.floating!==o){const e=ml(t,s,o);this.getContainer(o).add(e)}}else{if(!r)return;r.delete(n),fl(n)}}onGridStylesChanges(e){e.rowHeightChanged&&this.forContainers(e=>e.forEach(e=>e.setRowHeight(e.rowHeight,!0)))}getContainer(e){return"top"===e?this.top:this.bottom}findPinnedRowNode(e){return this.top.has(e)?this.top:this.bottom.has(e)?this.bottom:void 0}refreshRowPositions(e){const t=e=>function(e,t){let o=0,i=!1;return t.forEach((t,s)=>{if(i||(i=t.rowTop!==o),t.setRowTop(o),t.rowHeightEstimated||null==t.rowHeight){const o=pt(e,t).height;i||(i=t.rowHeight!==o),t.setRowHeight(o)}t.setRowIndex(s),o+=t.rowHeight}),i}(this.beans,e);if(e)return t(this.getContainer(e));let o=!1;return this.forContainers(e=>{const i=t(e);o||(o=i)}),o}forContainers(e){e(this.top,"top"),e(this.bottom,"bottom")}dispatchRowPinnedEvents(e){this.eventSvc.dispatchEvent({type:"pinnedRowsChanged"}),e?.dispatchRowEvent("rowPinned")}};function ml(e,t,o){if(t.pinnedSibling)return t.pinnedSibling;const i=function(e,t){const o=new _n(t);return Object.keys(e).forEach(t=>{Qn.has(t)||(o[t]=e[t])}),o.oldRowTop=null,o}(t,e);i.setRowTop(null),i.setRowIndex(null),i.rowPinned=o;const s="top"===o?Kn:jn;return i.id=`${s}${o}-${t.id}`,i.pinnedSibling=t,t.pinnedSibling=i,i}function fl(e){if(!e.pinnedSibling)return;e.rowPinned=null,e.setRowTop(null),e.setRowIndex(null);const t=e.pinnedSibling;e.pinnedSibling=void 0,t&&(t.pinnedSibling=void 0,t.rowPinned=null)}function Cl(e){const t=new Set;e.forEach(e=>{e.group&&t.add(e)}),t.forEach(t=>e.delete(t))}function vl(e){const t=e.size();if(0===t)return 0;const o=e.getByIndex(t-1);return void 0===o?0:o.rowTop+o.rowHeight}var wl=class extends Me{constructor(){super(...arguments),this.nextId=0,this.pinnedTopRows={cache:{},order:[]},this.pinnedBottomRows={cache:{},order:[]}}postConstruct(){const e=this.gos;this.setPinnedRowData(e.get("pinnedTopRowData"),"top"),this.setPinnedRowData(e.get("pinnedBottomRowData"),"bottom"),this.addManagedPropertyListener("pinnedTopRowData",e=>this.setPinnedRowData(e.currentValue,"top")),this.addManagedPropertyListener("pinnedBottomRowData",e=>this.setPinnedRowData(e.currentValue,"bottom")),this.addManagedEventListeners({gridStylesChanged:this.onGridStylesChanges.bind(this)})}reset(){}isEmpty(e){return 0===this.getCache(e).order.length}isRowsToRender(e){return!this.isEmpty(e)}isManual(){return!1}pinRow(e,t){}onGridStylesChanges(e){if(e.rowHeightChanged){const e=e=>{e.setRowHeight(e.rowHeight,!0)};El(this.pinnedBottomRows,e),El(this.pinnedTopRows,e)}}ensureRowHeightsValid(){let e=!1,t=0;const o=o=>{if(o.rowHeightEstimated){const i=pt(this.beans,o);o.setRowTop(t),o.setRowHeight(i.height),t+=i.height,e=!0}};return El(this.pinnedBottomRows,o),t=0,El(this.pinnedTopRows,o),this.eventSvc.dispatchEvent({type:"pinnedHeightChanged"}),e}setPinnedRowData(e,t){this.updateNodesFromRowData(e,t),this.eventSvc.dispatchEvent({type:"pinnedRowDataChanged"})}updateNodesFromRowData(e,t){const o=this.getCache(t);if(void 0===e)return o.order.length=0,void(o.cache={});const i=Ft(this.gos),s="top"===t?Kn:jn,n=new Set(o.order),r=[],a=new Set;let l=0,d=-1;for(const h of e){const e=i?.({data:h,level:0,rowPinned:t})??s+this.nextId++;if(a.has(e)){st(96,{id:e,data:h});continue}d++,a.add(e),r.push(e);const c=yl(o,e);if(void 0!==c)c.data!==h&&c.updateData(h),l+=this.setRowTopAndRowIndex(c,l,d),n.delete(e);else{const i=new _n(this.beans);i.id=e,i.data=h,i.rowPinned=t,l+=this.setRowTopAndRowIndex(i,l,d),o.cache[e]=i,o.order.push(e)}}n.forEach(e=>{yl(o,e)?.clearRowTopAndRowIndex(),delete o.cache[e]}),o.order=r}setRowTopAndRowIndex(e,t,o){return e.setRowTop(t),e.setRowHeight(pt(this.beans,e).height),e.setRowIndex(o),e.rowHeight}getPinnedTopTotalHeight(){return bl(this.pinnedTopRows)}getPinnedBottomTotalHeight(){return bl(this.pinnedBottomRows)}getPinnedTopRowCount(){return Rl(this.pinnedTopRows)}getPinnedBottomRowCount(){return Rl(this.pinnedBottomRows)}getPinnedTopRow(e){return Sl(this.pinnedTopRows,e)}getPinnedBottomRow(e){return Sl(this.pinnedBottomRows,e)}getPinnedRowById(e,t){return yl(this.getCache(t),e)}forEachPinnedRow(e,t){return El(this.getCache(e),t)}getCache(e){return"top"===e?this.pinnedTopRows:this.pinnedBottomRows}getPinnedState(){return{top:[],bottom:[]}}setPinnedState(){}getGrandTotalPinned(){}setGrandTotalPinned(){}};function bl(e){const t=Rl(e);if(0===t)return 0;const o=Sl(e,t-1);return void 0===o?0:o.rowTop+o.rowHeight}function yl(e,t){return e.cache[t]}function Sl(e,t){return yl(e,e.order[t])}function El(e,t){e.order.forEach((o,i)=>{const s=yl(e,o);s&&t(s,i)})}function Rl(e){return e.order.length}var xl=class extends Me{constructor(){super(...arguments),this.nextId=0,this.allNodesMap={},this.rootNode=null}getRowNode(e){return this.allNodesMap[e]}extractRowData(){return this.rootNode?.allLeafChildren?.map(e=>e.data)}activate(e){this.rootNode=e,e.group=!0,e.level=-1,e.id="ROOT_NODE_ID",e.allLeafChildren=[],e.childrenAfterGroup=[],e.childrenAfterSort=[],e.childrenAfterAggFilter=[],e.childrenAfterFilter=[],this.updateRootSiblingArrays(e)}deactivate(){this.rootNode&&(this.allNodesMap={},this.rootNode=null)}destroy(){super.destroy(),this.allNodesMap={},this.rootNode=null}setNewRowData(e){const t=this.rootNode;t&&(this.dispatchRowDataUpdateStartedEvent(e),t.childrenAfterFilter=null,t.childrenAfterGroup=null,t.childrenAfterAggFilter=null,t.childrenAfterSort=null,t.childrenMapped=null,t.updateHasChildren(),this.allNodesMap={},this.nextId=0,this.loadNewRowData(e),this.updateRootSiblingArrays(t))}updateRootSiblingArrays(e){const t=e.sibling;t&&(t.childrenAfterFilter=e.childrenAfterFilter,t.childrenAfterGroup=e.childrenAfterGroup,t.childrenAfterAggFilter=e.childrenAfterAggFilter,t.childrenAfterSort=e.childrenAfterSort,t.childrenMapped=e.childrenMapped,t.allLeafChildren=e.allLeafChildren)}loadNewRowData(e){this.rootNode.allLeafChildren=e?.map((e,t)=>this.createRowNode(e,t))??[]}setImmutableRowData(e,t){const o=Ft(this.gos),i=!this.gos.get("suppressMaintainUnsortedOrder"),s=e.changedRowNodes,n=new Set,r=this.rootNode,a=r.allLeafChildren,l=a.length;let d=!1,h=!1,c=!1,u=!1;for(let e=0,r=-1,a=t.length;e<a;e++){const a=t[e];let l=this.getRowNode(o({data:a,level:0}));if(l){if(i){const e=l.sourceRowIndex;u||(u=e<=r||d),r=e}l.data!==a&&(c=!0,l.updateData(a),s.update(l))}else d=!0,l=this.createRowNode(a,-1),s.add(l);n.add(l)}const g=[];for(let e=0;e<l;e++){const t=a[e];n.has(t)||(h=!0,t.isSelected()&&g.push(t),t.pinnedSibling&&this.beans.pinnedRowModel?.pinRow(t.pinnedSibling,null),this.rowNodeDeleted(t),s.remove(t))}if(d||h||u){const t=new Array(n.size);let o=0;if(!i)for(let e=0;e<l;++e){const i=a[e];n.delete(i)&&(i.sourceRowIndex=o,t[o++]=i)}for(const e of n)e.sourceRowIndex=o,t[o++]=e;r.allLeafChildren=t;const s=r.sibling;s&&(s.allLeafChildren=t),e.rowNodesOrderChanged||(e.rowNodesOrderChanged=u)}(d||h||u||c)&&(this.deselectNodes(g),e.rowDataUpdated=!0)}rowNodeDeleted(e){e.clearRowTopAndRowIndex();const t=e.id,o=this.allNodesMap;o[t]===e&&delete o[t]}updateRowData(e,t){this.dispatchRowDataUpdateStartedEvent(e.add);const o={changedRowNodes:t,rowNodeTransaction:{remove:[],update:[],add:[]},rowsInserted:!1},i=[],s=Ft(this.gos);return this.executeRemove(s,e,o,i),this.executeUpdate(s,e,o,i),this.executeAdd(e,o),this.deselectNodes(i),o}executeAdd(e,t){const o=e.add;if(!o?.length)return;let i=this.rootNode.allLeafChildren,s=i.length;if("number"==typeof e.addIndex&&(s=this.sanitizeAddIndex(e.addIndex),s>0)){if(this.gos.get("treeData")&&this.gos.get("getDataPath"))for(let e=0;e<i.length;e++){const t=i[e];if(t?.rowIndex==s-1){s=e+1;break}}}const n=o.length,r=t.changedRowNodes,a=new Array(n);for(let e=0;e<n;e++){const t=this.createRowNode(o[e],s+e);r.add(t),a[e]=t}const l=this.rootNode;if(s<i.length){const e=i.slice(0,s),o=i.slice(s,i.length),n=e.length+a.length;for(let e=0,t=o.length;e<t;++e)o[e].sourceRowIndex=n+e;i=[...e,...a,...o],t.rowsInserted=!0}else i=i.concat(a);l.allLeafChildren=i;const d=l.sibling;d&&(d.allLeafChildren=i),t.rowNodeTransaction.add=a}executeRemove(e,t,{changedRowNodes:o,rowNodeTransaction:i},s){const{remove:n}=t;if(!n?.length)return;const r={};n.forEach(t=>{const n=this.lookupRowNode(e,t);n&&(n.isSelected()&&s.push(n),n.pinnedSibling&&this.beans.pinnedRowModel?.pinRow(n.pinnedSibling,null),n.clearRowTopAndRowIndex(),r[n.id]=!0,delete this.allNodesMap[n.id],i.remove.push(n),o.remove(n))});const a=this.rootNode;a.allLeafChildren=a.allLeafChildren?.filter(e=>!r[e.id])??null,a.allLeafChildren?.forEach((e,t)=>{e.sourceRowIndex=t});const l=a.sibling;l&&(l.allLeafChildren=a.allLeafChildren)}executeUpdate(e,t,{changedRowNodes:o,rowNodeTransaction:i},s){const{update:n}=t;n?.length&&n.forEach(t=>{const n=this.lookupRowNode(e,t);n&&(n.updateData(t),!n.selectable&&n.isSelected()&&s.push(n),i.update.push(n),o.update(n))})}dispatchRowDataUpdateStartedEvent(e){this.eventSvc.dispatchEvent({type:"rowDataUpdateStarted",firstRowData:e?.length?e[0]:null})}deselectNodes(e){const t="rowDataChanged",o=this.beans.selectionSvc,i=e.length>0;i&&o?.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t}),o?.updateGroupsFromChildrenSelections?.(t),i&&this.eventSvc.dispatchEvent({type:"selectionChanged",source:t,selectedNodes:o?.getSelectedNodes()??null,serverSideState:null})}sanitizeAddIndex(e){const t=this.rootNode.allLeafChildren?.length??0;return e<0||e>=t||Number.isNaN(e)?t:Math.ceil(e)}createRowNode(e,t){const o=new _n(this.beans);return o.parent=this.rootNode,o.level=0,o.group=!1,o.expanded=!1,o.sourceRowIndex=t,o.setDataAndId(e,String(this.nextId)),this.allNodesMap[o.id]&&st(2,{nodeId:o.id}),this.allNodesMap[o.id]=o,this.nextId++,o}lookupRowNode(e,t){let o;if(e){const i=e({data:t,level:0});if(o=this.allNodesMap[i],!o)return nt(4,{id:i}),null}else if(o=this.rootNode?.allLeafChildren?.find(e=>e.data===t),!o)return nt(5,{data:t}),null;return o||null}};function Fl(e){return!(!e.rowPinned||!e.pinnedSibling)}function Pl(e,t,o,i){const s="top"===t;if(!o)return Pl(e,t,s?e.getPinnedTopRow(0):e.getPinnedBottomRow(0),i);if(!i){const i=s?e.getPinnedTopRowCount():e.getPinnedBottomRowCount();return Pl(e,t,o,s?e.getPinnedTopRow(i-1):e.getPinnedBottomRow(i-1))}let n=!1,r=!1;const a=[];return e.forEachPinnedRow(t,e=>e!==o||n?n&&e===i?(r=!0,void a.push(e)):void(n&&!r&&a.push(e)):(n=!0,void a.push(e))),a}var Dl={tag:"div",cls:"ag-selection-checkbox",role:"presentation",children:[{tag:"ag-checkbox",ref:"eCheckbox",role:"presentation"}]},Ml=class extends Uo{constructor(){super(Dl,[Ms]),this.eCheckbox=Go}postConstruct(){this.eCheckbox.setPassive(!0)}onDataChanged(){this.onSelectionChanged()}onSelectableChanged(){this.showOrHideSelect()}onSelectionChanged(){const e=this.getLocaleTextFunc(),{rowNode:t,eCheckbox:o}=this,i=t.isSelected(),s=A(e,i),[n,r]=t.selectable?["ariaRowToggleSelection","Press Space to toggle row selection"]:["ariaRowSelectionDisabled","Row Selection is disabled for this row"],a=e(n,r);o.setValue(i,!0),o.setInputAriaLabel(`${a} (${s})`)}init(e){this.rowNode=e.rowNode,this.column=e.column,this.overrides=e.overrides,this.onSelectionChanged(),this.addManagedListeners(this.eCheckbox.getInputElement(),{dblclick:Fr,click:e=>{Fr(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?kt(e):void 0)!==("object"==typeof t?kt(t):void 0)&&this.onSelectableChanged()});if(At(this.gos)||"function"==typeof this.getIsVisible()){const 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(){const{column:e,rowNode:t,overrides:o,gos:i}=this,s=t.selectable,n=this.getIsVisible();let r;if("function"==typeof n){const i=o?.callbackParams;if(e){const o=e.createColumnFunctionCallbackParams(t);r=n({...i,...o})}else r=n({...i,node:t,data:t.data})}else r=n??!1;const a=s&&!r||!s&&r,l=s||r,d=i.get("rowSelection"),h=d&&"string"!=typeof d?!kt(d):!!e?.getColDef().showDisabledCheckboxes;this.setVisible(l&&(!a||h)),this.setDisplayed(l&&(!a||h)),l&&this.eCheckbox.setDisabled(a),o?.removeHidden&&this.setDisplayed(l)}getIsVisible(){const e=this.overrides;if(e)return e.isVisible;const t=this.gos.get("rowSelection");return t&&"string"!=typeof t?Pt(t):this.column?.getColDef()?.checkboxSelection}},kl=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){const 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;const{rowModel:o,pinnedRowModel:i}=this;return t??(t=o.getRowNode(e)),i?.isManual()&&(t??(t=i.getPinnedRowById(e,"top")),t??(t=i.getPinnedRowById(e,"bottom"))),t}truncate(e){const t=this.getRange();if(0===t.length)return{keep:[],discard:[]};const o=t[0].id===this.rootId,i=t.findIndex(t=>t.id===e.id);if(i>-1){const s=t.slice(0,i),n=t.slice(i+1);return this.setEndRange(e),o?{keep:s,discard:n}:{keep:n,discard:s}}return{keep:t,discard:[]}}extend(e,t=!1){const o=this.getRoot();if(null==o){const o=this.getRange().slice();return t&&e.depthFirstSearch(e=>!e.group&&o.push(e)),o.push(e),this.setRoot(e),{keep:o,discard:[]}}const i=this.getNodesInRange(o,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:[]};{const t=this.getRange().slice();return this.setEndRange(e),{keep:this.getRange(),discard:t}}}getNodesInRange(e,t){const{pinnedRowModel:o,rowModel:i}=this;if(!o?.isManual())return i.getNodesInRangeForSelection(e,t);if("top"===e.rowPinned&&!t.rowPinned){return Pl(o,"top",e,void 0).concat(i.getNodesInRangeForSelection(i.getRow(0),t)??[])}if("bottom"===e.rowPinned&&!t.rowPinned){const s=Pl(o,"bottom",void 0,e),n=i.getRowCount(),r=i.getRow(n-1);return(i.getNodesInRangeForSelection(t,r)??[]).concat(s)}if(!e.rowPinned&&!t.rowPinned)return i.getNodesInRangeForSelection(e,t);if("top"===e.rowPinned&&"top"===t.rowPinned)return Pl(o,"top",e,t);if("bottom"===e.rowPinned&&"top"===t.rowPinned){const s=Pl(o,"top",t,void 0),n=Pl(o,"bottom",void 0,e),r=i.getRow(0),a=i.getRow(i.getRowCount()-1);return s.concat(i.getNodesInRangeForSelection(r,a)??[]).concat(n)}if(!e.rowPinned&&"top"===t.rowPinned){return Pl(o,"top",t,void 0).concat(i.getNodesInRangeForSelection(i.getRow(0),e)??[])}if("top"===e.rowPinned&&"bottom"===t.rowPinned){const s=Pl(o,"top",e,void 0),n=Pl(o,"bottom",void 0,t),r=i.getRow(0),a=i.getRow(i.getRowCount()-1);return s.concat(i.getNodesInRangeForSelection(r,a)??[]).concat(n)}if("bottom"===e.rowPinned&&"bottom"===t.rowPinned)return Pl(o,"bottom",e,t);if(!e.rowPinned&&"bottom"===t.rowPinned){const s=Pl(o,"bottom",void 0,t),n=i.getRow(i.getRowCount());return(i.getNodesInRangeForSelection(e,n)??[]).concat(s)}return null}},Tl=class extends Me{constructor(e){super(),this.column=e,this.cbSelectAllVisible=!1,this.processingEventFromCheckbox=!1}onSpaceKeyDown(e){const t=this.cbSelectAll;t.isDisplayed()&&!t.getGui().contains(u(this.beans))&&(e.preventDefault(),t.setValue(!t.getValue()))}getCheckboxGui(){return this.cbSelectAll.getGui()}setComp(e){this.headerCellCtrl=e;const t=this.createManagedBean(new Ds);this.cbSelectAll=t,t.addCss("ag-header-select-all"),y(t.getGui(),"presentation"),this.showOrHideSelectAll();const o=this.updateStateOfCheckbox.bind(this);this.addManagedEventListeners({newColumnsLoaded:()=>this.showOrHideSelectAll(),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),selectionChanged:o,paginationChanged:o,modelUpdated:o}),this.addManagedPropertyListener("rowSelection",({currentValue:e,previousValue:t})=>{const o=e=>"string"!=typeof e&&e&&"singleRow"!==e.mode?e.selectAll:void 0;o(e)!==o(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){const 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;const e=this.getSelectAllMode(),t=this.beans.selectionSvc,o=this.cbSelectAll,i=t.getSelectAllState(e);o.setValue(i);const s=t.hasNodesToSelect(e);o.setDisabled(!s),this.refreshSelectAllLabel(),this.processingEventFromCheckbox=!1}refreshSelectAllLabel(e=!1){const t=this.getLocaleTextFunc(),{headerCellCtrl:o,cbSelectAll:i,cbSelectAllVisible:s}=this,n=A(t,i.getValue()),r=t("ariaRowSelectAll","Press Space to toggle all rows selection");o.setAriaDescriptionProperty("selectAll",s?`${r} (${n})`:null),i.setInputAriaLabel(t("ariaHeaderSelection","Column with Header Selection")),e||o.announceAriaDescription()}checkSelectionType(e){return!!Bt(this.gos)||(st(128,{feature:e}),!1)}checkRightRowModelType(e){const{gos:t,rowModel:o}=this.beans;return!(!dt(t)&&!ht(t))||(st(129,{feature:e,rowModel:o.getType()}),!1)}onCbSelectAll(){if(this.processingEventFromCheckbox)return;if(!this.cbSelectAllVisible)return;const e=this.cbSelectAll.getValue(),t=this.getSelectAllMode();let o="uiSelectAll";"currentPage"===t?o="uiSelectAllCurrentPage":"filtered"===t&&(o="uiSelectAllFiltered");const i={source:o,selectAll:t},s=this.beans.selectionSvc;e?s.selectAllRowNodes(i):s.deselectAllRowNodes(i)}isCheckboxSelection(){const{column:e,gos:t,beans:o}=this,i="object"==typeof t.get("rowSelection")?"headerCheckbox":"headerCheckboxSelection";return Il(o,e)&&this.checkRightRowModelType(i)&&this.checkSelectionType(i)}getSelectAllMode(){const e=Vt(this.gos,!1);if(e)return e;const{headerCheckboxSelectionCurrentPageOnly:t,headerCheckboxSelectionFilteredOnly:o}=this.column.getColDef();return t?"currentPage":o?"filtered":"all"}destroy(){super.destroy(),this.cbSelectAll=void 0,this.headerCellCtrl=void 0}};function Il({gos:e,selectionColSvc:t},o){const i=e.get("rowSelection"),s=o.getColDef(),{headerCheckboxSelection:n}=s;let r=!1;if("object"==typeof i){const e=po(o),s=go(o);("autoGroupColumn"===Mt(i)&&s||e&&t?.isSelectionColumnEnabled())&&(r=Dt(i))}else r="function"==typeof n?n(zt(e,{column:o,colDef:s})):!!n;return r}var Al=class extends Me{postConstruct(){const{gos:e,beans:t}=this;this.selectionCtx=new kl(t.rowModel,t.pinnedRowModel),this.addManagedPropertyListeners(["isRowSelectable","rowSelection"],()=>{const t=At(e);t!==this.isRowSelectable&&(this.isRowSelectable=t,this.updateSelectable())}),this.isRowSelectable=At(e),this.addManagedEventListeners({cellValueChanged:e=>this.updateRowSelectable(e.node),rowNodeDataChanged:e=>this.updateRowSelectable(e.node)})}destroy(){super.destroy(),this.selectionCtx.reset()}createCheckboxSelectionComponent(){return new Ml}createSelectAllFeature(e){if(Il(this.beans,e))return new Tl(e)}isMultiSelect(){return Bt(this.gos)}onRowCtrlSelected(e,t,o){const i=!!e.rowNode.isSelected();e.forEachGui(o,e=>{e.rowComp.toggleCss("ag-row-selected",i);const o=e.element;k(o,i);o.contains(u(this.beans))&&t(e)})}announceAriaRowSelection(e){if(this.isRowSelectionBlocked(e))return;const t=e.isSelected();if(!e.selectable)return;const o=this.getLocaleTextFunc()(t?"ariaRowDeselect":"ariaRowSelect",`Press SPACE to ${t?"deselect":"select"} this row`);this.beans.ariaAnnounce?.announceValue(o,"rowSelection")}isRowSelectionBlocked(e){return!e.selectable||e.rowPinned&&!Fl(e)||!ut(this.gos)}updateRowSelectable(e,t){const o=e.rowPinned&&e.pinnedSibling?e.pinnedSibling.selectable:this.isRowSelectable?.(e)??!0;return this.setRowSelectable(e,o,t),o}setRowSelectable(e,t,o){if(e.selectable!==t){if(e.selectable=t,e.dispatchRowEvent("selectableChanged"),o)return;if(Gt(this.gos)){const t=this.calculateSelectedFromChildren(e);return void this.setNodesSelected({nodes:[e],newValue:t??!1,source:"selectableChanged"})}e.isSelected()&&!e.selectable&&this.setNodesSelected({nodes:[e],newValue:!1,source:"selectableChanged"})}}calculateSelectedFromChildren(e){let t=!1,o=!1;if(!e.childrenAfterGroup?.length)return e.selectable?e.__selected:null;for(let i=0;i<e.childrenAfterGroup.length;i++){const s=e.childrenAfterGroup[i];let n=s.isSelected();if(!s.selectable){const e=this.calculateSelectedFromChildren(s);if(null===e)continue;n=e}switch(n){case!0:t=!0;break;case!1:o=!0;break;default:return}}return t&&o?void 0:!!t||!o&&(e.selectable?e.__selected:null)}selectRowNode(e,t,o,i="api"){const s=!e.selectable&&t,n=e.__selected===t;if(s||n)return!1;e.__selected=t,e.dispatchRowEvent("rowSelected");const r=e.sibling;r&&r.footer&&r.__localEventService&&r.dispatchRowEvent("rowSelected");const a=e.pinnedSibling;return a&&a.rowPinned&&a.__localEventService&&a.dispatchRowEvent("rowSelected"),this.eventSvc.dispatchEvent({...Yn(e,this.gos,"rowSelected"),event:o||null,source:i}),!0}isCellCheckboxSelection(e,t){const o=this.gos.get("rowSelection");if(o&&"string"!=typeof o){const i=po(e)&&Pt(o);return e.isColumnFunc(t,i)}return e.isColumnFunc(t,e.colDef.checkboxSelection)}inferNodeSelections(e,t,o,i){const{gos:s,selectionCtx:n}=this,r=e.isSelected(),a=Gt(s),l=function(e){const t=It(e);return!0===t||"enableSelection"===t}(s),d=function(e){const t=It(e);return!0===t||"enableDeselection"===t}(s),h=this.isMultiSelect(),c="rowClicked"===i;if(c&&!l&&!d)return null;if(t&&o&&h){const t=n.getRoot();if(t){if(t.isSelected()){const t=n.isInRange(e)?n.truncate(e):n.extend(e,a);return{deselect:t.discard,select:t.keep,reset:!1}}return{select:[],deselect:n.extend(e,a).keep,reset:!1}}return null}if(t&&h){const t=n.selectAll?this.beans.rowModel.getRow(0):void 0,o=n.getRoot(t),i=n.isInRange(e)?n.truncate(e):n.extend(e,a);return{select:i.keep,deselect:i.discard,reset:n.selectAll||!(!o||o.isSelected())}}if(o){if(c){const t=!r;return t&&!l||!t&&!d?null:(n.setRoot(e),{node:e,newValue:t,clearSelection:!1})}return n.setRoot(e),{node:e,newValue:!r,clearSelection:!h}}{n.setRoot(e);const t=function(e){const t=e.get("rowSelection");return"string"==typeof t?e.get("rowMultiSelectWithClick"):t?.enableSelectionWithoutKeys??!1}(s),o=c&&(!t||!l);if("filteredDescendants"===Ht(s)&&void 0===r&&dt(s))return{node:e,newValue:!1,checkFilteredNodes:!0,clearSelection:!h||o};if(c){const i=r?!t:l;return i===r&&!o||i&&!l||!i&&!d?null:{node:e,newValue:i,clearSelection:!h||o,keepDescendants:e.group&&a}}return{node:e,newValue:!r,clearSelection:!h||o}}}},Ll="ag-tab-guard",Bl="ag-tab-guard-top",Hl="ag-tab-guard-bottom",Vl=class extends Me{constructor(e){super(),this.skipTabGuardFocus=!1,this.forcingFocusOut=!1,this.allowFocus=!1;const{comp:t,eTopGuard:o,eBottomGuard:i,focusTrapActive:s,forceFocusOutWhenTabGuardsAreEmpty:n,isFocusableContainer:r,focusInnerElement:a,onFocusIn:l,onFocusOut:d,shouldStopEventPropagation:h,onTabKeyDown:c,handleKeyDown:u,isEmpty:g,eFocusableElement:p}=e;this.comp=t,this.eTopGuard=o,this.eBottomGuard=i,this.providedFocusInnerElement=a,this.eFocusableElement=p,this.focusTrapActive=!!s,this.forceFocusOutWhenTabGuardsAreEmpty=!!n,this.isFocusableContainer=!!r,this.providedFocusIn=l,this.providedFocusOut=d,this.providedShouldStopEventPropagation=h,this.providedOnTabKeyDown=c,this.providedHandleKeyDown=u,this.providedIsEmpty=g}postConstruct(){this.createManagedBean(new Dr(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].forEach(e=>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;const 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)return void(this.skipTabGuardFocus=!1);if(this.forceFocusOutWhenTabGuardsAreEmpty){if(this.providedIsEmpty?this.providedIsEmpty():0===ws(this.eFocusableElement,".ag-tab-guard").length)return void this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard)}if(this.isFocusableContainer&&this.eFocusableElement.contains(e.relatedTarget))return;const t=e.target===this.eBottomGuard;!(this.providedFocusInnerElement?this.providedFocusInnerElement(t):this.focusInnerElement(t))&&this.forceFocusOutWhenTabGuardsAreEmpty&&this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard)}findNextElementOutsideAndFocus(e){const t=ws(g(this.beans).body,null,!0),o=t.indexOf(e?this.eTopGuard:this.eBottomGuard);if(-1===o)return;let i,s;e?(i=0,s=o):(i=o+1,s=t.length);const n=t.slice(i,s),r=this.gos.get("tabIndex");n.sort((e,t)=>{const o=parseInt(e.getAttribute("tabindex")||"0"),i=parseInt(t.getAttribute("tabindex")||"0");return i===r?1:o===r?-1:0===o?1:0===i?-1:o-i}),n[e?n.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)return;if(e.defaultPrevented)return;const t=this.tabGuardsAreActive();t&&this.deactivateTabGuards();const o=this.getNextFocusableElement(e.shiftKey);t&&setTimeout(()=>this.activateTabGuards(),0),o&&(o.focus(),e.preventDefault())}focusInnerElement(e=!1){const t=ws(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 ys(this.beans,this.eFocusableElement,!1,e)}forceFocusOutOfContainer(e=!1){if(this.forcingFocusOut)return;const 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}},Gl=class extends Me{constructor(e){super(),this.comp=e}initialiseTabGuard(e){this.eTopGuard=this.createTabGuard("top"),this.eBottomGuard=this.createTabGuard("bottom"),this.eFocusableElement=this.comp.getFocusableElement();const{eTopGuard:t,eBottomGuard:o,eFocusableElement:i}=this,s=[t,o],n={setTabIndex:e=>{s.forEach(t=>null!=e?t.setAttribute("tabindex",e):t.removeAttribute("tabindex"))}};this.addTabGuards(t,o);const{focusTrapActive:r=!1,onFocusIn:a,onFocusOut:l,focusInnerElement:d,handleKeyDown:h,onTabKeyDown:c,shouldStopEventPropagation:u,isEmpty:g,forceFocusOutWhenTabGuardsAreEmpty:p,isFocusableContainer:m}=e;this.tabGuardCtrl=this.createManagedBean(new Vl({comp:n,focusTrapActive:r,eTopGuard:t,eBottomGuard:o,eFocusableElement:i,onFocusIn:a,onFocusOut:l,focusInnerElement:d,handleKeyDown:h,onTabKeyDown:c,shouldStopEventPropagation:u,isEmpty:g,forceFocusOutWhenTabGuardsAreEmpty:p,isFocusableContainer:m}))}getTabGuardCtrl(){return this.tabGuardCtrl}createTabGuard(e){const t=g(this.beans).createElement("div"),o="top"===e?Bl:Hl;return t.classList.add(Ll,o),y(t,"presentation"),t}addTabGuards(e,t){const o=this.eFocusableElement;o.insertAdjacentElement("afterbegin",e),o.insertAdjacentElement("beforeend",t)}removeAllChildrenExceptTabGuards(){const e=[this.eTopGuard,this.eBottomGuard];q(this.comp.getFocusableElement()),this.addTabGuards(...e)}forceFocusOutOfContainer(e=!1){this.tabGuardCtrl.forceFocusOutOfContainer(e)}appendChild(e,t,o){de(t)||(t=t.getGui());const{eBottomGuard:i}=this;i?i.insertAdjacentElement("beforebegin",t):e(t,o)}destroy(){const{eTopGuard:e,eBottomGuard:t}=this;_(e),_(t),super.destroy()}},Nl=class extends Uo{initialiseTabGuard(e){this.tabGuardFeature=this.createManagedBean(new Gl(this)),this.tabGuardFeature.initialiseTabGuard(e)}forceFocusOutOfContainer(e=!1){this.tabGuardFeature.forceFocusOutOfContainer(e)}appendChild(e,t){this.tabGuardFeature.appendChild(super.appendChild.bind(this),e,t)}},Ol=class{constructor(t,o=!1){this.DOUBLE_TAP_MILLIS=500,this.destroyFuncs=[],this.touching=!1,this.localEventService=new e,this.preventMouseClick=o;const i=this.onTouchStart.bind(this),s=this.onTouchMove.bind(this),n=this.onTouchEnd.bind(this);t.addEventListener("touchstart",i,{passive:!0}),t.addEventListener("touchmove",s,{passive:!0}),t.addEventListener("touchend",n,{passive:!1}),this.destroyFuncs.push(()=>{t.removeEventListener("touchstart",i,{passive:!0}),t.removeEventListener("touchmove",s,{passive:!0}),t.removeEventListener("touchend",n,{passive:!1})})}getActiveTouch(e){for(let t=0;t<e.length;t++){if(e[t].identifier===this.touchStart.identifier)return e[t]}return null}addEventListener(e,t){this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService.removeEventListener(e,t)}onTouchStart(e){if(this.touching)return;this.touchStart=e.touches[0],this.touching=!0,this.moved=!1;const t=this.touchStart;window.setTimeout(()=>{const o=this.touchStart===t;if(this.touching&&o&&!this.moved){this.moved=!0;const t={type:"longTap",touchStart:this.touchStart,touchEvent:e};this.localEventService.dispatchEvent(t)}},500)}onTouchMove(e){if(!this.touching)return;const t=this.getActiveTouch(e.touches);if(!t)return;!Ee(t,this.touchStart,4)&&(this.moved=!0)}onTouchEnd(e){if(this.touching){if(!this.moved){const e={type:"tap",touchStart:this.touchStart};this.localEventService.dispatchEvent(e),this.checkForDoubleTap()}this.preventMouseClick&&e.cancelable&&e.preventDefault(),this.touching=!1}}checkForDoubleTap(){const e=Date.now();if(this.lastTapTime&&this.lastTapTime>0){if(e-this.lastTapTime>this.DOUBLE_TAP_MILLIS){const e={type:"doubleTap",touchStart:this.touchStart};this.localEventService.dispatchEvent(e),this.lastTapTime=null}else this.lastTapTime=e}else this.lastTapTime=e}destroy(){this.destroyFuncs.forEach(e=>e())}},zl=class{constructor(e){this.tickingInterval=null,this.onScrollCallback=null,this.scrollContainer=e.scrollContainer,this.scrollHorizontally=-1!==e.scrollAxis.indexOf("x"),this.scrollVertically=-1!==e.scrollAxis.indexOf("y"),this.scrollByTick=null!=e.scrollByTick?e.scrollByTick:20,e.onScrollCallback&&(this.onScrollCallback=e.onScrollCallback),this.scrollVertically&&(this.getVerticalPosition=e.getVerticalPosition,this.setVerticalPosition=e.setVerticalPosition),this.scrollHorizontally&&(this.getHorizontalPosition=e.getHorizontalPosition,this.setHorizontalPosition=e.setHorizontalPosition),this.shouldSkipVerticalScroll=e.shouldSkipVerticalScroll||(()=>!1),this.shouldSkipHorizontalScroll=e.shouldSkipHorizontalScroll||(()=>!1)}check(e,t=!1){const o=t||this.shouldSkipVerticalScroll();if(o&&this.shouldSkipHorizontalScroll())return;const i=this.scrollContainer.getBoundingClientRect(),s=this.scrollByTick;this.tickLeft=e.clientX<i.left+s,this.tickRight=e.clientX>i.right-s,this.tickUp=e.clientY<i.top+s&&!o,this.tickDown=e.clientY>i.bottom-s&&!o,this.tickLeft||this.tickRight||this.tickUp||this.tickDown?this.ensureTickingStarted():this.ensureCleared()}ensureTickingStarted(){null===this.tickingInterval&&(this.tickingInterval=window.setInterval(this.doTick.bind(this),100),this.tickCount=0)}doTick(){this.tickCount++;const e=this.tickCount>20?200:this.tickCount>10?80:40;if(this.scrollVertically){const t=this.getVerticalPosition();this.tickUp&&this.setVerticalPosition(t-e),this.tickDown&&this.setVerticalPosition(t+e)}if(this.scrollHorizontally){const t=this.getHorizontalPosition();this.tickLeft&&this.setHorizontalPosition(t-e),this.tickRight&&this.setHorizontalPosition(t+e)}this.onScrollCallback&&this.onScrollCallback()}ensureCleared(){this.tickingInterval&&(window.clearInterval(this.tickingInterval),this.tickingInterval=null)}},Wl=class{constructor(e="javascript"){var t;this.frameworkName=e,this.renderingEngine="vanilla",this.batchFrameworkComps=!1,this.wrapIncoming=e=>e(),this.wrapOutgoing=e=>e(),this.baseDocLink=`${Ue}/${this.frameworkName}-data-grid`,t=this.baseDocLink,Qe=t}frameworkComponent(e){return null}isFrameworkComponent(e){return!1}getDocLink(e){return`${this.baseDocLink}${e?`/${e}`:""}`}};function Ul(e){return{beanName:"gridApi",bean:e.getBean("apiFunctionSvc").api}}var $l=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 Kl(e,t){return((e.beanName?$l[e.beanName]:void 0)??Number.MAX_SAFE_INTEGER)-((t.beanName?$l[t.beanName]:void 0)??Number.MAX_SAFE_INTEGER)}function jl(e,t){return"gridDestroySvc"===e?.beanName?-1:"gridDestroySvc"===t?.beanName?1:0}var ql={tag:"div",cls:"ag-pinned-left-header",role:"rowgroup"},_l={tag:"div",cls:"ag-pinned-right-header",role:"rowgroup"},Yl={tag:"div",cls:"ag-header-viewport",role:"rowgroup",attrs:{tabindex:"-1"},children:[{tag:"div",ref:"eCenterContainer",cls:"ag-header-container",role:"presentation"}]},Ql=class extends Uo{constructor(e){super(),this.eCenterContainer=Go,this.headerRowComps={},this.rowCompsList=[],this.pinned=e}postConstruct(){this.selectAndSetTemplate();const e={setDisplayed:e=>this.setDisplayed(e),setCtrls:e=>this.setCtrls(e),setCenterWidth:e=>this.eCenterContainer.style.width=e,setViewportScrollLeft:e=>this.getGui().scrollLeft=e,setPinnedContainerWidth:e=>{const t=this.getGui();t.style.width=e,t.style.maxWidth=e,t.style.minWidth=e}};this.createManagedBean(new el(this.pinned)).setComp(e,this.getGui())}selectAndSetTemplate(){const e="left"==this.pinned,t="right"==this.pinned,o=e?ql:t?_l:Yl;this.setTemplate(o),this.eRowContainer=this.eCenterContainer!==Go?this.eCenterContainer:this.getGui()}destroy(){this.setCtrls([]),super.destroy()}destroyRowComp(e){this.destroyBean(e),this.eRowContainer.removeChild(e.getGui())}setCtrls(e){const t=this.headerRowComps;let o;this.headerRowComps={},this.rowCompsList=[];const i=e=>{const t=e.getGui();t.parentElement!=this.eRowContainer&&this.eRowContainer.appendChild(t),o&&J(this.eRowContainer,t,o),o=t};e.forEach(e=>{const o=e.instanceId,s=t[o];delete t[o];const n=s||this.createBean(new Ka(e));this.headerRowComps[o]=n,this.rowCompsList.push(n),i(n)}),Object.values(t).forEach(e=>this.destroyRowComp(e))}},Zl={tag:"div",cls:"ag-header",role:"presentation"},Jl={selector:"AG-HEADER-ROOT",component:class extends Uo{constructor(){super(Zl)}postConstruct(){const e={toggleCss:(e,t)=>this.toggleCss(e,t),setHeightAndMinHeight:e=>{this.getGui().style.height=e,this.getGui().style.minHeight=e}};this.createManagedBean(new Va).setComp(e,this.getGui(),this.getFocusableElement());const t=e=>{this.createManagedBean(e),this.appendChild(e)};t(new Ql("left")),t(new Ql(null)),t(new Ql("right"))}}},Xl=class extends Uo{constructor(e,t,o,i,s){super(),this.cellCtrl=t,this.rendererVersion=0,this.editorVersion=0,this.beans=e,this.gos=e.gos,this.column=t.column,this.rowNode=t.rowNode,this.eRow=i;const n=sr({tag:"div",role:t.getCellAriaRole(),attrs:{"comp-id":`${this.getCompId()}`,"col-id":t.column.colIdSanitised}});let r;this.eCell=n,t.isCellSpanning()?(r=sr({tag:"div",cls:"ag-spanned-cell-wrapper",role:"presentation"}),r.appendChild(n),this.setTemplateFromElement(r)):this.setTemplateFromElement(n),this.cellCssManager=new Oo(()=>n),this.forceWrapper=t.isForceWrapper(),this.refreshWrapper(!1);const a={toggleCss:(e,t)=>this.cellCssManager.toggleCss(e,t),setUserStyles:e=>te(n,e),getFocusableElement:()=>n,setIncludeSelection:e=>this.includeSelection=e,setIncludeRowDrag:e=>this.includeRowDrag=e,setIncludeDndSource:e=>this.includeDndSource=e,setRenderDetails:(e,t,o)=>this.setRenderDetails(e,t,o),setEditDetails:(e,t,o)=>this.setEditDetails(e,t,o),getCellEditor:()=>this.cellEditor||null,getCellRenderer:()=>this.cellRenderer||null,getParentOfValue:()=>this.getParentOfValue(),refreshEditStyles:(e,t)=>this.refreshEditStyles(e,t)};t.setComp(a,n,r,this.eCellWrapper,o,s,void 0)}getParentOfValue(){return this.eCellValue??this.eCellWrapper??this.eCell}setRenderDetails(e,t,o){if(this.cellEditor&&!this.cellEditorPopupWrapper)return;this.firstRender=null==this.firstRender;const i=this.refreshWrapper(!1);if(this.refreshEditStyles(!1),e){!(o||i)&&this.refreshCellRenderer(e)||(this.destroyRenderer(),this.createCellRendererInstance(e))}else this.destroyRenderer(),this.insertValueWithoutCellRenderer(t);this.rowDraggingComp?.refreshVisibility()}setEditDetails(e,t,o){e?this.createCellEditorInstance(e,t,o):this.destroyEditor()}removeControls(){const e=this.beans.context;this.checkboxSelectionComp=e.destroyBean(this.checkboxSelectionComp),this.dndSourceComp=e.destroyBean(this.dndSourceComp),this.rowDraggingComp=e.destroyBean(this.rowDraggingComp)}refreshWrapper(e){const t=this.includeRowDrag||this.includeDndSource||this.includeSelection,o=t||this.forceWrapper,i=o&&null==this.eCellWrapper;i&&(this.eCellWrapper=sr({tag:"div",cls:"ag-cell-wrapper",role:"presentation"}),this.eCell.appendChild(this.eCellWrapper));const s=!o&&null!=this.eCellWrapper;s&&(_(this.eCellWrapper),this.eCellWrapper=void 0),this.cellCssManager.toggleCss("ag-cell-value",!o);const n=!e&&o,r=n&&null==this.eCellValue;r&&(this.eCellValue=sr({tag:"span",cls:"ag-cell-value",role:"presentation"}),this.eCellWrapper.appendChild(this.eCellValue));const a=!n&&null!=this.eCellValue;a&&(_(this.eCellValue),this.eCellValue=void 0);const l=i||s||r||a;return l&&this.removeControls(),!e&&t&&this.addControls(),l}addControls(){const{cellCtrl:e,eCellWrapper:t,eCellValue:o,includeRowDrag:i,includeDndSource:s,includeSelection:n}=this,r=e=>{e&&t.insertBefore(e.getGui(),o)};i&&null==this.rowDraggingComp&&(this.rowDraggingComp=e.createRowDragComp(),r(this.rowDraggingComp)),s&&null==this.dndSourceComp&&(this.dndSourceComp=e.createDndSource(),r(this.dndSourceComp)),n&&null==this.checkboxSelectionComp&&(this.checkboxSelectionComp=e.createSelectionCheckbox(),r(this.checkboxSelectionComp))}createCellEditorInstance(e,t,o){const s=this.editorVersion,n=e.newAgStackInstance(),{params:r}=e;n.then(e=>this.afterCellEditorCreated(s,e,r,t,o));i(this.cellEditor)&&r.cellStartedEdit&&this.cellCtrl.focusCell(!0)}insertValueWithoutCellRenderer(e){const t=this.getParentOfValue();q(t);const o=d(e);null!=o&&(t.textContent=o)}destroyRenderer(){const{context:e}=this.beans;this.cellRenderer=e.destroyBean(this.cellRenderer),_(this.cellRendererGui),this.cellRendererGui=null,this.rendererVersion++}destroyEditor(){const{context:e}=this.beans;(this.cellEditorPopupWrapper?.getGui().contains(u(this.beans))||this.cellCtrl.hasBrowserFocus())&&this.eCell.focus({preventScroll:!0}),this.hideEditorPopup?.(),this.hideEditorPopup=void 0,this.cellEditor=e.destroyBean(this.cellEditor),this.cellEditorPopupWrapper=e.destroyBean(this.cellEditorPopupWrapper),_(this.cellEditorGui),this.cellCtrl.disableEditorTooltipFeature(),this.cellEditorGui=null,this.editorVersion++}refreshCellRenderer(e){if(null==this.cellRenderer?.refresh)return!1;if(this.cellRendererClass!==e.componentClass)return!1;const t=this.cellRenderer.refresh(e.params);return!0===t||void 0===t}createCellRendererInstance(e){const t=this.rendererVersion,o=e=>o=>{if(this.rendererVersion!==t||!this.isAlive())return;const i=e.newAgStackInstance(),s=this.afterCellRendererCreated.bind(this,t,e.componentClass);i?.then(s)},{animationFrameSvc:i}=this.beans;let s;if(s=i?.active&&this.firstRender?(e,t=!1)=>{i.createTask(o(e),this.rowNode.rowIndex,"p2",e.componentFromFramework,t)}:e=>o(e)(),e.params?.deferRender&&!this.cellCtrl.rowNode.group){const{loadingComp:t,onReady:o}=this.cellCtrl.getDeferLoadingCellRenderer();t&&(s(t),o.then(()=>s(e,!0)))}else s(e)}afterCellRendererCreated(e,t,o){if(!this.isAlive()||e!==this.rendererVersion)return void this.beans.context.destroyBean(o);this.cellRenderer=o,this.cellRendererClass=t;const i=o.getGui();if(this.cellRendererGui=i,null!=i){const e=this.getParentOfValue();q(e),e.appendChild(i)}}afterCellEditorCreated(e,t,o,i,s){const n=e!==this.editorVersion,{context:r}=this.beans;if(n)return void r.destroyBean(t);if(t.isCancelBeforeStart&&t.isCancelBeforeStart())return r.destroyBean(t),void this.cellCtrl.stopEditing(!0);if(!t.getGui)return st(97,{colId:this.column.getId()}),void r.destroyBean(t);this.cellEditor=t,this.cellEditorGui=t.getGui();const a=i||void 0!==t.isPopup&&t.isPopup();a?this.addPopupCellEditor(o,s):this.addInCellEditor(),this.refreshEditStyles(!0,a),t.afterGuiAttached?.(),this.cellCtrl.enableEditorTooltipFeature(t),this.cellCtrl.cellEditorAttached()}refreshEditStyles(e,t){const{cellCssManager:o}=this;o.toggleCss("ag-cell-inline-editing",e&&!t),o.toggleCss("ag-cell-popup-editing",e&&!!t),o.toggleCss("ag-cell-not-inline-editing",!e||!!t)}addInCellEditor(){const{eCell:e}=this;if(e.contains(u(this.beans))&&e.focus(),this.destroyRenderer(),this.refreshWrapper(!0),q(this.getParentOfValue()),this.cellEditorGui){this.getParentOfValue().appendChild(this.cellEditorGui)}}addPopupCellEditor(e,t){const{gos:o,context:i,popupSvc:s,editSvc:n}=this.beans;"fullRow"===o.get("editType")&&st(98);const r=this.cellEditorPopupWrapper=i.createBean(n.createPopupEditorWrapper(e)),{cellEditor:a,cellEditorGui:l,eCell:d,rowNode:h,column:c,cellCtrl:u}=this,g=r.getGui();l&&g.appendChild(l);const p=o.get("stopEditingWhenCellsLoseFocus"),m={ePopup:g,column:c,rowNode:h,type:"popupCellEditor",eventSource:d,position:null!=t?t:a.getPopupPosition?.()??"over",alignSide:o.get("enableRtl")?"right":"left",keepWithinBounds:!0},f=s.positionPopupByComponent.bind(s,m),C=s.addPopup({modal:p,eChild:g,closeOnEsc:!0,closedCallback:()=>{u.onPopupEditorClosed()},anchorToElement:d,positionCallback:f,ariaOwns:d});C&&(this.hideEditorPopup=C.hideFunc)}detach(){this.eRow.removeChild(this.getGui())}destroy(){this.destroyRenderer(),this.destroyEditor(),this.removeControls(),super.destroy()}},ed=class extends Uo{constructor(e,t,o){super(),this.cellComps=new Map,this.beans=t,this.rowCtrl=e;const i=sr({tag:"div",role:"row",attrs:{"comp-id":`${this.getCompId()}`}});this.setInitialStyle(i,o),this.setTemplateFromElement(i);const s=i.style;this.domOrder=this.rowCtrl.getDomOrder();const n={setDomOrder:e=>this.domOrder=e,setCellCtrls:e=>this.setCellCtrls(e),showFullWidth:e=>this.showFullWidth(e),getFullWidthCellRenderer:()=>this.fullWidthCellRenderer,getFullWidthCellRendererParams:()=>this.fullWidthCellRendererParams,toggleCss:(e,t)=>this.toggleCss(e,t),setUserStyles:e=>te(i,e),setTop:e=>s.top=e,setTransform:e=>s.transform=e,setRowIndex:e=>i.setAttribute("row-index",e),setRowId:e=>i.setAttribute("row-id",e),setRowBusinessKey:e=>i.setAttribute("row-business-key",e),refreshFullWidth:e=>{const t=e();return this.fullWidthCellRendererParams=t,this.fullWidthCellRenderer?.refresh?.(t)??!1}};e.setComp(n,this.getGui(),o,void 0),this.addDestroyFunc(()=>{e.unsetComp(o)})}setInitialStyle(e,t){const o=this.rowCtrl.getInitialTransform(t);if(o)e.style.setProperty("transform",o);else{const o=this.rowCtrl.getInitialRowTop(t);o&&e.style.setProperty("top",o)}}showFullWidth(e){e.newAgStackInstance().then(t=>{if(this.isAlive()){const o=t.getGui();this.getGui().appendChild(o),this.rowCtrl.setupDetailRowAutoHeight(o),this.setFullWidthRowComp(t,e.params)}else this.beans.context.destroyBean(t)})}setCellCtrls(e){const t=new Map(this.cellComps);for(const o of e){const e=o.instanceId;this.cellComps.has(e)?t.delete(e):this.newCellComp(o)}this.destroyCells(t),this.ensureDomOrder(e)}ensureDomOrder(e){if(!this.domOrder)return;const t=[];for(const o of e){const e=this.cellComps.get(o.instanceId);e&&t.push(e.getGui())}X(this.getGui(),t)}newCellComp(e){const t=this.beans.editSvc?.isEditing(e,{withOpenEditor:!0})??!1,o=new Xl(this.beans,e,this.rowCtrl.printLayout,this.getGui(),t);this.cellComps.set(e.instanceId,o),this.getGui().appendChild(o.getGui())}destroy(){super.destroy(),this.destroyCells(this.cellComps)}setFullWidthRowComp(e,t){this.fullWidthCellRenderer=e,this.fullWidthCellRendererParams=t,this.addDestroyFunc(()=>{this.fullWidthCellRenderer=this.beans.context.destroyBean(this.fullWidthCellRenderer),this.fullWidthCellRendererParams=void 0})}destroyCells(e){for(const t of e.values()){if(!t)return;const e=t.cellCtrl.instanceId;if(this.cellComps.get(e)!==t)return;t.detach(),t.destroy(),this.cellComps.delete(e)}}};var td={selector:"AG-ROW-CONTAINER",component:class extends Uo{constructor(e){super(),this.eViewport=Go,this.eContainer=Go,this.eSpannedContainer=Go,this.rowCompsNoSpan={},this.rowCompsWithSpan={},this.name=e?.name,this.options=aa(this.name)}postConstruct(){this.setTemplate(function(e,t,o){const i=!!o.gos.get("enableCellSpan")&&!!t.getSpannedRowCtrls,s={tag:"div",ref:"eContainer",cls:na(e),role:"rowgroup"};if("center"===t.type||i){const t={tag:"div",ref:"eSpannedContainer",cls:`ag-spanning-container ${ra(e)}`,role:"presentation"};return s.role="presentation",{tag:"div",ref:"eViewport",cls:`ag-viewport ${sa(e)}`,role:"rowgroup",children:[s,i?t:null]}}return s}(this.name,this.options,this.beans));const e={setHorizontalScroll:e=>this.eViewport.scrollLeft=e,setViewportHeight:e=>this.eViewport.style.height=e,setRowCtrls:({rowCtrls:e})=>this.setRowCtrls(e),setSpannedRowCtrls:e=>this.setRowCtrls(e,!0),setDomOrder:e=>{this.domOrder=e},setContainerWidth:e=>{this.eContainer.style.width=e,this.eSpannedContainer&&(this.eSpannedContainer.style.width=e)},setOffsetTop:e=>{const t=`translateY(${e})`;this.eContainer.style.transform=t,this.eSpannedContainer&&(this.eSpannedContainer.style.transform=t)}};this.createManagedBean(new fa(this.name)).setComp(e,this.eContainer,this.eSpannedContainer,this.eViewport)}destroy(){this.setRowCtrls([]),this.setRowCtrls([],!0),super.destroy(),this.lastPlacedElement=null}setRowCtrls(e,t){const{beans:o,options:i}=this,s=t?this.eSpannedContainer:this.eContainer,n=t?{...this.rowCompsWithSpan}:{...this.rowCompsNoSpan},r={};t?this.rowCompsWithSpan=r:this.rowCompsNoSpan=r,this.lastPlacedElement=null;const a=[];for(const t of e){const e=t.instanceId,s=n[e];let l;if(s)l=s,delete n[e];else{if(!t.rowNode.displayed)continue;l=new ed(t,o,i.type)}r[e]=l,a.push([l,!s])}this.removeOldRows(Object.values(n),s),this.addRowNodes(a,s)}addRowNodes(e,t){const{domOrder:o}=this;for(const[i,s]of e){const e=i.getGui();o?this.ensureDomOrder(e,t):s&&t.appendChild(e)}}removeOldRows(e,t){for(const o of e)t.removeChild(o.getGui()),o.destroy()}ensureDomOrder(e,t){J(t,e,this.lastPlacedElement),this.lastPlacedElement=e}}};function od(e,t){return t.map(t=>{const o=`e${t[0].toUpperCase()+t.substring(1)}RowContainer`;return e[o]={name:t},{tag:"ag-row-container",ref:o,attrs:{name:t}}})}var id={selector:"AG-GRID-BODY",component:class extends Uo{constructor(){super(...arguments),this.eGridRoot=Go,this.eBodyViewport=Go,this.eStickyTop=Go,this.eStickyBottom=Go,this.eTop=Go,this.eBottom=Go,this.eBody=Go}postConstruct(){const{overlays:e,rangeSvc:t}=this.beans,o=e?.getOverlayWrapperSelector(),{paramsMap:i,elementParams:s}=function(e){const t={};return{paramsMap:t,elementParams:{tag:"div",ref:"eGridRoot",cls:"ag-root ag-unselectable",children:[{tag:"ag-header-root"},{tag:"div",ref:"eTop",cls:"ag-floating-top",role:"presentation",children:od(t,["topLeft","topCenter","topRight","topFullWidth"])},{tag:"div",ref:"eBody",cls:"ag-body",role:"presentation",children:[{tag:"div",ref:"eBodyViewport",cls:"ag-body-viewport",role:"presentation",children:od(t,["left","center","right","fullWidth"])},{tag:"ag-fake-vertical-scroll"}]},{tag:"div",ref:"eStickyTop",cls:"ag-sticky-top",role:"presentation",children:od(t,["stickyTopLeft","stickyTopCenter","stickyTopRight","stickyTopFullWidth"])},{tag:"div",ref:"eStickyBottom",cls:"ag-sticky-bottom",role:"presentation",children:od(t,["stickyBottomLeft","stickyBottomCenter","stickyBottomRight","stickyBottomFullWidth"])},{tag:"div",ref:"eBottom",cls:"ag-floating-bottom",role:"presentation",children:od(t,["bottomLeft","bottomCenter","bottomRight","bottomFullWidth"])},{tag:"ag-fake-horizontal-scroll"},e?{tag:"ag-overlay-wrapper"}:null]}}}(!!o);this.setTemplate(s,[...o?[o]:[],Sa,Ra,Jl,td],i);const n=(e,t)=>{const o=`${e}px`;t.style.minHeight=o,t.style.height=o},r={setRowAnimationCssOnBodyViewport:(e,t)=>this.setRowAnimationCssOnBodyViewport(e,t),setColumnCount:e=>{v(this.getGui(),"colcount",e)},setRowCount:e=>{v(this.getGui(),"rowcount",e)},setTopHeight:e=>n(e,this.eTop),setBottomHeight:e=>n(e,this.eBottom),setTopInvisible:e=>this.eTop.classList.toggle("ag-invisible",e),setBottomInvisible:e=>this.eBottom.classList.toggle("ag-invisible",e),setStickyTopHeight:e=>this.eStickyTop.style.height=e,setStickyTopTop:e=>this.eStickyTop.style.top=e,setStickyTopWidth:e=>this.eStickyTop.style.width=e,setStickyBottomHeight:e=>{this.eStickyBottom.style.height=e,this.eStickyBottom.classList.toggle("ag-invisible","0px"===e)},setStickyBottomBottom:e=>this.eStickyBottom.style.bottom=e,setStickyBottomWidth:e=>this.eStickyBottom.style.width=e,setColumnMovingCss:(e,t)=>this.toggleCss(e,t),updateLayoutClasses:(e,t)=>{const o=[this.eBodyViewport.classList,this.eBody.classList];for(const e of o)e.toggle(Tr.AUTO_HEIGHT,t.autoHeight),e.toggle(Tr.NORMAL,t.normal),e.toggle(Tr.PRINT,t.print);this.toggleCss(Tr.AUTO_HEIGHT,t.autoHeight),this.toggleCss(Tr.NORMAL,t.normal),this.toggleCss(Tr.PRINT,t.print)},setAlwaysVerticalScrollClass:(e,t)=>this.eBodyViewport.classList.toggle(Ca,t),registerBodyViewportResizeListener:e=>{const t=ce(this.beans,this.eBodyViewport,e);this.addDestroyFunc(()=>t())},setPinnedTopBottomOverflowY:e=>this.eTop.style.overflowY=this.eBottom.style.overflowY=e,setCellSelectableCss:(e,t)=>{[this.eTop,this.eBodyViewport,this.eBottom].forEach(o=>o.classList.toggle(e,t))},setBodyViewportWidth:e=>this.eBodyViewport.style.width=e,setGridRootRole:e=>y(this.eGridRoot,e)};this.ctrl=this.createManagedBean(new va),this.ctrl.setComp(r,this.getGui(),this.eBodyViewport,this.eTop,this.eBottom,this.eStickyTop,this.eStickyBottom),(t&&Tt(this.gos)||Bt(this.gos))&&v(this.getGui(),"multiselectable",!0)}setRowAnimationCssOnBodyViewport(e,t){const o=this.eBodyViewport.classList;o.toggle("ag-row-animation",t),o.toggle("ag-row-no-animation",!t)}}},sd=class extends Me{constructor(){super(...arguments),this.additionalFocusableContainers=new Set}setComp(e,t,o){this.view=e,this.eGridHostDiv=t,this.eGui=o,this.eGui.setAttribute("grid-id",this.beans.context.getId());const{dragAndDrop:i,ctrlsSvc:s}=this.beans;i?.registerGridDropTarget(()=>this.eGui,this),this.createManagedBean(new Ir(this.view)),this.view.setRtlClass(this.gos.get("enableRtl")?"ag-rtl":"ag-ltr");const n=ce(this.beans,this.eGridHostDiv,this.onGridSizeChanged.bind(this));this.addDestroyFunc(()=>n()),s.register("gridCtrl",this)}isDetailGrid(){const e=Ss(this.getGui());return e?.getAttribute("row-id")?.startsWith("detail")||!1}getOptionalSelectors(){const 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){const{view:t}=this;if(!1===e)t.setCursor(null);else{const o=1===e?"ew-resize":"ns-resize";t.setCursor(o)}}disableUserSelect(e){this.view.setUserSelect(e?"none":null)}focusNextInnerContainer(e){const t=this.getFocusableContainers(),{indexWithFocus:o,nextIndex:i}=this.getNextFocusableIndex(t,e);if(i<0||i>=t.length)return!1;if(0===i){if(o>0){const{visibleCols:e,focusSvc:t}=this.beans,o=to(e.allCols);if(t.focusGridView({column:o,backwards:!0}))return!0}return!1}return this.focusContainer(t[i],e)}focusInnerElement(e){const t=this.gos.getCallback("focusGridInnerElement");if(t&&t({fromBottom:!!e}))return!0;const o=this.getFocusableContainers(),{focusSvc:i,visibleCols:s}=this.beans,n=s.allCols;if(e){if(o.length>1)return this.focusContainer(to(o),e);const t=to(n);if(i.focusGridView({column:t,backwards:e}))return!0}if(0===this.gos.get("headerHeight")||Pa(this.beans)){if(i.focusGridView({column:n[0],backwards:e}))return!0;for(let t=1;t<o.length;t++)if(bs(o[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){const t=this.view.getFocusableContainers(),{nextIndex:o,indexWithFocus:i}=this.getNextFocusableIndex(t,e);if(-1===i||o<0||o>=t.length)return;const s=t[o];s.setAllowFocus?.(!0),setTimeout(()=>{s.setAllowFocus?.(!1)})}isFocusable(){const e=this.beans;return!Da(e)||!Pa(e)||!!e.sideBar?.comp?.isDisplayed()}getNextFocusableIndex(e,t){const o=u(this.beans),i=e.findIndex(e=>e.getGui().contains(o));return{indexWithFocus:i,nextIndex:i+(t?-1:1)}}focusContainer(e,t){e.setAllowFocus?.(!0);const o=bs(e.getGui(),t,!1,!0);return e.setAllowFocus?.(!1),o}getFocusableContainers(){return[...this.view.getFocusableContainers(),...this.additionalFocusableContainers]}destroy(){this.additionalFocusableContainers.clear(),super.destroy()}},nd=class extends Nl{constructor(e){super(),this.gridBody=Go,this.sideBar=Go,this.pagination=Go,this.rootWrapperBody=Go,this.eGridDiv=e}postConstruct(){const e={destroyGridUi:()=>this.destroyBean(this),setRtlClass:e=>this.addCss(e),forceFocusOutOfContainer:this.forceFocusOutOfContainer.bind(this),updateLayoutClasses:this.updateLayoutClasses.bind(this),getFocusableContainers:this.getFocusableContainers.bind(this),setUserSelect:e=>{this.getGui().style.userSelect=null!=e?e:"",this.getGui().style.webkitUserSelect=null!=e?e:""},setCursor:e=>{this.getGui().style.cursor=null!=e?e:""}},t=this.createManagedBean(new sd),o=t.getOptionalSelectors(),i=this.createTemplate(o),s=[id,...Object.values(o).filter(e=>!!e)];this.setTemplate(i,s),t.setComp(e,this.eGridDiv,this.getGui()),this.insertGridIntoDom(),this.initialiseTabGuard({onTabKeyDown:()=>{},focusInnerElement:e=>t.focusInnerElement(e),forceFocusOutWhenTabGuardsAreEmpty:!0,isEmpty:()=>!t.isFocusable()})}insertGridIntoDom(){const e=this.getGui();this.eGridDiv.appendChild(e),this.addDestroyFunc(()=>{this.eGridDiv.removeChild(e),$e(this.gos,"Grid removed from DOM")})}updateLayoutClasses(e,t){const o=this.rootWrapperBody.classList,{AUTO_HEIGHT:i,NORMAL:s,PRINT:n}=Tr,{autoHeight:r,normal:a,print:l}=t;o.toggle(i,r),o.toggle(s,a),o.toggle(n,l),this.toggleCss(i,r),this.toggleCss(s,a),this.toggleCss(n,l)}createTemplate(e){const t=e.gridHeaderDropZonesSelector?{tag:"ag-grid-header-drop-zones"}:null,o=e.sideBarSelector?{tag:"ag-side-bar",ref:"sideBar"}:null,i=e.statusBarSelector?{tag:"ag-status-bar"}:null,s=e.watermarkSelector?{tag:"ag-watermark"}:null;return{tag:"div",cls:"ag-root-wrapper",role:"presentation",children:[t,{tag:"div",ref:"rootWrapperBody",cls:"ag-root-wrapper-body",role:"presentation",children:[{tag:"ag-grid-body",ref:"gridBody"},o]},i,e.paginationSelector?{tag:"ag-pagination",ref:"pagination"}:null,s]}}getFocusableElement(){return this.rootWrapperBody}forceFocusOutOfContainer(e=!1){e||!this.pagination?.isDisplayed()?super.forceFocusOutOfContainer(e):this.pagination.forceFocusOutOfContainer(e)}getFocusableContainers(){const e=[this.gridBody];return[this.sideBar,this.pagination].forEach(t=>{t&&e.push(t)}),e.filter(e=>Q(e.getGui()))}},rd=(e,t)=>{for(const o of Object.keys(t))t[o]=e;return t},ad={dispatchEvent:"CommunityCore",...rd("CommunityCore",{destroy:0,getGridId:0,getGridOption:0,isDestroyed:0,setGridOption:0,updateGridOptions:0,isModuleRegistered:0}),...rd("GridState",{getState:0,setState:0}),...rd("SharedRowSelection",{setNodesSelected:0,selectAll:0,deselectAll:0,selectAllFiltered:0,deselectAllFiltered:0,selectAllOnCurrentPage:0,deselectAllOnCurrentPage:0,getSelectedNodes:0,getSelectedRows:0}),...rd("RowApi",{redrawRows:0,setRowNodeExpanded:0,getRowNode:0,addRenderedRowListener:0,getRenderedNodes:0,forEachNode:0,getFirstDisplayedRowIndex:0,getLastDisplayedRowIndex:0,getDisplayedRowAtIndex:0,getDisplayedRowCount:0}),...rd("ScrollApi",{getVerticalPixelRange:0,getHorizontalPixelRange:0,ensureColumnVisible:0,ensureIndexVisible:0,ensureNodeVisible:0}),...rd("KeyboardNavigation",{getFocusedCell:0,clearFocusedCell:0,setFocusedCell:0,tabToNextCell:0,tabToPreviousCell:0,setFocusedHeader:0}),...rd("EventApi",{addEventListener:0,addGlobalListener:0,removeEventListener:0,removeGlobalListener:0}),...rd("ValueCache",{expireValueCache:0}),...rd("CellApi",{getCellValue:0}),...rd("SharedMenu",{showColumnMenu:0,hidePopupMenu:0}),...rd("Sort",{onSortChanged:0}),...rd("PinnedRow",{getPinnedTopRowCount:0,getPinnedBottomRowCount:0,getPinnedTopRow:0,getPinnedBottomRow:0,forEachPinnedRow:0}),...rd("Overlay",{showLoadingOverlay:0,showNoRowsOverlay:0,hideOverlay:0}),...rd("RenderApi",{setGridAriaProperty:0,refreshCells:0,refreshHeader:0,isAnimationFrameQueueEmpty:0,flushAllAnimationFrames:0,getSizesForCurrentTheme:0,getCellRendererInstances:0}),...rd("HighlightChanges",{flashCells:0}),...rd("RowDrag",{addRowDropZone:0,removeRowDropZone:0,getRowDropZoneParams:0,getRowDropPositionIndicator:0,setRowDropPositionIndicator:0}),...rd("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}),...rd("ColumnAutoSize",{sizeColumnsToFit:0,autoSizeColumns:0,autoSizeAllColumns:0}),...rd("ColumnGroup",{setColumnGroupOpened:0,getColumnGroup:0,getProvidedColumnGroup:0,getDisplayNameForColumnGroup:0,getColumnGroupState:0,setColumnGroupState:0,resetColumnGroupState:0,getLeftDisplayedColumnGroups:0,getCenterDisplayedColumnGroups:0,getRightDisplayedColumnGroups:0,getAllDisplayedColumnGroups:0}),...rd("ColumnMove",{moveColumnByIndex:0,moveColumns:0}),...rd("ColumnResize",{setColumnWidths:0}),...rd("ColumnHover",{isColumnHovered:0}),...rd("EditCore",{getCellEditorInstances:0,getEditingCells:0,getEditRowValues:0,stopEditing:0,startEditingCell:0,isEditing:0,validateEdit:0}),...rd("BatchEdit",{startBatchEdit:0,cancelBatchEdit:0,commitBatchEdit:0,isBatchEditing:0}),...rd("UndoRedoEdit",{undoCellEditing:0,redoCellEditing:0,getCurrentUndoSize:0,getCurrentRedoSize:0}),...rd("FilterCore",{isAnyFilterPresent:0,onFilterChanged:0}),...rd("ColumnFilter",{isColumnFilterPresent:0,getColumnFilterInstance:0,destroyFilter:0,setFilterModel:0,getFilterModel:0,getColumnFilterModel:0,setColumnFilterModel:0,showColumnFilter:0,hideColumnFilter:0,getColumnFilterHandler:0,doFilterAction:0}),...rd("QuickFilter",{isQuickFilterPresent:0,getQuickFilter:0,resetQuickFilter:0}),...rd("Find",{findGetActiveMatch:0,findGetTotalMatches:0,findGoTo:0,findNext:0,findPrevious:0,findGetNumMatches:0,findGetParts:0,findClearActive:0,findRefresh:0}),...rd("Pagination",{paginationIsLastPageFound:0,paginationGetPageSize:0,paginationGetCurrentPage:0,paginationGetTotalPages:0,paginationGetRowCount:0,paginationGoToNextPage:0,paginationGoToPreviousPage:0,paginationGoToFirstPage:0,paginationGoToLastPage:0,paginationGoToPage:0}),...rd("CsrmSsrmSharedApi",{expandAll:0,collapseAll:0}),...rd("SsrmInfiniteSharedApi",{setRowCount:0,getCacheBlockState:0,isLastRowIndexKnown:0}),...rd("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}),...rd("CsvExport",{getDataAsCsv:0,exportDataAsCsv:0}),...rd("InfiniteRowModel",{refreshInfiniteCache:0,purgeInfiniteCache:0,getInfiniteRowCount:0}),...rd("AdvancedFilter",{getAdvancedFilterModel:0,setAdvancedFilterModel:0,showAdvancedFilterBuilder:0,hideAdvancedFilterBuilder:0}),...rd("IntegratedCharts",{getChartModels:0,getChartRef:0,getChartImageDataURL:0,downloadChart:0,openChartToolPanel:0,closeChartToolPanel:0,createRangeChart:0,createPivotChart:0,createCrossFilterChart:0,updateChart:0,restoreChart:0}),...rd("Clipboard",{copyToClipboard:0,cutToClipboard:0,copySelectedRowsToClipboard:0,copySelectedRangeToClipboard:0,copySelectedRangeDown:0,pasteFromClipboard:0}),...rd("ExcelExport",{getDataAsExcel:0,exportDataAsExcel:0,getSheetDataForExcel:0,getMultipleSheetsAsExcel:0,exportMultipleSheetsAsExcel:0}),...rd("SharedMasterDetail",{addDetailGridInfo:0,removeDetailGridInfo:0,getDetailGridInfo:0,forEachDetailGridInfo:0}),...rd("ContextMenu",{showContextMenu:0}),...rd("ColumnMenu",{showColumnChooser:0,hideColumnChooser:0}),...rd("CellSelection",{getCellRanges:0,addCellRange:0,clearRangeSelection:0,clearCellSelection:0}),...rd("SharedRowGrouping",{setRowGroupColumns:0,removeRowGroupColumns:0,addRowGroupColumns:0,getRowGroupColumns:0,moveRowGroupColumn:0}),...rd("SharedAggregation",{addAggFuncs:0,clearAggFuncs:0,setColumnAggFunc:0}),...rd("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}),...rd("ServerSideRowModelApi",{getServerSideSelectionState:0,setServerSideSelectionState:0,applyServerSideTransaction:0,applyServerSideTransactionAsync:0,applyServerSideRowData:0,retryServerSideLoads:0,flushServerSideAsyncTransactions:0,refreshServerSide:0,getServerSideGroupLevelState:0,onRowHeightChanged:0,resetRowHeights:0}),...rd("SideBar",{isSideBarVisible:0,setSideBarVisible:0,setSideBarPosition:0,openToolPanel:0,closeToolPanel:0,getOpenedToolPanel:0,refreshToolPanel:0,isToolPanelShowing:0,getToolPanelInstance:0,getSideBar:0}),...rd("StatusBar",{getStatusPanel:0})},ld={isDestroyed:()=>!0,destroy(){},preConstruct(){},postConstruct(){},preWireBeans(){},wireBeans(){}},dd=(e,t)=>e.eventSvc.dispatchEvent(t),hd=class{};Reflect.defineProperty(hd,"name",{value:"GridApi"});function cd(e,t){e.gos.updateGridOptions({options:t})}var ud={tag:"div",cls:"ag-drag-handle ag-row-drag",attrs:{draggable:"true"}};var gd={tag:"div",cls:"ag-drag-handle ag-row-drag",attrs:{"aria-hidden":"true"}},pd=class extends Uo{constructor(e,t,o,i,s,n=!1){super(),this.cellValueFn=e,this.rowNode=t,this.column=o,this.customGui=i,this.dragStartPixels=s,this.alwaysVisible=n,this.dragSource=null}isCustomGui(){return null!=this.customGui}postConstruct(){const{beans:e,customGui:t}=this;t?this.setDragElement(t,this.dragStartPixels):(this.setTemplate(gd),this.getGui().appendChild(al("rowDrag",e,null)),this.addDragSource()),this.alwaysVisible||this.initCellDrag()}initCellDrag(){const{beans:e,gos:t,rowNode:o}=this,i=this.refreshVisibility.bind(this);this.addManagedPropertyListener("suppressRowDrag",i),this.addManagedListeners(o,{dataChanged:i,cellChanged:i}),this.addManagedListeners(e.eventSvc,t.get("rowDragManaged")?{sortChanged:i,filterChanged:i,columnRowGroupChanged:i,newColumnsLoaded:i}:{newColumnsLoaded:i})}setDragElement(e,t){this.setTemplateFromElement(e,void 0,void 0,!0),this.addDragSource(t)}refreshVisibility(){if(this.alwaysVisible)return;const e={skipAriaHidden:!0};if(this.isNeverDisplayed())return void this.setDisplayed(!1,e);const t=this.column;let o="function"==typeof t?.getColDef().rowDrag,i=!t||this.isCustomGui()||t.isRowDrag(this.rowNode);i&&this.rowNode.footer&&this.gos.get("rowDragManaged")&&(i=!1,o=!0),this.setDisplayed(o||i,e),this.setVisible(i,e)}isNeverDisplayed(){const{gos:e,beans:t}=this;return!!e.get("suppressRowDrag")||!(!e.get("rowDragManaged")||!t.rowDragSvc.rowDragFeature?.shouldPreventRowMove()||t.dragAndDrop?.hasExternalDropZones())}getSelectedNodes(){const e=this.rowNode;if(!this.gos.get("rowDragMultiRow"))return[e];const t=this.beans.selectionSvc?.getSelectedNodes()??[];return-1!==t.indexOf(e)?t:[e]}getDragItem(){const{column:e,rowNode:t}=this;return{rowNode:t,rowNodes:this.getSelectedNodes(),columns:e?[e]:void 0,defaultTextValue:this.cellValueFn()}}getRowDragText(e){if(e){const t=e.getColDef();if(t.rowDragText)return t.rowDragText}return this.gos.get("rowDragText")}addDragSource(e=4){if(this.dragSource&&this.removeDragSource(),this.gos.get("rowDragManaged")&&this.rowNode.footer)return;const t=this.getGui();this.gos.get("enableCellTextSelection")&&(this.removeMouseDownListener(),this.mouseDownListener=this.addManagedElementListeners(t,{mousedown:e=>{e?.preventDefault()}})[0]);const o=this.getLocaleTextFunc();this.dragSource={type:2,eElement:t,dragItemName:e=>{const t=e?.dragItem||this.getDragItem(),i=(e?.dropTarget?.rows.length??t.rowNodes?.length)||1,s=this.getRowDragText(this.column);return s?s(t,i):1===i?this.cellValueFn():`${i} ${o("rowDragRows","rows")}`},getDragItem:()=>this.getDragItem(),dragStartPixels:e,dragSourceDomDataKey:this.gos.getDomDataKey()},this.beans.dragAndDrop.addDragSource(this.dragSource,!0)}destroy(){this.removeDragSource(),this.removeMouseDownListener(),super.destroy()}removeDragSource(){this.dragSource&&(this.beans.dragAndDrop.removeDragSource(this.dragSource),this.dragSource=null)}removeMouseDownListener(){this.mouseDownListener&&(this.mouseDownListener(),this.mouseDownListener=void 0)}};function md(e){const t=e.rowModel;return"clientSide"===t.getType()?t:void 0}function fd(e){const t=e.rowModel;return"infinite"===t.getType()?t:void 0}function Cd(e,t){const o=e.column===t.column,i=e.rowPinned===t.rowPinned,s=e.rowIndex===t.rowIndex;return o&&i&&s}function vd(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 wd(e,t){const o=e.spannedRowRenderer?.getCellByPosition(t);if(o)return o;const i=e.rowRenderer.getRowByPosition(t);return i?i.getCellCtrl(t.column):null}function bd(e,t,o=!1){const{rowIndex:i,rowPinned:s}=t,{pageBounds:n,pinnedRowModel:r,rowModel:a}=e;if(0===i)return"top"===s?null:"bottom"===s&&a.isRowsToRender()?{rowIndex:n.getLastRow(),rowPinned:null}:r?.isRowsToRender("top")?{rowIndex:r.getPinnedTopRowCount()-1,rowPinned:"top"}:null;if(o){return Sd(e,s?void 0:a.getRow(i),!0)??{rowIndex:i-1,rowPinned:s}}return{rowIndex:i-1,rowPinned:s}}function yd(e,t,o=!1){const{rowIndex:i,rowPinned:s}=t,{pageBounds:n,pinnedRowModel:r,rowModel:a}=e;if(function(e,t){const{rowPinned:o,rowIndex:i}=t,{pinnedRowModel:s,pageBounds:n}=e;if("top"===o){return(s?.getPinnedTopRowCount()??0)-1<=i}if("bottom"===o){return(s?.getPinnedBottomRowCount()??0)-1<=i}const r=n.getLastRow();return r<=i}(e,t))return"bottom"===s?null:"top"===s&&a.isRowsToRender()?{rowIndex:n.getFirstRow(),rowPinned:null}:r?.isRowsToRender("bottom")?{rowIndex:0,rowPinned:"bottom"}:null;if(o){return Sd(e,s?void 0:a.getRow(i))??{rowIndex:i+1,rowPinned:s}}return{rowIndex:i+1,rowPinned:s}}function Sd(e,t,o=!1){const{gos:i,rowRenderer:s}=e;if(!t?.sticky||!bt(i))return;const n=s.getStickyTopRowCtrls(),r=s.getStickyBottomRowCtrls(),a=!r.some(e=>e.rowNode.rowIndex===t.rowIndex),l=a?n:r,d=(o?-1:1)*(a?-1:1);let h;for(let e=0;e<l.length;e++)if(l[e].rowNode.rowIndex===t.rowIndex){h=l[e+d];break}return h?{rowIndex:h.rowNode.rowIndex,rowPinned:null}:void 0}var Ed=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){const{rowNode:o,children:i}=e;if(i)for(let e=0;e<i.length;++e)this.depthFirstSearchChangedPath(i[e],t);t(o)}depthFirstSearchEverything(e,t,o){const i=e.childrenAfterGroup;if(i)for(let e=0,s=i.length;e<s;++e){const s=i[e];s.childrenAfterGroup?this.depthFirstSearchEverything(s,t,o):o&&t(s)}t(e)}forEachChangedNodeDepthFirst(e,t=!1,o=!1){this.active&&!o?this.depthFirstSearchChangedPath(this.pathRoot,e):this.depthFirstSearchEverything(this.pathRoot.rowNode,e,t)}executeFromRootNode(e){e(this.pathRoot.rowNode)}createPathItems(e){let t=e,o=0;for(;!this.mapToItems[t.id];){const e={rowNode:t,children:null};this.mapToItems[t.id]=e,o++,t=t.parent}return o}populateColumnsMap(e,t){if(!this.keepingColumns||!t)return;let o=e;for(;o;)this.nodeIdsToColumns[o.id]||(this.nodeIdsToColumns[o.id]={}),t.forEach(e=>this.nodeIdsToColumns[o.id][e.getId()]=!0),o=o.parent}linkPathItems(e,t){let o=e;for(let e=0;e<t;e++){const e=this.mapToItems[o.id],t=this.mapToItems[o.parent.id];t.children||(t.children=[]),t.children.push(e),o=o.parent}}addParentNode(e,t){if(!e||e.isRowPinned())return;const o=this.createPathItems(e);this.linkPathItems(e,o),this.populateColumnsMap(e,t)}canSkip(e){return this.active&&!this.mapToItems[e.id]}getValueColumnsForNode(e,t){if(!this.keepingColumns)return t;const o=this.nodeIdsToColumns[e.id];return t.filter(e=>o[e.getId()])}getNotValueColumnsForNode(e,t){if(!this.keepingColumns)return null;const o=this.nodeIdsToColumns[e.id];return t.filter(e=>!o[e.getId()])}},Rd=class{constructor(e,t){this.beans=e,this.groupThrottled=!1,this.oldVScroll=null,this.groupTimer=null,this.groupTarget=null,this.onGroupThrottle=()=>{this.groupTimer=null,this.groupThrottled=!0,this.beans.dragAndDrop?.nudge()};const o=()=>t.scrollFeature.getVScrollPosition().top;this.autoScroll=new zl({scrollContainer:t.eBodyViewport,scrollAxis:"y",getVerticalPosition:o,setVerticalPosition:e=>t.scrollFeature.setVerticalScrollPosition(e),onScrollCallback:()=>{const e=o(),t=this.oldVScroll;this.oldVScroll=e,null!==t&&t!==e&&this.beans.dragAndDrop?.nudge()}})}updateGroup(e,t){this.groupTarget&&this.groupTarget!==e&&this.clearGroup(),e&&(t&&this.groupThrottled&&!e.expanded&&e.childrenAfterSort?.length&&e.isExpandable()&&e.setExpanded(!0,void 0,!0),e.expanded&&e.childrenAfterSort?.length&&(this.groupThrottled=!0,this.groupTarget=e))}startGroup(e){this.groupTarget=e,null===this.groupTimer&&(this.groupTimer=window.setTimeout(this.onGroupThrottle,this.beans.gos.get("rowDragInsertDelay")))}clearGroup(){this.groupThrottled=!1,this.groupTarget=null;const e=this.groupTimer;null!==e&&(this.groupTimer=null,window.clearTimeout(e))}clear(){this.clearGroup(),this.autoScroll.ensureCleared(),this.oldVScroll=null}},xd=class extends Me{constructor(e){super(),this.eContainer=e,this.lastDraggingEvent=null,this.nudger=null}postConstruct(){const e=this.beans;this.clientSideRowModel=md(e),e.ctrlsSvc.whenReady(this,t=>{this.nudger=new Rd(e,t.gridBodyCtrl)})}destroy(){super.destroy(),this.nudger?.clear(),this.nudger=null,this.lastDraggingEvent=null,this.eContainer=null}getContainer(){return this.eContainer}isInterestedIn(e){return 2===e}getIconName(e){return!1===e?.dropTarget?.allowed||this.gos.get("rowDragManaged")&&this.shouldPreventRowMove()?"notAllowed":"move"}shouldPreventRowMove(){const{rowGroupColsSvc:e,filterManager:t,sortSvc:o}=this.beans;if((e?.columns??[]).length)return!0;const i=t?.isAnyFilterPresent();if(i)return!0;const s=o?.isSortActive();return!!s}getRowNodes(e){if(!this.isFromThisGrid(e))return e.dragItem.rowNodes||[];const t=e.dragItem.rowNode;if(this.gos.get("rowDragMultiRow")){const e=this.beans.selectionSvc?.getSelectedNodes();if(e&&e.indexOf(t)>=0)return e.slice().sort(Id)}return[t]}onDragEnter(e){this.dragging(e,!0)}onDragging(e){this.dragging(e,!1)}dragging(e,t){const{lastDraggingEvent:o,beans:i}=this;if(t){const t=this.getRowNodes(e);e.dragItem.rowNodes=t,Ad(t,!0)}this.lastDraggingEvent=e;const s=e.fromNudge,n=this.makeRowsDrop(o,e,s,!1);i.rowDropHighlightSvc?.fromDrag(e),t&&this.dispatchGridEvent("rowDragEnter",e),this.dispatchGridEvent("rowDragMove",e),!s&&n?.rowDragManaged&&n.moved&&n.allowed&&n.sameGrid&&!n.suppressMoveWhenRowDragging&&this.dropRows(n),this.nudger?.autoScroll.check(e.event)}isFromThisGrid(e){return e.dragSource.dragSourceDomDataKey===this.gos.getDomDataKey()}makeRowsDrop(e,t,o,i){const{beans:s,gos:n,clientSideRowModel:r}=this,a=this.newRowsDrop(t,i);if(t.dropTarget=a,t.changed=!1,!a)return null;let{sameGrid:l,rootNode:d,source:h,target:c,rows:u}=a;c??(c=r.getRow(r.getRowCount()-1)??null);const g="group"!==Wt(n)&&l;let p=null;if(c?.footer){const e=Fd(r,-1,c)??Fd(r,1,c);p=c.sibling??d,c=e??null}c?.detail&&(c=c.parent),a.moved&&(a.moved=h!==c);let m=.5;if(c&&(m=l&&a.moved&&(p||!g)?h.rowIndex>c.rowIndex?-.5:.5:(a.y-c.rowTop-c.rowHeight/2)/c.rowHeight||0),!g&&l&&c&&a.moved){const e=Ld(r,a);e&&(m=h.rowIndex>e.rowIndex?-.5:.5,c=e,a.moved&&(a.moved=h!==c))}const f=this.nudger;f?.updateGroup(c,o),g&&!p&&f&&(!c||m>=.5&&c.rowIndex===s.pageBounds.getLastRow()?p=d:a.moved&&this.targetShouldBeParent(c,m,u)&&(f.groupThrottled&&(p=c),o||p&&(!c||c.expanded||!c.childrenAfterSort?.length)||f.startGroup(c)),p??(p=c?.parent??d));let C=!1;if(p){if(p===c&&p!==d){const e=p.expanded?Fd(r,1,c):null;e?.parent===p?(c=e,m=-.5):C=!0}if(c&&!C){let e=c;for(;e&&e!==d&&e!==p;)c=e,e=e.parent}}a.target=c,a.newParent=p,a.moved&&(a.moved=h!==c);const v=m<0?"above":"below";return a.position=a.moved?C?"inside":v:"none",this.validateRowsDrop(a,g,v,i),t.changed||(t.changed=Td(e?.dropTarget,a)),a}newRowsDrop(e,t){const{beans:o,gos:i,clientSideRowModel:s}=this,n=s.rootNode,r=i.get("rowDragManaged"),a=i.get("suppressMoveWhenRowDragging"),l=this.isFromThisGrid(e);let{rowNode:d,rowNodes:h}=e.dragItem;if(h||(h=d?[d]:[]),d||(d=h[0]),!d||!n)return null;const c=this.beans.dragAndDrop.isDropZoneWithinThisGrid(e);let u=!0;!r||h.length&&!this.shouldPreventRowMove()&&(!a&&l||c)||(u=!1);const g=wa(o,e).y,p=this.getOverNode(g);return{api:o.gridApi,context:o.gridOptions.context,draggingEvent:e,rowDragManaged:r,suppressMoveWhenRowDragging:a,sameGrid:l,withinGrid:c,rootNode:n,moved:d!==p,y:g,overNode:p,overIndex:p?.rowIndex??-1,position:"none",source:d,target:p??null,newParent:null,rows:h,allowed:u,highlight:!t&&r&&a&&(c||!l)}}validateRowsDrop(e,t,o,i){const{rowDragManaged:s,suppressMoveWhenRowDragging:n}=e;t||(e.newParent=null),n&&!e.moved&&(e.allowed=!1);const r=(!s||e.allowed)&&this.gos.get("isRowValidDropPosition");if(r){t&&e.newParent&&Dd(e.rows,e.newParent)&&(e.newParent=null);const o=r(e);if(o){if("object"==typeof o){void 0!==o.rows&&(e.rows=o.rows??[]),t&&void 0!==o.newParent&&(e.newParent=o.newParent),void 0!==o.target&&(e.target=o.target),o.position&&(e.position=o.position),void 0!==o.allowed?e.allowed=o.allowed:s||(e.allowed=!0);const n=e.draggingEvent;o.changed&&n&&(n.changed=!0),i||void 0===o.highlight||(e.highlight=o.highlight)}}else e.allowed=!1}s&&(e.rows=this.filterRows(e)),t&&e.newParent&&Dd(e.rows,e.newParent)&&(e.newParent=null),!n||e.rows.length&&"none"!==e.position||(e.allowed=!1),e.allowed&&e.newParent||"inside"!==e.position||(e.position=o)}targetShouldBeParent(e,t,o){const i=e.rowIndex;if(t<-.25)return!1;if(t<.25)return!0;let s,n=i+1;const r=this.clientSideRowModel;do{s=r.getRow(n++)}while(s&&s.footer);const a=e.childrenAfterGroup;if(s&&s.parent===e&&a?.length){const e=new Set(o);for(const t of a)if(null!==t.rowIndex&&!e.has(t))return!0}return!1}addRowDropZone(e){if(!e.getContainer())return void st(55);const t=this.beans.dragAndDrop;if(t.findExternalZone(e.getContainer()))return void st(56);const o={isInterestedIn:e=>2===e,getIconName:()=>"move",external:!0,...e.fromGrid?e:{getContainer:e.getContainer,onDragEnter:e.onDragEnter&&(t=>e.onDragEnter(this.rowDragEvent("rowDragEnter",t))),onDragLeave:e.onDragLeave&&(t=>e.onDragLeave(this.rowDragEvent("rowDragLeave",t))),onDragging:e.onDragging&&(t=>e.onDragging(this.rowDragEvent("rowDragMove",t))),onDragStop:e.onDragStop&&(t=>e.onDragStop(this.rowDragEvent("rowDragEnd",t))),onDragCancel:e.onDragCancel&&(t=>e.onDragCancel(this.rowDragEvent("rowDragCancel",t)))}};t.addDropTarget(o),this.addDestroyFunc(()=>t.removeDropTarget(o))}getRowDropZone(e){return{getContainer:this.getContainer.bind(this),onDragEnter:t=>{this.onDragEnter(t),e?.onDragEnter?.(this.rowDragEvent("rowDragEnter",t))},onDragLeave:t=>{this.onDragLeave(t),e?.onDragLeave?.(this.rowDragEvent("rowDragLeave",t))},onDragging:t=>{this.onDragging(t),e?.onDragging?.(this.rowDragEvent("rowDragMove",t))},onDragStop:t=>{this.onDragStop(t),e?.onDragStop?.(this.rowDragEvent("rowDragEnd",t))},onDragCancel:t=>{this.onDragCancel(t),e?.onDragCancel?.(this.rowDragEvent("rowDragCancel",t))},fromGrid:!0}}getOverNode(e){const{pageBounds:t,rowModel:o}=this.beans,i=e>t.getCurrentPagePixelRange().pageLastPixel?-1:o.getRowIndexAtPixel(e);return i>=0?o.getRow(i):void 0}rowDragEvent(e,t){const o=this.beans,{dragItem:i,dropTarget:s,event:n,vDirection:r}=t,a=s?.rootNode===this.clientSideRowModel.rootNode,l=a?s.y:wa(o,t).y,d=a?s.overNode:this.getOverNode(l),h=a?s.overIndex:d?.rowIndex??-1;return{api:o.gridApi,context:o.gridOptions.context,type:e,event:n,node:i.rowNode,nodes:i.rowNodes,overIndex:h,overNode:d,y:l,vDirection:r,rowsDrop:s}}dispatchGridEvent(e,t){const o=this.rowDragEvent(e,t);this.eventSvc.dispatchEvent(o)}onDragLeave(e){this.dispatchGridEvent("rowDragLeave",e),this.stopDragging(e)}onDragStop(e){const t=this.makeRowsDrop(this.lastDraggingEvent,e,!1,!0);this.dispatchGridEvent("rowDragEnd",e),t?.allowed&&t.rowDragManaged&&(t.suppressMoveWhenRowDragging||!t.sameGrid)&&this.dropRows(t),this.stopDragging(e)}onDragCancel(e){this.dispatchGridEvent("rowDragCancel",e),this.stopDragging(e)}stopDragging(e){this.nudger?.clear(),this.beans.rowDropHighlightSvc?.fromDrag(null),Ad(e.dragItem.rowNodes,!1)}dropRows(e){return e.sameGrid?this.moveRows(e):this.addRows(e)}addRows({position:e,target:t,rows:o}){const i=Ft(this.gos),s=this.clientSideRowModel,n=o.filter(({data:e,rowPinned:t})=>!s.getRowNode(i?.({data:e,level:0,rowPinned:t})??e.id)).map(({data:e})=>e);if(0===n.length)return!1;const r=t?Md(t)+("above"===e?0:1):void 0;return s.updateRowData({add:n,addIndex:r}),!0}filterRows({newParent:e,rows:t}){const o=this.clientSideRowModel;let i;for(let s=0,n=t.length;s<n;++s){let n=!0;const r=t[s];!r||r.footer||null===r.rowTop&&r!==o.getRowNode(r.id)||e&&r.parent!==e&&Pd(r,e)?n=!1:kd(r)||(n=!1),n?i?.push(r):i??(i=t.slice(0,s))}return i??t}moveRows({position:e,target:t,rows:o,newParent:i,rootNode:s}){let n=!1;const r=new Set;for(const e of o){i&&e.parent!==i&&(e.treeParent=i,n=!0);const t=kd(e);t&&r.add(t)}if(!n&&0===r.size)return!1;const a=this.beans.focusSvc,l=a.getFocusedCell(),d=l&&wd(this.beans,l);return r.size&&this.reorderLeafChildren(r,...this.getMoveRowsBounds(r,t,"above"===e))&&(n=!0),!!n&&(this.clientSideRowModel.refreshModel({step:"group",keepRenderedRows:!0,animate:!this.gos.get("suppressAnimationFrame"),changedPath:new Ed(!1,s),rowNodesOrderChanged:!0}),d?d.focusCell():a.clearFocusedCell(),!0)}getMoveRowsBounds(e,t,o){const i=this.clientSideRowModel.rootNode?.allLeafChildren.length??0;let s=Md(t);s<0||s>=i?s=i:o||++s;let n=s,r=Math.min(s,i-1);for(const t of e){const e=t.sourceRowIndex;e<n&&(n=e),e>r&&(r=e)}return[n,s,r]}reorderLeafChildren(e,t,o,i){let s=!1;const n=this.clientSideRowModel.rootNode?.allLeafChildren;if(!e.size||!n)return!1;let r=t;for(let i=t;i<o;++i){const t=n[i];e.has(t)||(t.sourceRowIndex!==r&&(t.sourceRowIndex=r,n[r]=t,s=!0),++r)}let a=i;for(let t=i;t>=o;--t){const o=n[t];e.has(o)||(o.sourceRowIndex!==a&&(o.sourceRowIndex=a,n[a]=o,s=!0),--a)}for(const t of e)t.sourceRowIndex!==r&&(t.sourceRowIndex=r,n[r]=t,s=!0),++r;return s}},Fd=(e,t,o)=>{if(o){const i=e.getRowCount();let s=o.rowIndex+t;for(;s>=0&&s<i;){const o=e.getRow(s);if(!o||!o.footer&&!o.detail)return o;s+=t}}},Pd=(e,t)=>{let o=t;for(;o;){if(o===e)return!0;o=o.parent}return!1},Dd=(e,t)=>{for(let o=0,i=e.length;o<i;++o)if(e[o].parent!==t)return!1;return!0},Md=e=>{const t=kd(e);return void 0!==t?t.sourceRowIndex:-1},kd=e=>{for(;e;){if(e.sourceRowIndex>=0)return e;const t=e.childrenAfterGroup;if(!t?.length)return;e=t[0]}},Td=(e,t)=>!(e===t||e&&e.sameGrid===t.sameGrid&&e.allowed===t.allowed&&e.position===t.position&&e.target===t.target&&e.source===t.source&&e.newParent===t.newParent&&oo(e.rows,t.rows)),Id=({rowIndex:e},{rowIndex:t})=>null!==e&&null!==t?e-t:0,Ad=(e,t)=>{for(let o=0,i=e?.length||0;o<i;++o){const i=e[o];i.dragging!==t&&(i.dragging=t,i.dispatchRowEvent("draggingChanged"))}},Ld=(e,t)=>{let o=null,i=t.target;if(i&&t.rows.indexOf(i)<0)return null;const s=t.source;if(!i||!s)return null;let n=i.rowIndex-s.rowIndex;const r=n<0?-1:1;n=t.suppressMoveWhenRowDragging?Math.abs(n):1;const a=new Set(t.rows);do{const t=Fd(e,r,i);if(!t)break;a.has(t)||(o=t,--n),i=t}while(n>0);return o},Bd={moduleName:"Drag",version:qe,beans:[class extends Nn{shouldPreventMouseEvent(e){return this.gos.get("enableCellTextSelection")&&super.shouldPreventMouseEvent(e)}}]},Hd={moduleName:"DragAndDrop",version:qe,dynamicBeans:{dndSourceComp:class extends Uo{constructor(e,t,o){super(ud),this.rowNode=e,this.column=t,this.eCell=o}postConstruct(){this.getGui().appendChild(al("rowDrag",this.beans,null)),this.addGuiEventListener("mousedown",e=>{e.stopPropagation()}),this.addDragSource(),this.checkVisibility()}addDragSource(){this.addGuiEventListener("dragstart",this.onDragStart.bind(this))}onDragStart(e){const{rowNode:t,column:o,eCell:i,gos:s}=this,n=o.getColDef().dndSourceOnRowDrag,r=e.dataTransfer;if(r.setDragImage(i,0,0),n){n(zt(s,{rowNode:t,dragEvent:e}))}else try{const e=JSON.stringify(t.data);r.setData("application/json",e),r.setData("text/plain",e)}catch(e){}}checkVisibility(){const e=this.column.isDndSource(this.rowNode);this.setDisplayed(e)}}},icons:{rowDrag:"grip"}},Vd={moduleName:"SharedDragAndDrop",version:qe,beans:[class extends On{createEvent(e){return zt(this.gos,e)}createDragImageComp(e){const{gos:t,beans:o}=this,i=(s=o.userCompFactory,n=zt(t,{dragSource:e}),s.getCompDetailsFromGridOptions(_o,"agDragAndDropImage",n,!0));var s,n;return i?.newAgStackInstance()}handleEnter(e,t){e?.onGridEnter?.(t)}handleExit(e,t){e?.onGridExit?.(t)}warnNoBody(){st(54)}isDropZoneWithinThisGrid(e){return this.beans.ctrlsSvc.getGridBodyCtrl().eGridBody.contains(e.dropZoneTarget)}registerGridDropTarget(e,t){const o={getContainer:e,isInterestedIn:e=>1===e||0===e,getIconName:()=>"notAllowed"};this.addDropTarget(o),t.addDestroyFunc(()=>this.removeDropTarget(o))}}],dependsOn:[Bd],userComponents:{agDragAndDropImage:class extends Uo{constructor(){super(),this.dragSource=null,this.eIcon=Go,this.eLabel=Go,this.eGhost=Go,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(){const e=e=>function(e,t,o){const i=al(e,t,o);if(i){const{className:e}=i;if("string"==typeof e&&e.indexOf("ag-icon")>-1||"object"==typeof e&&e["ag-icon"])return i}const s=sr({tag:"span"});return s.appendChild(i),s}(e,this.beans,null);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(ll),this.beans.environment.applyThemeClasses(this.eGhost)}destroy(){this.dragSource=null,super.destroy()}setIcon(e,t){const{eGhost:o,eIcon:i,dragSource:s,dropIconMap:n,gos:r}=this;q(i);let a=null;e||(e=s?.getDefaultIconName?s.getDefaultIconName():"notAllowed"),a=n[e],o.classList.toggle("ag-dnd-ghost-not-allowed","notAllowed"===e),i.classList.toggle("ag-shake-left-to-right",t),a===n.hide&&r.get("suppressDragLeaveHidesColumns")||a&&i.appendChild(a)}setLabel(e){this.eLabel.textContent=e}}},icons:{columnMovePin:"pin",columnMoveHide:"eye-slash",columnMoveMove:"arrows",columnMoveLeft:"left",columnMoveRight:"right",columnMoveGroup:"group",columnMoveValue:"aggregation",columnMovePivot:"pivot",dropNotAllowed:"not-allowed",rowDrag:"grip"}},Gd={moduleName:"RowDrag",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="rowDropHighlightSvc",this.uiLevel=0,this.dragging=!1,this.row=null,this.position="none"}postConstruct(){this.addManagedEventListeners({modelUpdated:this.onModelUpdated.bind(this)})}onModelUpdated(){const e=this.row,t=this.dragging;e&&null!==e.rowIndex&&"none"!==this.position?this.set(e,this.position):this.clear(),this.dragging=t}destroy(){this.clear(),super.destroy()}clear(){const e=this.row;this.dragging=!1,e&&(this.uiLevel=0,this.position="none",this.row=null,e.dispatchRowEvent("rowHighlightChanged"))}set(e,t){const o=e!==this.row,i=e.uiLevel,s=t!==this.position,n=i!==this.uiLevel;this.dragging=!1,(o||s||n)&&(o&&this.clear(),this.uiLevel=i,this.position=t,this.row=e,e.dispatchRowEvent("rowHighlightChanged"))}fromDrag(e){const t=e?.dropTarget;if(t){const{highlight:e,target:o,position:i}=t;if(e&&o&&"none"!==i)return this.set(o,i),void(this.dragging=!0)}this.dragging&&this.clear()}},class extends Me{constructor(){super(...arguments),this.beanName="rowDragSvc"}setupRowDrag(e,t){const o=t.createManagedBean(new xd(e)),i=this.beans.dragAndDrop;i.addDropTarget(o),t.addDestroyFunc(()=>i.removeDropTarget(o)),this.rowDragFeature=o}createRowDragComp(e,t,o,i,s,n){return new pd(e,t,o,i,s,n)}createRowDragCompForRow(e,t){if(Tt(this.gos))return;const o=this.getLocaleTextFunc();return this.createRowDragComp(()=>`1 ${o("rowDragRow","row")}`,e,void 0,t,void 0,!0)}createRowDragCompForCell(e,t,o,i,s,n){const r=this.gos;if(r.get("rowDragManaged")&&(!dt(r)||r.get("pagination")))return;return this.createRowDragComp(o,e,t,i,s,n)}}],apiFunctions:{addRowDropZone:function(e,t){e.rowDragSvc?.rowDragFeature?.addRowDropZone(t)},removeRowDropZone:function(e,t){const o=e.dragAndDrop?.findExternalZone(t.getContainer());o&&e.dragAndDrop?.removeDropTarget(o)},getRowDropZoneParams:function(e,t){return e.rowDragSvc?.rowDragFeature?.getRowDropZone(t)},getRowDropPositionIndicator:function(e){const t=e.rowDropHighlightSvc;return t?{row:t.row,dropIndicatorPosition:t.position}:{row:null,dropIndicatorPosition:"none"}},setRowDropPositionIndicator:function(e,t){const o=e.rowDropHighlightSvc;if(!o)return;const i=t?.row;let s=t?.dropIndicatorPosition;"above"!==s&&"below"!==s&&"inside"!==s&&(s="none");const n=i?.rowIndex;null==n||"none"===s?o.clear():o.set(i,s)}},dependsOn:[Vd]},Nd={moduleName:"HorizontalResize",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="horizontalResizeSvc"}addResizeBar(e){const 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:o}=this.beans;o.addDragSource(t);return()=>o.removeDragSource(t)}onDragStart(e,t){this.dragStartX=t.clientX,this.setResizeIcons();const o=t instanceof MouseEvent&&!0===t.shiftKey;e.onResizeStart(o)}setResizeIcons(){const e=this.beans.ctrlsSvc.get("gridCtrl");e.setResizeCursor(1),e.disableUserSelect(!0)}onDragStop(e){e.onResizeEnd(this.resizeAmount),this.resetIcons()}resetIcons(){const 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)}}],dependsOn:[Bd]};var Od=class extends Me{constructor(e){super(),this.pinned=e,this.columnsToAggregate=[],this.columnsToGroup=[],this.columnsToPivot=[]}onDragEnter(e){if(this.clearColumnsList(),this.gos.get("functionsReadOnly"))return;const t=e.dragItem.columns;t&&t.forEach(e=>{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){const{valueColsSvc:t,rowGroupColsSvc:o,pivotColsSvc:i}=this.beans;this.columnsToAggregate.length>0&&t?.addColumns(this.columnsToAggregate,"toolPanelDragAndDrop"),this.columnsToGroup.length>0&&o?.addColumns(this.columnsToGroup,"toolPanelDragAndDrop"),this.columnsToPivot.length>0&&i?.addColumns(this.columnsToPivot,"toolPanelDragAndDrop")}onDragCancel(){this.clearColumnsList()}};function zd(e){const{isFromHeader:t,fromLeft:o,xPosition:i,fromEnter:s,fakeEvent:n,pinned:r,gos:a,colModel:l,colMoves:d,visibleCols:h}=e;let{allMovingColumns:c}=e;t&&(c=function(e){const t=[...e];return e.forEach(e=>{let o=null,i=e.getParent();for(;null!=i&&1===i.getDisplayedLeafColumns().length;)o=i,i=i.getParent();null!=o&&(o.getColGroupDef()?.marryChildren?o.getProvidedColumnGroup().getLeafColumns():o.getLeafColumns()).forEach(e=>{t.includes(e)||t.push(e)})}),t}(c));const u=c.slice();!function(e,t){if(!t||t.length<=1)return;t.filter(t=>e.indexOf(t)<0).length>0||t.sort((t,o)=>e.indexOf(t)-e.indexOf(o))}(l.getCols(),u);const g=function(e){const{movingCols:t,draggingRight:o,xPosition:i,pinned:s,gos:n,colModel:r,visibleCols:a}=e,l=n.get("suppressMovableColumns")||t.some(e=>e.getColDef().suppressMovable);if(l)return[];const d=function(e,t){switch(t){case"left":return e.leftCols;case"right":return e.rightCols;default:return e.centerCols}}(a,s),h=r.getCols(),c=d.filter(e=>t.includes(e)),u=d.filter(e=>!t.includes(e)),g=h.filter(e=>!t.includes(e));let p,m=0,f=i;if(o){let e=0;c.forEach(t=>e+=t.getActualWidth()),f-=e}if(f>0){for(let e=0;e<u.length;e++){if(f-=u[e].getActualWidth(),f<0)break;m++}o&&m++}if(m>0){const e=u[m-1];p=g.indexOf(e)+1}else p=g.indexOf(u[0]),-1===p&&(p=0);const C=[p],v=(e,t)=>e-t;if(o){let e=p+1;const t=h.length-1;for(;e<=t;)C.push(e),e++;C.sort(v)}else{let e=p;const t=h.length-1;let o=h[e];for(;e<=t&&d.indexOf(o)<0;)e++,C.push(e),o=h[e];e=p-1;const i=0;for(;e>=i;)C.push(e),e--;C.sort(v).reverse()}return C}({movingCols:u,draggingRight:o,xPosition:i,pinned:r,gos:a,colModel:l,visibleCols:h}),p=function(e,t){const o=t.getCols(),i=e.map(e=>o.indexOf(e)).sort((e,t)=>e-t),s=i[0],n=to(i);return n-s!==i.length-1?null:s}(u,l);if(0===g.length)return;const m=g[0];if(null!==p&&(t||!s)&&!n){if(!o&&m>=p)return;if(o&&m<=p)return}const f=function(e,t,o,i){const s=i.allCols;let n=null,r=null;for(let i=0;i<e.length;i++){const a=e[i],l=o.getProposedColumnOrder(t,a);if(!o.doesOrderPassRules(l))continue;const d=l.filter(e=>s.includes(e));if(null===r)r=d;else if(!oo(d,r))break;const h=Ud(l);(null===n||h<n.fragCount)&&(n={move:a,fragCount:h})}return n}(g,u,d,h);if(!f)return;const C=f.move;return C>l.getCols().length-u.length?void 0:{columns:u,toIndex:C}}function Wd(e){const{columns:t,toIndex:o}=zd(e)||{},{finished:i,colMoves:s}=e;return t&&null!=o?(s.moveColumns(t,o,"uiColumnMoved",i),i?null:{columns:t,toIndex:o}):null}function Ud(e){function t(e){const t=[];let o=e.getOriginalParent();for(;null!=o;)t.push(o),o=o.getOriginalParent();return t}let o=0;for(let i=0;i<e.length-1;i++){let s=t(e[i]),n=t(e[i+1]);[s,n]=s.length>n.length?[s,n]:[n,s],s.forEach(e=>{-1===n.indexOf(e)&&o++})}return o}function $d(e){const{pinned:t,fromKeyboard:o,gos:i,ctrlsSvc:s,useHeaderRow:n,skipScrollPadding:r}=e;let a=s.getHeaderRowContainerCtrl(t)?.eViewport,{x:l}=e;return a?(o&&(l-=a.getBoundingClientRect().left),i.get("enableRtl")&&(n&&(a=a.querySelector(".ag-header-row")),l=a.clientWidth-l),null!=t||r||(l+=s.get("center").getCenterViewportScrollLeft()),l):0}function Kd(e,t){for(const o of e)o.moving=t,o.dispatchColEvent("movingChanged","uiColumnMoved")}var jd=class extends Me{constructor(e){super(),this.pinned=e,this.needToMoveLeft=!1,this.needToMoveRight=!1,this.lastMovedInfo=null,this.isCenterContainer=!o(e)}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl})}getIconName(){const{pinned:e,lastDraggingEvent:t}=this,{dragItem:o}=t||{},i=o?.columns??[];for(const t of i){const i=t.getPinned();if(t.getColDef().lockPinned){if(i==e)return"move";continue}const s=o?.containerType;if(s===e||!e)return"move";if(e&&(!i||s!==e))return"pinned"}return"notAllowed"}onDragEnter(e){const t=e.dragItem,o=t.columns;if(0===e.dragSource.type)this.setColumnsVisible(o,!0,"uiColumnDragged");else{const e=t.visibleState,i=(o||[]).filter(t=>e[t.getId()]&&!t.isVisible());this.setColumnsVisible(i,!0,"uiColumnDragged")}this.gos.get("suppressMoveWhenColumnDragging")||this.attemptToPinColumns(o,this.pinned),this.onDragging(e,!0,!0)}onDragging(e=this.lastDraggingEvent,t=!1,o=!1,s=!1){const{gos:n,ctrlsSvc:r}=this.beans,a=n.get("suppressMoveWhenColumnDragging");if(s&&!a)return void this.finishColumnMoving();if(this.lastDraggingEvent=e,!e||!s&&i(e.hDirection))return;const l=$d({x:e.x,pinned:this.pinned,gos:n,ctrlsSvc:r});t||this.checkCenterForScrolling(l),a?this.handleColumnDragWhileSuppressingMovement(e,t,o,l,s):this.handleColumnDragWhileAllowingMovement(e,t,o,l,s)}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,o){if(!e?.length)return;const i=e.filter(e=>!e.getColDef().lockVisible);i.length&&this.beans.colModel.setColsVisible(i,t,o)}finishColumnMoving(){this.clearHighlighted();const e=this.lastMovedInfo;if(!e)return;const{columns:t,toIndex:o}=e;this.beans.colMoves.moveColumns(t,o,"uiColumnMoved",!0)}updateDragItemContainerType(){const{lastDraggingEvent:e}=this;if(this.gos.get("suppressMoveWhenColumnDragging")||!e)return;const t=e.dragItem;t&&(t.containerType=this.pinned)}handleColumnDragWhileSuppressingMovement(e,t,o,i,s){const n=this.getAllMovingColumns(e,!0);if(s){const e=this.isAttemptingToPin(n);e&&this.attemptToPinColumns(n,void 0,!0);const{fromLeft:i,xPosition:s}=this.getNormalisedXPositionInfo(n,e)||{};if(null==i||null==s)return void this.finishColumnMoving();this.moveColumnsAfterHighlight({allMovingColumns:n,xPosition:s,fromEnter:t,fakeEvent:o,fromLeft:i})}else{if(!this.beans.dragAndDrop.isDropZoneWithinThisGrid(e))return;this.highlightHoveredColumn(n,i)}}handleColumnDragWhileAllowingMovement(e,t,o,i,s){const n=this.getAllMovingColumns(e),r="right"===this.normaliseDirection(e.hDirection),a=1===e.dragSource.type,l=Wd({...this.getMoveColumnParams({allMovingColumns:n,isFromHeader:a,xPosition:i,fromLeft:r,fromEnter:t,fakeEvent:o}),finished:s});l&&(this.lastMovedInfo=l)}getAllMovingColumns(e,t=!1){const o=e.dragSource.getDragItem();let i=null;t?(i=o.columnsInSplit,i||(i=o.columns)):i=o.columns;return i?i.filter(e=>!e.getColDef().lockPinned||e.getPinned()==this.pinned):[]}getMoveColumnParams(e){const{allMovingColumns:t,isFromHeader:o,xPosition:i,fromLeft:s,fromEnter:n,fakeEvent:r}=e,{gos:a,colModel:l,colMoves:d,visibleCols:h}=this.beans;return{allMovingColumns:t,isFromHeader:o,fromLeft:s,xPosition:i,pinned:this.pinned,fromEnter:n,fakeEvent:r,gos:a,colModel:l,colMoves:d,visibleCols:h}}highlightHoveredColumn(e,t){const{gos:o,colModel:i}=this.beans,s=o.get("enableRtl"),n=i.getCols().filter(e=>e.isVisible()&&e.getPinned()===this.pinned);let r,a=null,l=null,d=null;for(const e of n){if(l=e.getActualWidth(),a=this.getNormalisedColumnLeft(e,0,s),null!=a){if(a<=t&&a+l>=t){d=e;break}}a=null,l=null}if(d)-1!==e.indexOf(d)&&(d=null);else{for(let e=n.length-1;e>=0;e--){const t=n[e],o=n[e].getParent();if(!o){d=t;break}const i=o?.getDisplayedLeafColumns();if(i.length){d=to(i);break}}if(!d)return;a=this.getNormalisedColumnLeft(d,0,s),l=d.getActualWidth()}this.lastHighlightedColumn?.column!==d&&this.clearHighlighted(),null!=d&&null!=a&&null!=l&&(r=t-a<l/2!==s?0:1,qd(d,r),this.lastHighlightedColumn={column:d,position:r})}getNormalisedXPositionInfo(e,t){const{gos:o,visibleCols:i}=this.beans,s=o.get("enableRtl"),{firstMovingCol:n,column:r,position:a}=this.getColumnMoveAndTargetInfo(e,t,s);if(!n||!r||null==a)return;const l=i.allCols,d=l.indexOf(n),h=l.indexOf(r),c=0===a!==s,u=d<h||d===h&&!c;let g=0;if(c?u&&(g-=1):u||(g+=1),h+g===d)return;const p=l[h+g];if(!p)return;return{fromLeft:u,xPosition:this.getNormalisedColumnLeft(p,20,s)}}getColumnMoveAndTargetInfo(e,t,o){const i=this.lastHighlightedColumn||{},{firstMovingCol:s,lastMovingCol:n}=function(e){const t=e.length;let o,i;for(let s=0;s<t;s++){if(!o){const t=e[s];null!=t.getLeft()&&(o=t)}if(!i){const o=e[t-1-s];null!=o.getLeft()&&(i=o)}if(o&&i)break}return{firstMovingCol:o,lastMovingCol:i}}(e);if(!s||!n||i.column||!t)return{firstMovingCol:s,...i};const r="left"===this.getPinDirection();return{firstMovingCol:s,position:r?1:0,column:r!==o?s:n}}normaliseDirection(e){if(this.gos.get("enableRtl"))switch(e){case"left":return"right";case"right":return"left"}return e}getNormalisedColumnLeft(e,t,o){const{gos:i,ctrlsSvc:s}=this.beans,n=e.getLeft();if(null==n)return null;const r=e.getActualWidth();return $d({x:o?n+r-t:n+t,pinned:e.getPinned(),useHeaderRow:o,skipScrollPadding:!0,gos:i,ctrlsSvc:s})}isAttemptingToPin(e){const t=this.needToMoveLeft||this.needToMoveRight,o=this.failedMoveAttempts>7;return t&&o||e.some(e=>e.getPinned()!==this.pinned)}moveColumnsAfterHighlight(e){const{allMovingColumns:t,xPosition:o,fromEnter:i,fakeEvent:s,fromLeft:n}=e,r=this.getMoveColumnParams({allMovingColumns:t,isFromHeader:!0,xPosition:o,fromLeft:n,fromEnter:i,fakeEvent:s}),{columns:a,toIndex:l}=zd(r)||{};a&&null!=l&&(this.lastMovedInfo={columns:a,toIndex:l}),this.finishColumnMoving()}clearHighlighted(){const{lastHighlightedColumn:e}=this;e&&(qd(e.column,null),this.lastHighlightedColumn=null)}checkCenterForScrolling(e){if(!this.isCenterContainer)return;const t=this.beans.ctrlsSvc.get("center"),o=t.getCenterViewportScrollLeft(),i=o+t.getCenterWidth();let s,n;this.gos.get("enableRtl")?(s=e<o+50,n=e>i-50):(n=e<o+50,s=e>i-50),this.needToMoveRight=s,this.needToMoveLeft=n,n||s?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,e>100&&(e=100);let t=null;const o=this.gridBodyCon.scrollFeature;if(this.needToMoveLeft?t=o.scrollHorizontally(-e):this.needToMoveRight&&(t=o.scrollHorizontally(e)),0!==t)this.onDragging(this.lastDraggingEvent),this.failedMoveAttempts=0;else{this.failedMoveAttempts++;const{pinnedCols:e,dragAndDrop:t,gos:o}=this.beans;if(this.failedMoveAttempts<=8||!e)return;if(t.setDragImageCompIcon("pinned"),!o.get("suppressMoveWhenColumnDragging")){const 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,o=!1){const i=(e||[]).filter(e=>!e.getColDef().lockPinned);if(!i.length)return 0;o&&(t=this.getPinDirection());const{pinnedCols:s,dragAndDrop:n}=this.beans;return s?.setColsPinned(i,t,"uiColumnDragged"),o&&n.nudge(),i.length}destroy(){super.destroy(),this.lastDraggingEvent=null,this.clearHighlighted(),this.lastMovedInfo=null}};function qd(e,t){e.highlighted!==t&&(e.highlighted=t,e.dispatchColEvent("headerHighlightChanged","uiColumnMoved"))}var _d=class extends Me{constructor(e,t){super(),this.pinned=e,this.eContainer=t}postConstruct(){const{ctrlsSvc:e,dragAndDrop:t}=this.beans,o=this.pinned;e.whenReady(this,e=>{let t;const i=e.gridBodyCtrl.eBodyViewport;switch(o){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 jd(o)),this.bodyDropPivotTarget=this.createManagedBean(new Od(o)),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()}};var Yd={moduleName:"ColumnMove",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="colMoves"}moveColumnByIndex(e,t,o){const i=this.beans.colModel.getCols();if(!i)return;const s=i[e];this.moveColumns([s],t,o)}moveColumns(e,t,o,i=!0){const{colModel:s,colAnimation:n,visibleCols:r,eventSvc:a}=this.beans,l=s.getCols();if(!l)return;if(t>l.length-e.length)return void st(30,{toIndex:t});n?.start();const d=s.getColsForKeys(e);this.doesMovePassRules(d,t)&&(no(s.getCols(),d,t),r.refresh(o),a.dispatchEvent({type:"columnMoved",columns:d,column:1===d.length?d[0]:null,toIndex:t,finished:i,source:o})),n?.finish()}doesMovePassRules(e,t){const o=this.getProposedColumnOrder(e,t);return this.doesOrderPassRules(o)}doesOrderPassRules(e){const{colModel:t,gos:o}=this.beans;if(!Po(e,t.getColTree()))return!1;return!!(e=>{const t=o.get("enableRtl");let i=t?1:-1,s=!0;return e.forEach(e=>{const o=(n=e.getColDef().lockPosition)?"left"===n||!0===n?-1:1:0;var n;t?o>i&&(s=!1):o<i&&(s=!1),i=o}),s})(e)}getProposedColumnOrder(e,t){const o=this.beans.colModel.getCols().slice();return no(o,e,t),o}createBodyDropTarget(e,t){return new _d(e,t)}moveHeader(e,t,o,i,s){const{ctrlsSvc:n,gos:r,colModel:a,visibleCols:l,focusSvc:d}=this.beans,h=t.getBoundingClientRect(),c=h.left,u=Wn(o),g=u?h.width:o.getActualWidth(),p="left"===e!==r.get("enableRtl"),m=$d({x:p?c-20:c+g+20,pinned:i,fromKeyboard:!0,gos:r,ctrlsSvc:n}),f=d.focusedHeader;let C;if(Wd({allMovingColumns:u?o.getLeafColumns():[o],isFromHeader:!0,fromLeft:"right"===e,xPosition:m,pinned:i,fromEnter:!1,fakeEvent:!1,gos:r,colModel:a,colMoves:this,visibleCols:l,finished:!0}),u){const e=o.getDisplayedLeafColumns();C=p?e[0]:to(e)}else C=o;if(n.getScrollFeature().ensureColumnVisible(C,"auto"),(!s.isAlive()||r.get("ensureDomOrder"))&&f){let e;if(u){const t=o.getGroupId(),i=o.getLeafColumns();if(!i.length)return;const s=i[0].getParent();if(!s)return;e=function(e,t){for(;e;){if(e.getGroupId()===t)return e;e=e.getParent()}return}(s,t)}else e=o;e&&d.focusHeaderPosition({headerPosition:{...f,column:e}})}}setDragSourceForHeader(e,t,o){const{gos:i,colModel:s,dragAndDrop:n,visibleCols:r}=this.beans;let a=!i.get("suppressDragLeaveHidesColumns");const l=Wn(t),d=l?t.getProvidedColumnGroup().getLeafColumns():[t],h=l?()=>function(e,t){const o=e.getProvidedColumnGroup().getLeafColumns(),i={};o.forEach(e=>i[e.getId()]=e.isVisible());const s=[];t.forEach(e=>{o.indexOf(e)>=0&&(s.push(e),so(o,e))}),o.forEach(e=>s.push(e));const n=[],r=e.getLeafColumns();for(const e of s)-1!==r.indexOf(e)&&n.push(e);return{columns:s,columnsInSplit:n,visibleState:i,containerType:n[0]?.pinned}}(t,r.allCols):()=>function(e){const t={};return t[e.getId()]=e.isVisible(),{columns:[e],visibleState:t,containerType:e.pinned}}(t),c={type:1,eElement:e,getDefaultIconName:()=>a?"hide":"notAllowed",getDragItem:h,dragItemName:o,onDragStarted:()=>{a=!i.get("suppressDragLeaveHidesColumns"),Kd(d,!0)},onDragStopped:()=>Kd(d,!1),onDragCancelled:()=>Kd(d,!1),onGridEnter:e=>{if(a){const{columns:t=[],visibleState:o}=e??{},i=l?e=>!o||o[e.getColId()]:()=>!0,n=t.filter(e=>!e.getColDef().lockVisible&&i(e));s.setColsVisible(n,!0,"uiColumnMoved")}},onGridExit:e=>{if(a){const t=e?.columns?.filter(e=>!e.getColDef().lockVisible)||[];s.setColsVisible(t,!1,"uiColumnMoved")}}};return n.addDragSource(c,!0),c}},class extends Me{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;const{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++;const e=this.animationThreadCount,{gridBodyCtrl:t}=this;t.setColumnMovingCss(!0),this.executeLaterFuncs.push(()=>{this.animationThreadCount===e&&t.setColumnMovingCss(!1)})}flush(e,t){const{executeNextFuncs:o,executeLaterFuncs:i}=this;if(0===o.length&&0===i.length)return e(),void t();const s=e=>{for(;e.length;){const t=e.pop();t&&t()}};this.beans.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(()=>{e(),s(o)},0),window.setTimeout(()=>{t(),s(i)},200)})}}],apiFunctions:{moveColumnByIndex:function(e,t,o){e.colMoves?.moveColumnByIndex(t,o,"api")},moveColumns:function(e,t,o){e.colMoves?.moveColumns(t,o,"api")}},dependsOn:[Vd],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}}"]},Qd={moduleName:"AutoWidth",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="autoWidthCalc"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.centerRowContainerCtrl=e.center})}getPreferredWidthForColumn(e,t){const o=this.getHeaderCellForColumn(e);if(!o)return-1;const i=this.beans.rowRenderer.getAllCellsNotSpanningForColumn(e);return t||i.push(o),this.getPreferredWidthForElements(i)}getPreferredWidthForColumnGroup(e){const t=this.getHeaderCellForColumn(e);return t?this.getPreferredWidthForElements([t]):-1}getPreferredWidthForElements(e,t){const o=document.createElement("form");o.style.position="fixed";const i=this.centerRowContainerCtrl.eContainer;e.forEach(e=>this.cloneItemIntoDummy(e,o)),i.appendChild(o);const s=o.offsetWidth;return i.removeChild(o),s+(t=t??this.gos.get("autoSizePadding"))}getHeaderCellForColumn(e){let t=null;return this.beans.ctrlsSvc.getHeaderRowContainerCtrls().forEach(o=>{const i=o.getHtmlElementForColumnHeader(e);null!=i&&(t=i)}),t}cloneItemIntoDummy(e,t){const o=e.cloneNode(!0);o.style.width="",o.style.position="static",o.style.left="";const i=document.createElement("div"),s=i.classList;["ag-header-cell","ag-header-group-cell"].some(e=>o.classList.contains(e))?(s.add("ag-header","ag-header-row"),i.style.position="static"):s.add("ag-row");let n=e.parentElement;for(;n;){if(["ag-header-row","ag-row"].some(e=>n.classList.contains(e))){for(let e=0;e<n.classList.length;e++){const t=n.classList[e];"ag-row-position-absolute"!=t&&s.add(t)}break}n=n.parentElement}i.appendChild(o),t.appendChild(i)}}]};var Zd=class extends Me{constructor(e,t,o,i){super(),this.comp=e,this.eResize=t,this.pinned=o,this.columnGroup=i}postConstruct(){if(!this.columnGroup.isResizable())return void this.comp.setResizableDisplayed(!1);const{horizontalResizeSvc:e,gos:t,colAutosize:o}=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")&&o&&this.addDestroyFunc(o.addColumnGroupResize(this.eResize,this.columnGroup,()=>this.resizeLeafColumnsToFit("uiColumnResized")))}onResizeStart(e){const{columnsToResize:t,resizeStartWidth:o,resizeRatios:i,groupAfterColumns:s,groupAfterStartWidth:n,groupAfterRatios:r}=this.getInitialValues(e);this.resizeCols=t,this.resizeStartWidth=o,this.resizeRatios=i,this.resizeTakeFromCols=s,this.resizeTakeFromStartWidth=n,this.resizeTakeFromRatios=r,this.toggleColumnResizing(!0)}onResizing(e,t,o="uiColumnResized"){const i=this.normaliseDragChange(t),s=this.resizeStartWidth+i;this.resizeColumnsFromLocalValues(s,o,e)}getInitialValues(e){const t=e=>e.reduce((e,t)=>e+t.getActualWidth(),0),o=(e,t)=>e.map(e=>e.getActualWidth()/t),i=this.getColumnsToResize(),s=t(i),n={columnsToResize:i,resizeStartWidth:s,resizeRatios:o(i,s)};let r=null;if(e&&(r=this.beans.colGroupSvc?.getGroupAtDirection(this.columnGroup,"After")??null),r){const e=r.getDisplayedLeafColumns(),i=n.groupAfterColumns=e.filter(e=>e.isResizable()),s=n.groupAfterStartWidth=t(i);n.groupAfterRatios=o(i,s)}else n.groupAfterColumns=void 0,n.groupAfterStartWidth=void 0,n.groupAfterRatios=void 0;return n}resizeLeafColumnsToFit(e){const t=this.beans.autoWidthCalc.getPreferredWidthForColumnGroup(this.columnGroup),o=this.getInitialValues();t>o.resizeStartWidth&&this.resizeColumns(o,t,e,!0)}resizeColumnsFromLocalValues(e,t,o=!0){if(!this.resizeCols||!this.resizeRatios)return;const i={columnsToResize:this.resizeCols,resizeStartWidth:this.resizeStartWidth,resizeRatios:this.resizeRatios,groupAfterColumns:this.resizeTakeFromCols,groupAfterStartWidth:this.resizeTakeFromStartWidth,groupAfterRatios:this.resizeTakeFromRatios};this.resizeColumns(i,e,t,o)}resizeColumns(e,t,o,i=!0){const{columnsToResize:s,resizeStartWidth:n,resizeRatios:r,groupAfterColumns:a,groupAfterStartWidth:l,groupAfterRatios:d}=e,h=[];if(h.push({columns:s,ratios:r,width:t}),a){const e=t-n;h.push({columns:a,ratios:d,width:l-e})}this.beans.colResize?.resizeColumnSets({resizeSets:h,finished:i,source:o}),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}},Jd=class extends Me{constructor(e,t,o,i,s){super(),this.pinned=e,this.column=t,this.eResize=o,this.comp=i,this.ctrl=s}postConstruct(){const e=[];let t,o;const i=()=>{if(H(this.eResize,t),!t)return;const{horizontalResizeSvc:i,colAutosize:s}=this.beans,n=i.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});e.push(n),o&&s&&e.push(s.addColumnAutosize(this.eResize,this.column))},s=()=>{e.forEach(e=>e()),e.length=0},n=()=>{const e=this.column.isResizable(),n=!this.gos.get("suppressAutoSize")&&!this.column.getColDef().suppressAutoSize;(e!==t||n!==o)&&(t=e,o=n,s(),i())};n(),this.addDestroyFunc(s),this.ctrl.setRefreshFunction("resize",n)}onResizing(e,t){const{column:o,lastResizeAmount:i,resizeStartWidth:s,beans:n}=this,r=this.normaliseResizeAmount(t),a=[{key:o,newWidth:s+r}],{pinnedCols:l,ctrlsSvc:d,colResize:h}=n;if(this.column.getPinned()){if((l?.leftWidth??0)+(l?.rightWidth??0)+(r-i)>z(d.getGridBodyCtrl().eBodyViewport)-50)return}this.lastResizeAmount=r,h?.setColumnWidths(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;const o="left"!==this.pinned,i="right"===this.pinned;return this.gos.get("enableRtl")?o&&(t*=-1):i&&(t*=-1),t}};var Xd={moduleName:"ColumnResize",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="colResize"}setColumnWidths(e,t,o,i){const s=[],{colModel:n,gos:r,visibleCols:a}=this.beans;e.forEach(e=>{const o=n.getColDefCol(e.key)||n.getCol(e.key);if(!o)return;s.push({width:e.newWidth,ratios:[1],columns:[o]});if("shift"===r.get("colResizeDefault")&&(t=!t),t){const t=a.getColAfter(o);if(!t)return;const i=o.getActualWidth()-e.newWidth,n=t.getActualWidth()+i;s.push({width:n,ratios:[1],columns:[t]})}}),0!==s.length&&this.resizeColumnSets({resizeSets:s,finished:o,source:i})}resizeColumnSets(e){const{resizeSets:t,finished:o,source:i}=e;if(!(!t||t.every(e=>function(e){const{columns:t,width:o}=e;let i=0,s=0,n=!0;t.forEach(e=>{const t=e.getMinWidth();i+=t||0;const o=e.getMaxWidth();o>0?s+=o:n=!1});const r=!n||o<=s;return o>=i&&r}(e)))){if(o){const e=t&&t.length>0?t[0].columns:null;ko(this.eventSvc,e,o,i)}return}const s=[],n=[];t.forEach(e=>{const{width:t,columns:o,ratios:r}=e,a={},l={};o.forEach(e=>n.push(e));let d=!0,h=0;for(;d;){if(h++,h>1e3){nt(31);break}d=!1;const e=[];let i=0,s=t;o.forEach((t,o)=>{if(l[t.getId()])s-=a[t.getId()];else{e.push(t);const s=r[o];i+=s}});const n=1/i;e.forEach((o,i)=>{let h;i===e.length-1?h=s:(h=Math.round(r[i]*t*n),s-=h);const c=o.getMinWidth(),u=o.getMaxWidth();h<c?(h=c,l[o.getId()]=!0,d=!0):u>0&&h>u&&(h=u,l[o.getId()]=!0,d=!0),a[o.getId()]=h})}o.forEach(e=>{const t=a[e.getId()];e.getActualWidth()!==t&&(e.setActualWidth(t,i),s.push(e))})});const r=s.length>0;let a=[];if(r){const{colFlex:e,visibleCols:t,colViewport:o}=this.beans;a=e?.refreshFlexedColumns({resizingCols:n,skipSetLeft:!0})??[],t.setLeftValues(i),t.updateBodyWidths(),o.checkViewportColumns()}const l=n.concat(a);(r||o)&&ko(this.eventSvc,l,o,i,a)}resizeHeader(e,t,o){if(!e.isResizable())return;const i=e.getActualWidth(),s=e.getMinWidth(),n=e.getMaxWidth(),r=Math.min(Math.max(i+t,s),n);this.setColumnWidths([{key:e,newWidth:r}],o,!0,"uiColumnResized")}createResizeFeature(e,t,o,i,s){return new Jd(e,t,o,i,s)}createGroupResizeFeature(e,t,o,i){return new Zd(e,t,o,i)}}],apiFunctions:{setColumnWidths:function(e,t,o=!0,i="api"){e.colResize?.setColumnWidths(t,!1,o,i)}},dependsOn:[Nd,Qd]},eh=class extends Me{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();const e=this.onWidthChanged.bind(this);this.columnGroup.getLeafColumns().forEach(t=>{t.__addEventListener("widthChanged",e),t.__addEventListener("visibleChanged",e),this.removeChildListenersFuncs.push(()=>{t.__removeEventListener("widthChanged",e),t.__removeEventListener("visibleChanged",e)})})}removeListenersOnChildrenColumns(){this.removeChildListenersFuncs.forEach(e=>e()),this.removeChildListenersFuncs=[]}onDisplayedChildrenChanged(){this.addListenersToChildrenColumns(),this.onWidthChanged()}onWidthChanged(){const e=this.columnGroup.getActualWidth();this.comp.setWidth(`${e}px`),this.comp.toggleCss("ag-hidden",0===e)}};function th(e,t,o){if(e)for(let i=0;i<e.length;i++){const s=e[i];if(Wn(s)){th(t?s.getDisplayedChildren():s.getChildren(),t,o)}o(s)}}function oh(e){const t=[];return th(e,!0,e=>{qt(e)&&t.push(e)}),t}var ih={moduleName:"ColumnGroup",version:qe,dynamicBeans:{headerGroupCellCtrl:class extends Ya{constructor(){super(...arguments),this.onSuppressColMoveChange=()=>{!this.isAlive()||this.isSuppressMoving()?this.removeDragSource():this.dragSource||this.setDragSource(this.eGui)}}wireComp(e,t,o,i,s){const{column:n,beans:r}=this,{context:a,colNames:l,colHover:d,rangeSvc:h,colResize:c}=r;this.comp=e,s=Vo(this,a,s),this.setGui(t,s),this.displayName=l.getDisplayNameForColumnGroup(n,"header"),this.refreshHeaderStyles(),this.addClasses(),this.setupMovingCss(s),this.setupExpandable(s),this.setupTooltip(),this.setupAutoHeight({wrapperElement:i,compBean:s}),this.setupUserComp(),this.addHeaderMouseListeners(s),this.addManagedPropertyListener("groupHeaderHeight",this.refreshMaxHeaderHeight.bind(this)),this.refreshMaxHeaderHeight();const u=this.rowCtrl.pinned,g=n.getProvidedColumnGroup().getLeafColumns();d?.createHoverFeature(s,g,t),h?.createRangeHighlightFeature(s,n,e),s.createManagedBean(new ja(n,t,r)),s.createManagedBean(new eh(e,n)),c?this.resizeFeature=s.createManagedBean(c.createGroupResizeFeature(e,o,u,n)):e.setResizableDisplayed(!1),s.createManagedBean(new Dr(t,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:()=>{},handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)})),this.addHighlightListeners(s,g),s.addManagedPropertyListener("suppressMovableColumns",this.onSuppressColMoveChange),this.addResizeAndMoveKeyboardListeners(s),s.addDestroyFunc(()=>this.clearComponent())}getHeaderClassParams(){const{column:e,beans:t}=this,o=e.getDefinition();return zt(t.gos,{colDef:o,columnGroup:e,floatingFilter:!1})}refreshMaxHeaderHeight(){const{gos:e,comp:t}=this,o=e.get("groupHeaderHeight");null!=o?0===o?t.setHeaderWrapperHidden(!0):t.setHeaderWrapperMaxHeight(o):(t.setHeaderWrapperHidden(!1),t.setHeaderWrapperMaxHeight(null))}addHighlightListeners(e,t){if(this.beans.gos.get("suppressMoveWhenColumnDragging"))for(const o of t)e.addManagedListeners(o,{headerHighlightChanged:this.onLeafColumnHighlightChanged.bind(this,o)})}onLeafColumnHighlightChanged(e){const t=this.column.getDisplayedLeafColumns(),o=t[0]===e,i=to(t)===e;if(!o&&!i)return;const s=e.getHighlighted();let n=!1,r=!1;if(!!this.rowCtrl.getHeaderCellCtrls().find(e=>e.column.isMoving())){const e=this.beans.gos.get("enableRtl"),t=1===s,a=0===s;o&&(e?r=t:n=a),i&&(e?n=a:r=t)}this.comp.toggleCss("ag-header-highlight-before",n),this.comp.toggleCss("ag-header-highlight-after",r)}resizeHeader(e,t){const{resizeFeature:o}=this;if(!o)return;const i=o.getInitialValues(t);o.resizeColumns(i,i.resizeStartWidth+e,"uiColumnResized",!0)}resizeLeafColumnsToFit(e){this.resizeFeature?.resizeLeafColumnsToFit(e)}setupUserComp(){const{colGroupSvc:e,userCompFactory:t,gos:o,enterpriseMenuFactory:i}=this.beans,s=this.column,n=s.getProvidedColumnGroup(),r=function(e,t){const o=t.columnGroup.getColGroupDef();return e.getCompDetails(o,Jo,"agColumnGroupHeader",t)}(t,zt(o,{displayName:this.displayName,columnGroup:s,setExpanded:t=>{e.setColumnGroupOpened(n,t,"gridInitializing")},setTooltip:(e,t)=>{o.assertModuleRegistered("Tooltip",3),this.setupTooltip(e,t)},showColumnMenu:(e,t)=>i?.showMenuAfterButtonClick(n,e,"columnMenu",t),showColumnMenuAfterMouseClick:(e,t)=>i?.showMenuAfterMouseEvent(n,e,"columnMenu",t),eGridHeader:this.eGui}));r&&this.comp.setUserCompDetails(r)}addHeaderMouseListeners(e){const t=e=>this.handleMouseOverChange("mouseenter"===e.type);e.addManagedListeners(this.eGui,{mouseenter:t,mouseleave:t,click:()=>this.dispatchColumnMouseEvent("columnHeaderClicked",this.column.getProvidedColumnGroup()),contextmenu:e=>this.handleContextMenuMouseEvent(e,void 0,this.column.getProvidedColumnGroup())})}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){const t=this.column.getProvidedColumnGroup();this.refreshExpanded();const o=this.refreshExpanded.bind(this);e.addManagedListeners(t,{expandedChanged:o,expandableChanged:o})}refreshExpanded(){const{column:e}=this;this.expandable=e.isExpandable();const t=e.isExpanded();this.expandable?this.comp.setAriaExpanded(t?"true":"false"):this.comp.setAriaExpanded(void 0),this.refreshHeaderStyles()}addClasses(){const{column:e}=this,t=e.getColGroupDef(),o=xa(t,this.gos,null,e);if(e.isPadding()){o.push("ag-header-group-cell-no-group");e.getLeafColumns().every(e=>e.isSpanHeaderHeight())&&o.push("ag-header-span-height")}else o.push("ag-header-group-cell-with-group"),t?.wrapHeaderText&&o.push("ag-header-cell-wrap-text");o.forEach(e=>this.comp.toggleCss(e,!0))}setupMovingCss(e){const{column:t}=this,o=t.getProvidedColumnGroup().getLeafColumns(),i=()=>this.comp.toggleCss("ag-header-cell-moving",t.isMoving());o.forEach(t=>{e.addManagedListeners(t,{movingChanged:i})}),i()}onFocusIn(e){this.eGui.contains(e.relatedTarget)||this.focusThis()}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();if(this.expandable&&t&&e.key===Pi){const 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()}}},beans:[class extends Me{constructor(){super(...arguments),this.beanName="colGroupSvc"}getColumnGroupState(){const e=[];return xo(null,this.beans.colModel.getColTree(),t=>{Yt(t)&&e.push({groupId:t.getGroupId(),open:t.isExpanded()})}),e}resetColumnGroupState(e){const t=this.beans.colModel.getColDefColTree();if(!t)return;const o=[];xo(null,t,e=>{if(Yt(e)){const t=e.getColGroupDef(),i={groupId:e.getGroupId(),open:t?t.openByDefault:void 0};o.push(i)}}),this.setColumnGroupState(o,e)}setColumnGroupState(e,t){const{colModel:o,colAnimation:i,visibleCols:s,eventSvc:n}=this.beans;if(!o.getColTree().length)return;i?.start();const r=[];e.forEach(e=>{const t=e.groupId,o=e.open,i=this.getProvidedColGroup(t);i&&i.isExpanded()!==o&&(i.setExpanded(o),r.push(i))}),s.refresh(t,!0),r.length&&n.dispatchEvent({type:"columnGroupOpened",columnGroup:1===r.length?r[0]:void 0,columnGroups:r}),i?.finish()}setColumnGroupOpened(e,t,o){let i;i=Yt(e)?e.getId():e||"",this.setColumnGroupState([{groupId:i,open:t}],o)}getProvidedColGroup(e){let t=null;return xo(null,this.beans.colModel.getColTree(),o=>{Yt(o)&&o.getId()===e&&(t=o)}),t}getGroupAtDirection(e,t){const o=e.getProvidedColumnGroup().getLevel()+e.getPaddingLevel(),i=e.getDisplayedLeafColumns(),s="After"===t?to(i):i[0],n=`getCol${t}`;for(;;){const t=this.beans.visibleCols[n](s);if(!t)return null;const i=this.getColGroupAtLevel(t,o);if(i!==e)return i}}getColGroupAtLevel(e,t){let o,i,s=e.getParent();for(;;){if(o=s.getProvidedColumnGroup().getLevel(),i=s.getPaddingLevel(),o+i<=t)break;s=s.getParent()}return s}updateOpenClosedVisibility(){th(this.beans.visibleCols.getAllTrees(),!1,e=>{Wn(e)&&e.calculateDisplayedColumns()})}getColumnGroup(e,t){if(!e)return null;if(Wn(e))return e;const o=this.beans.visibleCols.getAllTrees(),i="number"==typeof t;let s=null;return th(o,!1,o=>{if(Wn(o)){const n=o;let r;r=i?e===n.getGroupId()&&t===n.getPartId():e===n.getGroupId(),r&&(s=n)}}),s}createColumnGroups(e){const{columns:t,idCreator:o,pinned:i,oldDisplayedGroups:s,isStandaloneStructure:n}=e,r=this.mapOldGroupsById(s),a=[];let l=t;for(;l.length;){const e=l;l=[];let t=0;const s=s=>{const d=t;t=s;const h=e[d],c=(Wn(h)?h.getProvidedColumnGroup():h).getOriginalParent();if(null==c){for(let t=d;t<s;t++)a.push(e[t]);return}const u=this.createColumnGroup(c,o,r,i,n);for(let t=d;t<s;t++)u.addChild(e[t]);l.push(u)};for(let o=1;o<e.length;o++){const i=e[o],n=(Wn(i)?i.getProvidedColumnGroup():i).getOriginalParent(),r=e[t];n!==(Wn(r)?r.getProvidedColumnGroup():r).getOriginalParent()&&s(o)}t<e.length&&s(e.length)}return n||this.setupParentsIntoCols(a,null),a}createProvidedColumnGroup(e,t,o,i,s,n,r){const a=s.getUniqueKey(t.groupId||null,null),l=Jt(this.beans,t,a),d=new Qt(l,a,!1,o);this.createBean(d);const h=this.findExistingGroup(t,n);h&&n.splice(h.idx,1);const c=h?.group;c&&d.setExpanded(c.isExpanded());const u=bo(this.beans,l.children,o+1,e,i,s,n,r);return d.setChildren(u),d}balanceColumnTree(e,t,o,i){const s=[];for(let n=0;n<e.length;n++){const r=e[n];if(Yt(r)){const e=r,n=this.balanceColumnTree(e.getChildren(),t+1,o,i);e.setChildren(n),s.push(e)}else{let n,a;for(let e=t;e<o;e++){const t=i.getUniqueKey(null,null),o=Jt(this.beans,null,t),s=new Qt(o,t,!0,e);this.createBean(s),a&&a.setChildren([s]),a=s,n||(n=a)}if(n&&a){s.push(n);if(e.some(e=>Yt(e))){a.setChildren([r]);continue}a.setChildren(e);break}s.push(r)}}return s}findDepth(e){let t=0,o=e;for(;o&&o[0]&&Yt(o[0]);)t++,o=o[0].getChildren();return t}findMaxDepth(e,t){let o=t;for(let i=0;i<e.length;i++){const s=e[i];if(Yt(s)){const e=s,i=this.findMaxDepth(e.getChildren(),t+1);o<i&&(o=i)}}return o}balanceTreeForAutoCols(e,t){const o=[];return e.forEach(e=>{let i=e;for(let o=t-1;o>=0;o--){const t=new Qt(null,`FAKE_PATH_${e.getId()}}_${o}`,!0,o);this.createBean(t),t.setChildren([i]),i.originalParent=t,i=t}0===t&&(e.originalParent=null),o.push(i)}),o}findExistingGroup(e,t){if(null!=e.groupId)for(let o=0;o<t.length;o++){const i=t[o];if(i.getColGroupDef()&&i.getId()===e.groupId)return{idx:o,group:i}}}createColumnGroup(e,t,i,s,n){const r=e.getGroupId(),a=t.getInstanceIdForKey(r);let l=i[zn(r,a)];return l&&l.getProvidedColumnGroup()!==e&&(l=null),o(l)?l.reset():(l=new Un(e,r,a,s),n||this.createBean(l)),l}mapOldGroupsById(e){const t={},o=e=>{e.forEach(e=>{if(Wn(e)){const i=e;t[e.getUniqueId()]=i,o(i.getChildren())}})};return e&&o(e),t}setupParentsIntoCols(e,t){e.forEach(e=>{if(e.parent!==t&&(this.beans.colViewport.colsWithinViewportHash=""),e.parent=t,Wn(e)){const t=e;this.setupParentsIntoCols(t.getChildren(),t)}})}}],apiFunctions:{getAllDisplayedColumnGroups:function(e){return e.visibleCols.getAllTrees()},getCenterDisplayedColumnGroups:function(e){return e.visibleCols.treeCenter},getColumnGroup:function(e,t,o){return e.colGroupSvc?.getColumnGroup(t,o)??null},getColumnGroupState:function(e){return e.colGroupSvc?.getColumnGroupState()??[]},getDisplayNameForColumnGroup:function(e,t,o){return e.colNames.getDisplayNameForColumnGroup(t,o)||""},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,o){e.colGroupSvc?.setColumnGroupOpened(t,o,"api")},setColumnGroupState:function(e,t){e.colGroupSvc?.setColumnGroupState(t,"api")}}},sh={tag:"div",cls:"ag-skeleton-container"},nh={moduleName:"CheckboxCellRenderer",version:qe,userComponents:{agCheckboxCellRenderer:class extends Uo{constructor(){super(dl,[Ms]),this.eCheckbox=Go,this.registerCSS(".ag-checkbox-cell{height:100%}")}init(e){this.refresh(e);const{eCheckbox:t,beans:o}=this,i=t.getInputElement();i.setAttribute("tabindex","-1"),R(i,"polite"),this.addManagedListeners(i,{click:e=>{if(Fr(e),t.isDisabled())return;const o=t.getValue();this.onCheckboxChanged(o)},dblclick:e=>{Fr(e)}}),this.addManagedElementListeners(e.eGridCell,{keydown:i=>{if(i.key===Mi&&!t.isDisabled()){e.eGridCell===u(o)&&t.toggle();const s=t.getValue();this.onCheckboxChanged(s),i.preventDefault()}}})}refresh(e){return this.params=e,this.updateCheckbox(e),!0}updateCheckbox(e){let t,o=!0;const{value:i,column:s,node:n}=e;if(n.group&&s)if("boolean"==typeof i)t=i;else{const e=s.getColId();e.startsWith(ro)?t=null==i||""===i?void 0:"true"===i:n.aggData&&void 0!==n.aggData[e]||n.sourceRowIndex>=0?t=i??void 0:o=!1}else t=i??void 0;const{eCheckbox:r}=this;if(!o)return void r.setDisplayed(!1);r.setValue(t);const a=e.disabled??!s?.isCellEditable(n);r.setDisabled(a);const l=this.getLocaleTextFunc(),d=A(l,t),h=a?d:`${l("ariaToggleCellValue","Press SPACE to toggle cell value")} (${d})`;r.setInputAriaLabel(h)}onCheckboxChanged(e){const{params:t}=this,{column:o,node:i,value:s}=t;this.beans?.editSvc?.setEditingCells([{column:o,colId:o.getColId(),rowIndex:i.rowIndex,rowPinned:i.rowPinned,state:"changed",oldValue:s,newValue:s}],{update:!0,forceRefreshOfEditCellsOnly:!0});const n=i.setDataValue(o,e,"renderer");this.beans.editSvc?.stopEditing({rowNode:i,column:o},{source:this.beans.editSvc?.isBatchEditing()?"ui":"api"}),n||this.updateCheckbox(t)}}}},rh={moduleName:"SkeletonCellRenderer",version:qe,userComponents:{agSkeletonCellRenderer:class extends Uo{constructor(){super(sh)}init(e){const t=`ag-cell-skeleton-renderer-${this.getCompId()}`;this.getGui().setAttribute("id",t),this.addDestroyFunc(()=>E(e.eParentOfValue)),E(e.eParentOfValue,t),e.deferRender?this.setupLoading(e):e.node.failedLoad?this.setupFailed():this.setupLoading(e)}setupFailed(){const e=this.getLocaleTextFunc();this.getGui().textContent=e("loadingError","ERR");const t=e("ariaSkeletonCellLoadingFailed","Row failed to load");S(this.getGui(),t)}setupLoading(e){const t=sr({tag:"div",cls:"ag-skeleton-effect"}),o=e.node.rowIndex;if(null!=o){const e=75+25*(o%2==0?Math.sin(o):Math.cos(o));t.style.width=`${e}%`}this.getGui().appendChild(t);const i=this.getLocaleTextFunc(),s=e.deferRender?i("ariaDeferSkeletonCellLoading","Cell is loading"):i("ariaSkeletonCellLoading","Row data is loading");S(this.getGui(),s)}refresh(e){return!1}}}};function ah(e,t){if(!e)return;const o=e,i={};return Object.keys(o).forEach(e=>{if(t&&t.indexOf(e)>=0||Ve.has(e))return;const s=o[e],n="object"==typeof s&&null!==s&&s.constructor===Object;i[e]=n?ah(s):s}),i}function lh(e,t,o){if(!t||!e)return;if(!o)return e[t];const i=t.split(".");let s=e;for(let e=0;e<i.length;e++){if(null==s)return;s=s[i[e]]}return s}var dh=["dateTimeString","dateString","text","number","boolean","date"];function hh(e,t){const o={...e,...t};return e.columnTypes&&t.columnTypes&&t.appendColumnTypes&&(o.columnTypes=[...fo(e.columnTypes),...fo(t.columnTypes)]),o}function ch(e,t,o){return t?t.baseDataType===e.baseDataType||(st(46),!1):(st(45,{parentCellDataType:o}),!1)}function uh(e,t){if(e.valueFormatter)return o=>{if(o.node?.group){const t=(o.colDef.pivotValueColumn??o.column).getAggFunc();if(t){if("first"===t||"last"===t)return e.valueFormatter(o);if("number"===e.baseDataType&&"count"!==t){if("number"==typeof o.value)return e.valueFormatter(o);if("object"==typeof o.value){if(!o.value)return;if("toNumber"in o.value)return e.valueFormatter({...o,value:o.value.toNumber()});if("value"in o.value)return e.valueFormatter({...o,value:o.value.value})}}return}}else if(t.get("groupHideOpenParents")&&o.column.isRowGroupActive()&&"string"==typeof o.value&&!e.dataTypeMatcher?.(o.value))return;return e.valueFormatter(o)}}function gh(e,t){return[["cellRenderer","agSparklineCellRenderer"],["valueGetter",void 0],["valueParser",void 0],["refData",void 0]].some(([o,i])=>function(e,t,o,i){if(!t[o])return!1;const s=e[o];return null===s?(t[o]=!1,!1):void 0===i?!!s:s===i}(e,t,o,i))}function ph(e,t){const o=Lo(e);return t.forEach(e=>{delete o[e],"rowGroup"===e?delete o.rowGroupIndex:"pivot"===e&&delete o.pivotIndex}),o}var mh={moduleName:"DataType",version:qe,beans:[class extends Me{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===Mi}),date:({formatValue:e})=>({cellEditor:"agDateCellEditor",keyCreator:e}),dateString:({formatValue:e})=>({cellEditor:"agDateStringCellEditor",keyCreator:e}),dateTime(e){return this.date(e)},dateTimeString(e){return this.dateString(e)},object:({formatValue:e,colModel:t,colId:o})=>({cellEditorParams:{useFormatter:!0},comparator:(i,s)=>{const n=t.getColDefCol(o),r=n?.getColDef();if(!n||!r)return 0;const a=null==i?"":e({column:n,node:null,value:i}),l=null==s?"":e({column:n,node:null,value:s});return a===l?0:a>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(){const e=this.getDefaultDataTypes(),t={},o={},i=e=>t=>{const{column:o,node:i,value:s}=t;let n=o.getColDef().valueFormatter;return n===e.groupSafeValueFormatter&&(n=e.valueFormatter),this.beans.valueSvc.formatValue(o,i,s,n)};for(const s of Object.keys(e)){const n=e[s],r={...n,groupSafeValueFormatter:uh(n,this.gos)};t[s]=r,o[s]=i(r)}const s=this.gos.get("dataTypeDefinitions")??{},n={};for(const r of Object.keys(s)){const a=s[r],l=this.processDataTypeDefinition(a,s,[r],e);l&&(t[r]=l,a.dataTypeMatcher&&(n[r]=a.dataTypeMatcher),o[r]=i(l))}const{valueParser:r,valueFormatter:a}=e.object,{valueParser:l,valueFormatter:d}=t.object;this.hasObjectValueParser=l!==r,this.hasObjectValueFormatter=d!==a,this.formatValueFuncs=o,this.dataTypeDefinitions=t,this.dataTypeMatchers=this.sortKeysInMatchers(n,e)}sortKeysInMatchers(e,t){const o={...e};for(const i of dh)delete o[i],o[i]=e[i]??t[i].dataTypeMatcher;return o}processDataTypeDefinition(e,t,o,i){let s;const n=e.extendsDataType;if(e.columnTypes&&(this.isColumnTypeOverrideInDataTypeDefinitions=!0),e.extendsDataType===e.baseDataType){let o=i[n];const r=t[n];if(o&&r&&(o=r),!ch(e,o,n))return;s=hh(o,e)}else{if(o.includes(n))return void st(44);const r=t[n];if(!ch(e,r,n))return;const a=this.processDataTypeDefinition(r,t,[...o,n],i);if(!a)return;s=hh(a,e)}return{...s,groupSafeValueFormatter:uh(s,this.gos)}}updateColDefAndGetColumnType(e,t,o){let{cellDataType:i}=t;const{field:s}=t;if(void 0===i&&(i=e.cellDataType),null!=i&&!0!==i||(i=!!this.canInferCellDataType(e,t)&&this.inferCellDataType(s,o)),!i)return void(e.cellDataType=!1);const n=this.dataTypeDefinitions[i];if(n)return e.cellDataType=i,n.groupSafeValueFormatter&&(e.valueFormatter=n.groupSafeValueFormatter),n.valueParser&&(e.valueParser=n.valueParser),n.suppressDefaultProperties||this.setColDefPropertiesForBaseDataType(e,i,n,o),n.columnTypes;st(47,{cellDataType:i})}addColumnListeners(e){if(!this.isPendingInference)return;const t=this.columnStateUpdatesPendingInference[e.getColId()];if(!t)return;const o=e=>{t.add(e.key)};e.__addEventListener("columnStateUpdated",o),this.columnStateUpdateListenerDestroyFuncs.push(()=>e.__removeEventListener("columnStateUpdated",o))}canInferCellDataType(e,t){const{gos:o}=this;if(!dt(o))return!1;const i={cellRenderer:!0,valueGetter:!0,valueParser:!0,refData:!0};if(gh(t,i))return!1;const s=null===t.type?e.type:t.type;if(s){const e=o.get("columnTypes")??{};if(fo(s).some(t=>{const o=e[t.trim()];return o&&gh(o,i)}))return!1}return!gh(e,i)}inferCellDataType(e,t){if(!e)return;let o;const i=this.getInitialData();if(i){const t=e.indexOf(".")>=0&&!this.gos.get("suppressFieldDotNotation");o=lh(i,e,t)}else this.initWaitForRowData(t);if(null==o)return;return Object.keys(this.dataTypeMatchers).find(e=>this.dataTypeMatchers[e](o))??"object"}getInitialData(){const e=this.gos.get("rowData");if(e?.length)return e[0];if(this.initialData)return this.initialData;{const e=this.beans.rowModel.rootNode?.allLeafChildren;if(e?.length)return e[0].data}return null}initWaitForRowData(e){if(this.columnStateUpdatesPendingInference[e]=new Set,this.isPendingInference)return;this.isPendingInference=!0;const t=this.isColumnTypeOverrideInDataTypeDefinitions,{colAutosize:o,eventSvc:i}=this.beans;t&&o&&(o.shouldQueueResizeOperations=!0);const[s]=this.addManagedEventListeners({rowDataUpdateStarted:e=>{const{firstRowData:n}=e;n&&(s?.(),this.isPendingInference=!1,this.processColumnsPendingInference(n,t),this.columnStateUpdatesPendingInference={},t&&o?.processResizeOperations(),i.dispatchEvent({type:"dataTypesInferred"}))}})}processColumnsPendingInference(e,t){this.initialData=e;const o=[];this.destroyColumnStateUpdateListeners();const i={},s={};for(const e of Object.keys(this.columnStateUpdatesPendingInference)){const n=this.columnStateUpdatesPendingInference[e],r=this.colModel.getCol(e);if(!r)return;const a=r.getColDef();if(!this.resetColDefIntoCol(r,"cellDataTypeInferred"))return;const l=r.getColDef();if(t&&l.type&&l.type!==a.type){const t=ph(r,n);t.rowGroup&&null==t.rowGroupIndex&&(i[e]=t),t.pivot&&null==t.pivotIndex&&(s[e]=t),o.push(t)}}t&&o.push(...this.generateColumnStateForRowGroupAndPivotIndexes(i,s)),o.length&&To(this.beans,{state:o},"cellDataTypeInferred"),this.initialData=null}generateColumnStateForRowGroupAndPivotIndexes(e,t){const o={},{rowGroupColsSvc:i,pivotColsSvc:s}=this.beans;return i?.restoreColumnOrder(o,e),s?.restoreColumnOrder(o,t),Object.values(o)}resetColDefIntoCol(e,t){const o=e.getUserProvidedColDef();if(!o)return!1;const i=Eo(this.beans,o,e.getColId());return e.setColDef(i,o,t),!0}getDateStringTypeDefinition(e){const{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){const 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;const o=this.getDataTypeDefinition(e)?.dataTypeMatcher;return!o||o(t)}validateColDef(e){const t=e=>st(48,{property:e});if("object"===e.cellDataType){const{object:o}=this.dataTypeDefinitions;e.valueFormatter!==o.groupSafeValueFormatter||this.hasObjectValueFormatter||t("Formatter"),e.editable&&e.valueParser===o.valueParser&&!this.hasObjectValueParser&&t("Parser")}}postProcess(e){const t=e.cellDataType;if(!t||"string"!=typeof t)return;const{dataTypeDefinitions:o,beans:i,formatValueFuncs:s}=this,n=o[t];n&&i.colFilter?.setColDefPropsForDataType(e,n,s[t])}getFormatValue(e){return this.formatValueFuncs[e]}isColPendingInference(e){return this.isPendingInference&&!!this.columnStateUpdatesPendingInference[e]}setColDefPropertiesForBaseDataType(e,t,o,i){const s=this.formatValueFuncs[t],n=this.columnDefinitionPropsPerDataType[o.baseDataType]({colDef:e,cellDataType:t,colModel:this.colModel,dataTypeDefinition:o,colId:i,formatValue:s});Object.assign(e,n)}getDateObjectTypeDef(e){const t=this.getLocaleTextFunc(),o=this.getDateIncludesTimeFlag(e);return{baseDataType:e,valueParser:e=>cs(e.newValue&&String(e.newValue)),valueFormatter:e=>null==e.value?"":e.value instanceof Date&&!isNaN(e.value.getTime())?ss(e.value,o)??"":t("invalidDate","Invalid Date"),dataTypeMatcher:e=>e instanceof Date}}getDateStringTypeDef(e){const t=this.getDateIncludesTimeFlag(e);return{baseDataType:e,dateParser:e=>cs(e)??void 0,dateFormatter:e=>ss(e??null,t)??void 0,valueParser:e=>hs(String(e.newValue))?e.newValue:null,valueFormatter:e=>hs(String(e.value))?String(e.value):"",dataTypeMatcher:e=>"string"==typeof e&&hs(e)}}getDefaultDataTypes(){const 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:s(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&&function(e){return hs(e,!0)}(e)},object:{baseDataType:"object",valueParser:()=>null,valueFormatter:e=>s(e.value)??""}}}destroyColumnStateUpdateListeners(){this.columnStateUpdateListenerDestroyFuncs.forEach(e=>e()),this.columnStateUpdateListenerDestroyFuncs=[]}destroy(){this.dataTypeDefinitions={},this.dataTypeMatchers={},this.formatValueFuncs={},this.columnStateUpdatesPendingInference={},this.destroyColumnStateUpdateListeners(),super.destroy()}}],dependsOn:[nh]},fh={moduleName:"ColumnFlex",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="colFlex"}refreshFlexedColumns(e={}){const t=e.source??"flex";null!=e.viewportWidth&&(this.flexViewportWidth=e.viewportWidth);const o=this.flexViewportWidth,{visibleCols:i,colDelayRenderSvc:s}=this.beans,n=i.centerCols;let r=-1;if(e.resizingCols){const t=new Set(e.resizingCols);for(let e=n.length-1;e>=0;e--)if(t.has(n[e])){r=e;break}}let a=!1;const l=n.map((e,t)=>{const o=e.getFlex(),i=null!=o&&o>0&&t>r;return a||(a=i),{col:e,isFlex:i,flex:Math.max(0,o??0),initialSize:e.getActualWidth(),min:e.getMinWidth(),max:e.getMaxWidth(),targetSize:0}});if(a&&s?.hideColumns("colFlex"),!o||!a)return[];let d=l.length,h=l.reduce((e,t)=>e+t.flex,0),c=o;const u=(e,o)=>{e.frozenSize=o,e.col.setActualWidth(o,t),c-=o,h-=e.flex,d-=1},g=e=>null!=e.frozenSize;for(const e of l)e.isFlex||u(e,e.initialSize);for(;d>0;){const e=Math.round(h<1?c*h:c);let t,o=0,i=0;for(const s of l){if(g(s))continue;t=s,i+=e*(s.flex/h);const n=i-o,r=Math.round(n);s.targetSize=r,o+=r}t&&(t.targetSize+=e-o);let s=0;for(const e of l){if(g(e))continue;const t=e.targetSize,o=Math.min(Math.max(t,e.min),e.max);s+=o-t,e.violationType=o===t?void 0:o<t?"max":"min",e.targetSize=o}const n=0===s?"all":s>0?"min":"max";for(const e of l)g(e)||"all"!==n&&e.violationType!==n||u(e,e.targetSize)}e.skipSetLeft||i.setLeftValues(t),e.updateBodyWidths&&i.updateBodyWidths();const p=l.filter(e=>e.isFlex&&!e.violationType).map(e=>e.col);if(e.fireResizedEvent){const e=l.filter(e=>e.initialSize!==e.frozenSize).map(e=>e.col),o=l.filter(e=>e.flex).map(e=>e.col);ko(this.eventSvc,e,!0,t,o)}return s?.revealColumns("colFlex"),p}initCol(e){const{flex:t,initialFlex:o}=e.colDef;void 0!==t?e.flex=t:void 0!==o&&(e.flex=o)}setColFlex(e,t){e.flex=t??null,e.dispatchStateUpdatedEvent("flex")}}]},Ch={moduleName:"ColumnApi",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="colDefFactory"}wireBeans(e){this.rowGroupColsSvc=e.rowGroupColsSvc,this.pivotColsSvc=e.pivotColsSvc}getColumnDefs(e,t,o,i){const s=e.slice();t?s.sort((e,t)=>o.indexOf(e)-o.indexOf(t)):o&&s.sort((e,t)=>i.indexOf(e)-i.indexOf(t));const n=this.rowGroupColsSvc?.columns,r=this.pivotColsSvc?.columns;return this.buildColumnDefs(s,n,r)}buildColumnDefs(e,t=[],o=[]){const i=[],s={};return e.forEach(e=>{let n=!0,r=this.createDefFromColumn(e,t,o),a=e.getOriginalParent(),l=null;for(;a;){let e=null;if(a.isPadding()){a=a.getOriginalParent();continue}const t=s[a.getGroupId()];if(t){t.children.push(r),n=!1;break}if(e=this.createDefFromGroup(a),e&&(e.children=[r],s[e.groupId]=e,r=e,a=a.getOriginalParent()),null!=a&&l===a){n=!1;break}l=a}n&&i.push(r)}),i}createDefFromGroup(e){const t=ah(e.getColGroupDef(),["children"]);return t&&(t.groupId=e.getGroupId()),t}createDefFromColumn(e,t,o){const i=ah(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()?o.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}}],apiFunctions:{getColumnDef:function(e,t){const o=e.colModel.getColDefCol(t);return o?o.getColDef():null},getDisplayNameForColumn:function(e,t,o){return e.colNames.getDisplayNameForColumn(t,o)||""},getColumn:function(e,t){return e.colModel.getColDefCol(t)},getColumns:function(e){return e.colModel.getColDefCols()},applyColumnState:function(e,t){return To(e,t,"api")},getColumnState:function(e){return Ao(e)},resetColumnState:function(e){!function(e,t){const{colModel:o,autoColSvc:s,selectionColSvc:n,eventSvc:r,gos:a}=e,l=o.getColDefCols();if(!l?.length)return;const d=ho(o.getColDefColTree()),h=[];let c=1e3,u=1e3;const g=e=>{const t=Lo(e);i(t.rowGroupIndex)&&t.rowGroup&&(t.rowGroupIndex=c++),i(t.pivotIndex)&&t.pivot&&(t.pivotIndex=u++),h.push(t)};s?.getColumns()?.forEach(g),n?.getColumns()?.forEach(g),d?.forEach(g),To(e,{state:h},t);const p=s?.getColumns()??[];To(e,{state:[...n?.getColumns()??[],...p,...l].map(e=>({colId:e.colId})),applyOrder:!0},t),r.dispatchEvent(zt(a,{type:"columnsReset",source:t}))}(e,"api")},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,o){e.colModel.setColsVisible(t,o,"api")},setColumnsPinned:function(e,t,o){e.pinnedCols?.setColsPinned(t,o,"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()}}};var vh,wh={moduleName:"CellRendererFunction",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="agCompUtils"}adaptFunction(e,t){if(!e.cellRenderer)return null;return class{refresh(){return!1}getGui(){return this.eGui}init(e){const o=t(e),i=typeof o;this.eGui="string"!==i&&"number"!==i&&"boolean"!==i?null!=o?o:sr({tag:"span"}):Z("<span>"+o+"</span>")}}}}]},bh=new Set,yh={},Sh={},Eh=!1,Rh=!1;function xh(e){vh||(vh=e.version);const t=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.`;if(e.version?function(e){const[t,o]=e.version.split(".")||[],[i,s]=vh.split(".")||[];return t===i&&o===s}(e)||je(t(`'${e.moduleName}' is version ${e.version} but the other modules are version ${vh}.`)):je(t(`'${e.moduleName}' is incompatible.`)),e.validate){const t=e.validate();if(!t.isValid){je(`${t.message}`)}}}function Fh(e,t,o=!1){o||(Eh=!0),xh(e);const i=e.rowModels??["all"];let s;bh.add(e),void 0!==t?(Rh=!0,void 0===Sh[t]&&(Sh[t]={}),s=Sh[t]):s=yh,i.forEach(t=>{void 0===s[t]&&(s[t]={}),s[t][e.moduleName]=e}),e.dependsOn&&e.dependsOn.forEach(e=>Fh(e,t,o))}function Ph(e,t,o){const i=o=>!!yh[o]?.[e]||!!Sh[t]?.[o]?.[e];return i(o)||i("all")}function Dh(){return Rh}var Mh,kh={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"},sideButtonBarBackgroundColor:{ref:"sideBarBackgroundColor"},sideButtonBarTopPadding:0,sideButtonSelectedUnderlineWidth:2,sideButtonSelectedUnderlineColor:"transparent",sideButtonSelectedUnderlineTransitionDuration:0,sideButtonBackgroundColor:"transparent",sideButtonTextColor:{ref:"textColor"},sideButtonHoverBackgroundColor:{ref:"sideButtonBackgroundColor"},sideButtonHoverTextColor:{ref:"sideButtonTextColor"},sideButtonSelectedBackgroundColor:on,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"},headerCellBackgroundTransitionDuration:"0.2s",cellTextColor:{ref:"textColor"},rangeSelectionBorderStyle:"solid",rangeSelectionBorderColor:nn,rangeSelectionBackgroundColor:Xs(.2),rangeSelectionChartBackgroundColor:"#0058FF1A",rangeSelectionChartCategoryBackgroundColor:"#00FF841A",rangeSelectionHighlightColor:Xs(.5),rangeHeaderHighlightColor:(Mh=.08,{ref:"foregroundColor",mix:Mh,onto:"headerBackgroundColor"}),rowNumbersSelectedColor:Xs(.5),rowHoverColor:Xs(.08),columnHoverColor:Xs(.05),selectedRowBackgroundColor:Xs(.12),modalOverlayBackgroundColor:{ref:"backgroundColor",mix:.66},oddRowBackgroundColor:on,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:en(.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:en(.1),iconButtonActiveColor:nn,iconButtonActiveBackgroundColor:Xs(.28),iconButtonActiveIndicatorColor:nn,menuBorder:{color:en(.2)},menuBackgroundColor:tn(.03),menuTextColor:tn(.95),menuShadow:{ref:"popupShadow"},menuSeparatorColor:{ref:"borderColor"},setFilterIndentSize:{ref:"iconSize"},chartMenuPanelWidth:260,chartMenuLabelColor:en(.8),dialogShadow:{ref:"popupShadow"},cellEditingBorder:{color:nn},cellEditingShadow:{ref:"cardShadow"},fullRowEditInvalidBackgroundColor:{ref:"invalidColor",onto:"backgroundColor",mix:.25},dialogBorder:{color:en(.2)},panelBackgroundColor:on,panelTitleBarBackgroundColor:{ref:"headerBackgroundColor"},panelTitleBarIconColor:{ref:"headerTextColor"},panelTitleBarTextColor:{ref:"headerTextColor"},panelTitleBarFontWeight:{ref:"headerFontWeight"},panelTitleBarBorder:!0,columnSelectIndentSize:{ref:"iconSize"},toolPanelSeparatorBorder:!0,columnDropCellBackgroundColor:en(.07),columnDropCellTextColor:{ref:"textColor"},columnDropCellDragHandleColor:{ref:"textColor"},columnDropCellBorder:{color:en(.13)},selectCellBackgroundColor:en(.07),selectCellBorder:{color:en(.13)},advancedFilterBuilderButtonBarBorder:!0,advancedFilterBuilderIndentSize:{calc:"spacing * 2 + iconSize"},advancedFilterBuilderJoinPillColor:"#f08e8d",advancedFilterBuilderColumnPillColor:"#a6e194",advancedFilterBuilderOptionPillColor:"#f3c08b",advancedFilterBuilderValuePillColor:"#85c0e4",filterPanelApplyButtonColor:on,filterPanelApplyButtonBackgroundColor:nn,filterPanelCardSubtleColor:{ref:"textColor",mix:.7},filterPanelCardSubtleHoverColor:{ref:"textColor"},findMatchColor:sn,findMatchBackgroundColor:"#ffff00",findActiveMatchColor:sn,findActiveMatchBackgroundColor:"#ffa500",filterToolPanelGroupIndent:{ref:"spacing"},rowLoadingSkeletonEffectColor:en(.15),statusBarLabelColor:sn,statusBarLabelFontWeight:500,statusBarValueColor:sn,statusBarValueFontWeight:500,pinnedSourceRowTextColor:{ref:"textColor"},pinnedSourceRowBackgroundColor:{ref:"backgroundColor"},pinnedSourceRowFontWeight:600,pinnedRowFontWeight:600,pinnedRowBackgroundColor:{ref:"backgroundColor"},pinnedRowTextColor:{ref:"textColor"}},Th={cellBatchEditBackgroundColor:"rgba(220 181 139 / 16%)",cellBatchEditTextColor:"#422f00",rowBatchEditBackgroundColor:{ref:"cellBatchEditBackgroundColor"},rowBatchEditTextColor:{ref:"cellBatchEditTextColor"}},Ih={...Th,cellBatchEditTextColor:"#f3d0b3"},Ah=(()=>qs({feature:"batchEditStyle",params:Th,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)}"}))(),Lh=":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)}}",Bh={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"},buttonDisabledBackgroundColor:{ref:"inputDisabledBackgroundColor"},buttonDisabledBorder:{ref:"inputDisabledBorder"}},Hh=(()=>qs({feature:"buttonStyle",params:Bh,css:Lh}))(),Vh=(()=>qs({feature:"buttonStyle",params:{...Bh,buttonBackgroundColor:on,buttonBorder:!0,buttonHoverBackgroundColor:{ref:"rowHoverColor"},buttonActiveBorder:{color:nn}},css:Lh}))(),Gh=(()=>qs({feature:"buttonStyle",params:{...Bh,buttonBackgroundColor:on,buttonBorder:{color:nn},buttonFontWeight:600,buttonTextColor:nn,buttonHoverBackgroundColor:{ref:"rowHoverColor"},buttonActiveBackgroundColor:nn,buttonActiveTextColor:on},css:Lh}))(),Nh=(()=>qs({feature:"buttonStyle",params:{...Bh,buttonBorder:{color:sn,width:2,style:"outset"},buttonActiveBorder:{color:sn,width:2,style:"inset"},buttonBackgroundColor:tn(.07),buttonHoverBackgroundColor:on,buttonVerticalPadding:{calc:"spacing * 0.5"}},css:Lh}))(),Oh=(()=>qs({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}"}))(),zh=(()=>qs({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))}"}))(),Wh={warn:(...e)=>{st(e[0],e[1])},error:(...e)=>{nt(e[0],e[1])},preInitErr:(...e)=>{rt(e[0],e[2],e[1])}},Uh=()=>{return(e=Wh,new bn(e)).withParams(kh).withPart(Vh).withPart(Oh).withPart(Ah);var e},$h=(()=>qs({feature:"checkboxStyle",params:{checkboxBorderWidth:1,checkboxBorderRadius:{ref:"borderRadius"},checkboxUncheckedBackgroundColor:on,checkboxUncheckedBorderColor:tn(.3),checkboxCheckedBackgroundColor:nn,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>'},checkboxCheckedShapeColor:on,checkboxIndeterminateBackgroundColor:tn(.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:on,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)}}'}))(),Kh=()=>({...rn,...Ih,backgroundColor:"hsl(217, 0%, 17%)",foregroundColor:"#FFF",chromeBackgroundColor:tn(.05),rowHoverColor:Xs(.15),selectedRowBackgroundColor:Xs(.2),menuBackgroundColor:tn(.1),browserColorScheme:"dark",popupShadow:"0 0px 20px #000A",cardShadow:"0 1px 4px 1px #000A",advancedFilterBuilderJoinPillColor:"#7a3a37",advancedFilterBuilderColumnPillColor:"#355f2d",advancedFilterBuilderOptionPillColor:"#5a3168",advancedFilterBuilderValuePillColor:"#374c86",filterPanelApplyButtonColor:sn,findMatchColor:on,findActiveMatchColor:on,checkboxUncheckedBorderColor:tn(.4),toggleButtonOffBackgroundColor:tn(.4),rowBatchEditBackgroundColor:tn(.1)}),jh=(()=>qs({feature:"colorScheme",params:rn,modeParams:{light:rn,dark:Kh(),"dark-blue":{...Kh(),backgroundColor:"#1f2836"}}}))(),qh=qs({feature:"iconSet",css:".ag-icon-aggregation:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eaggregation%3C/title%3E%3Cpath d='M25.128 2.002c2.56.096 4.772 2.292 4.87 4.87a712 712 0 0 1 0 18.256c-.096 2.56-2.292 4.772-4.87 4.87a712 712 0 0 1-18.256 0c-2.558-.096-4.772-2.29-4.87-4.87a712 712 0 0 1 0-18.256c.096-2.56 2.292-4.772 4.87-4.87a712 712 0 0 1 18.256 0M7.006 4c-1.57.02-2.946 1.348-3.004 2.922-.078 6.078-.23 12.16.002 18.234.094 1.484 1.354 2.746 2.84 2.84 6.1.232 12.212.232 18.312 0 1.48-.094 2.746-1.35 2.84-2.84.232-6.1.232-12.212 0-18.312-.094-1.48-1.35-2.746-2.84-2.84C19.11 3.774 13.056 4 7.006 4M22 12h-2v-2h-8v.092c.056 1.352 3.426 2.598 4.472 4.404.682 1.174.438 2.754-.572 3.72C14.29 19.618 12 20.924 12 22h8v-2h2v4H10c0-1.586-.098-3.304 1.016-4.314 1.904-1.632 4.89-3.108 3.54-4.42-1.918-1.68-4.464-2.936-4.554-5.12L10 8h12z'/%3E%3C/svg%3E\")}.ag-icon-arrows:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Earrows%3C/title%3E%3Cpath d='m6.414 17 2.294 2.292-1.416 1.416L2.586 16l4.706-4.708 1.416 1.416L6.414 15H15V6.414l-2.292 2.294-1.416-1.416L16 2.586l4.708 4.706-1.416 1.416L17 6.414V15h8.586l-2.294-2.292 1.416-1.416L29.414 16l-4.706 4.708-1.416-1.416L25.586 17H17v8.586l2.292-2.294 1.416 1.416L16 29.414l-4.708-4.706 1.416-1.416L15 25.586V17z'/%3E%3C/svg%3E\")}.ag-icon-asc:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Easc%3C/title%3E%3Cpath d='m15 10.621-4.292 4.294-1.416-1.416L16 6.793l6.708 6.706-1.416 1.416L17 10.621v14.586h-2z'/%3E%3C/svg%3E\")}.ag-icon-cancel:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecancel%3C/title%3E%3Cpath d='M16 4C9.378 4 4 9.378 4 16s5.378 12 12 12 12-5.378 12-12S22.622 4 16 4m0 2c5.52 0 10 4.48 10 10s-4.48 10-10 10S6 21.52 6 16 10.48 6 16 6m0 8.586 5.292-5.294 1.416 1.416L17.414 16l5.294 5.292-1.416 1.416L16 17.414l-5.292 5.294-1.416-1.416L14.586 16l-5.294-5.292 1.416-1.416z'/%3E%3C/svg%3E\")}.ag-icon-chart:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Echart%3C/title%3E%3Cpath d='M6.667 12.267h4v13.067h-4zm7.466-5.6h3.733v18.667h-3.733zM21.6 17.333h3.733v8H21.6z'/%3E%3C/svg%3E\")}.ag-icon-color-picker:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecolor-picker%3C/title%3E%3Cpath d='M23.907 17.587 10.574 4.254l-1.88 1.88 3.173 3.173-8.28 8.28 10.16 10.16zm-16.547 0 6.387-6.387 6.387 6.387H7.361zm18.387 2s-2.667 2.893-2.667 4.667c0 1.467 1.2 2.667 2.667 2.667s2.667-1.2 2.667-2.667c0-1.773-2.667-4.667-2.667-4.667'/%3E%3C/svg%3E\")}.ag-icon-columns:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecolumns%3C/title%3E%3Cpath d='M14 25h-2V7h2zm6 0h-2V7h2zm6 0h-2V7h2zM8 25H6V7h2z'/%3E%3C/svg%3E\")}.ag-icon-contracted:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Econtracted%3C/title%3E%3Cpath d='m21.061 16-8.706 8.708-1.416-1.416L18.233 16l-7.294-7.292 1.416-1.416z'/%3E%3C/svg%3E\")}.ag-icon-copy:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecopy%3C/title%3E%3Cpath d='M21.929 27.999h-7.828a5.09 5.09 0 0 1-5.086-5.086v-9.812a5.087 5.087 0 0 1 5.086-5.086h7.828a5.09 5.09 0 0 1 5.086 5.086v9.812a5.087 5.087 0 0 1-5.086 5.086m.16-17.984h-8.088a2.94 2.94 0 0 0-2.938 2.938v10.132a2.94 2.94 0 0 0 2.938 2.938h8.088a2.94 2.94 0 0 0 2.936-2.938V12.953a2.94 2.94 0 0 0-2.936-2.938M7.041 26.013h-2.05a4 4 0 0 1-.006-.228V9.065a5.07 5.07 0 0 1 5.064-5.064h12.812q.069 0 .134.002v2.012H9.915a2.876 2.876 0 0 0-2.874 2.874z'/%3E%3C/svg%3E\")}.ag-icon-cross:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='4 4 24 24'%3E%3Ctitle%3Ecross%3C/title%3E%3Cpath d='m16 14.586 5.292-5.294 1.416 1.416L17.414 16l5.294 5.292-1.416 1.416L16 17.414l-5.292 5.294-1.416-1.416L14.586 16l-5.294-5.292 1.416-1.416z'/%3E%3C/svg%3E\")}.ag-icon-csv:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='translate(3.934 -.054)scale(.06285)'/%3E%3Cpath d='M.688-.226a.2.2 0 0 1-.017.074.28.28 0 0 1-.145.14.412.412 0 0 1-.234.013.28.28 0 0 1-.202-.168.468.468 0 0 1-.04-.19q0-.086.025-.155a.319.319 0 0 1 .182-.191.4.4 0 0 1 .134-.025q.087 0 .155.035a.3.3 0 0 1 .104.085.17.17 0 0 1 .036.097.06.06 0 0 1-.018.044.06.06 0 0 1-.042.019.06.06 0 0 1-.042-.013.2.2 0 0 1-.031-.046.2.2 0 0 0-.066-.079.16.16 0 0 0-.095-.027.17.17 0 0 0-.142.068.3.3 0 0 0-.053.193.4.4 0 0 0 .023.139.2.2 0 0 0 .067.083.2.2 0 0 0 .1.027q.063 0 .106-.031a.2.2 0 0 0 .065-.091.2.2 0 0 1 .023-.046q.014-.018.044-.018a.06.06 0 0 1 .044.018.06.06 0 0 1 .019.045' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 7.122 25.977)'/%3E%3Cpath d='M.622-.215a.2.2 0 0 1-.033.117.23.23 0 0 1-.098.081.4.4 0 0 1-.153.029.34.34 0 0 1-.175-.04.23.23 0 0 1-.079-.077.17.17 0 0 1-.031-.093q0-.027.019-.045a.06.06 0 0 1 .046-.019.06.06 0 0 1 .039.014.1.1 0 0 1 .027.044.3.3 0 0 0 .03.057q.015.023.044.038.03.015.076.015.065 0 .105-.03a.09.09 0 0 0 .04-.075.08.08 0 0 0-.022-.058.14.14 0 0 0-.056-.034 1 1 0 0 0-.092-.025.7.7 0 0 1-.129-.042.2.2 0 0 1-.083-.066.17.17 0 0 1-.03-.104q0-.058.032-.105a.2.2 0 0 1 .093-.07.4.4 0 0 1 .144-.025q.066 0 .114.016a.3.3 0 0 1 .08.044.2.2 0 0 1 .046.057q.015.03.015.058a.07.07 0 0 1-.018.046.06.06 0 0 1-.046.021q-.025 0-.038-.012a.2.2 0 0 1-.028-.041.2.2 0 0 0-.047-.063Q.387-.625.326-.625a.15.15 0 0 0-.09.025q-.035.024-.035.059 0 .021.012.037a.1.1 0 0 0 .032.027.4.4 0 0 0 .111.036q.06.015.11.031.048.018.083.042a.2.2 0 0 1 .054.062.2.2 0 0 1 .019.091' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 13.339 25.977)'/%3E%3Cpath d='m.184-.633.162.48.163-.483q.013-.038.019-.053a.062.062 0 0 1 .061-.039q.018 0 .034.009a.1.1 0 0 1 .025.025q.009.015.009.031L.654-.64l-.007.025-.009.024-.173.468-.019.051a.2.2 0 0 1-.021.042.1.1 0 0 1-.033.03.1.1 0 0 1-.049.012.1.1 0 0 1-.05-.011A.1.1 0 0 1 .26-.03a.2.2 0 0 1-.021-.042L.22-.123.05-.587.041-.612.033-.638.03-.662q0-.025.02-.046a.07.07 0 0 1 .05-.02q.037 0 .053.023.015.023.031.072' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 18.94 25.977)'/%3E%3C/svg%3E\")}.ag-icon-cut:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M14.703 15.096 6.215 4.719a1 1 0 1 1 1.548-1.267l13.058 15.965A5.001 5.001 0 0 1 28 23.916a5 5 0 0 1-4.999 4.999 5 5 0 0 1-4.999-4.999 4.98 4.98 0 0 1 1.23-3.283l-3.238-3.958-3.272 4.001a4.98 4.98 0 0 1 1.265 3.323 5 5 0 0 1-4.999 4.999 5 5 0 0 1-4.999-4.999 5 5 0 0 1 7.13-4.522zM8.991 20.8a3.1 3.1 0 0 0-3.1 3.1c0 1.711 1.389 3.1 3.1 3.1s3.1-1.389 3.1-3.1-1.389-3.1-3.1-3.1M23 20.8a3.1 3.1 0 0 0-3.1 3.1c0 1.711 1.389 3.1 3.1 3.1s3.1-1.389 3.1-3.1-1.389-3.1-3.1-3.1m-5.723-8.852 1.292 1.579 7.205-8.808a1 1 0 0 0-1.548-1.267z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-desc:before,.ag-icon-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Edesc%3C/title%3E%3Cpath d='m17 21.379 4.292-4.294 1.416 1.416L16 25.207l-6.708-6.706 1.416-1.416L15 21.379V6.793h2z'/%3E%3C/svg%3E\")}.ag-icon-excel:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='translate(3.934 -.054)scale(.06285)'/%3E%3Cpath d='m.052-.139.16-.234-.135-.208a.4.4 0 0 1-.028-.052.1.1 0 0 1-.01-.042.05.05 0 0 1 .018-.037.07.07 0 0 1 .045-.016q.03 0 .047.018a1 1 0 0 1 .047.066l.107.174.115-.174.024-.038.019-.026.021-.015a.1.1 0 0 1 .027-.005.06.06 0 0 1 .044.016.05.05 0 0 1 .018.039q0 .033-.038.089l-.141.211.152.234a.3.3 0 0 1 .03.051.1.1 0 0 1 .009.038.1.1 0 0 1-.008.031.1.1 0 0 1-.024.023.1.1 0 0 1-.034.008.1.1 0 0 1-.035-.008.1.1 0 0 1-.023-.022L.427-.067.301-.265l-.134.204-.022.034-.016.019a.1.1 0 0 1-.022.015.1.1 0 0 1-.03.005.06.06 0 0 1-.044-.016.06.06 0 0 1-.017-.047q0-.036.036-.088' style='fill-rule:nonzero' transform='matrix(17.82892 0 0 16.50777 10.371 25.928)'/%3E%3C/svg%3E\")}.ag-icon-expanded:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eexpanded%3C/title%3E%3Cpath d='M21.061 8.708 13.767 16l7.294 7.292-1.416 1.416L10.939 16l8.706-8.708z'/%3E%3C/svg%3E\")}.ag-icon-eye-slash:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eeye-slash%3C/title%3E%3Cpath d='M9.304 7.89a15.2 15.2 0 0 1 6.404-1.638c.294-.002.292-.002.584 0 5.956.174 11.328 4.088 13.62 9.748 0 0-1.318 3.178-3.224 5.174a13.6 13.6 0 0 1-2.226 1.874L26.414 25 25 26.414l-2.336-2.336C17.866 26.396 11.776 26.15 7.36 22.96a14.9 14.9 0 0 1-4.168-4.612c-.41-.71-.694-1.336-1.104-2.348 0 0 .898-2.218 2.002-3.718a14.6 14.6 0 0 1 3.442-3.334L5.586 7 7 5.586zm-.3 2.528c-2.038 1.344-3.708 3.246-4.724 5.508L4.248 16c2.46 5.762 9.622 9.064 15.63 7.15q.688-.219 1.342-.516l-.912-.912a6.96 6.96 0 0 1-4.19 1.394c-3.862 0-7-3.136-7-7 0-1.57.52-3.022 1.394-4.19zm14.032 11.204a13.25 13.25 0 0 0 4.684-5.548l.032-.074c-1.984-4.646-6.834-7.798-12.006-7.748-1.712.05-3.386.458-4.922 1.158l1.102 1.102a6.97 6.97 0 0 1 4.192-1.396 7.003 7.003 0 0 1 5.606 11.192zm-11.09-8.262a5.003 5.003 0 0 0 6.928 6.928zm8.342 5.514a5.002 5.002 0 0 0-6.928-6.928z'/%3E%3C/svg%3E\")}.ag-icon-eye:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eeye%3C/title%3E%3Cpath d='M16.292 6.32c5.956.174 11.328 4.086 13.62 9.746 0 0-1.318 3.18-3.224 5.176-4.862 5.088-13.534 5.97-19.328 1.784a14.9 14.9 0 0 1-4.168-4.612c-.41-.71-.694-1.336-1.104-2.348 0 0 .898-2.216 2.002-3.716 2.678-3.64 7.03-5.896 11.618-6.03.294-.004.292-.004.584 0m-.546 2c-4.896.142-9.458 3.202-11.466 7.672l-.032.074c2.46 5.762 9.622 9.066 15.63 7.152 3.458-1.102 6.342-3.738 7.842-7.076l.032-.076C25.768 11.42 20.918 8.27 15.746 8.32m.254.946c3.754 0 6.8 3.048 6.8 6.8 0 3.754-3.046 6.8-6.8 6.8s-6.8-3.046-6.8-6.8c0-3.752 3.046-6.8 6.8-6.8m5 6.768V16c0-2.76-2.24-5-5-5s-5 2.24-5 5v.066c0 2.76 2.24 5 5 5s5-2.24 5-5z'/%3E%3C/svg%3E\")}.ag-icon-filter:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Efilter%3C/title%3E%3Cpath d='M26 8.184c-.066 2.658-4.058 5.154-6.742 7.974a1.05 1.05 0 0 0-.258.682v3.66L13 25c0-2.74.066-5.482-.002-8.222a1.05 1.05 0 0 0-.256-.62C10.026 13.304 6.06 10.61 6 8.184V6h20zM8 8c0 .304.06.612.258.842 2.716 2.854 6.682 5.548 6.742 7.974V21l2-1.5v-2.684c.066-2.658 4.058-5.154 6.742-7.974.198-.23.258-.538.258-.842z'/%3E%3C/svg%3E\")}.ag-icon-first:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Efirst%3C/title%3E%3Cpath d='M24.354 8.708 17.06 16l7.294 7.292-1.416 1.416L14.232 16l8.706-8.708zM9.646 8v16h-2V8z'/%3E%3C/svg%3E\")}.ag-icon-group:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Egroup%3C/title%3E%3Cpath d='M25.128 2.002c2.56.096 4.772 2.292 4.87 4.87a712 712 0 0 1 0 18.256c-.096 2.56-2.292 4.772-4.87 4.87a712 712 0 0 1-18.256 0c-2.558-.096-4.772-2.29-4.87-4.87a712 712 0 0 1 0-18.256c.096-2.56 2.292-4.772 4.87-4.87a712 712 0 0 1 18.256 0M7.006 4c-1.57.02-2.946 1.348-3.004 2.922-.078 6.078-.23 12.16.002 18.234.094 1.484 1.354 2.746 2.84 2.84 6.1.232 12.212.232 18.312 0 1.48-.094 2.746-1.35 2.84-2.84.232-6.1.232-12.212 0-18.312-.094-1.48-1.35-2.746-2.84-2.84C19.11 3.774 13.056 4 7.006 4M14 21h-4v-2h4zm12 0H16v-2h10zm-12-4h-4v-2h4zm12 0H16v-2h10zm-16-4H6v-2h4zm16 0H12v-2h14z'/%3E%3C/svg%3E\")}.ag-icon-last:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Elast%3C/title%3E%3Cpath d='m17.768 16-8.706 8.708-1.416-1.416L14.94 16 7.646 8.708l1.416-1.416zm6.586 8h-2V8h2z'/%3E%3C/svg%3E\")}.ag-icon-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eleft%3C/title%3E%3Cpath d='m17.621 11-2 2h12.586v6H15.621l2 2-4.414 4.414L3.793 16l9.414-9.414zm-11 5 6.586 6.586L14.793 21l-4-4h15.414v-2H10.793l4-4-1.586-1.586z'/%3E%3C/svg%3E\")}.ag-icon-linked:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Elinked%3C/title%3E%3Cpath d='M17.138 13.418a1.03 1.03 0 0 0-.298.658s.125.096.226.178c1.372 1.114 2.033 3.039 1.582 4.796a4.7 4.7 0 0 1-1.205 2.123c-1.145 1.151-2.296 2.294-3.445 3.441-1.241 1.232-3.185 1.691-4.864 1.105-1.546-.54-2.756-1.938-3.048-3.572-.267-1.496.246-3.108 1.319-4.186l.578-.578-.03-.092a10.5 10.5 0 0 1-.452-2.3v-.005c-.776.775-1.621 1.489-2.275 2.396-1.817 2.522-1.643 6.323.706 8.669 1.813 1.811 4.708 2.462 7.171 1.517a6.75 6.75 0 0 0 2.336-1.518l3.427-3.424c1.939-1.954 2.533-5.126 1.294-7.674a6.8 6.8 0 0 0-2.071-2.481l-.003-.002zM21.265 4a6.8 6.8 0 0 0-4.734 1.964l-3.427 3.424c-1.961 1.977-2.52 5.092-1.32 7.619a6.8 6.8 0 0 0 2.098 2.537l.003.002c.32-.32.643-.637.96-.96.167-.172.27-.401.286-.64l-.204-.167c-1.603-1.287-2.215-3.68-1.316-5.616a4.7 4.7 0 0 1 .918-1.32c1.145-1.151 2.296-2.294 3.445-3.441 1.239-1.23 3.178-1.694 4.864-1.105 1.83.639 3.16 2.498 3.12 4.493a4.8 4.8 0 0 1-1.391 3.265l-.578.578.03.092c.235.743.387 1.519.452 2.3v.005c.732-.731 1.521-1.406 2.162-2.244 1.192-1.559 1.643-3.651 1.204-5.575a6.8 6.8 0 0 0-3.98-4.703 6.8 6.8 0 0 0-2.529-.506h-.061z'/%3E%3C/svg%3E\")}.ag-icon-loading:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eloading%3C/title%3E%3Cpath d='M17 29h-2v-8h2zm-3.586-9L7 26.414 5.586 25 12 18.586zm13 5L25 26.414 18.586 20 20 18.586zM29 17h-8v-2h8zm-18 0H3v-2h8zm2.414-5L12 13.414 5.586 7 7 5.586zm13-5L20 13.414 18.586 12 25 5.586zM17 11h-2V3h2z'/%3E%3C/svg%3E\")}.ag-icon-maximize:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='3 3 26 26'%3E%3Ctitle%3Emaximize%3C/title%3E%3Cpath d='m7.54 17.4.1 6.98 6.96.1-2.24-2.24L16 18.6 13.4 16l-3.64 3.64zm16.92-2.8-.1-6.98-6.96-.1 2.24 2.24L16 13.4l2.6 2.6 3.64-3.64z'/%3E%3C/svg%3E\")}.ag-icon-menu:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Emenu%3C/title%3E%3Cpath d='M26 23H6v-2h20zm0-6H6v-2h20zm0-6H6V9h20z'/%3E%3C/svg%3E\")}.ag-icon-menu-alt:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none'%3E%3Cpath fill='%23000' d='M16 18a2 2 0 1 0 0-4 2 2 0 0 0 0 4m0-7a2 2 0 1 0 0-4 2 2 0 0 0 0 4m0 14a2 2 0 1 0 0-4 2 2 0 0 0 0 4'/%3E%3C/svg%3E\")}.ag-icon-minimize:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='3 3 26 26'%3E%3Ctitle%3Eminimize%3C/title%3E%3Cpath d='m14.8 24.26-.1-6.96-6.96-.1 2.24 2.24-3.64 3.64 2.6 2.6 3.64-3.64zm2.4-16.52.1 6.96 6.96.1-2.24-2.24 3.64-3.64-2.6-2.6-3.64 3.64z'/%3E%3C/svg%3E\")}.ag-icon-minus:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.515 7.515c-4.683 4.682-4.683 12.288 0 16.97 4.682 4.683 12.288 4.683 16.97 0 4.683-4.682 4.683-12.288 0-16.97-4.682-4.683-12.288-4.683-16.97 0m1.414 1.414c3.903-3.903 10.239-3.903 14.142 0s3.903 10.239 0 14.142-10.239 3.903-14.142 0-3.903-10.239 0-14.142m-1.414 6.07h16.97v2.002H7.515z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-next:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enext%3C/title%3E%3Cpath d='m21.061 16-8.706 8.708-1.416-1.416L18.233 16l-7.294-7.292 1.416-1.416z'/%3E%3C/svg%3E\")}.ag-icon-none:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enone%3C/title%3E%3Cpath d='m10.044 21.258 4.478-4.198L16 18.444 9 25l-7-6.556 1.478-1.384 4.478 4.198V7h2.088zm14 3.742h-2.088V10.742l-4.478 4.198L16 13.556 23 7q3.5 3.28 7 6.556l-1.478 1.384-4.478-4.198z'/%3E%3C/svg%3E\")}.ag-icon-not-allowed:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enot-allowed%3C/title%3E%3Cpath d='M16.186 3.646c8.188.154 14.898 9.796 11.17 17.78-3.298 7.066-13.932 9.374-19.848 3.87-3.9-3.632-5.076-9.896-2.684-14.708 2.082-4.19 6.588-6.974 11.362-6.942m-.298 1.998c-6.922.132-12.578 8.308-9.33 15.052 3.342 6.934 15.246 7.646 18.932 0 3.076-6.386-1.988-15.1-9.602-15.052m7.596 6.422c2.864 5.33-1.744 13.186-8.306 12.536a8.6 8.6 0 0 1-3.232-.998l-1.266-.706L22.778 10.8q.351.633.706 1.266m-9.422 10.276c3.296 1.028 7.246-1.006 8.216-4.418a6.6 6.6 0 0 0-.056-3.742zm2.104-14.696a8.8 8.8 0 0 1 3.936 1.038l1.266.706L9.27 21.488c-3.018-5.41-.99-13.37 6.318-13.834q.289-.01.578-.008m-.31 2c-4.06.154-7.23 4.614-6.03 8.46l8.16-8.16a6.8 6.8 0 0 0-2.13-.3'/%3E%3C/svg%3E\")}.ag-icon-paste:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Epaste%3C/title%3E%3Cpath d='M20 6.5c0-1-1-3-4-3s-4 2-4 3H8c-2.21 0-4 1.79-4 4v14c0 2.21 1.79 4 4 4h16c2.21 0 4-1.79 4-4v-14c0-2.21-1.79-4-4-4zm-4 .546c.734 0 1.334.572 1.334 1.272S16.734 9.59 16 9.59s-1.334-.572-1.334-1.272.6-1.272 1.334-1.272M24 26.5H8a2 2 0 0 1-2-2v-14a2 2 0 0 1 2-2h2v4h12v-4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2'/%3E%3C/svg%3E\")}.ag-icon-pin:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Epin%3C/title%3E%3Cpath d='m10.78 19.777-4.668-4.666s.032-1 .67-1.87c1.366-1.86 4.052-1.96 6.056-1.572l3.158-3.108c-.7-2.342 3.352-5.046 3.352-5.046l9.166 9.168q-.334.447-.67.894c-1.074 1.426-2.538 2.63-4.272 2.338l-3.32 3.218c.046.344.042.03.118 1.152.144 2.13-.64 4.324-2.632 5.34l-.746.364-4.798-4.798-7.292 7.294-1.416-1.416zm8.24-13.672c-.688.568-1.416 1.45-1.024 2.072l.49.722-4.986 4.988c-1.988-.506-4.346-.636-5.156.614l9.02 9.032q.14-.099.272-.21c1.226-1.08.764-3.04.498-4.9l4.79-4.79s1.47.938 2.936-.776l-6.79-6.79q-.026.019-.05.038'/%3E%3C/svg%3E\")}.ag-icon-pivot:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Epivot%3C/title%3E%3Cpath d='M25.128 2.002c2.56.096 4.772 2.292 4.87 4.87a712 712 0 0 1 0 18.256c-.096 2.56-2.292 4.772-4.87 4.87a712 712 0 0 1-18.256 0c-2.558-.096-4.772-2.29-4.87-4.87a712 712 0 0 1 0-18.256c.096-2.56 2.292-4.772 4.87-4.87a712 712 0 0 1 18.256 0m2.966 7.954H9.892v18.136c5.086.13 10.18.098 15.264-.096 1.48-.094 2.746-1.35 2.84-2.84.192-5.064.226-10.134.098-15.2M3.968 24.1q.015.528.036 1.056c.094 1.484 1.354 2.746 2.84 2.84l1.012.036V24.1zM22 15.414l-.292.294-1.416-1.416L23 11.586l2.708 2.706-1.416 1.416-.292-.294v3.592c-.032 2.604-2.246 4.892-4.872 4.992L15.414 24l.294.292-1.416 1.416L11.586 23l2.706-2.708 1.416 1.416-.322.32c3.372.03 6.578-.164 6.614-3.034zM3.88 18.038c.002 1.346.012 2.694.038 4.04h3.938v-4.04zm.05-6.062a681 681 0 0 0-.044 4.042h3.97v-4.042zm5.962-7.99Q8.449 3.999 7.006 4c-1.57.02-2.946 1.348-3.004 2.922q-.02 1.517-.042 3.034h3.896v-2.02h2.036zm14.244-.016v3.966h3.898q-.017-.546-.038-1.092c-.094-1.48-1.35-2.746-2.84-2.84q-.51-.019-1.02-.034m-8.14-.054q-2.035.022-4.07.048v3.972h4.07zm6.106.008c-1.358-.022-2.714-.026-4.07-.022v4.034h4.07z'/%3E%3C/svg%3E\")}.ag-icon-plus:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.515 7.515c-4.683 4.682-4.683 12.288 0 16.97 4.682 4.683 12.288 4.683 16.97 0 4.683-4.682 4.683-12.288 0-16.97-4.682-4.683-12.288-4.683-16.97 0m1.414 1.414c3.903-3.903 10.239-3.903 14.142 0s3.903 10.239 0 14.142-10.239 3.903-14.142 0-3.903-10.239 0-14.142M15 15l-.001-7.485h2.002L17 15l7.485-.001v2.002L17 17l.001 7.485h-2.002L15 17l-7.485.001v-2.002z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-previous:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eprevious%3C/title%3E%3Cpath d='M21.061 8.708 13.767 16l7.294 7.292-1.416 1.416L10.939 16l8.706-8.708z'/%3E%3C/svg%3E\")}.ag-icon-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eright%3C/title%3E%3Cpath d='m28.207 16-9.414 9.414L14.379 21l2-2H3.793v-6h12.586l-2-2 4.414-4.414zm-11-5 4 4H5.793v2h15.414l-4 4 1.586 1.586L25.379 16l-6.586-6.586z'/%3E%3C/svg%3E\")}.ag-icon-save:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esave%3C/title%3E%3Cpath d='M25.333 16v9.333H6.666V16H3.999v9.333C3.999 26.8 5.199 28 6.666 28h18.667C26.8 28 28 26.8 28 25.333V16zm-8 .893 3.453-3.44 1.88 1.88L15.999 22l-6.667-6.667 1.88-1.88 3.453 3.44V4h2.667v12.893z'/%3E%3C/svg%3E\")}.ag-icon-small-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-down%3C/title%3E%3Cpath d='M24.708 12.355 16 21.061l-8.708-8.706 1.416-1.416L16 18.233l7.292-7.294z'/%3E%3C/svg%3E\")}.ag-icon-small-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-left%3C/title%3E%3Cpath d='M21.061 8.708 13.767 16l7.294 7.292-1.416 1.416L10.939 16l8.706-8.708z'/%3E%3C/svg%3E\")}.ag-icon-small-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-right%3C/title%3E%3Cpath d='m21.061 16-8.706 8.708-1.416-1.416L18.233 16l-7.294-7.292 1.416-1.416z'/%3E%3C/svg%3E\")}.ag-icon-small-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-up%3C/title%3E%3Cpath d='m24.708 19.645-1.416 1.416L16 13.767l-7.292 7.294-1.416-1.416L16 10.939z'/%3E%3C/svg%3E\")}.ag-icon-tick:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etick%3C/title%3E%3Cpath d='M24.708 10.855 13 22.561l-5.708-5.706 1.416-1.416L13 19.733 23.292 9.439z'/%3E%3C/svg%3E\")}.ag-icon-tree-closed:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etree-closed%3C/title%3E%3Cpath d='m21.061 16-8.706 8.708-1.416-1.416L18.233 16l-7.294-7.292 1.416-1.416z'/%3E%3C/svg%3E\")}.ag-icon-tree-indeterminate:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etree-indeterminate%3C/title%3E%3Cpath d='M6 15h20v2H6z'/%3E%3C/svg%3E\")}.ag-icon-tree-open:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etree-open%3C/title%3E%3Cpath d='M24.708 12.355 16 21.061l-8.708-8.706 1.416-1.416L16 18.233l7.292-7.294z'/%3E%3C/svg%3E\")}.ag-icon-unlinked:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eunlinked%3C/title%3E%3Cpath d='M5.35 3.999a.2.2 0 0 0-.14.058c-.388.38-.768.768-1.152 1.152a.21.21 0 0 0-.002.288c7.459 7.506 14.965 14.965 22.447 22.447a.21.21 0 0 0 .288.002q.576-.574 1.151-1.151a.21.21 0 0 0 .002-.288C20.484 19.002 12.979 11.542 5.497 4.06a.2.2 0 0 0-.146-.061zm.611 12.548c-1.933 1.939-2.538 5.119-1.289 7.688a6.79 6.79 0 0 0 4.891 3.672 6.82 6.82 0 0 0 5.893-1.866l1.984-1.984-1.438-1.438-1.986 1.986c-1.486 1.476-3.993 1.81-5.834.629a4.73 4.73 0 0 1-2.024-2.853 4.76 4.76 0 0 1 1.241-4.393l1.986-1.986-1.438-1.438-1.984 1.984zM21.273 3.999a6.78 6.78 0 0 0-4.727 1.963l-1.984 1.984L16 9.384l1.985-1.985a4.74 4.74 0 0 1 2.776-1.338c1.974-.224 4.045.926 4.845 2.834.712 1.699.329 3.778-1.004 5.12L22.616 16l1.439 1.438q1-1 2-2c2.012-2.031 2.557-5.368 1.112-7.982-1.144-2.07-3.432-3.441-5.834-3.459h-.061z'/%3E%3C/svg%3E\")}.ag-icon-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Easc%3C/title%3E%3Cpath d='m15 10.621-4.292 4.294-1.416-1.416L16 6.793l6.708 6.706-1.416 1.416L17 10.621v14.586h-2z'/%3E%3C/svg%3E\")}.ag-icon-grip:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Egrip%3C/title%3E%3Cpath d='M8 24H6v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zM8 18H6v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zM8 12H6V8h2zm6 0h-2V8h2zm6 0h-2V8h2zm6 0h-2V8h2z'/%3E%3C/svg%3E\")}.ag-icon-settings:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='%23000' d='M30 8h-4.1c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2v2h14.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30zm-9 4c-1.7 0-3-1.3-3-3s1.3-3 3-3 3 1.3 3 3-1.3 3-3 3M2 24h4.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30v-2H15.9c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2zm9-4c1.7 0 3 1.3 3 3s-1.3 3-3 3-3-1.3-3-3 1.3-3 3-3'/%3E%3C/svg%3E\")}.ag-icon-column-arrow:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M11 4a1 1 0 0 1 1 1v22a1 1 0 1 1-2 0V5a1 1 0 0 1 1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 13a1 1 0 0 1 1-1h23.5a1 1 0 1 1 0 2H3a1 1 0 0 1-1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 4h18v24H2zm2 2v20h14V6zM26.793 13 23 9.207l1.414-1.414L29.621 13l-5.207 5.207L23 16.793z' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-un-pin:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='m6.112 15.111 3.272 3.271 1.436-1.402-2.476-2.479c.81-1.25 3.168-1.12 5.156-.614l4.986-4.988-.49-.722c-.392-.622.336-1.504 1.024-2.072l.008-.007.01-.006.032-.025 1.447 1.447 1.432-1.397-2.601-2.602s-4.052 2.704-3.352 5.046l-3.158 3.108c-2.004-.388-4.69-.288-6.056 1.572-.638.87-.67 1.87-.67 1.87m.581 11.582.014.014 5.502-5.501 4.783 4.783.746-.364c1.992-1.016 2.776-3.21 2.632-5.34-.055-.805-.068-.87-.088-.97-.008-.04-.017-.085-.03-.182l3.32-3.218c1.734.292 3.198-.912 4.272-2.338q.337-.447.67-.894l-.001-.001-.007-.007-.007-.007-.007-.007-3.87-3.87 1.585-1.584-1.414-1.414-14.381 14.38-1.237 1.209-5.69 5.687 1.417 1.416zM23.21 10.206l2.65 2.651c-1.465 1.714-2.935.776-2.935.776l-4.79 4.79q.041.291.087.583c.257 1.676.513 3.35-.585 4.317a4 4 0 0 1-.272.21l-3.739-3.744z' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-pinned-top:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='m16.708 10.878 8.708 8.706L24 21l-6.292-6.294V27h-2V14.706L9.416 21 8 19.584q4.348-4.344 8.691-8.69zM25 6H8v2h17z'/%3E%3C/svg%3E\")}.ag-icon-pinned-bottom:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M16.708 22.122 8 13.416 9.416 12l6.292 6.294V6h2v12.294L24 12l1.416 1.416-8.691 8.69zM7.416 28h17v-2h-17z'/%3E%3C/svg%3E\")}.ag-icon-chevron-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M3.479 10.521a.75.75 0 0 1 0-1.06l4-4a.75.75 0 0 1 1.06 0l4 4a.75.75 0 0 1-1.06 1.06l-3.47-3.47-3.47 3.47a.75.75 0 0 1-1.06 0' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M12.521 5.461a.75.75 0 0 1 0 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 1.06-1.06l3.47 3.47 3.47-3.47a.75.75 0 0 1 1.06 0' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M10.53 12.512a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 0-1.06l4-4a.75.75 0 0 1 1.06 1.06l-3.47 3.47 3.47 3.47a.75.75 0 0 1 0 1.06' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M5.47 3.47a.75.75 0 0 1 1.06 0l4 4a.75.75 0 0 1 0 1.06l-4 4a.75.75 0 0 1-1.06-1.06L8.94 8 5.47 4.53a.75.75 0 0 1 0-1.06' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-filter-add:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M19.834 8H8c0 .304.06.612.258.842 2.716 2.854 6.682 5.548 6.742 7.974V21l2-1.5v-2.684c.056-2.267 2.968-4.417 5.49-6.75v3.087c-1.081.974-2.245 1.968-3.232 3.005a1.05 1.05 0 0 0-.258.682v3.66L13 25c0-2.74.066-5.482-.002-8.222a1.05 1.05 0 0 0-.256-.62C10.026 13.304 6.06 10.61 6 8.184V6h13.834z'/%3E%3Cpath fill='currentColor' d='M26 6h2.946v2.002H26v3.313h-2.002V8.002h-2.946V6h2.946V3.04H26z'/%3E%3C/svg%3E\")}.ag-icon-edit:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M23.182 5a3.82 3.82 0 0 1 2.83 6.383l-.131.137-2.09 2.088a1 1 0 0 1-.084.099 1 1 0 0 1-.098.084L12.533 24.869a3 3 0 0 1-1.245.746l-4.353 1.32-.003.002a1.5 1.5 0 0 1-1.87-1.867l.003-.004 1.32-4.352v-.003l.06-.174c.13-.344.321-.661.565-.936l.126-.135L18.209 8.39a1 1 0 0 1 .18-.181l2.092-2.09.137-.132A3.82 3.82 0 0 1 23.182 5M8.548 20.883a1 1 0 0 0-.25.415l-1.049 3.451 3.457-1.048.114-.042q.17-.076.301-.206l10.458-10.46-2.572-2.572zM23.182 7c-.482 0-.946.19-1.287.531v.001l-1.474 1.475 2.572 2.572 1.474-1.474.121-.133A1.82 1.82 0 0 0 23.182 7'/%3E%3C/svg%3E\")}"}),_h=qs({feature:"iconSet",css:".ag-icon-aggregation:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M24 6H8v2l8 8-8 8v2h16v-2H11l8-8-8-8h13z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-arrows:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.515 11.171 2.687 16l4.828 4.829-1.414 1.414L-.142 16l6.243-6.243zm16.97 0 1.414-1.414L32.142 16l-6.243 6.243-1.414-1.414L29.313 16zM16.028 13.2l2.829 2.828-2.829 2.829-2.828-2.829zm-4.857 11.285L16 29.313l4.829-4.828 1.414 1.414L16 32.142l-6.243-6.243zm0-16.97L9.757 6.101 16-.142l6.243 6.243-1.414 1.414L16 2.687z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-asc:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m5.333 16 1.88 1.88 7.453-7.44v16.227h2.667V10.44l7.44 7.453L26.666 16 15.999 5.333 5.332 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-cancel:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M16 2.667A13.32 13.32 0 0 0 2.667 16c0 7.373 5.96 13.333 13.333 13.333S29.333 23.373 29.333 16 23.373 2.667 16 2.667m6.667 18.12-1.88 1.88L16 17.88l-4.787 4.787-1.88-1.88L14.12 16l-4.787-4.787 1.88-1.88L16 14.12l4.787-4.787 1.88 1.88L17.88 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-chart:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Echart%3C/title%3E%3Cg fill='%23000' fill-rule='nonzero'%3E%3Cpath d='M14 7h4v18h-4zM8 17h4v8H8zM20 13h4v12h-4z'/%3E%3C/g%3E%3C/svg%3E\")}.ag-icon-color-picker:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M23.907 17.587 10.574 4.254l-1.88 1.88 3.173 3.173-8.28 8.28 10.16 10.16zm-16.547 0 6.387-6.387 6.387 6.387zm18.387 2s-2.667 2.893-2.667 4.667c0 1.467 1.2 2.667 2.667 2.667s2.667-1.2 2.667-2.667c0-1.773-2.667-4.667-2.667-4.667' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-columns:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M26 25H6V7h20zM12 11H8v12h4zm6 0h-4v12h4zm6 12V11h-4v12z' style='fill-rule:nonzero' transform='translate(0 -1)'/%3E%3C/svg%3E\")}.ag-icon-contracted:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m12 6 10 10-10 10-2-2 8-8-8-8z'/%3E%3C/svg%3E\")}.ag-icon-copy:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M22 1.333H6A2.675 2.675 0 0 0 3.333 4v18.667H6V4h16zm4 5.334H11.333a2.675 2.675 0 0 0-2.667 2.667v18.667c0 1.467 1.2 2.667 2.667 2.667H26c1.467 0 2.667-1.2 2.667-2.667V9.334c0-1.467-1.2-2.667-2.667-2.667M26 28H11.333V9.333H26z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-cross:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M15.984 13.894 27.05 2.828l2.122 2.122-11.066 11.066 11.066 11.066-2.122 2.12-11.066-11.066L4.918 29.202l-2.12-2.12 11.066-11.066L2.798 4.95l2.12-2.122z'/%3E%3C/svg%3E\")}.ag-icon-csv:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='translate(3.934 -.054)scale(.06285)'/%3E%3Cpath d='M.688-.226a.2.2 0 0 1-.017.074.28.28 0 0 1-.145.14.412.412 0 0 1-.234.013.28.28 0 0 1-.202-.168.468.468 0 0 1-.04-.19q0-.086.025-.155a.319.319 0 0 1 .182-.191.4.4 0 0 1 .134-.025q.087 0 .155.035a.3.3 0 0 1 .104.085.17.17 0 0 1 .036.097.06.06 0 0 1-.018.044.06.06 0 0 1-.042.019.06.06 0 0 1-.042-.013.2.2 0 0 1-.031-.046.2.2 0 0 0-.066-.079.16.16 0 0 0-.095-.027.17.17 0 0 0-.142.068.3.3 0 0 0-.053.193.4.4 0 0 0 .023.139.2.2 0 0 0 .067.083.2.2 0 0 0 .1.027q.063 0 .106-.031a.2.2 0 0 0 .065-.091.2.2 0 0 1 .023-.046q.014-.018.044-.018a.06.06 0 0 1 .044.018.06.06 0 0 1 .019.045' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 7.122 25.977)'/%3E%3Cpath d='M.622-.215a.2.2 0 0 1-.033.117.23.23 0 0 1-.098.081.4.4 0 0 1-.153.029.34.34 0 0 1-.175-.04.23.23 0 0 1-.079-.077.17.17 0 0 1-.031-.093q0-.027.019-.045a.06.06 0 0 1 .046-.019.06.06 0 0 1 .039.014.1.1 0 0 1 .027.044.3.3 0 0 0 .03.057q.015.023.044.038.03.015.076.015.065 0 .105-.03a.09.09 0 0 0 .04-.075.08.08 0 0 0-.022-.058.14.14 0 0 0-.056-.034 1 1 0 0 0-.092-.025.7.7 0 0 1-.129-.042.2.2 0 0 1-.083-.066.17.17 0 0 1-.03-.104q0-.058.032-.105a.2.2 0 0 1 .093-.07.4.4 0 0 1 .144-.025q.066 0 .114.016a.3.3 0 0 1 .08.044.2.2 0 0 1 .046.057q.015.03.015.058a.07.07 0 0 1-.018.046.06.06 0 0 1-.046.021q-.025 0-.038-.012a.2.2 0 0 1-.028-.041.2.2 0 0 0-.047-.063Q.387-.625.326-.625a.15.15 0 0 0-.09.025q-.035.024-.035.059 0 .021.012.037a.1.1 0 0 0 .032.027.4.4 0 0 0 .111.036q.06.015.11.031.048.018.083.042a.2.2 0 0 1 .054.062.2.2 0 0 1 .019.091' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 13.339 25.977)'/%3E%3Cpath d='m.184-.633.162.48.163-.483q.013-.038.019-.053a.062.062 0 0 1 .061-.039q.018 0 .034.009a.1.1 0 0 1 .025.025q.009.015.009.031L.654-.64l-.007.025-.009.024-.173.468-.019.051a.2.2 0 0 1-.021.042.1.1 0 0 1-.033.03.1.1 0 0 1-.049.012.1.1 0 0 1-.05-.011A.1.1 0 0 1 .26-.03a.2.2 0 0 1-.021-.042L.22-.123.05-.587.041-.612.033-.638.03-.662q0-.025.02-.046a.07.07 0 0 1 .05-.02q.037 0 .053.023.015.023.031.072' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 18.94 25.977)'/%3E%3C/svg%3E\")}.ag-icon-cut:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M13.775 15.198 3.835 2.945a1.501 1.501 0 0 1 2.33-1.89l14.997 18.488A6.003 6.003 0 0 1 29.657 25c0 3.311-2.688 6-6 6s-6-2.689-6-6c0-1.335.437-2.569 1.176-3.566l-3.127-3.855-3.001 3.7A5.97 5.97 0 0 1 14 25c0 3.311-2.689 6-6 6s-6-2.689-6-6a6.003 6.003 0 0 1 8.315-5.536zm9.882 6.702a3.1 3.1 0 0 0-3.1 3.1c0 1.711 1.389 3.1 3.1 3.1s3.1-1.389 3.1-3.1-1.389-3.1-3.1-3.1M8 21.95a3.05 3.05 0 1 0 .001 6.101A3.05 3.05 0 0 0 8 21.95m9.63-11.505 1.932 2.381 8.015-9.881a1.5 1.5 0 0 0-2.329-1.89z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-desc:before,.ag-icon-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m26.667 16-1.88-1.88-7.453 7.44V5.333h-2.667V21.56l-7.44-7.453L5.334 16l10.667 10.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-excel:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='translate(3.934 -.054)scale(.06285)'/%3E%3Cpath d='m.052-.139.16-.234-.135-.208a.4.4 0 0 1-.028-.052.1.1 0 0 1-.01-.042.05.05 0 0 1 .018-.037.07.07 0 0 1 .045-.016q.03 0 .047.018a1 1 0 0 1 .047.066l.107.174.115-.174.024-.038.019-.026.021-.015a.1.1 0 0 1 .027-.005.06.06 0 0 1 .044.016.05.05 0 0 1 .018.039q0 .033-.038.089l-.141.211.152.234a.3.3 0 0 1 .03.051.1.1 0 0 1 .009.038.1.1 0 0 1-.008.031.1.1 0 0 1-.024.023.1.1 0 0 1-.034.008.1.1 0 0 1-.035-.008.1.1 0 0 1-.023-.022L.427-.067.301-.265l-.134.204-.022.034-.016.019a.1.1 0 0 1-.022.015.1.1 0 0 1-.03.005.06.06 0 0 1-.044-.016.06.06 0 0 1-.017-.047q0-.036.036-.088' style='fill-rule:nonzero' transform='matrix(17.82892 0 0 16.50777 10.371 25.928)'/%3E%3C/svg%3E\")}.ag-icon-expanded:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M20 26 10 16 20 6l2 2-8 8 8 8z'/%3E%3C/svg%3E\")}.ag-icon-eye-slash:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eeye-slash%3C/title%3E%3Cpath fill='%23000' fill-rule='nonzero' d='M8.95 10.364 7 8.414 8.414 7l2.32 2.32A13.2 13.2 0 0 1 16.5 8c5.608 0 10.542 3.515 12.381 8.667L29 17l-.119.333a13 13 0 0 1-4.255 5.879l1.466 1.466-1.414 1.414-1.754-1.753A13.2 13.2 0 0 1 16.5 26c-5.608 0-10.542-3.515-12.381-8.667L4 17l.119-.333a13 13 0 0 1 4.83-6.303m1.445 1.445A11.02 11.02 0 0 0 6.148 17c1.646 4.177 5.728 7 10.352 7 1.76 0 3.441-.409 4.94-1.146l-1.878-1.878A5.06 5.06 0 0 1 16.5 22c-2.789 0-5.05-2.239-5.05-5 0-1.158.398-2.223 1.065-3.07zm1.855-.974 1.794 1.795A5.07 5.07 0 0 1 16.5 12c2.789 0 5.05 2.239 5.05 5 0 .9-.24 1.745-.661 2.474l2.305 2.306A11 11 0 0 0 26.852 17c-1.646-4.177-5.728-7-10.352-7-1.495 0-2.933.295-4.25.835'/%3E%3C/svg%3E\")}.ag-icon-eye:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M16.5 23c4.624 0 8.706-2.823 10.352-7-1.646-4.177-5.728-7-10.352-7s-8.706 2.823-10.352 7c1.646 4.177 5.728 7 10.352 7M4.119 15.667C5.958 10.515 10.892 7 16.5 7s10.542 3.515 12.381 8.667L29 16l-.119.333C27.042 21.485 22.108 25 16.5 25S5.958 21.485 4.119 16.333L4 16zM16.5 21c2.789 0 5.049-2.239 5.049-5s-2.26-5-5.049-5-5.049 2.239-5.049 5 2.26 5 5.049 5' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-filter:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m28 8-8 8v5l-6 6V16L6 8V6h22zM9 8l7 7v7l2-2v-5l7-7z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-first:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M24.273 22.12 18.153 16l6.12-6.12L22.393 8l-8 8 8 8zM7.727 8h2.667v16H7.727z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-group:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M14 7v1H9V7zm0-3v1H5.001V4zm-7 7H5v-1h2zm0-3H5V7h2zM3 5H1V4h2zm11 5v1H9v-1zm-7 4H5v-1h2zm7-1v1H9v-1z' style='fill-rule:nonzero' transform='matrix(2 0 0 2 0 -2)'/%3E%3C/svg%3E\")}.ag-icon-last:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m7.727 9.88 6.12 6.12-6.12 6.12L9.607 24l8-8-8-8zM21.607 8h2.667v16h-2.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M26.667 14.667H10.44l7.453-7.453L16 5.334 5.333 16.001 16 26.668l1.88-1.88-7.44-7.453h16.227z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-linked:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M5.2 16a4.136 4.136 0 0 1 4.133-4.133h5.333V9.334H9.333a6.67 6.67 0 0 0-6.667 6.667 6.67 6.67 0 0 0 6.667 6.667h5.333v-2.533H9.333A4.136 4.136 0 0 1 5.2 16.002zm5.467 1.333h10.667v-2.667H10.667zm12-8h-5.333v2.533h5.333a4.136 4.136 0 0 1 4.133 4.133 4.136 4.136 0 0 1-4.133 4.133h-5.333v2.533h5.333a6.67 6.67 0 0 0 6.667-6.667 6.67 6.67 0 0 0-6.667-6.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-loading:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M17 29h-2v-8h2zm-3.586-9L7 26.414 5.586 25 12 18.586zm13 5L25 26.414 18.586 20 20 18.586zM29 17h-8v-2h8zm-18 0H3v-2h8zm2.414-5L12 13.414 5.586 7 7 5.586zm13-5L20 13.414 18.586 12 25 5.586zM17 11h-2V3h2z' style='fill-rule:nonzero' transform='translate(-3.692 -3.692)scale(1.23077)'/%3E%3C/svg%3E\")}.ag-icon-maximize:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M14 30H2V18h2.828v7.05l8.254-8.252 2.12 2.12-8.252 8.254H14zm4-28h12v12h-2.828V6.95l-8.254 8.252-2.12-2.12 8.252-8.254H18z'/%3E%3C/svg%3E\")}.ag-icon-menu:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M20 13H0v-2h20zm0-6H0V5h20zm0-6H0v-2h20z' style='fill-rule:nonzero' transform='translate(6 9)'/%3E%3C/svg%3E\")}.ag-icon-menu-alt:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='%23000' d='M16 19a3 3 0 1 0 0-6 3 3 0 0 0 0 6M16 11a3 3 0 1 0 0-6 3 3 0 0 0 0 6M16 27a3 3 0 1 0 0-6 3 3 0 0 0 0 6'/%3E%3C/svg%3E\")}.ag-icon-minimize:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M2 18h12v12h-2.828v-7.05l-8.254 8.252-2.12-2.12 8.252-8.254H2zm28-4H18V2h2.828v7.05L29.082.798l2.12 2.12-8.252 8.254H30z'/%3E%3C/svg%3E\")}.ag-icon-minus:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6.572 6.572a13.32 13.32 0 0 0 0 18.856 13.32 13.32 0 0 0 18.856 0 13.32 13.32 0 0 0 0-18.856 13.32 13.32 0 0 0-18.856 0m17.527 8.099v2.658H7.901v-2.658z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-next:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M10.94 6 9.06 7.88 17.167 16 9.06 24.12 10.94 26l10-10z' style='fill-rule:nonzero' transform='translate(1)'/%3E%3C/svg%3E\")}.ag-icon-none:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enone%3C/title%3E%3Cg fill='%23000' fill-rule='nonzero'%3E%3Cpath d='M23.708 14.645 16 6.939l-7.708 7.706 1.416 1.416L16 9.767l6.292 6.294zM23.708 20.355 16 28.061l-7.708-7.706 1.416-1.416L16 25.233l6.292-6.294z'/%3E%3C/g%3E%3C/svg%3E\")}.ag-icon-not-allowed:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M16 2.667C8.64 2.667 2.667 8.64 2.667 16S8.64 29.333 16 29.333 29.333 23.36 29.333 16 23.36 2.667 16 2.667M5.333 16c0-5.893 4.773-10.667 10.667-10.667 2.467 0 4.733.84 6.533 2.253L7.586 22.533A10.54 10.54 0 0 1 5.333 16M16 26.667c-2.467 0-4.733-.84-6.533-2.253L24.414 9.467A10.54 10.54 0 0 1 26.667 16c0 5.893-4.773 10.667-10.667 10.667' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-paste:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M25.334 4H19.76C19.2 2.453 17.733 1.333 16 1.333S12.8 2.453 12.24 4H6.667A2.675 2.675 0 0 0 4 6.667V28c0 1.467 1.2 2.667 2.667 2.667h18.667c1.467 0 2.667-1.2 2.667-2.667V6.667C28.001 5.2 26.801 4 25.334 4M16 4c.733 0 1.333.6 1.333 1.333s-.6 1.333-1.333 1.333-1.333-.6-1.333-1.333S15.267 4 16 4m9.333 24H6.666V6.667h2.667v4h13.333v-4h2.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-pin:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m10.78 19.777-4.668-4.666s.032-1 .67-1.87c1.366-1.86 4.052-1.96 6.056-1.572l3.158-3.108c-.7-2.342 3.352-5.046 3.352-5.046l9.166 9.168q-.334.447-.67.894c-1.074 1.426-2.538 2.63-4.272 2.338l-3.32 3.218c.046.344.042.03.118 1.152.144 2.13-.64 4.324-2.632 5.34l-.746.364-4.798-4.798-7.292 7.294-1.416-1.416zm8.24-13.672c-.688.568-1.416 1.45-1.024 2.072l.49.722-4.986 4.988c-1.988-.506-4.346-.636-5.156.614l9.02 9.032q.14-.099.272-.21c1.226-1.08.764-3.04.498-4.9l4.79-4.79s1.47.938 2.936-.776l-6.79-6.79q-.026.019-.05.038' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-pivot:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M25.128 2.002c2.56.096 4.772 2.292 4.87 4.87a712 712 0 0 1 0 18.256c-.096 2.56-2.292 4.772-4.87 4.87a712 712 0 0 1-18.256 0c-2.558-.096-4.772-2.29-4.87-4.87a712 712 0 0 1 0-18.256c.096-2.56 2.292-4.772 4.87-4.87a712 712 0 0 1 18.256 0m2.966 7.954H9.892v18.136c5.086.13 10.18.098 15.264-.096 1.48-.094 2.746-1.35 2.84-2.84.192-5.064.226-10.134.098-15.2M3.968 24.1q.015.528.036 1.056c.094 1.484 1.354 2.746 2.84 2.84l1.012.036V24.1zM22 15.414l-.292.294-1.416-1.416L23 11.586l2.708 2.706-1.416 1.416-.292-.294v3.592c-.032 2.604-2.246 4.892-4.872 4.992L15.414 24l.294.292-1.416 1.416L11.586 23l2.706-2.708 1.416 1.416-.322.32c3.372.03 6.578-.164 6.614-3.034zM3.88 18.038c.002 1.346.012 2.694.038 4.04h3.938v-4.04zm.05-6.062a681 681 0 0 0-.044 4.042h3.97v-4.042zm5.962-7.99Q8.449 3.999 7.006 4c-1.57.02-2.946 1.348-3.004 2.922q-.02 1.517-.042 3.034h3.896v-2.02h2.036zm14.244-.016v3.966h3.898q-.017-.546-.038-1.092c-.094-1.48-1.35-2.746-2.84-2.84q-.51-.019-1.02-.034m-8.14-.054q-2.035.022-4.07.048v3.972h4.07zm6.106.008a213 213 0 0 0-4.07-.022v4.034h4.07z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-plus:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6.572 6.572a13.32 13.32 0 0 0 0 18.856 13.32 13.32 0 0 0 18.856 0 13.32 13.32 0 0 0 0-18.856 13.32 13.32 0 0 0-18.856 0m17.527 8.099v2.658h-6.77v6.77h-2.658v-6.77h-6.77v-2.658h6.77v-6.77h2.658v6.77z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-previous:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M21.94 7.88 20.06 6l-10 10 10 10 1.88-1.88L13.833 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m16 5.333-1.88 1.88 7.44 7.453H5.333v2.667H21.56l-7.44 7.453 1.88 1.88 10.667-10.667L16 5.332z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-save:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M15.708 2.355 8 10.061.292 2.355 1.708.939 8 7.233 14.292.939z' style='fill-rule:nonzero' transform='translate(8 14)'/%3E%3Cpath d='M5 26h22v2H5zM15 4h2v18h-2z'/%3E%3C/svg%3E\")}.ag-icon-small-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.334 10.667 16 21.334l8.667-10.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-small-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M21.333 7.334 10.666 16l10.667 8.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-small-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M10.667 24.666 21.334 16 10.667 7.333z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-small-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.334 21.333 16 10.666l8.667 10.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-tick:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M11.586 22.96 27.718 6.828 29.84 8.95 11.586 27.202 2.4 18.016l2.12-2.122z'/%3E%3C/svg%3E\")}.ag-icon-tree-closed:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m11.94 6-1.88 1.88L18.167 16l-8.107 8.12L11.94 26l10-10z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-tree-indeterminate:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6 13.5h20v3H6z'/%3E%3C/svg%3E\")}.ag-icon-tree-open:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M24.12 9.06 16 17.167 7.88 9.06 6 10.94l10 10 10-10z' style='fill-rule:nonzero' transform='translate(0 1)'/%3E%3C/svg%3E\")}.ag-icon-unlinked:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M22.667 9.333h-5.333v2.533h5.333a4.136 4.136 0 0 1 4.133 4.133c0 1.907-1.307 3.507-3.08 3.973l1.947 1.947c2.173-1.107 3.667-3.32 3.667-5.92a6.67 6.67 0 0 0-6.667-6.667zm-1.334 5.334h-2.92l2.667 2.667h.253zM2.667 5.693 6.814 9.84A6.65 6.65 0 0 0 2.667 16a6.67 6.67 0 0 0 6.667 6.667h5.333v-2.533H9.334a4.136 4.136 0 0 1-4.133-4.133c0-2.12 1.613-3.867 3.68-4.093l2.76 2.76h-.973v2.667h3.64l3.027 3.027v2.307h2.307l5.347 5.333 1.68-1.68L4.362 4.002 2.669 5.695z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m5.333 16 1.88 1.88 7.453-7.44v16.227h2.667V10.44l7.44 7.453L26.666 16 15.999 5.333 5.332 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-grip:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M8 24H6v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zM8 18H6v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zM8 12H6V8h2zm6 0h-2V8h2zm6 0h-2V8h2zm6 0h-2V8h2z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-settings:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='%23000' d='M30 8h-4.1c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2v2h14.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30zm-9 4c-1.7 0-3-1.3-3-3s1.3-3 3-3 3 1.3 3 3-1.3 3-3 3M2 24h4.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30v-2H15.9c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2zm9-4c1.7 0 3 1.3 3 3s-1.3 3-3 3-3-1.3-3-3 1.3-3 3-3'/%3E%3C/svg%3E\")}.ag-icon-column-arrow:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M11 4a1 1 0 0 1 1 1v22a1 1 0 1 1-2 0V5a1 1 0 0 1 1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 13a1 1 0 0 1 1-1h23.5a1 1 0 1 1 0 2H3a1 1 0 0 1-1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 4h18v24H2zm2 2v20h14V6zM26.793 13 23 9.207l1.414-1.414L29.621 13l-5.207 5.207L23 16.793z' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-un-pin:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='m6.112 15.111 3.272 3.271 1.436-1.402-2.476-2.479c.81-1.25 3.168-1.12 5.156-.614l4.986-4.988-.49-.722c-.392-.622.336-1.504 1.024-2.072l.008-.007.01-.006.032-.025 1.447 1.447 1.432-1.397-2.601-2.602s-4.052 2.704-3.352 5.046l-3.158 3.108c-2.004-.388-4.69-.288-6.056 1.572-.638.87-.67 1.87-.67 1.87m.581 11.582.014.014 5.502-5.501 4.783 4.783.746-.364c1.992-1.016 2.776-3.21 2.632-5.34-.055-.805-.068-.87-.088-.97-.008-.04-.017-.085-.03-.182l3.32-3.218c1.734.292 3.198-.912 4.272-2.338q.337-.447.67-.894l-.001-.001-.007-.007-.007-.007-.007-.007-3.87-3.87 1.585-1.584-1.414-1.414-14.381 14.38-1.237 1.209-5.69 5.687 1.417 1.416zM23.21 10.206l2.65 2.651c-1.465 1.714-2.935.776-2.935.776l-4.79 4.79q.041.291.087.583c.257 1.676.513 3.35-.585 4.317a4 4 0 0 1-.272.21l-3.739-3.744z' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-pinned-top:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='m16.708 10.878 8.708 8.706L24 21l-6.292-6.294V27h-2V14.706L9.416 21 8 19.584q4.348-4.344 8.691-8.69zM25 6H8v2h17z'/%3E%3C/svg%3E\")}.ag-icon-pinned-bottom:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M16.708 22.122 8 13.416 9.416 12l6.292 6.294V6h2v12.294L24 12l1.416 1.416-8.691 8.69zM7.416 28h17v-2h-17z'/%3E%3C/svg%3E\")}.ag-icon-chevron-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M3.479 10.521a.75.75 0 0 1 0-1.06l4-4a.75.75 0 0 1 1.06 0l4 4a.75.75 0 0 1-1.06 1.06l-3.47-3.47-3.47 3.47a.75.75 0 0 1-1.06 0' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M12.521 5.461a.75.75 0 0 1 0 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 1.06-1.06l3.47 3.47 3.47-3.47a.75.75 0 0 1 1.06 0' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M10.53 12.512a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 0-1.06l4-4a.75.75 0 0 1 1.06 1.06l-3.47 3.47 3.47 3.47a.75.75 0 0 1 0 1.06' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M5.47 3.47a.75.75 0 0 1 1.06 0l4 4a.75.75 0 0 1 0 1.06l-4 4a.75.75 0 0 1-1.06-1.06L8.94 8 5.47 4.53a.75.75 0 0 1 0-1.06' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-filter-add:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M19.834 8H8c0 .304.06.612.258.842 2.716 2.854 6.682 5.548 6.742 7.974V21l2-1.5v-2.684c.056-2.267 2.968-4.417 5.49-6.75v3.087c-1.081.974-2.245 1.968-3.232 3.005a1.05 1.05 0 0 0-.258.682v3.66L13 25c0-2.74.066-5.482-.002-8.222a1.05 1.05 0 0 0-.256-.62C10.026 13.304 6.06 10.61 6 8.184V6h13.834z'/%3E%3Cpath fill='currentColor' d='M26 6h2.946v2.002H26v3.313h-2.002V8.002h-2.946V6h2.946V3.04H26z'/%3E%3C/svg%3E\")}.ag-icon-edit:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M6.222 25.778h1.611l14.834-14.811-1.611-1.611-14.834 14.81zM4 28v-4.733L22.644 4.656a2.26 2.26 0 0 1 1.567-.634q.423 0 .833.167.412.166.734.478l1.589 1.6q.333.322.483.733t.15.822q0 .423-.161.839-.162.416-.472.728L8.733 28zm17.856-17.833-.8-.811 1.61 1.61z'/%3E%3C/svg%3E\")}"}),Yh=qs({feature:"iconSet",css:".ag-icon-aggregation:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eaggregation%3C/title%3E%3Cpath d='M24 5.333H8V8l8.667 8L8 24v2.667h16v-4h-9.333L21.334 16l-6.667-6.667H24z'/%3E%3C/svg%3E\")}.ag-icon-arrows:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Earrows%3C/title%3E%3Cpath d='M13.333 11.556h5.333V8h3.556L16 1.778 9.778 8h3.556zm-1.777 1.777H8V9.777l-6.222 6.222L8 22.221v-3.556h3.556zM30.222 16 24 9.778v3.556h-3.556v5.333H24v3.556l6.222-6.222zm-11.555 4.444h-5.333V24H9.778L16 30.222 22.222 24h-3.556z'/%3E%3C/svg%3E\")}.ag-icon-asc:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Easc%3C/title%3E%3Cpath d='m5.333 16 1.88 1.88 7.453-7.44v16.227h2.667V10.44l7.44 7.453L26.666 16 15.999 5.333z'/%3E%3C/svg%3E\")}.ag-icon-cancel:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecancel%3C/title%3E%3Cpath d='M16 2.667C8.627 2.667 2.667 8.627 2.667 16S8.627 29.333 16 29.333 29.333 23.373 29.333 16 23.373 2.667 16 2.667m6.667 18.12-1.88 1.88L16 17.88l-4.787 4.787-1.88-1.88L14.12 16l-4.787-4.787 1.88-1.88L16 14.12l4.787-4.787 1.88 1.88L17.88 16z'/%3E%3C/svg%3E\")}.ag-icon-chart:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Echart%3C/title%3E%3Cpath d='M6.667 12.267h4v13.067h-4zm7.466-5.6h3.733v18.667h-3.733zM21.6 17.333h3.733v8H21.6z'/%3E%3C/svg%3E\")}.ag-icon-color-picker:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecolor-picker%3C/title%3E%3Cpath d='M23.907 17.587 10.574 4.254l-1.88 1.88 3.173 3.173-8.28 8.28 10.16 10.16zm-16.547 0 6.387-6.387 6.387 6.387H7.361zm18.387 2s-2.667 2.893-2.667 4.667c0 1.467 1.2 2.667 2.667 2.667s2.667-1.2 2.667-2.667c0-1.773-2.667-4.667-2.667-4.667'/%3E%3C/svg%3E\")}.ag-icon-columns:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecolumns%3C/title%3E%3Cpath d='M5.333 10.667h5.333V5.334H5.333zm8 16h5.333v-5.333h-5.333zm-8 0h5.333v-5.333H5.333zm0-8h5.333v-5.333H5.333zm8 0h5.333v-5.333h-5.333zm8-13.334v5.333h5.333V5.333zm-8 5.334h5.333V5.334h-5.333zm8 8h5.333v-5.333h-5.333zm0 8h5.333v-5.333h-5.333z'/%3E%3C/svg%3E\")}.ag-icon-contracted:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Econtracted%3C/title%3E%3Cpath d='m12.94 8-1.88 1.88L17.167 16l-6.107 6.12L12.94 24l8-8z'/%3E%3C/svg%3E\")}.ag-icon-copy:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecopy%3C/title%3E%3Cpath d='M22 1.333H6A2.675 2.675 0 0 0 3.333 4v18.667H6V4h16zm4 5.334H11.333a2.675 2.675 0 0 0-2.667 2.667v18.667c0 1.467 1.2 2.667 2.667 2.667H26c1.467 0 2.667-1.2 2.667-2.667V9.334c0-1.467-1.2-2.667-2.667-2.667M26 28H11.333V9.333H26z'/%3E%3C/svg%3E\")}.ag-icon-cross:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Ecross%3C/title%3E%3Cpath d='m25.333 8.547-1.88-1.88L16 14.12 8.547 6.667l-1.88 1.88L14.12 16l-7.453 7.453 1.88 1.88L16 17.88l7.453 7.453 1.88-1.88L17.88 16z'/%3E%3C/svg%3E\")}.ag-icon-csv:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='translate(3.934 -.054)scale(.06285)'/%3E%3Cpath d='M.688-.226a.2.2 0 0 1-.017.074.28.28 0 0 1-.145.14.412.412 0 0 1-.234.013.28.28 0 0 1-.202-.168.468.468 0 0 1-.04-.19q0-.086.025-.155a.319.319 0 0 1 .182-.191.4.4 0 0 1 .134-.025q.087 0 .155.035a.3.3 0 0 1 .104.085.17.17 0 0 1 .036.097.06.06 0 0 1-.018.044.06.06 0 0 1-.042.019.06.06 0 0 1-.042-.013.2.2 0 0 1-.031-.046.2.2 0 0 0-.066-.079.16.16 0 0 0-.095-.027.17.17 0 0 0-.142.068.3.3 0 0 0-.053.193.4.4 0 0 0 .023.139.2.2 0 0 0 .067.083.2.2 0 0 0 .1.027q.063 0 .106-.031a.2.2 0 0 0 .065-.091.2.2 0 0 1 .023-.046q.014-.018.044-.018a.06.06 0 0 1 .044.018.06.06 0 0 1 .019.045' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 7.122 25.977)'/%3E%3Cpath d='M.622-.215a.2.2 0 0 1-.033.117.23.23 0 0 1-.098.081.4.4 0 0 1-.153.029.34.34 0 0 1-.175-.04.23.23 0 0 1-.079-.077.17.17 0 0 1-.031-.093q0-.027.019-.045a.06.06 0 0 1 .046-.019.06.06 0 0 1 .039.014.1.1 0 0 1 .027.044.3.3 0 0 0 .03.057q.015.023.044.038.03.015.076.015.065 0 .105-.03a.09.09 0 0 0 .04-.075.08.08 0 0 0-.022-.058.14.14 0 0 0-.056-.034 1 1 0 0 0-.092-.025.7.7 0 0 1-.129-.042.2.2 0 0 1-.083-.066.17.17 0 0 1-.03-.104q0-.058.032-.105a.2.2 0 0 1 .093-.07.4.4 0 0 1 .144-.025q.066 0 .114.016a.3.3 0 0 1 .08.044.2.2 0 0 1 .046.057q.015.03.015.058a.07.07 0 0 1-.018.046.06.06 0 0 1-.046.021q-.025 0-.038-.012a.2.2 0 0 1-.028-.041.2.2 0 0 0-.047-.063Q.387-.625.326-.625a.15.15 0 0 0-.09.025q-.035.024-.035.059 0 .021.012.037a.1.1 0 0 0 .032.027.4.4 0 0 0 .111.036q.06.015.11.031.048.018.083.042a.2.2 0 0 1 .054.062.2.2 0 0 1 .019.091' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 13.339 25.977)'/%3E%3Cpath d='m.184-.633.162.48.163-.483q.013-.038.019-.053a.062.062 0 0 1 .061-.039q.018 0 .034.009a.1.1 0 0 1 .025.025q.009.015.009.031L.654-.64l-.007.025-.009.024-.173.468-.019.051a.2.2 0 0 1-.021.042.1.1 0 0 1-.033.03.1.1 0 0 1-.049.012.1.1 0 0 1-.05-.011A.1.1 0 0 1 .26-.03a.2.2 0 0 1-.021-.042L.22-.123.05-.587.041-.612.033-.638.03-.662q0-.025.02-.046a.07.07 0 0 1 .05-.02q.037 0 .053.023.015.023.031.072' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 18.94 25.977)'/%3E%3C/svg%3E\")}.ag-icon-cut:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m19 3-6 6 2 2 7-7V3m-10 9.5a.503.503 0 0 1-.5-.5c0-.274.226-.5.5-.5s.5.226.5.5-.226.5-.5.5M6 20c-1.097 0-2-.903-2-2a2 2 0 0 1 2-2c1.097 0 2 .903 2 2a2 2 0 0 1-2 2M6 8c-1.097 0-2-.903-2-2a2 2 0 0 1 2-2c1.097 0 2 .903 2 2a2 2 0 0 1-2 2m3.64-.36c.23-.5.36-1.05.36-1.64 0-2.194-1.806-4-4-4S2 3.806 2 6s1.806 4 4 4c.59 0 1.14-.13 1.64-.36L10 12l-2.36 2.36C7.14 14.13 6.59 14 6 14c-2.194 0-4 1.806-4 4s1.806 4 4 4 4-1.806 4-4c0-.59-.13-1.14-.36-1.64L12 14l7 7h3v-1z' style='fill-rule:nonzero' transform='translate(4 4)'/%3E%3C/svg%3E\")}.ag-icon-desc:before,.ag-icon-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Edesc%3C/title%3E%3Cpath d='m26.667 16-1.88-1.88-7.453 7.44V5.333h-2.667V21.56l-7.44-7.453L5.334 16l10.667 10.667L26.668 16z'/%3E%3C/svg%3E\")}.ag-icon-excel:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='translate(3.934 -.054)scale(.06285)'/%3E%3Cpath d='m.052-.139.16-.234-.135-.208a.4.4 0 0 1-.028-.052.1.1 0 0 1-.01-.042.05.05 0 0 1 .018-.037.07.07 0 0 1 .045-.016q.03 0 .047.018a1 1 0 0 1 .047.066l.107.174.115-.174.024-.038.019-.026.021-.015a.1.1 0 0 1 .027-.005.06.06 0 0 1 .044.016.05.05 0 0 1 .018.039q0 .033-.038.089l-.141.211.152.234a.3.3 0 0 1 .03.051.1.1 0 0 1 .009.038.1.1 0 0 1-.008.031.1.1 0 0 1-.024.023.1.1 0 0 1-.034.008.1.1 0 0 1-.035-.008.1.1 0 0 1-.023-.022L.427-.067.301-.265l-.134.204-.022.034-.016.019a.1.1 0 0 1-.022.015.1.1 0 0 1-.03.005.06.06 0 0 1-.044-.016.06.06 0 0 1-.017-.047q0-.036.036-.088' style='fill-rule:nonzero' transform='matrix(17.82892 0 0 16.50777 10.371 25.928)'/%3E%3C/svg%3E\")}.ag-icon-expanded:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eexpanded%3C/title%3E%3Cpath d='M20.94 9.88 19.06 8l-8 8 8 8 1.88-1.88L14.833 16z'/%3E%3C/svg%3E\")}.ag-icon-eye-slash:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eeye-slash%3C/title%3E%3Cpath d='M21.106 15.088A5.19 5.19 0 0 0 16 10.814a5.17 5.17 0 0 0-3.668 1.522L9.866 9.868a12.2 12.2 0 0 1 6.133-1.646c5.186 0 9.614 3.225 11.408 7.778a12.34 12.34 0 0 1-5.276 6.133l-2.468-2.466a5.17 5.17 0 0 0 1.449-2.802h-2.123c-.148.508-.42.964-.782 1.33l-1.33-1.33h-2.514l2.196 2.196q-.272.049-.56.05a3.11 3.11 0 0 1-2.99-2.245h-2.123a5.19 5.19 0 0 0 7.3 3.836l2.247 2.247a12.2 12.2 0 0 1-4.434.828c-5.186 0-9.614-3.225-11.408-7.778a12.3 12.3 0 0 1 3.781-5.111l2.924 2.924a5.1 5.1 0 0 0-.404 1.275h4.206l-1.296-1.296a3.1 3.1 0 0 1 2.196-.903c1.404 0 2.587.924 2.976 2.199h2.13z'/%3E%3C/svg%3E\")}.ag-icon-eye:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eeye%3C/title%3E%3Cpath d='M16 8.222c-5.186 0-9.614 3.225-11.408 7.778 1.794 4.553 6.222 7.778 11.408 7.778S25.614 20.553 27.408 16C25.614 11.447 21.186 8.222 16 8.222m0 12.964c-2.862 0-5.186-2.324-5.186-5.186s2.324-5.186 5.186-5.186 5.186 2.324 5.186 5.186-2.324 5.186-5.186 5.186m0-8.297c-1.721 0-3.111 1.39-3.111 3.111s1.39 3.111 3.111 3.111 3.111-1.39 3.111-3.111-1.39-3.111-3.111-3.111'/%3E%3C/svg%3E\")}.ag-icon-filter:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Efilter%3C/title%3E%3Cpath d='M13.333 24h5.333v-2.667h-5.333zM4 8v2.667h24V8zm4 9.333h16v-2.667H8z'/%3E%3C/svg%3E\")}.ag-icon-first:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Efirst%3C/title%3E%3Cpath d='M24.273 22.12 18.153 16l6.12-6.12L22.393 8l-8 8 8 8zM7.727 8h2.667v16H7.727z'/%3E%3C/svg%3E\")}.ag-icon-group:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Egroup%3C/title%3E%3Cpath d='M18.667 21.333h8.889A3.555 3.555 0 0 1 24 24.889h-5.333zm8.888-7.111v3.556h-8.889v-3.556zM24 7.111a3.555 3.555 0 0 1 3.556 3.556h-16V7.111zm-8.889 17.778h-3.556v-3.556h3.556zm0-7.111h-3.556v-3.556h3.556zM8 10.667H4.444A3.555 3.555 0 0 1 8 7.111z'/%3E%3C/svg%3E\")}.ag-icon-last:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Elast%3C/title%3E%3Cpath d='m7.727 9.88 6.12 6.12-6.12 6.12L9.607 24l8-8-8-8zM21.607 8h2.667v16h-2.667z'/%3E%3C/svg%3E\")}.ag-icon-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eleft%3C/title%3E%3Cpath d='M26.667 14.667H10.44l7.453-7.453L16 5.334 5.333 16.001 16 26.668l1.88-1.88-7.44-7.453h16.227v-2.667z'/%3E%3C/svg%3E\")}.ag-icon-linked:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Elinked%3C/title%3E%3Cpath d='M5.2 16a4.136 4.136 0 0 1 4.133-4.133h5.333V9.334H9.333c-3.68 0-6.667 2.987-6.667 6.667s2.987 6.667 6.667 6.667h5.333v-2.533H9.333A4.136 4.136 0 0 1 5.2 16.002zm5.467 1.333h10.667v-2.667H10.667zm12-8h-5.333v2.533h5.333c2.28 0 4.133 1.853 4.133 4.133s-1.853 4.133-4.133 4.133h-5.333v2.533h5.333c3.68 0 6.667-2.987 6.667-6.667s-2.987-6.667-6.667-6.667z'/%3E%3C/svg%3E\")}.ag-icon-loading:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eloading%3C/title%3E%3Cpath d='m17.778 11.708 3.25-3.251 2.516 2.516-3.251 3.25h4.597v3.556h-4.597l3.251 3.25-2.516 2.516-3.25-3.251v4.597h-3.556v-4.597l-3.25 3.251-2.516-2.516 3.251-3.25H7.11v-3.556h4.597l-3.251-3.25 2.516-2.516 3.25 3.251V7.111h3.556zm-3.251 7.847h2.944l2.084-2.084v-2.944l-2.084-2.084h-2.944l-2.084 2.084v2.944z'/%3E%3C/svg%3E\")}.ag-icon-maximize:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Emaximize%3C/title%3E%3Cpath d='M4 4h24v2.667H4z'/%3E%3C/svg%3E\")}.ag-icon-menu:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Emenu%3C/title%3E%3Cpath d='M4 24h24v-2.667H4zm0-6.667h24v-2.667H4zM4 8v2.667h24V8z'/%3E%3C/svg%3E\")}.ag-icon-menu-alt:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='%23000' d='M16 26.667a2.57 2.57 0 0 1-1.883-.784A2.57 2.57 0 0 1 13.333 24q0-1.1.784-1.883A2.57 2.57 0 0 1 16 21.333q1.1 0 1.883.784.784.783.784 1.883t-.784 1.883a2.57 2.57 0 0 1-1.883.784m0-8a2.57 2.57 0 0 1-1.883-.784A2.57 2.57 0 0 1 13.333 16q0-1.1.784-1.883A2.57 2.57 0 0 1 16 13.333q1.1 0 1.883.784.784.783.784 1.883t-.784 1.883a2.57 2.57 0 0 1-1.883.784m0-8a2.57 2.57 0 0 1-1.883-.784A2.57 2.57 0 0 1 13.333 8q0-1.1.784-1.883A2.57 2.57 0 0 1 16 5.333q1.1 0 1.883.784.784.783.784 1.883t-.784 1.883a2.57 2.57 0 0 1-1.883.784'/%3E%3C/svg%3E\")}.ag-icon-minimize:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eminimize%3C/title%3E%3Cpath d='M8 25.333h16V28H8z'/%3E%3C/svg%3E\")}.ag-icon-minus:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6.572 6.572a13.32 13.32 0 0 0 0 18.856 13.32 13.32 0 0 0 18.856 0 13.32 13.32 0 0 0 0-18.856 13.32 13.32 0 0 0-18.856 0m17.527 8.099v2.658H7.901v-2.658z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-next:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enext%3C/title%3E%3Cpath d='m12.94 8-1.88 1.88L17.167 16l-6.107 6.12L12.94 24l8-8z'/%3E%3C/svg%3E\")}.ag-icon-none:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enone%3C/title%3E%3Cpath d='M4 24h16v-2.667H4zM4 8v2.667h24V8zm0 9.333h24v-2.667H4z'/%3E%3C/svg%3E\")}.ag-icon-not-allowed:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enot-allowed%3C/title%3E%3Cpath d='M16 2.667C8.64 2.667 2.667 8.64 2.667 16S8.64 29.333 16 29.333 29.333 23.36 29.333 16 23.36 2.667 16 2.667M5.333 16c0-5.893 4.773-10.667 10.667-10.667 2.467 0 4.733.84 6.533 2.253L7.586 22.533A10.54 10.54 0 0 1 5.333 16M16 26.667c-2.467 0-4.733-.84-6.533-2.253L24.414 9.467A10.54 10.54 0 0 1 26.667 16c0 5.893-4.773 10.667-10.667 10.667'/%3E%3C/svg%3E\")}.ag-icon-paste:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Epaste%3C/title%3E%3Cpath d='M25.333 4H19.76C19.2 2.453 17.733 1.333 16 1.333S12.8 2.453 12.24 4H6.667A2.675 2.675 0 0 0 4 6.667V28c0 1.467 1.2 2.667 2.667 2.667h18.667c1.467 0 2.667-1.2 2.667-2.667V6.667C28.001 5.2 26.801 4 25.334 4zM16 4c.733 0 1.333.6 1.333 1.333s-.6 1.333-1.333 1.333-1.333-.6-1.333-1.333S15.267 4 16 4m9.333 24H6.666V6.667h2.667v4h13.333v-4h2.667z'/%3E%3C/svg%3E\")}.ag-icon-pin:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Epin%3C/title%3E%3Cpath d='m11.106 22.093-4.444 4.444-1.259-1.259 4.444-4.444zm5.872-16.63 9.618 9.62-.962.962-.962-.962-7.694 3.847 1.924 1.924-2.74 2.74-7.696-7.696 2.741-2.74 1.924 1.925 3.847-7.696-.962-.962z'/%3E%3C/svg%3E\")}.ag-icon-pivot:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Epivot%3C/title%3E%3Cpath d='M26.667 30.223H5.334a3.556 3.556 0 0 1-3.556-3.556V5.334a3.556 3.556 0 0 1 3.556-3.556h21.333a3.556 3.556 0 0 1 3.556 3.556v21.333a3.556 3.556 0 0 1-3.556 3.556m-16-8.89H5.334v5.333h5.333zm16-7.11H12.444v12.444h14.223zm-9.15 6.85-2.039 2.037 2.039 2.039-1.257 1.257-3.295-3.296 3.295-3.295q.63.628 1.257 1.257zm-6.85-6.85H5.334v5.333h5.333zm15.74 3.816-1.257 1.256-2.039-2.037-2.037 2.037-1.257-1.256 3.295-3.296zM10.667 5.333H5.334v5.333h5.333zm8.889 0h-7.112v5.333h7.112zm7.111 0h-5.333v5.333h5.333z'/%3E%3C/svg%3E\")}.ag-icon-plus:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6.572 6.572a13.32 13.32 0 0 0 0 18.856 13.32 13.32 0 0 0 18.856 0 13.32 13.32 0 0 0 0-18.856 13.32 13.32 0 0 0-18.856 0m17.527 8.099v2.658h-6.77v6.77h-2.658v-6.77h-6.77v-2.658h6.77v-6.77h2.658v6.77z' style='fill-rule:nonzero'/%3E%3C/svg%3E\")}.ag-icon-previous:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eprevious%3C/title%3E%3Cpath d='M20.94 9.88 19.06 8l-8 8 8 8 1.88-1.88L14.833 16z'/%3E%3C/svg%3E\")}.ag-icon-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eright%3C/title%3E%3Cpath d='m16 5.333-1.88 1.88 7.44 7.453H5.333v2.667H21.56l-7.44 7.453 1.88 1.88 10.667-10.667L16 5.332z'/%3E%3C/svg%3E\")}.ag-icon-save:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esave%3C/title%3E%3Cpath d='M25.333 16v9.333H6.666V16H3.999v9.333C3.999 26.8 5.199 28 6.666 28h18.667C26.8 28 28 26.8 28 25.333V16zm-8 .893 3.453-3.44 1.88 1.88L15.999 22l-6.667-6.667 1.88-1.88 3.453 3.44V4h2.667v12.893z'/%3E%3C/svg%3E\")}.ag-icon-small-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-down%3C/title%3E%3Cpath d='M9.333 12.667 16 19.334l6.667-6.667H9.334z'/%3E%3C/svg%3E\")}.ag-icon-small-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-left%3C/title%3E%3Cpath d='M19.333 9.333 12.666 16l6.667 6.667V9.334z'/%3E%3C/svg%3E\")}.ag-icon-small-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-right%3C/title%3E%3Cpath d='M12.667 22.667 19.334 16l-6.667-6.667v13.333z'/%3E%3C/svg%3E\")}.ag-icon-small-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Esmall-up%3C/title%3E%3Cpath d='M9.333 19.333 16 12.666l6.667 6.667H9.334z'/%3E%3C/svg%3E\")}.ag-icon-tick:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etick%3C/title%3E%3Cpath d='m11.727 21.167-5.56-5.56-1.893 1.88 7.453 7.453 16-16-1.88-1.88z'/%3E%3C/svg%3E\")}.ag-icon-tree-closed:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etree-closed%3C/title%3E%3Cpath d='m12.94 8-1.88 1.88L17.167 16l-6.107 6.12L12.94 24l8-8z'/%3E%3C/svg%3E\")}.ag-icon-tree-indeterminate:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etree-indeterminate%3C/title%3E%3Cpath d='M6.667 14.667h18.667v2.667H6.667z'/%3E%3C/svg%3E\")}.ag-icon-tree-open:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Etree-open%3C/title%3E%3Cpath d='M22.12 11.06 16 17.167 9.88 11.06 8 12.94l8 8 8-8z'/%3E%3C/svg%3E\")}.ag-icon-unlinked:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eunlinked%3C/title%3E%3Cpath d='M22.667 9.333h-5.333v2.533h5.333a4.136 4.136 0 0 1 4.133 4.133c0 1.907-1.307 3.507-3.08 3.973l1.947 1.947c2.173-1.107 3.667-3.32 3.667-5.92a6.67 6.67 0 0 0-6.667-6.667zm-1.334 5.334h-2.92l2.667 2.667h.253zM2.667 5.693 6.814 9.84A6.65 6.65 0 0 0 2.667 16a6.67 6.67 0 0 0 6.667 6.667h5.333v-2.533H9.334a4.136 4.136 0 0 1-4.133-4.133c0-2.12 1.613-3.867 3.68-4.093l2.76 2.76h-.973v2.667h3.64l3.027 3.027v2.307h2.307l5.347 5.333 1.68-1.68L4.362 4.002 2.669 5.695z'/%3E%3C/svg%3E\")}.ag-icon-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Easc%3C/title%3E%3Cpath d='m5.333 16 1.88 1.88 7.453-7.44v16.227h2.667V10.44l7.44 7.453L26.666 16 15.999 5.333z'/%3E%3C/svg%3E\")}.ag-icon-grip:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Egrip%3C/title%3E%3Cpath d='M26.667 12H5.334v2.667h21.333zM5.333 20h21.333v-2.667H5.333z'/%3E%3C/svg%3E\")}.ag-icon-settings:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='%23000' d='M30 8h-4.1c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2v2h14.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30zm-9 4c-1.7 0-3-1.3-3-3s1.3-3 3-3 3 1.3 3 3-1.3 3-3 3M2 24h4.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30v-2H15.9c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2zm9-4c1.7 0 3 1.3 3 3s-1.3 3-3 3-3-1.3-3-3 1.3-3 3-3'/%3E%3C/svg%3E\")}.ag-icon-column-arrow:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M11 4a1 1 0 0 1 1 1v22a1 1 0 1 1-2 0V5a1 1 0 0 1 1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 13a1 1 0 0 1 1-1h23.5a1 1 0 1 1 0 2H3a1 1 0 0 1-1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 4h18v24H2zm2 2v20h14V6zM26.793 13 23 9.207l1.414-1.414L29.621 13l-5.207 5.207L23 16.793z' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-un-pin:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath 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 11'/%3E%3Cpath 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.904zm-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.28zM9.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.972z'/%3E%3C/svg%3E\")}.ag-icon-pinned-top:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath 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.22M3.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-.536'/%3E%3C/svg%3E\")}.ag-icon-pinned-bottom:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath 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-.22M12.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.536'/%3E%3C/svg%3E\")}.ag-icon-chevron-up:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M3.479 10.521a.75.75 0 0 1 0-1.06l4-4a.75.75 0 0 1 1.06 0l4 4a.75.75 0 0 1-1.06 1.06l-3.47-3.47-3.47 3.47a.75.75 0 0 1-1.06 0' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-down:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M12.521 5.461a.75.75 0 0 1 0 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 1.06-1.06l3.47 3.47 3.47-3.47a.75.75 0 0 1 1.06 0' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-left:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M10.53 12.512a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 0-1.06l4-4a.75.75 0 0 1 1.06 1.06l-3.47 3.47 3.47 3.47a.75.75 0 0 1 0 1.06' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-chevron-right:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M5.47 3.47a.75.75 0 0 1 1.06 0l4 4a.75.75 0 0 1 0 1.06l-4 4a.75.75 0 0 1-1.06-1.06L8.94 8 5.47 4.53a.75.75 0 0 1 0-1.06' clip-rule='evenodd'/%3E%3C/svg%3E\")}.ag-icon-filter-add:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M18.666 24h-5.333v-2.667h5.333zM24 17.333H8v-2.667h16zm3.59-9.344h3.221v2.657h-3.22v3.22h-2.656v-3.22h-3.221V7.989h3.22V4.77h2.657zm-8.582 2.678H4V8h15.008z'/%3E%3C/svg%3E\")}.ag-icon-edit:before{mask-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M6.222 25.778h1.611l14.834-14.811-1.611-1.611-14.834 14.81zM4 28v-4.733L22.644 4.656a2.26 2.26 0 0 1 1.567-.634q.423 0 .833.167.412.166.734.478l1.589 1.6q.333.322.483.733t.15.822q0 .423-.161.839-.162.416-.472.728L8.733 28zm17.856-17.833-.8-.811 1.61 1.61z'/%3E%3C/svg%3E\")}"}),Qh={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"/><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"/>'},Zh={"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"><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>'},Jh=(e,t=1.5)=>{const o=Zh[e];if(o)return o;const i=Qh[e];if(!i)throw new 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>"},Xh=((e={})=>qs({feature:"iconSet",css:()=>((e={})=>{let t="";for(const o of[...Object.keys(Qh),...Object.keys(Zh)]){const i=Jh(o,e.strokeWidth);t+=`.ag-icon-${o}::before { mask-image: url('data:image/svg+xml,${encodeURIComponent(i)}'); }\n`}return t})(e)}))(),ec=':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)}}',tc={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},oc=(()=>qs({feature:"inputStyle",params:{...tc,inputBackgroundColor:on,inputBorder:!0,inputBorderRadius:{ref:"borderRadius"},inputPaddingStart:{ref:"spacing"},inputFocusBorder:{color:nn},inputFocusShadow:{ref:"focusShadow"},inputDisabledBackgroundColor:tn(.06),inputDisabledTextColor:{ref:"textColor",mix:.5},inputInvalidBorder:{color:{ref:"invalidColor"}},pickerButtonBorder:!0,pickerListBorder:!0},css:()=>ec+".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)}}}"}))(),ic=(()=>qs({feature:"inputStyle",params:{...tc,inputBackgroundColor:"transparent",inputBorder:{width:2,color:en(.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:()=>ec+".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}"}))(),sc='.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)}&: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)}}}',nc={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},rc=(()=>qs({feature:"tabStyle",params:{...nc,tabBarBorder:!0,tabBarBackgroundColor:en(.05),tabTextColor:{ref:"textColor",mix:.7},tabSelectedTextColor:{ref:"textColor"},tabHoverTextColor:{ref:"textColor"},tabSelectedBorderColor:{ref:"borderColor"},tabSelectedBackgroundColor:on},css:sc}))(),ac=(()=>qs({feature:"tabStyle",params:{...nc,tabBarBackgroundColor:{ref:"chromeBackgroundColor"},tabSelectedUnderlineColor:{ref:"primaryColor"},tabSelectedUnderlineWidth:2,tabSelectedUnderlineTransitionDuration:0},css:sc}))(),lc=(()=>qs({feature:"tabStyle",params:{...nc,tabBarBorder:!0,tabBarBackgroundColor:{ref:"chromeBackgroundColor"},tabHoverTextColor:nn,tabSelectedTextColor:nn,tabSelectedUnderlineColor:nn,tabSelectedUnderlineWidth:2,tabSelectedUnderlineTransitionDuration:"0.3s"},css:sc}))(),dc=(()=>qs({feature:"tabStyle",params:{...nc,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:on},css:()=>sc+".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)}}"}))(),hc=(()=>Uh().withPart($h).withPart(jh).withPart(Xh).withPart(rc).withPart(oc).withPart(Oh).withParams({fontFamily:[{googleFont:"IBM Plex Sans"},"-apple-system","BlinkMacSystemFont","Segoe UI","Roboto","Oxygen-Sans","Ubuntu"]}))(),cc=(()=>Uh().withPart(Gh).withPart($h).withPart(jh).withPart(_h).withPart(lc).withPart(oc).withPart(Oh).withParams({accentColor:"#2196f3",selectedRowBackgroundColor:Xs(.3),inputFocusBorder:{color:Xs(.4)},focusShadow:{radius:2,spread:1.6,color:Xs(.4)},iconButtonHoverBackgroundColor:"transparent",iconButtonActiveBackgroundColor:"transparent",checkboxUncheckedBorderColor:tn(.45),checkboxIndeterminateBackgroundColor:tn(.45),checkboxIndeterminateBorderColor:tn(.45),checkboxBorderWidth:2,checkboxBorderRadius:2,fontSize:13,dataFontSize:14,headerFontWeight:700,borderRadius:3,wrapperBorderRadius:3,tabSelectedUnderlineColor:nn,tabSelectedBorderWidth:0,tabSelectedUnderlineTransitionDuration:.3,sideButtonSelectedUnderlineColor:nn,sideButtonSelectedUnderlineWidth:2,sideButtonSelectedUnderlineTransitionDuration:.3,sideButtonBorder:!1,sideButtonSelectedBorder:!1,sideButtonBarTopPadding:{calc:"spacing * 3"},sideButtonSelectedBackgroundColor:"transparent",sideButtonHoverTextColor:nn,iconButtonHoverColor:nn,toggleButtonWidth:28,toggleButtonHeight:18,toggleButtonSwitchInset:1,toggleButtonOffBackgroundColor:tn(.45),colorPickerThumbSize:13,colorPickerTrackSize:11,colorPickerThumbBorderWidth:2,colorPickerTrackBorderRadius:2,colorPickerColorBorderRadius:2}))(),uc=(()=>Uh().withPart(Nh).withPart($h).withPart(jh).withPart(qh).withPart(dc).withPart(oc).withPart(zh).withParams({accentColor:"#0091ea",borderColor:en(.2),spacing:4,widgetVerticalSpacing:{calc:"max(8px, spacing)"},borderRadius:2,wrapperBorderRadius:2,headerColumnResizeHandleColor:"transparent",headerColumnBorder:!0,headerColumnBorderHeight:"50%",oddRowBackgroundColor:{ref:"chromeBackgroundColor",mix:.5},checkboxBorderRadius:2,checkboxBorderWidth:1,checkboxUncheckedBackgroundColor:on,checkboxUncheckedBorderColor:tn(.5),checkboxCheckedBackgroundColor:on,checkboxCheckedBorderColor:nn,checkboxCheckedShapeColor:nn,checkboxIndeterminateBackgroundColor:on,checkboxIndeterminateBorderColor:tn(.5),checkboxIndeterminateShapeColor:tn(.5),focusShadow:{radius:2,spread:1,color:nn},headerTextColor:en(.6),iconButtonHoverBackgroundColor:"transparent",iconButtonActiveBackgroundColor:"transparent",fontSize:12,tabSelectedBackgroundColor:on,headerFontWeight:"bold",toggleButtonWidth:32,toggleButtonHeight:16,toggleButtonSwitchInset:1,toggleButtonOffBackgroundColor:tn(.5),sideButtonBorder:!0,sideButtonBarTopPadding:{calc:"spacing * 4"},popupShadow:"5px 5px 10px rgba(0, 0, 0, 0.3)",statusBarLabelColor:en(.54),statusBarLabelFontWeight:600,statusBarValueFontWeight:600,panelTitleBarIconColor:sn,colorPickerThumbSize:13,colorPickerTrackSize:11,colorPickerThumbBorderWidth:2,colorPickerTrackBorderRadius:2,colorPickerColorBorderRadius:2}))(),gc=(()=>{const e={tabSelectedUnderlineColor:{ref:"primaryColor"},sideButtonSelectedUnderlineColor:{ref:"primaryColor"},buttonTextColor:{ref:"primaryColor"},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:on,sideButtonSelectedBackgroundColor:"transparent",sideButtonBarTopPadding:{calc:"spacing * 4"},headerColumnResizeHandleColor:"none",headerBackgroundColor:{ref:"backgroundColor"},rowHoverColor:en(.08),columnHoverColor:en(.08),headerCellHoverBackgroundColor:en(.05),statusBarLabelColor:en(.63),statusBarLabelFontWeight:600,statusBarValueFontWeight:600,valueChangeValueHighlightBackgroundColor:"#00acc1",panelTitleBarIconColor:sn,advancedFilterBuilderButtonBarBorder:!1,filterPanelApplyButtonColor:{ref:"buttonTextColor"},filterPanelApplyButtonBackgroundColor:{ref:"buttonBackgroundColor"},colorPickerThumbSize:13,colorPickerTrackSize:11,colorPickerThumbBorderWidth:2,colorPickerTrackBorderRadius:2,colorPickerColorBorderRadius:2},t={...e,primaryColor:"#3f51b5",foregroundColor:"#000D",headerTextColor:"#0008",accentColor:"#ff4081",checkboxUncheckedBorderColor:sn,checkboxIndeterminateBackgroundColor:sn,toggleButtonOffBackgroundColor:sn,selectedRowBackgroundColor:"rgba(33, 150, 243, 0.3)"},o={...e,primaryColor:"#3f51b5",foregroundColor:"#fffD",headerTextColor:"#fff8",accentColor:"#bb86fc",checkboxUncheckedBorderColor:tn(.5),checkboxIndeterminateBackgroundColor:tn(.5),toggleButtonOffBackgroundColor:tn(.5),selectedRowBackgroundColor:"#bb86fc33"};return qs({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:t,modeParams:{light:t,dark:o,"dark-blue":o}})})(),pc=(()=>Uh().withPart(Hh).withPart($h).withPart(jh).withPart(Yh).withPart(ac).withPart(ic).withPart(zh).withPart(gc).withParams({rowHeight:{calc:"max(iconSize, dataFontSize) + spacing * 3.75 * rowVerticalPaddingScale"},headerHeight:{calc:"max(iconSize, dataFontSize) + spacing * 4.75 * headerVerticalPaddingScale"},widgetVerticalSpacing:{calc:"spacing * 1.75"},cellHorizontalPadding:{calc:"spacing * 3"},buttonHorizontalPadding:{ref:"spacing"},widgetContainerHorizontalPadding:{calc:"spacing * 1.5"},widgetContainerVerticalPadding:{calc:"spacing * 2"},fontSize:13,iconSize:18,borderRadius:0,wrapperBorderRadius:0,wrapperBorder:!1,menuBorder:!1,dialogBorder:!1,panelTitleBarBorder:!1,tabSelectedBorderWidth:0,tabSelectedUnderlineTransitionDuration:.3,sidePanelBorder:!1,sideButtonSelectedBorder:!1,sideButtonSelectedUnderlineWidth:2,sideButtonSelectedUnderlineTransitionDuration:.3,sideButtonBorder:!1,buttonBorder:!1,buttonDisabledBorder:!1,focusShadow:{spread:4,color:en(.16)},fontFamily:[{googleFont:"Roboto"},"-apple-system","BlinkMacSystemFont","Segoe UI","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue","sans-serif"],inputHeight:{calc:"max(iconSize, fontSize) + spacing * 3"},pickerButtonBorder:{width:1,color:"transparent"},headerFontWeight:600,headerFontSize:{calc:"fontSize - 1px"},checkboxBorderWidth:2,checkboxBorderRadius:2,toggleButtonWidth:34,toggleButtonSwitchInset:1,cardShadow:"0 3px 1px -2px rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 1px 5px 0 rgba(0, 0, 0, 0.12)",popupShadow:"5px 5px 10px rgba(0, 0, 0, 0.3)"}))(),mc={cssName:"--ag-cell-horizontal-padding",changeKey:"cellHorizontalPaddingChanged",defaultValue:16},fc={cssName:"--ag-indentation-level",changeKey:"indentationLevelChanged",defaultValue:0,noWarn:!0,cacheDefault:!0},Cc={cssName:"--ag-row-group-indent-size",changeKey:"rowGroupIndentSizeChanged",defaultValue:0},vc={cssName:"--ag-row-height",changeKey:"rowHeightChanged",defaultValue:42},wc={cssName:"--ag-header-height",changeKey:"headerHeightChanged",defaultValue:48},bc={cssName:"--ag-list-item-height",changeKey:"listItemHeightChanged",defaultValue:24},yc={cssName:"--ag-row-border",changeKey:"rowBorderWidthChanged",defaultValue:1,border:!0},Sc={cssName:"--ag-pinned-row-border",changeKey:"pinnedRowBorderWidthChanged",defaultValue:1,border:!0};var Ec=15538;function Rc(e,t,o){const i=e.visibleCols.headerGroupRowCount;if(o>=i)return{column:t,headerRowIndex:o};let s=t.getParent();for(;s&&s.getProvidedColumnGroup().getLevel()>o;)s=s.getParent();const n=t.isSpanHeaderHeight();return!s||n&&s.isPadding()?{column:t,headerRowIndex:i}:{column:s,headerRowIndex:s.getProvidedColumnGroup().getLevel()}}var xc=new Set(["gridPreDestroyed","fillStart","pasteStart"]),Fc=["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)=>{var o;return e[t]=!(o=t)||o.length<2?o:"on"+o[0].toUpperCase()+o.substring(1),e},{}),Pc=(e,t)=>({tag:"span",ref:`eSort${e}`,cls:`ag-sort-indicator-icon ag-sort-${t} ag-hidden`,attrs:{"aria-hidden":"true"}}),Dc={tag:"span",cls:"ag-sort-indicator-container",children:[Pc("Order","order"),Pc("Asc","ascending-icon"),Pc("Desc","descending-icon"),Pc("Mixed","mixed-icon"),Pc("None","none-icon")]},Mc=class extends Uo{constructor(e){super(),this.eSortOrder=Go,this.eSortAsc=Go,this.eSortDesc=Go,this.eSortMixed=Go,this.eSortNone=Go,e||this.setTemplate(Dc)}attachCustomElements(e,t,o,i,s){this.eSortOrder=e,this.eSortAsc=t,this.eSortDesc=o,this.eSortMixed=i,this.eSortNone=s}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);const o=this.updateIcons.bind(this),i=this.onSortChanged.bind(this);this.addManagedPropertyListener("unSortIcon",o),this.addManagedEventListeners({newColumnsLoaded:o,sortChanged:i,columnRowGroupChanged:i}),this.onSortChanged()}addInIcon(e,t,o){if(null==t)return;const i=al(e,this.beans,o);i&&t.appendChild(i)}onSortChanged(){this.updateIcons(),this.suppressOrder||this.updateSortOrder()}updateIcons(){const{eSortAsc:e,eSortDesc:t,eSortNone:o,column:i,gos:s,beans:n}=this,r=n.sortSvc.getDisplaySortForColumn(i);if(e){H(e,"asc"===r,{skipAriaHidden:!0})}if(t){H(t,"desc"===r,{skipAriaHidden:!0})}if(o){H(o,!(!i.getColDef().unSortIcon&&!s.get("unSortIcon"))&&null==r,{skipAriaHidden:!0})}}setupMultiSortIndicator(){const{eSortMixed:e,column:t,gos:o}=this;this.addInIcon("sortUnSort",e,t);const i=t.getColDef().showRowGroup;yt(o)&&i&&(this.addManagedEventListeners({sortChanged:this.updateMultiSortIndicator.bind(this),columnRowGroupChanged:this.updateMultiSortIndicator.bind(this)}),this.updateMultiSortIndicator())}updateMultiSortIndicator(){const{eSortMixed:e,beans:t,column:o}=this;if(e){H(e,"mixed"===t.sortSvc.getDisplaySortForColumn(o),{skipAriaHidden:!0})}}updateSortOrder(){const{eSortOrder:e,column:t,beans:{sortSvc:o}}=this;if(!e)return;const i=o.getColumnsWithSortingOrdered(),s=o.getDisplaySortIndexForColumn(t)??-1,n=i.some(e=>o.getDisplaySortIndexForColumn(e)??!1);H(e,s>=0&&n,{skipAriaHidden:!0}),s>=0?e.textContent=(s+1).toString():q(e)}},kc={selector:"AG-SORT-INDICATOR",component:Mc},Tc=["asc","desc",null],Ic={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"},Ac={aggFunc:"SharedAggregation",autoHeight:"RowAutoHeight",cellClass:"CellStyle",cellClassRules:"CellStyle",cellEditor:({cellEditor:e,editable:t})=>t?"string"==typeof e?Ic[e]??"CustomEditor":"CustomEditor":null,cellRenderer:({cellRenderer:e})=>"string"!=typeof e?null:Ic[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?Ic[e]??"ColumnFilter":"ColumnFilter",floatingFilter:"ColumnFilter",getQuickFilterText:"QuickFilter",headerTooltip:"Tooltip",mainMenuItems:"ColumnMenu",menuTabs:e=>{const 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",spanRows:"CellSpan",rowGroupingHierarchy:"SharedRowGrouping"},Lc={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,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,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},Bc=["overlayLoadingTemplate","overlayNoRowsTemplate","gridId","quickFilterText","rowModelType","editType","domLayout","clipboardDelimiter","rowGroupPanelShow","multiSortKey","pivotColumnGroupTotals","pivotRowTotals","pivotPanelShow","fillHandleDirection","groupDisplayType","treeDataDisplayType","treeDataChildrenField","treeDataParentIdField","colResizeDefault","tooltipTrigger","serverSidePivotResultFieldSeparator","columnMenu","tooltipShowMode","invalidEditValueMode","grandTotalRow","themeCssLayer","findSearchValue","styleNonce","renderingMode"],Hc=["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"],Vc=["sortingOrder","alignedGrids","rowData","columnDefs","excelStyles","pinnedTopRowData","pinnedBottomRowData","chartThemes","rowClass","paginationPageSizeSelector"],Gc=["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"],Nc=["theme","rowSelection"],Oc=["cellSelection","sideBar","rowNumbers","suppressGroupChangesColumnVisibility","groupAggFiltering","suppressStickyTotalRow","groupHideParentOfSingleChild","enableRowPinning"],zc=["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"],Wc=["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","sendToClipboard","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 Uc(e,t,o){return"number"==typeof t||null==t?null==t||t>=o?null:`${e}: value should be greater than or equal to ${o}`:`${e}: value should be a number`}var $c={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:"SharedRowGrouping",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"},Kc=()=>{const e={autoSizePadding:{validate:({autoSizePadding:e})=>Uc("autoSizePadding",e,0)},cacheBlockSize:{supportedRowModels:["serverSide","infinite"],validate:({cacheBlockSize:e})=>Uc("cacheBlockSize",e,1)},cacheOverflowSize:{validate:({cacheOverflowSize:e})=>Uc("cacheOverflowSize",e,1)},datasource:{supportedRowModels:["infinite"]},domLayout:{validate:e=>{const t=e.domLayout,o=["autoHeight","normal","print"];return t&&!o.includes(t)?`domLayout must be one of [${o.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:o})=>e&&(t||o)?"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:o,pinnedBottomRowData:i})=>t&&(o||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:o,pinnedBottomRowData:i})=>t&&(o||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,o){for(const t of Object.keys(e))o.validation?.validateColDef(e[t]);return null}},icons:{validate:({icons:e})=>{if(e){if(e.smallDown)return at(262);if(e.smallLeft)return at(263);if(e.smallRight)return at(264)}return null}},infiniteInitialRowCount:{validate:({infiniteInitialRowCount:e})=>Uc("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})=>Uc("keepDetailRowsCount",e,1)},paginationPageSize:{validate:({paginationPageSize:e})=>Uc("paginationPageSize",e,1)},paginationPageSizeSelector:{validate:e=>{const t=e.paginationPageSizeSelector;return"boolean"==typeof t||null==t||t.length?null:"'paginationPageSizeSelector' cannot be an empty array.\n 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})=>Uc("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}" is invalid. Use one of 'singleRow' or 'multiRow'.`:null},rowStyle:{validate:e=>{const 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})=>Uc("serverSideInitialRowCount",e,1)},serverSideOnlyRefreshFilteredGroups:{supportedRowModels:["serverSide"]},serverSideSortAllLevels:{supportedRowModels:["serverSide"]},sortingOrder:{validate:e=>{const t=e.sortingOrder;if(Array.isArray(t)&&t.length>0){const e=t.filter(e=>!Tc.includes(e));if(e.length>0)return`sortingOrder must be an array with elements from [${Tc.map(et).join()}], currently it includes [${e.map(et).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=>{const t=e.rowModelType??"clientSide";switch(t){case"clientSide":{const{treeDataChildrenField:t,treeDataParentIdField:o,getDataPath:i,getRowId:s}=e;if(!t&&!o&&!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(o)return"Cannot use both 'treeDataChildrenField' and 'treeDataParentIdField' at the same time."}if(o){if(!s)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."}return null}case"serverSide":{const o=`treeData requires 'isServerSideGroup' and 'getServerSideGroupKey' in the ${t} row model.`;return e.isServerSideGroup&&e.getServerSideGroupKey?null:o}}return null}},viewportDatasource:{supportedRowModels:["viewport"]},viewportRowModelBufferSize:{validate:({viewportRowModelBufferSize:e})=>Uc("viewportRowModelBufferSize",e,0)},viewportRowModelPageSize:{validate:({viewportRowModelPageSize:e})=>Uc("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=>{const t=e.renderingMode,o=["default","legacy"];return t&&!o.includes(t)?`renderingMode must be one of [${o.join()}], currently it's ${t}`:null}}},t={};return zc.forEach(e=>{t[e]={expectedType:"boolean"}}),Gc.forEach(e=>{t[e]={expectedType:"number"}}),Ge(t,e),t},jc=0,qc=0,_c="__ag_grid_instance";function Yc(e){const 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 Qc=Yc(!0),Zc=Yc(!1),Jc={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"}]},Xc={moduleName:"ColumnHeaderComp",version:qe,userComponents:{agColumnHeader:class extends Uo{constructor(){super(...arguments),this.eFilter=Go,this.eFilterButton=Go,this.eSortIndicator=Go,this.eMenu=Go,this.eLabel=Go,this.eText=Go,this.eSortOrder=Go,this.eSortAsc=Go,this.eSortDesc=Go,this.eSortMixed=Go,this.eSortNone=Go,this.isLoadingInnerComponent=!1}refresh(e){const 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){const t={...e};Ge(t,e.innerHeaderComponentParams),this.innerHeaderComponent.refresh?.(t)}else this.setDisplayName(e);return!0}workOutTemplate(e,t){const o=e.template;return o?o?.trim?o.trim():o:t?Qc:Zc}init(e){this.params=e;const{sortSvc:t,touchSvc:o,rowNumbersSvc:i,userCompFactory:s}=this.beans,n=t?.getSortIndicatorSelector();this.currentTemplate=this.workOutTemplate(e,!!n),this.setTemplate(this.currentTemplate,n?[n]:void 0),o?.setupForHeader(this),this.setMenu(),this.setupSort(),i?.setupForHeader(this),this.setupFilterIcon(),this.setupFilterButton(),this.workOutInnerHeaderComponent(s,e),this.setDisplayName(e)}workOutInnerHeaderComponent(e,t){const o=function(e,t,o){return e.getCompDetails(t,Qo,void 0,o)}(e,t,t);o&&(this.isLoadingInnerComponent=!0,o.newAgStackInstance().then(e=>{this.isLoadingInnerComponent=!1,e&&(this.isAlive()?(this.innerHeaderComponent=e,this.eText&&this.eText.appendChild(e.getGui())):this.destroyBean(e))}))}setDisplayName(e){const{displayName:t}=e,o=this.currentDisplayName;this.currentDisplayName=t,!this.eText||o===t||this.innerHeaderComponent||this.isLoadingInnerComponent||(this.eText.textContent=d(t))}addInIcon(e,t,o){const i=al(e,this.beans,o);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)return _(this.eMenu),void(this.eMenu=void 0);const{gos:e,eMenu:t,params:o}=this,i=Ot(e);this.addInIcon(i?"menu":"menuAlt",t,o.column),t.classList.toggle("ag-header-menu-icon",!i);const s=this.shouldSuppressMenuHide();this.currentSuppressMenuHide=s,this.addManagedElementListeners(t,{click:()=>this.showColumnMenu(this.eMenu)}),this.toggleMenuAlwaysShow(s)}toggleMenuAlwaysShow(e){this.eMenu?.classList.toggle("ag-header-menu-always-show",e)}showColumnMenu(e){const{currentSuppressMenuHide:t,params:o}=this;t||this.toggleMenuAlwaysShow(!0),o.showColumnMenu(e,()=>{t||this.toggleMenuAlwaysShow(!1)})}onMenuKeyboardShortcut(e){const{params:t,gos:o,beans:i,eMenu:s,eFilterButton:n}=this,r=t.column,a=Ot(o);if(e&&!a){if(i.menuSvc?.isFilterMenuInHeaderEnabled(r))return t.showFilter(n??s??this.getGui()),!0}else if(t.enableMenu)return this.showColumnMenu(s??n??this.getGui()),!0;return!1}setupSort(){const{sortSvc:e}=this.beans;if(!e)return;const{enableSorting:t,column:o}=this.params;if(this.currentSort=t,!this.eSortIndicator){this.eSortIndicator=this.createBean(e.createSortIndicator(!0));const{eSortIndicator:t,eSortOrder:o,eSortAsc:i,eSortDesc:s,eSortMixed:n,eSortNone:r}=this;t.attachCustomElements(o,i,s,n,r)}this.eSortIndicator.setupSort(o),this.currentSort&&e.setupHeader(this,o,this.eLabel)}setupFilterIcon(){const{eFilter:e,params:t}=this;if(!e)return;this.configureFilter(t.enableFilterIcon,e,()=>{const o=t.column.isFilterActive();H(e,o,{skipAriaHidden:!0})},"filterActive")}setupFilterButton(){const{eFilterButton:e,params:t}=this;if(!e)return;this.configureFilter(t.enableFilterButton,e,this.onFilterChangedButton.bind(this),"filter")?this.addManagedElementListeners(e,{click:()=>t.showFilter(e)}):this.eFilterButton=void 0}configureFilter(e,t,o,i){if(!e)return _(t),!1;const s=this.params.column;return this.addInIcon(i,t,s),this.addManagedListeners(s,{filterChanged:o}),o(),!0}onFilterChangedButton(){const e=this.params.column.isFilterActive();this.eFilterButton.classList.toggle("ag-filter-active",e)}getAnchorElementForMenu(e){const{eFilterButton:t,eMenu:o}=this;return e?t??o??this.getGui():o??t??this.getGui()}destroy(){super.destroy(),this.innerHeaderComponent&&(this.destroyBean(this.innerHeaderComponent),this.innerHeaderComponent=void 0)}}},icons:{menu:"menu",menuAlt:"menu-alt"}},eu={moduleName:"ColumnGroupHeaderComp",version:qe,userComponents:{agColumnGroupHeader:class extends Uo{constructor(){super(Jc),this.agOpened=Go,this.agClosed=Go,this.agLabel=Go,this.isLoadingInnerComponent=!1}init(e){const{userCompFactory:t,touchSvc:o}=this.beans;this.params=e,this.checkWarnings(),this.workOutInnerHeaderGroupComponent(t,e),this.setupLabel(e),this.addGroupExpandIcon(e),this.setupExpandIcons(),o?.setupForHeaderGroup(this)}checkWarnings(){this.params.template&&st(89)}workOutInnerHeaderGroupComponent(e,t){const o=function(e,t,o){return e.getCompDetails(t,Zo,void 0,o)}(e,t,t);o&&(this.isLoadingInnerComponent=!0,o.newAgStackInstance().then(e=>{this.isLoadingInnerComponent=!1,e&&(this.isAlive()?(this.innerHeaderGroupComponent=e,this.agLabel.appendChild(e.getGui())):this.destroyBean(e))}))}setupExpandIcons(){const{agOpened:e,agClosed:t,params:{columnGroup:o},beans:i}=this;this.addInIcon("columnGroupOpened",e),this.addInIcon("columnGroupClosed",t);const s=e=>{if(Pr(e))return;const t=!o.isExpanded();i.colGroupSvc.setColumnGroupOpened(o.getProvidedColumnGroup(),t,"uiColumnExpanded")};this.addTouchAndClickListeners(i,t,s),this.addTouchAndClickListeners(i,e,s);const n=e=>{Fr(e)};this.addManagedElementListeners(t,{dblclick:n}),this.addManagedElementListeners(e,{dblclick:n}),this.addManagedElementListeners(this.getGui(),{dblclick:s}),this.updateIconVisibility();const r=o.getProvidedColumnGroup(),a=this.updateIconVisibility.bind(this);this.addManagedListeners(r,{expandedChanged:a,expandableChanged:a})}addTouchAndClickListeners(e,t,o){e.touchSvc?.setupForHeaderGroupElement(this,t,o),this.addManagedElementListeners(t,{click:o})}updateIconVisibility(){const{agOpened:e,agClosed:t,params:{columnGroup:o}}=this;if(o.isExpandable()){const i=o.isExpanded();H(e,i),H(t,!i)}else H(e,!1),H(t,!1)}addInIcon(e,t){const o=al(e,this.beans,null);o&&t.appendChild(o)}addGroupExpandIcon(e){if(!e.columnGroup.isExpandable()){const{agOpened:e,agClosed:t}=this;return H(e,!1),void H(t,!1)}}setupLabel(e){const{displayName:t,columnGroup:i}=e,s=this.innerHeaderGroupComponent||this.isLoadingInnerComponent;o(t)&&!s&&(this.agLabel.textContent=d(t)),this.toggleCss("ag-sticky-label",!i.getColGroupDef()?.suppressStickyLabel)}destroy(){super.destroy(),this.innerHeaderGroupComponent&&(this.destroyBean(this.innerHeaderGroupComponent),this.innerHeaderGroupComponent=void 0)}}},icons:{columnGroupOpened:"expanded",columnGroupClosed:"contracted"}},tu={moduleName:"AnimationFrame",version:qe,beans:[class extends Me{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&&st(92)}createTask(e,t,o,i,s=!1){this.verify();let n=o;i&&this.batchFrameworkComps&&(n="f1");const r={task:e,index:t,createOrder:++this.taskCount,deferred:s};this.addTaskToList(this[n],r),this.schedule()}addTaskToList(e,t){e.list.push(t),e.sorted=!1}sortTaskList(e){if(e.sorted)return;const t=this.scrollGoingDown?1:-1;e.list.sort((e,o)=>e.deferred!==o.deferred?e.deferred?-1:1:e.index!==o.index?t*(o.index-e.index):o.createOrder-e.createOrder),e.sorted=!0}addDestroyTask(e){this.verify(),this.destroyTasks.push(e),this.schedule()}executeFrame(e){const{p1:t,p2:o,f1:i,destroyTasks:s,beans:n}=this,{ctrlsSvc:r,frameworkOverrides:a}=n,l=t.list,d=o.list,h=i.list,c=Date.now();let u=0;const g=e<=0,p=r.getScrollFeature();for(;g||u<e;){if(!p.scrollGridIfNeeded()){let n;if(l.length)this.sortTaskList(t),n=l.pop().task;else if(d.length)this.sortTaskList(o),n=d.pop().task;else if(h.length)a.wrapOutgoing(()=>{for(;g||u<e;){if(p.scrollGridIfNeeded())break;if(!h.length)break;this.sortTaskList(i),n=h.pop().task,n(),u=Date.now()-c}}),n=()=>{};else{if(!s.length)break;n=s.pop()}n()}u=Date.now()-c}l.length||d.length||h.length||s.length?this.requestFrame():this.ticking=!1}flushAllFrames(){this.active&&this.executeFrame(-1)}schedule(){this.active&&(this.ticking||(this.ticking=!0,this.requestFrame()))}requestFrame(){const e=this.executeFrame.bind(this,60);ue(this.beans,e)}isQueueEmpty(){return!this.ticking}}]},ou={moduleName:"Touch",version:qe,beans:[class extends Me{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(!Zi())return;this.mockContextMenu(e,e.element,(t,o,i)=>{const{rowCtrl:s,cellCtrl:n}=e.getControlsForEventTarget(i?.target??null);n?.column&&n.dispatchCellContextMenuEvent(i??null),this.beans.contextMenuSvc?.handleContextMenuMouseEvent(void 0,i,s,n)})}handleCellDoubleClick(e,t){return!!(()=>{if(!Zi()||be("dblclick"))return!1;const t=Date.now(),o=t-e.lastIPadMouseClickEvent<200;return e.lastIPadMouseClickEvent=t,o})()&&(e.onCellDoubleClicked(t),t.preventDefault(),!0)}setupForHeader(e){const{gos:t,sortSvc:i,menuSvc:s}=this.beans;if(t.get("suppressTouch"))return;const{params:n,eMenu:r,eFilterButton:a}=e,l=new Ol(e.getGui(),!0),d=e.shouldSuppressMenuHide(),h=d&&o(r)&&n.enableMenu,c=h?new Ol(r,!0):l;if(n.enableMenu||s?.isHeaderContextMenuEnabled(n.column)){const t=h?"tap":"longTap",o=e=>n.showColumnMenuAfterMouseClick(e.touchStart);e.addManagedListeners(c,{[t]:o})}if(n.enableSorting){const t=e=>{const t=e.touchStart.target;d&&(r?.contains(t)||a?.contains(t))||i?.progressSort(n.column,!1,"uiColumnSorted")};e.addManagedListeners(l,{tap:t})}if(n.enableFilterButton&&a){const t=new Ol(a,!0);e.addManagedListeners(t,{tap:()=>n.showFilter(a)}),e.addDestroyFunc(()=>t.destroy())}e.addDestroyFunc(()=>l.destroy()),h&&e.addDestroyFunc(()=>c.destroy())}setupForHeaderGroup(e){const t=e.params;if(this.beans.menuSvc?.isHeaderContextMenuEnabled(t.columnGroup.getProvidedColumnGroup())){const o=new Ol(t.eGridHeader,!0),i=e=>t.showColumnMenuAfterMouseClick(e.touchStart);e.addManagedListeners(o,{longTap:i}),e.addDestroyFunc(()=>o.destroy())}}setupForHeaderGroupElement(e,t,o){const i=new Ol(t,!0);e.addManagedListeners(i,{tap:o}),e.addDestroyFunc(()=>i.destroy())}mockContextMenu(e,t,o){if(!Zi())return;const i=new Ol(t);e.addManagedListeners(i,{longTap:e=>{Re(this.beans,e.touchEvent)&&o(void 0,e.touchStart,e.touchEvent)}}),e.addDestroyFunc(()=>i.destroy())}}]};var iu=class{constructor(){this.cellValidations=new Map}getCellValidation(e){const{rowNode:t,column:o}=e||{};return this.cellValidations?.get(t)?.get(o)}hasCellValidation(e){return e&&e.rowNode&&e.column?!!this.getCellValidation(e):this.cellValidations.size>0}setCellValidation(e,t){const{rowNode:o,column:i}=e;this.cellValidations.has(o)||this.cellValidations.set(o,new Map),this.cellValidations.get(o).set(i,t)}clearCellValidation(e){const{rowNode:t,column:o}=e;this.cellValidations.get(t)?.delete(o)}setCellValidationMap(e){this.cellValidations=e}getCellValidationMap(){return this.cellValidations}clearCellValidationMap(){this.cellValidations.clear()}},su=class{constructor(){this.rowValidations=new Map}getRowValidation(e){const{rowNode:t}=e||{};return this.rowValidations.get(t)}hasRowValidation(e){return e&&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 nu(e,t={}){const{rowIndex:o,rowId:i,rowCtrl:s,rowPinned:n}=t;if(s)return s;const{rowModel:r,rowRenderer:a}=e;let{rowNode:l}=t;return l||(i?l=function(e,t,o){const{rowModel:i,pinnedRowModel:s}=e;let n;return n??(n=i?.getRowNode(t)),o?n??(n=s?.getPinnedRowById(t,o)):(n??(n=s?.getPinnedRowById(t,"top")),n??(n=s?.getPinnedRowById(t,"bottom"))),n}(e,i,n):null!=o&&(l=r.getRow(o))),a.getRowCtrls(l?[l]:[])?.[0]}function ru(e,t={}){const{cellCtrl:o,colId:i,columnId:s,column:n}=t;if(o)return o;const r=e.colModel.getCol(i??s??lu(n)),a=t.rowCtrl??nu(e,t),l=a?.getCellCtrl(r)??void 0;if(l)return l;const d=t.rowNode??a?.rowNode;return d?e.rowRenderer.getCellCtrls([d],[r])?.[0]:void 0}function au(e){const{editSvc:t}=e;t?.isBatchEditing()?wu(e):t?.stopEditing(void 0,{source:"api"})}function lu(e){if(e)return"string"==typeof e?e:e.getColId()}var du=Symbol("unedited");function hu(e,t={}){const o=[],i=e.rowRenderer.getCellCtrls(t.rowNodes,t.columns);for(const e of i){const t=e.comp?.getCellEditor();t&&o.push({ctrl:e,editor:fi(t)})}return o}function cu({pendingValue:e,sourceValue:t}){return e===du&&(e=t),e!==t}function uu(e,t,o){const i=e.gos.get("enableGroupEdit"),{key:s,event:n,cellStartedEdit:r,silent:a}=o??{},l=ru(e,t),d=l?.comp?.getCellEditor(),h=pu(e,t,s,r&&!a),c=e.editModelSvc?.getEdit(t);let u=h.value;if(void 0===u&&(u=c?.sourceValue),e.editModelSvc?.setEdit(t,{editorValue:u,state:"editing"}),d)return void d.refresh?.(h);const g=t.column.getColDef(),p=gi(e.userCompFactory,g,h),m=null!=p?.popupFromSelector?p.popupFromSelector:!!g.cellEditorPopup,f=null!=p?.popupPositionFromSelector?p.popupPositionFromSelector:g.cellEditorPopupPosition;if(fu(p.params,n),l){l.editCompDetails=p,l.comp?.setEditDetails(p,m,f,e.gos.get("reactiveCustomComponents")),l?.rowCtrl?.refreshRow({suppressFlash:!0});const o=e.editModelSvc?.getEdit(t,!0);a||o?.editorState?.cellStartedEditing||(e.editSvc?.dispatchCellEvent(t,n,"cellEditingStarted",i?{value:u}:{}),e.editModelSvc?.setEdit(t,{editorState:{cellStartedEditing:!0}}))}}function gu(e,t,o){const i={editorValueExists:!1};if(Eu(e)){const e=t.getValidationErrors?.();if((e?.length??0)>0)return i}if(o?.isCancelling)return i;if(o?.isStopping){const e=t?.isCancelAfterEnd?.();if(e)return{...i,isCancelAfterEnd:e}}return{editorValue:t.getValue(),editorValueExists:!0}}function pu(e,t,o,i){const{valueSvc:s,gos:n,editSvc:r}=e,a=e.gos.get("enableGroupEdit"),l=ru(e,t),d=t.rowNode?.rowIndex??void 0,h=r?.isBatchEditing(),c=e.colModel.getCol(t.column.getId()),{rowNode:u,column:g}=t,p=l.comp?.getCellEditor(),m=r?.getCellDataValue(t,!1)??(p?gu(e,p)?.editorValue:void 0),f=m===du?s.getValueForDisplay(c,u)?.value:m;return zt(n,{value:a?m:f,eventKey:o??null,column:g,colDef:g.getColDef(),rowIndex:d,node:u,data:u.data,cellStartedEdit:i??!1,onKeyDown:l?.onKeyDown.bind(l),stopEditing:o=>{r.stopEditing(t,{source:h?"ui":"api",suppressNavigateAfterEdit:o}),bu(e,t)},eGridCell:l?.eGui,parseValue:e=>s.parseValue(c,u,e,l?.value),formatValue:l?.formatValue.bind(l),validate:()=>{r?.validateEdit()}})}function mu(e,t){const{editModelSvc:o}=e;o?.getEditMap().forEach((e,i)=>{e.forEach((e,s)=>{(t||"editing"!==e.state&&e.pendingValue!==du)&&(cu(e)||"editing"===e.state&&!t||o?.removeEdits({rowNode:i,column:s}))})})}function fu(e,t){return t instanceof KeyboardEvent&&"agNumberCellEditor"===e.column.getColDef().cellEditor?e.suppressPreventDefault=["-","+",".","e"].includes(t?.key??"")||e.suppressPreventDefault:t?.preventDefault?.(),e}function Cu(e,t){e.editModelSvc?.getEditPositions().forEach(o=>{const i=ru(e,o);if(!i)return;const s=i.comp?.getCellEditor();if(!s)return;const{editorValue:n,editorValueExists:r,isCancelAfterEnd:a}=gu(e,s,t);a&&e.editModelSvc?.setEdit(o,{editorState:{isCancelAfterEnd:a}}),vu(e,o,n,void 0,!r,t)})}function vu(e,t,o,i,s,n){const{editModelSvc:r,valueSvc:a}=e;if(!r)return;const{rowNode:l,column:d}=t;if(!l||!d)return;let h=r.getEdit(t,!0);h?.sourceValue||(h=r.setEdit(t,{sourceValue:a.getValue(d,l,void 0,"api"),pendingValue:h?h.editorValue:du})),r.setEdit(t,{editorValue:s?h.sourceValue:o}),n?.persist&&function(e,t){const{editModelSvc:o}=e,i=o?.getEdit(t,!0);o?.setEdit(t,{pendingValue:i?.editorValue})}(e,t)}function wu(e,t,o){t||(t=e.editModelSvc?.getEditPositions()),t.forEach(t=>bu(e,t,o))}function bu(e,t,o){const i=e.gos.get("enableGroupEdit"),{editModelSvc:s}=e,n=ru(e,t),r=s?.getEdit(t,!0);if(!n)return void(r&&s?.setEdit(t,{state:"changed"}));const{comp:a}=n;if(a&&!a.getCellEditor()){if(n?.refreshCell(),r){s?.setEdit(t,{state:"changed"});Su(e,t,i?yu(o,r):{valueChanged:!1,newValue:void 0,oldValue:r.sourceValue},o)}return}if(Eu(e)){const e=a?.getCellEditor()?.getValidationErrors?.(),o=s?.getCellValidationModel();e?.length?o?.setCellValidation(t,{errorMessages:e}):o?.clearCellValidation(t)}s?.setEdit(t,{state:"changed"}),a?.setEditDetails(),a?.refreshEditStyles(!1,!1),n?.refreshCell({force:!0,suppressFlash:!0});const l=s?.getEdit(t);if(l&&"changed"===l.state){Su(e,t,i?yu(o,l):{valueChanged:cu(l)&&!o?.cancel,newValue:o?.cancel||l.editorState.isCancelAfterEnd?void 0:l?.editorValue??r?.pendingValue,oldValue:l?.sourceValue},o)}}function yu(e,t){return e?.cancel?{valueChanged:!1,oldValue:t.sourceValue,newValue:void 0,value:t.sourceValue}:{valueChanged:!1,oldValue:t.sourceValue,newValue:t.pendingValue,value:t.sourceValue}}function Su(e,t,o,{silent:i,event:s}={}){const{editSvc:n,editModelSvc:r}=e,a=r?.getEdit(t),{editorState:l}=a||{},{isCancelBeforeStart:d}=l||{};i||d||(n?.dispatchCellEvent(t,s,"cellEditingStopped",o),r?.setEdit(t,{editorState:{cellStoppedEditing:!0}}))}function Eu(e){const{gos:t,colModel:o}=e,i=!!t.get("getFullRowEditValidationErrors"),s=o.getColumnDefs()?.filter(e=>e.editable).some(({cellEditorParams:e})=>{const{minLength:t,maxLength:o,getValidationErrors:i,min:s,max:n}=e||{};return void 0!==t||void 0!==o||void 0!==i||void 0!==s||void 0!==n}),n=e.gridApi.getCellEditorInstances().some(e=>e.getValidationElement||e.getValidationErrors);return s||i||n}function Ru(e,t){if(!t&&!Eu(e))return;const o=hu(e),i=new iu,{ariaAnnounce:s,localeSvc:n,editModelSvc:r,gos:a}=e,l="fullRow"===a.get("editType"),d=Pe(n)("ariaValidationErrorPrefix","Cell Editor Validation");for(const e of o){const{ctrl:t,editor:o}=e,{rowNode:n,column:r}=t,a=o.getValidationErrors?.()??[],l=o.getValidationElement?.(!1)||!o.isPopup?.()&&t.eGui;if(l){const e=null!=a&&a.length>0,t=e?a.join(". "):"";x(l,e),e&&s.announceValue(`${d} ${a}`,"editorValidation"),l instanceof HTMLInputElement?l.setCustomValidity(t):l.classList.toggle("invalid",e)}a?.length>0&&i.setCellValidation({rowNode:n,column:r},{errorMessages:a})}Cu(e,{persist:!1}),r?.setCellValidationModel(i);const h=new Set;for(const{ctrl:e}of o)h.add(e.rowCtrl);if(l){const t=xu(e);r?.setRowValidationModel(t)}for(const e of h.values()){e.rowEditStyleFeature?.applyRowStyles();for(const t of e.getAllCellCtrls())t.tooltipFeature?.refreshTooltip(!0),t.editorTooltipFeature?.refreshTooltip(!0),t.editStyleFeature?.applyCellStyles?.()}}var xu=e=>{const t=new su,o=e.gos.get("getFullRowEditValidationErrors"),i=e.editModelSvc?.getEditMap();if(!i)return t;for(const e of i.keys()){const s=i.get(e);if(!s)continue;const n=[],{rowIndex:r,rowPinned:a}=e;for(const e of s.keys()){const t=s.get(e);if(!t)continue;const{editorValue:o,pendingValue:i,sourceValue:l}=t,d=o??(i===du?void 0:i)??l;n.push({column:e,colId:e.getColId(),rowIndex:r,rowPinned:a,oldValue:l,newValue:d})}const l=o?.({editorsState:n})??[];l.length>0&&t.setRowValidation({rowNode:e},{errorMessages:l})}return t};var Fu=class extends Me{constructor(e,t,o,i){super(),this.cellCtrl=e,this.rowNode=o,this.rowCtrl=i,this.beans=t}init(){this.eGui=this.cellCtrl.eGui}onKeyDown(e){const t=e.key;switch(t){case Pi:this.onEnterKeyDown(e);break;case Bi:this.onF2KeyDown(e);break;case Di:this.onEscapeKeyDown(e);break;case Fi:this.onTabKeyDown(e);break;case xi:case Li:this.onBackspaceOrDeleteKeyDown(t,e);break;case Ai:case Ti:case Ii:case ki:this.onNavigationKeyDown(e,t)}}onNavigationKeyDown(e,t){const{cellCtrl:o,beans:i}=this;if(!i.editSvc?.isEditing(o,{withOpenEditor:!0})){if(e.shiftKey&&o.isRangeSelectionEnabled())this.onShiftRangeSelect(e);else{const s=o.getFocusedCellPosition();i.navigation?.navigateToNextCell(e,t,s,!0)}e.preventDefault()}}onShiftRangeSelect(e){const{rangeSvc:t,navigation:o}=this.beans;if(!t)return;const i=t.extendLatestRangeInDirection(e);i&&(e.key===ki||e.key===Ii?o?.ensureColumnVisible(i.column):o?.ensureRowVisible(i.rowIndex))}onTabKeyDown(e){this.beans.navigation?.onTabKeyDown(this.cellCtrl,e)}onBackspaceOrDeleteKeyDown(e,t){const{cellCtrl:o,beans:i,rowNode:s}=this,{gos:n,rangeSvc:r,eventSvc:a,editSvc:l}=i;if(a.dispatchEvent({type:"keyShortcutChangedCellStart"}),function(e,t=!1){return e===Li||!t&&e===xi&&Qi()}(e,n.get("enableCellEditingOnBackspace"))&&!l?.isEditing(o,{withOpenEditor:!0})){if(r&&Tt(n))r.clearCellRangeCellValues({dispatchWrapperEvents:!0,wrapperEventSource:"deleteKey"});else if(o.isCellEditable()){const{column:e}=o,t=this.beans.valueSvc.getDeleteValue(e,s);s.setDataValue(e,t,"cellClear")}}else l?.isEditing(o,{withOpenEditor:!0})||i.editSvc?.startEditing(o,{startedEdit:!0,event:t});a.dispatchEvent({type:"keyShortcutChangedCellEnd"})}onEnterKeyDown(e){const{cellCtrl:t,beans:o}=this,{editSvc:i,navigation:s}=o,n=i?.isEditing(t,{withOpenEditor:!0}),r=t.rowNode,a=i?.isRowEditing(r,{withOpenEditor:!0}),l=t=>{const o=i?.startEditing(t,{startedEdit:!0,event:e,source:"edit"});o&&e.preventDefault()};if(n||a){if(this.isCtrlEnter(e))return void i?.applyBulkEdit(t,o?.rangeSvc?.getCellRanges()||[]);if(Ru(o),"block-stop"===i?.checkNavWithValidation(void 0,e))return;i?.isEditing(t,{withOpenEditor:!0})?i?.stopEditing(t,{event:e,source:"edit"}):a&&!t.isCellEditable()?i?.stopEditing({rowNode:r},{event:e,source:"edit"}):l(t)}else if(o.gos.get("enterNavigatesVertically")){const o=e.shiftKey?Ti:Ai;s?.navigateToNextCell(null,o,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===Pi}onF2KeyDown(e){const{cellCtrl:t,beans:{editSvc:o}}=this,i=o?.isEditing();i&&(Ru(this.beans),"block-stop"===o?.checkNavWithValidation(void 0,e))||o?.startEditing(t,{startedEdit:!0,event:e})}onEscapeKeyDown(e){const{cellCtrl:t,beans:{editSvc:o}}=this;"block-stop"===o?.checkNavWithValidation(t,e)&&o.revertSingleCellEdit(t),o?.stopEditing(t,{event:e,cancel:!0})}processCharacter(e){const t=e.target!==this.eGui,{beans:{editSvc:o},cellCtrl:i}=this;if(t)return;if(o?.isEditing(i,{withOpenEditor:!0}))return;if(e.key===Mi)this.onSpaceKeyDown(e);else if(o?.isCellEditable(i,"ui")){if(o?.hasValidationErrors()&&!o?.hasValidationErrors(i))return;o?.startEditing(i,{startedEdit:!0,event:e,source:"api"});const t=i.editCompDetails;!t?.params?.suppressPreventDefault&&e.preventDefault()}}onSpaceKeyDown(e){const{gos:t,editSvc:o}=this.beans,{rowNode:i}=this.cellCtrl;!o?.isEditing(this.cellCtrl,{withOpenEditor:!0})&&ut(t)&&this.beans.selectionSvc?.handleSelectionEvent(e,i,"spaceKey"),e.preventDefault()}},Pu=class extends Me{constructor(e,t,o){super(),this.cellCtrl=e,this.column=o,this.beans=t}onMouseEvent(e,t){if(!Pr(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;const{eventSvc:t,rangeSvc:o,editSvc:i,editModelSvc:s,frameworkOverrides:n,gos:r}=this.beans,a=e.ctrlKey||e.metaKey,{cellCtrl:l}=this,{column:d,cellPosition:h,rowNode:c}=l,u=Nr(r,d,c,e);o&&a&&!u&&o.getCellRangeCount(h)>1&&o.intersectLastRange(!0);const g=l.createEvent(e,"cellClicked");g.isEventHandlingSuppressed=u,t.dispatchEvent(g);const p=d.getColDef();if(p.onCellClicked&&window.setTimeout(()=>{n.wrapOutgoing(()=>{p.onCellClicked(g)})},0),!u&&"editing"!==s?.getState(l)){const t=i?.isEditing(),o=s?.getCellValidationModel().getCellValidationMap().size??0,n=s?.getRowValidationModel().getRowValidationMap().size??0;if(t&&(o>0||n>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){const{column:t,beans:o,cellCtrl:i}=this,{eventSvc:s,frameworkOverrides:n,editSvc:r,editModelSvc:a,gos:l}=o,d=Nr(l,i.column,i.rowNode,e),h=t.getColDef(),c=i.createEvent(e,"cellDoubleClicked");if(c.isEventHandlingSuppressed=d,s.dispatchEvent(c),"function"==typeof h.onCellDoubleClicked&&window.setTimeout(()=>{n.wrapOutgoing(()=>{h.onCellDoubleClicked(c)})},0),!d&&r?.shouldStartEditing(i,e)&&"editing"!==a?.getState(i)){const t=r?.isEditing(),o=a?.getCellValidationModel().getCellValidationMap().size??0,s=a?.getRowValidationModel().getRowValidationMap().size??0;if(t&&(o>0||s>0))return;r?.startEditing(i,{event:e})}}onMouseDown(e){const{ctrlKey:t,metaKey:o,shiftKey:i}=e,s=e.target,{cellCtrl:n,beans:r}=this,{eventSvc:a,rangeSvc:l,rowNumbersSvc:d,focusSvc:h,gos:c,editSvc:u}=r,{column:g,rowNode:p,cellPosition:m}=n,f=Nr(c,g,p,e),C=()=>{const t=n.createEvent(e,"cellMouseDown");t.isEventHandlingSuppressed=f,a.dispatchEvent(t)};if(f)return void C();if(this.isRightClickInExistingRange(e))return;const v=l&&!l.isEmpty(),w=this.containsWidget(s),b=mo(g);if(d&&b&&!d.handleMouseDownOnCell(m,e))return l&&e.preventDefault(),void e.stopImmediatePropagation();if(!i||!v){const t=u?.isEditing(n),o=c.get("enableCellTextSelection")&&e.defaultPrevented,i=(_i()||o)&&!t&&!B(s)&&!w;n.focusCell(i,e)}if(i&&v&&!h.isCellFocused(m)){e.preventDefault();const t=h.getFocusedCell();if(t){const{column:o,rowIndex:i,rowPinned:s}=t;u?.isEditing(t)&&u?.stopEditing(t),h.setFocusedCell({column:o,rowIndex:i,rowPinned:s,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0,sourceEvent:e})}}if(!w){if(l){b&&e.preventDefault();const s=Ut(r,e)&&b;if(i)l.extendLatestRangeToCell(m);else if(!s){const e=t||o;l.setRangeToCell(m,e)}}C()}}isRightClickInExistingRange(e){const{rangeSvc:t}=this.beans;if(t){const o=t.isCellInAnyRange(this.cellCtrl.cellPosition),i=Ut(this.beans,e);if(o&&i)return!0}return!1}containsWidget(e){return G(e,"ag-selection-checkbox",3)||G(e,"ag-drag-handle",3)}onMouseOut(e){if(this.mouseStayingInsideCell(e))return;const{eventSvc:t,colHover:o}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOut")),o?.clearMouseOver()}onMouseOver(e){if(this.mouseStayingInsideCell(e))return;const{eventSvc:t,colHover:o}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOver")),o?.setMouseOver([this.column])}mouseStayingInsideCell(e){if(!e.target||!e.relatedTarget)return!1;const t=this.cellCtrl.eGui,o=t.contains(e.target),i=t.contains(e.relatedTarget);return o&&i}},Du=class extends Me{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;const e=this.cellCtrl.getCellSpan();if(e||(this.setupColSpan(),this.setupRowSpan()),this.onLeftChanged(),this.onWidthChanged(),e||this._legacyApplyRowSpan(),e){const t=this.refreshSpanHeight.bind(this,e);t(),this.addManagedListeners(this.beans.eventSvc,{paginationChanged:t,recalculateRowBounds:t,pinnedHeightChanged:t})}}refreshSpanHeight(e){const t=e.getCellHeight();null!=t&&(this.eContent.style.height=`${t}px`)}onNewColumnsLoaded(){const e=this.column.getRowSpan(this.rowNode);this.rowSpan!==e&&(this.rowSpan=e,this._legacyApplyRowSpan(!0))}onDisplayColumnsChanged(){const e=this.getColSpanningList();oo(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;const 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(){const{column:e,rowNode:t}=this,o=e.getColSpan(t),s=[];if(1===o)s.push(e);else{let t=e;const n=e.getPinned();for(let e=0;t&&e<o&&(s.push(t),t=this.beans.visibleCols.getColAfter(t),t&&!i(t))&&n===t.getPinned();e++);}return s}onLeftChanged(){if(!this.eSetLeft)return;const e=this.modifyLeftForPrintLayout(this.getCellLeft());this.eSetLeft.style.left=e+"px"}getCellLeft(){let e;return e=this.beans.gos.get("enableRtl")&&this.colsSpanning?to(this.colsSpanning):this.column,e.getLeft()}modifyLeftForPrintLayout(e){if(!this.cellCtrl.printLayout||"left"===this.column.getPinned())return e;const{visibleCols:t}=this.beans,o=t.getColsLeftWidth();if("right"===this.column.getPinned()){return o+t.bodyWidth+(e||0)}return o+(e||0)}_legacyApplyRowSpan(e){if(1===this.rowSpan&&!e)return;const t=mt(this.beans)*this.rowSpan;this.eContent.style.height=`${t}px`,this.eContent.style.zIndex="1"}destroy(){super.destroy()}},Mu=0,ku=class extends Me{constructor(e,t,o,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=o,this.gos=o.gos,this.editSvc=o.editSvc,this.hasEdit=!!o.editSvc;const{colId:s}=e;this.instanceId=s+"-"+Mu++,this.createCellPosition(),this.updateAndFormatValue(!1)}addFeatures(){const{beans:e}=this;this.positionFeature=new Du(this,e),this.customStyleFeature=e.cellStyles?.createCellCustomStyleFeature(this,e),this.editStyleFeature=e.editSvc?.createCellStyleFeature(this,e),this.mouseListener=new Pu(this,e,this.column),this.keyboardListener=new Fu(this,e,this.rowNode,this.rowCtrl),this.enableTooltipFeature();const{rangeSvc:t}=e;t&&Tt(e.gos)&&(this.rangeFeature=t.createCellRangeFeature(e,this)),mo(this.column)&&(this.rowResizeFeature=this.beans.rowNumbersSvc.createRowNumbersRowResizerFeature(e,this))}isCellSpanning(){return!1}getCellSpan(){}removeFeatures(){const 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),Ru(this.beans)}disableEditorTooltipFeature(){this.editorTooltipFeature=this.beans.context.destroyBean(this.editorTooltipFeature)}setComp(e,t,o,i,s,n,r){this.comp=e,this.eGui=t,this.printLayout=s,r??(r=this),this.addDomData(r),this.addFeatures(),r.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,r),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(),n&&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&&(this.onCompAttachedFuncs.forEach(e=>e()),this.onCompAttachedFuncs=[])}setupAutoHeight(e,t){this.isAutoHeight=this.beans.rowAutoHeight?.setupCellAutoHeight(this,e,t)??!1}getCellAriaRole(){return this.column.getColDef().cellAriaRole??"gridcell"}isCellRenderer(){const e=this.column.getColDef();return null!=e.cellRenderer||null!=e.cellRendererSelector}getValueToDisplay(){return this.valueFormatted??this.value}getDeferLoadingCellRenderer(){const{beans:e,column:t}=this,{userCompFactory:o,ctrlsSvc:i,eventSvc:s}=e,n=t.getColDef(),r=this.createCellRendererParams();r.deferRender=!0;const a=ui(o,n,r);if(i.getGridBodyCtrl()?.scrollFeature?.isScrolling()){let e;const t=new Ko(t=>{e=t});return this.addManagedListeners(s,{bodyScrollEnd:()=>e()}),{loadingComp:a,onReady:t}}return{loadingComp:a,onReady:Ko.resolve()}}showValue(e,t){const{beans:o,column:i,rowNode:s,rangeFeature:n}=this,{userCompFactory:r}=o;let a,l=this.getValueToDisplay();const d=s.stub&&null==s.groupData?.[i.getId()],h=i.getColDef();if(d||this.isCellRenderer()){const e=this.createCellRendererParams();a=!d||mo(i)?ci(r,h,e):ui(r,h,e)}if(!a&&!d&&o.findSvc?.isMatch(s,i)){const e=this.createCellRendererParams();a=ci(r,{...i.getColDef(),cellRenderer:"agFindCellRenderer"},e)}if(this.hasEdit&&this.editSvc.isBatchEditing()&&this.editSvc.isRowEditing(s,{checkSiblings:!0})){const e=this.editSvc.prepDetailsDuringBatch(this,{compDetails:a,valueToDisplay:l});e&&(e.compDetails?a=e.compDetails:e.valueToDisplay&&(l=e.valueToDisplay))}this.comp.setRenderDetails(a,l,e),this.customRowDragComp?.refreshVisibility(),!t&&n&&ue(o,()=>n?.refreshHandle()),this.rowResizeFeature?.refreshRowResizer()}setupControlComps(){const 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()}isIncludeControl(e,t=!1){return(null==this.rowNode.rowPinned||t&&Fl(this.rowNode))&&!!e}isCheckboxSelection(e){const{rowSelection:t,groupDisplayType:o}=this.beans.gridOptions,i=Mt(t),s=po(this.column);return("custom"!==o||"selectionColumn"===i||!s)&&(e.checkboxSelection||s&&"object"==typeof t&&Pt(t))}refreshShouldDestroy(){const e=this.column.getColDef(),t=this.includeSelection!=this.isIncludeControl(this.isCheckboxSelection(e),!0),o=this.includeRowDrag!=this.isIncludeControl(e.rowDrag),i=this.includeDndSource!=this.isIncludeControl(e.dndSource),s=this.isAutoHeight!=this.column.isAutoHeight();return t||o||i||s}onPopupEditorClosed(){const{editSvc:e}=this.beans;e?.isEditing(this,{withOpenEditor:!0})&&e?.stopEditing(this,{source:e?.isBatchEditing()?"ui":"api"})}stopEditing(e=!1){const{editSvc:t}=this.beans;return t?.stopEditing(this,{cancel:e,source:t?.isBatchEditing()?"ui":"api"})??!1}createCellRendererParams(){const{value:e,valueFormatted:t,column:o,rowNode:i,comp:s,eGui:n,beans:{valueSvc:r,gos:a,editSvc:l}}=this;return zt(a,{value:e,valueFormatted:t,getValue:()=>r.getValueForDisplay(o,i).value,setValue:e=>l?.setDataValue({rowNode:i,column:o},e)||i.setDataValue(o,e),formatValue:this.formatValue.bind(this),data:i.data,node:i,pinned:o.getPinned(),colDef:o.getColDef(),column:o,refreshCell:this.refreshCell.bind(this),eGridCell:n,eParentOfValue:s.getParentOfValue(),registerRowDragger:(e,t,o,i)=>this.registerRowDragger(e,t,i),setTooltip:(e,t)=>{a.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.editCompDetails){const{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:o}={}){if(this.suppressRefreshCell)return;const i=this.column.getColDef(),s=null==i.field&&null==i.valueGetter&&null==i.showRowGroup,n=e||s||o,r=!!this.comp,a=this.updateAndFormatValue(r);if(r){if(n||a){this.showValue(!!o,!1);const e=this.beans.filterManager?.isSuppressFlashingCellsBecauseFiltering();!t&&!e&&i.enableCellChangeFlash&&this.beans.cellFlashSvc?.flashCell(this),this.editStyleFeature?.applyCellStyles?.(),this.customStyleFeature?.applyUserStyles(),this.customStyleFeature?.applyClassesFromColDef()}this.tooltipFeature?.refreshTooltip(),this.customStyleFeature?.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){const t=this.value,o=this.valueFormatted,{value:i,valueFormatted:s}=this.beans.valueSvc.getValueForDisplay(this.column,this.rowNode,!0);return this.value=i,this.valueFormatted=s,!e||(!this.valuesAreEqual(t,this.value)||this.valueFormatted!=o)}valuesAreEqual(e,t){const o=this.column.getColDef();return o.equals?o.equals(e,t):e===t}addDomData(e){const t=this.eGui;vt(this.beans.gos,t,Wr,this),e.addDestroyFunc(()=>vt(this.beans.gos,t,Wr,null))}createEvent(e,t){const{rowNode:o,column:i,value:s,beans:n}=this;return function(e,t,o,{rowNode:i,column:s},n){return zt(e.gos,{type:o,node:i,data:i.data,value:n,column:s,colDef:s.getColDef(),rowPinned:i.rowPinned,event:t,rowIndex:i.rowIndex})}(n,e,t,{rowNode:o,column:i},s)}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(){const{comp:e,column:t,beans:o}=this;Fa(e,t,o.visibleCols)}refreshAriaColIndex(){const e=this.beans.visibleCols.getAriaColIndex(this.column);M(this.eGui,e)}onWidthChanged(){return this.positionFeature?.onWidthChanged()}getRowPosition(){const{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){const o=this.editSvc?.allowedFocusTargetOnValidation(this);o&&o!==this||this.beans.focusSvc.setFocusedCell({...this.getFocusedCellPosition(),forceBrowserFocus:e,sourceEvent:t})}restoreFocus(e=!1){const{beans:{editSvc:t,focusSvc:o},comp:i}=this;if(!i||t?.isEditing(this)||!this.isCellFocused()||!o.shouldTakeFocus())return;const s=()=>{if(!this.isAlive())return;const e=i.getFocusableElement();this.isCellFocused()&&e.focus({preventScroll:!0})};e?setTimeout(s,0):s()}onRowIndexChanged(){this.createCellPosition(),this.onCellFocused(),this.restoreFocus(),this.rangeFeature?.onCellSelectionChanged(),this.rowResizeFeature?.refreshRowResizer()}onSuppressCellFocusChanged(e){const t=this.eGui;t&&(mo(this.column)&&(e=!0),he(t,"tabindex",e?void 0:-1))}onFirstRightPinnedChanged(){if(!this.comp)return;const e=this.column.isFirstRightPinned();this.comp.toggleCss("ag-cell-first-right-pinned",e)}onLastLeftPinnedChanged(){if(!this.comp)return;const e=this.column.isLastLeftPinned();this.comp.toggleCss("ag-cell-last-left-pinned",e)}checkCellFocused(){return this.beans.focusSvc.isCellFocused(this.cellPosition)}isCellFocused(){const e=this.checkCellFocused();return this.hasBeenFocused||(this.hasBeenFocused=e),e}setupFocus(){this.restoreFocus(!0),this.onCellFocused(this.focusEventWhileNotReady??void 0)}onCellFocused(e){const{beans:t}=this;if(Da(t))return;if(!this.comp)return void(e&&(this.focusEventWhileNotReady=e));const o=this.isCellFocused(),i=t.editSvc?.isEditing(this)??!1;if(this.comp.toggleCss("ag-cell-focus",o),o&&e&&e.forceBrowserFocus){let t=this.comp.getFocusableElement();if(i){const e=ws(t,null,!0);e.length&&(t=e[0])}t.focus({preventScroll:!!e.preventScrollOnBrowserFocus})}o&&this.rowCtrl.announceDescription()}createCellPosition(){const{rowIndex:e,rowPinned:o}=this.rowNode;this.cellPosition={rowIndex:e,rowPinned:t(o),column:this.column}}applyStaticCssClasses(){const{comp:e}=this;e.toggleCss("ag-cell",!0),e.toggleCss("ag-cell-not-inline-editing",!0);const t=1==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(){const e=1==this.column.getColDef().wrapText;this.comp.toggleCss("ag-cell-wrap-text",e)}dispatchCellContextMenuEvent(e){const t=this.column.getColDef(),o=this.createEvent(e,"cellContextMenu"),{beans:i}=this;i.eventSvc.dispatchEvent(o),t.onCellContextMenu&&window.setTimeout(()=>{i.frameworkOverrides.wrapOutgoing(()=>{t.onCellContextMenu(o)})},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(u(this.beans))??!1}createSelectionCheckbox(){const e=this.beans.selectionSvc?.createCheckboxSelectionComponent();if(e)return this.beans.context.createBean(e),e.init({rowNode:this.rowNode,column:this.column}),e}createDndSource(){const e=this.beans.registry.createDynamicBean("dndSourceComp",!1,this.rowNode,this.column,this.eGui);return e&&this.beans.context.createBean(e),e}registerRowDragger(e,t,o){if(this.customRowDragComp)return void this.customRowDragComp.setDragElement(e,t);const i=this.createRowDragComp(e,t,o);i&&(this.customRowDragComp=i,this.addDestroyFunc(()=>{this.beans.context.destroyBean(i),this.customRowDragComp=null}),i.refreshVisibility())}createRowDragComp(e,t,o){const i=this.beans.rowDragSvc?.createRowDragCompForCell(this.rowNode,this.column,()=>this.value,e,t,o);if(i)return this.beans.context.createBean(i),i}cellEditorAttached(){this.onEditorAttachedFuncs.forEach(e=>e()),this.onEditorAttachedFuncs=[]}setFocusedCellPosition(e){}getFocusedCellPosition(){return this.cellPosition}refreshAriaRowIndex(){}getRootElement(){return this.eGui}};function Tu(e,t,o,i,s,n){if(null==o&&null==t)return;const r={},a={},l=(e,t)=>{e.split(" ").forEach(e=>{""!=e.trim()&&t(e)})};if(o){const t=Object.keys(o);for(let s=0;s<t.length;s++){const n=t[s],d=o[n];let h;"string"==typeof d?h=!e||e.evaluate(d,i):"function"==typeof d&&(h=d(i)),l(n,e=>{h?r[e]=!0:a[e]=!0})}}t&&n&&Object.keys(t).forEach(e=>l(e,e=>{r[e]||(a[e]=!0)})),n&&Object.keys(a).forEach(n),Object.keys(r).forEach(s)}function Iu(e){if(e.group)return e.level;const t=e.parent;return t?t.level+1:0}var Au=0,Lu=class extends Me{constructor(e,t,o,i,s){super(),this.rowNode=e,this.useAnimationFrameForCreate=i,this.printLayout=s,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+"-"+Au++,this.rowId=h(e.id),this.initRowBusinessKey(),this.rowFocused=t.focusSvc.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned),this.rowLevel=Iu(this.rowNode),this.setRowType(),this.setAnimateFlags(o),this.rowStyles=this.processStylesFromGridOptions(),this.rowEditStyleFeature=t.editSvc?.createRowStyleFeature(this,t),this.addListeners()}initRowBusinessKey(){this.businessKeyForNodeFunc=this.gos.get("getBusinessKeyForNode"),this.updateRowBusinessKey()}updateRowBusinessKey(){if("function"!=typeof this.businessKeyForNodeFunc)return;const e=this.businessKeyForNodeFunc(this.rowNode);this.businessKey=h(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,o,i){const{context:s,focusSvc:n}=this.beans,r={rowComp:e,element:t,containerType:o,compBean:i=Vo(this,s,i)};this.allRowGuis.push(r),this.updateGui(o,r),this.initialiseRowComp(r);const a=this.rowNode,l="FullWidthLoading"===this.rowType||a.stub,d=!a.data&&"infinite"===this.beans.rowModel.getType();l||d||a.rowPinned||this.beans.rowRenderer.dispatchFirstDataRenderedEvent();const h=this.fullWidthGui?.element;if(h){const e=this.beans.editSvc?.isEditing(this);!e&&n.isRowFocused(a.rowIndex,a.rowPinned)&&n.shouldTakeFocus()&&setTimeout(()=>h.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){const t=e?"none":"";this.allRowGuis.forEach(e=>e.element.style.display=t)}initialiseRowComp(e){const 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),ut(t)&&this.rowNode.selectable&&this.onRowSelected(e),this.updateColumnLists(!this.useAnimationFrameForCreate);const o=e.rowComp;this.getInitialRowClasses(e.containerType).forEach(e=>o.toggleCss(e,!0)),this.executeSlideAndFadeAnimations(e),this.rowNode.group&&P(e.element,1==this.rowNode.expanded),this.setRowCompRowId(o),this.setRowCompRowBusinessKey(o),vt(t,e.element,$r,this),e.compBean.addDestroyFunc(()=>vt(t,e.element,$r,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){const t=h(this.rowNode.id);this.rowId=t,null!=t&&e.setRowId(t)}executeSlideAndFadeAnimations(e){const{containerType:t}=e;this.slideInAnimation[t]&&(Le(()=>{this.onTopChanged()}),this.slideInAnimation[t]=!1);this.fadeInAnimation[t]&&(Le(()=>{e.rowComp.toggleCss("ag-opacity-zero",!1)}),this.fadeInAnimation[t]=!1)}addRowDraggerToRow(e){const t=this.beans.rowDragSvc?.createRowDragCompForRow(this.rowNode,e.element);if(!t)return;const o=this.createBean(t,this.beans.context);this.rowDragComps.push(o),e.compBean.addDestroyFunc(()=>{this.rowDragComps=this.rowDragComps.filter(e=>e!==o),this.rowEditStyleFeature=this.destroyBean(this.rowEditStyleFeature,this.beans.context),this.destroyBean(o,this.beans.context)})}setupFullWidth(e){const t=this.getPinnedForContainer(e.containerType),o=this.createFullWidthCompDetails(e.element,t);e.rowComp.showFullWidth(o)}getFullWidthCellRenderers(){return this.gos.get("embedFullWidthRows")?this.allRowGuis.map(e=>e?.rowComp?.getFullWidthCellRenderer()):[this.fullWidthGui?.rowComp?.getFullWidthCellRenderer()]}executeProcessRowPostCreateFunc(){const e=this.gos.getCallback("processRowPostCreate");if(!e||!this.areAllContainersReady())return;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(){const{leftGui:e,centerGui:t,rightGui:o,beans:{visibleCols:i}}=this,s=!!e||!i.isPinningLeft(),n=!!t,r=!!o||!i.isPinningRight();return s&&n&&r}isNodeFullWidthCell(){if(this.rowNode.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return!!e&&e({rowNode:this.rowNode})}setRowType(){const e=this.rowNode.stub&&!this.gos.get("suppressServerSideFullWidthLoadingRow")&&!this.gos.get("groupHideOpenParents"),t=this.isNodeFullWidthCell(),o=this.gos.get("masterDetail")&&this.rowNode.detail,i=this.beans.colModel.isPivotMode(),s=xt(this.gos,this.rowNode,i);this.rowType=e?"FullWidthLoading":o?"FullWidthDetail":t?"FullWidth":s?"FullWidthGroup":"Normal"}updateColumnLists(e=!1,t=!1){if(this.isFullWidth())return;const{animationFrameSvc:o}=this.beans;!o?.active||e||this.printLayout?this.updateColumnListsImpl(t):this.updateColumnListsPending||(o.createTask(()=>{this.active&&this.updateColumnListsImpl(!0)},this.rowNode.rowIndex,"p1",!1),this.updateColumnListsPending=!0)}getNewCellCtrl(e){const t=this.beans.rowSpanSvc?.isCellSpanning(e,this.rowNode);if(!t)return new ku(e,this.rowNode,this.beans,this)}isCorrectCtrlForSpan(e){return!this.beans.rowSpanSvc?.isCellSpanning(e.column,this.rowNode)}createCellCtrls(e,t,o=null){const i={list:[],map:{}},s=(e,t,o)=>{null!=o?i.list.splice(o,0,t):i.list.push(t),i.map[e]=t},n=[];for(const o of t){const t=o.getInstanceId();let i=e.map[t];i&&!this.isCorrectCtrlForSpan(i)&&(i.destroy(),i=void 0),i||(i=this.getNewCellCtrl(o)),i&&s(t,i)}for(const t of e.list){const e=t.column.getInstanceId();if(null!=i.map[e])continue;!this.isCellEligibleToBeRemoved(t,o)?n.push([e,t]):t.destroy()}if(n.length)for(const[e,t]of n){const o=i.list.findIndex(e=>e.column.getLeft()>t.column.getLeft()),n=-1===o?void 0:Math.max(o-1,0);s(e,t,n)}const{focusSvc:r,visibleCols:a}=this.beans,l=r.getFocusedCell();if(l&&l.column.getPinned()==o){const e=l.column.getInstanceId();if(!i.map[e]&&a.allCols.includes(l.column)){const t=this.createFocusedCellCtrl();if(t){const o=i.list.findIndex(e=>e.column.getLeft()>t.column.getLeft()),n=-1===o?void 0:Math.max(o-1,0);s(e,t,n)}}}return i}createFocusedCellCtrl(){const{focusSvc:e,rowSpanSvc:t}=this.beans,o=e.getFocusedCell();if(!o)return;const i=t?.getCellSpan(o.column,this.rowNode);if(i){if(i.firstNode!==this.rowNode||!i.doesSpanContain(o))return}else if(!e.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned))return;return this.getNewCellCtrl(o.column)}updateColumnListsImpl(e){this.updateColumnListsPending=!1,this.createAllCellCtrls(),this.setCellCtrls(e)}setCellCtrls(e){this.allRowGuis.forEach(t=>{const o=this.getCellCtrlsForContainer(t.containerType);t.rowComp.setCellCtrls(o,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(){const 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{const o=e.getColsWithinViewport(this.rowNode);this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,o);const i=t.getLeftColsForRow(this.rowNode);this.leftCellCtrls=this.createCellCtrls(this.leftCellCtrls,i,"left");const s=t.getRightColsForRow(this.rowNode);this.rightCellCtrls=this.createCellCtrls(this.rightCellCtrls,s,"right")}}isCellEligibleToBeRemoved(e,t){const o=!0,{column:i}=e;if(i.getPinned()!=t)return o;if(!this.isCorrectCtrlForSpan(e))return o;const{visibleCols:s,editSvc:n}=this.beans,r=n?.isEditing(e),a=e.isCellFocused();if(r||a){return!(s.allCols.indexOf(i)>=0)&&o}return o}getDomOrder(){return this.gos.get("ensureDomOrder")||ct(this.gos,"print")}listenOnDomOrder(e){e.compBean.addManagedPropertyListeners(["domLayout","ensureDomOrder"],()=>{e.rowComp.setDomOrder(this.getDomOrder())})}setAnimateFlags(e){if(this.rowNode.sticky||!e)return;const t=o(this.rowNode.oldRowTop),{visibleCols:i}=this.beans,s=i.isPinningLeft(),n=i.isPinningRight();if(t){const{slideInAnimation:e}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows"))return void(e.fullWidth=!0);e.center=!0,e.left=s,e.right=n}else{const{fadeInAnimation:e}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows"))return void(e.fullWidth=!0);e.center=!0,e.left=s,e.right=n}}isFullWidth(){return"Normal"!==this.rowType}refreshFullWidth(){const e=(e,t)=>!e||e.rowComp.refreshFullWidth(()=>this.createFullWidthCompDetails(e.element,t).params),t=e(this.fullWidthGui,null),o=e(this.centerGui,null),i=e(this.leftGui,"left"),s=e(this.rightGui,"right");return t&&o&&i&&s}addListeners(){const{beans:e,gos:t,rowNode:o}=this,{expansionSvc:i,eventSvc:s,context:n,rowSpanSvc:r}=e;this.addManagedListeners(this.rowNode,{heightChanged:()=>this.onRowHeightChanged(),rowSelected:()=>this.onRowSelected(),rowIndexChanged:this.onRowIndexChanged.bind(this),topChanged:this.onTopChanged.bind(this),...i?.getRowExpandedListeners(this)??{}}),o.detail&&this.addManagedListeners(o.parent,{dataChanged:this.onRowNodeDataChanged.bind(this)}),this.addManagedListeners(o,{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(s,{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()}),r&&this.addManagedListeners(r,{spannedCellsUpdated:({pinned:e})=>{e&&!o.rowPinned||this.updateColumnLists()}}),this.addDestroyFunc(()=>{this.rowDragComps=this.destroyBeans(this.rowDragComps,n),this.tooltipFeature=this.destroyBean(this.tooltipFeature,n),this.rowEditStyleFeature=this.destroyBean(this.rowEditStyleFeature,n)}),this.addManagedPropertyListeners(["rowStyle","getRowStyle","rowClass","getRowClass","rowClassRules"],this.postProcessCss.bind(this)),this.addManagedPropertyListener("rowDragEntireRow",()=>{t.get("rowDragEntireRow")?this.allRowGuis.forEach(e=>{this.addRowDraggerToRow(e)}):this.rowDragComps=this.destroyBeans(this.rowDragComps,n)}),this.addListenersForCellComps()}addListenersForCellComps(){this.addManagedListeners(this.rowNode,{rowIndexChanged:()=>this.getAllCellCtrls().forEach(e=>e.onRowIndexChanged()),cellChanged:e=>this.getAllCellCtrls().forEach(t=>t.onCellChanged(e))})}onRowPinned(){for(const 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())this.beans.rowRenderer.redrawRow(this.rowNode);else{if(this.isFullWidth()){return void(this.refreshFullWidth()||this.beans.rowRenderer.redrawRow(this.rowNode))}this.getAllCellCtrls().forEach(t=>t.refreshCell(e)),this.allRowGuis.forEach(e=>{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(){const e=this.beans.rowDropHighlightSvc,t=e?.row===this.rowNode?e.position:"none",o="above"===t,i="inside"===t,s="below"===t,n=this.gos.get("treeData")&&(s||o),r=this.rowNode.uiLevel.toString();this.allRowGuis.forEach(e=>{const t=e.rowComp;t.toggleCss("ag-row-highlight-above",o),t.toggleCss("ag-row-highlight-inside",i),t.toggleCss("ag-row-highlight-below",s),t.toggleCss("ag-row-highlight-indent",n),n?e.element.style.setProperty("--ag-row-highlight-level",r):e.element.style.removeProperty("--ag-row-highlight-level")})}postProcessRowDragging(){const e=this.rowNode.dragging;this.allRowGuis.forEach(t=>t.rowComp.toggleCss("ag-row-dragging",e))}onDisplayedColumnsChanged(){this.updateColumnLists(!0),this.beans.rowAutoHeight?.requestCheckAutoHeight()}onVirtualColumnsChanged(){this.updateColumnLists(!1,!0)}getRowPosition(){return{rowPinned:t(this.rowNode.rowPinned),rowIndex:this.rowNode.rowIndex}}onKeyboardNavigate(e){const t=this.findFullWidthInfoForEvent(e);if(!t)return;const{rowGui:o,column:i}=t;if(!(o.element===e.target))return;const s=this.rowNode,{focusSvc:n,navigation:r}=this.beans,a=n.getFocusedCell(),l={rowIndex:s.rowIndex,rowPinned:s.rowPinned,column:a?.column??i};r?.navigateToNextCell(e,e.key,l,!0),e.preventDefault()}onTabKeyDown(e){if(e.defaultPrevented||Pr(e))return;const t=this.allRowGuis.find(t=>t.element.contains(e.target)),o=t?t.element:null,i=o===e.target,s=u(this.beans);let n=!1;o&&s&&(n=o.contains(s)&&s.classList.contains("ag-cell"));let r=null;i||n||(r=ys(this.beans,o,!1,e.shiftKey)),(this.isFullWidth()&&i||!r)&&this.beans.navigation?.onTabKeyDown(this,e)}getFullWidthElement(){return this.fullWidthGui?this.fullWidthGui.element:null}getRowYPosition(){const e=this.allRowGuis.find(e=>Q(e.element))?.element;return e?e.getBoundingClientRect().top:0}onSuppressCellFocusChanged(e){const t=this.isFullWidth()&&e?void 0:this.gos.get("tabIndex");this.allRowGuis.forEach(e=>{he(e.element,"tabindex",t)})}onFullWidthRowFocused(e){const t=this.rowNode,o=!!e&&(this.isFullWidth()&&e.rowIndex===t.rowIndex&&e.rowPinned==t.rowPinned);let i;if(this.fullWidthGui)i=this.fullWidthGui.element;else{const t=this.beans.colModel.getCol(e?.column),o=t?.pinned;i=o?"right"===o?this.rightGui?.element:this.leftGui?.element:this.centerGui?.element}i&&(i.classList.toggle("ag-full-width-focus",o),o&&e?.forceBrowserFocus&&i.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){const o={list:[],map:{}};return e.list.forEach(e=>{e!==t&&(o.list.push(e),o.map[e.column.getInstanceId()]=e)}),o}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){const{rowNode:o}=this;return zt(this.gos,{type:e,node:o,data:o.data,rowIndex:o.rowIndex,rowPinned:o.rowPinned,event:t})}createRowEventWithSource(e,t){const o=this.createRowEvent(e,t);return o.source=this,o}onRowDblClick(e){if(Pr(e))return;const t=this.createRowEventWithSource("rowDoubleClicked",e);t.isEventHandlingSuppressed=this.isSuppressMouseEvent(e),this.beans.eventSvc.dispatchEvent(t)}findFullWidthInfoForEvent(e){if(!e)return;const t=this.findFullWidthRowGui(e.target),o=this.getColumnForFullWidth(t);return t&&o?{rowGui:t,column:o}:void 0}findFullWidthRowGui(e){return this.allRowGuis.find(t=>t.element.contains(e))}getColumnForFullWidth(e){const{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=G(e.target,"ag-row-drag",3),!this.isFullWidth()||this.isSuppressMouseEvent(e))return;const{rangeSvc:t,focusSvc:o}=this.beans;t?.removeAllCellRanges();const i=this.findFullWidthInfoForEvent(e);if(!i)return;const{rowGui:s,column:n}=i,r=s.element,a=e.target,l=this.rowNode;let d=e.defaultPrevented||_i();r&&r.contains(a)&&B(a)&&(d=!1),o.setFocusedCell({rowIndex:l.rowIndex,column:n,rowPinned:l.rowPinned,forceBrowserFocus:d})}isSuppressMouseEvent(e){const{gos:t,rowNode:o}=this;if(this.isFullWidth()){const i=this.findFullWidthRowGui(e.target);return function(e,t,o,i){const s=t?.suppressMouseEventHandling;return Or(e,void 0,o,i,s)}(t,i?.rowComp.getFullWidthCellRendererParams(),o,e)}const i=Ur(t,e.target);return null!=i&&Nr(t,i.column,o,e)}onRowClick(e){if(Pr(e)||this.lastMouseDownOnDragger)return;const t=this.isSuppressMouseEvent(e),{eventSvc:o,selectionSvc:i}=this.beans,s=this.createRowEventWithSource("rowClicked",e);s.isEventHandlingSuppressed=t,o.dispatchEvent(s),t||i?.handleSelectionEvent(e,this.rowNode,"rowClicked")}setupDetailRowAutoHeight(e){"FullWidthDetail"===this.rowType&&this.beans.masterDetailSvc?.setupDetailRowAutoHeight(this,e)}createFullWidthCompDetails(e,t){const{gos:o,rowNode:i}=this,s=zt(o,{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,o,i)=>this.addFullWidthRowDragging(e,t,o,i),setTooltip:(e,t)=>{o.assertModuleRegistered("Tooltip",3),this.setupFullWidthRowTooltip(e,t)}}),n=this.beans.userCompFactory;switch(this.rowType){case"FullWidthDetail":return function(e,t){return e.getCompDetailsFromGridOptions(hi,"agDetailCellRenderer",t,!0)}(n,s);case"FullWidthGroup":{const{value:e,valueFormatted:t}=this.beans.valueSvc.getValueForDisplay(void 0,this.rowNode,!0);return s.value=e,s.valueFormatted=t,function(e,t){return e.getCompDetailsFromGridOptions(di,"agGroupRowRenderer",t,!0)}(n,s)}case"FullWidthLoading":return function(e,t){return e.getCompDetailsFromGridOptions(li,"agLoadingCellRenderer",t,!0)}(n,s);default:return function(e,t){return e.getCompDetailsFromGridOptions(ai,void 0,t,!0)}(n,s)}}setupFullWidthRowTooltip(e,t){this.fullWidthGui&&(this.tooltipFeature=this.beans.tooltipSvc?.setupFullWidthRowTooltip(this.tooltipFeature,this,e,t))}addFullWidthRowDragging(e,t,o="",i){const{rowDragSvc:s,context:n}=this.beans;if(!s||!this.isFullWidth())return;const r=s.createRowDragComp(()=>o,this.rowNode,void 0,e,t,i);this.createBean(r,n),this.addDestroyFunc(()=>{this.destroyBean(r,n)})}onUiLevelChanged(){const e=Iu(this.rowNode);if(this.rowLevel!=e){const t="ag-row-level-"+e,o="ag-row-level-"+this.rowLevel;this.allRowGuis.forEach(e=>{e.rowComp.toggleCss(t,!0),e.rowComp.toggleCss(o,!1)})}this.rowLevel=e}isFirstRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getFirstRow()}isLastRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getLastRow()}refreshFirstAndLastRowStyles(){const e=this.isFirstRowOnPage(),t=this.isLastRowOnPage();this.firstRowOnPage!==e&&(this.firstRowOnPage=e,this.allRowGuis.forEach(t=>t.rowComp.toggleCss("ag-row-first",e))),this.lastRowOnPage!==t&&(this.lastRowOnPage=t,this.allRowGuis.forEach(e=>e.rowComp.toggleCss("ag-row-last",t)))}getAllCellCtrls(){if(0===this.leftCellCtrls.list.length&&0===this.rightCellCtrls.list.length)return this.centerCellCtrls.list;return[...this.centerCellCtrls.list,...this.leftCellCtrls.list,...this.rightCellCtrls.list]}postProcessClassesFromGridOptions(){const e=[];this.beans.rowStyleSvc?.processClassesFromGridOptions(e,this.rowNode),e.length&&e.forEach(e=>{this.allRowGuis.forEach(t=>t.rowComp.toggleCss(e,!0))})}postProcessRowClassRules(){this.beans.rowStyleSvc?.processRowClassRules(this.rowNode,e=>{this.allRowGuis.forEach(t=>t.rowComp.toggleCss(e,!0))},e=>{this.allRowGuis.forEach(t=>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){const t=this.getPinnedForContainer(e),o=this.isFullWidth(),{rowNode:i,beans:s}=this,n=[];n.push("ag-row"),n.push(this.rowFocused?"ag-row-focus":"ag-row-no-focus"),this.fadeInAnimation[e]&&n.push("ag-opacity-zero"),n.push(i.rowIndex%2==0?"ag-row-even":"ag-row-odd"),i.isRowPinned()&&(n.push("ag-row-pinned"),s.pinnedRowModel?.isManual()&&n.push("ag-row-pinned-manual")),!i.isRowPinned()&&i.pinnedSibling&&n.push("ag-row-pinned-source"),i.isSelected()&&n.push("ag-row-selected"),i.footer&&n.push("ag-row-footer"),n.push("ag-row-level-"+this.rowLevel),i.stub&&n.push("ag-row-loading"),o&&n.push("ag-full-width-row"),s.expansionSvc?.addExpandedCss(n,i),i.dragging&&n.push("ag-row-dragging");const{rowStyleSvc:r}=s;return r&&(r.processClassesFromGridOptions(n,i),r.preProcessRowClassRules(n,i)),n.push(this.printLayout?"ag-row-position-relative":"ag-row-position-absolute"),this.isFirstRowOnPage()&&n.push("ag-row-first"),this.isLastRowOnPage()&&n.push("ag-row-last"),o&&("left"===t&&n.push("ag-cell-last-left-pinned"),"right"===t&&n.push("ag-cell-first-right-pinned")),n}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;const{element:t,compBean:o}=e,{rowNode:i,beans:s,gos:n}=this;o.addManagedListeners(t,{pointerenter:e=>{"mouse"===e.pointerType&&i.dispatchRowEvent("mouseEnter")},pointerleave:e=>{"mouse"===e.pointerType&&i.dispatchRowEvent("mouseLeave")}}),o.addManagedListeners(i,{mouseEnter:()=>{s.dragSvc?.dragging||n.get("suppressRowHoverHighlight")||(t.classList.add("ag-row-hover"),i.setHovered(!0))},mouseLeave:()=>{this.resetHoveredStatus(t)}})}resetHoveredStatus(e){const t=e?[e]:this.allRowGuis.map(e=>e.element);for(const e of t)e.classList.remove("ag-row-hover");this.rowNode.setHovered(!1)}roundRowTopToBounds(e){const t=this.beans.ctrlsSvc.getScrollFeature().getApproximateVScollPosition(),o=this.applyPaginationOffset(t.top,!0)-100,i=this.applyPaginationOffset(t.bottom,!0)+100;return Math.min(Math.max(o,e),i)}forEachGui(e,t){e?t(e):this.allRowGuis.forEach(t)}isRowRendered(){return this.allRowGuis.length>0}onRowHeightChanged(e){if(null==this.rowNode.rowHeight)return;const t=this.rowNode.rowHeight,o=this.beans.environment.getDefaultRowHeight(),i=gt(this.gos)?pt(this.beans,this.rowNode).height:void 0,s=i?Math.min(o,i)-2+"px":void 0;this.forEachGui(e,e=>{e.element.style.height=`${t}px`,s&&e.element.style.setProperty("--ag-line-height",s)})}destroyFirstPass(e=!1){this.active=!1;const{rowNode:t}=this;if(!e&&wt(this.gos)&&!t.sticky){if(null!=t.rowTop){const e=this.roundRowTopToBounds(t.rowTop);this.setRowTop(e)}else this.allRowGuis.forEach(e=>e.rowComp.toggleCss("ag-opacity-zero",!0))}this.fullWidthGui?.element.contains(u(this.beans))&&this.beans.focusSvc.attemptToRecoverFocus(),t.setHovered(!1);const o=this.createRowEvent("virtualRowRemoved");this.dispatchLocalEvent(o),this.beans.eventSvc.dispatchEvent(o),super.destroy()}destroySecondPass(){this.allRowGuis.length=0;const e=e=>(e.list.forEach(e=>e.destroy()),{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(){const{focusSvc:e}=this.beans,t=e.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned);t!==this.rowFocused&&(this.rowFocused=t,this.setFocusedClasses())}onPaginationChanged(){const 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){if(this.rowNode.isRowPinned()||this.rowNode.sticky)return e;return e+this.beans.pageBounds.getPixelOffset()*(t?1:-1)}setRowTop(e){if(!this.printLayout&&o(e)){const t=this.applyPaginationOffset(e),o=`${this.rowNode.isRowPinned()||this.rowNode.sticky?t:this.beans.rowContainerHeight.getRealPixelPosition(t)}px`;this.setRowTopStyle(o)}}getInitialRowTop(e){return this.suppressRowTransform?this.getInitialRowTopShared(e):void 0}getInitialTransform(e){return this.suppressRowTransform?void 0:`translateY(${this.getInitialRowTopShared(e)})`}getInitialRowTopShared(e){if(this.printLayout)return"";const t=this.rowNode;let o;if(t.sticky)o=t.stickyRowTop;else{const i=this.slideInAnimation[e]?this.roundRowTopToBounds(t.oldRowTop):t.rowTop,s=this.applyPaginationOffset(i);o=t.isRowPinned()?s:this.beans.rowContainerHeight.getRealPixelPosition(s)}return o+"px"}setRowTopStyle(e){this.allRowGuis.forEach(t=>this.suppressRowTransform?t.rowComp.setTop(e):t.rowComp.setTransform(`translateY(${e})`))}getCellCtrl(e,t=!1){let o=null;return this.getAllCellCtrls().forEach(t=>{t.column==e&&(o=t)}),null!=o||t||this.getAllCellCtrls().forEach(t=>{t?.getColSpanningList().indexOf(e)>=0&&(o=t)}),o}onRowIndexChanged(){null!=this.rowNode.rowIndex&&(this.onCellFocusChanged(),this.updateRowIndexes(),this.postProcessCss())}updateRowIndexes(e){const t=this.rowNode.getRowIndexString();if(null===t)return;const o=(this.beans.ctrlsSvc.getHeaderRowContainerCtrl()?.getRowCount()??0)+(this.beans.filterManager?.getHeaderRowCount()??0),i=this.rowNode.rowIndex%2==0,s=o+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),D(e.element,s)})}};function Bu(e){return e.ctrlsSvc.getScrollFeature().getVScrollPosition()}var Hu={moduleName:"KeyboardNavigation",version:qe,beans:[class extends Me{constructor(){super(),this.beanName="navigation",this.onPageDown=He(this.onPageDown,100),this.onPageUp=He(this.onPageUp,100)}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl})}handlePageScrollingKey(e,t=!1){const o=e.key,i=e.altKey,s=e.ctrlKey||e.metaKey,n=!!this.beans.rangeSvc&&e.shiftKey,r=function(e,t){return Ur(e,t.target)?.getFocusedCellPosition()??null}(this.gos,e);let a=!1;switch(o){case Gi:case Ni:s||i||(this.onHomeOrEndKey(o),a=!0);break;case ki:case Ii:case Ti:case Ai:if(!r)return!1;!s||i||n||(this.onCtrlUpDownLeftRight(o,r),a=!0);break;case Vi:case Hi:s||i||(a=this.handlePageUpDown(o,r,t))}return a&&e.preventDefault(),a}handlePageUpDown(e,t,o){return o&&(t=this.beans.focusSvc.getFocusedCell()),!!t&&(e===Hi?this.onPageUp(t):this.onPageDown(t),!0)}navigateTo({scrollIndex:e,scrollType:t,scrollColumn:i,focusIndex:s,focusColumn:n,isAsync:r,rowPinned:a}){const{scrollFeature:l}=this.gridBodyCon;o(i)&&!i.isPinned()&&l.ensureColumnVisible(i),o(e)&&l.ensureIndexVisible(e,t),r||l.ensureIndexVisible(s);const{focusSvc:d,rangeSvc:h}=this.beans;d.setFocusedCell({rowIndex:s,column:n,rowPinned:a,forceBrowserFocus:!0}),h?.setRangeToCell({rowIndex:s,rowPinned:a,column:n})}onPageDown(e){const t=this.beans,o=Bu(t),i=this.getViewportHeight(),{pageBounds:s,rowModel:n,rowAutoHeight:r}=t,a=s.getPixelOffset(),l=o.top+i,d=n.getRowIndexAtPixel(l+a);r?.active?this.navigateToNextPageWithAutoHeight(e,d):this.navigateToNextPage(e,d)}onPageUp(e){const t=this.beans,o=Bu(t),{pageBounds:i,rowModel:s,rowAutoHeight:n}=t,r=i.getPixelOffset(),a=o.top,l=s.getRowIndexAtPixel(a+r);n?.active?this.navigateToNextPageWithAutoHeight(e,l,!0):this.navigateToNextPage(e,l,!0)}navigateToNextPage(e,t,o=!1){const{pageBounds:i,rowModel:s}=this.beans,n=this.getViewportHeight(),r=i.getFirstRow(),a=i.getLastRow(),l=i.getPixelOffset(),d=s.getRow(e.rowIndex),h=o?d?.rowHeight-n-l:n-l,c=d?.rowTop+h;let u,g=s.getRowIndexAtPixel(c+l);if(g===e.rowIndex){const i=o?-1:1;t=g=e.rowIndex+i}o?(u="bottom",g<r&&(g=r),t<r&&(t=r)):(u="top",g>a&&(g=a),t>a&&(t=a)),this.isRowTallerThanView(s.getRow(g))&&(t=g,u="top"),this.navigateTo({scrollIndex:t,scrollType:u,scrollColumn:null,focusIndex:g,focusColumn:e.column})}navigateToNextPageWithAutoHeight(e,t,o=!1){this.navigateTo({scrollIndex:t,scrollType:o?"bottom":"top",scrollColumn:null,focusIndex:t,focusColumn:e.column}),setTimeout(()=>{const i=this.getNextFocusIndexForAutoHeight(e,o);this.navigateTo({scrollIndex:t,scrollType:o?"bottom":"top",scrollColumn:null,focusIndex:i,focusColumn:e.column,isAsync:!0})},50)}getNextFocusIndexForAutoHeight(e,t=!1){const o=t?-1:1,i=this.getViewportHeight(),{pageBounds:s,rowModel:n}=this.beans,r=s.getLastRow();let a=0,l=e.rowIndex;for(;l>=0&&l<=r;){const e=n.getRow(l);if(e){const t=e.rowHeight??0;if(a+t>i)break;a+=t}l+=o}return Math.max(0,Math.min(l,r))}getViewportHeight(){const e=this.beans,t=Bu(e),o=this.beans.scrollVisibleSvc.getScrollbarWidth();let i=t.bottom-t.top;return e.ctrlsSvc.get("center").isHorizontalScrollShowing()&&(i-=o),i}isRowTallerThanView(e){if(!e)return!1;const t=e.rowHeight;return"number"==typeof t&&t>this.getViewportHeight()}onCtrlUpDownLeftRight(e,t){const o=this.beans.cellNavigation.getNextCellToFocus(e,t,!0),i=this.getNormalisedPosition(o),{rowIndex:s,rowPinned:n,column:r}=i??o,a=r;this.navigateTo({scrollIndex:s,scrollType:null,scrollColumn:a,focusIndex:s,focusColumn:a,rowPinned:n})}onHomeOrEndKey(e){const t=e===Gi,{visibleCols:o,pageBounds:i,rowModel:s}=this.beans,n=o.allCols,r=t?i.getFirstRow():i.getLastRow(),a=s.getRow(r);if(!a)return;const l=(t?n:[...n].reverse()).find(e=>!e.isSuppressNavigable(a));l&&this.navigateTo({scrollIndex:r,scrollType:null,scrollColumn:l,focusIndex:r,focusColumn:l})}onTabKeyDown(e,t){const o=t.shiftKey,i=this.tabToNextCellCommon(e,o,t),s=this.beans,{ctrlsSvc:n,pageBounds:r,focusSvc:a,gos:l}=s;if(!1===i)if(o){const{rowIndex:o,rowPinned:i}=e.getRowPosition();(i?0===o:o===r.getFirstRow())&&(0===l.get("headerHeight")||Pa(s)?Ma(s,!0,!0):(t.preventDefault(),a.focusPreviousFromFirstCell(t)))}else e instanceof ku&&e.focusCell(!0),(!o&&a.focusOverlay(!1)||Ma(s,o))&&t.preventDefault();else i?t.preventDefault():null===i&&n.get("gridCtrl").allowFocusForNextCoreContainer(o)}tabToNextCell(e,t){const o=this.beans,{focusSvc:i,rowRenderer:s}=o,n=i.getFocusedCell();if(!n)return!1;let r=wd(o,n);return!!(r||(r=s.getRowByPosition(n),r&&r.isFullWidth()))&&!!this.tabToNextCellCommon(r,e,t,"api")}tabToNextCellCommon(e,t,o,i="ui"){const{editSvc:s,focusSvc:n}=this.beans;let r;const a=e instanceof ku?e:e.getAllCellCtrls()?.[0];return r=s?.isEditing()?s?.moveToNextCell(a,t,o,i):this.moveToNextCellNotEditing(e,t,o),null===r?r:r||!!n.focusedHeader}moveToNextCellNotEditing(e,t,i){const s=this.beans.visibleCols.allCols;let n;if(e instanceof Lu){if(n={...e.getRowPosition(),column:t?s[0]:to(s)},this.gos.get("embedFullWidthRows")&&i){const t=e.findFullWidthInfoForEvent(i);t&&(n.column=t.column)}}else n=e.getFocusedCellPosition();const r=this.findNextCellToFocusOn(n,{backwards:t,startEditing:!1});if(!1===r)return null;if(r instanceof ku)r.focusCell(!0);else if(r)return this.tryToFocusFullWidthRow(r,t);return o(r)}findNextCellToFocusOn(e,{backwards:t,startEditing:i,skipToNextEditableCell:s}){let n=e;const r=this.beans,{cellNavigation:a,gos:l,focusSvc:d,rowRenderer:h,rangeSvc:c}=r;for(;;){e!==n&&(e=n),t||(n=this.getLastCellOfColSpan(n)),n=a.getNextTabbedCell(n,t);const u=l.getCallback("tabToNextCell");if(o(u)){const o=u({backwards:t,editing:i,previousCellPosition:e,nextCellPosition:n||null});if(!0===o)n=e;else{if(!1===o)return!1;n={rowIndex:o.rowIndex,column:o.column,rowPinned:o.rowPinned}}}if(!n)return null;if(n.rowIndex<0){const e=ka(r);return d.focusHeaderPosition({headerPosition:{headerRowIndex:e+n.rowIndex,column:n.column},fromCell:!0}),null}const g="fullRow"===l.get("editType");if(i&&(!g||s)){if(!this.isCellEditable(n))continue}this.ensureCellVisible(n);const p=wd(r,n);if(!p){const e=h.getRowByPosition(n);if(!e||!e.isFullWidth()||i)continue;return{...e.getRowPosition(),column:n?.column}}if(!a.isSuppressNavigable(p.column,p.rowNode))return p.setFocusedCellPosition(n),c?.setRangeToCell(n),p}}isCellEditable(e){const t=this.lookupRowNodeForCell(e);return!!t&&e.column.isCellEditable(t)}lookupRowNodeForCell({rowIndex:e,rowPinned:t}){const{pinnedRowModel:o,rowModel:i}=this.beans;return"top"===t?o?.getPinnedTopRow(e):"bottom"===t?o?.getPinnedBottomRow(e):i.getRow(e)}navigateToNextCell(e,t,s,n){let r=s,a=!1;const l=this.beans,{cellNavigation:d,focusSvc:h,gos:c}=l;for(;r&&(r===s||!this.isValidNavigateCell(r));)c.get("enableRtl")?t===ki&&(r=this.getLastCellOfColSpan(r)):t===Ii&&(r=this.getLastCellOfColSpan(r)),r=d.getNextCellToFocus(t,r),a=i(r);if(a&&e&&e.key===Ti&&(r={rowIndex:-1,rowPinned:null,column:s.column}),n){const i=c.getCallback("navigateToNextCell");if(o(i)){const n=i({key:t,previousCellPosition:s,nextCellPosition:r||null,event:e});r=o(n)?{rowPinned:n.rowPinned,rowIndex:n.rowIndex,column:n.column}:null}}if(!r)return;if(r.rowIndex<0){const t=ka(l);return void h.focusHeaderPosition({headerPosition:{headerRowIndex:t+r.rowIndex,column:s.column},event:e||void 0,fromCell:!0})}const u=this.getNormalisedPosition(r);u?this.focusPosition(u):this.tryToFocusFullWidthRow(r)}getNormalisedPosition(e){if(!!this.beans.spannedRowRenderer?.getCellByPosition(e))return e;this.ensureCellVisible(e);const t=wd(this.beans,e);return t?(e=t.getFocusedCellPosition(),this.ensureCellVisible(e),e):null}tryToFocusFullWidthRow(e,t){const{visibleCols:i,rowRenderer:s,focusSvc:n,eventSvc:r}=this.beans,a=i.allCols,l=s.getRowByPosition(e);if(!l||!l.isFullWidth())return!1;const d=n.getFocusedCell(),h={rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:e.column||(t?to(a):a[0])};this.focusPosition(h);const c=null==t?null!=d&&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(o(t.rowPinned))return"top"!==t.rowPinned}return e.rowIndex<t.rowIndex}(h,d):t;return r.dispatchEvent({type:"fullWidthRowFocused",rowIndex:h.rowIndex,rowPinned:h.rowPinned,column:h.column,isFullWidthCell:!0,fromBelow:c}),!0}focusPosition(e){const{focusSvc:t,rangeSvc:o}=this.beans;t.setFocusedCell({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0}),o?.setRangeToCell(e)}isValidNavigateCell(e){return!!vd(this.beans,e)}getLastCellOfColSpan(e){const t=wd(this.beans,e);if(!t)return e;const o=t.getColSpanningList();return 1===o.length?e:{rowIndex:e.rowIndex,column:to(o),rowPinned:e.rowPinned}}ensureCellVisible(e){const t=bt(this.gos),o=this.beans.rowModel.getRow(e.rowIndex),s=t&&o?.sticky,{scrollFeature:n}=this.gridBodyCon;!s&&i(e.rowPinned)&&n.ensureIndexVisible(e.rowIndex),e.column.isPinned()||n.ensureColumnVisible(e.column)}ensureColumnVisible(e){const t=this.gridBodyCon.scrollFeature;e.isPinned()||t.ensureColumnVisible(e)}ensureRowVisible(e){this.gridBodyCon.scrollFeature.ensureIndexVisible(e)}},class extends Me{constructor(){super(...arguments),this.beanName="cellNavigation"}wireBeans(e){this.rowSpanSvc=e.rowSpanSvc}getNextCellToFocus(e,t,o=!1){return o?this.getNextCellToFocusWithCtrlPressed(e,t):this.getNextCellToFocusWithoutCtrlPressed(e,t)}getNextCellToFocusWithCtrlPressed(e,t){const o=e===Ti,i=e===Ai,s=e===ki;let n,r;const{pageBounds:a,gos:l,visibleCols:d,pinnedRowModel:h}=this.beans,{rowPinned:c}=t;if(o||i)r=c&&h?o?0:"top"===c?h.getPinnedTopRowCount()-1:h.getPinnedBottomRowCount()-1:o?a.getFirstRow():a.getLastRow(),n=t.column;else{const e=l.get("enableRtl");r=t.rowIndex;n=(s!==e?d.allCols:[...d.allCols].reverse()).find(e=>this.isCellGoodToFocusOn({rowIndex:r,rowPinned:null,column:e}))}return n?{rowIndex:r,rowPinned:c,column:n}:null}getNextCellToFocusWithoutCtrlPressed(e,t){let o=t,i=!1;for(;!i;){switch(e){case Ti:o=this.getCellAbove(o);break;case Ai:o=this.getCellBelow(o);break;case Ii:o=this.gos.get("enableRtl")?this.getCellToLeft(o):this.getCellToRight(o);break;case ki:o=this.gos.get("enableRtl")?this.getCellToRight(o):this.getCellToLeft(o);break;default:o=null,st(8,{key:e})}i=!o||this.isCellGoodToFocusOn(o)}return o}isCellGoodToFocusOn(e){const t=e.column;let o;const{pinnedRowModel:i,rowModel:s}=this.beans;switch(e.rowPinned){case"top":o=i?.getPinnedTopRow(e.rowIndex);break;case"bottom":o=i?.getPinnedBottomRow(e.rowIndex);break;default:o=s.getRow(e.rowIndex)}if(!o)return!1;return!this.isSuppressNavigable(t,o)}getCellToLeft(e){if(!e)return null;const t=this.beans.visibleCols.getColBefore(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellToRight(e){if(!e)return null;const t=this.beans.visibleCols.getColAfter(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellBelow(e){if(!e)return null;const t=this.rowSpanSvc?.getCellEnd(e)??e,o=yd(this.beans,t,!0);return o?{rowIndex:o.rowIndex,column:e.column,rowPinned:o.rowPinned}:null}getCellAbove(e){if(!e)return null;const t=this.rowSpanSvc?.getCellStart(e)??e,o=bd(this.beans,{rowIndex:t.rowIndex,rowPinned:t.rowPinned},!0);return o?{rowIndex:o.rowIndex,column:e.column,rowPinned:o.rowPinned}:null}getNextTabbedCell(e,t){return t?this.getNextTabbedCellBackwards(e):this.getNextTabbedCellForwards(e)}getNextTabbedCellForwards(e){const{visibleCols:t,pagination:o}=this.beans,s=t.allCols;let n=e.rowIndex,r=e.rowPinned,a=t.getColAfter(e.column);if(!a){a=s[0];const t=yd(this.beans,e,!0);if(i(t))return null;if(!t.rowPinned&&!(o?.isRowInPage(t.rowIndex)??1))return null;n=t?t.rowIndex:null,r=t?t.rowPinned:null}return{rowIndex:n,column:a,rowPinned:r}}getNextTabbedCellBackwards(e){const{beans:t}=this,{visibleCols:o,pagination:s}=t,n=o.allCols;let r=e.rowIndex,a=e.rowPinned,l=o.getColBefore(e.column);if(!l){l=to(n);const o=bd(t,{rowIndex:e.rowIndex,rowPinned:e.rowPinned},!0);if(i(o))return null;if(!o.rowPinned&&!(s?.isRowInPage(o.rowIndex)??1))return null;r=o?o.rowIndex:null,a=o?o.rowPinned:null}return{rowIndex:r,column:l,rowPinned:a}}isSuppressNavigable(e,t){const{suppressNavigable:o}=e.colDef;if("boolean"==typeof o)return o;if("function"==typeof o){return o(e.createColumnFunctionCallbackParams(t))}return!1}},class extends Me{constructor(){super(...arguments),this.beanName="headerNavigation",this.currentHeaderRowWithoutSpan=-1}postConstruct(){const e=this.beans;e.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl});const t=g(e);this.addManagedElementListeners(t,{mousedown:()=>{this.currentHeaderRowWithoutSpan=-1}})}getHeaderPositionForColumn(e,t){let o;const{colModel:i,colGroupSvc:s,ctrlsSvc:n}=this.beans;if("string"==typeof e?(o=i.getCol(e),o||(o=s?.getColumnGroup(e)??null)):o=e,!o)return null;const r=n.getHeaderRowContainerCtrl(),a=r?.getAllCtrls(),l="filter"===to(a||[]).type,d=ka(this.beans)-1;let h=-1,c=o;for(;c;)h++,c=c.getParent();let u=h;return t&&l&&u===d-1&&u++,-1===u?null:{headerRowIndex:u,column:o}}navigateVertically(e,t){const{focusSvc:o,visibleCols:i}=this.beans,{focusedHeader:s}=o;if(!s)return!1;const{headerRowIndex:n}=s,r=s.column,a=ka(this.beans),l=this.getHeaderRowType(n),d=i.headerGroupRowCount;let{headerRowIndex:h,column:c,headerRowIndexWithoutSpan:u}="UP"===e?function(e,t,o){const i=o-1;if("filter"!==e){const e=t instanceof _t&&t.isSpanHeaderHeight();let o=t.getParent();for(;o&&(o.getProvidedColumnGroup().getLevel()>i||e&&o.isPadding());)o=o.getParent();if(o)return e?{column:o,headerRowIndex:o.getProvidedColumnGroup().getLevel(),headerRowIndexWithoutSpan:i}:{column:o,headerRowIndex:i,headerRowIndexWithoutSpan:i}}return{column:t,headerRowIndex:i,headerRowIndexWithoutSpan:i}}(l,r,n):function(e,t,o){const i=t+1,s={column:e,headerRowIndex:i,headerRowIndexWithoutSpan:i};if(e instanceof Un){if(i>=o)return{column:e.getDisplayedLeafColumns()[0],headerRowIndex:o,headerRowIndexWithoutSpan:i};let t=e.getDisplayedChildren()[0];if(t instanceof Un&&t.isPadding()){const e=t.getDisplayedLeafColumns()[0];e.isSpanHeaderHeight()&&(t=e)}s.column=t;t instanceof _t&&t.isSpanHeaderHeight()&&(s.headerRowIndex=o,s.headerRowIndexWithoutSpan=i)}return s}(r,n,d),g=!1;return h<0&&(h=0,c=r,g=!0),h>=a?(h=-1,this.currentHeaderRowWithoutSpan=-1):void 0!==u&&(this.currentHeaderRowWithoutSpan=u),!(!g&&!c)&&o.focusHeaderPosition({headerPosition:{headerRowIndex:h,column:c},allowUserOverride:!0,event:t})}navigateHorizontally(e,t=!1,o){const{focusSvc:i,gos:s}=this.beans,n={...i.focusedHeader};let r,a;-1!==this.currentHeaderRowWithoutSpan?n.headerRowIndex=this.currentHeaderRowWithoutSpan:this.currentHeaderRowWithoutSpan=n.headerRowIndex,"LEFT"===e!==s.get("enableRtl")?(a="Before",r=this.findHeader(n,a)):(a="After",r=this.findHeader(n,a));const l=s.getCallback("tabToNextHeader");if(t&&l){const e=i.focusHeaderPositionFromUserFunc({userFunc:l,headerPosition:r,direction:a});if(e){const{headerRowIndex:e}=i.focusedHeader||{};null!=e&&e!=n.headerRowIndex&&(this.currentHeaderRowWithoutSpan=e)}return e}return r||!t?i.focusHeaderPosition({headerPosition:r,direction:a,fromTab:t,allowUserOverride:!0,event:o}):this.focusNextHeaderRow(n,a,o)}focusNextHeaderRow(e,t,o){const i=this.beans,s=e.headerRowIndex;let n,r=null;const a=ka(i),l=this.beans.visibleCols.allCols;if("Before"===t){if(s<=0)return!1;r=to(l),n=s-1,this.currentHeaderRowWithoutSpan-=1}else r=l[0],n=s+1,this.currentHeaderRowWithoutSpan<a?this.currentHeaderRowWithoutSpan+=1:this.currentHeaderRowWithoutSpan=-1;let{column:d,headerRowIndex:h}=Rc(this.beans,r,n);return h>=a&&(h=-1),i.focusSvc.focusHeaderPosition({headerPosition:{column:d,headerRowIndex:h},direction:t,fromTab:!0,allowUserOverride:!0,event:o})}scrollToColumn(e,t="After"){if(e.getPinned())return;let o;if(Wn(e)){const i=e.getDisplayedLeafColumns();o="Before"===t?to(i):i[0]}else o=e;this.gridBodyCon.scrollFeature.ensureColumnVisible(o)}findHeader(e,t){const{colGroupSvc:o,visibleCols:i}=this.beans;let s=e.column;if(s instanceof Un){const e=s.getDisplayedLeafColumns();s="Before"===t?e[0]:e[e.length-1]}const n="Before"===t?i.getColBefore(s):i.getColAfter(s);if(!n)return;const r=i.headerGroupRowCount;if(e.headerRowIndex>=r)return{headerRowIndex:e.headerRowIndex,column:n};const a=o?.getColGroupAtLevel(n,e.headerRowIndex);if(!a){return{headerRowIndex:n instanceof _t&&n.isSpanHeaderHeight()?i.headerGroupRowCount:e.headerRowIndex,column:n}}return a.isPadding()&&n.isSpanHeaderHeight()?{headerRowIndex:i.headerGroupRowCount,column:n}:{headerRowIndex:e.headerRowIndex,column:a??n}}getHeaderRowType(e){const t=this.beans.ctrlsSvc.getHeaderRowContainerCtrl();if(t)return t.getRowType(e)}}],apiFunctions:{getFocusedCell:function(e){return e.focusSvc.getFocusedCell()},clearFocusedCell:function(e){return e.focusSvc.clearFocusedCell()},setFocusedCell:function(e,t,o,i){e.focusSvc.setFocusedCell({rowIndex:t,column:o,rowPinned:i,forceBrowserFocus:!0})},setFocusedHeader:function(e,t,o=!1){const i=e.headerNavigation?.getHeaderPositionForColumn(t,o);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}}},Vu=class extends Me{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(){const e=this.getWidth(),t=e>0;for(const o of this.elements)o&&(H(o,t),re(o,e))}},Gu={moduleName:"PinnedColumn",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="pinnedCols"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl});const e=this.checkContainerWidths.bind(this);this.addManagedEventListeners({displayedColumnsChanged:e,displayedColumnsWidthChanged:e}),this.addManagedPropertyListener("domLayout",e)}checkContainerWidths(){const{gos:e,visibleCols:t,eventSvc:o}=this.beans,i=ct(e,"print"),s=i?0:t.getColsLeftWidth(),n=i?0:t.getDisplayedColumnsRightWidth();s!=this.leftWidth&&(this.leftWidth=s,o.dispatchEvent({type:"leftPinnedWidthChanged"})),n!=this.rightWidth&&(this.rightWidth=n,o.dispatchEvent({type:"rightPinnedWidthChanged"}))}keepPinnedColumnsNarrowerThanViewport(){const e=z(this.gridBodyCtrl.eBodyViewport);if(e<=50)return;const t=this.getPinnedColumnsOverflowingViewport(e-50),o=this.gos.getCallback("processUnpinnedColumns"),{columns:i,hasLockedPinned:s}=t;let n=i;if(n.length||s){if(o){n=o({columns:n,viewportWidth:e})}n&&n.length&&(n=n.filter(e=>!mo(e)),this.setColsPinned(n,null,"viewportSizeFeature"))}}createPinnedWidthFeature(e,...t){return new Vu(e,t)}setColsPinned(e,t,o){const{colModel:i,colAnimation:s,visibleCols:n,gos:r}=this.beans;if(!i.cols)return;if(!e?.length)return;if(ct(r,"print"))return void st(37);let a;s?.start(),a=!0===t||"left"===t?"left":"right"===t?"right":null;const l=[];e.forEach(e=>{if(!e)return;const t=i.getCol(e);t&&t.getPinned()!==a&&(this.setColPinned(t,a),l.push(t))}),l.length&&(n.refresh(o),Mo(this.eventSvc,l,o)),s?.finish()}initCol(e){const{pinned:t,initialPinned:o}=e.colDef;void 0!==t?this.setColPinned(e,t):this.setColPinned(e,o)}setColPinned(e,t){e.pinned=!0===t||"left"===t?"left":"right"===t?"right":null,e.dispatchStateUpdatedEvent("pinned")}setupHeaderPinnedWidth(e){const{scrollVisibleSvc:t}=this.beans;if(null==e.pinned)return;const o="left"===e.pinned,i="right"===e.pinned;e.hidden=!0;const s=()=>{const s=o?this.leftWidth:this.rightWidth;if(null==s)return;const n=0==s,r=e.hidden!==n,a=this.gos.get("enableRtl"),l=t.getScrollbarWidth(),d=t.verticalScrollShowing&&(a&&o||!a&&i)?s+l:s;e.comp.setPinnedContainerWidth(`${d}px`),e.comp.setDisplayed(!n),r&&(e.hidden=n,e.refresh())};e.addManagedEventListeners({leftPinnedWidthChanged:s,rightPinnedWidthChanged:s,scrollVisibilityChanged:s,scrollbarWidthChanged:s})}getHeaderResizeDiff(e,t){if(t.getPinned()){const{leftWidth:t,rightWidth:o}=this,i=z(this.beans.ctrlsSvc.getGridBodyCtrl().eBodyViewport)-50;if(t+o+e>i){if(!(i>t+o))return 0;e=i-t-o}}return e}getPinnedColumnsOverflowingViewport(e){const t=(this.rightWidth??0)+(this.leftWidth??0);let o=!1;if(t<e)return{columns:[],hasLockedPinned:o};const{visibleCols:i}=this.beans,s=[...i.leftCols],n=[...i.rightCols];let r=0,a=0;const l=[];let d=t-0-e;for(;(a<s.length||r<n.length)&&d>0;){if(r<n.length){const e=n[r++];if(e.colDef.lockPinned){o=!0;continue}d-=e.getActualWidth(),l.push(e)}if(a<s.length&&d>0){const e=s[a++];if(e.colDef.lockPinned){o=!0;continue}d-=e.getActualWidth(),l.push(e)}}return{columns:l,hasLockedPinned:o}}}],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}"]},Nu={moduleName:"Aria",version:qe,beans:[class extends Me{constructor(){super(),this.beanName="ariaAnnounce",this.descriptionContainer=null,this.pendingAnnouncements=new Map,this.lastAnnouncement="",this.updateAnnouncement=Be(this,this.updateAnnouncement.bind(this),200)}postConstruct(){const e=this.beans,t=g(e),o=this.descriptionContainer=t.createElement("div");o.classList.add("ag-aria-description-container"),R(o,"polite"),C(o,"relevant","additions text"),function(e,t){C(e,"atomic",t)}(o,!0),e.eGridDiv.appendChild(o)}announceValue(e,t){this.pendingAnnouncements.set(t,e),this.updateAnnouncement()}updateAnnouncement(){if(!this.descriptionContainer)return;const 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;null!=t&&""!=t.replace(/[ .]/g,"")?(this.lastAnnouncement===t&&(t=`${t}`),this.lastAnnouncement=t,this.descriptionContainer.textContent=t):this.lastAnnouncement=""}destroy(){super.destroy();const{descriptionContainer:e}=this;e&&(q(e),e.parentElement?.removeChild(e)),this.descriptionContainer=null,this.pendingAnnouncements.clear()}}]},Ou="ag-delay-render",zu={moduleName:"ColumnDelayRender",version:qe,beans:[class extends Me{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(Ou)}),this.hideRequested=!0))}revealColumns(e){if(this.alreadyRevealed||!this.isAlive())return;if(this.requesters.delete(e),this.requesters.size>0)return;const{renderStatus:t,ctrlsSvc:o}=this.beans;if(t){if(!t.areHeaderCellsRendered()&&this.timesRetried<5)return this.timesRetried++,void setTimeout(()=>this.revealColumns(e));this.timesRetried=0}o.getGridBodyCtrl().eGridBody.classList.remove(Ou),this.alreadyRevealed=!0}}],css:[":where(.ag-delay-render){.ag-cell,.ag-header-cell,.ag-header-group-cell,.ag-row,.ag-spanned-cell-wrapper{visibility:hidden}}"]};var Wu={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"}]}]},Uu=class extends Uo{constructor(){super(Wu),this.eOverlayWrapper=Go,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(e.key!==Fi||e.defaultPrevented||Pr(e))return;const t=this.beans;if(ys(t,this.eOverlayWrapper,!1,e.shiftKey))return;let o=!1;o=e.shiftKey?t.focusSvc.focusGridView({column:to(t.visibleCols.allCols),backwards:!0,canFocusOverlay:!1}):Ma(t,!1),o&&e.preventDefault()}updateLayoutClasses(e,t){const o=this.eOverlayWrapper.classList,{AUTO_HEIGHT:i,NORMAL:s,PRINT:n}=Tr;o.toggle(i,t.autoHeight),o.toggle(s,t.normal),o.toggle(n,t.print)}postConstruct(){this.createManagedBean(new Ir(this)),this.setDisplayed(!1,{skipAriaHidden:!0}),this.beans.overlays.setOverlayWrapperComp(this),this.addManagedElementListeners(this.getFocusableElement(),{keydown:this.handleKeyDown.bind(this)})}setWrapperTypeClass(e){const t=this.eOverlayWrapper.classList;this.activeCssClass&&t.toggle(this.activeCssClass,!1),this.activeCssClass=e,t.toggle(e,!0)}showOverlay(e,t,o,i){if(this.setWrapperTypeClass(t),this.destroyActiveOverlay(),this.elToFocusAfter=null,this.activePromise=e,e){if(this.setDisplayed(!0,{skipAriaHidden:!0}),o&&this.isGridFocused()){const e=u(this.beans);e&&!p(this.beans)&&(this.elToFocusAfter=e)}e.then(t=>{if(this.activePromise===e){if(this.activePromise=null,t){if(this.activeOverlay!==t&&(this.eOverlayWrapper.appendChild(t.getGui()),this.activeOverlay=t,i)){const e=t;this.updateListenerDestroyFunc=this.addManagedPropertyListener(i,({currentValue:t})=>{e.refresh?.(zt(this.gos,{...t??{}}))})}o&&this.isGridFocused()&&bs(this.eOverlayWrapper)}}else this.activeOverlay!==t&&(this.destroyBean(t),t=null)})}}updateOverlayWrapperPaddingTop(e){this.eOverlayWrapper.style.setProperty("padding-top",`${e}px`)}destroyActiveOverlay(){this.activePromise=null;const e=this.activeOverlay;if(!e)return;let t=this.elToFocusAfter;this.activeOverlay=null,this.elToFocusAfter=null,t&&!this.isGridFocused()&&(t=null);const o=this.updateListenerDestroyFunc;o&&(o(),this.updateListenerDestroyFunc=null),this.destroyBean(e),q(this.eOverlayWrapper),t?.focus?.({preventScroll:!0})}hideOverlay(){this.destroyActiveOverlay(),this.setDisplayed(!1,{skipAriaHidden:!0})}isGridFocused(){const e=u(this.beans);return!!e&&this.beans.eGridDiv.contains(e)}destroy(){this.elToFocusAfter=null,this.destroyActiveOverlay(),this.beans.overlays.setOverlayWrapperComp(void 0),super.destroy()}},$u={selector:"AG-OVERLAY-WRAPPER",component:Uu},Ku={moduleName:"Overlay",version:qe,userComponents:{agLoadingOverlay:class extends sl{init(){const e=t(this.gos.get("overlayLoadingTemplate")?.trim());if(this.setTemplate(e??nl),!e){const e=this.getLocaleTextFunc()("loadingOoo","Loading...");this.getGui().textContent=e,this.beans.ariaAnnounce.announceValue(e,"overlay")}}},agNoRowsOverlay:class extends sl{init(){const e=t(this.gos.get("overlayNoRowsTemplate")?.trim());if(this.setTemplate(e??rl),!e){const e=this.getLocaleTextFunc()("noRowsToShow","No Rows To Show");this.getGui().textContent=e,this.beans.ariaAnnounce.announceValue(e,"overlay")}}}},apiFunctions:{showLoadingOverlay:function(e){e.overlays?.showLoadingOverlay()},showNoRowsOverlay:function(e){e.overlays?.showNoRowsOverlay()},hideOverlay:function(e){e.overlays?.hideOverlay()}},beans:[class extends Me{constructor(){super(...arguments),this.beanName="overlays",this.state=0,this.showInitialOverlay=!0,this.wrapperPadding=0}postConstruct(){this.isClientSide=dt(this.gos),this.isServerSide=!this.isClientSide&&ht(this.gos);const 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;const e=this.gos,t=e.get("loading");(t||void 0===t&&!e.get("suppressLoadingOverlay"))&&this.doShowLoadingOverlay()}showNoRowsOverlay(){this.showInitialOverlay=!1;const e=this.gos;e.get("loading")||e.get("suppressNoRowsOverlay")||this.doShowNoRowsOverlay()}hideOverlay(){this.showInitialOverlay=!1,this.gos.get("loading")?st(99):this.doHideOverlay()}getOverlayWrapperSelector(){return $u}getOverlayWrapperCompClass(){return Uu}updateOverlayVisibility(){if(!this.eWrapper)return void(this.state=0);const{state:e,isClientSide:t,isServerSide:o,beans:{gos:i,colModel:s,rowModel:n}}=this;let r=this.gos.get("loading");void 0!==r&&(this.showInitialOverlay=!1),this.showInitialOverlay&&void 0===r&&!i.get("suppressLoadingOverlay")&&(r=!i.get("columnDefs")||!s.ready||!i.get("rowData")&&t),r?1!==e&&this.doShowLoadingOverlay():(this.showInitialOverlay=!1,t&&n.isEmpty()&&!i.get("suppressNoRowsOverlay")?2!==e&&this.doShowNoRowsOverlay():(1===e||!o&&0!==e)&&this.doHideOverlay())}doShowLoadingOverlay(){var e,t;this.eWrapper&&(this.state=1,this.showOverlay((e=this.beans.userCompFactory,t=zt(this.gos,{}),e.getCompDetailsFromGridOptions(oi,"agLoadingOverlay",t,!0)),"ag-overlay-loading-wrapper","loadingOverlayComponentParams"),this.updateExclusive())}doShowNoRowsOverlay(){var e,t;this.eWrapper&&(this.state=2,this.showOverlay((e=this.beans.userCompFactory,t=zt(this.gos,{}),e.getCompDetailsFromGridOptions(ii,"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,o){const i=e?.newAgStackInstance()??null;this.eWrapper?.showOverlay(i,t,this.isExclusive(),o),this.refreshWrapperPadding()}updateExclusive(){const e=this.exclusive;this.exclusive=this.isExclusive(),this.exclusive!==e&&this.eventSvc.dispatchEvent({type:"overlayExclusiveChanged"})}refreshWrapperPadding(){const e=this.eWrapper;if(!e)return;let t=0;if(2===this.state){const e=this.beans.ctrlsSvc.get("gridHeaderCtrl");t=e?.headerHeight||0}else 0!==this.wrapperPadding&&(t=0);this.wrapperPadding!==t&&(this.wrapperPadding=t,e.updateOverlayWrapperPaddingTop(t))}}]},ju=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){const e=this.entriesList[0];e.destroyFirstPass(),e.destroySecondPass(),this.removeFromCache(e)}}getRow(e){if(null==e||null==e.id)return null;const t=this.entriesMap[e.id];if(!t)return null;this.removeFromCache(t),t.setCached(!1);return t.rowNode!=e?null:t}has(e){return null!=this.entriesMap[e.id]}removeRow(e){const t=e.id,o=this.entriesMap[t];delete this.entriesMap[t],so(this.entriesList,o)}removeFromCache(e){const t=e.rowNode.id;delete this.entriesMap[t],so(this.entriesList,e)}getEntries(){return this.entriesList}};function qu(e){if(!e)return;const t={top:{},bottom:{},normal:{}};return e.forEach(e=>{const o=e.id;switch(e.rowPinned){case"top":t.top[o]=e;break;case"bottom":t.bottom[o]=e;break;default:t.normal[o]=e}}),t}function _u(e,t){const o=e.id;switch(e.rowPinned){case"top":return null!=t.top[o];case"bottom":return null!=t.bottom[o];default:return null!=t.normal[o]}}var Yu={moduleName:"Sort",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="sortSvc"}progressSort(e,t,o){const i=this.getNextSortDirection(e);this.setSortForColumn(e,i,t,o)}progressSortFromEvent(e,t){const o="ctrl"===this.gos.get("multiSortKey")?t.ctrlKey||t.metaKey:t.shiftKey;this.progressSort(e,o,"uiColumnSorted")}setSortForColumn(e,t,o,i){"asc"!==t&&"desc"!==t&&(t=null);const{gos:s,showRowGroupCols:n}=this.beans;let r=[e];if(yt(s)&&e.getColDef().showRowGroup){const t=n?.getSourceColumnsForGroupColumn?.(e),o=t?.filter(e=>e.isSortable());o&&(r=[e,...o])}r.forEach(e=>this.setColSort(e,t,i));const a=[];if(!((o||s.get("alwaysMultiSort"))&&!s.get("suppressMultiSort"))){const e=this.clearSortBarTheseColumns(r,i);a.push(...e)}this.updateSortIndex(e),a.push(...r),this.dispatchSortChangedEvents(i,a)}updateSortIndex(e){const{gos:t,colModel:o,showRowGroupCols:i}=this.beans,s=yt(t),n=i?.getShowRowGroupCol(e.getId()),r=s&&n||e,a=this.getColumnsWithSortingOrdered();o.forAllCols(e=>this.setColSortIndex(e,null));const l=a.filter(e=>(!s||!e.getColDef().showRowGroup)&&e!==r);(r.getSort()?[...l,r]: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){const o={type:"sortChanged",source:e};t&&(o.columns=t),this.eventSvc.dispatchEvent(o)}clearSortBarTheseColumns(e,t){const o=[];return this.beans.colModel.forAllCols(i=>{e.includes(i)||(i.getSort()&&o.push(i),this.setColSort(i,void 0,t))}),o}getNextSortDirection(e){const t=e.getColDef().sortingOrder??this.gos.get("sortingOrder")??Tc,o=t.indexOf(e.getSort()),i=o<0,s=o==t.length-1;return i||s?t[0]:t[o+1]}getIndexedSortMap(){const{gos:e,colModel:t,showRowGroupCols:o,rowGroupColsSvc:i}=this.beans;let s=[];if(t.forAllCols(e=>{e.getSort()&&s.push(e)}),t.isPivotMode()){const t=yt(e);s=s.filter(e=>{const i=!!e.getAggFunc(),s=!e.isPrimary(),n=t?o?.getShowRowGroupCol(e.getId()):e.getColDef().showRowGroup;return i||s||n})}const n=i?.columns.filter(e=>!!e.getSort())??[],r={};s.forEach((e,t)=>r[e.getId()]=t),s.sort((e,t)=>{const o=e.getSortIndex(),i=t.getSortIndex();if(null!=o&&null!=i)return o-i;if(null==o&&null==i){return r[e.getId()]>r[t.getId()]?1:-1}return null==i?-1:1});const a=yt(e)&&!!n.length;a&&(s=[...new Set(s.map(e=>o?.getShowRowGroupCol(e.getId())??e))]);const l=new Map;return s.forEach((e,t)=>l.set(e,t)),a&&n.forEach(e=>{const t=o.getShowRowGroupCol(e.getId());l.set(e,l.get(t))}),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){const t=yt(this.gos),o=!!e.getColDef().showRowGroup;return t&&o}getDisplaySortForColumn(e){const t=this.beans.showRowGroupCols?.getSourceColumnsForGroupColumn(e);if(!this.canColumnDisplayMixedSort(e)||!t?.length)return e.getSort();const o=null!=e.getColDef().field||!!e.getColDef().valueGetter?[e,...t]:t,i=o[0].getSort();return o.every(e=>e.getSort()==i)?i:"mixed"}getDisplaySortIndexForColumn(e){return this.getIndexedSortMap().get(e)}setupHeader(e,t,o){let i=0;e.addManagedListeners(t,{movingChanged:()=>{i=Date.now()}}),o&&e.addManagedElementListeners(o,{click:e=>{const o=t.isMoving(),s=Date.now();o||s-i<50||this.progressSortFromEvent(t,e)}});const s=()=>{const o=t.getSort();if(e.toggleCss("ag-header-cell-sorted-asc","asc"===o),e.toggleCss("ag-header-cell-sorted-desc","desc"===o),e.toggleCss("ag-header-cell-sorted-none",!o),t.getColDef().showRowGroup){const o=this.beans.showRowGroupCols?.getSourceColumnsForGroupColumn(t),i=o?.every(e=>t.getSort()==e.getSort()),s=!i;e.toggleCss("ag-header-cell-sorted-mixed",s)}};e.addManagedEventListeners({sortChanged:s,columnRowGroupChanged:s})}initCol(e){const{sort:t,initialSort:o,sortIndex:i,initialSortIndex:s}=e.colDef;void 0!==t?"asc"!==t&&"desc"!==t||(e.sort=t):"asc"!==o&&"desc"!==o||(e.sort=o),void 0!==i?null!==i&&(e.sortIndex=i):null!==s&&(e.sortIndex=s)}updateColSort(e,t,o){void 0!==t&&("desc"===t||"asc"===t?this.setColSort(e,t,o):this.setColSort(e,void 0,o))}setColSort(e,t,o){e.sort!==t&&(e.sort=t,e.dispatchColEvent("sortChanged",o)),e.dispatchStateUpdatedEvent("sort")}setColSortIndex(e,t){e.sortIndex=t,e.dispatchStateUpdatedEvent("sortIndex")}createSortIndicator(e){return new Mc(e)}getSortIndicatorSelector(){return kc}},class extends Me{constructor(){super(...arguments),this.beanName="rowNodeSorter"}postConstruct(){const{gos:e}=this;this.isAccentedSort=e.get("accentedSort"),this.primaryColumnsSortGroups=yt(e),this.addManagedPropertyListener("accentedSort",e=>this.isAccentedSort=e.currentValue),this.addManagedPropertyListener("autoGroupColumnDef",()=>this.primaryColumnsSortGroups=yt(e))}doFullSort(e,t){const o=e.map((e,t)=>({currentPos:t,rowNode:e}));return o.sort(this.compareRowNodes.bind(this,t)),o.map(e=>e.rowNode)}compareRowNodes(e,t,o){const i=t.rowNode,s=o.rowNode;for(let t=0,o=e.length;t<o;t++){const o=e[t],n="desc"===o.sort,a=this.getValue(i,o.column),l=this.getValue(s,o.column);let d;const h=this.getComparator(o,i);d=h?h(a,l,i,s,n):r(a,l,this.isAccentedSort);if(!isNaN(d)&&0!==d)return"asc"===o.sort?d:-1*d}return t.currentPos-o.currentPos}getComparator(e,t){const o=e.column,i=o.getColDef().comparator;if(null!=i)return i;if(!o.getColDef().showRowGroup)return;const s=!t.group&&o.getColDef().field;if(!s)return;const n=this.beans.colModel.getColDefCol(s);return n?n.getColDef().comparator:void 0}getValue(e,t){const{valueSvc:o,colModel:i,showRowGroupCols:s,gos:n}=this.beans;if(!this.primaryColumnsSortGroups)return o.getValue(t,e,!1);if(e.rowGroupColumn===t){if(Rt(n,i.isPivotActive())){const i=e.allLeafChildren?.[0];return i?o.getValue(t,i,!1):void 0}const r=s?.getShowRowGroupCol(t.getId());if(!r)return;return e.groupData?.[r.getId()]}return e.group&&t.getColDef().showRowGroup?void 0:o.getValue(t,e,!1)}}],apiFunctions:{onSortChanged:function(e){e.sortSvc?.onSortChanged("api")}},userComponents:{agSortIndicator:Mc},icons:{sortAscending:"asc",sortDescending:"desc",sortUnSort:"none"}};var Qu={moduleName:"ValueCache",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="valueCache",this.cacheVersion=0}postConstruct(){const e=this.gos;this.active=e.get("valueCache"),this.neverExpires=e.get("valueCacheNeverExpires")}onDataChanged(){this.neverExpires||this.expire()}expire(){this.cacheVersion++}setValue(e,t,o){if(this.active){const i=this.cacheVersion;e.__cacheVersion!==i&&(e.__cacheVersion=i,e.__cacheData={}),e.__cacheData[t]=o}}getValue(e,t){if(this.active&&e.__cacheVersion===this.cacheVersion)return e.__cacheData[t]}}],apiFunctions:{expireValueCache:function(e){e.valueCache?.expire()}}},Zu={moduleName:"Expression",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="expressionSvc",this.cache={}}evaluate(e,t){if("string"==typeof e)return this.evaluateExpression(e,t);nt(15,{expression:e})}evaluateExpression(e,t){try{const o=this.createExpressionFunction(e);return o(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(o){return nt(16,{expression:e,params:t,e:o}),null}}createExpressionFunction(e){const t=this.cache;if(t[e])return t[e];const o=this.createFunctionBody(e),i=new Function("x, ctx, oldValue, newValue, value, node, data, colDef, rowIndex, api, getValue, column, columnGroup",o);return t[e]=i,i}createFunctionBody(e){return e.indexOf("return")>=0?e:"return "+e+";"}}]},Ju={moduleName:"ChangeDetection",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="changeDetectionSvc",this.clientSideRowModel=null}postConstruct(){const{gos:e,rowModel:t}=this.beans;dt(e)&&(this.clientSideRowModel=t),this.addManagedEventListeners({cellValueChanged:this.onCellValueChanged.bind(this)})}onCellValueChanged(e){const{gos:t,rowRenderer:o}=this.beans;if("paste"===e.source||t.get("suppressChangeDetection"))return;const i=e.node,s=[i],n=this.clientSideRowModel,r=n?.rootNode;if(r&&!i.isRowPinned()){const o=t.get("aggregateOnlyChangedColumns"),a=new Ed(o,r);a.addParentNode(i.parent,[e.column]),n.doAggregate(a),a.forEachChangedNodeDepthFirst(e=>{s.push(e),e.sibling&&s.push(e.sibling)})}o.refreshCells({rowNodes:s})}}]},Xu={moduleName:"CellApi",version:qe,apiFunctions:{getCellValue:function(e,t){const{colKey:o,rowNode:s,useFormatter:n}=t,r=e.colModel.getColDefCol(o)??e.colModel.getCol(o);if(i(r))return null;const a=e.valueSvc.getValueForDisplay(r,s,n);return n?a.valueFormatted??d(a.value):a.value}}},eg={moduleName:"CommunityCore",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="gridDestroySvc",this.destroyCalled=!1}destroy(){if(this.destroyCalled)return;const{stateSvc:e,ctrlsSvc:t,context:o}=this.beans;this.eventSvc.dispatchEvent({type:"gridPreDestroyed",state:e?.getState()??{}}),this.destroyCalled=!0,t.get("gridCtrl")?.destroyGridUi(),o.destroy(),super.destroy()}},class extends Me{constructor(){super(),this.beanName="apiFunctionSvc",this.api=new hd,this.fns={...ld,dispatchEvent:dd},this.preDestroyLink="";const{api:e}=this;for(const t of Object.keys(ad))e[t]=this.makeApi(t)[t]}postConstruct(){this.preDestroyLink=this.beans.frameworkOverrides.getDocLink("grid-lifecycle/#grid-pre-destroyed")}addFunction(e,t){const{fns:o,beans:i}=this;o!==ld&&(o[e]=i?.validation?.validateApiFunction(e,t)??t)}makeApi(e){return{[e]:(...t)=>{const{beans:o,fns:{[e]:i}}=this;return i?i(o,...t):this.apiNotFound(e)}}}apiNotFound(e){const{beans:t,gos:o,preDestroyLink:i}=this;if(t){const t=ad[e];o.assertModuleRegistered(t,`api.${e}`)&&st(27,{fnName:e,module:t})}else st(26,{fnName:e,preDestroyLink:i})}destroy(){super.destroy(),this.fns=ld,this.beans=null}},class extends In{constructor(){super(...arguments),this.agGridDefaults={},this.agGridDefaultOverrides={},this.jsComps={},this.selectors={},this.icons={}}postConstruct(){const e=this.gos.get("components");if(null!=e)for(const t of Object.keys(e))this.jsComps[t]=e[t]}registerModule(e){const{icons:t,userComponents:o,dynamicBeans:i,selectors:s}=e;if(o){const e=(e,t,o,i)=>{this.agGridDefaults[e]=t,(o||i)&&(this.agGridDefaultOverrides[e]={params:o,processParams:i})};for(const t of Object.keys(o)){let i=o[t];if(Ci(i)&&(i=i.getComp(this.beans)),"object"==typeof i){const{classImp:o,params:s,processParams:n}=i;e(t,o,s,n)}else e(t,i)}}if(this.registerDynamicBeans(i),s?.forEach(e=>{this.selectors[e.selector]=e}),t)for(const e of Object.keys(t))this.icons[e]=t[e]}getUserComponent(e,t){const o=(e,t,o,i)=>({componentFromFramework:t,component:e,params:o,processParams:i}),{frameworkOverrides:i}=this.beans,s=i.frameworkComponent(t,this.gos.get("components"));if(null!=s)return o(s,!0);const n=this.jsComps[t];if(n){return o(n,i.isFrameworkComponent(n))}const r=this.agGridDefaults[t];if(r){const e=this.agGridDefaultOverrides[t];return o(r,!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?at(279,{name:e}):this.beans.validation?.missingDynamicBean(e)??at(256)}},class extends Me{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,o,i=!1){return this.getCompDetails(this.gridOptions,e,t,o,i)}getCompDetails(e,t,o,i,s=!1){const{name:n,cellRenderer:r}=t;let a,l,{compName:d,jsComp:h,fwComp:c,paramsFromSelector:u,popupFromSelector:g,popupPositionFromSelector:p}=jo(this.beans.frameworkOverrides,e,t,i);const m=e=>{const t=this.registry.getUserComponent(n,e);t&&(h=t.componentFromFramework?void 0:t.component,c=t.componentFromFramework?t.component:void 0,a=t.params,l=t.processParams)};var f;if(null!=d&&m(d),null==h&&null==c&&null!=o&&m(o),!h||!r||(f=h)&&f.prototype&&"getGui"in f.prototype||(h=this.agCompUtils?.adaptFunction(t,h)),!h&&!c){const{validation:e}=this.beans;return void(!s||d===o&&o?o&&!e&&nt(146,{comp:o}):d?e?.isProvidedUserComp(d)||nt(50,{compName:d}):o?e||nt(260,{...this.gos.getModuleErrorParams(),propName:n,compName:o}):nt(216,{name:n}))}const C=this.mergeParams(e,t,i,u,a,l),v=null==h,w=h??c;return{componentFromFramework:v,componentClass:w,params:C,type:t,popupFromSelector:g,popupPositionFromSelector:p,newAgStackInstance:()=>this.newAgStackInstance(w,v,C,t)}}newAgStackInstance(e,t,o,i){let s;s=!t?new e:this.frameworkCompWrapper.wrap(e,i.mandatoryMethods,i.optionalMethods,i),this.createBean(s);const n=s.init?.(o);return null==n?Ko.resolve(s):n.then(()=>s)}mergeParams(e,t,o,i=null,s,n){const r={...o,...s},a=e&&e[t.name+"Params"];if("function"==typeof a){Ge(r,a(o))}else"object"==typeof a&&Ge(r,a);return Ge(r,i),n?n(r):r}},class extends Me{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!==Ri)return Ri;if(!document.body)return-1;let e=1e6;const t=Yi()?6e6:1e9,o=document.createElement("div");for(document.body.appendChild(o);;){const i=2*e;if(o.style.height=i+"px",i>t||o.clientHeight!==i)break;e=i}return document.body.removeChild(o),Ri=e,e}(),$e(this.gos,"RowContainerHeightService - maxDivHeight = "+this.maxDivHeight)}updateOffset(){if(!this.stretching)return;const 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;const e=this.scrollY/this.maxScrollY,t=e*this.pixelsToShave;$e(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:"rowContainerHeightChanged"}))}clearOffset(){this.setUiContainerHeight(this.modelHeight),this.pixelsToShave=0,this.setDivStretchOffset(0)}setDivStretchOffset(e){const 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(){const e=this.beans.ctrlsSvc.getScrollFeature().getVScrollPosition();return e.bottom-e.top}getScrollPositionForPixel(e){if(this.pixelsToShave<=0)return e;const t=e/(this.modelHeight-this.getUiBodyHeight());return this.maxScrollY*t}},class extends Me{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){const{colFlex:o,colModel:i,colGroupSvc:s,colViewport:n,selectionColSvc:r}=this.beans;t||this.buildTrees(i,s),s?.updateOpenClosedVisibility(),this.leftCols=oh(this.treeLeft),this.centerCols=oh(this.treeCenter),this.rightCols=oh(this.treeRight),r?.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()),o?.refreshFlexedColumns(),this.updateBodyWidths(),this.setFirstRightAndLastLeftPinned(i,this.leftCols,this.rightCols,e),n.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(const t of this.allCols){let o=t.getParent();for(;o;){if(!o.isPadding()){const t=o.getProvidedColumnGroup().getLevel()+1;t>e&&(e=t);break}o=o.getParent()}}return e}updateBodyWidths(){const e=co(this.centerCols),t=co(this.leftCols),o=co(this.rightCols);this.isBodyWidthDirty=this.bodyWidth!==e;(this.bodyWidth!==e||this.leftWidth!==t||this.rightWidth!==o)&&(this.bodyWidth=e,this.leftWidth=t,this.rightWidth=o,this.eventSvc.dispatchEvent({type:"columnContainerWidthChanged"}),this.eventSvc.dispatchEvent({type:"displayedColumnsWidthChanged"}))}setLeftValues(e){this.setLeftValuesOfCols(e),this.setLeftValuesOfGroups()}setFirstRightAndLastLeftPinned(e,t,o,i){let s,n;this.gos.get("enableRtl")?(s=t?t[0]:null,n=o?to(o):null):(s=t?to(t):null,n=o?o[0]:null),e.getCols().forEach(e=>{e.setLastLeftPinned(e===s,i),e.setFirstRightPinned(e===n,i)})}buildTrees(e,t){const o=e.getColsToShow(),i=o.filter(e=>"left"==e.getPinned()),s=o.filter(e=>"right"==e.getPinned()),n=o.filter(e=>"left"!=e.getPinned()&&"right"!=e.getPinned()),r=new Ho,a=e=>t?t.createColumnGroups(e):e.columns;this.treeLeft=a({columns:i,idCreator:r,pinned:"left",oldDisplayedGroups:this.treeLeft}),this.treeRight=a({columns:s,idCreator:r,pinned:"right",oldDisplayedGroups:this.treeRight}),this.treeCenter=a({columns:n,idCreator:r,pinned:null,oldDisplayedGroups:this.treeCenter}),this.updateColsAndGroupsMap()}clear(){this.leftCols=[],this.rightCols=[],this.centerCols=[],this.allCols=[],this.ariaOrderColumns=[]}joinColsAriaOrder(e){const t=e.getCols(),o=[],i=[],s=[];for(const e of t){const t=e.getPinned();t?!0===t||"left"===t?o.push(e):s.push(e):i.push(e)}this.ariaOrderColumns=o.concat(i).concat(s)}getAriaColIndex(e){let t;return t=Wn(e)?e.getLeafColumns()[0]:e,this.ariaOrderColumns.indexOf(t)+1}setLeftValuesOfGroups(){[this.treeLeft,this.treeRight,this.treeCenter].forEach(e=>{e.forEach(e=>{if(Wn(e)){e.checkLeft()}})})}setLeftValuesOfCols(e){const{colModel:t}=this.beans;if(!t.getColDefCols())return;const o=t.getCols().slice(0),i=this.gos.get("enableRtl");[this.leftCols,this.rightCols,this.centerCols].forEach(t=>{if(i){let o=co(t);t.forEach(t=>{o-=t.getActualWidth(),t.setLeft(o,e)})}else{let o=0;t.forEach(t=>{t.setLeft(o,e),o+=t.getActualWidth()})}!function(e,t){for(let o=0;o<t.length;o++){const i=e.indexOf(t[o]);i>=0&&(e[i]=e[e.length-1],e.pop())}}(o,t)}),o.forEach(t=>{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){const{leftCols:t,beans:{colModel:o}}=this;return o.colSpanActive?this.getColsForRow(e,t):t}getRightColsForRow(e){const{rightCols:t,beans:{colModel:o}}=this;return o.colSpanActive?this.getColsForRow(e,t):t}getColsForRow(e,t,o,i){const s=[];let n=null;for(let r=0;r<t.length;r++){const a=t[r],l=t.length-r,d=Math.min(a.getColSpan(e),l),h=[a];if(d>1){const e=d-1;for(let o=1;o<=e;o++)h.push(t[r+o]);r+=e}let c;if(o?(c=!1,h.forEach(e=>{o(e)&&(c=!0)})):c=!0,c){if(0===s.length&&n){!!i&&i(a)&&s.push(n)}s.push(a)}n=a}return s}getContainerWidth(e){switch(e){case"left":return this.leftWidth;case"right":return this.rightWidth;default:return this.bodyWidth}}getColBefore(e){const t=this.allCols,o=t.indexOf(e);return o>0?t[o-1]:null}isPinningLeft(){return this.leftCols.length>0}isPinningRight(){return this.rightCols.length>0}updateColsAndGroupsMap(){this.colsAndGroupsMap={};const e=e=>{this.colsAndGroupsMap[e.getUniqueId()]=e};th(this.treeCenter,!1,e),th(this.treeLeft,!1,e),th(this.treeRight,!1,e)}isVisible(e){return this.colsAndGroupsMap[e.getUniqueId()]===e}getFirstColumn(){const e=this.gos.get("enableRtl"),t=["leftCols","centerCols","rightCols"];e&&t.reverse();for(let o=0;o<t.length;o++){const i=this[t[o]];if(i.length)return e?to(i):i[0]}return null}getColAfter(e){const t=this.allCols,o=t.indexOf(e);return o<t.length-1?t[o+1]:null}getColsLeftWidth(){return co(this.leftCols)}getDisplayedColumnsRightWidth(){return co(this.rightCols)}isColAtEdge(e,t){const o=this.allCols;if(!o.length)return!1;const i="first"===t;let s;if(Wn(e)){const t=e.getDisplayedLeafColumns();if(!t.length)return!1;s=i?t[0]:to(t)}else s=e;return(i?o[0]:to(o))===s}},class extends An{postConstruct(){const{globalListener:e,globalSyncListener:t}=this.beans;e&&this.addGlobalListener(e,!0),t&&this.addGlobalListener(t,!1)}},class extends Me{constructor(){super(...arguments),this.beanName="gos",this.domDataKey="__AG_"+Math.random().toString(),this.instanceId=qc++,this.gridReadyFired=!1,this.queueEvents=[],this.propEventSvc=new e,this.globalEventHandlerFactory=e=>(t,o)=>{if(!this.isAlive())return;const i=xc.has(t);if(i&&!e||!i&&e)return;if(!function(e){return!!Fc[e]}(t))return;const s=(e,t)=>{const o=Fc[e],i=this.gridOptions[o];"function"==typeof i&&this.beans.frameworkOverrides.wrapOutgoing(()=>i(t))};if(this.gridReadyFired)s(t,o);else if("gridReady"===t){s(t,o),this.gridReadyFired=!0;for(const e of this.queueEvents)s(e.eventName,e.event);this.queueEvents=[]}else this.queueEvents.push({eventName:t,event:o})}}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]??We[e]}getCallback(e){return this.mergeGridCommonParams(this.gridOptions[e])}exists(e){return o(this.gridOptions[e])}mergeGridCommonParams(e){if(e){return t=>e(this.addCommon(t))}return e}updateGridOptions({options:e,force:t,source:o="api"}){const i={id:jc++,properties:[]},s=[],{gridOptions:n,validation:r}=this;for(const a of Object.keys(e)){const l=e[a];r?.warnOnInitialPropertyUpdate(o,a);const d=t||"object"==typeof l&&"api"===o,h=n[a];if(d||h!==l){n[a]=l;const e={type:a,currentValue:l,previousValue:h,changeSet:i,source:o};s.push(e)}}this.validateGridOptions(this.gridOptions),i.properties=s.map(e=>e.type),s.forEach(e=>{$e(this,`Updated property ${e.type} from`,e.previousValue," to ",e.currentValue),this.propEventSvc.dispatchEvent(e)})}addPropertyEventListener(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(const o of Object.keys(e)){const i=e[o];if(null==i||!1===i)continue;let s=t[o];"function"==typeof s&&(s=s(e,this.gridOptions,this.beans)),s&&this.assertModuleRegistered(s,o)}}validateGridOptions(e){this.validateOptions(e,$c),this.validation?.processGridOptions(e)}validateColDef(e,t,o){!o&&this.beans.dataTypeSvc?.isColPendingInference(t)||(this.validateOptions(e,Ac),this.validation?.validateColDef(e))}assertModuleRegistered(e,t){const o=Array.isArray(e)?e.some(e=>this.isModuleRegistered(e)):this.isModuleRegistered(e);return o||nt(200,{...this.getModuleErrorParams(),moduleName:e,reasonOrId:t}),o}getModuleErrorParams(){return{gridId:this.gridId,gridScoped:Dh(),rowModelType:this.get("rowModelType"),isUmd:!1}}isModuleRegistered(e){return Ph(e,this.gridId,this.get("rowModelType"))}setInstanceDomData(e){e[_c]=this.instanceId}isElementInThisInstance(e){let t=e;for(;t;){const e=t[_c];if(o(e)){return e===this.instanceId}t=t.parentElement}return!1}},class extends Me{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(Co(e.source))),this.addManagedPropertyListeners(["defaultColDef","defaultColGroupDef","columnTypes","suppressFieldDotNotation"],this.recreateColumnDefs.bind(this)),this.addManagedPropertyListener("pivotMode",e=>this.setPivotMode(this.gos.get("pivotMode"),Co(e.source)))}createColsFromColDefs(e){const{beans:t}=this,{valueCache:o,colAutosize:i,rowGroupColsSvc:s,pivotColsSvc:n,valueColsSvc:r,visibleCols:a,eventSvc:l,groupHierarchyColSvc:d}=t,h=this.colDefs?Io(t,e):void 0;o?.expire();const c=this.colDefCols?.list,u=this.colDefCols?.tree,g=wo(t,this.colDefs,!0,u,e);uo(t,this.colDefCols?.tree,g.columnTree);const p=g.columnTree,m=g.treeDepth,f=ho(p),C={};f.forEach(e=>C[e.getId()]=e),this.colDefCols={tree:p,treeDepth:m,list:f,map:C},this.createColumnsForService([d],this.colDefCols),s?.extractCols(e,c),n?.extractCols(e,c),r?.extractCols(e,c),this.ready=!0,this.refreshCols(!0),a.refresh(e),l.dispatchEvent({type:"columnEverythingChanged",source:e}),h&&(this.changeEventsDispatching=!0,h(),this.changeEventsDispatching=!1),l.dispatchEvent({type:"newColumnsLoaded",source:e}),"gridInitializing"===e&&i?.applyAutosizeStrategy()}refreshCols(e){if(!this.colDefCols)return;const t=this.cols?.tree;this.saveColOrder();const{autoColSvc:o,selectionColSvc:i,rowNumbersSvc:s,quickFilter:n,pivotResultCols:r,showRowGroupCols:a,rowAutoHeight:l,visibleCols:d,colViewport:h,eventSvc:c}=this.beans,u=this.selectCols(r,this.colDefCols);this.createColumnsForService([o,i,s],u);const g=(p=this.gos,this.showingPivotResult?!p.get("enableStrictPivotColumnOrder"):p.get("maintainColumnOrder"));var p;e&&!g||this.restoreColOrder(u),this.positionLockedCols(u),a?.refresh(),n?.refreshCols(),this.setColSpanActive(),l?.setAutoHeightActive(u),d.clear(),h.clear();!oo(t,this.cols.tree)&&c.dispatchEvent({type:"gridColumnsChanged"})}createColumnsForService(e,t){for(const o of e)o&&(o.createColumns(t,e=>{this.lastOrder=e(this.lastOrder),this.lastPivotOrder=e(this.lastPivotOrder)}),o.addColumns(t))}selectCols(e,t){const o=e?.getPivotResultCols()??null;this.showingPivotResult=null!=o;const{map:i,list:s,tree:n,treeDepth:r}=o??t;if(this.cols={list:s.slice(),map:{...i},tree:n.slice(),treeDepth:r},o){o.list.some(e=>void 0!==this.cols?.map[e.getColId()])||(this.lastPivotOrder=null)}return this.cols}getColsToShow(){if(!this.cols)return[];const{valueColsSvc:e,selectionColSvc:t,gos:o}=this.beans,i=this.isPivotMode()&&!this.showingPivotResult,s=t?.isSelectionColumnEnabled(),n=o.get("rowNumbers"),r=e?.columns;return this.cols.list.filter(e=>{const t=go(e);if(i){const o=r?.includes(e);return t||o||s&&po(e)||n&&mo(e)}return t||e.isVisible()})}refreshAll(e){this.ready&&(this.refreshCols(!1),this.beans.visibleCols.refresh(e))}setColsVisible(e,t=!1,o){To(this.beans,{state:e.map(e=>({colId:"string"==typeof e?e:e.getColId(),hide:!t}))},o)}restoreColOrder(e){const t=this.showingPivotResult?this.lastPivotOrder:this.lastOrder;if(!t)return;const o=t.filter(t=>null!=e.map[t.getId()]);if(0===o.length)return;if(o.length===e.list.length)return void(e.list=o);const i=e=>{const t=e.getOriginalParent();if(!t)return!1;return t.getChildren().length>1||i(t)};if(!o.some(e=>i(e))){const t=new Set(o);for(const i of e.list)t.has(i)||o.push(i);return void(e.list=o)}const s=new Map;for(let e=0;e<o.length;e++){const t=o[e];s.set(t,e)}const n=e.list.filter(e=>!s.has(e));if(0===n.length)return void(e.list=o);const r=(e,t)=>{const o=t?t.getOriginalParent():e.getOriginalParent();if(!o)return null;let i=null,n=null;for(const r of o.getChildren())if(r!==t&&r!==e){if(r instanceof _t){const e=s.get(r);if(null==e)continue;(null==i||i<e)&&(i=e,n=r);continue}r.forEachLeafColumn(e=>{const t=s.get(e);null!=t&&(null==i||i<t)&&(i=t,n=e)})}return null==n?r(e,o):n},a=[],l=new Map;for(const e of n){const t=r(e,null);if(null==t){a.push(e);continue}const o=l.get(t);void 0===o?l.set(t,e):Array.isArray(o)?o.push(e):l.set(t,[o,e])}const d=new Array(e.list.length);let h=d.length-1;for(let e=a.length-1;e>=0;e--)d[h--]=a[e];for(let e=o.length-1;e>=0;e--){const t=o[e],i=l.get(t);if(i)if(Array.isArray(i))for(let e=i.length-1;e>=0;e--){const t=i[e];d[h--]=t}else d[h--]=i;d[h--]=t}e.list=d}positionLockedCols(e){e.list=Fo(e.list,this.gos)}saveColOrder(){this.showingPivotResult?this.lastPivotOrder=this.cols?.list??null:this.lastOrder=this.cols?.list??null}getColumnDefs(){return this.colDefCols?this.beans.colDefFactory?.getColumnDefs(this.colDefCols.list,this.showingPivotResult,this.lastOrder,this.cols?.list??[]):void 0}setColSpanActive(){this.colSpanActive=!!this.cols?.list.some(e=>null!=e.getColDef().colSpan)}isPivotMode(){return this.pivotMode}setPivotMode(e,t){if(e===this.pivotMode)return;if(this.pivotMode=e,!this.ready)return;this.refreshCols(!1);const{visibleCols:o,eventSvc:i}=this.beans;o.refresh(t),i.dispatchEvent({type:"columnPivotModeChanged"})}isPivotActive(){const e=this.beans.pivotColsSvc?.columns;return this.pivotMode&&!!e?.length}recreateColumnDefs(e){if(!this.cols)return;this.beans.autoColSvc?.updateColumns(e);const t=Co(e.source);this.createColsFromColDefs(t)}setColumnDefs(e,t){this.colDefs=e,this.createColsFromColDefs(t)}destroy(){uo(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){const{pivotResultCols:t,autoColSvc:o,selectionColSvc:i,groupHierarchyColSvc:s}=this.beans;io(this.colDefCols?.list,e),io(o?.columns?.list,e),io(i?.columns?.list,e),io(s?.columns?.list,e),io(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;const{map:o,list:i}=t;if("string"==typeof e&&o[e])return o[e];for(let t=0;t<i.length;t++)if(vo(i[t],e))return i[t];const{autoColSvc:s,selectionColSvc:n,groupHierarchyColSvc:r}=this.beans;return s?.getColumn(e)??n?.getColumn(e)??r?.getColumn(e)??null}},class extends Me{constructor(){super(...arguments),this.beanName="pageBounds",this.pixelOffset=0}getFirstRow(){return this.topRowBounds?.rowIndex??-1}getLastRow(){return this.bottomRowBounds?.rowIndex??-1}getCurrentPageHeight(){const{topRowBounds:e,bottomRowBounds:t}=this;return e&&t?Math.max(t.rowTop+t.rowHeight-e.rowTop,0):0}getCurrentPagePixelRange(){const{topRowBounds:e,bottomRowBounds:t}=this;return{pageFirstPixel:e?.rowTop??0,pageLastPixel:t?t.rowTop+t.rowHeight:0}}calculateBounds(e,t){const{rowModel:o}=this.beans,i=o.getRowBounds(e);i&&(i.rowIndex=e),this.topRowBounds=i;const s=o.getRowBounds(t);s&&(s.rowIndex=t),this.bottomRowBounds=s,this.calculatePixelOffset()}getPixelOffset(){return this.pixelOffset}calculatePixelOffset(){const e=this.topRowBounds?.rowTop??0;this.pixelOffset!==e&&(this.pixelOffset=e,this.eventSvc.dispatchEvent({type:"paginationPixelOffsetChanged"}))}},class extends Me{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(){const{pageBounds:e,pagination:t,rowModel:o}=this.beans;t?t.calculatePages():e.calculateBounds(0,o.getRowCount()-1)}},class extends Me{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=()=>{const e=()=>{this.getAllCellCtrls().forEach(e=>e.onCellSelectionChanged())},t=()=>{this.getAllCellCtrls().forEach(e=>e.updateRangeBordersIfRangeCount())},o=()=>{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"],()=>{Tt(this.gos)?o():i()});Tt(this.gos)&&o()}}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()});const{stickyRowSvc:e,gos:t,showRowGroupCols:o}=this.beans;if(o&&this.addManagedPropertyListener("showOpenedGroup",()=>{const e=o.getShowRowGroupCols();e.length&&this.refreshCells({columns:e,force:!0})}),e)this.stickyRowFeature=e.createStickyRowFeature(this,this.createRowCon.bind(this),this.destroyRowCtrls.bind(this));else{const e=this.gridBodyCtrl;e.setStickyTopHeight(0),e.setStickyBottomHeight(0)}this.registerCellEventListeners(),this.initialiseCache(),this.printLayout=ct(t,"print"),this.embedFullWidthRows=this.printLayout||t.get("embedFullWidthRows"),this.redrawAfterModelUpdate()}initialiseCache(){if(this.gos.get("keepDetailRows")){const e=this.getKeepDetailRowsCount(),t=null!=e?e:3;this.cachedRowCtrls=new ju(t)}}getKeepDetailRowsCount(){return this.gos.get("keepDetailRowsCount")}getStickyTopRowCtrls(){return this.stickyRowFeature?.stickyTopRowCtrls??[]}getStickyBottomRowCtrls(){return this.stickyRowFeature?.stickyBottomRowCtrls??[]}updateAllRowCtrls(){const e=Object.values(this.rowCtrlsByRowIndex),t=Object.values(this.zombieRowCtrls),o=this.cachedRowCtrls?.getEntries()??[];t.length>0||o.length>0?this.allRowCtrls=[...e,...t,...o]:this.allRowCtrls=e}isCellBeingRendered(e,t){const o=this.rowCtrlsByRowIndex[e];if(!t||!o)return!!o;if(o.isFullWidth())return!0;const i=this.beans.spannedRowRenderer?.getCellByPosition({rowIndex:e,column:t,rowPinned:null});return!!i||!!o.getCellCtrl(t)||!o.isRowRendered()}updateCellFocus(e){this.getAllCellCtrls().forEach(t=>t.onCellFocused(e)),this.getFullWidthRowCtrls().forEach(t=>t.onFullWidthRowFocused(e))}onCellFocusChanged(e){if(e&&null!=e.rowIndex&&!e.rowPinned){const t=this.beans.colModel.getCol(e.column)??void 0;this.isCellBeingRendered(e.rowIndex,t)||this.redraw()}this.updateCellFocus(e)}onSuppressCellFocusChanged(e){this.getAllCellCtrls().forEach(t=>t.onSuppressCellFocusChanged(e)),this.getFullWidthRowCtrls().forEach(t=>t.onSuppressCellFocusChanged(e))}registerCellEventListeners(){this.addManagedEventListeners({cellFocused:e=>this.onCellFocusChanged(e),cellFocusCleared:()=>this.updateCellFocus(),flashCells:e=>{const{cellFlashSvc:t}=this.beans;t&&this.getAllCellCtrls().forEach(o=>t.onFlashCells(o,e))},columnHoverChanged:()=>{this.getAllCellCtrls().forEach(e=>e.onColumnHover())},displayedColumnsChanged:()=>{this.getAllCellCtrls().forEach(e=>e.onDisplayedColumnsChanged())},displayedColumnsWidthChanged:()=>{this.printLayout&&this.getAllCellCtrls().forEach(e=>e.onLeftChanged())}}),this.setupRangeSelectionListeners(),this.refreshListenersToColumnsForCellComps(),this.addManagedEventListeners({gridColumnsChanged:this.refreshListenersToColumnsForCellComps.bind(this)}),this.addDestroyFunc(this.removeGridColumnListeners.bind(this))}removeGridColumnListeners(){this.destroyFuncsForColumnListeners.forEach(e=>e()),this.destroyFuncsForColumnListeners.length=0}refreshListenersToColumnsForCellComps(){this.removeGridColumnListeners();this.colModel.getCols().forEach(e=>{const t=t=>{this.getAllCellCtrls().forEach(o=>{o.column===e&&t(o)})},o=()=>{t(e=>e.onLeftChanged())},i=()=>{t(e=>e.onWidthChanged())},s=()=>{t(e=>e.onFirstRightPinnedChanged())},n=()=>{t(e=>e.onLastLeftPinnedChanged())},r=()=>{t(e=>e.onColDefChanged())};e.__addEventListener("leftChanged",o),e.__addEventListener("widthChanged",i),e.__addEventListener("firstRightPinnedChanged",s),e.__addEventListener("lastLeftPinnedChanged",n),e.__addEventListener("colDefChanged",r),this.destroyFuncsForColumnListeners.push(()=>{e.__removeEventListener("leftChanged",o),e.__removeEventListener("widthChanged",i),e.__removeEventListener("firstRightPinnedChanged",s),e.__removeEventListener("lastLeftPinnedChanged",n),e.__removeEventListener("colDefChanged",r)})})}onDomLayoutChanged(){const e=ct(this.gos,"print"),t=e||this.gos.get("embedFullWidthRows"),o=t!==this.embedFullWidthRows||this.printLayout!==e;this.printLayout=e,this.embedFullWidthRows=t,o&&this.redrawAfterModelUpdate({domLayoutChanged:!0})}datasourceChanged(){this.firstRenderedRow=0,this.lastRenderedRow=-1;const e=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(e)}onPageLoaded(e){const t={recycleRows:e.keepRenderedRows,animate:e.animate,newData:e.newData,newPage:e.newPage,onlyBody:!0};this.redrawAfterModelUpdate(t)}getAllCellsNotSpanningForColumn(e){const t=[];return this.getAllRowCtrls().forEach(o=>{const i=o.getCellCtrl(e,!0)?.eGui;i&&t.push(i)}),t}refreshFloatingRowComps(e=!0){this.refreshFloatingRows(this.topRowCtrls,"top",e),this.refreshFloatingRows(this.bottomRowCtrls,"bottom",e)}refreshFloatingRows(e,t,o){const{pinnedRowModel:i,beans:s,printLayout:n}=this,r=Object.fromEntries(e.map(e=>[e.rowNode.id,e]));i?.forEachPinnedRow(t,(a,l)=>{const d=e[l];d&&void 0===i.getPinnedRowById(d.rowNode.id,t)&&(d.destroyFirstPass(),d.destroySecondPass()),a.id in r&&o?(e[l]=r[a.id],delete r[a.id]):e[l]=new Lu(a,s,!1,!1,n)});const a=("top"===t?i?.getPinnedTopRowCount():i?.getPinnedBottomRowCount())??0;e.length=a}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);{const t=t=>{const o=t[e.rowIndex];o&&o.rowNode===e&&(o.destroyFirstPass(),o.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){const{editSvc:t}=this.beans;t?.isEditing()&&(t.isBatchEditing()?t.cleanupEditors():t.stopEditing(void 0,{source:"api"}));if(null!=e)return e?.forEach(e=>this.redrawRow(e,!0)),void this.dispatchDisplayedRowsChanged(!1);this.redrawAfterModelUpdate()}redrawAfterModelUpdate(e={}){this.getLockOnRefresh();const t=this.beans.focusSvc?.getFocusCellToUseAfterRefresh();this.updateContainerHeights(),this.scrollToTopIfNewData(e);const o=!e.domLayoutChanged&&!!e.recycleRows,i=e.animate&&wt(this.gos),s=o?this.getRowsToRecycle():null;o||this.removeAllRowComps(),this.workOutFirstAndLastRowsToRender();const{stickyRowFeature:n,gos:r}=this;if(n){n.checkStickyRows();const e=n.extraTopHeight+n.extraBottomHeight;e&&this.updateContainerHeights(e)}this.recycleRows(s,i),this.gridBodyCtrl.updateRowCount(),e.onlyBody||this.refreshFloatingRowComps(r.get("enableRowPinning")?o:void 0),this.dispatchDisplayedRowsChanged(),null!=t&&this.restoreFocusedCell(t),this.releaseLockOnRefresh()}scrollToTopIfNewData(e){const t=e.newData||e.newPage,o=this.gos.get("suppressScrollOnNewData");t&&!o&&(this.gridBodyCtrl.scrollFeature.scrollToTop(),this.stickyRowFeature?.resetOffsets())}updateContainerHeights(e=0){const{rowContainerHeight:t}=this;if(this.printLayout)return void t.setModelHeight(null);let o=this.pageBounds.getCurrentPageHeight();0===o&&(o=1),t.setModelHeight(o+e)}getLockOnRefresh(){if(this.refreshInProgress)throw new Error(at(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;const t=this.beans.focusSvc,o=this.findPositionToFocus(e);o?e.rowIndex===o.rowIndex&&e.rowPinned==o.rowPinned?t.doesRowOrCellHaveBrowserFocus()||this.updateCellFocus(zt(this.gos,{...o,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0,type:"cellFocused"})):t.setFocusedCell({...o,preventScrollOnBrowserFocus:!0,forceBrowserFocus:!0}):t.focusHeaderPosition({headerPosition:{headerRowIndex:ka(this.beans)-1,column:e.column}})}findPositionToFocus(e){const{pagination:t,pageBounds:o}=this.beans;let i=e;for(null==i.rowPinned&&t&&o&&!t.isRowInPage(i.rowIndex)&&(i={rowPinned:null,rowIndex:o.getFirstRow()});i;){if(null==i.rowPinned&&o)if(i.rowIndex<o.getFirstRow()){if(i=bd(this.beans,{rowPinned:null,rowIndex:0}),!i)return null}else i.rowIndex>o.getLastRow()&&(i={rowPinned:null,rowIndex:o.getLastRow()});const t=this.getRowByPosition(i);if(t?.isAlive())return{...t.getRowPosition(),column:e.column};i=bd(this.beans,i)}return null}getAllCellCtrls(){const e=[],t=this.getAllRowCtrls(),o=t.length;for(let i=0;i<o;i++){const o=t[i].getAllCellCtrls(),s=o.length;for(let t=0;t<s;t++)e.push(o[t])}return e}getAllRowCtrls(){const{spannedRowRenderer:e}=this.beans,t=this.getStickyTopRowCtrls(),o=this.getStickyBottomRowCtrls();return[...this.topRowCtrls,...this.bottomRowCtrls,...t,...o,...e?.getCtrls("top")??[],...e?.getCtrls("bottom")??[],...e?.getCtrls("center")??[],...Object.values(this.rowCtrlsByRowIndex)]}addRenderedRowListener(e,t,o){const i=this.rowCtrlsByRowIndex[t];i&&i.addEventListener(e,o)}refreshCells({rowNodes:e,columns:t,force:o,suppressFlash:i}={}){const s={force:o,newData:!1,suppressFlash:i};for(const o of this.getCellCtrls(e,t))o.refreshOrDestroyCell(s);this.refreshFullWidth(e)}refreshRows(e={}){this.getRowCtrls(e.rowNodes).forEach(t=>t.refreshRow(e)),this.refreshFullWidth(e.rowNodes)}refreshFullWidth(e){if(!e)return;let t=!1;for(const o of this.getRowCtrls(e)){if(!o.isFullWidth())continue;o.refreshFullWidth()||(t=!0,this.redrawRow(o.rowNode,!0))}t&&this.dispatchDisplayedRowsChanged(!1)}getRowCtrls(e){const t=qu(e),o=this.getAllRowCtrls();return e&&t?o.filter(e=>_u(e.rowNode,t)):o}getCellCtrls(e,t){let i;o(t)&&(i={},t.forEach(e=>{const t=this.colModel.getCol(e);o(t)&&(i[t.getId()]=!0)}));const s=[];return this.getRowCtrls(e).forEach(e=>{e.getAllCellCtrls().forEach(e=>{const t=e.column.getId();i&&!i[t]||s.push(e)})}),s}destroy(){this.removeAllRowComps(!0),super.destroy()}removeAllRowComps(e=!1){const t=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(t,e),this.stickyRowFeature?.destroyStickyCtrls()}getRowsToRecycle(){const e=[];for(const t of Object.keys(this.rowCtrlsByRowIndex)){null==this.rowCtrlsByRowIndex[t].rowNode.id&&e.push(t)}this.removeRowCtrls(e);const t={};for(const e of Object.values(this.rowCtrlsByRowIndex)){t[e.rowNode.id]=e}return this.rowCtrlsByRowIndex={},t}removeRowCtrls(e,t=!1){e.forEach(e=>{const o=this.rowCtrlsByRowIndex[e];o&&(o.destroyFirstPass(t),o.destroySecondPass()),delete this.rowCtrlsByRowIndex[e]})}onBodyScroll(e){"vertical"===e.direction&&this.redraw({afterScroll:!0})}redraw(e={}){const{focusSvc:t,animationFrameSvc:o}=this.beans,{afterScroll:i}=e;let s;const n=this.stickyRowFeature;n&&(s=t?.getFocusCellToUseAfterRefresh()||void 0);const r=this.firstRenderedRow,a=this.lastRenderedRow;this.workOutFirstAndLastRowsToRender();let l=!1;if(n){l=n.checkStickyRows();const e=n.extraTopHeight+n.extraBottomHeight;e&&this.updateContainerHeights(e)}const d=this.firstRenderedRow!==r||this.lastRenderedRow!==a;if((!i||l||d)&&(this.getLockOnRefresh(),this.recycleRows(null,!1,i),this.releaseLockOnRefresh(),this.dispatchDisplayedRowsChanged(i&&!l),null!=s)){const e=t?.getFocusCellToUseAfterRefresh();null!=s&&null==e&&(o?.flushAllFrames(),this.restoreFocusedCell(s))}}removeRowCompsNotToDraw(e,t){const o={};e.forEach(e=>o[e]=!0);const i=Object.keys(this.rowCtrlsByRowIndex).filter(e=>!o[e]);this.removeRowCtrls(i,t)}calculateIndexesToDraw(e){const t=[];for(let e=this.firstRenderedRow;e<=this.lastRenderedRow;e++)t.push(e);const o=this.beans.pagination,i=this.beans.focusSvc?.getFocusedCell()?.rowIndex;null!=i&&(i<this.firstRenderedRow||i>this.lastRenderedRow)&&(!o||o.isRowInPage(i))&&i<this.rowModel.getRowCount()&&t.push(i);const s=e=>{const o=e.rowNode.rowIndex;null!=o&&o!==i&&(o<this.firstRenderedRow||o>this.lastRenderedRow)&&this.doNotUnVirtualiseRow(e)&&t.push(o)};for(const e of Object.values(this.rowCtrlsByRowIndex))s(e);if(e)for(const t of Object.values(e))s(t);t.sort((e,t)=>e-t);const n=[];for(let e=0;e<t.length;e++){const o=t[e],i=this.rowModel.getRow(o);i&&!i.sticky&&n.push(o)}return n}recycleRows(e,t=!1,o=!1){const i=this.calculateIndexesToDraw(e);if((this.printLayout||o)&&(t=!1),this.removeRowCompsNotToDraw(i,!t),i.forEach(i=>{this.createOrUpdateRowCtrl(i,e,t,o)}),e){const{animationFrameSvc:i}=this.beans;i?.active&&o&&!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(){const{visibleCols:e}=this.beans,t=e.isPinningLeft(),o=e.isPinningRight();(this.pinningLeft!==t||o!==this.pinningRight)&&(this.pinningLeft=t,this.pinningRight=o,this.embedFullWidthRows&&this.redrawFullWidthEmbeddedRows())}redrawFullWidthEmbeddedRows(){const e=[];this.getFullWidthRowCtrls().forEach(t=>{const o=t.rowNode.rowIndex;e.push(o.toString())}),this.refreshFloatingRowComps(),this.removeRowCtrls(e),this.redraw({afterScroll:!0})}getFullWidthRowCtrls(e){const t=qu(e);return this.getAllRowCtrls().filter(e=>{if(!e.isFullWidth())return!1;const o=e.rowNode;return!(null!=t&&!_u(o,t))})}createOrUpdateRowCtrl(e,t,i,s){let n,r=this.rowCtrlsByRowIndex[e];r||(n=this.rowModel.getRow(e),o(n)&&o(t)&&t[n.id]&&n.alreadyRendered&&(r=t[n.id],t[n.id]=null));if(!r){if(n||(n=this.rowModel.getRow(e)),!o(n))return;r=this.createRowCon(n,i,s)}return n&&(n.alreadyRendered=!0),this.rowCtrlsByRowIndex[e]=r,r}destroyRowCtrls(e,t){const o=[];if(e)for(const i of Object.values(e))if(i)if(this.cachedRowCtrls&&i.isCacheable())this.cachedRowCtrls.addRow(i);else if(i.destroyFirstPass(!t),t){const e=i.instanceId;this.zombieRowCtrls[e]=i,o.push(()=>{i.destroySecondPass(),delete this.zombieRowCtrls[e]})}else i.destroySecondPass();t&&(o.push(()=>{this.isAlive()&&(this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged())}),window.setTimeout(()=>o.forEach(e=>e()),400))}getRowBuffer(){return this.gos.get("rowBuffer")}getRowBufferInPixels(){return this.getRowBuffer()*mt(this.beans)}workOutFirstAndLastRowsToRender(){const{rowContainerHeight:e,pageBounds:t,rowModel:o}=this;let i,s;if(e.updateOffset(),o.isRowsToRender())if(this.printLayout)this.beans.environment.refreshRowHeightVariable(),i=t.getFirstRow(),s=t.getLastRow();else{const n=this.getRowBufferInPixels(),r=this.ctrlsSvc.getScrollFeature(),a=this.gos.get("suppressRowVirtualisation");let l,d,h=!1;do{const o=t.getPixelOffset(),{pageFirstPixel:i,pageLastPixel:s}=t.getCurrentPagePixelRange(),c=e.divStretchOffset,u=r.getVScrollPosition(),g=u.top,p=u.bottom;a?(l=i+c,d=s+c):(l=Math.max(g+o-n,i)+c,d=Math.min(p+o+n,s)+c),this.firstVisibleVPixel=Math.max(g+o,i)+c,this.lastVisibleVPixel=Math.min(p+o,s)+c,h=this.ensureAllRowsInRangeHaveHeightsCalculated(l,d)}while(h);let c=o.getRowIndexAtPixel(l),u=o.getRowIndexAtPixel(d);const g=t.getFirstRow(),p=t.getLastRow();c<g&&(c=g),u>p&&(u=p),i=c,s=u}else i=0,s=-1;const n=ct(this.gos,"normal"),r=this.gos.get("suppressMaxRenderedRowRestriction"),a=Math.max(this.getRowBuffer(),500);n&&!r&&s-i>a&&(s=i+a);const l=i!==this.firstRenderedRow,d=s!==this.lastRenderedRow;(l||d)&&(this.firstRenderedRow=i,this.lastRenderedRow=s,this.eventSvc.dispatchEvent({type:"viewportChanged",firstRow:i,lastRow:s}))}dispatchFirstDataRenderedEvent(){this.dataFirstRenderedFired||(this.dataFirstRenderedFired=!0,ue(this.beans,()=>{this.beans.eventSvc.dispatchEvent({type:"firstDataRendered",firstRow:this.firstRenderedRow,lastRow:this.lastRenderedRow})}))}ensureAllRowsInRangeHaveHeightsCalculated(e,t){const o=this.pinnedRowModel?.ensureRowHeightsValid(),i=this.stickyRowFeature?.ensureRowHeightsValid(),{pageBounds:s,rowModel:n}=this,r=n.ensureRowHeightsValid(e,t,s.getFirstRow(),s.getLastRow());return(r||i)&&this.eventSvc.dispatchEvent({type:"recalculateRowBounds"}),!!(i||r||o)&&(this.updateContainerHeights(),!0)}doNotUnVirtualiseRow(e){const t=!1,o=e.rowNode,i=this.focusSvc.isRowFocused(o.rowIndex,o.rowPinned),s=this.editSvc?.isEditing(e),n=o.detail;if(!(i||s||n))return t;return!!this.isRowPresent(o)||t}isRowPresent(e){return!!this.rowModel.isRowPresent(e)&&(this.beans.pagination?.isRowInPage(e.rowIndex)??!0)}createRowCon(e,t,o){const i=this.cachedRowCtrls?.getRow(e)??null;if(i)return i;const s=o&&!this.printLayout&&!!this.beans.animationFrameSvc?.active;return new Lu(e,this.beans,t,s,this.printLayout)}getRenderedNodes(){const 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;const{rowIndex:o}=e;switch(e.rowPinned){case"top":t=this.topRowCtrls[o];break;case"bottom":t=this.bottomRowCtrls[o];break;default:t=this.rowCtrlsByRowIndex[o],t||(t=this.getStickyTopRowCtrls().find(e=>e.rowNode.rowIndex===o)||null,t||(t=this.getStickyBottomRowCtrls().find(e=>e.rowNode.rowIndex===o)||null))}return t}isRangeInRenderedViewport(e,t){if(null==e||null==t)return!1;const o=e>this.lastRenderedRow;return!(t<this.firstRenderedRow)&&!o}},class extends Me{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=ht(this.gos),this.cellExpressions=this.gos.get("enableCellExpressions"),this.isTreeData=this.gos.get("treeData"),this.initialised=!0;const 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,o=!1,i=!1,s="ui"){const{showRowGroupColValueSvc:n}=this.beans,r=!e&&t.group,a=e?.colDef.showRowGroup,l=!this.isTreeData||t.footer;if(n&&l&&(r||a)){const s=n.getGroupValue(t,e);if(null==s)return{value:null,valueFormatted:null};if(!o)return{value:s.value,valueFormatted:null};const r=n.formatAndPrefixGroupColValue(s,e,i);return{value:s.value,valueFormatted:r}}if(!e)return{value:t.key,valueFormatted:null};const d=t.leafGroup&&this.colModel.isPivotMode(),h=t.group&&t.expanded&&!t.footer&&!d,c=this.gos.get("groupSuppressBlankHeader")||!t.sibling,u=h&&!c,g=this.getValue(e,t,u,s);return{value:g,valueFormatted:o&&!(i&&!1===e.colDef.useValueFormatterForExport)?this.formatValue(e,t,g):null}}getValue(e,t,o=!1,i="ui"){if(this.initialised||this.init(),!t)return;const s=e.getColDef(),n=s.field,r=e.getColId(),a=t.data;if(this.hasEditSvc&&"ui"===i){const o=this.editSvc;if(o.isEditing()){const i=o.getCellDataValue({rowNode:t,column:e},!0);if(void 0!==i)return i}}let l;const d=s.showRowGroup;if("string"==typeof d){if((this.beans.rowGroupColsSvc?.getColumnIndex(d)??-1)>t.level)return null}const h="string"!=typeof d||!t.group,c=t.groupData&&r in t.groupData,u=!o&&t.aggData&&void 0!==t.aggData[r],g=this.isSsrm&&o&&!!s.aggFunc,p=this.isSsrm&&t.footer&&t.field&&(!0===s.showRowGroup||s.showRowGroup===t.field);if(this.isTreeData&&u)l=t.aggData[r];else if(this.isTreeData&&s.valueGetter)l=this.executeValueGetter(s.valueGetter,a,e,t);else if(this.isTreeData&&n&&a)l=lh(a,n,e.isFieldContainsDots());else if(c)l=t.groupData[r];else if(u)l=t.aggData[r];else if(s.valueGetter&&!g){if(!h)return l;l=this.executeValueGetter(s.valueGetter,a,e,t)}else if(p)l=lh(a,t.field,e.isFieldContainsDots());else if(n&&a&&!g){if(!h)return l;l=lh(a,n,e.isFieldContainsDots())}if(this.cellExpressions&&"string"==typeof l&&0===l.indexOf("=")){const o=l.substring(1);l=this.executeValueGetter(o,a,e,t)}return l}parseValue(e,t,i,s){const n=e.getColDef(),r=n.valueParser;if(o(r)){const o=zt(this.gos,{node:t,data:t?.data,oldValue:s,newValue:i,colDef:n,column:e});return"function"==typeof r?r(o):this.expressionSvc?.evaluate(r,o)}return i}getDeleteValue(e,t){return o(e.getColDef().valueParser)?this.parseValue(e,t,"",this.getValueForDisplay(e,t).value)??null:null}formatValue(e,t,o,i,s=!0){const{expressionSvc:n}=this.beans;let r,a=null;const l=e.getColDef();if(i?r=i:s&&(r=l.valueFormatter),r){const i=t?t.data:null,s=zt(this.gos,{value:o,node:t,data:i,colDef:l,column:e});a="function"==typeof r?r(s):n?n.evaluate(r,s):null}else if(l.refData)return l.refData[o]||"";return null==a&&Array.isArray(o)&&(a=o.join(", ")),a}setValue(e,t,s,n){const r=this.colModel.getColDefCol(t);if(!e||!r)return!1;i(e.data)&&(e.data={});const{field:a,valueSetter:l}=r.getColDef();if(i(a)&&i(l))return st(17),!1;if(this.dataTypeSvc&&!this.dataTypeSvc.checkType(r,s))return st(135),!1;const d=zt(this.gos,{node:e,data:e.data,oldValue:this.getValue(r,e,void 0,n),newValue:s,colDef:r.getColDef(),column:r});let h;if(d.newValue=s,h=o(l)?"function"==typeof l?l(d):this.expressionSvc?.evaluate(l,d):this.setValueUsingField(e.data,a,s,r.isFieldContainsDots()),void 0===h&&(h=!0),!h)return!1;e.resetQuickFilterAggregateText(),this.valueCache?.onDataChanged();const c=this.getValue(r,e);return this.dispatchCellValueChangedEvent(e,d,c,n),e.pinnedSibling&&this.dispatchCellValueChangedEvent(e.pinnedSibling,d,c,n),!0}dispatchCellValueChangedEvent(e,t,o,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:o,value:o,source:i})}callColumnCellValueChangedHandler(e){const 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,o,i){if(!t)return!1;let s=!1;if(i){const i=t.split(".");let n=e;for(;i.length>0&&n;){const e=i.shift();0===i.length?(s=n[e]===o,s||(n[e]=o)):n=n[e]}}else s=e[t]===o,s||(e[t]=o);return!s}executeValueGetterWithValueCache(e,t,o,i){const s=o.getColId(),n=this.valueCache.getValue(i,s);if(void 0!==n)return n;const r=this.executeValueGetterWithoutValueCache(e,t,o,i);return this.valueCache.setValue(i,s,r),r}executeValueGetterWithoutValueCache(e,t,o,i){const s=zt(this.gos,{data:t,node:i,column:o,colDef:o.getColDef(),getValue:this.getValueCallback.bind(this,i)});let n;return n="function"==typeof e?e(s):this.expressionSvc?.evaluate(e,s),n}getValueCallback(e,t){const o=this.colModel.getColDefCol(t);return o?this.getValue(o,e):null}getKeyForNode(e,t){const o=this.getValue(e,t),i=e.getColDef().keyCreator;let s=o;if(i){s=i(zt(this.gos,{value:o,colDef:e.getColDef(),column:e,node:t,data:t.data}))}return"string"==typeof s||null==s||(s=String(s),"[object Object]"===s&&st(121)),s}},class extends Me{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(){const e=this.clearFocusedCell.bind(this);this.addManagedEventListeners({columnPivotModeChanged:e,newColumnsLoaded:this.onColumnEverythingChanged.bind(this),columnGroupOpened:e,columnRowGroupChanged:e}),this.addDestroyFunc(vs(this.beans))}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;const e=this.focusedCell.column,t=this.colModel.getCol(e.getId());e!==t&&this.clearFocusedCell()}getFocusCellToUseAfterRefresh(){const{gos:e,focusedCell:t}=this;return e.get("suppressFocusAfterRefresh")||e.get("suppressCellFocus")||!t?null:this.doesRowOrCellHaveBrowserFocus()?t:null}getFocusHeaderToUseAfterRefresh(){return this.gos.get("suppressFocusAfterRefresh")||!this.focusedHeader?null:this.isDomDataPresentInHierarchy(u(this.beans),_a)?this.focusedHeader:null}doesRowOrCellHaveBrowserFocus(){const e=u(this.beans);return!!this.isDomDataPresentInHierarchy(e,Wr)||this.isDomDataPresentInHierarchy(e,$r)}isDomDataPresentInHierarchy(e,t){let o=e;for(;o;){if(Ct(this.gos,o,t))return!0;o=o.parentNode}return!1}getFocusedCell(){return this.focusedCell}getFocusEventParams(e){const{rowIndex:t,rowPinned:o,column:i}=e,s={rowIndex:t,rowPinned:o,column:i,isFullWidthCell:!1},n=this.rowRenderer.getRowByPosition({rowIndex:t,rowPinned:o});return n&&(s.isFullWidthCell=n.isFullWidth()),s}clearFocusedCell(){if(null==this.focusedCell)return;const e=this.getFocusEventParams(this.focusedCell);this.focusedCell=null,this.eventSvc.dispatchEvent({type:"cellFocusCleared",...e})}setFocusedCell(e){this.setFocusRecovered();const{column:o,rowIndex:i,rowPinned:s,forceBrowserFocus:n=!1,preventScrollOnBrowserFocus:r=!1,sourceEvent:a}=e,l=this.colModel.getCol(o);if(!l)return void(this.focusedCell=null);this.focusedCell={rowIndex:i,rowPinned:t(s),column:l};const d=this.getFocusEventParams(this.focusedCell);this.eventSvc.dispatchEvent({type:"cellFocused",...d,...this.previousCellFocusParams&&{previousParams:this.previousCellFocusParams},forceBrowserFocus:n,preventScrollOnBrowserFocus:r,sourceEvent:a}),this.previousCellFocusParams=d}isCellFocused(e){return null!=this.focusedCell&&Cd(e,this.focusedCell)}isHeaderWrapperFocused(e){if(null==this.focusedHeader)return!1;const{column:t,rowCtrl:{rowIndex:o,pinned:i}}=e,{column:s,headerRowIndex:n}=this.focusedHeader;return t===s&&o===n&&i==s.getPinned()}focusHeaderPosition(e){if(this.setFocusRecovered(),Pa(this.beans))return!1;const{direction:t,fromTab:o,allowUserOverride:i,event:s,fromCell:n,rowWithoutSpanValue:r}=e;let{headerPosition:a}=e;if(n&&this.filterManager?.isAdvFilterHeaderActive())return this.focusAdvancedFilter(a);if(i){const e=this.focusedHeader,i=ka(this.beans);if(o){const o=this.gos.getCallback("tabToNextHeader");o&&(a=this.getHeaderPositionFromUserFunc({userFunc:o,direction:t,currentPosition:e,headerPosition:a,headerRowCount:i}))}else{const t=this.gos.getCallback("navigateToNextHeader");if(t&&s){a=t({key:s.key,previousHeaderPosition:e,nextHeaderPosition:a,headerRowCount:i,event:s})}}}return!!a&&this.focusProvidedHeaderPosition({headerPosition:a,direction:t,event:s,fromCell:n,rowWithoutSpanValue:r})}focusHeaderPositionFromUserFunc(e){if(Pa(this.beans))return!1;const{userFunc:t,headerPosition:o,direction:i,event:s}=e,n=this.focusedHeader,r=ka(this.beans),a=this.getHeaderPositionFromUserFunc({userFunc:t,direction:i,currentPosition:n,headerPosition:o,headerRowCount:r});return!!a&&this.focusProvidedHeaderPosition({headerPosition:a,direction:i,event:s})}getHeaderPositionFromUserFunc(e){const{userFunc:t,direction:o,currentPosition:i,headerPosition:s,headerRowCount:n}=e,r=t({backwards:"Before"===o,previousHeaderPosition:i,nextHeaderPosition:s,headerRowCount:n});return!0===r?i:!1===r?null:r}focusProvidedHeaderPosition(e){const{headerPosition:t,direction:o,fromCell:i,rowWithoutSpanValue:s,event:n}=e,{column:r,headerRowIndex:a}=t,{filterManager:l,ctrlsSvc:d,headerNavigation:h}=this.beans;if(-1===a)return l?.isAdvFilterHeaderActive()?this.focusAdvancedFilter(t):this.focusGridView({column:r,event:n});h?.scrollToColumn(r,o);const c=d.getHeaderRowContainerCtrl(r.getPinned()),u=c?.focusHeader(t.headerRowIndex,r,n)||!1;return h&&u&&(null!=s||i)&&(h.currentHeaderRowWithoutSpan=s??-1),u}focusFirstHeader(){if(this.overlays?.isExclusive()&&this.focusOverlay())return!0;const e=this.visibleCols.allCols[0];if(!e)return!1;const t=Rc(this.beans,e,0);return this.focusHeaderPosition({headerPosition:t,rowWithoutSpanValue:0})}focusLastHeader(e){if(this.overlays?.isExclusive()&&this.focusOverlay(!0))return!0;const t=ka(this.beans)-1,o=to(this.visibleCols.allCols);return this.focusHeaderPosition({headerPosition:{headerRowIndex:t,column:o},rowWithoutSpanValue:-1,event:e})}focusPreviousFromFirstCell(e){return this.filterManager?.isAdvFilterHeaderActive()?this.focusAdvancedFilter(null):this.focusLastHeader(e)}isAnyCellFocused(){return!!this.focusedCell}isRowFocused(e,o){return null!=this.focusedCell&&(this.focusedCell.rowIndex===e&&this.focusedCell.rowPinned===t(o))}focusOverlay(e){const t=this.overlays?.isVisible()&&this.overlays.eWrapper?.getGui();return!!t&&bs(t,e)}focusGridView(e){const{backwards:o=!1,canFocusOverlay:i=!0,event:s}=e;if(this.overlays?.isExclusive())return i&&this.focusOverlay(o);if(Da(this.beans))return o&&!Pa(this.beans)?this.focusLastHeader():!(!i||!this.focusOverlay(o))||!o&&Ma(this.beans,o);const n=o?function(e){let t,o=null;const{pinnedRowModel:i,pageBounds:s}=e,n=i?.getPinnedBottomRowCount(),r=i?.getPinnedTopRowCount();return n?(o="bottom",t=n-1):e.rowModel.getRowCount()?(o=null,t=s.getLastRow()):r&&(o="top",t=r-1),void 0===t?null:{rowIndex:t,rowPinned:o}}(this.beans):function(e){let t,o=0;const{pinnedRowModel:i,rowModel:s,pageBounds:n}=e;return i?.getPinnedTopRowCount()?t="top":s.getRowCount()?(t=null,o=n.getFirstRow()):i?.getPinnedBottomRowCount()&&(t="bottom"),void 0===t?null:{rowIndex:o,rowPinned:t}}(this.beans);if(n){const i=e.column??this.focusedHeader?.column,{rowIndex:r,rowPinned:a}=n,l=vd(this.beans,n);if(!i||!l||null==r)return!1;if(i.isSuppressNavigable(l)){const e=this.gos.get("enableRtl");let t;return t=s&&s.key!==Fi?s.key:e?ki:Ii,this.beans.navigation?.navigateToNextCell(null,t,{rowIndex:r,column:i,rowPinned:a||null},!0),!0}if(this.navigation?.ensureCellVisible({rowIndex:r,column:i,rowPinned:a}),o){const e=this.rowRenderer.getRowByPosition(n);if(e?.isFullWidth()&&this.navigation?.tryToFocusFullWidthRow(n,o))return!0}return this.setFocusedCell({rowIndex:r,column:i,rowPinned:t(a),forceBrowserFocus:!0}),this.beans.rangeSvc?.setRangeToCell({rowIndex:r,rowPinned:a,column:i}),!0}return!(!i||!this.focusOverlay(o))||!(!o||!this.focusLastHeader())}focusAdvancedFilter(e){return this.advFilterFocusColumn=e?.column,this.beans.advancedFilter?.getCtrl().focusHeaderComp()??!1}focusNextFromAdvancedFilter(e,t){const o=(t?void 0:this.advFilterFocusColumn)??this.visibleCols.allCols?.[0];return e?this.focusHeaderPosition({headerPosition:{column:o,headerRowIndex:ka(this.beans)-1}}):this.focusGridView({column:o})}clearAdvancedFilterColumn(){this.advFilterFocusColumn=void 0}},class extends Tn{constructor(){super(...arguments),this.sizeEls=new Map,this.lastKnownValues=new Map,this.sizesMeasured=!1}initVariables(){this.addManagedPropertyListener("rowHeight",()=>this.refreshRowHeightVariable()),this.getSizeEl(vc),this.getSizeEl(wc),this.getSizeEl(bc),this.getSizeEl(yc),this.getSizeEl(Sc),this.refreshRowBorderWidthVariable()}getPinnedRowBorderWidth(){return this.getCSSVariablePixelValue(Sc)}getRowBorderWidth(){return this.getCSSVariablePixelValue(yc)}getDefaultRowHeight(){return this.getCSSVariablePixelValue(vc)}getDefaultHeaderHeight(){return this.getCSSVariablePixelValue(wc)}getDefaultCellHorizontalPadding(){return this.getCSSVariablePixelValue(mc)}getCellPaddingLeft(){const e=this.getDefaultCellHorizontalPadding(),t=this.getCSSVariablePixelValue(fc);return e-1+this.getCSSVariablePixelValue(Cc)*t}getCellPadding(){const e=this.getDefaultCellHorizontalPadding()-1;return this.getCellPaddingLeft()+e}getDefaultColumnMinWidth(){return Math.min(36,this.getDefaultRowHeight())}getDefaultListItemHeight(){return this.getCSSVariablePixelValue(bc)}refreshRowHeightVariable(){const{eRootDiv:e}=this,t=e.style.getPropertyValue("--ag-line-height").trim(),o=this.gos.get("rowHeight");if(null==o||isNaN(o)||!isFinite(o))return null!==t&&e.style.setProperty("--ag-line-height",null),-1;const i=`${o}px`;return t!=i?(e.style.setProperty("--ag-line-height",i),o):""!=t?parseFloat(t):-1}getCSSVariablePixelValue(e){const t=this.lastKnownValues.get(e);if(null!=t)return t;const o=this.measureSizeEl(e);return"detached"===o||"no-styles"===o?(e.cacheDefault&&this.lastKnownValues.set(e,e.defaultValue),e.defaultValue):(this.lastKnownValues.set(e,o),o)}measureSizeEl(e){const t=this.getSizeEl(e);if(null==t.offsetParent)return"detached";const o=t.offsetWidth;return o===Ec?"no-styles":(this.sizesMeasured=!0,o)}getMeasurementContainer(){let e=this.eMeasurementContainer;return e||(e=this.eMeasurementContainer=sr({tag:"div",cls:"ag-measurement-container"}),this.eRootDiv.appendChild(e)),e}getSizeEl(e){let t=this.sizeEls.get(e);if(t)return t;const o=this.getMeasurementContainer();t=sr({tag:"div"});const{border:i,noWarn:s}=e;i?(t.className="ag-measurement-element-border",t.style.setProperty("--ag-internal-measurement-border",`var(${e.cssName}, solid ${Ec}px)`)):t.style.width=`var(${e.cssName}, ${Ec}px)`,o.appendChild(t),this.sizeEls.set(e,t);let n=this.measureSizeEl(e);"no-styles"!==n||s||st(9,{variable:e});const r=ce(this.beans,t,()=>{const t=this.measureSizeEl(e);"detached"!==t&&"no-styles"!==t&&(this.lastKnownValues.set(e,t),t!==n&&(n=t,this.fireStylesChangedEvent(e.changeKey)))});return this.addDestroyFunc(()=>r()),t}fireStylesChangedEvent(e){"rowBorderWidthChanged"===e&&this.refreshRowBorderWidthVariable(),this.eventSvc.dispatchEvent({type:"gridStylesChanged",[e]:!0})}refreshRowBorderWidthVariable(){const e=this.getCSSVariablePixelValue(yc);this.eRootDiv.style.setProperty("--ag-internal-row-border-width",`${e}px`)}postProcessThemeChange(e,t){e&&getComputedStyle(this.getMeasurementContainer()).getPropertyValue("--ag-legacy-styles-loaded")&&nt(t?106:239)}getAdditionalCss(){const e=new Map;var t;return e.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,.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-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-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-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-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-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}']),t=e,Array.from(new Set(bh)).sort((e,t)=>e.moduleName.localeCompare(t.moduleName)).forEach(e=>{const o=e.css;o&&t.set(`module-${e.moduleName}`,o)}),e}getDefaultTheme(){return hc}themeError(e){nt(240,{theme:e})}},class extends Me{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.getScrollbarWidth(),this.addManagedEventListeners({displayedColumnsChanged:this.updateScrollVisible.bind(this),displayedColumnsWidthChanged:this.updateScrollVisible.bind(this)})}updateScrollVisible(){const{colAnimation:e}=this;e?.isActive()?e.executeLaterVMTurn(()=>{e.executeLaterVMTurn(()=>this.updateScrollVisibleImpl())}):this.updateScrollVisibleImpl()}updateScrollVisibleImpl(){const e=this.ctrlsSvc.get("center");if(!e||this.colAnimation?.isActive())return;const t={horizontalScrollShowing:e.isHorizontalScrollShowing(),verticalScrollShowing:this.verticalScrollShowing};this.setScrollsVisible(t),this.updateScrollGap()}updateScrollGap(){const e=this.ctrlsSvc.get("center"),t=e.hasHorizontalScrollGap(),o=e.hasVerticalScrollGap();(this.horizontalScrollGap!==t||this.verticalScrollGap!==o)&&(this.horizontalScrollGap=t,this.verticalScrollGap=o,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){const e=this.gos.get("scrollbarWidth"),t="number"==typeof e&&e>=0?e:(null==Ei&&Xi(),Ei);null!=t&&(this.scrollbarWidth=t,this.eventSvc.dispatchEvent({type:"scrollbarWidthChanged"}))}return this.scrollbarWidth}},class extends Me{constructor(){super(...arguments),this.beanName="ctrlsSvc",this.params={},this.ready=!1,this.readyCallbacks=[]}postConstruct(){this.addEventListener("ready",()=>{this.updateReady(),this.ready&&(this.readyCallbacks.forEach(e=>e(this.params)),this.readyCallbacks.length=0)},this.beans.frameworkOverrides.runWhenReadyAsync?.()??!1)}updateReady(){const 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(()=>{const 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(){const{leftHeader:e,centerHeader:t,rightHeader:o}=this.params;return[e,o,t]}getHeaderRowContainerCtrl(e){const t=this.params;switch(e){case"left":return t.leftHeader;case"right":return t.rightHeader;default:return t.centerHeader}}getScrollFeature(){return this.getGridBodyCtrl().scrollFeature}},class extends Me{constructor(){super(...arguments),this.beanName="syncSvc",this.waitingForColumns=!1}postConstruct(){this.addManagedPropertyListener("columnDefs",e=>this.setColumnDefs(e))}start(){this.beans.ctrlsSvc.whenReady(this,()=>{const e=this.gos.get("columnDefs");e?this.setColumnsAndData(e):this.waitingForColumns=!0,this.gridReady()})}setColumnsAndData(e){const{colModel:t,rowModel:o}=this.beans;t.setColumnDefs(e??[],"gridInitializing"),o.start()}gridReady(){const{eventSvc:e,gos:t}=this;e.dispatchEvent({type:"gridReady"}),$e(t,`initialised successfully, enterprise = ${t.isModuleRegistered("EnterpriseCore")}`)}setColumnDefs(e){const t=this.gos.get("columnDefs");if(t)return this.waitingForColumns?(this.waitingForColumns=!1,void this.setColumnsAndData(t)):void this.beans.colModel.setColumnDefs(t,Co(e.source))}},class extends Me{constructor(){super(...arguments),this.beanName="colNames"}getDisplayNameForColumn(e,t,o=!1){if(!e)return null;const i=this.getHeaderName(e.getColDef(),e,null,null,t),{aggColNameSvc:s}=this.beans;return o&&s?s.getHeaderName(e,i):i}getDisplayNameForProvidedColumnGroup(e,t,o){const i=t?.getColGroupDef();return i?this.getHeaderName(i,null,e,t,o):null}getDisplayNameForColumnGroup(e,t){return this.getDisplayNameForProvidedColumnGroup(e,e.getProvidedColumnGroup(),t)}getHeaderName(e,t,o,i,s){const n=e.headerValueGetter;if(n){const r=zt(this.gos,{colDef:e,column:t,columnGroup:o,providedColumnGroup:i,location:s});return"function"==typeof n?n(r):"string"==typeof n?this.beans.expressionSvc?.evaluate(n,r)??null:""}return null!=e.headerName?e.headerName:e.field?(r=e.field)&&null!=r?r.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:"";var r}},class extends Me{constructor(){super(...arguments),this.beanName="colViewport",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,o=!1){const{visibleCols:i}=this,s=i.isBodyWidthDirty;if(!(e===this.scrollWidth&&t===this.scrollPosition&&!s)){if(this.scrollWidth=e,this.scrollPosition=t,i.isBodyWidthDirty=!0,this.gos.get("enableRtl")){const o=i.bodyWidth;this.viewportLeft=o-t-e,this.viewportRight=o-t}else this.viewportLeft=t,this.viewportRight=e+t;this.colModel.ready&&this.checkViewportColumns(o)}}getColumnHeadersToRender(e){switch(e){case"left":return this.columnsToRenderLeft;case"right":return this.columnsToRenderRight;default:return this.columnsToRenderCenter}}getHeadersToRender(e,t){let o;switch(e){case"left":o=this.rowsOfHeadersToRenderLeft[t];break;case"right":o=this.rowsOfHeadersToRenderRight[t];break;default:o=this.rowsOfHeadersToRenderCenter[t]}return o??[]}extractViewportColumns(){const 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;const t=e.getLeft()||0,o=t+e.getActualWidth(),i=this.viewportLeft-200,s=this.viewportRight+200;return!(t<i&&o<i)&&!(t>s&&o>s)}getViewportColumns(){const{leftCols:e,rightCols:t}=this.visibleCols;return this.colsWithinViewport.concat(e).concat(t)}getColsWithinViewport(e){if(!this.colModel.colSpanActive)return this.colsWithinViewport;const t=this.isColumnVirtualisationSuppressed()?void 0:this.isColumnInRowViewport.bind(this),{visibleCols:i}=this,s=i.centerCols;return i.getColsForRow(e,s,t,e=>{const t=e.getLeft();return o(t)&&t>this.viewportLeft})}checkViewportColumns(e=!1){this.extractViewport()&&this.eventSvc.dispatchEvent({type:"virtualColumnsChanged",afterScroll:e})}calculateHeaderRows(){const{leftCols:e,rightCols:t}=this.visibleCols;this.columnsToRenderLeft=e,this.columnsToRenderRight=t,this.columnsToRenderCenter=this.colsWithinViewport;const o=e=>{const t=new Set,o={};for(const i of e){let e=i.getParent();const s=i.isSpanHeaderHeight();for(;e&&!t.has(e);){if(s&&e.isPadding()){e=e.getParent();continue}const i=e.getProvidedColumnGroup().getLevel();o[i]??(o[i]=[]),o[i].push(e),t.add(e),e=e.getParent()}}return o};this.rowsOfHeadersToRenderLeft=o(e),this.rowsOfHeadersToRenderRight=o(t),this.rowsOfHeadersToRenderCenter=o(this.headerColsWithinViewport)}extractViewport(){this.extractViewportColumns();const e=this.getViewportColumns().map(e=>`${e.getId()}-${e.getPinned()||"normal"}`).join("#"),t=this.colsWithinViewportHash!==e;return t&&(this.colsWithinViewportHash=e,this.calculateHeaderRows()),t}},class extends Me{constructor(){super(...arguments),this.beanName="iconSvc"}createIconNoSpan(e,t){return al(e,this.beans,t?.column)}}],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,o){cd(e,{[t]:o})},updateGridOptions:cd,isModuleRegistered:function(e,t){const o=t.replace(/Module$/,"");return e.gos.isModuleRegistered(o)}},dependsOn:[mh,Yd,Xd,Yu,Xc,ih,eu,Ku,Ju,tu,Hu,Gu,Nu,ou,wh,fh,Zu,rh,zu]},tg={AdvancedFilter: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},og=["TextFilter","NumberFilter","DateFilter","SetFilter","MultiFilter","GroupFilter","CustomFilter"],ig={EditCore:["TextEditor","NumberEditor","DateEditor","CheckboxEditor","LargeTextEditor","SelectEditor","RichSelect","CustomEditor"],CheckboxCellRenderer:["AllCommunity"],ClientSideRowModelHierarchy:["RowGrouping","Pivot","TreeData"],ColumnFilter:og,ColumnGroupHeaderComp:["AllCommunity"],ColumnGroup:["AllCommunity"],ColumnHeaderComp:["AllCommunity"],ColumnMove:["AllCommunity"],ColumnResize:["AllCommunity"],CommunityCore:["AllCommunity"],CsrmSsrmSharedApi:["ClientSideRowModelApi","ServerSideRowModelApi"],RowModelSharedApi:["ClientSideRowModelApi","ServerSideRowModelApi"],EnterpriseCore:["AllEnterprise"],FilterCore:[...og,"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:[...og,"ColumnMenu","ContextMenu"],SharedPivot:["Pivot","ServerSideRowModel"],SharedRowGrouping:["RowGrouping","ServerSideRowModel"],SharedRowSelection:["RowSelection","ServerSideRowModel"],SkeletonCellRenderer:["ServerSideRowModel"],Sort:["AllCommunity"],SsrmInfiniteSharedApi:["InfiniteRowModel","ServerSideRowModelApi"],SharedTreeData:["TreeData","ServerSideRowModel"]},sg={InfiniteRowModel:"infinite",ClientSideRowModelApi:"clientSide",ClientSideRowModel:"clientSide",ServerSideRowModelApi:"serverSide",ServerSideRowModel:"serverSide",ViewportRowModel:"viewport"};function ng(e,t=!1){return!t||"IntegratedCharts"!==e&&"Sparklines"!==e?`${e}Module`:`${e}Module.with(AgChartsEnterpriseModule)`}function rg({moduleName:e,rowModelType:t}){return`To use the ${e}Module you must set the gridOption "rowModelType='${t}'"`}var ag=({reasonOrId:e,moduleName:t,gridScoped:o,gridId:i,rowModelType:s,additionalText:n,isUmd:r})=>{const a=function(e,t){const o=[];return(Array.isArray(e)?e:[e]).forEach(e=>{const i=ig[e];i?i.forEach(e=>{const i=sg[e];i&&i!==t||o.push(e)}):o.push(e)}),o}(t,s),l="string"==typeof e?e:cg[e];if(r)return function(e,t){const o=t.filter(e=>"IntegratedCharts"===e||"Sparklines"===e);let i="";const s=globalThis?.agCharts;return!s&&o.length>0?i=`Unable to use ${e} as either the ag-charts-community or ag-charts-enterprise script needs to be included alongside ag-grid-enterprise.\n`:t.some(e=>tg[e])&&(i+=`Unable to use ${e} as that requires the ag-grid-enterprise script to be included.\n`),i}(l,a);const d=a.filter(e=>"IntegratedCharts"===e||"Sparklines"===e),h=d.length>0?`${d.map(e=>ng(e)).join()} must be initialised with an AG Charts module. One of 'AgChartsCommunityModule' / 'AgChartsEnterpriseModule'.`:"";return`${`Unable to use ${l} as ${a.length>1?"one of "+a.map(e=>ng(e)).join(", "):ng(a[0])} is not registered${o?" for gridId: "+i:""}. ${h} Check if you have registered the module:\n`}\n${(e=>{const t=e.map(e=>`import { ${ng(e)} } from '${tg[e]?"ag-grid-enterprise":"ag-grid-community"}';`);if(e.some(e=>"IntegratedCharts"===e||"Sparklines"===e)){const e="import { AgChartsEnterpriseModule } from 'ag-charts-enterprise';";t.push(e)}return`import { ModuleRegistry } from 'ag-grid-community'; \n${t.join(" \n")} \n\nModuleRegistry.registerModules([ ${e.map(e=>ng(e,!0)).join(", ")} ]); \n\nFor more info see: ${Qe}/modules/`})(a)}`+(n?` \n\n${n}`:"")},lg=e=>`${e} must be initialised with an AG Charts module. One of 'AgChartsCommunityModule' / 'AgChartsEnterpriseModule'.\n\nimport { AgChartsEnterpriseModule } from 'ag-charts-enterprise';\nimport { ModuleRegistry } from 'ag-grid-community';\nimport { ${e} } from 'ag-grid-enterprise';\n \nModuleRegistry.registerModules([${e}.with(AgChartsEnterpriseModule)]);\n `,dg={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:o})=>["Processing of the expression failed","Expression = ",e,"Params = ",t,"Exception = ",o],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:\n "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:({key: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.\n Either clear local references to the grid api, when it is destroyed, or check gridApi.isDestroyed() to avoid calling methods against a destroyed grid.\n 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:e,method:t})=>`${e}\n${(e=>`AG Grid: Unable to use the Clipboard API (navigator.clipboard.${e}()). 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.`)(t)}`,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:o,pageSizeOptions:i})=>`'paginationPageSize=${e}'${t?"":" (default value)"}, but ${e} is not included in${o?"":" 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:o,jsComps:i})=>{const s=[],n=us({inputValue:t,allSuggestions:[...Object.keys(o??[]).filter(e=>!["agCellEditor","agGroupRowRenderer","agSortIndicator"].includes(e)),...Object.keys(i??[]).filter(e=>!!i[e])],hideIrrelevant:!0,filterByPercentageOfBestMatch:.8}).values;return s.push(`Could not find '${t}' component. It was configured as "${e}: '${t}'" but it wasn't found in the list of registered components.\n`),n.length>0&&s.push(` Did you mean: [${n.slice(0,3)}]?\n`),s.push("If using a custom component check it has been registered correctly."),s},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: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: ${Qe}/theming-migration/`,107:({key:e,value:t})=>`Invalid value for theme param ${e} - ${t}`,108:({e:e})=>["chart update failed",e],109:({inputValue:e,allSuggestions:t})=>{const o=us({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.`,o.length>0?` Did you mean: [${o.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()'",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.\n 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:o})=>["duplicate group keys for row data, keys should be unique",e,t,...o??[]],187:({rowId:e,firstData:t,secondData:o})=>[`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",o],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:ag,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 ${Qe}/filter-set-filter-list/#filter-value-types`,210:()=>"Set Filter has a Key Creator, but provided values are primitives. Did you 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. \nPlease 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})=>`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:()=>lg("IntegratedChartsModule"),258:()=>lg("SparklinesModule"),259:({part:e})=>`the argument to theme.withPart must be a Theming API part object, received: ${e}`,260:({propName:e,compName:t,gridScoped:o,gridId:i,rowModelType:s})=>ag({reasonOrId:`AG Grid '${e}' component: ${t}`,moduleName:Ic[t],gridId:i,gridScoped:o,rowModelType:s}),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 ${Qe}/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:()=>"No AG Grid modules are registered! It is recommended to start with all Community features via the AllCommunityModule:\n \n import { ModuleRegistry, AllCommunityModule } from 'ag-grid-community';\n \n ModuleRegistry.registerModules([ AllCommunityModule ]);\n ",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:rg,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`};function hg(e,t){const o=dg[e];if(!o)return[`Missing error text for error id ${e}!`];const i=o(t),s=`\nSee ${ot(e,t)}`;return Array.isArray(i)?i.concat(s):[i,s]}var cg={1:"Charting Aggregation",2:"pivotResultFields",3:"setTooltip"},ug=new WeakMap,gg=new WeakMap;var pg=1,mg=class{create(e,t,o,i,s,n){const r=ze.applyGlobalGridOptions(t),a=r.gridId??String(pg++),l=this.getRegisteredModules(s,a,r.rowModelType),d=this.createBeansList(r.rowModelType,l,a),h=this.createProvidedBeans(e,r,s);if(!d)return;const c={providedBeanInstances:h,beanClasses:d,id:a,beanInitComparator:Kl,beanDestroyComparator:jl,derivedBeans:[Ul],destroyCallback:()=>{gg.delete(g),ug.delete(e),function(e){delete Sh[e]}(a),n?.()}},u=new Mn(c);this.registerModuleFeatures(u,l),o(u),u.getBean("syncSvc").start(),i?.(u);const g=u.getBean("gridApi");return ug.set(e,g),gg.set(g,e),g}getRegisteredModules(e,t,o){return Fh(eg,void 0,!0),e?.modules?.forEach(e=>Fh(e,t)),function(e,t){const o=Sh[e]??{};return[...Object.values(yh.all??{}),...Object.values(o.all??{}),...Object.values(yh[t]??{}),...Object.values(o[t]??{})]}(t,fg(o))}registerModuleFeatures(e,t){const o=e.getBean("registry"),i=e.getBean("apiFunctionSvc");t.forEach(e=>{o.registerModule(e);const t=e.apiFunctions;if(t){Object.keys(t).forEach(e=>{i?.addFunction(e,t[e])})}})}createProvidedBeans(e,t,o){let s=o?o.frameworkOverrides:null;i(s)&&(s=new Wl);const n={gridOptions:t,eGridDiv:e,eRootDiv:e,globalListener:o?o.globalListener:null,globalSyncListener:o?o.globalSyncListener:null,frameworkOverrides:s};return o&&o.providedBeanInstances&&Object.assign(n,o.providedBeanInstances),n}createBeansList(e,t,o){const i={clientSide:"ClientSideRowModel",infinite:"InfiniteRowModel",serverSide:"ServerSideRowModel",viewport:"ViewportRowModel"},s=fg(e),n=i[s];if(!n)return void rt(201,{rowModelType:s},`Unknown rowModelType ${s}.`);if(!Eh)return void rt(272,void 0,"No AG Grid modules are registered! It is recommended to start with all Community features via the AllCommunityModule:\n \n import { ModuleRegistry, AllCommunityModule } from 'ag-grid-community';\n \n ModuleRegistry.registerModules([ AllCommunityModule ]);\n ");if(!e){const e=Object.entries(i).filter(([e,t])=>Ph(t,o,e));if(1==e.length){const[t,o]=e[0];if(t!==s){const e={moduleName:o,rowModelType:t};return void rt(275,e,rg(e))}}}if(!Ph(n,o,s))return void rt(200,{reasonOrId:`rowModelType = '${s}'`,moduleName:n,gridScoped:Dh(),gridId:o,rowModelType:s},`Missing module ${n}Module for rowModelType ${s}.`);const r=new Set;return t.forEach(e=>e.beans?.forEach(e=>r.add(e))),Array.from(r)}};function fg(e){return e??"clientSide"}function Cg(e){return"whenTruncated"===e.get("tooltipShowMode")}var vg=class extends Me{getFileName(e){const t=this.getDefaultFileExtension();return null!=e&&e.length||(e=this.getDefaultFileName()),-1===e.indexOf(".")?`${e}.${t}`:e}getData(e){const t=this.createSerializingSession(e);return this.beans.gridSerializer.serialize(t,e)}getDefaultFileName(){return`export.${this.getDefaultFileExtension()}`}},wg=class{constructor(e){const{colModel:t,rowGroupColsSvc:o,colNames:i,valueSvc:s,gos:n,processCellCallback:r,processHeaderCallback:a,processGroupHeaderCallback:l,processRowGroupCallback:d}=e;this.colModel=t,this.rowGroupColsSvc=o,this.colNames=i,this.valueSvc=s,this.gos=n,this.processCellCallback=r,this.processHeaderCallback=a,this.processGroupHeaderCallback=l,this.processRowGroupCallback=d}prepare(e){}extractHeaderValue(e){return this.getHeaderName(this.processHeaderCallback,e)??""}extractRowCellValue(e,t,o,i,s){const n=0===t&&xt(this.gos,s,this.colModel.isPivotMode());if(this.processRowGroupCallback&&(this.gos.get("treeData")||s.group)&&(e.isRowGroupDisplayed(s.rowGroupColumn?.getColId()??"")||n))return{value:this.processRowGroupCallback(zt(this.gos,{column:e,node:s}))??""};if(this.processCellCallback)return{value:this.processCellCallback(zt(this.gos,{accumulatedRowIndex:o,column:e,node:s,value:this.valueSvc.getValueForDisplay(e,s,void 0,void 0).value,type:i,parseValue:t=>this.valueSvc.parseValue(e,s,t,this.valueSvc.getValue(e,s,void 0)),formatValue:t=>this.valueSvc.formatValue(e,s,t)??t}))??""};const r=this.gos.get("treeData"),a=this.valueSvc,l=-1===s.level&&s.footer,d=!0===e.colDef.showRowGroup&&(s.group||r);if(!l&&(n||d)){let t="",o=s;for(;o&&-1!==o.level;){const{value:i,valueFormatted:s}=a.getValueForDisplay(n?void 0:e,o,!0,!0);t=` -> ${s??i??""}${t}`,o=o.parent}return{value:t,valueFormatted:t}}const{value:h,valueFormatted:c}=a.getValueForDisplay(e,s,!0,!0);return{value:h??"",valueFormatted:c}}getHeaderName(e,t){return e?e(zt(this.gos,{column:t})):this.colNames.getDisplayNameForColumn(t,"csv",!0)}};var bg={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},yg="clientSide",Sg="serverSide",Eg="infinite",Rg={onGroupExpandedOrCollapsed:[yg],refreshClientSideRowModel:[yg],isRowDataEmpty:[yg],forEachLeafNode:[yg],forEachNodeAfterFilter:[yg],forEachNodeAfterFilterAndSort:[yg],resetRowHeights:[yg,Sg],applyTransaction:[yg],applyTransactionAsync:[yg],flushAsyncTransactions:[yg],getBestCostNodeSelection:[yg],getServerSideSelectionState:[Sg],setServerSideSelectionState:[Sg],applyServerSideTransaction:[Sg],applyServerSideTransactionAsync:[Sg],applyServerSideRowData:[Sg],retryServerSideLoads:[Sg],flushServerSideAsyncTransactions:[Sg],refreshServerSide:[Sg],getServerSideGroupLevelState:[Sg],refreshInfiniteCache:[Eg],purgeInfiniteCache:[Eg],getInfiniteRowCount:[Eg],isLastRowIndexKnown:[Eg,Sg],expandAll:[yg,Sg],collapseAll:[yg,Sg],onRowHeightChanged:[yg,Sg],setRowCount:[Eg,Sg],getCacheBlockState:[Eg,Sg]},xg={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")'}};var Fg={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"},Pg={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},Dg={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"],sortDescending:["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"},Mg=new Set(["colorPicker","smallUp","checkboxChecked","checkboxIndeterminate","checkboxUnchecked","radioButtonOn","radioButtonOff","smallDown","smallLeft","smallRight"]);var kg=new Set(["firstChildChanged","lastChildChanged","childIndexChanged"]),Tg={moduleName:"Validation",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="validation"}wireBeans(e){this.gridOptions=e.gridOptions,Ye=hg}warnOnInitialPropertyUpdate(e,t){"api"===e&&bg[t]&&st(22,{key:t})}processGridOptions(e){this.processOptions(e,{objectName:"gridOptions",allProperties:[...Vc,...Hc,...Bc,...Gc,...Wc,...zc,...Oc,...Nc,...Object.values(Fc)],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:Kc()})}validateApiFunction(e,t){return function(e,t,o){const i=xg[e];if(i){const{version:o,new:s,old:n,message:r}=i,a=n??e;return(...e)=>(Ke(`Since ${o} api.${a} is deprecated. ${s?`Please use ${s} instead. `:""}${r??""}`),t.apply(t,e))}const s=Rg[e];return s?(...i)=>{const n=o.rowModel.getType();if(s.includes(n))return t.apply(t,i);je(`api.${e} can only be called when gridOptions.rowModelType is ${s.join(" or ")}`)}:t}(e,t,this.beans)}missingUserComponent(e,t,o,i){const s=Ic[t];s?this.gos.assertModuleRegistered(s,`AG Grid '${e}' component: ${t}`):st(101,{propertyName:e,componentName:t,agGridDefaults:o,jsComps:i})}missingDynamicBean(e){const t=Fg[e];return t?at(200,{...this.gos.getModuleErrorParams(),moduleName:t,reasonOrId:e}):void 0}checkRowEvents(e){kg.has(e)&&st(10,{eventType:e})}validateIcon(e){if(Mg.has(e)&&st(43,{iconName:e}),Pg[e])return;const t=Dg[e];t?nt(200,{reasonOrId:`icon '${e}'`,moduleName:t,gridScoped:Dh(),gridId:this.beans.context.getId(),rowModelType:this.gos.get("rowModelType"),additionalText:"Alternatively, use the CSS icon name directly."}):st(134,{iconName:e})}isProvidedUserComp(e){return!!Ic[e]}validateColDef(e){this.processOptions(e,{objectName:"colDef",allProperties:Object.keys(Lc),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."}},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)?null:'Since v33.0, `cellRendererParams.checkbox` has been deprecated. Use `rowSelection.checkboxLocation = "autoGroupColumn"` instead.'},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=>{const 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 at(262);if(e.smallLeft)return at(263);if(e.smallRight)return at(264)}return null}},sortingOrder:{validate:e=>{const t=e.sortingOrder;if(Array.isArray(t)&&t.length>0){const e=t.filter(e=>!Tc.includes(e));if(e.length>0)return`sortingOrder must be an array with elements from [${Tc.map(et).join()}], currently it includes [${e.map(et).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=>{const 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:o,suppressRowTransform:i,enableCellSpan:s,rowDragEntireRow:n,enableCellTextSelection:r})=>"object"==typeof t&&"singleRow"===t?.mode&&t?.enableClickSelection?"colDef.spanRows is not supported with rowSelection.clickSelection":o?"colDef.spanRows is not supported with cellSelection.":i?"colDef.spanRows is not supported with suppressRowTransform.":s?n?"colDef.spanRows is not supported with rowDragEntireRow.":r?"colDef.spanRows is not supported with enableCellTextSelection.":null:"colDef.spanRows requires enableCellSpan to be enabled."},rowGroupingHierarchy:{validate(e,{groupHierarchyConfig:t={}},o){const i=new Set(["year","quarter","month","formattedMonth","day","hour","minute","second"]),s=[];return e.rowGroupingHierarchy?.forEach(e=>{if("object"==typeof e)return o.validation?.validateColDef(e),null;i.has(e)||e in t||s.push(e)}),s.length>0?`The following parts of colDef.rowGroupingHierarchy are not recognised: ${s.map(e=>`"${e}"`).join(", ")}.\nChoose one of ${[...i].map(e=>`"${e}"`).join(", ")}, or define your own parts in gridOptions.groupHierarchyConfig.`:null}}}})}processOptions(e,t){const{validations:o,deprecations:i,allProperties:s,propertyExceptions:n,objectName:r,docsUrl:a}=t;s&&!0!==this.gridOptions.suppressPropertyNamesCheck&&this.checkProperties(e,[...n??[],...Object.keys(i)],s,r,a);const l=new Set;Object.keys(e).forEach(t=>{const s=i[t];if(s){const{message:e,version:o}=s;l.add(`As of v${o}, ${String(t)} is deprecated. ${e??""}`)}const n=e[t];if(null==n||!1===n)return;const r=o[t];if(!r)return;const{dependencies:a,validate:d,supportedRowModels:h,expectedType:c}=r;if(c){const e=typeof n;if(e!==c)return void l.add(`${String(t)} should be of type '${c}' but received '${e}' (${n}).`)}if(h){const e=this.gridOptions.rowModelType??"clientSide";if(!h.includes(e))return void l.add(`${String(t)} is not supported with the '${e}' row model. It is only valid with: ${h.join(", ")}.`)}if(a){const o=this.checkForRequiredDependencies(t,a,e);if(o)return void l.add(o)}if(d){const t=d(e,this.gridOptions,this.beans);if(t)return void l.add(t)}}),l.size>0&&l.forEach(e=>{Ke(e)})}checkForRequiredDependencies(e,t,o){const i=Object.entries(t).filter(([e,t])=>{const i=o[e];return!t.required.includes(i)});return 0===i.length?null:i.map(([t,o])=>`'${String(e)}' requires '${t}' to be one of [${o.required.map(e=>null===e?"null":void 0===e?"undefined":e).join(", ")}]. ${o.reason??""}`).join("\n ")}checkProperties(e,t,o,i,s){const n=function(e,t,o){const i={},s=e.filter(e=>!t.some(t=>t===e));s.length>0&&s.forEach(e=>i[e]=us({inputValue:e,allSuggestions:o}).values);return i}(Object.getOwnPropertyNames(e),["__ob__","__v_skip","__metadata__",...t,...o],o),r=Object.keys(n);for(const e of r){let t=`invalid ${i} property '${e}' did you mean any of these: ${n[e].slice(0,8).join(", ")}.`;o.includes("context")&&(t+=`\nIf you are trying to annotate ${i} with application data, use the '${i}.context' property instead.`),Ke(t)}if(r.length>0&&s){Ke(`to see all the valid ${i} properties please check: ${this.beans.frameworkOverrides.getDocLink(s)}`)}}}]};function Ig(e){e.sibling&&(e.sibling.childrenAfterFilter=e.childrenAfterFilter)}var Ag={moduleName:"SharedMenu",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="menuSvc"}postConstruct(){const{enterpriseMenuFactory:e,filterMenuFactory:t}=this.beans;this.activeMenuFactory=e??t}showColumnMenu(e){this.showColumnMenuCommon(this.activeMenuFactory,e,"columnMenu")}showFilterMenu(e){this.showColumnMenuCommon(ol(this.beans),e,e.containerType,!0)}showHeaderContextMenu(e,t,o){this.activeMenuFactory?.showMenuAfterContextMenuEvent(e,t,o)}hidePopupMenu(){this.beans.contextMenuSvc?.hideActiveMenu(),this.activeMenuFactory?.hideActiveMenu()}hideFilterMenu(){ol(this.beans)?.hideActiveMenu()}isColumnMenuInHeaderEnabled(e){const{suppressHeaderMenuButton:t}=e.getColDef();return!t&&!!this.activeMenuFactory?.isMenuEnabled(e)&&(Ot(this.gos)||!!this.beans.enterpriseMenuFactory)}isFilterMenuInHeaderEnabled(e){return!e.getColDef().suppressHeaderFilterButton&&!!this.beans.filterManager?.isFilterAllowed(e)}isHeaderContextMenuEnabled(e){const t=e&&qt(e)?e.getColDef():e?.getColGroupDef();return!t?.suppressHeaderContextMenu&&"new"===this.gos.get("columnMenu")}isHeaderMenuButtonAlwaysShowEnabled(){return this.isSuppressMenuHide()}isHeaderMenuButtonEnabled(){const e=!this.isSuppressMenuHide();return!(Zi()&&e)}isHeaderFilterButtonEnabled(e){return this.isFilterMenuInHeaderEnabled(e)&&!Ot(this.gos)&&!this.isFloatingFilterButtonDisplayed(e)}isFilterMenuItemEnabled(e){return!(!this.beans.filterManager?.isFilterAllowed(e)||Ot(this.gos)||this.isFilterMenuInHeaderEnabled(e)||this.isFloatingFilterButtonDisplayed(e))}isFloatingFilterButtonEnabled(e){return!e.getColDef().suppressFloatingFilterButton}isFloatingFilterButtonDisplayed(e){return!!e.getColDef().floatingFilter&&this.isFloatingFilterButtonEnabled(e)}isSuppressMenuHide(){const e=this.gos,t=e.get("suppressMenuHide");return Ot(e)?!!e.exists("suppressMenuHide")&&t:t}showColumnMenuCommon(e,t,o,i){const{positionBy:s,onClosedCallback:n}=t,r=t.column;if("button"===s){const{buttonElement:s}=t;e?.showMenuAfterButtonClick(r,s,o,n,i)}else if("mouse"===s){const{mouseEvent:s}=t;e?.showMenuAfterMouseEvent(r,s,o,n,i)}else if(r){const t=this.beans,s=t.ctrlsSvc;s.getScrollFeature().ensureColumnVisible(r,"auto"),ue(t,()=>{const t=s.getHeaderRowContainerCtrl(r.getPinned())?.getHeaderCtrlForColumn(r);t&&e?.showMenuAfterButtonClick(r,t.getAnchorElementForMenu(i),o,n,i)})}}}],apiFunctions:{showColumnMenu:function(e,t){const o=e.colModel.getCol(t);o?e.menuSvc?.showColumnMenu({column:o,positionBy:"auto"}):nt(12,{colKey:t})},hidePopupMenu:function(e){e.menuSvc?.hidePopupMenu()}}},Lg={moduleName:"Popup",version:qe,beans:[class extends Gn{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){const{eventSource:t,ePopup:o,event:i}=e,s=t.getBoundingClientRect(),n=this.getParentRect();this.setAlignedTo(t,o);let r=!1;this.positionPopup({ePopup:o,keepWithinBounds:!0,updatePosition:()=>{const e=this.keepXYWithinBounds(o,s.top-n.top,0),t=o.clientWidth>0?o.clientWidth:200;r||(o.style.minWidth=`${t}px`,r=!0);const i=n.right-n.left-t;let a;return this.gos.get("enableRtl")?(a=d(),a<0&&(a=l(),this.setAlignedStyles(o,"left")),a>i&&(a=0,this.setAlignedStyles(o,"right"))):(a=l(),a>i&&(a=d(),this.setAlignedStyles(o,"right")),a<0&&(a=0,this.setAlignedStyles(o,"left"))),{x:a,y:e};function l(){return s.right-n.left-2}function d(){return s.left-n.left-t}},postProcessCallback:()=>this.callPostProcessPopup(e,"subMenu",o,t,i instanceof MouseEvent?i:void 0)})}callPostProcessPopup(e,t,o,i,s){const n=this.gos.getCallback("postProcessPopup");if(n){const{column:r,rowNode:a}=e;n({column:r,rowNode:a,ePopup:o,type:t,eventSource:i,mouseEvent:s})}}getActivePopups(){return this.popupList.map(e=>e.element)}handleThemeChange(e){if(e.themeChanged){const e=this.beans.environment;for(const t of this.popupList)e.applyThemeClasses(t.wrapper)}}hasAnchoredPopup(){return this.popupList.some(e=>e.isAnchored)}isStopPropagation(e){return Pr(e)}}]};var Bg={filterHandler:()=>({doesFilterPass:()=>!0})};var Hg={tag:"div",cls:"ag-floating-filter-input",role:"presentation",children:[{tag:"ag-input-text-field",ref:"eFloatingFilterText"}]},Vg=class{constructor(){this.customFilterOptions={}}init(e,t){this.filterOptions=e.filterOptions??t,this.mapCustomOptions(),this.defaultOption=this.getDefaultItem(e.defaultOption)}refresh(e,t){const o=e.filterOptions??t;this.filterOptions!==o&&(this.filterOptions=o,this.customFilterOptions={},this.mapCustomOptions()),this.defaultOption=this.getDefaultItem(e.defaultOption)}mapCustomOptions(){const{filterOptions:e}=this;e&&e.forEach(t=>{if("string"==typeof t)return;[["displayKey"],["displayName"],["predicate","test"]].every(e=>!!e.some(e=>null!=t[e])||(st(72,{keys:e}),!1))?this.customFilterOptions[t.displayKey]=t:this.filterOptions=e.filter(e=>e===t)||[]})}getDefaultItem(e){const{filterOptions:t}=this;if(e)return e;if(t.length>=1){const e=t[0];if("string"==typeof e)return e;if(e.displayKey)return e.displayKey;st(73)}else st(74)}getCustomOption(e){return this.customFilterOptions[e]}};function Gg(e,t,o){return null==o?e.splice(t):e.splice(t,o)}function Ng(e){return null==e||"string"==typeof e&&0===e.trim().length}function Og(e,t){const o=t.getCustomOption(e);if(o){const{numberOfInputs:e}=o;return null!=e?e:1}return e&&["empty","notBlank","blank"].indexOf(e)>=0?0:"inRange"===e?2:1}var zg=class extends Mr{constructor(e,t,o){super(e,"simple-filter"),this.mapValuesFromModel=t,this.defaultOptions=o,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);const t=new Vg;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();const o=this.getGui();this.isReadOnly()?o.setAttribute("tabindex","-1"):o.removeAttribute("tabindex")}onFloatingFilterChanged(e,t){this.setTypeFromFloatingFilter(e),this.setValueFromFloatingFilter(t),this.onUiChanged("immediately",!0)}setTypeFromFloatingFilter(e){this.eTypes.forEach((t,o)=>{const i=0===o?e:this.optionsFactory.defaultOption;t.setValue(i,!0)})}getModelFromUi(){const 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(){const{eJoinOrs:e,defaultJoinOperator:t}=this;return 0===e.length?t:!0===e[0].getValue()?"OR":"AND"}areNonNullModelsEqual(e,t){const o=!e.operator,i=!t.operator;if(!o&&i||o&&!i)return!1;let s;if(o){const o=e,i=t;s=this.areSimpleModelsEqual(o,i)}else{const o=e,i=t;s=o.operator===i.operator&&oo(o.conditions,i.conditions,(e,t)=>this.areSimpleModelsEqual(e,t))}return s}setModelIntoUi(e,t){if(null==e)return this.resetUiToDefaults(t),Ko.resolve();if(e.operator){const t=e;let o=t.conditions;null==o&&(o=[],st(77));const i=function(e,t){let o=e.length;return o>t&&(e.splice(t),st(78),o=t),o}(o,this.maxNumConditions),s=this.getNumConditions();if(i<s)this.removeConditionsAndOperators(i);else if(i>s)for(let e=s;e<i;e++)this.createJoinOperatorPanel(),this.createOption();const n="OR"===t.operator;this.eJoinAnds.forEach(e=>e.setValue(!n,!0)),this.eJoinOrs.forEach(e=>e.setValue(n,!0)),o.forEach((e,t)=>{this.eTypes[t].setValue(e.type,!0),this.setConditionIntoUi(e,t)})}else{const t=e;this.getNumConditions()>1&&this.removeConditionsAndOperators(1),this.eTypes[0].setValue(t.type,!0),this.setConditionIntoUi(t,0)}return this.lastUiCompletePosition=this.getNumConditions()-1,this.createMissingConditionsAndOperators(),this.updateUiVisibility(),t||this.params.onUiChange(this.getUiChangeEventParams()),Ko.resolve()}setNumConditions(e){let t=e.maxNumConditions??2;t<1&&(st(79),t=1),this.maxNumConditions=t;let o=e.numAlwaysVisibleConditions??1;o<1&&(st(80),o=1),o>t&&(st(81),o=t),this.numAlwaysVisibleConditions=o}createOption(){const e=this.getGui(),t=this.createManagedBean(new zs);this.eTypes.push(t),t.addCss("ag-filter-select"),e.appendChild(t.getGui());const o=this.createEValue();this.eConditionBodies.push(o),e.appendChild(o),this.putOptionsIntoDropdown(t),this.resetType(t);const i=this.getNumConditions()-1;this.forEachPositionInput(i,e=>this.resetInput(e)),this.addChangedListeners(t,i)}createJoinOperatorPanel(){const e=sr({tag:"div",cls:"ag-filter-condition"});this.eJoinPanels.push(e);const t=this.createJoinOperator(this.eJoinAnds,e,"and"),o=this.createJoinOperator(this.eJoinOrs,e,"or");this.getGui().appendChild(e);const i=this.eJoinPanels.length-1,s=this.joinOperatorId++;this.resetJoinOperatorAnd(t,i,s),this.resetJoinOperatorOr(o,i,s),this.isReadOnly()||(t.onValueChange(this.listener),o.onValueChange(this.listener))}createJoinOperator(e,t,o){const i=this.createManagedBean(new ks);e.push(i);const s="ag-filter-condition-operator";return i.addCss(s),i.addCss(`${s}-${o}`),t.appendChild(i.getGui()),i}createFilterListOptions(){this.filterListOptions=this.optionsFactory.filterOptions.map(e=>"string"==typeof e?this.createBoilerplateListOption(e):this.createCustomListOption(e))}putOptionsIntoDropdown(e){const{filterListOptions:t}=this;t.forEach(t=>{e.addOption(t)}),e.setDisabled(t.length<=1)}createBoilerplateListOption(e){return{value:e,text:this.translate(e)}}createCustomListOption(e){const{displayKey:t}=e,o=this.optionsFactory.getCustomOption(e.displayKey);return{value:t,text:o?this.getLocaleTextFunc()(o.displayKey,o.displayName):this.translate(t)}}createBodyTemplate(){return null}getAgComponents(){return[]}updateUiVisibility(){const e=this.getJoinOperator();this.updateNumConditions(),this.updateConditionStatusesAndValues(this.lastUiCompletePosition,e)}updateNumConditions(){let e=-1,t=!0;for(let o=0;o<this.getNumConditions();o++)this.isConditionUiComplete(o)?e=o:t=!1;if(this.shouldAddNewConditionAtEnd(t))this.createJoinOperatorPanel(),this.createOption();else{const t=this.lastUiCompletePosition??this.getNumConditions()-2;if(e<t){this.removeConditionsAndOperators(t+1);const o=e+1,i=t-o;i>0&&this.removeConditionsAndOperators(o,i),this.createMissingConditionsAndOperators()}}this.lastUiCompletePosition=e}updateConditionStatusesAndValues(e,t){this.eTypes.forEach((t,o)=>{const i=this.isConditionDisabled(o,e);t.setDisabled(i||this.filterListOptions.length<=1),1===o&&(V(this.eJoinPanels[0],i),this.eJoinAnds[0].setDisabled(i),this.eJoinOrs[0].setDisabled(i))}),this.eConditionBodies.forEach((e,t)=>{H(e,this.isConditionBodyVisible(t))});const o="OR"===(t??this.getJoinOperator());this.eJoinAnds.forEach(e=>{e.setValue(!o,!0)}),this.eJoinOrs.forEach(e=>{e.setValue(o,!0)}),this.forEachInput((t,o,i,s)=>{this.setElementDisplayed(t,o<s),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;const{eTypes:o,eConditionBodies:i,eJoinPanels:s,eJoinAnds:n,eJoinOrs:r}=this;this.removeComponents(o,e,t),this.removeElements(i,e,t),this.removeEValues(e,t);const a=Math.max(e-1,0);this.removeElements(s,a,t),this.removeComponents(n,a,t),this.removeComponents(r,a,t)}removeElements(e,t,o){Gg(e,t,o).forEach(e=>_(e))}removeComponents(e,t,o){Gg(e,t,o).forEach(e=>{_(e.getGui()),this.destroyBean(e)})}afterGuiAttached(e){if(super.afterGuiAttached(e),this.resetPlaceholder(),!e?.suppressFocus){let e;if(!this.isReadOnly()){const t=this.getInputs(0)[0];e=t instanceof Ps&&this.isConditionBodyVisible(0)?t.getInputElement():this.eTypes[0]?.getFocusableElement()}(e??this.getGui()).focus({preventScroll:!0})}}afterGuiDetached(){super.afterGuiDetached();const e=this.params;if(this.beans.colFilter?.shouldKeepStateOnDetach(e.column))return;e.onStateChange({model:e.model});let t=-1,o=-1,i=!1;const s=this.getJoinOperator();for(let e=this.getNumConditions()-1;e>=0;e--)if(this.isConditionUiComplete(e))-1===t&&(t=e,o=e);else{const s=e<t;(e>=this.numAlwaysVisibleConditions&&!this.isConditionUiComplete(e-1)||s)&&(this.removeConditionsAndOperators(e,1),i=!0,s&&o--)}let n=!1;this.getNumConditions()<this.numAlwaysVisibleConditions&&(this.createMissingConditionsAndOperators(),n=!0),this.shouldAddNewConditionAtEnd(o===this.getNumConditions()-1)&&(this.createJoinOperatorPanel(),this.createOption(),n=!0),n&&this.updateConditionStatusesAndValues(o,s),i&&this.updateJoinOperatorsDisabled(),this.lastUiCompletePosition=o}getModelAsString(e){return this.params.getHandler()?.getModelAsString?.(e)??""}getPlaceholderText(e,t){let o=this.translate(e);if("function"==typeof this.filterPlaceholder){const e=this.eTypes[t].getValue(),i=this.translate(e);o=this.filterPlaceholder({filterOptionKey:e,filterOption:i,placeholder:o})}else"string"==typeof this.filterPlaceholder&&(o=this.filterPlaceholder);return o}resetPlaceholder(){const e=this.getLocaleTextFunc();this.forEachInput((t,o,i,s)=>{if(!(t instanceof Ps))return;const n=0===o&&s>1?"inRangeStart":0===o?"filterOoo":"inRangeEnd",r=0===o&&s>1?e("ariaFilterFromValue","Filter from value"):0===o?e("ariaFilterValue","Filter Value"):e("ariaFilterToValue","Filter to Value");t.setInputPlaceholder(this.getPlaceholderText(n,i)),t.setInputAriaLabel(r)})}setElementValue(e,t,o){e instanceof Ps&&e.setValue(null!=t?String(t):null,!0)}setElementDisplayed(e,t){No(e)&&H(e.getGui(),t)}setElementDisabled(e,t){No(e)&&V(e.getGui(),t)}attachElementOnChange(e,t){e instanceof Ps&&e.onValueChange(t)}forEachInput(e){this.getConditionTypes().forEach((t,o)=>{this.forEachPositionTypeInput(o,t,e)})}forEachPositionInput(e,t){const o=this.getConditionType(e);this.forEachPositionTypeInput(e,o,t)}forEachPositionTypeInput(e,t,o){const i=Og(t,this.optionsFactory),s=this.getInputs(e);for(let t=0;t<s.length;t++){const n=s[t];null!=n&&o(n,t,e,i)}}isConditionDisabled(e,t){return!!this.isReadOnly()||0!==e&&e>t+1}isConditionBodyVisible(e){return Og(this.getConditionType(e),this.optionsFactory)>0}isConditionUiComplete(e){if(e>=this.getNumConditions())return!1;return"empty"!==this.getConditionType(e)&&!this.getValues(e).some(e=>null==e)}getNumConditions(){return this.eTypes.length}getUiCompleteConditions(){const 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){const t=this.getLocaleTextFunc()("ariaFilteringOperator","Filtering operator");e.setValue(this.optionsFactory.defaultOption,!0).setAriaLabel(t).setDisabled(this.isReadOnly()||this.filterListOptions.length<=1)}resetJoinOperatorAnd(e,t,o){this.resetJoinOperator(e,t,"AND"===this.defaultJoinOperator,this.translate("andCondition"),o)}resetJoinOperatorOr(e,t,o){this.resetJoinOperator(e,t,"OR"===this.defaultJoinOperator,this.translate("orCondition"),o)}resetJoinOperator(e,t,o,i,s){this.updateJoinOperatorDisabled(e.setValue(o,!0).setName(`ag-simple-filter-and-or-${this.getCompId()}-${s}`).setLabel(i),t)}updateJoinOperatorsDisabled(){const e=(e,t)=>this.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){const o=this.mapValuesFromModel(e,this.optionsFactory);this.forEachInput((e,i,s)=>{s===t&&this.setElementValue(e,null!=o[i]?o[i]:null)})}setValueFromFloatingFilter(e){this.forEachInput((t,o,i)=>{this.setElementValue(t,0===o&&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}},Wg=class{constructor(e,t,o,i,s,n){this.alive=!0,this.context=e,this.eParent=s;const r=function(e,t,o){return e.getCompDetails(t,qo,"agDateInput",o,!0)}(t,o,i);r&&r.newAgStackInstance().then(t=>{if(!this.alive)return void e.destroyBean(t);if(this.dateComp=t,!t)return;s.appendChild(t.getGui()),t?.afterGuiAttached?.();const{tempValue:o,disabled:i}=this;o&&t.setDate(o),null!=i&&t.setDisabled?.(i),n?.(this)})}destroy(){this.alive=!1,this.dateComp=this.context.destroyBean(this.dateComp)}getDate(){return this.dateComp?this.dateComp.getDate():this.tempValue}setDate(e){const t=this.dateComp;t?t.setDate(e):this.tempValue=e}setDisabled(e){const t=this.dateComp;t?t.setDisabled?.(e):this.disabled=e}setDisplayed(e){H(this.eParent,e)}setInputPlaceholder(e){this.dateComp?.setInputPlaceholder?.(e)}setInputAriaLabel(e){this.dateComp?.setInputAriaLabel?.(e)}afterGuiAttached(e){this.dateComp?.afterGuiAttached?.(e)}updateParams(e){this.dateComp?.refresh?.(e)}},Ug=["equals","notEqual","lessThan","greaterThan","inRange","blank","notBlank"];function $g(e,t){const{dateFrom:o,dateTo:i,type:s}=e||{};return[o&&cs(o,void 0,!0)||null,i&&cs(i,void 0,!0)||null].slice(0,Og(s,t))}var Kg=1/0,jg=class extends Me{constructor(e,t){super(),this.mapValuesFromModel=e,this.defaultOptions=t}init(e){const t=e.filterParams,o=new Vg;this.optionsFactory=o,o.init(t,this.defaultOptions),this.filterModelFormatter=this.createManagedBean(new this.FilterModelFormatterClass(o,t)),this.updateParams(e),this.validateModel(e)}refresh(e){if("colDef"===e.source){const t=e.filterParams,o=this.optionsFactory;o.refresh(t,this.defaultOptions),this.filterModelFormatter.updateParams({optionsFactory:o,filterParams:t}),this.updateParams(e)}this.validateModel(e)}updateParams(e){this.params=e}doesFilterPass(e){const t=e.model;if(null==t)return!0;const{operator:o}=t,i=[];if(o){const e=t;i.push(...e.conditions??[])}else i.push(t);const s=o&&"OR"===o?"some":"every",n=this.params.getValue(e.node);return i[s](t=>this.individualConditionPasses(e,t,n))}getModelAsString(e,t){return this.filterModelFormatter.getModelAsString(e,t)??""}validateModel(e){const{model:t,filterParams:{filterOptions:o,maxNumConditions:i}}=e;if(null==t)return;let s=kr(t)?t.conditions:[t];const n=o?.map(e=>"string"==typeof e?e:e.displayKey)??this.defaultOptions;if(!(!s||s.every(e=>void 0!==n.find(t=>t===e.type))))return this.params={...e,model:null},void e.onModelChange(null);let r=!1;const a=this.filterType;if((s&&!s.every(e=>e.filterType===a)||t.filterType!==a)&&(s=s.map(e=>({...e,filterType:a})),r=!0),"number"==typeof i&&s&&s.length>i&&(s=s.slice(0,i),r=!0),r){const o=s.length>1?{...t,filterType:a,conditions:s}:{...s[0],filterType:a};return this.params={...e,model:o},void e.onModelChange(o)}}individualConditionPasses(e,t,o){const i=this.optionsFactory,s=this.mapValuesFromModel(t,i),n=function(e,t,o){if(null==e)return;const{predicate:i}=e;return null==i||t.some(e=>null==e)?void 0:i(t,o)}(i.getCustomOption(t.type),s,o);return null!=n?n:null==o?this.evaluateNullValue(t.type):this.evaluateNonNullValue(s,o,t,e)}},qg=class extends jg{evaluateNullValue(e){const{includeBlanksInEquals:t,includeBlanksInNotEqual:o,includeBlanksInGreaterThan:i,includeBlanksInLessThan:s,includeBlanksInRange:n}=this.params.filterParams;switch(e){case"equals":if(t)return!0;break;case"notEqual":if(o)return!0;break;case"greaterThan":case"greaterThanOrEqual":if(i)return!0;break;case"lessThan":case"lessThanOrEqual":if(s)return!0;break;case"inRange":if(n)return!0;break;case"blank":return!0;case"notBlank":return!1}return!1}evaluateNonNullValue(e,t,o){const i=o.type;if(!this.isValid(t))return"notEqual"===i||"notBlank"===i;const s=this.comparator(),n=null!=e[0]?s(e[0],t):0;switch(i){case"equals":return 0===n;case"notEqual":return 0!==n;case"greaterThan":return n>0;case"greaterThanOrEqual":return n>=0;case"lessThan":return n<0;case"lessThanOrEqual":return n<=0;case"inRange":{const o=s(e[1],t);return this.params.filterParams.inRangeInclusive?n>=0&&o<=0:n>0&&o<0}case"blank":return Ng(t);case"notBlank":return!Ng(t);default:return st(76,{filterModelType:i}),!0}}},_g={equals:"Equals",notEqual:"NotEqual",greaterThan:"GreaterThan",greaterThanOrEqual:"GreaterThanOrEqual",lessThan:"LessThan",lessThanOrEqual:"LessThanOrEqual",inRange:"InRange"},Yg={contains:"Contains",notContains:"NotContains",equals:"TextEquals",notEqual:"TextNotEqual",startsWith:"StartsWith",endsWith:"EndsWith",inRange:"InRange"},Qg=class extends Me{constructor(e,t,o){super(),this.optionsFactory=e,this.filterParams=t,this.valueFormatter=o}getModelAsString(e,t){const o=this.getLocaleTextFunc(),i="filterToolPanel"===t;if(!e)return i?ar(this,"filterSummaryInactive"):null;if(null!=e.operator){const o=e,i=(o.conditions??[]).map(e=>this.getModelAsString(e,t)),s="AND"===o.operator?"andCondition":"orCondition";return i.join(` ${ar(this,s)} `)}if("blank"===e.type||"notBlank"===e.type)return i?ar(this,"blank"===e.type?"filterSummaryBlank":"filterSummaryNotBlank"):o(e.type,e.type);{const t=e,s=this.optionsFactory.getCustomOption(t.type),{displayKey:n,displayName:r,numberOfInputs:a}=s||{};return n&&r&&0===a?o(n,r):this.conditionToString(t,i,"inRange"===t.type||2===a,n,r)}}updateParams(e){const{optionsFactory:t,filterParams:o}=e;this.optionsFactory=t,this.filterParams=o}conditionForToolPanel(e,t,o,i,s,n){let r;const a=this.getTypeKey(e);return a&&(r=ar(this,a)),s&&n&&(r=this.getLocaleTextFunc()(s,n)),null!=r?t?`${r} ${ar(this,"filterSummaryInRangeValues",[o(),i()])}`:`${r} ${o()}`:null}getTypeKey(e){const t=this.filterTypeKeys[e];return t?`filterSummary${t}`:null}formatValue(e){const t=this.valueFormatter;return t?t(e??null)??"":String(e)}},Zg=class extends Qg{constructor(e,t){super(e,t,e=>{const{dataTypeSvc:o,valueSvc:i}=this.beans,s=t.column,n=o?.getDateFormatterFunction(s),r=n?.(e??void 0);return i.formatValue(s,null,r)}),this.filterTypeKeys=_g}conditionToString(e,t,o,i,s){const{type:n}=e,r=cs(e.dateFrom),a=cs(e.dateTo),l=this.filterParams.inRangeFloatingFilterDateFormat,d=t?this.formatValue.bind(this):e=>ds(e,l),h=()=>null!==r?d(r):"null",c=()=>null!==a?d(a):"null";if(t){const e=this.conditionForToolPanel(n,o,h,c,i,s);if(null!=e)return e}return o?`${h()}-${c()}`:null!=r?d(r):`${n}`}};function Jg(e,t){return t<e?-1:t>e?1:0}var Xg=class extends Uo{constructor(){super(...arguments),this.defaultDebounceMs=0}setLastTypeFromModel(e){if(!e)return void(this.lastType=this.optionsFactory.defaultOption);let t;if(e.operator){t=e.conditions[0]}else t=e;this.lastType=t.type}canWeEditAfterModelFromParentFilter(e){if(!e)return this.isTypeEditable(this.lastType);if(e.operator)return!1;const t=e;return this.isTypeEditable(t.type)}init(e){this.params=e;const t=this.gos.get("enableFilterHandlers");if(this.reactive=t,this.setParams(e),t){const t=e;this.onModelUpdated(t.model)}}setParams(e){const t=new Vg;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){const o=this.optionsFactory.defaultOption;t||(this.lastType=o),this.readOnly=!!e.filterParams.readOnly;const i=this.isTypeEditable(o);this.setEditable(i)}refresh(e){this.params=e;const t=e,o=this.reactive;if(o&&"colDef"!==t.source||this.updateParams(e),o){const{source:e,model:o}=t;if("dataChanged"===e||"ui"===e)return;this.onModelUpdated(o)}}updateParams(e){const 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){const t=this.optionsFactory.getCustomOption(e)?.numberOfInputs;return null==t||1==t}isTypeEditable(e){return!!e&&!this.readOnly&&this.hasSingleInput(e)&&["inRange","empty","blank","notBlank"].indexOf(e)<0}getAriaLabel(e){return`${this.beans.colNames.getDisplayNameForColumn(e.column,"header",!0)} ${this.getLocaleTextFunc()("ariaFilterInput","Filter Input")}`}},ep={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"}]},tp={tag:"div",cls:"ag-filter-filter",children:[{tag:"ag-input-text-field",ref:"eDateInput",cls:"ag-date-filter"}]},op=["equals","notEqual","greaterThan","greaterThanOrEqual","lessThan","lessThanOrEqual","inRange","blank","notBlank"];function ip(e){const{allowedCharPattern:t}=e??{};return t??null}function sp(e){return null==e||isNaN(e)?null:e}function np(e,t){const{filter:o,filterTo:i,type:s}=e||{};return[sp(o),sp(i)].slice(0,Og(s,t))}var rp=class extends Qg{constructor(e,t){super(e,t,t.numberFormatter),this.filterTypeKeys=_g}conditionToString(e,t,o,i,s){const{filter:n,filterTo:r,type:a}=e,l=this.formatValue.bind(this);if(t){const e=this.conditionForToolPanel(a,o,()=>l(n),()=>l(r),i,s);if(null!=e)return e}return o?`${l(n)}-${l(r)}`:null!=n?l(n):`${a}`}},ap=class extends Me{constructor(e){super(),this.params=e,this.eInput=Go,this.onValueChanged=()=>{}}setupGui(e){this.eInput=this.createManagedBean(new Ts(this.params?.config));const t=this.eInput.getGui();e.appendChild(t);const o=e=>this.onValueChanged(e);this.addManagedListeners(t,{input:o,keydown:o})}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}){const{eInput:o}=this;o.setInputAriaLabel(e),void 0!==t&&o.setAutoComplete(t)}};function lp(e){const t=e?.trim();return""===t?e:t}function dp(e,t){const{filter:o,filterTo:i,type:s}=e||{};return[o||null,i||null].slice(0,Og(s,t))}var hp={tag:"div",ref:"eFloatingFilterInputContainer",cls:"ag-floating-filter-input",role:"presentation"},cp=class extends Xg{constructor(){super(...arguments),this.eFloatingFilterInputContainer=Go,this.defaultDebounceMs=500}postConstruct(){this.setTemplate(hp)}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){const t=e.browserAutoComplete??!1,{inputSvc:o,defaultDebounceMs:i,readOnly:s}=this;if(o.setParams({ariaLabel:this.getAriaLabel(e),autoComplete:t}),this.applyActive=dr(e.filterParams),!s){const t=lr(e.filterParams,i),s=Be(this,this.syncUpWithParentFilter.bind(this),t);o.setValueChangedListener(s)}}updateParams(e){super.updateParams(e),this.setTextInputParams(e)}recreateFloatingFilterInputService(e){const{inputSvc:t}=this,o=t.getValue();q(this.eFloatingFilterInputContainer),this.destroyBean(t),this.setupFloatingFilterInputService(e),t.setValue(o,!0)}syncUpWithParentFilter(e){const t=e.key===Pi,o=this.reactive;if(o){this.params.onUiChange()}if(this.applyActive&&!t)return;const{inputSvc:i,params:s,lastType:n}=this;let r=i.getValue();if(s.filterParams.trimInput&&(r=lp(r),i.setValue(r,!0)),o){const e=s,t=e.model,o=this.convertValue(r),i=null==o?null:{...t??{filterType:this.filterType,type:n??this.optionsFactory.defaultOption},filter:o};e.onModelChange(i,{afterFloatingFilter:!0})}else s.parentFilterInstance(e=>{e?.onFloatingFilterChanged(n||null,r||null)})}convertValue(e){return e||null}setEditable(e){this.inputSvc.setEditable(e)}},up=class extends Me{constructor(){super(...arguments),this.onValueChanged=()=>{},this.numberInputActive=!0}setupGui(e){this.eNumberInput=this.createManagedBean(new Ls),this.eTextInput=this.createManagedBean(new Ts),this.eTextInput.setDisabled(!0);const t=this.eNumberInput.getGui(),o=this.eTextInput.getGui();e.appendChild(t),e.appendChild(o),this.setupListeners(t,e=>this.onValueChanged(e)),this.setupListeners(o,e=>this.onValueChanged(e))}setEditable(e){this.numberInputActive=e,this.eNumberInput.setDisplayed(this.numberInputActive),this.eTextInput.setDisplayed(!this.numberInputActive)}setAutoComplete(e){this.eNumberInput.setAutoComplete(e),this.eTextInput.setAutoComplete(e)}getValue(){return this.getActiveInputElement().getValue()}setValue(e,t){this.getActiveInputElement().setValue(e,t)}getActiveInputElement(){return this.numberInputActive?this.eNumberInput:this.eTextInput}setValueChangedListener(e){this.onValueChanged=e}setupListeners(e,t){this.addManagedListeners(e,{input:t,keydown:t})}setParams(e){this.setAriaLabel(e.ariaLabel),void 0!==e.autoComplete&&this.setAutoComplete(e.autoComplete)}setAriaLabel(e){this.eNumberInput.setInputAriaLabel(e),this.eTextInput.setInputAriaLabel(e)}},gp=["contains","notContains","equals","notEqual","startsWith","endsWith","blank","notBlank"],pp=class extends Qg{constructor(){super(...arguments),this.filterTypeKeys=Yg}conditionToString(e,t,o,i,s){const{filter:n,filterTo:r,type:a}=e;if(t){const e=e=>()=>ar(this,"filterSummaryTextQuote",[e]),t=this.conditionForToolPanel(a,o,e(n),e(r),i,s);if(null!=t)return t}return o?`${n}-${r}`:null!=n?`${n}`:`${a}`}},mp=({filterOption:e,value:t,filterText:o})=>{if(null==o)return!1;switch(e){case"contains":return t.indexOf(o)>=0;case"notContains":return t.indexOf(o)<0;case"equals":return t===o;case"notEqual":return t!=o;case"startsWith":return 0===t.indexOf(o);case"endsWith":{const e=t.lastIndexOf(o);return e>=0&&e===t.length-o.length}default:return!1}},fp=e=>e,Cp=e=>null==e?null:e.toString().toLowerCase();var vp={moduleName:"ClientSideRowModelFilter",version:qe,rowModels:["clientSide"],beans:[class extends Me{constructor(){super(...arguments),this.beanName="filterStage",this.refreshProps=new Set(["excludeChildrenWhenTreeDataFiltering"]),this.step="filter"}wireBeans(e){this.filterManager=e.filterManager}execute(e){const{changedPath:t}=e;this.filter(t)}filter(e){const t=!!this.filterManager?.isChildFilterPresent();this.filterNodes(t,e)}filterNodes(e,t){const o=(t,o)=>{t.hasChildren()?t.childrenAfterFilter=e&&!o?t.childrenAfterGroup.filter(e=>{const t=e.childrenAfterFilter&&e.childrenAfterFilter.length>0,o=e.data&&this.filterManager.doesRowPassFilter({rowNode:e});return t||o}):t.childrenAfterGroup:t.childrenAfterFilter=t.childrenAfterGroup,Ig(t)};if(this.doingTreeDataFiltering()){const e=(t,i)=>{if(t.childrenAfterGroup)for(let s=0;s<t.childrenAfterGroup.length;s++){const n=t.childrenAfterGroup[s],r=i||this.filterManager.doesRowPassFilter({rowNode:n});n.childrenAfterGroup?e(t.childrenAfterGroup[s],r):o(n,r)}o(t,i)},i=t=>e(t,!1);t.executeFromRootNode(i)}else{const e=e=>o(e,!1);t.forEachChangedNodeDepthFirst(e,!0)}}doingTreeDataFiltering(){return this.gos.get("treeData")&&!this.gos.get("excludeChildrenWhenTreeDataFiltering")}}]},wp={moduleName:"FilterCore",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="filterManager",this.advFilterModelUpdateQueue=[]}wireBeans(e){this.quickFilter=e.quickFilter,this.advancedFilter=e.advancedFilter,this.colFilter=e.colFilter}postConstruct(){const 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"})});const{gos:o}=this;this.alwaysPassFilter=o.get("alwaysPassFilter"),this.addManagedPropertyListener("alwaysPassFilter",()=>{this.alwaysPassFilter=o.get("alwaysPassFilter"),this.onFilterChanged({source:"api"})})}isExternalFilterPresentCallback(){const e=this.gos.getCallback("isExternalFilterPresent");return"function"==typeof e&&e({})}doesExternalFilterPass(e){const t=this.gos.get("doesExternalFilterPass");return"function"==typeof t&&t(e)}setFilterState(e,t,o="api"){this.isAdvFilterEnabled()||this.colFilter?.setState(e,t,o)}setFilterModel(e,t="api",o){this.isAdvFilterEnabled()?o||this.warnAdvFilters():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(){St(this.gos)&&this.isAnyFilterPresent()&&this.onFilterChanged()}onFilterChanged(e={}){const{source:t,additionalEventAttributes:o,columns:i=[]}=e;this.externalFilterPresent=this.isExternalFilterPresentCallback(),(this.colFilter?this.colFilter.updateBeforeFilterChanged(e):Ko.resolve()).then(()=>{const e={source:t,type:"filterChanged",columns:i};o&&Ge(e,o),this.eventSvc.dispatchEvent(e),this.colFilter?.updateAfterFilterChanged()})}isSuppressFlashingCellsBecauseFiltering(){return!!this.colFilter?.isSuppressFlashingCellsBecauseFiltering()}isQuickFilterPresent(){return!!this.quickFilter?.isFilterPresent()}updateAggFiltering(){this.aggFiltering=!!St(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){const{rowNode:t}=e;return!!this.alwaysPassFilter?.(t)||!(this.isAggregateQuickFilterPresent()&&!this.quickFilter.doesRowPass(t))&&!(this.isAggregateFilterPresent()&&!this.colFilter.doFiltersPass(t,e.colIdToSkip,!0))}doesRowPassFilter(e){const{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}setAdvFilterModel(e,t="api"){this.isAdvFilterEnabled()&&(this.beans.dataTypeSvc?.isPendingInference?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(){st(68)}setupAdvFilterHeaderComp(e){this.advancedFilter?.getCtrl().setupHeaderComp(e)}getHeaderRowCount(){return this.isAdvFilterHeaderActive()?1:0}getHeaderHeight(){return this.isAdvFilterHeaderActive()?this.advancedFilter.getCtrl().getHeaderHeight():0}processFilterModelUpdateQueue(){this.advFilterModelUpdateQueue.forEach(e=>this.setAdvFilterModel(e)),this.advFilterModelUpdateQueue=[]}setColumnFilterModel(e,t){return this.isAdvFilterEnabled()?(this.warnAdvFilters(),Promise.resolve()):this.colFilter?.setModelForColumn(e,t)??Promise.resolve()}}],apiFunctions:{isAnyFilterPresent:function(e){return!!e.filterManager?.isAnyFilterPresent()},onFilterChanged:function(e,t="api"){e.filterManager?.onFilterChanged({source:t})}},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:[vp]},bp={moduleName:"FilterValue",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="filterValueSvc"}getValue(e,t,o){if(!t)return;const i=e.getColDef(),{selectableFilter:s,valueSvc:n}=this.beans,r=o??s?.getFilterValueGetter(e.getColId())??i.filterValueGetter;return r?this.executeFilterValueGetter(r,t.data,e,t,i):n.getValue(e,t)}executeFilterValueGetter(e,t,o,i,s){const{expressionSvc:n,valueSvc:r}=this.beans,a=zt(this.gos,{data:t,node:i,column:o,colDef:s,getValue:r.getValueCallback.bind(r,i)});return"function"==typeof e?e(a):n?.evaluate(e,a)}}]},yp={moduleName:"ColumnFilter",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="colFilter",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={...Zn},this.isGlobalButtons=!1,this.activeFilterComps=new Set}postConstruct(){this.addManagedEventListeners({gridColumnsChanged:this.onColumnsChanged.bind(this),dataTypesInferred:this.processFilterModelUpdateQueue.bind(this)});const 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",o){const{colModel:i,dataTypeSvc:s,filterManager:r}=this.beans;if(s?.isPendingInference)return void this.modelUpdates.push({model:e,source:t});const a=[],l=this.getModel(!0);if(e){const t=new Set(Object.keys(e));this.allColumnFilters.forEach((o,i)=>{const s=e[i];a.push(this.setModelOnFilterWrapper(o,s)),t.delete(i)}),t.forEach(t=>{const o=i.getColDefCol(t)||i.getCol(t);if(!o)return void st(62,{colId:t});if(!o.isFilterAllowed())return void st(63,{colId:t});const s=this.getOrCreateFilterWrapper(o,!0);s?a.push(this.setModelOnFilterWrapper(s,e[t],!0)):st(64,{colId:t})})}else this.model={},this.allColumnFilters.forEach(e=>{a.push(this.setModelOnFilterWrapper(e,null))});Ko.all(a).then(()=>{const e=this.getModel(!0),i=[];this.allColumnFilters.forEach((t,o)=>{n(l?l[o]:null,e?e[o]:null)||i.push(t.column)}),i.length>0?r?.onFilterChanged({columns:i,source:t}):o&&this.updateActive("filterChanged")})}getModel(e){const t={},{allColumnFilters:i,initialModel:s,beans:{colModel:n}}=this;if(i.forEach((e,i)=>{const s=this.getModelFromFilterWrapper(e);o(s)&&(t[i]=s)}),!e)for(const e of Object.keys(s)){const r=s[e];o(r)&&!i.has(e)&&n.getCol(e)?.isFilterAllowed()&&(t[e]=r)}return t}setState(e,t,o="api"){if(this.state.clear(),t)for(const e of Object.keys(t)){const o=t[e];this.state.set(e,{model:ir(this.model,e),state:o})}this.setModel(e,o,!0)}getState(){const e=this.state;if(!e.size)return;const t={};let o=!1;return e.forEach((e,i)=>{const s=e.state;null!=s&&(o=!0,t[i]=s)}),o?t:void 0}getModelFromFilterWrapper(e){const t=e.column.getColId();if(e.isHandler)return ir(this.model,t);const o=e.filter;return o?"function"!=typeof o.getModel?(st(66),null):o.getModel():ir(this.initialModel,t)}isFilterPresent(){return this.activeColumnFilters.length>0}isAggFilterPresent(){return!!this.activeAggregateFilters.length}disableFilters(){this.initialModel={};const{allColumnFilters:e}=this;return!!e.size&&(e.forEach(e=>this.disposeFilterWrapper(e,"advancedFilterEnabled")),!0)}updateActiveFilters(){const{colModel:e,gos:t}=this.beans,o=!!St(t),i=[],s=[],n=(t,n,r)=>{n&&((t=>{if(!t.isPrimary())return!0;const i=!e.isPivotActive();return!(!t.isValueActive()||!i)&&(!!e.isPivotMode()||o)})(t)?i.push(r):s.push(r))},r=[];return this.allColumnFilters.forEach(e=>{const t=e.column,o=t.getColId();if(e.isHandler)r.push(Ko.resolve().then(()=>{n(t,this.isHandlerActive(t),{colId:o,isHandler:!0,handler:e.handler,handlerParams:e.handlerParams})}));else{const i=Xn(e);i&&r.push(i.then(e=>{n(t,(e=>!!e&&(e.isFilterActive?e.isFilterActive():(st(67),!1)))(e),{colId:o,isHandler:!1,comp:e})}))}}),Ko.all(r).then(()=>{this.activeAggregateFilters=i,this.activeColumnFilters=s})}updateFilterFlagInColumns(e,t){const o=[];return this.allColumnFilters.forEach(i=>{const s=i.column;if(i.isHandler)o.push(Ko.resolve().then(()=>{this.setColFilterActive(s,this.isHandlerActive(s),e,t)}));else{const n=Xn(i);n&&o.push(n.then(o=>{this.setColFilterActive(s,o.isFilterActive(),e,t)}))}}),this.beans.groupFilter?.updateFilterFlags(e,t),Ko.all(o)}doFiltersPass(e,t,o){const{data:i,aggData:s}=e,n=o?this.activeAggregateFilters:this.activeColumnFilters,r=o?s:i,a=this.model;for(let o=0;o<n.length;o++){const i=n[o],{colId:s,isHandler:l}=i;if(s!==t)if(l){const{handler:t,handlerParams:o}=i;if(!t.doesFilterPass({node:e,data:r,model:ir(a,s),handlerParams:o}))return!1}else{const t=i.comp;if("function"!=typeof t.doesFilterPass){nt(91);continue}if(!t.doesFilterPass({node:e,data:r}))return!1}}return!0}getHandlerParams(e){const t=this.allColumnFilters.get(e.getColId());return t?.isHandler?t.handlerParams:void 0}callOnFilterChangedOutsideRenderCycle(e){const{rowRenderer:t,filterManager:o}=this.beans,i=()=>{this.isAlive()&&o?.onFilterChanged(e)};t.isRefreshInProgress()?setTimeout(i,0):i()}updateBeforeFilterChanged(e={}){const{column:t,additionalEventAttributes:o}=e,i=t?.getColId();return this.updateActiveFilters().then(()=>this.updateFilterFlagInColumns("filterChanged",o).then(()=>{this.allColumnFilters.forEach(e=>{const{column:t,isHandler:o}=e;i!==t.getColId()&&(o&&e.handler.onAnyFilterChanged?.(),Xn(e,o)?.then(e=>{"function"==typeof e?.onAnyFilterChanged&&e.onAnyFilterChanged()}))}),this.processingFilterChange=!0}))}updateAfterFilterChanged(){this.processingFilterChange=!1}isSuppressFlashingCellsBecauseFiltering(){return!(this.gos.get("allowShowChangeAfterFilter")??!1)&&this.processingFilterChange}onNewRowsLoaded(e){const t=[];this.allColumnFilters.forEach(e=>{const o=e.isHandler;o&&e.handler.onNewRowsLoaded?.();const i=Xn(e,o);i&&t.push(i.then(e=>{e.onNewRowsLoaded?.()}))}),Ko.all(t).then(()=>this.updateActive(e,{afterDataChange:!0}))}updateActive(e,t){this.updateFilterFlagInColumns(e,t).then(()=>this.updateActiveFilters())}createGetValue(e,t){const{filterValueSvc:o,colModel:i}=this.beans;return(s,n)=>{const r=n?i.getCol(n):e;return r?o.getValue(r,s,t):void 0}}isFilterActive(e){const t=this.cachedFilter(e);if(t?.isHandler)return this.isHandlerActive(e);const o=t?.filter;return o?o.isFilterActive():null!=ir(this.initialModel,e.getColId())}isHandlerActive(e){const t=o(ir(this.model,e.getColId()));if(t)return t;const i=this.beans.groupFilter;return!!i?.isGroupFilter(e)&&i.isFilterActive(e)}getOrCreateFilterUi(e){const t=this.getOrCreateFilterWrapper(e,!0);return t?Xn(t):null}getFilterUiForDisplay(e){const t=this.getOrCreateFilterWrapper(e,!0);if(!t)return null;const o=Xn(t);return o?o.then(e=>({comp:e,params:t.filterUi.filterParams,isHandler:t.isHandler})):null}getHandler(e,t){const o=this.getOrCreateFilterWrapper(e,t);return o?.isHandler?o.handler:void 0}getOrCreateFilterWrapper(e,t){if(!e.isFilterAllowed())return;let o=this.cachedFilter(e);return!o&&t&&(o=this.createFilterWrapper(e),this.setColumnFilterWrapper(e,o)),o}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){return(o=this.gos).isModuleRegistered("SetFilter")&&!o.get("suppressSetFilterByDefault")?t?"agSetColumnFloatingFilter":"agSetColumnFilter":function(e,t=!1){return(t?br:wr)[e??"text"]}(e(),t);var o}getDefaultFloatingFilter(e){return this.getDefaultFilter(e,!0)}createFilterComp(e,t,o,i,s,n){const r=()=>{const r=this.createFilterCompParams(e,s,n),a=i(r,s);return function(e,t,o,i){const s=t.filter;return $o(s)&&(t={filter:s.component,filterParams:t.filterParams}),e.getCompDetails(t,ni,i,o,!0)}(this.beans.userCompFactory,t,a,o)},a=r();if(!a)return null;return{compDetails:a,createFilterUi:e=>(e?r():a).newAgStackInstance()}}createFilterInstance(e,t,o,i){const s=this.beans.selectableFilter;s?.isSelectable(t)&&(t=s.getFilterDef(e,t));const{handler:n,handlerParams:r,handlerGenerator:a}=this.createHandler(e,t,o)??{},l=this.createFilterComp(e,t,o,i,!!n,"init");if(!l)return{compDetails:null,createFilterUi:null,handler:n,handlerGenerator:a,handlerParams:r};const{compDetails:d,createFilterUi:h}=l;if(this.isGlobalButtons){!!d.params?.buttons?.length||st(281,{colId:e.getColId()})}return{compDetails:d,handler:n,handlerGenerator:a,handlerParams:r,createFilterUi:h}}createBaseFilterParams(e,t){const{filterManager:o,rowModel:i}=this.beans;return zt(this.gos,{column:e,colDef:e.getColDef(),getValue:this.createGetValue(e),doesRowPassOtherFilter:t?()=>!0:t=>o?.doesRowPassOtherFilters(e.getColId(),t)??!0,rowModel:i})}createFilterCompParams(e,t,o,i){const s=this.filterChangedCallbackFactory(e),n=this.createBaseFilterParams(e,i);if(n.filterChangedCallback=s,n.filterModifiedCallback=i?()=>{}:t=>this.filterModified(e,t),t){const t=n,i=e.getColId(),r=ir(this.model,i);t.model=r,t.state=this.state.get(i)??{model:r},t.onModelChange=(t,o)=>{this.updateStoredModel(i,t),this.refreshHandlerAndUi(e,t,"ui").then(()=>{s({...o,source:"columnFilter"})})},t.onStateChange=t=>{this.updateState(e,t),this.updateOrRefreshFilterUi(e)},t.onAction=(t,o,i)=>{this.updateModel(e,t,o),this.dispatchLocalEvent({type:"filterAction",column:e,action:t,event:i})},t.getHandler=()=>this.getHandler(e,!0),t.onUiChange=t=>this.filterUiChanged(e,t),t.source=o}return n}createFilterUiForHandler(e,t){return t?{created:!1,create:t,filterParams:e.params,compDetails:e}:null}createFilterUiLegacy(e,t,o){const i=t(),s={created:!0,create:t,filterParams:e.params,compDetails:e,promise:i};return i.then(o),s}createFilterWrapper(e){const{compDetails:t,handler:o,handlerGenerator:i,handlerParams:s,createFilterUi:n}=this.createFilterInstance(e,e.getColDef(),this.getDefaultFilter(e),e=>e),r=e.getColId();if(o)return delete this.initialModel[r],o.init?.({...s,source:"init",model:ir(this.model,r)}),{column:e,isHandler:!0,handler:o,handlerGenerator:i,handlerParams:s,filterUi:this.createFilterUiForHandler(t,n)};if(n){const o={column:e,filterUi:null,isHandler:!1};return o.filterUi=this.createFilterUiLegacy(t,n,e=>{o.filter=e??void 0}),o}return{column:e,filterUi:null,isHandler:!1}}createHandlerFunc(e,t,o){const{gos:i,frameworkOverrides:s,registry:n}=this.beans;let r;const a=i.get("enableFilterHandlers"),l=a?(e=>{const t=e.filter;if($o(t)){const e=t.handler;return e||(r=t.doesFilterPass,r?()=>({doesFilterPass:r}):void 0)}return"string"==typeof t?t:void 0})(t):void 0,d=e=>()=>this.createBean(n.createDynamicBean(e,!0));let h,c;if("string"==typeof l){const e=i.get("filterHandlers")?.[l];null!=e?h=e:Jn.has(l)&&(h=d(l),c=l)}else h=l;if(!h){let e;const{compName:i,jsComp:n,fwComp:r}=pi(s,t);if(i)e=i;else{null==n&&null==r&&!0===t.filter&&(e=o)}c=this.handlerMap[e],c&&(h=d(c))}if(!h){if(!a)return;return dt(i)&&st(277,{colId:e.getColId()}),Bg}return{filterHandler:h,handlerNameOrCallback:r??c}}createHandler(e,t,o){const i=this.createHandlerFunc(e,t,o);if(!i)return;const s=mi(this.beans.userCompFactory,t,this.createFilterCompParams(e,!0,"init")),{handlerNameOrCallback:n,filterHandler:r}=i,{handler:a,handlerParams:l}=this.createHandlerFromFunc(e,r,s);return{handler:a,handlerParams:l,handlerGenerator:n??r}}createHandlerFromFunc(e,t,o){const i=e.getColDef();return{handler:t(zt(this.gos,{column:e,colDef:i})),handlerParams:this.createHandlerParams(e,o)}}createHandlerParams(e,t){const o=e.getColDef(),i=e.getColId(),s=this.filterChangedCallbackFactory(e);return zt(this.gos,{colDef:o,column:e,getValue:this.createGetValue(e),doesRowPassOtherFilter:e=>this.beans.filterManager?.doesRowPassOtherFilters(i,e)??!0,onModelChange:(t,o)=>{this.updateStoredModel(i,t),this.refreshHandlerAndUi(e,t,"handler").then(()=>{s({...o,source:"columnFilter"})})},filterParams:t})}onColumnsChanged(){const e=[],{colModel:t,filterManager:o,groupFilter:i}=this.beans;this.allColumnFilters.forEach((o,i)=>{let s;s=o.column.isPrimary()?t.getColDefCol(i):t.getCol(i),s&&s===o.column||(e.push(o.column),this.disposeFilterWrapper(o,"columnChanged"),this.disposeColumnListener(i))});const s=i&&e.every(e=>i.isGroupFilter(e));e.length>0&&!s&&o?.onFilterChanged({columns:e,source:"api"})}isFilterAllowed(e){if(!e.isFilterAllowed())return!1;const t=this.beans.groupFilter;return!t?.isGroupFilter(e)||t.isFilterAllowed(e)}getFloatingFilterCompDetails(e,t){const{userCompFactory:o,frameworkOverrides:i,selectableFilter:s}=this.beans,n=e.getColDef(),r=s?.isSelectable(n)?s.getFilterDef(e,n):n,a=function(e,t,o){if(null==t)return null;let i=null;const{compName:s,jsComp:n,fwComp:r}=pi(e,t);s?i={agSetColumnFilter:"agSetColumnFloatingFilter",agMultiColumnFilter:"agMultiColumnFloatingFilter",agGroupColumnFilter:"agGroupColumnFloatingFilter",agNumberColumnFilter:"agNumberColumnFloatingFilter",agDateColumnFilter:"agDateColumnFloatingFilter",agTextColumnFilter:"agTextColumnFloatingFilter"}[s]:null==n&&null==r&&!0===t.filter&&(i=o());return i}(i,r,()=>this.getDefaultFloatingFilter(e))??"agReadOnlyFloatingFilter",l=this.gos.get("enableFilterHandlers"),d=mi(o,r,this.createFilterCompParams(e,l,"init",!0)),h=zt(this.gos,{column:e,filterParams:d,currentParentModel:()=>this.getCurrentFloatingFilterParentModel(e),parentFilterInstance:t=>{const o=this.getOrCreateFilterUi(e);null!=o&&o.then(e=>{t(fi(e))})},showParentFilter:t});if(l){const t=h,o=e.getColId(),i=this.filterChangedCallbackFactory(e);t.onUiChange=t=>this.floatingFilterUiChanged(e,t),t.model=ir(this.model,o),t.onModelChange=(t,s)=>{this.updateStoredModel(o,t),this.refreshHandlerAndUi(e,t,"floating",!0).then(()=>{i({...s,source:"columnFilter"})})},t.getHandler=()=>this.getHandler(e,!0),t.source="init"}return function(e,t,o,i){return e.getCompDetails(t,ri,i,o)}(o,n,h,a)}getCurrentFloatingFilterParentModel(e){return this.getModelFromFilterWrapper(this.cachedFilter(e)??{column:e})}destroyFilterUi(e,t,o,i){if(e.isHandler){const s=t.getColId();delete this.initialModel[s],this.state.delete(s);const n=e.filterUi,r=this.createFilterUiForHandler(o,i);e.filterUi=r,n?.created&&n.promise.then(t=>{this.destroyBean(t),this.eventSvc.dispatchEvent({type:"filterDestroyed",source:"paramsUpdated",column:e.column})})}else this.destroyFilter(t,"paramsUpdated")}destroyFilter(e,t="api"){const o=e.getColId(),i=this.allColumnFilters.get(o);this.disposeColumnListener(o),delete this.initialModel[o],i&&this.disposeFilterWrapper(i,t).then(t=>{t&&this.isAlive()&&this.beans.filterManager?.onFilterChanged({columns:[e],source:"api"})})}disposeColumnListener(e){const t=this.allColumnListeners.get(e);t&&(this.allColumnListeners.delete(e),t())}disposeFilterWrapper(e,t){let o=!1;const{column:i,isHandler:s,filterUi:n}=e,r=i.getColId();s&&(o=this.isHandlerActive(i),this.destroyBean(e.handler),delete this.model[r],this.state.delete(r));const a=()=>{this.setColFilterActive(i,!1,"filterDestroyed"),this.allColumnFilters.delete(r),this.eventSvc.dispatchEvent({type:"filterDestroyed",source:t,column:i})};if(n){if(n.created)return n.promise.then(e=>(o=s?o:!!e?.isFilterActive(),this.destroyBean(e),a(),o));a()}return Ko.resolve(o)}filterChangedCallbackFactory(e){return t=>{this.callOnFilterChangedOutsideRenderCycle({additionalEventAttributes:t,columns:[e],column:e,source:t?.source??"columnFilter"})}}filterParamsChanged(e,t="api"){const o=this.allColumnFilters.get(e);if(!o)return;const i=this.beans,s=o.column,n=s.getColDef(),r=s.isFilterAllowed(),a=this.getDefaultFilter(s),l=i.selectableFilter,d=l?.isSelectable(n)?l.getFilterDef(s,n):n,h=r?this.createHandlerFunc(s,d,this.getDefaultFilter(s)):void 0,c=!!h,u=o.isHandler;if(u!=c)return void this.destroyFilter(s,"paramsUpdated");const{compDetails:g,createFilterUi:p}=(r?this.createFilterComp(s,d,a,e=>e,c,"colDef"):null)??{compDetails:null,createFilterUi:null},m=g?.params??mi(i.userCompFactory,d,this.createFilterCompParams(s,c,"colDef"));if(u){const i=h?.handlerNameOrCallback??h?.filterHandler,n=ir(this.model,e);if(o.handlerGenerator!=i){const r=o.handler,{handler:a,handlerParams:l}=this.createHandlerFromFunc(s,h.filterHandler,m);o.handler=a,o.handlerParams=l,o.handlerGenerator=i,delete this.model[e],a.init?.({...l,source:"init",model:null}),this.destroyBean(r),null!=n&&this.beans.filterManager?.onFilterChanged({columns:[s],source:t})}else{const e=this.createHandlerParams(s,g?.params);o.handlerParams=e,o.handler.refresh?.({...e,source:"colDef",model:n})}}!this.areFilterCompsDifferent(o.filterUi?.compDetails??null,g)&&o.filterUi&&g?(o.filterUi.filterParams=m,Xn(o,u)?.then(e=>{!1===(!e?.refresh||e.refresh(m))?this.destroyFilterUi(o,s,g,p):this.dispatchLocalEvent({type:"filterParamsChanged",column:s,params:m})})):this.destroyFilterUi(o,s,g,p)}refreshHandlerAndUi(e,t,o,i){const s=this.cachedFilter(e);if(!s)return i&&this.getOrCreateFilterWrapper(e,!0),Ko.resolve();if(!s.isHandler)return Ko.resolve();const{filterUi:n,handler:r,handlerParams:a}=s;return function(e,t,o,i,s,n){return t.refresh?.({...o,model:i,source:n}),e().then(e=>{if(e){const{filter:t,filterParams:o}=e;er(t,o,i,s,n)}})}(()=>{if(n){const{created:e,filterParams:t}=n;if(e)return n.promise.then(e=>e?{filter:e,filterParams:t}:void 0);n.refreshed=!0}return Ko.resolve(void 0)},r,a,t,this.state.get(e.getColId())??{model:t},o)}setColumnFilterWrapper(e,t){const o=e.getColId();this.allColumnFilters.set(o,t),this.allColumnListeners.set(o,this.addManagedListeners(e,{colDefChanged:()=>this.filterParamsChanged(o)})[0])}areFilterCompsDifferent(e,t){if(!t||!e)return!0;const{componentClass:o}=e,{componentClass:i}=t;return!(o===i||o?.render&&i?.render&&o.render===i.render)}hasFloatingFilters(){return this.beans.colModel.getCols().some(e=>e.getColDef().floatingFilter)}getFilterInstance(e){const t=this.beans.colModel.getColDefCol(e);if(!t)return Promise.resolve(void 0);const o=this.getOrCreateFilterUi(t);return o?new Promise(e=>{o.then(t=>{e(fi(t))})}):Promise.resolve(null)}processFilterModelUpdateQueue(){this.modelUpdates.forEach(({model:e,source:t})=>this.setModel(e,t)),this.modelUpdates=[],this.columnModelUpdates.forEach(({key:e,model:t,resolve:o})=>{this.setModelForColumn(e,t).then(()=>o())}),this.columnModelUpdates=[]}getModelForColumn(e,t){if(t){const{state:t,model:o}=this,i=e.getColId(),s=t.get(i);return s?s.model??null:ir(o,i)}const o=this.cachedFilter(e);return o?this.getModelFromFilterWrapper(o):null}setModelForColumn(e,t){if(this.beans.dataTypeSvc?.isPendingInference){let o=()=>{};const i=new Promise(e=>{o=e});return this.columnModelUpdates.push({key:e,model:t,resolve:o}),i}return new Promise(o=>{this.setModelForColumnLegacy(e,t).then(e=>o(e))})}getStateForColumn(e){return this.state.get(e)??{model:ir(this.model,e)}}setModelForColumnLegacy(e,t){const o=this.beans.colModel.getColDefCol(e),i=o?this.getOrCreateFilterWrapper(o,!0):null;return i?this.setModelOnFilterWrapper(i,t):Ko.resolve()}setColDefPropsForDataType(e,t,o){const i=e.filter,s=!0===i?this.getDefaultFilterFromDataType(()=>t.baseDataType):i;if("string"!=typeof s)return;let n,r;const a=this.beans,{filterParams:l,filterValueGetter:d}=e;({filterParams:n,filterValueGetter:r}="agMultiColumnFilter"===s?a.multiFilter?.getParamsForDataType(l,d,t,o)??{}:function(e,t,o,i,s,n,r){let a=t,l=o;const d="agSetColumnFilter"===e;l||"object"!==i.baseDataType||d||(l=({column:e,node:t})=>s({column:e,node:t,value:n.valueSvc.getValue(e,t)}));const h=(0,(d?vr:Cr)[i.baseDataType])({dataTypeDefinition:i,formatValue:s,t:r});return a="object"==typeof t?{...h,...t}:h,{filterParams:a,filterValueGetter:l}}(s,l,d,t,o,a,this.getLocaleTextFunc())),e.filterParams=n,r&&(e.filterValueGetter=r)}setColFilterActive(e,t,o,i){e.filterActive!==t&&(e.filterActive=t,e.dispatchColEvent("filterActiveChanged",o)),e.dispatchColEvent("filterChanged",o,i)}setModelOnFilterWrapper(e,t,o){return new Ko(i=>{if(e.isHandler){const s=e.column,n=s.getColId(),r=this.model[n];return this.updateStoredModel(n,t),o&&t===r?void i():void this.refreshHandlerAndUi(s,t,"api").then(()=>i())}const s=Xn(e);s?s.then(e=>{if("function"!=typeof e?.setModel)return st(65),void i();(e.setModel(t)||Ko.resolve()).then(()=>i())}):i()})}updateStoredModel(e,t){o(t)?this.model[e]=t:delete this.model[e];const i=this.state.get(e),s={model:t,state:i?.state};this.state.set(e,s)}filterModified(e,t){this.getOrCreateFilterUi(e)?.then(o=>{this.eventSvc.dispatchEvent({type:"filterModified",column:e,filterInstance:o,...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,o){const i=e.getColId(),s=this.cachedFilter(e),n=()=>s?.filterUi;or(t,n,()=>ir(this.model,i),()=>this.state.get(i),t=>this.updateState(e,t),e=>n()?.filterParams?.onModelChange(e,o),s?.isHandler?s.handler.processModelToApply?.bind(s.handler):void 0)}updateAllModels(e,t){const o=[];this.allColumnFilters.forEach((t,i)=>{const s=this.beans.colModel.getColDefCol(i);s&&or(e,()=>t.filterUi,()=>ir(this.model,i),()=>this.state.get(i),e=>this.updateState(s,e),t=>{this.updateStoredModel(i,t),this.dispatchLocalEvent({type:"filterAction",column:s,action:e}),o.push(this.refreshHandlerAndUi(s,t,"ui"))},t?.isHandler?t.handler.processModelToApply?.bind(t.handler):void 0)}),o.length&&Ko.all(o).then(()=>{this.callOnFilterChangedOutsideRenderCycle({source:"columnFilter",additionalEventAttributes:t,columns:[]})})}updateOrRefreshFilterUi(e){const t=e.getColId();tr(()=>this.cachedFilter(e)?.filterUi,()=>ir(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(){const{state:e,model:t,activeFilterComps:o}=this;for(const e of o)if("COLUMN_MENU"===e.source)return!1;let i=!1;for(const o of e.keys()){const s=e.get(o);if(!1===s.valid)return!1;(s.model??null)!==ir(t,o)&&(i=!0)}return i}hasUnappliedModel(e){const{model:t,state:o}=this;return(o.get(e)?.model??null)!==ir(t,e)}setGlobalButtons(e){this.isGlobalButtons=e,this.dispatchLocalEvent({type:"filterGlobalButtons",isGlobal:e})}shouldKeepStateOnDetach(e,t){if("newFiltersToolPanel"===t)return!0;const o=this.beans.filterPanelSvc;return!!o?.isActive&&!!o.getState(e.getColId())}destroy(){super.destroy(),this.allColumnFilters.forEach(e=>this.disposeFilterWrapper(e,"gridDestroyed")),this.allColumnListeners.clear(),this.state.clear(),this.activeFilterComps.clear()}},class extends Me{constructor(){super(...arguments),this.beanName="filterMenuFactory"}wireBeans(e){this.popupSvc=e.popupSvc}hideActiveMenu(){this.hidePopup?.()}showMenuAfterMouseEvent(e,t,o,i){e&&!e.isColumn||this.showPopup(e,i=>{this.popupSvc?.positionPopupUnderMouseEvent({column:e,type:o,mouseEvent:t,ePopup:i})},o,t.target,Ot(this.gos),i)}showMenuAfterButtonClick(e,t,o,i){if(e&&!e.isColumn)return;let s=-1,n="left";const r=Ot(this.gos);!r&&this.gos.get("enableRtl")&&(s=1,n="right");const a=r?void 0:4*s,l=r?void 0:4;this.showPopup(e,i=>{this.popupSvc?.positionPopupByComponent({type:o,eventSource:t,ePopup:i,nudgeX:a,nudgeY:l,alignSide:n,keepWithinBounds:!0,position:"under",column:e})},o,t,r,i)}showPopup(e,t,o,i,s,n){const r=e?this.createBean(new ur(e,"COLUMN_MENU")):void 0;if(this.activeMenu=r,!r?.hasFilter()||!e)return void nt(57);const a=sr({tag:"div",cls:"ag-menu"+(s?"":" ag-filter-menu"),role:"presentation"});let l;[this.tabListener]=this.addManagedElementListeners(a,{keydown:e=>this.trapFocusWithin(e,a)}),a.appendChild(r?.getGui());const d=Ot(this.gos)?void 0:i??this.beans.ctrlsSvc.getGridBodyCtrl().eGridBody;const h=this.getLocaleTextFunc(),c=s&&"columnFilter"!==o?h("ariaLabelColumnMenu","Column Menu"):h("ariaLabelColumnFilter","Column Filter"),u=this.popupSvc?.addPopup({modal:!0,eChild:a,closeOnEsc:!0,closedCallback:t=>{tl(e,!1,"contextMenu");const s=t instanceof KeyboardEvent;if(this.tabListener&&(this.tabListener=this.tabListener()),s&&i&&Q(i)){const e=Ss(i);e?.focus({preventScroll:!0})}r?.afterGuiDetached(),this.destroyBean(this.activeMenu),this.dispatchVisibleChangedEvent(!1,o,e),n?.()},positionCallback:()=>t(a),anchorToElement:d,ariaLabel:c});u&&(this.hidePopup=l=u.hideFunc),r.afterInit().then(()=>{t(a),r.afterGuiAttached({container:o,hidePopup:l})}),tl(e,!0,"contextMenu"),this.dispatchVisibleChangedEvent(!0,o,e)}trapFocusWithin(e,t){e.key!==Fi||e.defaultPrevented||ys(this.beans,t,!1,e.shiftKey)||(e.preventDefault(),bs(t,e.shiftKey))}dispatchVisibleChangedEvent(e,t,o){this.eventSvc.dispatchEvent({type:"columnMenuVisibleChanged",visible:e,switchingTab:!1,key:t,column:o??null,columnGroup:null})}isMenuEnabled(e){return e.isFilterAllowed()&&(e.getColDef().menuTabs??["filterMenuTab"]).includes("filterMenuTab")}showMenuAfterContextMenuEvent(){}destroy(){this.destroyBean(this.activeMenu),super.destroy()}}],dynamicBeans:{headerFilterCellCtrl:class extends Ya{constructor(){super(...arguments),this.iconCreated=!1}wireComp(e,t,o,i,s){this.comp=e;const n=Vo(this,this.beans.context,s);this.eButtonShowMainFilter=o,this.eFloatingFilterBody=i,this.setGui(t,n),this.setupActive(),this.refreshHeaderStyles(),this.setupWidth(n),this.setupLeft(n),this.setupHover(n),this.setupFocus(n),this.setupAria(),this.setupFilterButton(),this.setupUserComp(),this.setupSyncWithFilter(n),this.setupUi(),n.addManagedElementListeners(this.eButtonShowMainFilter,{click:this.showParentFilter.bind(this)}),this.setupFilterChangedListener(n);const r=()=>this.onColDefChanged(n);n.addManagedListeners(this.column,{colDefChanged:r}),n.addManagedEventListeners({filterSwitched:({column:e})=>{e===this.column&&r()}}),n.addDestroyFunc(()=>{this.eButtonShowMainFilter=null,this.eFloatingFilterBody=null,this.userCompDetails=null,this.clearComponent()})}resizeHeader(){}moveHeader(){}getHeaderClassParams(){const{column:e,beans:t}=this,o=e.colDef;return zt(t.gos,{colDef:o,column:e,floatingFilter:!0})}setupActive(){const e=this.column.getColDef(),t=!!e.filter,o=!!e.floatingFilter;this.active=t&&o}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;const e=al("filter",this.beans,this.column);e&&(this.iconCreated=!0,this.eButtonShowMainFilter.appendChild(e))}setupFocus(e){e.createManagedBean(new Dr(this.eGui,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)}))}setupAria(){const e=this.getLocaleTextFunc();S(this.eButtonShowMainFilter,e("ariaFilterMenuOpen","Open Filter Menu"))}onTabKeyDown(e){const{beans:t}=this;if(u(t)===this.eGui)return;const o=ys(t,this.eGui,null,e.shiftKey);if(o)return t.headerNavigation?.scrollToColumn(this.column),e.preventDefault(),void o.focus();const i=this.findNextColumnWithFloatingFilter(e.shiftKey);i&&t.focusSvc.focusHeaderPosition({headerPosition:{headerRowIndex:this.rowCtrl.rowIndex,column:i},event:e})&&e.preventDefault()}findNextColumnWithFloatingFilter(e){const t=this.beans.visibleCols;let o=this.column;do{if(o=e?t.getColBefore(o):t.getColAfter(o),!o)break}while(!o.getColDef().filter||!o.getColDef().floatingFilter);return o}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();switch(e.key){case Ti:case Ai:case ki:case Ii:if(t)return;Fr(e);case Pi:t&&bs(this.eGui)&&e.preventDefault();break;case Di:t||this.eGui.focus()}}onFocusIn(e){if(this.eGui.contains(e.relatedTarget))return;const t=!!e.relatedTarget&&!e.relatedTarget.classList.contains("ag-floating-filter"),o=!!e.relatedTarget&&G(e.relatedTarget,"ag-floating-filter");if(t&&o&&e.target===this.eGui){const e=this.lastFocusEvent,t=!(!e||e.key!==Fi);if(e&&t){const t=e.shiftKey;bs(this.eGui,t)}}this.focusThis()}setupHover(e){this.beans.colHover?.addHeaderFilterColumnHoverListener(e,this.comp,this.column,this.eGui)}setupLeft(e){const t=new ja(this.column,this.eGui,this.beans);e.createManagedBean(t)}setupFilterButton(){this.suppressFilterButton=!this.beans.menuSvc?.isFloatingFilterButtonEnabled(this.column),this.highlightFilterButtonWhenActive=!Ot(this.gos)}setupUserComp(){if(!this.active)return;const e=this.beans.colFilter?.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter());e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setCompDetails(e)}showParentFilter(){const 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;const{beans:{colFilter:t},column:o,gos:i}=this,s=e=>{if(!("filterDestroyed"!==e?.source||this.isAlive()&&t?.isAlive()))return;const s=this.comp.getFloatingFilterComp();s&&s.then(s=>{if(s){if(i.get("enableFilterHandlers")){const t=e;let o="filter";return t?.afterFloatingFilter?o="ui":t?.afterDataChange?o="dataChanged":"api"===e?.source&&(o="api"),void this.updateFloatingFilterParams(this.userCompDetails,o)}const n=t?.getCurrentFloatingFilterParentModel(o),r=e?{...e,columns:e.columns??[],source:"api"===e.source?"api":"columnFilter"}:null;s.onParentModelChanged(n,r)}})};[this.destroySyncListener]=e.addManagedListeners(o,{filterChanged:s}),t?.isFilterActive(o)&&s(null)}setupWidth(e){const t=()=>{const 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){const 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){const t=this.active;this.setupActive();const o=!t&&this.active;t&&!this.active&&(this.destroySyncListener(),this.destroyFilterChangedListener());const i=this.beans.colFilter,s=this.active?i?.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter()):null,n=this.comp.getFloatingFilterComp();n&&s?n.then(t=>{!t||i?.areFilterCompsDifferent(this.userCompDetails??null,s)?this.updateCompDetails(e,s,o):this.updateFloatingFilterParams(s,"colDef")}):this.updateCompDetails(e,s,o)}updateCompDetails(e,t,o){this.isAlive()&&(this.setCompDetails(t),this.setupFilterButton(),this.setupUi(),o&&(this.setupSyncWithFilter(e),this.setupFilterChangedListener(e)))}updateFloatingFilterParams(e,t){if(!e)return;let o=e.params;this.comp.getFloatingFilterComp()?.then(e=>{"function"==typeof e?.refresh&&(this.gos.get("enableFilterHandlers")&&(o={...o,model:ir(this.beans.colFilter?.model??{},this.column.getColId()),source:t}),e.refresh(o))})}addResizeAndMoveKeyboardListeners(){}destroy(){super.destroy(),this.destroySyncListener=null,this.destroyFilterChangedListener=null}}},icons:{filter:"filter",filterActive:"filter"},apiFunctions:{isColumnFilterPresent:function(e){const 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){const o=e.colModel.getColDefCol(t);if(o)return e.colFilter?.destroyFilter(o,"api")},setFilterModel:function(e,t){e.frameworkOverrides.wrapIncoming(()=>e.filterManager?.setFilterModel(t))},getFilterModel:function(e){return e.filterManager?.getFilterModel()??{}},getColumnFilterModel:function(e,t,o){const{gos:i,colModel:s,colFilter:n}=e;o&&!i.get("enableFilterHandlers")&&(st(288),o=!1);const r=s.getColDefCol(t);return r?n?.getModelForColumn(r,o)??null:null},setColumnFilterModel:function(e,t,o){return e.filterManager?.setColumnFilterModel(t,o)??Promise.resolve()},showColumnFilter:function(e,t){const o=e.colModel.getCol(t);o?e.menuSvc?.showFilterMenu({column:o,containerType:"columnFilter",positionBy:"auto"}):nt(12,{colKey:t})},hideColumnFilter:function(e){e.menuSvc?.hideFilterMenu()},getColumnFilterHandler:function(e,t){const o=e.colModel.getCol(t);if(o)return e.colFilter?.getHandler(o,!0);nt(12,{colKey:t})},doFilterAction:function(e,t){const{colModel:o,colFilter:i,gos:s}=e;if(!s.get("enableFilterHandlers"))return void st(287);const{colId:n,action:r}=t;if(n){const e=o.getColById(n);e&&i?.updateModel(e,r)}else i?.updateAllModels(r)}},dependsOn:[wp,Lg,bp,Ag]},Sp={moduleName:"CustomFilter",version:qe,userComponents:{agReadOnlyFloatingFilter:class extends Uo{constructor(){super(Hg,[Is]),this.eFloatingFilterText=Go}init(e){this.params=e;const t=this.beans.colNames.getDisplayNameForColumn(e.column,"header",!0);if(this.eFloatingFilterText.setDisabled(!0).setInputAriaLabel(`${t} ${this.getLocaleTextFunc()("ariaFilterInput","Filter Input")}`),this.gos.get("enableFilterHandlers")){const t=e,o=t.getHandler();if(o.getModelAsString){const e=o.getModelAsString(t.model);this.eFloatingFilterText.setValue(e)}}}onParentModelChanged(e){null!=e?this.params.parentFilterInstance(t=>{if(t.getModelAsString){const o=t.getModelAsString(e);this.eFloatingFilterText.setValue(o)}}):this.eFloatingFilterText.setValue("")}refresh(e){this.init(e)}}},dependsOn:[yp]},Ep={moduleName:"TextFilter",version:qe,dependsOn:[yp],userComponents:{agTextColumnFilter:{classImp:class extends zg{constructor(){super("textFilter",dp,gp),this.filterType="text",this.eValuesFrom=[],this.eValuesTo=[],this.defaultDebounceMs=500}createCondition(e){const t=this.getConditionType(e),o={filterType:this.filterType,type:t},i=this.getValues(e);return i.length>0&&(o.filter=i[0]),i.length>1&&(o.filterTo=i[1]),o}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}getInputs(e){const{eValuesFrom:t,eValuesTo:o}=this;return e>=t.length?[null,null]:[t[e],o[e]]}getValues(e){const o=[];return this.forEachPositionInput(e,(e,i,s,n)=>{i<n&&o.push(t(e.getValue()))}),o}createEValue(){const e=sr({tag:"div",cls:"ag-filter-body",role:"presentation"}),{eValuesFrom:t,eValuesTo:o}=this;return this.createFromToElement(e,t,"from"),this.createFromToElement(e,o,"to"),e}createFromToElement(e,t,o){const i=this.createManagedBean(new Ts);i.addCss(`ag-filter-${o}`),i.addCss("ag-filter-filter"),t.push(i),e.appendChild(i.getGui())}removeEValues(e,t){const o=o=>this.removeComponents(o,e,t),{eValuesFrom:i,eValuesTo:s}=this;o(i),o(s)}},params:{useForm:!0}},agTextColumnFloatingFilter:class extends cp{constructor(){super(...arguments),this.FilterModelFormatterClass=pp,this.filterType="text",this.defaultOptions=gp}createFloatingFilterInputService(){return this.createManagedBean(new ap)}}},dynamicBeans:{agTextColumnFilterHandler:class extends jg{constructor(){super(dp,gp),this.filterType="text",this.FilterModelFormatterClass=pp}updateParams(e){super.updateParams(e);const t=e.filterParams;this.matcher=t.textMatcher??mp,this.formatter=t.textFormatter??(t.caseSensitive?fp:Cp)}evaluateNullValue(e){return!!e&&["notEqual","notContains","blank"].indexOf(e)>=0}evaluateNonNullValue(e,t,o,i){const s=e.map(e=>this.formatter(e))||[],n=this.formatter(t),{api:r,colDef:a,column:l,context:d,filterParams:{textFormatter:h}}=this.params;if("blank"===o.type)return Ng(t);if("notBlank"===o.type)return!Ng(t);const c={api:r,colDef:a,column:l,context:d,node:i.node,data:i.data,filterOption:o.type,value:n,textFormatter:h};return s.some(e=>this.matcher({...c,filterText:e}))}processModelToApply(e){if(e&&this.params.filterParams.trimInput){const t=e=>{const t={...e},{filter:o,filterTo:i}=e;return o&&(t.filter=lp(o)??null),i&&(t.filterTo=lp(i)??null),t};return kr(e)?{...e,conditions:e.conditions.map(t)}:t(e)}return e}}}},Rp={moduleName:"NumberFilter",version:qe,dependsOn:[yp],userComponents:{agNumberColumnFilter:{classImp:class extends zg{constructor(){super("numberFilter",np,op),this.eValuesFrom=[],this.eValuesTo=[],this.filterType="number",this.defaultDebounceMs=500}setElementValue(e,t,o){const{numberFormatter:i}=this.params,s=!o&&i?i(t??null):t;super.setElementValue(e,s)}createEValue(){const e=ip(this.params),t=sr({tag:"div",cls:"ag-filter-body",role:"presentation"});return this.createFromToElement(t,this.eValuesFrom,"from",e),this.createFromToElement(t,this.eValuesTo,"to",e),t}createFromToElement(e,t,o,i){const s=this.createManagedBean(i?new Ts({allowedCharPattern:i}):new Ls);s.addCss(`ag-filter-${o}`),s.addCss("ag-filter-filter"),t.push(s),e.appendChild(s.getGui())}removeEValues(e,t){const o=o=>this.removeComponents(o,e,t);o(this.eValuesFrom),o(this.eValuesTo)}getValues(e){const t=[];return this.forEachPositionInput(e,(e,o,i,s)=>{o<s&&t.push(sp(this.stringToFloat(e.getValue())))}),t}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}stringToFloat(e){if("number"==typeof e)return e;let o=t(e);null!=o&&""===o.trim()&&(o=null);const i=this.params.numberParser;return i?i(o):null==o||"-"===o.trim()?null:parseFloat(o)}createCondition(e){const t=this.getConditionType(e),o={filterType:this.filterType,type:t},i=this.getValues(e);return i.length>0&&(o.filter=i[0]),i.length>1&&(o.filterTo=i[1]),o}getInputs(e){const{eValuesFrom:t,eValuesTo:o}=this;return e>=t.length?[null,null]:[t[e],o[e]]}hasInvalidInputs(){let e=!1;return this.forEachInput(t=>{t.getInputElement().validity.valid||(e=!0)}),e}},params:{useForm:!0}},agNumberColumnFloatingFilter:class extends cp{constructor(){super(...arguments),this.FilterModelFormatterClass=rp,this.filterType="number",this.defaultOptions=op}updateParams(e){ip(e.filterParams)!==this.allowedCharPattern&&this.recreateFloatingFilterInputService(e),super.updateParams(e)}createFloatingFilterInputService(e){return this.allowedCharPattern=ip(e.filterParams),this.allowedCharPattern?this.createManagedBean(new ap({config:{allowedCharPattern:this.allowedCharPattern}})):this.createManagedBean(new up)}convertValue(e){return e?Number(e):null}}},dynamicBeans:{agNumberColumnFilterHandler:class extends qg{constructor(){super(np,op),this.filterType="number",this.FilterModelFormatterClass=rp}comparator(){return(e,t)=>e===t?0:e<t?1:-1}isValid(e){return!isNaN(e)}}}},xp={moduleName:"DateFilter",version:qe,dependsOn:[yp],userComponents:{agDateColumnFilter:{classImp:class extends zg{constructor(){super("dateFilter",$g,Ug),this.eConditionPanelsFrom=[],this.eConditionPanelsTo=[],this.dateConditionFromComps=[],this.dateConditionToComps=[],this.minValidYear=1e3,this.maxValidYear=Kg,this.minValidDate=null,this.maxValidDate=null,this.filterType="date"}afterGuiAttached(e){super.afterGuiAttached(e),this.dateConditionFromComps[0].afterGuiAttached(e)}commonUpdateSimpleParams(e){super.commonUpdateSimpleParams(e);const t=(t,o)=>{const i=e[t];if(null!=i){if(!isNaN(i))return null==i?o:Number(i);st(82,{param:t})}return o},o=t("minValidYear",1e3),i=t("maxValidYear",Kg);this.minValidYear=o,this.maxValidYear=i,o>i&&st(83);const{minValidDate:s,maxValidDate:n}=e,r=s instanceof Date?s:cs(s);this.minValidDate=r;const a=n instanceof Date?n:cs(n);this.maxValidDate=a,r&&a&&r>a&&st(84)}createDateCompWrapper(e){const{beans:{userCompFactory:t,context:o,gos:i},params:s}=this,n=new Wg(o,t,s.colDef,zt(i,{onDateChanged:()=>this.onUiChanged(),filterParams:s,location:"filter"}),e);return this.addDestroyFunc(()=>n.destroy()),n}setElementValue(e,t){e.setDate(t)}setElementDisplayed(e,t){e.setDisplayed(t)}setElementDisabled(e,t){e.setDisabled(t)}createEValue(){const e=sr({tag:"div",cls:"ag-filter-body"});return this.createFromToElement(e,this.eConditionPanelsFrom,this.dateConditionFromComps,"from"),this.createFromToElement(e,this.eConditionPanelsTo,this.dateConditionToComps,"to"),e}createFromToElement(e,t,o,i){const s=sr({tag:"div",cls:`ag-filter-${i} ag-filter-date-${i}`});t.push(s),e.appendChild(s),o.push(this.createDateCompWrapper(s))}removeEValues(e,t){this.removeDateComps(this.dateConditionFromComps,e,t),this.removeDateComps(this.dateConditionToComps,e,t),Gg(this.eConditionPanelsFrom,e,t),Gg(this.eConditionPanelsTo,e,t)}removeDateComps(e,t,o){Gg(e,t,o).forEach(e=>e.destroy())}isValidDateValue(e){if(null===e)return!1;const{minValidDate:t,maxValidDate:o,minValidYear:i,maxValidYear:s}=this;if(t){if(e<t)return!1}else if(e.getUTCFullYear()<i)return!1;if(o){if(e>o)return!1}else if(e.getUTCFullYear()>s)return!1;return!0}isConditionUiComplete(e){if(!super.isConditionUiComplete(e))return!1;let t=!0;return this.forEachInput((o,i,s,n)=>{s!==e||!t||i>=n||(t=t&&this.isValidDateValue(o.getDate()))}),t}areSimpleModelsEqual(e,t){return e.dateFrom===t.dateFrom&&e.dateTo===t.dateTo&&e.type===t.type}createCondition(e){const t=this.getConditionType(e),o={},i=this.getValues(e),s=this.params.useIsoSeparator?"T":" ";return i.length>0&&(o.dateFrom=ss(i[0],!0,s)),i.length>1&&(o.dateTo=ss(i[1],!0,s)),{dateFrom:null,dateTo:null,filterType:this.filterType,type:t,...o}}resetPlaceholder(){const e=this.getLocaleTextFunc(),t=this.translate("dateFormatOoo"),o=e("ariaFilterValue","Filter Value");this.forEachInput(e=>{e.setInputPlaceholder(t),e.setInputAriaLabel(o)})}getInputs(e){const{dateConditionFromComps:t,dateConditionToComps:o}=this;return e>=t.length?[null,null]:[t[e],o[e]]}getValues(e){const t=[];return this.forEachPositionInput(e,(e,o,i,s)=>{o<s&&t.push(e.getDate())}),t}translate(e){return"lessThan"===e?super.translate("before"):"greaterThan"===e?super.translate("after"):super.translate(e)}},params:{useForm:!0}},agDateInput:class extends Uo{constructor(){super(tp,[Is]),this.eDateInput=Go,this.isApply=!1,this.applyOnFocusOut=!1}init(e){this.params=e,this.setParams(e);const t=this.eDateInput.getInputElement();this.addManagedListeners(t,{mouseDown:()=>{this.eDateInput.isDisabled()||this.usingSafariDatePicker||t.focus({preventScroll:!0})},input:this.handleInput.bind(this,!1),change:this.handleInput.bind(this,!0),focusout:this.handleFocusOut.bind(this)})}handleInput(e){if(!this.eDateInput.isDisabled())return this.isApply?(this.applyOnFocusOut=!e,void(e&&this.params.onDateChanged())):void(e||this.params.onDateChanged())}handleFocusOut(){this.applyOnFocusOut&&(this.applyOnFocusOut=!1,this.params.onDateChanged())}setParams(e){const t=this.eDateInput.getInputElement(),o=this.shouldUseBrowserDatePicker(e);this.usingSafariDatePicker=o&&_i();const{minValidYear:i,maxValidYear:s,minValidDate:n,maxValidDate:r,buttons:a,includeTime:l,colDef:d}=e.filterParams||{},h=this.beans.dataTypeSvc,c=l??h?.getDateIncludesTimeFlag?.(d.cellDataType)??!1;if(o?c?(t.type="datetime-local",t.step="1"):t.type="date":t.type="text",n&&i&&st(85),r&&s&&st(86),n&&r){const[e,t]=[n,r].map(e=>e instanceof Date?e:cs(e));e&&t&&e.getTime()>t.getTime()&&st(87)}n?n instanceof Date?t.min=ds(n):t.min=n:i&&(t.min=`${i}-01-01`),r?r instanceof Date?t.max=ds(r):t.max=r:s&&(t.max=`${s}-12-31`),this.isApply="floatingFilter"===e.location&&!!a?.includes("apply")}refresh(e){this.params=e,this.setParams(e)}getDate(){return cs(this.eDateInput.getValue())}setDate(e){const t=this.params.filterParams.colDef.cellDataType,o=this.beans.dataTypeSvc?.getDateIncludesTimeFlag(t)??!1;this.eDateInput.setValue(ss(e,o))}setInputPlaceholder(e){this.eDateInput.setInputPlaceholder(e)}setInputAriaLabel(e){this.eDateInput.setAriaLabel(e)}setDisabled(e){this.eDateInput.setDisabled(e)}afterGuiAttached(e){e&&e.suppressFocus||this.eDateInput.getInputElement().focus({preventScroll:!0})}shouldUseBrowserDatePicker(e){return e?.filterParams?.browserDatePicker??!0}},agDateColumnFloatingFilter:class extends Xg{constructor(){super(ep,[Is]),this.eReadOnlyText=Go,this.eDateWrapper=Go,this.FilterModelFormatterClass=Zg,this.filterType="date",this.defaultOptions=Ug}setParams(e){super.setParams(e),this.createDateComponent();const t=this.getLocaleTextFunc();this.eReadOnlyText.setDisabled(!0).setInputAriaLabel(t("ariaDateFilterInput","Date Filter Input"))}updateParams(e){super.updateParams(e),this.dateComp.updateParams(this.getDateComponentParams()),this.updateCompOnModelChange(e.currentParentModel())}updateCompOnModelChange(e){const t=!this.readOnly&&this.canWeEditAfterModelFromParentFilter(e);if(this.setEditable(t),t){const t=e?cs(e.dateFrom):null;this.dateComp.setDate(t),this.eReadOnlyText.setValue("")}else this.eReadOnlyText.setValue(this.filterModelFormatter.getModelAsString(e)),this.dateComp.setDate(null)}setEditable(e){H(this.eDateWrapper,e),H(this.eReadOnlyText.getGui(),!e)}onModelUpdated(e){super.setLastTypeFromModel(e),this.updateCompOnModelChange(e)}onDateChanged(){const e=this.dateComp.getDate();if(this.reactive){const t=this.params;t.onUiChange();const o=t.model,i=ss(e),s=null==i?null:{...o??{filterType:this.filterType,type:this.lastType??this.optionsFactory.defaultOption},dateFrom:i};t.onModelChange(s,{afterFloatingFilter:!0})}else this.params.parentFilterInstance(t=>{t?.onFloatingFilterChanged(this.lastType||null,e)})}getDateComponentParams(){const{filterParams:e}=this.params,t=lr(e,this.defaultDebounceMs);return zt(this.gos,{onDateChanged:Be(this,this.onDateChanged.bind(this),t),filterParams:e,location:"floatingFilter"})}createDateComponent(){const{beans:{context:e,userCompFactory:t},eDateWrapper:o,params:i}=this;this.dateComp=new Wg(e,t,i.column.getColDef(),this.getDateComponentParams(),o,e=>{e.setInputAriaLabel(this.getAriaLabel(i))}),this.addDestroyFunc(()=>this.dateComp.destroy())}}},dynamicBeans:{agDateColumnFilterHandler:class extends qg{constructor(){super($g,Ug),this.filterType="date",this.FilterModelFormatterClass=Zg}comparator(){return this.params.filterParams.comparator??Jg}isValid(e){const t=this.params.filterParams.isValidDate;return!t||t(e)}}}},Fp={moduleName:"QuickFilter",version:qe,apiFunctions:{isQuickFilterPresent:function(e){return!!e.quickFilter?.isFilterPresent()},getQuickFilter:function(e){return e.quickFilter?.getText()},resetQuickFilter:function(e){e.quickFilter?.resetCache()}},dependsOn:[{moduleName:"QuickFilterCore",version:qe,rowModels:["clientSide"],beans:[class extends Me{constructor(){super(...arguments),this.beanName="quickFilter",this.quickFilter=null,this.quickFilterParts=null}postConstruct(){const e=this.resetCache.bind(this),t=this.gos;this.addManagedEventListeners({columnPivotModeChanged:e,newColumnsLoaded:e,columnRowGroupChanged:e,columnVisible:()=>{t.get("includeHiddenColumnsInQuickFilter")||this.resetCache()}}),this.addManagedPropertyListener("quickFilterText",e=>this.setFilter(e.currentValue)),this.addManagedPropertyListeners(["includeHiddenColumnsInQuickFilter","applyQuickFilterBeforePivotOrAgg"],()=>this.onColumnConfigChanged()),this.quickFilter=this.parseFilter(t.get("quickFilterText")),this.parser=t.get("quickFilterParser"),this.matcher=t.get("quickFilterMatcher"),this.setFilterParts(),this.addManagedPropertyListeners(["quickFilterMatcher","quickFilterParser"],()=>this.setParserAndMatcher())}refreshCols(){const{autoColSvc:e,colModel:t,gos:o,pivotResultCols:i}=this.beans,s=t.isPivotMode(),n=e?.getColumns(),r=t.getColDefCols();let a=(s&&!o.get("applyQuickFilterBeforePivotOrAgg")?i?.getPivotResultCols()?.list:r)??[];n&&(a=a.concat(n)),this.colsToUse=o.get("includeHiddenColumnsInQuickFilter")?a:a.filter(e=>e.isVisible()||e.isRowGroupActive())}isFilterPresent(){return null!==this.quickFilter}doesRowPass(e){const t=this.gos.get("cacheQuickFilter");return this.matcher?this.doesRowPassMatcher(t,e):this.quickFilterParts.every(o=>t?this.doesRowPassCache(e,o):this.doesRowPassNoCache(e,o))}resetCache(){this.beans.rowModel.forEachNode(e=>e.quickFilterAggregateText=null)}getText(){return this.gos.get("quickFilterText")}setFilterParts(){const{quickFilter:e,parser:t}=this;this.quickFilterParts=e?t?t(e):e.split(" "):null}parseFilter(e){return o(e)?e.toUpperCase():null}setFilter(e){if(null!=e&&"string"!=typeof e)return void st(70,{newFilter:e});const t=this.parseFilter(e);this.quickFilter!==t&&(this.quickFilter=t,this.setFilterParts(),this.dispatchLocalEvent({type:"quickFilterChanged"}))}setParserAndMatcher(){const e=this.gos.get("quickFilterParser"),t=this.gos.get("quickFilterMatcher"),o=e!==this.parser||t!==this.matcher;this.parser=e,this.matcher=t,o&&(this.setFilterParts(),this.dispatchLocalEvent({type:"quickFilterChanged"}))}onColumnConfigChanged(){this.refreshCols(),this.resetCache(),this.isFilterPresent()&&this.dispatchLocalEvent({type:"quickFilterChanged"})}doesRowPassNoCache(e,t){return this.colsToUse.some(i=>{const s=this.getTextForColumn(i,e);return o(s)&&s.indexOf(t)>=0})}doesRowPassCache(e,t){return this.checkGenerateAggText(e),e.quickFilterAggregateText.indexOf(t)>=0}doesRowPassMatcher(e,t){let o;e?(this.checkGenerateAggText(t),o=t.quickFilterAggregateText):o=this.getAggText(t);const{quickFilterParts:i,matcher:s}=this;return s(i,o)}checkGenerateAggText(e){e.quickFilterAggregateText||(e.quickFilterAggregateText=this.getAggText(e))}getTextForColumn(e,t){let i=this.beans.filterValueSvc.getValue(e,t);const s=e.getColDef();if(s.getQuickFilterText){const o=zt(this.gos,{value:i,node:t,data:t.data,column:e,colDef:s});i=s.getQuickFilterText(o)}return o(i)?i.toString().toUpperCase():null}getAggText(e){const t=[];return this.colsToUse.forEach(i=>{const s=this.getTextForColumn(i,e);o(s)&&t.push(s)}),t.join("\n")}}],dependsOn:[wp,bp]}]},Pp={moduleName:"ExternalFilter",version:qe,dependsOn:[wp]},Dp=(e,t,o)=>{const{editModelSvc:i}=e,s=i?.getCellValidationModel()?.getCellValidation(t)?.errorMessages,n=i?.getRowValidationModel().getRowValidation(t)?.errorMessages,r=s||n;return r&&r.length?r.join(o("tooltipValidationErrorSeparator",". ")):void 0},Mp={moduleName:"Tooltip",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="tooltipSvc"}setupHeaderTooltip(e,t,o,i){e&&t.destroyBean(e);const s=Cg(this.gos),{column:n,eGui:r}=t,a=n.getColDef();i||!s||a.headerComponent||(i=oe(()=>r.querySelector(".ag-header-cell-text")));const l={getGui:()=>r,getLocation:()=>"header",getTooltipValue:()=>{if(null!=o)return o;return n.getColDef().headerTooltip},shouldDisplayTooltip:i,getAdditionalParams:()=>({column:n,colDef:n.getColDef()})};let d=this.createTooltipFeature(l);return d&&(d=t.createBean(d),t.setRefreshFunction("tooltip",()=>d.refreshTooltip())),d}setupHeaderGroupTooltip(e,t,o,i){e&&t.destroyBean(e);const s=Cg(this.gos),{column:n,eGui:r}=t,a=n.getColGroupDef();i||!s||a?.headerGroupComponent||(i=oe(()=>r.querySelector(".ag-header-group-text")));const l={getGui:()=>r,getLocation:()=>"headerGroup",getTooltipValue:()=>o??(a&&a.headerTooltip),shouldDisplayTooltip:i,getAdditionalParams:()=>{const e={column:n};return a&&(e.colDef=a),e}},d=this.createTooltipFeature(l);return d?t.createBean(d):d}enableCellTooltipFeature(e,t,i){const{beans:s}=this,{gos:n,editSvc:r}=s,{column:a,rowNode:l}=e;let d="cell";const h=Cg(n);i||(i=h&&!e.isCellRenderer()?()=>{const t=!!r?.isEditing(e);if(!t&&Dp(s,e,this.getLocaleTextFunc()))return!0;if(!a.isTooltipEnabled())return!1;const o=oe(()=>{const t=e.eGui;return 0===t.children.length?t:t.querySelector(".ag-cell-value")});return!t&&o()}:()=>!r?.isEditing(e));const c={getGui:()=>e.eGui,getLocation:()=>d,getTooltipValue:null!=t?()=>t:()=>{const t=!!!r?.isEditing(e)&&Dp(s,e,this.getLocaleTextFunc());if(t)return d="cellEditor",t;d="cell";const i=a.getColDef(),h=l.data;if(i.tooltipField&&o(h))return lh(h,i.tooltipField,a.isTooltipFieldContainsDots());const c=i.tooltipValueGetter;return c?c(zt(n,{location:"cell",colDef:a.getColDef(),column:a,rowIndex:e.cellPosition.rowIndex,node:l,data:l.data,value:e.value,valueFormatted:e.valueFormatted})):null},shouldDisplayTooltip:i,getAdditionalParams:()=>({column:a,colDef:a.getColDef(),rowIndex:e.cellPosition.rowIndex,node:l,data:l.data,valueFormatted:e.valueFormatted})};return this.createTooltipFeature(c,s)}setupFullWidthRowTooltip(e,t,o,i){const s={getGui:()=>t.getFullWidthElement(),getTooltipValue:()=>o,getLocation:()=>"fullWidthRow",shouldDisplayTooltip:i},n=this.beans,r=n.context;e&&t.destroyBean(e,r);const a=this.createTooltipFeature(s,n);if(a)return t.createBean(a,r)}setupCellEditorTooltip(e,t){const{beans:o}=this,{context:i}=o,s=t.getValidationElement?.(!0)||!t.isPopup?.()&&e.eGui;if(!s)return;const n={getGui:()=>s,getTooltipValue:()=>Dp(o,e,this.getLocaleTextFunc()),getLocation:()=>"cellEditor",shouldDisplayTooltip:()=>{const{editModelSvc:e}=o,t=e?.getRowValidationModel()?.getRowValidationMap(),i=e?.getCellValidationModel()?.getCellValidationMap(),s=!!t&&t.size>0,n=!!i&&i.size>0;return s||n}},r=this.createTooltipFeature(n,o);return r?e.createBean(r,i):void 0}initCol(e){const{colDef:t}=e;e.tooltipEnabled=o(t.tooltipField)||o(t.tooltipValueGetter)||o(t.tooltipComponent)}createTooltipFeature(e,t){return this.beans.registry.createDynamicBean("tooltipFeature",!1,e,t)}}],dynamicBeans:{tooltipFeature:Ln,highlightTooltipFeature:class extends Ln{constructor(e,t,o){super(e,o),this.highlightTracker=t,this.onHighlight=this.onHighlight.bind(this)}postConstruct(){super.postConstruct(),this.wireHighlightListeners()}wireHighlightListeners(){this.addManagedPropertyListener("tooltipTrigger",({currentValue:e})=>{this.setTooltipMode(e)}),this.setTooltipMode(this.gos.get("tooltipTrigger")),this.highlightTracker.addEventListener("itemHighlighted",this.onHighlight)}onHighlight(e){1===this.tooltipMode&&(e.highlighted?this.attemptToShowTooltip():this.attemptToHideTooltip())}setTooltipMode(e="focus"){this.tooltipMode="focus"===e?1:0}destroy(){this.highlightTracker.removeEventListener("itemHighlighted",this.onHighlight),super.destroy()}},tooltipStateManager:class extends Hn{createTooltipComp(e,t){const o=function(e,t){return e.getCompDetails(t.colDef,si,"agTooltipComponent",t,!0)}(this.beans.userCompFactory,e);o?.newAgStackInstance().then(t)}setEventHandlers(e){[this.onColumnMovedEventCallback]=this.addManagedEventListeners({columnMoved:e})}clearEventHandlers(){this.onColumnMovedEventCallback?.(),this.onColumnMovedEventCallback=void 0}}},userComponents:{agTooltipComponent:class extends qi{constructor(){super({tag:"div",cls:"ag-tooltip"})}init(e){const{value:t}=e,o=this.getGui();o.textContent=d(t);const i=e.location.replace(/([a-z])([A-Z0-9])/g,"$1-$2").toLowerCase();o.classList.add(`ag-${i}-tooltip`)}}},dependsOn:[Lg],css:[".ag-tooltip{background-color:var(--ag-tooltip-background-color);border:var(--ag-tooltip-border);border-radius:var(--ag-border-radius);color:var(--ag-tooltip-text-color);padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding);position:absolute;white-space:normal;z-index:99999;&:where(.ag-cell-editor-tooltip){background-color:var(--ag-tooltip-error-background-color);border:var(--ag-tooltip-error-border);color:var(--ag-tooltip-error-text-color);font-weight:500}}.ag-tooltip-custom{position:absolute;z-index:99999}.ag-tooltip-custom:where(:not(.ag-tooltip-interactive)),.ag-tooltip:where(:not(.ag-tooltip-interactive)){pointer-events:none}.ag-tooltip-animate{transition:opacity 1s;&:where(.ag-tooltip-hiding){opacity:0}}"]},kp=class{constructor(e){this.cellValueChanges=e}},Tp=class extends kp{constructor(e,t,o,i){super(e),this.initialRange=t,this.finalRange=o,this.ranges=i}},Ip=class{constructor(e){this.actionStack=[],this.maxStackSize=e||10,this.actionStack=new Array(this.maxStackSize)}pop(){return this.actionStack.pop()}push(e){e.cellValueChanges&&e.cellValueChanges.length>0&&(this.actionStack.length===this.maxStackSize&&this.actionStack.shift(),this.actionStack.push(e))}clear(){this.actionStack=[]}getCurrentStackSize(){return this.actionStack.length}},Ap={tag:"div",cls:"ag-cell-wrapper ag-cell-edit-wrapper ag-checkbox-edit",children:[{tag:"ag-checkbox",ref:"eEditor",role:"presentation"}]},Lp=class extends il{constructor(e){super(),this.cellEditorInput=e,this.eEditor=Go}initialiseEditor(e){const{cellEditorInput:t}=this;this.setTemplate({tag:"div",cls:"ag-cell-edit-wrapper",children:[t.getTemplate()]},t.getAgComponents());const{eEditor:o}=this,{cellStartedEdit:i,eventKey:s,suppressPreventDefault:n}=e;let r;o.getInputElement().setAttribute("title",""),t.init(o,e);let a=!0;i?(this.focusAfterAttached=!0,s===xi||s===Li?r="":s&&1===s.length?n?a=!1:r=s:(r=t.getStartValue(),s!==Bi&&(this.highlightAllOnFocus=!0))):(this.focusAfterAttached=!1,r=t.getStartValue()),a&&null!=r&&o.setStartValue(r),this.addGuiEventListener("keydown",e=>{const{key:t}=e;t!==Hi&&t!==Vi||e.preventDefault()})}afterGuiAttached(){const e=this.getLocaleTextFunc(),t=this.eEditor;if(t.setInputAriaLabel(e("ariaInputEditor","Input Editor")),!this.focusAfterAttached)return;_i()||t.getFocusableElement().focus();const o=t.getInputElement();this.highlightAllOnFocus?o.select():this.cellEditorInput.setCaret?.()}focusIn(){const{eEditor:e}=this,t=e.getFocusableElement(),o=e.getInputElement();t.focus(),o.select()}getValue(){return this.cellEditorInput.getValue()}isPopup(){return!1}getValidationElement(){return this.eEditor.getInputElement()}getValidationErrors(){return this.cellEditorInput.getValidationErrors()}},Bp={tag:"ag-input-date-field",ref:"eEditor",cls:"ag-cell-editor"},Hp=class{constructor(e,t){this.getDataTypeService=e,this.getLocaleTextFunc=t}getTemplate(){return Bp}getAgComponents(){return[Hs]}init(e,t){this.eEditor=e,this.params=t;const{min:o,max:i,step:s,colDef:n}=t;null!=o&&e.setMin(o),null!=i&&e.setMax(i),null!=s&&e.setStep(s),this.includeTime=t.includeTime??this.getDataTypeService()?.getDateIncludesTimeFlag?.(n.cellDataType),null!=this.includeTime&&e.setIncludeTime(this.includeTime)}getValidationErrors(){const e=this.eEditor.getInputElement().valueAsDate,{params:t}=this,{min:o,max:i,getValidationErrors:s}=t;let n=[];const r=this.getLocaleTextFunc();if(e instanceof Date&&!isNaN(e.getTime())){if(o){const t=o instanceof Date?o:new Date(o);if(e<t){const e=t.toLocaleDateString();n.push(r("minDateValidation",`Date must be after ${e}`,[e]))}}if(i){const t=i instanceof Date?i:new Date(i);if(e>t){const e=t.toLocaleDateString();n.push(r("maxDateValidation",`Date must be before ${e}`,[e]))}}}return n.length||(n=null),s?s({value:e,cellEditorParams:t,internalErrors:n}):n}getValue(){const{eEditor:e,params:t}=this,i=e.getDate();return o(i)||o(t.value)?i??null:t.value}getStartValue(){const{value:e}=this.params;if(e instanceof Date)return ss(e,this.includeTime??!1)}},Vp={tag:"ag-input-date-field",ref:"eEditor",cls:"ag-cell-editor"},Gp=class{constructor(e,t){this.getDataTypeService=e,this.getLocaleTextFunc=t}getTemplate(){return Vp}getAgComponents(){return[Hs]}init(e,t){this.eEditor=e,this.params=t;const{min:o,max:i,step:s,colDef:n}=t;null!=o&&e.setMin(o),null!=i&&e.setMax(i),null!=s&&e.setStep(s),this.includeTime=t.includeTime??this.getDataTypeService()?.getDateIncludesTimeFlag?.(n.cellDataType),null!=this.includeTime&&e.setIncludeTime(this.includeTime)}getValidationErrors(){const{eEditor:e,params:t}=this,o=e.getInputElement().value,i=this.formatDate(this.parseDate(o??void 0)),{min:s,max:n,getValidationErrors:r}=t;let a=[];if(i){const e=new Date(i),t=this.getLocaleTextFunc();if(s){const o=new Date(s);if(e<o){const e=o.toLocaleDateString();a.push(t("minDateValidation",`Date must be after ${e}`,[e]))}}if(n){const o=new Date(n);if(e>o){const e=o.toLocaleDateString();a.push(t("maxDateValidation",`Date must be before ${e}`,[e]))}}}return a.length||(a=null),r?r({value:this.getValue(),cellEditorParams:t,internalErrors:a}):a}getValue(){const{params:e,eEditor:t}=this,i=this.formatDate(t.getDate());return o(i)||o(e.value)?e.parseValue(i??""):e.value}getStartValue(){return ss(this.parseDate(this.params.value??void 0)??null,this.includeTime??!1)}parseDate(e){const t=this.getDataTypeService();return t?t.getDateParserFunction(this.params.column)(e):cs(e)??void 0}formatDate(e){const t=this.getDataTypeService();return t?t.getDateFormatterFunction(this.params.column)(e):ss(e??null,this.includeTime??!1)??void 0}},Np={tag:"div",cls:"ag-large-text",children:[{tag:"ag-input-text-area",ref:"eEditor",cls:"ag-large-text-input"}]},Op={tag:"ag-input-number-field",ref:"eEditor",cls:"ag-cell-editor"},zp=class{constructor(e){this.getLocaleTextFunc=e}getTemplate(){return Op}getAgComponents(){return[Bs]}init(e,t){this.eEditor=e,this.params=t;const{max:o,min:i,precision:s,step:n}=t;null!=o&&e.setMax(o),null!=i&&e.setMin(i),null!=s&&e.setPrecision(s),null!=n&&e.setStep(n);const r=e.getInputElement();t.preventStepping?e.addManagedElementListeners(r,{keydown:this.preventStepping}):t.showStepperButtons&&r.classList.add("ag-number-field-input-stepper")}getValidationErrors(){const{params:e}=this,{min:t,max:o,getValidationErrors:i}=e,s=this.eEditor.getInputElement().valueAsNumber,n=this.getLocaleTextFunc();let r=[];return"number"==typeof s&&(null!=t&&s<t&&r.push(n("minValueValidation",`Must be greater than or equal to ${t}.`,[String(t)])),null!=o&&s>o&&r.push(n("maxValueValidation",`Must be less than or equal to ${o}.`,[String(o)]))),r.length||(r=null),i?i({value:s,cellEditorParams:e,internalErrors:r}):r}preventStepping(e){e.key!==Ti&&e.key!==Ai||e.preventDefault()}getValue(){const{eEditor:e,params:t}=this,i=e.getValue();if(!o(i)&&!o(t.value))return t.value;let s=t.parseValue(i);if(null==s)return s;if("string"==typeof s){if(""===s)return null;s=Number(s)}return isNaN(s)?null:s}getStartValue(){return this.params.value}setCaret(){_i()&&this.eEditor.getInputElement().focus({preventScroll:!0})}},Wp={tag:"div",cls:"ag-cell-edit-wrapper",children:[{tag:"ag-select",ref:"eEditor",cls:"ag-cell-editor"}]},Up={tag:"ag-input-text-field",ref:"eEditor",cls:"ag-cell-editor"},$p=class{constructor(e){this.getLocaleTextFunc=e}getTemplate(){return Up}getAgComponents(){return[Is]}init(e,t){this.eEditor=e,this.params=t;const o=t.maxLength;null!=o&&e.setMaxLength(o)}getValidationErrors(){const{params:e}=this,{maxLength:t,getValidationErrors:o}=e,i=this.getValue(),s=this.getLocaleTextFunc();let n=[];return null!=t&&"string"==typeof i&&i.length>t&&n.push(s("maxLengthValidation",`Must be ${t} characters or fewer.`,[String(t)])),n.length||(n=null),o?o({value:i,cellEditorParams:e,internalErrors:n}):n}getValue(){const{eEditor:e,params:t}=this,i=e.getValue();return o(i)||o(t.value)?t.parseValue(i):t.value}getStartValue(){const e=this.params;return e.useFormatter||e.column.getColDef().refData?e.formatValue(e.value):e.value}setCaret(){_i()&&this.eEditor.getInputElement().focus({preventScroll:!0});const e=this.eEditor,t=e.getValue(),i=o(t)&&t.length||0;i&&e.getInputElement().setSelectionRange(i,i)}},Kp=class extends Lp{constructor(){super(new $p(()=>this.getLocaleTextFunc()))}};function jp(e,t,o="auto"){e.frameworkOverrides.wrapIncoming(()=>e.ctrlsSvc.getScrollFeature().ensureColumnVisible(t,o),"ensureVisible")}function qp(e,t,o){e.frameworkOverrides.wrapIncoming(()=>e.ctrlsSvc.getScrollFeature().ensureIndexVisible(t,o),"ensureVisible")}var _p={tag:"div",cls:"ag-popup-editor",attrs:{tabindex:"-1"}},Yp=class extends qi{constructor(e){super(_p),this.params=e}postConstruct(){vt(this.gos,this.getGui(),"popupEditorWrapper",!0),this.addKeyDownListener()}addKeyDownListener(){const e=this.getGui(),t=this.params;this.addManagedElementListeners(e,{keydown:e=>{jr(this.gos,e,t.node,t.column,!0)||t.onKeyDown(e)}})}};function Qp(e,{rowNode:t,column:o},i="ui"){const s=o.getColDef().editable,n=e.editModelSvc;return o.isColumnFunc(t,s)||!!n&&n.hasEdits({rowNode:t,column:o},{withOpenEditor:!0})}var Zp=(e,t=!1)=>{if(void 0!==e)return cu(e)||t&&"editing"===e.state};function Jp(e,t,o=!1){return Zp(e.editModelSvc?.getEdit(t),o)}function Xp(e,t){const{editModelSvc:o}=e,{column:i,rowNode:s}=t;if(e.gos.get("groupTotalRow")&&!s?.footer)return!1;for(const e of s?.allLeafChildren??[]){if(Zp(o?.getEdit({rowNode:e,column:i}))||Zp(o?.getEdit({rowNode:e.pinnedSibling,column:i})))return!0}}function em(e,{rowNode:t,column:o}){if(t=t.pinnedSibling)return Zp(e.editModelSvc?.getEdit({rowNode:t,column:o}))}var tm=class extends Me{constructor(e,t){super(),this.cellCtrl=e,this.beans=t,this.editSvc=t.editSvc,this.editModelSvc=t.editModelSvc}setComp(e){this.cellComp=e,this.applyCellStyles()}applyCellStyles(){const{cellCtrl:e,editSvc:t,beans:o}=this;if(t?.isBatchEditing()&&t.isEditing()){const t=Jp(o,e)||Xp(o,e)||em(o,e);this.applyBatchingStyle(t)}else this.applyBatchingStyle(!1);const i=!!this.editModelSvc?.getCellValidationModel().hasCellValidation(this.cellCtrl);this.cellComp.toggleCss("ag-cell-editing-error",i)}applyBatchingStyle(e){this.cellComp.toggleCss("ag-cell-editing",e??!1),this.cellComp.toggleCss("ag-cell-batch-edit",(e&&this.editSvc?.isBatchEditing())??!1)}},om=class extends Me{constructor(e,t){super(),this.rowCtrl=e,this.beans=t,this.gos=t.gos,this.editSvc=t.editSvc,this.editModelSvc=t.editModelSvc}applyRowStyles(){const{rowCtrl:e,editModelSvc:t,beans:o}=this;let i=e.rowNode,s=t?.getEditRow(i);const n=this.editModelSvc?.getRowValidationModel().hasRowValidation({rowNode:i});if(!s&&i.pinnedSibling&&(i=i.pinnedSibling,s=t?.getEditRow(i)),s){const e=Array.from(s.keys()).some(e=>{const t={rowNode:i,column:e};return Jp(o,t,!0)||Xp(o,t)||em(o,t)});return void this.applyStyle(n,e)}this.applyStyle(n)}applyStyle(e=!1,t=!1){const o=this.editSvc?.isBatchEditing()??!1,i="fullRow"===this.gos.get("editType");this.rowCtrl?.forEachGui(void 0,({rowComp:s})=>{s.toggleCss("ag-row-editing",i&&t),s.toggleCss("ag-row-batch-edit",i&&t&&o),s.toggleCss("ag-row-inline-editing",t),s.toggleCss("ag-row-not-inline-editing",!t),s.toggleCss("ag-row-editing-invalid",i&&t&&e)})}},im=e=>()=>{const t=new Set(e.colModel.getCols()),o=e.editModelSvc.getEditMap(!0),i=new Set(o.keys());(({editModelSvc:e},t,o)=>{t.forEach(t=>e?.getEditRow(t)?.forEach((i,s)=>!o.has(s)&&e.removeEdits({rowNode:t,column:s})))})(e,(({rowModel:e,pinnedRowModel:t,editModelSvc:o},i)=>{const s=new Set;return e.forEachNode(e=>i.has(e)&&s.add(e)),t?.forEachPinnedRow("top",e=>i.has(e)&&s.add(e)),t?.forEachPinnedRow("bottom",e=>i.has(e)&&s.add(e)),i.forEach(e=>{s.has(e)||o.removeEdits({rowNode:e})}),s})(e,i),t)},sm=new Set(["undo","redo","paste","bulk","rangeSvc"]),nm=new Set(["ui","api"]),rm={paste:"api",rangeSvc:"api",fillHandle:"api",cellClear:"api",bulk:"api"},am=new Set(Object.keys(rm)),lm=new Set(["paste","rangeSvc","renderer","cellClear","redo","undo"]),dm={cancel:!0,source:"api"},hm={cancel:!1,source:"api"},cm={checkSiblings:!0},um={force:!0,suppressFlash:!0};function gm(e){return{rowNodes:e?Array.from(e.keys()):void 0,columns:e?[...new Set(Array.from(e.values()).flatMap(e=>Array.from(e.keys())))]:void 0}}function pm(e,t){return t??e.get("editType")??"singleCell"}var mm=class extends Me{postConstruct(){this.model=this.beans.editModelSvc,this.editSvc=this.beans.editSvc,this.addManagedEventListeners({cellFocused:this.onCellFocusChanged?.bind(this),cellFocusCleared:this.onCellFocusChanged?.bind(this)})}clearEdits(e){this.model.clearEditValue(e)}onCellFocusChanged(e){let t;const o=e.previousParams,{editSvc:i,beans:s}=this,n="cellFocused"===e.type?e.sourceEvent:null;o&&(t=ru(s,o));const{gos:r,editModelSvc:a}=s,l="cellFocusCleared"===e.type;if(i.isEditing(void 0,{withOpenEditor:!0})){const{column:t,rowIndex:d,rowPinned:h}=e,c={column:t,rowNode:vd(s,{rowIndex:d,rowPinned:h})},u="block"===r.get("invalidEditValueMode");if(u)return;const g=!u,p=!!a?.getCellValidationModel().hasCellValidation(c),m=g&&p;!o&&!l||i.stopEditing(void 0,{cancel:m,source:l&&g?"api":void 0,event:n})||(i.isBatchEditing()?i.cleanupEditors():i.stopEditing(void 0,{source:"api"}))}t?.refreshCell({suppressFlash:!0,force:!0})}stop(e,t){const o=this.model.getEditPositions(),i={all:[],pass:[],fail:[]};if(o.forEach(e=>{i.all.push(e);const t=this.model.getCellValidationModel().getCellValidation(e);(t?.errorMessages?.length??0)>0?i.fail.push(e):i.pass.push(e)}),e)return o.forEach(t=>{bu(this.beans,t,{cancel:e}),this.model.stop(t)}),!0;const s=this.processValidationResults(i);return s.destroy.length>0&&s.destroy.forEach(o=>{bu(this.beans,o,{event:t,cancel:e}),this.model.stop(o)}),s.keep.length>0&&s.keep.forEach(e=>{const t=ru(this.beans,e);this.editSvc?.cellEditingInvalidCommitBlocks()||t&&this.editSvc.revertSingleCellEdit(t)}),!0}cleanupEditors({rowNode:e}={},t){Cu(this.beans,{persist:!1});const o=this.model.getEditPositions(),i=[];e?o.forEach(t=>{e&&t.rowNode!==e&&i.push(t)}):o.forEach(e=>{i.push(e)}),wu(this.beans,i),mu(this.beans,t)}setFocusOutOnEditor(e){e.comp?.getCellEditor()?.focusOut?.()}setFocusInOnEditor(e){const t=e.comp,o=t?.getCellEditor();if(o?.focusIn)o.focusIn();else{const o="fullRow"===this.beans.gos.get("editType");e.focusCell(o),e.onEditorAttachedFuncs.push(()=>t?.getCellEditor()?.focusIn?.())}}setupEditors(e){const{event:t,ignoreEventKey:o=!1,startedEdit:i,position:s,cells:n=this.model.getEditPositions()}=e,r=t instanceof KeyboardEvent&&!o&&t.key||void 0;!function(e,t,o,i,s,n){0===t.length&&o?.rowNode&&o?.column&&uu(e,o,{key:i,event:s,cellStartedEdit:n});const{valueSvc:r,editSvc:a,editModelSvc:l}=e,{rowNode:d,column:h}=o??{};for(const c of t){const{rowNode:t,column:u}=c,g=ru(e,c);if(!g){if(t&&u){const e=r.getValue(u,t,void 0,"api"),s=(o?.rowNode===t&&o?.column===u&&i||void 0)??a?.getCellDataValue(c,!1)??r.getValueForDisplay(u,t)?.value??e??du;l?.setEdit(c,{pendingValue:s,sourceValue:e,state:"editing"})}continue}const p=n&&d===g.rowNode&&g.column===h;uu(e,{rowNode:d,column:g.column},{key:p?i:null,event:p?s:null,cellStartedEdit:p&&n})}}(this.beans,n,s,r,t,i)}dispatchCellEvent(e,t,o,i){const s=ru(this.beans,e);s&&this.eventSvc.dispatchEvent({...s.createEvent(t??null,o),...i})}dispatchRowEvent(e,t,o){if(o)return;const i=nu(this.beans,e);i&&this.eventSvc.dispatchEvent(i.createRowEvent(t))}shouldStop(e,t,o="ui"){const i=this.editSvc.isBatchEditing();return!(!i||"api"!==o)||(!i||"ui"!==o&&"edit"!==o)&&("api"===o||(t instanceof KeyboardEvent&&!i?t.key===Pi:null))}shouldCancel(e,t,o="ui"){const i=this.editSvc.isBatchEditing();if(t instanceof KeyboardEvent&&!i){if(t.key===Di)return!0}return!(!i||"api"!==o)||"api"===o}setEditMap(e,t){t?.update||this.editSvc.stopEditing(void 0,{cancel:!0,source:"api"});const o=[];if(e.forEach((e,t)=>{e.forEach((e,i)=>{"editing"===e.state&&o.push({...e,rowNode:t,column:i})})}),t?.update&&(e=new Map([...this.model.getEditMap(),...e])),this.model?.setEditMap(e),o.length>0){const e=o.at(-1),t=e.pendingValue===du?void 0:e.pendingValue;this.start({position:e,event:new KeyboardEvent("keydown",{key:t}),source:"api"});const i=ru(this.beans,e);i&&this.setFocusInOnEditor(i)}}destroy(){this.cleanupEditors(),super.destroy()}},fm={moduleName:"EditCore",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="editModelSvc",this.edits=new Map,this.cellValidations=new iu,this.rowValidations=new su,this.suspendEdits=!1}suspend(e){this.suspendEdits=e}removeEdits({rowNode:e,column:t}){if(!this.hasEdits({rowNode:e})||!e)return;const o=this.getEditRow(e);t?o.delete(t):o.clear(),0===o.size&&this.edits.delete(e)}getEditRow(e,t={}){if(this.suspendEdits)return;if(0===this.edits.size)return;const o=e&&this.edits.get(e);if(o)return o;if(t.checkSiblings){const t=e.pinnedSibling;if(t)return this.getEditRow(t)}}getEditRowDataValue(e,{checkSiblings:t}={}){if(!e||0===this.edits.size)return;const o=this.getEditRow(e),i=e.pinnedSibling,s=t&&i&&this.getEditRow(i);if(!o&&!s)return;const n=Object.assign({},e.data),r=(e,t)=>e.forEach(({pendingValue:e},o)=>{e!==du&&(t[o.getColId()]=e)});return o&&r(o,n),s&&r(s,n),n}getEdit(e,t){const o=this._getEdit(e);return t&&o?{...o}:o}_getEdit(e){if(!this.suspendEdits&&0!==this.edits.size)return e.rowNode&&e.column&&this.getEditRow(e.rowNode)?.get(e.column)}getEditMap(e=!0){if(this.suspendEdits||0===this.edits.size)return new Map;if(!e)return this.edits;const t=new Map;return this.edits.forEach((e,o)=>{const i=new Map;e.forEach(({editorState:e,...t},o)=>i.set(o,{...t})),t.set(o,i)}),t}setEditMap(e){this.edits.clear(),e.forEach((e,t)=>{const o=new Map;e.forEach((e,t)=>o.set(t,{...e})),this.edits.set(t,o)})}setEdit(e,t){(0===this.edits.size||!this.edits.has(e.rowNode))&&this.edits.set(e.rowNode,new Map);const o=this._getEdit(e),i=Object.assign({editorState:{isCancelAfterEnd:void 0,isCancelBeforeStart:void 0},...o,...t});return this.getEditRow(e.rowNode).set(e.column,i),i}clearEditValue(e){const{rowNode:t,column:o}=e;if(t)if(o){const t=this._getEdit(e);t&&(t.editorValue=void 0,t.pendingValue=t.sourceValue,t.state="changed")}else this.getEditRow(t)?.forEach(e=>{e.editorValue=void 0,e.pendingValue=e.sourceValue,e.state="changed"})}getState(e){if(!this.suspendEdits)return this.getEdit(e)?.state}getEditPositions(e){if(this.suspendEdits||0===(e??this.edits).size)return[];const t=[];return(e??this.edits).forEach((e,o)=>{for(const i of e.keys()){const{editorState:s,...n}=e.get(i);t.push({rowNode:o,column:i,...n})}}),t}hasRowEdits(e,t){if(this.suspendEdits)return!1;if(0===this.edits.size)return!1;return!!this.getEditRow(e,t)}hasEdits(e={},t={}){if(this.suspendEdits)return!1;if(0===this.edits.size)return!1;const{rowNode:o,column:i}=e,{withOpenEditor:s}=t;if(o){const n=this.getEditRow(o,t);return!!n&&(i?s?"editing"===this.getEdit(e)?.state:n.has(i)??!1:0!==n.size&&(!s||Array.from(n.values()).some(({state:e})=>"editing"===e)))}return s?this.getEditPositions().some(({state:e})=>"editing"===e):this.edits.size>0}start(e){const t=this.getEditRow(e.rowNode)??new Map,{rowNode:o,column:i}=e;i&&!t.has(i)&&t.set(i,{editorValue:void 0,pendingValue:du,sourceValue:this.beans.valueSvc.getValue(i,o,!1,"api"),state:"editing",editorState:{isCancelAfterEnd:void 0,isCancelBeforeStart:void 0}}),this.edits.set(o,t)}stop(e){this.hasEdits(e)&&(e?this.removeEdits(e):this.clear())}clear(){for(const e of this.edits.values())e.clear();this.edits.clear()}getCellValidationModel(){return this.cellValidations}getRowValidationModel(){return this.rowValidations}setCellValidationModel(e){this.cellValidations=e}setRowValidationModel(e){this.rowValidations=e}destroy(){super.destroy(),this.clear()}},class extends Me{constructor(){super(...arguments),this.beanName="editSvc",this.batch=!1,this.stopping=!1,this.committing=!1}postConstruct(){const{beans:e}=this;this.model=e.editModelSvc,this.valueSvc=e.valueSvc,this.rangeSvc=e.rangeSvc,this.addManagedPropertyListener("editType",({currentValue:e})=>{this.stopEditing(void 0,dm),this.createStrategy(e)});const t=im(e),o=()=>{const t=this.model.getCellValidationModel().getCellValidationMap().size>0,o=this.model.getRowValidationModel().getRowValidationMap().size>0;return t||o?this.stopEditing(void 0,dm):this.isEditing()&&(this.isBatchEditing()?wu(e,this.model.getEditPositions()):this.stopEditing(void 0,hm)),!1};this.addManagedEventListeners({columnPinned:t,columnVisible:t,columnRowGroupChanged:t,rowExpansionStateChanged:t,pinnedRowsChanged:t,displayedRowsChanged:t,sortChanged:o,filterChanged:o,cellFocused:this.onCellFocused.bind(this)})}isBatchEditing(){return this.batch}setBatchEditing(e){e?(this.batch=!0,this.stopEditing(void 0,dm)):(this.stopEditing(void 0,dm),this.batch=!1)}createStrategy(e){const{beans:t,gos:o,strategy:i}=this,s=pm(o,e);if(i){if(i.beanName===s)return i;this.destroyStrategy()}return this.strategy=this.createOptionalManagedBean(t.registry.createDynamicBean(s,!0))}destroyStrategy(){this.strategy&&(this.strategy.destroy(),this.strategy=this.destroyBean(this.strategy))}shouldStartEditing(e,t,o,i="ui"){const s=function(e,{column:t},o,i,s="ui"){if(o instanceof KeyboardEvent&&(o.key===Fi||o.key===Pi||o.key===Bi||o.key===xi&&i))return!0;if(o?.shiftKey&&0!=e.rangeSvc?.getCellRanges().length)return!1;const n=t?.getColDef(),r=function(e,t){return!0===e.get("suppressClickEdit")?0:!0===e.get("singleClickEdit")||t?.singleClickEdit?1:2}(e.gos,n),a=o?.type;return"click"===a&&1===o?.detail&&1===r||"dblclick"===a&&2===o?.detail&&2===r||"api"===s&&(i??!1)}(this.beans,e,t,o,i);return s&&(this.strategy??(this.strategy=this.createStrategy())),s}shouldStopEditing(e,t,o="ui"){return this.strategy?.shouldStop(e,t,o)??null}shouldCancelEditing(e,t,o="ui"){return this.strategy?.shouldCancel(e,t,o)??null}validateEdit(){return function(e){Ru(e,!0);const t=e.editModelSvc?.getCellValidationModel().getCellValidationMap();if(!t)return null;const o=[];return t.forEach((e,t)=>{e.forEach(({errorMessages:e},i)=>{o.push({column:i,rowIndex:t.rowIndex,rowPinned:t.rowPinned,messages:e??null})})}),o}(this.beans)}isEditing(e,t){return this.model.hasEdits(e,t??cm)}isRowEditing(e,t){return(e&&this.model.hasRowEdits(e,t))??!1}startEditing(e,t){const{startedEdit:o=!0,event:i=null,source:s="ui",ignoreEventKey:n=!1,silent:r}=t;if(this.strategy??(this.strategy=this.createStrategy()),!this.isCellEditable(e,"api"))return;const a=ru(this.beans,e);if(a&&!a.comp)return void a.onCompAttachedFuncs.push(()=>this.startEditing(e,t));const l=this.shouldStartEditing(e,i,o,s);!1!==l||"api"===s?(this.batch||!this.shouldStopEditing(e,void 0,s)||t.continueEditing||this.stopEditing(void 0,{source:s}),l&&this.isBatchEditing()&&this.dispatchBatchEvent("batchEditingStarted",new Map),this.strategy.start({position:e,event:i,source:s,ignoreEventKey:n,startedEdit:o,silent:r})):this.isEditing(e)&&this.stopEditing()}stopEditing(e,t){const{event:o,cancel:i,source:s="ui",suppressNavigateAfterEdit:n,forceCancel:r,forceStop:a}=t||{},{beans:l,model:d}=this;if(am.has(s)&&this.isBatchEditing())return this.bulkRefresh(e),!1;const h=this.committing?rm[s]:s;if(!(this.committing||this.isEditing(e)||this.isBatchEditing()&&d.hasEdits(e,cm))||!this.strategy||this.stopping)return!1;this.stopping=!0;const c=ru(l,e);c&&(c.onEditorAttachedFuncs=[]);let u=d.getEditMap(!0),g=!1;const p=!i&&(!!this.shouldStopEditing(e,o,h)||this.committing&&!this.batch)||(a??!1),m=i&&!!this.shouldCancelEditing(e,o,h)||(r??!1);if(p||m){Cu(l,{persist:!0,isCancelling:m||i,isStopping:p});const e=d.getEditMap(),t=this.processEdits(e,i,s);this.strategy?.stop(i,o),t.forEach(e=>{d.clearEditValue(e)}),this.bulkRefresh(void 0,u),d.getEditPositions(e).forEach(e=>{const t=ru(l,e),o=cu(e);t?.refreshCell({force:!0,suppressFlash:!o})}),u=e,g||(g=p)}else if(o instanceof KeyboardEvent&&this.batch&&this.strategy?.midBatchInputsAllowed(e)&&this.isEditing(e,{withOpenEditor:!0})){const t=o.key,i=t===Pi,s=t===Di,n=t===Fi;(i||n||s)&&(i||n?Cu(l,{persist:!0}):s&&this.revertSingleCellEdit(c),this.isBatchEditing()?this.strategy?.cleanupEditors():wu(l,d.getEditPositions(),{event:o,cancel:s}),o.preventDefault(),this.bulkRefresh(e,u,{suppressFlash:!0}),u=d.getEditMap())}else Cu(l,{persist:!0}),u=d.getEditMap();return g&&e&&this.model.removeEdits(e),!n&&c&&this.navigateAfterEdit(o instanceof KeyboardEvent&&o.shiftKey,c.cellPosition),mu(l),this.model.hasEdits()||(this.model.getCellValidationModel().clearCellValidationMap(),this.model.getRowValidationModel().clearRowValidationMap()),this.bulkRefresh(),m&&this.beans.rowRenderer.refreshRows({rowNodes:Array.from(u.keys())}),this.isBatchEditing()&&(this.beans.rowRenderer.refreshRows({suppressFlash:!0,force:!0}),g&&p&&this.dispatchBatchEvent("batchEditingStopped",u)),this.stopping=!1,g}navigateAfterEdit(e,t){if(this.gos.get("enterNavigatesVerticallyAfterEdit")){const o=e?Ti:Ai;this.beans.navigation?.navigateToNextCell(null,o,t,!1)}}processEdits(e,t=!1,o){const i=Array.from(e.keys()),s=this.model.getCellValidationModel().getCellValidationMap().size>0||this.model.getRowValidationModel().getRowValidationMap().size>0,n=[];for(const r of i){const i=e.get(r);for(const e of i.keys()){const a=i.get(e),l={rowNode:r,column:e},d=cu(a);if(!t&&d&&!s){this.setNodeDataValue(r,e,a.pendingValue,void 0,o)||n.push(l)}}}return n}setNodeDataValue(e,t,o,i,s="edit"){const{beans:n}=this,r=ru(n,{rowNode:e,column:t}),a=nm.has(s)?"edit":s;r&&(r.suppressRefreshCell=!0),this.commitNextEdit();const l=e.setDataValue(t,o,a);return r&&(r.suppressRefreshCell=!1),i&&r?.refreshCell(um),l}setEditMap(e,t){this.strategy??(this.strategy=this.createStrategy()),this.strategy?.setEditMap(e,t),this.bulkRefresh();let o=um;t?.forceRefreshOfEditCellsOnly&&(o={...gm(e),...um}),this.beans.rowRenderer.refreshCells(o)}dispatchEditValuesChanged({rowNode:e,column:t},o={}){if(!e||!t||!o)return;const{pendingValue:i,sourceValue:s}=o,{rowIndex:n,rowPinned:r,data:a}=e;this.beans.eventSvc.dispatchEvent({type:"cellEditValuesChanged",node:e,rowIndex:n,rowPinned:r,column:t,source:"api",data:a,newValue:i,oldValue:s,value:i,colDef:t.getColDef()})}bulkRefresh(e={},t,o={}){const{beans:i,gos:s}=this,{editModelSvc:n,rowModel:r}=i;dt(s)&&(e.rowNode&&e.column?this.refCell(e,this.model.getEdit(e),o):t&&n?.getEditMap(!1)?.forEach((e,t)=>{for(const i of e.keys())this.refCell({rowNode:t,column:i},e.get(i),o)}))}refCell({rowNode:e,column:t},o,i={}){const{beans:s,gos:n}=this,r=new Set([e]),a=new Set,l=e.pinnedSibling;l&&r.add(l);const d=e.sibling;d&&a.add(d);let h=e.parent;for(;h;)h.sibling?.footer&&n.get("groupTotalRow")||!h.parent&&h.sibling&&n.get("grandTotalRow")?a.add(h.sibling):a.add(h),h=h.parent;r.forEach(e=>this.dispatchEditValuesChanged({rowNode:e,column:t},o)),r.forEach(e=>ru(s,{rowNode:e,column:t})?.refreshCell(i)),a.forEach(e=>ru(s,{rowNode:e,column:t})?.refreshCell(i))}stopAllEditing(e=!1,t="ui"){this.isEditing()&&this.stopEditing(void 0,{cancel:e,source:t})}isCellEditable(e,t="ui"){const{rowNode:o}=e,{gos:i,beans:s}=this;if(o.group)if(i.get("treeData")){if(!o.data&&!i.get("enableGroupEdit"))return!1}else if(!i.get("enableGroupEdit"))return!1;const n="fullRow"===pm(i)?function(e,t,o="ui"){const i=Qp(e,t,o);return!0===i||"ui"===o?i:e.colModel.getCols().some(i=>Qp(e,{rowNode:t.rowNode,column:i},o))}(s,e,t):Qp(s,e,t);return n&&(this.strategy??(this.strategy=this.createStrategy())),n}cellEditingInvalidCommitBlocks(){return"block"===this.gos.get("invalidEditValueMode")}checkNavWithValidation(e,t,o=!0){if(this.hasValidationErrors(e)){const i=ru(this.beans,e);return this.cellEditingInvalidCommitBlocks()?(t?.preventDefault?.(),o&&(!i?.hasBrowserFocus()&&i?.focusCell(),i?.comp?.getCellEditor()?.focusIn?.()),"block-stop"):(i&&this.revertSingleCellEdit(i),"revert-continue")}return"continue"}revertSingleCellEdit(e,t=!1){const o=ru(this.beans,e);o?.comp?.getCellEditor()&&(wu(this.beans,[e],{silent:!0}),this.model.clearEditValue(e),uu(this.beans,e,{silent:!0}),Ru(this.beans),o?.refreshCell(um),o.rowCtrl.rowEditStyleFeature?.applyRowStyles(),t&&(o?.focusCell(),o?.comp?.getCellEditor()?.focusIn?.()))}hasValidationErrors(e){Ru(this.beans);const t=ru(this.beans,e);t&&(t.refreshCell(um),t.rowCtrl.rowEditStyleFeature?.applyRowStyles());let o=!1;return e?.rowNode?(o||(o=this.model.getRowValidationModel().hasRowValidation({rowNode:e.rowNode})),e.column&&(o||(o=this.model.getCellValidationModel().hasCellValidation({rowNode:e.rowNode,column:e.column})))):(o||(o=this.model.getCellValidationModel().getCellValidationMap().size>0),o||(o=this.model.getRowValidationModel().getRowValidationMap().size>0)),o}moveToNextCell(e,t,o,i="ui"){let s;const n=this.isEditing(),r=n&&"block-stop"===this.checkNavWithValidation(void 0,o);return e instanceof ku&&n&&(s=this.strategy?.moveToNextEditingCell(e,t,o,i,r)),null===s||(s=s||!!this.beans.focusSvc.focusedHeader,!1!==s||r||this.stopEditing()),s}getCellDataValue({rowNode:e,column:t},o=!0){if(!e||!t)return;let i=this.model.getEdit({rowNode:e,column:t});const s=e.pinnedSibling;if(s){const e=this.model.getEdit({rowNode:s,column:t});e&&(i=e)}const n=o?i?.editorValue??i?.pendingValue:i?.pendingValue;return n!==du&&i?n:i?.sourceValue??this.valueSvc.getValue(t,e,!1,"api")}addStopEditingWhenGridLosesFocus(e){!function(e,t,o){const{gos:i,popupSvc:s}=t;if(!i.get("stopEditingWhenCellsLoseFocus"))return;const n=e=>{const n=e.relatedTarget;if(null===Ji(n))return void au(t);let r=o.some(e=>e.contains(n))&&i.isElementInThisInstance(n);r||(r=!!s&&(s.getActivePopups().some(e=>e.contains(n))||s.isElementWithinCustomPopup(n))),r||au(t)};o.forEach(t=>e.addManagedElementListeners(t,{focusout:n}))}(this,this.beans,e)}createPopupEditorWrapper(e){return new Yp(e)}commitNextEdit(){this.committing=!0}setDataValue(e,t,o){try{if((!this.isEditing()||this.committing)&&!lm.has(o))return;const{beans:i}=this;this.strategy??(this.strategy=this.createStrategy());const s=this.isBatchEditing()?"ui":this.committing?o??"api":"api";if(!o||sm.has(o))return vu(i,e,t,0,void 0,{persist:!0}),this.setNodeDataValue(e.rowNode,e.column,t,!0,o);const n=this.model.getEdit(e);if(n){if(n.pendingValue===t)return!1;if(n.sourceValue!==t)return vu(i,e,t,0,void 0,{persist:!0}),this.stopEditing(e,{source:s,suppressNavigateAfterEdit:!0}),!0;if(n.sourceValue===t)return i.editModelSvc?.removeEdits(e),this.dispatchEditValuesChanged(e,{...n,pendingValue:t}),!0}return vu(i,e,t,0,void 0,{persist:!0}),this.stopEditing(e,{source:s,suppressNavigateAfterEdit:!0}),!0}finally{this.committing=!1}}handleColDefChanged(e){!function(e,t){const o=t.comp?.getCellEditor();if(!o?.refresh)return;const{eventKey:i,cellStartedEdit:s}=t.editCompDetails.params,{column:n}=t,r=pu(e,t,i,s),a=n.getColDef(),l=gi(e.userCompFactory,a,r);o.refresh(fu(l.params,i))}(this.beans,e)}destroy(){this.model.clear(),this.destroyStrategy(),super.destroy()}prepDetailsDuringBatch(e,t){if(!this.batch)return;if(!this.model.hasRowEdits(e.rowNode,cm))return;const{rowNode:o,column:i}=e,{compDetails:s,valueToDisplay:n}=t;if(s){const{params:e}=s;return e.data=this.model.getEditRowDataValue(o,cm),{compDetails:s}}const r=this.model.getEditRow(e.rowNode,cm);return void 0!==n&&r?.has(i)?{valueToDisplay:this.valueSvc.getValue(i,o)}:void 0}cleanupEditors(){this.strategy?.cleanupEditors()}dispatchCellEvent(e,t,o,i){this.strategy?.dispatchCellEvent(e,t,o,i)}dispatchBatchEvent(e,t){this.eventSvc.dispatchEvent(this.createBatchEditEvent(e,t))}createBatchEditEvent(e,t){return zt(this.gos,{type:e,..."batchEditingStopped"===e?{changes:this.toEventChangeList(t)}:{}})}toEventChangeList(e){return this.model.getEditPositions(e).map(e=>({rowIndex:e.rowNode.rowIndex,rowPinned:e.rowNode.rowPinned,columnId:e.column.getColId(),newValue:e.pendingValue,oldValue:e.sourceValue}))}applyBulkEdit({rowNode:e,column:t},o){if(!o||0===o.length)return;const{beans:i,rangeSvc:s,valueSvc:n}=this;Cu(i,{persist:!0});const r=this.model.getEditMap(!0),a=r.get(e)?.get(t)?.pendingValue;this.batch||this.eventSvc.dispatchEvent({type:"bulkEditingStarted"}),o.forEach(e=>{if(s?.forEachRowInRange(e,t=>{const o=vd(i,t);if(void 0===o)return;const s=r.get(o)??new Map;for(const t of e.columns)if(t&&this.isCellEditable({rowNode:o,column:t},"api")){const e=n.getValue(t,o,!0,"api");let i=n.parseValue(t,o??null,a,e);Number.isNaN(i)&&(i=null),s.set(t,{editorValue:void 0,pendingValue:i,sourceValue:e,state:"changed",editorState:{isCancelAfterEnd:void 0,isCancelBeforeStart:void 0}})}s.size>0&&r.set(o,s)}),this.setEditMap(r),this.batch)return this.cleanupEditors(),mu(i),void this.bulkRefresh();this.commitNextEdit(),this.stopEditing(void 0,{source:"bulk"}),this.eventSvc.dispatchEvent({type:"bulkEditingStopped",changes:this.toEventChangeList(r)})}),this.bulkRefresh();const l=ru(i,{rowNode:e,column:t});l&&l.focusCell(!0)}createCellStyleFeature(e,t){return new tm(e,t)}createRowStyleFeature(e,t){return new om(e,t)}setEditingCells(e,t){const{beans:o}=this,{colModel:i,valueSvc:s}=o,n=new Map;e.forEach(({colId:e,column:r,colKey:a,rowIndex:l,rowPinned:d,newValue:h,state:c})=>{const u=e?i.getCol(e):a?i.getCol(a):r;if(!u)return;const g=vd(o,{rowIndex:l,rowPinned:d});if(!g)return;const p=s.getValue(u,g,!0,"api");if(!t?.forceRefreshOfEditCellsOnly&&!cu({pendingValue:h,sourceValue:p})&&"editing"!==c)return;let m=n.get(g);m||(m=new Map,n.set(g,m)),void 0===h&&(h=du),m.set(u,{editorValue:void 0,pendingValue:h,sourceValue:p,state:c??"changed",editorState:{isCancelAfterEnd:void 0,isCancelBeforeStart:void 0}})}),this.setEditMap(n,t)}onCellFocused(e){const t=ru(this.beans,e);if(!t||!this.isEditing(t,cm))return;const o=this.model.getEdit(t);if(!o||!cu(o))return;const i=this.getLocaleTextFunc()("ariaPendingChange","Pending Change");this.beans.ariaAnnounce?.announceValue(i,"pendingChange")}allowedFocusTargetOnValidation(e){return ru(this.beans,e)}}],apiFunctions:{getEditingCells:function(e){const t=e.editModelSvc?.getEditMap(),o=[];return t?.forEach((e,t)=>{const{rowIndex:i,rowPinned:s}=t;e.forEach((e,t)=>{const{editorValue:n,pendingValue:r,sourceValue:a,state:l}=e,d=cu(e);let h=n??r;h===du&&(h=void 0);const c={newValue:h,oldValue:a,state:l,column:t,colId:t.getColId(),colKey:t.getColId(),rowIndex:i,rowPinned:s};("editing"===l||"changed"===l&&d)&&o.push(c)})}),o},getEditRowValues:function(e,t){return e.editModelSvc?.getEditRowDataValue(t,{checkSiblings:!0})},getCellEditorInstances:(e,t={})=>hu(e,t).map(e=>e.editor),startEditingCell:function(e,t){const{key:o,colKey:i,rowIndex:s,rowPinned:n}=t,{editSvc:r,colModel:a}=e,l=a.getCol(i);if(!l)return void st(12,{colKey:i});const d=vd(e,{rowIndex:s,rowPinned:n||null});if(!d)return void st(290,{rowIndex:s,rowPinned:n});if(!l.isCellEditable(d))return;null==n&&qp(e,s),jp(e,i),r?.startEditing({rowNode:d,column:l},{event:o?new KeyboardEvent("keydown",{key:o}):void 0,source:"api"})},stopEditing:function(e,t=!1){const{editSvc:o}=e;o?.isBatchEditing()?(t?e.editModelSvc?.getEditPositions().forEach(e=>{"editing"===e.state&&o.revertSingleCellEdit(e)}):Cu(e,{persist:!0}),wu(e,void 0,{cancel:t})):o?.stopEditing(void 0,{cancel:t,source:"edit",forceStop:!t,forceCancel:t})},isEditing:function(e,t){const o=ru(e,t);return e.editSvc?.isEditing(o)??!1},validateEdit:function(e){return e.editSvc?.validateEdit()||null}},dynamicBeans:{singleCell:class extends mm{constructor(){super(...arguments),this.beanName="singleCell"}shouldStop(e,t,o="ui"){const i=super.shouldStop(e,t,o);if(null!==i)return i;const{rowNode:s,column:n}=e||{};return this.rowNode&&this.column||!s||!n?this.rowNode!==s||this.column!==n:null}midBatchInputsAllowed(e){return this.model.hasEdits(e)}start(e){const{position:t,startedEdit:o,event:i,ignoreEventKey:s}=e;this.rowNode===t.rowNode&&this.column===t.column||super.cleanupEditors(),this.rowNode=t.rowNode,this.column=t.column,this.model.start(t),this.setupEditors({cells:[t],position:t,startedEdit:o,event:i,ignoreEventKey:s})}dispatchRowEvent(e,t,o){}processValidationResults(e){return e.fail.length>0&&this.editSvc.cellEditingInvalidCommitBlocks()?{destroy:[],keep:e.all}:{destroy:e.all,keep:[]}}stop(e,t){return super.stop(e,t),this.rowNode=void 0,this.column=void 0,!0}onCellFocusChanged(e){const{colModel:t,editSvc:o}=this.beans,{rowIndex:i,column:s,rowPinned:n}=e,r=vd(this.beans,{rowIndex:i,rowPinned:n}),a=lu(s),l=t.getCol(a),d=e.previousParams;if(d){const e=lu(d.column);if(d?.rowIndex===i&&e===a&&d?.rowPinned===n)return}o?.isEditing({rowNode:r,column:l},{withOpenEditor:!0})&&"cellFocused"===e.type||super.onCellFocusChanged(e)}moveToNextEditingCell(e,t,o,i="ui",s=!1){const n=this.beans.focusSvc.getFocusedCell();n&&(e=wd(this.beans,n)??e);const r=e.cellPosition;let a;const l="fullRow"===this.beans.gos.get("editType");l&&this.model.suspend(!0),s||(e.eGui.focus(),this.editSvc?.stopEditing(e,{source:this.editSvc?.isBatchEditing()?"ui":"api",event:o}));try{a=this.beans.navigation?.findNextCellToFocusOn(r,{backwards:t,startEditing:!0})}finally{l&&this.model.suspend(!1)}if(!1===a)return null;if(null==a)return!1;const d=a.cellPosition,h=e.isCellEditable(),c=a.isCellEditable(),u=d&&r.rowIndex===d.rowIndex&&r.rowPinned===d.rowPinned;h&&!s&&this.setFocusOutOnEditor(e);const g=this.gos.get("suppressStartEditOnTab");if(u||s||(super.cleanupEditors(a,!0),g?a.focusCell(!0,o):this.editSvc.startEditing(a,{startedEdit:!0,event:o,source:i,ignoreEventKey:!0})),c&&!s){if(a.focusCell(!1,o),g)a.focusCell(!0,o);else if(!a.comp?.getCellEditor()){const e=this.editSvc?.isEditing(a,{withOpenEditor:!0});uu(this.beans,a,{event:o,cellStartedEdit:!0,silent:e}),this.setFocusInOnEditor(a),this.cleanupEditors(a)}}else c&&s&&this.setFocusInOnEditor(a),a.focusCell(!0,o);return e.rowCtrl?.refreshRow({suppressFlash:!0,force:!0}),!0}destroy(){super.destroy(),this.rowNode=void 0,this.column=void 0}},fullRow:class extends mm{constructor(){super(...arguments),this.beanName="fullRow",this.startedRows=[]}shouldStop(e,t,o="ui"){const{rowNode:i}=e||{};if(!nu(this.beans,{rowNode:this.rowNode}))return!0;const s=super.shouldStop({rowNode:this.rowNode},t,o);return null!==s?s:!!this.rowNode&&i!==this.rowNode}midBatchInputsAllowed({rowNode:e}){return!!e&&this.model.hasEdits({rowNode:e})}clearEdits(e){this.model.clearEditValue(e)}start(e){const{position:t,silent:o,startedEdit:i,event:s,ignoreEventKey:n}=e,{rowNode:r}=t;this.rowNode!==r&&super.cleanupEditors(t),this.dispatchRowEvent({rowNode:r},"rowEditingStarted",o),this.startedRows.push(r);const a=this.beans.visibleCols.allCols,l=[];a.forEach(e=>{if(!e.isCellEditable(r))return;const t={rowNode:r,column:e};l.push(t),this.model.hasEdits(t)||this.model.start(t)}),this.rowNode=r,this.setupEditors({cells:l,position:t,startedEdit:i,event:s,ignoreEventKey:n})}processValidationResults(e){return e.fail.length>0&&this.editSvc.cellEditingInvalidCommitBlocks()?{destroy:[],keep:e.all}:{destroy:e.all,keep:[]}}stop(e,t){const{rowNode:o}=this;if(o&&!this.model.hasRowEdits(o))return!1;const i=[];return e||this.model.getEditMap().forEach((e,t)=>{if(e&&0!==e.size)for(const o of e.values())if(cu(o)){i.push(t);break}}),Ru(this.beans),!(!e&&"block-stop"===this.editSvc?.checkNavWithValidation({rowNode:o}))&&(super.stop(e,t),i.forEach(e=>this.dispatchRowEvent({rowNode:e},"rowValueChanged")),this.cleanupEditors({rowNode:o},!0),this.rowNode=void 0,!0)}onCellFocusChanged(e){const{rowIndex:t}=e,o=e.previousParams;if(o?.rowIndex===t||e.sourceEvent instanceof KeyboardEvent)return;const i=ru(this.beans,o);"block"===this.gos.get("invalidEditValueMode")&&i&&(this.model.getCellValidationModel().getCellValidation(i)||this.model.getRowValidationModel().getRowValidation(i))||super.onCellFocusChanged(e)}cleanupEditors(e={},t){super.cleanupEditors(e,t),this.startedRows.forEach(e=>this.dispatchRowEvent({rowNode:e},"rowEditingStopped")),this.startedRows.length=0}moveToNextEditingCell(e,t,o,i="ui",s=!1){const n=e.cellPosition;let r;this.model.suspend(!0);try{r=this.beans.navigation?.findNextCellToFocusOn(n,{backwards:t,startEditing:!0,skipToNextEditableCell:!1})}finally{this.model.suspend(!1)}if(!1===r)return null;if(null==r)return!1;const a=r.cellPosition,l=e.isCellEditable(),d=r.isCellEditable(),h=a&&n.rowIndex===a.rowIndex&&n.rowPinned===a.rowPinned;l&&this.setFocusOutOnEditor(e),this.restoreEditors();const c=this.gos.get("suppressStartEditOnTab");return d&&!s?c?r.focusCell(!0,o):(r.comp?.getCellEditor()||uu(this.beans,r,{event:o,cellStartedEdit:!0}),this.setFocusInOnEditor(r),r.focusCell(!1,o)):(d&&s&&this.setFocusInOnEditor(r),r.focusCell(!0,o)),h||s||(this.editSvc?.stopEditing({rowNode:e.rowNode},{event:o}),this.cleanupEditors(r,!0),c?r.focusCell(!0,o):this.editSvc.startEditing(r,{startedEdit:!0,event:o,source:i,ignoreEventKey:!0})),e.rowCtrl?.refreshRow({suppressFlash:!0,force:!0}),!0}restoreEditors(){this.model.getEditMap().forEach((e,t)=>e.forEach(({state:e},o)=>{if("editing"!==e)return;const i=ru(this.beans,{rowNode:t,column:o});i&&!i.comp?.getCellEditor()&&uu(this.beans,i,{silent:!0})}))}destroy(){super.destroy(),this.rowNode=void 0,this.startedRows.length=0}}},dependsOn:[Lg,Mp],css:[".ag-cell-inline-editing{border:var(--ag-cell-editing-border)!important;border-radius:var(--ag-border-radius);box-shadow:var(--ag-cell-editing-shadow);padding:0;z-index:1;.ag-cell-edit-wrapper,.ag-cell-editor,.ag-cell-wrapper,:where(.ag-cell-editor) .ag-input-field-input,:where(.ag-cell-editor) .ag-wrapper{height:100%;line-height:normal;min-height:100%;width:100%}&.ag-cell-editing-error{border-color:var(--ag-invalid-color)!important}}:where(.ag-popup-editor) .ag-large-text{background-color:var(--ag-background-color);border-radius:var(--ag-border-radius);box-shadow:var(--ag-dropdown-shadow);padding:0}.ag-large-text-input{display:block;height:auto;padding:var(--ag-cell-horizontal-padding)}:where(.ag-rtl .ag-large-text-input) textarea{resize:none}:where(.ag-ltr) .ag-checkbox-edit{padding-left:var(--ag-cell-horizontal-padding)}:where(.ag-rtl) .ag-checkbox-edit{padding-right:var(--ag-cell-horizontal-padding)}:where(.ag-row.ag-row-editing-invalid .ag-cell-inline-editing){opacity:.8}.ag-popup-editor{position:absolute;-webkit-user-select:none;-moz-user-select:none;user-select:none}"]},Cm={moduleName:"UndoRedoEdit",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="undoRedo",this.cellValueChanges=[],this.activeCellEdit=null,this.activeRowEdit=null,this.isPasting=!1,this.isRangeInAction=!1,this.batchEditing=!1,this.bulkEditing=!1,this.onCellValueChanged=e=>{const t={column:e.column,rowIndex:e.rowIndex,rowPinned:e.rowPinned},o=null!==this.activeCellEdit&&Cd(this.activeCellEdit,t),i=null!==this.activeRowEdit&&(s=this.activeRowEdit,n=t,!s&&!n||!(s&&!n||!s&&n)&&s.rowIndex===n.rowIndex&&s.rowPinned==n.rowPinned);var s,n;if(!(o||i||this.isPasting||this.isRangeInAction))return;const{rowPinned:r,rowIndex:a,column:l,oldValue:d,value:h}=e,c={rowPinned:r,rowIndex:a,columnId:l.getColId(),newValue:h,oldValue:d};this.cellValueChanges.push(c)},this.clearStacks=()=>{this.undoStack.clear(),this.redoStack.clear()}}postConstruct(){const{gos:e,ctrlsSvc:t}=this.beans;if(!e.get("undoRedoCellEditing"))return;const o=e.get("undoRedoCellEditingLimit");if(o<=0)return;this.undoStack=new Ip(o),this.redoStack=new Ip(o),this.addListeners();const i=this.clearStacks.bind(this);this.addManagedEventListeners({cellValueChanged:this.onCellValueChanged.bind(this),modelUpdated:e=>{e.keepUndoRedoStack||this.clearStacks()},columnPivotModeChanged:i,newColumnsLoaded:i,columnGroupOpened:i,columnRowGroupChanged:i,columnMoved:i,columnPinned:i,columnVisible:i,rowDragEnd:i}),t.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl})}getCurrentUndoStackSize(){return this.undoStack?.getCurrentStackSize()??0}getCurrentRedoStackSize(){return this.redoStack?.getCurrentStackSize()??0}undo(e){const{eventSvc:t,undoStack:o,redoStack:i}=this;t.dispatchEvent({type:"undoStarted",source:e});const s=this.undoRedo(o,i,"initialRange","oldValue","undo");t.dispatchEvent({type:"undoEnded",source:e,operationPerformed:s})}redo(e){const{eventSvc:t,undoStack:o,redoStack:i}=this;t.dispatchEvent({type:"redoStarted",source:e});const s=this.undoRedo(i,o,"finalRange","newValue","redo");t.dispatchEvent({type:"redoEnded",source:e,operationPerformed:s})}undoRedo(e,t,o,i,s){if(!e)return!1;const n=e.pop();return!(!n||!n.cellValueChanges)&&(this.processAction(n,e=>e[i],s),n instanceof Tp?this.processRange(n.ranges||[n[o]]):this.processCell(n.cellValueChanges),t.push(n),!0)}processAction(e,t,o){e.cellValueChanges.forEach(e=>{const{rowIndex:i,rowPinned:s,columnId:n}=e,r={rowIndex:i,rowPinned:s},a=vd(this.beans,r);a.displayed&&a.setDataValue(n,t(e),o)})}processRange(e){let t;const o=this.beans.rangeSvc;o.removeAllCellRanges(!0),e.forEach((i,s)=>{if(!i)return;const n=i.startRow,r=i.endRow;s===e.length-1&&(t={rowPinned:n.rowPinned,rowIndex:n.rowIndex,columnId:i.startColumn.getColId()},this.setLastFocusedCell(t));const a={rowStartIndex:n.rowIndex,rowStartPinned:n.rowPinned,rowEndIndex:r.rowIndex,rowEndPinned:r.rowPinned,columnStart:i.startColumn,columns:i.columns};o.addCellRange(a)})}processCell(e){const t=e[0],{rowIndex:o,rowPinned:i}=t,s={rowIndex:o,rowPinned:i},n=vd(this.beans,s),r={rowPinned:t.rowPinned,rowIndex:n.rowIndex,columnId:t.columnId};this.setLastFocusedCell(r)}setLastFocusedCell(e){const{rowIndex:t,columnId:o,rowPinned:i}=e,{colModel:s,focusSvc:n,rangeSvc:r}=this.beans,a=s.getCol(o);if(!a)return;const{scrollFeature:l}=this.gridBodyCtrl;l.ensureIndexVisible(t),l.ensureColumnVisible(a);const d={rowIndex:t,column:a,rowPinned:i};n.setFocusedCell({...d,forceBrowserFocus:!0}),r?.setRangeToCell(d)}addListeners(){this.addManagedEventListeners({rowEditingStarted:e=>{this.activeRowEdit={rowIndex:e.rowIndex,rowPinned:e.rowPinned}},rowEditingStopped:()=>{const e=new kp(this.cellValueChanges);this.pushActionsToUndoStack(e),this.activeRowEdit=null},cellEditingStarted:e=>{this.activeCellEdit={column:e.column,rowIndex:e.rowIndex,rowPinned:e.rowPinned}},cellEditingStopped:e=>{this.activeCellEdit=null;if(e.valueChanged&&!this.activeRowEdit&&!this.isPasting&&!this.isRangeInAction){const e=new kp(this.cellValueChanges);this.pushActionsToUndoStack(e)}},pasteStart:()=>{this.isPasting=!0},pasteEnd:()=>{const e=new kp(this.cellValueChanges);this.pushActionsToUndoStack(e),this.isPasting=!1},fillStart:()=>{this.isRangeInAction=!0},fillEnd:e=>{const t=new Tp(this.cellValueChanges,e.initialRange,e.finalRange);this.pushActionsToUndoStack(t),this.isRangeInAction=!1},keyShortcutChangedCellStart:()=>{this.isRangeInAction=!0},keyShortcutChangedCellEnd:()=>{let e;const{rangeSvc:t,gos:o}=this.beans;e=t&&Tt(o)?new Tp(this.cellValueChanges,void 0,void 0,[...t.getCellRanges()]):new kp(this.cellValueChanges),this.pushActionsToUndoStack(e),this.isRangeInAction=!1},batchEditingStarted:()=>this.startBigChange("batchEditing"),batchEditingStopped:({changes:e})=>this.stopBigChange("batchEditing",e),bulkEditingStarted:()=>this.startBigChange("bulkEditing"),bulkEditingStopped:({changes:e})=>this.stopBigChange("bulkEditing",e)})}startBigChange(e){this[e]=!0}stopBigChange(e,t){if(!this[e])return;if(this[e]=!1,0===t?.length)return;const o=new kp(t??[]);this.pushActionsToUndoStack(o),this.cellValueChanges=[]}pushActionsToUndoStack(e){this.undoStack.push(e),this.cellValueChanges=[],this.redoStack.clear()}}],apiFunctions:{undoCellEditing:function(e){e.undoRedo?.undo("api")},redoCellEditing:function(e){e.undoRedo?.redo("api")},getCurrentUndoSize:function(e){return e.undoRedo?.getCurrentUndoStackSize()??0},getCurrentRedoSize:function(e){return e.undoRedo?.getCurrentRedoStackSize()??0}},dependsOn:[fm]},vm={moduleName:"TextEditor",version:qe,userComponents:{agCellEditor:Kp,agTextCellEditor:Kp},dependsOn:[fm]},wm={moduleName:"NumberEditor",version:qe,userComponents:{agNumberCellEditor:{classImp:class extends Lp{constructor(){super(new zp(()=>this.getLocaleTextFunc()))}}}},dependsOn:[fm]},bm={moduleName:"DateEditor",version:qe,userComponents:{agDateCellEditor:class extends Lp{constructor(){super(new Hp(()=>this.beans.dataTypeSvc,()=>this.getLocaleTextFunc()))}},agDateStringCellEditor:class extends Lp{constructor(){super(new Gp(()=>this.beans.dataTypeSvc,()=>this.getLocaleTextFunc()))}}},dependsOn:[fm]},ym={moduleName:"CheckboxEditor",version:qe,userComponents:{agCheckboxCellEditor:class extends il{constructor(){super(Ap,[Ms]),this.eEditor=Go}initialiseEditor(e){const t=e.value??void 0,o=this.eEditor;o.setValue(t);o.getInputElement().setAttribute("tabindex","-1"),this.setAriaLabel(t),this.addManagedListeners(o,{fieldValueChanged:e=>this.setAriaLabel(e.selected)})}getValue(){return this.eEditor.getValue()}focusIn(){this.eEditor.getFocusableElement().focus()}afterGuiAttached(){this.params.cellStartedEdit&&this.focusIn()}isPopup(){return!1}setAriaLabel(e){const t=this.getLocaleTextFunc(),o=A(t,e),i=t("ariaToggleCellValue","Press SPACE to toggle cell value");this.eEditor.setInputAriaLabel(`${i} (${o})`)}getValidationElement(e){return e?this.params.eGridCell:this.eEditor.getInputElement()}getValidationErrors(){const{params:e}=this,{getValidationErrors:t}=e,o=this.getValue();return t?t({value:o,internalErrors:null,cellEditorParams:e}):null}}},dependsOn:[fm]},Sm={moduleName:"SelectEditor",version:qe,userComponents:{agSelectCellEditor:class extends il{constructor(){super(Wp,[Ws]),this.eEditor=Go,this.startedByEnter=!1}wireBeans(e){this.valueSvc=e.valueSvc}initialiseEditor(e){this.focusAfterAttached=e.cellStartedEdit;const{eEditor:t,valueSvc:o,gos:s}=this,{values:n,value:r,eventKey:a}=e;if(i(n))return void st(58);this.startedByEnter=null!=a&&a===Pi;let l=!1;n.forEach(i=>{const s={value:i},n=o.formatValue(e.column,null,i),a=null!=n;s.text=a?n:i,t.addOption(s),l=l||r===i}),l?t.setValue(e.value,!0):e.values.length&&t.setValue(e.values[0],!0);const{valueListGap:d,valueListMaxWidth:h,valueListMaxHeight:c}=e;null!=d&&t.setPickerGap(d),null!=c&&t.setPickerMaxHeight(c),null!=h&&t.setPickerMaxWidth(h),"fullRow"!==s.get("editType")&&this.addManagedListeners(this.eEditor,{selectedItem:()=>e.stopEditing()})}afterGuiAttached(){this.focusAfterAttached&&this.eEditor.getFocusableElement().focus(),this.startedByEnter&&setTimeout(()=>{this.isAlive()&&this.eEditor.showPicker()})}focusIn(){this.eEditor.getFocusableElement().focus()}getValue(){return this.eEditor.getValue()}isPopup(){return!1}getValidationElement(){return this.eEditor.getAriaElement()}getValidationErrors(){const{params:e}=this,{values:t,getValidationErrors:o}=e,i=this.getValue();let s=[];if(t&&!t.includes(i)){const e=this.getLocaleTextFunc();s.push(e("invalidSelectionValidation","Invalid selection."))}else s=null;return o?o({value:i,internalErrors:s,cellEditorParams:e}):s}}},dependsOn:[fm]},Em={moduleName:"LargeTextEditor",version:qe,userComponents:{agLargeTextCellEditor:class extends il{constructor(){super(Np,[As]),this.eEditor=Go}initialiseEditor(e){const{eEditor:t}=this,{cellStartedEdit:o,eventKey:i,maxLength:s,cols:n,rows:r}=e;let a;this.focusAfterAttached=o,t.getInputElement().setAttribute("title",""),t.setMaxLength(s||200).setCols(n||60).setRows(r||10),o?(this.focusAfterAttached=!0,i===xi||i===Li?a="":i&&1===i.length?a=i:(a=this.getStartValue(e),i!==Bi&&(this.highlightAllOnFocus=!0))):(this.focusAfterAttached=!1,a=this.getStartValue(e)),null!=a&&t.setValue(a,!0),this.addGuiEventListener("keydown",this.onKeyDown.bind(this)),this.activateTabIndex()}getStartValue(e){const{value:t}=e;return t?.toString()??t}onKeyDown(e){const t=e.key;(t===ki||t===Ti||t===Ii||t===Ai||e.shiftKey&&t===Pi)&&e.stopPropagation()}afterGuiAttached(){const{eEditor:e,focusAfterAttached:t,highlightAllOnFocus:o}=this,i=this.getLocaleTextFunc();e.setInputAriaLabel(i("ariaInputEditor","Input Editor")),t&&(e.getFocusableElement().focus(),o&&e.getInputElement().select())}getValue(){const{eEditor:e,params:t}=this,{value:i}=t,s=e.getValue();return o(s)||o(i)?t.parseValue(s):i}getValidationElement(){return this.eEditor.getInputElement()}getValidationErrors(){const{params:e}=this,{maxLength:t,getValidationErrors:o}=e,i=this.getLocaleTextFunc(),s=this.getValue();let n=[];return"string"==typeof s&&null!=t&&s.length>t&&n.push(i("maxLengthValidation",`Must be ${t} characters or fewer.`,[String(t)])),n.length||(n=null),o?o({value:s,internalErrors:n,cellEditorParams:e}):n}}},dependsOn:[fm]},Rm={moduleName:"CustomEditor",version:qe,dependsOn:[fm]};function xm(e){return Fl(e)?e.pinnedSibling:e.footer?e.sibling:e}function Fm(e,t){return(0!==e||0!==t)&&(e>0&&t>0?void 0:e>0)}function Pm(e){const t=!1===e.isSelected(),o=e.childrenAfterFilter?.some(Pm)??!1;return t||o}var Dm={moduleName:"SharedRowSelection",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="selectionColSvc"}postConstruct(){this.addManagedPropertyListener("rowSelection",e=>{this.onSelectionOptionsChanged(e.currentValue,e.previousValue,Co(e.source))}),this.addManagedPropertyListener("selectionColumnDef",this.updateColumns.bind(this))}addColumns(e){const t=this.columns;null!=t&&(e.list=t.list.concat(e.list),e.tree=t.tree.concat(e.tree),function(e){e.map={},e.list.forEach(t=>e.map[t.getId()]=t)}(e))}createColumns(e,t){const o=e.treeDepth,i=(this.columns?.treeDepth??-1)==o,s=this.generateSelectionCols();var n,r;if((n=s,r=this.columns?.list??[],oo(n,r,(e,t)=>e.getColId()===t.getColId()))&&i)return;(()=>{uo(this.beans,this.columns?.tree),this.columns=null})();const{colGroupSvc:a}=this.beans,l=a?.findDepth(e.tree)??0,d=a?.balanceTreeForAutoCols(s,l)??[];this.columns={list:s,tree:d,treeDepth:l,map:{}};t(e=>{if(!e)return null;const t=e.filter(e=>!po(e));return[...s,...t]})}updateColumns(e){const t=Co(e.source);this.columns?.list.forEach(o=>{const i=this.createSelectionColDef(e.currentValue);o.setColDef(i,null,t),To(this.beans,{state:[{...i,colId:o.getColId()}]},t)})}getColumn(e){return this.columns?.list.find(t=>vo(t,e))??null}getColumns(){return this.columns?.list??null}isSelectionColumnEnabled(){const{gos:e,beans:t}=this,o=e.get("rowSelection");if("object"!=typeof o||!ut(e))return!1;const i=(t.autoColSvc?.getColumns()?.length??0)>0;if("autoGroupColumn"===o.checkboxLocation&&i)return!1;const s=!!Pt(o),n=Dt(o);return s||n}createSelectionColDef(e){const{gos:t}=this,o=e??t.get("selectionColumnDef"),i=t.get("enableRtl"),{rowSpan:s,spanRows:n,...r}=o??{};return{width:50,resizable:!1,suppressHeaderMenuButton:!0,sortable:!1,suppressMovable:!0,lockPosition:i?"right":"left",comparator(e,t,o,i){const s=o.isSelected();return s===i.isSelected()?0:s?1:-1},editable:!1,suppressFillHandle:!0,pinned:null,...r,colId:ao,chartDataType:"excluded"}}generateSelectionCols(){if(!this.isSelectionColumnEnabled())return[];const e=this.createSelectionColDef(),t=e.colId;this.gos.validateColDef(e,t,!0);const o=new _t(e,null,t,!1);return this.createBean(o),[o]}onSelectionOptionsChanged(e,t,o){const i=(t&&"string"!=typeof t?Pt(t):void 0)!==(e&&"string"!=typeof e?Pt(e):void 0),s=(t&&"string"!=typeof t?Dt(t):void 0)!==(e&&"string"!=typeof e?Dt(e):void 0),n=Mt(e),r=Mt(t);(i||s||n!==r)&&this.beans.colModel.refreshAll(o)}destroy(){uo(this.beans,this.columns?.tree),super.destroy()}refreshVisibility(e,t,o){if(!this.columns?.list.length)return;const i=e.length+t.length+o.length;if(0===i)return;const s=this.columns.list[0];if(!s.isVisible())return;const n=this.beans.rowNumbersSvc?.getColumn(lo);(n?2:1)===i&&(()=>{let i;switch(s.pinned){case"left":case!0:i=e;break;case"right":i=o;break;default:i=t}i&&so(i,s)})()}}],apiFunctions:{setNodesSelected:function(e,t){if(!t.nodes.every(e=>e.rowPinned&&!Fl(e)?(st(59),!1):void 0!==e.id||(st(60),!1)))return;const{nodes:o,source:i,newValue:s}=t;e.selectionSvc?.setNodesSelected({nodes:o,source:i??"api",newValue:s})},selectAll:function(e,t,o="apiSelectAll"){e.selectionSvc?.selectAllRowNodes({source:o,selectAll:t})},deselectAll:function(e,t,o="apiSelectAll"){e.selectionSvc?.deselectAllRowNodes({source:o,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()??[]}}},Mm={moduleName:"RowSelection",version:qe,rowModels:["clientSide","infinite","viewport"],beans:[class extends Al{constructor(){super(...arguments),this.beanName="selectionSvc",this.selectedNodes=new Map,this.detailSelection=new Map,this.masterSelectsDetail=!1}postConstruct(){super.postConstruct();const{gos:e}=this;this.mode=Lt(e),this.groupSelectsDescendants=Gt(e),this.groupSelectsFiltered="filteredDescendants"===Ht(e),this.masterSelectsDetail="detail"===Nt(e),this.addManagedPropertyListeners(["groupSelectsChildren","groupSelectsFiltered","rowSelection"],()=>{const t=Gt(e),o=Lt(e),i="filteredDescendants"===Ht(e);this.masterSelectsDetail="detail"===Nt(e),t===this.groupSelectsDescendants&&i===this.groupSelectsFiltered&&o===this.mode||(this.deselectAllRowNodes({source:"api"}),this.groupSelectsDescendants=t,this.groupSelectsFiltered=i,this.mode=o)}),this.addManagedEventListeners({rowSelected:this.onRowSelected.bind(this)})}destroy(){super.destroy(),this.resetNodes()}handleSelectionEvent(e,t,o){if(this.isRowSelectionBlocked(t))return 0;const i=this.inferNodeSelections(t,e.shiftKey,e.metaKey||e.ctrlKey,o);if(null==i)return 0;if(this.selectionCtx.selectAll=!1,"select"in i)return i.reset?this.resetNodes():this.selectRange(i.deselect,!1,o),this.selectRange(i.select,!0,o);{const t=i.checkFilteredNodes?Pm(i.node):i.newValue;return this.setNodesSelected({nodes:[i.node],newValue:t,clearSelection:i.clearSelection,keepDescendants:i.keepDescendants,event:e,source:o})}}setNodesSelected({newValue:e,clearSelection:t,suppressFinishActions:o,nodes:i,event:s,source:n,keepDescendants:r=!1}){const{gos:a}=this;if(!ut(a)&&e)return st(132),0;if(0===i.length)return 0;if(i.length>1&&!this.isMultiSelect())return st(130),0;let l=0;for(let t=0;t<i.length;t++){const o=xm(i[t]);if(o.rowPinned&&!Fl(o)){st(59);continue}if(void 0===o.id){st(60);continue}if(!(this.groupSelectsFiltered&&o.group&&!a.get("treeData"))){this.selectRowNode(o,e,s,n)&&(this.detailSelection.delete(o.id),l++)}this.groupSelectsDescendants&&o.childrenAfterGroup?.length&&(l+=this.selectChildren(o,e,n))}if(!o){1===i.length&&"api"===n&&this.selectionCtx.setRoot(xm(i[0]));e&&(t||!this.isMultiSelect())&&(l+=this.clearOtherNodes(xm(i[0]),r,n)),l>0&&(this.updateGroupsFromChildrenSelections(n),this.dispatchSelectionChanged(n))}return l}selectRange(e,t,o){let i=0;return e.forEach(e=>{const s=xm(e);if(s.group&&this.groupSelectsDescendants)return;this.selectRowNode(s,t,void 0,o)&&i++}),i>0&&(this.updateGroupsFromChildrenSelections(o),this.dispatchSelectionChanged(o)),i}selectChildren(e,t,o){const i=this.groupSelectsFiltered?e.childrenAfterAggFilter:e.childrenAfterGroup;return i?this.setNodesSelected({newValue:t,clearSelection:!1,suppressFinishActions:!0,source:o,nodes:i}):0}getSelectedNodes(){return Array.from(this.selectedNodes.values())}getSelectedRows(){const e=[];return this.selectedNodes.forEach(t=>t.data&&e.push(t.data)),e}getSelectionCount(){return this.selectedNodes.size}filterFromSelection(e){const t=new Map;this.selectedNodes.forEach((o,i)=>{e(o)&&t.set(i,o)}),this.selectedNodes=t}updateGroupsFromChildrenSelections(e,t){if(!this.groupSelectsDescendants)return!1;const{gos:o,rowModel:i}=this.beans;if(!dt(o))return!1;const s=i.rootNode;if(!s)return!1;t||((t=new Ed(!0,s)).active=!1);let n=!1;return t.forEachChangedNodeDepthFirst(t=>{if(t!==s){const o=this.calculateSelectedFromChildren(t);n=this.selectRowNode(t,null!==o&&o,void 0,e)||n}}),n}clearOtherNodes(e,t,o){const i=new Map;let s=0;return this.selectedNodes.forEach(n=>{const r=n.id==e.id;if((!t||!function(e,t){let o=t.parent;for(;o;){if(o===e)return!0;o=o.parent}return!1}(e,n))&&!r){const e=this.selectedNodes.get(n.id);s+=this.setNodesSelected({nodes:[e],newValue:!1,clearSelection:!1,suppressFinishActions:!0,source:o}),this.groupSelectsDescendants&&n.parent&&i.set(n.parent.id,n.parent)}}),i.forEach(e=>{const t=this.calculateSelectedFromChildren(e);this.selectRowNode(e,null!==t&&t,void 0,o)}),s}onRowSelected(e){const 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;const t=new _n(this.beans);return t.id=e.id,t.data=e.data,t.__daemon=!0,t.__selected=e.__selected,t.level=e.level,t}syncInOldRowNode(e,t){if(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){const t=this.getSelectionCount();this.resetNodes(),t&&this.dispatchSelectionChanged(e)}resetNodes(){this.selectedNodes.forEach(e=>{this.selectRowNode(e,!1)}),this.selectedNodes.clear()}getBestCostNodeSelection(){const{gos:e,rowModel:t}=this.beans;if(!dt(e))return;const o=t.getTopLevelNodes();if(null===o)return;const i=[];return function e(t){for(let o=0,s=t.length;o<s;o++){const s=t[o];s.isSelected()?i.push(s):s.group&&s.childrenAfterGroup&&e(s.childrenAfterGroup)}}(o),i}isEmpty(){return 0===this.getSelectionCount()}deselectAllRowNodes({source:e,selectAll:t}){const o=dt(this.gos);let i=!1;const s=t=>{const o=this.selectRowNode(xm(t),!1,void 0,e);i||(i=o)};if("currentPage"===t||"filtered"===t){if(!o)return void nt(102);this.getNodesToSelect(t).forEach(s)}else this.selectedNodes.forEach(s),this.reset(e);if(this.selectionCtx.selectAll=!1,o&&this.groupSelectsDescendants){const t=this.updateGroupsFromChildrenSelections(e);i||(i=t)}i&&this.dispatchSelectionChanged(e)}getSelectedCounts(e){let t=0,o=0;return this.getNodesToSelect(e).forEach(e=>{this.groupSelectsDescendants&&e.group||(e.isSelected()?t++:e.selectable&&o++)}),{selectedCount:t,notSelectedCount:o}}getSelectAllState(e){const{selectedCount:t,notSelectedCount:o}=this.getSelectedCounts(e);return Fm(t,o)??null}hasNodesToSelect(e){return this.getNodesToSelect(e).filter(e=>e.selectable).length>0}getNodesToSelect(e){if(!this.canSelectAll())return[];const t=[],o=e=>t.push(e);if("currentPage"===e)return this.forEachNodeOnPage(e=>{if(e.group){if(!e.expanded&&!e.footer){const t=e=>{o(e),e.childrenAfterFilter?.forEach(t)};return void t(e)}this.groupSelectsDescendants||o(e)}else o(e)}),t;const i=this.beans.rowModel;return"filtered"===e?(i.forEachNodeAfterFilter(o),t):(i.forEachNode(o),t)}forEachNodeOnPage(e){const{pageBounds:t,rowModel:o}=this.beans,i=t.getFirstRow(),s=t.getLastRow();for(let t=i;t<=s;t++){const i=o.getRow(t);i&&e(i)}}selectAllRowNodes(e){const{gos:t,selectionCtx:o}=this;if(!ut(t))return void st(132);if(function(e){return"string"!=typeof e.get("rowSelection")}(t)&&!Bt(t))return void st(130);if(!this.canSelectAll())return;const{source:i,selectAll:s}=e;let n=!1;if(this.getNodesToSelect(s).forEach(e=>{const t=this.selectRowNode(xm(e),!0,void 0,i);n||(n=t)}),o.selectAll=!0,dt(t)&&this.groupSelectsDescendants){const e=this.updateGroupsFromChildrenSelections(i);n||(n=e)}n&&this.dispatchSelectionChanged(i)}getSelectionState(){return this.isEmpty()?null:Array.from(this.selectedNodes.keys())}setSelectionState(e,t,o){if(e||(e=[]),!Array.isArray(e))return void nt(103);const i=new Set(e),s=[];this.beans.rowModel.forEachNode(e=>{i.has(e.id)&&s.push(e)}),o&&this.resetNodes(),this.setNodesSelected({newValue:!0,nodes:s,source:t})}canSelectAll(){const{gos:e}=this.beans;return!!dt(e)}updateSelectable(e){const{gos:t,rowModel:o}=this.beans;if(!ut(t))return;const i="selectableChanged",s=void 0!==e,n=dt(t)&&this.groupSelectsDescendants,r=[],a=e=>{if(s&&!e.group)return;if(n&&e.group){const t=e.childrenAfterGroup?.some(e=>e.selectable)??!1;return void this.setRowSelectable(e,t,!0)}!this.updateRowSelectable(e,!0)&&e.isSelected()&&r.push(e)};if(n){if(void 0===e){const t=o.rootNode;e=t?new Ed(!1,t):void 0}e?.forEachChangedNodeDepthFirst(a,!s,!s)}else o.forEachNode(a);r.length&&this.setNodesSelected({nodes:r,newValue:!1,source:i}),!s&&n&&this.updateGroupsFromChildrenSelections?.(i)}updateSelectableAfterGrouping(e){if(this.updateSelectable(e),this.groupSelectsDescendants){const t=this.updateGroupsFromChildrenSelections?.("rowGroupChanged",e);t&&this.dispatchSelectionChanged("rowGroupChanged")}}refreshMasterNodeState(e,t){if(!this.masterSelectsDetail)return;const o=e.detailNode?.detailGridInfo?.api;if(!o)return;const i=function(e){let t=0,o=0;return e.forEachNode(e=>{e.isSelected()?t++:e.selectable&&o++}),Fm(t,o)}(o);if(e.isSelected()!==i){this.selectRowNode(e,i,t,"masterDetail")&&this.dispatchSelectionChanged("masterDetail")}if(!i){const t=this.detailSelection.get(e.id)??new Set;for(const e of o.getSelectedNodes())t.add(e.id);this.detailSelection.set(e.id,t)}}setDetailSelectionState(e,t,o){if(this.masterSelectsDetail)if(Bt(t))switch(e.isSelected()){case!0:o.selectAll();break;case!1:o.deselectAll();break;case void 0:{const t=this.detailSelection.get(e.id);if(t){const e=[];for(const i of t){const t=o.getRowNode(i);t&&e.push(t)}o.setNodesSelected({nodes:e,newValue:!0,source:"masterDetail"})}break}}else st(269)}dispatchSelectionChanged(e){this.eventSvc.dispatchEvent({type:"selectionChanged",source:e,selectedNodes:this.getSelectedNodes(),serverSideState:null})}}],dependsOn:[Dm]};function km(e){e.rowModel?.onRowHeightChanged()}function Tm(e){e.rowAutoHeight?.active?st(3):e.rowModel?.resetRowHeights()}var Im={moduleName:"CsrmSsrmSharedApi",version:qe,apiFunctions:{expandAll:function(e){e.expansionSvc?.expandAll(!0)},collapseAll:function(e){e.expansionSvc?.expandAll(!1)}}},Am={moduleName:"RowModelSharedApi",version:qe,apiFunctions:{onRowHeightChanged:km,resetRowHeights:Tm}},Lm={moduleName:"SsrmInfiniteSharedApi",version:qe,apiFunctions:{setRowCount:function(e,t,o){const i=function(e){const t=e.rowModel;return"serverSide"===t.getType()?t:void 0}(e);if(i)return 0===e.rowGroupColsSvc?.columns.length?t<0?void nt(238):void i.setRowCount(t,o):void nt(28);const s=fd(e);s&&s.setRowCount(t,o)},getCacheBlockState:function(e){if(ht(e.gos)){return e.rowModel.getBlockStates()}return e.rowNodeBlockLoader?.getBlockState()??{}},isLastRowIndexKnown:function(e){return e.rowModel.isLastRowIndexKnown()}}},Bm={moduleName:"AlignedGrids",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="alignedGridsSvc",this.consuming=!1}getAlignedGridApis(){let e=this.gos.get("alignedGrids")??[];const t="function"==typeof e;"function"==typeof e&&(e=e());return e.map(e=>{if(!e)return nt(18),void(t||nt(20));if(this.isGridApi(e))return e;const o=e;return"current"in o?o.current?.api:(o.api||nt(19),o.api)}).filter(e=>!!e&&!e.isDestroyed())}isGridApi(e){return!!e&&!!e.dispatchEvent}postConstruct(){const e=this.fireColumnEvent.bind(this);this.addManagedEventListeners({columnMoved:e,columnVisible:e,columnPinned:e,columnGroupOpened:e,columnResized:e,bodyScroll:this.fireScrollEvent.bind(this),alignedGridColumn:({event:e})=>this.onColumnEvent(e),alignedGridScroll:({event:e})=>this.onScrollEvent(e)})}fireEvent(e){this.consuming||this.getAlignedGridApis().forEach(t=>{t.isDestroyed()||t.dispatchEvent(e)})}onEvent(e){this.consuming=!0,e(),this.consuming=!1}fireColumnEvent(e){this.fireEvent({type:"alignedGridColumn",event:e})}fireScrollEvent(e){"horizontal"===e.direction&&this.fireEvent({type:"alignedGridScroll",event:e})}onScrollEvent(e){this.onEvent(()=>{this.beans.ctrlsSvc.getScrollFeature().setHorizontalScrollPosition(e.left,!0)})}extractDataFromEvent(e,t){const o=[];return e.columns?e.columns.forEach(e=>{o.push(t(e))}):e.column&&o.push(t(e.column)),o}getMasterColumns(e){return this.extractDataFromEvent(e,e=>e)}getColumnIds(e){return this.extractDataFromEvent(e,e=>e.getColId())}onColumnEvent(e){this.onEvent(()=>{switch(e.type){case"columnMoved":case"columnVisible":case"columnPinned":case"columnResized":this.processColumnEvent(e);break;case"columnGroupOpened":this.processGroupOpenedEvent(e);break;case"columnPivotChanged":st(21)}})}processGroupOpenedEvent(e){const{colGroupSvc:t}=this.beans;t&&e.columnGroups.forEach(e=>{let o=null;e&&(o=t.getProvidedColGroup(e.getGroupId())),e&&!o||t.setColumnGroupOpened(o,e.isExpanded(),"alignedGridChanged")})}processColumnEvent(e){const t=e.column;let o=null;const i=this.beans,{colResize:s,ctrlsSvc:n,colModel:r}=i;if(t&&(o=r.getColDefCol(t.getColId())),t&&!o)return;const a=this.getMasterColumns(e);switch(e.type){case"columnMoved":To(i,{state:e.api.getColumnState().map(e=>({colId:e.colId})),applyOrder:!0},"alignedGridChanged");break;case"columnVisible":To(i,{state:e.api.getColumnState().map(e=>({colId:e.colId,hide:e.hide}))},"alignedGridChanged");break;case"columnPinned":To(i,{state:e.api.getColumnState().map(e=>({colId:e.colId,pinned:e.pinned}))},"alignedGridChanged");break;case"columnResized":{const t=e,o={};a.forEach(e=>{o[e.getId()]={key:e.getColId(),newWidth:e.getActualWidth()}}),t.flexColumns?.forEach(e=>{o[e.getId()]&&delete o[e.getId()]}),s?.setColumnWidths(Object.values(o),!1,t.finished,"alignedGridChanged");break}}const l=n.getGridBodyCtrl().isVerticalScrollShowing();this.getAlignedGridApis().forEach(e=>{e.setGridOption("alwaysShowVerticalScroll",l)})}}],dependsOn:[Ch]},Hm=class{constructor(){this.removals=new Set,this.updates=new Set,this.adds=new Set}remove(e){this.adds.delete(e)||(this.updates.delete(e),this.removals.add(e))}update(e){this.adds.has(e)||this.updates.add(e)}add(e){this.adds.add(e)}},Vm=e=>{const t=e.childrenAfterSort,o=e.sibling;if(o&&(o.childrenAfterSort=t),t)for(let e=0,o=t.length-1;e<=o;e++){const i=t[e],s=0===e,n=e===o;i.firstChild!==s&&(i.firstChild=s,i.dispatchRowEvent("firstChildChanged")),i.lastChild!==n&&(i.lastChild=n,i.dispatchRowEvent("lastChildChanged")),i.childIndex!==e&&(i.childIndex=e,i.dispatchRowEvent("childIndexChanged"))}},Gm=(e,t,o,i,s)=>{const n=t.childrenAfterAggFilter,r=t.childrenAfterSort;if(!r)return e.doFullSort(n,s);const a=new Set,l=[],{updates:d,adds:h}=o;for(let e=0,t=n.length;e<t;++e){const t=n[e];d.has(t)||h.has(t)||i&&!i.canSkip(t)?l.push({currentPos:l.length,rowNode:t}):a.add(t)}const c=r.filter(e=>a.has(e)).map((e,t)=>({currentPos:t,rowNode:e}));return l.sort((t,o)=>e.compareRowNodes(s,t,o)),Nm(e,s,l,c)},Nm=(e,t,o,i)=>{let s=0,n=0;const r=o.length,a=i.length,l=new Array(r+a);let d=0;for(;s<r&&n<a;){const r=o[s],a=i[n];e.compareRowNodes(t,r,a)<0?(l[d++]=r.rowNode,++s):(l[d++]=a.rowNode,++n)}for(;s<r;)l[d++]=o[s++].rowNode;for(;n<a;)l[d++]=i[n++].rowNode;return l},Om=e=>{const t=e.childrenAfterSort,o=e.childrenAfterAggFilter,i=t?.length,s=o?.length;if(!i||!s)return null;const n=new Array(s),r=new Set;for(let e=0;e<s;++e)r.add(o[e]);let a=0;for(let e=0;e<i;++e){const o=t[e];r.delete(o)&&(n[a++]=o)}if(0===r.size&&a===i)return t;for(const e of r)n[a++]=e;return n.length=a,n};var zm={moduleName:"ClientSideRowModel",version:qe,rowModels:["clientSide"],beans:[class extends xl{constructor(){super(...arguments),this.beanName="csrmNodeSvc"}},class extends Me{constructor(){super(...arguments),this.beanName="rowModel",this.rootNode=null,this.rowsToDisplay=[],this.rowDataUpdatedPending=!1,this.started=!1,this.isRefreshingModel=!1,this.rowNodesCountReady=!1,this.rowCountReady=!1,this.onRowHeightChanged_debounced=Be(this,this.onRowHeightChanged.bind(this),100)}wireBeans(e){this.colModel=e.colModel,this.valueCache=e.valueCache,this.filterStage=e.filterStage,this.sortStage=e.sortStage,this.flattenStage=e.flattenStage,this.groupStage=e.groupStage,this.aggStage=e.aggStage,this.pivotStage=e.pivotStage,this.filterAggStage=e.filterAggStage}postConstruct(){this.orderedStages=[this.groupStage,this.filterStage,this.pivotStage,this.aggStage,this.sortStage,this.filterAggStage,this.flattenStage].filter(e=>!!e);const e=this.refreshModel.bind(this,{step:"group"}),t=this.refreshModel.bind(this,{step:"group",afterColumnsChanged:!0,keepRenderedRows:!0,animate:!this.gos.get("suppressAnimationFrame")});this.addManagedEventListeners({newColumnsLoaded:t,columnRowGroupChanged:e,columnValueChanged:this.onValueChanged.bind(this),columnPivotChanged:this.refreshModel.bind(this,{step:"pivot"}),filterChanged:this.onFilterChanged.bind(this),sortChanged:this.onSortChanged.bind(this),columnPivotModeChanged:e,gridStylesChanged:this.onGridStylesChanges.bind(this),gridReady:this.onGridReady.bind(this),rowExpansionStateChanged:this.onRowGroupOpened.bind(this)}),this.addPropertyListeners(),this.rootNode=new _n(this.beans);const o=this.getNewNodeManager();this.nodeManager=o,o.activate(this.rootNode)}getNewNodeManager(){const{gos:e,beans:t}=this;return"treeNested"===Wt(e)&&t.csrmChildrenTreeNodeSvc||t.csrmNodeSvc}addPropertyListeners(){const e=["treeData","treeDataChildrenField",...this.orderedStages.flatMap(({refreshProps:e})=>[...e])];this.addManagedPropertyListeners(e,e=>{const 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,o,i){let s,n=!1;do{s=!1;const r=this.getRowIndexAtPixel(e),a=this.getRowIndexAtPixel(t),l=Math.max(r,o),d=Math.min(a,i);for(let e=l;e<=d;e++){const t=this.getRow(e);if(t.rowHeightEstimated){const e=pt(this.beans,t);t.setRowHeight(e.height),s=!0,n=!0}}s&&this.setRowTopAndRowIndex()}while(s);return n}onPropChange(e){if(!this.rootNode)return;const t=this.gos,o=new Set(e),i={step:"nothing",changedProps:o},s=o.has("rowData"),n=this.nodeManager,r=this.getNewNodeManager(),a=n!==r||s&&o.has("treeData")&&t.get("treeData")||o.has("treeDataChildrenField")&&t.get("treeData");let l;if((a||s)&&(l=t.get("rowData"),null==l||Array.isArray(l)||(l=null,st(1))),a&&(s||(l=n?.extractRowData()??l),n!==r&&(n?.deactivate(),this.nodeManager=r),r.activate(this.rootNode)),l){if(!a&&!this.isEmpty()&&l.length>0&&t.exists("getRowId")&&!t.get("resetRowDataOnUpdate"))i.keepRenderedRows=!0,i.animate=!this.gos.get("suppressAnimationFrame"),i.changedRowNodes=new Hm,r.setImmutableRowData(i,l);else{i.rowDataUpdated=!0,i.newData=!0;const{selectionSvc:e,pinnedRowModel:t}=this.beans;e?.reset("rowDataChanged"),t?.isManual()&&t.reset(),this.rowNodesCountReady=!0,r.setNewRowData(l)}}if(i.rowDataUpdated)i.step="group";else if("nothing"===i.step)for(const{refreshProps:t,step:o}of this.orderedStages)if(e.some(e=>t.has(e))){i.step=o;break}"nothing"!==i.step&&this.refreshModel(i)}setRowTopAndRowIndex(){const{beans:e,rowsToDisplay:t}=this,o=e.environment.getDefaultRowHeight();let i=0;const s=new Set,n=ct(this.gos,"normal");for(let r=0,a=t.length;r<a;++r){const a=t[r];if(null!=a.id&&s.add(a.id),null==a.rowHeight){const t=pt(e,a,n,o);a.setRowHeight(t.height,t.estimated)}a.setRowTop(i),a.setRowIndex(r),i+=a.rowHeight}return s}clearRowTopAndRowIndex(e,t){const o=e.active,i=e=>{e&&null!=e.id&&!t.has(e.id)&&e.clearRowTopAndRowIndex()},s=e=>{if(null!==e&&(i(e),i(e.detailNode),i(e.sibling),e.hasChildren()&&e.childrenAfterGroup)){const t=-1==e.level;o&&!t&&!e.expanded||e.childrenAfterGroup.forEach(s)}};s(this.rootNode)}isLastRowIndexKnown(){return!0}getRowCount(){return this.rowsToDisplay?this.rowsToDisplay.length:0}getTopLevelRowCount(){const e=this.rootNode;if(!e)return 0;if(0===this.rowsToDisplay.length)return 0;if(this.rowsToDisplay&&this.rowsToDisplay[0]===e)return 1;const t=e.childrenAfterSort,o=e.sibling&&e.sibling.displayed?1:0;return(t?t.length:0)+o}getTopLevelRowDisplayedIndex(e){const{rootNode:t,rowsToDisplay:o}=this;if(!t||!o.length||o[0]===t)return e;const{childrenAfterSort:i}=t,s=e=>{let t=i[e];if(this.gos.get("groupHideOpenParents"))for(;t.expanded&&t.childrenAfterSort&&t.childrenAfterSort.length>0;)t=t.childrenAfterSort[0];return t.rowIndex},{footerSvc:n}=this.beans;return n?n.getTopDisplayIndex(o,e,i,s):s(e)}getTopLevelIndexFromDisplayedIndex(e){const{rootNode:t,rowsToDisplay:o}=this;if(!t||!o.length||o[0]===t)return e;let i=this.getRow(e);for(i.footer&&(i=i.sibling);i.parent&&i.parent!==t;)i=i.parent;const s=t.childrenAfterSort?.findIndex(e=>e===i);return-1===s?e:s??e}getRowBounds(e){const t=this.rowsToDisplay[e];return t?{rowTop:t.rowTop,rowHeight:t.rowHeight}:null}onRowGroupOpened(){const e=wt(this.gos);this.refreshModel({step:"map",keepRenderedRows:!0,animate:e})}onFilterChanged(e){if(e.afterDataChange)return;const t=wt(this.gos),o=0===e.columns.length||e.columns.some(e=>e.isPrimary())?"filter":"filter_aggregates";this.refreshModel({step:o,keepRenderedRows:!0,animate:t})}onSortChanged(){const e=wt(this.gos);this.refreshModel({step:"sort",keepRenderedRows:!0,animate:e})}getType(){return"clientSide"}onValueChanged(){this.refreshModel({step:this.colModel.isPivotActive()?"pivot":"aggregate"})}createChangePath(e){const t=new Ed(!1,this.rootNode);return e||(t.active=!1),t}isSuppressModelUpdateAfterUpdateTransaction(e){if(!this.gos.get("suppressModelUpdateAfterUpdateTransaction"))return!1;const{changedRowNodes:t,newData:o,rowDataUpdated:i}=e;return!(!t||o||!i)&&(!t.removals.size&&!t.adds.size)}refreshModel(e){if(!this.rootNode)return;const t=this.beans;let o=!!e.rowDataUpdated;const i=e.changedPath??(e.changedPath=this.createChangePath(!e.newData&&o));if(this.started&&o&&this.eventSvc.dispatchEvent({type:"rowDataUpdated"}),!this.started||this.isRefreshingModel||this.colModel.changeEventsDispatching||this.isSuppressModelUpdateAfterUpdateTransaction(e))return void(this.rowDataUpdatedPending||(this.rowDataUpdatedPending=o));switch(this.rowDataUpdatedPending&&(this.rowDataUpdatedPending=!1,e.rowDataUpdated=o=!0,e.step="group"),this.isRefreshingModel=!0,t.masterDetailSvc?.refreshModel(e),o&&"group"!==e.step&&t.colFilter?.refreshModel(),e.step){case"group":(this.doRowGrouping(e)||o)&&t.colFilter?.refreshModel(),!this.rowCountReady&&this.rowNodesCountReady&&(this.rowCountReady=!0,this.eventSvc.dispatchEventOnce({type:"rowCountReady"}));case"filter":this.doFilter(i);case"pivot":this.doPivot(i);case"aggregate":this.doAggregate(i);case"filter_aggregates":this.doFilterAggregates(i);case"sort":this.doSort(e.changedRowNodes,i);case"map":this.doRowsToDisplay()}const s=this.setRowTopAndRowIndex();this.clearRowTopAndRowIndex(i,s),this.isRefreshingModel=!1,this.eventSvc.dispatchEvent({type:"modelUpdated",animate:e.animate,keepRenderedRows:e.keepRenderedRows,newData:e.newData,newPage:!1,keepUndoRedoStack:e.keepUndoRedoStack})}isEmpty(){return!this.rootNode?.allLeafChildren?.length||!this.colModel?.ready}isRowsToRender(){return this.rowsToDisplay.length>0}getNodesInRangeForSelection(e,t){let o=!1,i=!1;const s=[],n=Gt(this.gos);return this.forEachNodeAfterFilterAndSort(r=>{if(i)return;if(o&&(r===t||r===e)&&(i=!0,r.group&&n))return void s.push(...r.allLeafChildren);if(!o){if(r!==t&&r!==e)return;o=!0,t===e&&(i=!0)}(!r.group||!n)&&s.push(r)}),s}getTopLevelNodes(){return this.rootNode?.childrenAfterGroup??null}getRow(e){return this.rowsToDisplay[e]}isRowPresent(e){return this.rowsToDisplay.indexOf(e)>=0}getRowIndexAtPixel(e){const t=this.rowsToDisplay;if(this.isEmpty()||0===t.length)return-1;let o=0,i=t.length-1;if(e<=0)return 0;if(to(t).rowTop<=e)return t.length-1;let s=-1,n=-1;for(;;){const r=Math.floor((o+i)/2),a=t[r];if(this.isRowInPixel(a,e))return r;a.rowTop<e?o=r+1:a.rowTop>e&&(i=r-1);if(s===o&&n===i)return r;s=o,n=i}}isRowInPixel(e,t){const o=e.rowTop,i=e.rowTop+e.rowHeight;return o<=t&&i>t}forEachLeafNode(e){this.rootNode?.allLeafChildren?.forEach((t,o)=>e(t,o))}forEachNode(e,t=!1){this.depthFirstSearchRowNodes(e,t)}forEachDisplayedNode(e){this.rowsToDisplay.forEach(e)}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=!1,o=!1){const{colModel:i,rowGroupColsSvc:s}=this.beans;if(!i.isPivotMode())return;if(!s?.columns.length)return void e(this.rootNode,0);const n=o?"childrenAfterSort":"childrenAfterGroup";this.depthFirstSearchRowNodes(e,t,e=>e.leafGroup?null:e[n])}depthFirstSearchRowNodes(e,t=!1,o=e=>e.childrenAfterGroup,i=this.rootNode,s=0){let n=s;if(!i)return n;const r=i===this.rootNode;r||e(i,n++);const{footerSvc:a}=this.beans;if(i.hasChildren()&&!i.footer){const s=o(i);if(s){n=a?.addTotalRows(n,i,e,t,r,"top")??n;for(const i of s)n=this.depthFirstSearchRowNodes(e,t,o,i,n);return a?.addTotalRows(n,i,e,t,r,"bottom")??n}}return n}doAggregate(e){const t=this.rootNode;t&&this.aggStage?.execute({rowNode:t,changedPath:e})}doFilterAggregates(e){const t=this.rootNode;this.filterAggStage?this.filterAggStage.execute({rowNode:t,changedPath:e}):t.childrenAfterAggFilter=t.childrenAfterFilter}doSort(e,t){this.sortStage?this.sortStage.execute({rowNode:this.rootNode,changedRowNodes:e,changedPath:t}):t.forEachChangedNodeDepthFirst(e=>{e.childrenAfterSort=e.childrenAfterAggFilter.slice(0),Vm(e)})}doRowGrouping(e){const t=this.rootNode,o=this.groupStage?.execute({rowNode:t,changedRowNodes:e.changedRowNodes,changedPath:e.changedPath,rowNodesOrderChanged:!!e.rowNodesOrderChanged,afterColumnsChanged:!!e.afterColumnsChanged});if(void 0!==o)return o;const i=t.sibling;return t.childrenAfterGroup=t.allLeafChildren,i&&(i.childrenAfterGroup=t.childrenAfterGroup),t.updateHasChildren(),!1}doFilter(e){this.filterStage?this.filterStage.execute({rowNode:this.rootNode,changedPath:e}):e.forEachChangedNodeDepthFirst(e=>{e.childrenAfterFilter=e.childrenAfterGroup,Ig(e)},!0)}doPivot(e){this.pivotStage?.execute({rowNode:this.rootNode,changedPath:e})}getRowNode(e){const t=this.nodeManager.getRowNode(e);if("object"==typeof t)return t;return"string"==typeof e&&0===e.indexOf($n)?this.groupStage?.getNode(e):void 0}batchUpdateRowData(e,t){if(null==this.applyAsyncTransactionsTimeout){this.rowDataTransactionBatch=[];const e=this.gos.get("asyncTransactionWaitMillis");this.applyAsyncTransactionsTimeout=window.setTimeout(()=>{this.isAlive()&&this.executeBatchUpdateRowData()},e)}this.rowDataTransactionBatch.push({rowDataTransaction:e,callback:t})}flushAsyncTransactions(){null!=this.applyAsyncTransactionsTimeout&&(clearTimeout(this.applyAsyncTransactionsTimeout),this.executeBatchUpdateRowData())}executeBatchUpdateRowData(){this.valueCache?.onDataChanged();const e=[],t=[],o=new Hm;let i=!1;this.rowDataTransactionBatch?.forEach(s=>{this.rowNodesCountReady=!0;const{rowNodeTransaction:n,rowsInserted:r}=this.nodeManager.updateRowData(s.rowDataTransaction,o);r&&(i=!0),t.push(n),s.callback&&e.push(s.callback.bind(null,n))}),this.commitTransactions(i,o),e.length>0&&window.setTimeout(()=>{e.forEach(e=>e())},0),t.length>0&&this.eventSvc.dispatchEvent({type:"asyncTransactionsFlushed",results:t}),this.rowDataTransactionBatch=null,this.applyAsyncTransactionsTimeout=void 0}updateRowData(e){this.valueCache?.onDataChanged(),this.rowNodesCountReady=!0;const t=new Hm,{rowNodeTransaction:o,rowsInserted:i}=this.nodeManager.updateRowData(e,t);return this.commitTransactions(i,t),o}commitTransactions(e,t){this.refreshModel({step:"group",rowDataUpdated:!0,rowNodesOrderChanged:e,keepRenderedRows:!0,animate:!this.gos.get("suppressAnimationFrame"),changedRowNodes:t,changedPath:this.createChangePath(!0)})}doRowsToDisplay(){const{flattenStage:e,rootNode:t}=this;let o;if(e)o=e.execute({rowNode:t});else{o=t?.childrenAfterSort??[];for(const e of o)e.setUiLevel(0)}this.rowsToDisplay=o}onRowHeightChanged(){this.refreshModel({step:"map",keepRenderedRows:!0,keepUndoRedoStack:!0})}resetRowHeights(){const e=this.rootNode;if(!e)return;const t=this.resetRowHeightsForAllRowNodes();e.setRowHeight(e.rowHeight,!0),e.sibling&&e.sibling.setRowHeight(e.sibling.rowHeight,!0),t&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode(t=>{t.setRowHeight(t.rowHeight,!0);const o=t.detailNode;o&&o.setRowHeight(o.rowHeight,!0),t.sibling&&t.sibling.setRowHeight(t.sibling.rowHeight,!0),e=!0}),e}onGridStylesChanges(e){if(e.rowHeightChanged){if(this.beans.rowAutoHeight?.active)return;this.resetRowHeights()}}onGridReady(){this.started||this.setInitialData()}isRowDataLoaded(){return this.rowCountReady}destroy(){super.destroy(),this.started=!1,this.rootNode=null,this.nodeManager=null,this.rowDataTransactionBatch=null,this.orderedStages=eo,this.rowsToDisplay=eo}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}},class extends Me{constructor(){super(...arguments),this.beanName="sortStage",this.refreshProps=new Set(["postSortRows","groupDisplayType","accentedSort"]),this.step="sort"}execute(e){const t=this.beans.sortSvc.getSortOptions(),o=t.length>0&&!!e.changedRowNodes&&this.gos.get("deltaSort");this.sort(t,o,e.changedRowNodes,e.changedPath)}sort(e,t,o,i){const{gos:s,colModel:n,rowGroupColsSvc:r,rowNodeSorter:a,rowRenderer:l,showRowGroupCols:d}=this.beans,h=s.get("groupMaintainOrder"),c=n.getCols().some(e=>e.isRowGroupActive()),u=r?.columns,g=n.isPivotMode(),p=s.getCallback("postSortRows");let m,f=!1;if(i?.forEachChangedNodeDepthFirst(s=>{const n=g&&s.leafGroup;let r=h&&c&&!s.leafGroup;r&&(m??(m=this.shouldSortContainsGroupCols(e)),r&&(r=!m));let l=null;if(r){let e=!1;if(u){const t=s.level+1;t<u.length&&(e=null===u[t].getSort())}e||(l=Om(s))}else l=!e.length||n?null:t&&o?Gm(a,s,o,i,e):a.doFullSort(s.childrenAfterAggFilter,e);if(l||(l=s.childrenAfterAggFilter?.slice(0)??[]),f||(f=s.childrenAfterSort?.[0]!==l[0]),s.childrenAfterSort=l,Vm(s),p){const e={nodes:s.childrenAfterSort};p(e)}}),f&&s.get("groupHideOpenParents")){const e=d?.getShowRowGroupCols();e?.length&&l.refreshCells({columns:e,force:!0})}}shouldSortContainsGroupCols(e){const t=e.length;if(!t)return!1;if(yt(this.gos)){for(let o=0;o<t;++o){const t=e[o].column;if(t.isPrimary()&&t.isRowGroupActive())return!0}return!1}for(let o=0;o<t;++o)if(e[o].column.getColDef().showRowGroup)return!0;return!1}}],dependsOn:[Yu]},Wm={moduleName:"ClientSideRowModelApi",version:qe,apiFunctions:{onGroupExpandedOrCollapsed:function(e){e.expansionSvc?.onGroupExpandedOrCollapsed()},refreshClientSideRowModel:function(e,t){const o=md(e);o&&(t&&"everything"!==t||(t="group"),o.refreshModel({step:t,keepRenderedRows:!0,animate:!e.gos.get("suppressAnimationFrame")}))},isRowDataEmpty:function(e){return md(e)?.isEmpty()??!0},forEachLeafNode:function(e,t){md(e)?.forEachLeafNode(t)},forEachNodeAfterFilter:function(e,t){md(e)?.forEachNodeAfterFilter(t)},forEachNodeAfterFilterAndSort:function(e,t){md(e)?.forEachNodeAfterFilterAndSort(t)},applyTransaction:function(e,t){return e.frameworkOverrides.wrapIncoming(()=>md(e)?.updateRowData(t))},applyTransactionAsync:function(e,t,o){e.frameworkOverrides.wrapIncoming(()=>md(e)?.batchUpdateRowData(t,o))},flushAsyncTransactions:function(e){e.frameworkOverrides.wrapIncoming(()=>md(e)?.flushAsyncTransactions())},getBestCostNodeSelection:function(e){return e.selectionSvc?.getBestCostNodeSelection()},resetRowHeights:Tm,onRowHeightChanged:km},dependsOn:[Im,Am]},Um={moduleName:"SharedExport",version:qe,beans:[class extends Me{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={}){const{allColumns:o,columnKeys:i,skipRowGroups:s,exportRowNumbers:n}=t,r=this.getColumnsToExport({allColumns:o,skipRowGroups:s,columnKeys:i,exportRowNumbers:n});return[this.prepareSession(r),this.prependContent(t),this.exportColumnGroups(t,r),this.exportHeaders(t,r),this.processPinnedTopRows(t,r),this.processRows(t,r),this.processPinnedBottomRows(t,r),this.appendContent(t)].reduce((e,t)=>t(e),e).parse()}processRow(e,t,o,i){const s=t.shouldRowBeSkipped||(()=>!1),n=null!=t.rowPositions||!!t.onlySelected,r=this.gos.get("groupHideOpenParents")&&!n,a=this.colModel.isPivotMode()?i.leafGroup:!i.group,l=!!i.footer,d=1===i.allChildrenCount&&1===i.childrenAfterGroup?.length&&function(e,t){const o=e.get("groupHideParentOfSingleChild");return!0===o||!("leafGroupsOnly"!==o||!t.leafGroup)||!!e.get("groupRemoveSingleChildren")||!(!e.get("groupRemoveLowestSingleChildren")||!t.leafGroup)}(this.gos,i);if(!a&&!l&&(t.skipRowGroups||d||r)||t.onlySelected&&!i.isSelected()||t.skipPinnedTop&&"top"===i.rowPinned||t.skipPinnedBottom&&"bottom"===i.rowPinned||i.stub)return;if(-1===i.level&&!a&&!l)return;if(s(zt(this.gos,{node:i})))return;const h=e.onNewBodyRow(i);if(o.forEach((e,t)=>{h.onColumn(e,t,i)}),t.getCustomContentBelowRow){const o=t.getCustomContentBelowRow(zt(this.gos,{node:i}));o&&e.addCustomContent(o)}}appendContent(e){return t=>{const o=e.appendContent;return o&&t.addCustomContent(o),t}}prependContent(e){return t=>{const o=e.prependContent;return o&&t.addCustomContent(o),t}}prepareSession(e){return t=>(t.prepare(e),t)}exportColumnGroups(e,t){return o=>{if(!e.skipColumnGroupHeaders){const i=new Ho,{colGroupSvc:s}=this.beans,n=s?s.createColumnGroups({columns:t,idCreator:i,pinned:null,isStandaloneStructure:!0}):t;this.recursivelyAddHeaderGroups(n,o,e.processGroupHeaderCallback)}return o}}exportHeaders(e,t){return o=>{if(!e.skipColumnHeaders){const e=o.onNewHeaderRow();t.forEach((t,o)=>{e.onColumn(t,o,void 0)})}return o}}processPinnedTopRows(e,t){return o=>{const i=this.processRow.bind(this,o,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),o}}processRows(e,t){return o=>{const i=this.rowModel,s=dt(this.gos),n=ht(this.gos),r=!s&&e.onlySelected,a=this.processRow.bind(this,o,e,t),{exportedRows:l="filteredAndSorted"}=e;if(e.rowPositions)return e.rowPositions.filter(e=>null==e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>i.getRow(e.rowIndex)).forEach(a),o;if(this.colModel.isPivotMode())return s?i.forEachPivotNode(a,!0,"filteredAndSorted"===l):n?i.forEachNodeAfterFilterAndSort(a,!0):i.forEachNode(a),o;if(e.onlySelectedAllPages||r){const e=this.beans.selectionSvc?.getSelectedNodes()??[];this.replicateSortedOrder(e),e.forEach(a)}else"all"===l?i.forEachNode(a):s||n?i.forEachNodeAfterFilterAndSort(a,!0):i.forEachNode(a);return o}}replicateSortedOrder(e){const{sortSvc:t,rowNodeSorter:o}=this.beans;if(!t||!o)return;const i=t.getSortOptions(),s=(e,t)=>null!=e.rowIndex&&null!=t.rowIndex?e.rowIndex-t.rowIndex:e.level===t.level?e.parent?.id===t.parent?.id?o.compareRowNodes(i,{rowNode:e,currentPos:e.rowIndex??-1},{rowNode:t,currentPos:t.rowIndex??-1}):s(e.parent,t.parent):e.level>t.level?s(e.parent,t):s(e,t.parent);e.sort(s)}processPinnedBottomRows(e,t){return o=>{const i=this.processRow.bind(this,o,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),o}}getColumnsToExport(e){const{allColumns:t=!1,skipRowGroups:o=!1,exportRowNumbers:i=!1,columnKeys:s}=e,{colModel:n,gos:r,visibleCols:a}=this,l=n.isPivotMode(),d=e=>!po(e)&&(!mo(e)||i);if(s&&s.length)return n.getColsForKeys(s).filter(d);const h=r.get("treeData");let c=[];return c=t&&!l?n.getCols():a.allCols,c=c.filter(e=>d(e)&&(!(o&&!h)||!go(e))),c}recursivelyAddHeaderGroups(e,t,o){const i=[];e.forEach(e=>{const t=e;t.getChildren&&t.getChildren().forEach(e=>i.push(e))}),e.length>0&&Wn(e[0])&&this.doAddHeaderHeader(t,e,o),i&&i.length>0&&this.recursivelyAddHeaderGroups(i,t,o)}doAddHeaderHeader(e,t,o){const i=e.onNewHeaderGroupingRow();let s=0;t.forEach(e=>{const t=e;let n;n=o?o(zt(this.gos,{columnGroup:t})):this.beans.colNames.getDisplayNameForColumnGroup(t,"header");const r=(t.isExpandable()?t.getLeafColumns():[]).reduce((e,t,o,i)=>{let s=to(e);return"open"===t.getColumnGroupShow()?s&&null==s[1]||(s=[o],e.push(s)):s&&null==s[1]&&(s[1]=o-1),o===i.length-1&&s&&null==s[1]&&(s[1]=o),e},[]);i.onColumn(t,n||"",s++,t.getLeafColumns().length-1,r)})}}]},$m=class extends wg{constructor(e){super(e),this.config=e,this.isFirstLine=!0,this.result="";const{suppressQuotes:t,columnSeparator:o}=e;this.suppressQuotes=t,this.columnSeparator=o}addCustomContent(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,o,i){0!=o&&(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,o){0!=t&&(this.result+=this.columnSeparator);const i=this.extractRowCellValue(e,t,t,"csv",o);this.result+=this.putInQuotes(i.valueFormatted??i.value)}putInQuotes(e){if(this.suppressQuotes)return e;if(null==e)return'""';let t;"string"==typeof e?t=e:"function"==typeof e.toString?t=e.toString():(st(53),t="");return'"'+t.replace(/"/g,'""')+'"'}parse(){return this.result}beginNewLine(){this.isFirstLine||(this.result+="\r\n"),this.isFirstLine=!1}};var Km={moduleName:"CsvExport",version:qe,beans:[class extends vg{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){const t=this.gos.get("defaultCsvExportParams");return Object.assign({},t,e)}export(e){if(this.isExportSuppressed())return void st(51);const t=this.getMergedParams(e),o=this.getData(t),i=new Blob(["\ufeff",o],{type:"text/plain"}),s="function"==typeof t.fileName?t.fileName(zt(this.gos,{})):t.fileName;!function(e,t){const o=document.defaultView||window;if(!o)return void st(52);const i=document.createElement("a"),s=o.URL.createObjectURL(t);i.setAttribute("href",s),i.setAttribute("download",e),i.style.display="none",document.body.appendChild(i),i.dispatchEvent(new MouseEvent("click",{bubbles:!1,cancelable:!0,view:o})),document.body.removeChild(i),o.setTimeout(()=>{o.URL.revokeObjectURL(s)},0)}(this.getFileName(s),i)}exportDataAsCsv(e){this.export(e)}getDataAsCsv(e,t=!1){const o=t?Object.assign({},e):this.getMergedParams(e);return this.getData(o)}getDefaultFileExtension(){return"csv"}createSerializingSession(e){const{colModel:t,colNames:o,rowGroupColsSvc:i,valueSvc:s,gos:n}=this,{processCellCallback:r,processHeaderCallback:a,processGroupHeaderCallback:l,processRowGroupCallback:d,suppressQuotes:h,columnSeparator:c}=e;return new $m({colModel:t,colNames:o,valueSvc:s,gos:n,processCellCallback:r||void 0,processHeaderCallback:a||void 0,processGroupHeaderCallback:l||void 0,processRowGroupCallback:d||void 0,suppressQuotes:h||!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:[Um]},jm=class extends Me{constructor(e,t,o){super(),this.id=e,this.parentCache=t,this.params=o,this.state="needsLoading",this.version=0,this.startRow=e*o.blockSize,this.endRow=this.startRow+o.blockSize}load(){this.state="loading",this.loadFromDatasource()}setStateWaitingToLoad(){this.version++,this.state="needsLoading"}pageLoadFailed(e){this.isRequestMostRecentAndLive(e)&&(this.state="failed"),this.dispatchLocalEvent({type:"loadComplete"})}pageLoaded(e,t,o){this.successCommon(e,{rowData:t,rowCount:o})}isRequestMostRecentAndLive(e){const t=e===this.version,o=this.isAlive();return t&&o}successCommon(e,t){this.dispatchLocalEvent({type:"loadComplete"});this.isRequestMostRecentAndLive(e)&&(this.state="loaded",this.processServerResult(t))}postConstruct(){this.rowNodes=[];const{params:{blockSize:e,rowHeight:t},startRow:o,beans:i,rowNodes:s}=this;for(let n=0;n<e;n++){const e=o+n,r=new _n(i);r.setRowHeight(t),r.uiLevel=0,r.setRowIndex(e),r.setRowTop(t*e),s.push(r)}}getBlockStateJson(){const{id:e,startRow:t,endRow:o,state:i}=this;return{id:""+e,state:{blockNumber:e,startRow:t,endRow:o,pageStatus:i}}}setDataAndId(e,t,i){o(t)?e.setDataAndId(t,i.toString()):e.setDataAndId(void 0,void 0)}loadFromDatasource(){const e=this.createLoadParams();i(this.params.datasource.getRows)?st(90):window.setTimeout(()=>{this.params.datasource.getRows(e)},0)}createLoadParams(){const{startRow:e,endRow:t,version:o,params:{sortModel:i,filterModel:s},gos:n}=this;return{startRow:e,endRow:t,successCallback:this.pageLoaded.bind(this,o),failCallback:this.pageLoadFailed.bind(this,o),sortModel:i,filterModel:s,context:zt(n,{}).context}}forEachNode(e,t,o){this.rowNodes.forEach((i,s)=>{this.startRow+s<o&&e(i,t.value++)})}getRow(e,t=!1){t||(this.lastAccessed=this.params.lastAccessedSequence.value++);const o=e-this.startRow;return this.rowNodes[o]}processServerResult(e){const{rowNodes:t,beans:o}=this;t.forEach((i,s)=>{const n=e.rowData?e.rowData[s]:void 0;!i.id&&i.alreadyRendered&&n&&(t[s]=new _n(o),t[s].setRowIndex(i.rowIndex),t[s].setRowTop(i.rowTop),t[s].setRowHeight(i.rowHeight),i.clearRowTopAndRowIndex()),this.setDataAndId(t[s],n,this.startRow+s)});const i=null!=e.rowCount&&e.rowCount>=0?e.rowCount:void 0;this.parentCache.pageLoaded(this,i)}destroy(){this.rowNodes.forEach(e=>{e.clearRowTopAndRowIndex()}),super.destroy()}},qm=class extends Me{constructor(e){super(),this.params=e,this.lastRowIndexKnown=!1,this.blocks={},this.blockCount=0,this.rowCount=e.initialRowCount}getRow(e,t=!1){const o=Math.floor(e/this.params.blockSize);let i=this.blocks[o];if(!i){if(t)return;i=this.createBlock(o)}return i.getRow(e)}createBlock(e){const t=this.params,o=this.createBean(new jm(e,this,t));return this.blocks[o.id]=o,this.blockCount++,this.purgeBlocksIfNeeded(o),t.rowNodeBlockLoader.addBlock(o),o}refreshCache(){0==this.blockCount?this.purgeCache():(this.getBlocksInOrder().forEach(e=>e.setStateWaitingToLoad()),this.params.rowNodeBlockLoader.checkBlockToLoad())}destroy(){this.getBlocksInOrder().forEach(e=>this.destroyBlock(e)),super.destroy()}getRowCount(){return this.rowCount}isLastRowIndexKnown(){return this.lastRowIndexKnown}pageLoaded(e,t){this.isAlive()&&($e(this.gos,`InfiniteCache - onPageLoaded: page = ${e.id}, lastRow = ${t}`),this.checkRowCount(e,t),this.onCacheUpdated())}purgeBlocksIfNeeded(e){const t=this.getBlocksInOrder().filter(t=>t!=e);t.sort((e,t)=>t.lastAccessed-e.lastAccessed);const o=this.params.maxBlocksInCache>0,i=o?this.params.maxBlocksInCache-1:null;t.forEach((e,t)=>{if("needsLoading"===e.state&&t>=1||!!o&&t>=i){if(this.isBlockCurrentlyDisplayed(e))return;if(this.isBlockFocused(e))return;this.removeBlockFromCache(e)}})}isBlockFocused(e){const t=this.beans.focusSvc.getFocusCellToUseAfterRefresh();if(!t)return!1;if(null!=t.rowPinned)return!1;const{startRow:o,endRow:i}=e;return t.rowIndex>=o&&t.rowIndex<i}isBlockCurrentlyDisplayed(e){const{startRow:t,endRow:o}=e;return this.beans.rowRenderer.isRangeInRenderedViewport(t,o-1)}removeBlockFromCache(e){e&&this.destroyBlock(e)}checkRowCount(e,t){if("number"==typeof t&&t>=0)this.rowCount=t,this.lastRowIndexKnown=!0;else if(!this.lastRowIndexKnown){const{blockSize:t,overflowSize:o}=this.params,i=(e.id+1)*t+o;this.rowCount<i&&(this.rowCount=i)}}setRowCount(e,t){this.rowCount=e,o(t)&&(this.lastRowIndexKnown=t),this.lastRowIndexKnown||this.rowCount%this.params.blockSize===0&&this.rowCount++,this.onCacheUpdated()}forEachNodeDeep(e){const t={value:0};this.getBlocksInOrder().forEach(o=>o.forEachNode(e,t,this.rowCount))}getBlocksInOrder(){return Object.values(this.blocks).sort((e,t)=>e.id-t.id)}destroyBlock(e){delete this.blocks[e.id],this.destroyBean(e),this.blockCount--,this.params.rowNodeBlockLoader.removeBlock(e)}onCacheUpdated(){this.isAlive()&&(this.destroyAllBlocksPastVirtualRowCount(),this.eventSvc.dispatchEvent({type:"storeUpdated"}))}destroyAllBlocksPastVirtualRowCount(){const e=[];this.getBlocksInOrder().forEach(t=>{t.id*this.params.blockSize>=this.rowCount&&e.push(t)}),e.length>0&&e.forEach(e=>this.destroyBlock(e))}purgeCache(){this.getBlocksInOrder().forEach(e=>this.removeBlockFromCache(e)),this.lastRowIndexKnown=!1,0===this.rowCount&&(this.rowCount=this.params.initialRowCount),this.onCacheUpdated()}getRowNodesInRange(e,t){const o=[];let i=-1,s=!1;const n={value:0};let r=!1;this.getBlocksInOrder().forEach(a=>{r||(s&&i+1!==a.id?r=!0:(i=a.id,a.forEachNode(i=>{const n=i===e||i===t;(s||n)&&o.push(i),n&&(s=!s)},n,this.rowCount)))});return r||s?[]:o}};var _m={moduleName:"InfiniteRowModelCore",version:qe,rowModels:["infinite"],beans:[class extends Me{constructor(){super(...arguments),this.beanName="rowModel"}getRowBounds(e){return{rowHeight:this.rowHeight,rowTop:this.rowHeight*e}}ensureRowHeightsValid(){return!1}postConstruct(){"infinite"===this.gos.get("rowModelType")&&(this.rowHeight=mt(this.beans),this.addEventListeners(),this.addDestroyFunc(()=>this.destroyCache()))}start(){this.setDatasource(this.gos.get("datasource"))}destroy(){this.destroyDatasource(),super.destroy()}destroyDatasource(){this.datasource&&(this.destroyBean(this.datasource),this.beans.rowRenderer.datasourceChanged(),this.datasource=null)}addEventListeners(){this.addManagedEventListeners({filterChanged:this.reset.bind(this),sortChanged:this.reset.bind(this),newColumnsLoaded:this.onColumnEverything.bind(this),storeUpdated:this.dispatchModelUpdatedEvent.bind(this)}),this.addManagedPropertyListener("datasource",()=>this.setDatasource(this.gos.get("datasource"))),this.addManagedPropertyListener("cacheBlockSize",()=>this.resetCache()),this.addManagedPropertyListener("rowHeight",()=>{this.rowHeight=mt(this.beans),this.cacheParams.rowHeight=this.rowHeight,this.updateRowHeights()})}onColumnEverything(){let e;e=!this.cacheParams||!n(this.cacheParams.sortModel,this.beans.sortSvc?.getSortModel()??[]),e&&this.reset()}getType(){return"infinite"}setDatasource(e){this.destroyDatasource(),this.datasource=e,e&&this.reset()}isEmpty(){return!this.infiniteCache}isRowsToRender(){return!!this.infiniteCache}getNodesInRangeForSelection(e,t){return this.infiniteCache?.getRowNodesInRange(e,t)??[]}reset(){if(!this.datasource)return;null!=Ft(this.gos)||this.beans.selectionSvc?.reset("rowDataChanged"),this.resetCache()}dispatchModelUpdatedEvent(){this.eventSvc.dispatchEvent({type:"modelUpdated",newPage:!1,newPageSize:!1,newData:!1,keepRenderedRows:!0,animate:!1})}resetCache(){this.destroyCache();const e=this.beans,{filterManager:t,sortSvc:o,rowNodeBlockLoader:i,eventSvc:s,gos:n}=e;this.cacheParams={datasource:this.datasource,filterModel:t?.getFilterModel()??{},sortModel:o?.getSortModel()??[],rowNodeBlockLoader:i,initialRowCount:n.get("infiniteInitialRowCount"),maxBlocksInCache:n.get("maxBlocksInCache"),rowHeight:mt(e),overflowSize:n.get("cacheOverflowSize"),blockSize:n.get("cacheBlockSize"),lastAccessedSequence:{value:0}},this.infiniteCache=this.createBean(new qm(this.cacheParams)),s.dispatchEventOnce({type:"rowCountReady"}),this.dispatchModelUpdatedEvent()}updateRowHeights(){this.forEachNode(e=>{e.setRowHeight(this.rowHeight),e.setRowTop(this.rowHeight*e.rowIndex)}),this.dispatchModelUpdatedEvent()}destroyCache(){this.infiniteCache=this.destroyBean(this.infiniteCache)}getRow(e){const t=this.infiniteCache;if(t&&!(e>=t.getRowCount()))return t.getRow(e)}getRowNode(e){let t;return this.forEachNode(o=>{o.id===e&&(t=o)}),t}forEachNode(e){this.infiniteCache?.forEachNodeDeep(e)}getTopLevelRowCount(){return this.getRowCount()}getTopLevelRowDisplayedIndex(e){return e}getRowIndexAtPixel(e){if(0!==this.rowHeight){const t=Math.floor(e/this.rowHeight),o=this.getRowCount()-1;return t>o?o:t}return 0}getRowCount(){return this.infiniteCache?this.infiniteCache.getRowCount():0}isRowPresent(e){return!!this.getRowNode(e.id)}refreshCache(){this.infiniteCache?.refreshCache()}purgeCache(){this.infiniteCache?.purgeCache()}isLastRowIndexKnown(){return this.infiniteCache?.isLastRowIndexKnown()??!1}setRowCount(e,t){this.infiniteCache?.setRowCount(e,t)}resetRowHeights(){}onRowHeightChanged(){}},class extends Me{constructor(){super(...arguments),this.beanName="rowNodeBlockLoader",this.activeBlockLoadsCount=0,this.blocks=[],this.active=!0}postConstruct(){this.maxConcurrentRequests=function(e){const t=e.get("maxConcurrentDatasourceRequests");return t>0?t:void 0}(this.gos);const e=this.gos.get("blockLoadDebounceMillis");e&&e>0&&(this.checkBlockToLoadDebounce=Be(this,this.performCheckBlocksToLoad.bind(this),e))}addBlock(e){this.blocks.push(e),e.addEventListener("loadComplete",this.loadComplete.bind(this)),this.checkBlockToLoad()}removeBlock(e){so(this.blocks,e)}destroy(){super.destroy(),this.active=!1}loadComplete(){this.activeBlockLoadsCount--,this.checkBlockToLoad()}checkBlockToLoad(){this.checkBlockToLoadDebounce?this.checkBlockToLoadDebounce():this.performCheckBlocksToLoad()}performCheckBlocksToLoad(){if(!this.active)return;if(this.printCacheStatus(),null!=this.maxConcurrentRequests&&this.activeBlockLoadsCount>=this.maxConcurrentRequests)return void $e(this.gos,"RowNodeBlockLoader - checkBlockToLoad: max loads exceeded");const e=null!=this.maxConcurrentRequests?this.maxConcurrentRequests-this.activeBlockLoadsCount:1,t=this.blocks.filter(e=>"needsLoading"===e.state).slice(0,e);this.activeBlockLoadsCount+=t.length,t.forEach(e=>e.load()),this.printCacheStatus()}getBlockState(){const e={};return this.blocks.forEach(t=>{const{id:o,state:i}=t.getBlockStateJson();e[o]=i}),e}printCacheStatus(){$e(this.gos,`RowNodeBlockLoader - printCacheStatus: activePageLoadsCount = ${this.activeBlockLoadsCount}, blocks = ${JSON.stringify(this.getBlockState())}`)}}]},Ym={moduleName:"InfiniteRowModel",version:qe,apiFunctions:{refreshInfiniteCache:function(e){fd(e)?.refreshCache()},purgeInfiniteCache:function(e){fd(e)?.purgeCache()},getInfiniteRowCount:function(e){return fd(e)?.getRowCount()}},dependsOn:[_m,Lm]},Qm={tag:"span",children:[{tag:"span",ref:"eDelta",cls:"ag-value-change-delta"},{tag:"span",ref:"eValue",cls:"ag-value-change-value"}]},Zm={tag:"span",children:[{tag:"span",ref:"eCurrent",cls:"ag-value-slide-current"}]};var Jm={moduleName:"HighlightChanges",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="cellFlashSvc",this.nextAnimationTime=null,this.nextAnimationCycle=null,this.animations={highlight:new Map,"data-changed":new Map}}animateCell(e,t,o=this.beans.gos.get("cellFlashDuration"),i=this.beans.gos.get("cellFadeDuration")){const s=this.animations[t];s.delete(e);const n=Date.now(),r=n+o,a={phase:"flash",flashEndTime:r,fadeEndTime:n+o+i};s.set(e,a);const l=`ag-cell-${t}`,d=`${l}-animation`,{comp:h,eGui:{style:c}}=e;h.toggleCss(l,!0),h.toggleCss(d,!1),c.removeProperty("transition"),c.removeProperty("transition-delay"),this.nextAnimationTime&&r+15<this.nextAnimationTime&&(clearTimeout(this.nextAnimationCycle),this.nextAnimationCycle=null,this.nextAnimationTime=null),this.nextAnimationCycle||(this.beans.frameworkOverrides.wrapIncoming(()=>{this.nextAnimationCycle=setTimeout(this.advanceAnimations.bind(this),o)}),this.nextAnimationTime=r)}advanceAnimations(){const e=Date.now();let t=null;for(const o of Object.keys(this.animations)){const i=this.animations[o],s=`ag-cell-${o}`,n=`${s}-animation`;for(const[o,r]of i){if(!o.isAlive()||!o.comp){i.delete(o);continue}const{phase:a,flashEndTime:l,fadeEndTime:d}=r,h="flash"===a?l:d;if(!(e+15>=h)){t=Math.min(h,t??1/0);continue}const{comp:c,eGui:{style:u}}=o;switch(a){case"flash":c.toggleCss(s,!1),c.toggleCss(n,!0),u.transition=`background-color ${d-l}ms`,u.transitionDelay=l-e+"ms",t=Math.min(d,t??1/0),r.phase="fade";break;case"fade":c.toggleCss(s,!1),c.toggleCss(n,!1),u.removeProperty("transition"),u.removeProperty("transition-delay"),i.delete(o)}}}null==t?(this.nextAnimationTime=null,this.nextAnimationCycle=null):t&&(this.nextAnimationCycle=setTimeout(this.advanceAnimations.bind(this),t-e),this.nextAnimationTime=t)}onFlashCells(e,t){if(!e.comp)return;const o=function(e){const{rowIndex:t,rowPinned:o,column:i}=e;return`${t}.${null==o?"null":o}.${i.getId()}`}(e.cellPosition);t.cells[o]&&this.animateCell(e,"highlight")}flashCell(e,t){this.animateCell(e,"data-changed",t?.flashDuration,t?.fadeDuration)}destroy(){for(const e of Object.keys(this.animations)){this.animations[e].clear()}}}],userComponents:{agAnimateShowChangeCellRenderer:class extends Uo{constructor(){super(Qm),this.eValue=Go,this.eDelta=Go,this.refreshCount=0}init(e){this.refresh(e,!0)}showDelta(e,t){const i=Math.abs(t),s=e.formatValue(i),n=o(s)?s:i,r=t>=0,a=this.eDelta;a.textContent=r?"↑"+n:"↓"+n,a.classList.toggle("ag-value-change-delta-up",r),a.classList.toggle("ag-value-change-delta-down",!r)}setTimerToRemoveDelta(){this.refreshCount++;const e=this.refreshCount;this.beans.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(()=>{e===this.refreshCount&&this.hideDeltaValue()},2e3)})}hideDeltaValue(){this.eValue.classList.remove("ag-value-change-value-highlight"),q(this.eDelta)}refresh(e,t=!1){const{value:i,valueFormatted:s}=e,{eValue:n,lastValue:r,beans:a}=this;if(i===r)return!1;if(o(s)?n.textContent=s:o(i)?n.textContent=i:q(n),a.filterManager?.isSuppressFlashingCellsBecauseFiltering())return!1;const l=i&&"object"==typeof i&&"toNumber"in i?i.toNumber():i,d=r&&"object"==typeof r&&"toNumber"in r?r.toNumber():r;if(l===d)return!1;if("number"==typeof l&&"number"==typeof d){const t=l-d;this.showDelta(e,t)}return r&&n.classList.add("ag-value-change-value-highlight"),t||this.setTimerToRemoveDelta(),this.lastValue=i,!0}},agAnimateSlideCellRenderer:class extends Uo{constructor(){super(Zm),this.eCurrent=Go,this.refreshCount=0,this.registerCSS(".ag-value-slide-out{opacity:1}:where(.ag-ltr) .ag-value-slide-out{margin-right:5px;transition:opacity 3s,margin-right 3s}:where(.ag-rtl) .ag-value-slide-out{margin-left:5px;transition:opacity 3s,margin-left 3s}:where(.ag-ltr,.ag-rtl) .ag-value-slide-out{transition-timing-function:linear}.ag-value-slide-out-end{opacity:0}:where(.ag-ltr) .ag-value-slide-out-end{margin-right:10px}:where(.ag-rtl) .ag-value-slide-out-end{margin-left:10px}")}init(e){this.refresh(e,!0)}addSlideAnimation(){this.refreshCount++;const e=this.refreshCount;this.ePrevious&&this.getGui().removeChild(this.ePrevious);const{beans:t,eCurrent:o}=this,i=sr({tag:"span",cls:"ag-value-slide-previous ag-value-slide-out"});this.ePrevious=i,i.textContent=o.textContent,this.getGui().insertBefore(i,o),t.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(()=>{e===this.refreshCount&&this.ePrevious.classList.add("ag-value-slide-out-end")},50),window.setTimeout(()=>{e===this.refreshCount&&(this.getGui().removeChild(this.ePrevious),this.ePrevious=null)},3e3)})}refresh(e,t=!1){let s=e.value;if(i(s)&&(s=""),s===this.lastValue)return!1;if(this.beans.filterManager?.isSuppressFlashingCellsBecauseFiltering())return!1;t||this.addSlideAnimation(),this.lastValue=s;const n=this.eCurrent;return o(e.valueFormatted)?n.textContent=e.valueFormatted:o(e.value)?n.textContent=s:q(n),!0}}},apiFunctions:{flashCells:function(e,t={}){const{cellFlashSvc:o}=e;o&&e.frameworkOverrides.wrapIncoming(()=>{e.rowRenderer.getCellCtrls(t.rowNodes,t.columns).forEach(e=>o.flashCell(e,t))})}}};function Xm(e){if((e={...e}).version||(e.version="32.1.0"),"32.1.0"===e.version)e=function(e){return e.cellSelection=function(e,t){if(e&&"object"==typeof e)return e[t]}(e,"rangeSelection"),e}(e);return e.version=qe,e}var ef={moduleName:"GridState",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="stateSvc",this.updateRowGroupExpansionStateTimer=0,this.suppressEvents=!0,this.queuedUpdateSources=new Set,this.dispatchStateUpdateEventDebounced=Be(this,()=>this.dispatchQueuedStateUpdateEvents(),0),this.onRowGroupOpenedDebounced=Be(this,()=>{this.beans.gos.get("ssrmExpandAllAffectsAllRows")?(this.updateCachedState("ssrmRowGroupExpansion",this.getRowGroupExpansionState()),this.updateCachedState("rowGroupExpansion",void 0)):(this.updateCachedState("rowGroupExpansion",this.getRowGroupExpansionState()),this.updateCachedState("ssrmRowGroupExpansion",void 0))},0),this.onRowSelectedDebounced=Be(this,()=>{this.staleStateKeys.delete("rowSelection"),this.updateCachedState("rowSelection",this.getRowSelectionState())},0),this.staleStateKeys=new Set}postConstruct(){const{gos:e,ctrlsSvc:t,colDelayRenderSvc:o}=this.beans;this.isClientSideRowModel=dt(e);const i=Xm(e.get("initialState")??{}),s=i.partialColumnState;delete i.partialColumnState,this.cachedState=i;const n=this.suppressEventsAndDispatchInitEvent.bind(this);t.whenReady(this,()=>n(()=>this.setupStateOnGridReady(i))),(i.columnOrder||i.columnVisibility||i.columnSizing||i.columnPinning||i.columnGroup)&&o?.hideColumns("columnState");const[r,a,l]=this.addManagedEventListeners({newColumnsLoaded:({source:e})=>{"gridInitializing"===e&&(r(),n(()=>{this.setupStateOnColumnsInitialised(i,!!s),o?.revealColumns("columnState")}))},rowCountReady:()=>{a?.(),n(()=>this.setupStateOnRowCountReady(i))},firstDataRendered:()=>{l?.(),n(()=>this.setupStateOnFirstDataRendered(i))}})}destroy(){super.destroy(),clearTimeout(this.updateRowGroupExpansionStateTimer),this.queuedUpdateSources.clear()}getState(){return this.staleStateKeys.size&&this.refreshStaleState(),this.cachedState}setState(e,t){const o=Xm(e);delete o.partialColumnState,this.cachedState=o,this.startSuppressEvents();const i="api",s=t?new Set(t):void 0;this.setGridReadyState(o,i,s),this.setColumnsInitialisedState(o,i,!1,s),this.setRowCountState(o,i,s),setTimeout(()=>{this.isAlive()&&this.setFirstDataRenderedState(o,i,s),this.stopSuppressEvents(i)})}setGridReadyState(e,t,o){"api"!==t||o?.has("sideBar")||this.beans.sideBar?.comp?.setState(e.sideBar),this.updateCachedState("sideBar",this.getSideBarState())}setupStateOnGridReady(e){this.setGridReadyState(e,"gridInitializing");const t=()=>this.updateCachedState("sideBar",this.getSideBarState());this.addManagedEventListeners({toolPanelVisibleChanged:t,sideBarUpdated:t})}updateColumnAndGroupState(){this.updateColumnState(["aggregation","columnOrder","columnPinning","columnSizing","columnVisibility","pivot","rowGroup","sort"]),this.updateCachedState("columnGroup",this.getColumnGroupState())}setColumnsInitialisedState(e,t,o,i){this.setColumnState(e,t,o,i),this.setColumnGroupState(e,t,i),this.updateColumnAndGroupState()}setupStateOnColumnsInitialised(e,t){this.setColumnsInitialisedState(e,"gridInitializing",t);const o=e=>()=>this.updateColumnState([e]);this.addManagedEventListeners({columnValueChanged:o("aggregation"),columnMoved:o("columnOrder"),columnPinned:o("columnPinning"),columnResized:o("columnSizing"),columnVisible:o("columnVisibility"),columnPivotChanged:o("pivot"),columnPivotModeChanged:o("pivot"),columnRowGroupChanged:o("rowGroup"),sortChanged:o("sort"),newColumnsLoaded:this.updateColumnAndGroupState.bind(this),columnGroupOpened:()=>this.updateCachedState("columnGroup",this.getColumnGroupState())})}setRowCountState(e,t,o){const{filter:i,rowGroupExpansion:s,ssrmRowGroupExpansion:n,rowSelection:r,pagination:a}=e,l=(e,i)=>!o?.has(e)&&(i||"api"===t);l("filter",i)&&this.setFilterState(i),l("rowGroupExpansion",s)&&this.setRowGroupExpansionState(n,s,t),l("rowSelection",r)&&this.setRowSelectionState(r,t),l("pagination",a)&&this.setPaginationState(a,t);const d=this.updateCachedState.bind(this);d("filter",this.getFilterState()),this.beans.gos.get("ssrmExpandAllAffectsAllRows")?(d("ssrmRowGroupExpansion",this.getRowGroupExpansionState()),d("rowGroupExpansion",void 0)):(d("rowGroupExpansion",this.getRowGroupExpansionState()),d("ssrmRowGroupExpansion",void 0)),d("rowSelection",this.getRowSelectionState()),d("pagination",this.getPaginationState())}setupStateOnRowCountReady(e){this.setRowCountState(e,"gridInitializing");const t=this.updateCachedState.bind(this),o=()=>{this.updateRowGroupExpansionStateTimer=0,this.beans.gos.get("ssrmExpandAllAffectsAllRows")?(t("ssrmRowGroupExpansion",this.getRowGroupExpansionState()),t("rowGroupExpansion",void 0)):(t("rowGroupExpansion",this.getRowGroupExpansionState()),t("ssrmRowGroupExpansion",void 0))},i=()=>t("filter",this.getFilterState()),{gos:s,colFilter:n}=this.beans;this.addManagedEventListeners({filterChanged:i,rowExpansionStateChanged:this.onRowGroupOpenedDebounced,expandOrCollapseAll:o,columnRowGroupChanged:o,rowDataUpdated:()=>{(0!==s.get("groupDefaultExpanded")||s.get("isGroupOpenByDefault"))&&(this.updateRowGroupExpansionStateTimer||(this.updateRowGroupExpansionStateTimer=setTimeout(o)))},selectionChanged:()=>{this.staleStateKeys.add("rowSelection"),this.onRowSelectedDebounced()},paginationChanged:e=>{(e.newPage||e.newPageSize)&&t("pagination",this.getPaginationState())}}),n&&this.addManagedListeners(n,{filterStateChanged:i})}setFirstDataRenderedState(e,t,o){const{scroll:i,cellSelection:s,focusedCell:n,columnOrder:r,rowPinning:a}=e,l=(e,i)=>!o?.has(e)&&(i||"api"===t);l("focusedCell",n)&&this.setFocusedCellState(n),l("cellSelection",s)&&this.setCellSelectionState(s),l("scroll",i)&&this.setScrollState(i),l("rowPinning",a)&&this.setRowPinningState(a),this.setColumnPivotState(!!r?.orderedColIds,t);const d=this.updateCachedState.bind(this);d("sideBar",this.getSideBarState()),d("focusedCell",this.getFocusedCellState());const h=this.getRangeSelectionState();d("rangeSelection",h),d("cellSelection",h),d("scroll",this.getScrollState())}setupStateOnFirstDataRendered(e){this.setFirstDataRenderedState(e,"gridInitializing");const t=this.updateCachedState.bind(this),o=()=>t("focusedCell",this.getFocusedCellState());this.addManagedEventListeners({cellFocused:o,cellFocusCleared:o,cellSelectionChanged:e=>{if(e.finished){const e=this.getRangeSelectionState();t("rangeSelection",e),t("cellSelection",e)}},bodyScrollEnd:()=>t("scroll",this.getScrollState()),pinnedRowsChanged:()=>t("rowPinning",this.getRowPinningState())})}getColumnState(){const e=this.beans;return function(e,t=!1){const o=[],i=[],s=[],n=[],r=[],a=[],l=[],d=[],h=[];let c=0;for(let t=0;t<e.length;t++){const{colId:u,sort:g,sortIndex:p,rowGroup:m,rowGroupIndex:f,aggFunc:C,pivot:v,pivotIndex:w,pinned:b,hide:y,width:S,flex:E}=e[t];h.push(u),g&&(o[p??c++]={colId:u,sort:g}),m&&(i[f??0]=u),"string"==typeof C&&s.push({colId:u,aggFunc:C}),v&&(n[w??0]=u),b&&("right"===b?a:r).push(u),y&&l.push(u),(null!=E||S)&&d.push({colId:u,flex:E??void 0,width:S})}return{sort:o.length?{sortModel:o}:void 0,rowGroup:i.length?{groupColIds:i}:void 0,aggregation:s.length?{aggregationModel:s}:void 0,pivot:n.length||t?{pivotMode:t,pivotColIds:n}:void 0,columnPinning:r.length||a.length?{leftColIds:r,rightColIds:a}:void 0,columnVisibility:l.length?{hiddenColIds:l}:void 0,columnSizing:d.length?{columnSizingModel:d}:void 0,columnOrder:h.length?{orderedColIds:h}:void 0}}(Ao(e),e.colModel.isPivotMode())}setColumnState(e,t,o,i){const{sort:s,rowGroup:n,aggregation:r,pivot:a,columnPinning:l,columnVisibility:d,columnSizing:h,columnOrder:c}=e;let u=!1;const g=(e,o)=>{const s=!(i?.has(e)||!o&&"api"!==t);return u||(u=s),s},p={},m=e=>{let t=p[e];return t||(t={colId:e},p[e]=t,t)},f={},C=g("sort",s);C&&s?.sortModel.forEach(({colId:e,sort:t},o)=>{const i=m(e);i.sort=t,i.sortIndex=o}),!C&&o||(f.sort=null,f.sortIndex=null);const v=g("rowGroup",n);v&&n?.groupColIds.forEach((e,t)=>{const o=m(e);o.rowGroup=!0,o.rowGroupIndex=t}),!v&&o||(f.rowGroup=null,f.rowGroupIndex=null);const w=g("aggregation",r);w&&r?.aggregationModel.forEach(({colId:e,aggFunc:t})=>{m(e).aggFunc=t}),!w&&o||(f.aggFunc=null);const b=g("pivot",a);b&&(a?.pivotColIds.forEach((e,t)=>{const o=m(e);o.pivot=!0,o.pivotIndex=t}),this.gos.updateGridOptions({options:{pivotMode:!!a?.pivotMode},source:t})),!b&&o||(f.pivot=null,f.pivotIndex=null);const y=g("columnPinning",l);y&&(l?.leftColIds.forEach(e=>{m(e).pinned="left"}),l?.rightColIds.forEach(e=>{m(e).pinned="right"})),!y&&o||(f.pinned=null);const S=g("columnVisibility",d);S&&d?.hiddenColIds.forEach(e=>{m(e).hide=!0}),!S&&o||(f.hide=null);const E=g("columnSizing",h);E&&h?.columnSizingModel.forEach(({colId:e,flex:t,width:o})=>{const i=m(e);i.flex=t??null,i.width=o}),!E&&o||(f.flex=null);const R=c?.orderedColIds,x=!!R?.length&&!i?.has("columnOrder"),F=x?R.map(e=>m(e)):Object.values(p);(F.length||u)&&(this.columnStates=F,To(this.beans,{state:F,applyOrder:x,defaultState:f},t))}setColumnPivotState(e,t){const o=this.columnStates;this.columnStates=void 0;const i=this.columnGroupStates;this.columnGroupStates=void 0;const s=this.beans,{pivotResultCols:n,colGroupSvc:r}=s;if(n?.isPivotResultColsPresent()){if(o){const i=[];for(const e of o)n.getPivotResultCol(e.colId)&&i.push(e);To(s,{state:i,applyOrder:e},t)}i&&r?.setColumnGroupState(i,t)}}getColumnGroupState(){const e=this.beans.colGroupSvc;if(!e)return;return function(e){const t=[];return e.forEach(({groupId:e,open:o})=>{o&&t.push(e)}),t.length?{openColumnGroupIds:t}:void 0}(e.getColumnGroupState())}setColumnGroupState(e,t,o){const i=this.beans.colGroupSvc;if(!i||o?.has("columnGroup")||"api"!==t&&!Object.prototype.hasOwnProperty.call(e,"columnGroup"))return;const s=new Set(e.columnGroup?.openColumnGroupIds),n=i.getColumnGroupState().map(({groupId:e})=>{const t=s.has(e);return t&&s.delete(e),{groupId:e,open:t}});s.forEach(e=>{n.push({groupId:e,open:!0})}),n.length&&(this.columnGroupStates=n),i.setColumnGroupState(n,t)}getFilterState(){const e=this.beans.filterManager;let t=e?.getFilterModel();t&&0===Object.keys(t).length&&(t=void 0);const o=e?.getFilterState(),i=e?.getAdvFilterModel()??void 0;return t||i||o?{filterModel:t,columnFilterState:o,advancedFilterModel:i}:void 0}setFilterState(e){const t=this.beans.filterManager,{filterModel:o,columnFilterState:i,advancedFilterModel:s}=e??{filterModel:null,columnFilterState:null,advancedFilterModel:null};void 0===o&&void 0===i||t?.setFilterState(o??null,i??null,"columnFilter"),void 0!==s&&t?.setAdvFilterModel(s??null,"advancedFilter")}getRangeSelectionState(){const e=this.beans.rangeSvc?.getCellRanges().map(e=>{const{id:t,type:o,startRow:i,endRow:s,columns:n,startColumn:r}=e;return{id:t,type:o,startRow:i,endRow:s,colIds:n.map(e=>e.getColId()),startColId:r.getColId()}});return e?.length?{cellRanges:e}:void 0}setCellSelectionState(e){const{gos:t,rangeSvc:o,colModel:i,visibleCols:s}=this.beans;if(!Tt(t)||!o)return;const n=[];e?.cellRanges.forEach(e=>{const t=[];if(e.colIds.forEach(e=>{const o=i.getCol(e);o&&t.push(o)}),!t.length)return;let o=i.getCol(e.startColId);if(!o){const e=s.allCols,i=new Set(t);o=e.find(e=>i.has(e))}n.push({...e,columns:t,startColumn:o})}),o.setCellRanges(n)}getScrollState(){if(!this.isClientSideRowModel)return;const e=this.beans.ctrlsSvc.getScrollFeature(),{left:t}=e?.getHScrollPosition()??{left:0},{top:o}=e?.getVScrollPosition()??{top:0};return o||t?{top:o,left:t}:void 0}setScrollState(e){if(!this.isClientSideRowModel)return;const{top:t,left:o}=e??{top:0,left:0},{frameworkOverrides:i,rowRenderer:s,animationFrameSvc:n,ctrlsSvc:r}=this.beans;i.wrapIncoming(()=>{r.get("center").setCenterViewportScrollLeft(o),r.getScrollFeature()?.setVerticalScrollPosition(t),s.redraw({afterScroll:!0}),n?.flushAllFrames()})}getSideBarState(){return this.beans.sideBar?.comp?.getState()}getFocusedCellState(){if(!this.isClientSideRowModel)return;const e=this.beans.focusSvc.getFocusedCell();if(e){const{column:t,rowIndex:o,rowPinned:i}=e;return{colId:t.getColId(),rowIndex:o,rowPinned:i}}}setFocusedCellState(e){if(!this.isClientSideRowModel)return;const{focusSvc:t,colModel:o}=this.beans;if(!e)return void t.clearFocusedCell();const{colId:i,rowIndex:s,rowPinned:n}=e;t.setFocusedCell({column:o.getCol(i),rowIndex:s,rowPinned:n,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}getPaginationState(){const{pagination:e,gos:t}=this.beans;if(!e)return;const o=e.getCurrentPage(),i=t.get("paginationAutoPageSize")?void 0:e.getPageSize();return o||i?{page:o,pageSize:i}:void 0}setPaginationState(e,t){const{pagination:o,gos:i}=this.beans;if(!o)return;const{pageSize:s,page:n}=e??{page:0,pageSize:i.get("paginationPageSize")},r="gridInitializing"===t;s&&!i.get("paginationAutoPageSize")&&o.setPageSize(s,r?"initialState":"pageSizeSelector"),"number"==typeof n&&(r?o.setPage(n):o.goToPage(n))}getRowSelectionState(){const e=this.beans.selectionSvc;if(!e)return;const t=e.getSelectionState();return!t||!Array.isArray(t)&&(!1===t.selectAll||!1===t.selectAllChildren)&&!t?.toggledNodes?.length?void 0:t}setRowSelectionState(e,t){this.beans.selectionSvc?.setSelectionState(e,t,"api"===t)}getRowGroupExpansionState(){const{expansionSvc:e}=this.beans;if(e)return e.getExpansionState()}getRowPinningState(){return this.beans.pinnedRowModel?.getPinnedState()}setRowPinningState(e){const t=this.beans.pinnedRowModel;e?t?.setPinnedState(e):t?.reset()}setRowGroupExpansionState(e,t,o){const i=this.beans.expansionSvc;if(!i)return;const s=t??{expandedRowGroupIds:[],collapsedRowGroupIds:[]};i.setExpansionState(s,o)}updateColumnState(e){const t=this.getColumnState();let o=!1;const i=this.cachedState;for(const e of Object.keys(t)){n(t[e],i[e])||(o=!0)}this.cachedState={...i,...t},o&&this.dispatchStateUpdateEvent(e)}updateCachedState(e,t){const o=this.cachedState[e];this.setCachedStateValue(e,t),n(t,o)||this.dispatchStateUpdateEvent([e])}setCachedStateValue(e,t){this.cachedState={...this.cachedState,[e]:t}}refreshStaleState(){const e=this.staleStateKeys;e.forEach(e=>{if("rowSelection"===e)this.setCachedStateValue(e,this.getRowSelectionState())}),e.clear()}dispatchStateUpdateEvent(e){this.suppressEvents||(e.forEach(e=>this.queuedUpdateSources.add(e)),this.dispatchStateUpdateEventDebounced())}dispatchQueuedStateUpdateEvents(){const e=this.queuedUpdateSources,t=Array.from(e);e.clear(),this.eventSvc.dispatchEvent({type:"stateUpdated",sources:t,state:this.cachedState})}startSuppressEvents(){this.suppressEvents=!0,this.beans.colAnimation?.setSuppressAnimation(!0)}stopSuppressEvents(e){setTimeout(()=>{this.suppressEvents=!1,this.queuedUpdateSources.clear(),this.isAlive()&&(this.beans.colAnimation?.setSuppressAnimation(!1),this.dispatchStateUpdateEvent([e]))})}suppressEventsAndDispatchInitEvent(e){this.startSuppressEvents(),e(),this.stopSuppressEvents("gridInitializing")}}],apiFunctions:{getState:function(e){return e.stateSvc?.getState()??{}},setState:function(e,t,o){return e.stateSvc?.setState(t,o)}}};var tf="paginationPageSizeSelector",of={tag:"span",cls:"ag-paging-page-size"},sf={selector:"AG-PAGE-SIZE-SELECTOR",component:class extends Uo{constructor(){super(of),this.hasEmptyOption=!1,this.handlePageSizeItemSelected=()=>{if(!this.selectPageSizeComp)return;const e=this.selectPageSizeComp.getValue();if(!e)return;const 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(tf,()=>{this.onPageSizeSelectorValuesChange()}),this.addManagedEventListeners({paginationChanged:e=>this.handlePaginationChanged(e)})}handlePaginationChanged(e){if(!this.selectPageSizeComp||!e?.newPageSize)return;const t=this.pagination.getPageSize();this.getPageSizeSelectorValues().includes(t)?this.selectPageSizeComp.setValue(t.toString()):this.hasEmptyOption?this.selectPageSizeComp.setValue(""):this.toggleSelectDisplay(!0)}toggleSelectDisplay(e){this.selectPageSizeComp&&!e&&this.reset(),e&&(this.reloadPageSizesSelector(),this.selectPageSizeComp)}reset(){q(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(tf)}reloadPageSizesSelector(){const e=this.getPageSizeSelectorValues(),t=this.pagination.getPageSize(),o=!t||!e.includes(t);if(o){const o=this.gos.exists("paginationPageSize"),i=!0!==this.gos.get(tf);st(94,{pageSizeSet:o,pageSizesSet:i,pageSizeOptions:e,paginationPageSizeOption:t}),i||st(95,{paginationPageSizeOption:t,paginationPageSizeSelector:tf}),e.unshift("")}const i=String(o?"":t);this.selectPageSizeComp?(oo(this.pageSizeOptions,e)||(this.selectPageSizeComp.clearOptions().addOptions(this.createPageSizeSelectOptions(e)),this.pageSizeOptions=e),this.selectPageSizeComp.setValue(i,!0)):this.createPageSizeSelectorComp(e,i),this.hasEmptyOption=o}createPageSizeSelectOptions(e){return e.map(e=>({value:String(e)}))}createPageSizeSelectorComp(e,t){const o=this.getLocaleTextFunc(),i=o("pageSizeSelectorLabel","Page Size:"),s=o("ariaPageSizeSelectorLabel","Page Size");this.selectPageSizeComp=this.createManagedBean(new zs).addOptions(this.createPageSizeSelectOptions(e)).setValue(t).setAriaLabel(s).setLabel(i).onValueChange(()=>this.handlePageSizeItemSelected()),this.appendChild(this.selectPageSizeComp)}getPageSizeSelectorValues(){const e=[20,50,100],t=this.gos.get(tf);return Array.isArray(t)&&t?.length?[...t].sort((e,t)=>e-t):e}destroy(){this.toggleSelectDisplay(!1),super.destroy()}}},nf={selector:"AG-PAGINATION",component:class extends Nl{constructor(){super(),this.btFirst=Go,this.btPrevious=Go,this.btNext=Go,this.btLast=Go,this.lbRecordCount=Go,this.lbFirstRowOnPage=Go,this.lbLastRowOnPage=Go,this.lbCurrent=Go,this.lbTotal=Go,this.pageSizeComp=Go,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(){const e=this.gos.get("enableRtl");this.setTemplate(this.getTemplate(),[sf]);const{btFirst:t,btPrevious:o,btNext:i,btLast:s}=this;this.activateTabIndex([t,o,i,s]),t.insertAdjacentElement("afterbegin",al(e?"last":"first",this.beans)),o.insertAdjacentElement("afterbegin",al(e?"next":"previous",this.beans)),i.insertAdjacentElement("afterbegin",al(e?"previous":"next",this.beans)),s.insertAdjacentElement("afterbegin",al(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=>this.allowFocusInnerElement?this.tabGuardFeature.getTabGuardCtrl().focusInnerElement(e):function(e,t){return e.ctrlsSvc.get("gridCtrl").focusInnerElement(t)}(this.beans,e),forceFocusOutWhenTabGuardsAreEmpty:!0}),this.onPaginationChanged()}setAllowFocus(e){this.allowFocusInnerElement=e}onPaginationChanged(){const 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(){var e,t,o;this.areListenersSetup||(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)}].forEach(e=>{const{el:t,fn:o}=e;this.addManagedListeners(t,{click:o,keydown:e=>{e.key!==Pi&&e.key!==Mi||(e.preventDefault(),o())}})}),e=this.beans,t=this,o=this.getGui(),t.addManagedElementListeners(o,{keydown:t=>{if(!t.defaultPrevented&&t.key===Fi){const i=t.shiftKey;ys(e,o,!1,i)||Ma(e,i)&&t.preventDefault()}}}),this.areListenersSetup=!0)}onBtFirst(){this.previousAndFirstButtonsDisabled||this.pagination.goToFirstPage()}formatNumber(e){const t=this.gos.getCallback("paginationNumberFormatter");if(t){return t({value:e})}return function(e,t){if("number"!=typeof e)return"";const o=t(),i=o("thousandSeparator",","),s=o("decimalSeparator",".");return e.toString().replace(".",s).replace(/(\d)(?=(\d{3})+(?!\d))/g,`$1${i}`)}(e,this.getLocaleTextFunc.bind(this))}getTemplate(){const 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(){const e=this.pagination.getCurrentPage(),t=this.rowModel.isLastRowIndexKnown(),o=this.pagination.getTotalPages();this.previousAndFirstButtonsDisabled=0===e,this.toggleButtonDisabled(this.btFirst,this.previousAndFirstButtonsDisabled),this.toggleButtonDisabled(this.btPrevious,this.previousAndFirstButtonsDisabled);const i=this.isZeroPagesToDisplay(),s=e===o-1;this.nextButtonDisabled=s||i,this.lastButtonDisabled=!t||i||e===o-1,this.toggleButtonDisabled(this.btNext,this.nextButtonDisabled),this.toggleButtonDisabled(this.btLast,this.lastButtonDisabled)}toggleButtonDisabled(e,t){!function(e,t){C(e,"disabled",t)}(e,t),e.classList.toggle("ag-disabled",t)}isZeroPagesToDisplay(){const e=this.rowModel.isLastRowIndexKnown(),t=this.pagination.getTotalPages();return e&&0===t}updateLabels(){const e=this.rowModel.isLastRowIndexKnown(),t=this.pagination.getTotalPages(),o=this.pagination.getMasterRowCount(),i=e?o:null,s=this.pagination.getCurrentPage(),n=this.pagination.getPageSize();let r,a;this.isZeroPagesToDisplay()?r=a=0:(r=n*s+1,a=r+n-1,e&&a>i&&(a=i));const l=!e&&o<r+n-1,d=this.formatNumber(r);let h;this.lbFirstRowOnPage.textContent=d;const c=this.getLocaleTextFunc();h=l?c("pageLastRowUnknown","?"):this.formatNumber(a),this.lbLastRowOnPage.textContent=h;const u=t>0?s+1:0,g=this.formatNumber(u);let p,m;if(this.lbCurrent.textContent=g,e)p=this.formatNumber(t),m=this.formatNumber(i);else{const e=c("more","more");p=e,m=e}this.lbTotal.textContent=p,this.lbRecordCount.textContent=m,this.announceAriaStatus(d,h,m,g,p)}announceAriaStatus(e,t,o,i,s){const n=this.getLocaleTextFunc(),r=n("page","Page"),a=n("to","to"),l=n("of","of"),d=`${e} ${a} ${t} ${l} ${o}`,h=`${r} ${i} ${l} ${s}`;d!==this.ariaRowStatus&&(this.ariaRowStatus=d,this.ariaAnnounce?.announceValue(d,"paginationRow")),h!==this.ariaPageStatus&&(this.ariaPageStatus=h,this.ariaAnnounce?.announceValue(h,"paginationPage"))}}},rf={moduleName:"Pagination",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="pagination",this.currentPage=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=0,this.masterRowCount=0}postConstruct(){const 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 nf}isPaginateChildRows(){const 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){const t=this.currentPage;if(!this.active||t===e||"number"!=typeof t)return;const{editSvc:o}=this.beans;o?.isEditing()&&(o.isBatchEditing()?o.cleanupEditors():o.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(){const e=this.beans.rowModel.getRowCount(),t=Math.floor(e/this.pageSize);this.goToPage(t)}getPageSize(){return this.pageSize}getTotalPages(){return this.totalPages}setPage(e){this.currentPage=e}get pageSize(){return o(this.pageSizeAutoCalculated)&&this.gos.get("paginationAutoPageSize")?this.pageSizeAutoCalculated:o(this.pageSizeFromPageSizeSelector)?this.pageSizeFromPageSizeSelector:o(this.pageSizeFromInitialState)?this.pageSizeFromInitialState:o(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;const e=this.pageSizeAutoCalculated;this.pageSizeAutoCalculated=void 0,this.pageSize!==e&&(this.calculatePages(),this.dispatchPaginationChangedEvent({newPageSize:!0}))}setPageSize(e,t){const o=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()}o!==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(){const e=this.totalPages;this.currentPage>=e&&(this.currentPage=e-1);const t=this.currentPage;(!isFinite(t)||isNaN(t)||t<0)&&(this.currentPage=0)}calculatePagesMasterRowsOnly(){const e=this.beans.rowModel,t=e.getTopLevelRowCount();if(this.masterRowCount=t,t<=0)return void this.setZeroRows();const o=this.pageSize,i=t-1;this.totalPages=Math.floor(i/o)+1,this.adjustCurrentPageIfInvalid();const s=this.currentPage,n=o*s;let r=o*(s+1)-1;if(r>i&&(r=i),this.topDisplayedRowIndex=e.getTopLevelRowDisplayedIndex(n),r===i)this.bottomDisplayedRowIndex=e.getRowCount()-1;else{const t=e.getTopLevelRowDisplayedIndex(r+1);this.bottomDisplayedRowIndex=t-1}}getMasterRowCount(){return this.masterRowCount}calculatePagesAllRows(){const e=this.beans.rowModel.getRowCount();if(this.masterRowCount=e,0===e)return void this.setZeroRows();const{pageSize:t,currentPage:o}=this,i=e-1;this.totalPages=Math.floor(i/t)+1,this.adjustCurrentPageIfInvalid(),this.topDisplayedRowIndex=t*o,this.bottomDisplayedRowIndex=t*(o+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){const{keepRenderedRows:t=!1,newPage:o=!1,newPageSize:i=!1}=e;this.eventSvc.dispatchEvent({type:"paginationChanged",animate:!1,newData:!1,newPage:o,newPageSize:i,keepRenderedRows:t})}},class extends Me{constructor(){super(...arguments),this.beanName="paginationAutoPageSizeSvc"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.centerRowsCtrl=e.center;const 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;const e=this.centerRowsCtrl.viewportSizeFeature.getBodyHeight();if(e>0){const t=this.beans,o=()=>{const o=Math.max(mt(t),1),i=Math.floor(e/o);t.pagination.setPageSize(i,"autoCalculated")};this.isBodyRendered?Be(this,o,50)():(o(),this.isBodyRendered=!0)}else this.isBodyRendered=!1}}],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:[Lg]};var af={moduleName:"RowApi",version:qe,apiFunctions:{redrawRows:function(e,t={}){const o=t?t.rowNodes:void 0;e.frameworkOverrides.wrapIncoming(()=>e.rowRenderer.redrawRows(o))},setRowNodeExpanded:function e(t,o,i,s,n){o&&(s&&o.parent&&-1!==o.parent.level&&e(t,o.parent,i,s,n),o.setExpanded(i,void 0,n))},getRowNode:function(e,t){return e.rowModel.getRowNode(t)},addRenderedRowListener:function(e,t,o,i){e.rowRenderer.addRenderedRowListener(t,o,i)},getRenderedNodes:function(e){return e.rowRenderer.getRenderedNodes()},forEachNode:function(e,t,o){e.rowModel.forEachNode(t,o)},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()}}},lf={moduleName:"ScrollApi",version:qe,apiFunctions:{getVerticalPixelRange:function(e){return e.ctrlsSvc.getScrollFeature().getVScrollPosition()},getHorizontalPixelRange:function(e){return e.ctrlsSvc.getScrollFeature().getHScrollPosition()},ensureColumnVisible:jp,ensureIndexVisible:qp,ensureNodeVisible:function(e,t,o=null){e.frameworkOverrides.wrapIncoming(()=>e.ctrlsSvc.getScrollFeature().ensureNodeVisible(t,o),"ensureVisible")}}};var df={moduleName:"RenderApi",version:qe,apiFunctions:{setGridAriaProperty:function(e,t,o){if(!t)return;const i=e.ctrlsSvc.getGridBodyCtrl().eGridBody,s=`aria-${t}`;null===o?i.removeAttribute(s):i.setAttribute(s,o)},refreshCells:function(e,t={}){e.frameworkOverrides.wrapIncoming(()=>e.rowRenderer.refreshCells(t))},refreshHeader:function(e){e.frameworkOverrides.wrapIncoming(()=>e.ctrlsSvc.getHeaderRowContainerCtrls().forEach(e=>e.refresh()))},isAnimationFrameQueueEmpty:function(e){return e.animationFrameSvc?.isQueueEmpty()??!0},flushAllAnimationFrames:function(e){e.animationFrameSvc?.flushAllFrames()},getSizesForCurrentTheme:function(e){return{rowHeight:mt(e),headerHeight:La(e)}},getCellRendererInstances:function(e,t={}){const o=[];if(e.rowRenderer.getCellCtrls(t.rowNodes,t.columns).forEach(e=>{const t=e.getCellRenderer();null!=t&&o.push(fi(t))}),t.columns?.length)return o;const i=[],s=qu(t.rowNodes);return e.rowRenderer.getAllRowCtrls().forEach(e=>{if(s&&!_u(e.rowNode,s))return;if(!e.isFullWidth())return;const t=e.getFullWidthCellRenderers();for(let e=0;e<t.length;e++){const o=t[e];null!=o&&i.push(fi(o))}}),[...i,...o]}}};function hf({colAutosize:e,visibleCols:t},o,i){Array.isArray(o)?e?.autoSizeCols({colKeys:o,skipHeader:i,source:"api"}):e?.autoSizeCols({colKeys:o.colIds??t.allCols,skipHeader:o.skipHeader,defaultMaxWidth:o.defaultMaxWidth,defaultMinWidth:o.defaultMinWidth,columnLimits:o.columnLimits,source:"api"})}function cf(e,t,o={}){const i=o.minWidth??e.getMinWidth();t<i&&(t=i);const s=o.maxWidth??e.getMaxWidth();return t>s&&(t=s),t}var uf={moduleName:"ColumnAutoSize",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="colAutosize",this.timesDelayed=0,this.shouldQueueResizeOperations=!1,this.resizeOperationQueue=[]}postConstruct(){const e=this.gos.get("autoSizeStrategy");if(e){let t=!1;const o=e.type;"fitGridWidth"===o||"fitProvidedWidth"===o?t=!0:"fitCellContents"===o&&this.addManagedEventListeners({firstDataRendered:()=>this.onFirstDataRendered(e)}),t&&this.beans.colDelayRenderSvc?.hideColumns(o)}}autoSizeCols(e){if(this.shouldQueueResizeOperations)return void this.pushResizeOperation(()=>this.autoSizeCols(e));const{colKeys:t,skipHeader:o,skipHeaderGroups:i,stopAtGroup:s,defaultMaxWidth:n,defaultMinWidth:r,columnLimits:a=[],source:l="api"}=e,{animationFrameSvc:d,renderStatus:h,colModel:c,autoWidthCalc:u,visibleCols:g}=this.beans;if(d?.flushAllFrames(),this.timesDelayed<5&&h&&(!h.areHeaderCellsRendered()||!h.areCellsRendered()))return this.timesDelayed++,void setTimeout(()=>{this.isAlive()&&this.autoSizeCols(e)});this.timesDelayed=0;const p=[];let m=-1;const f=Object.fromEntries(a.map(({colId:e,maxWidth:t,minWidth:o})=>[e,{maxWidth:t,minWidth:o}])),C=null!=o?o:this.gos.get("skipHeaderOnAutoSize"),v=null!=i?i:C;for(;0!==m;){m=0;const e=[];t.forEach(t=>{if(!t||(po(o=t)||mo(o)))return;var o;const i=c.getCol(t);if(!i)return;if(p.indexOf(i)>=0)return;const s=u.getPreferredWidthForColumn(i,C);if(s>0){const e=f[i.colId]??{};e.minWidth??(e.minWidth=r),e.maxWidth??(e.maxWidth=n);const t=cf(i,s,e);i.setActualWidth(t,l),p.push(i),m++}e.push(i)}),e.length&&g.refresh(l)}v||this.autoSizeColumnGroupsByColumns(t,l,s),ko(this.eventSvc,p,!0,"autosizeColumns")}autoSizeColumn(e,t,o){e&&this.autoSizeCols({colKeys:[e],skipHeader:o,skipHeaderGroups:!0,source:t})}autoSizeColumnGroupsByColumns(e,t,o){const{colModel:i,ctrlsSvc:s}=this.beans,n=new Set;let r;i.getColsForKeys(e).forEach(e=>{let t=e.getParent();for(;t&&t!=o;)t.isPadding()||n.add(t),t=t.getParent()});for(const e of n){for(const t of s.getHeaderRowContainerCtrls())if(r=t.getHeaderCtrlForColumn(e),r)break;r&&r.resizeLeafColumnsToFit(t)}return[]}autoSizeAllColumns(e){if(this.shouldQueueResizeOperations)return void this.pushResizeOperation(()=>this.autoSizeAllColumns(e));const t=this.beans.visibleCols.allCols;this.autoSizeCols({colKeys:t,...e})}addColumnAutosize(e,t){const o=this.gos.get("skipHeaderOnAutoSize"),i=()=>{this.autoSizeColumn(t,"uiColumnResized",o)};e.addEventListener("dblclick",i);const s=new Ol(e);return s.addEventListener("doubleTap",i),()=>{e.removeEventListener("dblclick",i),s.removeEventListener("doubleTap",i),s.destroy()}}addColumnGroupResize(e,t,o){const i=this.gos.get("skipHeaderOnAutoSize"),s=()=>{const e=[];t.getDisplayedLeafColumns().forEach(t=>{t.getColDef().suppressAutoSize||e.push(t.getColId())}),e.length>0&&this.autoSizeCols({colKeys:e,skipHeader:i,stopAtGroup:t,source:"uiColumnResized"}),o()};return e.addEventListener("dblclick",s),()=>e.removeEventListener("dblclick",s)}sizeColumnsToFitGridBody(e,t){if(!this.isAlive())return;const{ctrlsSvc:o,scrollVisibleSvc:i}=this.beans,s=o.getGridBodyCtrl(),n=s.isVerticalScrollShowing()?i.getScrollbarWidth():0,r=z(s.eGridBody)-n;r>0?this.sizeColumnsToFit(r,"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):st(29)}sizeColumnsToFit(e,t="sizeColumnsToFit",o,i){if(this.shouldQueueResizeOperations)return void this.pushResizeOperation(()=>this.sizeColumnsToFit(e,t,o,i));const s={};i&&i?.columnLimits?.forEach(({key:e,...t})=>{s["string"==typeof e?e:e.getColId()]=t});const n=this.beans.visibleCols.allCols;if(e<=0||!n.length)return;if(e===co(n)){if(n.every(e=>{if(e.colDef.suppressSizeToFit)return!0;const t=s?.[e.getId()],o=t?.minWidth??i?.defaultMinWidth,n=t?.maxWidth??i?.defaultMaxWidth,r=e.getActualWidth();return(null==o||r>=o)&&(null==n||r<=n)}))return}const r=[],a=[];n.forEach(e=>{!0===e.getColDef().suppressSizeToFit?a.push(e):r.push(e)});const l=r.slice(0);let d=!1;const h=e=>{so(r,e),a.push(e)};for(r.forEach(e=>{e.resetActualWidth(t);const o=s?.[e.getId()],n=o?.minWidth??i?.defaultMinWidth,r=o?.maxWidth??i?.defaultMaxWidth,a=e.getActualWidth();"number"==typeof n&&a<n?e.setActualWidth(n,t,!0):"number"==typeof r&&a>r&&e.setActualWidth(r,t,!0)});!d;){d=!0;const o=e-co(a);if(o<=0)r.forEach(e=>{const o=s?.[e.getId()]?.minWidth??i?.defaultMinWidth;"number"!=typeof o?e.setActualWidth(e.minWidth,t):e.setActualWidth(o,t,!0)});else{const e=o/co(r);let n=o;for(let o=r.length-1;o>=0;o--){const a=r[o],l=s?.[a.getId()],c=l?.minWidth??i?.defaultMinWidth,u=l?.maxWidth??i?.defaultMaxWidth,g=a.getMinWidth(),p=a.getMaxWidth(),m="number"==typeof c&&c>g?c:g,f="number"==typeof u&&u<p?u:p;let C=Math.round(a.getActualWidth()*e);C<m?(C=m,h(a),d=!1):C>f?(C=f,h(a),d=!1):0===o&&(C=n),a.setActualWidth(C,t,!0),n-=C}}}l.forEach(e=>{e.fireColumnWidthChangedEvent(t)});const c=this.beans.visibleCols;c.setLeftValues(t),c.updateBodyWidths(),o||ko(this.eventSvc,l,!0,t)}applyAutosizeStrategy(){const{gos:e,colDelayRenderSvc:t}=this.beans,o=e.get("autoSizeStrategy");o&&"fitCellContents"!==o.type&&setTimeout(()=>{if(!this.isAlive())return;const e=o.type;if("fitGridWidth"===e){const{columnLimits:e,defaultMinWidth:t,defaultMaxWidth:i}=o,s=e?.map(({colId:e,minWidth:t,maxWidth:o})=>({key:e,minWidth:t,maxWidth:o}));this.sizeColumnsToFitGridBody({defaultMinWidth:t,defaultMaxWidth:i,columnLimits:s})}else"fitProvidedWidth"===e&&this.sizeColumnsToFit(o.width,"sizeColumnsToFit");t?.revealColumns(e)})}onFirstDataRendered(e){const{colIds:t,skipHeader:o,defaultMaxWidth:i,defaultMinWidth:s,columnLimits:n}=e;setTimeout(()=>{if(!this.isAlive())return;const e={skipHeader:o,source:"autosizeColumns",defaultMaxWidth:i,defaultMinWidth:s,columnLimits:n};t?this.autoSizeCols({colKeys:t,...e}):this.autoSizeAllColumns(e)})}processResizeOperations(){this.shouldQueueResizeOperations=!1,this.resizeOperationQueue.forEach(e=>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:hf,autoSizeAllColumns:function(e,t){t&&"object"==typeof t?hf(e,t):e.colAutosize?.autoSizeAllColumns({source:"api",skipHeader:t})}},dependsOn:[Qd]};var gf={moduleName:"PinnedRow",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="pinnedRowModel"}postConstruct(){const{gos:e}=this,t=()=>{const t=e.get("enableRowPinning"),o=Et(e),i=!!t||("pinnedBottom"===o||"pinnedTop"===o),s=i?this.inner instanceof wl:this.inner instanceof pl;this.inner&&s&&this.destroyBean(this.inner),!s&&this.inner||(this.inner=this.createManagedBean(i?new pl:new wl))};this.addManagedPropertyListeners(["enableRowPinning","grandTotalRow"],t),t()}reset(){return this.inner.reset()}isEmpty(e){return this.inner.isEmpty(e)}isManual(){return this.inner.isManual()}isRowsToRender(e){return this.inner.isRowsToRender(e)}pinRow(e,t,o){return this.inner.pinRow(e,t,o)}ensureRowHeightsValid(){return this.inner.ensureRowHeightsValid()}getPinnedRowById(e,t){return this.inner.getPinnedRowById(e,t)}getPinnedTopTotalHeight(){return this.inner.getPinnedTopTotalHeight()}getPinnedBottomTotalHeight(){return this.inner.getPinnedBottomTotalHeight()}getPinnedTopRowCount(){return this.inner.getPinnedTopRowCount()}getPinnedBottomRowCount(){return this.inner.getPinnedBottomRowCount()}getPinnedTopRow(e){return this.inner.getPinnedTopRow(e)}getPinnedBottomRow(e){return this.inner.getPinnedBottomRow(e)}forEachPinnedRow(e,t){return this.inner.forEachPinnedRow(e,t)}getPinnedState(){return this.inner.getPinnedState()}setPinnedState(e){return this.inner.setPinnedState(e)}setGrandTotalPinned(e){return this.inner.setGrandTotalPinned(e)}getGrandTotalPinned(){return this.inner.getGrandTotalPinned()}}],css:[".ag-row-pinned-source{background-color:var(--ag-pinned-source-row-background-color);color:var(--ag-pinned-source-row-text-color);font-weight:var(--ag-pinned-source-row-font-weight)}.ag-row-pinned-manual{background-color:var(--ag-pinned-row-background-color);color:var(--ag-pinned-row-text-color);font-weight:var(--ag-pinned-row-font-weight)}"],apiFunctions:{getPinnedTopRowCount:function(e){return e.pinnedRowModel?.getPinnedTopRowCount()??0},getPinnedBottomRowCount:function(e){return e.pinnedRowModel?.getPinnedBottomRowCount()??0},getPinnedTopRow:function(e,t){return e.pinnedRowModel?.getPinnedTopRow(t)},getPinnedBottomRow:function(e,t){return e.pinnedRowModel?.getPinnedBottomRow(t)},forEachPinnedRow:function(e,t,o){return e.pinnedRowModel?.forEachPinnedRow(t,o)}},icons:{rowPin:"pin",rowPinTop:"pinned-top",rowPinBottom:"pinned-bottom",rowUnpin:"un-pin"}},pf=class extends ku{constructor(e,t,o){super(e.col,e.firstNode,o,t),this.cellSpan=e,this.SPANNED_CELL_CSS_CLASS="ag-spanned-cell"}setComp(e,t,o,i,s,n,r){this.eWrapper=o,super.setComp(e,t,o,i,s,n,r),this.setAriaRowSpan(),this.refreshAriaRowIndex()}isCellSpanning(){return!0}getCellSpan(){return this.cellSpan}refreshAriaRowIndex(){null!=this.rowNode.rowIndex&&D(this.eGui,this.rowNode.rowIndex)}setAriaRowSpan(){var e,t;e=this.eGui,t=this.cellSpan.spannedNodes.size,v(e,"rowspan",t)}setFocusedCellPosition(e){this.focusedCellPosition=e}getFocusedCellPosition(){return this.focusedCellPosition??this.cellPosition}checkCellFocused(){const e=this.beans.focusSvc.getFocusedCell();return!!e&&this.cellSpan.doesSpanContain(e)}applyStaticCssClasses(){super.applyStaticCssClasses(),this.comp.toggleCss(this.SPANNED_CELL_CSS_CLASS,!0)}onCellFocused(e){const{beans:t}=this;if(Da(t))return void(this.focusedCellPosition=void 0);const o=this.isCellFocused();o||(this.focusedCellPosition=void 0),e&&o&&(this.focusedCellPosition={rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:e.column}),super.onCellFocused(e)}getRootElement(){return this.eWrapper}},mf=class extends Lu{onRowIndexChanged(){super.onRowIndexChanged(),this.getAllCellCtrls().forEach(e=>e.refreshAriaRowIndex())}getInitialRowClasses(e){return["ag-spanned-row"]}getNewCellCtrl(e){const t=this.beans.rowSpanSvc?.getCellSpan(e,this.rowNode);if(!t)return;return t.firstNode!==this.rowNode?void 0:new pf(t,this,this.beans)}isCorrectCtrlForSpan(e){const t=this.beans.rowSpanSvc?.getCellSpan(e.column,this.rowNode);if(!t)return!1;return!(t.firstNode!==this.rowNode)&&e.getCellSpan()===t}onRowHeightChanged(){}refreshFirstAndLastRowStyles(){}addHoverFunctionality(){}resetHoveredStatus(){}},ff=e=>e??"center",Cf=class{constructor(e,t){this.col=e,this.firstNode=t,this.cellSpan=!0,this.spannedNodes=new Set,this.addSpannedNode(t)}reset(){this.spannedNodes.clear(),this.addSpannedNode(this.firstNode)}addSpannedNode(e){this.spannedNodes.add(e),this.lastNode=e}getLastNode(){return this.lastNode}getCellHeight(){return this.lastNode.rowTop+this.lastNode.rowHeight-this.firstNode.rowTop-1}doesSpanContain(e){return e.column===this.col&&(e.rowPinned==this.firstNode.rowPinned&&(this.firstNode.rowIndex<=e.rowIndex&&e.rowIndex<=this.lastNode.rowIndex))}getLastNodeAutoHeight(){const e=this.firstNode.__autoHeights?.[this.col.getColId()];if(null==e)return;let t=0;return this.spannedNodes.forEach(e=>{e!==this.lastNode&&(t+=e.rowHeight)}),e-t}},vf=class extends Me{constructor(e){super(),this.column=e}buildCache(e){const{column:t,beans:{gos:o,pinnedRowModel:i,rowModel:s,valueSvc:n,pagination:r}}=this,{colDef:a}=t,l=this[`${e}ValueNodeMap`],d=new Map,h=o.getCallback("isFullWidthRow"),c=a.equals,u=a.spanRows,g="function"==typeof u;let p,m=null,f=null;const C=(e,t)=>{m=e,f=null,p=t},v=e=>{const i=!(e.isExpandable()||e.group||e.detail||h&&h({rowNode:e}));if(null==e.rowIndex||!i)return void C(null,null);if(null==m||e.level!==m.level||e.footer||f&&e.rowIndex-1!==f?.getLastNode().rowIndex)return void C(e,n.getValue(t,e));const s=n.getValue(t,e);if(g){const i=zt(o,{valueA:p,nodeA:m,valueB:s,nodeB:e,column:t,colDef:a});if(!u(i))return void C(e,s)}else if(c?!c(p,s):p!==s)return void C(e,s);if(!f){const e=l?.get(m);e?.firstNode===m?(e.reset(),f=e):f=new Cf(t,m),d.set(m,f)}f.addSpannedNode(e),d.set(e,f)};switch(e){case"center":s.forEachDisplayedNode?.(e=>{(!r||r.isRowInPage(e.rowIndex))&&v(e)});break;case"top":i?.forEachPinnedRow("top",v);break;case"bottom":i?.forEachPinnedRow("bottom",v)}this[`${e}ValueNodeMap`]=d}isCellSpanning(e){return!!this.getCellSpan(e)}getCellSpan(e){return this[`${ff(e.rowPinned)}ValueNodeMap`].get(e)}},wf={moduleName:"CellSpan",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="rowSpanSvc",this.spanningColumns=new Map,this.debouncePinnedEvent=Be(this,this.dispatchCellsUpdatedEvent.bind(this,!0),0),this.debounceModelEvent=Be(this,this.dispatchCellsUpdatedEvent.bind(this,!1),0),this.pinnedTimeout=null,this.modelTimeout=null}postConstruct(){const e=this.onRowDataUpdated.bind(this),t=this.buildPinnedCaches.bind(this);this.addManagedEventListeners({paginationChanged:this.buildModelCaches.bind(this),pinnedRowDataChanged:t,pinnedRowsChanged:t,rowNodeDataChanged:e,cellValueChanged:e})}register(e){const{gos:t}=this.beans;if(!t.get("enableCellSpan"))return;if(this.spanningColumns.has(e))return;const o=this.createManagedBean(new vf(e));this.spanningColumns.set(e,o),o.buildCache("top"),o.buildCache("bottom"),o.buildCache("center"),this.debouncePinnedEvent(),this.debounceModelEvent()}dispatchCellsUpdatedEvent(e){this.dispatchLocalEvent({type:"spannedCellsUpdated",pinned:e})}deregister(e){this.spanningColumns.delete(e)}onRowDataUpdated({node:e}){const{spannedRowRenderer:t}=this.beans;if(e.rowPinned){if(null!=this.pinnedTimeout)return;this.pinnedTimeout=window.setTimeout(()=>{this.pinnedTimeout=null,this.buildPinnedCaches(),t?.createCtrls("top"),t?.createCtrls("bottom")},0)}else null==this.modelTimeout&&(this.modelTimeout=window.setTimeout(()=>{this.modelTimeout=null,this.buildModelCaches(),t?.createCtrls("center")},0))}buildModelCaches(){null!=this.modelTimeout&&clearTimeout(this.modelTimeout),this.spanningColumns.forEach(e=>e.buildCache("center")),this.debounceModelEvent()}buildPinnedCaches(){null!=this.pinnedTimeout&&clearTimeout(this.pinnedTimeout),this.spanningColumns.forEach(e=>{e.buildCache("top"),e.buildCache("bottom")}),this.debouncePinnedEvent()}isCellSpanning(e,t){const o=this.spanningColumns.get(e);return!!o&&o.isCellSpanning(t)}getCellSpanByPosition(e){const{pinnedRowModel:t,rowModel:o}=this.beans,i=e.column,s=e.rowIndex,n=this.spanningColumns.get(i);if(!n)return;let r;switch(e.rowPinned){case"top":r=t?.getPinnedTopRow(s);break;case"bottom":r=t?.getPinnedBottomRow(s);break;default:r=o.getRow(s)}return r?n.getCellSpan(r):void 0}getCellStart(e){const t=this.getCellSpanByPosition(e);return t?{...e,rowIndex:t.firstNode.rowIndex}:e}getCellEnd(e){const t=this.getCellSpanByPosition(e);return t?{...e,rowIndex:t.getLastNode().rowIndex}:e}getCellSpan(e,t){const o=this.spanningColumns.get(e);if(o)return o.getCellSpan(t)}forEachSpannedColumn(e,t){for(const[o,i]of this.spanningColumns)if(i.isCellSpanning(e)){t(o,i.getCellSpan(e))}}destroy(){super.destroy(),this.spanningColumns.clear()}},class extends Me{constructor(){super(...arguments),this.beanName="spannedRowRenderer",this.topCtrls=new Map,this.bottomCtrls=new Map,this.centerCtrls=new Map}postConstruct(){this.addManagedEventListeners({displayedRowsChanged:this.createAllCtrls.bind(this)})}createAllCtrls(){this.createCtrls("top"),this.createCtrls("bottom"),this.createCtrls("center")}createCtrls(e){const{rowSpanSvc:t}=this.beans,o=`${e}Ctrls`,i=this[o],s=i.size,n=this.getAllRelevantRowControls(e),r=new Map;let a=!1;for(const e of n)e.isAlive()&&t?.forEachSpannedColumn(e.rowNode,(e,t)=>{if(r.has(t.firstNode))return;const o=i.get(t.firstNode);if(o)return r.set(t.firstNode,o),void i.delete(t.firstNode);a=!0;const s=new mf(t.firstNode,this.beans,!1,!1,!1);r.set(t.firstNode,s)});this[o]=r;const l=r.size===s;if(a||!l){for(const e of i.values())e.destroyFirstPass(!0),e.destroySecondPass();this.dispatchLocalEvent({type:"spannedRowsUpdated",ctrlsKey:e})}}getAllRelevantRowControls(e){const{rowRenderer:t}=this.beans;switch(e){case"top":return t.topRowCtrls;case"bottom":return t.bottomRowCtrls;case"center":return t.allRowCtrls}}getCellByPosition(e){const{rowSpanSvc:t}=this.beans,o=t?.getCellSpanByPosition(e);if(!o)return;const i=this[`${ff(e.rowPinned)}Ctrls`].get(o.firstNode);return i?i.getAllCellCtrls().find(t=>t.column===e.column):void 0}getCtrls(e){return[...this[`${e}Ctrls`].values()]}destroyRowCtrls(e){const t=`${e}Ctrls`;for(const e of this[t].values())e.destroyFirstPass(!0),e.destroySecondPass();this[t]=new Map}destroy(){super.destroy(),this.destroyRowCtrls("top"),this.destroyRowCtrls("bottom"),this.destroyRowCtrls("center")}}]},bf=class extends Me{constructor(e,t){super(),this.cellCtrl=e,this.staticClasses=[],this.beans=t,this.column=e.column}setComp(e){this.cellComp=e,this.applyUserStyles(),this.applyCellClassRules(),this.applyClassesFromColDef()}applyCellClassRules(){const{column:e,cellComp:t}=this,o=e.colDef,i=o.cellClassRules,s=this.getCellClassParams(e,o);Tu(this.beans.expressionSvc,i===this.cellClassRules?void 0:this.cellClassRules,i,s,e=>t.toggleCss(e,!0),e=>t.toggleCss(e,!1)),this.cellClassRules=i}applyUserStyles(){const e=this.column,t=e.colDef,o=t.cellStyle;if(!o)return;let i;if("function"==typeof o){i=o(this.getCellClassParams(e,t))}else i=o;i&&this.cellComp.setUserStyles(i)}applyClassesFromColDef(){const{column:e,cellComp:t}=this,o=e.colDef,i=this.getCellClassParams(e,o);this.staticClasses.forEach(e=>t.toggleCss(e,!1));const s=this.beans.cellStyles.getStaticCellClasses(o,i);this.staticClasses=s,s.forEach(e=>t.toggleCss(e,!0))}getCellClassParams(e,t){const{value:o,rowNode:i}=this.cellCtrl;return zt(this.beans.gos,{value:o,data:i.data,node:i,colDef:t,column:e,rowIndex:i.rowIndex})}},yf={moduleName:"CellStyle",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="cellStyles"}processAllCellClasses(e,t,o,i){Tu(this.beans.expressionSvc,void 0,e.cellClassRules,t,o,i),this.processStaticCellClasses(e,t,o)}getStaticCellClasses(e,t){const{cellClass:o}=e;if(!o)return[];let i;if("function"==typeof o){i=o(t)}else i=o;return"string"==typeof i&&(i=[i]),i||[]}createCellCustomStyleFeature(e,t){return new bf(e,t)}processStaticCellClasses(e,t,o){this.getStaticCellClasses(e,t).forEach(e=>{o(e)})}}]},Sf={moduleName:"RowStyle",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="rowStyleSvc"}processClassesFromGridOptions(e,t){const o=this.gos,i=t=>{"string"==typeof t?e.push(t):Array.isArray(t)&&t.forEach(t=>e.push(t))},s=o.get("rowClass");s&&i(s);const n=o.getCallback("getRowClass");if(n){i(n({data:t.data,node:t,rowIndex:t.rowIndex}))}}preProcessRowClassRules(e,t){this.processRowClassRules(t,t=>{e.push(t)},()=>{})}processRowClassRules(e,t,o){const{gos:i,expressionSvc:s}=this.beans,n=zt(i,{data:e.data,node:e,rowIndex:e.rowIndex});Tu(s,void 0,i.get("rowClassRules"),n,t,o)}processStylesFromGridOptions(e){const t=this.gos,o=t.get("rowStyle"),i=t.getCallback("getRowStyle");let s;if(i){s=i({data:e.data,node:e,rowIndex:e.rowIndex})}if(s||o)return Object.assign({},o,s)}}]};var Ef=class extends Me{constructor(e,t){super(),this.columns=e,this.element=t,this.destroyManagedListeners=[],this.enableFeature=e=>{const{beans:t,gos:o,element:i,columns:s}=this,n=t.colHover;e??!!o.get("columnHoverHighlight")?this.destroyManagedListeners=this.addManagedElementListeners(i,{mouseover:n.setMouseOver.bind(n,s),mouseout:n.clearMouseOver.bind(n)}):(this.destroyManagedListeners.forEach(e=>e()),this.destroyManagedListeners=[])}}postConstruct(){this.addManagedPropertyListener("columnHoverHighlight",({currentValue:e})=>{this.enableFeature(e)}),this.enableFeature()}destroy(){super.destroy(),this.destroyManagedListeners=null}},Rf={moduleName:"ColumnHover",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="colHover"}postConstruct(){this.addManagedPropertyListener("columnHoverHighlight",({currentValue:e})=>{e||this.clearMouseOver()})}setMouseOver(e){this.updateState(e)}clearMouseOver(){this.updateState(null)}isHovered(e){if(!this.gos.get("columnHoverHighlight"))return!1;const t=this.selectedColumns;return!!t&&t.indexOf(e)>=0}addHeaderColumnHoverListener(e,t,o){const i=()=>{const e=this.isHovered(o);t.toggleCss("ag-column-hover",e)};e.addManagedEventListeners({columnHoverChanged:i}),i()}onCellColumnHover(e,t){if(!t)return;const o=this.isHovered(e);t.toggleCss("ag-column-hover",o)}addHeaderFilterColumnHoverListener(e,t,o,i){this.createHoverFeature(e,[o],i);const s=()=>{const e=this.isHovered(o);t.toggleCss("ag-column-hover",e)};e.addManagedEventListeners({columnHoverChanged:s}),s()}createHoverFeature(e,t,o){e.createManagedBean(new Ef(t,o))}updateState(e){this.selectedColumns=e,this.eventSvc.dispatchEvent({type:"columnHoverChanged"})}}],apiFunctions:{isColumnHovered:function(e,t){return!!e.colHover?.isHovered(t)}}};var xf={moduleName:"EventApi",version:qe,apiFunctions:{addEventListener:function(e,t,o){e.apiEventSvc?.addListener(t,o)},addGlobalListener:function(e,t){e.apiEventSvc?.addGlobalListener(t)},removeEventListener:function(e,t,o){e.apiEventSvc?.removeListener(t,o)},removeGlobalListener:function(e,t){e.apiEventSvc?.removeGlobalListener(t)}},beans:[class extends Me{constructor(){super(...arguments),this.beanName="apiEventSvc",this.syncListeners=new Map,this.asyncListeners=new Map,this.syncGlobalListeners=new Set,this.globalListenerPairs=new Map}postConstruct(){this.wrapSvc=this.beans.frameworkOverrides.createGlobalEventListenerWrapper?.()}addListener(e,t){const o=this.wrapSvc?.wrap(e,t)??t,i=!xc.has(e),s=i?this.asyncListeners:this.syncListeners;s.has(e)||s.set(e,new Set),s.get(e).add(o),this.eventSvc.addListener(e,o,i)}removeListener(e,t){const o=this.wrapSvc?.unwrap(e,t)??t,i=this.asyncListeners.get(e),s=!!i?.delete(o);s||this.syncListeners.get(e)?.delete(o),this.eventSvc.removeListener(e,o,s)}addGlobalListener(e){const t=this.wrapSvc?.wrapGlobal(e)??e,o=(e,o)=>{xc.has(e)&&t(e,o)},i=(e,o)=>{xc.has(e)||t(e,o)};this.globalListenerPairs.set(e,{syncListener:o,asyncListener:i});const s=this.eventSvc;s.addGlobalListener(o,!1),s.addGlobalListener(i,!0)}removeGlobalListener(e){const{eventSvc:t,wrapSvc:o,globalListenerPairs:i}=this,s=o?.unwrapGlobal(e)??e;if(i.has(s)){const{syncListener:o,asyncListener:n}=i.get(s);t.removeGlobalListener(o,!1),t.removeGlobalListener(n,!0),i.delete(e)}else this.syncGlobalListeners.delete(s),t.removeGlobalListener(s,!1)}destroyEventListeners(e,t){e.forEach((e,o)=>{e.forEach(e=>this.eventSvc.removeListener(o,e,t)),e.clear()}),e.clear()}destroyGlobalListeners(e,t){e.forEach(e=>this.eventSvc.removeGlobalListener(e,t)),e.clear()}destroy(){super.destroy(),this.destroyEventListeners(this.syncListeners,!1),this.destroyEventListeners(this.asyncListeners,!0),this.destroyGlobalListeners(this.syncGlobalListeners,!1);const{globalListenerPairs:e,eventSvc:t}=this;e.forEach(({syncListener:e,asyncListener:o})=>{t.removeGlobalListener(e,!1),t.removeGlobalListener(o,!0)}),e.clear()}}]},Ff={moduleName:"Locale",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="localeSvc"}getLocaleTextFunc(){const e=this.gos,t=e.getCallback("getLocaleText");return t?function(e){return(t,o,i)=>e({key:t,defaultValue:o,variableValues:i})}(t):(o=e.get("localeText"),(e,t,i)=>{let s=o&&o[e];if(s&&i&&i.length){let e=0;for(;!(e>=i.length)&&-1!==s.indexOf("${variable}");)s=s.replace("${variable}",i[e++])}return s??t});var o}}]},Pf={moduleName:"AllCommunity",version:qe,dependsOn:[zm,Km,Ym,Tg,vm,wm,bm,ym,Sm,Em,Rm,Cm,Ep,Rp,xp,Sp,Fp,Pp,ef,Bm,rf,Ch,af,lf,df,uf,Gd,gf,Mm,Qu,yf,Rf,Sf,xf,Xu,Jm,Mp,Ff,{moduleName:"RowAutoHeight",version:qe,beans:[class extends Me{constructor(){super(...arguments),this.beanName="rowAutoHeight",this.wasEverActive=!1,this._debouncedCalculateRowHeights=Be(this,this.calculateRowHeights.bind(this),1)}requestCheckAutoHeight(){this.wasEverActive&&this._debouncedCalculateRowHeights()}calculateRowHeights(){const{visibleCols:e,rowModel:t,rowSpanSvc:o,pinnedRowModel:i}=this.beans,s=e.autoHeightCols;let n=!1;const r=e=>{const t=e.__autoHeights;let i=pt(this.beans,e).height;for(const n of s){let s=t?.[n.getColId()];const r=o?.getCellSpan(n,e);if(r){if(r.getLastNode()!==e)continue;if(s=o?.getCellSpan(n,e)?.getLastNodeAutoHeight(),!s)return}if(null==s){if(this.colSpanSkipCell(n,e))continue;return}i=Math.max(s,i)}i!==e.rowHeight&&(e.setRowHeight(i),n=!0)};i?.forEachPinnedRow?.("top",r),i?.forEachPinnedRow?.("bottom",r),t.forEachDisplayedNode?.(r),n&&t.onRowHeightChanged?.()}setRowAutoHeight(e,t,o){if(e.__autoHeights??(e.__autoHeights={}),null==t)return void delete e.__autoHeights[o.getId()];const i=e.__autoHeights[o.getId()];e.__autoHeights[o.getId()]=t,i!==t&&this.requestCheckAutoHeight()}colSpanSkipCell(e,t){const{colModel:o,colViewport:i,visibleCols:s}=this.beans;if(!o.colSpanActive)return!1;let n=[];switch(e.getPinned()){case"left":n=s.getLeftColsForRow(t);break;case"right":n=s.getRightColsForRow(t);break;case null:n=i.getColsWithinViewport(t)}return!n.includes(e)}setupCellAutoHeight(e,t,o){if(!e.column.isAutoHeight()||!t)return!1;this.wasEverActive=!0;const i=t.parentElement,{rowNode:s,column:n}=e,r=this.beans,a=l=>{if(this.beans.editSvc?.isEditing(e))return;if(!e.isAlive()||!o.isAlive())return;const{paddingTop:d,paddingBottom:h,borderBottomWidth:c,borderTopWidth:u}=N(i),p=d+h+c+u,m=t.offsetHeight+p;if(l<5){const e=g(r);if(!e||!e.contains(t)||0==m)return void window.setTimeout(()=>a(l+1),0)}this.setRowAutoHeight(s,m,n)},l=()=>a(0);l();const d=ce(r,t,l);return o.addDestroyFunc(()=>{d(),this.setRowAutoHeight(s,void 0,n)}),!0}setAutoHeightActive(e){this.active=e.list.some(e=>e.isVisible()&&e.isAutoHeight())}areRowsMeasured(){if(!this.active)return!0;const e=this.beans.rowRenderer.getAllRowCtrls();let t=null;for(const{rowNode:o}of e){if(!t||this.beans.colModel.colSpanActive){t=this.beans.colViewport.getColsWithinViewport(o).filter(e=>e.isAutoHeight())}if(0!==t.length){if(!o.__autoHeights)return!1;for(const e of t){const t=o.__autoHeights[e.getColId()];if(!t||o.rowHeight<t)return!1}}}return!0}}]},Hd,Wm,wf]};(class{static register(e){Fh(e,void 0)}static registerModules(e){e.forEach(e=>Fh(e,void 0))}}).registerModules([Pf]);var Df={createGrid:function(e,t,o){if(!t)return nt(11),{};const i=o;let s;if(!i?.setThemeOnGridDiv){const t=sr({tag:"div"});t.style.height="100%",e.appendChild(t),e=t,s=()=>e.remove()}return(new mg).create(e,t,t=>{const o=new nd(e);t.createBean(o)},void 0,o,s)},themes:{alpine:cc,balham:uc,material:pc,quartz:hc},colorSchemeVariable:jh};export{Df as default};
//# sourceMappingURL=index.js.map