feat: 添加pinia状态管理库和Tabbar组件
- 添加pinia状态管理库和Tabbar组件 - 导入新的组件和模块 - 更新页面布局和样式 - 删除无用的文件和代码
This commit is contained in:
@ -1,30 +1,18 @@
|
||||
<template>
|
||||
<div class="content">
|
||||
<img class="logo" src="/static/logo.png" />
|
||||
<div class="flex flex-col items-center gap-4">
|
||||
<p class="title text-red-500">
|
||||
{{ title }}
|
||||
</p>
|
||||
<WdButton @click="onClick">Increment</WdButton>
|
||||
<Tabbar current-name="home" />
|
||||
<page-wrapper>
|
||||
<div class="content">
|
||||
<img class="logo" src="/static/logo.png" />
|
||||
<div class="flex flex-col items-center gap-4">
|
||||
<p class="title text-red-500">
|
||||
Welcome
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</page-wrapper>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useUserStore } from '@/stores/user';
|
||||
import { computed } from 'vue';
|
||||
|
||||
import Tabbar from '@/components/Tabbar.vue';
|
||||
|
||||
const user = useUserStore()
|
||||
|
||||
const onClick = () => {
|
||||
user.count++
|
||||
}
|
||||
|
||||
const title = computed(() => `Counter: ${user.count}`)
|
||||
import pageWrapper from '@/components/page-wrapper.vue';
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
Reference in New Issue
Block a user