mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-03-06 22:39:41 +08:00
Add router prop for the DrawerNavigator content component (#487)
This commit is contained in:
committed by
Satyajit Sahoo
parent
49133c3dfe
commit
1ca18dee13
@@ -14,6 +14,7 @@ import type {
|
||||
NavigationState,
|
||||
NavigationRoute,
|
||||
NavigationAction,
|
||||
NavigationRouter,
|
||||
Style,
|
||||
} from '../../TypeDefinition';
|
||||
import type {
|
||||
@@ -29,6 +30,7 @@ type Props = {
|
||||
getLabel: (scene: DrawerScene) => ?(React.Element<*> | string);
|
||||
renderIcon: (scene: DrawerScene) => ?React.Element<*>;
|
||||
style?: Style;
|
||||
router: NavigationRouter;
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
@@ -81,6 +81,7 @@ class DrawerSidebar extends PureComponent<void, Props, void> {
|
||||
navigation={this.props.navigation}
|
||||
getLabel={this._getLabel}
|
||||
renderIcon={this._renderIcon}
|
||||
rotuer={this.props.router}
|
||||
/>
|
||||
</View>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user