fcr-ui-scene 3.1.1 → 3.3.0
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/installer/icons/favicon.ico +0 -0
- package/installer/icons/favicon.png +0 -0
- package/installer/mac/entitlements.mac.plist +16 -0
- package/lib/base.d.ts +0 -1
- package/lib/base.js +16 -0
- package/lib/common/device-store.d.ts +4 -5
- package/lib/common/device-store.js +178 -86
- package/lib/common/device-stream-store.d.ts +3 -2
- package/lib/common/device-stream-store.js +94 -72
- package/lib/common/event-store.d.ts +20 -3
- package/lib/common/event-store.js +43 -5
- package/lib/common/security-store.d.ts +16 -16
- package/lib/common/security-store.js +278 -124
- package/lib/electron/app.js +13 -5
- package/lib/electron/bootstrap-dev.d.ts +1 -0
- package/lib/electron/bootstrap-dev.js +51 -0
- package/lib/electron/bootstrap-sdk.d.ts +1 -0
- package/lib/electron/bootstrap-sdk.js +56 -0
- package/lib/electron/bootstrap.d.ts +1 -0
- package/lib/electron/bootstrap.js +56 -0
- package/lib/electron/default-options.js +1 -1
- package/lib/electron/dev.d.ts +1 -0
- package/lib/electron/dev.js +51 -0
- package/lib/electron/injections.d.ts +3 -4
- package/lib/electron/injections.js +46 -33
- package/lib/electron/logger.d.ts +6 -0
- package/lib/electron/logger.js +66 -0
- package/lib/electron/main.js +15 -11
- package/lib/electron/plugins/meeting-state.d.ts +2 -0
- package/lib/electron/plugins/meeting-state.js +39 -0
- package/lib/electron/preload.js +2 -1
- package/lib/electron/tools.js +9 -0
- package/lib/electron/window.d.ts +1 -1
- package/lib/electron/window.js +14 -2
- package/lib/fragments/control-bar/context.d.ts +0 -1
- package/lib/fragments/control-bar/control-bar-store.d.ts +34 -1
- package/lib/fragments/control-bar/control-bar-store.js +394 -81
- package/lib/fragments/control-bar/device/index.js +12 -3
- package/lib/fragments/control-bar/index.css +15 -10
- package/lib/fragments/control-bar/index.js +19 -1
- package/lib/fragments/control-bar/meeting-details/meeting-detail.css +109 -0
- package/lib/fragments/control-bar/meeting-details/meeting-details-portal.d.ts +3 -0
- package/lib/fragments/control-bar/meeting-details/meeting-details-portal.js +60 -0
- package/lib/fragments/control-bar/meeting-details/meeting-details.d.ts +2 -0
- package/lib/fragments/control-bar/meeting-details/meeting-details.js +179 -0
- package/lib/fragments/control-bar/more-actions/index.css +53 -0
- package/lib/fragments/control-bar/more-actions/index.js +77 -37
- package/lib/fragments/control-bar/security-content/index.css +10 -0
- package/lib/fragments/control-bar/security-content/index.js +43 -18
- package/lib/fragments/control-bar/view.js +8 -2
- package/lib/fragments/live-streaming/context.d.ts +0 -1
- package/lib/fragments/live-streaming/store.js +27 -17
- package/lib/fragments/share-screen-selection/context.d.ts +0 -1
- package/lib/fragments/share-screen-selection/selection-store.d.ts +0 -1
- package/lib/fragments/share-screen-selection/selection-store.js +34 -33
- package/lib/fragments/share-screen-selection/view.js +7 -0
- package/lib/fragments/toolbar/components/color-picker/components/color.js +2 -0
- package/lib/fragments/toolbar/components/color-picker/components/panel.js +4 -0
- package/lib/fragments/toolbar/components/color-picker/components/picker.js +2 -0
- package/lib/fragments/toolbar/components/color-picker/index.js +5 -1
- package/lib/fragments/toolbar/components/color-picker.js +3 -1
- package/lib/fragments/toolbar/components/eraser-picker.js +4 -13
- package/lib/fragments/toolbar/components/extension-toolbar-item.js +5 -0
- package/lib/fragments/toolbar/components/extra-tool-picker.js +4 -0
- package/lib/fragments/toolbar/components/pen-picker.js +2 -0
- package/lib/fragments/toolbar/components/screen-capture-picker.js +2 -0
- package/lib/fragments/toolbar/components/shape-picker.js +2 -0
- package/lib/fragments/toolbar/hooks.d.ts +1 -1
- package/lib/fragments/toolbar/hooks.js +13 -8
- package/lib/fragments/toolbar/store.d.ts +4 -4
- package/lib/fragments/toolbar/store.js +20 -2
- package/lib/fragments/toolbar/view.js +2 -0
- package/lib/global.d.ts +1 -0
- package/lib/hooks/meeting-time.d.ts +2 -2
- package/lib/login-confirm-dialog.d.ts +12 -0
- package/lib/login-confirm-dialog.js +80 -0
- package/lib/modules/action-bar/action-bar-collapes-items.js +14 -5
- package/lib/modules/action-bar/chat/index.js +6 -6
- package/lib/modules/action-bar/context.d.ts +0 -1
- package/lib/modules/action-bar/device/index.css +7 -2
- package/lib/modules/action-bar/device/index.d.ts +2 -2
- package/lib/modules/action-bar/device/index.js +6 -4
- package/lib/modules/action-bar/index.css +63 -12
- package/lib/modules/action-bar/index.d.ts +3 -2
- package/lib/modules/action-bar/index.dev.js +8 -7
- package/lib/modules/action-bar/index.js +21 -0
- package/lib/modules/action-bar/item-placement.d.ts +1 -2
- package/lib/modules/action-bar/item.js +5 -0
- package/lib/modules/action-bar/leave/assign-host.d.ts +3 -1
- package/lib/modules/action-bar/leave/assign-host.js +7 -7
- package/lib/modules/action-bar/leave/index.js +35 -7
- package/lib/modules/action-bar/leave/leave-meeting.d.ts +11 -1
- package/lib/modules/action-bar/leave/leave-meeting.js +25 -16
- package/lib/modules/action-bar/more/poppover-content.d.ts +0 -1
- package/lib/modules/action-bar/more/poppover-content.js +14 -4
- package/lib/modules/action-bar/participants/index.css +12 -0
- package/lib/modules/action-bar/participants/index.js +21 -14
- package/lib/modules/action-bar/screen-share/index.js +5 -1
- package/lib/modules/action-bar/screen-share/submenu.js +17 -22
- package/lib/modules/action-bar/security/drop-menu.js +124 -14
- package/lib/modules/action-bar/security/index.js +1 -1
- package/lib/modules/action-bar/settings/index.js +1 -1
- package/lib/modules/action-bar/store.d.ts +45 -21
- package/lib/modules/action-bar/store.js +544 -134
- package/lib/modules/action-bar/view.js +65 -42
- package/lib/modules/audio-stream/index.js +12 -6
- package/lib/modules/chat/chat-bar/index.js +46 -27
- package/lib/modules/chat/chat-select/index.css +19 -4
- package/lib/modules/chat/chat-select/index.d.ts +0 -1
- package/lib/modules/chat/chat-select/index.js +29 -3
- package/lib/modules/chat/chat.d.ts +2 -3
- package/lib/modules/chat/chat.js +210 -107
- package/lib/modules/chat/contex.d.ts +0 -1
- package/lib/modules/chat/demo-wrapper.d.ts +0 -1
- package/lib/modules/chat/index.css +49 -0
- package/lib/modules/chat/index.d.ts +3 -3
- package/lib/modules/chat/index.dev.js +4 -4
- package/lib/modules/chat/index.js +32 -11
- package/lib/modules/chat/message-list.js +81 -49
- package/lib/modules/chat/store.d.ts +50 -4
- package/lib/modules/chat/store.js +303 -124
- package/lib/modules/chat/util.js +1 -1
- package/lib/modules/connection-gateway/components/phone/components/callinfo/index.js +2 -0
- package/lib/modules/connection-gateway/components/phone/index.js +2 -0
- package/lib/modules/connection-gateway/index.d.ts +3 -2
- package/lib/modules/connection-gateway/index.js +2 -0
- package/lib/modules/connection-gateway/store.d.ts +6 -4
- package/lib/modules/connection-gateway/store.js +46 -15
- package/lib/modules/device-pretest/audio-preview/microphone-detection.d.ts +1 -0
- package/lib/modules/device-pretest/audio-preview/microphone-detection.js +3 -2
- package/lib/modules/device-pretest/audio-preview/speaker-control.d.ts +0 -1
- package/lib/modules/device-pretest/audio-preview/speaker-control.js +1 -1
- package/lib/modules/device-pretest/context.d.ts +0 -1
- package/lib/modules/device-pretest/index.css +0 -4
- package/lib/modules/device-pretest/index.d.ts +0 -1
- package/lib/modules/device-pretest/index.js +2 -1
- package/lib/modules/device-pretest/settings/beauty.js +19 -6
- package/lib/modules/device-pretest/settings/video-effect.d.ts +0 -1
- package/lib/modules/device-pretest/settings/video-settings-basic.js +1 -0
- package/lib/modules/device-pretest/settings/virtual-background-setting.js +2 -0
- package/lib/modules/device-pretest/store.js +34 -19
- package/lib/modules/dialog/components/chat/electron.js +3 -2
- package/lib/modules/dialog/components/chat/index.js +1 -1
- package/lib/modules/dialog/components/confirm/electron.js +7 -5
- package/lib/modules/dialog/components/confirm/index.js +16 -2
- package/lib/modules/dialog/components/connection-gateway/electron.js +4 -2
- package/lib/modules/dialog/components/connection-gateway/index.css +0 -2
- package/lib/modules/dialog/components/device-setting/electron.d.ts +2 -0
- package/lib/modules/dialog/components/device-setting/electron.js +74 -0
- package/lib/modules/dialog/components/device-setting/index.css +26 -0
- package/lib/modules/dialog/components/device-setting/index.d.ts +4 -0
- package/lib/modules/dialog/components/device-setting/index.js +60 -0
- package/lib/modules/dialog/components/operation-waiting-room/electron.d.ts +5 -0
- package/lib/modules/dialog/components/operation-waiting-room/electron.js +89 -0
- package/lib/modules/dialog/components/operation-waiting-room/index.css +44 -0
- package/lib/modules/dialog/components/operation-waiting-room/index.d.ts +5 -0
- package/lib/modules/dialog/components/operation-waiting-room/index.js +156 -0
- package/lib/modules/dialog/components/participant/electron.js +8 -2
- package/lib/modules/dialog/components/remove-admit-waiting-room/electron.d.ts +5 -0
- package/lib/modules/dialog/components/remove-admit-waiting-room/electron.js +89 -0
- package/lib/modules/dialog/components/remove-admit-waiting-room/index.css +50 -0
- package/lib/modules/dialog/components/remove-admit-waiting-room/index.d.ts +5 -0
- package/lib/modules/dialog/components/remove-admit-waiting-room/index.js +90 -0
- package/lib/modules/dialog/components/share-screen-selection/index.js +1 -1
- package/lib/modules/dialog/components/whiteboard/index.js +2 -1
- package/lib/modules/dialog/context.d.ts +0 -1
- package/lib/modules/dialog/dialogs.d.ts +0 -2
- package/lib/modules/dialog/dialogs.js +62 -103
- package/lib/modules/dialog/index.css +7 -6
- package/lib/modules/dialog/index.d.ts +1 -1
- package/lib/modules/dialog/index.js +17 -0
- package/lib/modules/dialog/store.d.ts +6 -2
- package/lib/modules/dialog/store.js +52 -9
- package/lib/modules/dialog/view.js +2 -0
- package/lib/modules/event-notification/context.d.ts +2 -0
- package/lib/modules/event-notification/context.js +9 -0
- package/lib/modules/event-notification/index.css +58 -0
- package/lib/modules/event-notification/index.d.ts +13 -0
- package/lib/modules/event-notification/index.js +48 -0
- package/lib/modules/event-notification/store.d.ts +17 -0
- package/lib/modules/event-notification/store.js +133 -0
- package/lib/modules/event-notification/view.d.ts +5 -0
- package/lib/modules/event-notification/view.js +114 -0
- package/lib/modules/event-toast/context.d.ts +0 -1
- package/lib/modules/event-toast/store.js +16 -0
- package/lib/modules/invite/context.d.ts +0 -1
- package/lib/modules/invite/index.css +4 -4
- package/lib/modules/invite/index.d.ts +2 -2
- package/lib/modules/invite/pstn-invite.js +4 -1
- package/lib/modules/invite/store.d.ts +2 -2
- package/lib/modules/invite/store.js +27 -7
- package/lib/modules/invite/voip-invite.d.ts +0 -1
- package/lib/modules/invite/voip-invite.js +1 -1
- package/lib/modules/layout/components/Aside.d.ts +0 -1
- package/lib/modules/layout/components/Aside.js +4 -1
- package/lib/modules/layout/components/Carousel.js +6 -5
- package/lib/modules/layout/components/Gallery.js +16 -9
- package/lib/modules/layout/components/Layout.js +82 -57
- package/lib/modules/layout/components/index.css +42 -5
- package/lib/modules/layout/components/index.js +3 -0
- package/lib/modules/layout/context.d.ts +0 -1
- package/lib/modules/layout/index.css +30 -0
- package/lib/modules/layout/index.dev.js +11 -11
- package/lib/modules/layout/index.js +0 -6
- package/lib/modules/layout/member-window/index.css +5 -5
- package/lib/modules/layout/member-window/index.d.ts +7 -7
- package/lib/modules/layout/member-window/index.js +59 -13
- package/lib/modules/layout/store.d.ts +61 -50
- package/lib/modules/layout/store.js +517 -342
- package/lib/modules/layout/type.d.ts +2 -1
- package/lib/modules/layout/video-window-datasource.d.ts +14 -8
- package/lib/modules/layout/video-window-datasource.js +129 -78
- package/lib/modules/live-streaming/context.d.ts +0 -1
- package/lib/modules/live-streaming/index.d.ts +2 -2
- package/lib/modules/live-streaming/index.dev.js +5 -4
- package/lib/modules/live-streaming/store.d.ts +2 -2
- package/lib/modules/live-streaming/store.js +32 -11
- package/lib/modules/participant/attendee/index.d.ts +12 -3
- package/lib/modules/participant/attendee/index.js +142 -30
- package/lib/modules/participant/context.d.ts +0 -1
- package/lib/modules/participant/index.css +20 -0
- package/lib/modules/participant/index.d.ts +5 -2
- package/lib/modules/participant/index.dev.js +14 -12
- package/lib/modules/participant/index.js +27 -0
- package/lib/modules/participant/member-list-data-source.d.ts +3 -3
- package/lib/modules/participant/member-list-data-source.js +29 -3
- package/lib/modules/participant/room-control-drop-menu/index.css +37 -0
- package/lib/modules/participant/room-control-drop-menu/index.js +35 -1
- package/lib/modules/participant/store.d.ts +59 -34
- package/lib/modules/participant/store.js +541 -222
- package/lib/modules/participant/view.d.ts +6 -6
- package/lib/modules/participant/view.js +138 -34
- package/lib/modules/setting/audio-settings/audio-settings.js +16 -12
- package/lib/modules/setting/audio-settings/index.css +2 -2
- package/lib/modules/setting/context.d.ts +0 -1
- package/lib/modules/setting/general-settings/general-settings.js +2 -1
- package/lib/modules/setting/general-settings/index.css +2 -2
- package/lib/modules/setting/index.css +1 -5
- package/lib/modules/setting/index.d.ts +2 -2
- package/lib/modules/setting/index.dev.js +14 -12
- package/lib/modules/setting/index.js +16 -0
- package/lib/modules/setting/minutes-settings/index.css +65 -0
- package/lib/modules/setting/minutes-settings/minutes-settings.d.ts +4 -0
- package/lib/modules/setting/minutes-settings/minutes-settings.js +159 -0
- package/lib/modules/setting/state/index.css +0 -4
- package/lib/modules/setting/state/index.js +11 -1
- package/lib/modules/setting/storage-settings/storage-settings.js +1 -1
- package/lib/modules/setting/store.d.ts +7 -5
- package/lib/modules/setting/store.js +69 -46
- package/lib/modules/setting/translate-settings/index.css +45 -0
- package/lib/modules/setting/translate-settings/language-select.d.ts +12 -0
- package/lib/modules/setting/translate-settings/language-select.js +50 -0
- package/lib/modules/setting/translate-settings/translate-settings.d.ts +4 -0
- package/lib/modules/setting/translate-settings/translate-settings.js +139 -0
- package/lib/modules/setting/video-settings/index.css +15 -6
- package/lib/modules/setting/video-settings/video-settings-basic.js +3 -2
- package/lib/modules/setting/video-settings/video-settings.js +5 -1
- package/lib/modules/setting/view.js +34 -2
- package/lib/modules/share-screen/index.d.ts +4 -2
- package/lib/modules/share-screen/index.dev.js +17 -14
- package/lib/modules/share-screen/index.js +2 -0
- package/lib/modules/share-screen/selection/index.css +2 -0
- package/lib/modules/share-screen/selection/index.js +44 -6
- package/lib/modules/share-screen/share-state-bar/index.css +49 -11
- package/lib/modules/share-screen/share-state-bar/index.d.ts +0 -1
- package/lib/modules/share-screen/share-state-bar/index.js +51 -20
- package/lib/modules/share-screen/store.d.ts +23 -13
- package/lib/modules/share-screen/store.js +733 -606
- package/lib/modules/state-bar/context.d.ts +0 -1
- package/lib/modules/state-bar/index.css +2 -2
- package/lib/modules/state-bar/index.d.ts +2 -2
- package/lib/modules/state-bar/index.dev.js +12 -10
- package/lib/modules/state-bar/layout-config.js +2 -0
- package/lib/modules/state-bar/live-streaming-state.js +3 -0
- package/lib/modules/state-bar/meeting-detail.css +6 -4
- package/lib/modules/state-bar/meeting-details.js +29 -3
- package/lib/modules/state-bar/meeting-network-state.css +14 -3
- package/lib/modules/state-bar/meeting-network-state.js +10 -4
- package/lib/modules/state-bar/recording.js +9 -11
- package/lib/modules/state-bar/store.d.ts +7 -5
- package/lib/modules/state-bar/store.js +68 -8
- package/lib/modules/state-bar/view.js +4 -8
- package/lib/modules/video-window/context.d.ts +0 -1
- package/lib/modules/video-window/deviceState/index.d.ts +3 -3
- package/lib/modules/video-window/index.css +1 -0
- package/lib/modules/video-window/members/index.js +7 -4
- package/lib/modules/video-window/store.d.ts +5 -4
- package/lib/modules/video-window/store.js +49 -17
- package/lib/modules/video-window/topControl/index.js +7 -0
- package/lib/modules/video-window/view.js +2 -0
- package/lib/modules/waiting-room-layout/context.d.ts +2 -0
- package/lib/modules/waiting-room-layout/context.js +9 -0
- package/lib/modules/waiting-room-layout/index.css +71 -0
- package/lib/modules/waiting-room-layout/index.d.ts +8 -0
- package/lib/modules/waiting-room-layout/index.js +47 -0
- package/lib/modules/waiting-room-layout/store.d.ts +30 -0
- package/lib/modules/waiting-room-layout/store.js +189 -0
- package/lib/modules/waiting-room-layout/type.d.ts +0 -0
- package/lib/modules/waiting-room-layout/type.js +1 -0
- package/lib/modules/waiting-room-layout/view.d.ts +3 -0
- package/lib/modules/waiting-room-layout/view.js +67 -0
- package/lib/modules/whiteboard/app.js +2 -8
- package/lib/modules/whiteboard/components/control-bar/index.css +3 -0
- package/lib/modules/whiteboard/components/control-bar/store.d.ts +0 -1
- package/lib/modules/whiteboard/components/control-bar/store.js +29 -29
- package/lib/modules/whiteboard/components/loading/index.js +2 -2
- package/lib/modules/whiteboard/components/multi-window/index.js +8 -3
- package/lib/modules/whiteboard/components/pagination/store.d.ts +0 -1
- package/lib/modules/whiteboard/components/progress/electron.js +3 -2
- package/lib/modules/whiteboard/components/progress/style.css +4 -3
- package/lib/modules/whiteboard/components/switch-theme/index.css +4 -0
- package/lib/modules/whiteboard/components/switch-theme/index.d.ts +2 -1
- package/lib/modules/whiteboard/components/switch-theme/index.js +29 -17
- package/lib/modules/whiteboard/components/switch-theme/item.d.ts +1 -0
- package/lib/modules/whiteboard/components/switch-theme/item.js +11 -2
- package/lib/modules/whiteboard/components/switch-theme/libs.d.ts +2 -1
- package/lib/modules/whiteboard/components/switch-theme/libs.js +21 -20
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/panel.js +2 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/index.js +3 -1
- package/lib/modules/whiteboard/components/toolbar/components/eraser-picker.js +11 -9
- package/lib/modules/whiteboard/components/toolbar/components/extra-tool-picker.js +4 -0
- package/lib/modules/whiteboard/components/toolbar/components/move-handle.js +5 -0
- package/lib/modules/whiteboard/components/toolbar/components/pen-picker.js +2 -0
- package/lib/modules/whiteboard/components/toolbar/components/shape-picker.js +18 -12
- package/lib/modules/whiteboard/components/toolbar/hooks/index.d.ts +3 -3
- package/lib/modules/whiteboard/components/toolbar/hooks/index.js +16 -11
- package/lib/modules/whiteboard/components/toolbar/index.js +9 -0
- package/lib/modules/whiteboard/components/toolbar/store.d.ts +8 -7
- package/lib/modules/whiteboard/components/toolbar/store.js +25 -4
- package/lib/modules/whiteboard/context.d.ts +7 -3
- package/lib/modules/whiteboard/context.js +6 -4
- package/lib/modules/whiteboard/index.d.ts +6 -8
- package/lib/modules/whiteboard/index.js +310 -255
- package/lib/modules/whiteboard/type.d.ts +4 -12
- package/lib/modules/whiteboard/type.js +6 -16
- package/lib/modules/whiteboard/utils.d.ts +1 -0
- package/lib/modules/whiteboard/utils.js +12 -1
- package/lib/plugins/browser-runtime-plugin.js +2 -1
- package/lib/plugins/module-dev-plugin.js +12 -10
- package/lib/plugins/multi-lang-plugin.d.ts +1 -5
- package/lib/plugins/multi-lang-plugin.js +2 -0
- package/lib/runtime.d.ts +3 -5
- package/lib/translations/enUS.d.ts +590 -0
- package/lib/translations/enUS.js +608 -6
- package/lib/translations/zhCN.d.ts +588 -0
- package/lib/translations/zhCN.js +604 -4
- package/lib/type.d.ts +6 -2
- package/lib/ui-manager.d.ts +7 -3
- package/lib/ui-manager.js +597 -143
- package/lib/ui-scene.d.ts +1 -0
- package/lib/ui-scene.js +32 -22
- package/lib/utilities/board-context.d.ts +0 -1
- package/lib/utilities/constant.d.ts +47 -5
- package/lib/utilities/constant.js +44 -1
- package/lib/utilities/copyText.js +1 -1
- package/lib/utilities/extract.js +26 -3
- package/lib/utilities/hooks.js +2 -0
- package/lib/utilities/parameters.js +2 -2
- package/lib/utilities/renderer-event.js +28 -0
- package/lib/utilities/renderer.d.ts +1 -0
- package/lib/utilities/renderer.js +15 -6
- package/lib/utilities/tools.js +5 -2
- package/lib/utilities/ui-resources.d.ts +2 -2
- package/lib/utilities/ui-resources.js +20 -3
- package/lib/utilities/video-track-render-context.d.ts +0 -1
- package/package.json +17 -16
- package/public/assets/fcr_defaultpage.png +0 -0
- package/public/assets/login_confirm.png +0 -0
- package/public/index.html +29 -11
- package/lib/modules/device-pretest/settings/index.css +0 -15
- package/lib/modules/participant/attendee/participants-more-action.d.ts +0 -18
- package/lib/modules/participant/attendee/participants-more-action.js +0 -275
|
@@ -12,12 +12,15 @@ require("core-js/modules/es.number.constructor.js");
|
|
|
12
12
|
require("core-js/modules/es.object.create.js");
|
|
13
13
|
require("core-js/modules/es.object.define-property.js");
|
|
14
14
|
require("core-js/modules/es.object.get-own-property-descriptor.js");
|
|
15
|
+
require("core-js/modules/esnext.function.metadata.js");
|
|
16
|
+
require("core-js/modules/esnext.symbol.metadata.js");
|
|
15
17
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
16
18
|
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
17
19
|
Object.defineProperty(exports, "__esModule", {
|
|
18
20
|
value: true
|
|
19
21
|
});
|
|
20
22
|
exports["default"] = void 0;
|
|
23
|
+
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
21
24
|
require("core-js/modules/es.array.concat.js");
|
|
22
25
|
require("core-js/modules/es.array.filter.js");
|
|
23
26
|
require("core-js/modules/es.array.find.js");
|
|
@@ -36,19 +39,72 @@ require("core-js/modules/es.set.js");
|
|
|
36
39
|
require("core-js/modules/es.string.includes.js");
|
|
37
40
|
require("core-js/modules/es.string.iterator.js");
|
|
38
41
|
require("core-js/modules/es.weak-map.js");
|
|
42
|
+
require("core-js/modules/esnext.async-iterator.filter.js");
|
|
43
|
+
require("core-js/modules/esnext.async-iterator.find.js");
|
|
44
|
+
require("core-js/modules/esnext.async-iterator.for-each.js");
|
|
45
|
+
require("core-js/modules/esnext.async-iterator.map.js");
|
|
46
|
+
require("core-js/modules/esnext.async-iterator.some.js");
|
|
47
|
+
require("core-js/modules/esnext.iterator.constructor.js");
|
|
48
|
+
require("core-js/modules/esnext.iterator.filter.js");
|
|
49
|
+
require("core-js/modules/esnext.iterator.find.js");
|
|
50
|
+
require("core-js/modules/esnext.iterator.for-each.js");
|
|
51
|
+
require("core-js/modules/esnext.iterator.map.js");
|
|
52
|
+
require("core-js/modules/esnext.iterator.some.js");
|
|
53
|
+
require("core-js/modules/esnext.map.delete-all.js");
|
|
54
|
+
require("core-js/modules/esnext.map.emplace.js");
|
|
55
|
+
require("core-js/modules/esnext.map.every.js");
|
|
56
|
+
require("core-js/modules/esnext.map.filter.js");
|
|
57
|
+
require("core-js/modules/esnext.map.find.js");
|
|
58
|
+
require("core-js/modules/esnext.map.find-key.js");
|
|
59
|
+
require("core-js/modules/esnext.map.includes.js");
|
|
60
|
+
require("core-js/modules/esnext.map.key-of.js");
|
|
61
|
+
require("core-js/modules/esnext.map.map-keys.js");
|
|
62
|
+
require("core-js/modules/esnext.map.map-values.js");
|
|
63
|
+
require("core-js/modules/esnext.map.merge.js");
|
|
64
|
+
require("core-js/modules/esnext.map.reduce.js");
|
|
65
|
+
require("core-js/modules/esnext.map.some.js");
|
|
66
|
+
require("core-js/modules/esnext.map.update.js");
|
|
67
|
+
require("core-js/modules/esnext.set.add-all.js");
|
|
68
|
+
require("core-js/modules/esnext.set.delete-all.js");
|
|
69
|
+
require("core-js/modules/esnext.set.difference.v2.js");
|
|
70
|
+
require("core-js/modules/esnext.set.difference.js");
|
|
71
|
+
require("core-js/modules/esnext.set.every.js");
|
|
72
|
+
require("core-js/modules/esnext.set.filter.js");
|
|
73
|
+
require("core-js/modules/esnext.set.find.js");
|
|
74
|
+
require("core-js/modules/esnext.set.intersection.v2.js");
|
|
75
|
+
require("core-js/modules/esnext.set.intersection.js");
|
|
76
|
+
require("core-js/modules/esnext.set.is-disjoint-from.v2.js");
|
|
77
|
+
require("core-js/modules/esnext.set.is-disjoint-from.js");
|
|
78
|
+
require("core-js/modules/esnext.set.is-subset-of.v2.js");
|
|
79
|
+
require("core-js/modules/esnext.set.is-subset-of.js");
|
|
80
|
+
require("core-js/modules/esnext.set.is-superset-of.v2.js");
|
|
81
|
+
require("core-js/modules/esnext.set.is-superset-of.js");
|
|
82
|
+
require("core-js/modules/esnext.set.join.js");
|
|
83
|
+
require("core-js/modules/esnext.set.map.js");
|
|
84
|
+
require("core-js/modules/esnext.set.reduce.js");
|
|
85
|
+
require("core-js/modules/esnext.set.some.js");
|
|
86
|
+
require("core-js/modules/esnext.set.symmetric-difference.v2.js");
|
|
87
|
+
require("core-js/modules/esnext.set.symmetric-difference.js");
|
|
88
|
+
require("core-js/modules/esnext.set.union.v2.js");
|
|
89
|
+
require("core-js/modules/esnext.set.union.js");
|
|
90
|
+
require("core-js/modules/esnext.weak-map.delete-all.js");
|
|
91
|
+
require("core-js/modules/esnext.weak-map.emplace.js");
|
|
39
92
|
require("core-js/modules/web.dom-collections.for-each.js");
|
|
40
93
|
require("core-js/modules/web.dom-collections.iterator.js");
|
|
41
94
|
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
95
|
+
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
42
96
|
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
43
97
|
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
44
98
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
99
|
+
var _agoraEduCore = require("agora-edu-core");
|
|
45
100
|
var _type = require("agora-edu-core/lib/type");
|
|
101
|
+
var _constant = require("../../utilities/constant");
|
|
46
102
|
var _logger = require("agora-foundation/lib/logger");
|
|
47
103
|
var _type2 = require("agora-rte-sdk/lib/core/scene/type");
|
|
48
104
|
var _type3 = require("agora-rte-sdk/lib/type");
|
|
105
|
+
var _attendee = require("agora-ui-foundation/lib/components/participants/attendee");
|
|
49
106
|
var _toast = require("agora-ui-foundation/lib/components/toast");
|
|
50
107
|
var _mobx = require("mobx");
|
|
51
|
-
var _constant = require("../../utilities/constant");
|
|
52
108
|
var _decorator = require("agora-foundation/lib/decorator");
|
|
53
109
|
var _rendererEvent = require("../../utilities/renderer-event");
|
|
54
110
|
var _mobxUtils = require("mobx-utils");
|
|
@@ -56,10 +112,11 @@ var _memberListDataSource = require("./member-list-data-source");
|
|
|
56
112
|
var _type4 = require("./type");
|
|
57
113
|
var _i18n = require("agora-ui-foundation/lib/i18n");
|
|
58
114
|
var _i18n2 = require("../../hooks/i18n");
|
|
115
|
+
var _type5 = require("agora-edu-core/lib/room-control/user-control/type");
|
|
59
116
|
var _ParticipantStore;
|
|
60
|
-
var _initProto, _init__mainList, _init__participantsWindowActive, _init_currentPerspectiveType, _init_audioVolumeMap, _init_enableParticipantsJoinWithMute, _init_searchText, _init_currentModal, _init_localUserRole, _init_spotlightStreamId, _init_enableSpotlight, _init_mergeConfirmDialog, _init_mergeUserId,
|
|
61
|
-
function _classPrivateFieldInitSpec(
|
|
62
|
-
function _checkPrivateRedeclaration(
|
|
117
|
+
var _initProto, _init__mainList, _init__participantsWindowActive, _init_currentPerspectiveType, _init_audioVolumeMap, _init_enableParticipantsJoinWithMute, _init_searchText, _init_currentModal, _init_localUserRole, _init_spotlightStreamId, _init_enableSpotlight, _init_mergeConfirmDialog, _init_mergeUserId, _init_activeTab, _init_isNewWaitingRoomUserEnter, _init_waitingRoomUserCount, _setSpotlightStreamIdDecs, _setCurrentModalDecs, _openParticipantsWindowDecs, _setParticipantsWindowActiveDecs, _handlerSearchUserDecs, _getAllowedOperationsDecs, _closeRemoveAdmitWaitingRoomDialogDecs, _openRemoveAdmitWaitingRoomDialogDecs, _handlerUserActionDecs, _moveToWaitingRoomByUserIdsDecs, _removeWaitingRoomUserDecs, _kickOutWaitingRoomAllMemberDecs, _moveToMainRoomAllMemberDecs, _handlerRoomControlActionDecs, _handleEventDecs, _moveToMainRoomByUserIdsDecs, _handleActiveTabDecs, _initWaitingRoomUserListDecs, _kickOutUserDecs, _setAsAttendeeDecs, _onAudioVolumeUpdatedDecs, _handleRemoteUserJoinedDecs, _handleRemoteUserLeftDecs, _handleRemoteWaitingUserJoinedDecs, _handleRemoteWaitingUserLeftDecs, _onUserInfoUpdatedDecs, _initUserListDecs, _refreshCurrentPerspectiveTypeDecs, _onPeerSessionReceivedDecs, _updateLocalUserRoleDecs, _ref;
|
|
118
|
+
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
|
119
|
+
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
|
|
63
120
|
function _classPrivateFieldSet(s, a, r) { return s.set(_assertClassBrand(s, a), r), r; }
|
|
64
121
|
function _classPrivateFieldGet(s, a) { return s.get(_assertClassBrand(s, a)); }
|
|
65
122
|
function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n; throw new TypeError("Private element is not present on this object"); }
|
|
@@ -85,7 +142,10 @@ var _J = /*#__PURE__*/new WeakMap();
|
|
|
85
142
|
var _K = /*#__PURE__*/new WeakMap();
|
|
86
143
|
var _L = /*#__PURE__*/new WeakMap();
|
|
87
144
|
var _M = /*#__PURE__*/new WeakMap();
|
|
88
|
-
|
|
145
|
+
var _N = /*#__PURE__*/new WeakMap();
|
|
146
|
+
var _O = /*#__PURE__*/new WeakMap();
|
|
147
|
+
var _P = /*#__PURE__*/new WeakMap();
|
|
148
|
+
_ref = (_setSpotlightStreamIdDecs = [_mobx.action, _mobx.action.bound], _setCurrentModalDecs = [_mobx.action, _mobx.action.bound], _openParticipantsWindowDecs = [_mobx.action, _mobx.action.bound], _setParticipantsWindowActiveDecs = [_mobx.action, _mobx.action.bound], _handlerSearchUserDecs = [_mobx.action, _mobx.action.bound], _getAllowedOperationsDecs = [_mobx.action, _mobx.action.bound], _closeRemoveAdmitWaitingRoomDialogDecs = [_mobx.action, _mobx.action.bound], _openRemoveAdmitWaitingRoomDialogDecs = [_mobx.action, _mobx.action.bound], _handlerUserActionDecs = [_mobx.action, _mobx.action.bound], _moveToWaitingRoomByUserIdsDecs = [_mobx.action, _mobx.action.bound], _removeWaitingRoomUserDecs = [_mobx.action, _mobx.action.bound], _kickOutWaitingRoomAllMemberDecs = [_mobx.action, _mobx.action.bound], _moveToMainRoomAllMemberDecs = [_mobx.action, _mobx.action.bound], _handlerRoomControlActionDecs = [_mobx.action, _mobx.action.bound], _handleEventDecs = [_mobx.action, _mobx.action.bound], _moveToMainRoomByUserIdsDecs = [_mobx.action, _mobx.action.bound], _handleActiveTabDecs = [_mobx.action, _mobx.action.bound], _initWaitingRoomUserListDecs = [_mobx.action, _mobx.action.bound], _kickOutUserDecs = [_mobx.action, _mobx.action.bound], _setAsAttendeeDecs = [_mobx.action, _mobx.action.bound], _onAudioVolumeUpdatedDecs = [_mobx.action, _mobx.action.bound], _handleRemoteUserJoinedDecs = [_mobx.action, _mobx.action.bound], _handleRemoteUserLeftDecs = [_mobx.action, _mobx.action.bound], _handleRemoteWaitingUserJoinedDecs = [_mobx.action, _mobx.action.bound], _handleRemoteWaitingUserLeftDecs = [_mobx.action, _mobx.action.bound], _onUserInfoUpdatedDecs = [_mobx.action, _mobx.action.bound], _initUserListDecs = [_mobx.action, _mobx.action.bound], _refreshCurrentPerspectiveTypeDecs = [_mobx.action, _mobx.action.bound], _onPeerSessionReceivedDecs = [_mobx.action, _mobx.action.bound], _updateLocalUserRoleDecs = [_mobx.action, _mobx.action.bound], "logger");
|
|
89
149
|
var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
90
150
|
function ParticipantStore(_ref2) {
|
|
91
151
|
var _this = this;
|
|
@@ -99,27 +159,15 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
99
159
|
(0, _classCallCheck2["default"])(this, ParticipantStore);
|
|
100
160
|
(0, _defineProperty2["default"])(this, _ref, (_initProto(this), (0, _logger.getLogger)()));
|
|
101
161
|
(0, _defineProperty2["default"])(this, "_dataSource", new _memberListDataSource.FcrUIMemberListDataSourceImpl());
|
|
162
|
+
(0, _defineProperty2["default"])(this, "_waitingRoomDataSource", new _memberListDataSource.FcrUIMemberListDataSourceImpl());
|
|
102
163
|
(0, _defineProperty2["default"])(this, "_disposers", []);
|
|
103
164
|
(0, _defineProperty2["default"])(this, "_unmuteAudioTimestamp", new Map());
|
|
104
165
|
(0, _defineProperty2["default"])(this, "_unmuteVideoTimestamp", new Map());
|
|
105
|
-
_classPrivateFieldInitSpec(this, _B, _init__mainList(this, []));
|
|
106
|
-
_classPrivateFieldInitSpec(this, _C, _init__participantsWindowActive(this, false));
|
|
107
|
-
_classPrivateFieldInitSpec(this, _D, _init_currentPerspectiveType(this, 'attendee'));
|
|
108
|
-
_classPrivateFieldInitSpec(this, _E, _init_audioVolumeMap(this, new Map()));
|
|
109
|
-
_classPrivateFieldInitSpec(this, _A, _type.FcrMediaSourceState.STOPPED);
|
|
110
|
-
_classPrivateFieldInitSpec(this, _F, _init_enableParticipantsJoinWithMute(this, false));
|
|
111
|
-
_classPrivateFieldInitSpec(this, _G, _init_searchText(this, ''));
|
|
112
|
-
_classPrivateFieldInitSpec(this, _H, _init_currentModal(this, 'modal'));
|
|
113
|
-
_classPrivateFieldInitSpec(this, _I, _init_localUserRole(this));
|
|
114
|
-
_classPrivateFieldInitSpec(this, _J, _init_spotlightStreamId(this, ''));
|
|
115
|
-
_classPrivateFieldInitSpec(this, _K, _init_enableSpotlight(this, true));
|
|
116
|
-
_classPrivateFieldInitSpec(this, _L, _init_mergeConfirmDialog(this, false));
|
|
117
|
-
_classPrivateFieldInitSpec(this, _M, _init_mergeUserId(this, ''));
|
|
118
166
|
(0, _defineProperty2["default"])(this, "_processedUserOpenDeviceRequests", new Set());
|
|
119
167
|
(0, _defineProperty2["default"])(this, "_streamsObserver", {
|
|
120
168
|
onStreamsAdded: this._handleStreamsAdded,
|
|
121
169
|
onStreamsUpdated: this._handleStreamsUpdated,
|
|
122
|
-
|
|
170
|
+
onStreamVolumeIndicationUpdated: this._onAudioVolumeUpdated,
|
|
123
171
|
onStreamsRemoved: this._handleStreamsRemoved
|
|
124
172
|
});
|
|
125
173
|
(0, _defineProperty2["default"])(this, "_peerSessionObserver", {
|
|
@@ -135,11 +183,38 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
135
183
|
(0, _defineProperty2["default"])(this, "_eventObserver", {
|
|
136
184
|
onEvent: this._handleEvent
|
|
137
185
|
});
|
|
186
|
+
(0, _defineProperty2["default"])(this, "_waitingRoomUserObserver", {
|
|
187
|
+
onRemoteUsersJoined: this._handleRemoteWaitingUserJoined.bind(this),
|
|
188
|
+
onRemoteUsersLeft: this._handleRemoteWaitingUserLeft.bind(this)
|
|
189
|
+
});
|
|
138
190
|
(0, _defineProperty2["default"])(this, "_whitebaordObderver", {
|
|
139
|
-
|
|
140
|
-
_this._updateUserBoardState(
|
|
191
|
+
onActive: function onActive(ownerId, operatorUser) {
|
|
192
|
+
_this._updateUserBoardState(operatorUser);
|
|
193
|
+
},
|
|
194
|
+
onInactive: function onInactive(reason, operatorUser) {
|
|
195
|
+
_this._updateUserBoardState(operatorUser);
|
|
141
196
|
}
|
|
142
197
|
});
|
|
198
|
+
_classPrivateFieldInitSpec(this, _B, _init__mainList(this, []));
|
|
199
|
+
_classPrivateFieldInitSpec(this, _C, _init__participantsWindowActive(this, false));
|
|
200
|
+
_classPrivateFieldInitSpec(this, _D, _init_currentPerspectiveType(this, 'attendee'));
|
|
201
|
+
_classPrivateFieldInitSpec(this, _E, _init_audioVolumeMap(this, new Map()));
|
|
202
|
+
_classPrivateFieldInitSpec(this, _A, _agoraEduCore.FcrMediaSourceState.STOPPED);
|
|
203
|
+
_classPrivateFieldInitSpec(this, _F, _init_enableParticipantsJoinWithMute(this, false));
|
|
204
|
+
_classPrivateFieldInitSpec(this, _G, _init_searchText(this, ''));
|
|
205
|
+
_classPrivateFieldInitSpec(this, _H, _init_currentModal(this, 'modal'));
|
|
206
|
+
_classPrivateFieldInitSpec(this, _I, _init_localUserRole(this));
|
|
207
|
+
_classPrivateFieldInitSpec(this, _J, _init_spotlightStreamId(this, ''));
|
|
208
|
+
_classPrivateFieldInitSpec(this, _K, _init_enableSpotlight(this, true));
|
|
209
|
+
_classPrivateFieldInitSpec(this, _L, _init_mergeConfirmDialog(this, false));
|
|
210
|
+
_classPrivateFieldInitSpec(this, _M, _init_mergeUserId(this, ''));
|
|
211
|
+
_classPrivateFieldInitSpec(this, _N, _init_activeTab(this, _constant.RoomType.MAIN_ROOM));
|
|
212
|
+
_classPrivateFieldInitSpec(this, _O, _init_isNewWaitingRoomUserEnter(this, false));
|
|
213
|
+
_classPrivateFieldInitSpec(this, _P, _init_waitingRoomUserCount(this, 0));
|
|
214
|
+
(0, _defineProperty2["default"])(this, "allowedOperations", (0, _mobxUtils.computedFn)(function (userId, userRole) {
|
|
215
|
+
var _this$_userControl$ge;
|
|
216
|
+
return _this.getAllowedOperations(userRole, userId === ((_this$_userControl$ge = _this._userControl.getLocalUser()) === null || _this$_userControl$ge === void 0 ? void 0 : _this$_userControl$ge.userId));
|
|
217
|
+
}));
|
|
143
218
|
(0, _defineProperty2["default"])(this, "checkIsPin", (0, _mobxUtils.computedFn)(function (userId) {
|
|
144
219
|
var _this$userMap$get;
|
|
145
220
|
return !!((_this$userMap$get = _this.userMap.get(userId)) !== null && _this$userMap$get !== void 0 && _this$userMap$get.streams.some(function (stream) {
|
|
@@ -147,30 +222,30 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
147
222
|
}));
|
|
148
223
|
}));
|
|
149
224
|
(0, _defineProperty2["default"])(this, "_formatUser", function (user) {
|
|
150
|
-
var _this$_userControl$
|
|
225
|
+
var _this$_userControl$ge2;
|
|
151
226
|
var targetUsers = user.streams;
|
|
152
227
|
var hasShareScreen = targetUsers.find(function (user) {
|
|
153
228
|
return user.videoSourceType === _type3.AgoraRteVideoSourceType.SCREEN;
|
|
154
229
|
});
|
|
155
230
|
var isSelf = user.userId === _this._userControl.getLocalUser().userId;
|
|
156
231
|
var hasAudioPublishedAndStarted = function hasAudioPublishedAndStarted(stream) {
|
|
157
|
-
return (stream === null || stream === void 0 ? void 0 : stream.audioSourceState) ===
|
|
232
|
+
return (stream === null || stream === void 0 ? void 0 : stream.audioSourceState) === _agoraEduCore.FcrMediaSourceState.STARTED && ((stream === null || stream === void 0 ? void 0 : stream.streamType) === _type2.AgoraRteMediaStreamType.AUDIO || (stream === null || stream === void 0 ? void 0 : stream.streamType) === _type2.AgoraRteMediaStreamType.BOTH);
|
|
158
233
|
};
|
|
159
234
|
var hasVideoPublishedAndStarted = function hasVideoPublishedAndStarted(stream) {
|
|
160
|
-
return (stream === null || stream === void 0 ? void 0 : stream.videoSourceState) ===
|
|
235
|
+
return (stream === null || stream === void 0 ? void 0 : stream.videoSourceState) === _agoraEduCore.FcrMediaSourceState.STARTED && ((stream === null || stream === void 0 ? void 0 : stream.streamType) === _type2.AgoraRteMediaStreamType.VIDEO || (stream === null || stream === void 0 ? void 0 : stream.streamType) === _type2.AgoraRteMediaStreamType.BOTH);
|
|
161
236
|
};
|
|
162
237
|
var hasAudio = false;
|
|
163
238
|
var hasVideo = false;
|
|
164
239
|
var audioDeviceType = 'none';
|
|
165
240
|
var videoDeviceType = 'none';
|
|
166
241
|
var userType = 'normal';
|
|
167
|
-
if (user.userInfo.connectorType ===
|
|
242
|
+
if (user.userInfo.connectorType === _agoraEduCore.FcrRoomConnectorType.NONE) {
|
|
168
243
|
var defaultStream = targetUsers.find(function (user) {
|
|
169
244
|
return user.videoSourceType === _type3.AgoraRteVideoSourceType.CAMERA;
|
|
170
245
|
});
|
|
171
246
|
var pstnStream = targetUsers.find(function (_ref3) {
|
|
172
247
|
var connectorType = _ref3.connectorType;
|
|
173
|
-
return connectorType ==
|
|
248
|
+
return connectorType == _agoraEduCore.FcrRoomConnectorType.PSTN;
|
|
174
249
|
});
|
|
175
250
|
videoDeviceType = 'computer-cam';
|
|
176
251
|
hasVideo = isSelf ? _this._deviceStore.cameraEnabled : hasVideoPublishedAndStarted(defaultStream);
|
|
@@ -189,10 +264,10 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
189
264
|
}
|
|
190
265
|
}
|
|
191
266
|
// 2.sip user with camera and phone mic
|
|
192
|
-
else if ([
|
|
267
|
+
else if ([_agoraEduCore.FcrRoomConnectorType.SIP, _agoraEduCore.FcrRoomConnectorType.H323].includes(user.userInfo.connectorType)) {
|
|
193
268
|
var firstSipOrH323Stream = targetUsers.find(function (_ref4) {
|
|
194
269
|
var connectorType = _ref4.connectorType;
|
|
195
|
-
return [
|
|
270
|
+
return [_agoraEduCore.FcrRoomConnectorType.SIP, _agoraEduCore.FcrRoomConnectorType.H323].includes(connectorType);
|
|
196
271
|
});
|
|
197
272
|
audioDeviceType = 'phone-mic';
|
|
198
273
|
videoDeviceType = 'computer-cam';
|
|
@@ -201,10 +276,10 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
201
276
|
hasVideo = hasVideoPublishedAndStarted(firstSipOrH323Stream);
|
|
202
277
|
}
|
|
203
278
|
// 3.phone user with no camera and phone mic
|
|
204
|
-
else if (user.userInfo.connectorType ===
|
|
279
|
+
else if (user.userInfo.connectorType === _agoraEduCore.FcrRoomConnectorType.PSTN) {
|
|
205
280
|
var _pstnStream = targetUsers.find(function (_ref5) {
|
|
206
281
|
var connectorType = _ref5.connectorType;
|
|
207
|
-
return connectorType ==
|
|
282
|
+
return connectorType == _agoraEduCore.FcrRoomConnectorType.PSTN;
|
|
208
283
|
});
|
|
209
284
|
audioDeviceType = 'phone-mic';
|
|
210
285
|
userType = 'phone';
|
|
@@ -218,7 +293,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
218
293
|
userId: user.userId,
|
|
219
294
|
userName: user.userInfo.userName,
|
|
220
295
|
isHost: user.userInfo.userRole === _type.FcrUserRole.HOST,
|
|
221
|
-
isMe: user.userId === ((_this$_userControl$
|
|
296
|
+
isMe: user.userId === ((_this$_userControl$ge2 = _this._userControl.getLocalUser()) === null || _this$_userControl$ge2 === void 0 ? void 0 : _this$_userControl$ge2.userId),
|
|
222
297
|
hasAudio: hasAudio,
|
|
223
298
|
hasVideo: hasVideo,
|
|
224
299
|
isScreenSharing: !!hasShareScreen,
|
|
@@ -227,7 +302,9 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
227
302
|
userType: userType,
|
|
228
303
|
userRole: user.userInfo.userRole,
|
|
229
304
|
isSpotlight: isSpotlight,
|
|
230
|
-
isBoardActive: user.userInfo.isBoardActive
|
|
305
|
+
isBoardActive: user.userInfo.isBoardActive,
|
|
306
|
+
allowedOperations: _this.allowedOperations(user.userId, user.userInfo.userRole),
|
|
307
|
+
isPin: _this.checkIsPin(user.userId)
|
|
231
308
|
};
|
|
232
309
|
});
|
|
233
310
|
this._roomControl = roomControl;
|
|
@@ -239,7 +316,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
239
316
|
this._userControl.addObserver(this._userObserver);
|
|
240
317
|
this._streamControl.addObserver(this._streamsObserver);
|
|
241
318
|
this._peerSessionControl.addObserver(this._peerSessionObserver);
|
|
242
|
-
this._roomControl.
|
|
319
|
+
this._roomControl.getBoardControl().addObserver(this._whitebaordObderver);
|
|
243
320
|
this._securityStore = securityStore;
|
|
244
321
|
this._uiEventStore = uiEventStore;
|
|
245
322
|
this._deviceStore = deviceStore;
|
|
@@ -354,24 +431,37 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
354
431
|
_classPrivateFieldSet(_M, this, v);
|
|
355
432
|
}
|
|
356
433
|
}, {
|
|
357
|
-
key: "
|
|
358
|
-
|
|
359
|
-
|
|
434
|
+
key: "activeTab",
|
|
435
|
+
get: function get() {
|
|
436
|
+
return _classPrivateFieldGet(_N, this);
|
|
437
|
+
},
|
|
438
|
+
set: function set(v) {
|
|
439
|
+
_classPrivateFieldSet(_N, this, v);
|
|
360
440
|
}
|
|
361
441
|
}, {
|
|
362
|
-
key: "
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
442
|
+
key: "isNewWaitingRoomUserEnter",
|
|
443
|
+
get: function get() {
|
|
444
|
+
return _classPrivateFieldGet(_O, this);
|
|
445
|
+
},
|
|
446
|
+
set: function set(v) {
|
|
447
|
+
_classPrivateFieldSet(_O, this, v);
|
|
448
|
+
}
|
|
449
|
+
}, {
|
|
450
|
+
key: "waitingRoomUserCount",
|
|
451
|
+
get: function get() {
|
|
452
|
+
return _classPrivateFieldGet(_P, this);
|
|
453
|
+
},
|
|
454
|
+
set: function set(v) {
|
|
455
|
+
_classPrivateFieldSet(_P, this, v);
|
|
370
456
|
}
|
|
371
457
|
}, {
|
|
372
458
|
key: "userListSource",
|
|
373
459
|
get: function get() {
|
|
374
|
-
|
|
460
|
+
if (this.activeTab === _constant.RoomType.MAIN_ROOM) {
|
|
461
|
+
return this._dataSource.list;
|
|
462
|
+
} else {
|
|
463
|
+
return this._waitingRoomDataSource.list;
|
|
464
|
+
}
|
|
375
465
|
}
|
|
376
466
|
}, {
|
|
377
467
|
key: "mergeUserInfo",
|
|
@@ -447,11 +537,56 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
447
537
|
return i.isPin;
|
|
448
538
|
});
|
|
449
539
|
}
|
|
540
|
+
}, {
|
|
541
|
+
key: "userList",
|
|
542
|
+
get: function get() {
|
|
543
|
+
var _this3 = this;
|
|
544
|
+
var list = this.userListSource;
|
|
545
|
+
if (this.searchText.length) {
|
|
546
|
+
list = list.filter(function (user) {
|
|
547
|
+
return user.userInfo.userName.toLocaleLowerCase().includes(_this3.searchText.toLocaleLowerCase());
|
|
548
|
+
});
|
|
549
|
+
}
|
|
550
|
+
var uiDataList = list.map(function (user) {
|
|
551
|
+
return _this3._formatUser(user);
|
|
552
|
+
});
|
|
553
|
+
return uiDataList;
|
|
554
|
+
}
|
|
555
|
+
}, {
|
|
556
|
+
key: "localMicVolume",
|
|
557
|
+
get: function get() {
|
|
558
|
+
return this._deviceStore.microphoneVolumeLevel;
|
|
559
|
+
}
|
|
560
|
+
}, {
|
|
561
|
+
key: "hasRevokeHostPermission",
|
|
562
|
+
get: function get() {
|
|
563
|
+
return this._securityStore.hasRevokeHostPermission() && this.localUserRole !== _type.FcrUserRole.HOST;
|
|
564
|
+
}
|
|
565
|
+
}, {
|
|
566
|
+
key: "setSpotlightStreamId",
|
|
567
|
+
value: function setSpotlightStreamId(streamId) {
|
|
568
|
+
this.spotlightStreamId = streamId;
|
|
569
|
+
}
|
|
570
|
+
}, {
|
|
571
|
+
key: "release",
|
|
572
|
+
value: function release() {
|
|
573
|
+
this._userControl.removeObserver(this._userObserver);
|
|
574
|
+
this._streamControl.removeObserver(this._streamsObserver);
|
|
575
|
+
this._uiEventStore.removeObserver(this._eventObserver);
|
|
576
|
+
this._disposers.forEach(function (disposer) {
|
|
577
|
+
return disposer();
|
|
578
|
+
});
|
|
579
|
+
}
|
|
450
580
|
}, {
|
|
451
581
|
key: "hasMutePermission",
|
|
452
582
|
value: function hasMutePermission(targetRole) {
|
|
453
583
|
return this._securityStore.hasMutePermission(targetRole);
|
|
454
584
|
}
|
|
585
|
+
}, {
|
|
586
|
+
key: "hasWaitingRoomPermission",
|
|
587
|
+
value: function hasWaitingRoomPermission() {
|
|
588
|
+
return this._securityStore.isWaitingRoomEnabled() && this._securityStore.hasWaitingRoomPermission();
|
|
589
|
+
}
|
|
455
590
|
}, {
|
|
456
591
|
key: "hasUnmutePermission",
|
|
457
592
|
value: function hasUnmutePermission(targetRole) {
|
|
@@ -462,28 +597,6 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
462
597
|
value: function hasRequestStartAudioPermission(targetRole) {
|
|
463
598
|
return this._securityStore.hasRequestStartAudioPermission(targetRole);
|
|
464
599
|
}
|
|
465
|
-
}, {
|
|
466
|
-
key: "_handleEvent",
|
|
467
|
-
value: function _handleEvent(action, payload) {
|
|
468
|
-
if (action === _constant.UIAction.MAIN_LIST_CHANGED) {
|
|
469
|
-
this._mainList = payload || [];
|
|
470
|
-
}
|
|
471
|
-
if (action === _constant.UIAction.SPOTLIGHT_STREAM_CHANGED) {
|
|
472
|
-
var _ref6 = payload,
|
|
473
|
-
type = _ref6.type,
|
|
474
|
-
streamId = _ref6.streamId;
|
|
475
|
-
if (type === 'add') {
|
|
476
|
-
this.setSpotlightStreamId(streamId);
|
|
477
|
-
} else {
|
|
478
|
-
this.setSpotlightStreamId('');
|
|
479
|
-
}
|
|
480
|
-
}
|
|
481
|
-
if (action === _constant.UIAction.CUSTOM_SETTINGS_CHANGED) {
|
|
482
|
-
var _ref7 = payload,
|
|
483
|
-
spotlightEnabled = _ref7.spotlightEnabled;
|
|
484
|
-
this.enableSpotlight = spotlightEnabled;
|
|
485
|
-
}
|
|
486
|
-
}
|
|
487
600
|
}, {
|
|
488
601
|
key: "setCurrentModal",
|
|
489
602
|
value: function setCurrentModal(modal) {
|
|
@@ -529,7 +642,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
529
642
|
}, {
|
|
530
643
|
key: "openConfirmDialog",
|
|
531
644
|
value: function openConfirmDialog(params, id) {
|
|
532
|
-
var
|
|
645
|
+
var _this4 = this;
|
|
533
646
|
var title = params.title,
|
|
534
647
|
content = params.content,
|
|
535
648
|
_onOk = params.onOk,
|
|
@@ -545,30 +658,15 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
545
658
|
cancelText: cancelText,
|
|
546
659
|
height: height,
|
|
547
660
|
onCancel: function onCancel() {
|
|
548
|
-
|
|
661
|
+
_this4._uiEventStore.closeDialog(dialogKey);
|
|
549
662
|
_onCancel && _onCancel();
|
|
550
663
|
},
|
|
551
664
|
onOk: function onOk() {
|
|
552
|
-
|
|
665
|
+
_this4._uiEventStore.closeDialog(dialogKey);
|
|
553
666
|
_onOk();
|
|
554
667
|
}
|
|
555
668
|
});
|
|
556
669
|
}
|
|
557
|
-
}, {
|
|
558
|
-
key: "userList",
|
|
559
|
-
get: function get() {
|
|
560
|
-
var _this4 = this;
|
|
561
|
-
var list = this.userListSource;
|
|
562
|
-
if (this.searchText.length) {
|
|
563
|
-
list = list.filter(function (user) {
|
|
564
|
-
return user.userInfo.userName.toLocaleLowerCase().includes(_this4.searchText.toLocaleLowerCase());
|
|
565
|
-
});
|
|
566
|
-
}
|
|
567
|
-
var uiDataList = list.map(function (user) {
|
|
568
|
-
return _this4._formatUser(user);
|
|
569
|
-
});
|
|
570
|
-
return uiDataList;
|
|
571
|
-
}
|
|
572
670
|
}, {
|
|
573
671
|
key: "setParticipantsWindowActive",
|
|
574
672
|
value: function setParticipantsWindowActive(active) {
|
|
@@ -596,7 +694,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
596
694
|
key: "mergeConfirmDialogOk",
|
|
597
695
|
value: function mergeConfirmDialogOk(userId) {
|
|
598
696
|
var _this$userMap$get2;
|
|
599
|
-
this.
|
|
697
|
+
this._streamControl.mergeAudioStream(userId);
|
|
600
698
|
this.setMergeConfirmDialog(false);
|
|
601
699
|
_toast.FcrToastApi.open({
|
|
602
700
|
id: 'mergeVideo',
|
|
@@ -609,65 +707,222 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
609
707
|
duration: 3000
|
|
610
708
|
});
|
|
611
709
|
}
|
|
710
|
+
}, {
|
|
711
|
+
key: "removePin",
|
|
712
|
+
value: function removePin(userId) {
|
|
713
|
+
var _this$userMap$get3;
|
|
714
|
+
var streamId = (_this$userMap$get3 = this.userMap.get(userId)) === null || _this$userMap$get3 === void 0 || (_this$userMap$get3 = _this$userMap$get3.streams.find(function (stream) {
|
|
715
|
+
return stream.videoSourceType === _type3.AgoraRteVideoSourceType.CAMERA;
|
|
716
|
+
})) === null || _this$userMap$get3 === void 0 ? void 0 : _this$userMap$get3.streamId;
|
|
717
|
+
if (streamId) {
|
|
718
|
+
this._uiEventStore.sendEvent(_constant.UIAction.VIDEO_WINDOW_PIN_ACTION, {
|
|
719
|
+
action: _constant.VideoWindowPinType.REMOVE_PIN,
|
|
720
|
+
streamId: streamId
|
|
721
|
+
});
|
|
722
|
+
}
|
|
723
|
+
}
|
|
724
|
+
}, {
|
|
725
|
+
key: "addPin",
|
|
726
|
+
value: function addPin(userId) {
|
|
727
|
+
var _this$userMap$get4;
|
|
728
|
+
var streamId = (_this$userMap$get4 = this.userMap.get(userId)) === null || _this$userMap$get4 === void 0 || (_this$userMap$get4 = _this$userMap$get4.streams.find(function (stream) {
|
|
729
|
+
return stream.videoSourceType === _type3.AgoraRteVideoSourceType.CAMERA;
|
|
730
|
+
})) === null || _this$userMap$get4 === void 0 ? void 0 : _this$userMap$get4.streamId;
|
|
731
|
+
if (streamId) {
|
|
732
|
+
this._uiEventStore.sendEvent(_constant.UIAction.VIDEO_WINDOW_PIN_ACTION, {
|
|
733
|
+
action: _constant.VideoWindowPinType.ADD_PIN,
|
|
734
|
+
streamId: streamId
|
|
735
|
+
});
|
|
736
|
+
}
|
|
737
|
+
}
|
|
738
|
+
}, {
|
|
739
|
+
key: "getAllowedOperations",
|
|
740
|
+
value: function getAllowedOperations(targetRole, isSelf) {
|
|
741
|
+
return this._securityStore.getAllowedOperations(targetRole, isSelf);
|
|
742
|
+
}
|
|
743
|
+
}, {
|
|
744
|
+
key: "closeRemoveAdmitWaitingRoomDialog",
|
|
745
|
+
value: function closeRemoveAdmitWaitingRoomDialog(dialogKey) {
|
|
746
|
+
this._uiEventStore.closeRemoveAdmitWaitingRoomDialog(dialogKey);
|
|
747
|
+
}
|
|
748
|
+
}, {
|
|
749
|
+
key: "openRemoveAdmitWaitingRoomDialog",
|
|
750
|
+
value: function openRemoveAdmitWaitingRoomDialog(dialogKey, params) {
|
|
751
|
+
this._uiEventStore.openDialog(dialogKey, '', {
|
|
752
|
+
userId: params.userId,
|
|
753
|
+
type: params.type,
|
|
754
|
+
title: params.title,
|
|
755
|
+
tooltip: params.tooltip
|
|
756
|
+
});
|
|
757
|
+
}
|
|
612
758
|
}, {
|
|
613
759
|
key: "handlerUserAction",
|
|
614
760
|
value: function handlerUserAction(action, userId) {
|
|
615
761
|
switch (action) {
|
|
616
|
-
case
|
|
762
|
+
case _attendee.ParticipantActionType.MUTE_AUDIO:
|
|
617
763
|
this._muteUserAudio(userId);
|
|
618
764
|
break;
|
|
619
|
-
case
|
|
765
|
+
case _attendee.ParticipantActionType.UNMUTE_AUDIO:
|
|
620
766
|
this._unmuteUserAudio(userId);
|
|
621
767
|
break;
|
|
622
|
-
case
|
|
768
|
+
case _attendee.ParticipantActionType.MUTE_VIDEO:
|
|
623
769
|
this._muteUserVideo(userId);
|
|
624
770
|
break;
|
|
625
|
-
case
|
|
771
|
+
case _attendee.ParticipantActionType.UNMUTE_VIDEO:
|
|
626
772
|
this._unmuteUserVideo(userId);
|
|
627
773
|
break;
|
|
628
|
-
case
|
|
774
|
+
case _attendee.ParticipantActionType.PRIVATE_CHAT:
|
|
629
775
|
this._privateChat(userId);
|
|
630
776
|
break;
|
|
631
|
-
case
|
|
632
|
-
this.
|
|
777
|
+
case _attendee.ParticipantActionType.KICK_OUT:
|
|
778
|
+
if (this.activeTab === _constant.RoomType.MAIN_ROOM) {
|
|
779
|
+
this._kickOutUser(userId);
|
|
780
|
+
} else {
|
|
781
|
+
var _this$userMap$get5;
|
|
782
|
+
this.openRemoveAdmitWaitingRoomDialog(_constant.DialogKey.WAITING_ROOM_SINGLE_REMOVE, {
|
|
783
|
+
userId: userId,
|
|
784
|
+
type: 'remove',
|
|
785
|
+
title: (0, _i18n.transI18n)('fmt_waitingroom_sidebar_popup_removeall'),
|
|
786
|
+
tooltip: (0, _i18n.transI18n)('fmt_waitingroom_sidebar_popup_label_remove', {
|
|
787
|
+
reason1: (_this$userMap$get5 = this.userMap.get(userId)) === null || _this$userMap$get5 === void 0 ? void 0 : _this$userMap$get5.userInfo.userName
|
|
788
|
+
})
|
|
789
|
+
});
|
|
790
|
+
}
|
|
633
791
|
break;
|
|
634
|
-
case
|
|
792
|
+
case _attendee.ParticipantActionType.ADD_PIN:
|
|
635
793
|
this.addPin(userId);
|
|
636
794
|
break;
|
|
637
|
-
case
|
|
795
|
+
case _attendee.ParticipantActionType.REMOVE_PIN:
|
|
638
796
|
this.removePin(userId);
|
|
639
797
|
break;
|
|
640
|
-
case
|
|
798
|
+
case _attendee.ParticipantActionType.SET_AS_HOST:
|
|
641
799
|
this._setAsHost(userId);
|
|
642
800
|
break;
|
|
643
|
-
case
|
|
801
|
+
case _attendee.ParticipantActionType.RENAME:
|
|
644
802
|
break;
|
|
645
|
-
case
|
|
803
|
+
case _attendee.ParticipantActionType.SET_MAIN_SPEAKER:
|
|
646
804
|
this._uiEventStore.setMainSpeaker({
|
|
647
805
|
userId: userId
|
|
648
806
|
});
|
|
649
807
|
break;
|
|
650
|
-
case
|
|
808
|
+
case _attendee.ParticipantActionType.SET_AS_CO_HOST:
|
|
651
809
|
this._setAsCoHost(userId);
|
|
652
810
|
break;
|
|
653
|
-
case
|
|
811
|
+
case _attendee.ParticipantActionType.SET_AS_ATTENDEE:
|
|
654
812
|
this._setAsAttendee(userId);
|
|
655
813
|
break;
|
|
656
|
-
case
|
|
814
|
+
case _attendee.ParticipantActionType.MERGE_VIDEO:
|
|
657
815
|
this.setMergeConfirmDialog(true);
|
|
658
816
|
this.mergeUserId = userId;
|
|
817
|
+
break;
|
|
818
|
+
case _attendee.ParticipantActionType.PUT_IN_WAITING_ROOM:
|
|
819
|
+
this._moveToWaitingRoomByUserIds(userId);
|
|
820
|
+
break;
|
|
659
821
|
}
|
|
660
822
|
}
|
|
823
|
+
}, {
|
|
824
|
+
key: "_moveToWaitingRoomByUserIds",
|
|
825
|
+
value: function () {
|
|
826
|
+
var _moveToWaitingRoomByUserIds2 = (0, _asyncToGenerator2["default"])(/*#__PURE__*/_regenerator["default"].mark(function _callee(userId) {
|
|
827
|
+
var _this$userMap$get6;
|
|
828
|
+
var username;
|
|
829
|
+
return _regenerator["default"].wrap(function _callee$(_context) {
|
|
830
|
+
while (1) switch (_context.prev = _context.next) {
|
|
831
|
+
case 0:
|
|
832
|
+
username = (_this$userMap$get6 = this.userMap.get(userId)) === null || _this$userMap$get6 === void 0 ? void 0 : _this$userMap$get6.userInfo.userName;
|
|
833
|
+
_context.prev = 1;
|
|
834
|
+
_context.next = 4;
|
|
835
|
+
return this._roomControl.moveToWaitingRoomByUserIds([userId]);
|
|
836
|
+
case 4:
|
|
837
|
+
this._uiEventStore.showToast({
|
|
838
|
+
type: 'normal',
|
|
839
|
+
message: (0, _i18n.transI18n)('fmt_waitingroom_put_in_success', {
|
|
840
|
+
reason1: username
|
|
841
|
+
})
|
|
842
|
+
});
|
|
843
|
+
_context.next = 10;
|
|
844
|
+
break;
|
|
845
|
+
case 7:
|
|
846
|
+
_context.prev = 7;
|
|
847
|
+
_context.t0 = _context["catch"](1);
|
|
848
|
+
this._uiEventStore.showToast({
|
|
849
|
+
type: 'error',
|
|
850
|
+
message: (0, _i18n.transI18n)('fmt_waitingroom_setting_popup_toast_move_in_failed')
|
|
851
|
+
});
|
|
852
|
+
case 10:
|
|
853
|
+
case "end":
|
|
854
|
+
return _context.stop();
|
|
855
|
+
}
|
|
856
|
+
}, _callee, this, [[1, 7]]);
|
|
857
|
+
}));
|
|
858
|
+
function _moveToWaitingRoomByUserIds(_x) {
|
|
859
|
+
return _moveToWaitingRoomByUserIds2.apply(this, arguments);
|
|
860
|
+
}
|
|
861
|
+
return _moveToWaitingRoomByUserIds;
|
|
862
|
+
}()
|
|
863
|
+
}, {
|
|
864
|
+
key: "removeWaitingRoomUser",
|
|
865
|
+
value: function removeWaitingRoomUser(userId, type) {
|
|
866
|
+
var _this$_waitingRoomUse;
|
|
867
|
+
(_this$_waitingRoomUse = this._waitingRoomUserControl) === null || _this$_waitingRoomUse === void 0 || _this$_waitingRoomUse.kickOutByUserIds([userId], type);
|
|
868
|
+
}
|
|
869
|
+
}, {
|
|
870
|
+
key: "kickOutWaitingRoomAllMember",
|
|
871
|
+
value: function () {
|
|
872
|
+
var _kickOutWaitingRoomAllMember = (0, _asyncToGenerator2["default"])(/*#__PURE__*/_regenerator["default"].mark(function _callee2(type) {
|
|
873
|
+
var _this$_waitingRoomUse2;
|
|
874
|
+
return _regenerator["default"].wrap(function _callee2$(_context2) {
|
|
875
|
+
while (1) switch (_context2.prev = _context2.next) {
|
|
876
|
+
case 0:
|
|
877
|
+
_context2.next = 2;
|
|
878
|
+
return (_this$_waitingRoomUse2 = this._waitingRoomUserControl) === null || _this$_waitingRoomUse2 === void 0 ? void 0 : _this$_waitingRoomUse2.kickOutByUserRoles([_type.FcrUserRole.PARTICIPANT], type);
|
|
879
|
+
case 2:
|
|
880
|
+
this._uiEventStore.showToast({
|
|
881
|
+
type: 'normal',
|
|
882
|
+
message: (0, _i18n.transI18n)('fmt_waitingroom_mobile_memberlist_tips_all_removed')
|
|
883
|
+
});
|
|
884
|
+
case 3:
|
|
885
|
+
case "end":
|
|
886
|
+
return _context2.stop();
|
|
887
|
+
}
|
|
888
|
+
}, _callee2, this);
|
|
889
|
+
}));
|
|
890
|
+
function kickOutWaitingRoomAllMember(_x2) {
|
|
891
|
+
return _kickOutWaitingRoomAllMember.apply(this, arguments);
|
|
892
|
+
}
|
|
893
|
+
return kickOutWaitingRoomAllMember;
|
|
894
|
+
}()
|
|
895
|
+
}, {
|
|
896
|
+
key: "moveToMainRoomAllMember",
|
|
897
|
+
value: function () {
|
|
898
|
+
var _moveToMainRoomAllMember = (0, _asyncToGenerator2["default"])(/*#__PURE__*/_regenerator["default"].mark(function _callee3() {
|
|
899
|
+
var _this$_waitingRoomCon;
|
|
900
|
+
return _regenerator["default"].wrap(function _callee3$(_context3) {
|
|
901
|
+
while (1) switch (_context3.prev = _context3.next) {
|
|
902
|
+
case 0:
|
|
903
|
+
_context3.next = 2;
|
|
904
|
+
return (_this$_waitingRoomCon = this._waitingRoomControl) === null || _this$_waitingRoomCon === void 0 ? void 0 : _this$_waitingRoomCon.moveToMainRoomByUserRoles([_type.FcrUserRole.PARTICIPANT]);
|
|
905
|
+
case 2:
|
|
906
|
+
this._uiEventStore.showToast({
|
|
907
|
+
type: 'normal',
|
|
908
|
+
message: (0, _i18n.transI18n)('fmt_waitingroom_mobile_memberlist_tips_all_amitted')
|
|
909
|
+
});
|
|
910
|
+
case 3:
|
|
911
|
+
case "end":
|
|
912
|
+
return _context3.stop();
|
|
913
|
+
}
|
|
914
|
+
}, _callee3, this);
|
|
915
|
+
}));
|
|
916
|
+
function moveToMainRoomAllMember() {
|
|
917
|
+
return _moveToMainRoomAllMember.apply(this, arguments);
|
|
918
|
+
}
|
|
919
|
+
return moveToMainRoomAllMember;
|
|
920
|
+
}()
|
|
661
921
|
}, {
|
|
662
922
|
key: "getMicStreamVolume",
|
|
663
923
|
value: function getMicStreamVolume(streamId) {
|
|
664
924
|
return this.audioVolumeMap.get(streamId) || 0;
|
|
665
925
|
}
|
|
666
|
-
}, {
|
|
667
|
-
key: "localMicVolume",
|
|
668
|
-
get: function get() {
|
|
669
|
-
return this._deviceStore.microphoneVolumeLevel;
|
|
670
|
-
}
|
|
671
926
|
}, {
|
|
672
927
|
key: "handlerRoomControlAction",
|
|
673
928
|
value: function handlerRoomControlAction(action, data) {
|
|
@@ -704,11 +959,83 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
704
959
|
break;
|
|
705
960
|
}
|
|
706
961
|
}
|
|
707
|
-
|
|
708
|
-
|
|
962
|
+
}, {
|
|
963
|
+
key: "_handleEvent",
|
|
964
|
+
value: function _handleEvent(action, payload) {
|
|
965
|
+
if (action === _constant.UIAction.MAIN_LIST_CHANGED) {
|
|
966
|
+
this._mainList = payload || [];
|
|
967
|
+
}
|
|
968
|
+
if (action === _constant.UIAction.SPOTLIGHT_STREAM_CHANGED) {
|
|
969
|
+
var _ref6 = payload,
|
|
970
|
+
type = _ref6.type,
|
|
971
|
+
streamId = _ref6.streamId;
|
|
972
|
+
if (type === 'add') {
|
|
973
|
+
this.setSpotlightStreamId(streamId);
|
|
974
|
+
} else {
|
|
975
|
+
this.setSpotlightStreamId('');
|
|
976
|
+
}
|
|
977
|
+
}
|
|
978
|
+
if (action === _constant.UIAction.CUSTOM_SETTINGS_CHANGED) {
|
|
979
|
+
var _ref7 = payload,
|
|
980
|
+
spotlightEnabled = _ref7.spotlightEnabled;
|
|
981
|
+
this.enableSpotlight = spotlightEnabled;
|
|
982
|
+
}
|
|
983
|
+
if (action === _constant.UIAction.WAITING_ROOM_CREATED) {
|
|
984
|
+
var room = payload.room;
|
|
985
|
+
this._waitingRoomControl = room;
|
|
986
|
+
var waitingRoomUserControl = room.getUserControl();
|
|
987
|
+
this._waitingRoomUserControl = waitingRoomUserControl;
|
|
988
|
+
waitingRoomUserControl.addObserver(this._waitingRoomUserObserver);
|
|
989
|
+
this.waitingRoomUserCount = this._getWaitingRoomUserCount();
|
|
990
|
+
this._initWaitingRoomUserList();
|
|
991
|
+
}
|
|
992
|
+
if (action === _constant.UIAction.CHANGE_PARTICIPANT_TAB) {
|
|
993
|
+
this.handleActiveTab(payload);
|
|
994
|
+
}
|
|
995
|
+
if (action === _constant.UIAction.WAITING_ROOM_DESTROYED) {
|
|
996
|
+
var _this$_waitingRoomUse3;
|
|
997
|
+
(_this$_waitingRoomUse3 = this._waitingRoomUserControl) === null || _this$_waitingRoomUse3 === void 0 || _this$_waitingRoomUse3.removeObserver(this._waitingRoomUserObserver);
|
|
998
|
+
this._waitingRoomControl = undefined;
|
|
999
|
+
this._waitingRoomUserControl = undefined;
|
|
1000
|
+
this.waitingRoomUserCount = 0;
|
|
1001
|
+
this.handleActiveTab(_constant.RoomType.MAIN_ROOM);
|
|
1002
|
+
}
|
|
1003
|
+
}
|
|
1004
|
+
}, {
|
|
1005
|
+
key: "moveToMainRoomByUserIds",
|
|
1006
|
+
value: function moveToMainRoomByUserIds(userId) {
|
|
1007
|
+
if (this._waitingRoomControl) {
|
|
1008
|
+
this._waitingRoomControl.moveToMainRoomByUserIds(userId);
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
}, {
|
|
1012
|
+
key: "handleActiveTab",
|
|
1013
|
+
value: function handleActiveTab(tab) {
|
|
1014
|
+
this.activeTab = tab;
|
|
1015
|
+
this._uiEventStore.sendEvent(_constant.UIAction.CURRENT_PARTITIPANT_TAB, tab);
|
|
1016
|
+
if (this.activeTab === _constant.RoomType.WAITING_ROOM) {
|
|
1017
|
+
this.isNewWaitingRoomUserEnter = false;
|
|
1018
|
+
}
|
|
1019
|
+
}
|
|
1020
|
+
}, {
|
|
1021
|
+
key: "_initWaitingRoomUserList",
|
|
1022
|
+
value: function _initWaitingRoomUserList() {
|
|
1023
|
+
if (!this._waitingRoomUserControl) return;
|
|
1024
|
+
var users = this._waitingRoomUserControl.getUsers();
|
|
1025
|
+
for (var _i = 0, _Object$entries = Object.entries(users); _i < _Object$entries.length; _i++) {
|
|
1026
|
+
var _Object$entries$_i = (0, _slicedToArray2["default"])(_Object$entries[_i], 2),
|
|
1027
|
+
userId = _Object$entries$_i[0],
|
|
1028
|
+
user = _Object$entries$_i[1];
|
|
1029
|
+
if (userId !== this._userControl.getLocalUser().userId && user.userRole === _type.FcrUserRole.PARTICIPANT) {
|
|
1030
|
+
this._waitingRoomDataSource.add(user, this._streamControl.getStreamsByUserId(userId), this._userControl.getLocalUser().userId === userId);
|
|
1031
|
+
}
|
|
1032
|
+
}
|
|
1033
|
+
}
|
|
709
1034
|
}, {
|
|
710
1035
|
key: "_muteUserAudio",
|
|
711
|
-
value:
|
|
1036
|
+
value:
|
|
1037
|
+
// user actions
|
|
1038
|
+
function _muteUserAudio(user) {
|
|
712
1039
|
var isSelf = user === this._userControl.getLocalUser().userId;
|
|
713
1040
|
if (isSelf) {
|
|
714
1041
|
this._deviceStreamStore.enableMicrophoneWithStream(false);
|
|
@@ -721,8 +1048,8 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
721
1048
|
return;
|
|
722
1049
|
}
|
|
723
1050
|
this._streamControl.updatePublishPrivilegeOfStreams((0, _defineProperty2["default"])({}, targetUser.streamId, {
|
|
724
|
-
audioPrivilege:
|
|
725
|
-
videoPrivilege:
|
|
1051
|
+
audioPrivilege: _agoraEduCore.FcrStreamPrivilegeOperation.NOPRIVILEGE,
|
|
1052
|
+
videoPrivilege: _agoraEduCore.FcrStreamPrivilegeOperation.NOOPERATION
|
|
726
1053
|
}));
|
|
727
1054
|
}
|
|
728
1055
|
}
|
|
@@ -771,8 +1098,8 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
771
1098
|
return;
|
|
772
1099
|
}
|
|
773
1100
|
this._streamControl.updatePublishPrivilegeOfStreams((0, _defineProperty2["default"])({}, targetUser.streamId, {
|
|
774
|
-
audioPrivilege:
|
|
775
|
-
videoPrivilege:
|
|
1101
|
+
audioPrivilege: _agoraEduCore.FcrStreamPrivilegeOperation.NOOPERATION,
|
|
1102
|
+
videoPrivilege: _agoraEduCore.FcrStreamPrivilegeOperation.NOPRIVILEGE
|
|
776
1103
|
}));
|
|
777
1104
|
}
|
|
778
1105
|
}
|
|
@@ -826,56 +1153,28 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
826
1153
|
key: "_kickOutUser",
|
|
827
1154
|
value: function _kickOutUser(userId) {
|
|
828
1155
|
var _this5 = this,
|
|
829
|
-
_this$userMap$
|
|
1156
|
+
_this$userMap$get7;
|
|
830
1157
|
this.openConfirmDialog({
|
|
831
1158
|
title: '',
|
|
832
1159
|
onCancel: function onCancel() {
|
|
833
1160
|
_this5._uiEventStore.closeConfirmDialog();
|
|
834
1161
|
},
|
|
835
1162
|
content: (0, _i18n.transI18n)('fmt_uimanager_tips_Remove', {
|
|
836
|
-
reason2: (_this$userMap$
|
|
1163
|
+
reason2: (_this$userMap$get7 = this.userMap.get(userId)) === null || _this$userMap$get7 === void 0 ? void 0 : _this$userMap$get7.userInfo.userName
|
|
837
1164
|
}),
|
|
838
1165
|
onOk: function onOk() {
|
|
839
|
-
_this5._userControl.kickOut(userId,
|
|
1166
|
+
_this5._userControl.kickOut(userId, _type5.FcrUserKickOutType.Once);
|
|
840
1167
|
_this5._uiEventStore.closeConfirmDialog();
|
|
841
1168
|
},
|
|
842
1169
|
height: 160
|
|
843
1170
|
}, 'KICK_OUT');
|
|
844
1171
|
}
|
|
845
|
-
}, {
|
|
846
|
-
key: "removePin",
|
|
847
|
-
value: function removePin(userId) {
|
|
848
|
-
var _this$userMap$get4;
|
|
849
|
-
var streamId = (_this$userMap$get4 = this.userMap.get(userId)) === null || _this$userMap$get4 === void 0 || (_this$userMap$get4 = _this$userMap$get4.streams.find(function (stream) {
|
|
850
|
-
return stream.videoSourceType === _type3.AgoraRteVideoSourceType.CAMERA;
|
|
851
|
-
})) === null || _this$userMap$get4 === void 0 ? void 0 : _this$userMap$get4.streamId;
|
|
852
|
-
if (streamId) {
|
|
853
|
-
this._uiEventStore.sendEvent(_constant.UIAction.VIDEO_WINDOW_PIN_ACTION, {
|
|
854
|
-
action: _constant.VideoWindowPinType.REMOVE_PIN,
|
|
855
|
-
streamId: streamId
|
|
856
|
-
});
|
|
857
|
-
}
|
|
858
|
-
}
|
|
859
|
-
}, {
|
|
860
|
-
key: "addPin",
|
|
861
|
-
value: function addPin(userId) {
|
|
862
|
-
var _this$userMap$get5;
|
|
863
|
-
var streamId = (_this$userMap$get5 = this.userMap.get(userId)) === null || _this$userMap$get5 === void 0 || (_this$userMap$get5 = _this$userMap$get5.streams.find(function (stream) {
|
|
864
|
-
return stream.videoSourceType === _type3.AgoraRteVideoSourceType.CAMERA;
|
|
865
|
-
})) === null || _this$userMap$get5 === void 0 ? void 0 : _this$userMap$get5.streamId;
|
|
866
|
-
if (streamId) {
|
|
867
|
-
this._uiEventStore.sendEvent(_constant.UIAction.VIDEO_WINDOW_PIN_ACTION, {
|
|
868
|
-
action: _constant.VideoWindowPinType.ADD_PIN,
|
|
869
|
-
streamId: streamId
|
|
870
|
-
});
|
|
871
|
-
}
|
|
872
|
-
}
|
|
873
1172
|
}, {
|
|
874
1173
|
key: "_handleSetHostOrCoHost",
|
|
875
1174
|
value: function _handleSetHostOrCoHost(userId, type) {
|
|
876
|
-
var _this$userMap$
|
|
1175
|
+
var _this$userMap$get8,
|
|
877
1176
|
_this6 = this;
|
|
878
|
-
var username = (_this$userMap$
|
|
1177
|
+
var username = (_this$userMap$get8 = this.userMap.get(userId)) === null || _this$userMap$get8 === void 0 ? void 0 : _this$userMap$get8.userInfo.userName;
|
|
879
1178
|
var targetRole = type === 'host' ? (0, _i18n.transI18n)('fmt_role_host') : (0, _i18n.transI18n)('fmt_role_cohost');
|
|
880
1179
|
this.openConfirmDialog({
|
|
881
1180
|
title: (0, _i18n.transI18n)('fmt_uimanager_labels_Setas', {
|
|
@@ -896,7 +1195,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
896
1195
|
});
|
|
897
1196
|
return;
|
|
898
1197
|
}
|
|
899
|
-
_this6._userControl.
|
|
1198
|
+
_this6._userControl.updateRemoteUserRole(userId, type === 'host' ? _type.FcrUserRole.HOST : _type.FcrUserRole.COHOST);
|
|
900
1199
|
_this6._uiEventStore.closeConfirmDialog();
|
|
901
1200
|
},
|
|
902
1201
|
okText: (0, _i18n.transI18n)('fmt_uimanager_labels_Setas', {
|
|
@@ -919,7 +1218,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
919
1218
|
}, {
|
|
920
1219
|
key: "_setAsAttendee",
|
|
921
1220
|
value: function _setAsAttendee(userId) {
|
|
922
|
-
this._userControl.
|
|
1221
|
+
this._userControl.updateRemoteUserRole(userId, _type.FcrUserRole.PARTICIPANT);
|
|
923
1222
|
}
|
|
924
1223
|
|
|
925
1224
|
// room control actions
|
|
@@ -961,17 +1260,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
961
1260
|
if (!this._securityStore.hasRevokeHostPermission() || this._userControl.getLocalUser().userRole === _type.FcrUserRole.HOST) {
|
|
962
1261
|
return;
|
|
963
1262
|
}
|
|
964
|
-
|
|
965
|
-
// find current host
|
|
966
|
-
var hostUser;
|
|
967
|
-
this.userMap.forEach(function (user) {
|
|
968
|
-
if (user.userInfo.userRole === _type.FcrUserRole.HOST) {
|
|
969
|
-
hostUser = user.userInfo;
|
|
970
|
-
}
|
|
971
|
-
});
|
|
972
|
-
if (hostUser) {
|
|
973
|
-
this._userControl.revokeHost(hostUser.userId);
|
|
974
|
-
}
|
|
1263
|
+
this._userControl.revokeHost();
|
|
975
1264
|
}
|
|
976
1265
|
}, {
|
|
977
1266
|
key: "_playJoinLeaveSound",
|
|
@@ -1008,17 +1297,16 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1008
1297
|
}, {
|
|
1009
1298
|
key: "_onAudioVolumeUpdated",
|
|
1010
1299
|
value: function _onAudioVolumeUpdated(roomId, streamId, volume) {
|
|
1011
|
-
var
|
|
1012
|
-
|
|
1013
|
-
if (!user) {
|
|
1300
|
+
var stream = this._streamControl.getStreamByStreamId(streamId);
|
|
1301
|
+
if (!stream) {
|
|
1014
1302
|
return;
|
|
1015
1303
|
}
|
|
1016
|
-
this.audioVolumeMap.set(
|
|
1304
|
+
this.audioVolumeMap.set(stream.owner.userId, volume);
|
|
1017
1305
|
}
|
|
1018
1306
|
}, {
|
|
1019
1307
|
key: "_updateUserBoardState",
|
|
1020
1308
|
value: function _updateUserBoardState(modifiedUser) {
|
|
1021
|
-
var _this$_roomControl$ge = this._roomControl.
|
|
1309
|
+
var _this$_roomControl$ge = this._roomControl.getBoardControl().getBoardActiveInfo(),
|
|
1022
1310
|
isActive = _this$_roomControl$ge.isActive,
|
|
1023
1311
|
ownerUserId = _this$_roomControl$ge.ownerUserId;
|
|
1024
1312
|
if (!ownerUserId && !modifiedUser) return;
|
|
@@ -1046,17 +1334,55 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1046
1334
|
_this8._updateUserBoardState(modifiedUser);
|
|
1047
1335
|
});
|
|
1048
1336
|
}
|
|
1337
|
+
}, {
|
|
1338
|
+
key: "_handleRemoteWaitingUserJoined",
|
|
1339
|
+
value: function _handleRemoteWaitingUserJoined(roomId, events) {
|
|
1340
|
+
var _this9 = this;
|
|
1341
|
+
events.forEach(function (event) {
|
|
1342
|
+
var modifiedUser = event.modifiedUser;
|
|
1343
|
+
if (modifiedUser.userRole === _type.FcrUserRole.PARTICIPANT) {
|
|
1344
|
+
_this9._waitingRoomDataSource.add(modifiedUser, _this9._streamControl.getStreamsByUserId(modifiedUser.userId), modifiedUser.userId === _this9._userControl.getLocalUser().userId);
|
|
1345
|
+
// this._updateUserBoardState(modifiedUser);
|
|
1346
|
+
}
|
|
1347
|
+
});
|
|
1348
|
+
if (this.activeTab === _constant.RoomType.MAIN_ROOM) {
|
|
1349
|
+
this.isNewWaitingRoomUserEnter = true;
|
|
1350
|
+
}
|
|
1351
|
+
this.waitingRoomUserCount = this._getWaitingRoomUserCount();
|
|
1352
|
+
}
|
|
1353
|
+
}, {
|
|
1354
|
+
key: "_getWaitingRoomUserCount",
|
|
1355
|
+
value: function _getWaitingRoomUserCount() {
|
|
1356
|
+
var _this$_waitingRoomUse4;
|
|
1357
|
+
return (_this$_waitingRoomUse4 = this._waitingRoomUserControl) === null || _this$_waitingRoomUse4 === void 0 ? void 0 : _this$_waitingRoomUse4.getUserList().filter(function (user) {
|
|
1358
|
+
return user.userRole === _type.FcrUserRole.PARTICIPANT;
|
|
1359
|
+
}).length;
|
|
1360
|
+
}
|
|
1361
|
+
}, {
|
|
1362
|
+
key: "_handleRemoteWaitingUserLeft",
|
|
1363
|
+
value: function _handleRemoteWaitingUserLeft(roomId, events) {
|
|
1364
|
+
var _this10 = this;
|
|
1365
|
+
events.forEach(function (event) {
|
|
1366
|
+
var modifiedUser = event.modifiedUser;
|
|
1367
|
+
_this10._waitingRoomDataSource["delete"](modifiedUser);
|
|
1368
|
+
_this10._updateUserBoardState(modifiedUser);
|
|
1369
|
+
});
|
|
1370
|
+
this.waitingRoomUserCount = this._getWaitingRoomUserCount();
|
|
1371
|
+
if (this._getWaitingRoomUserCount() === 0) {
|
|
1372
|
+
this.handleActiveTab(_constant.RoomType.MAIN_ROOM);
|
|
1373
|
+
}
|
|
1374
|
+
}
|
|
1049
1375
|
}, {
|
|
1050
1376
|
key: "_onUserInfoUpdated",
|
|
1051
1377
|
value: function _onUserInfoUpdated(roomId, event) {
|
|
1052
|
-
var _this$userMap$
|
|
1378
|
+
var _this$userMap$get9;
|
|
1053
1379
|
var targetUser = event.modifiedUser;
|
|
1054
1380
|
this._updateUserBoardState(targetUser);
|
|
1055
1381
|
this._dataSource.update(targetUser);
|
|
1056
|
-
var originUser = (_this$userMap$
|
|
1057
|
-
var _this$_userControl$
|
|
1058
|
-
localUserId = _this$_userControl$
|
|
1059
|
-
localUserRole = _this$_userControl$
|
|
1382
|
+
var originUser = (_this$userMap$get9 = this.userMap.get(targetUser.userId)) === null || _this$userMap$get9 === void 0 ? void 0 : _this$userMap$get9.userInfo;
|
|
1383
|
+
var _this$_userControl$ge3 = this._userControl.getLocalUser(),
|
|
1384
|
+
localUserId = _this$_userControl$ge3.userId,
|
|
1385
|
+
localUserRole = _this$_userControl$ge3.userRole;
|
|
1060
1386
|
var effectSelf = targetUser.userId === localUserId;
|
|
1061
1387
|
if ((originUser === null || originUser === void 0 ? void 0 : originUser.userRole) !== targetUser.userRole) {
|
|
1062
1388
|
// 参会者变管理
|
|
@@ -1092,45 +1418,45 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1092
1418
|
value: function _initUserList() {
|
|
1093
1419
|
this._refreshCurrentPerspectiveType();
|
|
1094
1420
|
var users = this._userControl.getUsers();
|
|
1095
|
-
for (var
|
|
1096
|
-
var _Object$
|
|
1097
|
-
userId = _Object$
|
|
1098
|
-
user = _Object$
|
|
1421
|
+
for (var _i2 = 0, _Object$entries2 = Object.entries(users); _i2 < _Object$entries2.length; _i2++) {
|
|
1422
|
+
var _Object$entries2$_i = (0, _slicedToArray2["default"])(_Object$entries2[_i2], 2),
|
|
1423
|
+
userId = _Object$entries2$_i[0],
|
|
1424
|
+
user = _Object$entries2$_i[1];
|
|
1099
1425
|
this._dataSource.add(user, this._streamControl.getStreamsByUserId(userId), this._userControl.getLocalUser().userId === userId);
|
|
1100
1426
|
}
|
|
1101
1427
|
}
|
|
1102
1428
|
}, {
|
|
1103
1429
|
key: "_handleStreamsAdded",
|
|
1104
1430
|
value: function _handleStreamsAdded(roomId, events) {
|
|
1105
|
-
var
|
|
1431
|
+
var _this11 = this;
|
|
1106
1432
|
events.forEach(function (e) {
|
|
1107
1433
|
var modifiedStream = e.modifiedStream;
|
|
1108
|
-
|
|
1434
|
+
_this11._dataSource.updateWithStreamAdd(modifiedStream);
|
|
1109
1435
|
});
|
|
1110
1436
|
}
|
|
1111
1437
|
}, {
|
|
1112
1438
|
key: "_handleStreamsUpdated",
|
|
1113
1439
|
value: function _handleStreamsUpdated(roomId, events) {
|
|
1114
|
-
var
|
|
1440
|
+
var _this12 = this;
|
|
1115
1441
|
events.forEach(function (e) {
|
|
1116
1442
|
var modifiedStream = e.modifiedStream;
|
|
1117
|
-
|
|
1443
|
+
_this12._dataSource.update(modifiedStream);
|
|
1118
1444
|
});
|
|
1119
1445
|
}
|
|
1120
1446
|
}, {
|
|
1121
1447
|
key: "_handleStreamsRemoved",
|
|
1122
1448
|
value: function _handleStreamsRemoved(roomId, events) {
|
|
1123
|
-
var
|
|
1449
|
+
var _this13 = this;
|
|
1124
1450
|
events.forEach(function (e) {
|
|
1125
1451
|
var modifiedStream = e.modifiedStream;
|
|
1126
|
-
|
|
1452
|
+
_this13._dataSource.updateWithStreamRemove(modifiedStream);
|
|
1127
1453
|
});
|
|
1128
1454
|
}
|
|
1129
1455
|
}, {
|
|
1130
1456
|
key: "_refreshCurrentPerspectiveType",
|
|
1131
1457
|
value: function _refreshCurrentPerspectiveType() {
|
|
1132
|
-
var _this$_userControl$
|
|
1133
|
-
var localUserUid = (_this$_userControl$
|
|
1458
|
+
var _this$_userControl$ge4;
|
|
1459
|
+
var localUserUid = (_this$_userControl$ge4 = this._userControl.getLocalUser()) === null || _this$_userControl$ge4 === void 0 ? void 0 : _this$_userControl$ge4.userId;
|
|
1134
1460
|
if (!localUserUid) {
|
|
1135
1461
|
this.currentPerspectiveType = 'attendee';
|
|
1136
1462
|
return;
|
|
@@ -1150,26 +1476,16 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1150
1476
|
}
|
|
1151
1477
|
this.currentPerspectiveType = 'attendee';
|
|
1152
1478
|
}
|
|
1153
|
-
}, {
|
|
1154
|
-
key: "hasRevokeHostPermission",
|
|
1155
|
-
get: function get() {
|
|
1156
|
-
return this._securityStore.hasRevokeHostPermission() && this.localUserRole !== _type.FcrUserRole.HOST;
|
|
1157
|
-
}
|
|
1158
|
-
}, {
|
|
1159
|
-
key: "getAllowedOperations",
|
|
1160
|
-
value: function getAllowedOperations(targetRole, isSelf) {
|
|
1161
|
-
return this._securityStore.getAllowedOperations(targetRole, isSelf);
|
|
1162
|
-
}
|
|
1163
1479
|
}, {
|
|
1164
1480
|
key: "_onPeerSessionReceived",
|
|
1165
1481
|
value: function _onPeerSessionReceived(session) {
|
|
1166
|
-
var _this$_userControl$
|
|
1167
|
-
|
|
1482
|
+
var _this$_userControl$ge5,
|
|
1483
|
+
_this14 = this;
|
|
1168
1484
|
if (session.sessionId && this._processedUserOpenDeviceRequests.has(session.sessionId)) {
|
|
1169
1485
|
return;
|
|
1170
1486
|
}
|
|
1171
1487
|
this._processedUserOpenDeviceRequests.add(session.sessionId);
|
|
1172
|
-
var localUserUid = (_this$_userControl$
|
|
1488
|
+
var localUserUid = (_this$_userControl$ge5 = this._userControl.getLocalUser()) === null || _this$_userControl$ge5 === void 0 ? void 0 : _this$_userControl$ge5.userId;
|
|
1173
1489
|
if (!localUserUid) {
|
|
1174
1490
|
return;
|
|
1175
1491
|
}
|
|
@@ -1198,13 +1514,13 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1198
1514
|
okText: (0, _i18n.transI18n)('fmt_additional_button_accept'),
|
|
1199
1515
|
cancelText: (0, _i18n.transI18n)('fmt_additional_button_refuse'),
|
|
1200
1516
|
onOk: function onOk() {
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1517
|
+
_this14._peerSessionControl.acceptPeerSession(session);
|
|
1518
|
+
_this14._deviceStreamStore.enableCameraWithStream(true);
|
|
1519
|
+
_this14._uiEventStore.closeConfirmDialog();
|
|
1204
1520
|
},
|
|
1205
1521
|
onCancel: function onCancel() {
|
|
1206
|
-
|
|
1207
|
-
|
|
1522
|
+
_this14._peerSessionControl.rejectPeerSession(session);
|
|
1523
|
+
_this14._uiEventStore.closeConfirmDialog();
|
|
1208
1524
|
}
|
|
1209
1525
|
}, _type4.FcrUISessionKey.REQUEST_OPEN_CAMERA);
|
|
1210
1526
|
return;
|
|
@@ -1224,13 +1540,13 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1224
1540
|
okText: (0, _i18n.transI18n)('fmt_device_label_audio_unmute'),
|
|
1225
1541
|
cancelText: (0, _i18n.transI18n)('fmt_additional_options_Keepsilent'),
|
|
1226
1542
|
onOk: function onOk() {
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1543
|
+
_this14._peerSessionControl.acceptPeerSession(session);
|
|
1544
|
+
_this14._deviceStreamStore.enableMicrophoneWithStream(true);
|
|
1545
|
+
_this14._uiEventStore.closeConfirmDialog();
|
|
1230
1546
|
},
|
|
1231
1547
|
onCancel: function onCancel() {
|
|
1232
|
-
|
|
1233
|
-
|
|
1548
|
+
_this14._peerSessionControl.rejectPeerSession(session);
|
|
1549
|
+
_this14._uiEventStore.closeConfirmDialog();
|
|
1234
1550
|
}
|
|
1235
1551
|
}, _type4.FcrUISessionKey.REQUEST_OPEN_MICROPHONE);
|
|
1236
1552
|
}
|
|
@@ -1270,29 +1586,29 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1270
1586
|
}, {
|
|
1271
1587
|
key: "_addReactions",
|
|
1272
1588
|
value: function _addReactions() {
|
|
1273
|
-
var
|
|
1589
|
+
var _this15 = this;
|
|
1274
1590
|
this._disposers.push((0, _mobx.reaction)(function () {
|
|
1275
|
-
return
|
|
1591
|
+
return _this15._participantsWindowActive;
|
|
1276
1592
|
}, function (active) {
|
|
1277
1593
|
if (active) {
|
|
1278
|
-
|
|
1279
|
-
userList:
|
|
1280
|
-
perspectiveType:
|
|
1281
|
-
allowChangeSelfName:
|
|
1282
|
-
allowChat:
|
|
1283
|
-
allowJoinWithMuteAudio:
|
|
1284
|
-
allowShareScreen:
|
|
1285
|
-
allowUnmuteSelfVideo:
|
|
1286
|
-
allowUnmuteSelfAudio:
|
|
1287
|
-
isLockRoomEnabled:
|
|
1288
|
-
isWaitingRoomEnabled:
|
|
1289
|
-
hasRevokeHostPermission:
|
|
1290
|
-
userRole:
|
|
1594
|
+
_this15._sendEvent(_constant.RendererEventAction.INIT_PARTICIPANT_LIST, {
|
|
1595
|
+
userList: _this15.userList,
|
|
1596
|
+
perspectiveType: _this15.currentPerspectiveType,
|
|
1597
|
+
allowChangeSelfName: _this15._securityStore.allowChangeSelfName(),
|
|
1598
|
+
allowChat: _this15._securityStore.allowChat(),
|
|
1599
|
+
allowJoinWithMuteAudio: _this15._securityStore.allowJoinWithMuteAudio(),
|
|
1600
|
+
allowShareScreen: _this15._securityStore.allowScreenShareAndBoard(),
|
|
1601
|
+
allowUnmuteSelfVideo: _this15._securityStore.allowUnmuteSelfVideo(),
|
|
1602
|
+
allowUnmuteSelfAudio: _this15._securityStore.allowUnmuteSelfAudio(),
|
|
1603
|
+
isLockRoomEnabled: _this15._securityStore.isLockRoomEnabled(),
|
|
1604
|
+
isWaitingRoomEnabled: _this15._securityStore.isWaitingRoomEnabled(),
|
|
1605
|
+
hasRevokeHostPermission: _this15._securityStore.hasRevokeHostPermission() && _this15._userControl.getLocalUser().userRole !== _type.FcrUserRole.HOST,
|
|
1606
|
+
userRole: _this15._userControl.getLocalUser().userRole
|
|
1291
1607
|
});
|
|
1292
1608
|
}
|
|
1293
1609
|
}));
|
|
1294
1610
|
this._disposers.push((0, _mobx.reaction)(function () {
|
|
1295
|
-
return
|
|
1611
|
+
return _this15.userList;
|
|
1296
1612
|
}, function (list) {
|
|
1297
1613
|
(0, _rendererEvent.sendEvent)({
|
|
1298
1614
|
action: _constant.RendererEventAction.UPDATE_PARTICIPANT,
|
|
@@ -1318,7 +1634,7 @@ var ParticipantStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1318
1634
|
}]);
|
|
1319
1635
|
}();
|
|
1320
1636
|
_ParticipantStore = ParticipantStore;
|
|
1321
|
-
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_ParticipantStore, [[_mobx.observable, 1, "_mainList"], [_mobx.observable, 1, "_participantsWindowActive"], [_mobx.observable, 1, "currentPerspectiveType"], [_mobx.observable, 1, "audioVolumeMap"], [_mobx.observable, 1, "enableParticipantsJoinWithMute"], [_mobx.observable, 1, "searchText"], [_mobx.observable, 1, "currentModal"], [_mobx.observable, 1, "localUserRole"], [_mobx.observable, 1, "spotlightStreamId"], [_mobx.observable, 1, "enableSpotlight"], [_mobx.observable, 1, "mergeConfirmDialog"], [_mobx.observable, 1, "mergeUserId"], [
|
|
1637
|
+
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_ParticipantStore, [[_mobx.observable, 1, "_mainList"], [_mobx.observable, 1, "_participantsWindowActive"], [_mobx.observable, 1, "currentPerspectiveType"], [_mobx.observable, 1, "audioVolumeMap"], [_mobx.observable, 1, "enableParticipantsJoinWithMute"], [_mobx.observable, 1, "searchText"], [_mobx.observable, 1, "currentModal"], [_mobx.observable, 1, "localUserRole"], [_mobx.observable, 1, "spotlightStreamId"], [_mobx.observable, 1, "enableSpotlight"], [_mobx.observable, 1, "mergeConfirmDialog"], [_mobx.observable, 1, "mergeUserId"], [_mobx.observable, 1, "activeTab"], [_mobx.observable, 1, "isNewWaitingRoomUserEnter"], [_mobx.observable, 1, "waitingRoomUserCount"], [_mobx.computed, 3, "userListSource"], [_mobx.computed, 3, "mergeUserInfo"], [_mobx.computed, 3, "userMap"], [_mobx.computed, 3, "pinedStreamIds"], [_mobx.computed, 3, "hasPinnedStream"], [_mobx.computed, 3, "userList"], [_mobx.computed, 3, "localMicVolume"], [_mobx.computed, 3, "hasRevokeHostPermission"], [_setSpotlightStreamIdDecs, 18, "setSpotlightStreamId"], [_decorator.bound, 2, "hasMutePermission"], [_decorator.bound, 2, "hasWaitingRoomPermission"], [_decorator.bound, 2, "hasUnmutePermission"], [_decorator.bound, 2, "hasRequestStartAudioPermission"], [_setCurrentModalDecs, 18, "setCurrentModal"], [_decorator.bound, 2, "closeParticipantsAside"], [_openParticipantsWindowDecs, 18, "openParticipantsWindow"], [_setParticipantsWindowActiveDecs, 18, "setParticipantsWindowActive"], [_handlerSearchUserDecs, 18, "handlerSearchUser"], [_decorator.bound, 2, "onInvite"], [_decorator.bound, 2, "setMergeConfirmDialog"], [_decorator.bound, 2, "mergeConfirmDialogOk"], [_decorator.bound, 2, "removePin"], [_decorator.bound, 2, "addPin"], [_getAllowedOperationsDecs, 18, "getAllowedOperations"], [_closeRemoveAdmitWaitingRoomDialogDecs, 18, "closeRemoveAdmitWaitingRoomDialog"], [_openRemoveAdmitWaitingRoomDialogDecs, 18, "openRemoveAdmitWaitingRoomDialog"], [_handlerUserActionDecs, 18, "handlerUserAction"], [_moveToWaitingRoomByUserIdsDecs, 18, "_moveToWaitingRoomByUserIds"], [_removeWaitingRoomUserDecs, 18, "removeWaitingRoomUser"], [_kickOutWaitingRoomAllMemberDecs, 18, "kickOutWaitingRoomAllMember"], [_moveToMainRoomAllMemberDecs, 18, "moveToMainRoomAllMember"], [_decorator.bound, 2, "getMicStreamVolume"], [_handlerRoomControlActionDecs, 18, "handlerRoomControlAction"], [_handleEventDecs, 18, "_handleEvent"], [_moveToMainRoomByUserIdsDecs, 18, "moveToMainRoomByUserIds"], [_handleActiveTabDecs, 18, "handleActiveTab"], [_initWaitingRoomUserListDecs, 18, "_initWaitingRoomUserList"], [_kickOutUserDecs, 18, "_kickOutUser"], [_setAsAttendeeDecs, 18, "_setAsAttendee"], [_onAudioVolumeUpdatedDecs, 18, "_onAudioVolumeUpdated"], [_handleRemoteUserJoinedDecs, 18, "_handleRemoteUserJoined"], [_handleRemoteUserLeftDecs, 18, "_handleRemoteUserLeft"], [_handleRemoteWaitingUserJoinedDecs, 18, "_handleRemoteWaitingUserJoined"], [_handleRemoteWaitingUserLeftDecs, 18, "_handleRemoteWaitingUserLeft"], [_onUserInfoUpdatedDecs, 18, "_onUserInfoUpdated"], [_initUserListDecs, 18, "_initUserList"], [_decorator.bound, 2, "_handleStreamsAdded"], [_decorator.bound, 2, "_handleStreamsUpdated"], [_decorator.bound, 2, "_handleStreamsRemoved"], [_refreshCurrentPerspectiveTypeDecs, 18, "_refreshCurrentPerspectiveType"], [_onPeerSessionReceivedDecs, 18, "_onPeerSessionReceived"], [_updateLocalUserRoleDecs, 18, "_updateLocalUserRole"]], []).e, 16);
|
|
1322
1638
|
_init__mainList = _applyDecs$e[0];
|
|
1323
1639
|
_init__participantsWindowActive = _applyDecs$e[1];
|
|
1324
1640
|
_init_currentPerspectiveType = _applyDecs$e[2];
|
|
@@ -1331,4 +1647,7 @@ _init_spotlightStreamId = _applyDecs$e[8];
|
|
|
1331
1647
|
_init_enableSpotlight = _applyDecs$e[9];
|
|
1332
1648
|
_init_mergeConfirmDialog = _applyDecs$e[10];
|
|
1333
1649
|
_init_mergeUserId = _applyDecs$e[11];
|
|
1334
|
-
|
|
1650
|
+
_init_activeTab = _applyDecs$e[12];
|
|
1651
|
+
_init_isNewWaitingRoomUserEnter = _applyDecs$e[13];
|
|
1652
|
+
_init_waitingRoomUserCount = _applyDecs$e[14];
|
|
1653
|
+
_initProto = _applyDecs$e[15];
|