Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
main_1._.iterateObject(this.columnComps, function (key, column) {
column.onSelectAllChanged(checked);
});
}
else {
// however if pivot mode is off, then it's all about column visibility so we can do a bulk
// operation directly with the column controller. we could column.onSelectAllChanged(checked)
// as above, however this would work on each column independently and take longer.
var primaryCols = this.columnApi.getPrimaryColumns();
this.columnApi.setColumnsVisible(primaryCols, checked);
}
};
PrimaryColsListPanel.TEMPLATE = "<div class="\"ag-primary-cols-list-panel\""></div>";
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], PrimaryColsListPanel.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], PrimaryColsListPanel.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], PrimaryColsListPanel.prototype, "globalEventService", void 0);
__decorate([
main_1.Autowired('columnApi'),
__metadata("design:type", ag_grid_community_1.ColumnApi)
], PrimaryColsListPanel.prototype, "columnApi", void 0);
return PrimaryColsListPanel;
}(main_1.Component));
exports.PrimaryColsListPanel = PrimaryColsListPanel;
this.childDestroyFuncs.forEach(function (func) { return func(); });
this.childDestroyFuncs.length = 0;
main_1._.clearElement(this.getGui());
};
ColumnToolPanel.prototype.refresh = function () {
this.destroyChildren();
this.init(this.params);
};
ColumnToolPanel.prototype.destroy = function () {
this.destroyChildren();
_super.prototype.destroy.call(this);
};
ColumnToolPanel.TEMPLATE = "<div class="\"ag-column-panel\""></div>";
__decorate([
main_1.Autowired("gridOptionsWrapper"),
__metadata("design:type", main_1.GridOptionsWrapper)
], ColumnToolPanel.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired("gridApi"),
__metadata("design:type", main_1.GridApi)
], ColumnToolPanel.prototype, "gridApi", void 0);
__decorate([
main_1.Autowired("eventService"),
__metadata("design:type", main_1.EventService)
], ColumnToolPanel.prototype, "eventService", void 0);
return ColumnToolPanel;
}(main_1.Component));
exports.ColumnToolPanel = ColumnToolPanel;
ToolPanelColumnComp.prototype.isSelected = function () {
return this.cbSelect.getValue();
};
ToolPanelColumnComp.prototype.isSelectable = function () {
return !this.cbSelect.isReadOnly();
};
ToolPanelColumnComp.prototype.isExpandable = function () {
return false;
};
ToolPanelColumnComp.prototype.setExpanded = function (value) {
console.warn('ag-grid: can not expand a column item that does not represent a column group header');
};
ToolPanelColumnComp.TEMPLATE = "<div class="\"ag-column-tool-panel-column\"">\n \n <span class="\"ag-column-tool-panel-column-label\""></span>\n </div>";
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], ToolPanelColumnComp.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], ToolPanelColumnComp.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], ToolPanelColumnComp.prototype, "eventService", void 0);
__decorate([
main_1.Autowired('dragAndDropService'),
__metadata("design:type", main_1.DragAndDropService)
], ToolPanelColumnComp.prototype, "dragAndDropService", void 0);
__decorate([
main_1.Autowired('columnApi'),
__metadata("design:type", main_1.ColumnApi)
if (checkedCount > 0 && uncheckedCount > 0) {
this.selectState = SELECTED_STATE.INDETERMINATE;
}
else if (uncheckedCount > 0) {
this.selectState = SELECTED_STATE.UNCHECKED;
}
else {
this.selectState = SELECTED_STATE.CHECKED;
}
main_1._.setDisplayed(this.eSelectChecked, this.selectState === SELECTED_STATE.CHECKED);
main_1._.setDisplayed(this.eSelectUnchecked, this.selectState === SELECTED_STATE.UNCHECKED);
main_1._.setDisplayed(this.eSelectIndeterminate, this.selectState === SELECTED_STATE.INDETERMINATE);
};
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], PrimaryColsHeaderPanel.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], PrimaryColsHeaderPanel.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], PrimaryColsHeaderPanel.prototype, "eventService", void 0);
__decorate([
main_1.RefSelector('eFilterTextField'),
__metadata("design:type", HTMLInputElement)
], PrimaryColsHeaderPanel.prototype, "eFilterTextField", void 0);
__decorate([
main_1.RefSelector('eExpand'),
__metadata("design:type", HTMLElement)
return this.isPotentialDndColumns() ? main_1.DragAndDropService.ICON_GROUP : main_1.DragAndDropService.ICON_NOT_ALLOWED;
};
RowGroupDropZonePanel.prototype.getExistingColumns = function () {
return this.columnController.getRowGroupColumns();
};
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], RowGroupDropZonePanel.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], RowGroupDropZonePanel.prototype, "eventService", void 0);
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], RowGroupDropZonePanel.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('loggerFactory'),
__metadata("design:type", main_1.LoggerFactory)
], RowGroupDropZonePanel.prototype, "loggerFactory", void 0);
__decorate([
main_1.Autowired('dragAndDropService'),
__metadata("design:type", main_1.DragAndDropService)
], RowGroupDropZonePanel.prototype, "dragAndDropService", void 0);
__decorate([
main_1.Autowired('columnApi'),
__metadata("design:type", main_1.ColumnApi)
], RowGroupDropZonePanel.prototype, "columnApi", void 0);
__decorate([
main_1.Autowired('gridApi'),
__metadata("design:type", main_1.GridApi)
};
ToolPanelColumnGroupComp.prototype.isSelectable = function () {
return !this.cbSelect.isReadOnly();
};
ToolPanelColumnGroupComp.prototype.isExpandable = function () {
return true;
};
ToolPanelColumnGroupComp.prototype.setExpanded = function (value) {
if (this.expanded !== value) {
this.onExpandOrContractClicked();
}
};
ToolPanelColumnGroupComp.TEMPLATE = "<div class="\"ag-column-tool-panel-column-group\"">\n <span class="\"ag-column-group-icons\"">\n <span class="\"ag-column-group-closed-icon\""></span>\n <span class="\"ag-column-group-opened-icon\""></span>\n </span>\n \n <span class="\"ag-column-tool-panel-column-label\""></span>\n </div>";
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], ToolPanelColumnGroupComp.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], ToolPanelColumnGroupComp.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('dragAndDropService'),
__metadata("design:type", main_1.DragAndDropService)
], ToolPanelColumnGroupComp.prototype, "dragAndDropService", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], ToolPanelColumnGroupComp.prototype, "eventService", void 0);
__decorate([
main_1.RefSelector('cbSelect'),
__metadata("design:type", main_1.AgCheckbox)
}
var rowGroupPanelShow = this.gridOptionsWrapper.getRowGroupPanelShow();
if (rowGroupPanelShow === main_1.Constants.ALWAYS) {
this.rowGroupComp.setDisplayed(true);
}
else if (rowGroupPanelShow === main_1.Constants.ONLY_WHEN_GROUPING) {
var grouping = !this.columnController.isRowGroupEmpty();
this.rowGroupComp.setDisplayed(grouping);
}
else {
this.rowGroupComp.setDisplayed(false);
}
};
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], GridHeaderDropZones.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], GridHeaderDropZones.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], GridHeaderDropZones.prototype, "eventService", void 0);
__decorate([
main_1.PostConstruct,
__metadata("design:type", Function),
__metadata("design:paramtypes", []),
__metadata("design:returntype", void 0)
], GridHeaderDropZones.prototype, "postConstruct", null);
return GridHeaderDropZones;
};
PivotModePanel.prototype.onPivotModeChanged = function () {
var pivotModeActive = this.columnController.isPivotMode();
this.cbPivotMode.setValue(pivotModeActive);
};
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], PivotModePanel.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], PivotModePanel.prototype, "eventService", void 0);
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], PivotModePanel.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.RefSelector('cbPivotMode'),
__metadata("design:type", main_1.AgCheckbox)
], PivotModePanel.prototype, "cbPivotMode", void 0);
__decorate([
main_1.PreConstruct,
__metadata("design:type", Function),
__metadata("design:paramtypes", []),
__metadata("design:returntype", void 0)
], PivotModePanel.prototype, "init", null);
return PivotModePanel;
}(main_1.Component));
exports.PivotModePanel = PivotModePanel;
}
};
ValuesDropZonePanel.prototype.getExistingColumns = function () {
return this.columnController.getValueColumns();
};
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], ValuesDropZonePanel.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], ValuesDropZonePanel.prototype, "eventService", void 0);
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], ValuesDropZonePanel.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('loggerFactory'),
__metadata("design:type", main_1.LoggerFactory)
], ValuesDropZonePanel.prototype, "loggerFactory", void 0);
__decorate([
main_1.Autowired('dragAndDropService'),
__metadata("design:type", main_1.DragAndDropService)
], ValuesDropZonePanel.prototype, "dragAndDropService", void 0);
__decorate([
main_1.Autowired('columnApi'),
__metadata("design:type", main_1.ColumnApi)
], ValuesDropZonePanel.prototype, "columnApi", void 0);
__decorate([
main_1.Autowired('gridApi'),
__metadata("design:type", main_1.GridApi)
return this.isPotentialDndColumns() ? main_1.DragAndDropService.ICON_PIVOT : main_1.DragAndDropService.ICON_NOT_ALLOWED;
};
PivotDropZonePanel.prototype.getExistingColumns = function () {
return this.columnController.getPivotColumns();
};
__decorate([
main_1.Autowired('columnController'),
__metadata("design:type", main_1.ColumnController)
], PivotDropZonePanel.prototype, "columnController", void 0);
__decorate([
main_1.Autowired('eventService'),
__metadata("design:type", main_1.EventService)
], PivotDropZonePanel.prototype, "eventService", void 0);
__decorate([
main_1.Autowired('gridOptionsWrapper'),
__metadata("design:type", main_1.GridOptionsWrapper)
], PivotDropZonePanel.prototype, "gridOptionsWrapper", void 0);
__decorate([
main_1.Autowired('loggerFactory'),
__metadata("design:type", main_1.LoggerFactory)
], PivotDropZonePanel.prototype, "loggerFactory", void 0);
__decorate([
main_1.Autowired('dragAndDropService'),
__metadata("design:type", main_1.DragAndDropService)
], PivotDropZonePanel.prototype, "dragAndDropService", void 0);
__decorate([
main_1.Autowired('columnApi'),
__metadata("design:type", main_1.ColumnApi)
], PivotDropZonePanel.prototype, "columnApi", void 0);
__decorate([
main_1.Autowired('gridApi'),
__metadata("design:type", main_1.GridApi)