@ndscnj/roomkit-web-vue3 25.12.2318 → 25.12.2320
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/es/components/RoomFooter/index/index.d.ts +13 -3
- package/es/components/RoomFooter/index/indexPC.vue.d.ts +5 -1
- package/es/components/RoomFooter/index/indexPC.vue.mjs +1 -1
- package/es/components/RoomFooter/index/indexPC.vue2.mjs +8 -2
- package/es/components/RoomFooter/voteControl.vue.mjs +1 -1
- package/es/components/RoomFooter/voteControl.vue2.mjs +26 -13
- package/es/components/RoomInvite/useRoomInviteHooks.d.ts +1 -1
- package/es/components/RoomSidebar/useSideBarHooks.d.ts +1 -1
- package/es/components/RoomVote/index.d.ts +17 -1
- package/es/components/RoomVote/indexPC.vue.d.ts +10 -1
- package/es/components/RoomVote/indexPC.vue.mjs +1 -1
- package/es/components/RoomVote/indexPC.vue2.mjs +5 -1
- package/es/index.mjs +155 -163
- package/es/locales/zh-CN.mjs +1 -1
- package/es/services/manager/componentManager.d.ts +1 -1
- package/es/services/manager/componentManager.mjs +2 -0
- package/es/stores/basic.d.ts +1 -1
- package/lib/components/RoomFooter/index/index.d.ts +13 -3
- package/lib/components/RoomFooter/index/indexPC.vue.d.ts +5 -1
- package/lib/components/RoomFooter/index/indexPC.vue.js +1 -1
- package/lib/components/RoomFooter/index/indexPC.vue2.js +8 -2
- package/lib/components/RoomFooter/voteControl.vue.js +1 -1
- package/lib/components/RoomFooter/voteControl.vue2.js +25 -12
- package/lib/components/RoomInvite/useRoomInviteHooks.d.ts +1 -1
- package/lib/components/RoomSidebar/useSideBarHooks.d.ts +1 -1
- package/lib/components/RoomVote/index.d.ts +17 -1
- package/lib/components/RoomVote/indexPC.vue.d.ts +10 -1
- package/lib/components/RoomVote/indexPC.vue.js +1 -1
- package/lib/components/RoomVote/indexPC.vue2.js +4 -0
- package/lib/index.js +155 -163
- package/lib/locales/zh-CN.js +1 -1
- package/lib/services/manager/componentManager.d.ts +1 -1
- package/lib/services/manager/componentManager.js +2 -0
- package/lib/stores/basic.d.ts +1 -1
- package/package.json +1 -1
- package/src/TUIRoom/components/RoomFooter/index/indexPC.vue +6 -0
- package/src/TUIRoom/components/RoomFooter/voteControl.vue +30 -33
- package/src/TUIRoom/components/RoomVote/indexPC.vue +3 -0
- package/src/TUIRoom/locales/zh-CN.ts +1 -1
- package/src/TUIRoom/services/manager/componentManager.ts +2 -0
- package/src/TUIRoom/stores/basic.ts +1 -1
package/lib/stores/basic.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { LAYOUT } from '../constants/render';
|
|
2
2
|
import { TUINetwork } from '../../../node_modules/@tencentcloud/tuiroom-engine-js';
|
|
3
3
|
|
|
4
|
-
type SideBarType = 'chat' | 'invite' | 'manage-member' | 'more' | 'transfer-leave' | 'apply' | 'aiTranscription' | '
|
|
4
|
+
type SideBarType = 'chat' | 'invite' | 'manage-member' | 'vote' | 'more' | 'transfer-leave' | 'apply' | 'aiTranscription' | '';
|
|
5
5
|
type SceneType = 'chat' | 'default';
|
|
6
6
|
interface BasicState {
|
|
7
7
|
sdkAppId: number;
|
package/package.json
CHANGED
|
@@ -54,6 +54,7 @@
|
|
|
54
54
|
<voteControl
|
|
55
55
|
class="center-container-item"
|
|
56
56
|
@click="handleControlClick('voteControl')"
|
|
57
|
+
@on-vote="onVote"
|
|
57
58
|
>
|
|
58
59
|
<template #content>
|
|
59
60
|
<slot name="content"></slot>
|
|
@@ -81,6 +82,7 @@
|
|
|
81
82
|
</template>
|
|
82
83
|
|
|
83
84
|
<script setup lang="ts">
|
|
85
|
+
import { defineEmits } from "vue";
|
|
84
86
|
import {
|
|
85
87
|
AudioSetting,
|
|
86
88
|
VideoSetting,
|
|
@@ -108,6 +110,10 @@ const { roomStore, isMaster, isAdmin, isAudience } = useRoomFooter();
|
|
|
108
110
|
function handleControlClick(name: string) {
|
|
109
111
|
bus.emit('experience-communication', name);
|
|
110
112
|
}
|
|
113
|
+
const emit = defineEmits(['on-vote']);
|
|
114
|
+
const onVote = (data: { name: string; visible: boolean }) => {
|
|
115
|
+
emit('on-vote', { code: data.visible, message: 'vote' });
|
|
116
|
+
};
|
|
111
117
|
</script>
|
|
112
118
|
|
|
113
119
|
<style lang="scss" scoped>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div class="
|
|
2
|
+
<div class="vote-control-container" v-if="voteControlConfig.visible">
|
|
3
3
|
<icon-button
|
|
4
4
|
:is-active="sidebarName === 'vote'"
|
|
5
5
|
:title="t('Vote')"
|
|
@@ -7,19 +7,25 @@
|
|
|
7
7
|
>
|
|
8
8
|
<IconAIIcon size="24" />
|
|
9
9
|
</icon-button>
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
<div class="contact-container" v-if="!isSidebarOpen && showToolBox">
|
|
11
|
+
<room-vote ref="contactRef" @on-close-contact="handleOnCloseContact">
|
|
12
|
+
<template #content>
|
|
13
|
+
<slot name="content"></slot>
|
|
14
|
+
</template>
|
|
15
|
+
</room-vote>
|
|
15
16
|
</div>
|
|
16
17
|
</div>
|
|
17
18
|
</template>
|
|
18
19
|
|
|
19
20
|
<script setup lang="ts">
|
|
20
|
-
|
|
21
|
+
import { roomService } from '../../services';
|
|
21
22
|
import { defineEmits, ref,computed,watch } from 'vue';
|
|
22
23
|
import { useI18n } from '../../locales';
|
|
24
|
+
import IconButton from '../common/base/IconButton.vue';
|
|
25
|
+
import {
|
|
26
|
+
IconAIIcon,
|
|
27
|
+
} from '@tencentcloud/uikit-base-component-vue3';
|
|
28
|
+
import roomVote from '../RoomVote';
|
|
23
29
|
const { basicStore } = roomService;
|
|
24
30
|
const isSidebarOpen = computed(() => basicStore.isSidebarOpen);
|
|
25
31
|
const sidebarName = computed(() => basicStore.sidebarName);
|
|
@@ -28,39 +34,30 @@ const showToolBox = ref(false);
|
|
|
28
34
|
watch(isSidebarOpen, newValue => {
|
|
29
35
|
showToolBox.value = newValue && false;
|
|
30
36
|
});
|
|
37
|
+
const voteControlConfig = roomService.getComponentConfig('VoteControl');
|
|
31
38
|
const emit = defineEmits(['on-vote']);
|
|
32
39
|
function toggleToolBox() {
|
|
33
40
|
showToolBox.value = !showToolBox.value;
|
|
34
41
|
emit('on-vote', {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
42
|
+
name: 'onVote',
|
|
43
|
+
visible: showToolBox.value,
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
function handleOnCloseContact() {
|
|
47
|
+
showToolBox.value = false;
|
|
38
48
|
}
|
|
39
|
-
|
|
40
49
|
</script>
|
|
41
50
|
|
|
42
51
|
<style lang="scss" scoped>
|
|
43
|
-
.
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
.more-notice {
|
|
55
|
-
width: 100%;
|
|
56
|
-
height: 22px;
|
|
57
|
-
padding-left: 8px;
|
|
58
|
-
font-size: 14px;
|
|
59
|
-
font-weight: 400;
|
|
60
|
-
line-height: 22px;
|
|
61
|
-
color: var(--text-color-primary);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
|
|
52
|
+
.contact-container {
|
|
53
|
+
position: fixed;
|
|
54
|
+
top: 0;
|
|
55
|
+
bottom: 0;
|
|
56
|
+
left: 0;
|
|
57
|
+
z-index: 11;
|
|
58
|
+
box-sizing: border-box;
|
|
59
|
+
width: 100vw;
|
|
60
|
+
height: auto;
|
|
61
|
+
background-color: var(--uikit-color-black-8);
|
|
65
62
|
}
|
|
66
63
|
</style>
|
|
@@ -18,6 +18,7 @@ const componentNames = [
|
|
|
18
18
|
'ManageMemberControl',
|
|
19
19
|
'InviteControl',
|
|
20
20
|
'ChatControl',
|
|
21
|
+
'VoteControl',
|
|
21
22
|
'MoreControl',
|
|
22
23
|
'VirtualBackground',
|
|
23
24
|
'BasicBeauty',
|
|
@@ -49,6 +50,7 @@ const defaultConfig = {
|
|
|
49
50
|
ManageMemberControl: { visible: true },
|
|
50
51
|
InviteControl: { visible: true },
|
|
51
52
|
ChatControl: { visible: true },
|
|
53
|
+
VoteControl: { visible: true },
|
|
52
54
|
MoreControl: { visible: true },
|
|
53
55
|
VirtualBackground: { visible: false },
|
|
54
56
|
AIControl: { visible: false },
|