igniteui-react-grids
Version:
Ignite UI React grid components.
82 lines (81 loc) • 3.09 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 { Color } from "igniteui-react-core";
import { CellModel } from "./CellModel";
import { FontUtil } from "igniteui-react-core";
/**
* @hidden
*/
export let CanvasContentCellModelHelper = /*@__PURE__*/ (() => {
class CanvasContentCellModelHelper extends Base {
static e(a) {
if (a == null) {
return CanvasContentCellModelHelper.d;
}
return a.color;
}
static a(a, b, c) {
if (b.a3) {
if (b.a8(CellModel.fa) || b.a8(CellModel.eg) || b.a8(CellModel.hc) || b.a7("IsRowPinned") || b.a7("IsRowSticky") || b.a7("PinnedRowOpacity")) {
let d = Math.min(1, Math.max(0, b.ct));
let e = b.cg * (1 - d);
c.ci(e);
if (b.bi) {
c.cy(b.cg * d);
}
}
if (b.a8(CellModel.er)) {
CanvasContentCellModelHelper.c(c, b.lw);
if (b.bi) {
c.cw(b.lw);
}
}
if (b.a8(CellModel.gg)) {
}
if (b.a8(CellModel.fw) || b.a8(CellModel.hb)) {
let f = b.g;
let g = b.i;
c.cl(f);
c.ct(g);
if (b.bi) {
c.cv(f, g);
}
}
if (b.a7("ActualFontInfo")) {
CanvasContentCellModelHelper.b(a, c, b.ag);
}
if (b.a7("IsEdited") || b.a7("IsDeleted")) {
if (b.a9 || b.a6) {
if (b.a6) {
c.cq(true);
}
else {
c.cq(false);
}
}
else {
c.cq(false);
}
}
}
}
static b(a, b, c) {
if (c == null) {
c = FontUtil.getDefaultFont(a);
}
b.cj(c);
}
static c(a, b) {
let c = CanvasContentCellModelHelper.e(b);
a.cs(c);
}
}
CanvasContentCellModelHelper.$t = /*@__PURE__*/ markType(CanvasContentCellModelHelper, 'CanvasContentCellModelHelper');
CanvasContentCellModelHelper.d = /*@__PURE__*/ Color.u(0, 0, 0, 0);
return CanvasContentCellModelHelper;
})();