42 lines
1.4 KiB
Vue
42 lines
1.4 KiB
Vue
|
|
<script setup lang="ts">
|
||
|
|
import { computed } from 'vue'
|
||
|
|
import CompetitionLayout from '@/components/custom/user/CompetitionLayout.vue'
|
||
|
|
import { useRouterPush } from '@/hooks/common/router'
|
||
|
|
import { useCompetitionStore } from '@/store/modules/competition'
|
||
|
|
|
||
|
|
const { routerPushByKey } = useRouterPush()
|
||
|
|
|
||
|
|
const store = useCompetitionStore()
|
||
|
|
|
||
|
|
const currentNode = computed(() => store.currentNode)
|
||
|
|
function handleDraw() {
|
||
|
|
routerPushByKey('user_game')
|
||
|
|
}
|
||
|
|
|
||
|
|
function handleBack() {
|
||
|
|
routerPushByKey('user_cover')
|
||
|
|
}
|
||
|
|
</script>
|
||
|
|
|
||
|
|
<template>
|
||
|
|
<CompetitionLayout :show-back="true" :show-next="false" :title="currentNode?.moduleName || '抽题'" @back="handleBack">
|
||
|
|
<div class="h-full w-full flex flex-col items-center pt-10 font-sans">
|
||
|
|
<div v-if="currentNode" class="mb-20 max-w-4xl text-center">
|
||
|
|
<div class="text-2xl text-gray-800 font-medium leading-relaxed tracking-wide">
|
||
|
|
{{ currentNode.description }}
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
|
||
|
|
<!-- 抽题按钮 (大圆形) -->
|
||
|
|
<div class="group relative">
|
||
|
|
<button
|
||
|
|
class="h-64 w-64 flex flex-col items-center justify-center border-4 border-blue-400 rounded-full bg-gray-200/80 text-3xl text-gray-700 font-bold shadow-xl transition-all active:scale-95 hover:scale-105"
|
||
|
|
@click="handleDraw"
|
||
|
|
>
|
||
|
|
<span>抽题</span>
|
||
|
|
</button>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
</CompetitionLayout>
|
||
|
|
</template>
|