@stream-io/video-react-sdk 0.5.6 → 0.5.8

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 CHANGED
@@ -2,6 +2,23 @@
2
2
 
3
3
  This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
4
4
 
5
+ ### [0.5.8](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-sdk-0.5.7...@stream-io/video-react-sdk-0.5.8) (2024-03-29)
6
+
7
+ ### Dependency Updates
8
+
9
+ * `@stream-io/video-client` updated to version `0.6.6`
10
+ * `@stream-io/video-react-bindings` updated to version `0.4.6`
11
+ ### [0.5.7](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-sdk-0.5.6...@stream-io/video-react-sdk-0.5.7) (2024-03-29)
12
+
13
+ ### Dependency Updates
14
+
15
+ * `@stream-io/video-client` updated to version `0.6.5`
16
+ * `@stream-io/video-react-bindings` updated to version `0.4.5`
17
+
18
+ ### Bug Fixes
19
+
20
+ * various bug fixes and improvements ([#1300](https://github.com/GetStream/stream-video-js/issues/1300)) ([a6186e2](https://github.com/GetStream/stream-video-js/commit/a6186e2406fd0b3e0aaa51a4222fa2e24e9dfac3))
21
+
5
22
  ### [0.5.6](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-sdk-0.5.5...@stream-io/video-react-sdk-0.5.6) (2024-03-28)
6
23
 
7
24
  ### Dependency Updates
package/dist/index.cjs.js CHANGED
@@ -85,12 +85,15 @@ const useFloatingUIPreset = ({ placement, strategy, offset: offsetInPx = 10, })
85
85
  */
86
86
  const usePersistDevicePreferences = (key) => {
87
87
  const { useMicrophoneState, useCameraState, useSpeakerState, useCallSettings, } = videoReactBindings.useCallStateHooks();
88
+ const call = videoReactBindings.useCall();
88
89
  const mic = useMicrophoneState();
89
90
  const camera = useCameraState();
90
91
  const speaker = useSpeakerState();
91
92
  const settings = useCallSettings();
92
93
  react.useEffect(() => {
93
- if (!settings)
94
+ if (!call || !settings)
95
+ return;
96
+ if (call.state.callingState === videoClient.CallingState.LEFT)
94
97
  return;
95
98
  try {
96
99
  const hasPreferences = !!window.localStorage.getItem(key);
@@ -116,6 +119,7 @@ const usePersistDevicePreferences = (key) => {
116
119
  console.warn('Failed to save device preferences', err);
117
120
  }
118
121
  }, [
122
+ call,
119
123
  camera.isMute,
120
124
  camera.selectedDevice,
121
125
  key,
@@ -2277,7 +2281,7 @@ const VerticalScrollButtons = ({ scrollWrapper, }) => {
2277
2281
  };
2278
2282
  const hasScreenShare = (p) => !!p?.publishedTracks.includes(videoClient.SfuModels.TrackType.SCREEN_SHARE);
2279
2283
 
2280
- const [major, minor, patch] = ("0.5.6" ).split('.');
2284
+ const [major, minor, patch] = ("0.5.8" ).split('.');
2281
2285
  videoClient.setSdkInfo({
2282
2286
  type: videoClient.SfuModels.SdkType.REACT,
2283
2287
  major,