ag-grid-enterprise
Version:
Advanced Data Grid / Data Table supporting Javascript / Typescript / React / Angular / Vue
1 lines • 3.32 MB
JavaScript
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.agGrid=t():e.agGrid=t()}(self,(function(){return function(){var e={7886:function(e,t,i){var a,r=Object.defineProperty,n=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,s=Object.prototype.hasOwnProperty,l={};((e,t)=>{for(var i in t)r(e,i,{get:t[i],enumerable:!0})})(l,{ClientSideRowModelModule:()=>I}),e.exports=(a=l,((e,t,i,a)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let l of o(t))s.call(e,l)||l===i||r(e,l,{get:()=>t[l],enumerable:!(a=n(t,l))||a.enumerable});return e})(r({},"__esModule",{value:!0}),a));var c=i(3423),d=i(3423),h=i(3423),u=i(3423),g=class{constructor(e,t,i,a,r,n){this.nextId=0,this.rowCountReady=!1,this.allNodesMap={},this.rootNode=e,this.gos=t,this.eventService=i,this.funcColsService=a,this.beans=n,this.selectionService=r,this.rootNode.group=!0,this.rootNode.level=-1,this.rootNode.id="ROOT_NODE_ID",this.rootNode.allLeafChildren=[],this.rootNode.childrenAfterGroup=[],this.rootNode.childrenAfterSort=[],this.rootNode.childrenAfterAggFilter=[],this.rootNode.childrenAfterFilter=[]}getCopyOfNodesMap(){return(0,u._cloneObject)(this.allNodesMap)}getRowNode(e){return this.allNodesMap[e]}setRowData(e){if("string"==typeof e)return void(0,u._warnOnce)("rowData must be an array.");this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(e);const t=this.rootNode,i=this.rootNode.sibling;t.childrenAfterFilter=null,t.childrenAfterGroup=null,t.childrenAfterAggFilter=null,t.childrenAfterSort=null,t.childrenMapped=null,t.updateHasChildren(),this.nextId=0,this.allNodesMap={},e?t.allLeafChildren=e.map(((e,t)=>this.createNode(e,this.rootNode,0,t))):(t.allLeafChildren=[],t.childrenAfterGroup=[]),i&&(i.childrenAfterFilter=t.childrenAfterFilter,i.childrenAfterGroup=t.childrenAfterGroup,i.childrenAfterAggFilter=t.childrenAfterAggFilter,i.childrenAfterSort=t.childrenAfterSort,i.childrenMapped=t.childrenMapped,i.allLeafChildren=t.allLeafChildren)}updateRowData(e){this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(e.add);const t={rowNodeTransaction:{remove:[],update:[],add:[]},rowsInserted:!1},i=[];return this.executeRemove(e,t,i),this.executeUpdate(e,t,i),this.executeAdd(e,t),this.updateSelection(i,"rowDataChanged"),t}updateRowOrderFromRowData(e){const t=this.rootNode.allLeafChildren,i=t?.length??0,a=new Map;let r=-1,n=-1;for(let o=0;o<i;++o){const i=t[o],s=i.data;s!==e[o]&&(n<0&&(r=o),n=o,a.set(s,i))}if(r<0)return!1;for(let i=r;i<=n;++i){const r=a.get(e[i]);void 0!==r&&(t[i]=r,r.sourceRowIndex=i)}return!0}isRowCountReady(){return this.rowCountReady}dispatchRowDataUpdateStartedEvent(e){this.eventService.dispatchEvent({type:"rowDataUpdateStarted",firstRowData:e?.length?e[0]:null})}updateSelection(e,t){const i=e.length>0;i&&this.selectionService.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t}),this.selectionService.updateGroupsFromChildrenSelections(t),i&&this.eventService.dispatchEvent({type:"selectionChanged",source:t})}executeAdd(e,t){const i=e.add;if((0,u._missingOrEmpty)(i))return;const a=this.rootNode.allLeafChildren;let r=a.length;if("number"==typeof e.addIndex&&(r=this.sanitizeAddIndex(e.addIndex),r>0)){if(this.gos.get("treeData"))for(let e=0;e<a.length;e++){const t=a[e];if(t?.rowIndex==r-1){r=e+1;break}}}const n=i.map(((e,t)=>this.createNode(e,this.rootNode,0,r+t)));if(r<a.length){const e=a.slice(0,r),i=a.slice(r,a.length),o=e.length+n.length;for(let e=0,t=i.length;e<t;++e)i[e].sourceRowIndex=o+e;this.rootNode.allLeafChildren=[...e,...n,...i],t.rowsInserted=!0}else this.rootNode.allLeafChildren=a.concat(n);const o=this.rootNode.sibling;o&&(o.allLeafChildren=a),t.rowNodeTransaction.add=n}sanitizeAddIndex(e){const t=this.rootNode.allLeafChildren?.length??0;return e<0||e>=t||Number.isNaN(e)?t:Math.ceil(e)}executeRemove(e,{rowNodeTransaction:t},i){const{remove:a}=e;if((0,u._missingOrEmpty)(a))return;const r={};a.forEach((e=>{const a=this.lookupRowNode(e);a&&(a.isSelected()&&i.push(a),a.clearRowTopAndRowIndex(),r[a.id]=!0,delete this.allNodesMap[a.id],t.remove.push(a))})),this.rootNode.allLeafChildren=this.rootNode.allLeafChildren?.filter((e=>!r[e.id]))??null,this.rootNode.allLeafChildren?.forEach(((e,t)=>{e.sourceRowIndex=t}));const n=this.rootNode.sibling;n&&(n.allLeafChildren=this.rootNode.allLeafChildren)}executeUpdate(e,{rowNodeTransaction:t},i){const{update:a}=e;(0,u._missingOrEmpty)(a)||a.forEach((e=>{const a=this.lookupRowNode(e);a&&(a.updateData(e),!a.selectable&&a.isSelected()&&i.push(a),this.setMasterForRow(a,e,0,!1),t.update.push(a))}))}lookupRowNode(e){const t=(0,u._getRowIdCallback)(this.gos);let i;if(t){const a=t({data:e,level:0});if(i=this.allNodesMap[a],!i)return(0,u._errorOnce)(`could not find row id=${a}, data item was not found for this id`),null}else if(i=this.rootNode.allLeafChildren?.find((t=>t.data===e)),!i)return(0,u._errorOnce)("could not find data item as object was not found",e),(0,u._errorOnce)("Consider using getRowId to help the Grid find matching row data"),null;return i||null}createNode(e,t,i,a){const r=new u.RowNode(this.beans);return r.sourceRowIndex=a,r.group=!1,this.setMasterForRow(r,e,i,!0),t&&(r.parent=t),r.level=i,r.setDataAndId(e,this.nextId.toString()),this.allNodesMap[r.id]&&(0,u._warnOnce)(`duplicate node id '${r.id}' detected from getRowId callback, this could cause issues in your grid.`),this.allNodesMap[r.id]=r,this.nextId++,r}setMasterForRow(e,t,i,a){if(this.gos.get("treeData"))e.setMaster(!1),a&&(e.expanded=!1);else{if(this.gos.get("masterDetail")){const i=this.gos.get("isRowMaster");i?e.setMaster(i(t)):e.setMaster(!0)}else e.setMaster(!1);if(a){const t=this.funcColsService.getRowGroupColumns(),a=i+(t?t.length:0);e.expanded=!!e.master&&this.isExpanded(a)}}}isExpanded(e){const t=this.gos.get("groupDefaultExpanded");return-1===t||e<t}},p=class extends h.BeanStub{constructor(){super(...arguments),this.beanName="rowModel",this.onRowHeightChanged_debounced=(0,h._debounce)(this.onRowHeightChanged.bind(this),100),this.rowsToDisplay=[],this.hasStarted=!1,this.shouldSkipSettingDataOnStart=!1,this.isRefreshingModel=!1,this.rowCountReady=!1}wireBeans(e){this.beans=e,this.columnModel=e.columnModel,this.funcColsService=e.funcColsService,this.selectionService=e.selectionService,this.valueCache=e.valueCache,this.environment=e.environment,this.filterStage=e.filterStage,this.sortStage=e.sortStage,this.flattenStage=e.flattenStage,this.groupStage=e.groupStage,this.aggregationStage=e.aggregationStage,this.pivotStage=e.pivotStage,this.filterAggregatesStage=e.filterAggregatesStage}postConstruct(){const e=this.refreshModel.bind(this,{step:h.ClientSideRowModelSteps.EVERYTHING}),t=!this.gos.get("suppressAnimationFrame"),i=this.refreshModel.bind(this,{step:h.ClientSideRowModelSteps.EVERYTHING,afterColumnsChanged:!0,keepRenderedRows:!0,animate:t});this.addManagedEventListeners({newColumnsLoaded:i,columnRowGroupChanged:e,columnValueChanged:this.onValueChanged.bind(this),columnPivotChanged:this.refreshModel.bind(this,{step:h.ClientSideRowModelSteps.PIVOT}),filterChanged:this.onFilterChanged.bind(this),sortChanged:this.onSortChanged.bind(this),columnPivotModeChanged:e,gridStylesChanged:this.onGridStylesChanges.bind(this),gridReady:this.onGridReady.bind(this)}),this.addPropertyListeners(),this.rootNode=new h.RowNode(this.beans),this.nodeManager=new g(this.rootNode,this.gos,this.eventService,this.funcColsService,this.selectionService,this.beans)}addPropertyListeners(){const e=new Set(["treeData","masterDetail"]),t=new Set(["groupDefaultExpanded","groupAllowUnbalanced","initialGroupOrderComparator","groupHideOpenParents","groupDisplayType"]),i=new Set(["excludeChildrenWhenTreeDataFiltering"]),a=new Set(["removePivotHeaderRowWhenSingleValueColumn","pivotRowTotals","pivotColumnGroupTotals","suppressExpandablePivotGroups"]),r=new Set(["getGroupRowAgg","alwaysAggregateAtRootLevel","groupIncludeTotalFooter","suppressAggFilteredOnly","grandTotalRow"]),n=new Set(["postSortRows","groupDisplayType","accentedSort"]),o=new Set([]),s=new Set(["groupRemoveSingleChildren","groupRemoveLowestSingleChildren","groupIncludeFooter","groupTotalRow"]),l=[...e,...t,...i,...a,...a,...r,...n,...o,...s];this.addManagedPropertyListeners(l,(l=>{const c=l.changeSet?.properties;if(!c)return;const d=e=>c.some((t=>e.has(t)));d(e)?this.setRowData(this.rootNode.allLeafChildren.map((e=>e.data))):d(t)?this.refreshModel({step:h.ClientSideRowModelSteps.EVERYTHING}):d(i)?this.refreshModel({step:h.ClientSideRowModelSteps.FILTER}):d(a)?this.refreshModel({step:h.ClientSideRowModelSteps.PIVOT}):d(r)?this.refreshModel({step:h.ClientSideRowModelSteps.AGGREGATE}):d(n)?this.refreshModel({step:h.ClientSideRowModelSteps.SORT}):d(o)?this.refreshModel({step:h.ClientSideRowModelSteps.FILTER_AGGREGATES}):d(s)&&this.refreshModel({step:h.ClientSideRowModelSteps.MAP})})),this.addManagedPropertyListener("rowHeight",(()=>this.resetRowHeights()))}start(){this.hasStarted=!0,this.shouldSkipSettingDataOnStart?this.dispatchUpdateEventsAndRefresh():this.setInitialData()}setInitialData(){const e=this.gos.get("rowData");e&&(this.shouldSkipSettingDataOnStart=!0,this.setRowData(e))}ensureRowHeightsValid(e,t,i,a){let r,n=!1;do{r=!1;const o=this.getRowIndexAtPixel(e),s=this.getRowIndexAtPixel(t),l=Math.max(o,i),c=Math.min(s,a);for(let e=l;e<=c;e++){const t=this.getRow(e);if(t.rowHeightEstimated){const e=(0,h._getRowHeightForNode)(this.gos,t);t.setRowHeight(e.height),r=!0,n=!0}}r&&this.setRowTopAndRowIndex()}while(r);return n}setRowTopAndRowIndex(){const e=this.environment.getDefaultRowHeight();let t=0;const i=new Set,a=(0,h._isDomLayout)(this.gos,"normal");for(let r=0;r<this.rowsToDisplay.length;r++){const n=this.rowsToDisplay[r];if(null!=n.id&&i.add(n.id),null==n.rowHeight){const t=(0,h._getRowHeightForNode)(this.gos,n,a,e);n.setRowHeight(t.height,t.estimated)}n.setRowTop(t),n.setRowIndex(r),t+=n.rowHeight}return i}clearRowTopAndRowIndex(e,t){const i=e.isActive(),a=e=>{e&&null!=e.id&&!t.has(e.id)&&e.clearRowTopAndRowIndex()},r=e=>{if(a(e),a(e.detailNode),a(e.sibling),e.hasChildren()&&e.childrenAfterGroup){const t=-1==e.level;i&&!t&&!e.expanded||e.childrenAfterGroup.forEach(r)}};r(this.rootNode)}ensureRowsAtPixel(e,t,i=0){const a=this.getRowIndexAtPixel(t),r=this.getRow(a),n=!this.gos.get("suppressAnimationFrame");if(r===e[0])return!1;const o=this.rootNode.allLeafChildren;return e.forEach((e=>{(0,h._removeFromArray)(o,e)})),e.forEach(((e,t)=>{(0,h._insertIntoArray)(o,e,Math.max(a+i,0)+t)})),e.forEach(((e,t)=>{e.sourceRowIndex=t})),this.refreshModel({step:h.ClientSideRowModelSteps.EVERYTHING,keepRenderedRows:!0,keepEditingRows:!0,animate:n,rowNodesOrderChanged:!0}),!0}highlightRowAtPixel(e,t){const i=null!=t?this.getRowIndexAtPixel(t):null,a=null!=i?this.getRow(i):null;if(!a||!e||a===e||null==t)return void(this.lastHighlightedRow&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null));const r=this.getHighlightPosition(t,a);this.lastHighlightedRow&&this.lastHighlightedRow!==a&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null),a.setHighlighted(r),this.lastHighlightedRow=a}getHighlightPosition(e,t){if(!t){const i=this.getRowIndexAtPixel(e);if(!(t=this.getRow(i||0)))return h.RowHighlightPosition.Below}const{rowTop:i,rowHeight:a}=t;return e-i<a/2?h.RowHighlightPosition.Above:h.RowHighlightPosition.Below}getLastHighlightedRowNode(){return this.lastHighlightedRow}isLastRowIndexKnown(){return!0}getRowCount(){return this.rowsToDisplay?this.rowsToDisplay.length:0}getTopLevelRowCount(){if(0===this.rowsToDisplay.length)return 0;if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return 1;const e=this.rootNode.childrenAfterAggFilter,t=this.rootNode.sibling?1:0;return(e?e.length:0)+t}getTopLevelRowDisplayedIndex(e){if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return e;let t=e;if(this.rowsToDisplay[0].footer){if(0===e)return 0;t-=1}const i=this.rowsToDisplay[this.rowsToDisplay.length-1],a=t>=this.rootNode.childrenAfterSort.length;if(i.footer&&a)return i.rowIndex;let r=this.rootNode.childrenAfterSort[t];if(this.gos.get("groupHideOpenParents"))for(;r.expanded&&r.childrenAfterSort&&r.childrenAfterSort.length>0;)r=r.childrenAfterSort[0];return r.rowIndex}getRowBounds(e){if((0,h._missing)(this.rowsToDisplay))return null;const t=this.rowsToDisplay[e];return t?{rowTop:t.rowTop,rowHeight:t.rowHeight}:null}onRowGroupOpened(){const e=(0,h._isAnimateRows)(this.gos);this.refreshModel({step:h.ClientSideRowModelSteps.MAP,keepRenderedRows:!0,animate:e})}onFilterChanged(e){if(e.afterDataChange)return;const t=(0,h._isAnimateRows)(this.gos),i=0===e.columns.length||e.columns.some((e=>e.isPrimary()))?h.ClientSideRowModelSteps.FILTER:h.ClientSideRowModelSteps.FILTER_AGGREGATES;this.refreshModel({step:i,keepRenderedRows:!0,animate:t})}onSortChanged(){const e=(0,h._isAnimateRows)(this.gos);this.refreshModel({step:h.ClientSideRowModelSteps.SORT,keepRenderedRows:!0,animate:e,keepEditingRows:!0})}getType(){return"clientSide"}onValueChanged(){this.columnModel.isPivotActive()?this.refreshModel({step:h.ClientSideRowModelSteps.PIVOT}):this.refreshModel({step:h.ClientSideRowModelSteps.AGGREGATE})}createChangePath(e){const t=(0,h._missingOrEmpty)(e),i=new h.ChangedPath(!1,this.rootNode);return t&&i.setInactive(),i}isSuppressModelUpdateAfterUpdateTransaction(e){if(!this.gos.get("suppressModelUpdateAfterUpdateTransaction"))return!1;if(null==e.rowNodeTransactions)return!1;const t=e.rowNodeTransactions.filter((e=>null!=e.add&&e.add.length>0||null!=e.remove&&e.remove.length>0));return null==t||0==t.length}buildRefreshModelParams(e){let t=h.ClientSideRowModelSteps.EVERYTHING;const i={everything:h.ClientSideRowModelSteps.EVERYTHING,group:h.ClientSideRowModelSteps.EVERYTHING,filter:h.ClientSideRowModelSteps.FILTER,map:h.ClientSideRowModelSteps.MAP,aggregate:h.ClientSideRowModelSteps.AGGREGATE,sort:h.ClientSideRowModelSteps.SORT,pivot:h.ClientSideRowModelSteps.PIVOT};if((0,h._exists)(e)&&(t=i[e]),(0,h._missing)(t))return void(0,h._errorOnce)(`invalid step ${e}, available steps are ${Object.keys(i).join(", ")}`);return{step:t,keepRenderedRows:!0,keepEditingRows:!0,animate:!this.gos.get("suppressAnimationFrame")}}refreshModel(e){if(!this.hasStarted||this.isRefreshingModel||this.columnModel.isChangeEventsDispatching())return;const t="object"==typeof e&&"step"in e?e:this.buildRefreshModelParams(e);if(!t)return;if(this.isSuppressModelUpdateAfterUpdateTransaction(t))return;const i=this.createChangePath(t.rowNodeTransactions);switch(this.isRefreshingModel=!0,t.step){case h.ClientSideRowModelSteps.EVERYTHING:this.doRowGrouping(t.rowNodeTransactions,i,!!t.rowNodesOrderChanged,!!t.afterColumnsChanged);case h.ClientSideRowModelSteps.FILTER:this.doFilter(i);case h.ClientSideRowModelSteps.PIVOT:this.doPivot(i);case h.ClientSideRowModelSteps.AGGREGATE:this.doAggregate(i);case h.ClientSideRowModelSteps.FILTER_AGGREGATES:this.doFilterAggregates(i);case h.ClientSideRowModelSteps.SORT:this.doSort(t.rowNodeTransactions,i);case h.ClientSideRowModelSteps.MAP:this.doRowsToDisplay()}const a=this.setRowTopAndRowIndex();this.clearRowTopAndRowIndex(i,a),this.isRefreshingModel=!1,this.eventService.dispatchEvent({type:"modelUpdated",animate:t.animate,keepRenderedRows:t.keepRenderedRows,newData:t.newData,newPage:!1,keepUndoRedoStack:t.keepUndoRedoStack})}isEmpty(){const e=(0,h._missing)(this.rootNode.allLeafChildren)||0===this.rootNode.allLeafChildren.length;return(0,h._missing)(this.rootNode)||e||!this.columnModel.isReady()}isRowsToRender(){return(0,h._exists)(this.rowsToDisplay)&&this.rowsToDisplay.length>0}getNodesInRangeForSelection(e,t){let i=!1,a=!1;const r=[],n=(0,h._getGroupSelectsDescendants)(this.gos);return this.forEachNodeAfterFilterAndSort((o=>{if(a)return;if(i&&(o===t||o===e)&&(a=!0,o.group&&n))return void r.push(...o.allLeafChildren);if(!i){if(o!==t&&o!==e)return;i=!0}(!o.group||!n)&&r.push(o)})),r}setDatasource(e){(0,h._errorOnce)("should never call setDatasource on clientSideRowController")}getTopLevelNodes(){return this.rootNode?this.rootNode.childrenAfterGroup:null}getRootNode(){return this.rootNode}getRow(e){return this.rowsToDisplay[e]}isRowPresent(e){return this.rowsToDisplay.indexOf(e)>=0}getRowIndexAtPixel(e){if(this.isEmpty()||0===this.rowsToDisplay.length)return-1;let t=0,i=this.rowsToDisplay.length-1;if(e<=0)return 0;if((0,h._last)(this.rowsToDisplay).rowTop<=e)return this.rowsToDisplay.length-1;let a=-1,r=-1;for(;;){const n=Math.floor((t+i)/2),o=this.rowsToDisplay[n];if(this.isRowInPixel(o,e))return n;o.rowTop<e?t=n+1:o.rowTop>e&&(i=n-1);if(a===t&&r===i)return n;a=t,r=i}}isRowInPixel(e,t){const i=e.rowTop,a=e.rowTop+e.rowHeight;return i<=t&&a>t}forEachLeafNode(e){this.rootNode.allLeafChildren&&this.rootNode.allLeafChildren.forEach(((t,i)=>e(t,i)))}forEachNode(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterGroup||[]],callback:e,recursionType:0,index:0,includeFooterNodes:t})}forEachNodeAfterFilter(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterAggFilter||[]],callback:e,recursionType:1,index:0,includeFooterNodes:t})}forEachNodeAfterFilterAndSort(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterSort||[]],callback:e,recursionType:2,index:0,includeFooterNodes:t})}forEachPivotNode(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[this.rootNode],callback:e,recursionType:3,index:0,includeFooterNodes:t})}recursivelyWalkNodesAndCallback(e){const{nodes:t,callback:i,recursionType:a,includeFooterNodes:r}=e;let{index:n}=e;const o=e=>{const a=t[0]?.parent;if(!a)return;const o=r&&(0,h._getGrandTotalRow)(this.gos),s=(0,h._getGroupTotalRowCallback)(this.gos),l=r&&s({node:a});a===this.rootNode?o===e&&(a.createFooter(),i(a.sibling,n++)):l===e&&(a.createFooter(),i(a.sibling,n++))};o("top");for(let e=0;e<t.length;e++){const o=t[e];if(i(o,n++),o.hasChildren()&&!o.footer){let e=null;switch(a){case 0:e=o.childrenAfterGroup;break;case 1:e=o.childrenAfterAggFilter;break;case 2:e=o.childrenAfterSort;break;case 3:e=o.leafGroup?null:o.childrenAfterSort}e&&(n=this.recursivelyWalkNodesAndCallback({nodes:[...e],callback:i,recursionType:a,index:n,includeFooterNodes:r}))}}return o("bottom"),n}doAggregate(e){this.aggregationStage?.execute({rowNode:this.rootNode,changedPath:e})}doFilterAggregates(e){this.filterAggregatesStage?this.filterAggregatesStage.execute({rowNode:this.rootNode,changedPath:e}):this.rootNode.childrenAfterAggFilter=this.rootNode.childrenAfterFilter}expandOrCollapseAll(e){const t=this.gos.get("treeData"),i=this.columnModel.isPivotActive(),a=r=>{r&&r.forEach((r=>{const n=()=>{r.expanded=e,a(r.childrenAfterGroup)};if(t){return void((0,h._exists)(r.childrenAfterGroup)&&n())}if(i){return void(!r.leafGroup&&n())}r.group&&n()}))};this.rootNode&&a(this.rootNode.childrenAfterGroup),this.refreshModel({step:h.ClientSideRowModelSteps.MAP}),this.eventService.dispatchEvent({type:"expandOrCollapseAll",source:e?"expandAll":"collapseAll"})}doSort(e,t){this.sortStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,changedPath:t})}doRowGrouping(e,t,i,a){if(this.groupStage){if(e?this.groupStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,rowNodesOrderChanged:i,changedPath:t}):this.groupStage.execute({rowNode:this.rootNode,changedPath:t,afterColumnsChanged:a}),(0,h._getGroupSelectsDescendants)(this.gos)){this.selectionService.updateGroupsFromChildrenSelections("rowGroupChanged",t)&&this.eventService.dispatchEvent({type:"selectionChanged",source:"rowGroupChanged"})}}else{const e=this.rootNode,t=e.sibling;e.childrenAfterGroup=e.allLeafChildren,t&&(t.childrenAfterGroup=e.childrenAfterGroup),this.rootNode.updateHasChildren()}this.nodeManager.isRowCountReady()&&(this.rowCountReady=!0,this.eventService.dispatchEventOnce({type:"rowCountReady"}))}doFilter(e){this.filterStage.execute({rowNode:this.rootNode,changedPath:e})}doPivot(e){this.pivotStage?.execute({rowNode:this.rootNode,changedPath:e})}getNodeManager(){return this.nodeManager}getRowNode(e){if("string"==typeof e&&0==e.indexOf(h.RowNode.ID_PREFIX_ROW_GROUP)){let t;return this.forEachNode((i=>{i.id===e&&(t=i)})),t}return this.nodeManager.getRowNode(e)}setRowData(e){this.selectionService.reset("rowDataChanged"),this.nodeManager.setRowData(e),this.hasStarted&&this.dispatchUpdateEventsAndRefresh()}dispatchUpdateEventsAndRefresh(){this.eventService.dispatchEvent({type:"rowDataUpdated"}),this.refreshModel({step:h.ClientSideRowModelSteps.EVERYTHING,newData:!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=[];let i=!1;this.rowDataTransactionBatch?.forEach((a=>{const{rowNodeTransaction:r,rowsInserted:n}=this.nodeManager.updateRowData(a.rowDataTransaction);n&&(i=!0),t.push(r),a.callback&&e.push(a.callback.bind(null,r))})),this.commonUpdateRowData(t,i),e.length>0&&window.setTimeout((()=>{e.forEach((e=>e()))}),0),t.length>0&&this.eventService.dispatchEvent({type:"asyncTransactionsFlushed",results:t}),this.rowDataTransactionBatch=null,this.applyAsyncTransactionsTimeout=void 0}updateRowData(e){this.valueCache.onDataChanged();const{rowNodeTransaction:t,rowsInserted:i}=this.nodeManager.updateRowData(e);return this.commonUpdateRowData([t],i),t}afterImmutableDataChange(e,t){this.commonUpdateRowData([e],t)}commonUpdateRowData(e,t){if(!this.hasStarted)return;const i=!this.gos.get("suppressAnimationFrame");this.eventService.dispatchEvent({type:"rowDataUpdated"}),this.refreshModel({step:h.ClientSideRowModelSteps.EVERYTHING,rowNodeTransactions:e,rowNodesOrderChanged:t,keepRenderedRows:!0,keepEditingRows:!0,animate:i})}doRowsToDisplay(){this.rowsToDisplay=this.flattenStage.execute({rowNode:this.rootNode})}onRowHeightChanged(){this.refreshModel({step:h.ClientSideRowModelSteps.MAP,keepRenderedRows:!0,keepEditingRows:!0,keepUndoRedoStack:!0})}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}resetRowHeights(){const e=this.resetRowHeightsForAllRowNodes();this.rootNode.setRowHeight(this.rootNode.rowHeight,!0),this.rootNode.sibling&&this.rootNode.sibling.setRowHeight(this.rootNode.sibling.rowHeight,!0),e&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode((t=>{t.setRowHeight(t.rowHeight,!0);const i=t.detailNode;i&&i.setRowHeight(i.rowHeight,!0),t.sibling&&t.sibling.setRowHeight(t.sibling.rowHeight,!0),e=!0})),e}onGridStylesChanges(e){if(e.rowHeightChanged){if(this.columnModel.isAutoRowHeightActive())return;this.resetRowHeights()}}onGridReady(){this.hasStarted||this.setInitialData()}isRowDataLoaded(){return this.rowCountReady}},m=i(3423);var f=i(3423),v=class extends f.BeanStub{constructor(){super(...arguments),this.beanName="filterStage"}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 i=(t,i)=>{t.hasChildren()?t.childrenAfterFilter=e&&!i?t.childrenAfterGroup.filter((e=>{const t=e.childrenAfterFilter&&e.childrenAfterFilter.length>0,i=e.data&&this.filterManager.doesRowPassFilter({rowNode:e});return t||i})):t.childrenAfterGroup:t.childrenAfterFilter=t.childrenAfterGroup,t.sibling&&(t.sibling.childrenAfterFilter=t.childrenAfterFilter)};if(this.doingTreeDataFiltering()){const e=(t,a)=>{if(t.childrenAfterGroup)for(let r=0;r<t.childrenAfterGroup.length;r++){const n=t.childrenAfterGroup[r],o=a||this.filterManager.doesRowPassFilter({rowNode:n});n.childrenAfterGroup?e(t.childrenAfterGroup[r],o):i(n,o)}i(t,a)},a=t=>e(t,!1);t.executeFromRootNode(a)}else{const e=e=>i(e,!1);t.forEachChangedNodeDepthFirst(e,!0)}}doingTreeDataFiltering(){return this.gos.get("treeData")&&!this.gos.get("excludeChildrenWhenTreeDataFiltering")}},y=i(3423),b=class extends y.BeanStub{constructor(){super(...arguments),this.beanName="flattenStage"}wireBeans(e){this.beans=e,this.columnModel=e.columnModel}execute(e){const t=e.rowNode,i=[],a=this.columnModel.isPivotMode(),r=a&&t.leafGroup,n=r?[t]:t.childrenAfterSort,o=this.getFlattenDetails();this.recursivelyAddToRowsToDisplay(o,n,i,a,0);if(!r&&i.length>0&&o.grandTotalRow){t.createFooter();const e="top"===o.grandTotalRow;this.addRowNodeToRowsToDisplay(o,t.sibling,i,0,e)}return i}getFlattenDetails(){const e=this.gos.get("groupRemoveSingleChildren");return{groupRemoveLowestSingleChildren:!e&&this.gos.get("groupRemoveLowestSingleChildren"),groupRemoveSingleChildren:e,isGroupMultiAutoColumn:(0,y._isGroupMultiAutoColumn)(this.gos),hideOpenParents:this.gos.get("groupHideOpenParents"),grandTotalRow:(0,y._getGrandTotalRow)(this.gos),groupTotalRow:(0,y._getGroupTotalRowCallback)(this.gos)}}recursivelyAddToRowsToDisplay(e,t,i,a,r){if(!(0,y._missingOrEmpty)(t))for(let n=0;n<t.length;n++){const o=t[n],s=o.hasChildren(),l=a&&!s,c=e.groupRemoveSingleChildren&&s&&1===o.childrenAfterGroup.length,d=e.groupRemoveLowestSingleChildren&&s&&o.leafGroup&&1===o.childrenAfterGroup.length,h=a&&o.leafGroup,u=e.hideOpenParents&&o.expanded&&!o.master&&!h;if(!(l||u||c||d)&&this.addRowNodeToRowsToDisplay(e,o,i,r),!a||!o.leafGroup)if(s){const t=c||d;if(o.expanded||t){const n=e.groupTotalRow({node:o});n||o.destroyFooter();const s=t?r:r+1;"top"===n&&(o.createFooter(),this.addRowNodeToRowsToDisplay(e,o.sibling,i,s)),this.recursivelyAddToRowsToDisplay(e,o.childrenAfterSort,i,a,s),"bottom"===n&&(o.createFooter(),this.addRowNodeToRowsToDisplay(e,o.sibling,i,s))}}else if(o.master&&o.expanded){const t=this.createDetailNode(o);this.addRowNodeToRowsToDisplay(e,t,i,r)}}}addRowNodeToRowsToDisplay(e,t,i,a,r){r?i.unshift(t):i.push(t),t.setUiLevel(e.isGroupMultiAutoColumn?0:a)}createDetailNode(e){if((0,y._exists)(e.detailNode))return e.detailNode;const t=new y.RowNode(this.beans);return t.detail=!0,t.selectable=!1,t.parent=e,(0,y._exists)(e.id)&&(t.id="detail_"+e.id),t.data=e.data,t.level=e.level+1,e.detailNode=t,t}},C=i(3423),w=class extends C.BeanStub{constructor(){super(...arguments),this.beanName="immutableService"}wireBeans(e){this.rowModel=e.rowModel,this.selectionService=e.selectionService}postConstruct(){(0,C._isClientSideRowModel)(this.gos)&&(this.clientSideRowModel=this.rowModel,this.addManagedPropertyListener("rowData",(()=>this.onRowDataUpdated())))}isActive(){const e=this.gos.exists("getRowId");return!this.gos.get("resetRowDataOnUpdate")&&e}setRowData(e){const t=this.createTransactionForRowData(e);if(!t)return;const i=this.clientSideRowModel.getNodeManager(),{rowNodeTransaction:a,rowsInserted:r}=i.updateRowData(t);let n=!1;this.gos.get("suppressMaintainUnsortedOrder")||(n=i.updateRowOrderFromRowData(e)),this.clientSideRowModel.afterImmutableDataChange(a,n||r)}createTransactionForRowData(e){if(!(0,C._isClientSideRowModel)(this.gos))return(0,C._errorOnce)("ImmutableService only works with ClientSideRowModel"),null;const t=(0,C._getRowIdCallback)(this.gos);if(null==t)return(0,C._errorOnce)("ImmutableService requires getRowId() callback to be implemented, your row data needs IDs!"),null;const i=this.clientSideRowModel.getNodeManager().getCopyOfNodesMap(),a=[],r=[],n=[];return(0,C._exists)(e)&&e.forEach((e=>{const a=t({data:e,level:0}),o=i[a];if(o){o.data!==e&&r.push(e),i[a]=void 0}else n.push(e)})),(0,C._iterateObject)(i,((e,t)=>{t&&a.push(t.data)})),{remove:a,update:r,add:n}}onRowDataUpdated(){const e=this.gos.get("rowData");e&&(this.isActive()?this.setRowData(e):(this.selectionService.reset("rowDataChanged"),this.clientSideRowModel.setRowData(e)))}},x=i(3423),S=class extends x.BeanStub{constructor(){super(...arguments),this.beanName="sortService"}wireBeans(e){this.columnModel=e.columnModel,this.funcColsService=e.funcColsService,this.rowNodeSorter=e.rowNodeSorter,this.showRowGroupColsService=e.showRowGroupColsService}sort(e,t,i,a,r,n){const o=this.gos.get("groupMaintainOrder"),s=this.columnModel.getCols().some((e=>e.isRowGroupActive()));let l={};i&&a&&(l=this.calculateDirtyNodes(a));const c=this.columnModel.isPivotMode(),d=this.gos.getCallback("postSortRows"),h=a=>{this.pullDownGroupDataForHideOpenParents(a.childrenAfterAggFilter,!0);const h=c&&a.leafGroup;if(o&&s&&!a.leafGroup&&!n){const e=this.funcColsService.getRowGroupColumns()?.[a.level+1],t=null===e?.getSort(),i=a.childrenAfterAggFilter.slice(0);if(a.childrenAfterSort&&!t){const e={};a.childrenAfterSort.forEach(((t,i)=>{e[t.id]=i})),i.sort(((t,i)=>(e[t.id]??0)-(e[i.id]??0)))}a.childrenAfterSort=i}else a.childrenAfterSort=!t||h?a.childrenAfterAggFilter.slice(0):i?this.doDeltaSort(a,l,r,e):this.rowNodeSorter.doFullSort(a.childrenAfterAggFilter,e);if(a.sibling&&(a.sibling.childrenAfterSort=a.childrenAfterSort),this.updateChildIndexes(a),d){const e={nodes:a.childrenAfterSort};d(e)}};r&&r.forEachChangedNodeDepthFirst(h),this.updateGroupDataForHideOpenParents(r)}calculateDirtyNodes(e){const t={},i=e=>{e&&e.forEach((e=>t[e.id]=!0))};return e&&e.forEach((e=>{i(e.add),i(e.update),i(e.remove)})),t}doDeltaSort(e,t,i,a){const r=e.childrenAfterAggFilter,n=e.childrenAfterSort;if(!n)return this.rowNodeSorter.doFullSort(r,a);const o={},s=[];r.forEach((e=>{t[e.id]||!i.canSkip(e)?s.push(e):o[e.id]=!0}));const l=n.filter((e=>o[e.id])),c=(e,t)=>({currentPos:t,rowNode:e}),d=s.map(c).sort(((e,t)=>this.rowNodeSorter.compareRowNodes(a,e,t)));return this.mergeSortedArrays(a,d,l.map(c)).map((({rowNode:e})=>e))}mergeSortedArrays(e,t,i){const a=[];let r=0,n=0;for(;r<t.length&&n<i.length;){this.rowNodeSorter.compareRowNodes(e,t[r],i[n])<0?a.push(t[r++]):a.push(i[n++])}for(;r<t.length;)a.push(t[r++]);for(;n<i.length;)a.push(i[n++]);return a}updateChildIndexes(e){if((0,x._missing)(e.childrenAfterSort))return;const t=e.childrenAfterSort;for(let i=0;i<t.length;i++){const a=t[i],r=0===i,n=i===e.childrenAfterSort.length-1;a.setFirstChild(r),a.setLastChild(n),a.setChildIndex(i)}}updateGroupDataForHideOpenParents(e){if(!this.gos.get("groupHideOpenParents"))return;if(this.gos.get("treeData"))return(0,x._warnOnce)("The property hideOpenParents dose not work with Tree Data. This is because Tree Data has values at the group level, it doesn't make sense to hide them."),!1;const t=e=>{this.pullDownGroupDataForHideOpenParents(e.childrenAfterSort,!1),e.childrenAfterSort.forEach((e=>{e.hasChildren()&&t(e)}))};e&&e.executeFromRootNode((e=>t(e)))}pullDownGroupDataForHideOpenParents(e,t){this.gos.get("groupHideOpenParents")&&!(0,x._missing)(e)&&e.forEach((e=>{(this.showRowGroupColsService?.getShowRowGroupCols()??[]).forEach((i=>{const a=i.getColDef().showRowGroup;if("string"!=typeof a)return void(0,x._errorOnce)("groupHideOpenParents only works when specifying specific columns for colDef.showRowGroup");const r=a,n=this.columnModel.getColDefCol(r);if(!(n===e.rowGroupColumn))if(t)e.setGroupValue(i.getId(),void 0);else{const t=this.getFirstChildOfFirstChild(e,n);t&&e.setGroupValue(i.getId(),t.key)}}))}))}getFirstChildOfFirstChild(e,t){let i=e;for(;i;){const e=i.parent;if(!e||!i.firstChild)return null;if(e.rowGroupColumn===t)return e;i=e}return null}},M=i(3423),k=class extends M.BeanStub{constructor(){super(...arguments),this.beanName="sortStage"}wireBeans(e){this.sortService=e.sortService,this.sortController=e.sortController}execute(e){const t=this.sortController.getSortOptions(),i=(0,M._exists)(t)&&t.length>0,a=i&&(0,M._exists)(e.rowNodeTransactions)&&this.gos.get("deltaSort"),r=t.some((e=>(0,M._isColumnsSortingCoupledToGroup)(this.gos)?e.column.isPrimary()&&e.column.isRowGroupActive():!!e.column.getColDef().showRowGroup));this.sortService.sort(t,i,a,e.rowNodeTransactions,e.changedPath,r)}},D="32.2.1",E=(0,c._defineModule)({version:D,moduleName:`${d.ModuleNames.ClientSideRowModelModule}-core`,rowModel:"clientSide",beans:[p,v,k,b,S,w]}),A=(0,c._defineModule)({version:D,moduleName:`${d.ModuleNames.ClientSideRowModelModule}-api`,beans:[d.RowModelHelperService],apiFunctions:{onGroupExpandedOrCollapsed:function(e){e.expansionService.onGroupExpandedOrCollapsed()},refreshClientSideRowModel:function(e,t){e.rowModelHelperService?.getClientSideRowModel()?.refreshModel(t)},isRowDataEmpty:function(e){return e.rowModelHelperService?.getClientSideRowModel()?.isEmpty()??!0},forEachLeafNode:function(e,t){e.rowModelHelperService?.getClientSideRowModel()?.forEachLeafNode(t)},forEachNodeAfterFilter:function(e,t){e.rowModelHelperService?.getClientSideRowModel()?.forEachNodeAfterFilter(t)},forEachNodeAfterFilterAndSort:function(e,t){e.rowModelHelperService?.getClientSideRowModel()?.forEachNodeAfterFilterAndSort(t)},resetRowHeights:function(e){e.columnModel.isAutoRowHeightActive()?(0,m._warnOnce)("calling gridApi.resetRowHeights() makes no sense when using Auto Row Height."):e.rowModelHelperService?.getClientSideRowModel()?.resetRowHeights()},applyTransaction:function(e,t){return e.frameworkOverrides.wrapIncoming((()=>e.rowModelHelperService?.getClientSideRowModel()?.updateRowData(t)))},applyTransactionAsync:function(e,t,i){e.frameworkOverrides.wrapIncoming((()=>e.rowModelHelperService?.getClientSideRowModel()?.batchUpdateRowData(t,i)))},flushAsyncTransactions:function(e){e.frameworkOverrides.wrapIncoming((()=>e.rowModelHelperService?.getClientSideRowModel()?.flushAsyncTransactions()))},getBestCostNodeSelection:function(e){return e.selectionService.getBestCostNodeSelection()}},dependantModules:[E,d._CsrmSsrmSharedApiModule]}),I=(0,c._defineModule)({version:D,moduleName:d.ModuleNames.ClientSideRowModelModule,dependantModules:[E,A]})},3423:function(e,t,i){var a,r=Object.defineProperty,n=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,s=Object.prototype.hasOwnProperty,l={};((e,t)=>{for(var i in t)r(e,i,{get:t[i],enumerable:!0})})(l,{ALWAYS_SYNC_GLOBAL_EVENTS:()=>Fd,AbstractHeaderCellCtrl:()=>co,AgAbstractField:()=>tr,AgAbstractInputField:()=>ir,AgAbstractLabel:()=>er,AgCheckbox:()=>ar,AgCheckboxSelector:()=>rr,AgColumn:()=>vt,AgColumnGroup:()=>Ht,AgInputDateField:()=>zl,AgInputNumberField:()=>Tn,AgInputNumberFieldSelector:()=>Pn,AgInputTextArea:()=>Dl,AgInputTextField:()=>In,AgInputTextFieldSelector:()=>Rn,AgPickerField:()=>wn,AgPromise:()=>fr,AgProvidedColumnGroup:()=>Ye,AgRadioButton:()=>bn,AgSelect:()=>xn,AgSelectSelector:()=>Sn,AgToggleButton:()=>uc,AgToggleButtonSelector:()=>gc,AnimateShowChangeCellRenderer:()=>Qa,AnimateSlideCellRenderer:()=>Xa,AnimationFrameService:()=>xl,AriaAnnouncementService:()=>_d,AutoScrollService:()=>Zr,AutoWidthCalculator:()=>ec,BarColumnLabelPlacement:()=>wh,BaseComponentWrapper:()=>bh,BeanStub:()=>qe,BodyDropPivotTarget:()=>Wo,BodyDropTarget:()=>$o,CellComp:()=>ol,CellCtrl:()=>Ns,CellNavigationService:()=>xc,CellPositionUtils:()=>jc,CellRangeType:()=>Rs,ChangedPath:()=>Xd,ChartMappings:()=>Ch,CheckboxCellEditor:()=>jl,CheckboxCellRenderer:()=>nr,CheckboxSelectionComponent:()=>Ss,ClientSideRowModelSteps:()=>Sl,ColumnApplyStateService:()=>At,ColumnAutosizeService:()=>Dt,ColumnFactory:()=>Ct,ColumnKeyCreator:()=>bt,ColumnModel:()=>xt,ColumnMoveService:()=>Rt,ColumnNameService:()=>zt,ColumnSizeService:()=>Gt,CommunityFeaturesModule:()=>Pd,Component:()=>Oa,ComponentUtil:()=>Xt,Context:()=>Wr,CssClassManager:()=>gi,CtrlsService:()=>Hc,DataTypeService:()=>rd,DateCellEditor:()=>Bl,DateFilter:()=>to,DateStringCellEditor:()=>Hl,DragAndDropService:()=>Yr,DragService:()=>Xr,DragSourceType:()=>Kr,Environment:()=>Yc,EventService:()=>Qc,ExcelFactoryMode:()=>Ur,ExpansionService:()=>Ml,ExpressionService:()=>nh,FakeHScrollComp:()=>ps,FakeVScrollComp:()=>vs,FilterManager:()=>sn,FilterWrapperComp:()=>ln,FocusService:()=>Jc,FuncColsService:()=>Et,GROUP_AUTO_COLUMN_ID:()=>Qe,Grid:()=>gh,GridBodyComp:()=>ul,GridBodyCtrl:()=>nl,GridComp:()=>id,GridCoreCreator:()=>mh,GridCoreModule:()=>Rd,GridCtrl:()=>td,GridHeaderComp:()=>ss,GridHeaderCtrl:()=>Ho,GridOptionsService:()=>Bd,GroupInstanceIdCreator:()=>jt,HeaderCellCtrl:()=>Jo,HeaderFilterCellComp:()=>Fo,HeaderFilterCellCtrl:()=>uo,HeaderGroupCellCtrl:()=>is,HeaderNavigationDirection:()=>Bo,HeaderNavigationService:()=>Vo,HeaderPositionUtils:()=>Vd,HeaderRowComp:()=>Go,HeaderRowContainerComp:()=>os,HeaderRowContainerCtrl:()=>ns,HeaderRowCtrl:()=>rs,HeaderRowType:()=>Oo,HorizontalDirection:()=>qr,HorizontalResizeService:()=>bl,KeyCode:()=>Ja,LargeTextCellEditor:()=>Al,LayoutCssClasses:()=>cs,LocalEventService:()=>c,LocaleService:()=>Hd,ManagedFocusFeature:()=>pn,MenuService:()=>kl,ModuleNames:()=>d,ModuleRegistry:()=>Hr,MouseEventService:()=>vl,MoveColumnFeature:()=>Zo,NavigationService:()=>yl,NumberCellEditor:()=>Nl,NumberFilter:()=>On,NumberSequence:()=>Ta,OverlayWrapperComponent:()=>hs,PinnedRowModel:()=>rc,PivotResultColsService:()=>Ot,PopupComponent:()=>hr,PopupEditorWrapper:()=>Il,PopupService:()=>bc,PositionableFeature:()=>un,PropertyKeys:()=>$t,ProvidedFilter:()=>yn,RefPlaceholder:()=>za,ResizeObserverService:()=>wl,RowContainerComp:()=>ll,RowContainerCtrl:()=>al,RowCtrl:()=>Gs,RowDragComp:()=>Jr,RowHighlightPosition:()=>$r,RowModelHelperService:()=>fh,RowNode:()=>on,RowNodeBlock:()=>sc,RowNodeBlockLoader:()=>lc,RowNodeSorter:()=>Qd,RowPositionUtils:()=>Uc,RowRenderer:()=>ic,ScalarFilter:()=>Dn,ScrollVisibleService:()=>pl,SelectCellEditor:()=>Rl,SelectableService:()=>eh,SelectionHandleType:()=>Is,ServerSideTransactionResultStatus:()=>oc,SetLeftFeature:()=>io,SimpleFilter:()=>kn,SortController:()=>ih,SortIndicatorComp:()=>Ka,SortIndicatorSelector:()=>Ya,StandardMenuFactory:()=>Cl,StylingService:()=>hc,TabGuardClassNames:()=>pc,TabGuardComp:()=>vc,TabGuardCtrl:()=>mc,TabGuardFeature:()=>fc,TextCellEditor:()=>Ll,TextFilter:()=>Hn,TextFloatingFilter:()=>xo,TooltipFeature:()=>Fa,TooltipStateManager:()=>La,TouchListener:()=>Ua,UserComponentFactory:()=>Gr,UserComponentRegistry:()=>mr,ValueCache:()=>oh,ValueService:()=>sh,VanillaFrameworkOverrides:()=>wc,VerticalDirection:()=>_r,VisibleColsService:()=>Wt,_ColumnFilterModule:()=>ko,_CommunityMenuApiModule:()=>dd,_CsrmSsrmSharedApiModule:()=>vh,_EditCoreModule:()=>Yl,_EmptyBean:()=>ti,_FilterCoreModule:()=>So,_FloatingFilterModule:()=>Ao,_ReadOnlyFloatingFilterModule:()=>Io,_RowNodeBlockModule:()=>cc,_SsrmInfiniteSharedApiModule:()=>yh,_addFocusableContainerListener:()=>md,_areEqual:()=>De,_bindCellRendererToHtmlElement:()=>Ra,_capitalise:()=>Ft,_clearElement:()=>ma,_cloneObject:()=>st,_combineAttributesAndGridOptions:()=>Jt,_compose:()=>M,_createIcon:()=>Va,_createIconNoSpan:()=>Ha,_debounce:()=>w,_defaultComparator:()=>F,_defineModule:()=>go,_doOnce:()=>u,_errorOnce:()=>m,_escapeString:()=>Nt,_exists:()=>D,_existsAndNotEmpty:()=>Me,_flatten:()=>Ne,_forEachReverse:()=>Oe,_formatNumberCommas:()=>qn,_formatNumberTwoDecimalPlacesAndCommas:()=>_n,_fuzzySuggestions:()=>gr,_getAbsoluteHeight:()=>ca,_getAbsoluteWidth:()=>da,_getActiveDomElement:()=>Q,_getAllValuesInObject:()=>ct,_getAriaPosInSet:()=>bi,_getCtrlForEventTarget:()=>Ue,_getDocument:()=>Y,_getFillHandle:()=>me,_getGlobalGridOption:()=>hh,_getGrandTotalRow:()=>ae,_getGroupAggFiltering:()=>ie,_getGroupSelection:()=>we,_getGroupSelectsDescendants:()=>xe,_getGroupTotalRowCallback:()=>re,_getHeaderCheckbox:()=>ce,_getHeaderClassesFromColDef:()=>ao,_getInnerHeight:()=>sa,_getInnerWidth:()=>la,_getIsRowSelectable:()=>ye,_getRowContainerOptions:()=>Ys,_getRowHeightAsNumber:()=>U,_getRowHeightForNode:()=>W,_getRowIdCallback:()=>se,_getRowSelectionMode:()=>be,_getSuppressMultiRanges:()=>ue,_getToolPanelClassesFromColDef:()=>ro,_includes:()=>Fe,_insertArrayIntoArray:()=>Pe,_insertIntoArray:()=>Te,_isAnimateRows:()=>J,_isCellSelectionEnabled:()=>ge,_isClientSideRowModel:()=>O,_isColumnsSortingCoupledToGroup:()=>te,_isDomLayout:()=>B,_isElementInEventPath:()=>_e,_isEventFromPrintableCharacter:()=>En,_isGetRowHeightFunction:()=>j,_isGroupMultiAutoColumn:()=>ne,_isGroupUseEntireRow:()=>oe,_isIOSUserAgent:()=>Yi,_isMultiRowSelection:()=>Ce,_isNodeOrElement:()=>Ea,_isNothingFocused:()=>X,_isRowSelection:()=>V,_isServerSideRowModel:()=>G,_isStopPropagationForAgGrid:()=>je,_isUsingNewCellSelectionAPI:()=>he,_isUsingNewRowSelectionAPI:()=>de,_isVisible:()=>ya,_iterateObject:()=>ot,_jsonEquals:()=>L,_last:()=>ke,_loadTemplate:()=>ba,_log:()=>g,_makeNull:()=>k,_mergeDeep:()=>dt,_missing:()=>E,_missingOrEmpty:()=>A,_parseDateTimeFromString:()=>$n,_processOnChange:()=>ei,_radioCssClass:()=>Ji,_removeAriaExpanded:()=>Ii,_removeAriaSort:()=>Gi,_removeFromArray:()=>Re,_removeFromParent:()=>fa,_removeRepeatsFromArray:()=>Ae,_serialiseDate:()=>Kn,_setAriaActiveDescendant:()=>Ei,_setAriaChecked:()=>Vi,_setAriaColCount:()=>Fi,_setAriaColIndex:()=>Ni,_setAriaColSpan:()=>zi,_setAriaControls:()=>Hi,_setAriaDescribedBy:()=>xi,_setAriaDisabled:()=>ki,_setAriaExpanded:()=>Ai,_setAriaHidden:()=>Di,_setAriaLabel:()=>Ci,_setAriaLabelledBy:()=>wi,_setAriaLevel:()=>Mi,_setAriaPosInSet:()=>Ti,_setAriaRole:()=>yi,_setAriaRowCount:()=>Pi,_setAriaRowIndex:()=>Li,_setAriaSelected:()=>Bi,_setAriaSetSize:()=>Ri,_setAriaSort:()=>Oi,_setDisabled:()=>ra,_setDisplayed:()=>ia,_setFixedWidth:()=>Ma,_setVisible:()=>aa,_shallowCompare:()=>Ee,_stopPropagationForAgGrid:()=>He,_toStringOrNull:()=>I,_unwrapUserComp:()=>Br,_utf8_encode:()=>Lt,_values:()=>N,_waitUntil:()=>S,_warnOnce:()=>p,createGrid:()=>uh,getDefaultFloatingFilterType:()=>mo,isColumn:()=>ft,isColumnControlsCol:()=>it,isColumnGroup:()=>Vt,isColumnGroupAutoCol:()=>tt,isProvidedColumnGroup:()=>Ke,isSelectionUIEvent:()=>Nd,provideGlobalGridOptions:()=>dh}),e.exports=(a=l,((e,t,i,a)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let l of o(t))s.call(e,l)||l===i||r(e,l,{get:()=>t[l],enumerable:!(a=n(t,l))||a.enumerable});return e})(r({},"__esModule",{value:!0}),a));var c=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,i){const a=t?this.allAsyncListeners:this.allSyncListeners;let r=a.get(e);return!r&&i&&(r=new Set,a.set(e,r)),r}noRegisteredListenersExist(){return 0===this.allSyncListeners.size&&0===this.allAsyncListeners.size&&0===this.globalSyncListeners.size&&0===this.globalAsyncListeners.size}addEventListener(e,t,i=!1){this.getListeners(e,i,!0).add(t)}removeEventListener(e,t,i=!1){const a=this.getListeners(e,i,!1);if(a&&(a.delete(t),0===a.size)){(i?this.allAsyncListeners:this.allSyncListeners).delete(e)}}addGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).add(e)}removeGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).delete(e)}dispatchEvent(e){const t=e;this.dispatchToListeners(t,!0),this.dispatchToListeners(t,!1),this.firedEvents[t.type]=!0}dispatchEventOnce(e){this.firedEvents[e.type]||this.dispatchEvent(e)}dispatchToListeners(e,t){const i=e.type;if(t&&"event"in e){const t=e.event;t instanceof Event&&(e.eventPath=t.composedPath())}const a=(i,a)=>i.forEach((i=>{if(!a.has(i))return;const r=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming((()=>i(e))):()=>i(e);t?this.dispatchAsync(r):r()})),r=this.getListeners(i,t,!1)??new Set,n=new Set(r);n.size>0&&a(n,r);new Set(t?this.globalAsyncListeners:this.globalSyncListeners).forEach((a=>{const r=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming((()=>a(i,e))):()=>a(i,e);t?this.dispatchAsync(r):r()}))}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()))}},d=(e=>(e.CommunityCoreModule="@ag-grid-community/core",e.InfiniteRowModelModule="@ag-grid-community/infinite-row-model",e.ClientSideRowModelModule="@ag-grid-community/client-side-row-model",e.CsvExportModule="@ag-grid-community/csv-export",e.EnterpriseCoreModule="@ag-grid-enterprise/core",e.RowGroupingModule="@ag-grid-enterprise/row-grouping",e.ColumnsToolPanelModule="@ag-grid-enterprise/column-tool-panel",e.FiltersToolPanelModule="@ag-grid-enterprise/filter-tool-panel",e.MenuModule="@ag-grid-enterprise/menu",e.SetFilterModule="@ag-grid-enterprise/set-filter",e.MultiFilterModule="@ag-grid-enterprise/multi-filter",e.StatusBarModule="@ag-grid-enterprise/status-bar",e.SideBarModule="@ag-grid-enterprise/side-bar",e.RangeSelectionModule="@ag-grid-enterprise/range-selection",e.MasterDetailModule="@ag-grid-enterprise/master-detail",e.RichSelectModule="@ag-grid-enterprise/rich-select",e.GridChartsModule="@ag-grid-enterprise/charts",e.ViewportRowModelModule="@ag-grid-enterprise/viewport-row-model",e.ServerSideRowModelModule="@ag-grid-enterprise/server-side-row-model",e.ExcelExportModule="@ag-grid-enterprise/excel-export",e.ClipboardModule="@ag-grid-enterprise/clipboard",e.SparklinesModule="@ag-grid-enterprise/sparklines",e.AdvancedFilterModule="@ag-grid-enterprise/advanced-filter",e.AngularModule="@ag-grid-community/angular",e.ReactModule="@ag-grid-community/react",e.VueModule="@ag-grid-community/vue",e))(d||{}),h={};function u(e,t){h[t]||(e(),h[t]=!0)}function g(e,...t){console.log("AG Grid: "+e,...t)}function p(e,...t){u((()=>console.warn("AG Grid: "+e,...t)),e+t?.join(""))}function m(e,...t){u((()=>console.error("AG Grid: "+e,...t)),e+t?.join(""))}function f(e){return!!(e&&e.constructor&&e.call&&e.apply)}function v(e){!function(e,t=0){e.length>0&&window.setTimeout((()=>e.forEach((e=>e()))),t)}(e,400)}var y=[],b=!1;function C(e){y.push(e),b||(b=!0,window.setTimeout((()=>{const e=y.slice();y.length=0,b=!1,e.forEach((e=>e()))}),0))}function w(e,t){let i;return function(...a){const r=this;window.clearTimeout(i),i=window.setTimeout((function(){e.apply(r,a)}),t)}}function x(e,t){let i=0;return function(...a){const r=(new Date).getTime();r-i<t||(i=r,e.apply(this,a))}}function S(e,t,i=100,a){const r=(new Date).getTime();let n=null,o=!1;const s=()=>{const s=(new Date).getTime()-r>i;(e()||s)&&(t(),o=!0,null!=n&&(window.clearInterval(n),n=null),s&&a&&p(a))};s(),o||(n=window.setInterval(s,10))}function M(...e){return t=>e.reduce(((e,t)=>t(e)),t)}function k(e){return null==e||""===e?null:e}function D(e,t=!1){return null!=e&&(""!==e||t)}function E(e){return!D(e)}function A(e){return null==e||0===e.length}function I(e){return null!=e&&"function"==typeof e.toString?e.toString():null}function R(e){if(void 0===e)return;if(null===e||""===e)return null;if("number"==typeof e)return isNaN(e)?void 0:e;const t=parseInt(e,10);return isNaN(t)?void 0:t}function T(e){if(void 0!==e)return null!==e&&""!==e&&P(e)}function P(e){return"boolean"==typeof e?e:"string"==typeof e&&("TRUE"===e.toUpperCase()||""==e)}function L(e,t){return(e?JSON.stringify(e):null)===(t?JSON.stringify(t):null)}function F(e,t,i=!1){const a=null==e,r=null==t;if(e&&e.toNumber&&(e=e.toNumber()),t&&t.toNumber&&(t=t.toNumber()),a&&r)return 0;if(a)return-1;if(r)return 1;function n(e,t){return e>t?1:e<t?-1:0}if("string"!=typeof e)return n(e,t);if(!i)return n(e,t);try{return e.localeCompare(t)}catch(i){return n(e,t)}}function N(e){if(e instanceof Set||e instanceof Map){const t=[];return e.forEach((e=>t.push(e))),t}return Object.values(e)}function z(e,t){return e.get("rowModelType")===t}function O(e){return z(e,"clientSide")}function G(e){return z(e,"serverSide")}function B(e,t){return e.get("domLayout")===t}function V(e){return void 0!==be(e)}function H(e){return!e.get("suppressAsyncEvents")}function j(e){return"function"==typeof e.get("getRowHeight")}function W(e,t,i=!1,a){if(null==a&&(a=e.environment.getDefaultRowHeight()),j(e)){if(i)return{height:a,estimated:!0};const r={node:t,data:t.data},n=e.getCallback("getRowHeight")(r);if(_(n))return 0===n&&p("The return of `getRowHeight` cannot be zero. If the intention is to hide rows, use a filter instead."),{height:Math.max(1,n),estimated:!1}}if(t.detail&&e.get("masterDetail"))return function(e){if(e.get("detailRowAutoHeight"))return{height:1,estimated:!1};const t=e.get("detailRowHeight");if(_(t))return{height:t,estimated:!1};return{height:300,estimated:!1}}(e);const r=e.get("rowHeight");return{height:r&&_(r)?r:a,estimated:!1}}function U(e){const{environment:t}=e,i=e.get("rowHeight");if(!i||E(i))return t.getDefaultRowHeight();const a=t.refreshRowHeightVariable();return-1!==a?a:(p("row height must be a number if not using standard row model"),t.getDefaultRowHeight())}function _(e){return!isNaN(e)&&"number"==typeof e&&isFinite(e)}function q(e,t,i){const a=t[e.getDomDataKey()];return a?a[i]:void 0}function K(e,t,i,a){const r=e.getDomDataKey();let n=t[r];E(n)&&(n={},t[r]=n),n[i]=a}function Y(e){let t=null;const i=e.get("getDocument");return i&&D(i)?t=i():e.eGridDiv&&(t=e.eGridDiv.ownerDocument),t&&D(t)?t:document}function Z(e){return Y(e).defaultView||window}function $(e){return e.eGridDiv.getRootNode()}function Q(e){return $(e).activeElement}function X(e){const t=Y(e),i=Q(e);return null===i||i===t.body}function J(e){return!e.get("ensureDomOrder")&&e.get("animateRows")}function ee(e){return!(e.get("paginateChildRows")||e.get("groupHideOpenParents")||B(e,"print"))}function te(e){const t=e.get("autoGroupColumnDef");return!t?.comparator&&!e.get("treeData")}function ie(e){const t=e.get("groupAggFiltering");return"function"==typeof t?e.getCallback("groupAggFiltering"):!0===t?()=>!0:void 0}function ae(e){const t=e.get("grandTotalRow");if(t)return t;return e.get("groupIncludeTotalFooter")?"bottom":void 0}function re(e){const t=e.get("groupTotalRow");if("function"==typeof t)return e.getCallback("groupTotalRow");if(t)return()=>t;const i=e.get("groupIncludeFooter");if("function"==typeof i){const t=e.getCallback("groupIncludeFooter");return e=>t(e)?