ancient页面添加

This commit is contained in:
minimaxagent1 2025-08-06 09:56:03 +08:00
parent 209864ff39
commit e595b5eb29

73
pages/ancient/ancient.vue Normal file
View File

@ -0,0 +1,73 @@
<template>
<view class="page">
<custom-navbar title="基础页面" />
<tile-grid/>
<view class="header" :style="{ backgroundColor: CommonEnum.BASE_COLOR }">
<!-- 状态展示 -->
<status-display
v-if="loading"
type="loading"
loading-text="加载中..."
/>
<!-- 页面内容将在这里添加 -->
</view>
</view>
</template>
<script>
import CustomNavbar from "../../components/custom-navbar/custom-navbar.vue";
import TileGrid from "../../components/tile-grid/tile-grid.vue";
import CommonEnum from "../../enum/common";
import StatusDisplay from "../../components/status-display/status-display.vue";
export default {
components: {
CustomNavbar,
TileGrid,
StatusDisplay
},
data() {
return {
CommonEnum,
loading: false
}
},
onLoad() {
//
this.loadPageData()
},
methods: {
//
async loadPageData() {
this.loading = true
try {
// TODO: API
// const response = await getPageData()
//
setTimeout(() => {
this.loading = false
}, 1000)
} catch (error) {
console.error('获取页面数据失败:', error)
this.loading = false
}
}
}
}
</script>
<style lang="scss" scoped>
page {
background: #F5F0E7;
}
.header {
width: 100%;
min-height: 100vh;
display: flex;
align-items: flex-start;
flex-direction: column;
padding: 0 15rpx;
padding-bottom: 40rpx;
}
</style>