@stream-io/video-react-sdk 0.5.0 → 0.5.1
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 +7 -0
- package/dist/index.cjs.js +5 -5
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +5 -5
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
- package/src/components/CallControls/ToggleAudioOutputButton.tsx +7 -1
- package/src/components/CallControls/ToggleVideoButton.tsx +8 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
|
|
4
4
|
|
|
5
|
+
### [0.5.1](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-sdk-0.5.0...@stream-io/video-react-sdk-0.5.1) (2024-02-28)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* **react-sdk:** add default menus to ToggleAudio and ToggleVideo buttons ([#1275](https://github.com/GetStream/stream-video-js/issues/1275)) ([462bd40](https://github.com/GetStream/stream-video-js/commit/462bd408bfea4edfe2062525872f06500814328d)), closes [#1194](https://github.com/GetStream/stream-video-js/issues/1194)
|
|
11
|
+
|
|
5
12
|
## [0.5.0](https://github.com/GetStream/stream-video-js/compare/@stream-io/video-react-sdk-0.4.26...@stream-io/video-react-sdk-0.5.0) (2024-02-26)
|
|
6
13
|
|
|
7
14
|
### Dependency Updates
|
package/dist/index.cjs.js
CHANGED
|
@@ -860,13 +860,13 @@ const ToggleAudioPublishingButton = (props) => {
|
|
|
860
860
|
};
|
|
861
861
|
|
|
862
862
|
const ToggleVideoPreviewButton = (props) => {
|
|
863
|
-
const { caption, ...restCompositeButtonProps } = props;
|
|
863
|
+
const { caption, Menu = DeviceSelectorVideo, menuPlacement = 'top', ...restCompositeButtonProps } = props;
|
|
864
864
|
const { t } = videoReactBindings.useI18n();
|
|
865
865
|
const { useCameraState } = videoReactBindings.useCallStateHooks();
|
|
866
866
|
const { camera, isMute, hasBrowserPermission } = useCameraState();
|
|
867
867
|
return (jsxRuntime.jsxs(CompositeButton, { active: isMute, caption: caption, className: clsx(!hasBrowserPermission && 'str-video__device-unavailable'), title: !hasBrowserPermission
|
|
868
868
|
? t('Check your browser video permissions')
|
|
869
|
-
: caption || t('Video'), variant: "secondary", "data-testid": isMute ? 'preview-video-unmute-button' : 'preview-video-mute-button', onClick: () => camera.toggle(), disabled: !hasBrowserPermission, ...restCompositeButtonProps, children: [jsxRuntime.jsx(Icon, { icon: !isMute ? 'camera' : 'camera-off' }), !hasBrowserPermission && (jsxRuntime.jsx("span", { className: "str-video__no-media-permission", title: t('Check your browser video permissions'), children: "!" }))] }));
|
|
869
|
+
: caption || t('Video'), variant: "secondary", "data-testid": isMute ? 'preview-video-unmute-button' : 'preview-video-mute-button', onClick: () => camera.toggle(), disabled: !hasBrowserPermission, Menu: Menu, menuPlacement: menuPlacement, ...restCompositeButtonProps, children: [jsxRuntime.jsx(Icon, { icon: !isMute ? 'camera' : 'camera-off' }), !hasBrowserPermission && (jsxRuntime.jsx("span", { className: "str-video__no-media-permission", title: t('Check your browser video permissions'), children: "!" }))] }));
|
|
870
870
|
};
|
|
871
871
|
const ToggleVideoPublishingButton = (props) => {
|
|
872
872
|
const { t } = videoReactBindings.useI18n();
|
|
@@ -1131,8 +1131,8 @@ const ToggleMenuButton = react.forwardRef(function ToggleMenuButton(props, ref)
|
|
|
1131
1131
|
|
|
1132
1132
|
const ToggleAudioOutputButton = (props) => {
|
|
1133
1133
|
const { t } = videoReactBindings.useI18n();
|
|
1134
|
-
const { caption, Menu } = props;
|
|
1135
|
-
return (jsxRuntime.jsx(CompositeButton, { Menu: Menu, caption: caption, title: caption || t('Speakers'), "data-testid": "audio-output-button", children: jsxRuntime.jsx(Icon, { icon: "speaker" }) }));
|
|
1134
|
+
const { caption, Menu = DeviceSelectorAudioOutput, menuPlacement = 'top', } = props;
|
|
1135
|
+
return (jsxRuntime.jsx(CompositeButton, { Menu: Menu, menuPlacement: menuPlacement, caption: caption, title: caption || t('Speakers'), "data-testid": "audio-output-button", children: jsxRuntime.jsx(Icon, { icon: "speaker" }) }));
|
|
1136
1136
|
};
|
|
1137
1137
|
|
|
1138
1138
|
const BlockedUserListing = ({ data }) => {
|
|
@@ -2277,7 +2277,7 @@ const VerticalScrollButtons = ({ scrollWrapper, }) => {
|
|
|
2277
2277
|
};
|
|
2278
2278
|
const hasScreenShare = (p) => !!p?.publishedTracks.includes(videoClient.SfuModels.TrackType.SCREEN_SHARE);
|
|
2279
2279
|
|
|
2280
|
-
const [major, minor, patch] = ("0.5.
|
|
2280
|
+
const [major, minor, patch] = ("0.5.1" ).split('.');
|
|
2281
2281
|
videoClient.setSdkInfo({
|
|
2282
2282
|
type: videoClient.SfuModels.SdkType.REACT,
|
|
2283
2283
|
major,
|