Skip to content

Commit eaec523

Browse files
author
majaklajic
authored
Merge pull request #48 from shoutem/feature/platform-release-2.5.1
Extensins as of platform release 2.5.1
2 parents 66ed776 + 0199699 commit eaec523

File tree

477 files changed

+58211
-2034
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

477 files changed

+58211
-2034
lines changed

shoutem.about/app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "shoutem.about",
3-
"version": "2.4.4-rc.1",
3+
"version": "2.5.0",
44
"description": "Shoutem Extension with basic information about business",
55
"peerDependencies": {
66
"@shoutem/redux-io": "*",

shoutem.about/extension.json

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,17 @@
11
{
22
"name": "about",
3-
"version": "2.4.4-rc.1",
4-
"platform": "2.4.*",
3+
"version": "2.5.0",
4+
"platform": "2.5.*",
55
"title": "About",
66
"description": "Show info about your app or your business",
77
"icon": "server/assets/add-about-image.png",
8-
"dependencies": ["shoutem.layouts", "shoutem.cms"],
9-
"categories": ["content"],
8+
"dependencies": [
9+
"shoutem.layouts",
10+
"shoutem.cms"
11+
],
12+
"categories": [
13+
"content"
14+
],
1015
"i18n": {
1116
"locale": "en",
1217
"translationPath": "server/translations/en.json"
@@ -21,6 +26,9 @@
2126
"title": "About",
2227
"icon": "theme://about.png",
2328
"screen": "@.AboutScreen",
29+
"capabilities": [
30+
"shoutem.cms.import-csv"
31+
],
2432
"adminPages": [
2533
{
2634
"page": "shoutem.cms.CmsPage",

shoutem.about/server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"name": "shoutem.about",
3-
"version": "2.4.4-rc.1"
3+
"version": "2.5.0"
44
}

shoutem.advertising/app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "shoutem.advertising",
3-
"version": "2.4.3",
3+
"version": "2.5.0",
44
"description": "Integrate AdMob and embed ads to your application",
55
"dependencies": {
66
"@react-native-firebase/app": "7.1.0",

shoutem.advertising/extension.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"name": "advertising",
33
"title": "Advertising",
4-
"version": "2.4.3",
4+
"version": "2.5.0",
55
"description": "Integrate AdMob and embed ads to your application",
66
"icon": "server/assets/add-advertising-image.png",
7-
"platform": "~2.4.1",
7+
"platform": "2.5.*",
88
"i18n": {
99
"locale": "en",
1010
"translationPath": "server/translations/en.json"

shoutem.advertising/server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "shoutem.advertising",
3-
"version": "2.4.3",
3+
"version": "2.5.0",
44
"description": "Integrate AdMob and embed ads to your application",
55
"scripts": {
66
"lint": "eslint --no-eslintrc -c .eslintrc src/**/*.{js,jsx}",

shoutem.agora/app/components/LocalVideoContainer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ function LocalVideoContainer({ onCameraSwitchPress, style }) {
2121
styleName="clear"
2222
>
2323
<Icon
24-
name="cam-switch"
24+
name="camSwitch"
2525
style={style.switchCameraIcon}
2626
styleName="clear"
2727
/>

shoutem.agora/app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "shoutem.agora",
3-
"version": "2.4.4",
3+
"version": "2.5.1",
44
"dependencies": {
55
"react-native-agora": "~2.9.1-alpha.4",
66
"react-native-stopwatch-timer": "~0.0.21",

shoutem.agora/app/screens/VideoCallScreen.js

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,23 @@ import { connectStyle } from '@shoutem/theme';
99
import { NavigationBar } from 'shoutem.navigation';
1010
import { getUser, isAuthenticated } from 'shoutem.auth';
1111
import { getExtensionSettings } from 'shoutem.application/redux';
12+
import {
13+
checkPermissions,
14+
openDeviceSettings,
15+
PERMISSION_RESULT_TYPES,
16+
PERMISSION_TYPES,
17+
requestPermissions,
18+
} from 'shoutem.permissions';
1219
import WaitingForPeerView from '../components/WaitingForPeerView';
1320
import VideoCallView from '../components/VideoCallView';
1421
import VideoCallStartingView from '../components/VideoCallStartingView';
15-
import { checkPermissions, requestPermissions } from '../services/permissions';
1622
import * as Agora from '../services/agora';
1723
import { images } from '../assets/index';
1824
import { ext } from '../const';
1925

26+
const { CAMERA, MICROPHONE } = PERMISSION_TYPES;
27+
const { GRANTED } = PERMISSION_RESULT_TYPES;
28+
2029
class VideoCallScreen extends PureComponent {
2130
constructor(props) {
2231
super(props);
@@ -43,7 +52,7 @@ class VideoCallScreen extends PureComponent {
4352

4453
componentDidMount() {
4554
// Requesting Mic and Camera permissions
46-
requestPermissions();
55+
requestPermissions(CAMERA, MICROPHONE);
4756

4857
// If new user has joined
4958
RtcEngine.on(Agora.EVENTS.REMOTE_USER_JOINED, (data) => {
@@ -147,7 +156,23 @@ class VideoCallScreen extends PureComponent {
147156
return Agora.authFailedAlert();
148157
}
149158

150-
checkPermissions()
159+
/* this function checks camera and microphone status and opens Settings Page
160+
if permissions have not been granted */
161+
checkPermissions(CAMERA, MICROPHONE)
162+
.then((statuses) => {
163+
const camera = statuses[CAMERA];
164+
const microphone = statuses[MICROPHONE];
165+
166+
if (microphone === GRANTED && camera === GRANTED) {
167+
return true;
168+
}
169+
170+
openDeviceSettings();
171+
return false;
172+
})
173+
.catch((error) => {
174+
console.log('Check permissions failed:', error);
175+
})
151176
.then((permissionsGranted) => {
152177
if (permissionsGranted) {
153178
return this.startCall();

shoutem.agora/app/services/permissions.js

Lines changed: 0 additions & 75 deletions
This file was deleted.

0 commit comments

Comments
 (0)