@trtc/calls-uikit-react 4.2.0 → 4.2.2
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/package.json +4 -3
- package/src/TUICallService/CallService/chatCombine.ts +5 -19
- package/src/TUICallService/CallService/index.ts +1 -1
- package/src/index.ts +1 -1
- package/tuicall-uikit-react.es.js +909 -922
- package/tuicall-uikit-react.umd.js +7 -7
- package/types/TUICallService/CallService/chatCombine.d.ts +0 -1
- package/src/TUICallService/utils/validate/validateStatus.ts +0 -26
- package/types/TUICallService/utils/validate/validateStatus.d.ts +0 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trtc/calls-uikit-react",
|
|
3
|
-
"version": "4.2.
|
|
3
|
+
"version": "4.2.2",
|
|
4
4
|
"main": "./tuicall-uikit-react.umd.js",
|
|
5
5
|
"module": "./tuicall-uikit-react.es.js",
|
|
6
6
|
"types": "./types/index.d.ts",
|
|
@@ -14,8 +14,9 @@
|
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
16
|
"@tencentcloud/tui-core-lite": "1.0.0",
|
|
17
|
-
"@trtc/call-engine-lite-js": "
|
|
18
|
-
"@tencentcloud/lite-chat": "^1.5.0"
|
|
17
|
+
"@trtc/call-engine-lite-js": "~3.4.0",
|
|
18
|
+
"@tencentcloud/lite-chat": "^1.5.0",
|
|
19
|
+
"@trtc/call-engine-lite-wx": "~3.4.3"
|
|
19
20
|
},
|
|
20
21
|
"bugs": {
|
|
21
22
|
"url": "https://github.com/tencentyun/TUICallKit/issues"
|
|
@@ -275,31 +275,17 @@ export default class ChatCombine {
|
|
|
275
275
|
*/
|
|
276
276
|
private async _handleTUICoreOnClick(options, type: CallMediaType) {
|
|
277
277
|
try {
|
|
278
|
-
const isForceUseV2API = TUIStore.getData(StoreName.CALL, NAME.IS_FORCE_USE_V2_API);
|
|
279
278
|
const { groupID, userIDList = [], version = '', ...rest } = options;
|
|
280
279
|
|
|
281
|
-
|
|
282
|
-
await this._useV2API({ ...options, type });
|
|
283
|
-
return;
|
|
284
|
-
}
|
|
285
|
-
if (version === 'v3') {
|
|
286
|
-
await this._callService?.calls({ chatGroupID: groupID, userIDList, type, ...rest });
|
|
287
|
-
return;
|
|
288
|
-
}
|
|
289
|
-
await this._useV2API({ ...options, type });
|
|
280
|
+
await this._callService?.calls({ chatGroupID: groupID, userIDList, type, ...rest });
|
|
290
281
|
} catch (error: any) {
|
|
282
|
+
// call update to lite-chat only support calls interface
|
|
283
|
+
if (!options?.version) {
|
|
284
|
+
console.warn('Please upgrade to the latest Chat UIKit components.');
|
|
285
|
+
}
|
|
291
286
|
console.debug(error);
|
|
292
287
|
}
|
|
293
288
|
}
|
|
294
|
-
private async _useV2API(options) {
|
|
295
|
-
const { groupID, userIDList = [], type, ...rest } = options || {};
|
|
296
|
-
|
|
297
|
-
if (groupID) {
|
|
298
|
-
await this._callService?.groupCall({ groupID, userIDList, type, ...rest });
|
|
299
|
-
} else if (userIDList.length === 1) {
|
|
300
|
-
await this._callService?.call({ userID: userIDList[0], type, ...rest });
|
|
301
|
-
}
|
|
302
|
-
}
|
|
303
289
|
private async _handleGroupAttributesUpdated(event) {
|
|
304
290
|
if (TUIStore.getData(StoreName.CALL, NAME.CALL_STATUS) !== CallStatus.IDLE) return;
|
|
305
291
|
|
|
@@ -26,7 +26,7 @@ const TUIGlobal: ITUIGlobal = TuiGlobal.getInstance();
|
|
|
26
26
|
const TUIStore: ITUIStore = TuiStore.getInstance();
|
|
27
27
|
const uiDesign = UIDesign.getInstance();
|
|
28
28
|
uiDesign.setTUIStore(TUIStore);
|
|
29
|
-
const version = '4.2.
|
|
29
|
+
const version = '4.2.2';
|
|
30
30
|
const frameWork = 'react';
|
|
31
31
|
export { TUIGlobal, TUIStore, uiDesign };
|
|
32
32
|
|