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
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
<view class="heatmap-container">
|
||||
<view class="calendar-header">
|
||||
<text class="month-label">{{year}}年{{month}}月</text>
|
||||
<view class="weekday-labels">
|
||||
<text class="weekday" wx:for="{{['日','一','二','三','四','五','六']}}" wx:key="*this">{{item}}</text>
|
||||
</view>
|
||||
|
||||
@@ -6,15 +6,6 @@
|
||||
margin-bottom: 16rpx;
|
||||
}
|
||||
|
||||
.month-label {
|
||||
font-size: 28rpx;
|
||||
font-weight: 600;
|
||||
color: #333;
|
||||
margin-bottom: 12rpx;
|
||||
display: block;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.weekday-labels {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
|
||||
@@ -17,12 +17,15 @@ Component({
|
||||
},
|
||||
|
||||
observers: {
|
||||
'remaining, status, duration, size, ringWidth, primaryColor'() {
|
||||
'remaining, status, duration'() {
|
||||
const texts = { idle: '准备开始', running: '坚持住', paused: '已暂停', completed: '完成!' }
|
||||
this.setData({
|
||||
displayTime: util.formatTime(this.data.remaining),
|
||||
statusText: texts[this.data.status] || ''
|
||||
})
|
||||
},
|
||||
|
||||
'remaining, duration, size, ringWidth, primaryColor'() {
|
||||
this._draw()
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user