@webex/plugin-meetings 3.11.0-next.4 → 3.11.0-next.41
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/aiEnableRequest/index.js +184 -0
- package/dist/aiEnableRequest/index.js.map +1 -0
- package/dist/aiEnableRequest/utils.js +36 -0
- package/dist/aiEnableRequest/utils.js.map +1 -0
- package/dist/annotation/index.js +3 -3
- package/dist/annotation/index.js.map +1 -1
- package/dist/breakouts/breakout.js +1 -1
- package/dist/breakouts/index.js +1 -1
- package/dist/config.js +5 -1
- package/dist/config.js.map +1 -1
- package/dist/constants.js +26 -6
- package/dist/constants.js.map +1 -1
- package/dist/hashTree/constants.js +3 -1
- package/dist/hashTree/constants.js.map +1 -1
- package/dist/hashTree/hashTree.js +18 -0
- package/dist/hashTree/hashTree.js.map +1 -1
- package/dist/hashTree/hashTreeParser.js +709 -380
- package/dist/hashTree/hashTreeParser.js.map +1 -1
- package/dist/hashTree/types.js +4 -2
- package/dist/hashTree/types.js.map +1 -1
- package/dist/hashTree/utils.js +10 -0
- package/dist/hashTree/utils.js.map +1 -1
- package/dist/index.js +11 -2
- package/dist/index.js.map +1 -1
- package/dist/interceptors/constant.js +12 -0
- package/dist/interceptors/constant.js.map +1 -0
- package/dist/interceptors/dataChannelAuthToken.js +233 -0
- package/dist/interceptors/dataChannelAuthToken.js.map +1 -0
- package/dist/interceptors/index.js +7 -0
- package/dist/interceptors/index.js.map +1 -1
- package/dist/interpretation/index.js +2 -2
- package/dist/interpretation/index.js.map +1 -1
- package/dist/interpretation/siLanguage.js +1 -1
- package/dist/locus-info/controlsUtils.js +5 -3
- package/dist/locus-info/controlsUtils.js.map +1 -1
- package/dist/locus-info/index.js +125 -68
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/selfUtils.js +1 -0
- package/dist/locus-info/selfUtils.js.map +1 -1
- package/dist/locus-info/types.js.map +1 -1
- package/dist/media/MediaConnectionAwaiter.js +57 -1
- package/dist/media/MediaConnectionAwaiter.js.map +1 -1
- package/dist/media/properties.js +4 -2
- package/dist/media/properties.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +7 -1
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +209 -90
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/request.js +50 -0
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/request.type.js.map +1 -1
- package/dist/meeting/util.js +128 -2
- package/dist/meeting/util.js.map +1 -1
- package/dist/meetings/index.js +78 -36
- package/dist/meetings/index.js.map +1 -1
- package/dist/member/index.js +10 -0
- package/dist/member/index.js.map +1 -1
- package/dist/member/util.js +10 -0
- package/dist/member/util.js.map +1 -1
- package/dist/metrics/constants.js +2 -1
- package/dist/metrics/constants.js.map +1 -1
- package/dist/multistream/mediaRequestManager.js +1 -1
- package/dist/multistream/mediaRequestManager.js.map +1 -1
- package/dist/multistream/remoteMediaManager.js +11 -0
- package/dist/multistream/remoteMediaManager.js.map +1 -1
- package/dist/reactions/reactions.type.js.map +1 -1
- package/dist/types/aiEnableRequest/index.d.ts +5 -0
- package/dist/types/aiEnableRequest/utils.d.ts +2 -0
- package/dist/types/config.d.ts +3 -0
- package/dist/types/constants.d.ts +21 -1
- package/dist/types/hashTree/constants.d.ts +1 -0
- package/dist/types/hashTree/hashTree.d.ts +7 -0
- package/dist/types/hashTree/hashTreeParser.d.ts +99 -14
- package/dist/types/hashTree/types.d.ts +3 -0
- package/dist/types/hashTree/utils.d.ts +6 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/interceptors/constant.d.ts +5 -0
- package/dist/types/interceptors/dataChannelAuthToken.d.ts +35 -0
- package/dist/types/interceptors/index.d.ts +2 -1
- package/dist/types/locus-info/index.d.ts +9 -2
- package/dist/types/locus-info/types.d.ts +1 -0
- package/dist/types/media/MediaConnectionAwaiter.d.ts +10 -1
- package/dist/types/media/properties.d.ts +2 -1
- package/dist/types/meeting/in-meeting-actions.d.ts +6 -0
- package/dist/types/meeting/index.d.ts +24 -2
- package/dist/types/meeting/request.d.ts +16 -1
- package/dist/types/meeting/request.type.d.ts +5 -0
- package/dist/types/meeting/util.d.ts +31 -0
- package/dist/types/meetings/index.d.ts +4 -2
- package/dist/types/member/index.d.ts +1 -0
- package/dist/types/member/util.d.ts +5 -0
- package/dist/types/metrics/constants.d.ts +1 -0
- package/dist/types/reactions/reactions.type.d.ts +1 -0
- package/dist/webinar/index.js +1 -1
- package/package.json +22 -22
- package/src/aiEnableRequest/README.md +84 -0
- package/src/aiEnableRequest/index.ts +170 -0
- package/src/aiEnableRequest/utils.ts +25 -0
- package/src/annotation/index.ts +7 -4
- package/src/config.ts +3 -0
- package/src/constants.ts +26 -1
- package/src/hashTree/constants.ts +1 -0
- package/src/hashTree/hashTree.ts +17 -0
- package/src/hashTree/hashTreeParser.ts +627 -249
- package/src/hashTree/types.ts +4 -0
- package/src/hashTree/utils.ts +9 -0
- package/src/index.ts +8 -1
- package/src/interceptors/constant.ts +6 -0
- package/src/interceptors/dataChannelAuthToken.ts +142 -0
- package/src/interceptors/index.ts +2 -1
- package/src/interpretation/index.ts +2 -2
- package/src/locus-info/controlsUtils.ts +11 -0
- package/src/locus-info/index.ts +146 -58
- package/src/locus-info/selfUtils.ts +1 -0
- package/src/locus-info/types.ts +1 -0
- package/src/media/MediaConnectionAwaiter.ts +41 -1
- package/src/media/properties.ts +3 -1
- package/src/meeting/in-meeting-actions.ts +12 -0
- package/src/meeting/index.ts +127 -17
- package/src/meeting/request.ts +42 -0
- package/src/meeting/request.type.ts +6 -0
- package/src/meeting/util.ts +156 -1
- package/src/meetings/index.ts +94 -9
- package/src/member/index.ts +10 -0
- package/src/member/util.ts +12 -0
- package/src/metrics/constants.ts +1 -0
- package/src/multistream/mediaRequestManager.ts +1 -1
- package/src/multistream/remoteMediaManager.ts +13 -0
- package/src/reactions/reactions.type.ts +1 -0
- package/test/unit/spec/aiEnableRequest/index.ts +981 -0
- package/test/unit/spec/aiEnableRequest/utils.ts +130 -0
- package/test/unit/spec/hashTree/hashTree.ts +66 -0
- package/test/unit/spec/hashTree/hashTreeParser.ts +1869 -189
- package/test/unit/spec/interceptors/dataChannelAuthToken.ts +141 -0
- package/test/unit/spec/locus-info/controlsUtils.js +29 -0
- package/test/unit/spec/locus-info/index.js +201 -45
- package/test/unit/spec/media/MediaConnectionAwaiter.ts +41 -1
- package/test/unit/spec/media/properties.ts +12 -3
- package/test/unit/spec/meeting/in-meeting-actions.ts +8 -2
- package/test/unit/spec/meeting/index.js +441 -75
- package/test/unit/spec/meeting/request.js +64 -0
- package/test/unit/spec/meeting/utils.js +433 -22
- package/test/unit/spec/meetings/index.js +550 -10
- package/test/unit/spec/member/index.js +28 -4
- package/test/unit/spec/member/util.js +65 -27
- package/test/unit/spec/multistream/remoteMediaManager.ts +30 -0
package/src/meetings/index.ts
CHANGED
|
@@ -195,6 +195,8 @@ export default class Meetings extends WebexPlugin {
|
|
|
195
195
|
preferredWebexSite: any;
|
|
196
196
|
reachability: Reachability;
|
|
197
197
|
registered: any;
|
|
198
|
+
registrationPromise: Promise<void>;
|
|
199
|
+
unregistrationPromise: Promise<void>;
|
|
198
200
|
request: any;
|
|
199
201
|
geoHintInfo: any;
|
|
200
202
|
meetingInfo: any;
|
|
@@ -624,7 +626,7 @@ export default class Meetings extends WebexPlugin {
|
|
|
624
626
|
}
|
|
625
627
|
|
|
626
628
|
/**
|
|
627
|
-
* handles locus events through mercury that are not roap
|
|
629
|
+
* handles locus events through mercury that are not roap or approval request events
|
|
628
630
|
* @param {Object} envelope
|
|
629
631
|
* @param {Object} envelope.data
|
|
630
632
|
* @param {String} envelope.data.eventType
|
|
@@ -637,7 +639,11 @@ export default class Meetings extends WebexPlugin {
|
|
|
637
639
|
// eslint-disable-next-line @typescript-eslint/no-shadow
|
|
638
640
|
const {eventType} = data;
|
|
639
641
|
|
|
640
|
-
if (
|
|
642
|
+
if (
|
|
643
|
+
eventType &&
|
|
644
|
+
eventType !== LOCUSEVENT.MESSAGE_ROAP &&
|
|
645
|
+
eventType !== LOCUSEVENT.APPROVAL_REQUEST
|
|
646
|
+
) {
|
|
641
647
|
this.handleLocusEvent(data, true);
|
|
642
648
|
}
|
|
643
649
|
}
|
|
@@ -929,9 +935,20 @@ export default class Meetings extends WebexPlugin {
|
|
|
929
935
|
* @returns {Promise} A promise that resolves when the step is completed.
|
|
930
936
|
*/
|
|
931
937
|
executeRegistrationStep(step: () => Promise<any>, stepName: string) {
|
|
932
|
-
return step()
|
|
933
|
-
|
|
934
|
-
|
|
938
|
+
return step()
|
|
939
|
+
.then(() => {
|
|
940
|
+
LoggerProxy.logger.info(
|
|
941
|
+
`Meetings:index#executeRegistrationStep --> INFO, ${stepName} completed`
|
|
942
|
+
);
|
|
943
|
+
this.registrationStatus[stepName] = true;
|
|
944
|
+
})
|
|
945
|
+
.catch((error) => {
|
|
946
|
+
LoggerProxy.logger.error(
|
|
947
|
+
`Meetings:index#executeRegistrationStep --> ERROR, ${stepName} failed: ${error.message}`
|
|
948
|
+
);
|
|
949
|
+
|
|
950
|
+
return Promise.reject(error);
|
|
951
|
+
});
|
|
935
952
|
}
|
|
936
953
|
|
|
937
954
|
/**
|
|
@@ -944,7 +961,33 @@ export default class Meetings extends WebexPlugin {
|
|
|
944
961
|
* @memberof Meetings
|
|
945
962
|
*/
|
|
946
963
|
public register(deviceRegistrationOptions?: DeviceRegistrationOptions): Promise<any> {
|
|
947
|
-
this.
|
|
964
|
+
if (this.unregistrationPromise) {
|
|
965
|
+
LoggerProxy.logger.info(
|
|
966
|
+
'Meetings:index#register --> INFO, Meetings plugin unregistration in progress, waiting to register'
|
|
967
|
+
);
|
|
968
|
+
|
|
969
|
+
this.registrationPromise = this.unregistrationPromise
|
|
970
|
+
.catch(() => {}) // It doesn't matter what happened during unregistration
|
|
971
|
+
.finally(() => {
|
|
972
|
+
LoggerProxy.logger.info(
|
|
973
|
+
'Meetings:index#register --> INFO, Meetings plugin unregistration completed, proceeding to register'
|
|
974
|
+
);
|
|
975
|
+
|
|
976
|
+
this.registrationPromise = null;
|
|
977
|
+
|
|
978
|
+
return this.register(deviceRegistrationOptions);
|
|
979
|
+
});
|
|
980
|
+
|
|
981
|
+
return this.registrationPromise;
|
|
982
|
+
}
|
|
983
|
+
|
|
984
|
+
if (this.registrationPromise) {
|
|
985
|
+
LoggerProxy.logger.info(
|
|
986
|
+
'Meetings:index#register --> INFO, Meetings plugin registration in progress, returning existing promise'
|
|
987
|
+
);
|
|
988
|
+
|
|
989
|
+
return this.registrationPromise;
|
|
990
|
+
}
|
|
948
991
|
|
|
949
992
|
// @ts-ignore
|
|
950
993
|
if (!this.webex.canAuthorize) {
|
|
@@ -963,7 +1006,11 @@ export default class Meetings extends WebexPlugin {
|
|
|
963
1006
|
return Promise.resolve();
|
|
964
1007
|
}
|
|
965
1008
|
|
|
966
|
-
|
|
1009
|
+
LoggerProxy.logger.info('Meetings:index#register --> INFO, Registering Meetings plugin');
|
|
1010
|
+
|
|
1011
|
+
this.registrationStatus = clone(INITIAL_REGISTRATION_STATUS);
|
|
1012
|
+
|
|
1013
|
+
this.registrationPromise = Promise.all([
|
|
967
1014
|
this.executeRegistrationStep(() => this.fetchUserPreferredWebexSite(), 'fetchWebexSite'),
|
|
968
1015
|
this.executeRegistrationStep(() => this.getGeoHint(), 'getGeoHint'),
|
|
969
1016
|
this.executeRegistrationStep(
|
|
@@ -1022,7 +1069,12 @@ export default class Meetings extends WebexPlugin {
|
|
|
1022
1069
|
});
|
|
1023
1070
|
|
|
1024
1071
|
return Promise.reject(error);
|
|
1072
|
+
})
|
|
1073
|
+
.finally(() => {
|
|
1074
|
+
this.registrationPromise = null;
|
|
1025
1075
|
});
|
|
1076
|
+
|
|
1077
|
+
return this.registrationPromise;
|
|
1026
1078
|
}
|
|
1027
1079
|
|
|
1028
1080
|
/**
|
|
@@ -1034,6 +1086,35 @@ export default class Meetings extends WebexPlugin {
|
|
|
1034
1086
|
* @memberof Meetings
|
|
1035
1087
|
*/
|
|
1036
1088
|
unregister() {
|
|
1089
|
+
if (this.unregistrationPromise) {
|
|
1090
|
+
LoggerProxy.logger.info(
|
|
1091
|
+
'Meetings:index#unregister --> INFO, Meetings plugin unregistration in progress, returning existing promise'
|
|
1092
|
+
);
|
|
1093
|
+
|
|
1094
|
+
return this.unregistrationPromise;
|
|
1095
|
+
}
|
|
1096
|
+
|
|
1097
|
+
if (this.registrationPromise) {
|
|
1098
|
+
LoggerProxy.logger.info(
|
|
1099
|
+
'Meetings:index#unregister --> INFO, Meetings plugin registration in progress, waiting to unregister'
|
|
1100
|
+
);
|
|
1101
|
+
|
|
1102
|
+
// Wait for registration to complete (success or failure), then call unregister again
|
|
1103
|
+
this.unregistrationPromise = this.registrationPromise
|
|
1104
|
+
.catch(() => {}) // It doesn't matter what happened during registration
|
|
1105
|
+
.finally(() => {
|
|
1106
|
+
LoggerProxy.logger.info(
|
|
1107
|
+
'Meetings:index#unregister --> INFO, Meetings plugin registration completed, proceeding to unregister'
|
|
1108
|
+
);
|
|
1109
|
+
|
|
1110
|
+
this.unregistrationPromise = null;
|
|
1111
|
+
|
|
1112
|
+
return this.unregister();
|
|
1113
|
+
});
|
|
1114
|
+
|
|
1115
|
+
return this.unregistrationPromise;
|
|
1116
|
+
}
|
|
1117
|
+
|
|
1037
1118
|
if (!this.registered) {
|
|
1038
1119
|
LoggerProxy.logger.info(
|
|
1039
1120
|
'Meetings:index#unregister --> INFO, Meetings plugin already unregistered'
|
|
@@ -1044,7 +1125,7 @@ export default class Meetings extends WebexPlugin {
|
|
|
1044
1125
|
|
|
1045
1126
|
this.stopListeningForEvents();
|
|
1046
1127
|
|
|
1047
|
-
|
|
1128
|
+
this.unregistrationPromise =
|
|
1048
1129
|
// @ts-ignore
|
|
1049
1130
|
this.webex.internal.mercury
|
|
1050
1131
|
// Use code 3050 with a non-reconnecting reason to prevent Mercury auto-reconnect
|
|
@@ -1081,7 +1162,11 @@ export default class Meetings extends WebexPlugin {
|
|
|
1081
1162
|
this.registered = false;
|
|
1082
1163
|
this.registrationStatus = clone(INITIAL_REGISTRATION_STATUS);
|
|
1083
1164
|
})
|
|
1084
|
-
|
|
1165
|
+
.finally(() => {
|
|
1166
|
+
this.unregistrationPromise = null;
|
|
1167
|
+
});
|
|
1168
|
+
|
|
1169
|
+
return this.unregistrationPromise;
|
|
1085
1170
|
}
|
|
1086
1171
|
|
|
1087
1172
|
/**
|
package/src/member/index.ts
CHANGED
|
@@ -13,6 +13,7 @@ export type MemberId = string;
|
|
|
13
13
|
export default class Member {
|
|
14
14
|
associatedUser: MemberId | null; // deprecated, use associatedUsers instead
|
|
15
15
|
associatedUsers: Set<MemberId>; // users associated with this device, empty if this member is not a device
|
|
16
|
+
canApproveAIEnablement: boolean;
|
|
16
17
|
canReclaimHost: boolean;
|
|
17
18
|
id: MemberId;
|
|
18
19
|
isAudioMuted: any;
|
|
@@ -291,6 +292,14 @@ export default class Member {
|
|
|
291
292
|
*/
|
|
292
293
|
this.isPresenterAssignmentProhibited = null;
|
|
293
294
|
|
|
295
|
+
/**
|
|
296
|
+
* @instance
|
|
297
|
+
* @type {Boolean}
|
|
298
|
+
* @public
|
|
299
|
+
* @memberof Member
|
|
300
|
+
*/
|
|
301
|
+
this.canApproveAIEnablement = null;
|
|
302
|
+
|
|
294
303
|
/**
|
|
295
304
|
* @instance
|
|
296
305
|
* @type {Boolean}
|
|
@@ -360,6 +369,7 @@ export default class Member {
|
|
|
360
369
|
MemberUtil.isModeratorAssignmentProhibited(participant);
|
|
361
370
|
this.isPresenterAssignmentProhibited =
|
|
362
371
|
MemberUtil.isPresenterAssignmentProhibited(participant);
|
|
372
|
+
this.canApproveAIEnablement = MemberUtil.canApproveAIEnablement(participant);
|
|
363
373
|
this.processStatus(participant);
|
|
364
374
|
this.processRoles(participant);
|
|
365
375
|
// must be done last
|
package/src/member/util.ts
CHANGED
|
@@ -42,6 +42,18 @@ const MemberUtil = {
|
|
|
42
42
|
return participant.canReclaimHostRole || false;
|
|
43
43
|
},
|
|
44
44
|
|
|
45
|
+
/**
|
|
46
|
+
* @param {Object} participant - The locus participant object.
|
|
47
|
+
* @returns {Boolean}
|
|
48
|
+
*/
|
|
49
|
+
canApproveAIEnablement: (participant) => {
|
|
50
|
+
if (!participant) {
|
|
51
|
+
return false;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
return !participant.attendeeRequestAiAssistantNotAllowed;
|
|
55
|
+
},
|
|
56
|
+
|
|
45
57
|
/**
|
|
46
58
|
* @param {Object} participant - The locus participant object.
|
|
47
59
|
* @returns {[ServerRoleShape]}
|
package/src/metrics/constants.ts
CHANGED
|
@@ -90,6 +90,7 @@ const BEHAVIORAL_METRICS = {
|
|
|
90
90
|
MEDIA_ISSUE_DETECTED: 'js_sdk_media_issue_detected',
|
|
91
91
|
LOCUS_CLASSIC_VS_HASH_TREE_MISMATCH: 'js_sdk_locus_classic_vs_hash_tree_mismatch',
|
|
92
92
|
LOCUS_HASH_TREE_UNSUPPORTED_OPERATION: 'js_sdk_locus_hash_tree_unsupported_operation',
|
|
93
|
+
MEDIA_STILL_NOT_CONNECTED: 'js_sdk_media_still_not_connected',
|
|
93
94
|
};
|
|
94
95
|
|
|
95
96
|
export {BEHAVIORAL_METRICS as default};
|
|
@@ -356,7 +356,7 @@ export class MediaRequestManager {
|
|
|
356
356
|
mr.receiveSlots.map((receiveSlot) => receiveSlot.wcmeReceiveSlot),
|
|
357
357
|
this.getMaxPayloadBitsPerSecond(mr),
|
|
358
358
|
mr.codecInfo && [
|
|
359
|
-
|
|
359
|
+
WcmeCodecInfo.fromH264(
|
|
360
360
|
0x80,
|
|
361
361
|
new H264Codec(
|
|
362
362
|
mr.codecInfo.maxFs,
|
|
@@ -67,6 +67,18 @@ const AllEqualLayout: VideoLayout = {
|
|
|
67
67
|
],
|
|
68
68
|
};
|
|
69
69
|
|
|
70
|
+
// An "all equal" grid, with size up to 5 x 5 = 25:
|
|
71
|
+
const AllEqual25Layout: VideoLayout = {
|
|
72
|
+
activeSpeakerVideoPaneGroups: [
|
|
73
|
+
{
|
|
74
|
+
id: 'main',
|
|
75
|
+
numPanes: 25,
|
|
76
|
+
size: 'best',
|
|
77
|
+
priority: 255,
|
|
78
|
+
},
|
|
79
|
+
],
|
|
80
|
+
};
|
|
81
|
+
|
|
70
82
|
// A layout with just a single remote active speaker video pane:
|
|
71
83
|
const SingleLayout: VideoLayout = {
|
|
72
84
|
activeSpeakerVideoPaneGroups: [
|
|
@@ -164,6 +176,7 @@ export const DefaultConfiguration: Configuration = {
|
|
|
164
176
|
|
|
165
177
|
layouts: {
|
|
166
178
|
AllEqual: AllEqualLayout,
|
|
179
|
+
AllEqual25: AllEqual25Layout,
|
|
167
180
|
OnePlusFive: OnePlusFiveLayout,
|
|
168
181
|
Single: SingleLayout,
|
|
169
182
|
Stage: Stage2x2With6ThumbnailsLayout,
|