From 6238f01346bffa3c0a85612d9e69770b3f6eca98 Mon Sep 17 00:00:00 2001 From: lik Date: Mon, 9 Nov 2026 16:24:49 +0800 Subject: [PATCH] =?UTF-8?q?style(escort):=20=E9=A2=84=E7=BA=A6=E8=A1=A8?= =?UTF-8?q?=E5=8D=95=E8=A1=8C=E6=A0=87=E7=AD=BE=E5=8A=A0=E6=B5=85=E5=BA=95?= =?UTF-8?q?tag=EF=BC=8C=E5=8C=BB=E9=99=A2=E4=B8=8B=E6=8B=89=E8=A1=A5?= =?UTF-8?q?=E9=81=AE=E7=BD=A9=E4=B8=8E=E6=94=B6=E8=B5=B7=E5=85=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 行标题统一 190rpx 浅橙底 tag,整列对齐 - 医院下拉展开时加全屏遮罩,点空白处收起 - 下拉面板改白底橙边,收起文案换箭头图标,列表加高到 6 行 - 各 picker 补下拉箭头,行分隔线改点分线,底部占位加高避开固定栏 --- components/hospital-select/index.js | 5 ++- components/hospital-select/index.wxml | 8 +++- components/hospital-select/index.wxss | 57 ++++++++++++++++++++++++--- pages/escort/itemorder.wxml | 20 ++++++++-- pages/escort/itemorder.wxss | 36 +++++++++++++++-- 5 files changed, 110 insertions(+), 16 deletions(-) diff --git a/components/hospital-select/index.js b/components/hospital-select/index.js index aed81e8..cf99e6b 100644 --- a/components/hospital-select/index.js +++ b/components/hospital-select/index.js @@ -60,7 +60,7 @@ Component({ methods: { refreshFiltered(options = this.data.options, keyword = this.data.keyword) { const filtered = filterHospitals(options, keyword) - const visibleRows = Math.min(filtered.length, 4) + const visibleRows = Math.min(filtered.length, 6) this.setData({ filtered, optionsHeight: visibleRows * OPTION_HEIGHT, @@ -112,6 +112,9 @@ Component({ this.setData({ open: false, keyword: '', optionsHeight: 0, manualEntry: false }) }, + // 遮罩占位:catchtouchmove 阻止穿透滚动页面 + noop() {}, + onKeywordInput(e) { const keyword = e.detail.value this.setData({ keyword }) diff --git a/components/hospital-select/index.wxml b/components/hospital-select/index.wxml index 78e634d..593ba72 100644 --- a/components/hospital-select/index.wxml +++ b/components/hospital-select/index.wxml @@ -1,4 +1,6 @@ - + + + {{label}} @@ -17,7 +19,9 @@ confirm-type="search" bindinput="onKeywordInput" /> - 收起 + + + diff --git a/components/hospital-select/index.wxss b/components/hospital-select/index.wxss index 30e0cf7..d890e95 100644 --- a/components/hospital-select/index.wxss +++ b/components/hospital-select/index.wxss @@ -1,10 +1,34 @@ /* 医院选择:行结构与页面表单保持一致,展开面板作为行内下拉 */ +/* 展开时整组件抬到遮罩之上:遮罩盖住页面其余内容(含底部栏 100),面板仍可点 */ +.hospital-select.is-open { + position: relative; + z-index: 151; +} + +/* 展开遮罩:浅墨半透明,点击任意空白处收起;层级低于页面支付弹窗(200/201) */ +.hospital-mask { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 1; + background: rgba(43, 37, 33, 0.3); +} + +/* 展开时行与面板抬到遮罩之上(同属 .is-open 层叠上下文,仅内部比较) */ +.hospital-select.is-open .hospital-row, +.hospital-select.is-open .hospital-panel { + position: relative; + z-index: 2; +} + .hospital-row { display: flex; align-items: center; justify-content: space-between; padding: 24rpx 0; - border-bottom: 2rpx solid var(--line, #ECE3D6); + border-bottom: 2rpx dotted var(--line-soft, #E9DECB); } .is-compact .hospital-row { @@ -37,6 +61,16 @@ margin-left: 24rpx; } +/* 行标题:浅橙底 tag,与页面表单 .order-label 同款(同宽对齐) */ +.hospital-label { + box-sizing: border-box; + min-width: 190rpx; + padding: 8rpx 20rpx; + text-align: center; + background: var(--brand-soft, #FFF4E8); + border-radius: 12rpx; +} + .hospital-value-text { min-width: 0; overflow: hidden; @@ -124,13 +158,13 @@ transform: rotate(-135deg); } -/* 展开面板:浅橙衬底 + 2rpx 浅橙描边托形,与白卡拉开边界(不用阴影) */ +/* 展开面板:白底 + 2rpx 浅橙描边托形,与白卡靠橙边区分(不用阴影) */ .hospital-panel { margin: 12rpx 0 24rpx; padding: 0 20rpx 20rpx; border: 2rpx solid var(--brand-line, #FFE0C2); border-radius: 20rpx; - background: var(--brand-soft, #FFF4E8); + background: var(--white, #FFFFFF); } .hospital-search { @@ -150,11 +184,22 @@ border-radius: 12rpx; } +/* 收起按钮:上箭头图标(CSS 边框三角,不依赖字体图标),留足点击热区 */ .hospital-search-close { + display: flex; flex-shrink: 0; + align-items: center; + justify-content: center; margin-left: 16rpx; - color: var(--muted, #6F655C); - font-size: var(--fs-28, 28rpx); + padding: 12rpx; +} + +.hospital-collapse-arrow { + width: 20rpx; + height: 20rpx; + border-top: 4rpx solid var(--brand-ink, #9B4508); + border-right: 4rpx solid var(--brand-ink, #9B4508); + transform: rotate(-45deg); } .hospital-search-close:active { @@ -178,7 +223,7 @@ } .hospital-option:active { - background: var(--white, #FFFFFF); + background: var(--brand-soft, #FFF4E8); } .hospital-option-main { diff --git a/pages/escort/itemorder.wxml b/pages/escort/itemorder.wxml index 1091f64..8873144 100644 --- a/pages/escort/itemorder.wxml +++ b/pages/escort/itemorder.wxml @@ -80,7 +80,10 @@ 就诊省份 - {{province || '请选择省份'}} + + {{province || '请选择省份'}} + + @@ -97,14 +100,20 @@ 陪诊师性别 - {{gender || '请选择性别要求'}} + + {{gender || '请选择性别要求'}} + + 预约日期 - {{appointmentDate || '请选择预约日期'}} + + {{appointmentDate || '请选择预约日期'}} + + @@ -112,7 +121,10 @@ 预约时间 - {{appointmentTime || '请选择预约时间'}} + + {{appointmentTime || '请选择预约时间'}} + + diff --git a/pages/escort/itemorder.wxss b/pages/escort/itemorder.wxss index 3f71875..7ee3184 100644 --- a/pages/escort/itemorder.wxss +++ b/pages/escort/itemorder.wxss @@ -55,7 +55,7 @@ page { /* 陪诊项目:展示沿用原项目卡片,点击卡片展开下拉列表 */ .service-picker-row { padding: 24rpx 0; - border-bottom: 2rpx solid var(--line); + border-bottom: 2rpx dotted var(--line-soft, #E9DECB); } .service-picker { @@ -225,12 +225,13 @@ page { font-size: var(--fs-30); } +/* 行间分隔:点分线(2rpx 才在真机可见,1rpx 会碎成像素噪点) */ .order-row { display: flex; align-items: center; justify-content: space-between; padding: 24rpx 0; - border-bottom: 2rpx solid var(--line); + border-bottom: 2rpx dotted var(--line-soft, #E9DECB); } .order-row:last-child { @@ -245,9 +246,21 @@ page { .order-label { flex-shrink: 0; + box-sizing: border-box; + /* 统一宽度:容纳 5 字标题(5×30 + 40 内边距),短标题居中补齐 */ + min-width: 190rpx; + padding: 8rpx 20rpx; color: var(--muted); font-size: var(--fs-30); letter-spacing: 1rpx; + text-align: center; + background: var(--brand-soft, #FFF4E8); + border-radius: 12rpx; +} + +/* 竖排行标题不随 stretch 撑满整行,保持 tag 宽度 */ +.order-row.column .order-label { + align-self: flex-start; } .order-input, @@ -282,6 +295,23 @@ page { text-align: right; } +/* picker 取值 + 下拉箭头:右对齐成一列,与医院选择行的箭头对齐 */ +.picker-value-wrap { + display: flex; + align-items: center; + justify-content: flex-end; + gap: 12rpx; +} + +.picker-chevron { + flex-shrink: 0; + width: 16rpx; + height: 16rpx; + border-right: 2rpx solid var(--muted, #6F655C); + border-bottom: 2rpx solid var(--muted, #6F655C); + transform: rotate(45deg); +} + .order-textarea { box-sizing: border-box; width: 100%; @@ -392,7 +422,7 @@ page { } .bottom-placeholder { - height: 152rpx; + height: 200rpx; } .bottom-bar {