/
index.d.ts
44 lines (33 loc) · 976 Bytes
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
import { Boundary, Placement, PopperOptions } from 'popper.js';
export type TitleFunction = () => string;
export type Delay = Record<'show' | 'hide', number>;
export interface Options {
placement?: Placement;
arrowSelector?: string;
innerSelector?: string;
container?: HTMLElement | string;
delay?: number | Delay;
html?: boolean;
template?: string;
title?: string | HTMLElement | TitleFunction;
/**
* available options are click, hover, focus, manual
* required to form a space delimited string
* e.g. 'hover focus'
*/
trigger?: string;
closeOnClickOutside?: boolean;
boundariesElement?: Boundary | HTMLElement;
offset?: number | string;
popperOptions?: PopperOptions;
}
declare class Tooltip {
constructor(reference: HTMLElement, options: Options);
_isOpen: boolean;
show(): void;
hide(): void;
dispose(): void;
toggle(): void;
updateTitleContent(title: string | HTMLElement): void;
}
export default Tooltip;