@hxui/angular
Version:
An Angular library based on the [HXUI design system](https://hxui.io).
40 lines (39 loc) • 1.91 kB
TypeScript
import { ChangeDetectorRef, TemplateRef } from '@angular/core';
import { Observable } from 'rxjs';
import { Context, Visibility } from '../enums';
import { TooltipDynamicContentDirective } from './tooltip-dynamic-content.directive';
import * as i0 from "@angular/core";
export declare class TooltipContentComponent {
private _changeDetectionRef;
content: string;
placement: 'top' | 'bottom' | 'left' | 'right';
context: Context;
maxWidth: number;
dynamicContent: TemplateRef<TooltipDynamicContentDirective>;
/** Enums to be used in the template **/
contextEnum: typeof Context;
visibilityEnum: typeof Visibility;
visibility: Visibility;
/** Subject for notifying that the tooltip has been hidden from the view */
private readonly _onHide;
/** The timeout ID of any current timer set to show the tooltip */
private _showTimeoutId;
/** The timeout ID of any current timer set to hide the tooltip */
private _hideTimeoutId;
constructor(_changeDetectionRef: ChangeDetectorRef);
/**
* Shows the tooltip
* @param delay Amount of milliseconds to the delay showing the tooltip.
*/
show(delay: number): void;
/**
* Hide the tooltip after the provided delay in ms.
* @param delay Amount of milliseconds to delay hiding the tooltip.
*/
hide(delay: number): void;
/** Returns an observable that notifies when the tooltip has been hidden from view. */
afterHidden(): Observable<void>;
isVisible(): boolean;
static ɵfac: i0.ɵɵFactoryDeclaration<TooltipContentComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<TooltipContentComponent, "hx-tooltip-content, hxa-tooltip-content", never, { "content": "content"; "placement": "placement"; "context": "context"; "maxWidth": "maxWidth"; "dynamicContent": "dynamicContent"; }, {}, never, never>;
}