feat: 优化

This commit is contained in:
2026-07-23 13:59:35 +08:00
parent 268207b01b
commit 3f335074ea
13 changed files with 614 additions and 580 deletions
+12 -23
View File
@@ -3,38 +3,22 @@
<view class="eval-header">
<view class="title">商品评价 ({{ totalCount }})</view>
<view class="more" @click="goMore">
<view class="rate"
>查看全部
<up-image
src="/static/common/right.png"
width="14"
height="14"
bgColor="#f1f6ff00"
class="arrow"
></up-image
></view>
<view class="rate">查看全部
<up-image src="/static/common/right.png" width="14" height="14" bgColor="#f1f6ff00" class="arrow"></up-image>
</view>
</view>
</view>
<view class="eval-list">
<view class="eval-item" v-for="(item, index) in list" :key="index">
<view class="user-info">
<view class="user-left">
<image
class="avatar"
:src="item.userImage"
mode="aspectFill"
></image>
<image class="avatar" :src="item.userImage" mode="aspectFill"></image>
<text class="username">{{ item.userName }}</text>
</view>
<view class="user-right">
<view class="stars">
<text
v-for="s in item.rating"
:key="s"
class="star-icon"
:style="{ color: s <= item.rating ? '#7934F6' : '#e5e5e5' }"
>★</text
>
<text v-for="s in item.rating" :key="s" class="star-icon"
:style="{ color: s <= item.rating ? '#7934F6' : '#e5e5e5' }">★</text>
</view>
</view>
</view>
@@ -109,6 +93,7 @@ export default {
/* 自适应父级宽度,可根据页面情况调整 margin */
margin: 20rpx auto;
box-sizing: border-box;
}
/* 头部样式 */
@@ -133,10 +118,12 @@ export default {
.rate {
color: #999999;
margin-right: 4rpx;
display: flex;
.arrow {
display: inline-block;
vertical-align: middle;
margin-left: 4rpx;
}
}
}
@@ -185,6 +172,7 @@ export default {
.user-right {
.stars {
display: flex;
.star-icon {
font-size: 26rpx;
margin-left: 6rpx;
@@ -196,6 +184,7 @@ export default {
/* 评价文字 */
.eval-content {
margin-bottom: 16rpx;
.text-desc {
font-size: 28rpx;
color: #333333;