igniteui-react-grids
Version:
Ignite UI React grid components.
101 lines (100 loc) • 3.41 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 { Base, markType } from "igniteui-react-core";
import { ICellPresenter_$type } from "./ICellPresenter";
import { CellModel } from "./CellModel";
import { BrushUtil } from "igniteui-react-core";
/**
* @hidden
*/
export let CellPresenterBase = /*@__PURE__*/ (() => {
class CellPresenterBase extends Base {
constructor(a) {
super();
this.a = null;
this.a = a;
}
modelUpdated(a) {
this.b(a);
}
b(a) {
this.a.bz(a.c);
this.a.b5(a.e);
this.a.b2(a.d);
this.a.br();
if (a.a8(CellModel.f8)) {
this.a.y = a.bd;
}
if (a.a8(CellModel.em) || a.a8(CellModel.eq) || a.a8(CellModel.eo) || a.a8(CellModel.ek)) {
this.a.b7(a.el, a.ep, a.en, a.ej);
}
if (a.a1) {
this.a.b1(a.lv, a.d9, a.ee, a.ec, a.d7);
if (a.a8(CellModel.d5)) {
if (!a.bf && a.p.ix && a.bc && a.cf == 1) {
this.a.bh();
}
}
}
if (a.bo) {
this.a.b3(a.fu, (a.ep + a.ej + a.ee + a.d7));
this.a.b9(a.hd, (a.el + a.en + a.d9 + a.ec));
}
if (a.a3) {
if (a.bi && !this.a.u) {
this.a.bg();
}
if (a.a8(CellModel.d6)) {
this.a.b0(a.lu.color);
}
if (a.a8(CellModel.ei)) {
this.a.b6(a.ch);
}
if (a.a7("IsCollapsable")) {
this.a.v = a.a2;
this.a.a6 = a.f0;
this.a.w = a.ba;
this.a.b9(a.hd, (a.el + a.en + a.d9 + a.ec));
}
if (a.a7("Indent")) {
this.a.a6 = a.f0;
this.a.b9(a.hd, (a.el + a.en + a.d9 + a.ec));
}
if (a.a7("IsExpanded")) {
this.a.w = a.ba;
}
}
if (a.bo && a.bi) {
this.a.ch(a);
}
if (a.a7("DoClone")) {
if (a.ax) {
a.ax = false;
this.a.bf();
}
}
}
c(a, b, c) {
if (c == 0) {
return a.color;
}
if (c == 1) {
return b.color;
}
let d = BrushUtil.l(a, c, b, 0);
return d.color;
}
get nativeCell() {
return this.a;
}
get isCanvasBased() {
return false;
}
}
CellPresenterBase.$t = /*@__PURE__*/ markType(CellPresenterBase, 'CellPresenterBase', Base.$, [ICellPresenter_$type]);
return CellPresenterBase;
})();