From fa1bd95d533444d7360d1ada127b7a3279a3901f Mon Sep 17 00:00:00 2001
From: inleft <inleft@qq.com>
Date: Fri, 26 Aug 2022 18:43:56 +0800
Subject: [PATCH] 新增图组等上传支持 新增编辑页

---
 src/components/mini/Aplayer.vue |   50 ++++++++++++++++++++++++++++++++++++++++++++++----
 1 files changed, 46 insertions(+), 4 deletions(-)

diff --git a/src/components/mini/Aplayer.vue b/src/components/mini/Aplayer.vue
index cb854f2..9421d4d 100644
--- a/src/components/mini/Aplayer.vue
+++ b/src/components/mini/Aplayer.vue
@@ -1,16 +1,41 @@
 <template>
-	<div >
-		<aplayer :audio="audio"  fixed  style="z-index: 10;" :preload="preload"/>
+	<div class="fade">
+		<a-col v-bind="colMain">
+			<aplayer ref="myAplayer" :audio="audio" :autoplay="autoplay" fixed style="z-index: 10;" :volume="0.1"
+				:preload="preload" />
+		</a-col>
+
+		<!-- <a-modal ref="musicModal" title="" :dialog-style="{ top: '10px' }" :mask="false"
+		:maskClosable="false"	:visible="modal1Visible" @ok="() => setModal1Visible(false)" @cancel="() => setModal1Visible(false)">
+			<p>{{secondsToGo}}秒后关闭</p>
+		</a-modal> -->
 	</div>
 </template>
 
 <script>
 	import APlayer from '@moefe/vue-aplayer';
-	
+
 	export default {
+		created() {
+			this.$nextTick(function() {
+				this.$message.info("stop..")
+				this.$refs.myAplayer.pause();
+			})
+		},
 		data() {
 			return {
-				preload:"none",
+				colMain: {
+					xs: 0,
+					sm: 0,
+					md: 1,
+					lg: 1,
+					xl: 1,
+					xxl: 1
+				},
+				autoplay: false,
+				modal1Visible: true,
+				secondsToGo: 5,
+				preload: "none",
 				audio: {
 					name: 'Moonwisher',
 					artist: 'Kan R. Gao',
@@ -19,6 +44,23 @@
 					cover: 'http://p2.music.126.net/0AYWra9rCzgeprGp6OUyUw==/868614185993997.jpg?param=130y130',
 				},
 			};
+
+		},
+		created() {
+			// const interval = setInterval(() => {
+			// 	this.secondsToGo -= 1;
+			// }, 1000);
+
+			// setTimeout(() => {
+			// 	clearInterval(interval);
+			// 	this.modal1Visible = false
+			// }, 5000);
+		},
+		methods: {
+			setModal1Visible(modal1Visible) {
+
+				this.modal1Visible = modal1Visible;
+			},
 		},
 	};
 	// var ap = new APlayer({

--
Gitblit v1.9.1