完成答题逻辑
This commit is contained in:
@@ -1,15 +1,17 @@
|
||||
<template>
|
||||
<div class="home">
|
||||
<Loading v-if="showLoad" @LoadPage="loadFn"></Loading>
|
||||
<Index v-if="showIndex" @IndexPage="indexFn"></Index>
|
||||
<Question v-if="showQuestion" @QuestionPage="questionFn"></Question>
|
||||
<Loading v-if="showLoad" @LoadPage="loadFn"></Loading>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import Loading from "@/components/Loading.vue";
|
||||
import Index from "@/components/Index.vue";
|
||||
import Loading from "@/components/Loading";
|
||||
import Index from "@/components/Index";
|
||||
import Question from "@/components/Question";
|
||||
|
||||
const showLoad = ref(true);
|
||||
const showLoad = ref(false);
|
||||
const loadFn = (item) => {
|
||||
if (item.action == "hide") {
|
||||
showLoad.value = false;
|
||||
@@ -24,6 +26,14 @@ const indexFn = (item) => {
|
||||
}
|
||||
};
|
||||
|
||||
const showQuestion = ref(true);
|
||||
const questionFn = (item) => {
|
||||
if (item.action == "hide") {
|
||||
showQuestion.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
onMounted(() => { });
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user