import { TickCodes, TickFields } from "./TickCodes.js"; import { rgb2Hex, num2Hex, num2Rgb, hex2Num, hex2Rgb, blendColor, getContrastColor } from "./Color.js"; import { ElfUtil } from "./ElfUtil.js"; import { ExpressionParser } from "./ExpressionParser.js"; declare namespace CellPainter { type Expression = { name?: string|null, text: string, values?: any[]|null }; type Condition = { expression: string|((...params: any[]) => any)|null, field?: string|null, backgroundColor?: string|null, color?: string|null, fontSize?: string|null, fontWeight?: string|null, fontStyle?: string|null, textAlign?: string|null, textDecoration?: string|null, cssClass?: string|null }; type ThemeColors = { baseGrid?: string|null, baseText?: string|null, up?: string|null, down?: string|null, level?: string|null, tickUp?: string|null, tickDown?: string|null }; enum ColoringTypes { TEXT = 1, HEATMAP = 2, CONDITIONAL = 3 } } declare class CellPainter { constructor(); public static readonly themeReady: Promise|null; public static parse(expression: string|((...params: any[]) => any)|null): ((...params: any[]) => any)|null; public dispose(): void; public reset(): void; public resetColoring(): void; public clearBlinking(): void; public clearHeatMap(): boolean; public applyThemeColor(): void; public getConditions(): (any)[]|null; public getColoringType(): CellPainter.ColoringTypes|null; public setEffectiveStyles(mapping: any): void; public getEffectiveStyles(): any; public setConditions(conditions: (CellPainter.Condition)[]|null): void; public setColumnStats(columnStats: any): void; public getColumnStats(): any; public addHeatmap(field: string, midPoint: number, upColor: string, downColor: string, baseColor: string, opt_textMode?: (string|boolean)|null): any; public addHeatmapWithTheme(field: string, midPoint: number, opt_textMode?: (string|boolean)|null): any; public addColorText(field: string, upClass?: string|null, downClass?: string|null, levelClass?: string|null): any; public addColorTextWithTheme(field: string): any; public addTickColorText(upColor: string, downColor: string, levelColor: string): any; public addTickColorTextWithTheme(): any; public addTickBlink(upColor: string, downColor: string, levelColor: string, opt_border?: (string|boolean)|null): any; public addTickBlinkWithTheme(opt_border?: (string|boolean)|null): any; public addBlink(field: string, upColor: string, downColor: string, levelColor: string, opt_border?: (string|boolean)|null): any; public addBlinkWithTheme(field: string, opt_border?: (string|boolean)|null): any; public renderForPrinting(cell: Element|null, rowData: any, min: number, max: number): void; public static blendColor(baseColor: string, maxColor: string, ratio: number): (number)[]|null; public static rgb2Hex(rgbCode: string): string; public static num2Hex(triplet: (number)[]|null): string; public static num2Rgb(triplet: (number)[]|null): string; public static hex2Num(hex: string): (number)[]|null; public static hex2Rgb(hex: string): string; public static setThemeColors(): void; public static loadThemeColors(): Promise|null; public static reloadThemeColors(): Promise|null; public static getOppositeColor(hexCode: string|(number)[]|null): string; public render(cell: any, rowData: any, min: number, max: number): void; public renderHeatMap(cell: any, rowData: any, min: number, max: number): void; public renderColoring(cell: any, rowData: any): void; public blink(cell: any, blinkSignal: number, rowData: any): boolean; public flash(cell: any, blinkColor: string|null|null, rowData: any): boolean; public blinkCell(cell: any, newValue: number, oldValue: number, rowData: any): boolean; public verifyBlinking(cell: any, rowData: any): void; public disableLevelColor(disabled?: boolean|null): void; public setBlinkingDuration(duration: number): void; } export default CellPainter; export {CellPainter};