@webex/plugin-meetings 3.0.0-beta.16 → 3.0.0-beta.161
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/README.md +45 -1
- package/dist/annotation/annotation.types.js +7 -0
- package/dist/annotation/annotation.types.js.map +1 -0
- package/dist/annotation/constants.js +49 -0
- package/dist/annotation/constants.js.map +1 -0
- package/dist/annotation/index.js +359 -0
- package/dist/annotation/index.js.map +1 -0
- package/dist/breakouts/breakout.js +212 -0
- package/dist/breakouts/breakout.js.map +1 -0
- package/dist/breakouts/collection.js +23 -0
- package/dist/breakouts/collection.js.map +1 -0
- package/dist/breakouts/edit-lock-error.js +52 -0
- package/dist/breakouts/edit-lock-error.js.map +1 -0
- package/dist/breakouts/events.js +43 -0
- package/dist/breakouts/events.js.map +1 -0
- package/dist/breakouts/index.js +1046 -0
- package/dist/breakouts/index.js.map +1 -0
- package/dist/breakouts/request.js +78 -0
- package/dist/breakouts/request.js.map +1 -0
- package/dist/breakouts/utils.js +67 -0
- package/dist/breakouts/utils.js.map +1 -0
- package/dist/common/errors/webex-errors.js +3 -2
- package/dist/common/errors/webex-errors.js.map +1 -1
- package/dist/common/logs/logger-proxy.js +1 -1
- package/dist/common/logs/logger-proxy.js.map +1 -1
- package/dist/config.js +6 -8
- package/dist/config.js.map +1 -1
- package/dist/constants.js +175 -26
- package/dist/constants.js.map +1 -1
- package/dist/controls-options-manager/constants.js +14 -0
- package/dist/controls-options-manager/constants.js.map +1 -0
- package/dist/controls-options-manager/enums.js +27 -0
- package/dist/controls-options-manager/enums.js.map +1 -0
- package/dist/controls-options-manager/index.js +297 -0
- package/dist/controls-options-manager/index.js.map +1 -0
- package/dist/controls-options-manager/types.js +7 -0
- package/dist/controls-options-manager/types.js.map +1 -0
- package/dist/controls-options-manager/util.js +300 -0
- package/dist/controls-options-manager/util.js.map +1 -0
- package/dist/index.js +77 -0
- package/dist/index.js.map +1 -1
- package/dist/interpretation/collection.js +23 -0
- package/dist/interpretation/collection.js.map +1 -0
- package/dist/interpretation/index.js +214 -0
- package/dist/interpretation/index.js.map +1 -0
- package/dist/interpretation/siLanguage.js +25 -0
- package/dist/interpretation/siLanguage.js.map +1 -0
- package/dist/locus-info/controlsUtils.js +92 -2
- package/dist/locus-info/controlsUtils.js.map +1 -1
- package/dist/locus-info/index.js +317 -24
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/mediaSharesUtils.js +43 -1
- package/dist/locus-info/mediaSharesUtils.js.map +1 -1
- package/dist/locus-info/parser.js +2 -1
- package/dist/locus-info/parser.js.map +1 -1
- package/dist/locus-info/selfUtils.js +97 -14
- package/dist/locus-info/selfUtils.js.map +1 -1
- package/dist/media/index.js +39 -134
- package/dist/media/index.js.map +1 -1
- package/dist/media/properties.js +19 -97
- package/dist/media/properties.js.map +1 -1
- package/dist/mediaQualityMetrics/config.js +505 -493
- package/dist/mediaQualityMetrics/config.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +79 -1
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +2349 -2178
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/locusMediaRequest.js +291 -0
- package/dist/meeting/locusMediaRequest.js.map +1 -0
- package/dist/meeting/muteState.js +229 -124
- package/dist/meeting/muteState.js.map +1 -1
- package/dist/meeting/request.js +191 -167
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/request.type.js.map +1 -1
- package/dist/meeting/util.js +444 -443
- package/dist/meeting/util.js.map +1 -1
- package/dist/meeting-info/meeting-info-v2.js +157 -49
- package/dist/meeting-info/meeting-info-v2.js.map +1 -1
- package/dist/meeting-info/utilv2.js +20 -5
- package/dist/meeting-info/utilv2.js.map +1 -1
- package/dist/meetings/collection.js +22 -0
- package/dist/meetings/collection.js.map +1 -1
- package/dist/meetings/index.js +365 -73
- package/dist/meetings/index.js.map +1 -1
- package/dist/meetings/meetings.types.js +7 -0
- package/dist/meetings/meetings.types.js.map +1 -0
- package/dist/meetings/request.js +16 -12
- package/dist/meetings/request.js.map +1 -1
- package/dist/meetings/util.js +88 -1
- package/dist/meetings/util.js.map +1 -1
- package/dist/member/index.js +43 -0
- package/dist/member/index.js.map +1 -1
- package/dist/member/types.js +15 -0
- package/dist/member/types.js.map +1 -0
- package/dist/member/util.js +97 -3
- package/dist/member/util.js.map +1 -1
- package/dist/members/collection.js +10 -0
- package/dist/members/collection.js.map +1 -1
- package/dist/members/index.js +94 -11
- package/dist/members/index.js.map +1 -1
- package/dist/members/request.js +109 -39
- package/dist/members/request.js.map +1 -1
- package/dist/members/types.js +15 -0
- package/dist/members/types.js.map +1 -0
- package/dist/members/util.js +316 -233
- package/dist/members/util.js.map +1 -1
- package/dist/metrics/config.js +50 -14
- package/dist/metrics/config.js.map +1 -1
- package/dist/metrics/constants.js +3 -5
- package/dist/metrics/constants.js.map +1 -1
- package/dist/metrics/index.js +48 -29
- package/dist/metrics/index.js.map +1 -1
- package/dist/multistream/mediaRequestManager.js +265 -36
- package/dist/multistream/mediaRequestManager.js.map +1 -1
- package/dist/multistream/receiveSlot.js +52 -19
- package/dist/multistream/receiveSlot.js.map +1 -1
- package/dist/multistream/receiveSlotManager.js +53 -33
- package/dist/multistream/receiveSlotManager.js.map +1 -1
- package/dist/multistream/remoteMedia.js +44 -18
- package/dist/multistream/remoteMedia.js.map +1 -1
- package/dist/multistream/remoteMediaGroup.js +60 -3
- package/dist/multistream/remoteMediaGroup.js.map +1 -1
- package/dist/multistream/remoteMediaManager.js +322 -103
- package/dist/multistream/remoteMediaManager.js.map +1 -1
- package/dist/networkQualityMonitor/index.js +4 -2
- package/dist/networkQualityMonitor/index.js.map +1 -1
- package/dist/reachability/index.js +117 -60
- package/dist/reachability/index.js.map +1 -1
- package/dist/reachability/request.js +12 -5
- package/dist/reachability/request.js.map +1 -1
- package/dist/reactions/constants.js +13 -0
- package/dist/reactions/constants.js.map +1 -0
- package/dist/reactions/reactions.js +2 -2
- package/dist/reactions/reactions.js.map +1 -1
- package/dist/reactions/reactions.type.js +18 -18
- package/dist/reactions/reactions.type.js.map +1 -1
- package/dist/reconnection-manager/index.js +190 -145
- package/dist/reconnection-manager/index.js.map +1 -1
- package/dist/recording-controller/enums.js +17 -0
- package/dist/recording-controller/enums.js.map +1 -0
- package/dist/recording-controller/index.js +343 -0
- package/dist/recording-controller/index.js.map +1 -0
- package/dist/recording-controller/util.js +63 -0
- package/dist/recording-controller/util.js.map +1 -0
- package/dist/roap/index.js +21 -29
- package/dist/roap/index.js.map +1 -1
- package/dist/roap/request.js +127 -92
- package/dist/roap/request.js.map +1 -1
- package/dist/roap/turnDiscovery.js +135 -53
- package/dist/roap/turnDiscovery.js.map +1 -1
- package/dist/statsAnalyzer/global.js +1 -93
- package/dist/statsAnalyzer/global.js.map +1 -1
- package/dist/statsAnalyzer/index.js +329 -314
- package/dist/statsAnalyzer/index.js.map +1 -1
- package/dist/statsAnalyzer/mqaUtil.js +103 -54
- package/dist/statsAnalyzer/mqaUtil.js.map +1 -1
- package/dist/types/annotation/annotation.types.d.ts +43 -0
- package/dist/types/annotation/constants.d.ts +31 -0
- package/dist/types/annotation/index.d.ts +124 -0
- package/dist/types/breakouts/breakout.d.ts +8 -0
- package/dist/types/breakouts/collection.d.ts +5 -0
- package/dist/types/breakouts/edit-lock-error.d.ts +15 -0
- package/dist/types/breakouts/events.d.ts +2 -0
- package/dist/types/breakouts/index.d.ts +5 -0
- package/dist/types/breakouts/request.d.ts +22 -0
- package/dist/types/breakouts/utils.d.ts +15 -0
- package/dist/types/common/browser-detection.d.ts +9 -0
- package/dist/types/common/collection.d.ts +48 -0
- package/dist/types/common/config.d.ts +2 -0
- package/dist/types/common/errors/captcha-error.d.ts +15 -0
- package/dist/types/common/errors/intent-to-join.d.ts +16 -0
- package/dist/types/common/errors/join-meeting.d.ts +17 -0
- package/dist/types/common/errors/media.d.ts +15 -0
- package/dist/types/common/errors/parameter.d.ts +15 -0
- package/dist/types/common/errors/password-error.d.ts +15 -0
- package/dist/types/common/errors/permission.d.ts +14 -0
- package/dist/types/common/errors/reconnection-in-progress.d.ts +9 -0
- package/dist/types/common/errors/reconnection.d.ts +15 -0
- package/dist/types/common/errors/stats.d.ts +15 -0
- package/dist/types/common/errors/webex-errors.d.ts +69 -0
- package/dist/types/common/errors/webex-meetings-error.d.ts +20 -0
- package/dist/types/common/events/events-scope.d.ts +17 -0
- package/dist/types/common/events/events.d.ts +12 -0
- package/dist/types/common/events/trigger-proxy.d.ts +2 -0
- package/dist/types/common/events/util.d.ts +2 -0
- package/dist/types/common/logs/logger-config.d.ts +2 -0
- package/dist/types/common/logs/logger-proxy.d.ts +2 -0
- package/dist/types/common/logs/request.d.ts +34 -0
- package/dist/types/common/queue.d.ts +32 -0
- package/dist/types/config.d.ts +72 -0
- package/dist/types/constants.d.ts +987 -0
- package/dist/types/controls-options-manager/constants.d.ts +4 -0
- package/dist/types/controls-options-manager/enums.d.ts +15 -0
- package/dist/types/controls-options-manager/index.d.ts +136 -0
- package/dist/types/controls-options-manager/types.d.ts +43 -0
- package/dist/types/controls-options-manager/util.d.ts +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/interpretation/collection.d.ts +5 -0
- package/dist/types/interpretation/index.d.ts +5 -0
- package/dist/types/interpretation/siLanguage.d.ts +5 -0
- package/dist/types/locus-info/controlsUtils.d.ts +2 -0
- package/dist/types/locus-info/embeddedAppsUtils.d.ts +2 -0
- package/dist/types/locus-info/fullState.d.ts +2 -0
- package/dist/types/locus-info/hostUtils.d.ts +2 -0
- package/dist/types/locus-info/index.d.ts +315 -0
- package/dist/types/locus-info/infoUtils.d.ts +2 -0
- package/dist/types/locus-info/mediaSharesUtils.d.ts +2 -0
- package/dist/types/locus-info/parser.d.ts +212 -0
- package/dist/types/locus-info/selfUtils.d.ts +2 -0
- package/dist/types/media/index.d.ts +34 -0
- package/dist/types/media/properties.d.ts +86 -0
- package/dist/types/media/util.d.ts +2 -0
- package/dist/types/mediaQualityMetrics/config.d.ts +365 -0
- package/dist/types/meeting/in-meeting-actions.d.ts +149 -0
- package/dist/types/meeting/index.d.ts +1524 -0
- package/dist/types/meeting/locusMediaRequest.d.ts +70 -0
- package/dist/types/meeting/muteState.d.ts +184 -0
- package/dist/types/meeting/request.d.ts +270 -0
- package/dist/types/meeting/request.type.d.ts +11 -0
- package/dist/types/meeting/state.d.ts +9 -0
- package/dist/types/meeting/util.d.ts +75 -0
- package/dist/types/meeting-info/collection.d.ts +20 -0
- package/dist/types/meeting-info/index.d.ts +57 -0
- package/dist/types/meeting-info/meeting-info-v2.d.ts +122 -0
- package/dist/types/meeting-info/request.d.ts +22 -0
- package/dist/types/meeting-info/util.d.ts +2 -0
- package/dist/types/meeting-info/utilv2.d.ts +2 -0
- package/dist/types/meetings/collection.d.ts +31 -0
- package/dist/types/meetings/index.d.ts +364 -0
- package/dist/types/meetings/meetings.types.d.ts +4 -0
- package/dist/types/meetings/request.d.ts +27 -0
- package/dist/types/meetings/util.d.ts +18 -0
- package/dist/types/member/index.d.ts +158 -0
- package/dist/types/member/types.d.ts +21 -0
- package/dist/types/member/util.d.ts +2 -0
- package/dist/types/members/collection.d.ts +29 -0
- package/dist/types/members/index.d.ts +353 -0
- package/dist/types/members/request.d.ts +114 -0
- package/dist/types/members/types.d.ts +24 -0
- package/dist/types/members/util.d.ts +210 -0
- package/dist/types/metrics/config.d.ts +195 -0
- package/dist/types/metrics/constants.d.ts +55 -0
- package/dist/types/metrics/index.d.ts +169 -0
- package/dist/types/multistream/mediaRequestManager.d.ts +118 -0
- package/dist/types/multistream/receiveSlot.d.ts +68 -0
- package/dist/types/multistream/receiveSlotManager.d.ts +56 -0
- package/dist/types/multistream/remoteMedia.d.ts +72 -0
- package/dist/types/multistream/remoteMediaGroup.d.ts +47 -0
- package/dist/types/multistream/remoteMediaManager.d.ts +277 -0
- package/dist/types/networkQualityMonitor/index.d.ts +70 -0
- package/dist/types/personal-meeting-room/index.d.ts +47 -0
- package/dist/types/personal-meeting-room/request.d.ts +14 -0
- package/dist/types/personal-meeting-room/util.d.ts +2 -0
- package/dist/types/reachability/index.d.ts +152 -0
- package/dist/types/reachability/request.d.ts +37 -0
- package/dist/types/reactions/constants.d.ts +3 -0
- package/dist/types/reactions/reactions.d.ts +4 -0
- package/dist/types/reactions/reactions.type.d.ts +52 -0
- package/dist/types/reconnection-manager/index.d.ts +126 -0
- package/dist/types/recording-controller/enums.d.ts +7 -0
- package/dist/types/recording-controller/index.d.ts +193 -0
- package/dist/types/recording-controller/util.d.ts +13 -0
- package/dist/types/roap/index.d.ts +77 -0
- package/dist/types/roap/request.d.ts +36 -0
- package/dist/types/roap/turnDiscovery.d.ts +91 -0
- package/dist/types/statsAnalyzer/global.d.ts +36 -0
- package/dist/types/statsAnalyzer/index.d.ts +200 -0
- package/dist/types/statsAnalyzer/mqaUtil.d.ts +24 -0
- package/dist/types/transcription/index.d.ts +64 -0
- package/package.json +28 -21
- package/src/annotation/annotation.types.ts +52 -0
- package/src/annotation/constants.ts +36 -0
- package/src/annotation/index.ts +343 -0
- package/src/breakouts/README.md +220 -0
- package/src/breakouts/breakout.ts +180 -0
- package/src/breakouts/collection.ts +19 -0
- package/src/breakouts/edit-lock-error.ts +25 -0
- package/src/breakouts/events.ts +37 -0
- package/src/breakouts/index.ts +921 -0
- package/src/breakouts/request.ts +55 -0
- package/src/breakouts/utils.ts +57 -0
- package/src/common/errors/webex-errors.ts +6 -2
- package/src/common/logs/logger-proxy.ts +1 -1
- package/src/config.ts +5 -7
- package/src/constants.ts +165 -20
- package/src/controls-options-manager/constants.ts +5 -0
- package/src/controls-options-manager/enums.ts +18 -0
- package/src/controls-options-manager/index.ts +278 -0
- package/src/controls-options-manager/types.ts +59 -0
- package/src/controls-options-manager/util.ts +286 -0
- package/src/index.ts +34 -0
- package/src/interpretation/README.md +51 -0
- package/src/interpretation/collection.ts +19 -0
- package/src/interpretation/index.ts +182 -0
- package/src/interpretation/siLanguage.ts +18 -0
- package/src/locus-info/controlsUtils.ts +110 -0
- package/src/locus-info/index.ts +339 -21
- package/src/locus-info/mediaSharesUtils.ts +48 -0
- package/src/locus-info/parser.ts +2 -1
- package/src/locus-info/selfUtils.ts +86 -2
- package/src/media/index.ts +70 -142
- package/src/media/properties.ts +41 -104
- package/src/mediaQualityMetrics/config.ts +379 -377
- package/src/meeting/in-meeting-actions.ts +156 -0
- package/src/meeting/index.ts +1779 -1741
- package/src/meeting/locusMediaRequest.ts +309 -0
- package/src/meeting/muteState.ts +228 -132
- package/src/meeting/request.ts +100 -91
- package/src/meeting/request.type.ts +2 -0
- package/src/meeting/util.ts +422 -421
- package/src/meeting-info/meeting-info-v2.ts +134 -13
- package/src/meeting-info/utilv2.ts +13 -3
- package/src/meetings/collection.ts +20 -0
- package/src/meetings/index.ts +385 -83
- package/src/meetings/meetings.types.ts +12 -0
- package/src/meetings/request.ts +3 -1
- package/src/meetings/util.ts +103 -4
- package/src/member/index.ts +42 -0
- package/src/member/types.ts +24 -0
- package/src/member/util.ts +95 -1
- package/src/members/collection.ts +8 -0
- package/src/members/index.ts +108 -6
- package/src/members/request.ts +98 -17
- package/src/members/types.ts +28 -0
- package/src/members/util.ts +319 -240
- package/src/metrics/config.ts +49 -10
- package/src/metrics/constants.ts +2 -4
- package/src/metrics/index.ts +43 -27
- package/src/multistream/mediaRequestManager.ts +337 -63
- package/src/multistream/receiveSlot.ts +68 -26
- package/src/multistream/receiveSlotManager.ts +61 -38
- package/src/multistream/remoteMedia.ts +29 -3
- package/src/multistream/remoteMediaGroup.ts +61 -2
- package/src/multistream/remoteMediaManager.ts +260 -66
- package/src/networkQualityMonitor/index.ts +6 -6
- package/src/reachability/index.ts +75 -25
- package/src/reachability/request.ts +10 -5
- package/src/reactions/constants.ts +4 -0
- package/src/reactions/reactions.ts +4 -4
- package/src/reactions/reactions.type.ts +28 -3
- package/src/reconnection-manager/index.ts +53 -32
- package/src/recording-controller/enums.ts +8 -0
- package/src/recording-controller/index.ts +315 -0
- package/src/recording-controller/util.ts +58 -0
- package/src/roap/index.ts +21 -30
- package/src/roap/request.ts +51 -52
- package/src/roap/turnDiscovery.ts +51 -27
- package/src/statsAnalyzer/global.ts +1 -94
- package/src/statsAnalyzer/index.ts +380 -390
- package/src/statsAnalyzer/mqaUtil.ts +106 -99
- package/test/integration/spec/converged-space-meetings.js +233 -0
- package/test/integration/spec/journey.js +331 -254
- package/test/integration/spec/space-meeting.js +77 -4
- package/test/unit/spec/annotation/index.ts +436 -0
- package/test/unit/spec/breakouts/breakout.ts +233 -0
- package/test/unit/spec/breakouts/collection.ts +15 -0
- package/test/unit/spec/breakouts/edit-lock-error.ts +30 -0
- package/test/unit/spec/breakouts/events.ts +77 -0
- package/test/unit/spec/breakouts/index.ts +1790 -0
- package/test/unit/spec/breakouts/request.ts +104 -0
- package/test/unit/spec/breakouts/utils.js +72 -0
- package/test/unit/spec/controls-options-manager/index.js +287 -0
- package/test/unit/spec/controls-options-manager/util.js +518 -0
- package/test/unit/spec/fixture/locus.js +1 -0
- package/test/unit/spec/interpretation/collection.ts +15 -0
- package/test/unit/spec/interpretation/index.ts +329 -0
- package/test/unit/spec/interpretation/siLanguage.ts +26 -0
- package/test/unit/spec/locus-info/controlsUtils.js +323 -30
- package/test/unit/spec/locus-info/index.js +680 -4
- package/test/unit/spec/locus-info/mediaSharesUtils.ts +22 -0
- package/test/unit/spec/locus-info/selfConstant.js +48 -0
- package/test/unit/spec/locus-info/selfUtils.js +275 -0
- package/test/unit/spec/media/index.ts +118 -22
- package/test/unit/spec/media/properties.ts +9 -9
- package/test/unit/spec/meeting/in-meeting-actions.ts +76 -0
- package/test/unit/spec/meeting/index.js +2695 -1513
- package/test/unit/spec/meeting/locusMediaRequest.ts +436 -0
- package/test/unit/spec/meeting/muteState.js +370 -208
- package/test/unit/spec/meeting/request.js +354 -42
- package/test/unit/spec/meeting/utils.js +270 -156
- package/test/unit/spec/meeting-info/meetinginfov2.js +383 -5
- package/test/unit/spec/meeting-info/utilv2.js +21 -0
- package/test/unit/spec/meetings/collection.js +14 -0
- package/test/unit/spec/meetings/index.js +866 -120
- package/test/unit/spec/meetings/utils.js +206 -2
- package/test/unit/spec/member/index.js +31 -0
- package/test/unit/spec/member/util.js +408 -32
- package/test/unit/spec/members/index.js +320 -1
- package/test/unit/spec/members/request.js +206 -27
- package/test/unit/spec/members/utils.js +184 -0
- package/test/unit/spec/metrics/index.js +98 -0
- package/test/unit/spec/multistream/mediaRequestManager.ts +1012 -109
- package/test/unit/spec/multistream/receiveSlot.ts +77 -18
- package/test/unit/spec/multistream/receiveSlotManager.ts +69 -39
- package/test/unit/spec/multistream/remoteMedia.ts +32 -2
- package/test/unit/spec/multistream/remoteMediaGroup.ts +271 -5
- package/test/unit/spec/multistream/remoteMediaManager.ts +672 -65
- package/test/unit/spec/networkQualityMonitor/index.js +4 -4
- package/test/unit/spec/reachability/index.ts +176 -25
- package/test/unit/spec/reachability/request.js +66 -0
- package/test/unit/spec/reconnection-manager/index.js +46 -13
- package/test/unit/spec/recording-controller/index.js +231 -0
- package/test/unit/spec/recording-controller/util.js +102 -0
- package/test/unit/spec/roap/index.ts +21 -51
- package/test/unit/spec/roap/request.ts +187 -0
- package/test/unit/spec/roap/turnDiscovery.ts +73 -34
- package/test/unit/spec/stats-analyzer/index.js +94 -43
- package/test/utils/constants.js +9 -0
- package/test/utils/integrationTestUtils.js +46 -0
- package/test/utils/testUtils.js +0 -45
- package/test/utils/webex-config.js +4 -0
- package/test/utils/webex-test-users.js +7 -3
- package/tsconfig.json +6 -0
- package/dist/media/internal-media-core-wrapper.js +0 -18
- package/dist/media/internal-media-core-wrapper.js.map +0 -1
- package/dist/meeting/effectsState.js +0 -262
- package/dist/meeting/effectsState.js.map +0 -1
- package/dist/multistream/multistreamMedia.js +0 -106
- package/dist/multistream/multistreamMedia.js.map +0 -1
- package/src/index.js +0 -15
- package/src/media/internal-media-core-wrapper.ts +0 -9
- package/src/meeting/effectsState.ts +0 -211
- package/src/multistream/multistreamMedia.ts +0 -93
- package/test/unit/spec/meeting/effectsState.js +0 -281
package/dist/locus-info/index.js
CHANGED
|
@@ -15,6 +15,8 @@ var _inherits2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/
|
|
|
15
15
|
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/possibleConstructorReturn"));
|
|
16
16
|
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/getPrototypeOf"));
|
|
17
17
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/defineProperty"));
|
|
18
|
+
var _cloneDeep2 = _interopRequireDefault(require("lodash/cloneDeep"));
|
|
19
|
+
var _assignWith2 = _interopRequireDefault(require("lodash/assignWith"));
|
|
18
20
|
var _isEqual2 = _interopRequireDefault(require("lodash/isEqual"));
|
|
19
21
|
var _loggerProxy = _interopRequireDefault(require("../common/logs/logger-proxy"));
|
|
20
22
|
var _eventsScope = _interopRequireDefault(require("../common/events/events-scope"));
|
|
@@ -40,6 +42,13 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_R
|
|
|
40
42
|
var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
41
43
|
(0, _inherits2.default)(LocusInfo, _EventsScope);
|
|
42
44
|
var _super = _createSuper(LocusInfo);
|
|
45
|
+
/**
|
|
46
|
+
* Constructor
|
|
47
|
+
* @param {boolean} updateMeeting true if the meeting should be updated
|
|
48
|
+
* @param {object} webex
|
|
49
|
+
* @param {string} meetingId
|
|
50
|
+
* @returns {undefined}
|
|
51
|
+
*/
|
|
43
52
|
function LocusInfo(updateMeeting, webex, meetingId) {
|
|
44
53
|
var _this;
|
|
45
54
|
(0, _classCallCheck2.default)(this, LocusInfo);
|
|
@@ -68,9 +77,12 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
68
77
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "fullState", void 0);
|
|
69
78
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "host", void 0);
|
|
70
79
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "info", void 0);
|
|
80
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "roles", void 0);
|
|
71
81
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "mediaShares", void 0);
|
|
72
82
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "replace", void 0);
|
|
73
83
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "url", void 0);
|
|
84
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "services", void 0);
|
|
85
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "mainSessionLocusCache", void 0);
|
|
74
86
|
_this.parsedLocus = {
|
|
75
87
|
states: []
|
|
76
88
|
};
|
|
@@ -109,7 +121,7 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
109
121
|
case DESYNC:
|
|
110
122
|
meeting.meetingRequest.getFullLocus({
|
|
111
123
|
desync: true,
|
|
112
|
-
locusUrl: meeting.locusUrl
|
|
124
|
+
locusUrl: locus.url ? locus.url : meeting.locusUrl
|
|
113
125
|
}).then(function (res) {
|
|
114
126
|
meeting.locusInfo.onFullLocus(res.body);
|
|
115
127
|
// Notify parser to resume processing delta events
|
|
@@ -154,6 +166,7 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
154
166
|
}, {
|
|
155
167
|
key: "init",
|
|
156
168
|
value: function init() {
|
|
169
|
+
var _locus$links;
|
|
157
170
|
var locus = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
158
171
|
this.created = locus.created || null;
|
|
159
172
|
this.scheduledMeeting = locus.meeting || null;
|
|
@@ -184,13 +197,13 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
184
197
|
* @member LocusInfo
|
|
185
198
|
*/
|
|
186
199
|
this.deltaParticipants = [];
|
|
187
|
-
|
|
200
|
+
this.updateLocusCache(locus);
|
|
188
201
|
// above section only updates the locusInfo object
|
|
189
202
|
// The below section makes sure it updates the locusInfo as well as updates the meeting object
|
|
190
203
|
this.updateParticipants(locus.participants);
|
|
191
204
|
// For 1:1 space meeting the conversation Url does not exist in locus.conversation
|
|
192
205
|
this.updateConversationUrl(locus.conversationUrl, locus.info);
|
|
193
|
-
this.updateControls(locus.controls);
|
|
206
|
+
this.updateControls(locus.controls, locus.self);
|
|
194
207
|
this.updateLocusUrl(locus.url);
|
|
195
208
|
this.updateFullState(locus.fullState);
|
|
196
209
|
this.updateMeetingInfo(locus.info);
|
|
@@ -199,6 +212,7 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
199
212
|
this.updateSelf(locus.self, locus.participants);
|
|
200
213
|
this.updateHostInfo(locus.host);
|
|
201
214
|
this.updateMediaShares(locus.mediaShares);
|
|
215
|
+
this.updateServices((_locus$links = locus.links) === null || _locus$links === void 0 ? void 0 : _locus$links.services);
|
|
202
216
|
}
|
|
203
217
|
|
|
204
218
|
/**
|
|
@@ -209,6 +223,7 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
209
223
|
}, {
|
|
210
224
|
key: "initialSetup",
|
|
211
225
|
value: function initialSetup(locus) {
|
|
226
|
+
this.updateLocusCache(locus);
|
|
212
227
|
this.onFullLocus(locus);
|
|
213
228
|
|
|
214
229
|
// Change it to true after it receives it first locus object
|
|
@@ -226,6 +241,7 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
226
241
|
value: function parse(meeting, data) {
|
|
227
242
|
// eslint-disable-next-line @typescript-eslint/no-shadow
|
|
228
243
|
var eventType = data.eventType;
|
|
244
|
+
var locus = this.getTheLocusToUpdate(data.locus);
|
|
229
245
|
_loggerProxy.default.logger.info("Locus-info:index#parse --> received locus data: ".concat(eventType));
|
|
230
246
|
switch (eventType) {
|
|
231
247
|
case _constants.LOCUSEVENT.PARTICIPANT_JOIN:
|
|
@@ -242,15 +258,15 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
242
258
|
case _constants.LOCUSEVENT.PARTICIPANT_DECLINED:
|
|
243
259
|
case _constants.LOCUSEVENT.FLOOR_GRANTED:
|
|
244
260
|
case _constants.LOCUSEVENT.FLOOR_RELEASED:
|
|
245
|
-
this.onFullLocus(
|
|
261
|
+
this.onFullLocus(locus, eventType);
|
|
246
262
|
break;
|
|
247
263
|
case _constants.LOCUSEVENT.DIFFERENCE:
|
|
248
|
-
this.handleLocusDelta(
|
|
264
|
+
this.handleLocusDelta(locus, meeting);
|
|
249
265
|
break;
|
|
250
266
|
default:
|
|
251
267
|
// Why will there be a event with no eventType ????
|
|
252
268
|
// we may not need this, we can get full locus
|
|
253
|
-
this.handleLocusDelta(
|
|
269
|
+
this.handleLocusDelta(locus, meeting);
|
|
254
270
|
}
|
|
255
271
|
}
|
|
256
272
|
|
|
@@ -284,8 +300,9 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
284
300
|
this.updateParticipantDeltas(locus.participants);
|
|
285
301
|
this.scheduledMeeting = locus.meeting || null;
|
|
286
302
|
this.participants = locus.participants;
|
|
303
|
+
var isReplaceMembers = _controlsUtils.default.isNeedReplaceMembers(this.controls, locus.controls);
|
|
287
304
|
this.updateLocusInfo(locus);
|
|
288
|
-
this.updateParticipants(locus.participants);
|
|
305
|
+
this.updateParticipants(locus.participants, isReplaceMembers);
|
|
289
306
|
this.isMeetingActive();
|
|
290
307
|
this.handleOneOnOneEvent(eventType);
|
|
291
308
|
this.updateEmbeddedApps(locus.embeddedApps);
|
|
@@ -337,8 +354,9 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
337
354
|
}, {
|
|
338
355
|
key: "onDeltaLocus",
|
|
339
356
|
value: function onDeltaLocus(locus) {
|
|
357
|
+
var isReplaceMembers = _controlsUtils.default.isNeedReplaceMembers(this.controls, locus.controls);
|
|
340
358
|
this.updateLocusInfo(locus);
|
|
341
|
-
this.updateParticipants(locus.participants);
|
|
359
|
+
this.updateParticipants(locus.participants, isReplaceMembers);
|
|
342
360
|
this.isMeetingActive();
|
|
343
361
|
}
|
|
344
362
|
|
|
@@ -350,7 +368,14 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
350
368
|
}, {
|
|
351
369
|
key: "updateLocusInfo",
|
|
352
370
|
value: function updateLocusInfo(locus) {
|
|
353
|
-
|
|
371
|
+
var _locus$self, _locus$self2, _locus$links2;
|
|
372
|
+
if (((_locus$self = locus.self) === null || _locus$self === void 0 ? void 0 : _locus$self.reason) === 'MOVED' && ((_locus$self2 = locus.self) === null || _locus$self2 === void 0 ? void 0 : _locus$self2.state) === 'LEFT') {
|
|
373
|
+
// When moved to a breakout session locus sends a message for the previous locus
|
|
374
|
+
// indicating that we have been moved. It isn't helpful to continue parsing this
|
|
375
|
+
// as it gets interpreted as if we have left the call
|
|
376
|
+
return;
|
|
377
|
+
}
|
|
378
|
+
this.updateControls(locus.controls, locus.self);
|
|
354
379
|
this.updateConversationUrl(locus.conversationUrl, locus.info);
|
|
355
380
|
this.updateCreated(locus.created);
|
|
356
381
|
this.updateFullState(locus.fullState);
|
|
@@ -367,6 +392,7 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
367
392
|
this.updateMemberShip(locus.membership);
|
|
368
393
|
this.updateIdentifiers(locus.identities);
|
|
369
394
|
this.updateEmbeddedApps(locus.embeddedApps);
|
|
395
|
+
this.updateServices((_locus$links2 = locus.links) === null || _locus$links2 === void 0 ? void 0 : _locus$links2.services);
|
|
370
396
|
this.compareAndUpdate();
|
|
371
397
|
// update which required to compare different objects from locus
|
|
372
398
|
}
|
|
@@ -595,15 +621,15 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
595
621
|
}
|
|
596
622
|
|
|
597
623
|
/**
|
|
598
|
-
*
|
|
624
|
+
* update meeting's members
|
|
599
625
|
* @param {Object} participants new participants object
|
|
600
|
-
* @param {
|
|
626
|
+
* @param {Boolean} isReplace is replace the whole members
|
|
601
627
|
* @returns {Array} updatedParticipants
|
|
602
628
|
* @memberof LocusInfo
|
|
603
629
|
*/
|
|
604
630
|
}, {
|
|
605
631
|
key: "updateParticipants",
|
|
606
|
-
value: function updateParticipants(participants) {
|
|
632
|
+
value: function updateParticipants(participants, isReplace) {
|
|
607
633
|
var _this$parsedLocus$con;
|
|
608
634
|
this.emitScoped({
|
|
609
635
|
file: 'locus-info',
|
|
@@ -613,18 +639,20 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
613
639
|
recordingId: this.parsedLocus.controls && ((_this$parsedLocus$con = this.parsedLocus.controls.record) === null || _this$parsedLocus$con === void 0 ? void 0 : _this$parsedLocus$con.modifiedBy),
|
|
614
640
|
selfIdentity: this.parsedLocus.self && this.parsedLocus.self.selfIdentity,
|
|
615
641
|
selfId: this.parsedLocus.self && this.parsedLocus.self.selfId,
|
|
616
|
-
hostId: this.parsedLocus.host && this.parsedLocus.host.hostId
|
|
642
|
+
hostId: this.parsedLocus.host && this.parsedLocus.host.hostId,
|
|
643
|
+
isReplace: isReplace
|
|
617
644
|
});
|
|
618
645
|
}
|
|
619
646
|
|
|
620
647
|
/**
|
|
621
648
|
* @param {Object} controls
|
|
649
|
+
* @param {Object} self
|
|
622
650
|
* @returns {undefined}
|
|
623
651
|
* @memberof LocusInfo
|
|
624
652
|
*/
|
|
625
653
|
}, {
|
|
626
654
|
key: "updateControls",
|
|
627
|
-
value: function updateControls(controls) {
|
|
655
|
+
value: function updateControls(controls, self) {
|
|
628
656
|
if (controls && !(0, _isEqual2.default)(this.controls, controls)) {
|
|
629
657
|
this.parsedLocus.controls = _controlsUtils.default.parse(controls);
|
|
630
658
|
var _ControlsUtils$getCon = _controlsUtils.default.getControls(this.controls, controls),
|
|
@@ -634,7 +662,74 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
634
662
|
hasMeetingContainerChanged = _ControlsUtils$getCon2.hasMeetingContainerChanged,
|
|
635
663
|
hasTranscribeChanged = _ControlsUtils$getCon2.hasTranscribeChanged,
|
|
636
664
|
hasEntryExitToneChanged = _ControlsUtils$getCon2.hasEntryExitToneChanged,
|
|
665
|
+
hasBreakoutChanged = _ControlsUtils$getCon2.hasBreakoutChanged,
|
|
666
|
+
hasVideoEnabledChanged = _ControlsUtils$getCon2.hasVideoEnabledChanged,
|
|
667
|
+
hasMuteOnEntryChanged = _ControlsUtils$getCon2.hasMuteOnEntryChanged,
|
|
668
|
+
hasShareControlChanged = _ControlsUtils$getCon2.hasShareControlChanged,
|
|
669
|
+
hasDisallowUnmuteChanged = _ControlsUtils$getCon2.hasDisallowUnmuteChanged,
|
|
670
|
+
hasReactionsChanged = _ControlsUtils$getCon2.hasReactionsChanged,
|
|
671
|
+
hasReactionDisplayNamesChanged = _ControlsUtils$getCon2.hasReactionDisplayNamesChanged,
|
|
672
|
+
hasViewTheParticipantListChanged = _ControlsUtils$getCon2.hasViewTheParticipantListChanged,
|
|
673
|
+
hasRaiseHandChanged = _ControlsUtils$getCon2.hasRaiseHandChanged,
|
|
674
|
+
hasVideoChanged = _ControlsUtils$getCon2.hasVideoChanged,
|
|
675
|
+
hasInterpretationChanged = _ControlsUtils$getCon2.hasInterpretationChanged,
|
|
637
676
|
current = _ControlsUtils$getCon.current;
|
|
677
|
+
if (hasMuteOnEntryChanged) {
|
|
678
|
+
this.emitScoped({
|
|
679
|
+
file: 'locus-info',
|
|
680
|
+
function: 'updateControls'
|
|
681
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_MUTE_ON_ENTRY_CHANGED, {
|
|
682
|
+
state: current.muteOnEntry
|
|
683
|
+
});
|
|
684
|
+
}
|
|
685
|
+
if (hasShareControlChanged) {
|
|
686
|
+
this.emitScoped({
|
|
687
|
+
file: 'locus-info',
|
|
688
|
+
function: 'updateControls'
|
|
689
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_SHARE_CONTROL_CHANGED, {
|
|
690
|
+
state: current.shareControl
|
|
691
|
+
});
|
|
692
|
+
}
|
|
693
|
+
if (hasDisallowUnmuteChanged) {
|
|
694
|
+
this.emitScoped({
|
|
695
|
+
file: 'locus-info',
|
|
696
|
+
function: 'updateControls'
|
|
697
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_DISALLOW_UNMUTE_CHANGED, {
|
|
698
|
+
state: current.disallowUnmute
|
|
699
|
+
});
|
|
700
|
+
}
|
|
701
|
+
if (hasReactionsChanged || hasReactionDisplayNamesChanged) {
|
|
702
|
+
this.emitScoped({
|
|
703
|
+
file: 'locus-info',
|
|
704
|
+
function: 'updateControls'
|
|
705
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_REACTIONS_CHANGED, {
|
|
706
|
+
state: current.reactions
|
|
707
|
+
});
|
|
708
|
+
}
|
|
709
|
+
if (hasViewTheParticipantListChanged) {
|
|
710
|
+
this.emitScoped({
|
|
711
|
+
file: 'locus-info',
|
|
712
|
+
function: 'updateControls'
|
|
713
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_VIEW_THE_PARTICIPANTS_LIST_CHANGED, {
|
|
714
|
+
state: current.viewTheParticipantList
|
|
715
|
+
});
|
|
716
|
+
}
|
|
717
|
+
if (hasRaiseHandChanged) {
|
|
718
|
+
this.emitScoped({
|
|
719
|
+
file: 'locus-info',
|
|
720
|
+
function: 'updateControls'
|
|
721
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_RAISE_HAND_CHANGED, {
|
|
722
|
+
state: current.raiseHand
|
|
723
|
+
});
|
|
724
|
+
}
|
|
725
|
+
if (hasVideoChanged) {
|
|
726
|
+
this.emitScoped({
|
|
727
|
+
file: 'locus-info',
|
|
728
|
+
function: 'updateControls'
|
|
729
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_VIDEO_CHANGED, {
|
|
730
|
+
state: current.video
|
|
731
|
+
});
|
|
732
|
+
}
|
|
638
733
|
if (hasRecordingChanged || hasRecordingPausedChanged) {
|
|
639
734
|
var state = null;
|
|
640
735
|
if (hasRecordingPausedChanged) {
|
|
@@ -677,16 +772,51 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
677
772
|
caption: caption
|
|
678
773
|
});
|
|
679
774
|
}
|
|
775
|
+
if (hasBreakoutChanged) {
|
|
776
|
+
var breakout = current.breakout;
|
|
777
|
+
breakout.breakoutMoveId = _selfUtils.default.getReplacedBreakoutMoveId(self, this.webex.internal.device.url);
|
|
778
|
+
this.emitScoped({
|
|
779
|
+
file: 'locus-info',
|
|
780
|
+
function: 'updateControls'
|
|
781
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_BREAKOUT_UPDATED, {
|
|
782
|
+
breakout: breakout
|
|
783
|
+
});
|
|
784
|
+
}
|
|
785
|
+
if (hasInterpretationChanged) {
|
|
786
|
+
var interpretation = current.interpretation;
|
|
787
|
+
this.emitScoped({
|
|
788
|
+
file: 'locus-info',
|
|
789
|
+
function: 'updateControls'
|
|
790
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_MEETING_INTERPRETATION_UPDATED, {
|
|
791
|
+
interpretation: interpretation
|
|
792
|
+
});
|
|
793
|
+
}
|
|
680
794
|
if (hasEntryExitToneChanged) {
|
|
681
795
|
var entryExitTone = current.entryExitTone;
|
|
796
|
+
this.updateMeeting({
|
|
797
|
+
entryExitTone: entryExitTone
|
|
798
|
+
});
|
|
682
799
|
this.emitScoped({
|
|
683
800
|
file: 'locus-info',
|
|
684
801
|
function: 'updateControls'
|
|
685
802
|
}, _constants.LOCUSINFO.EVENTS.CONTROLS_ENTRY_EXIT_TONE_UPDATED, {
|
|
686
803
|
entryExitTone: entryExitTone
|
|
687
804
|
});
|
|
805
|
+
}
|
|
806
|
+
|
|
807
|
+
// videoEnabled is handled differently than other controls,
|
|
808
|
+
// to fit with audio mute status logic
|
|
809
|
+
if (hasVideoEnabledChanged) {
|
|
810
|
+
var videoEnabled = current.videoEnabled;
|
|
688
811
|
this.updateMeeting({
|
|
689
|
-
|
|
812
|
+
unmuteVideoAllowed: videoEnabled
|
|
813
|
+
});
|
|
814
|
+
this.emitScoped({
|
|
815
|
+
file: 'locus-info',
|
|
816
|
+
function: 'updateControls'
|
|
817
|
+
}, _constants.LOCUSINFO.EVENTS.SELF_REMOTE_VIDEO_MUTE_STATUS_UPDATED, {
|
|
818
|
+
// muted: not part of locus.controls
|
|
819
|
+
unmuteAllowed: videoEnabled
|
|
690
820
|
});
|
|
691
821
|
}
|
|
692
822
|
this.controls = controls;
|
|
@@ -728,6 +858,25 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
728
858
|
}
|
|
729
859
|
}
|
|
730
860
|
|
|
861
|
+
/**
|
|
862
|
+
* @param {Object} services
|
|
863
|
+
* @returns {undefined}
|
|
864
|
+
* @memberof LocusInfo
|
|
865
|
+
*/
|
|
866
|
+
}, {
|
|
867
|
+
key: "updateServices",
|
|
868
|
+
value: function updateServices(services) {
|
|
869
|
+
if (services && !(0, _isEqual2.default)(this.services, services)) {
|
|
870
|
+
this.services = services;
|
|
871
|
+
this.emitScoped({
|
|
872
|
+
file: 'locus-info',
|
|
873
|
+
function: 'updateServices'
|
|
874
|
+
}, _constants.LOCUSINFO.EVENTS.LINKS_SERVICES, {
|
|
875
|
+
services: services
|
|
876
|
+
});
|
|
877
|
+
}
|
|
878
|
+
}
|
|
879
|
+
|
|
731
880
|
/**
|
|
732
881
|
* @param {Object} fullState
|
|
733
882
|
* @returns {undefined}
|
|
@@ -800,9 +949,9 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
800
949
|
}, {
|
|
801
950
|
key: "updateMeetingInfo",
|
|
802
951
|
value: function updateMeetingInfo(info, self) {
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
952
|
+
var _this$parsedLocus$sel;
|
|
953
|
+
var roles = self ? _selfUtils.default.getRoles(self) : ((_this$parsedLocus$sel = this.parsedLocus.self) === null || _this$parsedLocus$sel === void 0 ? void 0 : _this$parsedLocus$sel.roles) || [];
|
|
954
|
+
if (info && !(0, _isEqual2.default)(this.info, info) || roles.length && !(0, _isEqual2.default)(this.roles, roles) && info) {
|
|
806
955
|
var isJoined = _selfUtils.default.isJoined(self || this.parsedLocus.self);
|
|
807
956
|
var parsedInfo = _infoUtils.default.getInfos(this.parsedLocus.info, info, roles, isJoined);
|
|
808
957
|
this.emitScoped({
|
|
@@ -829,6 +978,7 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
829
978
|
// Parses the info and adds necessary values
|
|
830
979
|
this.updateMeeting(parsedInfo.current);
|
|
831
980
|
}
|
|
981
|
+
this.roles = roles;
|
|
832
982
|
}
|
|
833
983
|
|
|
834
984
|
/**
|
|
@@ -867,6 +1017,8 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
867
1017
|
if (mediaShares && !(0, _isEqual2.default)(this.mediaShares, mediaShares)) {
|
|
868
1018
|
var parsedMediaShares = _mediaSharesUtils.default.getMediaShares(this.mediaShares, mediaShares);
|
|
869
1019
|
this.updateMeeting(parsedMediaShares.current);
|
|
1020
|
+
this.parsedLocus.mediaShares = parsedMediaShares.current;
|
|
1021
|
+
this.mediaShares = mediaShares;
|
|
870
1022
|
this.emitScoped({
|
|
871
1023
|
file: 'locus-info',
|
|
872
1024
|
function: 'updateMediaShares'
|
|
@@ -874,8 +1026,6 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
874
1026
|
current: parsedMediaShares.current,
|
|
875
1027
|
previous: parsedMediaShares.previous
|
|
876
1028
|
});
|
|
877
|
-
this.parsedLocus.mediaShares = parsedMediaShares.current;
|
|
878
|
-
this.mediaShares = mediaShares;
|
|
879
1029
|
}
|
|
880
1030
|
}
|
|
881
1031
|
|
|
@@ -946,6 +1096,23 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
946
1096
|
layout: parsedSelves.current.layout
|
|
947
1097
|
});
|
|
948
1098
|
}
|
|
1099
|
+
if (parsedSelves.updates.breakoutsChanged) {
|
|
1100
|
+
this.emitScoped({
|
|
1101
|
+
file: 'locus-info',
|
|
1102
|
+
function: 'updateSelf'
|
|
1103
|
+
}, _constants.LOCUSINFO.EVENTS.SELF_MEETING_BREAKOUTS_CHANGED, {
|
|
1104
|
+
breakoutSessions: parsedSelves.current.breakoutSessions
|
|
1105
|
+
});
|
|
1106
|
+
}
|
|
1107
|
+
if (parsedSelves.updates.interpretationChanged) {
|
|
1108
|
+
this.emitScoped({
|
|
1109
|
+
file: 'locus-info',
|
|
1110
|
+
function: 'updateSelf'
|
|
1111
|
+
}, _constants.LOCUSINFO.EVENTS.SELF_MEETING_INTERPRETATION_CHANGED, {
|
|
1112
|
+
interpretation: parsedSelves.current.interpretation,
|
|
1113
|
+
selfParticipantId: parsedSelves.current.selfId
|
|
1114
|
+
});
|
|
1115
|
+
}
|
|
949
1116
|
if (parsedSelves.updates.isMediaInactiveOrReleased) {
|
|
950
1117
|
this.emitScoped({
|
|
951
1118
|
file: 'locus-info',
|
|
@@ -960,6 +1127,26 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
960
1127
|
function: 'updateSelf'
|
|
961
1128
|
}, _constants.LOCUSINFO.EVENTS.SELF_MODERATOR_CHANGED, self);
|
|
962
1129
|
}
|
|
1130
|
+
if (parsedSelves.updates.isRolesChanged) {
|
|
1131
|
+
var _parsedSelves$previou, _parsedSelves$current;
|
|
1132
|
+
this.emitScoped({
|
|
1133
|
+
file: 'locus-info',
|
|
1134
|
+
function: 'updateSelf'
|
|
1135
|
+
}, _constants.LOCUSINFO.EVENTS.SELF_ROLES_CHANGED, {
|
|
1136
|
+
oldRoles: (_parsedSelves$previou = parsedSelves.previous) === null || _parsedSelves$previou === void 0 ? void 0 : _parsedSelves$previou.roles,
|
|
1137
|
+
newRoles: (_parsedSelves$current = parsedSelves.current) === null || _parsedSelves$current === void 0 ? void 0 : _parsedSelves$current.roles
|
|
1138
|
+
});
|
|
1139
|
+
}
|
|
1140
|
+
if (parsedSelves.updates.isVideoMutedByOthersChanged) {
|
|
1141
|
+
this.emitScoped({
|
|
1142
|
+
file: 'locus-info',
|
|
1143
|
+
function: 'updateSelf'
|
|
1144
|
+
}, _constants.LOCUSINFO.EVENTS.SELF_REMOTE_VIDEO_MUTE_STATUS_UPDATED, {
|
|
1145
|
+
muted: parsedSelves.current.remoteVideoMuted
|
|
1146
|
+
// unmuteAllowed: not part of .self
|
|
1147
|
+
});
|
|
1148
|
+
}
|
|
1149
|
+
|
|
963
1150
|
if (parsedSelves.updates.localAudioUnmuteRequiredByServer) {
|
|
964
1151
|
this.emitScoped({
|
|
965
1152
|
file: 'locus-info',
|
|
@@ -1005,14 +1192,14 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
1005
1192
|
_constants.LOCUSINFO.EVENTS.MEDIA_INACTIVITY, _selfUtils.default.getMediaStatus(self.mediaSessions));
|
|
1006
1193
|
}
|
|
1007
1194
|
if (parsedSelves.updates.audioStateChange || parsedSelves.updates.videoStateChange || parsedSelves.updates.shareStateChange) {
|
|
1008
|
-
var _parsedSelves$
|
|
1195
|
+
var _parsedSelves$current2, _parsedSelves$current3, _parsedSelves$current4;
|
|
1009
1196
|
this.emitScoped({
|
|
1010
1197
|
file: 'locus-info',
|
|
1011
1198
|
function: 'updateSelf'
|
|
1012
1199
|
}, _constants.LOCUSINFO.EVENTS.MEDIA_STATUS_CHANGE, {
|
|
1013
|
-
audioStatus: (_parsedSelves$
|
|
1014
|
-
videoStatus: (_parsedSelves$
|
|
1015
|
-
shareStatus: (_parsedSelves$
|
|
1200
|
+
audioStatus: (_parsedSelves$current2 = parsedSelves.current.currentMediaStatus) === null || _parsedSelves$current2 === void 0 ? void 0 : _parsedSelves$current2.audio,
|
|
1201
|
+
videoStatus: (_parsedSelves$current3 = parsedSelves.current.currentMediaStatus) === null || _parsedSelves$current3 === void 0 ? void 0 : _parsedSelves$current3.video,
|
|
1202
|
+
shareStatus: (_parsedSelves$current4 = parsedSelves.current.currentMediaStatus) === null || _parsedSelves$current4 === void 0 ? void 0 : _parsedSelves$current4.share
|
|
1016
1203
|
});
|
|
1017
1204
|
}
|
|
1018
1205
|
if (parsedSelves.updates.isUserObserving) {
|
|
@@ -1137,6 +1324,112 @@ var LocusInfo = /*#__PURE__*/function (_EventsScope) {
|
|
|
1137
1324
|
this.identities = identities;
|
|
1138
1325
|
}
|
|
1139
1326
|
}
|
|
1327
|
+
|
|
1328
|
+
/**
|
|
1329
|
+
* check the locus is main session's one or not, if is main session's, update main session cache
|
|
1330
|
+
* @param {Object} locus
|
|
1331
|
+
* @returns {undefined}
|
|
1332
|
+
* @memberof LocusInfo
|
|
1333
|
+
*/
|
|
1334
|
+
}, {
|
|
1335
|
+
key: "updateLocusCache",
|
|
1336
|
+
value: function updateLocusCache(locus) {
|
|
1337
|
+
var isMainSessionDTO = _controlsUtils.default.isMainSessionDTO(locus);
|
|
1338
|
+
if (isMainSessionDTO) {
|
|
1339
|
+
this.updateMainSessionLocusCache(locus);
|
|
1340
|
+
}
|
|
1341
|
+
}
|
|
1342
|
+
|
|
1343
|
+
/**
|
|
1344
|
+
* if return from breakout to main session, need to use cached main session DTO since locus won't send the full locus (participants)
|
|
1345
|
+
* if join breakout from main session, need to query main locus url (if response with 403 means no privilege, need to clear the cache)
|
|
1346
|
+
* @param {Object} newLocus
|
|
1347
|
+
* @returns {Object}
|
|
1348
|
+
* @memberof LocusInfo
|
|
1349
|
+
*/
|
|
1350
|
+
}, {
|
|
1351
|
+
key: "getTheLocusToUpdate",
|
|
1352
|
+
value: function getTheLocusToUpdate(newLocus) {
|
|
1353
|
+
var switchStatus = _controlsUtils.default.getSessionSwitchStatus(this.controls, newLocus === null || newLocus === void 0 ? void 0 : newLocus.controls);
|
|
1354
|
+
if (switchStatus.isReturnToMain && this.mainSessionLocusCache) {
|
|
1355
|
+
return (0, _cloneDeep2.default)(this.mainSessionLocusCache);
|
|
1356
|
+
}
|
|
1357
|
+
if (switchStatus.isJoinToBreakout) {
|
|
1358
|
+
this.emitScoped({
|
|
1359
|
+
file: 'locus-info',
|
|
1360
|
+
function: 'updateControls'
|
|
1361
|
+
}, _constants.LOCUSINFO.EVENTS.CONTROLS_JOIN_BREAKOUT_FROM_MAIN, {
|
|
1362
|
+
mainLocusUrl: this.url
|
|
1363
|
+
});
|
|
1364
|
+
}
|
|
1365
|
+
return newLocus;
|
|
1366
|
+
}
|
|
1367
|
+
|
|
1368
|
+
/**
|
|
1369
|
+
* merge participants by participant id
|
|
1370
|
+
* @param {Array} participants
|
|
1371
|
+
* @param {Array} sourceParticipants
|
|
1372
|
+
* @returns {Array} merged participants
|
|
1373
|
+
* @memberof LocusInfo
|
|
1374
|
+
*/
|
|
1375
|
+
// eslint-disable-next-line class-methods-use-this
|
|
1376
|
+
}, {
|
|
1377
|
+
key: "mergeParticipants",
|
|
1378
|
+
value: function mergeParticipants(participants, sourceParticipants) {
|
|
1379
|
+
if (!sourceParticipants || !sourceParticipants.length) return participants;
|
|
1380
|
+
if (!participants || !participants.length) {
|
|
1381
|
+
return sourceParticipants;
|
|
1382
|
+
}
|
|
1383
|
+
sourceParticipants.forEach(function (participant) {
|
|
1384
|
+
var existIndex = participants.findIndex(function (p) {
|
|
1385
|
+
return p.id === participant.id;
|
|
1386
|
+
});
|
|
1387
|
+
if (existIndex > -1) {
|
|
1388
|
+
participants.splice(existIndex, 1, participant);
|
|
1389
|
+
} else {
|
|
1390
|
+
participants.push(participant);
|
|
1391
|
+
}
|
|
1392
|
+
});
|
|
1393
|
+
return participants;
|
|
1394
|
+
}
|
|
1395
|
+
|
|
1396
|
+
/**
|
|
1397
|
+
* need cache main sessions' participants since locus will not send the full list when cohost/host leave breakout
|
|
1398
|
+
* @param {Object} mainLocus
|
|
1399
|
+
* @returns {undefined}
|
|
1400
|
+
* @memberof LocusInfo
|
|
1401
|
+
*/
|
|
1402
|
+
}, {
|
|
1403
|
+
key: "updateMainSessionLocusCache",
|
|
1404
|
+
value: function updateMainSessionLocusCache(mainLocus) {
|
|
1405
|
+
var _this5 = this;
|
|
1406
|
+
if (!mainLocus) {
|
|
1407
|
+
return;
|
|
1408
|
+
}
|
|
1409
|
+
var locusClone = (0, _cloneDeep2.default)(mainLocus);
|
|
1410
|
+
if (this.mainSessionLocusCache) {
|
|
1411
|
+
// shallow merge and do special merge for participants
|
|
1412
|
+
(0, _assignWith2.default)(this.mainSessionLocusCache, locusClone, function (objValue, srcValue, key) {
|
|
1413
|
+
if (key === 'participants') {
|
|
1414
|
+
return _this5.mergeParticipants(objValue, srcValue);
|
|
1415
|
+
}
|
|
1416
|
+
return srcValue || objValue;
|
|
1417
|
+
});
|
|
1418
|
+
} else {
|
|
1419
|
+
this.mainSessionLocusCache = locusClone;
|
|
1420
|
+
}
|
|
1421
|
+
}
|
|
1422
|
+
|
|
1423
|
+
/**
|
|
1424
|
+
* clear main session cache
|
|
1425
|
+
* @returns {undefined}
|
|
1426
|
+
* @memberof LocusInfo
|
|
1427
|
+
*/
|
|
1428
|
+
}, {
|
|
1429
|
+
key: "clearMainSessionLocusCache",
|
|
1430
|
+
value: function clearMainSessionLocusCache() {
|
|
1431
|
+
this.mainSessionLocusCache = null;
|
|
1432
|
+
}
|
|
1140
1433
|
}]);
|
|
1141
1434
|
return LocusInfo;
|
|
1142
1435
|
}(_eventsScope.default);
|