From 0dfa3bc5a89cb21459f7431d699d45cd2d0fd895 Mon Sep 17 00:00:00 2001 From: xiaowang <2161656029@qq.com> Date: Sun, 8 Nov 2026 00:28:17 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=B0=8F=E7=A8=8B=E5=BA=8F?= =?UTF-8?q?=E6=97=A5=E7=A8=8B=E9=A1=B5=E6=97=A5=E8=A7=86=E5=9B=BE=E6=9C=AB?= =?UTF-8?q?=E6=9D=A1=E5=86=85=E5=AE=B9=E8=A2=AB=E6=BB=9A=E5=8A=A8=E5=AE=B9?= =?UTF-8?q?=E5=99=A8=E5=BA=95=E8=BE=B9=E8=A3=81=E5=88=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 日视图滚动容器末尾新增留白(64rpx + 安全区),避免末条时间刻度与末个预约卡片贴边、滚到底仍缺一截 - 视口高度计算同步预留该留白,短时间轴不再因高度刚好等于内容高度而裁掉末条标签 - 时间刻度列加宽到 104rpx,刻度与泳道内容间距增至 20rpx,改善左侧呼吸感并避免刻度文字被截断 --- JC-Salon-WeChat/pages/planning/index.js | 5 ++++- JC-Salon-WeChat/pages/planning/index.test.js | 2 +- JC-Salon-WeChat/pages/planning/index.wxml | 1 + JC-Salon-WeChat/pages/planning/index.wxss | 10 +++++++--- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/JC-Salon-WeChat/pages/planning/index.js b/JC-Salon-WeChat/pages/planning/index.js index ce16465c..5827479a 100644 --- a/JC-Salon-WeChat/pages/planning/index.js +++ b/JC-Salon-WeChat/pages/planning/index.js @@ -21,6 +21,9 @@ function resolveCalendarErrorMessage(error) { const LANE_TINTS = ['#EAF3FA', '#FBF1EB', '#EEF5EF'] +// 日视图时间轴末尾留白(rpx):避免末条时间刻度与末个预约卡片贴住滚动容器底边 +const TIMELINE_BOTTOM_SPACE = 64 + const DESIGN_ARTIST_COLORS = { 张小雨: '#43789E', 林小满: '#96684B', @@ -747,7 +750,7 @@ Page({ hours, hasTimedAppointments: timedAppointments.length > 0, timelineHeight: timelineHeight + laneHeaderHeight, - timelineViewportHeight: Math.min(820, timelineHeight + laneHeaderHeight), + timelineViewportHeight: Math.min(820, timelineHeight + laneHeaderHeight + TIMELINE_BOTTOM_SPACE), laneHeaderHeight, laneItemWidth: 248, laneWidth: Math.max(720, lanes.reduce((width, lane) => width + (lane.width || 248), 0)), diff --git a/JC-Salon-WeChat/pages/planning/index.test.js b/JC-Salon-WeChat/pages/planning/index.test.js index c779b2b1..ea72daba 100644 --- a/JC-Salon-WeChat/pages/planning/index.test.js +++ b/JC-Salon-WeChat/pages/planning/index.test.js @@ -135,7 +135,7 @@ async function run() { }) assert.strictEqual(shortAppointmentState.hours[0].top, 54) assert.strictEqual(shortAppointmentState.hours[1].top, 204) - assert.strictEqual(shortAppointmentState.timelineViewportHeight, 204) + assert.strictEqual(shortAppointmentState.timelineViewportHeight, 268) const shortAppointmentLane = shortAppointmentState.dayLanes.find(lane => lane.artistId === 1) assert.strictEqual(shortAppointmentLane.blocks[0].height, 40) assert.strictEqual(shortAppointmentLane.blocks[0].compact, true) diff --git a/JC-Salon-WeChat/pages/planning/index.wxml b/JC-Salon-WeChat/pages/planning/index.wxml index 0d5b8222..929887f3 100644 --- a/JC-Salon-WeChat/pages/planning/index.wxml +++ b/JC-Salon-WeChat/pages/planning/index.wxml @@ -128,6 +128,7 @@ + diff --git a/JC-Salon-WeChat/pages/planning/index.wxss b/JC-Salon-WeChat/pages/planning/index.wxss index 2e206db7..08833170 100644 --- a/JC-Salon-WeChat/pages/planning/index.wxss +++ b/JC-Salon-WeChat/pages/planning/index.wxss @@ -371,12 +371,16 @@ position: relative; } +.timeline-bottom-space { + height: calc(64rpx + env(safe-area-inset-bottom)); +} + .time-axis { position: absolute; top: 0; left: 0; z-index: 4; - width: 92rpx; + width: 104rpx; height: 100%; border-right: 1rpx solid #e7ece9; background: #ffffff; @@ -390,7 +394,7 @@ .time-label { position: absolute; - right: 12rpx; + right: 16rpx; color: #71807a; font-size: 20rpx; line-height: 1; @@ -402,7 +406,7 @@ position: absolute; top: 0; right: 0; - left: 104rpx; + left: 124rpx; height: 100%; }