import { BasePlugin } from './base.plugin';
import type { DimensionCols, ColumnRegular, DataType, BeforeSaveDataDetails, BeforeRangeSaveDataDetails, PluginProviders } from "../types/index";
interface Column extends ColumnRegular {
    index: number;
}
type AutoSizeColumns = Record<DimensionCols, ColumnRecords>;
type ColumnRecords = Record<any, Column>;
type EditEvent = BeforeSaveDataDetails | BeforeRangeSaveDataDetails;
type Resolve = (cols: Partial<AutoSizeColumns>) => void;
type Reject = () => void;
export type AutoSizeColumnConfig = {
    mode?: ColumnAutoSizeMode;
    /**
     * autoSize for all columns
     * if allColumnes true all columns treated as autoSize, worse for performance
     * false by default
     */
    allColumns?: boolean;
    /**
     * assumption per characted size
     * by default defined as 8, can be changed in this config
     */
    letterBlockSize?: number;
    /** make size calculation exact
     * by default it based on assumption each character takes some space defined in letterBlockSize */
    preciseSize?: boolean;
};
export declare enum ColumnAutoSizeMode {
    headerClickAutosize = "headerClickAutoSize",
    autoSizeOnTextOverlap = "autoSizeOnTextOverlap",
    autoSizeAll = "autoSizeAll"
}
export declare class AutoSizeColumnPlugin extends BasePlugin {
    providers: PluginProviders;
    config?: AutoSizeColumnConfig | undefined;
    autoSizeColumns: Partial<AutoSizeColumns> | null;
    readonly letterBlockSize: number;
    /** for config option when preciseSize enabled */
    readonly precsizeCalculationArea: HTMLElement;
    /** for edge case when no columns defined before data */
    dataResolve: Resolve | null;
    dataReject: Reject | null;
    constructor(revogrid: HTMLRevoGridElement, providers: PluginProviders, config?: AutoSizeColumnConfig | undefined);
    setSource(source: DataType[]): Promise<void>;
    getLength(len?: any): number;
    afteredit(e: EditEvent): void;
    afterEditAll(e: EditEvent): void;
    getColumnSize(index: number, type: DimensionCols): number;
    columnSet(columns: Record<DimensionCols, ColumnRegular[]>): void;
    clearPromise(): void;
    isRangeEdit(e: EditEvent): e is BeforeRangeSaveDataDetails;
    initiatePresizeElement(): HTMLElement;
    destroy(): void;
}
export {};
