style: move post favorite beside share
This commit is contained in:
@@ -6,11 +6,17 @@
|
|||||||
<u-icon name="arrow-left" size="40" color="#111111" />
|
<u-icon name="arrow-left" size="40" color="#111111" />
|
||||||
</view>
|
</view>
|
||||||
<text class="detail-topbar__title">帖子详情</text>
|
<text class="detail-topbar__title">帖子详情</text>
|
||||||
|
<view class="detail-topbar__actions">
|
||||||
|
<view class="detail-topbar__action" @tap="handleFavorite">
|
||||||
|
<u-icon :name="isFavorite ? 'star-fill' : 'star'" size="40"
|
||||||
|
:color="isFavorite ? '#e6a23c' : '#111111'" />
|
||||||
|
</view>
|
||||||
<view class="detail-topbar__action" @tap="handleShare">
|
<view class="detail-topbar__action" @tap="handleShare">
|
||||||
<u-icon name="share" size="42" color="#111111" />
|
<u-icon name="share" size="42" color="#111111" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
<scroll-view scroll-y class="detail-scroll">
|
<scroll-view scroll-y class="detail-scroll">
|
||||||
<view v-if="loading" class="detail-loading">
|
<view v-if="loading" class="detail-loading">
|
||||||
@@ -155,12 +161,6 @@
|
|||||||
<u-icon name="thumb-up" size="34" :color="post.is_liked ? '#1468f5' : '#737373'" />
|
<u-icon name="thumb-up" size="34" :color="post.is_liked ? '#1468f5' : '#737373'" />
|
||||||
<text :class="{ 'is-active': post.is_liked }">{{ formatCount(post.like_count) }}</text>
|
<text :class="{ 'is-active': post.is_liked }">{{ formatCount(post.like_count) }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="detail-interaction__stat detail-interaction__stat--favorite"
|
|
||||||
@tap="handleFavorite">
|
|
||||||
<u-icon :name="isFavorite ? 'star-fill' : 'star'" size="34"
|
|
||||||
:color="isFavorite ? '#e6a23c' : '#737373'" />
|
|
||||||
<text :class="{ 'is-active': isFavorite }">{{ isFavorite ? '已藏' : '收藏' }}</text>
|
|
||||||
</view>
|
|
||||||
<view class="detail-interaction__stat">
|
<view class="detail-interaction__stat">
|
||||||
<u-icon name="chat" size="34" color="#737373" />
|
<u-icon name="chat" size="34" color="#737373" />
|
||||||
<text>{{ formatCount(post.comment_count) }}</text>
|
<text>{{ formatCount(post.comment_count) }}</text>
|
||||||
@@ -913,6 +913,7 @@ const formatCommentTime = (value: any) => {
|
|||||||
border-bottom: 1rpx solid #edf0f4;
|
border-bottom: 1rpx solid #edf0f4;
|
||||||
|
|
||||||
&__nav {
|
&__nav {
|
||||||
|
position: relative;
|
||||||
height: 96rpx;
|
height: 96rpx;
|
||||||
padding: 0 28rpx;
|
padding: 0 28rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -933,7 +934,16 @@ const formatCommentTime = (value: any) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&__actions {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 4rpx;
|
||||||
|
}
|
||||||
|
|
||||||
&__title {
|
&__title {
|
||||||
|
position: absolute;
|
||||||
|
left: 50%;
|
||||||
|
transform: translateX(-50%);
|
||||||
font-size: 34rpx;
|
font-size: 34rpx;
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
|
|||||||
Reference in New Issue
Block a user