Constants.js
1.49 KB
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
import {Easing} from 'react-native'
const ToastDuration = {
LONG: 3500,
SHORT: 2000
}
const ToastInHeight = 120
const ToastInOutDuration = 240
const ToastPosition = {
TOP: 1,
CENTER: 0,
BOTTOM: -1
}
const ToastDefaultOpt = {
data: '', //required
duration: ToastDuration.SHORT,
position: ToastPosition.BOTTOM,
inEasing: Easing.elastic(1),
textColor: 'white',
backgroundColor: 'black',
icon: undefined,
isShowShadow: true,
}
// ---------
const SnackBarDuration = {
LONG: 3500,
SHORT: 2000,
INDEFINITE: -1
}
const SnackBarPosition = {
TOP: 1,
BOTTOM: -1
}
const SnackBarDefaultOpt = {
data: '', //required
statusBarHeight: -1,
height: 44,
duration: SnackBarDuration.SHORT,
position: SnackBarPosition.BOTTOM,
inEasing: Easing.linear,
textColor: 'white',
backgroundColor: 'black',
actionText: undefined,
actionTextColor: 'white',
isAllowSlideExit: true,
onActionHide: undefined,
isShowShadow: true,
numberOfLines: 1,
}
const SnackBarInOutDuration = 200
// --------
const ModalDefaultOpt = {
data: '', //required
position: ToastPosition.BOTTOM,
inEasing: Easing.elastic(1),
textColor: 'white',
backgroundColor: 'black',
icon: undefined,
onRequestClose: undefined
}
export {
ToastDuration,ToastInOutDuration,ToastInHeight,ToastPosition,ToastDefaultOpt,
SnackBarDuration,SnackBarPosition,SnackBarDefaultOpt,SnackBarInOutDuration,
ModalDefaultOpt
}