feat: 添加Loading效果

This commit is contained in:
LOG1997
2025-10-12 22:30:54 +08:00
parent ebbed65253
commit 27fd0768c1
11 changed files with 266 additions and 155 deletions

View File

@@ -1,11 +1,13 @@
<script setup lang="ts">
import { storeToRefs } from 'pinia'
import { onMounted, ref } from 'vue'
import { onMounted, provide, ref } from 'vue'
import { useI18n } from 'vue-i18n'
import { loadingKey, loadingState } from '@/components/Loading'
import PlayMusic from '@/components/PlayMusic/index.vue'
import useStore from '@/store'
import { themeChange } from '@/utils'
provide(loadingKey, loadingState)
const { t } = useI18n()
const globalConfig = useStore().globalConfig
const prizeConfig = useStore().prizeConfig
@@ -14,7 +16,6 @@ const { getTheme: localTheme } = storeToRefs(globalConfig)
const { getPrizeConfig: prizeList } = storeToRefs(prizeConfig)
const tipDialog = ref()
// 设置当前奖列表
function setCurrentPrize() {
if (prizeList.value.length <= 0) {