mirror of
https://github.com/algerkong/AlgerMusicPlayer.git
synced 2026-04-05 07:20:50 +08:00
✨ feat: 修复无法播放的问题
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
<template>
|
||||
<div class="app-container" :class="{ mobile: isMobile }">
|
||||
<audio id="MusicAudio" ref="audioRef" :src="playMusicUrl" :autoplay="play"></audio>
|
||||
<n-config-provider :theme="darkTheme">
|
||||
<n-dialog-provider>
|
||||
<router-view></router-view>
|
||||
@@ -17,6 +18,9 @@ import store from '@/store';
|
||||
|
||||
import { isMobile } from './utils';
|
||||
|
||||
const playMusicUrl = computed(() => store.state.playMusicUrl as string);
|
||||
// 是否播放
|
||||
const play = computed(() => store.state.play as boolean);
|
||||
const windowData = window as any;
|
||||
onMounted(() => {
|
||||
if (windowData.electron) {
|
||||
|
||||
Reference in New Issue
Block a user