@100mslive/hms-video-store 0.2.57 → 0.2.58
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/IHMSActions.d.ts +21 -18
- package/dist/core/hmsSDKStore/adapter.d.ts +2 -11
- package/dist/core/index.d.ts +1 -1
- package/dist/core/schema/index.d.ts +0 -1
- package/dist/core/schema/room.d.ts +3 -11
- package/dist/core/selectors/selectors.d.ts +2 -20
- package/dist/hms-video-store.cjs.development.js +2 -2
- package/dist/hms-video-store.cjs.development.js.map +1 -1
- package/dist/hms-video-store.cjs.production.min.js +1 -1
- package/dist/hms-video-store.cjs.production.min.js.map +1 -1
- package/dist/hms-video-store.esm.js +2 -2
- package/dist/hms-video-store.esm.js.map +1 -1
- package/package.json +3 -3
- package/src/core/IHMSActions.ts +31 -18
- package/src/core/hmsSDKStore/adapter.ts +2 -2
- package/src/core/index.ts +2 -0
- package/src/core/schema/index.ts +0 -1
- package/src/core/schema/room.ts +3 -11
- package/dist/core/schema/ui.d.ts +0 -11
- package/src/core/schema/ui.ts +0 -11
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { HMSConfig, HMSSimulcastLayer, HMSAudioTrackSettings, HMSVideoTrackSettings, HMSLogLevel, HMSVideoPlugin, HMSAudioPlugin } from '@100mslive/hms-video';
|
|
2
|
-
import { HMSPeerID, HMSRoleName, HMSTrackSource, IHMSPlaylistActions } from './schema';
|
|
2
|
+
import { HMSMessageID, HMSPeerID, HMSRoleName, HMSTrackID, HMSTrackSource, IHMSPlaylistActions } from './schema';
|
|
3
3
|
import { HMSRoleChangeRequest } from './selectors';
|
|
4
4
|
import { RTMPRecordingConfig } from './hmsSDKStore/sdkTypes';
|
|
5
5
|
/**
|
|
@@ -55,7 +55,7 @@ export interface IHMSActions {
|
|
|
55
55
|
* This method removes the track from the local peer's list of auxiliary tracks and unpublishes it.
|
|
56
56
|
* @param trackId string - ID of the track to be removed
|
|
57
57
|
*/
|
|
58
|
-
removeTrack(trackId:
|
|
58
|
+
removeTrack(trackId: HMSTrackID): Promise<void>;
|
|
59
59
|
/**
|
|
60
60
|
* @deprecated The method should not be used
|
|
61
61
|
* @see sendBroadcastMessage
|
|
@@ -93,21 +93,22 @@ export interface IHMSActions {
|
|
|
93
93
|
* @param readStatus boolean value which you want to set as read flag for message/messages.
|
|
94
94
|
* @param messageId message id whose read falg you want to set.
|
|
95
95
|
*/
|
|
96
|
-
setMessageRead(readStatus: boolean, messageId?:
|
|
96
|
+
setMessageRead(readStatus: boolean, messageId?: HMSMessageID): void;
|
|
97
97
|
/**
|
|
98
|
-
*
|
|
99
|
-
* @param enabled boolean
|
|
98
|
+
* This function can be used to enable/disable(unmute/mute) local audio track
|
|
99
|
+
* @param enabled boolean - true to unmute, false to mute
|
|
100
100
|
*/
|
|
101
101
|
setLocalAudioEnabled(enabled: boolean): Promise<void>;
|
|
102
102
|
/**
|
|
103
|
-
*
|
|
103
|
+
* This function can be used to enable/disable(unmute/mute) local video track
|
|
104
|
+
* @param enabled boolean - true to unmute, false to mute
|
|
104
105
|
*/
|
|
105
106
|
setLocalVideoEnabled(enabled: boolean): Promise<void>;
|
|
106
107
|
/**
|
|
107
108
|
* @param trackId string - ID of the track whose mute status needs to be set
|
|
108
109
|
* @param enabled boolean - true when we want to unmute the track and false when we want to unmute it
|
|
109
110
|
*/
|
|
110
|
-
setEnabledTrack(trackId:
|
|
111
|
+
setEnabledTrack(trackId: HMSTrackID, enabled: boolean): Promise<void>;
|
|
111
112
|
/**
|
|
112
113
|
* Change settings of the local peer's audio track
|
|
113
114
|
* @param settings HMSAudioTrackSettings
|
|
@@ -121,25 +122,25 @@ export interface IHMSActions {
|
|
|
121
122
|
*/
|
|
122
123
|
setVideoSettings(settings: Partial<HMSVideoTrackSettings>): Promise<void>;
|
|
123
124
|
/**
|
|
124
|
-
*
|
|
125
|
+
* You can use the attach and detach video function
|
|
125
126
|
* to add/remove video from an element for a track ID. The benefit of using this
|
|
126
127
|
* instead of removing the video yourself is that it'll also auto unsubscribe to
|
|
127
128
|
* the stream coming from server saving significant bandwidth for the user.
|
|
128
|
-
* @param
|
|
129
|
+
* @param localTrackID trackID as stored in the store for the peer
|
|
129
130
|
* @param videoElement HTML native element where the video has to be shown
|
|
130
131
|
*/
|
|
131
|
-
attachVideo(
|
|
132
|
+
attachVideo(localTrackID: HMSTrackID, videoElement: HTMLVideoElement): Promise<void>;
|
|
132
133
|
/**
|
|
133
134
|
* @see attachVideo
|
|
134
135
|
*/
|
|
135
|
-
detachVideo(
|
|
136
|
+
detachVideo(localTrackID: HMSTrackID, videoElement: HTMLVideoElement): Promise<void>;
|
|
136
137
|
/**
|
|
137
138
|
* Set the output volume of audio tracks(overall/particular audio track)
|
|
138
139
|
* @param value number between 0-100
|
|
139
140
|
* @param trackId string If undefined sets the overall volume(of every audio track in the room); If valid - set the volume of particular audio track
|
|
140
141
|
*
|
|
141
142
|
*/
|
|
142
|
-
setVolume(value: number, trackId?:
|
|
143
|
+
setVolume(value: number, trackId?: HMSTrackID): void;
|
|
143
144
|
/**
|
|
144
145
|
* Set the audio output(speaker) device
|
|
145
146
|
* @param deviceId string deviceId of the audio output device
|
|
@@ -150,7 +151,7 @@ export interface IHMSActions {
|
|
|
150
151
|
* @param trackId
|
|
151
152
|
* @param layer
|
|
152
153
|
*/
|
|
153
|
-
setPreferredLayer(trackId:
|
|
154
|
+
setPreferredLayer(trackId: HMSTrackID, layer: HMSSimulcastLayer): void;
|
|
154
155
|
/**
|
|
155
156
|
* Add or remove a video plugin from/to the local peer video track. Eg. Virtual Background, Face Filters etc.
|
|
156
157
|
* Video plugins can be added/removed at any time after the join is successful.
|
|
@@ -172,7 +173,7 @@ export interface IHMSActions {
|
|
|
172
173
|
* @param toRole The name of the new role.
|
|
173
174
|
* @param [force] this being true would mean that user won't get a request to accept role change
|
|
174
175
|
*/
|
|
175
|
-
changeRole(forPeerId:
|
|
176
|
+
changeRole(forPeerId: HMSPeerID, toRole: HMSRoleName, force?: boolean): Promise<void>;
|
|
176
177
|
/**
|
|
177
178
|
* Accept the role change request received
|
|
178
179
|
* @param {HMSRoleChangeRequest} request The original request that was received
|
|
@@ -189,9 +190,11 @@ export interface IHMSActions {
|
|
|
189
190
|
* @param forRemoteTrackID The track ID or array of track IDs for which you want to change the state
|
|
190
191
|
* @param enabled `true` if you wish to enable(unmute permission is required) the track, `false` if you wish to disable(mute permission is required) the track
|
|
191
192
|
*/
|
|
192
|
-
setRemoteTrackEnabled(forRemoteTrackID:
|
|
193
|
+
setRemoteTrackEnabled(forRemoteTrackID: HMSTrackID | HMSTrackID[], enabled: boolean): Promise<void>;
|
|
193
194
|
/**
|
|
194
|
-
*
|
|
195
|
+
* Most browsers have limitations where an audio can not be played if there was no user interaction.
|
|
196
|
+
* SDK throws an autoplay error in this case, this method can be called after an UI interaction
|
|
197
|
+
* to resolve the autoplay error
|
|
195
198
|
*/
|
|
196
199
|
unblockAudio: () => Promise<void>;
|
|
197
200
|
/**
|
|
@@ -201,12 +204,12 @@ export interface IHMSActions {
|
|
|
201
204
|
endRoom: (lock: boolean, reason: string) => Promise<void>;
|
|
202
205
|
/**
|
|
203
206
|
* If you have **removeOthers** permission, you can remove a peer from the room.
|
|
204
|
-
* @param peerID peerID of the peer to be removed from the
|
|
207
|
+
* @param peerID peerID of the peer to be removed from the room
|
|
205
208
|
* @param reason a string explaining why the peer is removed from the room.
|
|
206
209
|
* This string could be used to notify the user before they're removed from the room
|
|
207
210
|
* using the `REMOVED_FROM_ROOM` type of notification
|
|
208
211
|
*/
|
|
209
|
-
removePeer(peerID:
|
|
212
|
+
removePeer(peerID: HMSPeerID, reason: string): Promise<void>;
|
|
210
213
|
/**
|
|
211
214
|
* If you want to start RTMP streaming or recording.
|
|
212
215
|
* @param params.meetingURL This is the meeting url which is opened in a headless chrome instance for streaming and recording.
|
|
@@ -39,16 +39,7 @@ export declare class SDKToHMS {
|
|
|
39
39
|
};
|
|
40
40
|
private static getConvertedPlaylistType;
|
|
41
41
|
static convertRecordingRTMPState(recording: sdkTypes.HMSRecording | undefined, rtmp: sdkTypes.HMSRTMP | undefined): {
|
|
42
|
-
recording:
|
|
43
|
-
|
|
44
|
-
running: boolean;
|
|
45
|
-
};
|
|
46
|
-
server: {
|
|
47
|
-
running: boolean;
|
|
48
|
-
};
|
|
49
|
-
};
|
|
50
|
-
rtmp: {
|
|
51
|
-
running: boolean;
|
|
52
|
-
};
|
|
42
|
+
recording: sdkTypes.HMSRecording;
|
|
43
|
+
rtmp: sdkTypes.HMSRTMP;
|
|
53
44
|
};
|
|
54
45
|
}
|
package/dist/core/index.d.ts
CHANGED
|
@@ -4,4 +4,4 @@ export { IHMSNotifications as HMSNotifications } from './IHMSNotifications';
|
|
|
4
4
|
export { HMSReactiveStore } from './hmsSDKStore/HMSReactiveStore';
|
|
5
5
|
export * from './schema';
|
|
6
6
|
export * from './selectors';
|
|
7
|
-
export { HMSConfig, HMSAudioTrackSettings, HMSVideoTrackSettings, HMSSimulcastLayer, SimulcastLayerDefinition, DeviceMap, HMSLogLevel, RTMPRecordingConfig, } from './hmsSDKStore/sdkTypes';
|
|
7
|
+
export { HMSConfig, HMSAudioTrackSettings, HMSVideoTrackSettings, HMSSimulcastLayer, SimulcastLayerDefinition, DeviceMap, HMSLogLevel, RTMPRecordingConfig, HMSRecording, HMSRTMP, } from './hmsSDKStore/sdkTypes';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { HMSPeerID } from './peer';
|
|
2
|
+
import { HMSRecording, HMSRTMP } from '@100mslive/hms-video';
|
|
2
3
|
export declare type HMSRoomID = string;
|
|
3
4
|
export declare enum HMSRoomState {
|
|
4
5
|
Disconnected = "Disconnected",
|
|
@@ -17,15 +18,6 @@ export interface HMSRoom {
|
|
|
17
18
|
shareableLink: string;
|
|
18
19
|
hasWaitingRoom: boolean;
|
|
19
20
|
roomState: HMSRoomState;
|
|
20
|
-
recording:
|
|
21
|
-
|
|
22
|
-
running: boolean;
|
|
23
|
-
};
|
|
24
|
-
server: {
|
|
25
|
-
running: boolean;
|
|
26
|
-
};
|
|
27
|
-
};
|
|
28
|
-
rtmp: {
|
|
29
|
-
running: boolean;
|
|
30
|
-
};
|
|
21
|
+
recording: HMSRecording;
|
|
22
|
+
rtmp: HMSRTMP;
|
|
31
23
|
}
|
|
@@ -179,23 +179,5 @@ export declare const selectPermissions: import("reselect").OutputSelector<HMSSto
|
|
|
179
179
|
mute: boolean;
|
|
180
180
|
changeRole: boolean;
|
|
181
181
|
} | undefined>;
|
|
182
|
-
export declare const selectRecordingState: import("reselect").OutputSelector<HMSStore,
|
|
183
|
-
|
|
184
|
-
running: boolean;
|
|
185
|
-
};
|
|
186
|
-
server: {
|
|
187
|
-
running: boolean;
|
|
188
|
-
};
|
|
189
|
-
}, (res: HMSRoom) => {
|
|
190
|
-
browser: {
|
|
191
|
-
running: boolean;
|
|
192
|
-
};
|
|
193
|
-
server: {
|
|
194
|
-
running: boolean;
|
|
195
|
-
};
|
|
196
|
-
}>;
|
|
197
|
-
export declare const selectRTMPState: import("reselect").OutputSelector<HMSStore, {
|
|
198
|
-
running: boolean;
|
|
199
|
-
}, (res: HMSRoom) => {
|
|
200
|
-
running: boolean;
|
|
201
|
-
}>;
|
|
182
|
+
export declare const selectRecordingState: import("reselect").OutputSelector<HMSStore, import("@100mslive/hms-video/dist/interfaces/room").HMSRecording, (res: HMSRoom) => import("@100mslive/hms-video/dist/interfaces/room").HMSRecording>;
|
|
183
|
+
export declare const selectRTMPState: import("reselect").OutputSelector<HMSStore, import("@100mslive/hms-video/dist/interfaces/room").HMSRTMP, (res: HMSRoom) => import("@100mslive/hms-video/dist/interfaces/room").HMSRTMP>;
|
|
@@ -1295,12 +1295,12 @@ var SDKToHMS = /*#__PURE__*/function () {
|
|
|
1295
1295
|
};
|
|
1296
1296
|
|
|
1297
1297
|
SDKToHMS.convertRecordingRTMPState = function convertRecordingRTMPState(recording, rtmp) {
|
|
1298
|
-
var _recording$server;
|
|
1298
|
+
var _recording$browser, _recording$server;
|
|
1299
1299
|
|
|
1300
1300
|
return {
|
|
1301
1301
|
recording: {
|
|
1302
1302
|
browser: {
|
|
1303
|
-
running: !!(recording != null && recording.browser.running)
|
|
1303
|
+
running: !!(recording != null && (_recording$browser = recording.browser) != null && _recording$browser.running)
|
|
1304
1304
|
},
|
|
1305
1305
|
server: {
|
|
1306
1306
|
running: !!(recording != null && (_recording$server = recording.server) != null && _recording$server.running)
|