From 19e1c3b1f67bea24ef78cb0c7836d6ff247a9c96 Mon Sep 17 00:00:00 2001 From: xingyy <64720302+Concur-max@users.noreply.github.com> Date: Tue, 21 Jan 2025 15:11:26 +0800 Subject: [PATCH] =?UTF-8?q?refactor(LiveRoom):=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E7=9B=B4=E6=92=AD=E9=A1=B5=E9=9D=A2=E5=85=A8=E5=B1=8F=E9=80=BB?= =?UTF-8?q?=E8=BE=91=E5=92=8C=E8=BF=87=E6=B8=A1=E6=95=88=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 添加 fullLive1 变量用于控制全屏状态 - 使用 watch 监听 fullLive属性变化,延迟更新 fullLive1 - 调整过渡效果持续时间,提升用户体验 --- app/pages/LiveRoom/index.client.vue | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/app/pages/LiveRoom/index.client.vue b/app/pages/LiveRoom/index.client.vue index 1607e58..0d8ea8b 100644 --- a/app/pages/LiveRoom/index.client.vue +++ b/app/pages/LiveRoom/index.client.vue @@ -70,6 +70,20 @@ onBeforeUnmount(() => { const goPay = () => { show.value = true } +const fullLive1 = ref(false) + +watch(()=>{ + return props.fullLive +}, (newVal) => { + console.log('newVal',newVal) + if (newVal) { + setTimeout(() => { + fullLive1.value = true + }, 400) + }else { + fullLive1.value = false + } +})