@webex/plugin-meetings 3.0.0-beta.3 → 3.0.0-beta.300
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 +46 -8
- package/UPGRADING.md +9 -9
- package/browsers.js +19 -24
- 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 +342 -0
- package/dist/annotation/index.js.map +1 -0
- package/dist/breakouts/breakout.js +216 -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 +45 -0
- package/dist/breakouts/events.js.map +1 -0
- package/dist/breakouts/index.js +1048 -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/browser-detection.js +1 -20
- package/dist/common/browser-detection.js.map +1 -1
- package/dist/common/collection.js +5 -20
- package/dist/common/collection.js.map +1 -1
- package/dist/common/config.js +0 -7
- package/dist/common/config.js.map +1 -1
- package/dist/common/errors/captcha-error.js +10 -24
- package/dist/common/errors/captcha-error.js.map +1 -1
- package/dist/common/errors/intent-to-join.js +11 -24
- package/dist/common/errors/intent-to-join.js.map +1 -1
- package/dist/common/errors/join-meeting.js +12 -25
- package/dist/common/errors/join-meeting.js.map +1 -1
- package/dist/common/errors/media.js +10 -24
- package/dist/common/errors/media.js.map +1 -1
- package/dist/common/errors/no-meeting-info.js +51 -0
- package/dist/common/errors/no-meeting-info.js.map +1 -0
- package/dist/common/errors/parameter.js +5 -33
- package/dist/common/errors/parameter.js.map +1 -1
- package/dist/common/errors/password-error.js +10 -24
- package/dist/common/errors/password-error.js.map +1 -1
- package/dist/common/errors/permission.js +9 -23
- package/dist/common/errors/permission.js.map +1 -1
- package/dist/common/errors/reclaim-host-role-errors.js +158 -0
- package/dist/common/errors/reclaim-host-role-errors.js.map +1 -0
- package/dist/common/errors/reconnection-in-progress.js +0 -17
- package/dist/common/errors/reconnection-in-progress.js.map +1 -1
- package/dist/common/errors/reconnection.js +10 -24
- package/dist/common/errors/reconnection.js.map +1 -1
- package/dist/common/errors/stats.js +10 -24
- package/dist/common/errors/stats.js.map +1 -1
- package/dist/common/errors/webex-errors.js +54 -48
- package/dist/common/errors/webex-errors.js.map +1 -1
- package/dist/common/errors/webex-meetings-error.js +5 -25
- package/dist/common/errors/webex-meetings-error.js.map +1 -1
- package/dist/common/events/events-scope.js +0 -22
- package/dist/common/events/events-scope.js.map +1 -1
- package/dist/common/events/events.js +0 -23
- package/dist/common/events/events.js.map +1 -1
- package/dist/common/events/trigger-proxy.js +0 -12
- package/dist/common/events/trigger-proxy.js.map +1 -1
- package/dist/common/events/util.js +0 -15
- package/dist/common/events/util.js.map +1 -1
- package/dist/common/logs/logger-config.js +0 -4
- package/dist/common/logs/logger-config.js.map +1 -1
- package/dist/common/logs/logger-proxy.js +1 -8
- package/dist/common/logs/logger-proxy.js.map +1 -1
- package/dist/common/logs/request.js +41 -60
- package/dist/common/logs/request.js.map +1 -1
- package/dist/common/queue.js +28 -23
- package/dist/common/queue.js.map +1 -1
- package/dist/config.js +9 -15
- package/dist/config.js.map +1 -1
- package/dist/constants.js +315 -68
- 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 +319 -0
- package/dist/controls-options-manager/util.js.map +1 -0
- package/dist/index.js +114 -17
- 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 +366 -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 +101 -29
- package/dist/locus-info/controlsUtils.js.map +1 -1
- package/dist/locus-info/embeddedAppsUtils.js +3 -26
- package/dist/locus-info/embeddedAppsUtils.js.map +1 -1
- package/dist/locus-info/fullState.js +0 -15
- package/dist/locus-info/fullState.js.map +1 -1
- package/dist/locus-info/hostUtils.js +4 -12
- package/dist/locus-info/hostUtils.js.map +1 -1
- package/dist/locus-info/index.js +561 -246
- package/dist/locus-info/index.js.map +1 -1
- package/dist/locus-info/infoUtils.js +10 -38
- package/dist/locus-info/infoUtils.js.map +1 -1
- package/dist/locus-info/mediaSharesUtils.js +68 -38
- package/dist/locus-info/mediaSharesUtils.js.map +1 -1
- package/dist/locus-info/parser.js +314 -163
- package/dist/locus-info/parser.js.map +1 -1
- package/dist/locus-info/selfUtils.js +110 -92
- package/dist/locus-info/selfUtils.js.map +1 -1
- package/dist/media/index.js +103 -231
- package/dist/media/index.js.map +1 -1
- package/dist/media/properties.js +137 -222
- package/dist/media/properties.js.map +1 -1
- package/dist/media/util.js +2 -9
- package/dist/media/util.js.map +1 -1
- package/dist/mediaQualityMetrics/config.js +505 -495
- package/dist/mediaQualityMetrics/config.js.map +1 -1
- package/dist/meeting/in-meeting-actions.js +93 -14
- package/dist/meeting/in-meeting-actions.js.map +1 -1
- package/dist/meeting/index.js +4624 -3740
- package/dist/meeting/index.js.map +1 -1
- package/dist/meeting/locusMediaRequest.js +292 -0
- package/dist/meeting/locusMediaRequest.js.map +1 -0
- package/dist/meeting/muteState.js +249 -184
- package/dist/meeting/muteState.js.map +1 -1
- package/dist/meeting/request.js +400 -346
- package/dist/meeting/request.js.map +1 -1
- package/dist/meeting/request.type.js +7 -0
- package/dist/meeting/request.type.js.map +1 -0
- package/dist/meeting/state.js +21 -31
- package/dist/meeting/state.js.map +1 -1
- package/dist/meeting/util.js +598 -586
- package/dist/meeting/util.js.map +1 -1
- package/dist/meeting-info/collection.js +6 -25
- package/dist/meeting-info/collection.js.map +1 -1
- package/dist/meeting-info/index.js +87 -39
- package/dist/meeting-info/index.js.map +1 -1
- package/dist/meeting-info/meeting-info-v2.js +349 -283
- package/dist/meeting-info/meeting-info-v2.js.map +1 -1
- package/dist/meeting-info/request.js +3 -15
- package/dist/meeting-info/request.js.map +1 -1
- package/dist/meeting-info/util.js +98 -183
- package/dist/meeting-info/util.js.map +1 -1
- package/dist/meeting-info/utilv2.js +143 -234
- package/dist/meeting-info/utilv2.js.map +1 -1
- package/dist/meetings/collection.js +26 -19
- package/dist/meetings/collection.js.map +1 -1
- package/dist/meetings/index.js +813 -596
- 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 +26 -41
- package/dist/meetings/request.js.map +1 -1
- package/dist/meetings/util.js +183 -156
- package/dist/meetings/util.js.map +1 -1
- package/dist/member/index.js +135 -85
- package/dist/member/index.js.map +1 -1
- package/dist/member/types.js +25 -0
- package/dist/member/types.js.map +1 -0
- package/dist/member/util.js +158 -88
- package/dist/member/util.js.map +1 -1
- package/dist/members/collection.js +13 -12
- package/dist/members/collection.js.map +1 -1
- package/dist/members/index.js +194 -204
- package/dist/members/index.js.map +1 -1
- package/dist/members/request.js +113 -68
- 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 +324 -259
- package/dist/members/util.js.map +1 -1
- package/dist/metrics/constants.js +14 -7
- package/dist/metrics/constants.js.map +1 -1
- package/dist/metrics/index.js +11 -558
- package/dist/metrics/index.js.map +1 -1
- package/dist/multistream/mediaRequestManager.js +263 -50
- package/dist/multistream/mediaRequestManager.js.map +1 -1
- package/dist/multistream/receiveSlot.js +58 -65
- package/dist/multistream/receiveSlot.js.map +1 -1
- package/dist/multistream/receiveSlotManager.js +76 -95
- package/dist/multistream/receiveSlotManager.js.map +1 -1
- package/dist/multistream/remoteMedia.js +62 -76
- package/dist/multistream/remoteMedia.js.map +1 -1
- package/dist/multistream/remoteMediaGroup.js +66 -43
- package/dist/multistream/remoteMediaGroup.js.map +1 -1
- package/dist/multistream/remoteMediaManager.js +536 -439
- package/dist/multistream/remoteMediaManager.js.map +1 -1
- package/dist/multistream/sendSlotManager.js +233 -0
- package/dist/multistream/sendSlotManager.js.map +1 -0
- package/dist/networkQualityMonitor/index.js +40 -59
- package/dist/networkQualityMonitor/index.js.map +1 -1
- package/dist/personal-meeting-room/index.js +21 -45
- package/dist/personal-meeting-room/index.js.map +1 -1
- package/dist/personal-meeting-room/request.js +1 -31
- package/dist/personal-meeting-room/request.js.map +1 -1
- package/dist/personal-meeting-room/util.js +0 -13
- package/dist/personal-meeting-room/util.js.map +1 -1
- package/dist/reachability/index.js +322 -200
- package/dist/reachability/index.js.map +1 -1
- package/dist/reachability/request.js +20 -26
- 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 +109 -0
- package/dist/reactions/reactions.js.map +1 -0
- package/dist/reactions/reactions.type.js +36 -0
- package/dist/reactions/reactions.type.js.map +1 -0
- package/dist/reconnection-manager/index.js +388 -476
- 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 +362 -0
- package/dist/recording-controller/index.js.map +1 -0
- package/dist/recording-controller/util.js +64 -0
- package/dist/recording-controller/util.js.map +1 -0
- package/dist/roap/index.js +99 -94
- package/dist/roap/index.js.map +1 -1
- package/dist/roap/request.js +131 -135
- package/dist/roap/request.js.map +1 -1
- package/dist/roap/turnDiscovery.js +151 -101
- package/dist/roap/turnDiscovery.js.map +1 -1
- package/dist/rtcMetrics/constants.js +12 -0
- package/dist/rtcMetrics/constants.js.map +1 -0
- package/dist/rtcMetrics/index.js +117 -0
- package/dist/rtcMetrics/index.js.map +1 -0
- package/dist/statsAnalyzer/global.js +1 -95
- package/dist/statsAnalyzer/global.js.map +1 -1
- package/dist/statsAnalyzer/index.js +416 -497
- package/dist/statsAnalyzer/index.js.map +1 -1
- package/dist/statsAnalyzer/mqaUtil.js +145 -88
- package/dist/statsAnalyzer/mqaUtil.js.map +1 -1
- package/dist/transcription/index.js +22 -47
- package/dist/transcription/index.js.map +1 -1
- package/dist/types/annotation/annotation.types.d.ts +42 -0
- package/dist/types/annotation/constants.d.ts +31 -0
- package/dist/types/annotation/index.d.ts +117 -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 +8 -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/no-meeting-info.d.ts +14 -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/reclaim-host-role-errors.d.ts +60 -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 +93 -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 +36 -0
- package/dist/types/common/queue.d.ts +34 -0
- package/dist/types/config.d.ts +71 -0
- package/dist/types/constants.d.ts +1066 -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 +322 -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 +273 -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 +93 -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 +163 -0
- package/dist/types/meeting/index.d.ts +1676 -0
- package/dist/types/meeting/locusMediaRequest.d.ts +74 -0
- package/dist/types/meeting/muteState.d.ts +184 -0
- package/dist/types/meeting/request.d.ts +290 -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 +102 -0
- package/dist/types/meeting-info/collection.d.ts +20 -0
- package/dist/types/meeting-info/index.d.ts +69 -0
- package/dist/types/meeting-info/meeting-info-v2.d.ts +123 -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 +367 -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 +160 -0
- package/dist/types/member/types.d.ts +32 -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 +25 -0
- package/dist/types/members/util.d.ts +215 -0
- package/dist/types/metrics/constants.d.ts +65 -0
- package/dist/types/metrics/index.d.ts +45 -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 +285 -0
- package/dist/types/multistream/sendSlotManager.d.ts +61 -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 +194 -0
- package/dist/types/reachability/request.d.ts +39 -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 +207 -0
- package/dist/types/recording-controller/util.d.ts +14 -0
- package/dist/types/roap/index.d.ts +78 -0
- package/dist/types/roap/request.d.ts +39 -0
- package/dist/types/roap/turnDiscovery.d.ts +92 -0
- package/dist/types/rtcMetrics/constants.d.ts +4 -0
- package/dist/types/rtcMetrics/index.d.ts +47 -0
- package/dist/types/statsAnalyzer/global.d.ts +36 -0
- package/dist/types/statsAnalyzer/index.d.ts +201 -0
- package/dist/types/statsAnalyzer/mqaUtil.d.ts +24 -0
- package/dist/types/transcription/index.d.ts +64 -0
- package/dist/types/webinar/collection.d.ts +16 -0
- package/dist/types/webinar/index.d.ts +5 -0
- package/dist/webinar/collection.js +44 -0
- package/dist/webinar/collection.js.map +1 -0
- package/dist/webinar/index.js +69 -0
- package/dist/webinar/index.js.map +1 -0
- package/internal-README.md +7 -6
- package/package.json +29 -21
- package/src/annotation/annotation.types.ts +50 -0
- package/src/annotation/constants.ts +36 -0
- package/src/annotation/index.ts +328 -0
- package/src/breakouts/README.md +220 -0
- package/src/breakouts/breakout.ts +188 -0
- package/src/breakouts/collection.ts +19 -0
- package/src/breakouts/edit-lock-error.ts +25 -0
- package/src/breakouts/events.ts +56 -0
- package/src/breakouts/index.ts +925 -0
- package/src/breakouts/request.ts +55 -0
- package/src/breakouts/utils.ts +57 -0
- package/src/common/{browser-detection.js → browser-detection.ts} +9 -6
- package/src/common/collection.ts +9 -7
- package/src/common/{config.js → config.ts} +1 -1
- package/src/common/errors/{captcha-error.js → captcha-error.ts} +11 -7
- package/src/common/errors/{intent-to-join.js → intent-to-join.ts} +12 -7
- package/src/common/errors/{join-meeting.js → join-meeting.ts} +17 -8
- package/src/common/errors/{media.js → media.ts} +11 -7
- package/src/common/errors/no-meeting-info.ts +24 -0
- package/src/common/errors/parameter.ts +11 -7
- package/src/common/errors/{password-error.js → password-error.ts} +11 -7
- package/src/common/errors/{permission.js → permission.ts} +10 -6
- package/src/common/errors/reclaim-host-role-errors.ts +134 -0
- package/src/common/errors/{reconnection.js → reconnection.ts} +11 -7
- package/src/common/errors/{stats.js → stats.ts} +11 -7
- package/src/common/errors/{webex-errors.js → webex-errors.ts} +51 -8
- package/src/common/errors/{webex-meetings-error.js → webex-meetings-error.ts} +4 -2
- package/src/common/events/{events-scope.js → events-scope.ts} +6 -2
- package/src/common/events/{events.js → events.ts} +5 -1
- package/src/common/events/{trigger-proxy.js → trigger-proxy.ts} +9 -5
- package/src/common/events/{util.js → util.ts} +2 -3
- package/src/common/logs/{logger-config.js → logger-config.ts} +1 -2
- package/src/common/logs/logger-proxy.ts +44 -0
- package/src/common/logs/{request.js → request.ts} +26 -9
- package/src/common/queue.ts +22 -9
- package/src/{config.js → config.ts} +18 -19
- package/src/constants.ts +260 -22
- 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 +300 -0
- package/src/index.ts +40 -0
- package/src/interpretation/README.md +60 -0
- package/src/interpretation/collection.ts +19 -0
- package/src/interpretation/index.ts +332 -0
- package/src/interpretation/siLanguage.ts +18 -0
- package/src/locus-info/controlsUtils.ts +222 -0
- package/src/locus-info/{embeddedAppsUtils.js → embeddedAppsUtils.ts} +5 -6
- package/src/locus-info/{fullState.js → fullState.ts} +16 -12
- package/src/locus-info/{hostUtils.js → hostUtils.ts} +9 -8
- package/src/locus-info/{index.js → index.ts} +557 -119
- package/src/locus-info/{infoUtils.js → infoUtils.ts} +29 -10
- package/src/locus-info/{mediaSharesUtils.js → mediaSharesUtils.ts} +81 -17
- package/src/locus-info/{parser.js → parser.ts} +303 -104
- package/src/locus-info/{selfUtils.js → selfUtils.ts} +199 -68
- package/src/media/index.ts +458 -0
- package/src/media/properties.ts +283 -0
- package/src/media/{util.js → util.ts} +2 -2
- package/src/mediaQualityMetrics/config.ts +384 -0
- package/src/meeting/in-meeting-actions.ts +191 -3
- package/src/meeting/index.ts +7882 -0
- package/src/meeting/locusMediaRequest.ts +313 -0
- package/src/meeting/muteState.ts +451 -0
- package/src/meeting/{request.js → request.ts} +421 -220
- package/src/meeting/request.type.ts +13 -0
- package/src/meeting/{state.js → state.ts} +50 -35
- package/src/meeting/util.ts +697 -0
- package/src/meeting-info/{collection.js → collection.ts} +6 -2
- package/src/meeting-info/index.ts +210 -0
- package/src/meeting-info/meeting-info-v2.ts +429 -0
- package/src/meeting-info/{request.js → request.ts} +14 -4
- package/src/meeting-info/{util.js → util.ts} +60 -51
- package/src/meeting-info/{utilv2.js → utilv2.ts} +78 -71
- package/src/meetings/{collection.js → collection.ts} +26 -3
- package/src/meetings/index.ts +1470 -0
- package/src/meetings/meetings.types.ts +12 -0
- package/src/meetings/{request.js → request.ts} +34 -25
- package/src/meetings/{util.js → util.ts} +132 -37
- package/src/member/{index.js → index.ts} +160 -56
- package/src/member/types.ts +38 -0
- package/src/member/util.ts +397 -0
- package/src/members/{collection.js → collection.ts} +10 -2
- package/src/members/{index.js → index.ts} +351 -146
- package/src/members/request.ts +255 -0
- package/src/members/types.ts +29 -0
- package/src/members/util.ts +353 -0
- package/src/metrics/{constants.js → constants.ts} +12 -6
- package/src/metrics/index.ts +73 -0
- package/src/multistream/mediaRequestManager.ts +337 -63
- package/src/multistream/receiveSlot.ts +69 -26
- package/src/multistream/receiveSlotManager.ts +66 -42
- package/src/multistream/remoteMedia.ts +40 -5
- package/src/multistream/remoteMediaGroup.ts +63 -3
- package/src/multistream/remoteMediaManager.ts +300 -66
- package/src/multistream/sendSlotManager.ts +170 -0
- package/src/networkQualityMonitor/{index.js → index.ts} +41 -29
- package/src/personal-meeting-room/{index.js → index.ts} +28 -19
- package/src/personal-meeting-room/{request.js → request.ts} +13 -4
- package/src/personal-meeting-room/{util.js → util.ts} +4 -4
- package/src/reachability/index.ts +671 -0
- package/src/reachability/request.ts +50 -35
- package/src/reactions/constants.ts +4 -0
- package/src/reactions/reactions.ts +104 -0
- package/src/reactions/reactions.type.ts +62 -0
- package/src/reconnection-manager/{index.js → index.ts} +258 -138
- package/src/recording-controller/enums.ts +8 -0
- package/src/recording-controller/index.ts +332 -0
- package/src/recording-controller/util.ts +75 -0
- package/src/roap/{index.js → index.ts} +127 -79
- package/src/roap/request.ts +153 -0
- package/src/roap/turnDiscovery.ts +109 -47
- package/src/rtcMetrics/constants.ts +3 -0
- package/src/rtcMetrics/index.ts +100 -0
- package/src/statsAnalyzer/global.ts +37 -0
- package/src/statsAnalyzer/index.ts +1250 -0
- package/src/statsAnalyzer/mqaUtil.ts +292 -0
- package/src/transcription/{index.js → index.ts} +46 -39
- package/src/webinar/collection.ts +31 -0
- package/src/webinar/index.ts +62 -0
- package/test/integration/spec/converged-space-meetings.js +233 -0
- package/test/integration/spec/journey.js +790 -530
- package/test/integration/spec/space-meeting.js +391 -204
- package/test/integration/spec/transcription.js +7 -8
- package/test/unit/spec/annotation/index.ts +418 -0
- package/test/unit/spec/breakouts/breakout.ts +237 -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 +89 -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/common/browser-detection.js +9 -28
- package/test/unit/spec/common/queue.js +31 -2
- package/test/unit/spec/controls-options-manager/index.js +287 -0
- package/test/unit/spec/controls-options-manager/util.js +582 -0
- package/test/unit/spec/fixture/locus.js +93 -90
- package/test/unit/spec/interpretation/collection.ts +15 -0
- package/test/unit/spec/interpretation/index.ts +589 -0
- package/test/unit/spec/interpretation/siLanguage.ts +28 -0
- package/test/unit/spec/locus-info/controlsUtils.js +325 -32
- package/test/unit/spec/locus-info/embeddedAppsUtils.js +8 -6
- package/test/unit/spec/locus-info/index.js +1390 -17
- package/test/unit/spec/locus-info/infoUtils.js +71 -40
- package/test/unit/spec/locus-info/lib/BasicSeqCmp.json +88 -430
- package/test/unit/spec/locus-info/lib/SeqCmp.json +529 -685
- package/test/unit/spec/locus-info/mediaSharesUtils.ts +32 -0
- package/test/unit/spec/locus-info/parser.js +119 -44
- package/test/unit/spec/locus-info/selfConstant.js +120 -103
- package/test/unit/spec/locus-info/selfUtils.js +296 -12
- package/test/unit/spec/media/index.ts +128 -77
- package/test/unit/spec/media/properties.ts +11 -11
- package/test/unit/spec/meeting/in-meeting-actions.ts +92 -3
- package/test/unit/spec/meeting/index.js +7433 -2752
- package/test/unit/spec/meeting/locusMediaRequest.ts +442 -0
- package/test/unit/spec/meeting/muteState.js +420 -211
- package/test/unit/spec/meeting/request.js +545 -79
- package/test/unit/spec/meeting/utils.js +722 -174
- package/test/unit/spec/meeting-info/index.js +300 -0
- package/test/unit/spec/meeting-info/meetinginfov2.js +624 -76
- package/test/unit/spec/meeting-info/request.js +7 -9
- package/test/unit/spec/meeting-info/util.js +11 -12
- package/test/unit/spec/meeting-info/utilv2.js +131 -74
- package/test/unit/spec/meetings/collection.js +15 -1
- package/test/unit/spec/meetings/index.js +1365 -377
- package/test/unit/spec/meetings/utils.js +216 -14
- package/test/unit/spec/member/index.js +61 -7
- package/test/unit/spec/member/util.js +526 -26
- package/test/unit/spec/members/index.js +536 -55
- package/test/unit/spec/members/request.js +228 -40
- package/test/unit/spec/members/utils.js +217 -4
- package/test/unit/spec/metrics/index.js +12 -66
- 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 +40 -2
- package/test/unit/spec/multistream/remoteMediaGroup.ts +271 -5
- package/test/unit/spec/multistream/remoteMediaManager.ts +738 -65
- package/test/unit/spec/multistream/sendSlotManager.ts +242 -0
- package/test/unit/spec/networkQualityMonitor/index.js +24 -18
- package/test/unit/spec/personal-meeting-room/personal-meeting-room.js +2 -7
- package/test/unit/spec/reachability/index.ts +598 -26
- package/test/unit/spec/reachability/request.js +68 -0
- package/test/unit/spec/reconnection-manager/index.js +181 -12
- package/test/unit/spec/recording-controller/index.js +307 -0
- package/test/unit/spec/recording-controller/util.js +229 -0
- package/test/unit/spec/roap/index.ts +179 -64
- package/test/unit/spec/roap/request.ts +232 -0
- package/test/unit/spec/roap/turnDiscovery.ts +123 -58
- package/test/unit/spec/rtcMetrics/index.ts +73 -0
- package/test/unit/spec/stats-analyzer/index.js +199 -60
- package/test/unit/spec/webinar/collection.ts +13 -0
- package/test/unit/spec/webinar/index.ts +60 -0
- package/test/utils/cmr.js +44 -42
- package/test/utils/constants.js +9 -0
- package/test/utils/integrationTestUtils.js +46 -0
- package/test/utils/testUtils.js +63 -99
- package/test/utils/webex-config.js +22 -18
- package/test/utils/webex-test-users.js +57 -50
- package/tsconfig.json +6 -0
- package/dist/media/internal-media-core-wrapper.js +0 -22
- package/dist/media/internal-media-core-wrapper.js.map +0 -1
- package/dist/meeting/effectsState.js +0 -327
- package/dist/meeting/effectsState.js.map +0 -1
- package/dist/metrics/config.js +0 -301
- package/dist/metrics/config.js.map +0 -1
- package/dist/multistream/multistreamMedia.js +0 -116
- package/dist/multistream/multistreamMedia.js.map +0 -1
- package/dist/peer-connection-manager/util.js +0 -124
- package/dist/peer-connection-manager/util.js.map +0 -1
- package/src/common/logs/logger-proxy.js +0 -33
- package/src/index.js +0 -15
- package/src/locus-info/controlsUtils.js +0 -102
- package/src/media/index.js +0 -459
- package/src/media/internal-media-core-wrapper.ts +0 -9
- package/src/media/properties.js +0 -289
- package/src/mediaQualityMetrics/config.js +0 -382
- package/src/meeting/effectsState.js +0 -205
- package/src/meeting/index.js +0 -6284
- package/src/meeting/muteState.js +0 -318
- package/src/meeting/util.js +0 -506
- package/src/meeting-info/index.js +0 -131
- package/src/meeting-info/meeting-info-v2.js +0 -255
- package/src/meetings/index.js +0 -1015
- package/src/member/util.js +0 -254
- package/src/members/request.js +0 -131
- package/src/members/util.js +0 -258
- package/src/metrics/config.js +0 -324
- package/src/metrics/index.js +0 -530
- package/src/multistream/multistreamMedia.ts +0 -92
- package/src/peer-connection-manager/util.ts +0 -117
- package/src/reachability/index.js +0 -464
- package/src/roap/request.js +0 -127
- package/src/statsAnalyzer/global.js +0 -133
- package/src/statsAnalyzer/index.js +0 -1006
- package/src/statsAnalyzer/mqaUtil.js +0 -173
- package/test/unit/spec/meeting/effectsState.js +0 -291
- package/test/unit/spec/peerconnection-manager/utils.test-fixtures.ts +0 -389
- /package/src/common/errors/{reconnection-in-progress.js → reconnection-in-progress.ts} +0 -0
package/README.md
CHANGED
|
@@ -117,7 +117,7 @@ webex.meetings.getMeetingByType('SIP_URI', sipUri);
|
|
|
117
117
|
|
|
118
118
|
```js
|
|
119
119
|
webex.meetings.personalMeetingRoom; // the personal meeting room instance
|
|
120
|
-
webex.meetings.reachability; // the reachability instance
|
|
120
|
+
webex.meetings.reachability; // the reachability instance
|
|
121
121
|
webex.meetings.meetingCollection; // the collection of meetings instance
|
|
122
122
|
webex.meetings.meetingInfo; // the meeting info instance
|
|
123
123
|
```
|
|
@@ -331,7 +331,6 @@ webex.meetings.on('meeting:added', (addedMeeting) => {
|
|
|
331
331
|
addedMeeting.join().then(() => {});
|
|
332
332
|
}
|
|
333
333
|
```
|
|
334
|
-
|
|
335
334
|
##### Reject an incoming meeting
|
|
336
335
|
|
|
337
336
|
When listening to an added meeting, to determine if it is an "incoming" meeting, check the type property of the meeting:
|
|
@@ -457,6 +456,51 @@ audioOutputSelect.onchange = function () {
|
|
|
457
456
|
attachSinkId(document.getElementById('remoteaudio'), audioOutputSelect.value);
|
|
458
457
|
};
|
|
459
458
|
```
|
|
459
|
+
##### Availabel joining options
|
|
460
|
+
```
|
|
461
|
+
/**
|
|
462
|
+
* Make a network request to join a meeting
|
|
463
|
+
* @param {Object} options
|
|
464
|
+
* @param {String} options.sipUri
|
|
465
|
+
* @param {String} options.deviceUrl
|
|
466
|
+
* @param {String} options.locusUrl
|
|
467
|
+
* @param {String} options.resourceId,
|
|
468
|
+
* @param {String} options.correlationId
|
|
469
|
+
* @param {boolean} options.ensureConversation
|
|
470
|
+
* @param {boolean} options.moderator
|
|
471
|
+
* @param {boolean} options.pin
|
|
472
|
+
* @param {boolean} options.moveToResource
|
|
473
|
+
* @param {Object} options.roapMessage
|
|
474
|
+
* @param {boolean} options.breakoutsSupported
|
|
475
|
+
* @param {String} options.locale,
|
|
476
|
+
* @param {Array} options.deviceCapabilities
|
|
477
|
+
* @param {boolean} options.liveAnnotationSupported
|
|
478
|
+
* @returns {Promise}
|
|
479
|
+
*/
|
|
480
|
+
```
|
|
481
|
+
##### options.deviceCapabilities
|
|
482
|
+
This option provides toggles that Locus service needs, and those toggles will control the performance or features of the meetings to be joined, see examples:
|
|
483
|
+
###### Breakout Sessions
|
|
484
|
+
```
|
|
485
|
+
if (breakoutsSupported) {
|
|
486
|
+
deviceCapabilities.push(BREAKOUTS.BREAKOUTS_SUPPORTED);
|
|
487
|
+
}
|
|
488
|
+
```
|
|
489
|
+
###### Live Annotation
|
|
490
|
+
```
|
|
491
|
+
if (liveAnnotationSupported) {
|
|
492
|
+
deviceCapabilities.push(ANNOTATION.ANNOTATION_ON_SHARE_SUPPORTED);
|
|
493
|
+
}
|
|
494
|
+
```
|
|
495
|
+
###### Audio Disclaimer
|
|
496
|
+
```
|
|
497
|
+
const joinOptions = {
|
|
498
|
+
locale: 'en_UK', // audio disclaimer language
|
|
499
|
+
deviceCapabilities: ['SERVER_AUDIO_ANNOUNCEMENT_SUPPORTED'], // audio disclaimer toggle
|
|
500
|
+
};
|
|
501
|
+
|
|
502
|
+
const joinMeeting = () => { meeting.join(joinOptions)}
|
|
503
|
+
```
|
|
460
504
|
|
|
461
505
|
##### Record
|
|
462
506
|
|
|
@@ -956,9 +1000,6 @@ meeting.on('media:ready', (media) => {
|
|
|
956
1000
|
if (media.type === 'remoteShare') {
|
|
957
1001
|
document.getElementById('sharevideo').srcObject = media.stream;
|
|
958
1002
|
}
|
|
959
|
-
if (media.type === 'localShare') {
|
|
960
|
-
document.getElementById('localshare').srcObject = media.stream;
|
|
961
|
-
}
|
|
962
1003
|
});
|
|
963
1004
|
```
|
|
964
1005
|
|
|
@@ -979,9 +1020,6 @@ meeting.on('media:stopped', (media) => {
|
|
|
979
1020
|
if (media.type === 'remoteAudio') {
|
|
980
1021
|
document.getElementById('remoteaudio').srcObject = null;
|
|
981
1022
|
}
|
|
982
|
-
if (media.type === 'localShare') {
|
|
983
|
-
document.getElementById('localshare').srcObject = null;
|
|
984
|
-
}
|
|
985
1023
|
if (media.type === 'remoteShare') {
|
|
986
1024
|
document.getElementById('sharevideo').srcObject = null;
|
|
987
1025
|
}
|
package/UPGRADING.md
CHANGED
|
@@ -25,7 +25,7 @@ When using the phone plugin, this was handled automatically for you via `webex.p
|
|
|
25
25
|
With the meetings plugin, we provide the same method:
|
|
26
26
|
|
|
27
27
|
```js
|
|
28
|
-
webex.meetings.register()
|
|
28
|
+
webex.meetings.register();
|
|
29
29
|
```
|
|
30
30
|
|
|
31
31
|
## Dialing
|
|
@@ -56,7 +56,7 @@ await myMeeting.join();
|
|
|
56
56
|
### Joining a one-on-one meeting
|
|
57
57
|
|
|
58
58
|
```js
|
|
59
|
-
let destination =
|
|
59
|
+
let destination = 'testuser@webex.bot';
|
|
60
60
|
|
|
61
61
|
const myMeeting = await webex.meetings.create(destination);
|
|
62
62
|
|
|
@@ -92,7 +92,7 @@ const mediaSettings = {
|
|
|
92
92
|
receiveShare: true,
|
|
93
93
|
sendVideo: true,
|
|
94
94
|
sendAudio: true,
|
|
95
|
-
sendShare: false
|
|
95
|
+
sendShare: false,
|
|
96
96
|
};
|
|
97
97
|
|
|
98
98
|
const mediaStreams = await meeting.getMediaStreams(mediaSettings);
|
|
@@ -117,7 +117,7 @@ Once you have your local streams and shares, you need to add the media to the me
|
|
|
117
117
|
const mediaResponse = await meeting.addMedia({
|
|
118
118
|
localShare,
|
|
119
119
|
localStream,
|
|
120
|
-
mediaSettings
|
|
120
|
+
mediaSettings,
|
|
121
121
|
});
|
|
122
122
|
```
|
|
123
123
|
|
|
@@ -130,20 +130,20 @@ Just like the phone plugin, the meeting object will emit events that the develop
|
|
|
130
130
|
```js
|
|
131
131
|
myMeeting.on('media:ready', (media) => {
|
|
132
132
|
// Handle media streams
|
|
133
|
-
})
|
|
133
|
+
});
|
|
134
134
|
```
|
|
135
135
|
|
|
136
136
|
This event is emitted when a media stream is ready to be rendered. It contains an object with two properties:
|
|
137
137
|
|
|
138
|
-
|
|
139
|
-
|
|
138
|
+
- `stream` the actual media stream that can be used in an html srcObject
|
|
139
|
+
- `type` the type of stream that is ready (`local`, `remoteVideo`, etc)
|
|
140
140
|
|
|
141
141
|
### `media:stopped`
|
|
142
142
|
|
|
143
143
|
```js
|
|
144
144
|
myMeeting.on('media:stopped', (media) => {
|
|
145
145
|
// Remove media streams
|
|
146
|
-
})
|
|
146
|
+
});
|
|
147
147
|
```
|
|
148
148
|
|
|
149
149
|
This event is emitted when a stream has stopped sending. It has a `type` property to know which media to remove from the DOM.
|
|
@@ -197,7 +197,7 @@ With a meeting object, you use these functions:
|
|
|
197
197
|
const mediaStreams = await meeting.getMediaStreams(mediaSettings);
|
|
198
198
|
const [localStream, localShare] = mediaStreams;
|
|
199
199
|
// Then, update share
|
|
200
|
-
meeting.updateShare({sendShare: true, receiveShare:true, stream: localShare})
|
|
200
|
+
meeting.updateShare({sendShare: true, receiveShare: true, stream: localShare});
|
|
201
201
|
```
|
|
202
202
|
|
|
203
203
|
### Stop Sending Share
|
package/browsers.js
CHANGED
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
// eslint-disable-next-line strict
|
|
6
6
|
|
|
7
|
-
|
|
8
7
|
/* eslint camelcase: [0] */
|
|
9
8
|
module.exports = function createBrowsers() {
|
|
10
9
|
if (process.env.SC_TUNNEL_IDENTIFIER || process.env.SAUCE) {
|
|
@@ -19,14 +18,14 @@ module.exports = function createBrowsers() {
|
|
|
19
18
|
args: [
|
|
20
19
|
'--disable-features=WebRtcHideLocalIpsWithMdns',
|
|
21
20
|
'--use-fake-device-for-media-stream',
|
|
22
|
-
'--use-fake-ui-for-media-stream'
|
|
23
|
-
]
|
|
21
|
+
'--use-fake-ui-for-media-stream',
|
|
22
|
+
],
|
|
24
23
|
},
|
|
25
24
|
flags: [
|
|
26
25
|
'--disable-features=WebRtcHideLocalIpsWithMdns',
|
|
27
26
|
'--use-fake-device-for-media-stream',
|
|
28
|
-
'--use-fake-ui-for-media-stream'
|
|
29
|
-
]
|
|
27
|
+
'--use-fake-ui-for-media-stream',
|
|
28
|
+
],
|
|
30
29
|
},
|
|
31
30
|
sl_edge_latest_Win_10: {
|
|
32
31
|
base: 'SauceLabs',
|
|
@@ -38,9 +37,9 @@ module.exports = function createBrowsers() {
|
|
|
38
37
|
args: [
|
|
39
38
|
'--disable-features=WebRtcHideLocalIpsWithMdns',
|
|
40
39
|
'--use-fake-device-for-media-stream',
|
|
41
|
-
'--use-fake-ui-for-media-stream'
|
|
42
|
-
]
|
|
43
|
-
}
|
|
40
|
+
'--use-fake-ui-for-media-stream',
|
|
41
|
+
],
|
|
42
|
+
},
|
|
44
43
|
},
|
|
45
44
|
// sl_firefox_latest_linux: {
|
|
46
45
|
// base: 'SauceLabs',
|
|
@@ -54,8 +53,8 @@ module.exports = function createBrowsers() {
|
|
|
54
53
|
browserName: 'Safari',
|
|
55
54
|
version: 'latest',
|
|
56
55
|
'webkit:WebRTC': {
|
|
57
|
-
DisableInsecureMediaCapture: true
|
|
58
|
-
}
|
|
56
|
+
DisableInsecureMediaCapture: true,
|
|
57
|
+
},
|
|
59
58
|
},
|
|
60
59
|
sl_firefox_macOS_Catalina: {
|
|
61
60
|
base: 'SauceLabs',
|
|
@@ -63,10 +62,7 @@ module.exports = function createBrowsers() {
|
|
|
63
62
|
browserName: 'Firefox',
|
|
64
63
|
extendedDebugging: true,
|
|
65
64
|
'moz:firefoxOptions': {
|
|
66
|
-
args: [
|
|
67
|
-
'-start-debugger-server',
|
|
68
|
-
'9222'
|
|
69
|
-
],
|
|
65
|
+
args: ['-start-debugger-server', '9222'],
|
|
70
66
|
prefs: {
|
|
71
67
|
'devtools.chrome.enabled': true,
|
|
72
68
|
'devtools.debugger.prompt-connection': false,
|
|
@@ -76,10 +72,10 @@ module.exports = function createBrowsers() {
|
|
|
76
72
|
'media.getusermedia.screensharing.enabled': true,
|
|
77
73
|
'media.navigator.permission.disabled': true,
|
|
78
74
|
'media.navigator.streams.fake': true,
|
|
79
|
-
'media.peerconnection.video.h264_enabled': true
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
}
|
|
75
|
+
'media.peerconnection.video.h264_enabled': true,
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
},
|
|
83
79
|
// sl_firefox_latest_win7: {
|
|
84
80
|
// base: `SauceLabs`,
|
|
85
81
|
// platform: `Windows 7`,
|
|
@@ -97,17 +93,16 @@ module.exports = function createBrowsers() {
|
|
|
97
93
|
'media.getusermedia.screensharing.enabled': true,
|
|
98
94
|
'media.navigator.permission.disabled': true,
|
|
99
95
|
'media.navigator.streams.fake': true,
|
|
100
|
-
'media.peerconnection.video.h264_enabled': true
|
|
101
|
-
}
|
|
96
|
+
'media.peerconnection.video.h264_enabled': true,
|
|
97
|
+
},
|
|
102
98
|
},
|
|
103
99
|
ChromeH264: {
|
|
104
100
|
base: 'ChromeHeadless',
|
|
105
101
|
flags: [
|
|
106
102
|
'--disable-features=WebRtcHideLocalIpsWithMdns',
|
|
107
103
|
'--use-fake-device-for-media-stream',
|
|
108
|
-
'--use-fake-ui-for-media-stream'
|
|
109
|
-
]
|
|
110
|
-
}
|
|
104
|
+
'--use-fake-ui-for-media-stream',
|
|
105
|
+
],
|
|
106
|
+
},
|
|
111
107
|
};
|
|
112
108
|
};
|
|
113
|
-
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sources":["annotation.types.ts"],"sourcesContent":["import {ANNOTATION_POLICY} from './constants';\n\n/**\n * Type for an StrokeData Object\n */\ntype StrokeData = {\n deviceId: string;\n toUserId: string;\n requesterId: string;\n content: string;\n shareInstanceId: string;\n encryptionKeyUrl: string;\n version: string;\n};\n\ntype RequestData = {\n toUserId: string;\n toDeviceUrl: string;\n shareInstanceId: string;\n};\n\ntype CommandRequestBody = {\n actionType: string;\n resourceType: string;\n shareInstanceId: string;\n receivers?: any[];\n};\n/**\n * Type for an annotation Object include annotation version and privilege\n */\ntype AnnotationInfo = {\n version: string;\n policy: ANNOTATION_POLICY;\n};\n\ninterface IAnnotationChannel {\n // === below is for presenter\n acceptRequest: (approval) => undefined | Promise<void>;\n declineRequest: (approval) => undefined | Promise<void>;\n closeAnnotation: (requestData: RequestData) => undefined | Promise<void>;\n // === below is for attendee\n approveAnnotation: (requestData: RequestData) => undefined | Promise<void>;\n cancelApproveAnnotation: (requestData: RequestData, approval) => undefined | Promise<void>;\n sendStrokeData: (strokeData: StrokeData) => void;\n // =====\n approvalUrlUpdate: (approvalUrl: string) => void;\n locusUrlUpdate: (locusUrl: string) => void;\n}\n\nexport type {StrokeData, RequestData, CommandRequestBody, IAnnotationChannel, AnnotationInfo};\n"],"mappings":""}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _Object$defineProperty = require("@babel/runtime-corejs2/core-js/object/define-property");
|
|
4
|
+
_Object$defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.EVENT_TRIGGERS = exports.ANNOTATION_STATUS = exports.ANNOTATION_RESOURCE_TYPE = exports.ANNOTATION_REQUEST_TYPE = exports.ANNOTATION_RELAY_TYPES = exports.ANNOTATION_POLICY = exports.ANNOTATION_ACTION_TYPE = exports.ANNOTATION = void 0;
|
|
8
|
+
var EVENT_TRIGGERS = {
|
|
9
|
+
ANNOTATION_STROKE_DATA: 'annotation:strokeData',
|
|
10
|
+
ANNOTATION_COMMAND: 'annotation:command'
|
|
11
|
+
};
|
|
12
|
+
exports.EVENT_TRIGGERS = EVENT_TRIGGERS;
|
|
13
|
+
var ANNOTATION_RESOURCE_TYPE = 'AnnotationOnShare';
|
|
14
|
+
exports.ANNOTATION_RESOURCE_TYPE = ANNOTATION_RESOURCE_TYPE;
|
|
15
|
+
var ANNOTATION_RELAY_TYPES = {
|
|
16
|
+
ANNOTATION_CLIENT: 'annotation.client'
|
|
17
|
+
};
|
|
18
|
+
exports.ANNOTATION_RELAY_TYPES = ANNOTATION_RELAY_TYPES;
|
|
19
|
+
var ANNOTATION_STATUS = {
|
|
20
|
+
NO_ANNOTATION: 'NO_ANNOTATION',
|
|
21
|
+
RUNNING_ANNOTATION: 'RUNNING_ANNOTATION'
|
|
22
|
+
};
|
|
23
|
+
exports.ANNOTATION_STATUS = ANNOTATION_STATUS;
|
|
24
|
+
var ANNOTATION_POLICY;
|
|
25
|
+
exports.ANNOTATION_POLICY = ANNOTATION_POLICY;
|
|
26
|
+
(function (ANNOTATION_POLICY) {
|
|
27
|
+
ANNOTATION_POLICY["ANYONE_CAN_ANNOTATE"] = "AnyoneCanAnnotate";
|
|
28
|
+
ANNOTATION_POLICY["APPROVAL"] = "Approval";
|
|
29
|
+
ANNOTATION_POLICY["ANNOTATION_NOT_ALLOWED"] = "AnnotationNotAllowed";
|
|
30
|
+
})(ANNOTATION_POLICY || (exports.ANNOTATION_POLICY = ANNOTATION_POLICY = {}));
|
|
31
|
+
var ANNOTATION_REQUEST_TYPE = {
|
|
32
|
+
ANNOTATION_MESSAGE: 'annotation_message'
|
|
33
|
+
};
|
|
34
|
+
exports.ANNOTATION_REQUEST_TYPE = ANNOTATION_REQUEST_TYPE;
|
|
35
|
+
var ANNOTATION_ACTION_TYPE;
|
|
36
|
+
exports.ANNOTATION_ACTION_TYPE = ANNOTATION_ACTION_TYPE;
|
|
37
|
+
(function (ANNOTATION_ACTION_TYPE) {
|
|
38
|
+
ANNOTATION_ACTION_TYPE["REQUESTED"] = "REQUESTED";
|
|
39
|
+
ANNOTATION_ACTION_TYPE["ACCEPTED"] = "ACCEPTED";
|
|
40
|
+
ANNOTATION_ACTION_TYPE["DECLINED"] = "DECLINED";
|
|
41
|
+
ANNOTATION_ACTION_TYPE["OFFERED"] = "OFFERED";
|
|
42
|
+
ANNOTATION_ACTION_TYPE["CANCELED"] = "CANCELED";
|
|
43
|
+
ANNOTATION_ACTION_TYPE["EXPIRED"] = "EXPIRED";
|
|
44
|
+
ANNOTATION_ACTION_TYPE["REVOKED"] = "REVOKED";
|
|
45
|
+
ANNOTATION_ACTION_TYPE["CLOSED"] = "CLOSED";
|
|
46
|
+
})(ANNOTATION_ACTION_TYPE || (exports.ANNOTATION_ACTION_TYPE = ANNOTATION_ACTION_TYPE = {}));
|
|
47
|
+
var ANNOTATION = 'annotation';
|
|
48
|
+
exports.ANNOTATION = ANNOTATION;
|
|
49
|
+
//# sourceMappingURL=constants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["EVENT_TRIGGERS","ANNOTATION_STROKE_DATA","ANNOTATION_COMMAND","ANNOTATION_RESOURCE_TYPE","ANNOTATION_RELAY_TYPES","ANNOTATION_CLIENT","ANNOTATION_STATUS","NO_ANNOTATION","RUNNING_ANNOTATION","ANNOTATION_POLICY","ANNOTATION_REQUEST_TYPE","ANNOTATION_MESSAGE","ANNOTATION_ACTION_TYPE","ANNOTATION"],"sources":["constants.ts"],"sourcesContent":["export const EVENT_TRIGGERS = {\n ANNOTATION_STROKE_DATA: 'annotation:strokeData',\n ANNOTATION_COMMAND: 'annotation:command',\n};\nexport const ANNOTATION_RESOURCE_TYPE = 'AnnotationOnShare';\nexport const ANNOTATION_RELAY_TYPES = {\n ANNOTATION_CLIENT: 'annotation.client',\n};\n\nexport const ANNOTATION_STATUS = {\n NO_ANNOTATION: 'NO_ANNOTATION',\n RUNNING_ANNOTATION: 'RUNNING_ANNOTATION',\n};\n\nexport enum ANNOTATION_POLICY {\n ANYONE_CAN_ANNOTATE = 'AnyoneCanAnnotate',\n APPROVAL = 'Approval',\n ANNOTATION_NOT_ALLOWED = 'AnnotationNotAllowed',\n}\n\nexport const ANNOTATION_REQUEST_TYPE = {\n ANNOTATION_MESSAGE: 'annotation_message',\n};\n\nexport const enum ANNOTATION_ACTION_TYPE {\n REQUESTED = 'REQUESTED',\n ACCEPTED = 'ACCEPTED',\n DECLINED = 'DECLINED',\n OFFERED = 'OFFERED',\n CANCELED = 'CANCELED',\n EXPIRED = 'EXPIRED',\n REVOKED = 'REVOKED',\n CLOSED = 'CLOSED',\n}\n\nexport const ANNOTATION = 'annotation';\n"],"mappings":";;;;;;;AAAO,IAAMA,cAAc,GAAG;EAC5BC,sBAAsB,EAAE,uBAAuB;EAC/CC,kBAAkB,EAAE;AACtB,CAAC;AAAC;AACK,IAAMC,wBAAwB,GAAG,mBAAmB;AAAC;AACrD,IAAMC,sBAAsB,GAAG;EACpCC,iBAAiB,EAAE;AACrB,CAAC;AAAC;AAEK,IAAMC,iBAAiB,GAAG;EAC/BC,aAAa,EAAE,eAAe;EAC9BC,kBAAkB,EAAE;AACtB,CAAC;AAAC;AAAA,IAEUC,iBAAiB;AAAA;AAAA,WAAjBA,iBAAiB;EAAjBA,iBAAiB;EAAjBA,iBAAiB;EAAjBA,iBAAiB;AAAA,GAAjBA,iBAAiB,iCAAjBA,iBAAiB;AAMtB,IAAMC,uBAAuB,GAAG;EACrCC,kBAAkB,EAAE;AACtB,CAAC;AAAC;AAAA,IAEgBC,sBAAsB;AAAA;AAAA,WAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;AAAA,GAAtBA,sBAAsB,sCAAtBA,sBAAsB;AAWjC,IAAMC,UAAU,GAAG,YAAY;AAAC"}
|
|
@@ -0,0 +1,342 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _Reflect$construct = require("@babel/runtime-corejs2/core-js/reflect/construct");
|
|
4
|
+
var _Object$defineProperty = require("@babel/runtime-corejs2/core-js/object/define-property");
|
|
5
|
+
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
|
|
6
|
+
_Object$defineProperty(exports, "__esModule", {
|
|
7
|
+
value: true
|
|
8
|
+
});
|
|
9
|
+
exports.default = void 0;
|
|
10
|
+
var _regenerator = _interopRequireDefault(require("@babel/runtime-corejs2/regenerator"));
|
|
11
|
+
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/asyncToGenerator"));
|
|
12
|
+
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/classCallCheck"));
|
|
13
|
+
var _createClass2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/createClass"));
|
|
14
|
+
var _assertThisInitialized2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/assertThisInitialized"));
|
|
15
|
+
var _inherits2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/inherits"));
|
|
16
|
+
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/possibleConstructorReturn"));
|
|
17
|
+
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/getPrototypeOf"));
|
|
18
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/defineProperty"));
|
|
19
|
+
var _uuid = _interopRequireDefault(require("uuid"));
|
|
20
|
+
var _webexCore = require("@webex/webex-core");
|
|
21
|
+
var _triggerProxy = _interopRequireDefault(require("../common/events/trigger-proxy"));
|
|
22
|
+
var _constants = require("./constants");
|
|
23
|
+
var _constants2 = require("../constants");
|
|
24
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = _Reflect$construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
25
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !_Reflect$construct) return false; if (_Reflect$construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(_Reflect$construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
26
|
+
/**
|
|
27
|
+
* @description Annotation to handle LLM and Mercury message and locus API
|
|
28
|
+
* @class
|
|
29
|
+
*/
|
|
30
|
+
var AnnotationChannel = /*#__PURE__*/function (_WebexPlugin) {
|
|
31
|
+
(0, _inherits2.default)(AnnotationChannel, _WebexPlugin);
|
|
32
|
+
var _super = _createSuper(AnnotationChannel);
|
|
33
|
+
/**
|
|
34
|
+
* Initializes annotation module
|
|
35
|
+
*/
|
|
36
|
+
function AnnotationChannel() {
|
|
37
|
+
var _this;
|
|
38
|
+
(0, _classCallCheck2.default)(this, AnnotationChannel);
|
|
39
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
40
|
+
args[_key] = arguments[_key];
|
|
41
|
+
}
|
|
42
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
43
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "namespace", _constants.ANNOTATION);
|
|
44
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "seqNum", void 0);
|
|
45
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "hasSubscribedToEvents", void 0);
|
|
46
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "approvalUrl", void 0);
|
|
47
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "locusUrl", void 0);
|
|
48
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "deviceUrl", void 0);
|
|
49
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "sendAnnotationAction", /*#__PURE__*/function () {
|
|
50
|
+
var _ref = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(actionType, requestData) {
|
|
51
|
+
var body;
|
|
52
|
+
return _regenerator.default.wrap(function _callee$(_context) {
|
|
53
|
+
while (1) switch (_context.prev = _context.next) {
|
|
54
|
+
case 0:
|
|
55
|
+
body = {
|
|
56
|
+
actionType: actionType,
|
|
57
|
+
resourceType: 'AnnotationOnShare',
|
|
58
|
+
shareInstanceId: requestData.shareInstanceId
|
|
59
|
+
};
|
|
60
|
+
if (requestData !== null && requestData !== void 0 && requestData.toUserId) {
|
|
61
|
+
body.receivers = [{
|
|
62
|
+
participantId: requestData.toUserId,
|
|
63
|
+
deviceUrl: requestData.toDeviceUrl
|
|
64
|
+
}];
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// @ts-ignore
|
|
68
|
+
return _context.abrupt("return", _this.request({
|
|
69
|
+
method: _constants2.HTTP_VERBS.POST,
|
|
70
|
+
url: "".concat(_this.approvalUrl),
|
|
71
|
+
body: body
|
|
72
|
+
}));
|
|
73
|
+
case 3:
|
|
74
|
+
case "end":
|
|
75
|
+
return _context.stop();
|
|
76
|
+
}
|
|
77
|
+
}, _callee);
|
|
78
|
+
}));
|
|
79
|
+
return function (_x, _x2) {
|
|
80
|
+
return _ref.apply(this, arguments);
|
|
81
|
+
};
|
|
82
|
+
}());
|
|
83
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "decryptContent", function (encryptionKeyUrl, content) {
|
|
84
|
+
// @ts-ignore
|
|
85
|
+
return _this.webex.internal.encryption.decryptText(encryptionKeyUrl, content).then(function (res) {
|
|
86
|
+
return res;
|
|
87
|
+
});
|
|
88
|
+
});
|
|
89
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "encryptContent", function (encryptionKeyUrl, content) {
|
|
90
|
+
// @ts-ignore
|
|
91
|
+
return _this.webex.internal.encryption.encryptText(encryptionKeyUrl, content).then(function (res) {
|
|
92
|
+
return res;
|
|
93
|
+
});
|
|
94
|
+
});
|
|
95
|
+
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "sendStrokeData", function (strokeData) {
|
|
96
|
+
// @ts-ignore
|
|
97
|
+
if (!_this.webex.internal.llm.isConnected()) return;
|
|
98
|
+
_this.encryptContent(strokeData.encryptionKeyUrl, strokeData.content).then(function (encryptedContent) {
|
|
99
|
+
_this.publishEncrypted(encryptedContent, strokeData);
|
|
100
|
+
});
|
|
101
|
+
});
|
|
102
|
+
_this.seqNum = 1;
|
|
103
|
+
return _this;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
/**
|
|
107
|
+
* Process Stroke Data
|
|
108
|
+
* @param {object} data
|
|
109
|
+
* @returns {void}
|
|
110
|
+
*/
|
|
111
|
+
(0, _createClass2.default)(AnnotationChannel, [{
|
|
112
|
+
key: "processStrokeMessage",
|
|
113
|
+
value: function processStrokeMessage(data) {
|
|
114
|
+
var _this2 = this;
|
|
115
|
+
var request = data.request;
|
|
116
|
+
this.decryptContent(request.value.encryptionKeyUrl, request.value.content).then(function (decryptedContent) {
|
|
117
|
+
request.value.content = decryptedContent;
|
|
118
|
+
_triggerProxy.default.trigger(_this2, {
|
|
119
|
+
file: 'annotation',
|
|
120
|
+
function: 'processStrokeMessage'
|
|
121
|
+
}, _constants.EVENT_TRIGGERS.ANNOTATION_STROKE_DATA, {
|
|
122
|
+
payload: data
|
|
123
|
+
});
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
/** bind all events from mercury
|
|
128
|
+
* @param {Object} e
|
|
129
|
+
* @returns {undefined}
|
|
130
|
+
*/
|
|
131
|
+
}, {
|
|
132
|
+
key: "eventCommandProcessor",
|
|
133
|
+
value: function eventCommandProcessor(e) {
|
|
134
|
+
var _e$data, _e$data2, _e$data2$approval, _e$data3, _e$data3$approval;
|
|
135
|
+
if ((e === null || e === void 0 ? void 0 : (_e$data = e.data) === null || _e$data === void 0 ? void 0 : _e$data.eventType) === 'locus.approval_request' && (e === null || e === void 0 ? void 0 : (_e$data2 = e.data) === null || _e$data2 === void 0 ? void 0 : (_e$data2$approval = _e$data2.approval) === null || _e$data2$approval === void 0 ? void 0 : _e$data2$approval.resourceType) === _constants.ANNOTATION_RESOURCE_TYPE && e !== null && e !== void 0 && (_e$data3 = e.data) !== null && _e$data3 !== void 0 && (_e$data3$approval = _e$data3.approval) !== null && _e$data3$approval !== void 0 && _e$data3$approval.actionType) {
|
|
136
|
+
_triggerProxy.default.trigger(this, {
|
|
137
|
+
file: 'annotation',
|
|
138
|
+
function: 'approval_request'
|
|
139
|
+
}, _constants.EVENT_TRIGGERS.ANNOTATION_COMMAND, {
|
|
140
|
+
type: e.data.approval.actionType,
|
|
141
|
+
payload: e.data.approval
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
/** bind all events from llm
|
|
147
|
+
* @param {Object} e
|
|
148
|
+
* @returns {undefined}
|
|
149
|
+
*/
|
|
150
|
+
}, {
|
|
151
|
+
key: "eventDataProcessor",
|
|
152
|
+
value: function eventDataProcessor(e) {
|
|
153
|
+
var _e$data4;
|
|
154
|
+
switch (e === null || e === void 0 ? void 0 : (_e$data4 = e.data) === null || _e$data4 === void 0 ? void 0 : _e$data4.relayType) {
|
|
155
|
+
case _constants.ANNOTATION_RELAY_TYPES.ANNOTATION_CLIENT:
|
|
156
|
+
this.processStrokeMessage(e.data);
|
|
157
|
+
break;
|
|
158
|
+
default:
|
|
159
|
+
break;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* Listen to websocket messages
|
|
165
|
+
* @returns {undefined}
|
|
166
|
+
*/
|
|
167
|
+
}, {
|
|
168
|
+
key: "listenToEvents",
|
|
169
|
+
value: function listenToEvents() {
|
|
170
|
+
if (!this.hasSubscribedToEvents) {
|
|
171
|
+
// @ts-ignore
|
|
172
|
+
this.webex.internal.mercury.on('event:locus.approval_request', this.eventCommandProcessor, this);
|
|
173
|
+
// @ts-ignore
|
|
174
|
+
this.webex.internal.llm.on('event:relay.event', this.eventDataProcessor, this);
|
|
175
|
+
this.hasSubscribedToEvents = true;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
/**
|
|
180
|
+
* set locusUrl
|
|
181
|
+
* @param {string} locusUrl
|
|
182
|
+
* @returns {void}
|
|
183
|
+
*/
|
|
184
|
+
}, {
|
|
185
|
+
key: "locusUrlUpdate",
|
|
186
|
+
value: function locusUrlUpdate(locusUrl) {
|
|
187
|
+
this.locusUrl = locusUrl;
|
|
188
|
+
this.listenToEvents();
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* set approved url
|
|
193
|
+
* @param {string} approvalUrl
|
|
194
|
+
* @returns {void}
|
|
195
|
+
*/
|
|
196
|
+
}, {
|
|
197
|
+
key: "approvalUrlUpdate",
|
|
198
|
+
value: function approvalUrlUpdate(approvalUrl) {
|
|
199
|
+
this.approvalUrl = approvalUrl;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
/**
|
|
203
|
+
* accept request
|
|
204
|
+
* @param {object} approval
|
|
205
|
+
* @returns {Promise}
|
|
206
|
+
*/
|
|
207
|
+
}, {
|
|
208
|
+
key: "acceptRequest",
|
|
209
|
+
value: function acceptRequest(approval) {
|
|
210
|
+
// @ts-ignore
|
|
211
|
+
return this.request({
|
|
212
|
+
method: _constants2.HTTP_VERBS.PUT,
|
|
213
|
+
url: approval.url,
|
|
214
|
+
body: {
|
|
215
|
+
resourceType: _constants.ANNOTATION_RESOURCE_TYPE,
|
|
216
|
+
actionType: _constants.ANNOTATION_ACTION_TYPE.ACCEPTED
|
|
217
|
+
}
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
/**
|
|
222
|
+
* presenter declined request annotation
|
|
223
|
+
* @param {approval} approval
|
|
224
|
+
* @returns {Promise}
|
|
225
|
+
*/
|
|
226
|
+
}, {
|
|
227
|
+
key: "declineRequest",
|
|
228
|
+
value: function declineRequest(approval) {
|
|
229
|
+
// @ts-ignore
|
|
230
|
+
return this.request({
|
|
231
|
+
method: _constants2.HTTP_VERBS.PUT,
|
|
232
|
+
url: approval.url,
|
|
233
|
+
body: {
|
|
234
|
+
resourceType: _constants.ANNOTATION_RESOURCE_TYPE,
|
|
235
|
+
actionType: _constants.ANNOTATION_ACTION_TYPE.DECLINED
|
|
236
|
+
}
|
|
237
|
+
});
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
/**
|
|
241
|
+
* request approved annotation
|
|
242
|
+
* @param {RequestData} requestData
|
|
243
|
+
* @returns {Promise}
|
|
244
|
+
*/
|
|
245
|
+
}, {
|
|
246
|
+
key: "approveAnnotation",
|
|
247
|
+
value: function approveAnnotation(requestData) {
|
|
248
|
+
return this.sendAnnotationAction(_constants.ANNOTATION_ACTION_TYPE.REQUESTED, requestData);
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
/**
|
|
252
|
+
* cancel approved annotation
|
|
253
|
+
* @param {object} requestData
|
|
254
|
+
* @param {object} approval
|
|
255
|
+
* @returns {Promise}
|
|
256
|
+
*/
|
|
257
|
+
}, {
|
|
258
|
+
key: "cancelApproveAnnotation",
|
|
259
|
+
value: function cancelApproveAnnotation(requestData, approval) {
|
|
260
|
+
var body = {
|
|
261
|
+
actionType: _constants.ANNOTATION_ACTION_TYPE.CANCELED,
|
|
262
|
+
resourceType: 'AnnotationOnShare',
|
|
263
|
+
shareInstanceId: requestData.shareInstanceId
|
|
264
|
+
};
|
|
265
|
+
|
|
266
|
+
// @ts-ignore
|
|
267
|
+
return this.request({
|
|
268
|
+
method: _constants2.HTTP_VERBS.PUT,
|
|
269
|
+
url: "".concat(approval.url),
|
|
270
|
+
body: body
|
|
271
|
+
});
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
/**
|
|
275
|
+
* close annotation
|
|
276
|
+
* @param {object} requestData
|
|
277
|
+
* @returns {Promise}
|
|
278
|
+
*/
|
|
279
|
+
}, {
|
|
280
|
+
key: "closeAnnotation",
|
|
281
|
+
value: function closeAnnotation(requestData) {
|
|
282
|
+
return this.sendAnnotationAction(_constants.ANNOTATION_ACTION_TYPE.CLOSED, requestData);
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
/**
|
|
286
|
+
* send annotation command
|
|
287
|
+
* @param {ANNOTATION_ACTION_TYPE} actionType
|
|
288
|
+
* @param {RequestData} requestData
|
|
289
|
+
* @returns {Promise}
|
|
290
|
+
*/
|
|
291
|
+
}, {
|
|
292
|
+
key: "publishEncrypted",
|
|
293
|
+
value:
|
|
294
|
+
/**
|
|
295
|
+
* private encrypted the strokes data
|
|
296
|
+
* @param {string} encryptedContent
|
|
297
|
+
* @param {StrokeData} strokeData
|
|
298
|
+
* @returns {void}
|
|
299
|
+
*/
|
|
300
|
+
function publishEncrypted(encryptedContent, strokeData) {
|
|
301
|
+
var data = {
|
|
302
|
+
id: "".concat(this.seqNum),
|
|
303
|
+
type: 'publishRequest',
|
|
304
|
+
recipients: {
|
|
305
|
+
// @ts-ignore
|
|
306
|
+
route: this.webex.internal.llm.getBinding()
|
|
307
|
+
},
|
|
308
|
+
headers: {
|
|
309
|
+
to: strokeData.toUserId
|
|
310
|
+
},
|
|
311
|
+
data: {
|
|
312
|
+
eventType: 'relay.event',
|
|
313
|
+
relayType: _constants.ANNOTATION_RELAY_TYPES.ANNOTATION_CLIENT,
|
|
314
|
+
request: {
|
|
315
|
+
value: {
|
|
316
|
+
type: _constants.ANNOTATION_REQUEST_TYPE.ANNOTATION_MESSAGE,
|
|
317
|
+
content: encryptedContent,
|
|
318
|
+
deviceId: strokeData.deviceId,
|
|
319
|
+
seq: this.seqNum,
|
|
320
|
+
requesterId: strokeData.requesterId,
|
|
321
|
+
version: strokeData.version,
|
|
322
|
+
shareInstanceId: strokeData.shareInstanceId,
|
|
323
|
+
encryptionKeyUrl: strokeData.encryptionKeyUrl
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
},
|
|
327
|
+
trackingId: "".concat(_webexCore.config.trackingIdPrefix, "_").concat(_uuid.default.v4().toString()),
|
|
328
|
+
timestamp: new Date().getTime(),
|
|
329
|
+
sequenceNumber: this.seqNum,
|
|
330
|
+
filterMessage: false
|
|
331
|
+
};
|
|
332
|
+
|
|
333
|
+
// @ts-ignore
|
|
334
|
+
this.webex.internal.llm.socket.send(data);
|
|
335
|
+
this.seqNum += 1;
|
|
336
|
+
}
|
|
337
|
+
}]);
|
|
338
|
+
return AnnotationChannel;
|
|
339
|
+
}(_webexCore.WebexPlugin);
|
|
340
|
+
var _default = AnnotationChannel;
|
|
341
|
+
exports.default = _default;
|
|
342
|
+
//# sourceMappingURL=index.js.map
|