From 9cfd6df6491e29a7669b417ba5857ac69179ae38 Mon Sep 17 00:00:00 2001 From: cxc Date: Fri, 10 Jun 2022 14:26:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=BB=E6=8C=81=E4=BA=BA=E5=AF=8C=E6=96=87?= =?UTF-8?q?=E6=9C=AC=E3=80=81leave=20meeting=20after=20close=20the=20brows?= =?UTF-8?q?er?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/chat.vue | 28 ++++++++++++++++++------- src/components/wangEditor/index.vue | 16 +++++++++++---- src/router/index.js | 5 +++-- src/views/meeting.vue | 32 +++++++++++++++++++++++------ 4 files changed, 62 insertions(+), 19 deletions(-) diff --git a/src/components/chat.vue b/src/components/chat.vue index 6299224..27ac2cc 100644 --- a/src/components/chat.vue +++ b/src/components/chat.vue @@ -25,15 +25,28 @@
-
+ >
--> + + + { } .input-bar { display: flex; - margin: 0 5px; + margin: 5px; + align-items: center; .message-input { margin-right: 5px; } diff --git a/src/components/wangEditor/index.vue b/src/components/wangEditor/index.vue index db15ea1..7a0c224 100644 --- a/src/components/wangEditor/index.vue +++ b/src/components/wangEditor/index.vue @@ -7,7 +7,7 @@ :mode="mode" /> { // 前往主持人页面 if (to.name === "Host") { console.log("host"); - // const bytes = cryptoJs.AES.decrypt(to.params.hostinfo, "secret"); - // const decryptedData = JSON.parse(bytes.toString(cryptoJs.enc.Utf8)); + if (to.params.meetingId !== store.state.joinUser.meetingId) { + store.commit("setMessagesList", []); + } store.commit("setJoinUser", { nickname: to.params.nickname, username: to.params.username, diff --git a/src/views/meeting.vue b/src/views/meeting.vue index d6a0de5..d3e3f50 100644 --- a/src/views/meeting.vue +++ b/src/views/meeting.vue @@ -32,9 +32,9 @@ > -
+
{ }; const isFullScreen = ref(false); +const rightChatRef = ref(null); onMounted(() => { meetingContainerRef.value.style.background = ` url(${ store.getters.templateBackgroundPic || store.getters.defaultBackground @@ -654,7 +655,9 @@ onMounted(() => { meetingHeight.value = (meetingWidth.value * 9) / 16; videoElementRef.value.style.height = `${meetingHeight.value + 42}px`; - + rightChatRef.value.style.height = `${ + meetingContainerRef.value.offsetWidth * 0.08 + meetingHeight.value + 42 + }px`; const handleFullscreenChange = () => { if (document.fullscreenElement) { isFullScreen.value = true; @@ -729,6 +732,7 @@ const leaveConference = () => { meetingConfig.client.leaveMeeting(); }; window.addEventListener("beforeunload", leaveConference); +window.addEventListener("unload", leaveConference); onUnmounted(() => { window.removeEventListener("beforeunload", leaveConference); }); @@ -742,7 +746,9 @@ $meetingBackgroundWidth: 80vw; //会议背景宽度 $meetingBackgroundHeight: 80vw * 9 / 16; :deep(#right-chat .chat-container .message-list) { - height: $meetingComponentWitdh * 9 / 16; + // height: $meetingComponentWitdh * 9 / 16; + // height: 100%; + flex-grow: 1; overflow-y: scroll; } @@ -750,6 +756,9 @@ $meetingBackgroundHeight: 80vw * 9 / 16; #meeting-chat-row { display: flex; justify-content: space-between; + :deep(.rich-editor) { + width: 14vw !important; + } #meeting-container { box-sizing: border-box; padding-top: calc(80vw * 0.08); @@ -896,6 +905,10 @@ $meetingBackgroundHeight: 80vw * 9 / 16; #meeting-container { padding-top: calc(100vw * 0.08); width: 100vw; + .text-label-container { + width: 100vw; + // height: 100%; + } #video-element { width: 96vw; :deep(div[id*="suspension-view-tabpanel"] @@ -952,6 +965,10 @@ $meetingBackgroundHeight: 80vw * 9 / 16; } width: 100vw; height: 100vh; + .text-label-container { + width: 100vw; + height: 100%; + } #video-element { width: $meetingComponentWitdh; } @@ -1027,7 +1044,10 @@ $meetingBackgroundHeight: 80vw * 9 / 16; left: 100vw; width: 100vh !important; height: 100vw; - + .text-label-container { + width: 100vh; + height: 100vw; + } #video-element { width: $meetingComponentWitdh; :deep(div[id*="suspension-view-tabpanel"]