|
| 1 | +{ |
| 2 | + "name": "Drawer", |
| 3 | + "category": "lists", |
| 4 | + "description": "Drawer Component", |
| 5 | + "notes": "If your app works with RNN, your screen must be wrapped with gestureHandlerRootHOC from 'react-native-gesture-handler'. see: https://kmagiera.github.io/react-native-gesture-handler/docs/getting-started.html#with-wix-react-native-navigation-https-githubcom-wix-react-native-navigation", |
| 6 | + "example": "https://github.com/wix/react-native-ui-lib/blob/master/demo/src/screens/componentScreens/DrawerScreen.tsx", |
| 7 | + "images": ["https://github.com/wix/react-native-ui-lib/blob/master/demo/showcase/Drawer/Drawer.gif?raw=true"], |
| 8 | + "props": [ |
| 9 | + { |
| 10 | + "name": "rightItems", |
| 11 | + "type": "ItemProps[]", |
| 12 | + "description": "The bottom layer's items to appear when opened from the right" |
| 13 | + }, |
| 14 | + { |
| 15 | + "name": "leftItem", |
| 16 | + "type": "ItemProps", |
| 17 | + "description": "The bottom layer's item to appear when opened from the left (a single item)" |
| 18 | + }, |
| 19 | + {"name": "bounciness", "type": "number", "description": "The drawer animation bounciness"}, |
| 20 | + {"name": "itemsMinWidth", "type": "number", "description": "Set a different minimum width"}, |
| 21 | + { |
| 22 | + "name": "itemsTintColor", |
| 23 | + "type": "string", |
| 24 | + "description": "The color for the text and icon tint of the items", |
| 25 | + "default": "Colors.white" |
| 26 | + }, |
| 27 | + {"name": "itemsIconSize", "type": "number", "description": "The items' icon size", "default": "24"}, |
| 28 | + {"name": "itemsTextStyle", "type": "TextStyle", "description": "The items' text style"}, |
| 29 | + {"name": "useNativeAnimations", "type": "boolean", "description": "Perform the animation in natively"}, |
| 30 | + {"name": "fullSwipeLeft", "type": "boolean", "description": "Whether to allow a full left swipe"}, |
| 31 | + {"name": "fullLeftThreshold", "type": "number", "description": "Threshold for a left full swipe (0-1)"}, |
| 32 | + {"name": "onFullSwipeLeft", "type": "() => void", "description": "Callback for left item full swipe"}, |
| 33 | + {"name": "onWillFullSwipeLeft", "type": "() => void", "description": "Callback for just before left item full swipe"}, |
| 34 | + {"name": "onToggleSwipeLeft", "type": "() => {rowWidth, leftWidth, dragX, resetItemPosition}", "description": "Callback for left item toggle swipe"}, |
| 35 | + { |
| 36 | + "name": "leftToggleHapticTrigger", |
| 37 | + "type": "() => void", |
| 38 | + "description": "Haptic trigger callback to use onToggleSwipeLeft", |
| 39 | + "deprecated": true |
| 40 | + }, |
| 41 | + {"name": "fullSwipeRight", "type": "boolean", "description": "Whether to allow a full right swipe"}, |
| 42 | + {"name": "fullRightThreshold", "type": "number", "description": "Threshold for a right full swipe (0-1)"}, |
| 43 | + {"name": "onFullSwipeRight", "type": "() => void", "description": "Callback for right item full swipe"}, |
| 44 | + { |
| 45 | + "name": "onWillFullSwipeRight", |
| 46 | + "type": "() => void", |
| 47 | + "description": "Callback for just before right item full swipe" |
| 48 | + }, |
| 49 | + {"name": "disableHaptic", "type": "boolean", "description": "Whether to disable the haptic"}, |
| 50 | + {"name": "onDragStart", "type": "() => any", "description": "Called when drag gesture starts"}, |
| 51 | + {"name": "onSwipeableWillOpen", "type": "() => void", "description": "Callback for open action"}, |
| 52 | + {"name": "onSwipeableWillClose", "type": "() => void", "description": "Callback for close action"}, |
| 53 | + { |
| 54 | + "name": "customValue", |
| 55 | + "type": "any", |
| 56 | + "description": "Custom value of any type to pass on to the component and receive back in the action callbacks" |
| 57 | + }, |
| 58 | + {"name": "style", "type": "ViewStyle", "description": "Component's style"}, |
| 59 | + {"name": "testID", "type": "string", "description": "The test id for e2e tests"} |
| 60 | + ] |
| 61 | +} |
0 commit comments