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,6 +12,8 @@ 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", {
|
|
@@ -21,17 +23,71 @@ exports["default"] = void 0;
|
|
|
21
23
|
require("core-js/modules/es.array.filter.js");
|
|
22
24
|
require("core-js/modules/es.array.find.js");
|
|
23
25
|
require("core-js/modules/es.array.for-each.js");
|
|
26
|
+
require("core-js/modules/es.array.includes.js");
|
|
24
27
|
require("core-js/modules/es.array.iterator.js");
|
|
28
|
+
require("core-js/modules/es.array.map.js");
|
|
25
29
|
require("core-js/modules/es.array.push.js");
|
|
26
30
|
require("core-js/modules/es.array.slice.js");
|
|
27
31
|
require("core-js/modules/es.array.some.js");
|
|
28
32
|
require("core-js/modules/es.function.bind.js");
|
|
29
33
|
require("core-js/modules/es.map.js");
|
|
34
|
+
require("core-js/modules/es.object.entries.js");
|
|
30
35
|
require("core-js/modules/es.object.to-string.js");
|
|
31
36
|
require("core-js/modules/es.object.values.js");
|
|
32
37
|
require("core-js/modules/es.set.js");
|
|
38
|
+
require("core-js/modules/es.string.includes.js");
|
|
33
39
|
require("core-js/modules/es.string.iterator.js");
|
|
34
40
|
require("core-js/modules/es.weak-map.js");
|
|
41
|
+
require("core-js/modules/esnext.async-iterator.filter.js");
|
|
42
|
+
require("core-js/modules/esnext.async-iterator.find.js");
|
|
43
|
+
require("core-js/modules/esnext.async-iterator.for-each.js");
|
|
44
|
+
require("core-js/modules/esnext.async-iterator.map.js");
|
|
45
|
+
require("core-js/modules/esnext.async-iterator.some.js");
|
|
46
|
+
require("core-js/modules/esnext.iterator.constructor.js");
|
|
47
|
+
require("core-js/modules/esnext.iterator.filter.js");
|
|
48
|
+
require("core-js/modules/esnext.iterator.find.js");
|
|
49
|
+
require("core-js/modules/esnext.iterator.for-each.js");
|
|
50
|
+
require("core-js/modules/esnext.iterator.map.js");
|
|
51
|
+
require("core-js/modules/esnext.iterator.some.js");
|
|
52
|
+
require("core-js/modules/esnext.map.delete-all.js");
|
|
53
|
+
require("core-js/modules/esnext.map.emplace.js");
|
|
54
|
+
require("core-js/modules/esnext.map.every.js");
|
|
55
|
+
require("core-js/modules/esnext.map.filter.js");
|
|
56
|
+
require("core-js/modules/esnext.map.find.js");
|
|
57
|
+
require("core-js/modules/esnext.map.find-key.js");
|
|
58
|
+
require("core-js/modules/esnext.map.includes.js");
|
|
59
|
+
require("core-js/modules/esnext.map.key-of.js");
|
|
60
|
+
require("core-js/modules/esnext.map.map-keys.js");
|
|
61
|
+
require("core-js/modules/esnext.map.map-values.js");
|
|
62
|
+
require("core-js/modules/esnext.map.merge.js");
|
|
63
|
+
require("core-js/modules/esnext.map.reduce.js");
|
|
64
|
+
require("core-js/modules/esnext.map.some.js");
|
|
65
|
+
require("core-js/modules/esnext.map.update.js");
|
|
66
|
+
require("core-js/modules/esnext.set.add-all.js");
|
|
67
|
+
require("core-js/modules/esnext.set.delete-all.js");
|
|
68
|
+
require("core-js/modules/esnext.set.difference.v2.js");
|
|
69
|
+
require("core-js/modules/esnext.set.difference.js");
|
|
70
|
+
require("core-js/modules/esnext.set.every.js");
|
|
71
|
+
require("core-js/modules/esnext.set.filter.js");
|
|
72
|
+
require("core-js/modules/esnext.set.find.js");
|
|
73
|
+
require("core-js/modules/esnext.set.intersection.v2.js");
|
|
74
|
+
require("core-js/modules/esnext.set.intersection.js");
|
|
75
|
+
require("core-js/modules/esnext.set.is-disjoint-from.v2.js");
|
|
76
|
+
require("core-js/modules/esnext.set.is-disjoint-from.js");
|
|
77
|
+
require("core-js/modules/esnext.set.is-subset-of.v2.js");
|
|
78
|
+
require("core-js/modules/esnext.set.is-subset-of.js");
|
|
79
|
+
require("core-js/modules/esnext.set.is-superset-of.v2.js");
|
|
80
|
+
require("core-js/modules/esnext.set.is-superset-of.js");
|
|
81
|
+
require("core-js/modules/esnext.set.join.js");
|
|
82
|
+
require("core-js/modules/esnext.set.map.js");
|
|
83
|
+
require("core-js/modules/esnext.set.reduce.js");
|
|
84
|
+
require("core-js/modules/esnext.set.some.js");
|
|
85
|
+
require("core-js/modules/esnext.set.symmetric-difference.v2.js");
|
|
86
|
+
require("core-js/modules/esnext.set.symmetric-difference.js");
|
|
87
|
+
require("core-js/modules/esnext.set.union.v2.js");
|
|
88
|
+
require("core-js/modules/esnext.set.union.js");
|
|
89
|
+
require("core-js/modules/esnext.weak-map.delete-all.js");
|
|
90
|
+
require("core-js/modules/esnext.weak-map.emplace.js");
|
|
35
91
|
require("core-js/modules/web.dom-collections.for-each.js");
|
|
36
92
|
require("core-js/modules/web.dom-collections.iterator.js");
|
|
37
93
|
require("core-js/modules/web.timers.js");
|
|
@@ -40,22 +96,28 @@ var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/cl
|
|
|
40
96
|
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
41
97
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
42
98
|
var _mobx = require("mobx");
|
|
99
|
+
var _agoraEduCore = require("agora-edu-core");
|
|
43
100
|
var _type = require("agora-edu-core/lib/type");
|
|
44
101
|
var _decorator = require("agora-foundation/lib/decorator");
|
|
45
102
|
var _logger = require("agora-foundation/lib/logger");
|
|
46
|
-
var _type2 = require("
|
|
47
|
-
var
|
|
103
|
+
var _type2 = require("../video-window/type");
|
|
104
|
+
var _eventStore = require("../../common/event-store");
|
|
48
105
|
var _constant = require("../../utilities/constant");
|
|
49
|
-
var
|
|
106
|
+
var _type3 = require("./type");
|
|
50
107
|
var _Layout = require("./components/Layout");
|
|
51
108
|
var _videoWindowDatasource = require("./video-window-datasource");
|
|
52
109
|
var _toast = require("agora-ui-foundation/lib/components/toast");
|
|
53
|
-
var
|
|
110
|
+
var _type4 = require("../whiteboard/type");
|
|
54
111
|
var _i18n = require("agora-ui-foundation/lib/i18n");
|
|
112
|
+
var _type5 = require("agora-edu-core/lib/room-control/chatroom-control/type");
|
|
113
|
+
var _type6 = require("agora-rte-sdk/lib/core/scene/type");
|
|
114
|
+
var _attendee = require("agora-ui-foundation/lib/components/participants/attendee");
|
|
115
|
+
var _type7 = require("agora-edu-core/lib/room-control/privilege-control/type");
|
|
116
|
+
var _get = _interopRequireDefault(require("lodash/get"));
|
|
55
117
|
var _LayoutStore;
|
|
56
|
-
var _initProto, _participantDecs, _init_participant, _chatDecs, _init_chat, _chatActionDecs, _init_chatAction, _stateBarDecs, _init_stateBar, _actionBarDecs, _init_actionBar, _layersDecs, _init_layers, _whiteboardDecs, _init_whiteboard, _init_collapsed, _init_galleryMaxSize, _init_aside, _init_asideContent, _init_localUserRole, _init_barHovering, _init_barLocked, _init_barHidden, _init_asideWidth, _init_userVolumeMap, _init_chatRoomState, _init_videoWindowPreviewType, _init_whiteboardActive, _init_spotlightStreamId, _init_shouldHideNonVideoParticipants, _init_participantCount, _init_ownerUser, _init_localUser,
|
|
57
|
-
function _classPrivateFieldInitSpec(
|
|
58
|
-
function _checkPrivateRedeclaration(
|
|
118
|
+
var _initProto, _participantDecs, _init_participant, _chatDecs, _init_chat, _chatActionDecs, _init_chatAction, _stateBarDecs, _init_stateBar, _actionBarDecs, _init_actionBar, _layersDecs, _init_layers, _whiteboardDecs, _init_whiteboard, _init_collapsed, _init_galleryMaxSize, _init_aside, _init_asideContent, _init_localUserRole, _init_barHovering, _init_barLocked, _init_barHidden, _init_asideWidth, _init_userVolumeMap, _init_chatRoomState, _init_videoWindowPreviewType, _init_whiteboardActive, _init_spotlightStreamId, _init_shouldHideNonVideoParticipants, _init_participantCount, _init_ownerUser, _init_localUser, _init_enableSpotlight, _init_isWaitingRoomNotify, _notifyParticipantShowWaitingRoomDecs, _setIsWaitingRoomNotifyDecs, _setWhiteboardActiveDecs, _setAsideWidthDecs, _updateSlotsDecs, _updateAsideContentDecs, _getAllowedOperationsDecs, _toggleLayoutDecs, _toggleCollapsedDecs, _setGalleryMaxSizeDecs, _toggleAsideDecs, _asideWidthChangedDecs, _toggleLayoutBarLockDecs, _toggleLayoutBarHiddenDecs, _resetLockTimerDecs, _setHoveringHandlerDecs, _setHoveringLeaveHandlerDecs, _onUserInfoUpdatedDecs, _handleLayoutUpdatedDecs, _init__handleLayoutUpdated, _handleFoldListChangedDecs, _handleMainListChangedDecs, _setBarHoveringDecs, _onAllUserCountUpdatedDecs, _handleConnectionUpdatedDecs, _onAudioVolumeUpdatedDecs, _ref;
|
|
119
|
+
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
|
120
|
+
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
|
|
59
121
|
function _classPrivateFieldSet(s, a, r) { return s.set(_assertClassBrand(s, a), r), r; }
|
|
60
122
|
function _classPrivateFieldGet(s, a) { return s.get(_assertClassBrand(s, a)); }
|
|
61
123
|
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"); }
|
|
@@ -91,13 +153,29 @@ var _X = /*#__PURE__*/new WeakMap();
|
|
|
91
153
|
var _Y = /*#__PURE__*/new WeakMap();
|
|
92
154
|
var _Z = /*#__PURE__*/new WeakMap();
|
|
93
155
|
var _a = /*#__PURE__*/new WeakMap();
|
|
94
|
-
_ref = (_participantDecs = [_mobx.observable, _mobx.observable.ref], _chatDecs = [_mobx.observable, _mobx.observable.ref], _chatActionDecs = [_mobx.observable, _mobx.observable.ref], _stateBarDecs = [_mobx.observable, _mobx.observable.ref], _actionBarDecs = [_mobx.observable, _mobx.observable.ref], _layersDecs = [_mobx.observable, _mobx.observable.ref], _whiteboardDecs = [_mobx.observable, _mobx.observable.ref],
|
|
156
|
+
_ref = (_participantDecs = [_mobx.observable, _mobx.observable.ref], _chatDecs = [_mobx.observable, _mobx.observable.ref], _chatActionDecs = [_mobx.observable, _mobx.observable.ref], _stateBarDecs = [_mobx.observable, _mobx.observable.ref], _actionBarDecs = [_mobx.observable, _mobx.observable.ref], _layersDecs = [_mobx.observable, _mobx.observable.ref], _whiteboardDecs = [_mobx.observable, _mobx.observable.ref], _notifyParticipantShowWaitingRoomDecs = [_mobx.action, _mobx.action.bound], _setIsWaitingRoomNotifyDecs = [_mobx.action, _mobx.action.bound], _setWhiteboardActiveDecs = [_mobx.action, _mobx.action.bound], _setAsideWidthDecs = [_mobx.action, _mobx.action.bound], _updateSlotsDecs = [_mobx.action, _mobx.action.bound], _updateAsideContentDecs = [_mobx.action, _mobx.action.bound], _getAllowedOperationsDecs = [_mobx.action, _mobx.action.bound], _toggleLayoutDecs = [_mobx.action, _mobx.action.bound], _toggleCollapsedDecs = [_mobx.action, _mobx.action.bound], _setGalleryMaxSizeDecs = [_mobx.action, _mobx.action.bound], _toggleAsideDecs = [_mobx.action, _mobx.action.bound], _asideWidthChangedDecs = [_mobx.action, _mobx.action.bound], _toggleLayoutBarLockDecs = [_mobx.action, _mobx.action.bound], _toggleLayoutBarHiddenDecs = [_mobx.action, _mobx.action.bound], _resetLockTimerDecs = [_mobx.action, _mobx.action.bound], _setHoveringHandlerDecs = [_mobx.action, _mobx.action.bound], _setHoveringLeaveHandlerDecs = [_mobx.action, _mobx.action.bound], _onUserInfoUpdatedDecs = [_mobx.action, _mobx.action.bound], _handleLayoutUpdatedDecs = [_mobx.action, _mobx.action.bound], _handleFoldListChangedDecs = [_mobx.action, _mobx.action.bound], _handleMainListChangedDecs = [_mobx.action, _mobx.action.bound], _setBarHoveringDecs = [_mobx.action, _mobx.action.bound], _onAllUserCountUpdatedDecs = [_mobx.action, _mobx.action.bound], _handleConnectionUpdatedDecs = [_mobx.action, _mobx.action.bound], _onAudioVolumeUpdatedDecs = [_mobx.action, _mobx.action.bound], "logger");
|
|
95
157
|
var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
96
158
|
function LayoutStore(params) {
|
|
97
159
|
var _this = this;
|
|
98
160
|
(0, _classCallCheck2["default"])(this, LayoutStore);
|
|
99
|
-
(0, _defineProperty2["default"])(this, _ref, (_initProto(this),
|
|
100
|
-
(0, _defineProperty2["default"])(this, "
|
|
161
|
+
(0, _defineProperty2["default"])(this, _ref, (_initProto(this), (0, _logger.getLogger)()));
|
|
162
|
+
(0, _defineProperty2["default"])(this, "_videoWindowDataSource", new _videoWindowDatasource.FcrUIVideoWindowDataSource());
|
|
163
|
+
(0, _defineProperty2["default"])(this, "_localView", null);
|
|
164
|
+
(0, _defineProperty2["default"])(this, "_subscriptions", []);
|
|
165
|
+
(0, _defineProperty2["default"])(this, "_barLockTimer", 0);
|
|
166
|
+
(0, _defineProperty2["default"])(this, "_liveStreamState", _type.FcrLiveStreamingState.STOPPED);
|
|
167
|
+
(0, _defineProperty2["default"])(this, "_chatRoomObserver", {
|
|
168
|
+
onConnectionStateUpdated: this._handleConnectionUpdated.bind(this),
|
|
169
|
+
onErrorOccurred: function onErrorOccurred() {},
|
|
170
|
+
onTextMessageReceived: function onTextMessageReceived() {}
|
|
171
|
+
});
|
|
172
|
+
(0, _defineProperty2["default"])(this, "_waitingRoomUserObserver", {
|
|
173
|
+
onRemoteUsersLeft: this._handleRemoteWaitingUserLeft.bind(this)
|
|
174
|
+
});
|
|
175
|
+
(0, _defineProperty2["default"])(this, "_waitingRoomObserver", {
|
|
176
|
+
onRoomMessageReceived: this._handleMessageReceived.bind(this)
|
|
177
|
+
});
|
|
178
|
+
(0, _defineProperty2["default"])(this, "_managerRoleUpdateForToast", new Set([_type.FcrUserRole.HOST, _type.FcrUserRole.COHOST]));
|
|
101
179
|
// Slots
|
|
102
180
|
_classPrivateFieldInitSpec(this, _A, _init_participant(this, null));
|
|
103
181
|
_classPrivateFieldInitSpec(this, _B, _init_chat(this, null));
|
|
@@ -108,7 +186,7 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
108
186
|
_classPrivateFieldInitSpec(this, _G, _init_whiteboard(this, null));
|
|
109
187
|
// State
|
|
110
188
|
_classPrivateFieldInitSpec(this, _H, _init_collapsed(this, true));
|
|
111
|
-
_classPrivateFieldInitSpec(this, _I, _init_galleryMaxSize(this,
|
|
189
|
+
_classPrivateFieldInitSpec(this, _I, _init_galleryMaxSize(this, _type3.GalleryMaxSize.Normal));
|
|
112
190
|
_classPrivateFieldInitSpec(this, _J, _init_aside(this, false));
|
|
113
191
|
_classPrivateFieldInitSpec(this, _K, _init_asideContent(this, {
|
|
114
192
|
participant: false,
|
|
@@ -120,27 +198,20 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
120
198
|
_classPrivateFieldInitSpec(this, _O, _init_barHidden(this, false));
|
|
121
199
|
_classPrivateFieldInitSpec(this, _P, _init_asideWidth(this, _Layout.MinAsideWidth));
|
|
122
200
|
_classPrivateFieldInitSpec(this, _Q, _init_userVolumeMap(this, new Map()));
|
|
123
|
-
_classPrivateFieldInitSpec(this, _R, _init_chatRoomState(this,
|
|
124
|
-
_classPrivateFieldInitSpec(this, _S, _init_videoWindowPreviewType(this,
|
|
201
|
+
_classPrivateFieldInitSpec(this, _R, _init_chatRoomState(this, _type5.FcrChatRoomConnectionState.Disconnected));
|
|
202
|
+
_classPrivateFieldInitSpec(this, _S, _init_videoWindowPreviewType(this, _type2.FcrVideoWindowPreviewType.MIX));
|
|
125
203
|
_classPrivateFieldInitSpec(this, _T, _init_whiteboardActive(this, false));
|
|
126
204
|
_classPrivateFieldInitSpec(this, _U, _init_spotlightStreamId(this, ''));
|
|
127
205
|
_classPrivateFieldInitSpec(this, _V, _init_shouldHideNonVideoParticipants(this, false));
|
|
128
206
|
_classPrivateFieldInitSpec(this, _W, _init_participantCount(this, 0));
|
|
129
|
-
_classPrivateFieldInitSpec(this, _X, _init_ownerUser(this,
|
|
207
|
+
_classPrivateFieldInitSpec(this, _X, _init_ownerUser(this, undefined));
|
|
130
208
|
_classPrivateFieldInitSpec(this, _Y, _init_localUser(this));
|
|
131
|
-
_classPrivateFieldInitSpec(this, _Z,
|
|
132
|
-
_classPrivateFieldInitSpec(this, _a,
|
|
133
|
-
(0, _defineProperty2["default"])(this, "_localView", null);
|
|
134
|
-
(0, _defineProperty2["default"])(this, "_subscriptions", []);
|
|
135
|
-
(0, _defineProperty2["default"])(this, "_barLockTimer", 0);
|
|
136
|
-
(0, _defineProperty2["default"])(this, "_chatRoomObserver", {
|
|
137
|
-
onConnectionStateUpdated: this._handleConnectionUpdated.bind(this)
|
|
138
|
-
});
|
|
139
|
-
(0, _defineProperty2["default"])(this, "_managerRoleUpdateForToast", new Set([_type.FcrUserRole.HOST, _type.FcrUserRole.COHOST]));
|
|
209
|
+
_classPrivateFieldInitSpec(this, _Z, _init_enableSpotlight(this, true));
|
|
210
|
+
_classPrivateFieldInitSpec(this, _a, _init_isWaitingRoomNotify(this, true));
|
|
140
211
|
(0, _defineProperty2["default"])(this, "_handleLayoutUpdated", _init__handleLayoutUpdated(this, function (layout) {
|
|
141
|
-
if (layout ===
|
|
212
|
+
if (layout === _type3.FcrUIVideoWindowLayoutType.Speaker) {
|
|
142
213
|
_this._switchToSpeaker();
|
|
143
|
-
} else if (layout ===
|
|
214
|
+
} else if (layout === _type3.FcrUIVideoWindowLayoutType.Gallery) {
|
|
144
215
|
_this._switchToGallery();
|
|
145
216
|
}
|
|
146
217
|
_this._uiEventStore.notifyLayoutChanged({
|
|
@@ -154,7 +225,8 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
154
225
|
_this._videoWindowDataSource.setSpeakerSpotlight(streamId);
|
|
155
226
|
});
|
|
156
227
|
var userControl = params.userControl,
|
|
157
|
-
chatRoomControl = params.chatRoomControl
|
|
228
|
+
chatRoomControl = params.chatRoomControl,
|
|
229
|
+
roomControl = params.roomControl;
|
|
158
230
|
this._securityStore = params.securityStore;
|
|
159
231
|
this._deviceStore = params.deviceStore;
|
|
160
232
|
this._uiEventStore = params.uiEventStore;
|
|
@@ -162,7 +234,13 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
162
234
|
this._streamControl = params.streamControl;
|
|
163
235
|
this._chatRoomControl = chatRoomControl;
|
|
164
236
|
this._whiteBoardControl = params.whiteBoardControl;
|
|
237
|
+
this._privilegeControl = params.privilegeControl;
|
|
165
238
|
this.localUser = userControl.getLocalUser();
|
|
239
|
+
roomControl.addObserver({
|
|
240
|
+
onLiveStreamingStateUpdated: function onLiveStreamingStateUpdated(_, state) {
|
|
241
|
+
_this._liveStreamState = state;
|
|
242
|
+
}
|
|
243
|
+
});
|
|
166
244
|
this._addListeners();
|
|
167
245
|
//@ts-ignore
|
|
168
246
|
window.layoutStore = this;
|
|
@@ -380,7 +458,7 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
380
458
|
_classPrivateFieldSet(_Y, this, v);
|
|
381
459
|
}
|
|
382
460
|
}, {
|
|
383
|
-
key: "
|
|
461
|
+
key: "enableSpotlight",
|
|
384
462
|
get: function get() {
|
|
385
463
|
return _classPrivateFieldGet(_Z, this);
|
|
386
464
|
},
|
|
@@ -388,7 +466,7 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
388
466
|
_classPrivateFieldSet(_Z, this, v);
|
|
389
467
|
}
|
|
390
468
|
}, {
|
|
391
|
-
key: "
|
|
469
|
+
key: "isWaitingRoomNotify",
|
|
392
470
|
get: function get() {
|
|
393
471
|
return _classPrivateFieldGet(_a, this);
|
|
394
472
|
},
|
|
@@ -405,23 +483,38 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
405
483
|
get: function get() {
|
|
406
484
|
return this._streamControl;
|
|
407
485
|
}
|
|
486
|
+
}, {
|
|
487
|
+
key: "isWaterMarkEnabled",
|
|
488
|
+
get: function get() {
|
|
489
|
+
return this._securityStore.isWaterMarkEnabled();
|
|
490
|
+
}
|
|
491
|
+
}, {
|
|
492
|
+
key: "isMulti",
|
|
493
|
+
get: function get() {
|
|
494
|
+
return this._securityStore.isMulti();
|
|
495
|
+
}
|
|
408
496
|
}, {
|
|
409
497
|
key: "layout",
|
|
410
498
|
get: function get() {
|
|
411
499
|
return this._videoWindowDataSource.layoutType;
|
|
412
500
|
}
|
|
501
|
+
}, {
|
|
502
|
+
key: "manualLayout",
|
|
503
|
+
get: function get() {
|
|
504
|
+
return this._videoWindowDataSource.manualLayout;
|
|
505
|
+
}
|
|
413
506
|
}, {
|
|
414
507
|
key: "mainList",
|
|
415
508
|
get: function get() {
|
|
416
509
|
var _this2 = this;
|
|
417
510
|
var sourceList = this._videoWindowDataSource.mainList.filter(function (i) {
|
|
418
|
-
return !i.isMySelf || i.videoSourceType !==
|
|
511
|
+
return !i.isMySelf || i.videoSourceType !== _agoraEduCore.FcrVideoSourceType.SCREEN;
|
|
419
512
|
});
|
|
420
513
|
var existHasVideoStreamUser = sourceList.some(function (i) {
|
|
421
514
|
return i.hasVideoStream;
|
|
422
515
|
});
|
|
423
516
|
return this.shouldHideNonVideoParticipants ? sourceList.filter(function (i) {
|
|
424
|
-
var visible = i.isMySelf && !existHasVideoStreamUser || i.hasVideoStream || i.videoSourceType ===
|
|
517
|
+
var visible = i.isMySelf && !existHasVideoStreamUser || i.hasVideoStream || i.videoSourceType === _agoraEduCore.FcrVideoSourceType.SCREEN || i.type === _type3.FcrUIWindowType.BOARD;
|
|
425
518
|
if (!visible && i.isPin) {
|
|
426
519
|
_this2.removePin(i.windowId, (0, _i18n.transI18n)('fmt_internalsetting_other_hide_no_video_pin_cancelled'));
|
|
427
520
|
}
|
|
@@ -450,18 +543,18 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
450
543
|
key: "currentShareData",
|
|
451
544
|
get: function get() {
|
|
452
545
|
return this.mainList.find(function (item) {
|
|
453
|
-
return item.videoSourceType ===
|
|
546
|
+
return item.videoSourceType === _agoraEduCore.FcrVideoSourceType.SCREEN || item.type === _type3.FcrUIWindowType.BOARD;
|
|
454
547
|
});
|
|
455
548
|
}
|
|
456
549
|
}, {
|
|
457
550
|
key: "galleryList",
|
|
458
551
|
get: function get() {
|
|
459
|
-
return this._videoWindowDataSource.layoutType ===
|
|
552
|
+
return this._videoWindowDataSource.layoutType === _type3.FcrUIVideoWindowLayoutType.Speaker ? this.mainList.slice(0, 1) : this.mainList;
|
|
460
553
|
}
|
|
461
554
|
}, {
|
|
462
555
|
key: "carouselList",
|
|
463
556
|
get: function get() {
|
|
464
|
-
return this._videoWindowDataSource.layoutType ===
|
|
557
|
+
return this._videoWindowDataSource.layoutType === _type3.FcrUIVideoWindowLayoutType.Speaker ? this.mainList.slice(1) : this.mainList;
|
|
465
558
|
}
|
|
466
559
|
}, {
|
|
467
560
|
key: "hasPinnedStream",
|
|
@@ -509,178 +602,58 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
509
602
|
return this._securityStore.allowUnmuteSelfVideo();
|
|
510
603
|
}
|
|
511
604
|
}, {
|
|
512
|
-
key: "
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
var isSharingScreen = false;
|
|
516
|
-
this._streamControl.getStreamList().forEach(function (stream) {
|
|
517
|
-
if (stream.videoSourceType === _type2.AgoraRtcVideoSourceType.SCREEN) {
|
|
518
|
-
isSharingScreen = true;
|
|
519
|
-
}
|
|
520
|
-
_this4._handleStreamAdded(stream);
|
|
521
|
-
});
|
|
522
|
-
if (isSharingScreen && this.layout === _type4.FcrUIVideoWindowLayoutType.Gallery) {
|
|
523
|
-
this.toggleLayout(_type4.FcrUIVideoWindowLayoutType.Speaker);
|
|
524
|
-
}
|
|
605
|
+
key: "isHostOrCoHost",
|
|
606
|
+
get: function get() {
|
|
607
|
+
return this.localUserRole === _type.FcrUserRole.HOST || this.localUserRole === _type.FcrUserRole.COHOST;
|
|
525
608
|
}
|
|
526
609
|
}, {
|
|
527
|
-
key: "
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
return setSpotlightEnable && enableSpotlight;
|
|
610
|
+
key: "allowedAllChat",
|
|
611
|
+
get: function get() {
|
|
612
|
+
return this._securityStore.allowedAllChat();
|
|
531
613
|
}
|
|
532
614
|
}, {
|
|
533
|
-
key: "
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
this._uiEventStore.addObserver({
|
|
537
|
-
onEvent: this.onEvent
|
|
538
|
-
});
|
|
539
|
-
this._streamControl.addObserver({
|
|
540
|
-
onStreamsAdded: this._onStreamsAdded,
|
|
541
|
-
onStreamsUpdated: this._onStreamsUpdated,
|
|
542
|
-
onStreamsRemoved: this._onStreamsRemoved,
|
|
543
|
-
onAudioVolumeUpdated: this._onAudioVolumeUpdated
|
|
544
|
-
});
|
|
545
|
-
this._userControl.addObserver({
|
|
546
|
-
onUserInfoUpdated: this.onUserInfoUpdated,
|
|
547
|
-
onAllUserCountUpdated: this._onAllUserCountUpdated
|
|
548
|
-
});
|
|
549
|
-
this._videoWindowDataSource.addObserver({
|
|
550
|
-
onLayoutUpdated: this._handleLayoutUpdated,
|
|
551
|
-
onFoldListAdded: this._handleFoldListChanged,
|
|
552
|
-
onFoldListRemoved: this._handleFoldListChanged,
|
|
553
|
-
onFoldListUpdated: this._handleFoldListChanged,
|
|
554
|
-
onMainListAdded: this._handleMainListChanged,
|
|
555
|
-
onMainListUpdated: this._handleMainListChanged,
|
|
556
|
-
onMainListRemoved: this._handleMainListChanged,
|
|
557
|
-
onSpotlightAdded: this._handleSpotlightAdded,
|
|
558
|
-
onSpotlightRemoved: this._handleSpotlightRemoved
|
|
559
|
-
});
|
|
560
|
-
this._whiteBoardControl.addObserver({
|
|
561
|
-
onBoardActiveInfoUpdated: this.setWhiteboardActive
|
|
562
|
-
});
|
|
563
|
-
this._chatRoomControl.addobserver(this._chatRoomObserver);
|
|
564
|
-
this._subscriptions.push((0, _mobx.reaction)(function () {
|
|
565
|
-
return _this5.mainList.length;
|
|
566
|
-
}, function (length) {
|
|
567
|
-
if (length < 2) {
|
|
568
|
-
if (_this5.layout === _type4.FcrUIVideoWindowLayoutType.Speaker) {
|
|
569
|
-
_this5.toggleLayout(_type4.FcrUIVideoWindowLayoutType.Gallery);
|
|
570
|
-
}
|
|
571
|
-
}
|
|
572
|
-
_this5._uiEventStore.sendEvent(_constant.UIAction.MAIN_LIST_LENGTH_CHANGED, length);
|
|
573
|
-
}), (0, _mobx.reaction)(function () {
|
|
574
|
-
return _this5.whiteboardActive;
|
|
575
|
-
}, function (opened) {
|
|
576
|
-
if (opened) {
|
|
577
|
-
var ownerUserId = _this5._whiteBoardControl.getBoardActiveInfo().ownerUserId;
|
|
578
|
-
var ownerUser = _this5._userControl.getUser(ownerUserId);
|
|
579
|
-
_this5._videoWindowDataSource.addBoard(ownerUser, ownerUserId === _this5.localUserId);
|
|
580
|
-
if (_this5.layout === _type4.FcrUIVideoWindowLayoutType.Gallery) {
|
|
581
|
-
_this5.toggleLayout(_type4.FcrUIVideoWindowLayoutType.Speaker);
|
|
582
|
-
}
|
|
583
|
-
} else {
|
|
584
|
-
_this5._videoWindowDataSource.removeBoard();
|
|
585
|
-
}
|
|
586
|
-
}), (0, _mobx.reaction)(function () {
|
|
587
|
-
return _this5._securityStore.hasWriteBoardPermission();
|
|
588
|
-
}, function (canEdit) {
|
|
589
|
-
if (!_this5.mainList.some(function (u) {
|
|
590
|
-
return u.type === _type4.FcrUIWindowType.BOARD;
|
|
591
|
-
})) return;
|
|
592
|
-
_this5._videoWindowDataSource.updateBoard(canEdit);
|
|
593
|
-
}), (0, _mobx.reaction)(function () {
|
|
594
|
-
return _this5.galleryMaxSize;
|
|
595
|
-
}, function (size) {
|
|
596
|
-
_this5._uiEventStore.notifyLayoutSizeChanged({
|
|
597
|
-
size: size
|
|
598
|
-
});
|
|
599
|
-
}), (0, _mobx.reaction)(function () {
|
|
600
|
-
return _this5.asideContent;
|
|
601
|
-
}, function (asideContent) {
|
|
602
|
-
if (asideContent.participant || asideContent.chat) {
|
|
603
|
-
_this5.toggleAside(true);
|
|
604
|
-
}
|
|
605
|
-
if (!asideContent.participant && !asideContent.chat) {
|
|
606
|
-
_this5.toggleAside(false);
|
|
607
|
-
}
|
|
608
|
-
}, {
|
|
609
|
-
fireImmediately: true
|
|
610
|
-
}), (0, _mobx.reaction)(function () {
|
|
611
|
-
return {
|
|
612
|
-
cameraEnabled: _this5._deviceStore.cameraEnabled,
|
|
613
|
-
cameraId: _this5._deviceStore.cameraId
|
|
614
|
-
};
|
|
615
|
-
}, function (_ref2) {
|
|
616
|
-
var cameraEnabled = _ref2.cameraEnabled,
|
|
617
|
-
cameraId = _ref2.cameraId;
|
|
618
|
-
if (!cameraEnabled && _this5._localView) {
|
|
619
|
-
_this5.stopLocalPreview(_this5._localView);
|
|
620
|
-
}
|
|
621
|
-
if (cameraEnabled && cameraId && _this5._localView) {
|
|
622
|
-
_this5.startLocalPreview(_this5._localView);
|
|
623
|
-
}
|
|
624
|
-
}), (0, _mobx.reaction)(function () {
|
|
625
|
-
return _this5.barLocked;
|
|
626
|
-
}, function (barLocked) {
|
|
627
|
-
if (_this5._barLockTimer && barLocked) {
|
|
628
|
-
_this5.resetLockTimer();
|
|
629
|
-
} else {
|
|
630
|
-
_this5.setHoveringHandler();
|
|
631
|
-
}
|
|
632
|
-
}), (0, _mobx.reaction)(function () {
|
|
633
|
-
return _this5._deviceStore.microphoneVolumeLevel;
|
|
634
|
-
}, function (volume) {
|
|
635
|
-
(0, _mobx.runInAction)(function () {
|
|
636
|
-
_this5.userVolumeMap.set('0', volume);
|
|
637
|
-
});
|
|
638
|
-
}), (0, _mobx.reaction)(function () {
|
|
639
|
-
return {
|
|
640
|
-
count: _this5.participantCount,
|
|
641
|
-
enableSpotlight: _this5.enableSpotlight
|
|
642
|
-
};
|
|
643
|
-
}, function (_ref3) {
|
|
644
|
-
var count = _ref3.count,
|
|
645
|
-
enableSpotlight = _ref3.enableSpotlight;
|
|
646
|
-
var enableSetSpotlight = _this5._isSetSpotlightEnable(count, enableSpotlight);
|
|
647
|
-
_this5._videoWindowDataSource.setSpotlightEnabled(enableSetSpotlight);
|
|
648
|
-
}),
|
|
649
|
-
// 录制的特殊逻辑:
|
|
650
|
-
// 因为录制机器人不发流,且当前切换布局的逻辑是有多个人的视频窗口才切换到 speaker layout
|
|
651
|
-
// 所以当房间只有主持人的时候录制机器人的视角不会切换到 speaker layout,故加上以下逻辑
|
|
652
|
-
(0, _mobx.reaction)(function () {
|
|
653
|
-
var _this5$currentShareDa;
|
|
654
|
-
return (_this5$currentShareDa = _this5.currentShareData) === null || _this5$currentShareDa === void 0 ? void 0 : _this5$currentShareDa.hasScreenSharing;
|
|
655
|
-
}, function (hasScreenSharing) {
|
|
656
|
-
if (_this5.isRobot) {
|
|
657
|
-
if (hasScreenSharing) {
|
|
658
|
-
_this5.logger.info('set layout to speaker for robot');
|
|
659
|
-
_this5.toggleLayout(_type4.FcrUIVideoWindowLayoutType.Speaker);
|
|
660
|
-
} else {
|
|
661
|
-
_this5.logger.info('set layout to gallery for robot');
|
|
662
|
-
_this5.toggleLayout(_type4.FcrUIVideoWindowLayoutType.Gallery);
|
|
663
|
-
}
|
|
664
|
-
}
|
|
665
|
-
}, {
|
|
666
|
-
fireImmediately: true
|
|
667
|
-
}));
|
|
615
|
+
key: "allowedPublicChatAndDisallowedPrivateChat",
|
|
616
|
+
get: function get() {
|
|
617
|
+
return this._securityStore.allowedPublicChatAndDisallowedPrivateChat();
|
|
668
618
|
}
|
|
669
619
|
}, {
|
|
670
|
-
key: "
|
|
671
|
-
|
|
672
|
-
this.
|
|
673
|
-
type: 'add',
|
|
674
|
-
streamId: streamId
|
|
675
|
-
});
|
|
620
|
+
key: "disallowedPublicChatAndDisallowedPrivateChatToParticipant",
|
|
621
|
+
get: function get() {
|
|
622
|
+
return this._securityStore.disallowedPublicChatAndDisallowedPrivateChatToParticipant();
|
|
676
623
|
}
|
|
677
624
|
}, {
|
|
678
|
-
key: "
|
|
679
|
-
|
|
680
|
-
this.
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
625
|
+
key: "disallowedAllChat",
|
|
626
|
+
get: function get() {
|
|
627
|
+
return this._securityStore.disallowedAllChat();
|
|
628
|
+
}
|
|
629
|
+
}, {
|
|
630
|
+
key: "privilegeOperator",
|
|
631
|
+
get: function get() {
|
|
632
|
+
return this._securityStore.privilegeOperator;
|
|
633
|
+
}
|
|
634
|
+
}, {
|
|
635
|
+
key: "localUserId",
|
|
636
|
+
get: function get() {
|
|
637
|
+
var _this$_userControl$ge;
|
|
638
|
+
return (_this$_userControl$ge = this._userControl.getLocalUser()) === null || _this$_userControl$ge === void 0 ? void 0 : _this$_userControl$ge.userId;
|
|
639
|
+
}
|
|
640
|
+
}, {
|
|
641
|
+
key: "getWaterMarkContent",
|
|
642
|
+
value: function getWaterMarkContent() {
|
|
643
|
+
return this._securityStore.getWaterMarkContent();
|
|
644
|
+
}
|
|
645
|
+
}, {
|
|
646
|
+
key: "notifyParticipantShowWaitingRoom",
|
|
647
|
+
value: function notifyParticipantShowWaitingRoom() {
|
|
648
|
+
this._uiEventStore.sendEvent(_constant.UIAction.TOGGLE_PARTICIPANT_TAB, _constant.RoomType.WAITING_ROOM);
|
|
649
|
+
this._uiEventStore.sendEvent(_constant.UIAction.CHANGE_PARTICIPANT_TAB, _constant.RoomType.WAITING_ROOM);
|
|
650
|
+
this._uiEventStore.sendEvent(_constant.UIAction.COLSE_NOTIFICATION, _eventStore.NotificationContentType.WAITING_ROOM);
|
|
651
|
+
}
|
|
652
|
+
}, {
|
|
653
|
+
key: "setIsWaitingRoomNotify",
|
|
654
|
+
value: function setIsWaitingRoomNotify() {
|
|
655
|
+
this.isWaitingRoomNotify = false;
|
|
656
|
+
this._uiEventStore.sendEvent(_constant.UIAction.COLSE_NOTIFICATION, _eventStore.NotificationContentType.WAITING_ROOM);
|
|
684
657
|
}
|
|
685
658
|
}, {
|
|
686
659
|
key: "hasMutePermission",
|
|
@@ -702,8 +675,8 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
702
675
|
value: function toggleMainStream(streamId) {
|
|
703
676
|
var success = this._videoWindowDataSource.toggleMainStream(streamId);
|
|
704
677
|
if (success) {
|
|
705
|
-
if (this.layout ===
|
|
706
|
-
this.toggleLayout(
|
|
678
|
+
if (this.layout === _type3.FcrUIVideoWindowLayoutType.Gallery) {
|
|
679
|
+
this.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Speaker, true);
|
|
707
680
|
}
|
|
708
681
|
}
|
|
709
682
|
}
|
|
@@ -732,8 +705,8 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
732
705
|
content: (0, _i18n.transI18n)('fmt_settings_tips_screenlocked')
|
|
733
706
|
}
|
|
734
707
|
});
|
|
735
|
-
if (this.layout ===
|
|
736
|
-
this.toggleLayout(
|
|
708
|
+
if (this.layout === _type3.FcrUIVideoWindowLayoutType.Gallery) {
|
|
709
|
+
this.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Speaker);
|
|
737
710
|
}
|
|
738
711
|
}
|
|
739
712
|
}
|
|
@@ -778,16 +751,11 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
778
751
|
key: "setWhiteboardActive",
|
|
779
752
|
value: function setWhiteboardActive(active) {
|
|
780
753
|
this.whiteboardActive = active;
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
}
|
|
787
|
-
}, {
|
|
788
|
-
key: "_handleMainListChanged",
|
|
789
|
-
value: function _handleMainListChanged() {
|
|
790
|
-
this._uiEventStore.sendEvent(_constant.UIAction.MAIN_LIST_CHANGED, this.mainList);
|
|
754
|
+
if (!active && this.manualLayout) {
|
|
755
|
+
this._uiEventStore.sendEvent(_constant.UIAction.TOGGLE_LAYOUT, {
|
|
756
|
+
layout: this.manualLayout
|
|
757
|
+
});
|
|
758
|
+
}
|
|
791
759
|
}
|
|
792
760
|
}, {
|
|
793
761
|
key: "setAsideWidth",
|
|
@@ -796,21 +764,6 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
796
764
|
!this.aside && this.toggleAside(true);
|
|
797
765
|
this.asideWidth = val;
|
|
798
766
|
}
|
|
799
|
-
}, {
|
|
800
|
-
key: "setDocumentVisibility",
|
|
801
|
-
value: function setDocumentVisibility(visible) {
|
|
802
|
-
this.documentVisible = visible;
|
|
803
|
-
}
|
|
804
|
-
}, {
|
|
805
|
-
key: "_switchToSpeaker",
|
|
806
|
-
value: function _switchToSpeaker() {
|
|
807
|
-
this.collapsed = false;
|
|
808
|
-
}
|
|
809
|
-
}, {
|
|
810
|
-
key: "_switchToGallery",
|
|
811
|
-
value: function _switchToGallery() {
|
|
812
|
-
this.collapsed = true;
|
|
813
|
-
}
|
|
814
767
|
}, {
|
|
815
768
|
key: "getLocalUserId",
|
|
816
769
|
value: function getLocalUserId() {
|
|
@@ -896,8 +849,8 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
896
849
|
}
|
|
897
850
|
}, {
|
|
898
851
|
key: "toggleLayout",
|
|
899
|
-
value: function toggleLayout(layout) {
|
|
900
|
-
this._videoWindowDataSource.setLayout(layout);
|
|
852
|
+
value: function toggleLayout(layout, manual) {
|
|
853
|
+
this._videoWindowDataSource.setLayout(layout, manual);
|
|
901
854
|
}
|
|
902
855
|
}, {
|
|
903
856
|
key: "toggleCollapsed",
|
|
@@ -932,11 +885,6 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
932
885
|
value: function toggleLayoutBarHidden() {
|
|
933
886
|
this.barHidden = !this.barHidden;
|
|
934
887
|
}
|
|
935
|
-
}, {
|
|
936
|
-
key: "_setBarHovering",
|
|
937
|
-
value: function _setBarHovering(state) {
|
|
938
|
-
this.barHovering = state;
|
|
939
|
-
}
|
|
940
888
|
}, {
|
|
941
889
|
key: "resetLockTimer",
|
|
942
890
|
value: function resetLockTimer() {
|
|
@@ -947,12 +895,12 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
947
895
|
}, {
|
|
948
896
|
key: "setHoveringHandler",
|
|
949
897
|
value: function setHoveringHandler() {
|
|
950
|
-
var
|
|
898
|
+
var _this4 = this;
|
|
951
899
|
this._setBarHovering(true);
|
|
952
900
|
if (!this._barLockTimer && !this.barLocked) {
|
|
953
901
|
this._barLockTimer = window.setTimeout(function () {
|
|
954
|
-
|
|
955
|
-
|
|
902
|
+
_this4._setBarHovering(false);
|
|
903
|
+
_this4.resetLockTimer();
|
|
956
904
|
}, 3000);
|
|
957
905
|
}
|
|
958
906
|
}
|
|
@@ -969,14 +917,10 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
969
917
|
});
|
|
970
918
|
this._chatRoomControl.removeObserver(this._chatRoomObserver);
|
|
971
919
|
}
|
|
972
|
-
}, {
|
|
973
|
-
key: "_onAllUserCountUpdated",
|
|
974
|
-
value: function _onAllUserCountUpdated(_roomId, count) {
|
|
975
|
-
this.participantCount = count;
|
|
976
|
-
}
|
|
977
920
|
}, {
|
|
978
921
|
key: "onUserInfoUpdated",
|
|
979
922
|
value: function onUserInfoUpdated(roomId, event) {
|
|
923
|
+
var _this5 = this;
|
|
980
924
|
this._videoWindowDataSource.update(event.modifiedUser);
|
|
981
925
|
this.setLocalUserRole(this._userControl.getLocalUser().userRole);
|
|
982
926
|
if (this._managerRoleUpdateForToast.has(event.modifiedUser.userRole)) {
|
|
@@ -985,11 +929,15 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
985
929
|
var toastContent = function toastContent() {
|
|
986
930
|
var contentText = '';
|
|
987
931
|
if (event.modifiedUser.userRole === _type.FcrUserRole.HOST) {
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
}
|
|
991
|
-
|
|
992
|
-
|
|
932
|
+
if (_this5._liveStreamState === _type.FcrLiveStreamingState.STARTED) {
|
|
933
|
+
contentText = "\u79FB\u4EA4 \u4E3B\u6301\u4EBA\u5B8C\u6210\uFF0C\u76F4\u64AD\u505C\u6B62\uFF0C\u8BF7\u91CD\u65B0\u5F00\u542F\u76F4\u64AD";
|
|
934
|
+
} else {
|
|
935
|
+
contentText = isMe ? (0, _i18n.transI18n)('fmt_attendies_tips_mine_new_host', {
|
|
936
|
+
reason1: userName
|
|
937
|
+
}) : (0, _i18n.transI18n)('fmt_attendies_tips_new_host', {
|
|
938
|
+
reason1: userName
|
|
939
|
+
});
|
|
940
|
+
}
|
|
993
941
|
} else if (event.modifiedUser.userRole === _type.FcrUserRole.COHOST) {
|
|
994
942
|
contentText = isMe ? (0, _i18n.transI18n)('fmt_attendies_tips_mine_new_co_host') : (0, _i18n.transI18n)('fmt_attendies_tips_new_co_host', {
|
|
995
943
|
reason1: userName
|
|
@@ -1008,50 +956,93 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1008
956
|
value: function setLocalUserRole(role) {
|
|
1009
957
|
this.localUserRole = role;
|
|
1010
958
|
}
|
|
959
|
+
}, {
|
|
960
|
+
key: "stopLocalPreview",
|
|
961
|
+
value: function stopLocalPreview(view) {
|
|
962
|
+
this._deviceStore.stopPlayLocalVideo(view);
|
|
963
|
+
}
|
|
964
|
+
}, {
|
|
965
|
+
key: "startLocalPreview",
|
|
966
|
+
value: function startLocalPreview(div) {
|
|
967
|
+
if (div) {
|
|
968
|
+
this._deviceStore.startPlayLocalVideo(div);
|
|
969
|
+
}
|
|
970
|
+
}
|
|
971
|
+
}, {
|
|
972
|
+
key: "setAllowChatWithPayload",
|
|
973
|
+
value: function setAllowChatWithPayload(type) {
|
|
974
|
+
switch (type) {
|
|
975
|
+
case 'public':
|
|
976
|
+
this._securityStore.setAllowedPublicChatAndDisallowedPrivateChat();
|
|
977
|
+
break;
|
|
978
|
+
case 'private_to_manager':
|
|
979
|
+
this._securityStore.setDisallowedPublicChatAndDisallowedPrivateChatToParticipant();
|
|
980
|
+
break;
|
|
981
|
+
}
|
|
982
|
+
}
|
|
983
|
+
}, {
|
|
984
|
+
key: "muteAudio",
|
|
985
|
+
value: function muteAudio(mute, userId) {
|
|
986
|
+
this._uiEventStore.sendEvent(_constant.UIAction.PARTICIPANT_ACTION, {
|
|
987
|
+
action: mute ? _attendee.ParticipantActionType.MUTE_AUDIO : _attendee.ParticipantActionType.UNMUTE_AUDIO,
|
|
988
|
+
userId: userId
|
|
989
|
+
});
|
|
990
|
+
}
|
|
991
|
+
}, {
|
|
992
|
+
key: "sendParticipantEvent",
|
|
993
|
+
value: function sendParticipantEvent(payload) {
|
|
994
|
+
this._uiEventStore.sendEvent(_constant.UIAction.PARTICIPANT_ACTION, payload);
|
|
995
|
+
}
|
|
1011
996
|
}, {
|
|
1012
997
|
key: "onEvent",
|
|
1013
|
-
value:
|
|
998
|
+
value:
|
|
999
|
+
// onEvent(
|
|
1000
|
+
// action: UIAction.WHITEBOARD_CHANGED,
|
|
1001
|
+
// payload: { action: WhiteboardControlbarEvents; payload: boolean },
|
|
1002
|
+
// ): void;
|
|
1003
|
+
function onEvent(action, payload) {
|
|
1014
1004
|
if (action === _constant.UIAction.UPDATE_ASIDE) {
|
|
1015
|
-
var
|
|
1016
|
-
participant =
|
|
1017
|
-
chat =
|
|
1005
|
+
var _ref2 = payload,
|
|
1006
|
+
participant = _ref2.participant,
|
|
1007
|
+
chat = _ref2.chat;
|
|
1018
1008
|
// this._uiEventStore.sendEvent(UIAction.ASIDE_WIDTH_CHANGED, this.asideWidth);
|
|
1019
1009
|
this.updateAsideContent(participant, chat);
|
|
1020
1010
|
}
|
|
1021
1011
|
if (action === _constant.UIAction.TOGGLE_LAYOUT) {
|
|
1022
|
-
var
|
|
1023
|
-
layout =
|
|
1024
|
-
|
|
1012
|
+
var _ref3 = payload,
|
|
1013
|
+
layout = _ref3.layout,
|
|
1014
|
+
manual = _ref3.manual;
|
|
1015
|
+
this.toggleLayout(layout, manual);
|
|
1025
1016
|
}
|
|
1026
1017
|
if (action === _constant.UIAction.TOGGLE_LAYOUT_SIZE) {
|
|
1027
|
-
var
|
|
1028
|
-
size =
|
|
1018
|
+
var _ref4 = payload,
|
|
1019
|
+
size = _ref4.size;
|
|
1029
1020
|
this.setGalleryMaxSize(size);
|
|
1030
1021
|
}
|
|
1031
1022
|
if (action === _constant.UIAction.SET_MAIN_SPEAKER) {
|
|
1032
|
-
var
|
|
1033
|
-
userId =
|
|
1023
|
+
var _ref5 = payload,
|
|
1024
|
+
userId = _ref5.userId;
|
|
1034
1025
|
}
|
|
1035
1026
|
if (action === _constant.UIAction.SET_USER_PIN_STATE) {
|
|
1036
|
-
var
|
|
1037
|
-
_userId =
|
|
1027
|
+
var _ref6 = payload,
|
|
1028
|
+
_userId = _ref6.userId;
|
|
1038
1029
|
this.handleSetPinState(_userId);
|
|
1039
1030
|
}
|
|
1040
1031
|
if (action === _constant.UIAction.TOGGLE_LAYOUT_BAR_LOCK) {
|
|
1041
1032
|
this.toggleLayoutBarLock(payload);
|
|
1042
1033
|
}
|
|
1043
1034
|
if (action === _constant.UIAction.VIDEO_WINDOW_BOUNDS) {
|
|
1044
|
-
var
|
|
1045
|
-
videoWindowPreviewType =
|
|
1035
|
+
var _ref7 = payload,
|
|
1036
|
+
videoWindowPreviewType = _ref7.videoWindowPreviewType;
|
|
1046
1037
|
this.videoWindowPreviewType = videoWindowPreviewType;
|
|
1047
1038
|
}
|
|
1048
1039
|
if (action === _constant.UIAction.TOGGLE_LAYOUT_ACTIONBAR_HIDDEN) {
|
|
1049
1040
|
this.toggleLayoutBarHidden();
|
|
1050
1041
|
}
|
|
1051
1042
|
if (action === _constant.UIAction.VIDEO_WINDOW_PIN_ACTION) {
|
|
1052
|
-
var
|
|
1053
|
-
_action =
|
|
1054
|
-
streamId =
|
|
1043
|
+
var _ref8 = payload,
|
|
1044
|
+
_action = _ref8.action,
|
|
1045
|
+
streamId = _ref8.streamId;
|
|
1055
1046
|
if (_action === _constant.VideoWindowPinType.REMOVE_PIN) {
|
|
1056
1047
|
this.removePin(streamId);
|
|
1057
1048
|
} else if (_action === _constant.VideoWindowPinType.ADD_PIN) {
|
|
@@ -1059,9 +1050,9 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1059
1050
|
}
|
|
1060
1051
|
}
|
|
1061
1052
|
if (action === _constant.UIAction.SPOTLIGHT_STREAM_CHANGED) {
|
|
1062
|
-
var
|
|
1063
|
-
type =
|
|
1064
|
-
_streamId =
|
|
1053
|
+
var _ref9 = payload,
|
|
1054
|
+
type = _ref9.type,
|
|
1055
|
+
_streamId = _ref9.streamId;
|
|
1065
1056
|
if (type === 'add') {
|
|
1066
1057
|
this.spotlightStreamId = _streamId;
|
|
1067
1058
|
} else {
|
|
@@ -1069,9 +1060,9 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1069
1060
|
}
|
|
1070
1061
|
}
|
|
1071
1062
|
if (action === _constant.UIAction.CUSTOM_SETTINGS_CHANGED) {
|
|
1072
|
-
var
|
|
1073
|
-
spotlightEnabled =
|
|
1074
|
-
shouldHideNonVideoParticipants =
|
|
1063
|
+
var _ref10 = payload,
|
|
1064
|
+
spotlightEnabled = _ref10.spotlightEnabled,
|
|
1065
|
+
shouldHideNonVideoParticipants = _ref10.shouldHideNonVideoParticipants;
|
|
1075
1066
|
this.shouldHideNonVideoParticipants = shouldHideNonVideoParticipants;
|
|
1076
1067
|
this.enableSpotlight = spotlightEnabled;
|
|
1077
1068
|
if (shouldHideNonVideoParticipants) {
|
|
@@ -1082,10 +1073,10 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1082
1073
|
}
|
|
1083
1074
|
}
|
|
1084
1075
|
if (action === _constant.UIAction.WHITEBOARD_CHANGED) {
|
|
1085
|
-
var
|
|
1086
|
-
changeAction =
|
|
1087
|
-
isLoneyWindow =
|
|
1088
|
-
if (changeAction ===
|
|
1076
|
+
var _ref11 = payload,
|
|
1077
|
+
changeAction = _ref11.action,
|
|
1078
|
+
isLoneyWindow = _ref11.payload;
|
|
1079
|
+
if (changeAction === _type4.WhiteboardControlbarEvents.LONEYWINDOW) {
|
|
1089
1080
|
if (isLoneyWindow) {
|
|
1090
1081
|
this._videoWindowDataSource.removeBoard();
|
|
1091
1082
|
} else {
|
|
@@ -1094,85 +1085,228 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1094
1085
|
this._videoWindowDataSource.addBoard(ownerUser, ownerUserId === this.localUserId, this._securityStore.hasWriteBoardPermission());
|
|
1095
1086
|
}
|
|
1096
1087
|
}
|
|
1097
|
-
if (changeAction ===
|
|
1098
|
-
var
|
|
1099
|
-
_ownerUserId =
|
|
1100
|
-
this.ownerUser = _ownerUserId ? this._userControl.getUser(_ownerUserId) :
|
|
1088
|
+
if (changeAction === _type4.WhiteboardBaseEvents.SET_OWNER_USER_ID) {
|
|
1089
|
+
var _ref12 = payload,
|
|
1090
|
+
_ownerUserId = _ref12.payload;
|
|
1091
|
+
this.ownerUser = _ownerUserId ? this._userControl.getUser(_ownerUserId) : undefined;
|
|
1101
1092
|
}
|
|
1102
1093
|
}
|
|
1094
|
+
if (action === _constant.UIAction.WAITING_ROOM_CREATED) {
|
|
1095
|
+
var room = payload.room;
|
|
1096
|
+
this._waitingRoomControl = room;
|
|
1097
|
+
this._waitingRoomControl.addObserver(this._waitingRoomObserver);
|
|
1098
|
+
this._waitingRoomUserControl = room.getUserControl();
|
|
1099
|
+
this._waitingRoomUserControl.addObserver(this._waitingRoomUserObserver);
|
|
1100
|
+
}
|
|
1103
1101
|
}
|
|
1104
1102
|
}, {
|
|
1105
|
-
key: "
|
|
1106
|
-
value: function
|
|
1107
|
-
this
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
this.
|
|
1114
|
-
|
|
1103
|
+
key: "_addListeners",
|
|
1104
|
+
value: function _addListeners() {
|
|
1105
|
+
var _this6 = this;
|
|
1106
|
+
this._uiEventStore.addObserver({
|
|
1107
|
+
onEvent: this.onEvent
|
|
1108
|
+
});
|
|
1109
|
+
this._streamControl.addObserver({
|
|
1110
|
+
onStreamsAdded: this._onStreamsAdded,
|
|
1111
|
+
onStreamsUpdated: this._onStreamsUpdated,
|
|
1112
|
+
onStreamsRemoved: this._onStreamsRemoved,
|
|
1113
|
+
onStreamVolumeIndicationUpdated: this._onAudioVolumeUpdated
|
|
1114
|
+
});
|
|
1115
|
+
this._userControl.addObserver({
|
|
1116
|
+
onUserInfoUpdated: this.onUserInfoUpdated,
|
|
1117
|
+
onAllUserCountUpdated: this._onAllUserCountUpdated
|
|
1118
|
+
});
|
|
1119
|
+
this._videoWindowDataSource.addObserver({
|
|
1120
|
+
onLayoutUpdated: this._handleLayoutUpdated,
|
|
1121
|
+
onFoldListAdded: this._handleFoldListChanged,
|
|
1122
|
+
onFoldListRemoved: this._handleFoldListChanged,
|
|
1123
|
+
onFoldListUpdated: this._handleFoldListChanged,
|
|
1124
|
+
onMainListAdded: this._handleMainListChanged,
|
|
1125
|
+
onMainListUpdated: this._handleMainListChanged,
|
|
1126
|
+
onMainListRemoved: this._handleMainListChanged,
|
|
1127
|
+
onSpotlightAdded: this._handleSpotlightAdded,
|
|
1128
|
+
onSpotlightRemoved: this._handleSpotlightRemoved
|
|
1129
|
+
});
|
|
1130
|
+
this._whiteBoardControl.addObserver({
|
|
1131
|
+
onActive: function onActive() {
|
|
1132
|
+
return _this6.setWhiteboardActive(true);
|
|
1133
|
+
},
|
|
1134
|
+
onInactive: function onInactive() {
|
|
1135
|
+
return _this6.setWhiteboardActive(false);
|
|
1136
|
+
}
|
|
1137
|
+
});
|
|
1138
|
+
this._chatRoomControl.addObserver(this._chatRoomObserver);
|
|
1139
|
+
this._subscriptions.push((0, _mobx.reaction)(function () {
|
|
1140
|
+
return _this6.mainList.length;
|
|
1141
|
+
}, function (length) {
|
|
1142
|
+
if (length < 2) {
|
|
1143
|
+
if (_this6.layout === _type3.FcrUIVideoWindowLayoutType.Speaker) {
|
|
1144
|
+
_this6.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Gallery);
|
|
1145
|
+
}
|
|
1146
|
+
}
|
|
1147
|
+
_this6._uiEventStore.sendEvent(_constant.UIAction.MAIN_LIST_LENGTH_CHANGED, length);
|
|
1148
|
+
}), (0, _mobx.reaction)(function () {
|
|
1149
|
+
return _this6.whiteboardActive;
|
|
1150
|
+
}, function (opened) {
|
|
1151
|
+
if (opened) {
|
|
1152
|
+
var ownerUserId = _this6._whiteBoardControl.getBoardActiveInfo().ownerUserId;
|
|
1153
|
+
var ownerUser = _this6._userControl.getUser(ownerUserId);
|
|
1154
|
+
_this6._videoWindowDataSource.addBoard(ownerUser, ownerUserId === _this6.localUserId);
|
|
1155
|
+
if (_this6.layout === _type3.FcrUIVideoWindowLayoutType.Gallery) {
|
|
1156
|
+
_this6.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Speaker);
|
|
1157
|
+
}
|
|
1158
|
+
} else {
|
|
1159
|
+
_this6._videoWindowDataSource.removeBoard();
|
|
1160
|
+
}
|
|
1161
|
+
}), (0, _mobx.reaction)(function () {
|
|
1162
|
+
return _this6._securityStore.hasWriteBoardPermission();
|
|
1163
|
+
}, function (canEdit) {
|
|
1164
|
+
if (!_this6.mainList.some(function (u) {
|
|
1165
|
+
return u.type === _type3.FcrUIWindowType.BOARD;
|
|
1166
|
+
})) return;
|
|
1167
|
+
_this6._videoWindowDataSource.updateBoard(canEdit);
|
|
1168
|
+
}), (0, _mobx.reaction)(function () {
|
|
1169
|
+
return _this6.galleryMaxSize;
|
|
1170
|
+
}, function (size) {
|
|
1171
|
+
_this6._uiEventStore.notifyLayoutSizeChanged({
|
|
1172
|
+
size: size
|
|
1173
|
+
});
|
|
1174
|
+
}), (0, _mobx.reaction)(function () {
|
|
1175
|
+
return _this6.asideContent;
|
|
1176
|
+
}, function (asideContent) {
|
|
1177
|
+
if (asideContent.participant || asideContent.chat) {
|
|
1178
|
+
_this6.toggleAside(true);
|
|
1179
|
+
}
|
|
1180
|
+
if (!asideContent.participant && !asideContent.chat) {
|
|
1181
|
+
_this6.toggleAside(false);
|
|
1182
|
+
}
|
|
1183
|
+
}, {
|
|
1184
|
+
fireImmediately: true
|
|
1185
|
+
}), (0, _mobx.reaction)(function () {
|
|
1186
|
+
return {
|
|
1187
|
+
cameraEnabled: _this6._deviceStore.cameraEnabled,
|
|
1188
|
+
cameraId: _this6._deviceStore.cameraId
|
|
1189
|
+
};
|
|
1190
|
+
}, function (_ref13) {
|
|
1191
|
+
var cameraEnabled = _ref13.cameraEnabled,
|
|
1192
|
+
cameraId = _ref13.cameraId;
|
|
1193
|
+
if (!cameraEnabled && _this6._localView) {
|
|
1194
|
+
_this6.stopLocalPreview(_this6._localView);
|
|
1195
|
+
}
|
|
1196
|
+
if (cameraEnabled && cameraId && _this6._localView) {
|
|
1197
|
+
_this6.startLocalPreview(_this6._localView);
|
|
1198
|
+
}
|
|
1199
|
+
}), (0, _mobx.reaction)(function () {
|
|
1200
|
+
return _this6.barLocked;
|
|
1201
|
+
}, function (barLocked) {
|
|
1202
|
+
if (_this6._barLockTimer && barLocked) {
|
|
1203
|
+
_this6.resetLockTimer();
|
|
1204
|
+
} else {
|
|
1205
|
+
_this6.setHoveringHandler();
|
|
1206
|
+
}
|
|
1207
|
+
}), (0, _mobx.reaction)(function () {
|
|
1208
|
+
return _this6._deviceStore.microphoneVolumeLevel;
|
|
1209
|
+
}, function (volume) {
|
|
1210
|
+
(0, _mobx.runInAction)(function () {
|
|
1211
|
+
_this6.userVolumeMap.set('0', volume);
|
|
1212
|
+
});
|
|
1213
|
+
}), (0, _mobx.reaction)(function () {
|
|
1214
|
+
return {
|
|
1215
|
+
count: _this6.participantCount,
|
|
1216
|
+
enableSpotlight: _this6.enableSpotlight
|
|
1217
|
+
};
|
|
1218
|
+
}, function (_ref14) {
|
|
1219
|
+
var count = _ref14.count,
|
|
1220
|
+
enableSpotlight = _ref14.enableSpotlight;
|
|
1221
|
+
var enableSetSpotlight = _this6._isSetSpotlightEnable(count, enableSpotlight);
|
|
1222
|
+
_this6._videoWindowDataSource.setSpotlightEnabled(enableSetSpotlight);
|
|
1223
|
+
}),
|
|
1224
|
+
// 录制的特殊逻辑:
|
|
1225
|
+
// 因为录制机器人不发流,且当前切换布局的逻辑是有多个人的视频窗口才切换到 speaker layout
|
|
1226
|
+
// 所以当房间只有主持人的时候录制机器人的视角不会切换到 speaker layout,故加上以下逻辑
|
|
1227
|
+
(0, _mobx.reaction)(function () {
|
|
1228
|
+
var _this6$currentShareDa;
|
|
1229
|
+
return (_this6$currentShareDa = _this6.currentShareData) === null || _this6$currentShareDa === void 0 ? void 0 : _this6$currentShareDa.hasScreenSharing;
|
|
1230
|
+
}, function (hasScreenSharing) {
|
|
1231
|
+
if (_this6.isRobot) {
|
|
1232
|
+
if (hasScreenSharing) {
|
|
1233
|
+
_this6.logger.info('set layout to speaker for robot');
|
|
1234
|
+
_this6.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Speaker);
|
|
1235
|
+
} else {
|
|
1236
|
+
_this6.logger.info('set layout to gallery for robot');
|
|
1237
|
+
_this6.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Gallery);
|
|
1238
|
+
}
|
|
1239
|
+
}
|
|
1240
|
+
}, {
|
|
1241
|
+
fireImmediately: true
|
|
1242
|
+
}));
|
|
1115
1243
|
}
|
|
1116
1244
|
}, {
|
|
1117
|
-
key: "
|
|
1118
|
-
|
|
1119
|
-
|
|
1245
|
+
key: "_handleFoldListChanged",
|
|
1246
|
+
value: function _handleFoldListChanged() {
|
|
1247
|
+
this._uiEventStore.sendEvent(_constant.UIAction.FOLD_LIST_CHANGED, this.foldList);
|
|
1120
1248
|
}
|
|
1121
1249
|
}, {
|
|
1122
|
-
key: "
|
|
1123
|
-
value: function
|
|
1124
|
-
|
|
1125
|
-
case 'public':
|
|
1126
|
-
this._securityStore.setAllowedPublicChatAndDisallowedPrivateChat();
|
|
1127
|
-
break;
|
|
1128
|
-
case 'private_to_manager':
|
|
1129
|
-
this._securityStore.setDisallowedPublicChatAndDisallowedPrivateChatToParticipant();
|
|
1130
|
-
break;
|
|
1131
|
-
}
|
|
1250
|
+
key: "_handleMainListChanged",
|
|
1251
|
+
value: function _handleMainListChanged() {
|
|
1252
|
+
this._uiEventStore.sendEvent(_constant.UIAction.MAIN_LIST_CHANGED, this.mainList);
|
|
1132
1253
|
}
|
|
1133
1254
|
}, {
|
|
1134
|
-
key: "
|
|
1135
|
-
|
|
1136
|
-
|
|
1255
|
+
key: "_switchToSpeaker",
|
|
1256
|
+
value: function _switchToSpeaker() {
|
|
1257
|
+
this.collapsed = false;
|
|
1137
1258
|
}
|
|
1138
1259
|
}, {
|
|
1139
|
-
key: "
|
|
1140
|
-
|
|
1141
|
-
|
|
1260
|
+
key: "_switchToGallery",
|
|
1261
|
+
value: function _switchToGallery() {
|
|
1262
|
+
this.collapsed = true;
|
|
1142
1263
|
}
|
|
1143
1264
|
}, {
|
|
1144
|
-
key: "
|
|
1145
|
-
|
|
1146
|
-
|
|
1265
|
+
key: "_setBarHovering",
|
|
1266
|
+
value: function _setBarHovering(state) {
|
|
1267
|
+
this.barHovering = state;
|
|
1147
1268
|
}
|
|
1148
1269
|
}, {
|
|
1149
|
-
key: "
|
|
1150
|
-
|
|
1151
|
-
|
|
1270
|
+
key: "_onAllUserCountUpdated",
|
|
1271
|
+
value: function _onAllUserCountUpdated(_roomId, count) {
|
|
1272
|
+
this.participantCount = count;
|
|
1152
1273
|
}
|
|
1153
1274
|
}, {
|
|
1154
|
-
key: "
|
|
1155
|
-
value: function
|
|
1156
|
-
this
|
|
1157
|
-
|
|
1158
|
-
|
|
1275
|
+
key: "_initStream",
|
|
1276
|
+
value: function _initStream() {
|
|
1277
|
+
var _this7 = this;
|
|
1278
|
+
var isSharingScreen = false;
|
|
1279
|
+
this._streamControl.getStreamList().forEach(function (stream) {
|
|
1280
|
+
if (stream.videoSourceType === _agoraEduCore.FcrVideoSourceType.SCREEN) {
|
|
1281
|
+
isSharingScreen = true;
|
|
1282
|
+
}
|
|
1283
|
+
_this7._handleStreamAdded(stream);
|
|
1159
1284
|
});
|
|
1285
|
+
if (isSharingScreen && this.layout === _type3.FcrUIVideoWindowLayoutType.Gallery) {
|
|
1286
|
+
this.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Speaker);
|
|
1287
|
+
}
|
|
1160
1288
|
}
|
|
1161
1289
|
}, {
|
|
1162
|
-
key: "
|
|
1163
|
-
value: function
|
|
1164
|
-
|
|
1290
|
+
key: "_isSetSpotlightEnable",
|
|
1291
|
+
value: function _isSetSpotlightEnable(count, enableSpotlight) {
|
|
1292
|
+
var setSpotlightEnable = count > LayoutStore.MIN_USERS_TO_ENABLE_SPOTLIGHT;
|
|
1293
|
+
return setSpotlightEnable && enableSpotlight;
|
|
1165
1294
|
}
|
|
1166
1295
|
}, {
|
|
1167
|
-
key: "
|
|
1168
|
-
|
|
1169
|
-
|
|
1296
|
+
key: "_handleSpotlightAdded",
|
|
1297
|
+
value: function _handleSpotlightAdded(streamId) {
|
|
1298
|
+
this._uiEventStore.notifySpotlightStreamChanged({
|
|
1299
|
+
type: 'add',
|
|
1300
|
+
streamId: streamId
|
|
1301
|
+
});
|
|
1170
1302
|
}
|
|
1171
1303
|
}, {
|
|
1172
|
-
key: "
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1304
|
+
key: "_handleSpotlightRemoved",
|
|
1305
|
+
value: function _handleSpotlightRemoved(streamId) {
|
|
1306
|
+
this._uiEventStore.notifySpotlightStreamChanged({
|
|
1307
|
+
type: 'remove',
|
|
1308
|
+
streamId: streamId
|
|
1309
|
+
});
|
|
1176
1310
|
}
|
|
1177
1311
|
}, {
|
|
1178
1312
|
key: "_handleConnectionUpdated",
|
|
@@ -1182,9 +1316,9 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1182
1316
|
}, {
|
|
1183
1317
|
key: "_handleStreamAdded",
|
|
1184
1318
|
value: function _handleStreamAdded(modifiedStream) {
|
|
1185
|
-
if (modifiedStream.videoSourceType ===
|
|
1186
|
-
if (this.layout ===
|
|
1187
|
-
this.toggleLayout(
|
|
1319
|
+
if (modifiedStream.videoSourceType === _agoraEduCore.FcrVideoSourceType.SCREEN) {
|
|
1320
|
+
if (this.layout === _type3.FcrUIVideoWindowLayoutType.Gallery) {
|
|
1321
|
+
this.toggleLayout(_type3.FcrUIVideoWindowLayoutType.Speaker);
|
|
1188
1322
|
}
|
|
1189
1323
|
}
|
|
1190
1324
|
this._videoWindowDataSource.add(modifiedStream, modifiedStream.owner.userId === this.getLocalUserId());
|
|
@@ -1192,29 +1326,38 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1192
1326
|
}, {
|
|
1193
1327
|
key: "_onStreamsAdded",
|
|
1194
1328
|
value: function _onStreamsAdded(roomId, events) {
|
|
1195
|
-
var
|
|
1329
|
+
var _this8 = this;
|
|
1196
1330
|
events.forEach(function (_ref15) {
|
|
1197
1331
|
var modifiedStream = _ref15.modifiedStream;
|
|
1198
|
-
|
|
1332
|
+
_this8._handleStreamAdded(modifiedStream);
|
|
1199
1333
|
});
|
|
1200
1334
|
}
|
|
1201
1335
|
}, {
|
|
1202
1336
|
key: "_onStreamsUpdated",
|
|
1203
1337
|
value: function _onStreamsUpdated(roomId, events) {
|
|
1204
|
-
var
|
|
1338
|
+
var _this9 = this;
|
|
1205
1339
|
events.forEach(function (_ref16) {
|
|
1206
1340
|
var modifiedStream = _ref16.modifiedStream;
|
|
1207
|
-
|
|
1341
|
+
_this9._videoWindowDataSource.update(modifiedStream);
|
|
1208
1342
|
});
|
|
1209
1343
|
}
|
|
1210
1344
|
}, {
|
|
1211
1345
|
key: "_onStreamsRemoved",
|
|
1212
1346
|
value: function _onStreamsRemoved(roomId, events) {
|
|
1213
|
-
var
|
|
1347
|
+
var _this10 = this;
|
|
1214
1348
|
events.forEach(function (_ref17) {
|
|
1215
1349
|
var modifiedStream = _ref17.modifiedStream;
|
|
1216
|
-
|
|
1350
|
+
_this10._videoWindowDataSource["delete"](modifiedStream);
|
|
1217
1351
|
});
|
|
1352
|
+
var hasScreenStream = events === null || events === void 0 ? void 0 : events.find(function (event) {
|
|
1353
|
+
var type = event.modifiedStream.streamType;
|
|
1354
|
+
return type === _type6.AgoraRteMediaStreamType.BOTH || type === _type6.AgoraRteMediaStreamType.VIDEO;
|
|
1355
|
+
});
|
|
1356
|
+
if (hasScreenStream && this.manualLayout) {
|
|
1357
|
+
this._uiEventStore.sendEvent(_constant.UIAction.TOGGLE_LAYOUT, {
|
|
1358
|
+
layout: this.manualLayout
|
|
1359
|
+
});
|
|
1360
|
+
}
|
|
1218
1361
|
}
|
|
1219
1362
|
}, {
|
|
1220
1363
|
key: "_onAudioVolumeUpdated",
|
|
@@ -1225,14 +1368,14 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1225
1368
|
}, {
|
|
1226
1369
|
key: "_findSpotlightStream",
|
|
1227
1370
|
value: function _findSpotlightStream() {
|
|
1228
|
-
var
|
|
1371
|
+
var _this11 = this;
|
|
1229
1372
|
//find the max volume stream
|
|
1230
1373
|
var res = {
|
|
1231
1374
|
streamId: '',
|
|
1232
1375
|
volume: 0
|
|
1233
1376
|
};
|
|
1234
1377
|
this.userVolumeMap.forEach(function (volume, id) {
|
|
1235
|
-
var windowData =
|
|
1378
|
+
var windowData = _this11.mainListMapByAudioStreamId.get(id);
|
|
1236
1379
|
if (id !== '0' && !res.streamId && volume > 0 && windowData !== null && windowData !== void 0 && windowData.hasMicrophoneAudioStream) {
|
|
1237
1380
|
res = {
|
|
1238
1381
|
streamId: windowData.windowId,
|
|
@@ -1242,10 +1385,42 @@ var LayoutStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
1242
1385
|
});
|
|
1243
1386
|
return res;
|
|
1244
1387
|
}
|
|
1388
|
+
}, {
|
|
1389
|
+
key: "_handleRemoteWaitingUserLeft",
|
|
1390
|
+
value: function _handleRemoteWaitingUserLeft(roomId, events) {
|
|
1391
|
+
var _this$_privilegeContr;
|
|
1392
|
+
var targetRoles = (_this$_privilegeContr = this._privilegeControl.getSecurityInfo(_type7.FcrSecurityAction.WaitingRoom).info) === null || _this$_privilegeContr === void 0 ? void 0 : _this$_privilegeContr.targetRoles;
|
|
1393
|
+
if (this._waitingRoomUserControl) {
|
|
1394
|
+
var users = this._waitingRoomUserControl.getUsers();
|
|
1395
|
+
var userCount = Object.entries(users).map(function (_ref18) {
|
|
1396
|
+
var _ref19 = (0, _slicedToArray2["default"])(_ref18, 2),
|
|
1397
|
+
userId = _ref19[0],
|
|
1398
|
+
user = _ref19[1];
|
|
1399
|
+
return user;
|
|
1400
|
+
}).filter(function (user) {
|
|
1401
|
+
return targetRoles.includes(user.userRole);
|
|
1402
|
+
}).length;
|
|
1403
|
+
if (userCount === 0) {
|
|
1404
|
+
this._uiEventStore.sendEvent(_constant.UIAction.COLSE_NOTIFICATION, _eventStore.NotificationContentType.WAITING_ROOM);
|
|
1405
|
+
}
|
|
1406
|
+
}
|
|
1407
|
+
}
|
|
1408
|
+
}, {
|
|
1409
|
+
key: "_handleMessageReceived",
|
|
1410
|
+
value: function _handleMessageReceived(roomId, message) {
|
|
1411
|
+
if ((0, _get["default"])(message, 'payload.data.messageKey') === _type.RoomMessageKey.USER_WAITING_ROOM_JOINED && this.isWaitingRoomNotify) {
|
|
1412
|
+
this._uiEventStore.showNotification({
|
|
1413
|
+
type: _eventStore.NotificationContentType.WAITING_ROOM,
|
|
1414
|
+
onOk: this.notifyParticipantShowWaitingRoom,
|
|
1415
|
+
onClose: this.setIsWaitingRoomNotify,
|
|
1416
|
+
placement: 'topLeft'
|
|
1417
|
+
});
|
|
1418
|
+
}
|
|
1419
|
+
}
|
|
1245
1420
|
}]);
|
|
1246
1421
|
}();
|
|
1247
1422
|
_LayoutStore = LayoutStore;
|
|
1248
|
-
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_LayoutStore, [[_participantDecs, 17, "participant"], [_chatDecs, 17, "chat"], [_chatActionDecs, 17, "chatAction"], [_stateBarDecs, 17, "stateBar"], [_actionBarDecs, 17, "actionBar"], [_layersDecs, 17, "layers"], [_whiteboardDecs, 17, "whiteboard"], [_mobx.observable, 1, "collapsed"], [_mobx.observable, 1, "galleryMaxSize"], [_mobx.observable, 1, "aside"], [_mobx.observable, 1, "asideContent"], [_mobx.observable, 1, "localUserRole"], [_mobx.observable, 1, "barHovering"], [_mobx.observable, 1, "barLocked"], [_mobx.observable, 1, "barHidden"], [_mobx.observable, 1, "asideWidth"], [_mobx.observable, 1, "userVolumeMap"], [_mobx.observable, 1, "chatRoomState"], [_mobx.observable, 1, "videoWindowPreviewType"], [_mobx.observable, 1, "whiteboardActive"], [_mobx.observable, 1, "spotlightStreamId"], [_mobx.observable, 1, "shouldHideNonVideoParticipants"], [_mobx.observable, 1, "participantCount"], [_mobx.observable, 1, "ownerUser"], [_mobx.observable, 1, "localUser"], [_mobx.observable, 1, "
|
|
1423
|
+
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_LayoutStore, [[_participantDecs, 17, "participant"], [_chatDecs, 17, "chat"], [_chatActionDecs, 17, "chatAction"], [_stateBarDecs, 17, "stateBar"], [_actionBarDecs, 17, "actionBar"], [_layersDecs, 17, "layers"], [_whiteboardDecs, 17, "whiteboard"], [_mobx.observable, 1, "collapsed"], [_mobx.observable, 1, "galleryMaxSize"], [_mobx.observable, 1, "aside"], [_mobx.observable, 1, "asideContent"], [_mobx.observable, 1, "localUserRole"], [_mobx.observable, 1, "barHovering"], [_mobx.observable, 1, "barLocked"], [_mobx.observable, 1, "barHidden"], [_mobx.observable, 1, "asideWidth"], [_mobx.observable, 1, "userVolumeMap"], [_mobx.observable, 1, "chatRoomState"], [_mobx.observable, 1, "videoWindowPreviewType"], [_mobx.observable, 1, "whiteboardActive"], [_mobx.observable, 1, "spotlightStreamId"], [_mobx.observable, 1, "shouldHideNonVideoParticipants"], [_mobx.observable, 1, "participantCount"], [_mobx.observable, 1, "ownerUser"], [_mobx.observable, 1, "localUser"], [_mobx.observable, 1, "enableSpotlight"], [_mobx.observable, 1, "isWaitingRoomNotify"], [_mobx.computed, 3, "isWaterMarkEnabled"], [_mobx.computed, 3, "isMulti"], [_mobx.computed, 3, "layout"], [_mobx.computed, 3, "manualLayout"], [_mobx.computed, 3, "mainList"], [_mobx.computed, 3, "mainListMapByAudioStreamId"], [_mobx.computed, 3, "foldList"], [_mobx.computed, 3, "galleryList"], [_mobx.computed, 3, "carouselList"], [_mobx.computed, 3, "hasPinnedStream"], [_mobx.computed, 3, "isManager"], [_mobx.computed, 3, "isRobot"], [_mobx.computed, 3, "findSpotlightUser"], [_mobx.computed, 3, "microphoneEnabled"], [_mobx.computed, 3, "isHostOrCoHost"], [_decorator.bound, 2, "getWaterMarkContent"], [_notifyParticipantShowWaitingRoomDecs, 18, "notifyParticipantShowWaitingRoom"], [_setIsWaitingRoomNotifyDecs, 18, "setIsWaitingRoomNotify"], [_decorator.bound, 2, "hasMutePermission"], [_decorator.bound, 2, "hasUnmutePermission"], [_decorator.bound, 2, "hasRequestStartAudioPermission"], [_decorator.bound, 2, "toggleMainStream"], [_decorator.bound, 2, "addPin"], [_decorator.bound, 2, "removePin"], [_decorator.bound, 2, "setVideoOrientation"], [_decorator.bound, 2, "setAllowChat"], [_decorator.bound, 2, "handleSetPinState"], [_setWhiteboardActiveDecs, 18, "setWhiteboardActive"], [_setAsideWidthDecs, 18, "setAsideWidth"], [_updateSlotsDecs, 18, "updateSlots"], [_updateAsideContentDecs, 18, "updateAsideContent"], [_decorator.bound, 2, "closeParticipantFromAside"], [_decorator.bound, 2, "moveParticipantFromAsideToDialog"], [_decorator.bound, 2, "closeChatFromAside"], [_decorator.bound, 2, "closeAsideChat"], [_decorator.bound, 2, "moveChatFromAsideToDialog"], [_decorator.bound, 2, "openPrivateChat"], [_getAllowedOperationsDecs, 18, "getAllowedOperations"], [_toggleLayoutDecs, 18, "toggleLayout"], [_toggleCollapsedDecs, 18, "toggleCollapsed"], [_setGalleryMaxSizeDecs, 18, "setGalleryMaxSize"], [_toggleAsideDecs, 18, "toggleAside"], [_asideWidthChangedDecs, 18, "asideWidthChanged"], [_toggleLayoutBarLockDecs, 18, "toggleLayoutBarLock"], [_toggleLayoutBarHiddenDecs, 18, "toggleLayoutBarHidden"], [_resetLockTimerDecs, 18, "resetLockTimer"], [_setHoveringHandlerDecs, 18, "setHoveringHandler"], [_setHoveringLeaveHandlerDecs, 18, "setHoveringLeaveHandler"], [_onUserInfoUpdatedDecs, 18, "onUserInfoUpdated"], [_mobx.action, 2, "setLocalUserRole"], [_decorator.bound, 2, "stopLocalPreview"], [_decorator.bound, 2, "startLocalPreview"], [_decorator.bound, 2, "setAllowChatWithPayload"], [_decorator.bound, 2, "muteAudio"], [_decorator.bound, 2, "sendParticipantEvent"], [_decorator.bound, 2, "onEvent"], [_decorator.bound, 2, "_addListeners"], [_handleFoldListChangedDecs, 18, "_handleFoldListChanged"], [_handleMainListChangedDecs, 18, "_handleMainListChanged"], [_mobx.action, 2, "_switchToSpeaker"], [_mobx.action, 2, "_switchToGallery"], [_setBarHoveringDecs, 18, "_setBarHovering"], [_onAllUserCountUpdatedDecs, 18, "_onAllUserCountUpdated"], [_decorator.bound, 2, "_initStream"], [_decorator.bound, 2, "_isSetSpotlightEnable"], [_decorator.bound, 2, "_handleSpotlightAdded"], [_decorator.bound, 2, "_handleSpotlightRemoved"], [_handleConnectionUpdatedDecs, 18, "_handleConnectionUpdated"], [_decorator.bound, 2, "_handleStreamAdded"], [_decorator.bound, 2, "_onStreamsAdded"], [_decorator.bound, 2, "_onStreamsUpdated"], [_decorator.bound, 2, "_onStreamsRemoved"], [_onAudioVolumeUpdatedDecs, 18, "_onAudioVolumeUpdated"], [_decorator.bound, 2, "_handleRemoteWaitingUserLeft"], [_decorator.bound, 2, "_handleMessageReceived"], [_handleLayoutUpdatedDecs, 16, "_handleLayoutUpdated"]], []).e, 29);
|
|
1249
1424
|
_init_participant = _applyDecs$e[0];
|
|
1250
1425
|
_init_chat = _applyDecs$e[1];
|
|
1251
1426
|
_init_chatAction = _applyDecs$e[2];
|
|
@@ -1271,8 +1446,8 @@ _init_shouldHideNonVideoParticipants = _applyDecs$e[21];
|
|
|
1271
1446
|
_init_participantCount = _applyDecs$e[22];
|
|
1272
1447
|
_init_ownerUser = _applyDecs$e[23];
|
|
1273
1448
|
_init_localUser = _applyDecs$e[24];
|
|
1274
|
-
|
|
1275
|
-
|
|
1449
|
+
_init_enableSpotlight = _applyDecs$e[25];
|
|
1450
|
+
_init_isWaitingRoomNotify = _applyDecs$e[26];
|
|
1276
1451
|
_init__handleLayoutUpdated = _applyDecs$e[27];
|
|
1277
1452
|
_initProto = _applyDecs$e[28];
|
|
1278
1453
|
(0, _defineProperty2["default"])(LayoutStore, "MIN_USERS_TO_ENABLE_SPOTLIGHT", 2);
|