UNPKG

3.02 kBTypeScriptView Raw
1/**
2 * @dynamic is for runtime initializing DomHandler.browser
3 *
4 * If delete below comment, we can see this error message:
5 * Metadata collected contains an error that will be reported at runtime:
6 * Only initialized variables and constants can be referenced
7 * because the value of this variable is needed by the template compiler.
8 */
9export declare class DomHandler {
10 static zindex: number;
11 private static calculatedScrollbarWidth;
12 private static calculatedScrollbarHeight;
13 private static browser;
14 static addClass(element: any, className: string): void;
15 static addMultipleClasses(element: any, className: string): void;
16 static removeClass(element: any, className: string): void;
17 static hasClass(element: any, className: string): boolean;
18 static siblings(element: any): any;
19 static find(element: any, selector: string): any[];
20 static findSingle(element: any, selector: string): any;
21 static index(element: any): number;
22 static indexWithinGroup(element: any, attributeName: string): number;
23 static relativePosition(element: any, target: any): void;
24 static absolutePosition(element: any, target: any): void;
25 static getHiddenElementOuterHeight(element: any): number;
26 static getHiddenElementOuterWidth(element: any): number;
27 static getHiddenElementDimensions(element: any): any;
28 static scrollInView(container: any, item: any): void;
29 static fadeIn(element: any, duration: number): void;
30 static fadeOut(element: any, ms: any): void;
31 static getWindowScrollTop(): number;
32 static getWindowScrollLeft(): number;
33 static matches(element: any, selector: string): boolean;
34 static getOuterWidth(el: any, margin?: any): any;
35 static getHorizontalPadding(el: any): number;
36 static getHorizontalMargin(el: any): number;
37 static innerWidth(el: any): any;
38 static width(el: any): any;
39 static getInnerHeight(el: any): any;
40 static getOuterHeight(el: any, margin?: any): any;
41 static getHeight(el: any): number;
42 static getWidth(el: any): number;
43 static getViewport(): any;
44 static getOffset(el: any): {
45 top: any;
46 left: any;
47 };
48 static replaceElementWith(element: any, replacementElement: any): any;
49 static getUserAgent(): string;
50 static isIE(): boolean;
51 static isIOS(): boolean;
52 static isAndroid(): boolean;
53 static appendChild(element: any, target: any): void;
54 static removeChild(element: any, target: any): void;
55 static isElement(obj: any): boolean;
56 static calculateScrollbarWidth(el?: HTMLElement): number;
57 static calculateScrollbarHeight(): number;
58 static invokeElementMethod(element: any, methodName: string, args?: any[]): void;
59 static clearSelection(): void;
60 static getBrowser(): any;
61 static resolveUserAgent(): {
62 browser: any;
63 version: any;
64 };
65 static isInteger(value: any): boolean;
66 static isHidden(element: HTMLElement): boolean;
67 static getFocusableElements(element: HTMLElement): any[];
68}