forked from DefinitelyTyped/DefinitelyTyped
-
Notifications
You must be signed in to change notification settings - Fork 0
/
polymer.paper-toast.d.ts
63 lines (53 loc) · 1.54 KB
/
polymer.paper-toast.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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
// Type definitions for polymer's paper-toast
// Project: https://github.com/Polymer/paper-toast
// Definitions by: Louis Grignon <https://github.com/lgrignon>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
///<reference path="polymer.d.ts"/>
declare module PolymerComponents {
export module Paper {
export interface Toast extends PolymerElement, HTMLElement {
/**
* The text shows in a toast.
* default: ''
*/
text: string;
/**
* The duration in milliseconds to show the toast.
* default: 3000
*/
duration: number;
/**
* Set opened to true to show the toast and to false to hide it.
* default: false
*/
opened: boolean;
/**
* Min-width when the toast changes to narrow layout. In narrow layout, the toast fits at the bottom of the screen when opened.
* default: '480px'
*/
responsiveWidth: string;
/**
* If true, the toast can't be swiped.
* default: false
*/
swipeDisabled: boolean;
/**
* By default, the toast will close automatically if the user taps outside it or presses the escape key. Disable this behavior by setting the autoCloseDisabled property to true.
* default: false
*/
autoCloseDisabled: boolean;
/**
* Show the toast for the specified duration
*/
show(): void;
/**
* Dismiss the toast and hide it.
*/
dismiss(): void;
/**
* Toggle the opened state of the toast.
*/
toggle(): void;
}
}
}