feat: upgrade custom tabbar with emoji support, redesign quick-actions
- Switch back to custom tabbar (custom: true) with emoji fix (line-height, font-family) - Redesign home quick-actions: product/followup/analytics/notifications replace redundant nav items - Refactor goToPage to auto-detect tabbar vs non-tabbar pages - Update PROGRESS.md
This commit is contained in:
@@ -82,7 +82,8 @@ onUnmounted(() => {
|
||||
|
||||
.tab-bar-icon {
|
||||
font-size: 28px !important;
|
||||
line-height: 1 !important;
|
||||
line-height: 1.5 !important;
|
||||
font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif !important;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
|
||||
@@ -105,7 +105,7 @@
|
||||
"backgroundColor": "#f5f5f5"
|
||||
},
|
||||
"tabBar": {
|
||||
"custom": false,
|
||||
"custom": true,
|
||||
"color": "#666666",
|
||||
"selectedColor": "#1890ff",
|
||||
"backgroundColor": "#ffffff",
|
||||
|
||||
@@ -93,29 +93,35 @@
|
||||
</view>
|
||||
|
||||
<view class="quick-actions">
|
||||
<view class="action-item" @click="goToPage('/pages/translate/translate')">
|
||||
<view class="action-item" @click="hasLogin ? goToPage('/pages/product/product') : goToLogin()">
|
||||
<view class="action-icon-wrap" style="background:#e6f7ff">
|
||||
<text class="action-icon-text" style="color:#1890ff">译</text>
|
||||
<text class="action-icon-text" style="color:#1890ff">品</text>
|
||||
</view>
|
||||
<text class="action-label">智能翻译</text>
|
||||
<text class="action-label">产品库</text>
|
||||
</view>
|
||||
<view class="action-item" @click="hasLogin ? goToPage('/pages/customers/customers') : goToLogin()">
|
||||
<view class="action-icon-wrap" style="background:#fff7e6">
|
||||
<text class="action-icon-text" style="color:#fa8c16">客</text>
|
||||
<view class="action-item" @click="hasLogin ? goToPage('/pages/followup/followup') : goToLogin()">
|
||||
<view class="action-icon-wrap" style="background:#f0f0ff">
|
||||
<text class="action-icon-text" style="color:#667eea">跟</text>
|
||||
</view>
|
||||
<text class="action-label">客户管理</text>
|
||||
<text class="action-label">
|
||||
<text>跟进</text>
|
||||
<text class="action-badge" v-if="hasLogin && followupStats.pending > 0">{{ followupStats.pending > 99 ? '99+' : followupStats.pending }}</text>
|
||||
</text>
|
||||
</view>
|
||||
<view class="action-item" @click="hasLogin ? goToPage('/pages/marketing/marketing') : goToLogin()">
|
||||
<view class="action-item" @click="hasLogin ? goToPage('/pages/analytics/analytics') : goToLogin()">
|
||||
<view class="action-icon-wrap" style="background:#f6ffed">
|
||||
<text class="action-icon-text" style="color:#52c41a">营</text>
|
||||
<text class="action-icon-text" style="color:#52c41a">数</text>
|
||||
</view>
|
||||
<text class="action-label">营销文案</text>
|
||||
<text class="action-label">数据</text>
|
||||
</view>
|
||||
<view class="action-item" @click="hasLogin ? goToPage('/pages/quotation/quotation') : goToLogin()">
|
||||
<view class="action-icon-wrap" style="background:#fff0f6">
|
||||
<text class="action-icon-text" style="color:#eb2f96">价</text>
|
||||
<view class="action-item" @click="hasLogin ? goToPage('/pages/notification/notification') : goToLogin()">
|
||||
<view class="action-icon-wrap" style="background:#fff7e6">
|
||||
<text class="action-icon-text" style="color:#fa8c16">知</text>
|
||||
</view>
|
||||
<text class="action-label">报价单</text>
|
||||
<text class="action-label">
|
||||
<text>通知</text>
|
||||
<text class="action-badge" v-if="hasLogin && unreadCount > 0">{{ unreadCount > 99 ? '99+' : unreadCount }}</text>
|
||||
</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -343,11 +349,13 @@ const loadData = async () => {
|
||||
}
|
||||
}
|
||||
|
||||
const tabbarPages = ['/pages/index/index', '/pages/translate/translate', '/pages/customers/customers', '/pages/marketing/marketing', '/pages/quotation/quotation']
|
||||
|
||||
const goToPage = (url) => {
|
||||
if (url === '/pages/followup/followup') {
|
||||
uni.navigateTo({ url })
|
||||
} else {
|
||||
if (tabbarPages.includes(url)) {
|
||||
uni.switchTab({ url })
|
||||
} else {
|
||||
uni.navigateTo({ url })
|
||||
}
|
||||
}
|
||||
|
||||
@@ -785,6 +793,21 @@ const copyTryResult = () => {
|
||||
.action-label {
|
||||
font-size: 22rpx;
|
||||
color: #666;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 4rpx;
|
||||
}
|
||||
|
||||
.action-badge {
|
||||
background: #ff4d4f;
|
||||
color: #fff;
|
||||
font-size: 18rpx;
|
||||
min-width: 28rpx;
|
||||
height: 28rpx;
|
||||
border-radius: 14rpx;
|
||||
text-align: center;
|
||||
line-height: 28rpx;
|
||||
padding: 0 6rpx;
|
||||
}
|
||||
|
||||
.more-section {
|
||||
|
||||
Reference in New Issue
Block a user