import type { default as MetaManagerInstance } from '..'; /** * @class DynamicCellMetaMod * * The `DynamicCellMetaMod` modifier allows for extending cell meta objects * (returned by `getCellMeta()` from `MetaManager`) * by user-specific properties. * * The user-specific properties can be added and changed dynamically, * either by Handsontable's hooks (`beforeGetCellMeta` and`afterGetCellMeta`), * or by Handsontable's `cells` option. * * The `getCellMeta()` method is used widely throughout the source code. * To boost the method's execution time, * the logic is triggered only once per one Handsontable slow render cycle. */ type MetaManagerWithHot = MetaManagerInstance & { hot: { colToProp: (column: number) => string | number; runHooks: (...args: unknown[]) => unknown; [key: string]: unknown; }; addLocalHook: (hookName: string, callback: (...args: unknown[]) => void) => void; updateCellMeta: (...args: unknown[]) => void; [key: string]: unknown; }; /** * Modifier that extends cell meta objects dynamically through Handsontable hooks and the `cells` option, * memoizing results per render cycle to avoid redundant work. */ export declare class DynamicCellMetaMod { /** * @type {MetaManager} */ metaManager: MetaManagerWithHot; /** * @type {Map} */ metaSyncMemo: Map; /** * Initializes the modifier, registers the `afterGetCellMeta` local hook, and subscribes to `beforeRender` to clear the memo on full renders. */ constructor(metaManager: MetaManagerWithHot); /** * Extends the cell meta object by user-specific properties. * * The cell meta object can be extended dynamically, * either by Handsontable's hooks (`beforeGetCellMeta` and`afterGetCellMeta`), * or by Handsontable's `cells` option. * * To boost performance, the extending process is triggered only once per one slow Handsontable render cycle. * * @param {object} cellMeta The cell meta object. */ extendCellMeta(cellMeta: Record): void; } export {};