From 4258b60bba8d644b6184c3fdd193f6cb7f330d25 Mon Sep 17 00:00:00 2001 From: sdvd Date: Wed, 26 Jul 2023 16:24:36 +0530 Subject: [PATCH] docs(web): update api reference Co-authored-by: eswarclynn --- .../javascript/v2/classes/HMSReactiveStore.md | 8 +- .../v2/enums/HMSNotificationTypes.md | 24 ++ .../javascript/v2/home/content.md | 251 +++++++++------ .../javascript/v2/interfaces/HMSActions.md | 168 +++++----- .../v2/interfaces/HMSLocalTrackStats.md | 10 + .../javascript/v2/interfaces/HMSPoll.md | 118 ++++++++ .../v2/interfaces/HMSPollCreateParams.md | 116 +++++++ .../v2/interfaces/HMSPollNotification.md | 56 ++++ .../v2/interfaces/HMSPollQuestionAnswer.md | 40 +++ .../interfaces/HMSPollQuestionCreateParams.md | 62 ++++ .../v2/interfaces/HMSPreviewConfig.md | 2 +- .../v2/interfaces/HMSPublishAllowed.md | 2 +- .../javascript/v2/interfaces/HMSRTMP.md | 2 +- .../interfaces/HMSReconnectionNotification.md | 2 +- .../javascript/v2/interfaces/HMSRecording.md | 2 +- .../v2/interfaces/HMSRemoteTrackStats.md | 2 +- .../javascript/v2/interfaces/HMSRole.md | 4 +- .../v2/interfaces/HMSRoleChangeRequest.md | 2 +- .../interfaces/HMSRoleChangeStoreRequest.md | 2 +- .../javascript/v2/interfaces/HMSRoom.md | 2 +- .../v2/interfaces/HMSScreenAudioTrack.md | 2 +- .../v2/interfaces/HMSScreenShareConfig.md | 34 ++- .../v2/interfaces/HMSScreenVideoTrack.md | 2 +- .../interfaces/HMSSimulcastLayerDefinition.md | 2 +- .../javascript/v2/interfaces/HMSSpeaker.md | 2 +- .../javascript/v2/interfaces/HMSStatsStore.md | 2 +- .../v2/interfaces/HMSStatsStoreWrapper.md | 2 +- .../javascript/v2/interfaces/HMSStore.md | 8 +- .../v2/interfaces/HMSStoreWrapper.md | 2 +- .../v2/interfaces/HMSTrackNotification.md | 2 +- .../javascript/v2/interfaces/HMSTrackStats.md | 12 +- .../javascript/v2/interfaces/HMSVideoTrack.md | 2 +- .../v2/interfaces/HMSVideoTrackSettings.md | 2 +- .../v2/interfaces/IHMSPlaylistActions.md | 2 +- .../v2/interfaces/IHMSSessionStoreActions.md | 2 +- .../v2/interfaces/IHMSStatsStore.md | 2 +- .../javascript/v2/interfaces/IHMSStore.md | 2 +- .../v2/interfaces/RTMPRecordingConfig.md | 2 +- .../v2/interfaces/ScreenCaptureHandle.md | 2 +- .../javascript/v2/interfaces/TokenRequest.md | 2 +- .../v2/interfaces/TokenRequestOptions.md | 2 +- .../javascript/v2/react-hooks/home/content.md | 286 +++++++++--------- .../interfaces/useAVToggleResult.md | 8 +- .../interfaces/useAutoplayErrorResult.md | 6 +- .../interfaces/useCustomEventInput.md | 18 +- .../interfaces/useCustomEventResult.md | 34 ++- .../interfaces/useDevicesResult.md | 20 +- .../interfaces/useEmbedShareResult.md | 57 ++-- .../interfaces/usePDFShareResult.md | 60 ++-- .../interfaces/useParticipantListResult.md | 8 +- .../interfaces/useParticipantsResult.md | 8 +- .../react-hooks/interfaces/usePreviewInput.md | 20 +- .../interfaces/usePreviewResult.md | 8 +- .../interfaces/useRecordingStreamingResult.md | 14 +- .../interfaces/useRemoteAVToggleResult.md | 16 +- .../interfaces/useScreenShareResult.md | 16 +- .../react-hooks/interfaces/useVideoInput.md | 4 +- .../interfaces/useVideoListInput.md | 32 +- .../interfaces/useVideoListTile.md | 8 +- .../react-hooks/interfaces/useVideoOutput.md | 10 +- .../react-hooks/interfaces/useVideoResult.md | 4 +- 61 files changed, 1101 insertions(+), 501 deletions(-) create mode 100644 docs/api-reference/javascript/v2/interfaces/HMSPoll.md create mode 100644 docs/api-reference/javascript/v2/interfaces/HMSPollCreateParams.md create mode 100644 docs/api-reference/javascript/v2/interfaces/HMSPollNotification.md create mode 100644 docs/api-reference/javascript/v2/interfaces/HMSPollQuestionAnswer.md create mode 100644 docs/api-reference/javascript/v2/interfaces/HMSPollQuestionCreateParams.md diff --git a/docs/api-reference/javascript/v2/classes/HMSReactiveStore.md b/docs/api-reference/javascript/v2/classes/HMSReactiveStore.md index b2cc7c1139..cb0dca2089 100644 --- a/docs/api-reference/javascript/v2/classes/HMSReactiveStore.md +++ b/docs/api-reference/javascript/v2/classes/HMSReactiveStore.md @@ -51,14 +51,14 @@ through the IHMSActions instance returned by this Any action which may modify the store or may need to talk to the SDK will happen through the IHMSActions instance returned by this -**`Deprecated`** - -use getActions - #### Returns [`HMSActions`](/api-reference/javascript/v2/interfaces/HMSActions)<`T`\> +**`Deprecated`** + +use getActions + --- ### getNotifications diff --git a/docs/api-reference/javascript/v2/enums/HMSNotificationTypes.md b/docs/api-reference/javascript/v2/enums/HMSNotificationTypes.md index 3983cb96b2..fecb958463 100644 --- a/docs/api-reference/javascript/v2/enums/HMSNotificationTypes.md +++ b/docs/api-reference/javascript/v2/enums/HMSNotificationTypes.md @@ -71,6 +71,30 @@ nav: '2.5' --- +### POLL_CREATED + +• **POLL_CREATED** = `"POLL_CREATED"` + +--- + +### POLL_STARTED + +• **POLL_STARTED** = `"POLL_STARTED"` + +--- + +### POLL_STOPPED + +• **POLL_STOPPED** = `"POLL_STOPPED"` + +--- + +### POLL_VOTES_UPDATED + +• **POLL_VOTES_UPDATED** = `"POLL_VOTES_UPDATED"` + +--- + ### RECONNECTED • **RECONNECTED** = `"RECONNECTED"` diff --git a/docs/api-reference/javascript/v2/home/content.md b/docs/api-reference/javascript/v2/home/content.md index 405e69ac37..bd1f883b55 100644 --- a/docs/api-reference/javascript/v2/home/content.md +++ b/docs/api-reference/javascript/v2/home/content.md @@ -1,98 +1,103 @@ --- title: Web SDK API Reference -nav: '2.01' +nav: '1.1' --- ## Enumerations -- [DeviceType](/api-reference/javascript/v2/enums/DeviceType) -- [HMSAudioPluginType](/api-reference/javascript/v2/enums/HMSAudioPluginType) -- [HMSLogLevel](/api-reference/javascript/v2/enums/HMSLogLevel) -- [HMSNotificationSeverity](/api-reference/javascript/v2/enums/HMSNotificationSeverity) -- [HMSNotificationTypes](/api-reference/javascript/v2/enums/HMSNotificationTypes) -- [HMSPlaylistType](/api-reference/javascript/v2/enums/HMSPlaylistType) -- [HMSRoomState](/api-reference/javascript/v2/enums/HMSRoomState) -- [HMSSimulcastLayer](/api-reference/javascript/v2/enums/HMSSimulcastLayer) -- [HMSVideoPluginCanvasContextType](/api-reference/javascript/v2/enums/HMSVideoPluginCanvasContextType) -- [HMSVideoPluginType](/api-reference/javascript/v2/enums/HMSVideoPluginType) +- [DeviceType](/api-reference/javascript/v2/enums/DeviceType) +- [HMSAudioPluginType](/api-reference/javascript/v2/enums/HMSAudioPluginType) +- [HMSLogLevel](/api-reference/javascript/v2/enums/HMSLogLevel) +- [HMSNotificationSeverity](/api-reference/javascript/v2/enums/HMSNotificationSeverity) +- [HMSNotificationTypes](/api-reference/javascript/v2/enums/HMSNotificationTypes) +- [HMSPlaylistType](/api-reference/javascript/v2/enums/HMSPlaylistType) +- [HMSRoomState](/api-reference/javascript/v2/enums/HMSRoomState) +- [HMSSimulcastLayer](/api-reference/javascript/v2/enums/HMSSimulcastLayer) +- [HMSVideoPluginCanvasContextType](/api-reference/javascript/v2/enums/HMSVideoPluginCanvasContextType) +- [HMSVideoPluginType](/api-reference/javascript/v2/enums/HMSVideoPluginType) ## Classes -- [HMSReactiveStore](/api-reference/javascript/v2/classes/HMSReactiveStore) +- [HMSReactiveStore](/api-reference/javascript/v2/classes/HMSReactiveStore) ## Core Interfaces -- [HMSActions](/api-reference/javascript/v2/interfaces/HMSActions) -- [HMSNotifications](/api-reference/javascript/v2/interfaces/HMSNotifications) -- [HMSStoreWrapper](/api-reference/javascript/v2/interfaces/HMSStoreWrapper) +- [HMSActions](/api-reference/javascript/v2/interfaces/HMSActions) +- [HMSNotifications](/api-reference/javascript/v2/interfaces/HMSNotifications) +- [HMSStoreWrapper](/api-reference/javascript/v2/interfaces/HMSStoreWrapper) ## Other Interfaces -- [DeviceMap](/api-reference/javascript/v2/interfaces/DeviceMap) -- [HLSConfig](/api-reference/javascript/v2/interfaces/HLSConfig) -- [HLSMeetingURLVariant](/api-reference/javascript/v2/interfaces/HLSMeetingURLVariant) -- [HLSVariant](/api-reference/javascript/v2/interfaces/HLSVariant) -- [HMSAudioTrack](/api-reference/javascript/v2/interfaces/HMSAudioTrack) -- [HMSAudioTrackSettings](/api-reference/javascript/v2/interfaces/HMSAudioTrackSettings) -- [HMSChangeMultiTrackStateParams](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateParams) -- [HMSChangeMultiTrackStateRequest](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateRequest) -- [HMSChangeMultiTrackStateRequestNotification](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateRequestNotification) -- [HMSChangeTrackStateRequest](/api-reference/javascript/v2/interfaces/HMSChangeTrackStateRequest) -- [HMSChangeTrackStateRequestNotification](/api-reference/javascript/v2/interfaces/HMSChangeTrackStateRequestNotification) -- [HMSConfig](/api-reference/javascript/v2/interfaces/HMSConfig) -- [HMSConfigInitialSettings](/api-reference/javascript/v2/interfaces/HMSConfigInitialSettings) -- [HMSDeviceChangeEvent](/api-reference/javascript/v2/interfaces/HMSDeviceChangeEvent) -- [HMSDeviceChangeEventNotification](/api-reference/javascript/v2/interfaces/HMSDeviceChangeEventNotification) -- [HMSException](/api-reference/javascript/v2/interfaces/HMSException) -- [HMSExceptionNotification](/api-reference/javascript/v2/interfaces/HMSExceptionNotification) -- [HMSGenericTypes](/api-reference/javascript/v2/interfaces/HMSGenericTypes) -- [HMSHLS](/api-reference/javascript/v2/interfaces/HMSHLS) -- [HMSLeaveRoomRequest](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequest) -- [HMSLeaveRoomRequestNotification](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequestNotification) -- [HMSLocalTrackStats](/api-reference/javascript/v2/interfaces/HMSLocalTrackStats) -- [HMSMediaSettings](/api-reference/javascript/v2/interfaces/HMSMediaSettings) -- [HMSMessage](/api-reference/javascript/v2/interfaces/HMSMessage) -- [HMSMessageNotification](/api-reference/javascript/v2/interfaces/HMSMessageNotification) -- [HMSPeer](/api-reference/javascript/v2/interfaces/HMSPeer) -- [HMSPeerListNotification](/api-reference/javascript/v2/interfaces/HMSPeerListNotification) -- [HMSPeerNotification](/api-reference/javascript/v2/interfaces/HMSPeerNotification) -- [HMSPeerStats](/api-reference/javascript/v2/interfaces/HMSPeerStats) -- [HMSPeerWithMuteStatus](/api-reference/javascript/v2/interfaces/HMSPeerWithMuteStatus) -- [HMSPlaylist](/api-reference/javascript/v2/interfaces/HMSPlaylist) -- [HMSPlaylistItem](/api-reference/javascript/v2/interfaces/HMSPlaylistItem) -- [HMSPlaylistItemNotification](/api-reference/javascript/v2/interfaces/HMSPlaylistItemNotification) -- [HMSPlaylistSelection](/api-reference/javascript/v2/interfaces/HMSPlaylistSelection) -- [HMSPlaylistSelector](/api-reference/javascript/v2/interfaces/HMSPlaylistSelector) -- [HMSPreviewConfig](/api-reference/javascript/v2/interfaces/HMSPreviewConfig) -- [HMSPublishAllowed](/api-reference/javascript/v2/interfaces/HMSPublishAllowed) -- [HMSRTMP](/api-reference/javascript/v2/interfaces/HMSRTMP) -- [HMSReconnectionNotification](/api-reference/javascript/v2/interfaces/HMSReconnectionNotification) -- [HMSRecording](/api-reference/javascript/v2/interfaces/HMSRecording) -- [HMSRemoteTrackStats](/api-reference/javascript/v2/interfaces/HMSRemoteTrackStats) -- [HMSRole](/api-reference/javascript/v2/interfaces/HMSRole) -- [HMSRoleChangeRequest](/api-reference/javascript/v2/interfaces/HMSRoleChangeRequest) -- [HMSRoleChangeStoreRequest](/api-reference/javascript/v2/interfaces/HMSRoleChangeStoreRequest) -- [HMSRoom](/api-reference/javascript/v2/interfaces/HMSRoom) -- [HMSScreenAudioTrack](/api-reference/javascript/v2/interfaces/HMSScreenAudioTrack) -- [HMSScreenShareConfig](/api-reference/javascript/v2/interfaces/HMSScreenShareConfig) -- [HMSScreenVideoTrack](/api-reference/javascript/v2/interfaces/HMSScreenVideoTrack) -- [HMSSimulcastLayerDefinition](/api-reference/javascript/v2/interfaces/HMSSimulcastLayerDefinition) -- [HMSSpeaker](/api-reference/javascript/v2/interfaces/HMSSpeaker) -- [HMSStatsStore](/api-reference/javascript/v2/interfaces/HMSStatsStore) -- [HMSStatsStoreWrapper](/api-reference/javascript/v2/interfaces/HMSStatsStoreWrapper) -- [HMSStore](/api-reference/javascript/v2/interfaces/HMSStore) -- [HMSTrackNotification](/api-reference/javascript/v2/interfaces/HMSTrackNotification) -- [HMSTrackStats](/api-reference/javascript/v2/interfaces/HMSTrackStats) -- [HMSVideoTrack](/api-reference/javascript/v2/interfaces/HMSVideoTrack) -- [HMSVideoTrackSettings](/api-reference/javascript/v2/interfaces/HMSVideoTrackSettings) -- [IHMSPlaylistActions](/api-reference/javascript/v2/interfaces/IHMSPlaylistActions) -- [IHMSSessionStoreActions](/api-reference/javascript/v2/interfaces/IHMSSessionStoreActions) -- [IHMSStatsStore](/api-reference/javascript/v2/interfaces/IHMSStatsStore) -- [IHMSStore](/api-reference/javascript/v2/interfaces/IHMSStore) -- [RTMPRecordingConfig](/api-reference/javascript/v2/interfaces/RTMPRecordingConfig) -- [ScreenCaptureHandle](/api-reference/javascript/v2/interfaces/ScreenCaptureHandle) -- [TokenRequest](/api-reference/javascript/v2/interfaces/TokenRequest) -- [TokenRequestOptions](/api-reference/javascript/v2/interfaces/TokenRequestOptions) +- [DeviceMap](/api-reference/javascript/v2/interfaces/DeviceMap) +- [HLSConfig](/api-reference/javascript/v2/interfaces/HLSConfig) +- [HLSMeetingURLVariant](/api-reference/javascript/v2/interfaces/HLSMeetingURLVariant) +- [HLSVariant](/api-reference/javascript/v2/interfaces/HLSVariant) +- [HMSAudioTrack](/api-reference/javascript/v2/interfaces/HMSAudioTrack) +- [HMSAudioTrackSettings](/api-reference/javascript/v2/interfaces/HMSAudioTrackSettings) +- [HMSChangeMultiTrackStateParams](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateParams) +- [HMSChangeMultiTrackStateRequest](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateRequest) +- [HMSChangeMultiTrackStateRequestNotification](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateRequestNotification) +- [HMSChangeTrackStateRequest](/api-reference/javascript/v2/interfaces/HMSChangeTrackStateRequest) +- [HMSChangeTrackStateRequestNotification](/api-reference/javascript/v2/interfaces/HMSChangeTrackStateRequestNotification) +- [HMSConfig](/api-reference/javascript/v2/interfaces/HMSConfig) +- [HMSConfigInitialSettings](/api-reference/javascript/v2/interfaces/HMSConfigInitialSettings) +- [HMSDeviceChangeEvent](/api-reference/javascript/v2/interfaces/HMSDeviceChangeEvent) +- [HMSDeviceChangeEventNotification](/api-reference/javascript/v2/interfaces/HMSDeviceChangeEventNotification) +- [HMSException](/api-reference/javascript/v2/interfaces/HMSException) +- [HMSExceptionNotification](/api-reference/javascript/v2/interfaces/HMSExceptionNotification) +- [HMSGenericTypes](/api-reference/javascript/v2/interfaces/HMSGenericTypes) +- [HMSHLS](/api-reference/javascript/v2/interfaces/HMSHLS) +- [HMSLeaveRoomRequest](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequest) +- [HMSLeaveRoomRequestNotification](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequestNotification) +- [HMSLocalTrackStats](/api-reference/javascript/v2/interfaces/HMSLocalTrackStats) +- [HMSMediaSettings](/api-reference/javascript/v2/interfaces/HMSMediaSettings) +- [HMSMessage](/api-reference/javascript/v2/interfaces/HMSMessage) +- [HMSMessageNotification](/api-reference/javascript/v2/interfaces/HMSMessageNotification) +- [HMSPeer](/api-reference/javascript/v2/interfaces/HMSPeer) +- [HMSPeerListNotification](/api-reference/javascript/v2/interfaces/HMSPeerListNotification) +- [HMSPeerNotification](/api-reference/javascript/v2/interfaces/HMSPeerNotification) +- [HMSPeerStats](/api-reference/javascript/v2/interfaces/HMSPeerStats) +- [HMSPeerWithMuteStatus](/api-reference/javascript/v2/interfaces/HMSPeerWithMuteStatus) +- [HMSPlaylist](/api-reference/javascript/v2/interfaces/HMSPlaylist) +- [HMSPlaylistItem](/api-reference/javascript/v2/interfaces/HMSPlaylistItem) +- [HMSPlaylistItemNotification](/api-reference/javascript/v2/interfaces/HMSPlaylistItemNotification) +- [HMSPlaylistSelection](/api-reference/javascript/v2/interfaces/HMSPlaylistSelection) +- [HMSPlaylistSelector](/api-reference/javascript/v2/interfaces/HMSPlaylistSelector) +- [HMSPoll](/api-reference/javascript/v2/interfaces/HMSPoll) +- [HMSPollCreateParams](/api-reference/javascript/v2/interfaces/HMSPollCreateParams) +- [HMSPollNotification](/api-reference/javascript/v2/interfaces/HMSPollNotification) +- [HMSPollQuestionAnswer](/api-reference/javascript/v2/interfaces/HMSPollQuestionAnswer) +- [HMSPollQuestionCreateParams](/api-reference/javascript/v2/interfaces/HMSPollQuestionCreateParams) +- [HMSPreviewConfig](/api-reference/javascript/v2/interfaces/HMSPreviewConfig) +- [HMSPublishAllowed](/api-reference/javascript/v2/interfaces/HMSPublishAllowed) +- [HMSRTMP](/api-reference/javascript/v2/interfaces/HMSRTMP) +- [HMSReconnectionNotification](/api-reference/javascript/v2/interfaces/HMSReconnectionNotification) +- [HMSRecording](/api-reference/javascript/v2/interfaces/HMSRecording) +- [HMSRemoteTrackStats](/api-reference/javascript/v2/interfaces/HMSRemoteTrackStats) +- [HMSRole](/api-reference/javascript/v2/interfaces/HMSRole) +- [HMSRoleChangeRequest](/api-reference/javascript/v2/interfaces/HMSRoleChangeRequest) +- [HMSRoleChangeStoreRequest](/api-reference/javascript/v2/interfaces/HMSRoleChangeStoreRequest) +- [HMSRoom](/api-reference/javascript/v2/interfaces/HMSRoom) +- [HMSScreenAudioTrack](/api-reference/javascript/v2/interfaces/HMSScreenAudioTrack) +- [HMSScreenShareConfig](/api-reference/javascript/v2/interfaces/HMSScreenShareConfig) +- [HMSScreenVideoTrack](/api-reference/javascript/v2/interfaces/HMSScreenVideoTrack) +- [HMSSimulcastLayerDefinition](/api-reference/javascript/v2/interfaces/HMSSimulcastLayerDefinition) +- [HMSSpeaker](/api-reference/javascript/v2/interfaces/HMSSpeaker) +- [HMSStatsStore](/api-reference/javascript/v2/interfaces/HMSStatsStore) +- [HMSStatsStoreWrapper](/api-reference/javascript/v2/interfaces/HMSStatsStoreWrapper) +- [HMSStore](/api-reference/javascript/v2/interfaces/HMSStore) +- [HMSTrackNotification](/api-reference/javascript/v2/interfaces/HMSTrackNotification) +- [HMSTrackStats](/api-reference/javascript/v2/interfaces/HMSTrackStats) +- [HMSVideoTrack](/api-reference/javascript/v2/interfaces/HMSVideoTrack) +- [HMSVideoTrackSettings](/api-reference/javascript/v2/interfaces/HMSVideoTrackSettings) +- [IHMSPlaylistActions](/api-reference/javascript/v2/interfaces/IHMSPlaylistActions) +- [IHMSSessionStoreActions](/api-reference/javascript/v2/interfaces/IHMSSessionStoreActions) +- [IHMSStatsStore](/api-reference/javascript/v2/interfaces/IHMSStatsStore) +- [IHMSStore](/api-reference/javascript/v2/interfaces/IHMSStore) +- [RTMPRecordingConfig](/api-reference/javascript/v2/interfaces/RTMPRecordingConfig) +- [ScreenCaptureHandle](/api-reference/javascript/v2/interfaces/ScreenCaptureHandle) +- [TokenRequest](/api-reference/javascript/v2/interfaces/TokenRequest) +- [TokenRequestOptions](/api-reference/javascript/v2/interfaces/TokenRequestOptions) ## References @@ -154,7 +159,7 @@ Renames and re-exports [HMSNotifications](/api-reference/javascript/v2/interface ### HMSNotificationMapping -Ƭ **HMSNotificationMapping**<`T`, `C`\>: { `CHANGE_MULTI_TRACK_STATE_REQUEST`: [`HMSChangeMultiTrackStateRequestNotification`](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateRequestNotification) ; `CHANGE_TRACK_STATE_REQUEST`: [`HMSChangeTrackStateRequestNotification`](/api-reference/javascript/v2/interfaces/HMSChangeTrackStateRequestNotification) ; `DEVICE_CHANGE_UPDATE`: [`HMSDeviceChangeEventNotification`](/api-reference/javascript/v2/interfaces/HMSDeviceChangeEventNotification) ; `ERROR`: [`HMSExceptionNotification`](/api-reference/javascript/v2/interfaces/HMSExceptionNotification) ; `METADATA_UPDATED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `NAME_UPDATED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `NEW_MESSAGE`: [`HMSMessageNotification`](/api-reference/javascript/v2/interfaces/HMSMessageNotification) ; `PEER_JOINED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `PEER_LEFT`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `PEER_LIST`: [`HMSPeerListNotification`](/api-reference/javascript/v2/interfaces/HMSPeerListNotification) ; `PLAYLIST_TRACK_ENDED`: [`HMSPlaylistItemNotification`](/api-reference/javascript/v2/interfaces/HMSPlaylistItemNotification)<`C`\> ; `RECONNECTED`: [`HMSReconnectionNotification`](/api-reference/javascript/v2/interfaces/HMSReconnectionNotification) ; `RECONNECTING`: [`HMSReconnectionNotification`](/api-reference/javascript/v2/interfaces/HMSReconnectionNotification) ; `REMOVED_FROM_ROOM`: [`HMSLeaveRoomRequestNotification`](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequestNotification) ; `ROLE_UPDATED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `ROOM_ENDED`: [`HMSLeaveRoomRequestNotification`](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequestNotification) ; `TRACK_ADDED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_DEGRADED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_DESCRIPTION_CHANGED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_MUTED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_REMOVED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_RESTORED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_UNMUTED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) }[`T`] +Ƭ **HMSNotificationMapping**<`T`, `C`\>: { `CHANGE_MULTI_TRACK_STATE_REQUEST`: [`HMSChangeMultiTrackStateRequestNotification`](/api-reference/javascript/v2/interfaces/HMSChangeMultiTrackStateRequestNotification) ; `CHANGE_TRACK_STATE_REQUEST`: [`HMSChangeTrackStateRequestNotification`](/api-reference/javascript/v2/interfaces/HMSChangeTrackStateRequestNotification) ; `DEVICE_CHANGE_UPDATE`: [`HMSDeviceChangeEventNotification`](/api-reference/javascript/v2/interfaces/HMSDeviceChangeEventNotification) ; `ERROR`: [`HMSExceptionNotification`](/api-reference/javascript/v2/interfaces/HMSExceptionNotification) ; `METADATA_UPDATED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `NAME_UPDATED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `NEW_MESSAGE`: [`HMSMessageNotification`](/api-reference/javascript/v2/interfaces/HMSMessageNotification) ; `PEER_JOINED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `PEER_LEFT`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `PEER_LIST`: [`HMSPeerListNotification`](/api-reference/javascript/v2/interfaces/HMSPeerListNotification) ; `PLAYLIST_TRACK_ENDED`: [`HMSPlaylistItemNotification`](/api-reference/javascript/v2/interfaces/HMSPlaylistItemNotification)<`C`\> ; `POLL_CREATED`: [`HMSPollNotification`](/api-reference/javascript/v2/interfaces/HMSPollNotification) ; `POLL_STARTED`: [`HMSPollNotification`](/api-reference/javascript/v2/interfaces/HMSPollNotification) ; `POLL_STOPPED`: [`HMSPollNotification`](/api-reference/javascript/v2/interfaces/HMSPollNotification) ; `POLL_VOTES_UPDATED`: [`HMSPollNotification`](/api-reference/javascript/v2/interfaces/HMSPollNotification) ; `RECONNECTED`: [`HMSReconnectionNotification`](/api-reference/javascript/v2/interfaces/HMSReconnectionNotification) ; `RECONNECTING`: [`HMSReconnectionNotification`](/api-reference/javascript/v2/interfaces/HMSReconnectionNotification) ; `REMOVED_FROM_ROOM`: [`HMSLeaveRoomRequestNotification`](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequestNotification) ; `ROLE_UPDATED`: [`HMSPeerNotification`](/api-reference/javascript/v2/interfaces/HMSPeerNotification) ; `ROOM_ENDED`: [`HMSLeaveRoomRequestNotification`](/api-reference/javascript/v2/interfaces/HMSLeaveRoomRequestNotification) ; `TRACK_ADDED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_DEGRADED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_DESCRIPTION_CHANGED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_MUTED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_REMOVED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_RESTORED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) ; `TRACK_UNMUTED`: [`HMSTrackNotification`](/api-reference/javascript/v2/interfaces/HMSTrackNotification) }[`T`] #### Type parameters @@ -336,7 +341,7 @@ if key is not passed, full data is returned. ### selectAppDataByPath -▸ **selectAppDataByPath**(...`keys`): `OutputSelector`<[`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<{ `sessionStore`: `Record`<`string`, `any`\> }\>, `undefined` \| `Record`<`string`, `any`\>, (`res`: `undefined` \| `Record`<`string`, `any`\>) => `undefined` \| `Record`<`string`, `any`\>\> +▸ **selectAppDataByPath**(`...keys`): `OutputSelector`<[`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<{ `sessionStore`: `Record`<`string`, `any`\> }\>, `undefined` \| `Record`<`string`, `any`\>, (`res`: `undefined` \| `Record`<`string`, `any`\>) => `undefined` \| `Record`<`string`, `any`\>\> #### Parameters @@ -414,8 +419,8 @@ Select the local audio volume of an audio track given a track ID. NOTE: **Volume** of a track is different from **Audio Level** of a track, -- Audio Level measures the audio of a track and it comes from 100ms's servers. -- Volume is how loud you hear the audio of a track, this is controlled by you at the client side. +- Audio Level measures the audio of a track and it comes from 100ms's servers. +- Volume is how loud you hear the audio of a track, this is controlled by you at the client side. #### Parameters @@ -1360,9 +1365,7 @@ Selects the first peer passing the condition given by the argument predicate fun Ex: to select a peer whose metadata has spotlight set to true(assuming peer.metadata is a valid json string), use ```js -const spotlightPeer = useHMSStore( - selectPeerByCondition((peer) => JSON.parse(peer.metadata).spotlight) -); +const spotlightPeer = useHMSStore(selectPeerByCondition(peer => JSON.parse(peer.metadata).spotlight)); ``` #### Parameters @@ -1565,9 +1568,7 @@ Selects all peers passing the condition given by the argument predicate function Ex: to select peers with isHandRaised set to true in their metadata(assuming peer.metadata is a valid json string), use ```js -const handRaisedPeers = useHMSStore( - selectPeersByCondition((peer) => JSON.parse(peer.metadata).isHandRaised) -); +const handRaisedPeers = useHMSStore(selectPeersByCondition(peer => JSON.parse(peer.metadata).isHandRaised)); ``` #### Parameters @@ -1658,7 +1659,7 @@ Select an array of peers who are currently sharing their screen. ### selectPermissions -▸ **selectPermissions**(`state`): `undefined` \| { `browserRecording`: `boolean` ; `changeRole`: `boolean` ; `endRoom`: `boolean` ; `hlsStreaming`: `boolean` ; `mute`: `boolean` ; `removeOthers`: `boolean` ; `rtmpStreaming`: `boolean` ; `unmute`: `boolean` } +▸ **selectPermissions**(`state`): `undefined` \| { `browserRecording`: `boolean` ; `changeRole`: `boolean` ; `endRoom`: `boolean` ; `hlsStreaming`: `boolean` ; `mute`: `boolean` ; `pollRead`: `boolean` ; `pollWrite`: `boolean` ; `removeOthers`: `boolean` ; `rtmpStreaming`: `boolean` ; `unmute`: `boolean` } Select the permissions which determine what actions the local peer can do. @@ -1670,7 +1671,59 @@ Select the permissions which determine what actions the local peer can do. #### Returns -`undefined` \| { `browserRecording`: `boolean` ; `changeRole`: `boolean` ; `endRoom`: `boolean` ; `hlsStreaming`: `boolean` ; `mute`: `boolean` ; `removeOthers`: `boolean` ; `rtmpStreaming`: `boolean` ; `unmute`: `boolean` } +`undefined` \| { `browserRecording`: `boolean` ; `changeRole`: `boolean` ; `endRoom`: `boolean` ; `hlsStreaming`: `boolean` ; `mute`: `boolean` ; `pollRead`: `boolean` ; `pollWrite`: `boolean` ; `removeOthers`: `boolean` ; `rtmpStreaming`: `boolean` ; `unmute`: `boolean` } + +--- + +### selectPollByID + +▸ **selectPollByID**(`id?`): `StoreSelector`<[`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<{ `sessionStore`: `Record`<`string`, `any`\> }\>, `null` \| [`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll)\> + +takes in a normal selector which has store and id as input and curries it to make it easier to use. +Before: store.getState((store) => normalSelector(store, peerID)) +After: store.getState(curriedSelector(peerID)) + +#### Parameters + +| Name | Type | +| :---- | :------- | +| `id?` | `string` | + +#### Returns + +`StoreSelector`<[`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<{ `sessionStore`: `Record`<`string`, `any`\> }\>, `null` \| [`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll)\> + +--- + +### selectPolls + +▸ **selectPolls**(`store`): [`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll)[] + +#### Parameters + +| Name | Type | +| :------ | :-------------------------------------------------------------------------------------------------------------- | +| `store` | [`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<{ `sessionStore`: `Record`<`string`, `any`\> }\> | + +#### Returns + +[`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll)[] + +--- + +### selectPollsMap + +▸ **selectPollsMap**(`store`): `Record`<`string`, [`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll)\> + +#### Parameters + +| Name | Type | +| :------ | :-------------------------------------------------------------------------------------------------------------- | +| `store` | [`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<{ `sessionStore`: `Record`<`string`, `any`\> }\> | + +#### Returns + +`Record`<`string`, [`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll)\> --- @@ -2044,10 +2097,6 @@ Select the local audio volume of the screen share of a peer given a peer ID. ▸ **selectSessionMetadata**(`store`): `any` -**`Deprecated`** - -- use `selectSessionStore` instead - #### Parameters | Name | Type | @@ -2058,6 +2107,10 @@ Select the local audio volume of the screen share of a peer given a peer ID. `any` +**`Deprecated`** + +- use `selectSessionStore` instead + --- ### selectSessionStore @@ -2089,7 +2142,7 @@ if key is not passed, full data is returned. `T`[``"sessionStore"``] \| `undefined` -▸ **selectSessionStore**<`T`, `K`\>(`key`): (`store`: [`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<`T`\>) => `T`[`"sessionStore"`][`k`] \| `undefined` +▸ **selectSessionStore**<`T`, `K`\>(`key`): (`store`: [`HMSStore`](/api-reference/javascript/v2/interfaces/HMSStore)<`T`\>) => `T`[`"sessionStore"`][`K`] \| `undefined` #### Type parameters @@ -2108,7 +2161,7 @@ if key is not passed, full data is returned. `fn` -▸ (`store`): `T`[`"sessionStore"`][`k`] \| `undefined` +▸ (`store`): `T`[`"sessionStore"`][`K`] \| `undefined` ##### Parameters @@ -2118,7 +2171,7 @@ if key is not passed, full data is returned. ##### Returns -`T`[`"sessionStore"`][`k`] \| `undefined` +`T`[`"sessionStore"`][`K`] \| `undefined` --- diff --git a/docs/api-reference/javascript/v2/interfaces/HMSActions.md b/docs/api-reference/javascript/v2/interfaces/HMSActions.md index f79a4593aa..0c2e0afa64 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSActions.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSActions.md @@ -58,6 +58,12 @@ If lock is passed as true, the room cannot be used further. --- +### interactivityCenter + +• **interactivityCenter**: `IHMSInteractivityCenter` + +--- + ### sessionStore • **sessionStore**: [`IHMSSessionStoreActions`](/api-reference/javascript/v2/interfaces/IHMSSessionStoreActions)<`T`[``"sessionStore"``]\> @@ -122,10 +128,6 @@ Accept the role change request received Add or remove a audio plugin from/to the local peer audio track. Eg. gain filter, noise suppression etc. Audio plugins can be added/removed at any time after the audio track is available -**`See`** - -HMSAudioPlugin - #### Parameters | Name | Type | Description | @@ -136,6 +138,10 @@ HMSAudioPlugin `Promise`<`void`\> +**`See`** + +HMSAudioPlugin + --- ### addPluginToVideoTrack @@ -146,10 +152,6 @@ Add or remove a video plugin from/to the local peer video track. Eg. Virtual Bac Video plugins can be added/removed at any time after the video track is available. pluginFrameRate is the rate at which the output plugin will do processing -**`See`** - -HMSVideoPlugin - #### Parameters | Name | Type | Description | @@ -161,6 +163,10 @@ HMSVideoPlugin `Promise`<`void`\> +**`See`** + +HMSVideoPlugin + --- ### addTrack @@ -248,10 +254,6 @@ If you want to update the name of peer. Request for a role change of a remote peer. Can be forced. -**`Deprecated`** - -Use `changeRoleOfPeer` - #### Parameters | Name | Type | Description | @@ -264,6 +266,10 @@ Use `changeRoleOfPeer` `Promise`<`void`\> +**`Deprecated`** + +Use `changeRoleOfPeer` + --- ### changeRoleOfPeer @@ -309,10 +315,6 @@ Request for a role change of a remote peer. Can be forced. ▸ **detachVideo**(`localTrackID`, `videoElement`): `Promise`<`void`\> -**`See`** - -attachVideo - #### Parameters | Name | Type | @@ -324,6 +326,10 @@ attachVideo `Promise`<`void`\> +**`See`** + +attachVideo + --- ### enableBeamSpeakerLabelsLogging @@ -401,11 +407,6 @@ Notifications for the ignored messages will still be sent, it'll only not be put join function can be used to join the room, if the room join is successful, current details of participants and track details are populated in the store. -**`Remarks`** - -If join is called while an earlier join is in progress for the room id, it -is ignored - #### Parameters | Name | Type | Description | @@ -416,6 +417,11 @@ is ignored `Promise`<`void`\> +**`Remarks`** + +If join is called while an earlier join is in progress for the room id, it +is ignored + --- ### leave @@ -436,14 +442,14 @@ This function can be used to leave the room, if the call is repeated it's ignore Fetch the current room metadata from the server and populate it in store -**`Deprecated`** - -use `actions.sessionStore.observe` instead - #### Returns `Promise`<`void`\> +**`Deprecated`** + +use `actions.sessionStore.observe` instead + --- ### preview @@ -513,10 +519,6 @@ If you have **removeOthers** permission, you can remove a peer from the room. ▸ **removePluginFromAudioTrack**(`plugin`): `Promise`<`void`\> -**`See`** - -addPluginToAudioTrack - #### Parameters | Name | Type | @@ -527,16 +529,16 @@ addPluginToAudioTrack `Promise`<`void`\> +**`See`** + +addPluginToAudioTrack + --- ### removePluginFromVideoTrack ▸ **removePluginFromVideoTrack**(`plugin`): `Promise`<`void`\> -**`See`** - -addPluginToVideoTrack - #### Parameters | Name | Type | @@ -547,6 +549,10 @@ addPluginToVideoTrack `Promise`<`void`\> +**`See`** + +addPluginToVideoTrack + --- ### removeTrack @@ -632,7 +638,14 @@ This api adds EXT-X-DATERANGE tags to the media playlist. It is useful for defining timed metadata for interstitial regions such as advertisements, but can be used to define any timed metadata needed by your stream. usage (e.g) -const metadataList = `[{ payload: "some string 1", duration: 2 }, { payload: "some string 2", duration: 3 }]` +const metadataList = `[{ + payload: "some string 1", + duration: 2 +}, +{ + payload: "some string 2", + duration: 3 +}]` sendHLSTimedMetadata(metadataList); #### Parameters @@ -651,15 +664,6 @@ sendHLSTimedMetadata(metadataList); ▸ **sendMessage**(`message`): `void` -**`Deprecated`** - -The method should not be used - -**`See`** - -sendBroadcastMessage -Send a plain text message to all the other participants in the room. - #### Parameters | Name | Type | Description | @@ -670,27 +674,22 @@ Send a plain text message to all the other participants in the room. `void` ---- +**`Deprecated`** -### setAppData +The method should not be used -▸ **setAppData**(`key`, `value`, `merge?`): `void` +**`See`** -use it for updating a particular property in the appdata +sendBroadcastMessage +Send a plain text message to all the other participants in the room. -**`Example`** +--- -assume appData is initially -`{ mySettings: { setting1: 'val1', setting2: 'val2', }, mySettings2: 43, mySettings3: false, };` +### setAppData -after calling, -`setAppData("mySettings", {setting1:'val1-edit', setting3:'val3'}, true);` -it becomes -`{ mySettings: { setting1: 'val1-edit', setting2: 'val2', setting3: 'val3', }, mySettings2: 43, mySettings3: false, };` +▸ **setAppData**(`key`, `value`, `merge?`): `void` -Note: This is not suitable for keeping large data or data which updates -at a high frequency, it is recommended to use app side store for those -cases. +use it for updating a particular property in the appdata #### Parameters @@ -704,6 +703,37 @@ cases. `void` +**`Example`** + +```ts +assume appData is initially + `{ + mySettings: { + setting1: 'val1', + setting2: 'val2', + }, + mySettings2: 43, + mySettings3: false, + };` + +after calling, +`setAppData("mySettings", {setting1:'val1-edit', setting3:'val3'}, true);` +it becomes + `{ + mySettings: { + setting1: 'val1-edit', + setting2: 'val2', + setting3: 'val3', + }, + mySettings2: 43, + mySettings3: false, + };` + +Note: This is not suitable for keeping large data or data which updates +at a high frequency, it is recommended to use app side store for those +cases. +``` + ▸ **setAppData**(`key`, `value`): `void` #### Parameters @@ -948,10 +978,6 @@ JSON.stringify. Session metadata is available to every peer in the room and is persisted throughout a session till the last peer leaves a room -**`Deprecated`** - -use `actions.sessionStore.set` instead - #### Parameters | Name | Type | @@ -962,6 +988,10 @@ use `actions.sessionStore.set` instead `Promise`<`void`\> +**`Deprecated`** + +use `actions.sessionStore.set` instead + --- ### setVideoSettings @@ -1086,10 +1116,6 @@ Toggle the camera between front and back if the both the camera's exist To check the support of the plugin, based on browser, os and audio devices -**`See`** - -HMSPluginSupportResult - #### Parameters | Name | Type | Description | @@ -1100,6 +1126,10 @@ HMSPluginSupportResult `HMSPluginSupportResult` +**`See`** + +HMSPluginSupportResult + --- ### validateVideoPluginSupport @@ -1108,10 +1138,6 @@ HMSPluginSupportResult To check the support of the plugin, based on browser, os and audio devices -**`See`** - -HMSPluginSupportResult - #### Parameters | Name | Type | Description | @@ -1121,3 +1147,7 @@ HMSPluginSupportResult #### Returns `HMSPluginSupportResult` + +**`See`** + +HMSPluginSupportResult diff --git a/docs/api-reference/javascript/v2/interfaces/HMSLocalTrackStats.md b/docs/api-reference/javascript/v2/interfaces/HMSLocalTrackStats.md index 728895d126..f1a479c8b7 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSLocalTrackStats.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSLocalTrackStats.md @@ -288,6 +288,16 @@ BaseTrackStats.timestamp --- +### totalPacketSendDelay + +• `Optional` **totalPacketSendDelay**: `number` + +#### Inherited from + +MissingOutboundStats.totalPacketSendDelay + +--- + ### totalRoundTripTime • `Optional` **totalRoundTripTime**: `number` diff --git a/docs/api-reference/javascript/v2/interfaces/HMSPoll.md b/docs/api-reference/javascript/v2/interfaces/HMSPoll.md new file mode 100644 index 0000000000..434c096629 --- /dev/null +++ b/docs/api-reference/javascript/v2/interfaces/HMSPoll.md @@ -0,0 +1,118 @@ +--- +title: HMSPoll +nav: '4.38' +--- + +## Properties + +### anonymous + +• `Optional` **anonymous**: `boolean` + +--- + +### createdAt + +• `Optional` **createdAt**: `Date` + +--- + +### createdBy + +• `Optional` **createdBy**: `string` + +--- + +### duration + +• `Optional` **duration**: `number` + +--- + +### id + +• **id**: `string` + +--- + +### locked + +• `Optional` **locked**: `boolean` + +--- + +### mode + +• `Optional` **mode**: `HMSPollUserTrackingMode` + +--- + +### questions + +• `Optional` **questions**: `HMSPollQuestion`[] + +--- + +### result + +• `Optional` **result**: `HMSPollResult` + +--- + +### rolesThatCanViewResponses + +• `Optional` **rolesThatCanViewResponses**: `string`[] + +--- + +### rolesThatCanVote + +• `Optional` **rolesThatCanVote**: `string`[] + +--- + +### startedAt + +• `Optional` **startedAt**: `Date` + +--- + +### startedBy + +• `Optional` **startedBy**: `string` + +--- + +### state + +• `Optional` **state**: `HMSPollState` + +--- + +### stoppedAt + +• `Optional` **stoppedAt**: `Date` + +--- + +### stoppedBy + +• `Optional` **stoppedBy**: `string` + +--- + +### title + +• **title**: `string` + +--- + +### type + +• **type**: `"poll"` \| `"quiz"` + +--- + +### visibility + +• `Optional` **visibility**: `boolean` diff --git a/docs/api-reference/javascript/v2/interfaces/HMSPollCreateParams.md b/docs/api-reference/javascript/v2/interfaces/HMSPollCreateParams.md new file mode 100644 index 0000000000..1b63d83346 --- /dev/null +++ b/docs/api-reference/javascript/v2/interfaces/HMSPollCreateParams.md @@ -0,0 +1,116 @@ +--- +title: HMSPollCreateParams +nav: '4.39' +--- + +## Hierarchy + +- `Pick`<[`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll), `"id"` \| `"title"` \| `"type"` \| `"duration"` \| `"anonymous"` \| `"visibility"` \| `"locked"` \| `"mode"` \| `"rolesThatCanVote"` \| `"rolesThatCanViewResponses"`\> + + ↳ **`HMSPollCreateParams`** + +## Properties + +### anonymous + +• `Optional` **anonymous**: `boolean` + +#### Inherited from + +Pick.anonymous + +--- + +### duration + +• `Optional` **duration**: `number` + +#### Inherited from + +Pick.duration + +--- + +### id + +• **id**: `string` + +#### Inherited from + +Pick.id + +--- + +### locked + +• `Optional` **locked**: `boolean` + +#### Inherited from + +Pick.locked + +--- + +### mode + +• `Optional` **mode**: `HMSPollUserTrackingMode` + +#### Inherited from + +Pick.mode + +--- + +### questions + +• `Optional` **questions**: [`HMSPollQuestionCreateParams`](/api-reference/javascript/v2/interfaces/HMSPollQuestionCreateParams)[] + +--- + +### rolesThatCanViewResponses + +• `Optional` **rolesThatCanViewResponses**: `string`[] + +#### Inherited from + +Pick.rolesThatCanViewResponses + +--- + +### rolesThatCanVote + +• `Optional` **rolesThatCanVote**: `string`[] + +#### Inherited from + +Pick.rolesThatCanVote + +--- + +### title + +• **title**: `string` + +#### Inherited from + +Pick.title + +--- + +### type + +• **type**: `"poll"` \| `"quiz"` + +#### Inherited from + +Pick.type + +--- + +### visibility + +• `Optional` **visibility**: `boolean` + +#### Inherited from + +Pick.visibility diff --git a/docs/api-reference/javascript/v2/interfaces/HMSPollNotification.md b/docs/api-reference/javascript/v2/interfaces/HMSPollNotification.md new file mode 100644 index 0000000000..4c203c20ec --- /dev/null +++ b/docs/api-reference/javascript/v2/interfaces/HMSPollNotification.md @@ -0,0 +1,56 @@ +--- +title: HMSPollNotification +nav: '4.40' +--- + +## Hierarchy + +- `BaseNotification` + + ↳ **`HMSPollNotification`** + +## Properties + +### data + +• **data**: [`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll) + +--- + +### id + +• **id**: `number` + +#### Inherited from + +BaseNotification.id + +--- + +### message + +• **message**: `string` + +#### Inherited from + +BaseNotification.message + +--- + +### severity + +• `Optional` **severity**: [`HMSNotificationSeverity`](/api-reference/javascript/v2/enums/HMSNotificationSeverity) + +#### Inherited from + +BaseNotification.severity + +--- + +### type + +• **type**: [`POLL_STARTED`](/api-reference/javascript/v2/enums/HMSNotificationTypes#poll_started) \| [`POLL_STOPPED`](/api-reference/javascript/v2/enums/HMSNotificationTypes#poll_stopped) \| [`POLL_VOTES_UPDATED`](/api-reference/javascript/v2/enums/HMSNotificationTypes#poll_votes_updated) + +#### Overrides + +BaseNotification.type diff --git a/docs/api-reference/javascript/v2/interfaces/HMSPollQuestionAnswer.md b/docs/api-reference/javascript/v2/interfaces/HMSPollQuestionAnswer.md new file mode 100644 index 0000000000..da88df57ea --- /dev/null +++ b/docs/api-reference/javascript/v2/interfaces/HMSPollQuestionAnswer.md @@ -0,0 +1,40 @@ +--- +title: HMSPollQuestionAnswer +nav: '4.41' +--- + +## Properties + +### case + +• `Optional` **case**: `boolean` + +--- + +### hidden + +• **hidden**: `boolean` + +--- + +### option + +• `Optional` **option**: `number` + +--- + +### options + +• `Optional` **options**: `number`[] + +--- + +### text + +• `Optional` **text**: `string` + +--- + +### trim + +• `Optional` **trim**: `boolean` diff --git a/docs/api-reference/javascript/v2/interfaces/HMSPollQuestionCreateParams.md b/docs/api-reference/javascript/v2/interfaces/HMSPollQuestionCreateParams.md new file mode 100644 index 0000000000..46544f5389 --- /dev/null +++ b/docs/api-reference/javascript/v2/interfaces/HMSPollQuestionCreateParams.md @@ -0,0 +1,62 @@ +--- +title: HMSPollQuestionCreateParams +nav: '4.42' +--- + +## Hierarchy + +- `Pick`<`HMSPollQuestion`, `"text"` \| `"skippable"` \| `"type"` \| `"answer"`\> + + ↳ **`HMSPollQuestionCreateParams`** + +## Properties + +### answer + +• `Optional` **answer**: [`HMSPollQuestionAnswer`](/api-reference/javascript/v2/interfaces/HMSPollQuestionAnswer) + +#### Inherited from + +Pick.answer + +--- + +### index + +• `Optional` **index**: `number` + +--- + +### options + +• `Optional` **options**: `HMSPollQuestionOptionCreateParams`[] + +--- + +### skippable + +• `Optional` **skippable**: `boolean` + +#### Inherited from + +Pick.skippable + +--- + +### text + +• **text**: `string` + +#### Inherited from + +Pick.text + +--- + +### type + +• **type**: `HMSPollQuestionType` + +#### Inherited from + +Pick.type diff --git a/docs/api-reference/javascript/v2/interfaces/HMSPreviewConfig.md b/docs/api-reference/javascript/v2/interfaces/HMSPreviewConfig.md index 6726037beb..aa498b577f 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSPreviewConfig.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSPreviewConfig.md @@ -1,6 +1,6 @@ --- title: HMSPreviewConfig -nav: '4.38' +nav: '4.43' --- the config object tells the SDK options you want to preview with(use if you want preview and join with different roles) diff --git a/docs/api-reference/javascript/v2/interfaces/HMSPublishAllowed.md b/docs/api-reference/javascript/v2/interfaces/HMSPublishAllowed.md index d5af18f2b7..17c23fd945 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSPublishAllowed.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSPublishAllowed.md @@ -1,6 +1,6 @@ --- title: HMSPublishAllowed -nav: '4.39' +nav: '4.44' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSRTMP.md b/docs/api-reference/javascript/v2/interfaces/HMSRTMP.md index 41f538205f..2ab78b0939 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSRTMP.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSRTMP.md @@ -1,6 +1,6 @@ --- title: HMSRTMP -nav: '4.40' +nav: '4.45' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSReconnectionNotification.md b/docs/api-reference/javascript/v2/interfaces/HMSReconnectionNotification.md index af8024bd76..dc109fff7d 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSReconnectionNotification.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSReconnectionNotification.md @@ -1,6 +1,6 @@ --- title: HMSReconnectionNotification -nav: '4.41' +nav: '4.46' --- ## Hierarchy diff --git a/docs/api-reference/javascript/v2/interfaces/HMSRecording.md b/docs/api-reference/javascript/v2/interfaces/HMSRecording.md index 6bc57d74a5..8fb62bffe7 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSRecording.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSRecording.md @@ -1,6 +1,6 @@ --- title: HMSRecording -nav: '4.42' +nav: '4.47' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSRemoteTrackStats.md b/docs/api-reference/javascript/v2/interfaces/HMSRemoteTrackStats.md index 52b17d5f69..99506e886c 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSRemoteTrackStats.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSRemoteTrackStats.md @@ -1,6 +1,6 @@ --- title: HMSRemoteTrackStats -nav: '4.43' +nav: '4.48' --- Extends RTCInboundRtpStreamStats diff --git a/docs/api-reference/javascript/v2/interfaces/HMSRole.md b/docs/api-reference/javascript/v2/interfaces/HMSRole.md index 2eb4cf9cc8..5b0f2edbff 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSRole.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSRole.md @@ -1,6 +1,6 @@ --- title: HMSRole -nav: '4.44' +nav: '4.49' --- ## Properties @@ -24,6 +24,8 @@ nav: '4.44' | `endRoom` | `boolean` | | `hlsStreaming` | `boolean` | | `mute` | `boolean` | +| `pollRead` | `boolean` | +| `pollWrite` | `boolean` | | `removeOthers` | `boolean` | | `rtmpStreaming` | `boolean` | | `unmute` | `boolean` | diff --git a/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeRequest.md b/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeRequest.md index 93f0e81897..928d0f2784 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeRequest.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeRequest.md @@ -1,6 +1,6 @@ --- title: HMSRoleChangeRequest -nav: '4.45' +nav: '4.50' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeStoreRequest.md b/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeStoreRequest.md index 84447619ac..3721bedc4b 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeStoreRequest.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSRoleChangeStoreRequest.md @@ -1,6 +1,6 @@ --- title: HMSRoleChangeStoreRequest -nav: '4.46' +nav: '4.51' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSRoom.md b/docs/api-reference/javascript/v2/interfaces/HMSRoom.md index 4a68d3d906..112c6aceb7 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSRoom.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSRoom.md @@ -1,6 +1,6 @@ --- title: HMSRoom -nav: '4.47' +nav: '4.52' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSScreenAudioTrack.md b/docs/api-reference/javascript/v2/interfaces/HMSScreenAudioTrack.md index 376e155d9c..6e3e00ea5b 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSScreenAudioTrack.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSScreenAudioTrack.md @@ -1,6 +1,6 @@ --- title: HMSScreenAudioTrack -nav: '4.48' +nav: '4.53' --- ## Hierarchy diff --git a/docs/api-reference/javascript/v2/interfaces/HMSScreenShareConfig.md b/docs/api-reference/javascript/v2/interfaces/HMSScreenShareConfig.md index 78bbb24a45..ce6a0dbd56 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSScreenShareConfig.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSScreenShareConfig.md @@ -1,6 +1,6 @@ --- title: HMSScreenShareConfig -nav: '4.49' +nav: '4.54' --- Config to have control over screenshare being captured. Note that @@ -18,7 +18,9 @@ for sharing music. **`Default`** -false +```ts +false; +``` --- @@ -53,7 +55,9 @@ monitor - for full screen **`Default`** -monitor +```ts +monitor; +``` --- @@ -66,7 +70,9 @@ error if user doesn't select current tab for sharing. **`Default`** -false +```ts +false; +``` --- @@ -79,7 +85,9 @@ if user selects something else. **`Default`** -false +```ts +false; +``` --- @@ -94,7 +102,9 @@ this is set to include. **`Default`** -exclude +```ts +exclude; +``` --- @@ -108,7 +118,9 @@ Default is include, set to exclude if forceCurrentTab is true **`Default`** -include +```ts +include; +``` --- @@ -122,7 +134,9 @@ Note that sharing system audio will cause echo if mic is on. **`Default`** -exclude +```ts +exclude; +``` --- @@ -134,4 +148,6 @@ do not give an option to share audio while screen sharing. **`Default`** -false +```ts +false; +``` diff --git a/docs/api-reference/javascript/v2/interfaces/HMSScreenVideoTrack.md b/docs/api-reference/javascript/v2/interfaces/HMSScreenVideoTrack.md index ab5733763c..3296c97de0 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSScreenVideoTrack.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSScreenVideoTrack.md @@ -1,6 +1,6 @@ --- title: HMSScreenVideoTrack -nav: '4.50' +nav: '4.55' --- ## Hierarchy diff --git a/docs/api-reference/javascript/v2/interfaces/HMSSimulcastLayerDefinition.md b/docs/api-reference/javascript/v2/interfaces/HMSSimulcastLayerDefinition.md index c3f4a80315..2927d35a29 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSSimulcastLayerDefinition.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSSimulcastLayerDefinition.md @@ -1,6 +1,6 @@ --- title: HMSSimulcastLayerDefinition -nav: '4.51' +nav: '4.56' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSSpeaker.md b/docs/api-reference/javascript/v2/interfaces/HMSSpeaker.md index da41038e64..f6fa98e151 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSSpeaker.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSSpeaker.md @@ -1,6 +1,6 @@ --- title: HMSSpeaker -nav: '4.52' +nav: '4.57' --- HMS Speaker stores the details of peers speaking at any point of time along with diff --git a/docs/api-reference/javascript/v2/interfaces/HMSStatsStore.md b/docs/api-reference/javascript/v2/interfaces/HMSStatsStore.md index b90d4bb2f4..260ae82a3a 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSStatsStore.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSStatsStore.md @@ -1,6 +1,6 @@ --- title: HMSStatsStore -nav: '4.53' +nav: '4.58' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/HMSStatsStoreWrapper.md b/docs/api-reference/javascript/v2/interfaces/HMSStatsStoreWrapper.md index 239703e9e6..f9b1cebb02 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSStatsStoreWrapper.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSStatsStoreWrapper.md @@ -1,6 +1,6 @@ --- title: HMSStatsStoreWrapper -nav: '4.54' +nav: '4.59' --- ## Hierarchy diff --git a/docs/api-reference/javascript/v2/interfaces/HMSStore.md b/docs/api-reference/javascript/v2/interfaces/HMSStore.md index 5061cac08a..f687782809 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSStore.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSStore.md @@ -1,6 +1,6 @@ --- title: HMSStore -nav: '4.55' +nav: '4.60' --- ## Type parameters @@ -60,6 +60,12 @@ nav: '4.55' --- +### polls + +• **polls**: `Record`<`string`, [`HMSPoll`](/api-reference/javascript/v2/interfaces/HMSPoll)\> + +--- + ### preview • `Optional` **preview**: `Object` diff --git a/docs/api-reference/javascript/v2/interfaces/HMSStoreWrapper.md b/docs/api-reference/javascript/v2/interfaces/HMSStoreWrapper.md index 33e913eb70..86f2ccfdea 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSStoreWrapper.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSStoreWrapper.md @@ -1,6 +1,6 @@ --- title: HMSStoreWrapper -nav: '4.56' +nav: '4.61' --- HMS store can be used to: diff --git a/docs/api-reference/javascript/v2/interfaces/HMSTrackNotification.md b/docs/api-reference/javascript/v2/interfaces/HMSTrackNotification.md index e6a774af3d..389daba1ae 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSTrackNotification.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSTrackNotification.md @@ -1,6 +1,6 @@ --- title: HMSTrackNotification -nav: '4.57' +nav: '4.62' --- ## Hierarchy diff --git a/docs/api-reference/javascript/v2/interfaces/HMSTrackStats.md b/docs/api-reference/javascript/v2/interfaces/HMSTrackStats.md index 5071fe3fbe..665997a14c 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSTrackStats.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSTrackStats.md @@ -1,6 +1,6 @@ --- title: HMSTrackStats -nav: '4.58' +nav: '4.63' --- Extends RTCOutboundRtpStreamStats @@ -370,6 +370,16 @@ https://www.w3.org/TR/webrtc-stats/#dom-rtcremoteinboundrtpstreamstats --- +### totalPacketSendDelay + +• `Optional` **totalPacketSendDelay**: `number` + +#### Inherited from + +[HMSLocalTrackStats](/api-reference/javascript/v2/interfaces/HMSLocalTrackStats).[totalPacketSendDelay](/api-reference/javascript/v2/interfaces/HMSLocalTrackStats#totalpacketsenddelay) + +--- + ### totalRoundTripTime • `Optional` **totalRoundTripTime**: `number` diff --git a/docs/api-reference/javascript/v2/interfaces/HMSVideoTrack.md b/docs/api-reference/javascript/v2/interfaces/HMSVideoTrack.md index 533844c8d2..e12269b1ab 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSVideoTrack.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSVideoTrack.md @@ -1,6 +1,6 @@ --- title: HMSVideoTrack -nav: '4.59' +nav: '4.64' --- ## Hierarchy diff --git a/docs/api-reference/javascript/v2/interfaces/HMSVideoTrackSettings.md b/docs/api-reference/javascript/v2/interfaces/HMSVideoTrackSettings.md index a42e210ad0..d8af6e1c68 100644 --- a/docs/api-reference/javascript/v2/interfaces/HMSVideoTrackSettings.md +++ b/docs/api-reference/javascript/v2/interfaces/HMSVideoTrackSettings.md @@ -1,6 +1,6 @@ --- title: HMSVideoTrackSettings -nav: '4.60' +nav: '4.65' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/IHMSPlaylistActions.md b/docs/api-reference/javascript/v2/interfaces/IHMSPlaylistActions.md index 7bc12e779f..d1c005eabc 100644 --- a/docs/api-reference/javascript/v2/interfaces/IHMSPlaylistActions.md +++ b/docs/api-reference/javascript/v2/interfaces/IHMSPlaylistActions.md @@ -1,6 +1,6 @@ --- title: IHMSPlaylistActions -nav: '4.61' +nav: '4.66' --- ## Methods diff --git a/docs/api-reference/javascript/v2/interfaces/IHMSSessionStoreActions.md b/docs/api-reference/javascript/v2/interfaces/IHMSSessionStoreActions.md index a7b9a57d10..31fa84ab0d 100644 --- a/docs/api-reference/javascript/v2/interfaces/IHMSSessionStoreActions.md +++ b/docs/api-reference/javascript/v2/interfaces/IHMSSessionStoreActions.md @@ -1,6 +1,6 @@ --- title: IHMSSessionStoreActions -nav: '4.62' +nav: '4.67' --- ## Type parameters diff --git a/docs/api-reference/javascript/v2/interfaces/IHMSStatsStore.md b/docs/api-reference/javascript/v2/interfaces/IHMSStatsStore.md index c8357ef0b5..2d42d21ea1 100644 --- a/docs/api-reference/javascript/v2/interfaces/IHMSStatsStore.md +++ b/docs/api-reference/javascript/v2/interfaces/IHMSStatsStore.md @@ -1,6 +1,6 @@ --- title: IHMSStatsStore -nav: '4.63' +nav: '4.68' --- ## Hierarchy diff --git a/docs/api-reference/javascript/v2/interfaces/IHMSStore.md b/docs/api-reference/javascript/v2/interfaces/IHMSStore.md index a74982740b..32b6144391 100644 --- a/docs/api-reference/javascript/v2/interfaces/IHMSStore.md +++ b/docs/api-reference/javascript/v2/interfaces/IHMSStore.md @@ -1,6 +1,6 @@ --- title: IHMSStore -nav: '4.64' +nav: '4.69' --- HMS Reactive store can be used to subscribe to different parts of the store using selectors diff --git a/docs/api-reference/javascript/v2/interfaces/RTMPRecordingConfig.md b/docs/api-reference/javascript/v2/interfaces/RTMPRecordingConfig.md index 4ea8a7f6db..a2323ebeca 100644 --- a/docs/api-reference/javascript/v2/interfaces/RTMPRecordingConfig.md +++ b/docs/api-reference/javascript/v2/interfaces/RTMPRecordingConfig.md @@ -1,6 +1,6 @@ --- title: RTMPRecordingConfig -nav: '4.65' +nav: '4.70' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/ScreenCaptureHandle.md b/docs/api-reference/javascript/v2/interfaces/ScreenCaptureHandle.md index 5921340e6f..26b0fff0e9 100644 --- a/docs/api-reference/javascript/v2/interfaces/ScreenCaptureHandle.md +++ b/docs/api-reference/javascript/v2/interfaces/ScreenCaptureHandle.md @@ -1,6 +1,6 @@ --- title: ScreenCaptureHandle -nav: '4.66' +nav: '4.71' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/TokenRequest.md b/docs/api-reference/javascript/v2/interfaces/TokenRequest.md index 45a30db2ad..157108565f 100644 --- a/docs/api-reference/javascript/v2/interfaces/TokenRequest.md +++ b/docs/api-reference/javascript/v2/interfaces/TokenRequest.md @@ -1,6 +1,6 @@ --- title: TokenRequest -nav: '4.67' +nav: '4.72' --- ## Properties diff --git a/docs/api-reference/javascript/v2/interfaces/TokenRequestOptions.md b/docs/api-reference/javascript/v2/interfaces/TokenRequestOptions.md index 3bf4a471e6..731f669f43 100644 --- a/docs/api-reference/javascript/v2/interfaces/TokenRequestOptions.md +++ b/docs/api-reference/javascript/v2/interfaces/TokenRequestOptions.md @@ -1,6 +1,6 @@ --- title: TokenRequestOptions -nav: '4.68' +nav: '4.73' --- ## Properties diff --git a/docs/api-reference/javascript/v2/react-hooks/home/content.md b/docs/api-reference/javascript/v2/react-hooks/home/content.md index 209236d939..1d491ce725 100644 --- a/docs/api-reference/javascript/v2/react-hooks/home/content.md +++ b/docs/api-reference/javascript/v2/react-hooks/home/content.md @@ -1,6 +1,6 @@ --- title: React Hooks API Reference -nav: "5.1.1" +nav: '5.1.1' --- ## Interfaces @@ -10,6 +10,8 @@ nav: "5.1.1" - [useCustomEventInput](/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventInput) - [useCustomEventResult](/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult) - [useDevicesResult](/api-reference/javascript/v2/react-hooks/interfaces/useDevicesResult) +- [useEmbedShareResult](/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult) +- [usePDFShareResult](/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult) - [useParticipantListResult](/api-reference/javascript/v2/react-hooks/interfaces/useParticipantListResult) - [useParticipantsResult](/api-reference/javascript/v2/react-hooks/interfaces/useParticipantsResult) - [usePreviewInput](/api-reference/javascript/v2/react-hooks/interfaces/usePreviewInput) @@ -39,16 +41,16 @@ only logs the error to the console, and can be overridden for any other behaviou ##### Parameters -| Name | Type | -| :------ | :------ | -| `err` | `Error` | +| Name | Type | +| :-------- | :------- | +| `err` | `Error` | | `method?` | `string` | ##### Returns `void` -___ +--- ### useParticipantsParams @@ -56,17 +58,17 @@ ___ #### Type declaration -| Name | Type | Description | -| :------ | :------ | :------ | +| Name | Type | Description | +| :--------- | :------------------------- | :---------------------------------------------------------------------------------- | | `metadata` | `Record`<`string`, `any`\> | To filter by particular by metadata. only supports `{ isHandRaised: true }` for now | -| `role` | `HMSRoleName` | To filter by particular role | -| `search` | `string` | To filter by name/role (partial match) | +| `role` | `HMSRoleName` | To filter by particular role | +| `search` | `string` | To filter by name/role (partial match) | ## Functions ### HMSRoomProvider -▸ **HMSRoomProvider**<`T`\>(`__namedParameters`): `FunctionComponentElement`<`ProviderProps`<``null`` \| `HMSContextProviderProps`\>\> +▸ **HMSRoomProvider**<`T`\>(`«destructured»`): `FunctionComponentElement`<`ProviderProps`<`null` \| `HMSContextProviderProps`\>\> top level wrapper for using react sdk hooks. This doesn't have any mandatory arguments, if you are already initialising the sdk on your side, you can pass in the primitives from there as well to use hooks for @@ -74,21 +76,21 @@ react part of your code. #### Type parameters -| Name | Type | -| :------ | :------ | -| `T` | extends `HMSGenericTypes` = { `sessionStore`: `Record`<`string`, `any`\> } | +| Name | Type | +| :--- | :------------------------------------------------------------------------- | +| `T` | extends `HMSGenericTypes` = { `sessionStore`: `Record`<`string`, `any`\> } | #### Parameters -| Name | Type | -| :------ | :------ | -| `__namedParameters` | `PropsWithChildren`<`HMSRoomProviderProps`<`T`\>\> | +| Name | Type | +| :--------------- | :------------------------------------------------- | +| `«destructured»` | `PropsWithChildren`<`HMSRoomProviderProps`<`T`\>\> | #### Returns -`FunctionComponentElement`<`ProviderProps`<``null`` \| `HMSContextProviderProps`\>\> +`FunctionComponentElement`<`ProviderProps`<`null` \| `HMSContextProviderProps`\>\> -___ +--- ### throwErrorHandler @@ -98,16 +100,16 @@ pass in this error handler to get the error thrown back to the UI for further ha #### Parameters -| Name | Type | -| :------ | :------ | -| `err` | `Error` | +| Name | Type | +| :-------- | :------- | +| `err` | `Error` | | `method?` | `string` | #### Returns `void` -___ +--- ### useAVToggle @@ -118,19 +120,19 @@ isAllowedToPublish can be used to decide whether to show the toggle buttons in t #### Parameters -| Name | Type | Default value | Description | -| :------ | :------ | :------ | :------ | +| Name | Type | Default value | Description | +| :------------ | :----------------------------------------------------------------------------------------- | :---------------- | :----------------------------------------------- | | `handleError` | [`hooksErrHandler`](/api-reference/javascript/v2/react-hooks/home/content#hookserrhandler) | `logErrorHandler` | to handle any error during toggle of audio/video | #### Returns [`useAVToggleResult`](/api-reference/javascript/v2/react-hooks/interfaces/useAVToggleResult) -___ +--- ### useAudioLevelStyles -▸ **useAudioLevelStyles**(`__namedParameters`): `void` +▸ **useAudioLevelStyles**(`«destructured»`): `void` This hook can be used to apply css properties on an element based on the current audio level for the passed in track. It doesn't return the audio level as it's optimised for performance. As audio level could be changing frequently we @@ -139,18 +141,18 @@ An e.g. use of this hook will be to apply box-shadow on parent tile based on aud #### Parameters -| Name | Type | -| :------ | :------ | -| `__namedParameters` | `Object` | -| `__namedParameters.getStyle` | (`level`: `number`) => `Record`<`string`, `string`\> | -| `__namedParameters.ref` | `RefObject`<`any`\> | -| `__namedParameters.trackId?` | `string` | +| Name | Type | +| :--------------- | :--------------------------------------------------- | +| `«destructured»` | `Object` | +| › `getStyle` | (`level`: `number`) => `Record`<`string`, `string`\> | +| › `ref` | `RefObject`<`any`\> | +| › `trackId?` | `string` | #### Returns `void` -___ +--- ### useAutoplayError @@ -163,11 +165,11 @@ unblock the browser autoplay block [`useAutoplayErrorResult`](/api-reference/javascript/v2/react-hooks/interfaces/useAutoplayErrorResult) -___ +--- ### useCustomEvent -▸ **useCustomEvent**<`T`\>(`__namedParameters`): [`useCustomEventResult`](/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult)<`T`\> +▸ **useCustomEvent**<`T`\>(`«destructured»`): [`useCustomEventResult`](/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult)<`T`\> A generic function to implement [custom events](https://www.100ms.live/docs/javascript/v2/features/chat#custom-events) in your UI. The data to be sent to remote is expected to be a serializable JSON. The serialization @@ -176,20 +178,20 @@ and deserialization is taken care of by the hook. #### Type parameters | Name | -| :------ | -| `T` | +| :--- | +| `T` | #### Parameters -| Name | Type | -| :------ | :------ | -| `__namedParameters` | [`useCustomEventInput`](/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventInput)<`T`\> | +| Name | Type | +| :--------------- | :----------------------------------------------------------------------------------------------------- | +| `«destructured»` | [`useCustomEventInput`](/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventInput)<`T`\> | #### Returns [`useCustomEventResult`](/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult)<`T`\> -___ +--- ### useDevices @@ -201,21 +203,40 @@ devices will be returned based on what the user is allowed to publish, so a audi the audioInput field. This can be used to show the UI dropdowns properly. Note: + - Browsers give access to the list of devices only if the user has given permission to access them - Changing devices manually work best in combination with remembering the user's selection for the next time, do pass the rememberDeviceSelection flag at time of join for this to happen. #### Parameters -| Name | Type | Default value | Description | -| :------ | :------ | :------ | :------ | +| Name | Type | Default value | Description | +| :------------ | :------------------------------------------------------------------------------------ | :---------------- | :------------------------------------------------ | | `handleError` | [`hooksErrHandler`](/api-reference/javascript/v2/react-hooks/modules#hookserrhandler) | `logErrorHandler` | error handler for any errors during device change | #### Returns [`useDevicesResult`](/api-reference/javascript/v2/react-hooks/interfaces/useDevicesResult) -___ +--- + +### useEmbedShare + +▸ **useEmbedShare**(`resetConfig?`): [`useEmbedShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult) + +#### Parameters + +| Name | Type | Description | +| :------------- | :----------- | :--------------------------------------------------------------------------------------- | +| `resetConfig?` | () => `void` | Callback that implements cleanup after Embed sharing stops. It is an optional parameter. | + +#### Returns + +[`useEmbedShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult) + +useEmbedShareResult + +--- ### useHMSActions @@ -225,31 +246,31 @@ ___ `IHMSActions`<{}\> -___ +--- ### useHMSNotifications -▸ **useHMSNotifications**<`T`\>(`type?`): ``null`` \| `HMSNotificationInCallback`<`T`\> +▸ **useHMSNotifications**<`T`\>(`type?`): `null` \| `HMSNotificationInCallback`<`T`\> `useHMSNotifications` is a read only hook which gives the latest notification(HMSNotification) received. #### Type parameters -| Name | Type | -| :------ | :------ | -| `T` | extends `HMSNotificationTypeParam` | +| Name | Type | +| :--- | :--------------------------------- | +| `T` | extends `HMSNotificationTypeParam` | #### Parameters -| Name | Type | Description | -| :------ | :------ | :------ | -| `type?` | `T` | can be a string or an array of string for the types of notifications to listen to. If an array is passed either declare it outside the functional component or use a useMemo to make sure its reference stays same across rerenders for performance reasons. | +| Name | Type | Description | +| :------ | :--- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `type?` | `T` | can be a string or an array of string for the types of notifications to listen to. If an array is passed either declare it outside the functional component or use a useMemo to make sure its reference stays same across rerenders for performance reasons. | #### Returns -``null`` \| `HMSNotificationInCallback`<`T`\> +`null` \| `HMSNotificationInCallback`<`T`\> -___ +--- ### useHMSStatsStore @@ -257,22 +278,22 @@ ___ #### Type parameters -| Name | -| :------ | +| Name | +| :----------- | | `StateSlice` | #### Parameters -| Name | Type | Default value | -| :------ | :------ | :------ | -| `selector` | `StateSelector`<`HMSStatsStore`, `StateSlice`\> | `undefined` | -| `equalityFn` | `EqualityChecker`<`StateSlice`\> | `shallow` | +| Name | Type | Default value | +| :----------- | :---------------------------------------------- | :------------ | +| `selector` | `StateSelector`<`HMSStatsStore`, `StateSlice`\> | `undefined` | +| `equalityFn` | `EqualityChecker`<`StateSlice`\> | `shallow` | #### Returns `undefined` \| `StateSlice` -___ +--- ### useHMSStore @@ -283,22 +304,22 @@ The hook can only be used in a component if HMSRoomProvider is present in its an #### Type parameters -| Name | -| :------ | +| Name | +| :----------- | | `StateSlice` | #### Parameters -| Name | Type | Default value | -| :------ | :------ | :------ | -| `selector` | `StateSelector`<`HMSStore`<{}\>, `StateSlice`\> | `undefined` | -| `equalityFn` | `EqualityChecker`<`StateSlice`\> | `shallow` | +| Name | Type | Default value | +| :----------- | :---------------------------------------------- | :------------ | +| `selector` | `StateSelector`<`HMSStore`<{}\>, `StateSlice`\> | `undefined` | +| `equalityFn` | `EqualityChecker`<`StateSlice`\> | `shallow` | #### Returns `StateSlice` -___ +--- ### useHMSVanillaNotifications @@ -308,7 +329,7 @@ ___ `undefined` \| `IHMSNotifications` -___ +--- ### useHMSVanillaStore @@ -316,6 +337,7 @@ ___ `useHMSVanillaStore` is a read only hook which returns the vanilla HMSStore. Usage: + ``` const hmsStore = useHMSVanillaStore(); const dominantSpeaker = hmsStore.getState(selectDominantSpeaker); @@ -329,7 +351,25 @@ For almost every case, `useHMSStore` would get the job done. `IHMSReactStore`<`HMSStore`<{}\>\> -___ +--- + +### usePDFShare + +▸ **usePDFShare**(`resetConfig?`): [`usePDFShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult) + +#### Parameters + +| Name | Type | Description | +| :------------- | :----------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `resetConfig?` | () => `void` | Callback that implements cleanup after PDF sharing stops. Typically used to reset the currently selected PDF file or URL in your state. It is an optional parameter. | + +#### Returns + +[`usePDFShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult) + +usePDFShareResult + +--- ### useParticipantList @@ -339,14 +379,14 @@ ___ `Object` -| Name | Type | -| :------ | :------ | -| `isConnected` | `undefined` \| `boolean` | +| Name | Type | +| :-------------------- | :------------------------------- | +| `isConnected` | `undefined` \| `boolean` | | `participantsByRoles` | `Record`<`string`, `HMSPeer`[]\> | -| `peerCount` | `number` | -| `roles` | `string`[] | +| `peerCount` | `number` | +| `roles` | `string`[] | -___ +--- ### useParticipants @@ -357,26 +397,26 @@ filtered by role or metadata with isHandRaised or the entire participants if no #### Parameters -| Name | Type | -| :------ | :------ | +| Name | Type | +| :-------- | :------------------------------------------------------------------------------------------------ | | `params?` | [`useParticipantsParams`](/api-reference/javascript/v2/react-hooks/modules#useparticipantsparams) | #### Returns `Object` -| Name | Type | -| :------ | :------ | -| `isConnected` | `undefined` \| `boolean` | -| `participants` | `HMSPeer`[] | -| `peerCount` | `number` | +| Name | Type | +| :---------------------- | :-------------------------- | +| `isConnected` | `undefined` \| `boolean` | +| `participants` | `HMSPeer`[] | +| `peerCount` | `number` | | `rolesWithParticipants` | (`undefined` \| `string`)[] | -___ +--- ### usePreviewJoin -▸ **usePreviewJoin**(`__namedParameters`): [`usePreviewResult`](/api-reference/javascript/v2/react-hooks/interfaces/usePreviewResult) +▸ **usePreviewJoin**(`«destructured»`): [`usePreviewResult`](/api-reference/javascript/v2/react-hooks/interfaces/usePreviewResult) This hook can be used to build a preview UI component, this lets you call preview every time the passed in token changes. This hook is best used in combination with useDevices for changing devices, useAVToggle for @@ -385,15 +425,15 @@ Any device change or mute/unmute will be carried across to join. #### Parameters -| Name | Type | -| :------ | :------ | -| `__namedParameters` | [`usePreviewInput`](/api-reference/javascript/v2/react-hooks/interfaces/usePreviewInput) | +| Name | Type | +| :--------------- | :--------------------------------------------------------------------------------------- | +| `«destructured»` | [`usePreviewInput`](/api-reference/javascript/v2/react-hooks/interfaces/usePreviewInput) | #### Returns [`usePreviewResult`](/api-reference/javascript/v2/react-hooks/interfaces/usePreviewResult) -___ +--- ### useRecordingStreaming @@ -403,7 +443,7 @@ ___ [`useRecordingStreamingResult`](/api-reference/javascript/v2/react-hooks/interfaces/useRecordingStreamingResult) -___ +--- ### useRemoteAVToggle @@ -413,17 +453,17 @@ This hook can be used to implement remote mute/unmute + audio volume changer on #### Parameters -| Name | Type | Default value | Description | -| :------ | :------ | :------ | :------ | -| `audioTrackId` | `string` | `undefined` | of the peer whose tracks need to be managed | -| `videoTrackId` | `string` | `undefined` | of the peer whose tracks need to be managed | -| `handleError` | [`hooksErrHandler`](/api-reference/javascript/v2/react-hooks/modules#hookserrhandler) | `logErrorHandler` | to handle any error during toggle of audio/video | +| Name | Type | Default value | Description | +| :------------- | :------------------------------------------------------------------------------------ | :---------------- | :----------------------------------------------- | +| `audioTrackId` | `string` | `undefined` | of the peer whose tracks need to be managed | +| `videoTrackId` | `string` | `undefined` | of the peer whose tracks need to be managed | +| `handleError` | [`hooksErrHandler`](/api-reference/javascript/v2/react-hooks/modules#hookserrhandler) | `logErrorHandler` | to handle any error during toggle of audio/video | #### Returns [`useRemoteAVToggleResult`](/api-reference/javascript/v2/react-hooks/interfaces/useRemoteAVToggleResult) -___ +--- ### useScreenShare @@ -438,49 +478,19 @@ For implementing control bar for local peer, this is used based with useAVToggle #### Parameters -| Name | Type | Default value | Description | -| :------ | :------ | :------ | :------ | +| Name | Type | Default value | Description | +| :------------ | :------------------------------------------------------------------------------------ | :---------------- | :--------------------------------------------- | | `handleError` | [`hooksErrHandler`](/api-reference/javascript/v2/react-hooks/modules#hookserrhandler) | `logErrorHandler` | to handle any errors during screenshare toggle | #### Returns [`useScreenShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/useScreenShareResult) -___ -### useEmbedShare - -▸ **useEmbedShare**(): [`useEmbedShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult) - -#### Parameters - -| Name | Type | Default value | Description -| :------ | :------ | :------ | :------ | -| `resetConfig?` | ():`void` | `undefined` | Callback that implements cleanup after Embed sharing stops. It is an optional parameter. - -#### Returns - -[`useEmbedShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult) -___ - -### usePDFShare - -▸ **usePDFShare**(): [`usePDFShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult) - -#### Parameters - - -| Name | Type | Default value | Description -| :------ | :------ | :------ | :------ | -| `resetConfig?` | ():`void` | `undefined` | Callback that implements cleanup after PDF sharing stops. Typically used to reset the currently selected PDF file or URL in your state. It is an optional parameter. - -#### Returns - -[`usePDFShareResult`](/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult) -___ +--- ### useVideo -▸ **useVideo**(`__namedParameters`): [`useVideoOutput`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoOutput) +▸ **useVideo**(`«destructured»`): [`useVideoOutput`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoOutput) This hooks can be used to implement a video tile component. Given a track id it will return a ref. The returned ref can be used to set on a video element meant to display the video. @@ -489,19 +499,19 @@ goes out of view to save on bandwidth. #### Parameters -| Name | Type | -| :------ | :------ | -| `__namedParameters` | [`useVideoInput`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoInput) | +| Name | Type | +| :--------------- | :----------------------------------------------------------------------------------- | +| `«destructured»` | [`useVideoInput`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoInput) | #### Returns [`useVideoOutput`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoOutput) -___ +--- ### useVideoList -▸ **useVideoList**(`__namedParameters`): [`useVideoResult`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoResult) +▸ **useVideoList**(`«destructured»`): [`useVideoResult`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoResult) This hook can be used to build a paginated gallery view of video tiles. You can give the hook a list of all the peers which need to be shown and it tells you how to structure the UI by giving @@ -510,9 +520,9 @@ Please check the documentation of input and output types for more details. #### Parameters -| Name | Type | -| :------ | :------ | -| `__namedParameters` | [`useVideoListInput`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoListInput) | +| Name | Type | +| :--------------- | :------------------------------------------------------------------------------------------- | +| `«destructured»` | [`useVideoListInput`](/api-reference/javascript/v2/react-hooks/interfaces/useVideoListInput) | #### Returns diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useAVToggleResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useAVToggleResult.md index f82afc97af..42869b6587 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useAVToggleResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useAVToggleResult.md @@ -1,6 +1,6 @@ --- title: useAVToggleResult -nav: "5.2.1" +nav: '5.2.1' --- ## Properties @@ -11,13 +11,13 @@ nav: "5.2.1" true if unmuted and vice versa -___ +--- ### isLocalVideoEnabled • **isLocalVideoEnabled**: `boolean` -___ +--- ### toggleAudio @@ -34,7 +34,7 @@ has permission to unmute audio `void` -___ +--- ### toggleVideo diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useAutoplayErrorResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useAutoplayErrorResult.md index 6d5a052749..ab7e461300 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useAutoplayErrorResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useAutoplayErrorResult.md @@ -1,6 +1,6 @@ --- title: useAutoplayErrorResult -nav: "5.2.2" +nav: '5.2.2' --- ## Properties @@ -9,7 +9,7 @@ nav: "5.2.2" • **error**: `string` -___ +--- ### resetError @@ -25,7 +25,7 @@ Call this method to reset(hide) the UI that is rendered when there was an error `void` -___ +--- ### unblockAudio diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventInput.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventInput.md index 583d0bb645..68d36823c5 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventInput.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventInput.md @@ -1,13 +1,13 @@ --- title: useCustomEventInput -nav: "5.2.3" +nav: '5.2.3' --- ## Type parameters | Name | -| :------ | -| `T` | +| :--- | +| `T` | ## Properties @@ -17,7 +17,7 @@ nav: "5.2.3" function to handle errors happening during sending the event -___ +--- ### json @@ -33,7 +33,7 @@ Set it to `true` if you want to send/receive objects default value is true -___ +--- ### onEvent @@ -51,15 +51,15 @@ handling event in the UI. ##### Parameters -| Name | Type | -| :------ | :------ | -| `data` | `T` | +| Name | Type | +| :----- | :--- | +| `data` | `T` | ##### Returns `void` -___ +--- ### type diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult.md index 8937e6d554..0517ae4d12 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useCustomEventResult.md @@ -1,13 +1,13 @@ --- title: useCustomEventResult -nav: "5.2.4" +nav: '5.2.4' --- ## Type parameters | Name | -| :------ | -| `T` | +| :--- | +| `T` | ## Properties @@ -21,27 +21,29 @@ nav: "5.2.4" sends the event data to others in the room who will receive it in onEvent +##### Parameters + +| Name | Type | +| :---------- | :-------------- | +| `data` | `T` | +| `receiver?` | `EventReceiver` | + +##### Returns + +`void` + **`Example`** to send message to peers of specific roles + ```js -sendEvent(data, {roleNames: ['host','guest']}) +sendEvent(data, { roleNames: ['host', 'guest'] }); ``` **`Example`** to send message to single peer + ```js -sendEvent(data, {peerId}) +sendEvent(data, { peerId }); ``` - -##### Parameters - -| Name | Type | -| :------ | :------ | -| `data` | `T` | -| `receiver?` | `EventReceiver` | - -##### Returns - -`void` diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useDevicesResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useDevicesResult.md index e9d25ca5c1..e1df43cc38 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useDevicesResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useDevicesResult.md @@ -1,6 +1,6 @@ --- title: useDevicesResult -nav: "5.2.5" +nav: '5.2.5' --- ## Properties @@ -11,7 +11,7 @@ nav: "5.2.5" list of all devices by type -___ +--- ### selectedDeviceIDs @@ -19,25 +19,25 @@ ___ selected device ids for all types -___ +--- ### updateDevice -• **updateDevice**: (`__namedParameters`: { `deviceId`: `string` ; `deviceType`: `DeviceType` }) => `Promise`<`void`\> +• **updateDevice**: (`__namedParameters`: { `deviceId`: `string` ; `deviceType`: `DeviceType` }) => `Promise`<`void`\> #### Type declaration -▸ (`__namedParameters`): `Promise`<`void`\> +▸ (`«destructured»`): `Promise`<`void`\> function to call to update device ##### Parameters -| Name | Type | -| :------ | :------ | -| `__namedParameters` | `Object` | -| `__namedParameters.deviceId` | `string` | -| `__namedParameters.deviceType` | `DeviceType` | +| Name | Type | +| :--------------- | :----------- | +| `«destructured»` | `Object` | +| › `deviceId` | `string` | +| › `deviceType` | `DeviceType` | ##### Returns diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult.md index 4a8b6de4cf..de82a16954 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useEmbedShareResult.md @@ -1,41 +1,64 @@ --- title: useEmbedShareResult -nav: "5.2.18" +nav: '5.2.6' --- ## Properties +### iframeRef + +• **iframeRef**: `RefObject`<`null` \| `HTMLIFrameElement`\> + +Reference to attach to the iframe that is responsible for rendering the URL passed. + +--- + +### isEmbedShareInProgress + +• **isEmbedShareInProgress**: `boolean` + +Flag to check if an embed is currently being shared. + +--- + ### startEmbedShare -• **startEmbedShare**: (`value`: `string`): `Promise`<`void`\> +• **startEmbedShare**: (`value`: `string`) => `Promise`<`void`\> + +#### Type declaration + +▸ (`value`): `Promise`<`void`\> Embed and start sharing a URL. It will throw an error in the following scenarios: - - When the URL has not been passed - - When the reference has not been attached to an iframe - - When screen share cannot be started -___ +- When the URL has not been passed +- When the reference has not been attached to an iframe +- When screen share cannot be started -### stopEmbedShare +##### Parameters -• **stopEmbedShare**: (): `Promise`<`void`\> +| Name | Type | +| :------ | :------- | +| `value` | `string` | -Stop sharing the embed. +##### Returns -___ +`Promise`<`void`\> -### isEmbedShareInProgress +--- -• **isEmbedShareInProgress**: `boolean` +### stopEmbedShare -Flag to check if an embed is currently being shared. +• **stopEmbedShare**: () => `Promise`<`void`\> -___ +#### Type declaration -### iframeRef +▸ (): `Promise`<`void`\> -• **iframeRef**: React.RefObject +Stop sharing the embed. -Reference to attach to the iframe that is responsible for rendering the URL passed. +##### Returns + +`Promise`<`void`\> diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult.md index 2b8ae7d437..dbace23336 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/usePDFShareResult.md @@ -1,41 +1,63 @@ --- title: usePDFShareResult -nav: "5.2.19" +nav: '5.2.7' --- ## Properties +### iframeRef + +• **iframeRef**: `RefObject`<`null` \| `HTMLIFrameElement`\> + +Reference to attach to the iframe that is responsible for rendering the PDF. + +--- + +### isPDFShareInProgress + +• **isPDFShareInProgress**: `boolean` + +Flag to check if PDF sharing is currently in progress. + +--- + ### startPDFShare -• **startPDFShare**: (`value`: `File` | `string`): `Promise`<`void`\> +• **startPDFShare**: (`value`: `string` \| `File`) => `Promise`<`void`\> -Start sharing a PDF file or URL. +#### Type declaration + +▸ (`value`): `Promise`<`void`\> +Start sharing a PDF file or URL. It will throw an error in the following scenarios: - - When file or URL has not been passed, or is invalid - - When the reference has not been attached to an iframe - - When screen share cannot be started - -___ -### stopPDFShare +- When file or URL has not been passed, or is invalid +- When the reference has not been attached to an iframe +- When screen share cannot be started -• **stopPDFShare**: (): `Promise`<`void`\> +##### Parameters -Stop sharing the PDF file or URL. +| Name | Type | +| :------ | :----------------- | +| `value` | `string` \| `File` | -___ +##### Returns -### isPDFShareInProgress +`Promise`<`void`\> -• **isPDFShareInProgress**: `boolean` +--- -Flag to check if PDF sharing is currently in progress. +### stopPDFShare -___ +• **stopPDFShare**: () => `Promise`<`void`\> -### iframeRef +#### Type declaration -• **iframeRef**: React.RefObject +▸ (): `Promise`<`void`\> -Reference to attach to the iframe that is responsible for rendering the PDF. +Stop sharing the PDF file or URL. + +##### Returns + +`Promise`<`void`\> diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantListResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantListResult.md index d6fc027f25..c8969c8f01 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantListResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantListResult.md @@ -1,6 +1,6 @@ --- title: useParticipantListResult -nav: "5.2.6" +nav: '5.2.8' --- ## Properties @@ -9,19 +9,19 @@ nav: "5.2.6" • **isConnected**: `boolean` -___ +--- ### participantsByRoles • **participantsByRoles**: `Record`<`string`, `HMSPeer`[]\> -___ +--- ### peerCount • **peerCount**: `number` -___ +--- ### roles diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantsResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantsResult.md index 8d03bf50ed..46f062ec30 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantsResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useParticipantsResult.md @@ -1,6 +1,6 @@ --- title: useParticipantsResult -nav: "5.2.7" +nav: '5.2.9' --- ## Properties @@ -11,7 +11,7 @@ nav: "5.2.7" is joined in the room -___ +--- ### participants @@ -19,7 +19,7 @@ ___ list of participants that match the given filters -___ +--- ### peerCount @@ -27,7 +27,7 @@ ___ Total number of participants in the room -___ +--- ### rolesWithParticipants diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewInput.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewInput.md index 2a54458899..4b084f6146 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewInput.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewInput.md @@ -1,6 +1,6 @@ --- title: usePreviewInput -nav: "5.2.8" +nav: '5.2.10' --- ## Properties @@ -9,7 +9,7 @@ nav: "5.2.8" • `Optional` **asRole**: `string` -___ +--- ### autoManageVideo @@ -19,7 +19,7 @@ if this flag is enabled, the SDK takes care of unsubscribing to the video when i Additionally if simulcast is enabled, it takes care of auto managing simulcast layers based on the dimensions of the video element to conserve bandwidth. -___ +--- ### autoManageWakeLock @@ -28,7 +28,7 @@ ___ if this flag is enabled, wake lock will be acquired automatically(if supported) when joining the room, so the device will be kept awake. -___ +--- ### captureNetworkQualityInPreview @@ -39,7 +39,7 @@ Enable to get a network quality score while in preview. The score ranges from -1 0 when there is a timeout/failure when measuring the quality 1-5 ranges from poor to good quality. -___ +--- ### handleError @@ -47,13 +47,13 @@ ___ function to handle errors happening during preview -___ +--- ### initEndpoint • `Optional` **initEndpoint**: `string` -___ +--- ### initialSettings @@ -61,7 +61,7 @@ ___ initial settings for audio/video and device to be used. -___ +--- ### metadata @@ -69,7 +69,7 @@ ___ any extra metadata info for the peer -___ +--- ### name @@ -77,7 +77,7 @@ ___ name of user who is joining, this is only required if join is called -___ +--- ### token diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewResult.md index 920fc1972c..f33e7c43e2 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/usePreviewResult.md @@ -1,6 +1,6 @@ --- title: usePreviewResult -nav: "5.2.9" +nav: '5.2.11' --- ## Properties @@ -11,7 +11,7 @@ nav: "5.2.9" enable the join button for the user only when this is true -___ +--- ### isConnected @@ -20,7 +20,7 @@ ___ once the user has joined the room, till leave happens this flag will be true. It can be used to decide to show between preview form and conferencing component/video tiles. -___ +--- ### join @@ -36,7 +36,7 @@ call this function to join the room `Promise`<`void`\> -___ +--- ### preview diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useRecordingStreamingResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useRecordingStreamingResult.md index e85699ab9b..54724a2bc4 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useRecordingStreamingResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useRecordingStreamingResult.md @@ -1,6 +1,6 @@ --- title: useRecordingStreamingResult -nav: "5.2.10" +nav: '5.2.12' --- ## Properties @@ -9,37 +9,37 @@ nav: "5.2.10" • **isBrowserRecordingOn**: `boolean` -___ +--- ### isHLSRecordingOn • **isHLSRecordingOn**: `boolean` -___ +--- ### isHLSRunning • **isHLSRunning**: `boolean` -___ +--- ### isRTMPRunning • **isRTMPRunning**: `boolean` -___ +--- ### isRecordingOn • **isRecordingOn**: `boolean` -___ +--- ### isServerRecordingOn • **isServerRecordingOn**: `boolean` -___ +--- ### isStreamingOn diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useRemoteAVToggleResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useRemoteAVToggleResult.md index b2a560a0a6..7021739aa5 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useRemoteAVToggleResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useRemoteAVToggleResult.md @@ -1,6 +1,6 @@ --- title: useRemoteAVToggleResult -nav: "5.2.11" +nav: '5.2.13' --- ## Properties @@ -11,13 +11,13 @@ nav: "5.2.11" true if unmuted and vice versa -___ +--- ### isVideoEnabled • **isVideoEnabled**: `boolean` -___ +--- ### setVolume @@ -32,15 +32,15 @@ only be present if the remote peer has an audio track to change volume for ##### Parameters -| Name | Type | -| :------ | :------ | +| Name | Type | +| :------- | :------- | | `volume` | `number` | ##### Returns `void` -___ +--- ### toggleAudio @@ -57,7 +57,7 @@ has permission to mute/unmute remote audio `void` -___ +--- ### toggleVideo @@ -74,7 +74,7 @@ has permission to mute/unmute remote video `void` -___ +--- ### volume diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useScreenShareResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useScreenShareResult.md index 1ac52f553d..ad40990d59 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useScreenShareResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useScreenShareResult.md @@ -1,6 +1,6 @@ --- title: useScreenShareResult -nav: "5.2.12" +nav: '5.2.14' --- ## Properties @@ -11,7 +11,7 @@ nav: "5.2.12" true if the local user is sharing screen, false otherwise -___ +--- ### screenShareAudioTrackId @@ -19,7 +19,7 @@ ___ screenShare audio track id, will only be present if there is a screenshare with audio track -___ +--- ### screenShareVideoTrackId @@ -27,7 +27,7 @@ ___ screenShare audio track id, will only be present if there is a screenshare with video track -___ +--- ### screenSharingPeerId @@ -36,7 +36,7 @@ ___ the id of the peer who is currently sharing screen, will only be present if there is a screenshare in the room. In case of multiple screenshares, the behaviour of which one is picked is not defined. -___ +--- ### screenSharingPeerName @@ -45,7 +45,7 @@ ___ the name of the peer who is currently sharing screen. Will be undefined if no one is sharing the screen. In case of multiple screenshares, the behavior of which one is picked is not defined. -___ +--- ### toggleScreenShare @@ -59,8 +59,8 @@ toggle screenshare for the local user, will only be present if the user has the ##### Parameters -| Name | Type | -| :------ | :------ | +| Name | Type | +| :-------- | :--------------------- | | `config?` | `HMSScreenShareConfig` | ##### Returns diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoInput.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoInput.md index 93df7ef1cf..a02445bde9 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoInput.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoInput.md @@ -1,6 +1,6 @@ --- title: useVideoInput -nav: "5.2.13" +nav: '5.2.15' --- ## Properties @@ -12,7 +12,7 @@ nav: "5.2.13" Boolean stating whether to override the internal behaviour. when attach is false, even if tile is inView or enabled, it won't be rendered -___ +--- ### trackId diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListInput.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListInput.md index 34e9bd0652..cc4ea17e09 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListInput.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListInput.md @@ -1,6 +1,6 @@ --- title: useVideoListInput -nav: "5.2.14" +nav: '5.2.16' --- ## Properties @@ -14,12 +14,12 @@ capture in the dashboard template. #### Type declaration -| Name | Type | -| :------ | :------ | +| Name | Type | +| :------- | :------- | | `height` | `number` | -| `width` | `number` | +| `width` | `number` | -___ +--- ### filterNonPublishingPeers @@ -28,7 +28,7 @@ ___ By default this will be true. Only publishing(audio/video/screen) peers in the passed in peer list will be filtered. If you wish to show all peers, pass false for this. -___ +--- ### includeScreenShareForPeer @@ -46,39 +46,39 @@ for example. includeScreenShare = (peer) => return peer.id !== mainScreenSharing ##### Parameters -| Name | Type | -| :------ | :------ | +| Name | Type | +| :----- | :-------- | | `peer` | `HMSPeer` | ##### Returns `boolean` -___ +--- ### maxColCount • `Optional` **maxColCount**: `number` -Max columns in a page. Only applied if maxTileCount and maxRowCount are not present +Max columns in a page. Only applied if maxTileCount and maxRowCount are not present -___ +--- ### maxRowCount • `Optional` **maxRowCount**: `number` -Max rows in a page. Only applied if maxTileCount is not present +Max rows in a page. Only applied if maxTileCount is not present -___ +--- ### maxTileCount • `Optional` **maxTileCount**: `number` -Max tiles in a page. Overrides maxRowCount and maxColCount +Max tiles in a page. Overrides maxRowCount and maxColCount -___ +--- ### offsetY @@ -86,7 +86,7 @@ ___ Height that would be subtracted from the parent's height to give the available height, use case: if your pagination is inside the parent component then offsetY would be the height of pagination -___ +--- ### peers diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListTile.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListTile.md index dd6b3cf842..5f990dc1d8 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListTile.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoListTile.md @@ -1,6 +1,6 @@ --- title: useVideoListTile -nav: "5.2.15" +nav: '5.2.17' --- ## Hierarchy @@ -15,7 +15,7 @@ nav: "5.2.15" • **height**: `number` -___ +--- ### peer @@ -25,7 +25,7 @@ ___ TrackWithPeer.peer -___ +--- ### track @@ -35,7 +35,7 @@ ___ TrackWithPeer.track -___ +--- ### width diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoOutput.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoOutput.md index 94de530c37..5a27cfd6bf 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoOutput.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoOutput.md @@ -1,13 +1,13 @@ --- title: useVideoOutput -nav: "5.2.16" +nav: '5.2.18' --- ## Properties ### videoRef -• **videoRef**: (`instance`: ``null`` \| `HTMLVideoElement`) => `void` +• **videoRef**: (`instance`: `null` \| `HTMLVideoElement`) => `void` #### Type declaration @@ -15,9 +15,9 @@ nav: "5.2.16" ##### Parameters -| Name | Type | -| :------ | :------ | -| `instance` | ``null`` \| `HTMLVideoElement` | +| Name | Type | +| :--------- | :--------------------------- | +| `instance` | `null` \| `HTMLVideoElement` | ##### Returns diff --git a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoResult.md b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoResult.md index 131dd53634..9655f73f6e 100644 --- a/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoResult.md +++ b/docs/api-reference/javascript/v2/react-hooks/interfaces/useVideoResult.md @@ -1,6 +1,6 @@ --- title: useVideoResult -nav: "5.2.17" +nav: '5.2.19' --- ## Properties @@ -11,7 +11,7 @@ nav: "5.2.17" This returns a list of all pages with every page containing the list of all tiles on it. -___ +--- ### ref