mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-04 06:47:03 +00:00
React Navigation: headerLayoutPreset && headerBackTitleVisible (#29833)
* Update types for stack navigator https://reactnavigation.org/docs/en/stack-navigator.html * unecessary ` * add tests? * What type is this Ref * commit a log * define Ref Types in tests * does not have any construct or call signatures | the methods causing this error arent even used * All tests passing * WIP * add to test * why do I need graphql-tools * diff * wip * cleanup * lol * remove console.log * remove ref Types
This commit is contained in:
Vendored
+3
@@ -25,6 +25,7 @@
|
||||
// Denis Frezzato <https://github.com/DenisFrezzato>
|
||||
// Mickael Wegerich <https://github.com/mickaelw>
|
||||
// Max Davidson <https://github.com/maxdavidson>
|
||||
// Lachlan Young <https://github.com/builtbyproxy>
|
||||
// Jason Killian <https://github.com/jkillian>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.8
|
||||
@@ -374,7 +375,9 @@ export interface NavigationToggleDrawerAction {
|
||||
export interface NavigationStackViewConfig {
|
||||
mode?: 'card' | 'modal';
|
||||
headerMode?: HeaderMode;
|
||||
headerBackTitleVisible?: boolean;
|
||||
headerTransitionPreset?: 'fade-in-place' | 'uikit';
|
||||
headerLayoutPreset?: 'left' | 'center';
|
||||
cardStyle?: StyleProp<ViewStyle>;
|
||||
transitionConfig?: (
|
||||
transitionProps: NavigationTransitionProps,
|
||||
|
||||
@@ -125,6 +125,7 @@ const initialRouteParams: StartScreenNavigationParams = {
|
||||
id: 1,
|
||||
s: "Start",
|
||||
};
|
||||
|
||||
const routeConfigMap: NavigationRouteConfigMap = {
|
||||
[ROUTE_NAME_START_SCREEN]: {
|
||||
path: "start",
|
||||
@@ -140,6 +141,7 @@ export const AppNavigator = createStackNavigator(
|
||||
{
|
||||
initialRouteName: ROUTE_NAME_START_SCREEN,
|
||||
initialRouteKey: ROUTE_KEY_START_SCREEN,
|
||||
headerLayoutPreset: 'center',
|
||||
initialRouteParams,
|
||||
navigationOptions,
|
||||
},
|
||||
@@ -614,7 +616,6 @@ createStackNavigator(
|
||||
);
|
||||
|
||||
// Test NavigationEvents component
|
||||
|
||||
const ViewWithNavigationEvents = (
|
||||
<NavigationEvents
|
||||
onWillFocus={console.log}
|
||||
|
||||
Reference in New Issue
Block a user