react-native-navigation icon indicating copy to clipboard operation
react-native-navigation copied to clipboard

[V2] sidemenu cannot overlay on content

Open archived-prf1le opened this issue 8 years ago • 14 comments

Hi, I have sidemenu with bottomtabs. when drawer right or left is visible, it pushes margin left or right to whole content. I want sidemenu open overlay content.

  Navigation.events().registerAppLaunchedListener(() => {
        Navigation.setDefaultOptions({
            statusBar: {
                visible: false,
                drawBehind: true,
            },
            topBar: {
                visible: false,
                drawBehind: true,
                animate: false,
            },
            bottomTabs: {
                titleDisplayMode: "alwaysHide",
            },
        });
        Navigation.setRoot({
            root: {
                sideMenu: {
                    center: {
                        bottomTabs: {
                            id: "bottomTab",
                            children: [
                                {
                                    stack: {
                                        children: [
                                            {
                                                component: {
                                                    name: "navigation.profile.RegisterScreen",
                                                    passProps: {
                                                        text: "This is tab 1",
                                                    },
                                                },
                                            },
                                        ],
                                        options: {
                                            bottomTab: {
                                                icon: require("./assets/images/home.png"),
                                                testID: "FIRST_TAB_BAR_BUTTON",
                                            },
                                        },
                                    },
                                },
                                {
                                    component: {
                                        name: "navigation.profile.FormScreen",
                                        passProps: {
                                            text: "This is tab 2",
                                        },
                                        options: {
                                            bottomTab: {
                                                icon: require("./assets/images/search.png"),
                                                testID: "SECOND_TAB_BAR_BUTTON",
                                            },
                                        },
                                    },
                                },
                                {
                                    component: {
                                        name: "navigation.profile.CommentScreen",
                                        passProps: {
                                            text: "This is tab 2",
                                        },
                                        options: {
                                            bottomTab: {
                                                icon: require("./assets/images/jobs.png"),
                                                testID: "SECOND_TAB_BAR_BUTTON",
                                            },
                                        },
                                    },
                                },
                                {
                                    component: {
                                        name: "navigation.profile.NotificationScreen",
                                        passProps: {
                                            text: "This is tab 2",
                                        },
                                        options: {
                                            bottomTab: {
                                                icon: require("./assets/images/notifications.png"),
                                                testID: "SECOND_TAB_BAR_BUTTON",
                                            },
                                        },
                                    },
                                },
                                {
                                    component: {
                                        name: "navigation.profile.ProfileScreen",
                                        passProps: {
                                            text: "This is tab 2",
                                        },
                                        options: {
                                            bottomTab: {
                                                icon: require("./assets/images/menu.png"),
                                                testID: "SECOND_TAB_BAR_BUTTON",
                                            },
                                        },
                                    },
                                },
                            ],
                        },
                    }
                }

            },
        });
    });

Environment

  • React Native Navigation version: 2.0.2538
  • React Native version: 0.56.0
  • Platform(s) (iOS, Android, or both?): IOS
  • Device info (Simulator/Device? OS version? Debug/Release?): Simulator/Iphone 6 ios 11.3

archived-prf1le avatar Sep 11 '18 13:09 archived-prf1le

+1

mammad2c avatar Sep 12 '18 07:09 mammad2c

+1

anonrig avatar Sep 29 '18 19:09 anonrig

+1

svenjens avatar Oct 10 '18 12:10 svenjens

+1

@guyca, when you said that this is supported in v2 you referred to Android only?

Because on iOS (v2.0.2586) the whole component is pushed to left/right.

sergiulucaci avatar Oct 22 '18 18:10 sergiulucaci

Pretty frustrating when looking at feature parity between V1 and V2 as there is no indication that the drawer/sideMenu functionality is so far out of sync. Halfway through moving over to V2 and discovered this.

whiffsalot avatar Oct 30 '18 22:10 whiffsalot

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If you believe the issue is still relevant, please test on the latest Detox and report back. Thank you for your contributions.

stale[bot] avatar Nov 29 '18 23:11 stale[bot]

This issue still exists

anonrig avatar Nov 30 '18 09:11 anonrig

Yes the same issue(with v2.0.2569) on IOS, the whole component is pushed to left/right. Any help or resolution in pipeline?

sure2win avatar Dec 05 '18 07:12 sure2win

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If you believe the issue is still relevant, please test on the latest Detox and report back. Thank you for your contributions.

stale[bot] avatar Jan 04 '19 16:01 stale[bot]

I hate this bot.

anonrig avatar Jan 06 '19 19:01 anonrig

We'd also like to have this updated for iOS. Thanks

FinHead avatar Jan 25 '19 18:01 FinHead

Hey everyone, (@sure2win, @FinHead, @kyledmellander, @anonrig, @sergiulucaci, @Profileir)

Guyca says "This is what's currently available and we have no plans or intentions to develop additional features. That being said, PR's are always welcome." in relation to the side menu feature.

That being said, I've build an implementation for a drawer, which uses showOverlay under the hood but provides a simple API for styling and animating the drawer inline with how other RNN features work.

Check it out: https://github.com/lukebrandonfarrell/react-native-navigation-drawer-extension

lukebrandonfarrell avatar Feb 19 '19 11:02 lukebrandonfarrell

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If you believe the issue is still relevant, please test on the latest Detox and report back. Thank you for your contributions.

stale[bot] avatar Mar 21 '19 12:03 stale[bot]

The issue has been closed for inactivity.

stale[bot] avatar Mar 28 '19 12:03 stale[bot]