Skip to content
This repository has been archived by the owner on Jan 14, 2020. It is now read-only.

Upgrades to Apollos 1.2.0-beta.6 #326

Merged
merged 14 commits into from
Oct 21, 2019
2 changes: 1 addition & 1 deletion packages/apollos-church-api/apollos.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"version": "1.2.0-beta.4",
"version": "1.2.0-beta.6",
"environment": "api"
}
32 changes: 16 additions & 16 deletions packages/apollos-church-api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,17 @@
"testEnvironment": "node"
},
"dependencies": {
"@apollosproject/config": "^1.2.0-beta.4",
"@apollosproject/data-connector-analytics": "^1.2.0-beta.4",
"@apollosproject/data-connector-bible": "^1.2.0-beta.4",
"@apollosproject/data-connector-church-online": "^1.2.0-beta.4",
"@apollosproject/data-connector-onesignal": "^1.2.0-beta.4",
"@apollosproject/data-connector-passes": "^1.2.0-beta.4",
"@apollosproject/data-connector-rock": "^1.2.0-beta.4",
"@apollosproject/data-connector-twilio": "^1.2.0-beta.4",
"@apollosproject/data-schema": "^1.2.0-beta.4",
"@apollosproject/rock-apollo-data-source": "^1.2.0-beta.4",
"@apollosproject/server-core": "^1.2.0-beta.4",
"@apollosproject/config": "^1.2.0-beta.6",
"@apollosproject/data-connector-analytics": "^1.2.0-beta.6",
"@apollosproject/data-connector-bible": "^1.2.0-beta.6",
"@apollosproject/data-connector-church-online": "^1.2.0-beta.6",
"@apollosproject/data-connector-onesignal": "^1.2.0-beta.6",
"@apollosproject/data-connector-passes": "^1.2.0-beta.6",
"@apollosproject/data-connector-rock": "^1.2.0-beta.6",
"@apollosproject/data-connector-twilio": "^1.2.0-beta.6",
"@apollosproject/data-schema": "^1.2.0-beta.6",
"@apollosproject/rock-apollo-data-source": "^1.2.0-beta.6",
"@apollosproject/server-core": "^1.2.0-beta.6",
"@bugsnag/js": "^6.2.0",
"@bugsnag/plugin-express": "^6.2.0",
"apollo-server": "^2.0.5",
Expand All @@ -51,13 +51,13 @@
"randomcolor": "0.5.3",
"apollo-server-express": "2.4.8",
"express": "^4.17.0",
"@apollosproject/data-connector-algolia-search": "^1.2.0-beta.4",
"@apollosproject/data-connector-cloudinary": "^1.2.0-beta.4",
"@apollosproject/data-connector-redis-cache": "^1.2.0-beta.4"
"@apollosproject/data-connector-algolia-search": "^1.2.0-beta.6",
"@apollosproject/data-connector-cloudinary": "^1.2.0-beta.6",
"@apollosproject/data-connector-redis-cache": "^1.2.0-beta.6"
},
"devDependencies": {
"@apollosproject/apollo-server-env-mock": "^1.2.0-beta.4",
"@apollosproject/babel-preset-apollos": "^1.2.0-beta.4",
"@apollosproject/apollo-server-env-mock": "^1.2.0-beta.6",
"@apollosproject/babel-preset-apollos": "^1.2.0-beta.6",
"@babel/cli": "^7.4.5",
"@babel/core": "^7.4.5",
"codecov": "3.0.2",
Expand Down
8 changes: 4 additions & 4 deletions packages/apollos-data-prayer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
"testEnvironment": "node"
},
"dependencies": {
"@apollosproject/data-schema": "^1.2.0-beta.4",
"@apollosproject/server-core": "^1.2.0-beta.4",
"@apollosproject/data-schema": "^1.2.0-beta.6",
"@apollosproject/server-core": "^1.2.0-beta.6",
"lodash": "^4.17.11",
"moment-timezone": "^0.5.25",
"natural": "^0.6.2",
Expand All @@ -32,8 +32,8 @@
"@apollosproject/rock-apollo-data-source": "*"
},
"devDependencies": {
"@apollosproject/apollo-server-env-mock": "^1.2.0-beta.4",
"@apollosproject/babel-preset-apollos": "^1.2.0-beta.4",
"@apollosproject/apollo-server-env-mock": "^1.2.0-beta.6",
"@apollosproject/babel-preset-apollos": "^1.2.0-beta.6",
"jest": "^23.6.0",
"jest-fetch-mock": "2.1.1"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/newspringchurchapp/apollos.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"version": "1.2.0-beta.4",
"version": "1.2.0-beta.6",
"environment": "client"
}
8 changes: 4 additions & 4 deletions packages/newspringchurchapp/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ PODS:
- React
- RNCAsyncStorage (1.6.1):
- React
- RNDeviceInfo (2.1.3):
- RNDeviceInfo (4.0.1):
- React
- RNGestureHandler (1.3.0):
- React
Expand Down Expand Up @@ -187,7 +187,7 @@ DEPENDENCIES:
- yoga (from `../node_modules/react-native/ReactCommon/yoga`)

SPEC REPOS:
https://github.com/cocoapods/specs.git:
trunk:
- Amplitude-iOS
- boost-for-react-native
- OneSignal
Expand Down Expand Up @@ -326,7 +326,7 @@ SPEC CHECKSUMS:
rn-fetch-blob: 651b8d076b43d0d7aa294a3d9ec16c00aab8bef9
RNAirplay: 75777dd55dafbd3687703c3eb9c290ea6cc43248
RNCAsyncStorage: 2e2e3feb9bdadc752a026703d8c4065ca912e75a
RNDeviceInfo: a67eef80ee1e68e1824f3ed3dc0ccf9e2d4fdc59
RNDeviceInfo: 687c1b2ab6d86ff1ca1208783320cd144138c7f2
RNGestureHandler: 5329a942fce3d41c68b84c2c2276ce06a696d8b0
RNInAppBrowser: 9d1ffb9db0d0cbdf03f528f1f0624b2c533b93fd
RNReanimated: c8dd490ca98a4edcba229bfa49f2516c95a43afb
Expand All @@ -336,4 +336,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 06c9ab780944d7b50a45ae6a20b26a8880c01405

COCOAPODS: 1.7.5
COCOAPODS: 1.8.3
39 changes: 32 additions & 7 deletions packages/newspringchurchapp/jest.setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,19 @@ import React from 'react';
import { NativeModules } from 'react-native';
// We ran into an issue where SafeAreaView would break jest tests.

jest.mock(
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
'../apollos-ui-kit/node_modules/react-native-safe-area-context/',
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
() => ({
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
SafeAreaConsumer: ({ children }) =>
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
children({ top: 0, bottom: 0, left: 0, right: 0 }),
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
SafeAreaProvider: ({ children }) => children,
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
})
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
);
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
jest.mock('react-native-safe-area-context', () => ({
SafeAreaConsumer: ({ children }) =>
children({ top: 0, bottom: 0, left: 0, right: 0 }),
SafeAreaProvider: ({ children }) => children,
}));
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
jest.mock('react-navigation', () => {
const ActualNavigation = require.requireActual('react-navigation');
return {
Expand All @@ -10,6 +23,19 @@ jest.mock('react-navigation', () => {
};
});

jest.mock('react-native-music-control', () => ({
enableBackgroundMode: jest.fn(),
enableControl: jest.fn(),
on: jest.fn(),
setNowPlaying: jest.fn(),
STATE_PLAYING: false,
STATE_PAUSED: true,
}));

jest.mock('react-native-config', () => ({
ONE_SIGNAL_KEY: 'doesntmatter',
}));

jest.mock('Animated', () => {
const ActualAnimated = require.requireActual('Animated');
return {
Expand All @@ -31,26 +57,24 @@ jest.mock('Animated', () => {
};
});

jest.mock('react-native-safe-area-context', () => ({
SafeAreaConsumer: ({ children }) =>
children({ top: 0, bottom: 0, left: 0, right: 0 }),
SafeAreaProvider: ({ children }) => children,
}));

jest.mock('react-native-safari-view', () => ({
isAvailable: jest.fn().mockImplementation(() => Promise.resolve(true)),
show: jest.fn(),
}));

jest.mock('react-native-device-info', () => ({
getUniqueID: () => 'id-123',
getUniqueId: () => 'id-123',
getSystemVersion: () => 'sys-version-123',
getModel: () => 'ios',
getVersion: () => 'version-123',
getBuildNumber: () => 0,
}));

jest.mock('rn-fetch-blob', () => 'Fetch');
jest.mock(
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
'@apollosproject/ui-passes/node_modules/rn-fetch-blob',
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
() => 'Fetch'
redreceipt marked this conversation as resolved.
Show resolved Hide resolved
);
redreceipt marked this conversation as resolved.
Show resolved Hide resolved

jest.mock('@apollosproject/ui-analytics', () => ({
track: () => '',
Expand Down Expand Up @@ -148,6 +172,7 @@ jest.mock('react-native-gesture-handler', () => {
});

jest.mock('react-native-video', () => 'Video');

jest.mock('NativeEventEmitter');

jest.mock('react-native-maps');
Expand Down
24 changes: 12 additions & 12 deletions packages/newspringchurchapp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,16 +78,16 @@
}
},
"dependencies": {
"@apollosproject/ui-analytics": "^1.2.0-beta.4",
"@apollosproject/ui-auth": "^1.2.0-beta.4",
"@apollosproject/ui-htmlview": "^1.2.0-beta.4",
"@apollosproject/ui-kit": "^1.2.0-beta.4",
"@apollosproject/ui-media-player": "^1.2.0-beta.4",
"@apollosproject/ui-notifications": "^1.2.0-beta.4",
"@apollosproject/ui-onboarding": "^1.2.0-beta.4",
"@apollosproject/ui-passes": "^1.2.0-beta.4",
"@apollosproject/ui-scripture": "^1.2.0-beta.4",
"@apollosproject/ui-storybook": "^1.2.0-beta.4",
"@apollosproject/ui-analytics": "^1.2.0-beta.6",
"@apollosproject/ui-auth": "^1.2.0-beta.6",
"@apollosproject/ui-htmlview": "^1.2.0-beta.6",
"@apollosproject/ui-kit": "^1.2.0-beta.6",
"@apollosproject/ui-media-player": "^1.2.0-beta.6",
"@apollosproject/ui-notifications": "^1.2.0-beta.6",
"@apollosproject/ui-onboarding": "^1.2.0-beta.6",
"@apollosproject/ui-passes": "^1.2.0-beta.6",
"@apollosproject/ui-scripture": "^1.2.0-beta.6",
"@apollosproject/ui-storybook": "^1.2.0-beta.6",
"@react-native-community/async-storage": "^1.5.1",
"apollo-cache-inmemory": "1.5.1",
"apollo-cache-persist": "0.1.1",
Expand Down Expand Up @@ -116,7 +116,7 @@
"react-native-actionsheet": "^2.4.2",
"react-native-amplitude-analytics": "^0.2.7",
"react-native-config": "^0.11.7",
"react-native-device-info": "^2.1.2",
"react-native-device-info": "^4.0.1",
"react-native-emoji": "^1.8.0",
"react-native-geolocation-service": "^3.0.0",
"react-native-gesture-handler": "^1.3.0",
Expand Down Expand Up @@ -153,4 +153,4 @@
"assets/fonts"
]
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import React, { PureComponent } from 'react';
import PropTypes from 'prop-types';
import { SafeAreaView } from 'react-navigation';
import { Query } from 'react-apollo';
import { PagerScroll } from 'react-native-tab-view';

import {
ErrorCard,
Expand Down Expand Up @@ -98,6 +99,7 @@ class DevotionalContentItem extends PureComponent {
return (
<TabView
routes={tabRoutes}
renderPager={(props) => <PagerScroll {...props} />}
renderScene={SceneMap({
content: this.contentRoute({ scriptures, loading }),
scripture: this.scriptureRoute({ scriptures, loading }),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,28 @@ class HorizontalContentFeed extends Component {
}),
};

renderItem = ({ item }) => {
const itemId = get(item, 'id', '');
const disabled = get(item, 'id', '') === this.props.contentId;
return (
<TouchableScale
onPress={() => this.handleOnPressItem(item)}
disabled={disabled}
>
<HorizontalContentCardConnected
contentId={itemId}
disabled={disabled}
/>
</TouchableScale>
);
};

handleOnPressItem = (item) => {
this.props.navigation.push('ContentSingle', {
itemId: item.id,
});
};

renderItem = ({ item }) => (
<TouchableScale onPress={() => this.handleOnPressItem(item)}>
<HorizontalContentCardConnected contentId={get(item, 'id', '')} />
</TouchableScale>
);

renderFeed = ({ data, loading, error, fetchMore }) => {
if (error) return null;
if (loading) return null;
Expand Down
1 change: 1 addition & 0 deletions packages/newspringchurchapp/src/ui/WebBrowser/Browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ export const GET_ROCK_AUTH_DETAILS = gql`
export const getRockAuthDetails = async () => {
const { data: { currentUser: { rock } = {} } = {} } = await client.query({
query: GET_ROCK_AUTH_DETAILS,
fetchPolicy: 'network-only',
});
return rock;
};
Expand Down
Loading