@stream-io/video-react-native-sdk 0.7.22 → 0.7.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/dist/commonjs/components/Call/CallControls/AcceptCallButton.js +3 -1
- package/dist/commonjs/components/Call/CallControls/AcceptCallButton.js.map +1 -1
- package/dist/commonjs/components/Call/CallControls/HangupCallButton.js +3 -2
- package/dist/commonjs/components/Call/CallControls/HangupCallButton.js.map +1 -1
- package/dist/commonjs/components/Call/CallControls/RejectCallButton.js +2 -1
- package/dist/commonjs/components/Call/CallControls/RejectCallButton.js.map +1 -1
- package/dist/commonjs/components/Call/CallControls/internal/ReactionsPicker.js +3 -1
- package/dist/commonjs/components/Call/CallControls/internal/ReactionsPicker.js.map +1 -1
- package/dist/commonjs/components/Call/Lobby/JoinCallButton.js +3 -1
- package/dist/commonjs/components/Call/Lobby/JoinCallButton.js.map +1 -1
- package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js +4 -2
- package/dist/commonjs/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -1
- package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +3 -1
- package/dist/commonjs/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -1
- package/dist/commonjs/components/Livestream/LivestreamPlayer/LivestreamPlayer.js +20 -4
- package/dist/commonjs/components/Livestream/LivestreamPlayer/LivestreamPlayer.js.map +1 -1
- package/dist/commonjs/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js +3 -1
- package/dist/commonjs/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js.map +1 -1
- package/dist/commonjs/contexts/BackgroundFilters.js +1 -3
- package/dist/commonjs/contexts/BackgroundFilters.js.map +1 -1
- package/dist/commonjs/hooks/push/useIosVoipPushEventsSetupEffect.js +9 -5
- package/dist/commonjs/hooks/push/useIosVoipPushEventsSetupEffect.js.map +1 -1
- package/dist/commonjs/hooks/useAndroidKeepCallAliveEffect.js +4 -2
- package/dist/commonjs/hooks/useAndroidKeepCallAliveEffect.js.map +1 -1
- package/dist/commonjs/hooks/usePermissionRequest.js +2 -1
- package/dist/commonjs/hooks/usePermissionRequest.js.map +1 -1
- package/dist/commonjs/utils/getAndroidDefaultRingtoneUrl.js +3 -1
- package/dist/commonjs/utils/getAndroidDefaultRingtoneUrl.js.map +1 -1
- package/dist/commonjs/utils/push/android.js +7 -4
- package/dist/commonjs/utils/push/android.js.map +1 -1
- package/dist/commonjs/utils/push/ios.js +4 -2
- package/dist/commonjs/utils/push/ios.js.map +1 -1
- package/dist/commonjs/utils/push/libs/firebaseMessaging.js +3 -1
- package/dist/commonjs/utils/push/libs/firebaseMessaging.js.map +1 -1
- package/dist/commonjs/utils/push/utils.js +8 -4
- package/dist/commonjs/utils/push/utils.js.map +1 -1
- package/dist/commonjs/version.js +1 -1
- package/dist/module/components/Call/CallControls/AcceptCallButton.js +3 -1
- package/dist/module/components/Call/CallControls/AcceptCallButton.js.map +1 -1
- package/dist/module/components/Call/CallControls/HangupCallButton.js +3 -1
- package/dist/module/components/Call/CallControls/HangupCallButton.js.map +1 -1
- package/dist/module/components/Call/CallControls/RejectCallButton.js +3 -2
- package/dist/module/components/Call/CallControls/RejectCallButton.js.map +1 -1
- package/dist/module/components/Call/CallControls/internal/ReactionsPicker.js +3 -1
- package/dist/module/components/Call/CallControls/internal/ReactionsPicker.js.map +1 -1
- package/dist/module/components/Call/Lobby/JoinCallButton.js +3 -1
- package/dist/module/components/Call/Lobby/JoinCallButton.js.map +1 -1
- package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js +5 -3
- package/dist/module/components/Livestream/LivestreamControls/HostStartStreamButton.js.map +1 -1
- package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js +3 -1
- package/dist/module/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.js.map +1 -1
- package/dist/module/components/Livestream/LivestreamPlayer/LivestreamPlayer.js +20 -4
- package/dist/module/components/Livestream/LivestreamPlayer/LivestreamPlayer.js.map +1 -1
- package/dist/module/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js +3 -1
- package/dist/module/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.js.map +1 -1
- package/dist/module/contexts/BackgroundFilters.js +1 -3
- package/dist/module/contexts/BackgroundFilters.js.map +1 -1
- package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js +10 -6
- package/dist/module/hooks/push/useIosVoipPushEventsSetupEffect.js.map +1 -1
- package/dist/module/hooks/useAndroidKeepCallAliveEffect.js +5 -3
- package/dist/module/hooks/useAndroidKeepCallAliveEffect.js.map +1 -1
- package/dist/module/hooks/usePermissionRequest.js +3 -2
- package/dist/module/hooks/usePermissionRequest.js.map +1 -1
- package/dist/module/utils/getAndroidDefaultRingtoneUrl.js +3 -1
- package/dist/module/utils/getAndroidDefaultRingtoneUrl.js.map +1 -1
- package/dist/module/utils/push/android.js +8 -5
- package/dist/module/utils/push/android.js.map +1 -1
- package/dist/module/utils/push/ios.js +4 -2
- package/dist/module/utils/push/ios.js.map +1 -1
- package/dist/module/utils/push/libs/firebaseMessaging.js +3 -1
- package/dist/module/utils/push/libs/firebaseMessaging.js.map +1 -1
- package/dist/module/utils/push/utils.js +9 -5
- package/dist/module/utils/push/utils.js.map +1 -1
- package/dist/module/version.js +1 -1
- package/dist/typescript/components/Call/CallControls/AcceptCallButton.d.ts.map +1 -1
- package/dist/typescript/components/Call/CallControls/HangupCallButton.d.ts.map +1 -1
- package/dist/typescript/components/Call/CallControls/RejectCallButton.d.ts.map +1 -1
- package/dist/typescript/components/Call/CallControls/internal/ReactionsPicker.d.ts.map +1 -1
- package/dist/typescript/components/Call/Lobby/JoinCallButton.d.ts.map +1 -1
- package/dist/typescript/components/Livestream/LivestreamControls/HostStartStreamButton.d.ts.map +1 -1
- package/dist/typescript/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.d.ts.map +1 -1
- package/dist/typescript/components/Livestream/LivestreamPlayer/LivestreamPlayer.d.ts.map +1 -1
- package/dist/typescript/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.d.ts.map +1 -1
- package/dist/typescript/contexts/BackgroundFilters.d.ts.map +1 -1
- package/dist/typescript/hooks/push/useIosVoipPushEventsSetupEffect.d.ts.map +1 -1
- package/dist/typescript/hooks/useAndroidKeepCallAliveEffect.d.ts.map +1 -1
- package/dist/typescript/hooks/usePermissionRequest.d.ts.map +1 -1
- package/dist/typescript/utils/getAndroidDefaultRingtoneUrl.d.ts.map +1 -1
- package/dist/typescript/utils/push/android.d.ts.map +1 -1
- package/dist/typescript/utils/push/ios.d.ts.map +1 -1
- package/dist/typescript/utils/push/libs/firebaseMessaging.d.ts.map +1 -1
- package/dist/typescript/utils/push/utils.d.ts.map +1 -1
- package/dist/typescript/version.d.ts +1 -1
- package/package.json +3 -3
- package/src/components/Call/CallControls/AcceptCallButton.tsx +3 -1
- package/src/components/Call/CallControls/HangupCallButton.tsx +3 -1
- package/src/components/Call/CallControls/RejectCallButton.tsx +3 -2
- package/src/components/Call/CallControls/internal/ReactionsPicker.tsx +3 -2
- package/src/components/Call/Lobby/JoinCallButton.tsx +3 -1
- package/src/components/Livestream/LivestreamControls/HostStartStreamButton.tsx +5 -3
- package/src/components/Livestream/LivestreamControls/ViewerLeaveStreamButton.tsx +3 -1
- package/src/components/Livestream/LivestreamPlayer/LivestreamPlayer.tsx +21 -4
- package/src/components/Participant/FloatingParticipantView/FloatingView/AnimatedFloatingView.tsx +4 -1
- package/src/contexts/BackgroundFilters.tsx +1 -3
- package/src/hooks/push/useIosVoipPushEventsSetupEffect.ts +10 -6
- package/src/hooks/useAndroidKeepCallAliveEffect.ts +6 -3
- package/src/hooks/usePermissionRequest.tsx +7 -2
- package/src/utils/getAndroidDefaultRingtoneUrl.ts +3 -1
- package/src/utils/push/android.ts +15 -5
- package/src/utils/push/ios.ts +4 -3
- package/src/utils/push/libs/firebaseMessaging.ts +5 -1
- package/src/utils/push/utils.ts +18 -5
- package/src/version.ts +1 -1
package/src/utils/push/ios.ts
CHANGED
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
processCallFromPushInBackground,
|
|
16
16
|
} from './utils';
|
|
17
17
|
import { getExpoNotificationsLib, getPushNotificationIosLib } from './libs';
|
|
18
|
-
import { StreamVideoClient } from '@stream-io/video-client';
|
|
18
|
+
import { StreamVideoClient, getLogger } from '@stream-io/video-client';
|
|
19
19
|
import { setPushLogoutCallback } from '../internal/pushLogoutCallback';
|
|
20
20
|
import notifee, { EventType } from '@notifee/react-native';
|
|
21
21
|
|
|
@@ -139,9 +139,10 @@ export async function initIosNonVoipToken(
|
|
|
139
139
|
const setDeviceToken = async (token: string) => {
|
|
140
140
|
setPushLogoutCallback(async () => {
|
|
141
141
|
try {
|
|
142
|
-
client.removeDevice(token);
|
|
142
|
+
await client.removeDevice(token);
|
|
143
143
|
} catch (err) {
|
|
144
|
-
|
|
144
|
+
const logger = getLogger(['initIosNonVoipToken']);
|
|
145
|
+
logger('warn', 'Failed to remove apn token from stream', err);
|
|
145
146
|
}
|
|
146
147
|
});
|
|
147
148
|
const push_provider_name = pushConfig.ios.pushProviderName;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { getLogger } from '@stream-io/video-client';
|
|
2
|
+
|
|
1
3
|
export type { FirebaseMessagingTypes } from '@react-native-firebase/messaging';
|
|
2
4
|
export type FirebaseMessagingType =
|
|
3
5
|
typeof import('@react-native-firebase/messaging').default;
|
|
@@ -22,7 +24,9 @@ export function getFirebaseMessagingLib() {
|
|
|
22
24
|
|
|
23
25
|
export function getFirebaseMessagingLibNoThrow(isExpo: boolean) {
|
|
24
26
|
if (!messaging) {
|
|
25
|
-
|
|
27
|
+
const logger = getLogger(['getFirebaseMessagingLibNoThrow']);
|
|
28
|
+
logger(
|
|
29
|
+
'warn',
|
|
26
30
|
`${
|
|
27
31
|
isExpo
|
|
28
32
|
? 'In Expo, @react-native-firebase/messaging library is required to receive ringing notifications in app killed state for Android.'
|
package/src/utils/push/utils.ts
CHANGED
|
@@ -1,4 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
Call,
|
|
3
|
+
RxUtils,
|
|
4
|
+
StreamVideoClient,
|
|
5
|
+
getLogger,
|
|
6
|
+
} from '@stream-io/video-client';
|
|
2
7
|
import type {
|
|
3
8
|
NonRingingPushEvent,
|
|
4
9
|
StreamVideoConfig,
|
|
@@ -71,7 +76,8 @@ export const processCallFromPushInBackground = async (
|
|
|
71
76
|
return;
|
|
72
77
|
}
|
|
73
78
|
} catch (e) {
|
|
74
|
-
|
|
79
|
+
const logger = getLogger(['processCallFromPushInBackground']);
|
|
80
|
+
logger('error', 'failed to create video client', e);
|
|
75
81
|
return;
|
|
76
82
|
}
|
|
77
83
|
await processCallFromPush(videoClient, call_cid, action);
|
|
@@ -93,7 +99,8 @@ export const processCallFromPush = async (
|
|
|
93
99
|
try {
|
|
94
100
|
callFromPush = await client.onRingingCall(call_cid);
|
|
95
101
|
} catch (e) {
|
|
96
|
-
|
|
102
|
+
const logger = getLogger(['processCallFromPush']);
|
|
103
|
+
logger('error', 'failed to fetch call from push notification', e);
|
|
97
104
|
return;
|
|
98
105
|
}
|
|
99
106
|
// note: when action was pressed or delivered, we dont need to do anything as the only thing is to do is to get the call which adds it to the client
|
|
@@ -104,7 +111,12 @@ export const processCallFromPush = async (
|
|
|
104
111
|
await callFromPush.leave({ reject: true });
|
|
105
112
|
}
|
|
106
113
|
} catch (e) {
|
|
107
|
-
|
|
114
|
+
const logger = getLogger(['processCallFromPush']);
|
|
115
|
+
logger(
|
|
116
|
+
'error',
|
|
117
|
+
`failed to process ${action} call from push notification`,
|
|
118
|
+
e
|
|
119
|
+
);
|
|
108
120
|
}
|
|
109
121
|
};
|
|
110
122
|
|
|
@@ -132,7 +144,8 @@ export const processNonIncomingCallFromPush = async (
|
|
|
132
144
|
await callFromPush.get();
|
|
133
145
|
}
|
|
134
146
|
} catch (e) {
|
|
135
|
-
|
|
147
|
+
const logger = getLogger(['processNonIncomingCallFromPush']);
|
|
148
|
+
logger('error', 'failed to fetch call from push notification', e);
|
|
136
149
|
return;
|
|
137
150
|
}
|
|
138
151
|
onNewCallNotification(callFromPush, nonRingingNotificationType);
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = '0.7.
|
|
1
|
+
export const version = '0.7.24';
|