Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bottom Up drawer in react native [closed]

I am new to react native. I want to create a menu slider like control center in IOS. I thought I can use react-native-drawer but the library doesn't provide a way to open drawer from the bottom. can you guys suggest something to implement that?

like image 901
Pankaj Agrawal Avatar asked Dec 21 '16 14:12

Pankaj Agrawal


People also ask

How do you check if drawer is open react native?

If you would like to determine if drawer is open or closed, you can do the following: import { useDrawerStatus } from '@react-navigation/drawer'; // ...


2 Answers

What you are looking for are called Bottom Sheets in Material Design (see here for examples) and Action Sheets in iOS (customized action sheets more precisely, like this one).

I found two React Native libraries which implement Bottom Sheets (so only for android):

  • https://github.com/cesardeazevedo/react-native-bottom-sheet-behavior
  • https://github.com/WhatAKitty/react-native-bottom-sheet

And this library implements custom Action Sheets (so only for ios):

  • https://github.com/eyaleizenberg/react-native-custom-action-sheet

I didn't find any RN library which works for both platforms, so we will have to be happy with what we've got. Good luck!

Edit: Since my answer a new package came out: https://github.com/beefe/react-native-actionsheet. Thanks @thibautnoah for pointing it out.

like image 120
jeanpaul62 Avatar answered Sep 30 '22 05:09

jeanpaul62


This library react-native-modalbox implements this behaviour. It's cross platform as well and pure javascript.

https://github.com/maxs15/react-native-modalbox

like image 27
Kyle Roach Avatar answered Sep 30 '22 07:09

Kyle Roach