feat: Notifications
This commit is contained in:
@@ -10,13 +10,6 @@
|
|||||||
<view v-if="unreadCount > 0" class="unread-chip">
|
<view v-if="unreadCount > 0" class="unread-chip">
|
||||||
<text class="unread-chip-text">{{ unreadCount }} 未读</text>
|
<text class="unread-chip-text">{{ unreadCount }} 未读</text>
|
||||||
</view>
|
</view>
|
||||||
<view
|
|
||||||
class="read-all-btn"
|
|
||||||
:class="{ disabled: readingAll || unreadCount === 0 }"
|
|
||||||
@tap="handleMarkAllRead"
|
|
||||||
>
|
|
||||||
<text class="read-all-text">{{ readingAll ? "处理中" : "全部已读" }}</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -24,25 +17,6 @@
|
|||||||
<view :style="{ height: statusBarHeight + 64 + 'px' }"></view>
|
<view :style="{ height: statusBarHeight + 64 + 'px' }"></view>
|
||||||
|
|
||||||
<view class="page-body">
|
<view class="page-body">
|
||||||
<view class="hero-card">
|
|
||||||
<view class="hero-stats">
|
|
||||||
<view class="hero-stat">
|
|
||||||
<text class="hero-stat-num">{{ totalCount }}</text>
|
|
||||||
<text class="hero-stat-label">全部消息</text>
|
|
||||||
</view>
|
|
||||||
<view class="hero-divider"></view>
|
|
||||||
<view class="hero-stat">
|
|
||||||
<text class="hero-stat-num accent">{{ unreadCount }}</text>
|
|
||||||
<text class="hero-stat-label">未读提醒</text>
|
|
||||||
</view>
|
|
||||||
<view class="hero-divider"></view>
|
|
||||||
<view class="hero-stat">
|
|
||||||
<text class="hero-stat-num">{{ todayCount }}</text>
|
|
||||||
<text class="hero-stat-label">今日新增</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view v-if="!isLoggedIn" class="state-card login-card">
|
<view v-if="!isLoggedIn" class="state-card login-card">
|
||||||
<text class="state-title">登录后查看你的系统消息</text>
|
<text class="state-title">登录后查看你的系统消息</text>
|
||||||
<text class="state-desc">审核结果、评论互动、点赞提醒都会同步到这里。</text>
|
<text class="state-desc">审核结果、评论互动、点赞提醒都会同步到这里。</text>
|
||||||
@@ -62,7 +36,13 @@
|
|||||||
<text class="filter-tab-text">{{ tab.label }}</text>
|
<text class="filter-tab-text">{{ tab.label }}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<text class="filter-hint">{{ activeFilter === "unread" ? "只看未读" : "全部消息" }}</text>
|
<view
|
||||||
|
class="read-all-btn filter-read-all-btn"
|
||||||
|
:class="{ disabled: readingAll || unreadCount === 0 }"
|
||||||
|
@tap="handleMarkAllRead"
|
||||||
|
>
|
||||||
|
<text class="read-all-text">{{ readingAll ? "处理中" : "全部已读" }}</text>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view v-if="loading && !notificationList.length" class="state-card">
|
<view v-if="loading && !notificationList.length" class="state-card">
|
||||||
@@ -563,6 +543,11 @@ onReachBottom(() => {
|
|||||||
background: #111111;
|
background: #111111;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.filter-read-all-btn {
|
||||||
|
flex-shrink: 0;
|
||||||
|
padding: 10rpx 22rpx;
|
||||||
|
}
|
||||||
|
|
||||||
.read-all-btn.disabled {
|
.read-all-btn.disabled {
|
||||||
opacity: 0.45;
|
opacity: 0.45;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user