fcr-ui-scene-mobile 3.4.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/lib/assets/ground_glass_bg.png +0 -0
- package/lib/base.d.ts +11 -0
- package/lib/base.js +39 -0
- package/lib/common/device-store.d.ts +86 -0
- package/lib/common/device-store.js +642 -0
- package/lib/common/device-stream-store.d.ts +26 -0
- package/lib/common/device-stream-store.js +298 -0
- package/lib/common/event-store.d.ts +124 -0
- package/lib/common/event-store.js +249 -0
- package/lib/common/global-context.d.ts +11 -0
- package/lib/common/global-context.js +9 -0
- package/lib/common/member-list-data-source.d.ts +28 -0
- package/lib/common/member-list-data-source.js +305 -0
- package/lib/common/participant-store.d.ts +195 -0
- package/lib/common/participant-store.js +1577 -0
- package/lib/common/security-store.d.ts +119 -0
- package/lib/common/security-store.js +948 -0
- package/lib/common/setting-store.d.ts +181 -0
- package/lib/common/setting-store.js +797 -0
- package/lib/common/type.d.ts +73 -0
- package/lib/common/type.js +22 -0
- package/lib/config/default-config.d.ts +32 -0
- package/lib/config/default-config.js +39 -0
- package/lib/config/setting-config.d.ts +16 -0
- package/lib/config/setting-config.js +17 -0
- package/lib/creator.d.ts +10 -0
- package/lib/creator.js +49 -0
- package/lib/global.d.ts +8 -0
- package/lib/hooks/meeting-time.d.ts +15 -0
- package/lib/hooks/meeting-time.js +92 -0
- package/lib/hooks/useIsNodePresent.d.ts +4 -0
- package/lib/hooks/useIsNodePresent.js +53 -0
- package/lib/hooks/useOnRefMount.d.ts +2 -0
- package/lib/hooks/useOnRefMount.js +27 -0
- package/lib/index.d.ts +6 -0
- package/lib/index.js +50 -0
- package/lib/mobile-global.css +28 -0
- package/lib/modules/action-bar/bottom-icons.d.ts +17 -0
- package/lib/modules/action-bar/bottom-icons.js +160 -0
- package/lib/modules/action-bar/context.d.ts +2 -0
- package/lib/modules/action-bar/context.js +9 -0
- package/lib/modules/action-bar/index.css +33 -0
- package/lib/modules/action-bar/index.d.ts +27 -0
- package/lib/modules/action-bar/index.js +46 -0
- package/lib/modules/action-bar/member-list-popup/attendee/index.css +130 -0
- package/lib/modules/action-bar/member-list-popup/attendee/index.d.ts +19 -0
- package/lib/modules/action-bar/member-list-popup/attendee/index.js +252 -0
- package/lib/modules/action-bar/member-list-popup/attendee/list.d.ts +1 -0
- package/lib/modules/action-bar/member-list-popup/attendee/list.js +82 -0
- package/lib/modules/action-bar/member-list-popup/index.css +35 -0
- package/lib/modules/action-bar/member-list-popup/index.d.ts +7 -0
- package/lib/modules/action-bar/member-list-popup/index.js +40 -0
- package/lib/modules/action-bar/member-list-popup/participant-more-actions/index.css +0 -0
- package/lib/modules/action-bar/member-list-popup/participant-more-actions/index.d.ts +12 -0
- package/lib/modules/action-bar/member-list-popup/participant-more-actions/index.js +58 -0
- package/lib/modules/action-bar/more-popup/index.css +71 -0
- package/lib/modules/action-bar/more-popup/index.d.ts +2 -0
- package/lib/modules/action-bar/more-popup/index.js +126 -0
- package/lib/modules/action-bar/store.d.ts +196 -0
- package/lib/modules/action-bar/store.js +1425 -0
- package/lib/modules/action-bar/type.d.ts +6 -0
- package/lib/modules/action-bar/type.js +13 -0
- package/lib/modules/action-bar/view.d.ts +2 -0
- package/lib/modules/action-bar/view.js +75 -0
- package/lib/modules/audio-stream/ index.d.ts +19 -0
- package/lib/modules/audio-stream/ index.js +109 -0
- package/lib/modules/audio-stream/index.d.ts +25 -0
- package/lib/modules/audio-stream/index.js +135 -0
- package/lib/modules/chat/chat-bar/index.css +97 -0
- package/lib/modules/chat/chat-bar/index.d.ts +12 -0
- package/lib/modules/chat/chat-bar/index.js +129 -0
- package/lib/modules/chat/chat-notification/index.css +71 -0
- package/lib/modules/chat/chat-notification/index.d.ts +3 -0
- package/lib/modules/chat/chat-notification/index.js +75 -0
- package/lib/modules/chat/chat-select/index.css +183 -0
- package/lib/modules/chat/chat-select/index.d.ts +12 -0
- package/lib/modules/chat/chat-select/index.js +223 -0
- package/lib/modules/chat/contex.d.ts +2 -0
- package/lib/modules/chat/contex.js +9 -0
- package/lib/modules/chat/demo-wrapper.d.ts +1 -0
- package/lib/modules/chat/demo-wrapper.js +42 -0
- package/lib/modules/chat/index.css +108 -0
- package/lib/modules/chat/index.d.ts +28 -0
- package/lib/modules/chat/index.dev.d.ts +1 -0
- package/lib/modules/chat/index.dev.js +58 -0
- package/lib/modules/chat/index.js +208 -0
- package/lib/modules/chat/message-list.d.ts +22 -0
- package/lib/modules/chat/message-list.js +617 -0
- package/lib/modules/chat/mock.d.ts +2 -0
- package/lib/modules/chat/mock.js +283 -0
- package/lib/modules/chat/store.d.ts +183 -0
- package/lib/modules/chat/store.js +1101 -0
- package/lib/modules/chat/util.d.ts +6 -0
- package/lib/modules/chat/util.js +69 -0
- package/lib/modules/chat/view.d.ts +11 -0
- package/lib/modules/chat/view.js +414 -0
- package/lib/modules/layout/bottom-drawer/index.css +34 -0
- package/lib/modules/layout/bottom-drawer/index.d.ts +3 -0
- package/lib/modules/layout/bottom-drawer/index.js +129 -0
- package/lib/modules/layout/components/Layout.d.ts +1 -0
- package/lib/modules/layout/components/Layout.js +98 -0
- package/lib/modules/layout/components/equip-request-popup/index.css +30 -0
- package/lib/modules/layout/components/equip-request-popup/index.d.ts +3 -0
- package/lib/modules/layout/components/equip-request-popup/index.js +78 -0
- package/lib/modules/layout/components/index.css +78 -0
- package/lib/modules/layout/components/index.d.ts +2 -0
- package/lib/modules/layout/components/index.js +25 -0
- package/lib/modules/layout/context.d.ts +2 -0
- package/lib/modules/layout/context.js +9 -0
- package/lib/modules/layout/drawer-header/index.css +27 -0
- package/lib/modules/layout/drawer-header/index.d.ts +10 -0
- package/lib/modules/layout/drawer-header/index.js +54 -0
- package/lib/modules/layout/index.css +22 -0
- package/lib/modules/layout/index.d.ts +8 -0
- package/lib/modules/layout/index.js +47 -0
- package/lib/modules/layout/store.d.ts +59 -0
- package/lib/modules/layout/store.js +379 -0
- package/lib/modules/layout/type.d.ts +65 -0
- package/lib/modules/layout/type.js +52 -0
- package/lib/modules/layout/view.d.ts +2 -0
- package/lib/modules/layout/view.js +10 -0
- package/lib/modules/member-layout/context.d.ts +2 -0
- package/lib/modules/member-layout/context.js +9 -0
- package/lib/modules/member-layout/data.d.ts +2 -0
- package/lib/modules/member-layout/data.js +304 -0
- package/lib/modules/member-layout/grid/index.css +98 -0
- package/lib/modules/member-layout/grid/index.d.ts +21 -0
- package/lib/modules/member-layout/grid/index.js +316 -0
- package/lib/modules/member-layout/index.css +88 -0
- package/lib/modules/member-layout/index.d.ts +8 -0
- package/lib/modules/member-layout/index.js +45 -0
- package/lib/modules/member-layout/share-toast/index.css +30 -0
- package/lib/modules/member-layout/share-toast/index.d.ts +5 -0
- package/lib/modules/member-layout/share-toast/index.js +43 -0
- package/lib/modules/member-layout/speaker/index.css +30 -0
- package/lib/modules/member-layout/speaker/index.d.ts +9 -0
- package/lib/modules/member-layout/speaker/index.js +28 -0
- package/lib/modules/member-layout/store.d.ts +70 -0
- package/lib/modules/member-layout/store.js +479 -0
- package/lib/modules/member-layout/user/index.css +121 -0
- package/lib/modules/member-layout/user/index.d.ts +34 -0
- package/lib/modules/member-layout/user/index.js +355 -0
- package/lib/modules/member-layout/user/types.d.ts +16 -0
- package/lib/modules/member-layout/user/types.js +6 -0
- package/lib/modules/member-layout/view.d.ts +2 -0
- package/lib/modules/member-layout/view.js +225 -0
- package/lib/modules/state-bar/context.d.ts +2 -0
- package/lib/modules/state-bar/context.js +9 -0
- package/lib/modules/state-bar/index.css +79 -0
- package/lib/modules/state-bar/index.d.ts +17 -0
- package/lib/modules/state-bar/index.js +55 -0
- package/lib/modules/state-bar/leaving-room/index.css +14 -0
- package/lib/modules/state-bar/leaving-room/index.d.ts +7 -0
- package/lib/modules/state-bar/leaving-room/index.js +38 -0
- package/lib/modules/state-bar/meeting-detail/index.css +72 -0
- package/lib/modules/state-bar/meeting-detail/index.d.ts +2 -0
- package/lib/modules/state-bar/meeting-detail/index.js +59 -0
- package/lib/modules/state-bar/meeting-detail/meeting-info/copy.d.ts +4 -0
- package/lib/modules/state-bar/meeting-detail/meeting-info/copy.js +81 -0
- package/lib/modules/state-bar/meeting-detail/meeting-info/index.css +92 -0
- package/lib/modules/state-bar/meeting-detail/meeting-info/index.d.ts +2 -0
- package/lib/modules/state-bar/meeting-detail/meeting-info/index.js +188 -0
- package/lib/modules/state-bar/meeting-detail/net-quality/index.css +27 -0
- package/lib/modules/state-bar/meeting-detail/net-quality/index.d.ts +2 -0
- package/lib/modules/state-bar/meeting-detail/net-quality/index.js +87 -0
- package/lib/modules/state-bar/store.d.ts +76 -0
- package/lib/modules/state-bar/store.js +561 -0
- package/lib/modules/state-bar/view.d.ts +7 -0
- package/lib/modules/state-bar/view.js +215 -0
- package/lib/modules/whiteboard/app.d.ts +2 -0
- package/lib/modules/whiteboard/app.js +41 -0
- package/lib/modules/whiteboard/components/control-bar/index.css +53 -0
- package/lib/modules/whiteboard/components/control-bar/index.d.ts +2 -0
- package/lib/modules/whiteboard/components/control-bar/index.js +156 -0
- package/lib/modules/whiteboard/components/control-bar/store.d.ts +35 -0
- package/lib/modules/whiteboard/components/control-bar/store.js +288 -0
- package/lib/modules/whiteboard/components/loading/index.css +76 -0
- package/lib/modules/whiteboard/components/loading/index.d.ts +2 -0
- package/lib/modules/whiteboard/components/loading/index.js +68 -0
- package/lib/modules/whiteboard/components/loading/loading.png +0 -0
- package/lib/modules/whiteboard/components/multi-window/index.css +65 -0
- package/lib/modules/whiteboard/components/multi-window/index.d.ts +5 -0
- package/lib/modules/whiteboard/components/multi-window/index.js +39 -0
- package/lib/modules/whiteboard/components/pagination/index.css +228 -0
- package/lib/modules/whiteboard/components/pagination/index.d.ts +15 -0
- package/lib/modules/whiteboard/components/pagination/index.js +163 -0
- package/lib/modules/whiteboard/components/pagination/store.d.ts +18 -0
- package/lib/modules/whiteboard/components/pagination/store.js +17 -0
- package/lib/modules/whiteboard/components/progress/index.d.ts +5 -0
- package/lib/modules/whiteboard/components/progress/index.js +43 -0
- package/lib/modules/whiteboard/components/progress/style.css +52 -0
- package/lib/modules/whiteboard/components/scene-pagination.d.ts +1 -0
- package/lib/modules/whiteboard/components/scene-pagination.js +30 -0
- package/lib/modules/whiteboard/components/switch-theme/index.css +98 -0
- package/lib/modules/whiteboard/components/switch-theme/index.d.ts +3 -0
- package/lib/modules/whiteboard/components/switch-theme/index.js +89 -0
- package/lib/modules/whiteboard/components/switch-theme/item.d.ts +9 -0
- package/lib/modules/whiteboard/components/switch-theme/item.js +53 -0
- package/lib/modules/whiteboard/components/switch-theme/libs.d.ts +4 -0
- package/lib/modules/whiteboard/components/switch-theme/libs.js +29 -0
- package/lib/modules/whiteboard/components/toolbar/ style.css +588 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/color.d.ts +5 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/color.js +38 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/panel.d.ts +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/panel.js +107 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/picker.d.ts +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/picker.js +59 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/index.d.ts +2 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/index.js +44 -0
- package/lib/modules/whiteboard/components/toolbar/components/eraser-picker.d.ts +4 -0
- package/lib/modules/whiteboard/components/toolbar/components/eraser-picker.js +89 -0
- package/lib/modules/whiteboard/components/toolbar/components/extra-tool-picker.d.ts +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/extra-tool-picker.js +63 -0
- package/lib/modules/whiteboard/components/toolbar/components/history.d.ts +2 -0
- package/lib/modules/whiteboard/components/toolbar/components/history.js +46 -0
- package/lib/modules/whiteboard/components/toolbar/components/icons/fold-icon.d.ts +2 -0
- package/lib/modules/whiteboard/components/toolbar/components/icons/fold-icon.js +39 -0
- package/lib/modules/whiteboard/components/toolbar/components/icons/move-icon.d.ts +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/icons/move-icon.js +66 -0
- package/lib/modules/whiteboard/components/toolbar/components/move-handle.d.ts +5 -0
- package/lib/modules/whiteboard/components/toolbar/components/move-handle.js +134 -0
- package/lib/modules/whiteboard/components/toolbar/components/pen-picker.d.ts +4 -0
- package/lib/modules/whiteboard/components/toolbar/components/pen-picker.js +106 -0
- package/lib/modules/whiteboard/components/toolbar/components/shape-picker.d.ts +4 -0
- package/lib/modules/whiteboard/components/toolbar/components/shape-picker.js +168 -0
- package/lib/modules/whiteboard/components/toolbar/hooks/index.d.ts +14 -0
- package/lib/modules/whiteboard/components/toolbar/hooks/index.js +211 -0
- package/lib/modules/whiteboard/components/toolbar/index.d.ts +2 -0
- package/lib/modules/whiteboard/components/toolbar/index.js +183 -0
- package/lib/modules/whiteboard/components/toolbar/store.d.ts +51 -0
- package/lib/modules/whiteboard/components/toolbar/store.js +248 -0
- package/lib/modules/whiteboard/context.d.ts +69 -0
- package/lib/modules/whiteboard/context.js +36 -0
- package/lib/modules/whiteboard/index.d.ts +119 -0
- package/lib/modules/whiteboard/index.js +1134 -0
- package/lib/modules/whiteboard/style.css +143 -0
- package/lib/modules/whiteboard/type.d.ts +94 -0
- package/lib/modules/whiteboard/type.js +89 -0
- package/lib/modules/whiteboard/utils.d.ts +12 -0
- package/lib/modules/whiteboard/utils.js +36 -0
- package/lib/plugins/css-preset-plugin.d.ts +1 -0
- package/lib/plugins/css-preset-plugin.js +29 -0
- package/lib/plugins/module-dev-plugin.d.ts +12 -0
- package/lib/plugins/module-dev-plugin.js +183 -0
- package/lib/plugins/multi-lang-plugin.d.ts +1 -0
- package/lib/plugins/multi-lang-plugin.js +19 -0
- package/lib/plugins/rtm-plugin.d.ts +1 -0
- package/lib/plugins/rtm-plugin.js +5 -0
- package/lib/plugins/web-rtc-plugin.d.ts +1 -0
- package/lib/plugins/web-rtc-plugin.js +5 -0
- package/lib/translations/enUS.d.ts +1855 -0
- package/lib/translations/enUS.js +1895 -0
- package/lib/translations/zhCN.d.ts +1852 -0
- package/lib/translations/zhCN.js +1892 -0
- package/lib/type.d.ts +121 -0
- package/lib/type.js +46 -0
- package/lib/ui-manager.d.ts +32 -0
- package/lib/ui-manager.js +426 -0
- package/lib/ui-scene.d.ts +14 -0
- package/lib/ui-scene.js +141 -0
- package/lib/utilities/board-context.d.ts +4 -0
- package/lib/utilities/board-context.js +12 -0
- package/lib/utilities/constant.d.ts +286 -0
- package/lib/utilities/constant.js +271 -0
- package/lib/utilities/copyText.d.ts +2 -0
- package/lib/utilities/copyText.js +43 -0
- package/lib/utilities/extract.d.ts +5 -0
- package/lib/utilities/extract.js +117 -0
- package/lib/utilities/hooks.d.ts +14 -0
- package/lib/utilities/hooks.js +101 -0
- package/lib/utilities/mute-action.d.ts +4 -0
- package/lib/utilities/mute-action.js +48 -0
- package/lib/utilities/parameters.d.ts +7 -0
- package/lib/utilities/parameters.js +20 -0
- package/lib/utilities/regex.d.ts +1 -0
- package/lib/utilities/regex.js +14 -0
- package/lib/utilities/tools.d.ts +27 -0
- package/lib/utilities/tools.js +169 -0
- package/lib/utilities/useNamespace.d.ts +15 -0
- package/lib/utilities/useNamespace.js +66 -0
- package/package.json +63 -0
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
.netless-whiteboard-wrapper {
|
|
2
|
+
height: 100%;
|
|
3
|
+
width: 100%;
|
|
4
|
+
pointer-events: none;
|
|
5
|
+
}
|
|
6
|
+
.netless-whiteboard-wrapper > * {
|
|
7
|
+
pointer-events: all;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.board-widget-app {
|
|
11
|
+
height: 100%;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.fcr-board-pagination {
|
|
15
|
+
position: absolute;
|
|
16
|
+
left: 10px;
|
|
17
|
+
bottom: 10px;
|
|
18
|
+
z-index: 10;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/* fold button */
|
|
22
|
+
|
|
23
|
+
/* board window */
|
|
24
|
+
.board-widget-app .telebox-maximized .netless-app-slide-btn-sidebar,
|
|
25
|
+
.board-widget-app .telebox-maximized .netless-app-docs-viewer-btn-sidebar,
|
|
26
|
+
.board-widget-app .telebox-maximized .vjs-p .player-controller-actions {
|
|
27
|
+
position: relative;
|
|
28
|
+
left: 190px;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.netless-whiteboard-wrapper .telebox-box-main {
|
|
32
|
+
/* @apply fcr-border-1; */
|
|
33
|
+
border: 1px solid var(--fcr_ui_scene_black1);
|
|
34
|
+
}
|
|
35
|
+
.netless-whiteboard-wrapper .telebox-titlebar {
|
|
36
|
+
/* @apply fcr-bg-2 fcr-border-1; */
|
|
37
|
+
flex-direction: row-reverse;
|
|
38
|
+
border: 1px solid var(--fcr_ui_scene_black1);
|
|
39
|
+
background: var(--fcr_ui_scene_black1);
|
|
40
|
+
}
|
|
41
|
+
.netless-whiteboard-wrapper .telebox-title {
|
|
42
|
+
/* @apply fcr-text-1; */
|
|
43
|
+
color: var(--fcr_ui_scene_black1);
|
|
44
|
+
background: var(--fcr_ui_scene_black1);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.netless-whiteboard-wrapper .telebox-content-wrap {
|
|
48
|
+
/* @apply fcr-bg-7; */
|
|
49
|
+
background: var(--fcr_ui_scene_black1);
|
|
50
|
+
}
|
|
51
|
+
.netless-whiteboard-wrapper .netless-app-slide-preview,
|
|
52
|
+
.netless-whiteboard-wrapper .netless-app-docs-viewer-preview {
|
|
53
|
+
/* @apply fcr-bg-3; */
|
|
54
|
+
background: var(--fcr_ui_scene_black1);
|
|
55
|
+
}
|
|
56
|
+
.netless-whiteboard-wrapper .netless-app-slide-preview-page-name {
|
|
57
|
+
/* @apply fcr-text-1; */
|
|
58
|
+
color: var(--fcr_ui_scene_black1);
|
|
59
|
+
}
|
|
60
|
+
.netless-whiteboard-wrapper .netless-app-slide-footer,
|
|
61
|
+
.netless-whiteboard-wrapper .app-talkative-footer,
|
|
62
|
+
.netless-whiteboard-wrapper .netless-app-docs-viewer-footer {
|
|
63
|
+
/* @apply fcr-bg-2 fcr-border-1 fcr-text-1; */
|
|
64
|
+
background: var(--fcr_ui_scene_black1);
|
|
65
|
+
border: 1px solid var(--fcr_ui_scene_black1);
|
|
66
|
+
color: var(--fcr_ui_scene_black1);
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.netless-whiteboard-wrapper .netless-app-slide-footer-btn:hover,
|
|
70
|
+
.netless-whiteboard-wrapper .netless-app-docs-viewer-footer-btn:hover {
|
|
71
|
+
/* @apply fcr-bg-7; */
|
|
72
|
+
background: var(--fcr_ui_scene_black1);
|
|
73
|
+
}
|
|
74
|
+
.netless-whiteboard-wrapper .netless-app-slide-footer-btn:focus,
|
|
75
|
+
.netless-whiteboard-wrapper .netless-app-docs-viewer-footer-btn:focus {
|
|
76
|
+
outline: none;
|
|
77
|
+
}
|
|
78
|
+
.netless-whiteboard-wrapper .netless-app-slide-page-number-input:hover,
|
|
79
|
+
.netless-whiteboard-wrapper .netless-app-slide-page-number-input:focus,
|
|
80
|
+
.netless-whiteboard-wrapper .netless-app-slide-page-number-input:active {
|
|
81
|
+
background: var(--fcr_ui_scene_black1);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.netless-whiteboard-wrapper .telebox-titlebar {
|
|
85
|
+
border-bottom: none;
|
|
86
|
+
}
|
|
87
|
+
.netless-whiteboard-wrapper
|
|
88
|
+
.telebox-titlebar.telebox-max-titlebar-maximized
|
|
89
|
+
.telebox-titlebar-btns {
|
|
90
|
+
margin-left: 0;
|
|
91
|
+
}
|
|
92
|
+
.netless-whiteboard-wrapper .telebox-titlebar-btn:focus,
|
|
93
|
+
.netless-whiteboard-wrapper .telebox-titles-tab:focus {
|
|
94
|
+
outline: none;
|
|
95
|
+
}
|
|
96
|
+
.netless-whiteboard-wrapper .telebox-titles-tab-focus {
|
|
97
|
+
/* @apply fcr-text-brand-6; */
|
|
98
|
+
color: var(--fcr_ui_scene_brand6);
|
|
99
|
+
background: #232529;
|
|
100
|
+
}
|
|
101
|
+
.netless-whiteboard-wrapper .telebox-titlebar.telebox-max-titlebar-maximized {
|
|
102
|
+
justify-content: flex-end;
|
|
103
|
+
}
|
|
104
|
+
.netless-whiteboard-wrapper .telebox-titles-tab,
|
|
105
|
+
.netless-whiteboard-wrapper .telebox-titles-bab.telebox-titles-tab-focus,
|
|
106
|
+
.netless-whiteboard-wrapper .netless-whiteboard-wrapper .telebox-titles-tab {
|
|
107
|
+
border-left: 1px solid #ccc;
|
|
108
|
+
border-right: 1px solid #ccc;
|
|
109
|
+
}
|
|
110
|
+
.netless-whiteboard-wrapper .telebox-titles-tab:not(:last-child) {
|
|
111
|
+
border-right: none;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.fcr-progress-saveImage {
|
|
115
|
+
/* @apply fcr-bg-block-4 !important; */
|
|
116
|
+
background: var(--fcr_ui_scene_black1);
|
|
117
|
+
|
|
118
|
+
text-align: left;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.fcr-progress-saveImage .fcr-progress {
|
|
122
|
+
background: rgba(47, 47, 47, 0.98);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
.fcr-progress-saveImage .fcr-progress .fcr-progress-inner {
|
|
126
|
+
height: 100%;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.fcr-progress-saveImage .dialog-progress-tip {
|
|
130
|
+
/* @apply fcr-text-1 !important; */
|
|
131
|
+
color: var(--fcr_ui_scene_black1);
|
|
132
|
+
}
|
|
133
|
+
.fcr-progress-saveImage .dialog-progress-tip ~ div {
|
|
134
|
+
margin-top: 4px;
|
|
135
|
+
}
|
|
136
|
+
/* .fcr-widget-dialog-content {
|
|
137
|
+
display: flex;
|
|
138
|
+
align-items: center;
|
|
139
|
+
justify-content: center;
|
|
140
|
+
width: 100%;
|
|
141
|
+
height: 100%;
|
|
142
|
+
} */
|
|
143
|
+
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { FcrBoardToolType } from 'fcr-core/lib/room-control/whiteboard-control/enums';
|
|
2
|
+
export declare enum FcrBoardShape {
|
|
3
|
+
Curve = 1,
|
|
4
|
+
Straight = 2,
|
|
5
|
+
Arrow = 3,
|
|
6
|
+
Rectangle = 4,
|
|
7
|
+
Triangle = 5,
|
|
8
|
+
Rhombus = 6,
|
|
9
|
+
Pentagram = 7,
|
|
10
|
+
Ellipse = 8
|
|
11
|
+
}
|
|
12
|
+
export declare enum FcrBoardRegion {
|
|
13
|
+
CN = "cn-hz",
|
|
14
|
+
US = "us-sv",
|
|
15
|
+
IN = "in-mum",
|
|
16
|
+
SG = "sg",
|
|
17
|
+
GB = "gb-lon"
|
|
18
|
+
}
|
|
19
|
+
export declare enum FcrBoardMainWindowFailureReason {
|
|
20
|
+
ResourceWindowAlreadyOpened = "resource-window-already-opened",
|
|
21
|
+
SnapshotFailure = "snapshot-failure",
|
|
22
|
+
MountFailure = "mount-failure"
|
|
23
|
+
}
|
|
24
|
+
export type BoardState = {
|
|
25
|
+
strokeColor: Color;
|
|
26
|
+
strokeWidth: number;
|
|
27
|
+
textSize: number;
|
|
28
|
+
tool: FcrBoardToolType;
|
|
29
|
+
shape: FcrBoardShape;
|
|
30
|
+
};
|
|
31
|
+
export type Color = {
|
|
32
|
+
r: number;
|
|
33
|
+
g: number;
|
|
34
|
+
b: number;
|
|
35
|
+
};
|
|
36
|
+
export declare enum ToolbarEvents {
|
|
37
|
+
REDO = "redo",
|
|
38
|
+
UNDO = "undo",
|
|
39
|
+
CLEAN = "clean",
|
|
40
|
+
SET_TOOL = "setTool",
|
|
41
|
+
SET_PEN = "setPen",
|
|
42
|
+
SET_SHAPE = "setShape",
|
|
43
|
+
SET_STROKE_COLOR = "setStrokeColor",
|
|
44
|
+
SET_STROKE_WIDTH = "setStrokeWidth",
|
|
45
|
+
CLICK_EXPANSION_TOOL = "clickExpansionTool",
|
|
46
|
+
SET_TOOLBAR_POSITION = "setToolbarPosition",
|
|
47
|
+
DRAG_TOOLBAR = "dragToolbar",
|
|
48
|
+
RELEASE_TOOLBAR = "releaseToolbar",
|
|
49
|
+
CAPTURE_SCREEN = "captureScreen",
|
|
50
|
+
SAVE_DRAFT = "saveDraft",
|
|
51
|
+
SET_THEME = "setTheme",
|
|
52
|
+
SET_COMMON_COLOR = "setCommonColor"
|
|
53
|
+
}
|
|
54
|
+
export declare enum WhiteboardEvents {
|
|
55
|
+
onJoinSuccess = "onJoinSuccess",
|
|
56
|
+
onJoinFailure = "onJoinFailure",
|
|
57
|
+
onConnectionStateUpdated = "onConnectionStateUpdated"
|
|
58
|
+
}
|
|
59
|
+
export declare enum WhiteboardUIEvents {
|
|
60
|
+
handleBoardDomLoad = "handleBoardDomLoad",
|
|
61
|
+
handleCollectorDomLoad = "handleCollectorDomLoad",
|
|
62
|
+
handleClose = "handleClose",
|
|
63
|
+
setPrivilege = "setPrivilege"
|
|
64
|
+
}
|
|
65
|
+
export declare enum WhiteboardControlbarEvents {
|
|
66
|
+
ZOOMIN = "zoomin",
|
|
67
|
+
ZOOMOUT = "zoomout",
|
|
68
|
+
ADAPTIVE = "adaptive",
|
|
69
|
+
ORIGIN = "origin",
|
|
70
|
+
LONEYWINDOW = "lonelyWindow",
|
|
71
|
+
ENABLE_CONTROL = "enableControl"
|
|
72
|
+
}
|
|
73
|
+
export declare enum WhiteboardBaseEvents {
|
|
74
|
+
LONELY_WINDOWN_CLOSED = "lonelyWindowClosed",
|
|
75
|
+
SET_OWNER_USER_ID = "setOnwerUserId"
|
|
76
|
+
}
|
|
77
|
+
export type WhiteboardThemeType = {
|
|
78
|
+
showColors?: string[][];
|
|
79
|
+
colors: string[];
|
|
80
|
+
background: string;
|
|
81
|
+
title: string;
|
|
82
|
+
theme?: 'whiteboard' | 'blackboard' | 'chalkboard';
|
|
83
|
+
};
|
|
84
|
+
export declare enum LonelyWindowState {
|
|
85
|
+
OPEN = "open",
|
|
86
|
+
CLOSE = "close",
|
|
87
|
+
DEFAULT = "default"
|
|
88
|
+
}
|
|
89
|
+
export declare enum FcrUIVideoWindowLayoutType {
|
|
90
|
+
/** Show a carousel on top and a big video on the rest of the screen. */
|
|
91
|
+
Speaker = "speaker",
|
|
92
|
+
/** Show videos in grid, filling the screen. */
|
|
93
|
+
Gallery = "gallery"
|
|
94
|
+
}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
require("core-js/modules/es.object.define-property.js");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.WhiteboardUIEvents = exports.WhiteboardEvents = exports.WhiteboardControlbarEvents = exports.WhiteboardBaseEvents = exports.ToolbarEvents = exports.LonelyWindowState = exports.FcrUIVideoWindowLayoutType = exports.FcrBoardShape = exports.FcrBoardRegion = exports.FcrBoardMainWindowFailureReason = void 0;
|
|
8
|
+
var FcrBoardShape = exports.FcrBoardShape = /*#__PURE__*/function (FcrBoardShape) {
|
|
9
|
+
FcrBoardShape[FcrBoardShape["Curve"] = 1] = "Curve";
|
|
10
|
+
FcrBoardShape[FcrBoardShape["Straight"] = 2] = "Straight";
|
|
11
|
+
FcrBoardShape[FcrBoardShape["Arrow"] = 3] = "Arrow";
|
|
12
|
+
FcrBoardShape[FcrBoardShape["Rectangle"] = 4] = "Rectangle";
|
|
13
|
+
FcrBoardShape[FcrBoardShape["Triangle"] = 5] = "Triangle";
|
|
14
|
+
FcrBoardShape[FcrBoardShape["Rhombus"] = 6] = "Rhombus";
|
|
15
|
+
FcrBoardShape[FcrBoardShape["Pentagram"] = 7] = "Pentagram";
|
|
16
|
+
FcrBoardShape[FcrBoardShape["Ellipse"] = 8] = "Ellipse";
|
|
17
|
+
return FcrBoardShape;
|
|
18
|
+
}({});
|
|
19
|
+
var FcrBoardRegion = exports.FcrBoardRegion = /*#__PURE__*/function (FcrBoardRegion) {
|
|
20
|
+
FcrBoardRegion["CN"] = "cn-hz";
|
|
21
|
+
FcrBoardRegion["US"] = "us-sv";
|
|
22
|
+
FcrBoardRegion["IN"] = "in-mum";
|
|
23
|
+
FcrBoardRegion["SG"] = "sg";
|
|
24
|
+
FcrBoardRegion["GB"] = "gb-lon";
|
|
25
|
+
return FcrBoardRegion;
|
|
26
|
+
}({});
|
|
27
|
+
var FcrBoardMainWindowFailureReason = exports.FcrBoardMainWindowFailureReason = /*#__PURE__*/function (FcrBoardMainWindowFailureReason) {
|
|
28
|
+
FcrBoardMainWindowFailureReason["ResourceWindowAlreadyOpened"] = "resource-window-already-opened";
|
|
29
|
+
FcrBoardMainWindowFailureReason["SnapshotFailure"] = "snapshot-failure";
|
|
30
|
+
FcrBoardMainWindowFailureReason["MountFailure"] = "mount-failure";
|
|
31
|
+
return FcrBoardMainWindowFailureReason;
|
|
32
|
+
}({});
|
|
33
|
+
var ToolbarEvents = exports.ToolbarEvents = /*#__PURE__*/function (ToolbarEvents) {
|
|
34
|
+
ToolbarEvents["REDO"] = "redo";
|
|
35
|
+
ToolbarEvents["UNDO"] = "undo";
|
|
36
|
+
ToolbarEvents["CLEAN"] = "clean";
|
|
37
|
+
ToolbarEvents["SET_TOOL"] = "setTool";
|
|
38
|
+
ToolbarEvents["SET_PEN"] = "setPen";
|
|
39
|
+
ToolbarEvents["SET_SHAPE"] = "setShape";
|
|
40
|
+
ToolbarEvents["SET_STROKE_COLOR"] = "setStrokeColor";
|
|
41
|
+
ToolbarEvents["SET_STROKE_WIDTH"] = "setStrokeWidth";
|
|
42
|
+
ToolbarEvents["CLICK_EXPANSION_TOOL"] = "clickExpansionTool";
|
|
43
|
+
ToolbarEvents["SET_TOOLBAR_POSITION"] = "setToolbarPosition";
|
|
44
|
+
ToolbarEvents["DRAG_TOOLBAR"] = "dragToolbar";
|
|
45
|
+
ToolbarEvents["RELEASE_TOOLBAR"] = "releaseToolbar";
|
|
46
|
+
ToolbarEvents["CAPTURE_SCREEN"] = "captureScreen";
|
|
47
|
+
ToolbarEvents["SAVE_DRAFT"] = "saveDraft";
|
|
48
|
+
ToolbarEvents["SET_THEME"] = "setTheme";
|
|
49
|
+
ToolbarEvents["SET_COMMON_COLOR"] = "setCommonColor";
|
|
50
|
+
return ToolbarEvents;
|
|
51
|
+
}({});
|
|
52
|
+
var WhiteboardEvents = exports.WhiteboardEvents = /*#__PURE__*/function (WhiteboardEvents) {
|
|
53
|
+
WhiteboardEvents["onJoinSuccess"] = "onJoinSuccess";
|
|
54
|
+
WhiteboardEvents["onJoinFailure"] = "onJoinFailure";
|
|
55
|
+
WhiteboardEvents["onConnectionStateUpdated"] = "onConnectionStateUpdated";
|
|
56
|
+
return WhiteboardEvents;
|
|
57
|
+
}({});
|
|
58
|
+
var WhiteboardUIEvents = exports.WhiteboardUIEvents = /*#__PURE__*/function (WhiteboardUIEvents) {
|
|
59
|
+
WhiteboardUIEvents["handleBoardDomLoad"] = "handleBoardDomLoad";
|
|
60
|
+
WhiteboardUIEvents["handleCollectorDomLoad"] = "handleCollectorDomLoad";
|
|
61
|
+
WhiteboardUIEvents["handleClose"] = "handleClose";
|
|
62
|
+
WhiteboardUIEvents["setPrivilege"] = "setPrivilege";
|
|
63
|
+
return WhiteboardUIEvents;
|
|
64
|
+
}({});
|
|
65
|
+
var WhiteboardControlbarEvents = exports.WhiteboardControlbarEvents = /*#__PURE__*/function (WhiteboardControlbarEvents) {
|
|
66
|
+
WhiteboardControlbarEvents["ZOOMIN"] = "zoomin";
|
|
67
|
+
WhiteboardControlbarEvents["ZOOMOUT"] = "zoomout";
|
|
68
|
+
WhiteboardControlbarEvents["ADAPTIVE"] = "adaptive";
|
|
69
|
+
WhiteboardControlbarEvents["ORIGIN"] = "origin";
|
|
70
|
+
WhiteboardControlbarEvents["LONEYWINDOW"] = "lonelyWindow";
|
|
71
|
+
WhiteboardControlbarEvents["ENABLE_CONTROL"] = "enableControl";
|
|
72
|
+
return WhiteboardControlbarEvents;
|
|
73
|
+
}({});
|
|
74
|
+
var WhiteboardBaseEvents = exports.WhiteboardBaseEvents = /*#__PURE__*/function (WhiteboardBaseEvents) {
|
|
75
|
+
WhiteboardBaseEvents["LONELY_WINDOWN_CLOSED"] = "lonelyWindowClosed";
|
|
76
|
+
WhiteboardBaseEvents["SET_OWNER_USER_ID"] = "setOnwerUserId";
|
|
77
|
+
return WhiteboardBaseEvents;
|
|
78
|
+
}({});
|
|
79
|
+
var LonelyWindowState = exports.LonelyWindowState = /*#__PURE__*/function (LonelyWindowState) {
|
|
80
|
+
LonelyWindowState["OPEN"] = "open";
|
|
81
|
+
LonelyWindowState["CLOSE"] = "close";
|
|
82
|
+
LonelyWindowState["DEFAULT"] = "default";
|
|
83
|
+
return LonelyWindowState;
|
|
84
|
+
}({});
|
|
85
|
+
var FcrUIVideoWindowLayoutType = exports.FcrUIVideoWindowLayoutType = /*#__PURE__*/function (FcrUIVideoWindowLayoutType) {
|
|
86
|
+
FcrUIVideoWindowLayoutType["Speaker"] = "speaker";
|
|
87
|
+
FcrUIVideoWindowLayoutType["Gallery"] = "gallery";
|
|
88
|
+
return FcrUIVideoWindowLayoutType;
|
|
89
|
+
}({});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare const heightPerTool = 36;
|
|
2
|
+
export declare const heightPerColor = 18;
|
|
3
|
+
export declare const defaultToolsRetain: number;
|
|
4
|
+
export declare const verticalPadding = 10;
|
|
5
|
+
export declare const sceneNavHeight: number;
|
|
6
|
+
export declare const widgetContainerClassName = "netless-whiteboard-wrapper";
|
|
7
|
+
export declare const layoutContentClassName = "fcr-layout-content-main-view";
|
|
8
|
+
export declare const ZOOM_IN_CANVAS = false;
|
|
9
|
+
export declare const toolbarClassName = "fcr-board-toolbar";
|
|
10
|
+
export declare const windowClassName = "netless-whiteboard-wrapper";
|
|
11
|
+
export declare const downloadCanvasImage: (canvas: HTMLCanvasElement, filename?: string) => void;
|
|
12
|
+
export declare const downloadImageData: (imageData: ImageData, filename?: string) => void;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
require("core-js/modules/es.object.define-property.js");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.windowClassName = exports.widgetContainerClassName = exports.verticalPadding = exports.toolbarClassName = exports.sceneNavHeight = exports.layoutContentClassName = exports.heightPerTool = exports.heightPerColor = exports.downloadImageData = exports.downloadCanvasImage = exports.defaultToolsRetain = exports.ZOOM_IN_CANVAS = void 0;
|
|
8
|
+
var heightPerTool = exports.heightPerTool = 36;
|
|
9
|
+
var heightPerColor = exports.heightPerColor = 18;
|
|
10
|
+
var defaultToolsRetain = exports.defaultToolsRetain = heightPerTool * 6;
|
|
11
|
+
var verticalPadding = exports.verticalPadding = 10;
|
|
12
|
+
var sceneNavHeight = exports.sceneNavHeight = heightPerTool + verticalPadding;
|
|
13
|
+
var widgetContainerClassName = exports.widgetContainerClassName = 'netless-whiteboard-wrapper';
|
|
14
|
+
var layoutContentClassName = exports.layoutContentClassName = 'fcr-layout-content-main-view';
|
|
15
|
+
var ZOOM_IN_CANVAS = exports.ZOOM_IN_CANVAS = false; // 开启是画布内放大,关闭是放大画布
|
|
16
|
+
|
|
17
|
+
var toolbarClassName = exports.toolbarClassName = 'fcr-board-toolbar';
|
|
18
|
+
var windowClassName = exports.windowClassName = 'netless-whiteboard-wrapper';
|
|
19
|
+
var downloadCanvasImage = exports.downloadCanvasImage = function downloadCanvasImage(canvas) {
|
|
20
|
+
var filename = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'fcr-board-snapshot.jpg';
|
|
21
|
+
var a = document.createElement('a');
|
|
22
|
+
a.download = filename;
|
|
23
|
+
a.href = canvas.toDataURL();
|
|
24
|
+
a.click();
|
|
25
|
+
};
|
|
26
|
+
var downloadImageData = exports.downloadImageData = function downloadImageData(imageData) {
|
|
27
|
+
var filename = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'fcr-board-snapshot.jpg';
|
|
28
|
+
var canvas = document.createElement('canvas');
|
|
29
|
+
canvas.width = imageData.width;
|
|
30
|
+
canvas.height = imageData.height;
|
|
31
|
+
var ctx = canvas.getContext('2d');
|
|
32
|
+
if (ctx) {
|
|
33
|
+
ctx.putImageData(imageData, 0, 0);
|
|
34
|
+
downloadCanvasImage(canvas, filename);
|
|
35
|
+
}
|
|
36
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import 'agora-ui-foundation/lib/utilities/global.css';
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _generate = require("agora-ui-foundation/lib/theme/generate");
|
|
4
|
+
var _toast = require("agora-ui-foundation/lib/components/toast");
|
|
5
|
+
require("agora-ui-foundation/lib/utilities/global.css");
|
|
6
|
+
var loadCssPreset = function loadCssPreset() {
|
|
7
|
+
var darkMode = window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)');
|
|
8
|
+
if (darkMode && darkMode.matches) {
|
|
9
|
+
(0, _generate.setThemeMode)('dark');
|
|
10
|
+
document.documentElement.style.colorScheme = 'dark';
|
|
11
|
+
}
|
|
12
|
+
(0, _generate.generateTheme)();
|
|
13
|
+
darkMode && darkMode.addEventListener('change', function (e) {
|
|
14
|
+
if (e.matches) {
|
|
15
|
+
(0, _generate.setThemeMode)('dark');
|
|
16
|
+
} else {
|
|
17
|
+
(0, _generate.setThemeMode)('light');
|
|
18
|
+
}
|
|
19
|
+
(0, _generate.generateTheme)();
|
|
20
|
+
});
|
|
21
|
+
};
|
|
22
|
+
if (document.documentElement) {
|
|
23
|
+
document.body.classList.add(_toast.TOAST_ROOT_CLASS_NAME);
|
|
24
|
+
loadCssPreset();
|
|
25
|
+
} else {
|
|
26
|
+
window.addEventListener('load', loadCssPreset, {
|
|
27
|
+
once: true
|
|
28
|
+
});
|
|
29
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { FcrCoreEngine } from 'fcr-core';
|
|
2
|
+
declare global {
|
|
3
|
+
interface Window {
|
|
4
|
+
__DEV_ENGINE__: FcrCoreEngine;
|
|
5
|
+
__DEV_ENGINE_IS_READY__: Promise<void>;
|
|
6
|
+
__DEV_ROOM_ID__: string;
|
|
7
|
+
__DEV_USER_ID__: string;
|
|
8
|
+
__DEV_USER_ROLE__: string;
|
|
9
|
+
__DEV_USER_TOKEN__: string;
|
|
10
|
+
__DEV_APP_ID__: string;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
5
|
+
require("core-js/modules/es.date.now.js");
|
|
6
|
+
require("core-js/modules/es.date.to-json.js");
|
|
7
|
+
require("core-js/modules/es.json.stringify.js");
|
|
8
|
+
require("core-js/modules/es.object.to-string.js");
|
|
9
|
+
require("core-js/modules/es.promise.js");
|
|
10
|
+
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
11
|
+
var _fcrCore = require("fcr-core");
|
|
12
|
+
/**
|
|
13
|
+
* 创建房间
|
|
14
|
+
* @param roomName
|
|
15
|
+
* @returns 房间ID
|
|
16
|
+
*/
|
|
17
|
+
var createRoom = /*#__PURE__*/function () {
|
|
18
|
+
var _ref = (0, _asyncToGenerator2["default"])(/*#__PURE__*/_regenerator["default"].mark(function _callee(roomName) {
|
|
19
|
+
var url, res, json;
|
|
20
|
+
return _regenerator["default"].wrap(function _callee$(_context) {
|
|
21
|
+
while (1) switch (_context.prev = _context.next) {
|
|
22
|
+
case 0:
|
|
23
|
+
url = "http://api-solutions-dev.bj2.agoralab.co/conference/companys/v1/rooms";
|
|
24
|
+
_context.next = 3;
|
|
25
|
+
return fetch(url, {
|
|
26
|
+
headers: {
|
|
27
|
+
'Content-Type': 'application/json'
|
|
28
|
+
},
|
|
29
|
+
method: 'POST',
|
|
30
|
+
body: JSON.stringify({
|
|
31
|
+
roomName: roomName,
|
|
32
|
+
sceneType: 4,
|
|
33
|
+
widgets: {},
|
|
34
|
+
startTime: Date.now(),
|
|
35
|
+
endTime: Date.now() + 1000 * 3600,
|
|
36
|
+
roomProperties: {}
|
|
37
|
+
})
|
|
38
|
+
});
|
|
39
|
+
case 3:
|
|
40
|
+
res = _context.sent;
|
|
41
|
+
_context.next = 6;
|
|
42
|
+
return res.json();
|
|
43
|
+
case 6:
|
|
44
|
+
json = _context.sent;
|
|
45
|
+
return _context.abrupt("return", json.data.roomId);
|
|
46
|
+
case 8:
|
|
47
|
+
case "end":
|
|
48
|
+
return _context.stop();
|
|
49
|
+
}
|
|
50
|
+
}, _callee);
|
|
51
|
+
}));
|
|
52
|
+
return function createRoom(_x) {
|
|
53
|
+
return _ref.apply(this, arguments);
|
|
54
|
+
};
|
|
55
|
+
}();
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* 生成用户Token
|
|
59
|
+
* @param roomId
|
|
60
|
+
* @param userId
|
|
61
|
+
* @param userName
|
|
62
|
+
* @param role
|
|
63
|
+
* @returns
|
|
64
|
+
*/
|
|
65
|
+
var getUserToken = /*#__PURE__*/function () {
|
|
66
|
+
var _ref2 = (0, _asyncToGenerator2["default"])(/*#__PURE__*/_regenerator["default"].mark(function _callee2(roomId, userId, userName, role) {
|
|
67
|
+
var url, res, json;
|
|
68
|
+
return _regenerator["default"].wrap(function _callee2$(_context2) {
|
|
69
|
+
while (1) switch (_context2.prev = _context2.next) {
|
|
70
|
+
case 0:
|
|
71
|
+
url = "https://api-solutions-dev.bj2.agoralab.co/conference/companys/v1/rooms";
|
|
72
|
+
_context2.next = 3;
|
|
73
|
+
return fetch(url, {
|
|
74
|
+
headers: {
|
|
75
|
+
'Content-Type': 'application/json'
|
|
76
|
+
},
|
|
77
|
+
method: 'PUT',
|
|
78
|
+
body: JSON.stringify({
|
|
79
|
+
roomId: roomId,
|
|
80
|
+
role: role,
|
|
81
|
+
userUuid: userId,
|
|
82
|
+
userName: userName
|
|
83
|
+
})
|
|
84
|
+
});
|
|
85
|
+
case 3:
|
|
86
|
+
res = _context2.sent;
|
|
87
|
+
_context2.next = 6;
|
|
88
|
+
return res.json();
|
|
89
|
+
case 6:
|
|
90
|
+
json = _context2.sent;
|
|
91
|
+
return _context2.abrupt("return", {
|
|
92
|
+
token: json.data.token,
|
|
93
|
+
appId: json.data.appId
|
|
94
|
+
});
|
|
95
|
+
case 8:
|
|
96
|
+
case "end":
|
|
97
|
+
return _context2.stop();
|
|
98
|
+
}
|
|
99
|
+
}, _callee2);
|
|
100
|
+
}));
|
|
101
|
+
return function getUserToken(_x2, _x3, _x4, _x5) {
|
|
102
|
+
return _ref2.apply(this, arguments);
|
|
103
|
+
};
|
|
104
|
+
}();
|
|
105
|
+
var roomId = 'test-room';
|
|
106
|
+
var userId = "test-user-".concat(Date.now());
|
|
107
|
+
var role = 'host';
|
|
108
|
+
window.__DEV_ENGINE_IS_READY__ = createRoom(roomId).then(/*#__PURE__*/function () {
|
|
109
|
+
var _ref3 = (0, _asyncToGenerator2["default"])(/*#__PURE__*/_regenerator["default"].mark(function _callee3(roomId) {
|
|
110
|
+
return _regenerator["default"].wrap(function _callee3$(_context3) {
|
|
111
|
+
while (1) switch (_context3.prev = _context3.next) {
|
|
112
|
+
case 0:
|
|
113
|
+
return _context3.abrupt("return", getUserToken(roomId, userId, userId, role).then(function (_ref4) {
|
|
114
|
+
var token = _ref4.token,
|
|
115
|
+
appId = _ref4.appId;
|
|
116
|
+
window.__DEV_ENGINE__ = new _fcrCore.FcrCoreEngine({
|
|
117
|
+
appId: appId,
|
|
118
|
+
token: token,
|
|
119
|
+
region: _fcrCore.FcrRegion.CN,
|
|
120
|
+
userId: userId,
|
|
121
|
+
dualCameraVideoStreamConfig: {
|
|
122
|
+
highVideoEncoderConfig: {
|
|
123
|
+
dimensions: {
|
|
124
|
+
width: 640,
|
|
125
|
+
height: 480
|
|
126
|
+
},
|
|
127
|
+
frameRate: 15,
|
|
128
|
+
bitrate: 800
|
|
129
|
+
},
|
|
130
|
+
lowVideoEncoderConfig: {
|
|
131
|
+
dimensions: {
|
|
132
|
+
width: 320,
|
|
133
|
+
height: 240
|
|
134
|
+
},
|
|
135
|
+
frameRate: 15,
|
|
136
|
+
bitrate: 400
|
|
137
|
+
},
|
|
138
|
+
enableDualStreamMode: false
|
|
139
|
+
},
|
|
140
|
+
dualScreenVideoStreamConfig: {
|
|
141
|
+
highVideoEncoderConfig: {
|
|
142
|
+
dimensions: {
|
|
143
|
+
width: 640,
|
|
144
|
+
height: 480
|
|
145
|
+
},
|
|
146
|
+
frameRate: 15,
|
|
147
|
+
bitrate: 800
|
|
148
|
+
},
|
|
149
|
+
lowVideoEncoderConfig: {
|
|
150
|
+
dimensions: {
|
|
151
|
+
width: 320,
|
|
152
|
+
height: 240
|
|
153
|
+
},
|
|
154
|
+
frameRate: 15,
|
|
155
|
+
bitrate: 400
|
|
156
|
+
},
|
|
157
|
+
enableDualStreamMode: false
|
|
158
|
+
},
|
|
159
|
+
parameters: {
|
|
160
|
+
rte: {
|
|
161
|
+
rteIpList: ['http://api-solutions-dev.bj2.agoralab.co']
|
|
162
|
+
},
|
|
163
|
+
core: {
|
|
164
|
+
coreIpList: ['http://api-solutions-dev.bj2.agoralab.co']
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
});
|
|
168
|
+
window.__DEV_ROOM_ID__ = roomId;
|
|
169
|
+
window.__DEV_USER_ID__ = userId;
|
|
170
|
+
window.__DEV_USER_ROLE__ = role;
|
|
171
|
+
window.__DEV_USER_TOKEN__ = token;
|
|
172
|
+
window.__DEV_APP_ID__ = appId;
|
|
173
|
+
}));
|
|
174
|
+
case 1:
|
|
175
|
+
case "end":
|
|
176
|
+
return _context3.stop();
|
|
177
|
+
}
|
|
178
|
+
}, _callee3);
|
|
179
|
+
}));
|
|
180
|
+
return function (_x6) {
|
|
181
|
+
return _ref3.apply(this, arguments);
|
|
182
|
+
};
|
|
183
|
+
}());
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _i18n = require("agora-ui-foundation/lib/i18n");
|
|
4
|
+
var _zhCN = require("../translations/zhCN");
|
|
5
|
+
var _enUS = require("../translations/enUS");
|
|
6
|
+
var _logger = require("agora-foundation/lib/logger");
|
|
7
|
+
//@internal
|
|
8
|
+
|
|
9
|
+
var logger = (0, _logger.getLogger)();
|
|
10
|
+
(0, _i18n.addResourceBundle)('zh', _zhCN.zhCn).then(function () {
|
|
11
|
+
logger.info('zh language pack has been loaded');
|
|
12
|
+
})["catch"](function () {
|
|
13
|
+
logger.info('failed to load zh language pack');
|
|
14
|
+
});
|
|
15
|
+
(0, _i18n.addResourceBundle)('en', _enUS.enUs).then(function () {
|
|
16
|
+
logger.info('en language pack has been loaded');
|
|
17
|
+
})["catch"](function () {
|
|
18
|
+
logger.info('failed to load en language pack');
|
|
19
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|