refactor: 重构首页界面

- 首页界面重新调整
- 新建问卷内容抽离单独 CreateSurvey 组件
- hooks 存放对应标题数据
This commit is contained in:
Huangzhe
2025-03-06 10:26:32 +08:00
parent 6e83ccdbb3
commit 91dd8d5f4c
3 changed files with 72 additions and 39 deletions

View File

@@ -0,0 +1,34 @@
<script setup lang="ts">
import { surveys } from "./Hooks/useRequestHooks"
</script>
<template>
<van-cell>
<div style="text-align: left;">新建问卷</div>
<van-row>
<van-col span="6" v-for="survey in surveys" :key="survey.title" class="survey">
<img width="45px" :src="survey.icon" alt=" " />
<span>{{ survey.title }}</span>
</van-col>
</van-row>
</van-cell>
</template>
<style lang="scss" scoped>
.survey {
display: flex;
flex-direction: column;
align-items: center;
justify-content: space-around;
img {
margin-bottom: 5px;
}
span {
color: black;
font-size: 10px;
}
}
</style>