Skip to content

Commit

Permalink
bring it up to date with latest changes in NavigationExperimental
Browse files Browse the repository at this point in the history
- [x] bump react
- [x] bump react-native
- [x] bump react-router
  • Loading branch information
jmurzy committed Jun 7, 2016
1 parent 2f9a0d8 commit 13e0d2a
Show file tree
Hide file tree
Showing 18 changed files with 284 additions and 274 deletions.
2 changes: 1 addition & 1 deletion examples/Aviato/app/components/Discover/Header.ios.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export default class Header extends Component {

renderTitleComponent(props) {
const { scene } = props;
const title = String(scene.navigationState.key || '');
const title = String(scene.route.key || '');
return (
<NavigationHeaderTitle>
{title}
Expand Down
6 changes: 3 additions & 3 deletions examples/Aviato/app/components/index.ios.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* @noflow */

import React, { Component, PropTypes } from 'react';
import React, { Component } from 'react';
import {
NavigationExperimental,
View,
Expand Down Expand Up @@ -37,7 +37,7 @@ export const stackHeaderComponent = (backgroundColor, marginTop = 0) => {

renderTitleComponent(props) {
const { scene } = props;
const title = String(scene.navigationState.key || '');
const title = String(scene.route.key || '');
return (
<NavigationHeaderTitle>
{title}
Expand Down Expand Up @@ -89,7 +89,7 @@ export const tabHeaderComponent = (backgroundColor, marginTop = 0) => {

renderTitleComponent(props) {
const { scene } = props;
const title = String(scene.navigationState.key || '');
const title = String(scene.route.key || '');
return (
<NavigationHeaderTitle>
{title}
Expand Down
5 changes: 2 additions & 3 deletions examples/Aviato/app/routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import { NAVIGATION_HEADER_HEIGHT } from './components/styles';
const SECOND_HEADER = NAVIGATION_HEADER_HEIGHT;
const THIRD_HEADER = NAVIGATION_HEADER_HEIGHT * 2;


/**
* NOTE: The route hierarchy below is deliberately complex to demonstrate all
* capabilities of this library, don't approach the information architecture
Expand All @@ -43,8 +42,8 @@ const THIRD_HEADER = NAVIGATION_HEADER_HEIGHT * 2;
* - has a 'public' ('/', entry point of the app) and a 'private' section
* (/home/user/private) which can be navigated by two buttons in the bottom
* of the page
* - The 'private' section (/home/user/private) again has some subroutes,
* which can be navigated to by opening the side menu and
* - The 'private' section (/home/user/private) again has some subroutes,
* which can be navigated to by opening the side menu and
* selecting 'Private settings' or 'Private Info'
* - a 'Following' (/home/following) tab
* - a 'Bar' tab (/home/following-bar), a parameterized version of the 'Following' tab
Expand Down
6 changes: 3 additions & 3 deletions examples/Aviato/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
"start": "node node_modules/react-native/local-cli/cli.js start"
},
"dependencies": {
"react": "15.1.0-alpha.1",
"react-native": "v0.27.0-rc",
"react": "^15.1.0",
"react-native": "0.28.0-rc.0",
"react-native-side-menu": "^0.19.0",
"react-router": "^2.3.0",
"react-router": "3.0.0-alpha.1",
"react-router-native": "file:../../"
}
}
6 changes: 3 additions & 3 deletions modules/Reducer.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
/* @flow */

import { defaultReducer } from './ReducerUtils';
import type { EnhancedNavigationState, NavigationAction } from './TypeDefinition';
import type { EnhancedNavigationRoute, NavigationAction } from './TypeDefinition';

export default (
state: ?EnhancedNavigationState,
state: ?EnhancedNavigationRoute,
action: NavigationAction,
): EnhancedNavigationState => {
): EnhancedNavigationRoute => {
const { nextNavigationState } = action;

if (!state) {
Expand Down
Loading

1 comment on commit 13e0d2a

@Andreyco
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome work here!

Please sign in to comment.