modern_spreadsheet/dist/modules/cell.d.ts

56 lines
1.6 KiB
TypeScript
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import Spreadsheet from "../main";
export type CellConstructorProps = {
value: string;
displayValue: string;
resultValue: string;
position: Position;
style: CellStyles | null;
};
interface CellStylesConstructorProps {
fontSize: number;
fontColor: string;
background: string;
borderColor: string;
selectedBackground: string;
selectedFontColor: string;
}
export declare class CellStyles {
fontSize: number;
fontColor: string;
background: string;
borderColor: string;
selectedBackground: string;
selectedFontColor: string;
constructor(props?: CellStylesConstructorProps);
}
export declare class Position {
row: number;
column: number;
constructor(row: number, column: number);
}
export declare class SerializableCell {
value: string;
displayValue: string;
resultValue: string;
position: Position;
style: CellStyles | null;
constructor(props: SerializableCell | SerializableCell);
}
export declare class Cell {
/** True value (data) */
value: string;
/** Value to render */
displayValue: string;
/** This refers to the values that were obtained by calculations, for example, after calculating the formula */
resultValue: string;
position: Position;
style: CellStyles | null;
constructor(props: CellConstructorProps);
getSerializableCell(): SerializableCell;
changeStyles(styles: CellStyles): void;
changeValues(values: Partial<Omit<CellConstructorProps, 'position'>>): void;
private isCellInRange;
render(root: Spreadsheet): void;
}
export {};