interface CursorSourceLiteral { top: string | number; left: string | number; height?: number; width?: number; } /** * Helper class for checking if element will fit at the desired side of cursor. * * @private * @class Cursor */ export declare class Cursor { /** * @type {number} */ top: number; /** * @type {number} */ topRelative: number; /** * @type {number} */ left: number; /** * @type {number} */ leftRelative: number; /** * @type {number} */ scrollTop: number; /** * @type {number} */ scrollLeft: number; /** * @type {number} */ cellHeight: number; /** * @type {number} */ cellWidth: number; /** * Reference to the root window used for reading scroll offsets and dimensions. */ rootWindow: Window; /** * Indicates the source type of the cursor position: either `'literal'` or `'event'`. */ type: string; /** * Initializes the cursor position by computing coordinates from either a literal object or a DOM event. */ constructor(object: CursorSourceLiteral | Event, rootWindow: Window); /** * Get source type name. * * @param {*} object Event or Object with coordinates. * @returns {string} Returns one of this values: `'literal'`, `'event'`. */ getSourceType(object: CursorSourceLiteral | Event): string; /** * Checks if element can be placed above the cursor. * * @param {HTMLElement} element Element to check if it's size will fit above the cursor. * @returns {boolean} */ fitsAbove(element: HTMLElement): boolean; /** * Checks if element can be placed below the cursor. * * @param {HTMLElement} element Element to check if it's size will fit below the cursor. * @param {number} [viewportHeight] The viewport height. * @returns {boolean} */ fitsBelow(element: HTMLElement, viewportHeight?: number): boolean; /** * Checks if element can be placed on the right of the cursor. * * @param {HTMLElement} element Element to check if it's size will fit on the right of the cursor. * @param {number} [viewportWidth] The viewport width. * @returns {boolean} */ fitsOnRight(element: HTMLElement, viewportWidth?: number): boolean; /** * Checks if element can be placed on the left on the cursor. * * @param {HTMLElement} element Element to check if it's size will fit on the left of the cursor. * @returns {boolean} */ fitsOnLeft(element: HTMLElement): boolean; } export {};