修复当前歌词 变色

This commit is contained in:
algerkong
2021-07-26 09:19:11 +08:00
parent ec1269d010
commit 68aedda1c2
+6 -5
View File
@@ -186,7 +186,7 @@ const setMusicFull = () => {
const musicFullClass = computed(() => { const musicFullClass = computed(() => {
if (musicFull.value) { if (musicFull.value) {
return setAnimationClass('animate__zoomInUp') return setAnimationClass('animate__fadeInUp')
} else { } else {
return setAnimationClass('animate__fadeOutDown') return setAnimationClass('animate__fadeOutDown')
} }
@@ -246,9 +246,9 @@ const loadLrc = async () => {
} }
// 是否是当前正在播放的歌词 // 是否是当前正在播放的歌词
const isCurrentLrc = computed((index) => { const isCurrentLrc = (index: any) => {
return !(nowTime.value <= lrcTimeArray.value[index] || nowTime.value >= lrcTimeArray.value[index + 1]) return !(nowTime.value <= lrcTimeArray.value[index] || nowTime.value >= lrcTimeArray.value[index + 1])
}) }
onMounted(() => { onMounted(() => {
}) })
@@ -258,7 +258,7 @@ onMounted(() => {
#drawer-target { #drawer-target {
@apply top-0 left-0 absolute w-full h-full overflow-hidden rounded px-24 pt-24 pb-48 flex items-center; @apply top-0 left-0 absolute w-full h-full overflow-hidden rounded px-24 pt-24 pb-48 flex items-center;
background-color: #333333; background-color: #333333;
animation-duration: 500ms; animation-duration: 300ms;
.music-img { .music-img {
@apply flex-1; @apply flex-1;
.img { .img {
@@ -284,7 +284,8 @@ onMounted(() => {
} }
.now-text { .now-text {
@apply font-bold; @apply font-bold text-xl text-red-500;
transition: all 0.3s ease-out;
} }
} }
} }