UNPKG

igniteui-react-grids

Version:

Ignite UI React grid components.

1,132 lines (1,126 loc) 40 kB
import { __extends, __values } from "tslib"; import * as React from 'react'; import { fromSize, toSize, ensureEnum, brushToString, stringToBrush, ensureBool, initializePropertiesFromCss, NamePatcher, isValidProp, toSpinal, getModifiedProps } from "igniteui-react-core"; import { FontInfo } from "igniteui-react-core"; import { ReactRenderer } from "igniteui-react-core"; import { delegateCombine, delegateRemove } from "igniteui-react-core"; import { SyncableObservableCollection$1 } from "igniteui-react-core"; import { CheckboxList } from './CheckboxList'; import { IgrDataGrid } from "./igr-data-grid"; import { IgrCheckedChangedEventArgs } from "./igr-checked-changed-event-args"; import { IgrSelectAllCheckboxChangedEventArgs } from "./igr-select-all-checkbox-changed-event-args"; import { PrimaryKeyValue } from "./PrimaryKeyValue"; import { IgrGridSelectedKeysCollection } from "./igr-grid-selected-keys-collection"; import { GridSelectedKeysCollection as GridSelectedKeysCollection_internal } from "./GridSelectedKeysCollection"; import { CheckboxListIndexType_$type } from "./CheckboxListIndexType"; import { InputGroupDisplayType_$type } from "igniteui-react-inputs"; import { BaseControlTheme_$type } from "igniteui-react-core"; import { ControlDisplayDensity_$type } from "igniteui-react-core"; import { ScrollbarStyle_$type } from "igniteui-react-core"; import { IgrCheckboxListIndexTypeChangedEventArgs } from './igr-checkbox-list-index-type-changed-event-args'; import { IgrCheckboxListKeysClearedEventArgs } from './igr-checkbox-list-keys-cleared-event-args'; var IgrCheckboxList = /** @class */ /*@__PURE__*/ (function (_super) { __extends(IgrCheckboxList, _super); function IgrCheckboxList(props) { var _this = _super.call(this, props) || this; _this._dataSource = null; _this._wrapper = null; _this._implementation = null; _this._keys = null; _this.__p = null; _this._hasUserValues = new Set(); _this._stylingContainer = null; _this._stylingParent = null; _this._inStyling = false; _this._selectedKeyAdded = null; _this._selectedKeyAdded_wrapped = null; _this._selectedKeyRemoved = null; _this._selectedKeyRemoved_wrapped = null; _this._checkedChanged = null; _this._checkedChanged_wrapped = null; _this._labelClicked = null; _this._labelClicked_wrapped = null; _this._indexTypeChanged = null; _this._indexTypeChanged_wrapped = null; _this._keysCleared = null; _this._keysCleared_wrapped = null; _this._selectAllCheckboxChanged = null; _this._selectAllCheckboxChanged_wrapped = null; if (_this._styling) { NamePatcher.ensureStylablePatched(Object.getPrototypeOf(_this)); } _this._getMainRef = _this._getMainRef.bind(_this); _this._getGridRef = _this._getGridRef.bind(_this); _this._getSelectAllSection = _this._getSelectAllSection.bind(_this); _this._getFilterHr = _this._getFilterHr.bind(_this); _this._implementation = _this.createImplementation(); var checkboxList = _this.i; _this._checkboxList = checkboxList; checkboxList.notifySizeChanged(); if (props) { _this.initializeProperties(); } return _this; } Object.defineProperty(IgrCheckboxList.prototype, "height", { get: function () { return this._height; }, set: function (value) { this._height = value; if (this._elRef) { this._elRef.style.height = value; this._checkboxList.notifySizeChanged(); } }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "width", { get: function () { return this._width; }, set: function (value) { this._width = value; if (this._elRef) { this._elRef.style.height = value; this._checkboxList.notifySizeChanged(); } }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "dataSource", { get: function () { return this._dataSource; }, set: function (value) { this._dataSource = value; if (this._checkboxList != null) { this._checkboxList.itemsSource = this._dataSource; } }, enumerable: false, configurable: true }); IgrCheckboxList.prototype._getMainRef = function (ref) { this._elRef = ref; this.verifyReferences(); }; IgrCheckboxList.prototype._getGridRef = function (ref) { this._gridRef = ref; this.verifyReferences(); }; IgrCheckboxList.prototype._getSelectAllSection = function (ref) { this._selectAllSectionRef = ref; this.verifyReferences(); }; IgrCheckboxList.prototype._getFilterHr = function (ref) { this._filterHrRef = ref; this.verifyReferences(); }; IgrCheckboxList.prototype.verifyReferences = function () { if (this._elRef != null && this._gridRef != null && this._filterHrRef != null && this._selectAllSectionRef != null) { this._renderer = new ReactRenderer(this._elRef, document, false, null); var selectAllSectionWrapper = this._renderer.getWrapper(this._selectAllSectionRef); this._checkboxList.provideContainer(this._renderer, this._gridRef.i, selectAllSectionWrapper); var filterHr = this._renderer.getWrapper(this._filterHrRef); filterHr.setStyleProperty("margin", "3px 0px"); filterHr.setStyleProperty("border-top", "1px solid #dde2eb"); filterHr.setStyleProperty("border-left", "0px"); filterHr.setStyleProperty("border-right", "0px"); filterHr.setStyleProperty("border-bottom", "0px"); this._checkboxList.provideHrElement(filterHr); } }; IgrCheckboxList.prototype.render = function () { var children = []; //let filterContainerChildren: any[] = []; var filterContainer = React.createElement("div", { key: "filterContainer" //children: filterContainerChildren }); children.push(filterContainer); var filterHr = React.createElement("hr", { ref: this._getFilterHr, key: "filterHr" //children: filterContainerChildren }); children.push(filterHr); /*let filter = React.createElement("input", { ref: this._getFilterRef, type: "text", key: "checkboxListFilterInput" }); filterContainerChildren.push(filter);*/ var selectAllSection = React.createElement("div", { ref: this._getSelectAllSection, key: "selectAllSection" }); children.push(selectAllSection); var grid = React.createElement(IgrDataGrid, { ref: this._getGridRef, key: "checkboxListGrid", headerHeight: 0 }); children.push(grid); var div = React.createElement("div", { className: "ig-checkbox-list igr-checkbox-list", ref: this._getMainRef, children: children }); return div; }; IgrCheckboxList.prototype.shouldComponentUpdate = function (nextProps, nextState) { var e_1, _a; var mod = getModifiedProps(this.props, nextProps); try { for (var _b = __values(Object.keys(mod)), _c = _b.next(); !_c.done; _c = _b.next()) { var p = _c.value; if (isValidProp(this, p)) { this[p] = mod[p]; } } } catch (e_1_1) { e_1 = { error: e_1_1 }; } finally { try { if (_c && !_c.done && (_a = _b.return)) _a.call(_b); } finally { if (e_1) throw e_1.error; } } return true; }; IgrCheckboxList.prototype.initializeProperties = function () { var e_2, _a; try { for (var _b = __values(Object.keys(this.props)), _c = _b.next(); !_c.done; _c = _b.next()) { var p = _c.value; if (isValidProp(this, p)) { this[p] = this.props[p]; } } } catch (e_2_1) { e_2 = { error: e_2_1 }; } finally { try { if (_c && !_c.done && (_a = _b.return)) _a.call(_b); } finally { if (e_2) throw e_2.error; } } }; // supports angular themes or custom properties set in CSS IgrCheckboxList.prototype.updateStyle = function () { this._styling(this._elRef, this); }; IgrCheckboxList.prototype.destroy = function () { if (this._checkboxList) this._checkboxList.destroy(); if (this._renderer) this._renderer.destroy(); }; IgrCheckboxList.prototype.componentWillUnmount = function () { }; IgrCheckboxList.prototype.componentDidMount = function () { this._elRef.style.width = this._width ? this._width : ""; this._elRef.style.height = this._height ? this._height : ""; this._checkboxList.notifySizeChanged(); this.initializeContent(); }; IgrCheckboxList.prototype.initializeContent = function () { this.updateStyle(); this.i.notifySizeChanged(); }; IgrCheckboxList.prototype.createImplementation = function () { return new CheckboxList(); }; Object.defineProperty(IgrCheckboxList.prototype, "i", { get: function () { return this._implementation; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "keys", { /** * Gets the collection responsible for selection in the CheckboxList. Selection is determined by two factors: * whether everything is selected or deselected and the values present in this collection. If everything is * selected then any items in this collection will be deselected. If everything is deselected then any items in * this collection will be selected. The CheckboxList defaults all items as deselected. This state can change * when you use the SelectAll and DeselectAll methods. */ get: function () { if (this._keys === null) { var coll = new IgrGridSelectedKeysCollection(); var innerColl = this.i.keys; if (!innerColl) { innerColl = new GridSelectedKeysCollection_internal(); } this._keys = coll._fromInner(innerColl); } return this._keys; }, set: function (v) { if (this._keys !== null) { this._keys._setSyncTarget(null); this._keys = null; } var coll = new IgrGridSelectedKeysCollection(); this._keys = coll._fromOuter(v); var syncColl = new SyncableObservableCollection$1(PrimaryKeyValue.$type); var innerColl = this.i.keys; if (!innerColl) { innerColl = new GridSelectedKeysCollection_internal(); } syncColl._inner = innerColl; syncColl.clear(); this._keys._setSyncTarget(syncColl); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "primaryKey", { /** * Gets or sets the primary key to use for the CheckboxList. */ get: function () { return this.i.primaryKey; }, set: function (v) { if (v && !Array.isArray(v) && typeof (v) == "string") { var re = /\s*(?:,|\s|$)\s*/gm; v = v.split(re); } this.i.primaryKey = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "dataMemberPath", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.dataMemberPath; }, set: function (v) { this.i.dataMemberPath = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "dataLegendTarget", { get: function () { return this.i.bh; }, set: function (v) { this.i.bh = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "subtitleMemberPath", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.cw; }, set: function (v) { this.i.cw = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "propertyTypeMemberPath", { get: function () { return this.i.cb; }, set: function (v) { this.i.cb = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "selectedMemberPath", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.selectedMemberPath; }, set: function (v) { this.i.selectedMemberPath = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "filterPlaceholderText", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.b4; }, set: function (v) { this.i.b4 = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "searchInputType", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.y; }, set: function (v) { this.i.y = ensureEnum(InputGroupDisplayType_$type, v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "rowHeight", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.be; }, set: function (v) { this.i.be = +v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "actualRowHeight", { get: function () { return this.i.bc; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "cellTextStyle", { /** * Gets or Sets the property name that contains the values. */ get: function () { if (this.i.am == null) { return null; } return this.i.am.fontString; }, set: function (v) { var fi = new FontInfo(); fi.fontString = v; this.i.am = fi; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "indexType", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.indexType; }, set: function (v) { this.i.indexType = ensureEnum(CheckboxListIndexType_$type, v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "baseTheme", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.baseTheme; }, set: function (v) { this.i.baseTheme = ensureEnum(BaseControlTheme_$type, v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "density", { /** * Gets or Sets the property name that contains the values. */ get: function () { return this.i.density; }, set: function (v) { this.i.density = ensureEnum(ControlDisplayDensity_$type, v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "searchIconColor", { /** * Gets or sets the search icon color. */ get: function () { return brushToString(this.i.searchIconColor); }, set: function (v) { this.i.searchIconColor = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "searchBackgroundColor", { /** * Gets or sets the search background color. */ get: function () { return brushToString(this.i.e1); }, set: function (v) { this.i.e1 = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "labelClickTriggersChange", { /** * Gets or sets the search background color. */ get: function () { return this.i.a1; }, set: function (v) { this.i.a1 = ensureBool(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "searchTextColor", { /** * Gets or sets the search text color. */ get: function () { return brushToString(this.i.searchTextColor); }, set: function (v) { this.i.searchTextColor = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "searchBorderColor", { /** * Gets or sets the search border color. */ get: function () { return brushToString(this.i.e2); }, set: function (v) { this.i.e2 = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "searchTextStyle", { /** * Gets or sets the text style. */ get: function () { if (this.i.an == null) { return null; } return this.i.an.fontString; }, set: function (v) { var fi = new FontInfo(); fi.fontString = v; this.i.an = fi; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkboxTickColor", { /** * Gets or sets the checkbox tick color. */ get: function () { return brushToString(this.i.et); }, set: function (v) { this.i.et = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkboxCheckedBackgroundColor", { /** * Gets or sets the checkbox background color when checked. */ get: function () { return brushToString(this.i.er); }, set: function (v) { this.i.er = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkboxUncheckedBackgroundColor", { /** * Gets or sets the checkbox background color when unchecked. */ get: function () { return brushToString(this.i.eu); }, set: function (v) { this.i.eu = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkboxCheckedBorderColor", { /** * Gets or sets the checkbox border color when checked. */ get: function () { return brushToString(this.i.es); }, set: function (v) { this.i.es = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkboxUncheckedBorderColor", { /** * Gets or sets the checkbox border color when unchecked. */ get: function () { return brushToString(this.i.ev); }, set: function (v) { this.i.ev = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkboxCornerRadius", { /** * Gets or sets the corner radius to use for the checkbox. */ get: function () { return this.i.a7; }, set: function (v) { this.i.a7 = +v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "scrollbarStyle", { /** * Gets or sets the style of scrollbar. */ get: function () { return this.i.ab; }, set: function (v) { this.i.ab = ensureEnum(ScrollbarStyle_$type, v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "scrollbarBackground", { /** * Gets or sets the scrollbar background color. */ get: function () { return brushToString(this.i.e0); }, set: function (v) { this.i.e0 = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "selectAllCaption", { /** * Gets / sets the caption of the "Select All" checkbox. */ get: function () { return this.i.cp; }, set: function (v) { this.i.cp = v; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "selectAllCaptionTextColor", { /** * Gets or sets the color to use for the "Select All" label. */ get: function () { return brushToString(this.i.e5); }, set: function (v) { this.i.e5 = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "actualSelectAllCaptionTextColor", { /** * Gets or sets the color to use for the actual header selectAllCaption text. */ get: function () { return brushToString(this.i.ep); }, set: function (v) { this.i.ep = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "showSelectAll", { /** * Gets / sets whether the "Select all" checkbox is visible. */ get: function () { return this.i.showSelectAll; }, set: function (v) { this.i.showSelectAll = ensureBool(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "backgroundColor", { /** * Gets or sets the color to use for the background of the component. */ get: function () { return brushToString(this.i.backgroundColor); }, set: function (v) { this.i.backgroundColor = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "rowHoverBackgroundColor", { /** * Gets or sets the color to use when hovering over a grid row. */ get: function () { return brushToString(this.i.rowHoverBackgroundColor); }, set: function (v) { this.i.rowHoverBackgroundColor = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "textColor", { /** * Gets or sets the color to use for the text of the component. */ get: function () { return brushToString(this.i.e7); }, set: function (v) { this.i.e7 = stringToBrush(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "showFilter", { /** * Gets or sets whether the filter input is visible. */ get: function () { return this.i.a3; }, set: function (v) { this.i.a3 = ensureBool(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "isRowHoverEnabled", { /** * Gets or sets whether row hover highlighting is enabled. */ get: function () { return this.i.az; }, set: function (v) { this.i.az = ensureBool(v); }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkboxAlignedRight", { /** * Gets or sets whether checkbox should be displayed to the right. */ get: function () { return this.i.av; }, set: function (v) { this.i.av = ensureBool(v); }, enumerable: false, configurable: true }); IgrCheckboxList.prototype.findByName = function (name) { if (this.findEphemera) { if (name && name.indexOf("@@e:") == 0) { return this.findEphemera(name); } } if (this.keys != null && this.keys.findByName && this.keys.findByName(name)) { return this.keys.findByName(name); } return null; }; Object.defineProperty(IgrCheckboxList.prototype, "hasUserValues", { get: function () { return this._hasUserValues; }, enumerable: false, configurable: true }); IgrCheckboxList.prototype.__m = function (propertyName) { if (!this._inStyling) { this._hasUserValues.add(propertyName); } }; IgrCheckboxList.prototype._styling = function (container, component, parent) { if (this._inStyling) { return; } this._inStyling = true; this._stylingContainer = container; this._stylingParent = component; var genericPrefix = ""; var typeName = this.i.$type.name; if (typeName.indexOf("Xam") === 0) { typeName = typeName.substring(3); } genericPrefix = toSpinal("CheckboxList"); var additionalPrefixes = []; var prefix = toSpinal(typeName); additionalPrefixes.push(prefix + "-"); var b = this.i.$type.baseType; while (b && b.name != "Object" && b.name != "Base" && b.name != "Control" && b.Name != "DependencyObject" && b.Name != "FrameworkElement") { typeName = b.name; if (typeName.indexOf("Xam") === 0) { typeName = typeName.substring(3); } var basePrefix = toSpinal(typeName); additionalPrefixes.push(basePrefix + "-"); b = b.baseType; } if (parent) { var parentTypeName = parent.i.$type.name; if (parentTypeName.indexOf("Xam") === 0) { parentTypeName = parentTypeName.substring(3); } var parentPrefix = toSpinal(parentTypeName); additionalPrefixes.push(parentPrefix + "-" + genericPrefix + "-"); additionalPrefixes.push(parentPrefix + "-" + prefix + "-"); } initializePropertiesFromCss(container, this, genericPrefix + "-", this.hasUserValues, false, additionalPrefixes); if (this._otherStyling) { this._otherStyling(container, component, parent); } this._inStyling = false; }; /** * selects all the items in the checkbox list. */ IgrCheckboxList.prototype.selectAll = function () { this.i.d3(); }; /** * Deselects all the items in the checkbox list. */ IgrCheckboxList.prototype.deselectAll = function () { this.i.c5(); }; IgrCheckboxList.prototype.notifySetItem = function (index, oldItem, newItem) { this.i.dg(index, oldItem, newItem); }; /** * Manually notifies the checkboxlist's grid that the data it has bound to has been cleared and needs to be re-examined. * This should not be called if the data that the grid is bound to is already observable. */ IgrCheckboxList.prototype.notifyClearItems = function () { this.i.dc(); }; IgrCheckboxList.prototype.notifyInsertItem = function (index, newItem) { this.i.dd(index, newItem); }; IgrCheckboxList.prototype.notifyRemoveItem = function (index, oldItem) { this.i.df(index, oldItem); }; IgrCheckboxList.prototype.refresh = function () { this.i.refresh(); }; IgrCheckboxList.prototype.addKeyValue = function (value) { this.i.c0(value); }; IgrCheckboxList.prototype.removeKeyValue = function (value) { this.i.d1(value); }; IgrCheckboxList.prototype.getDesiredSize = function (availableSize) { var iv = this.i.getDesiredSize(toSize(availableSize)); return fromSize(iv); }; /** * Returns true if no items are selected / checked; otherwise false. */ IgrCheckboxList.prototype.isNothingSelected = function () { var iv = this.i.ax(); return (iv); }; /** * Returns true if all of the items are selected / checked; otherwise false. */ IgrCheckboxList.prototype.isEverythingSelected = function () { var iv = this.i.aw(); return (iv); }; Object.defineProperty(IgrCheckboxList.prototype, "selectedKeyAdded", { /** * Called when an item is added. */ get: function () { return this._selectedKeyAdded; }, set: function (ev) { var _this = this; if (this._selectedKeyAdded_wrapped !== null) { this.i.selectedKeyAdded = delegateRemove(this.i.selectedKeyAdded, this._selectedKeyAdded_wrapped); this._selectedKeyAdded_wrapped = null; this._selectedKeyAdded = null; } this._selectedKeyAdded = ev; this._selectedKeyAdded_wrapped = function (o, e) { var outerArgs = new IgrCheckedChangedEventArgs(); outerArgs._provideImplementation(e); if (_this.beforeSelectedKeyAdded) { _this.beforeSelectedKeyAdded(_this, outerArgs); } if (_this._selectedKeyAdded) { _this._selectedKeyAdded(_this, outerArgs); } }; this.i.selectedKeyAdded = delegateCombine(this.i.selectedKeyAdded, this._selectedKeyAdded_wrapped); ; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "selectedKeyRemoved", { /** * Called when an item is removed. */ get: function () { return this._selectedKeyRemoved; }, set: function (ev) { var _this = this; if (this._selectedKeyRemoved_wrapped !== null) { this.i.selectedKeyRemoved = delegateRemove(this.i.selectedKeyRemoved, this._selectedKeyRemoved_wrapped); this._selectedKeyRemoved_wrapped = null; this._selectedKeyRemoved = null; } this._selectedKeyRemoved = ev; this._selectedKeyRemoved_wrapped = function (o, e) { var outerArgs = new IgrCheckedChangedEventArgs(); outerArgs._provideImplementation(e); if (_this.beforeSelectedKeyRemoved) { _this.beforeSelectedKeyRemoved(_this, outerArgs); } if (_this._selectedKeyRemoved) { _this._selectedKeyRemoved(_this, outerArgs); } }; this.i.selectedKeyRemoved = delegateCombine(this.i.selectedKeyRemoved, this._selectedKeyRemoved_wrapped); ; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "checkedChanged", { /** * Called when a checkbox is checked or unchecked. */ get: function () { return this._checkedChanged; }, set: function (ev) { var _this = this; if (this._checkedChanged_wrapped !== null) { this.i.checkedChanged = delegateRemove(this.i.checkedChanged, this._checkedChanged_wrapped); this._checkedChanged_wrapped = null; this._checkedChanged = null; } this._checkedChanged = ev; this._checkedChanged_wrapped = function (o, e) { var outerArgs = new IgrCheckedChangedEventArgs(); outerArgs._provideImplementation(e); if (_this.beforeCheckedChanged) { _this.beforeCheckedChanged(_this, outerArgs); } if (_this._checkedChanged) { _this._checkedChanged(_this, outerArgs); } }; this.i.checkedChanged = delegateCombine(this.i.checkedChanged, this._checkedChanged_wrapped); ; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "labelClicked", { get: function () { return this._labelClicked; }, set: function (ev) { var _this = this; if (this._labelClicked_wrapped !== null) { this.i.labelClicked = delegateRemove(this.i.labelClicked, this._labelClicked_wrapped); this._labelClicked_wrapped = null; this._labelClicked = null; } this._labelClicked = ev; this._labelClicked_wrapped = function (o, e) { var outerArgs = new IgrCheckedChangedEventArgs(); outerArgs._provideImplementation(e); if (_this.beforeLabelClicked) { _this.beforeLabelClicked(_this, outerArgs); } if (_this._labelClicked) { _this._labelClicked(_this, outerArgs); } }; this.i.labelClicked = delegateCombine(this.i.labelClicked, this._labelClicked_wrapped); ; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "indexTypeChanged", { get: function () { return this._indexTypeChanged; }, set: function (ev) { var _this = this; if (this._indexTypeChanged_wrapped !== null) { this.i.indexTypeChanged = delegateRemove(this.i.indexTypeChanged, this._indexTypeChanged_wrapped); this._indexTypeChanged_wrapped = null; this._indexTypeChanged = null; } this._indexTypeChanged = ev; this._indexTypeChanged_wrapped = function (o, e) { var outerArgs = new IgrCheckboxListIndexTypeChangedEventArgs(); outerArgs._provideImplementation(e); if (_this.beforeIndexTypeChanged) { _this.beforeIndexTypeChanged(_this, outerArgs); } if (_this._indexTypeChanged) { _this._indexTypeChanged(_this, outerArgs); } }; this.i.indexTypeChanged = delegateCombine(this.i.indexTypeChanged, this._indexTypeChanged_wrapped); ; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "keysCleared", { get: function () { return this._keysCleared; }, set: function (ev) { var _this = this; if (this._keysCleared_wrapped !== null) { this.i.keysCleared = delegateRemove(this.i.keysCleared, this._keysCleared_wrapped); this._keysCleared_wrapped = null; this._keysCleared = null; } this._keysCleared = ev; this._keysCleared_wrapped = function (o, e) { var outerArgs = new IgrCheckboxListKeysClearedEventArgs(); outerArgs._provideImplementation(e); if (_this.beforeKeysCleared) { _this.beforeKeysCleared(_this, outerArgs); } if (_this._keysCleared) { _this._keysCleared(_this, outerArgs); } }; this.i.keysCleared = delegateCombine(this.i.keysCleared, this._keysCleared_wrapped); ; }, enumerable: false, configurable: true }); Object.defineProperty(IgrCheckboxList.prototype, "selectAllCheckboxChanged", { /** * Called when the SelectAll checkbox is checked or unchecked. */ get: function () { return this._selectAllCheckboxChanged; }, set: function (ev) { var _this = this; if (this._selectAllCheckboxChanged_wrapped !== null) { this.i.selectAllCheckboxChanged = delegateRemove(this.i.selectAllCheckboxChanged, this._selectAllCheckboxChanged_wrapped); this._selectAllCheckboxChanged_wrapped = null; this._selectAllCheckboxChanged = null; } this._selectAllCheckboxChanged = ev; this._selectAllCheckboxChanged_wrapped = function (o, e) { var outerArgs = new IgrSelectAllCheckboxChangedEventArgs(); outerArgs._provideImplementation(e); if (_this.beforeSelectAllCheckboxChanged) { _this.beforeSelectAllCheckboxChanged(_this, outerArgs); } if (_this._selectAllCheckboxChanged) { _this._selectAllCheckboxChanged(_this, outerArgs); } }; this.i.selectAllCheckboxChanged = delegateCombine(this.i.selectAllCheckboxChanged, this._selectAllCheckboxChanged_wrapped); ; }, enumerable: false, configurable: true }); return IgrCheckboxList; }(React.Component)); export { IgrCheckboxList };