import { ElementRef, TemplateRef, OnDestroy } from "@angular/core"; import { Overlay } from "@angular/cdk/overlay"; import { TooltipTrigger, TooltipTheme } from "./tooltip-content/tooltip-content.component"; import { Subject } from "rxjs"; import { TooltipPosition } from "./tooltip.positions"; /** * A text label that acts as a helper to a specific item */ export declare class TooltipDirective implements OnDestroy { private overlay; private elementRef; /** content of tooltip */ content: string | TemplateRef; /** tooltip trigger method */ trigger: TooltipTrigger; /** tooltip position */ position: TooltipPosition; /** tooltip theme */ theme: TooltipTheme; /** CSS class */ className?: string; /** reposition tooltip with more placement choices */ cascade?: boolean; /** Close the tooltip once the user scrolls */ closeOnScroll: boolean; /** Delay before closing on scroll */ closeOnScrollDelay: number; /** */ private overlayRef; /** */ private tooltipRef; /** */ destroy$: Subject; constructor(overlay: Overlay, elementRef: ElementRef); /** * configure the overlay with position and scroll strategies * @param origin element ref to where the overlay will be connected to */ private getOverlayConfig; /** * Configure the overlay position in a flexible way * listen for position changes and update the arrow of the tooltip accordingly * @param origin element ref to where the overlay will be connected to */ private getOverlayPosition; /** * get possible overlay placements the first placement is the position Input * Default Tooltip position will display the tooltip in the following order depending on how available space [top, right, bottom, left] * Cascade Tooltip position have twelve different possible position like [top, top-right, top-bottom, right, right-top....] */ private getPositions; showHover(): void; hideHover(event: MouseEvent): void; /** * This Listener triggers both on focus and on click */ /** */ showFocusWithin(event: FocusEvent): void; hideClick(): void; /** * * Show tooltip */ showTooltip(): void; /** * * Hide tooltip by destroying the tooltip ref and overlay ref */ hideTooltip(): void; ngOnDestroy(): void; }