爱简收旧衣按件回收前端代码仓库
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

115 lines
2.5 KiB

<template>
<view class="about-container">
<!-- 顶部导航栏 -->
<view class="nav-bar" :style="{paddingTop: statusBarHeight + 'px'}">
<view class="back" @tap="goBack">
<uni-icons type="left" size="20"></uni-icons>
</view>
<text class="nav-title">关于我们</text>
<view class="nav-icons">
<!-- 占位元素保持布局对称 -->
</view>
</view>
<!-- 主卡片 -->
<view class="main-card" :style="{marginTop: 'calc(200rpx )'}">
<!-- 富文本内容 -->
<rich-text :nodes="memberTextContent" class="rich-text-content"></rich-text>
</view>
</view>
</template>
<script>
export default {
data() {
return {
statusBarHeight: 0
}
},
computed: {
memberTextContent() {
console.log(getApp().globalData.configData, 'about-getApp().globalData.configData')
const item = getApp().globalData.configData.find(i => i.keyName === 'member_text')
return item ? item.keyContent : ''
}
},
onLoad() {
this.statusBarHeight = uni.getSystemInfoSync().statusBarHeight
},
onPullDownRefresh() {
// 模拟刷新数据
setTimeout(() => {
uni.stopPullDownRefresh()
uni.showToast({
title: '刷新成功',
icon: 'success',
duration: 2000
})
}, 1000)
},
methods: {
goBack() {
uni.navigateBack();
}
}
}
</script>
<style scoped lang="scss">
.about-container {
min-height: 100vh;
background: linear-gradient(180deg, #fff3db 0%, #fffefb 30%);
padding-bottom: 40rpx;
}
.nav-bar {
display: flex;
align-items: center;
height: calc(150rpx + var(--status-bar-height));
padding: 0 32rpx;
background: #fffbe6;
position: fixed;
top: 0;
left: 0;
right: 0;
z-index: 999;
box-sizing: border-box;
box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.03);
.back {
padding: 20rpx;
margin-left: -20rpx;
}
.nav-title {
flex: 1;
text-align: center;
font-family: PingFang SC;
font-weight: 500;
font-size: 16px;
line-height: 140%;
letter-spacing: 0%;
text-align: center;
vertical-align: middle;
font-weight: 500;
color: #222;
}
.nav-icons {
display: flex;
align-items: center;
gap: 12px;
}
}
.main-card {
background: #ffffff;
border-radius: 36rpx;
box-shadow: 0 8rpx 32rpx rgba(255, 156, 0, 0.08);
margin: 0 24rpx 0 24rpx;
padding: 20rpx 32rpx 32rpx 32rpx;
display: flex;
flex-direction: column;
align-items: stretch;
}
.rich-text-content {
width: 100%;
line-height: 1.7;
font-size: 26rpx;
color: #444;
}
</style>