forked from enesozturk/rn-swipeable-panel
-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.d.ts
92 lines (72 loc) · 2.08 KB
/
index.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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
// Type definitions for rn-swipeable-panel
// Project: https://github.com/enesozturk/rn-swipeable-panel
// Definitions by: Enes Öztürk <https://github.com/enesozturk>
// Definitions: https://github.com/DefinitelyTyped/types/rn-swipeable-panel
import * as React from 'react';
declare var LARGE_PANEL_CONTENT_HEIGHT: number;
declare var SMALL_PANEL_CONTENT_HEIGHT: number;
declare interface SwipeablePanelProps extends React.Props<SwipeablePanel> {
/**
* Required prop for panels actual state. Set true if you want to open panel
*/
isActive: boolean;
/**
* Set true if you want to show close button
*/
showCloseButton?: boolean;
/**
* Set true if you want to make full with panel
*/
fullWidth?: boolean;
/**
* Set true if you want to disable black background opacity
*/
noBackgroundOpacity?: boolean;
/**
* Use this prop to override panel style
*/
style?: object;
/**
* Use this prop to override close button background style
*/
closeRootStyle?: object;
/**
* Use this prop to override close button icon style
*/
closeIconStyle?: object;
/**
* Set true if you want to close panel by touching outside
*/
closeOnTouchOutside?: boolean;
/**
* Set true if you want to let panel open just large mode
*/
onlyLarge?: boolean;
/**
* Set true if you want to let panel open just small mode
*/
onlySmall?: boolean;
/**
* Set true if you want to open panel large by default
*/
openLarge?: boolean;
/**
* Set true if you want to remove gray bar
*/
noBar?: boolean;
/**
* Use this prop to override bar style
*/
barStyle?: object;
/**
* Set true if you want to make toucable outside of panel
*/
allowTouchOutside?: boolean;
// Event Handlers
/**
* Required prop to keep panel's state sync with your parent components'state. Will be fired when panel is closed. See the example project.
*/
onClose: () => void;
}
declare class SwipeablePanel extends React.Component<SwipeablePanelProps, any> {}
export { SwipeablePanel, LARGE_PANEL_CONTENT_HEIGHT, SMALL_PANEL_CONTENT_HEIGHT };