ag-grid-enterprise
Version:
Advanced Data Grid / Data Table supporting Javascript / Typescript / React / Angular / Vue
1 lines • 2.47 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={886:function(e,t,i){var s,r=Object.defineProperty,o=Object.getOwnPropertyDescriptor,n=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l=(e,t,i,s)=>{for(var n,a=s>1?void 0:s?o(t,i):t,l=e.length-1;l>=0;l--)(n=e[l])&&(a=(s?n(t,i,a):n(a))||a);return s&&a&&r(t,i,a),a},d={};((e,t)=>{for(var i in t)r(e,i,{get:t[i],enumerable:!0})})(d,{ClientSideRowModelModule:()=>R}),e.exports=(s=d,((e,t,i,s)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let l of n(t))a.call(e,l)||l===i||r(e,l,{get:()=>t[l],enumerable:!(s=o(t,l))||s.enumerable});return e})(r({},"__esModule",{value:!0}),s));var h=i(423),c=i(423),u=i(423),p=class e{constructor(t,i,s,r,o,n){this.nextId=0,this.rowCountReady=!1,this.allNodesMap={},this.rootNode=t,this.gridOptionsService=i,this.eventService=s,this.columnModel=r,this.beans=n,this.selectionService=o,this.rootNode.group=!0,this.rootNode.level=-1,this.rootNode.id=e.ROOT_NODE_ID,this.rootNode.allLeafChildren=[],this.rootNode.childrenAfterGroup=[],this.rootNode.childrenAfterSort=[],this.rootNode.childrenAfterAggFilter=[],this.rootNode.childrenAfterFilter=[]}getCopyOfNodesMap(){return u._.cloneObject(this.allNodesMap)}getRowNode(e){return this.allNodesMap[e]}setRowData(t){if("string"==typeof t)return void console.warn("AG Grid: rowData must be an array, however you passed in a string. If you are loading JSON, make sure you convert the JSON string to JavaScript objects first");this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(t);const i=this.rootNode,s=this.rootNode.sibling;i.childrenAfterFilter=null,i.childrenAfterGroup=null,i.childrenAfterAggFilter=null,i.childrenAfterSort=null,i.childrenMapped=null,i.updateHasChildren(),this.nextId=0,this.allNodesMap={},t?i.allLeafChildren=t.map((t=>this.createNode(t,this.rootNode,e.TOP_LEVEL))):(i.allLeafChildren=[],i.childrenAfterGroup=[]),s&&(s.childrenAfterFilter=i.childrenAfterFilter,s.childrenAfterGroup=i.childrenAfterGroup,s.childrenAfterAggFilter=i.childrenAfterAggFilter,s.childrenAfterSort=i.childrenAfterSort,s.childrenMapped=i.childrenMapped,s.allLeafChildren=i.allLeafChildren)}updateRowData(e,t){this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(e.add);const i={remove:[],update:[],add:[]},s=[];return this.executeRemove(e,i,s),this.executeUpdate(e,i,s),this.executeAdd(e,i),this.updateSelection(s,"rowDataChanged"),t&&u._.sortRowNodesByOrder(this.rootNode.allLeafChildren,t),i}isRowCountReady(){return this.rowCountReady}dispatchRowDataUpdateStartedEvent(e){const t={type:u.Events.EVENT_ROW_DATA_UPDATE_STARTED,firstRowData:(null==e?void 0:e.length)?e[0]:null};this.eventService.dispatchEvent(t)}updateSelection(e,t){const i=e.length>0;if(i&&this.selectionService.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t}),this.selectionService.updateGroupsFromChildrenSelections(t),i){const e={type:u.Events.EVENT_SELECTION_CHANGED,source:t};this.eventService.dispatchEvent(e)}}executeAdd(t,i){var s;const{add:r,addIndex:o}=t;if(u._.missingOrEmpty(r))return;const n=r.map((t=>this.createNode(t,this.rootNode,e.TOP_LEVEL)));if("number"==typeof o&&o>=0){const{allLeafChildren:e}=this.rootNode,t=e.length;let i=o;if(this.gridOptionsService.get("treeData")&&o>0&&t>0)for(let r=0;r<t;r++)if((null==(s=e[r])?void 0:s.rowIndex)==o-1){i=r+1;break}const r=e.slice(0,i),a=e.slice(i,e.length);this.rootNode.allLeafChildren=[...r,...n,...a]}else this.rootNode.allLeafChildren=[...this.rootNode.allLeafChildren,...n];this.rootNode.sibling&&(this.rootNode.sibling.allLeafChildren=this.rootNode.allLeafChildren),i.add=n}executeRemove(e,t,i){const{remove:s}=e;if(u._.missingOrEmpty(s))return;const r={};s.forEach((e=>{const s=this.lookupRowNode(e);s&&(s.isSelected()&&i.push(s),s.clearRowTopAndRowIndex(),r[s.id]=!0,delete this.allNodesMap[s.id],t.remove.push(s))})),this.rootNode.allLeafChildren=this.rootNode.allLeafChildren.filter((e=>!r[e.id])),this.rootNode.sibling&&(this.rootNode.sibling.allLeafChildren=this.rootNode.allLeafChildren)}executeUpdate(t,i,s){const{update:r}=t;u._.missingOrEmpty(r)||r.forEach((t=>{const r=this.lookupRowNode(t);r&&(r.updateData(t),!r.selectable&&r.isSelected()&&s.push(r),this.setMasterForRow(r,t,e.TOP_LEVEL,!1),i.update.push(r))}))}lookupRowNode(e){const t=this.gridOptionsService.getCallback("getRowId");let i;if(t){const s=t({data:e,level:0});if(i=this.allNodesMap[s],!i)return console.error(`AG Grid: could not find row id=${s}, data item was not found for this id`),null}else if(i=this.rootNode.allLeafChildren.find((t=>t.data===e)),!i)return console.error("AG Grid: could not find data item as object was not found",e),console.error("Consider using getRowId to help the Grid find matching row data"),null;return i||null}createNode(e,t,i){const s=new u.RowNode(this.beans);s.group=!1,this.setMasterForRow(s,e,i,!0);const r=this.gridOptionsService.get("suppressParentsInRowNodes");return t&&!r&&(s.parent=t),s.level=i,s.setDataAndId(e,this.nextId.toString()),this.allNodesMap[s.id]&&console.warn(`AG Grid: duplicate node id '${s.id}' detected from getRowId callback, this could cause issues in your grid.`),this.allNodesMap[s.id]=s,this.nextId++,s}setMasterForRow(e,t,i,s){if(this.gridOptionsService.get("treeData"))e.setMaster(!1),s&&(e.expanded=!1);else{if(this.gridOptionsService.get("masterDetail")){const i=this.gridOptionsService.get("isRowMaster");i?e.setMaster(i(t)):e.setMaster(!0)}else e.setMaster(!1);if(s){const t=this.columnModel.getRowGroupColumns(),s=i+(t?t.length:0);e.expanded=!!e.master&&this.isExpanded(s)}}}isExpanded(e){const t=this.gridOptionsService.get("groupDefaultExpanded");return-1===t||e<t}};p.TOP_LEVEL=0,p.ROOT_NODE_ID="ROOT_NODE_ID";var g=p,m=class extends c.BeanStub{constructor(){super(...arguments),this.onRowHeightChanged_debounced=c._.debounce(this.onRowHeightChanged.bind(this),100),this.rowsToDisplay=[],this.hasStarted=!1,this.shouldSkipSettingDataOnStart=!1,this.isRefreshingModel=!1,this.rowCountReady=!1}init(){const e=this.refreshModel.bind(this,{step:c.ClientSideRowModelSteps.EVERYTHING}),t=!this.gridOptionsService.get("suppressAnimationFrame"),i=this.refreshModel.bind(this,{step:c.ClientSideRowModelSteps.EVERYTHING,afterColumnsChanged:!0,keepRenderedRows:!0,animate:t});this.addManagedListener(this.eventService,c.Events.EVENT_NEW_COLUMNS_LOADED,i),this.addManagedListener(this.eventService,c.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,e),this.addManagedListener(this.eventService,c.Events.EVENT_COLUMN_VALUE_CHANGED,this.onValueChanged.bind(this)),this.addManagedListener(this.eventService,c.Events.EVENT_COLUMN_PIVOT_CHANGED,this.refreshModel.bind(this,{step:c.ClientSideRowModelSteps.PIVOT})),this.addManagedListener(this.eventService,c.Events.EVENT_FILTER_CHANGED,this.onFilterChanged.bind(this)),this.addManagedListener(this.eventService,c.Events.EVENT_SORT_CHANGED,this.onSortChanged.bind(this)),this.addManagedListener(this.eventService,c.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,e),this.addManagedListener(this.eventService,c.Events.EVENT_GRID_STYLES_CHANGED,this.onGridStylesChanges.bind(this)),this.addManagedListener(this.eventService,c.Events.EVENT_GRID_READY,(()=>this.onGridReady())),this.addPropertyListeners(),this.rootNode=new c.RowNode(this.beans),this.nodeManager=new g(this.rootNode,this.gridOptionsService,this.eventService,this.columnModel,this.selectionService,this.beans)}addPropertyListeners(){const e=new Set(["treeData","masterDetail"]),t=new Set(["suppressParentsInRowNodes","groupDefaultExpanded","groupAllowUnbalanced","initialGroupOrderComparator","groupHideOpenParents","groupDisplayType"]),i=new Set(["excludeChildrenWhenTreeDataFiltering"]),s=new Set(["removePivotHeaderRowWhenSingleValueColumn","pivotRowTotals","pivotColumnGroupTotals","suppressExpandablePivotGroups"]),r=new Set(["getGroupRowAgg","alwaysAggregateAtRootLevel","groupIncludeTotalFooter","suppressAggFilteredOnly"]),o=new Set(["postSortRows","groupDisplayType","accentedSort"]),n=new Set([]),a=new Set(["groupRemoveSingleChildren","groupRemoveLowestSingleChildren","groupIncludeFooter"]),l=[...e,...t,...i,...s,...s,...r,...o,...n,...a];this.addManagedPropertyListeners(l,(l=>{var d;const h=null==(d=l.changeSet)?void 0:d.properties;if(!h)return;const u=e=>h.some((t=>e.has(t)));u(e)?this.setRowData(this.rootNode.allLeafChildren.map((e=>e.data))):u(t)?this.refreshModel({step:c.ClientSideRowModelSteps.EVERYTHING}):u(i)?this.refreshModel({step:c.ClientSideRowModelSteps.FILTER}):u(s)?this.refreshModel({step:c.ClientSideRowModelSteps.PIVOT}):u(r)?this.refreshModel({step:c.ClientSideRowModelSteps.AGGREGATE}):u(o)?this.refreshModel({step:c.ClientSideRowModelSteps.SORT}):u(n)?this.refreshModel({step:c.ClientSideRowModelSteps.FILTER_AGGREGATES}):u(a)&&this.refreshModel({step:c.ClientSideRowModelSteps.MAP})})),this.addManagedPropertyListener("rowHeight",(()=>this.resetRowHeights()))}start(){this.hasStarted=!0,this.shouldSkipSettingDataOnStart?this.dispatchUpdateEventsAndRefresh():this.setInitialData()}setInitialData(){const e=this.gridOptionsService.get("rowData");e&&(this.shouldSkipSettingDataOnStart=!0,this.setRowData(e))}ensureRowHeightsValid(e,t,i,s){let r,o=!1;do{r=!1;const n=this.getRowIndexAtPixel(e),a=this.getRowIndexAtPixel(t),l=Math.max(n,i),d=Math.min(a,s);for(let e=l;e<=d;e++){const t=this.getRow(e);if(t.rowHeightEstimated){const e=this.gridOptionsService.getRowHeightForNode(t);t.setRowHeight(e.height),r=!0,o=!0}}r&&this.setRowTopAndRowIndex()}while(r);return o}setRowTopAndRowIndex(){const e=this.environment.getDefaultRowHeight();let t=0;const i=new Set,s=this.gridOptionsService.isDomLayout("normal");for(let r=0;r<this.rowsToDisplay.length;r++){const o=this.rowsToDisplay[r];if(null!=o.id&&i.add(o.id),null==o.rowHeight){const t=this.gridOptionsService.getRowHeightForNode(o,s,e);o.setRowHeight(t.height,t.estimated)}o.setRowTop(t),o.setRowIndex(r),t+=o.rowHeight}return i}clearRowTopAndRowIndex(e,t){const i=e.isActive(),s=e=>{e&&null!=e.id&&!t.has(e.id)&&e.clearRowTopAndRowIndex()},r=e=>{if(s(e),s(e.detailNode),s(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 s=this.getRowIndexAtPixel(t),r=this.getRow(s),o=!this.gridOptionsService.get("suppressAnimationFrame");return r!==e[0]&&(e.forEach((e=>{c._.removeFromArray(this.rootNode.allLeafChildren,e)})),e.forEach(((e,t)=>{c._.insertIntoArray(this.rootNode.allLeafChildren,e,Math.max(s+i,0)+t)})),this.refreshModel({step:c.ClientSideRowModelSteps.EVERYTHING,keepRenderedRows:!0,keepEditingRows:!0,animate:o}),!0)}highlightRowAtPixel(e,t){const i=null!=t?this.getRowIndexAtPixel(t):null,s=null!=i?this.getRow(i):null;if(!s||!e||s===e||null==t)return void(this.lastHighlightedRow&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null));const r=this.getHighlightPosition(t,s);this.lastHighlightedRow&&this.lastHighlightedRow!==s&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null),s.setHighlighted(r),this.lastHighlightedRow=s}getHighlightPosition(e,t){if(!t){const i=this.getRowIndexAtPixel(e);if(!(t=this.getRow(i||0)))return c.RowHighlightPosition.Below}const{rowTop:i,rowHeight:s}=t;return e-i<s/2?c.RowHighlightPosition.Above:c.RowHighlightPosition.Below}getLastHighlightedRowNode(){return this.lastHighlightedRow}isLastRowIndexKnown(){return!0}getRowCount(){return this.rowsToDisplay?this.rowsToDisplay.length:0}getTopLevelRowCount(){if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return 1;const e=this.rootNode.childrenAfterAggFilter;return e?e.length:0}getTopLevelRowDisplayedIndex(e){if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return e;let t=this.rootNode.childrenAfterSort[e];if(this.gridOptionsService.get("groupHideOpenParents"))for(;t.expanded&&t.childrenAfterSort&&t.childrenAfterSort.length>0;)t=t.childrenAfterSort[0];return t.rowIndex}getRowBounds(e){if(c._.missing(this.rowsToDisplay))return null;const t=this.rowsToDisplay[e];return t?{rowTop:t.rowTop,rowHeight:t.rowHeight}:null}onRowGroupOpened(){const e=this.gridOptionsService.isAnimateRows();this.refreshModel({step:c.ClientSideRowModelSteps.MAP,keepRenderedRows:!0,animate:e})}onFilterChanged(e){if(e.afterDataChange)return;const t=this.gridOptionsService.isAnimateRows(),i=0===e.columns.length||e.columns.some((e=>e.isPrimary()))?c.ClientSideRowModelSteps.FILTER:c.ClientSideRowModelSteps.FILTER_AGGREGATES;this.refreshModel({step:i,keepRenderedRows:!0,animate:t})}onSortChanged(){const e=this.gridOptionsService.isAnimateRows();this.refreshModel({step:c.ClientSideRowModelSteps.SORT,keepRenderedRows:!0,animate:e,keepEditingRows:!0})}getType(){return"clientSide"}onValueChanged(){this.columnModel.isPivotActive()?this.refreshModel({step:c.ClientSideRowModelSteps.PIVOT}):this.refreshModel({step:c.ClientSideRowModelSteps.AGGREGATE})}createChangePath(e){const t=c._.missingOrEmpty(e),i=new c.ChangedPath(!1,this.rootNode);return(t||this.gridOptionsService.get("treeData"))&&i.setInactive(),i}isSuppressModelUpdateAfterUpdateTransaction(e){if(!this.gridOptionsService.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=c.ClientSideRowModelSteps.EVERYTHING;const i={everything:c.ClientSideRowModelSteps.EVERYTHING,group:c.ClientSideRowModelSteps.EVERYTHING,filter:c.ClientSideRowModelSteps.FILTER,map:c.ClientSideRowModelSteps.MAP,aggregate:c.ClientSideRowModelSteps.AGGREGATE,sort:c.ClientSideRowModelSteps.SORT,pivot:c.ClientSideRowModelSteps.PIVOT};if(c._.exists(e)&&(t=i[e]),c._.missing(t))return void console.error(`AG Grid: invalid step ${e}, available steps are ${Object.keys(i).join(", ")}`);return{step:t,keepRenderedRows:!0,keepEditingRows:!0,animate:!this.gridOptionsService.get("suppressAnimationFrame")}}refreshModel(e){if(!this.hasStarted||this.isRefreshingModel||this.columnModel.shouldRowModelIgnoreRefresh())return;let 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 c.ClientSideRowModelSteps.EVERYTHING:this.doRowGrouping(t.rowNodeTransactions,t.rowNodeOrder,i,!!t.afterColumnsChanged);case c.ClientSideRowModelSteps.FILTER:this.doFilter(i);case c.ClientSideRowModelSteps.PIVOT:this.doPivot(i);case c.ClientSideRowModelSteps.AGGREGATE:this.doAggregate(i);case c.ClientSideRowModelSteps.FILTER_AGGREGATES:this.doFilterAggregates(i);case c.ClientSideRowModelSteps.SORT:this.doSort(t.rowNodeTransactions,i);case c.ClientSideRowModelSteps.MAP:this.doRowsToDisplay()}const s=this.setRowTopAndRowIndex();this.clearRowTopAndRowIndex(i,s),this.isRefreshingModel=!1;const r={type:c.Events.EVENT_MODEL_UPDATED,animate:t.animate,keepRenderedRows:t.keepRenderedRows,newData:t.newData,newPage:!1,keepUndoRedoStack:t.keepUndoRedoStack};this.eventService.dispatchEvent(r)}isEmpty(){const e=c._.missing(this.rootNode.allLeafChildren)||0===this.rootNode.allLeafChildren.length;return c._.missing(this.rootNode)||e||!this.columnModel.isReady()}isRowsToRender(){return c._.exists(this.rowsToDisplay)&&this.rowsToDisplay.length>0}getNodesInRangeForSelection(e,t){let i=!t,s=!1;const r=[],o=this.gridOptionsService.get("groupSelectsChildren");return this.forEachNodeAfterFilterAndSort((n=>{if(s)return;if(i&&(n===t||n===e)&&(s=!0,n.group&&o))return void r.push(...n.allLeafChildren);if(!i){if(n!==t&&n!==e)return;i=!0}(!n.group||!o)&&r.push(n)})),r}setDatasource(e){console.error("AG Grid: 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(c._.last(this.rowsToDisplay).rowTop<=e)return this.rowsToDisplay.length-1;let s=-1,r=-1;for(;;){const o=Math.floor((t+i)/2),n=this.rowsToDisplay[o];if(this.isRowInPixel(n,e))return o;n.rowTop<e?t=o+1:n.rowTop>e&&(i=o-1);if(s===t&&r===i)return o;s=t,r=i}}isRowInPixel(e,t){const i=e.rowTop,s=e.rowTop+e.rowHeight;return i<=t&&s>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){var t;const{nodes:i,callback:s,recursionType:r,includeFooterNodes:o}=e;let{index:n}=e;for(let e=0;e<i.length;e++){const t=i[e];if(s(t,n++),t.hasChildren()&&!t.footer){let e=null;switch(r){case 0:e=t.childrenAfterGroup;break;case 1:e=t.childrenAfterAggFilter;break;case 2:e=t.childrenAfterSort;break;case 3:e=t.leafGroup?null:t.childrenAfterSort}e&&(n=this.recursivelyWalkNodesAndCallback({nodes:[...e],callback:s,recursionType:r,index:n,includeFooterNodes:o}))}}const a=null==(t=i[0])?void 0:t.parent;if(!o||!a)return n;if(a===this.rootNode){if(!this.gridOptionsService.get("groupIncludeTotalFooter"))return n}else{if(!this.gridOptionsService.getGroupIncludeFooter()({node:a}))return n}return a.createFooter(),s(a.sibling,n++),n}doAggregate(e){this.aggregationStage&&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.gridOptionsService.get("treeData"),i=this.columnModel.isPivotActive(),s=r=>{r&&r.forEach((r=>{const o=()=>{r.expanded=e,s(r.childrenAfterGroup)};if(t){return void(c._.exists(r.childrenAfterGroup)&&o())}if(i){return void(!r.leafGroup&&o())}r.group&&o()}))};this.rootNode&&s(this.rootNode.childrenAfterGroup),this.refreshModel({step:c.ClientSideRowModelSteps.MAP});const r=e?"expandAll":"collapseAll",o={type:c.Events.EVENT_EXPAND_COLLAPSE_ALL,source:r};this.eventService.dispatchEvent(o)}doSort(e,t){this.sortStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,changedPath:t})}doRowGrouping(e,t,i,s){if(this.groupStage){if(e?this.groupStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,rowNodeOrder:t,changedPath:i}):this.groupStage.execute({rowNode:this.rootNode,changedPath:i,afterColumnsChanged:s}),this.gridOptionsService.get("groupSelectsChildren")){if(this.selectionService.updateGroupsFromChildrenSelections("rowGroupChanged",i)){const e={type:c.Events.EVENT_SELECTION_CHANGED,source:"rowGroupChanged"};this.eventService.dispatchEvent(e)}}}else this.rootNode.childrenAfterGroup=this.rootNode.allLeafChildren,this.rootNode.sibling&&(this.rootNode.sibling.childrenAfterGroup=this.rootNode.childrenAfterGroup),this.rootNode.updateHasChildren();this.nodeManager.isRowCountReady()&&(this.rowCountReady=!0,this.eventService.dispatchEventOnce({type:c.Events.EVENT_ROW_COUNT_READY}))}doFilter(e){this.filterStage.execute({rowNode:this.rootNode,changedPath:e})}doPivot(e){this.pivotStage&&this.pivotStage.execute({rowNode:this.rootNode,changedPath:e})}getCopyOfNodesMap(){return this.nodeManager.getCopyOfNodesMap()}getRowNode(e){if("string"==typeof e&&0==e.indexOf(c.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(){const e={type:c.Events.EVENT_ROW_DATA_UPDATED};this.eventService.dispatchEvent(e),this.refreshModel({step:c.ClientSideRowModelSteps.EVERYTHING,newData:!0})}batchUpdateRowData(e,t){if(null==this.applyAsyncTransactionsTimeout){this.rowDataTransactionBatch=[];const e=this.gridOptionsService.getAsyncTransactionWaitMillis();this.applyAsyncTransactionsTimeout=window.setTimeout((()=>{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;if(this.rowDataTransactionBatch&&this.rowDataTransactionBatch.forEach((s=>{const r=this.nodeManager.updateRowData(s.rowDataTransaction,void 0);t.push(r),s.callback&&e.push(s.callback.bind(null,r)),"number"==typeof s.rowDataTransaction.addIndex&&(i=!0)})),this.commonUpdateRowData(t,void 0,i),e.length>0&&window.setTimeout((()=>{e.forEach((e=>e()))}),0),t.length>0){const e={type:c.Events.EVENT_ASYNC_TRANSACTIONS_FLUSHED,results:t};this.eventService.dispatchEvent(e)}this.rowDataTransactionBatch=null,this.applyAsyncTransactionsTimeout=void 0}updateRowData(e,t){this.valueCache.onDataChanged();const i=this.nodeManager.updateRowData(e,t),s="number"==typeof e.addIndex;return this.commonUpdateRowData([i],t,s),i}createRowNodeOrder(){if(this.gridOptionsService.get("suppressMaintainUnsortedOrder"))return;const e={};if(this.rootNode&&this.rootNode.allLeafChildren)for(let t=0;t<this.rootNode.allLeafChildren.length;t++){e[this.rootNode.allLeafChildren[t].id]=t}return e}commonUpdateRowData(e,t,i){if(!this.hasStarted)return;const s=!this.gridOptionsService.get("suppressAnimationFrame");i&&(t=this.createRowNodeOrder());const r={type:c.Events.EVENT_ROW_DATA_UPDATED};this.eventService.dispatchEvent(r),this.refreshModel({step:c.ClientSideRowModelSteps.EVERYTHING,rowNodeTransactions:e,rowNodeOrder:t,keepRenderedRows:!0,keepEditingRows:!0,animate:s})}doRowsToDisplay(){this.rowsToDisplay=this.flattenStage.execute({rowNode:this.rootNode})}onRowHeightChanged(){this.refreshModel({step:c.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(){this.columnModel.isAutoRowHeightActive()||this.resetRowHeights()}onGridReady(){this.hasStarted||this.setInitialData()}isRowDataLoaded(){return this.rowCountReady}};l([(0,c.Autowired)("columnModel")],m.prototype,"columnModel",2),l([(0,c.Autowired)("selectionService")],m.prototype,"selectionService",2),l([(0,c.Autowired)("filterManager")],m.prototype,"filterManager",2),l([(0,c.Autowired)("valueCache")],m.prototype,"valueCache",2),l([(0,c.Autowired)("beans")],m.prototype,"beans",2),l([(0,c.Autowired)("filterStage")],m.prototype,"filterStage",2),l([(0,c.Autowired)("sortStage")],m.prototype,"sortStage",2),l([(0,c.Autowired)("flattenStage")],m.prototype,"flattenStage",2),l([(0,c.Optional)("groupStage")],m.prototype,"groupStage",2),l([(0,c.Optional)("aggregationStage")],m.prototype,"aggregationStage",2),l([(0,c.Optional)("pivotStage")],m.prototype,"pivotStage",2),l([(0,c.Optional)("filterAggregatesStage")],m.prototype,"filterAggregatesStage",2),l([c.PostConstruct],m.prototype,"init",1),m=l([(0,c.Bean)("rowModel")],m);var v=i(423),f=class extends v.BeanStub{execute(e){const{changedPath:t}=e;this.filterService.filter(t)}};l([(0,v.Autowired)("filterService")],f.prototype,"filterService",2),f=l([(0,v.Bean)("filterStage")],f);var C=i(423),y=class extends C.BeanStub{execute(e){const t=this.sortController.getSortOptions(),i=C._.exists(t)&&t.length>0,s=i&&C._.exists(e.rowNodeTransactions)&&this.gridOptionsService.get("deltaSort"),r=t.some((e=>this.gridOptionsService.isColumnsSortingCoupledToGroup()?e.column.isPrimary()&&e.column.isRowGroupActive():!!e.column.getColDef().showRowGroup));this.sortService.sort(t,i,s,e.rowNodeTransactions,e.changedPath,r)}};l([(0,C.Autowired)("sortService")],y.prototype,"sortService",2),l([(0,C.Autowired)("sortController")],y.prototype,"sortController",2),y=l([(0,C.Bean)("sortStage")],y);var S=i(423),w=class extends S.BeanStub{execute(e){const t=e.rowNode,i=[],s=this.columnModel.isPivotMode(),r=s&&t.leafGroup,o=r?[t]:t.childrenAfterSort,n=this.getFlattenDetails();this.recursivelyAddToRowsToDisplay(n,o,i,s,0);return!r&&i.length>0&&n.groupIncludeTotalFooter&&(t.createFooter(),this.addRowNodeToRowsToDisplay(n,t.sibling,i,0)),i}getFlattenDetails(){const e=this.gridOptionsService.get("groupRemoveSingleChildren");return{groupRemoveLowestSingleChildren:!e&&this.gridOptionsService.get("groupRemoveLowestSingleChildren"),groupRemoveSingleChildren:e,isGroupMultiAutoColumn:this.gridOptionsService.isGroupMultiAutoColumn(),hideOpenParents:this.gridOptionsService.get("groupHideOpenParents"),groupIncludeTotalFooter:this.gridOptionsService.get("groupIncludeTotalFooter"),getGroupIncludeFooter:this.gridOptionsService.getGroupIncludeFooter()}}recursivelyAddToRowsToDisplay(e,t,i,s,r){if(!S._.missingOrEmpty(t))for(let o=0;o<t.length;o++){const n=t[o],a=n.hasChildren(),l=s&&!a,d=e.groupRemoveSingleChildren&&a&&1===n.childrenAfterGroup.length,h=e.groupRemoveLowestSingleChildren&&a&&n.leafGroup&&1===n.childrenAfterGroup.length,c=s&&n.leafGroup,u=e.hideOpenParents&&n.expanded&&!n.master&&!c;if(!(l||u||d||h)&&this.addRowNodeToRowsToDisplay(e,n,i,r),!s||!n.leafGroup)if(a){const t=d||h;if(n.expanded||t){const o=t?r:r+1;this.recursivelyAddToRowsToDisplay(e,n.childrenAfterSort,i,s,o);e.getGroupIncludeFooter({node:n})?(n.createFooter(),this.addRowNodeToRowsToDisplay(e,n.sibling,i,o)):n.destroyFooter()}}else if(n.master&&n.expanded){const t=this.createDetailNode(n);this.addRowNodeToRowsToDisplay(e,t,i,r)}}}addRowNodeToRowsToDisplay(e,t,i,s){i.push(t),t.setUiLevel(e.isGroupMultiAutoColumn?0:s)}createDetailNode(e){if(S._.exists(e.detailNode))return e.detailNode;const t=new S.RowNode(this.beans);return t.detail=!0,t.selectable=!1,t.parent=e,S._.exists(e.id)&&(t.id="detail_"+e.id),t.data=e.data,t.level=e.level+1,e.detailNode=t,t}};l([(0,S.Autowired)("columnModel")],w.prototype,"columnModel",2),l([(0,S.Autowired)("beans")],w.prototype,"beans",2),w=l([(0,S.Bean)("flattenStage")],w);var b=i(423),E=class extends b.BeanStub{sort(e,t,i,s,r,o){const n=this.gridOptionsService.get("groupMaintainOrder"),a=this.columnModel.getAllGridColumns().some((e=>e.isRowGroupActive()));let l={};i&&s&&(l=this.calculateDirtyNodes(s));const d=this.columnModel.isPivotMode(),h=this.gridOptionsService.getCallback("postSortRows"),c=s=>{var c;this.pullDownGroupDataForHideOpenParents(s.childrenAfterAggFilter,!0);const u=d&&s.leafGroup;if(n&&a&&!s.leafGroup&&!o){const e=null==(c=this.columnModel.getRowGroupColumns())?void 0:c[s.level+1],t=null===(null==e?void 0:e.getSort()),i=s.childrenAfterAggFilter.slice(0);if(s.childrenAfterSort&&!t){const e={};s.childrenAfterSort.forEach(((t,i)=>{e[t.id]=i})),i.sort(((t,i)=>{var s,r;return(null!=(s=e[t.id])?s:0)-(null!=(r=e[i.id])?r:0)}))}s.childrenAfterSort=i}else s.childrenAfterSort=!t||u?s.childrenAfterAggFilter.slice(0):i?this.doDeltaSort(s,l,r,e):this.rowNodeSorter.doFullSort(s.childrenAfterAggFilter,e);if(s.sibling&&(s.sibling.childrenAfterSort=s.childrenAfterSort),this.updateChildIndexes(s),h){const e={nodes:s.childrenAfterSort};h(e)}};r&&r.forEachChangedNodeDepthFirst(c),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,s){const r=e.childrenAfterAggFilter,o=e.childrenAfterSort;if(!o)return this.rowNodeSorter.doFullSort(r,s);const n={},a=[];r.forEach((e=>{t[e.id]||!i.canSkip(e)?a.push(e):n[e.id]=!0}));const l=o.filter((e=>n[e.id])),d=(e,t)=>({currentPos:t,rowNode:e}),h=a.map(d).sort(((e,t)=>this.rowNodeSorter.compareRowNodes(s,e,t)));return this.mergeSortedArrays(s,h,l.map(d)).map((({rowNode:e})=>e))}mergeSortedArrays(e,t,i){const s=[];let r=0,o=0;for(;r<t.length&&o<i.length;){this.rowNodeSorter.compareRowNodes(e,t[r],i[o])<0?s.push(t[r++]):s.push(i[o++])}for(;r<t.length;)s.push(t[r++]);for(;o<i.length;)s.push(i[o++]);return s}updateChildIndexes(e){if(b._.missing(e.childrenAfterSort))return;const t=e.childrenAfterSort;for(let i=0;i<t.length;i++){const s=t[i],r=0===i,o=i===e.childrenAfterSort.length-1;s.setFirstChild(r),s.setLastChild(o),s.setChildIndex(i)}}updateGroupDataForHideOpenParents(e){if(!this.gridOptionsService.get("groupHideOpenParents"))return;if(this.gridOptionsService.get("treeData"))return b._.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.gridOptionsService.get("groupHideOpenParents")&&!b._.missing(e)&&e.forEach((e=>{this.columnModel.getGroupDisplayColumns().forEach((i=>{const s=i.getColDef().showRowGroup;if("string"!=typeof s)return void console.error("AG Grid: groupHideOpenParents only works when specifying specific columns for colDef.showRowGroup");const r=s,o=this.columnModel.getPrimaryColumn(r);if(!(o===e.rowGroupColumn))if(t)e.setGroupValue(i.getId(),void 0);else{const t=e.getFirstChildOfFirstChild(o);t&&e.setGroupValue(i.getId(),t.key)}}))}))}};l([(0,b.Autowired)("columnModel")],E.prototype,"columnModel",2),l([(0,b.Autowired)("rowNodeSorter")],E.prototype,"rowNodeSorter",2),E=l([(0,b.Bean)("sortService")],E);var x=i(423),T=class extends x.BeanStub{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,s)=>{if(t.childrenAfterGroup)for(let r=0;r<t.childrenAfterGroup.length;r++){const o=t.childrenAfterGroup[r],n=s||this.filterManager.doesRowPassFilter({rowNode:o});o.childrenAfterGroup?e(t.childrenAfterGroup[r],n):i(o,n)}i(t,s)},s=t=>e(t,!1);t.executeFromRootNode(s)}else{const e=e=>i(e,!1);t.forEachChangedNodeDepthFirst(e,!0)}}doingTreeDataFiltering(){return this.gridOptionsService.get("treeData")&&!this.gridOptionsService.get("excludeChildrenWhenTreeDataFiltering")}};l([(0,x.Autowired)("filterManager")],T.prototype,"filterManager",2),T=l([(0,x.Bean)("filterService")],T);var D=i(423),A=class extends D.BeanStub{postConstruct(){"clientSide"===this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel,this.addManagedPropertyListener("rowData",(()=>this.onRowDataUpdated())))}isActive(){const e=this.gridOptionsService.exists("getRowId");return!this.gridOptionsService.get("resetRowDataOnUpdate")&&e}setRowData(e){const t=this.createTransactionForRowData(e);if(!t)return;const[i,s]=t;this.clientSideRowModel.updateRowData(i,s)}createTransactionForRowData(e){if(D._.missing(this.clientSideRowModel))return void console.error("AG Grid: ImmutableService only works with ClientSideRowModel");const t=this.gridOptionsService.getCallback("getRowId");if(null==t)return void console.error("AG Grid: ImmutableService requires getRowId() callback to be implemented, your row data needs IDs!");const i={remove:[],update:[],add:[]},s=this.clientSideRowModel.getCopyOfNodesMap(),r=this.gridOptionsService.get("suppressMaintainUnsortedOrder")?void 0:{};return D._.exists(e)&&e.forEach(((e,o)=>{const n=t({data:e,level:0}),a=s[n];if(r&&(r[n]=o),a){a.data!==e&&i.update.push(e),s[n]=void 0}else i.add.push(e)})),D._.iterateObject(s,((e,t)=>{t&&i.remove.push(t.data)})),[i,r]}onRowDataUpdated(){const e=this.gridOptionsService.get("rowData");e&&(this.isActive()?this.setRowData(e):(this.selectionService.reset("rowDataChanged"),this.clientSideRowModel.setRowData(e)))}};l([(0,D.Autowired)("rowModel")],A.prototype,"rowModel",2),l([(0,D.Autowired)("rowRenderer")],A.prototype,"rowRenderer",2),l([(0,D.Autowired)("selectionService")],A.prototype,"selectionService",2),l([D.PostConstruct],A.prototype,"postConstruct",1),A=l([(0,D.Bean)("immutableService")],A);var R={version:"31.2.0",moduleName:h.ModuleNames.ClientSideRowModelModule,rowModel:"clientSide",beans:[m,f,y,w,E,T,A]}},423:function(e,t,i){var s,r=Object.defineProperty,o=Object.defineProperties,n=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyDescriptors,l=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,h=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,u=(e,t,i)=>t in e?r(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,p=(e,t)=>{for(var i in t||(t={}))h.call(t,i)&&u(e,i,t[i]);if(d)for(var i of d(t))c.call(t,i)&&u(e,i,t[i]);return e},g=(e,t)=>o(e,a(t)),m=(e,t)=>{for(var i in t)r(e,i,{get:t[i],enumerable:!0})},v=(e,t,i,s)=>{for(var o,a=s>1?void 0:s?n(t,i):t,l=e.length-1;l>=0;l--)(o=e[l])&&(a=(s?o(t,i,a):o(a))||a);return s&&a&&r(t,i,a),a},f=(e,t)=>(i,s)=>t(i,s,e),C={};m(C,{ALWAYS_SYNC_GLOBAL_EVENTS:()=>ht,AbstractHeaderCellCtrl:()=>rl,AgAbstractField:()=>Hr,AgAbstractLabel:()=>Br,AgAutocomplete:()=>bd,AgCheckbox:()=>Yr,AgDialog:()=>md,AgGroupComponent:()=>nd,AgInputDateField:()=>Zl,AgInputNumberField:()=>lo,AgInputRange:()=>Ql,AgInputTextArea:()=>ql,AgInputTextField:()=>ao,AgMenuItemComponent:()=>ud,AgMenuItemRenderer:()=>vn,AgMenuList:()=>dd,AgMenuPanel:()=>hd,AgPanel:()=>gd,AgPickerField:()=>Wr,AgPromise:()=>fr,AgPromiseStatus:()=>vr,AgRadioButton:()=>Xr,AgRichSelect:()=>id,AgSelect:()=>$r,AgSlider:()=>rd,AgStackComponentsRegistry:()=>Nt,AgToggleButton:()=>Xl,AlignedGridsService:()=>Pd,AnimateShowChangeCellRenderer:()=>Go,AnimateSlideCellRenderer:()=>_o,AnimationFrameService:()=>Ll,AutoScrollService:()=>Wn,AutoWidthCalculator:()=>kl,Autowired:()=>ue,BarColumnLabelPlacement:()=>Yh,BaseComponentWrapper:()=>$h,Bean:()=>ce,BeanStub:()=>ot,Beans:()=>ua,BodyDropPivotTarget:()=>$a,BodyDropTarget:()=>Xa,CellComp:()=>Ua,CellCtrl:()=>ya,CellNavigationService:()=>Md,CellPositionUtils:()=>rh,CellRangeType:()=>aa,ChangedPath:()=>Ul,CheckboxCellEditor:()=>mn,CheckboxCellRenderer:()=>gn,CheckboxSelectionComponent:()=>Ho,ClientSideRowModelSteps:()=>Ol,ColDefUtil:()=>Vn,Column:()=>Ee,ColumnApi:()=>Ld,ColumnFactory:()=>nt,ColumnGroup:()=>lt,ColumnKeyCreator:()=>F,ColumnModel:()=>Dt,ColumnUtils:()=>Rt,Component:()=>Tr,ComponentUtil:()=>It,Context:()=>ae,CssClassApplier:()=>va,CssClassManager:()=>yr,CtrlsService:()=>gh,DataTypeService:()=>Oh,DateCellEditor:()=>hn,DateFilter:()=>so,DateStringCellEditor:()=>un,DisplayedGroupCreator:()=>Mt,DragAndDropService:()=>Ko,DragService:()=>zn,DragSourceType:()=>zo,Environment:()=>Zd,EventService:()=>fe,Events:()=>dt,ExcelFactoryMode:()=>Bn,ExpansionService:()=>Il,ExpressionService:()=>Id,FilterManager:()=>qn,FloatingFilterMapper:()=>kn,FocusService:()=>Hd,GROUP_AUTO_COLUMN_ID:()=>ut,Grid:()=>Uh,GridApi:()=>Yn,GridBodyComp:()=>Ga,GridBodyCtrl:()=>oa,GridComp:()=>Vd,GridCoreCreator:()=>Kh,GridCtrl:()=>_d,GridHeaderComp:()=>El,GridHeaderCtrl:()=>wl,GridOptionsService:()=>Ah,GroupCellRenderer:()=>Qo,GroupCellRendererCtrl:()=>qo,GroupInstanceIdCreator:()=>ct,HeaderCellCtrl:()=>hl,HeaderFilterCellComp:()=>Jn,HeaderFilterCellCtrl:()=>al,HeaderGroupCellCtrl:()=>pl,HeaderNavigationDirection:()=>yl,HeaderNavigationService:()=>Sl,HeaderPositionUtils:()=>hh,HeaderRowComp:()=>tl,HeaderRowContainerComp:()=>Cl,HeaderRowContainerCtrl:()=>vl,HeaderRowCtrl:()=>ml,HeaderRowType:()=>el,HorizontalDirection:()=>Uo,HorizontalResizeService:()=>xl,KeyCode:()=>qs,LargeTextCellEditor:()=>Lo,LayoutCssClasses:()=>ea,LocaleService:()=>Rh,Logger:()=>Gd,LoggerFactory:()=>kd,ManagedFocusFeature:()=>Ir,MenuService:()=>Nl,ModuleNames:()=>re,ModuleRegistry:()=>ne,MouseEventService:()=>Va,MoveColumnFeature:()=>Ya,NavigationService:()=>Ba,NumberCellEditor:()=>ln,NumberFilter:()=>po,NumberSequence:()=>mr,Optional:()=>pe,PaginationProxy:()=>jl,PillDragComp:()=>xd,PillDropZonePanel:()=>Dd,PinnedRowModel:()=>Hl,PopupComponent:()=>Po,PopupEditorWrapper:()=>Wa,PopupService:()=>fd,PositionableFeature:()=>Gr,PostConstruct:()=>de,PreConstruct:()=>le,PreDestroy:()=>he,PropertyKeys:()=>Lt,ProvidedColumnGroup:()=>Te,ProvidedFilter:()=>Vr,Qualifier:()=>me,QuerySelector:()=>Dr,RefSelector:()=>Ar,ResizeObserverService:()=>Fl,RowAnimationCssClasses:()=>sa,RowContainerComp:()=>Ka,RowContainerCtrl:()=>ka,RowContainerName:()=>Pa,RowContainerType:()=>Fa,RowCtrl:()=>ba,RowHighlightPosition:()=>Hn,RowNode:()=>Bo,RowNodeBlock:()=>Kl,RowNodeBlockLoader:()=>$l,RowNodeSorter:()=>ph,RowPositionUtils:()=>sh,RowRenderer:()=>_l,ScalarFilter:()=>Jr,ScrollVisibleService:()=>_a,SelectCellEditor:()=>Oo,SelectableService:()=>Jd,SelectionHandleType:()=>na,ServerSideTransactionResultStatus:()=>Wl,SetLeftFeature:()=>ol,SimpleFilter:()=>Qr,SortController:()=>Bd,SortIndicatorComp:()=>To,StandardMenuFactory:()=>Tl,StylingService:()=>Yl,TabGuardClassNames:()=>Dl,TabGuardComp:()=>Rl,TabGuardCtrl:()=>Al,TabbedLayout:()=>Pl,TemplateService:()=>Nd,TextCellEditor:()=>ko,TextFilter:()=>vo,TextFloatingFilter:()=>wo,Timer:()=>Cr,TooltipFeature:()=>br,TooltipStateManager:()=>wr,TouchListener:()=>Eo,UserComponentFactory:()=>Gn,UserComponentRegistry:()=>fn,ValueCache:()=>Kd,ValueFormatterService:()=>Bl,ValueParserService:()=>Ih,ValueService:()=>Od,VanillaFrameworkOverrides:()=>Rd,VerticalDirection:()=>Wo,VirtualList:()=>td,VirtualListDragFeature:()=>$n,_:()=>gr,__FORCE_MODULE_DETECTION:()=>jh,createGrid:()=>Wh,getRowContainerTypeForName:()=>La}),e.exports=(s=C,((e,t,i,s)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let o of l(t))h.call(e,o)||o===i||r(e,o,{get:()=>t[o],enumerable:!(s=n(t,o))||s.enumerable});return e})(r({},"__esModule",{value:!0}),s));var y={};function S(e){return null==e||""===e?null:e}function w(e,t=!1){return null!=e&&(""!==e||t)}function b(e){return!w(e)}function E(e){return null==e||0===e.length}function x(e){return null!=e&&"function"==typeof e.toString?e.toString():null}function T(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 D(e){if(void 0!==e)return null!==e&&""!==e&&("boolean"==typeof e?e:/true/i.test(e))}function A(e){if(null!=e&&""!==e)return e}function R(e,t){return(e?JSON.stringify(e):null)===(t?JSON.stringify(t):null)}function M(e,t,i=!1){const s=null==e,r=null==t;if(e&&e.toNumber&&(e=e.toNumber()),t&&t.toNumber&&(t=t.toNumber()),s&&r)return 0;if(s)return-1;if(r)return 1;function o(e,t){return e>t?1:e<t?-1:0}if("string"!=typeof e)return o(e,t);if(!i)return o(e,t);try{return e.localeCompare(t)}catch(i){return o(e,t)}}function P(e){if(e instanceof Set||e instanceof Map){const t=[];return e.forEach((e=>t.push(e))),t}return Object.values(e)}m(y,{attrToBoolean:()=>D,attrToNumber:()=>T,attrToString:()=>A,defaultComparator:()=>M,exists:()=>w,jsonEquals:()=>R,makeNull:()=>S,missing:()=>b,missingOrEmpty:()=>E,toStringOrNull:()=>x,values:()=>P});var F=class{constructor(){this.existingKeys={}}addExistingKeys(e){for(let t=0;t<e.length;t++)this.existingKeys[e[t]]=!0}getUniqueKey(e,t){e=x(e);let i=0;for(;;){let s;if(e?(s=e,0!==i&&(s+="_"+i)):t?(s=t,0!==i&&(s+="_"+i)):s=i,!this.existingKeys[s])return this.existingKeys[s]=!0,String(s);i++}}},L={};function O(e,t){if(null!=e)if(Array.isArray(e))for(let i=0;i<e.length;i++)t(i.toString(),e[i]);else for(const[i,s]of Object.entries(e))t(i,s)}function I(e){const t={},i=Object.keys(e);for(let s=0;s<i.length;s++){const r=i[s],o=e[r];t[r]=o}return t}function N(e,t){if(!e)return;const i=e,s={};return Object.keys(i).forEach((e=>{if(t&&t.indexOf(e)>=0)return;const r=i[e],o=B(r)&&r.constructor===Object;s[e]=o?N(r):r})),s}function k(e){if(!e)return[];const t=Object;if("function"==typeof t.values)return t.values(e);const i=[];for(const t in e)e.hasOwnProperty(t)&&e.propertyIsEnumerable(t)&&i.push(e[t]);return i}function G(e,t,i=!0,s=!1){w(t)&&O(t,((t,r)=>{let o=e[t];if(o!==r){if(s){if(null==o&&null!=r){"object"==typeof r&&r.constructor===Object&&(o={},e[t]=o)}}B(r)&&B(o)&&!Array.isArray(o)?G(o,r,i,s):(i||void 0!==r)&&(e[t]=r)}}))}function _(e,t,i){if(!t||!e)return;if(!i)return e[t];const s=t.split(".");let r=e;for(let e=0;e<s.length;e++){if(null==r)return;r=r[s[e]]}return r}function V(e,t=[],i){Object.keys(e).forEach((i=>{"object"!=typeof e[i]||t.includes(i)||(e[i]=void 0)}));const s=Object.getPrototypeOf(e),r={};Object.getOwnPropertyNames(s).forEach((e=>{if("function"==typeof s[e]&&!t.includes(e)){const t=()=>{console.warn((e=>`AG Grid: Grid API function ${e}() cannot be called as the grid has been destroyed.\n It is recommended to remove local references to the grid api. Alternatively, 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: ${i}`)(e))};r[e]={value:t,writable:!0}}})),Object.defineProperties(e,r)}function B(e){return"object"==typeof e&&null!==e}m(L,{cloneObject:()=>I,deepCloneDefinition:()=>N,getAllValuesInObject:()=>k,getValueUsingField:()=>_,isNonNullObject:()=>B,iterateObject:()=>O,mergeDeep:()=>G,removeAllReferences:()=>V});var H={};m(H,{compose:()=>ie,debounce:()=>J,doOnce:()=>U,errorOnce:()=>K,executeAfter:()=>Q,executeInAWhile:()=>Y,executeNextVMTurn:()=>Z,getFunctionName:()=>$,isFunction:()=>j,noop:()=>se,throttle:()=>ee,waitUntil:()=>te,warnOnce:()=>z});var W={};function U(e,t){W[t]||(e(),W[t]=!0)}function z(e){U((()=>console.warn("AG Grid: "+e)),e)}function K(e){U((()=>console.error("AG Grid: "+e)),e)}function $(e){if(e.name)return e.name;const t=/function\s+([^\(]+)/.exec(e.toString());return t&&2===t.length?t[1].trim():null}function j(e){return!!(e&&e.constructor&&e.call&&e.apply)}function Y(e){Q(e,400)}var X=[],q=!1;function Z(e){X.push(e),q||(q=!0,window.setTimeout((()=>{const e=X.slice();X.length=0,q=!1,e.forEach((e=>e()))}),0))}function Q(e,t=0){e.length>0&&window.setTimeout((()=>e.forEach((e=>e()))),t)}function J(e,t){let i;return function(...s){const r=this;window.clearTimeout(i),i=window.setTimeout((function(){e.apply(r,s)}),t)}}function ee(e,t){let i=0;return function(...s){const r=(new Date).getTime();r-i<t||(i=r,e.apply(this,s))}}function te(e,t,i=100,s){const r=(new Date).getTime();let o=null,n=!1;const a=()=>{const a=(new Date).getTime()-r>i;(e()||a)&&(t(),n=!0,null!=o&&(window.clearInterval(o),o=null),a&&s&&console.warn(s))};a(),n||(o=window.setInterval(a,10))}function ie(...e){return t=>e.reduce(((e,t)=>t(e)),t)}var se=()=>{},re=(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))(re||{}),oe=class e{static register(t){e.__register(t,!0,void 0)}static registerModules(t){e.__registerModules(t,!0,void 0)}static __register(t,i,s){e.runVersionChecks(t),void 0!==s?(e.areGridScopedModules=!0,void 0===e.gridModulesMap[s]&&(e.gridModulesMap[s]={}),e.gridModulesMap[s][t.moduleName]=t):e.globalModulesMap[t.moduleName]=t,e.setModuleBased(i)}static __unRegisterGridModules(t){delete e.gridModulesMap[t]}static __registerModules(t,i,s){e.setModuleBased(i),t&&t.forEach((t=>e.__register(t,i,s)))}static isValidModuleVersion(t){const[i,s]=t.version.split(".")||[],[r,o]=e.currentModuleVersion.split(".")||[];return i===r&&s===o}static runVersionChecks(t){if(e.currentModuleVersion||(e.currentModuleVersion=t.version),t.version?e.isValidModuleVersion(t)||console.error(`AG Grid: You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. '${t.moduleName}' is version ${t.version} but the other modules are version ${this.currentModuleVersion}. Please update all modules to the same version.`):console.error(`AG Grid: You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. '${t.moduleName}' is incompatible. Please update all modules to the same version.`),t.validate){const e=t.validate();if(!e.isValid){const t=e;console.error(`AG Grid: ${t.message}`)}}}static setModuleBased(t){void 0===e.moduleBased?e.moduleBased=t:e.moduleBased!==t&&U((()=>{console.warn("AG Grid: You are mixing modules (i.e. @ag-grid-community/core) and packages (ag-grid-community) - you can only use one or the other of these mechanisms."),console.warn("Please see https://www.ag-grid.com/javascript-grid/packages-modules/ for more information.")}),"ModulePackageCheck")}static __setIsBundled(){e.isBundled=!0}static __assertRegistered(t,i,s){var r;if(this.__isRegistered(t,s))return!0;const o=i+t;let n;if(e.isBundled)n=`AG Grid: unable to use ${i} as 'ag-grid-enterprise' has not been loaded. Check you are using the Enterprise bundle:\n \n <script src="https://cdn.jsdelivr.net/npm/ag-grid-enterprise@AG_GRID_VERSION/dist/ag-grid-enterprise.min.js"><\/script>\n \nFor more info see: https://ag-grid.com/javascript-data-grid/getting-started/#getting-started-with-ag-grid-enterprise`;else if(e.moduleBased||void 0===e.moduleBased){let o=null==(r=Object.entries(re).find((([e,i])=>i===t)))?void 0:r[0];n=`AG Grid: unable to use ${i} as the ${o} is not registered${e.areGridScopedModules?` for gridId: ${s}`:""}. Check if you have registered the module:\n \n import { ModuleRegistry } from '@ag-grid-community/core';\n import { ${o} } from '${t}';\n \n ModuleRegistry.registerModules([ ${o} ]);\n\nFor more info see: https://www.ag-grid.com/javascript-grid/modules/`}else n=`AG Grid: unable to use ${i} as package 'ag-grid-enterprise' has not been imported. Check that you have imported the package:\n \n import 'ag-grid-enterprise';\n \nFor more info see: https://www.ag-grid.com/javascript-grid/packages/`;return U((()=>{console.warn(n)}),o),!1}static __warnEnterpriseChartDisabled(e){const t=`AG Grid: the '${e}' chart type is not supported in AG Charts Community as 'ag-grid-charts-enterprise' or '@ag-grid-enterprise/charts-enterprise' hasn't been loaded. See https://www.ag-grid.com/javascript-data-grid/integrated-charts-installation/ for more details.`;U((()=>{console.warn(t)}),"ag-charts-enterprise:"+e)}static __isRegistered(t,i){var s;return!!e.globalModulesMap[t]||!!(null==(s=e.gridModulesMap[i])?void 0:s[t])}static __getRegisteredModules(t){return[...P(e.globalModulesMap),...P(e.gridModulesMap[t]||{})]}static __getGridRegisteredModules(t){var i;return P(null!=(i=e.gridModulesMap[t])?i:{})||[]}static __isPackageBased(){return!e.moduleBased}};oe.globalModulesMap={},oe.gridModulesMap={},oe.areGridScopedModules=!1;var ne=oe,ae=class{constructor(e,t){if(this.beanWrappers={},this.destroyed=!1,!e||!e.beanClasses)return;this.contextParams=e,this.logger=t,this.logger.log(">> creating ag-Application Context"),this.createBeans();const i=this.getBeanInstances();this.wireBeans(i),this.logger.log(">> ag-Application Context ready - component is alive")}getBeanInstances(){return P(this.beanWrappers).map((e=>e.beanInstance))}createBean(e,t){if(!e)throw Error("Can't wire to bean since it is null");return this.wireBeans([e],t),e}wireBeans(e,t){this.autoWireBeans(e),this.methodWireBeans(e),this.callLifeCycleMethods(e,"preConstructMethods"),w(t)&&e.forEach(t),this.callLifeCycleMethods(e,"postConstructMethods")}createBeans(){this.contextParams.beanClasses.forEach(this.createBeanWrapper.bind(this)),O(this.beanWrappers,((e,t)=>{let i;t.bean.__agBeanMetaData&&t.bean.__agBeanMetaData.autowireM