Files
wx_pbzc/custom-tab-bar/index.wxss
T
lc 89d93c8155 refactor(ui): 12-point UI polish and bugfixes
Bug fixes:
- #1 Remove duplicate month label from calendar-heatmap (shown twice in records)
- #2 Extract shared .modal-overlay to app.wxss (was duplicated in index/records)

UX improvements:
- #3 Add long-press hint to history list in records page
- #4 Add drag handle + catchtouchmove to picker modal
- #5 Extend timer auto-navigate-back from 1.5s to 3s
- #6 Add clear data option in settings with confirmation dialog

Visual/code polish:
- #7 Remove 4 unused @keyframes (shimmer, spin) and 5 unused .icon classes
- #8 Tab bar inactive colors: hardcoded #888/#666 -> var(--text-secondary)
- #10 Split progress-ring observer to avoid redundant setData on size/color changes
- #12 Remove meaningless Math.min(planDay, 99) cap
2026-06-04 16:34:22 +08:00

147 lines
2.4 KiB
Plaintext

.tab-bar {
position: fixed;
bottom: 0;
left: 0;
right: 0;
height: 110rpx;
background: #FFFFFF;
display: flex;
align-items: center;
justify-content: space-around;
border-top: 1rpx solid rgba(0, 0, 0, 0.06);
padding-bottom: env(safe-area-inset-bottom);
z-index: 999;
}
.tab-item {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 6rpx 0;
flex: 1;
}
.tab-item:active {
transform: scale(0.9);
}
.tab-text {
font-size: 24rpx;
color: var(--text-secondary);
margin-top: 8rpx;
line-height: 1;
}
.tab-item.active .tab-text {
color: var(--primary);
font-weight: 600;
}
/* ---- icon: home ---- */
.icon-home {
position: relative;
width: 44rpx;
height: 40rpx;
}
.tab-item.active .icon-home {
animation: bounceSoft 0.5s ease;
}
.home-roof {
width: 0;
height: 0;
border-left: 22rpx solid transparent;
border-right: 22rpx solid transparent;
border-bottom: 18rpx solid var(--text-secondary);
position: absolute;
top: 0;
left: 0;
}
.tab-item.active .home-roof {
border-bottom-color: var(--primary);
}
.home-body {
width: 22rpx;
height: 20rpx;
background: var(--text-secondary);
position: absolute;
bottom: 0;
left: 11rpx;
border-radius: 2rpx 2rpx 0 0;
}
.tab-item.active .home-body {
background: var(--primary);
}
/* ---- icon: records (3 bars) ---- */
.icon-records {
width: 40rpx;
height: 34rpx;
display: flex;
flex-direction: column;
justify-content: flex-end;
gap: 6rpx;
}
.tab-item.active .icon-records {
animation: bounceSoft 0.5s ease;
}
.bar {
height: 6rpx;
background: var(--text-secondary);
border-radius: 3rpx;
}
.bar1 { width: 100%; }
.bar2 { width: 65%; }
.bar3 { width: 80%; }
.tab-item.active .bar {
background: var(--primary);
}
/* ---- icon: settings (gear) ---- */
.icon-settings {
position: relative;
width: 42rpx;
height: 42rpx;
}
.tab-item.active .icon-settings {
animation: bounceSoft 0.5s ease;
}
.gear-outer {
width: 36rpx;
height: 36rpx;
border: 5rpx solid var(--text-secondary);
border-radius: 50%;
position: absolute;
top: 3rpx;
left: 3rpx;
}
.tab-item.active .gear-outer {
border-color: var(--primary);
}
.gear-center {
width: 12rpx;
height: 12rpx;
background: var(--text-secondary);
border-radius: 50%;
position: absolute;
top: 15rpx;
left: 15rpx;
}
.tab-item.active .gear-center {
background: var(--primary);
}