import { Renderer2, AfterViewInit } from '@angular/core';
import { CacheService } from '../../core/cache.service';
export declare type ResizeCacheEntry = {
    widths: number[];
};
/**
 * Base class for handling click and drag resizing of elements with a mouse.
 * Derived classes must provide the element to be resized and implement the setWidth function.
 */
export declare abstract class ResizableBase implements AfterViewInit {
    protected renderer: Renderer2;
    private cacheService;
    protected document: Document;
    ngAfterViewInit(): void;
    /**Set to true if the resizable should remember its width. Requires the element to have an ID*/
    rememberWidth: boolean;
    /**The id of the resizable, used for GI and for remembering the width  */
    id: string;
    /** The element that is current being resized */
    protected currentEl: HTMLElement | null;
    /** The x position of the mouse when dragging starts. Relative to the viewport. */
    protected startScreenX: number;
    /** The width of the current element when dragging starts. */
    protected startElWidth: number;
    /**
     * Stored 'unlisten' functions that remove their respective listeners when called
     */
    protected mouseupListener?: () => void;
    protected mousemoveListener?: () => void;
    constructor(renderer: Renderer2, cacheService: CacheService, document: Document);
    /**
     * On a mousedown event
     * * store the width of the current element to calculate the new width
     * * store the horizontal position of the pointer to calculate the new width.
     * * add the 'is-active' class to the current element
     * * set up listeners on the document to know when dragging starts and stops.
     * Mouse event listeners are added to the document because the cursor may move
     * off the current element while dragging.
     */
    startDrag(event: MouseEvent): void;
    /**
     * On a mousemove event, calculate the new width of the current element by
     * adding the difference of the start pageX position and the current pageX
     * position to the width of the element when we started dragging. Pass the
     * calculated with to the setWidth method.
     */
    protected drag(event: MouseEvent): void;
    /**
     * Update the current element's width. Called after a mousemove event.
     */
    protected abstract setWidth(width: number): void;
    /**
     * On a mouseup event
     * * remove the mouse event listeners on the document.
     * * remove the 'is-active' class from the current element
     * * reset the cursor style on the body
     */
    protected stopDrag(event: MouseEvent): void;
    /**Called after the view initializes if the component supports restoring widths and there are cached widths to restore.
     * To be overridden in a derived class if it supports restoring widths, defaults to a no-op*/
    protected restoreWidths(widths: number[]): void;
    /** Store the provided widths in cache so they can be retrieved later */
    protected saveWidths(widths: number[]): void;
}
