pedreviljoen / react-native-menu

Simple & lightweight customisable menu drawer component
MIT License
57 stars 16 forks source link

Switching from portrait to landscape size issue #77

Closed sdattatri closed 3 years ago

sdattatri commented 3 years ago

Describe the bug I have settings as follows:

<MenuDrawer
        open={menuOpenRef.current}
        drawerContent={menuContent()}
        drawerPercentage={100}
        animationTime={200}
        overlay={true}
        opacity={0.4}
 >

When I flip the phone from portrait to landscape, the dimensions of the menu remain the same. So now in landscape only part of the screen behind is covered by the menu. It appears that the height and width of the top window of the MenuDrawer component remain fixed even when the orientation is changed. To Reproduce Just flip the phone from portrait to landscape. Expected behavior Size recalculated and redrawn

Screenshots If applicable, add screenshots to help explain your problem. WhatsApp Image 2020-11-11 at 2 37 02 PM WhatsApp Image 2020-11-11 at 2 36 53 PM

issue-label-bot[bot] commented 3 years ago

Issue-Label Bot is automatically applying the label bug to this issue, with a confidence of 0.88. Please mark this comment with :thumbsup: or :thumbsdown: to give our bot feedback!

Links: app homepage, dashboard and code for this bot.

pedreviljoen commented 3 years ago

@sdattatri At this moment landscape is not supported.

damau commented 2 years ago

Heya @sdattatri and @pedreviljoen this should make it portrait compatible. @sdattatri Love it if you could give it a try.

(I don't class myself as a react-native dev, so performance may be an issue) https://github.com/pedreviljoen/react-native-menu/pull/90