Skip to content

Commit

Permalink
chore: upgrade depenendecies
Browse files Browse the repository at this point in the history
  • Loading branch information
satya164 committed Apr 7, 2020
1 parent b71de6c commit de5d985
Show file tree
Hide file tree
Showing 13 changed files with 817 additions and 2,092 deletions.
2 changes: 1 addition & 1 deletion example/app.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"slug": "react-navigation-example",
"description": "Demo app to showcase various functionality of React Navigation",
"privacy": "public",
"sdkVersion": "36.0.0",
"sdkVersion": "37.0.0",
"platforms": [
"ios",
"android",
Expand Down
19 changes: 9 additions & 10 deletions example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,31 +12,30 @@
},
"dependencies": {
"@expo/vector-icons": "^10.0.0",
"@react-native-community/masked-view": "0.1.7",
"@types/react-native-restart": "^0.0.0",
"@react-native-community/masked-view": "^0.1.7",
"color": "^3.1.2",
"expo": "^36.0.2",
"expo-asset": "~8.1.1",
"expo": "^37.0.0",
"expo-asset": "~8.1.3",
"expo-blur": "~8.1.0",
"react": "~16.9.0",
"react-dom": "~16.9.0",
"react-native": "~0.61.5",
"react-native-gesture-handler": "^1.6.0",
"react-native-paper": "^3.6.0",
"react-native-paper": "^3.7.0",
"react-native-reanimated": "^1.7.0",
"react-native-restart": "^0.0.14",
"react-native-safe-area-context": "^0.7.3",
"react-native-screens": "^2.3.0",
"react-native-tab-view": "2.13.0",
"react-native-unimodules": "^0.8.1",
"react-native-tab-view": "2.14.0",
"react-native-unimodules": "~0.8.1",
"react-native-web": "^0.11.7"
},
"devDependencies": {
"@expo/webpack-config": "^0.11.9",
"@expo/webpack-config": "^0.11.19",
"@types/react": "^16.9.23",
"@types/react-native": "^0.61.22",
"@types/react-native": "^0.60.22",
"babel-preset-expo": "^8.1.0",
"expo-cli": "^3.15.5",
"expo-cli": "^3.17.18",
"typescript": "^3.8.3"
}
}
2 changes: 1 addition & 1 deletion example/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ const THEME_PERSISTENCE_KEY = 'THEME_TYPE';
Asset.loadAsync(StackAssets);

export default function App() {
const containerRef = React.useRef<NavigationContainerRef>();
const containerRef = React.useRef<NavigationContainerRef>(null);

// To test deep linking on, run the following in the Terminal:
// Android: adb shell am start -a android.intent.action.VIEW -d "exp://127.0.0.1:19000/--/simple-stack"
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,17 +33,17 @@
"@babel/preset-typescript": "^7.9.0",
"@babel/runtime": "^7.9.2",
"@commitlint/config-conventional": "^8.3.4",
"@types/jest": "^25.1.4",
"babel-jest": "^25.2.1",
"@types/jest": "^25.2.1",
"babel-jest": "^25.2.6",
"codecov": "^3.6.5",
"commitlint": "^8.3.5",
"core-js": "^3.6.4",
"eslint": "^6.8.0",
"eslint-config-satya164": "^3.1.6",
"husky": "^4.2.3",
"jest": "^25.1.0",
"jest": "^25.2.7",
"lerna": "^3.20.2",
"prettier": "^2.0.2",
"prettier": "^2.0.4",
"typescript": "^3.8.3"
},
"resolutions": {
Expand Down
4 changes: 2 additions & 2 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"@react-navigation/routers": "^5.2.1",
"escape-string-regexp": "^2.0.0",
"nanoid": "^3.0.2",
"query-string": "^6.11.1",
"query-string": "^6.12.0",
"react-is": "^16.13.0",
"use-subscription": "^1.4.0"
},
Expand All @@ -44,7 +44,7 @@
"del-cli": "^3.0.0",
"react": "~16.9.0",
"react-native-testing-library": "^1.12.0",
"react-test-renderer": "~16.9.0",
"react-test-renderer": "~16.13.1",
"typescript": "^3.8.3"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/BaseNavigationContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ const BaseNavigationContainer = React.forwardRef(
independent,
children,
}: NavigationContainerProps,
ref: React.Ref<NavigationContainerRef>
ref?: React.Ref<NavigationContainerRef>
) {
const parent = React.useContext(NavigationStateContext);

Expand Down
16 changes: 9 additions & 7 deletions packages/core/src/__tests__/useDescriptors.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,10 @@ it('sets initial options with setOptions', () => {
};

const TestScreen = ({ navigation }: any): any => {
navigation.setOptions({
title: 'Hello world',
React.useEffect(() => {
navigation.setOptions({
title: 'Hello world',
});
});

return 'Test screen';
Expand Down Expand Up @@ -315,12 +317,12 @@ it('updates options with setOptions', () => {
};

const TestScreen = ({ navigation }: any): any => {
navigation.setOptions({
title: 'Hello world',
description: 'Something here',
});

React.useEffect(() => {
navigation.setOptions({
title: 'Hello world',
description: 'Something here',
});

const timer = setTimeout(() =>
navigation.setOptions({
title: 'Hello again',
Expand Down
31 changes: 13 additions & 18 deletions packages/core/src/types.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -410,24 +410,19 @@ export type RouteConfig<
}
);

export type NavigationContainerRef =
| (NavigationHelpers<ParamListBase> &
EventConsumer<{ state: { data: { state: NavigationState } } }> & {
/**
* Reset the navigation state of the root navigator to the provided state.
*
* @param state Navigation state object.
*/
resetRoot(
state?: PartialState<NavigationState> | NavigationState
): void;
/**
* Get the rehydrated navigation state of the navigation tree.
*/
getRootState(): NavigationState;
})
| undefined
| null;
export type NavigationContainerRef = NavigationHelpers<ParamListBase> &
EventConsumer<{ state: { data: { state: NavigationState } } }> & {
/**
* Reset the navigation state of the root navigator to the provided state.
*
* @param state Navigation state object.
*/
resetRoot(state?: PartialState<NavigationState> | NavigationState): void;
/**
* Get the rehydrated navigation state of the navigation tree.
*/
getRootState(): NavigationState;
};

export type TypedNavigator<
ParamList extends ParamListBase,
Expand Down
20 changes: 11 additions & 9 deletions packages/drawer/src/views/Drawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -631,15 +631,17 @@ export default class DrawerView extends React.Component<Props> {
>
{renderSceneContent({ progress })}
</View>
{// Disable overlay if sidebar is permanent
drawerType === 'permanent' ? null : (
<TapGestureHandler
enabled={gestureEnabled}
onHandlerStateChange={this.handleTapStateChange}
>
<Overlay progress={progress} style={overlayStyle} />
</TapGestureHandler>
)}
{
// Disable overlay if sidebar is permanent
drawerType === 'permanent' ? null : (
<TapGestureHandler
enabled={gestureEnabled}
onHandlerStateChange={this.handleTapStateChange}
>
<Overlay progress={progress} style={overlayStyle} />
</TapGestureHandler>
)
}
</Animated.View>
{drawerType === 'permanent' ? null : (
<Animated.Code
Expand Down
2 changes: 1 addition & 1 deletion packages/material-bottom-tabs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"del-cli": "^3.0.0",
"react": "~16.9.0",
"react-native": "~0.61.5",
"react-native-paper": "^3.6.0",
"react-native-paper": "^3.7.0",
"react-native-vector-icons": "^6.6.0",
"typescript": "^3.8.3"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/material-top-tabs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"react-native": "~0.61.5",
"react-native-gesture-handler": "^1.6.0",
"react-native-reanimated": "^1.7.0",
"react-native-tab-view": "^2.13.0",
"react-native-tab-view": "^2.14.0",
"typescript": "^3.8.3"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion packages/native/src/NavigationContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ type Props = NavigationContainerProps & {
*/
const NavigationContainer = React.forwardRef(function NavigationContainer(
{ theme = DefaultTheme, ...rest }: Props,
ref: React.Ref<NavigationContainerRef>
ref?: React.Ref<NavigationContainerRef | null>
) {
const refContainer = React.useRef<NavigationContainerRef>(null);

Expand Down
Loading

0 comments on commit de5d985

Please sign in to comment.