|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <div class="panel" :class="{ show }">
|
|
|
+ <div class="panel" :class="{ show }" v-if="panelShow">
|
|
|
<span class="icon" @click="handlePlayTours" v-if="hasTours">
|
|
|
<Icon type="play" />
|
|
|
</span>
|
|
@@ -18,7 +18,7 @@
|
|
|
//import { useMusicPlayer } from "@/utils/sound";
|
|
|
// import { changeScene } from "@/store/room";
|
|
|
import Icon from '/@/components/basic/icon/index.vue';
|
|
|
- import { onMounted, ref, unref } from 'vue';
|
|
|
+ import { computed, onMounted, ref, unref } from 'vue';
|
|
|
import { useRoom } from '/@/hooks/useRoom';
|
|
|
import { useTourPlayer } from '/@/hooks/userTourPlayer';
|
|
|
|
|
@@ -32,6 +32,7 @@
|
|
|
|
|
|
const showScenes = ref(false);
|
|
|
const { hasTours } = useTourPlayer();
|
|
|
+ const panelShow = computed(() => unref(hasTours) || unref(sceneList).length > 1);
|
|
|
|
|
|
function handlePlayTours() {
|
|
|
const { player, playing } = useTourPlayer();
|