igniteui-react-grids
Version:
Ignite UI React grid components.
62 lines (61 loc) • 2.49 kB
JavaScript
/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { __extends } from "tslib";
import { GridCellBase } from "./GridCellBase";
import { TemplateCellContainer } from "./TemplateCellContainer";
import { runOn, markType } from "igniteui-react-core";
import { BaseDOMEventProxy } from "igniteui-react-core";
/**
* @hidden
*/
var TemplateCell = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(TemplateCell, _super);
function TemplateCell(a) {
var _this = _super.call(this, a) || this;
_this.ck = null;
_this.ck = new TemplateCellContainer(a);
_this.ck.element.setRawStyleProperty("box-sizing", "border-box");
_this.ah.append(_this.ck.element);
_this.ah.listen("keydown", runOn(_this, _this.cm));
return _this;
}
Object.defineProperty(TemplateCell.prototype, "cl", {
get: function () {
return this.ck;
},
enumerable: false,
configurable: true
});
TemplateCell.prototype.get_z = function () {
return true;
};
TemplateCell.prototype.bs = function (a, b, c) {
_super.prototype.bs.call(this, a, b, c);
if (a == "Indent" || a == "IsCollapsable") {
this.ck.element.setRawStyleProperty("margin-left", this.a3 + this.a5 + this.a4 + "px");
}
};
TemplateCell.prototype.bh = function () {
var a = this.ck.element.getNativeElement();
if (a.contains(document.activeElement)) {
return;
}
_super.prototype.bh.call(this);
};
TemplateCell.prototype.cm = function (a) {
var b = this.ck.element.getNativeElement();
if (b.contains(document.activeElement) && document.activeElement.nodeName == "INPUT") {
var c = BaseDOMEventProxy.c0(a);
if (c == 14 || c == 16) {
a.stopPropagation();
}
}
};
TemplateCell.$t = markType(TemplateCell, 'TemplateCell', GridCellBase.$);
return TemplateCell;
}(GridCellBase));
export { TemplateCell };