forked from prateekbh/preact-material-components
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMaterialComponentsWeb.d.ts
42 lines (39 loc) · 1.31 KB
/
MaterialComponentsWeb.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
export declare class MDCFoundation<A = {}> {
static cssClasses: {[key: string]: string};
static strings: {[key: string]: string};
static numbers: {[key: string]: string};
static defaultAdapter: Object;
constructor(adapter?: A);
init(): void;
destroy(): void;
}
export declare class MDCComponent<F> {
static attachTo<F>(root: Element): MDCComponent<F>;
constructor(root: Element, foundation?: F, ...args: any[]);
initialize(): void;
getDefaultFoundation(): F;
initialSyncWithDOM(): void;
destroy(): void;
listen<K extends keyof ElementEventMap>(
type: K,
listener: (this: Element, ev: ElementEventMap[K]) => any
): void;
listen(type: string, listener: EventListenerOrEventListenerObject): void;
unlisten<K extends keyof ElementEventMap>(
type: K,
listener: (this: Element, ev: ElementEventMap[K]) => any
): void;
unlisten(type: string, listener: EventListenerOrEventListenerObject): void;
emit(evtType: string, evtData: Object, shouldBubble?: boolean): void;
}
export declare class MDCRippleFoundation extends MDCFoundation<MDCRipple> {
activate(event?: Event): void;
deactivate(event?: Event): void;
layout(): void;
}
export declare class MDCRipple extends MDCComponent<MDCRippleFoundation> {
unbounded: boolean;
activate(): void;
deactivate(): void;
layout(): void;
}