123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264 |
- import HtmlComponent from '../abstract/html-component';
- import { Point, PointLocationCfg } from '../types';
- import { TooltipCfg } from '../types';
- import { ILocation } from '../interfaces';
- declare class Tooltip<T extends TooltipCfg = TooltipCfg> extends HtmlComponent implements ILocation<PointLocationCfg> {
- getDefaultCfg(): {
- name: string;
- type: string;
- x: number;
- y: number;
- items: any[];
- customContent: any;
- containerTpl: string;
- itemTpl: string;
- xCrosshairTpl: string;
- yCrosshairTpl: string;
- title: any;
- showTitle: boolean;
- /**
- * tooltip 限制的区域
- * @type {Region}
- */
- region: any;
- crosshairsRegion: any;
- containerClassName: string;
- crosshairs: any;
- offset: number;
- position: string;
- domStyles: any;
- defaultStyles: {
- [x: string]: {
- position: string;
- visibility: string;
- zIndex: number;
- transition: string;
- backgroundColor: string;
- boxShadow: string;
- borderRadius: string;
- color: string;
- fontSize: string;
- fontFamily: string;
- lineHeight: string;
- padding: string;
- marginBottom?: undefined;
- margin?: undefined;
- listStyleType?: undefined;
- width?: undefined;
- height?: undefined;
- display?: undefined;
- marginRight?: undefined;
- float?: undefined;
- marginLeft?: undefined;
- } | {
- marginBottom: string;
- position?: undefined;
- visibility?: undefined;
- zIndex?: undefined;
- transition?: undefined;
- backgroundColor?: undefined;
- boxShadow?: undefined;
- borderRadius?: undefined;
- color?: undefined;
- fontSize?: undefined;
- fontFamily?: undefined;
- lineHeight?: undefined;
- padding?: undefined;
- margin?: undefined;
- listStyleType?: undefined;
- width?: undefined;
- height?: undefined;
- display?: undefined;
- marginRight?: undefined;
- float?: undefined;
- marginLeft?: undefined;
- } | {
- margin: string;
- listStyleType: string;
- padding: string;
- position?: undefined;
- visibility?: undefined;
- zIndex?: undefined;
- transition?: undefined;
- backgroundColor?: undefined;
- boxShadow?: undefined;
- borderRadius?: undefined;
- color?: undefined;
- fontSize?: undefined;
- fontFamily?: undefined;
- lineHeight?: undefined;
- marginBottom?: undefined;
- width?: undefined;
- height?: undefined;
- display?: undefined;
- marginRight?: undefined;
- float?: undefined;
- marginLeft?: undefined;
- } | {
- listStyleType: string;
- marginBottom: string;
- position?: undefined;
- visibility?: undefined;
- zIndex?: undefined;
- transition?: undefined;
- backgroundColor?: undefined;
- boxShadow?: undefined;
- borderRadius?: undefined;
- color?: undefined;
- fontSize?: undefined;
- fontFamily?: undefined;
- lineHeight?: undefined;
- padding?: undefined;
- margin?: undefined;
- width?: undefined;
- height?: undefined;
- display?: undefined;
- marginRight?: undefined;
- float?: undefined;
- marginLeft?: undefined;
- } | {
- width: string;
- height: string;
- borderRadius: string;
- display: string;
- marginRight: string;
- position?: undefined;
- visibility?: undefined;
- zIndex?: undefined;
- transition?: undefined;
- backgroundColor?: undefined;
- boxShadow?: undefined;
- color?: undefined;
- fontSize?: undefined;
- fontFamily?: undefined;
- lineHeight?: undefined;
- padding?: undefined;
- marginBottom?: undefined;
- margin?: undefined;
- listStyleType?: undefined;
- float?: undefined;
- marginLeft?: undefined;
- } | {
- display: string;
- float: string;
- marginLeft: string;
- position?: undefined;
- visibility?: undefined;
- zIndex?: undefined;
- transition?: undefined;
- backgroundColor?: undefined;
- boxShadow?: undefined;
- borderRadius?: undefined;
- color?: undefined;
- fontSize?: undefined;
- fontFamily?: undefined;
- lineHeight?: undefined;
- padding?: undefined;
- marginBottom?: undefined;
- margin?: undefined;
- listStyleType?: undefined;
- width?: undefined;
- height?: undefined;
- marginRight?: undefined;
- } | {
- position: string;
- width: string;
- backgroundColor: string;
- visibility?: undefined;
- zIndex?: undefined;
- transition?: undefined;
- boxShadow?: undefined;
- borderRadius?: undefined;
- color?: undefined;
- fontSize?: undefined;
- fontFamily?: undefined;
- lineHeight?: undefined;
- padding?: undefined;
- marginBottom?: undefined;
- margin?: undefined;
- listStyleType?: undefined;
- height?: undefined;
- display?: undefined;
- marginRight?: undefined;
- float?: undefined;
- marginLeft?: undefined;
- } | {
- position: string;
- height: string;
- backgroundColor: string;
- visibility?: undefined;
- zIndex?: undefined;
- transition?: undefined;
- boxShadow?: undefined;
- borderRadius?: undefined;
- color?: undefined;
- fontSize?: undefined;
- fontFamily?: undefined;
- lineHeight?: undefined;
- padding?: undefined;
- marginBottom?: undefined;
- margin?: undefined;
- listStyleType?: undefined;
- width?: undefined;
- display?: undefined;
- marginRight?: undefined;
- float?: undefined;
- marginLeft?: undefined;
- };
- };
- container: any;
- updateAutoRender: boolean;
- parent: any;
- id: string;
- locationType: string;
- offsetX: number;
- offsetY: number;
- animate: boolean;
- capture: boolean;
- animateOption: {
- appear: any;
- update: {
- duration: number;
- easing: string;
- };
- enter: {
- duration: number;
- easing: string;
- };
- leave: {
- duration: number;
- easing: string;
- };
- };
- events: any;
- defaultCfg: {};
- visible: boolean;
- };
- render(): void;
- clear(): void;
- show(): void;
- hide(): void;
- getLocation(): {
- x: any;
- y: any;
- };
- setLocation(point: Point): void;
- setCrossHairsVisible(visible: any): void;
- protected initContainer(): void;
- protected updateInner(cfg: Partial<T>): void;
- protected initDom(): void;
- protected removeDom(): void;
- protected resetPosition(): void;
- private renderCustomContent;
- private getHtmlContentNode;
- private cacheDoms;
- private resetTitle;
- private setTitle;
- private resetCrosshairs;
- private resetCrosshair;
- private checkCrosshair;
- private renderItems;
- private clearItemDoms;
- private clearCrosshairs;
- }
- export default Tooltip;
|