import { ElementRef } from '@angular/core';
import { ConnectionPosition, ConnectionPositionPair } from './position.interface';
export declare class ConnectedPositionStrategy {
    private _targetRef;
    private _overlaytRef;
    /** X-axis attachment point to be offset */
    private _offsetX;
    /** X-axis attachment point to be offset */
    private _offsetY;
    /** the target which overlay to be attached to */
    private _targetEl;
    /** overlay element */
    private _overlayEl;
    /** overlay arrow element */
    private _overlayArrowEl;
    /** preferred position, include user setted the position and the oppsite of that position */
    private _preferredPositions;
    /** store overlay's rect to avoid recalcuting while showing again */
    private _lastOverlayRect;
    /** final position */
    private _lastConnectedPosition;
    constructor(_targetRef: ElementRef, _overlaytRef: any);
    /**
     * set X-axis attachment point to be offset
     *
     * @param {number} offset
     * @return {object} this
     */
    withOffsetX(offset: number): this;
    /**
     * set Y-axis attachment point to be offset
     *
     * @param {number} offset
     * @return {object} this
     */
    withOffsetY(offset: number): this;
    /**
     * apply position strategy
     *
     */
    apply(): void;
    /**
     * positioning
     *
     * @return {ConnectionPositionPair} fallbackPosition
     */
    position(): ConnectionPositionPair;
    /**
     * push left to right at horizontaly and change the position
     *
     * @param {Point} overlayPointPoint
     * @param {ConnectionPositionPair} fallbackPosition
     * @param {Number} documentWidth
     * @param {ClientRect} targetRect
     */
    changePositionFromLeftToRight(overlayPointPoint: any, fallbackPosition: any, documentWidth: any, targetRect: any): void;
    /**
     * push right to left at horizontaly and change the position
     *
     * @param {Point} overlayPointPoint
     * @param {ConnectionPositionPair} fallbackPosition
     * @param {Number} documentWidth
     * @param {ClientRect} targetRect
     */
    changePositionFromRightToLeft(overlayPointPoint: any, fallbackPosition: any, targetRect: any): void;
    /**
     * Gets the point at which the overlay can be "pushed" on-screen. If the overlay is larger than
     * the viewport, the top-left corner will be pushed on-screen (with overflow occuring on the
     * right and bottom).
     *
     * @param start The starting point from which the overlay is pushed.
     * @param overlay The overlay dimensions.
     * @returns The point at which to position the overlay after pushing. This is effectively a new
     *     originPoint.
     */
    private _pushOverlayOnScreen;
    /**
     * get target's point according to the target's rect and position
     *
     * @param { ClientRect } targetRect
     * @param { ConnectionPositionPair } position
     * @return { Point } { x, y }
     */
    private _getTargetConnectionPoint;
    /**
     * get overlay's point according to the overlay's rect and position
     *
     * @param { ClientRect } targetRect
     * @param { ConnectionPositionPair } position
     * @return { Point } { x, y }
     */
    private _getOverlayPoint;
    /**
     * Subtracts the amount that an element is overflowing on an axis from it's length
     *
     * @param { number } length
     * @param { number[] } ...overflows
     * @return { number }
     */
    private _subtractOverflows;
    /**
     * Physically positions the overlay element to the given coordinate
     *
     * @param { HTMLElement } element
     * @param { Point } overlayPoint
     */
    private _setElementPosition;
    /**
     * Physically positions the overlay arrow element to the given coordinate
     *
     * @param { HTMLElement } element
     * @param { Point } overlayPoint
     */
    private _setElementArrowPosition;
    /**
     * Physically calculates the overlay arrow element to the given coordinate
     *
     * @param { HTMLElement } element
     * @param { Point } position
     */
    private _calculateElementArrowPosition;
    /**
     * Adds a new preferred fallback position.
     * @param originPos
     * @param overlayPos
     */
    withFallbackPosition(originPos: ConnectionPosition, overlayPos: ConnectionPosition, offsetX?: number, offsetY?: number): this;
    /**
     * Gets a ClientRect for the viewport's bounds
     *
     * @return ClientRect
     */
    getViewportRect(): ClientRect;
}
