UNPKG

positioning

Version:

The ng-bootstrap Positioning class as a standalone module

22 lines (21 loc) 999 B
interface Position { top: number; bottom: number; left: number; right: number; height: number; width: number; } export declare class Positioning { private getAllStyles; private getStyle; private isStaticPositioned; private offsetParent; position(element: HTMLElement, round?: boolean): Position; offset(element: HTMLElement, round?: boolean): Position; positionElements(hostElement: HTMLElement, targetElement: HTMLElement, placement: string, appendToBody?: boolean): boolean; } export declare function positionElements(hostElement: HTMLElement, targetElement: HTMLElement, placement: string | Placement | PlacementArray, appendToBody?: boolean, baseClass?: string): Placement; export type Placement = 'auto' | 'top' | 'bottom' | 'left' | 'right' | 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right' | 'left-top' | 'left-bottom' | 'right-top' | 'right-bottom'; export type PlacementArray = Placement | Array<Placement> | string; export {};