@stream-io/video-react-native-sdk 0.0.1 → 0.0.3
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/README.md +23 -29
- package/dist/src/providers/MediaStreamManagement.js +6 -2
- package/dist/src/providers/MediaStreamManagement.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
- package/src/providers/MediaStreamManagement.tsx +10 -2
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,19 @@
|
|
|
2
2
|
|
|
3
3
|
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
|
|
4
4
|
|
|
5
|
+
### [0.0.3](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-native-sdk-0.0.2...@stream-io/video-react-native-sdk-0.0.3) (2023-09-05)
|
|
6
|
+
|
|
7
|
+
### Dependency Updates
|
|
8
|
+
|
|
9
|
+
* `@stream-io/video-client` updated to version `0.1.0`
|
|
10
|
+
* `@stream-io/video-react-bindings` updated to version `0.2.15`
|
|
11
|
+
### [0.0.2](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-native-sdk-0.0.1...@stream-io/video-react-native-sdk-0.0.2) (2023-09-05)
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### Bug Fixes
|
|
15
|
+
|
|
16
|
+
* handle media device initial state when media status is undefined ([#1051](https://github.com/GetStream/stream-video-js/issues/1051)) ([4c9ff8d](https://github.com/GetStream/stream-video-js/commit/4c9ff8dda64eb5939ab1bae42734003da9aa768b))
|
|
17
|
+
|
|
5
18
|
### [0.0.1](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-native-sdk-0.0.1-alpha.415...@stream-io/video-react-native-sdk-0.0.1) (2023-08-31)
|
|
6
19
|
|
|
7
20
|
### Dependency Updates
|
package/README.md
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
# Official React Native SDK for [Stream Video](https://getstream.io/video/docs/)
|
|
2
|
-
## 🚧 WARNING This package is not yet stable, it is for internal use only. For more information check out our video product page. 🚧
|
|
3
2
|
|
|
4
|
-
<img src="
|
|
3
|
+
<img src="https://github.com/GetStream/stream-video-js/assets/11586388/954bab42-303d-45a7-843f-ab244a994b82" alt="Stream Video for React Header image" style="box-shadow: 0 3px 10px rgb(0 0 0 / 0.2); border-radius: 1rem" />
|
|
5
4
|
|
|
6
5
|
[](https://sonarcloud.io/summary/new_code?id=GetStream_stream-video-js)
|
|
7
6
|
[](https://github.com/GetStream/stream-video-js/releases)
|
|
@@ -9,7 +8,7 @@
|
|
|
9
8
|
|
|
10
9
|
## **Quick Links**
|
|
11
10
|
- [Register](https://getstream.io/chat/trial/) to get an API key for Stream Video
|
|
12
|
-
- [React Native Video Tutorial]()
|
|
11
|
+
- [React Native Video Tutorial](https://getstream.io/video/docs/reactnative/tutorials/video-calling/)
|
|
13
12
|
- [Sample application](https://github.com/GetStream/stream-video-js/tree/main/sample-apps/react-native/dogfood)
|
|
14
13
|
|
|
15
14
|
## **What is Stream?**
|
|
@@ -18,15 +17,15 @@ Stream allows developers to rapidly deploy scalable feeds, chat messaging and vi
|
|
|
18
17
|
|
|
19
18
|
With Stream's video components, you can use their SDK to build in-app video calling, audio rooms, audio calls, or live streaming. The best place to get started is with their tutorials:
|
|
20
19
|
|
|
21
|
-
- Video & Audio Calling Tutorial
|
|
22
|
-
- Audio Rooms Tutorial
|
|
23
|
-
- Livestreaming Tutorial
|
|
20
|
+
- [Video & Audio Calling Tutorial](https://getstream.io/video/docs/reactnative/tutorials/video-calling/)
|
|
21
|
+
- [Audio Rooms Tutorial](https://getstream.io/video/docs/reactnative/tutorials/audio-room/)
|
|
22
|
+
- [Livestreaming Tutorial](https://getstream.io/video/docs/reactnative/tutorials/livestream/)
|
|
24
23
|
|
|
25
24
|
Stream provides UI components and state handling that make it easy to build video calling for your app. All calls run on Stream's network of edge servers around the world, ensuring optimal latency and reliability.
|
|
26
25
|
|
|
27
26
|
## 👩💻 Free for Makers 👨💻
|
|
28
27
|
|
|
29
|
-
Stream is free for most side and hobby projects. To qualify, your project/company needs to have < 5 team members and < $10k in monthly revenue. Makers get $100 in monthly credit for video for free.
|
|
28
|
+
Stream is free for most side and hobby projects. To qualify, your project/company needs to have < 5 team members and < $10k in monthly revenue. Makers get $100 in monthly credit for [video](https://getstream.io/video/) for free.
|
|
30
29
|
|
|
31
30
|
## 💡Supported Features💡
|
|
32
31
|
|
|
@@ -62,7 +61,7 @@ Projects are broken up into directories containing the source code for each proj
|
|
|
62
61
|
The React Native SDK is a part of the Stream Video JS monorepo.
|
|
63
62
|
The monorepo consists of multiple folders, the most important of which are `packages` and `sample-apps`.
|
|
64
63
|
- The `packages` folder contains the packages each of which is a separate npm package. The React Native SDK is one of the packages alongside:
|
|
65
|
-
- Our shared JS Call Engine (`client`).
|
|
64
|
+
- [Our shared JS Call Engine](https://github.com/GetStream/stream-video-js/tree/main/packages/client) (`client`).
|
|
66
65
|
- [React Bindings](../react-bindings) (`react-bindings`).
|
|
67
66
|
- [React SDK](../react-sdk#official-react-sdk-for-stream-video) (`react-sdk`).
|
|
68
67
|
|
|
@@ -73,10 +72,8 @@ React Native's most relevant sample app is the `dogfooding` app which is a compl
|
|
|
73
72
|
|
|
74
73
|
|
|
75
74
|
## **Requirements** 🛠
|
|
76
|
-
Before running this project please ensure you have set up your development environment for React Native.
|
|
75
|
+
Before running this project please ensure you have set up your [development environment for React Native](https://reactnative.dev/docs/environment-setup).
|
|
77
76
|
The Stream Video React Native SDK supports apps created with the React Native CLI.
|
|
78
|
-
Apps created with Expo are currently not officially supported.
|
|
79
|
-
|
|
80
77
|
|
|
81
78
|
## **Contributing** 🤝
|
|
82
79
|
- How can I submit a sample app?
|
|
@@ -88,52 +85,49 @@ Apps created with Expo are currently not officially supported.
|
|
|
88
85
|
## Roadmap
|
|
89
86
|
Stream's video roadmap and changelog are available [here](https://github.com/GetStream/protocol/discussions/127).
|
|
90
87
|
|
|
91
|
-
###
|
|
88
|
+
### 0.1 milestone
|
|
92
89
|
- [x] Push notification- Android
|
|
93
90
|
- [x] Chat integration guide
|
|
94
91
|
- [x] Simulcasting- Android
|
|
95
92
|
- [x] Push notification- VoIP iOS
|
|
96
|
-
- [x] Reconnection
|
|
93
|
+
- [x] Reconnection
|
|
97
94
|
- [x] Simulcasting- iOS
|
|
98
95
|
- [x] Pinning and spotlighting participants
|
|
99
96
|
- [x] Components parity, alignment and refactor
|
|
100
|
-
- [
|
|
101
|
-
- [
|
|
102
|
-
- [
|
|
97
|
+
- [x] Write docs:
|
|
98
|
+
- [x] UI Components
|
|
99
|
+
- [x] Tutorials
|
|
103
100
|
- [x] Video Rooms Tutorial
|
|
104
101
|
- [x] Audio Rooms Tutorial
|
|
102
|
+
- [x] Livestream Tutorial
|
|
105
103
|
- [ ] Core
|
|
106
104
|
- [x] Camera & Microphone
|
|
107
105
|
- [ ] Advanced
|
|
108
|
-
- [
|
|
109
|
-
- [
|
|
110
|
-
- [
|
|
111
|
-
- [
|
|
112
|
-
- [
|
|
106
|
+
- [x] Chat Integration
|
|
107
|
+
- [x] Internationalization
|
|
108
|
+
- [x] Push Notification (validate)
|
|
109
|
+
- [x] UI Cookbook
|
|
110
|
+
- [x] Call Controls
|
|
113
111
|
- [x] Permission requests (native)
|
|
114
|
-
- [
|
|
115
|
-
- [
|
|
116
|
-
- [
|
|
112
|
+
- [x] Runtime layout switching
|
|
113
|
+
- [x] Video Layout (refactor)
|
|
114
|
+
- [x] ParticipantView customizations
|
|
117
115
|
|
|
118
116
|
### 0.2 milestone
|
|
119
|
-
- [ ] Livestream tutorial
|
|
120
117
|
- [ ] Regular Push Notification
|
|
121
118
|
- [ ] Deeplink support for video call demo (Dogfooding already implemented)
|
|
122
119
|
- [ ] Speaking while muted
|
|
123
120
|
- [ ] Landscape support
|
|
124
|
-
- [ ] Call Analytics
|
|
125
121
|
|
|
126
122
|
### 0.3 milestone
|
|
127
|
-
- [ ] Stability
|
|
128
123
|
- [ ] Test with a large call with many participants
|
|
129
124
|
- [ ] Test coverage
|
|
130
125
|
- [ ] CPU usage improvements
|
|
131
126
|
- [ ] Picture-in-Picture
|
|
132
|
-
- [ ] Dynascale 2.0 (codecs, f resolution switches, resolution webrtc handling)
|
|
133
127
|
|
|
134
128
|
### 0.4 milestone
|
|
135
129
|
- [ ] Audio & Video filters
|
|
136
130
|
- [ ] Screen sharing from mobile
|
|
137
|
-
- [ ] Tap to focus
|
|
138
131
|
- [ ] Analytics integration
|
|
139
132
|
- [ ] Picture of the video stream at highest resolution
|
|
133
|
+
- [ ] Call Analytics
|
|
@@ -27,7 +27,9 @@ export const MediaStreamManagement = ({ initialAudioEnabled, initialVideoEnabled
|
|
|
27
27
|
useEffect(() => {
|
|
28
28
|
if (typeof initialAudioEnabled !== 'undefined' &&
|
|
29
29
|
isMicPermissionGranted$.getValue()) {
|
|
30
|
-
if (initialAudioEnabled &&
|
|
30
|
+
if (initialAudioEnabled &&
|
|
31
|
+
(call?.microphone.state.status === undefined ||
|
|
32
|
+
call?.microphone.state.status === 'disabled')) {
|
|
31
33
|
call?.microphone.enable();
|
|
32
34
|
}
|
|
33
35
|
else {
|
|
@@ -36,7 +38,9 @@ export const MediaStreamManagement = ({ initialAudioEnabled, initialVideoEnabled
|
|
|
36
38
|
}
|
|
37
39
|
if (typeof initialVideoEnabled !== 'undefined' &&
|
|
38
40
|
isCameraPermissionGranted$.getValue()) {
|
|
39
|
-
if (initialVideoEnabled &&
|
|
41
|
+
if (initialVideoEnabled &&
|
|
42
|
+
(call?.camera.state.status === undefined ||
|
|
43
|
+
call?.camera.state.status === 'disabled')) {
|
|
40
44
|
call?.camera.enable();
|
|
41
45
|
}
|
|
42
46
|
else {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MediaStreamManagement.js","sourceRoot":"","sources":["../../../src/providers/MediaStreamManagement.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACZ,aAAa,EAEb,WAAW,EACX,UAAU,EACV,SAAS,EACT,OAAO,GACR,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,iCAAiC,CAAC;AACnE,OAAO,EACL,0BAA0B,EAC1B,uBAAuB,GACxB,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AACrC,OAAO,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AA8BrD,MAAM,kBAAkB,GACtB,aAAa,CAAyC,IAAI,CAAC,CAAC;AAE9D;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,EACpC,mBAAmB,EACnB,mBAAmB,EACnB,QAAQ,GACoC,EAAE,EAAE;IAChD,MAAM,IAAI,GAAG,OAAO,EAAE,CAAC;IACvB,MAAM,EAAE,CAAC,EAAE,GAAG,OAAO,EAAE,CAAC;IAExB,4EAA4E;IAC5E,2BAA2B;IAC3B,mBAAmB,CACjB,GAAG,EAAE;QACH,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACzB,CAAC,EACD,GAAG,EAAE;QACH,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC;IAC1B,CAAC,CACF,CAAC;IAEF,SAAS,CAAC,GAAG,EAAE;QACb,IACE,OAAO,mBAAmB,KAAK,WAAW;YAC1C,uBAAuB,CAAC,QAAQ,EAAE,EAClC;YACA,
|
|
1
|
+
{"version":3,"file":"MediaStreamManagement.js","sourceRoot":"","sources":["../../../src/providers/MediaStreamManagement.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACZ,aAAa,EAEb,WAAW,EACX,UAAU,EACV,SAAS,EACT,OAAO,GACR,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,iCAAiC,CAAC;AACnE,OAAO,EACL,0BAA0B,EAC1B,uBAAuB,GACxB,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EAA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AC3B,2BAA2B;SAC5B,CAAC;IACJ,CAAC,EAAE,CAAC,2BAA2B,EAAE,2BAA2B,CAAC,CAAC,CAAC;IAC/D,OAAO,CACL,oBAAC,kBAAkB,CAAC,QAAQ,IAAC,KAAK,EAAE,YAAY,IAC7C,QAAQ,CACmB,CAC/B,CAAC;AACJ,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAG,EAAE;IAC3C,MAAM,KAAK,GAAG,UAAU,CAAC,kBAAkB,CAAC,CAAC;IAC7C,IAAI,CAAC,KAAK,EAAE;QACV,OAAO,CAAC,IAAI,CAAC,0BAA0B,CAAC,CAAC;KAC1C;IACD,OAAO,KAAwC,CAAC;AAClD,CAAC,CAAC"}
|
package/dist/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "0.0.
|
|
1
|
+
export declare const version = "0.0.3";
|
package/dist/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const version = '0.0.
|
|
1
|
+
export const version = '0.0.3';
|
|
2
2
|
//# sourceMappingURL=version.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stream-io/video-react-native-sdk",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"packageManager": "yarn@3.2.4",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -41,8 +41,8 @@
|
|
|
41
41
|
],
|
|
42
42
|
"dependencies": {
|
|
43
43
|
"@stream-io/i18n": "^0.1.1",
|
|
44
|
-
"@stream-io/video-client": "^0.3.
|
|
45
|
-
"@stream-io/video-react-bindings": "^0.2.
|
|
44
|
+
"@stream-io/video-client": "^0.3.14",
|
|
45
|
+
"@stream-io/video-react-bindings": "^0.2.15",
|
|
46
46
|
"intl-pluralrules": "2.0.1",
|
|
47
47
|
"lodash.merge": "^4.6.2",
|
|
48
48
|
"react-native-url-polyfill": "2.0.0",
|
|
@@ -79,7 +79,11 @@ export const MediaStreamManagement = ({
|
|
|
79
79
|
typeof initialAudioEnabled !== 'undefined' &&
|
|
80
80
|
isMicPermissionGranted$.getValue()
|
|
81
81
|
) {
|
|
82
|
-
if (
|
|
82
|
+
if (
|
|
83
|
+
initialAudioEnabled &&
|
|
84
|
+
(call?.microphone.state.status === undefined ||
|
|
85
|
+
call?.microphone.state.status === 'disabled')
|
|
86
|
+
) {
|
|
83
87
|
call?.microphone.enable();
|
|
84
88
|
} else {
|
|
85
89
|
call?.microphone.disable();
|
|
@@ -89,7 +93,11 @@ export const MediaStreamManagement = ({
|
|
|
89
93
|
typeof initialVideoEnabled !== 'undefined' &&
|
|
90
94
|
isCameraPermissionGranted$.getValue()
|
|
91
95
|
) {
|
|
92
|
-
if (
|
|
96
|
+
if (
|
|
97
|
+
initialVideoEnabled &&
|
|
98
|
+
(call?.camera.state.status === undefined ||
|
|
99
|
+
call?.camera.state.status === 'disabled')
|
|
100
|
+
) {
|
|
93
101
|
call?.camera.enable();
|
|
94
102
|
} else {
|
|
95
103
|
call?.camera.disable();
|