fix: 权益详情页修复底部预约条遮挡「权益说明」
- .bottom-bar 是 position:fixed 不占文档流,「权益说明」作为最后一个内容块, 短屏滚到底会被预约条压住 - 内容容器按底栏高度预留空间:padding-bottom calc(80px + env(safe-area-inset-bottom)) (底栏 12 + 按钮 44 + 12 = 68px,另留 12px 呼吸位,并兼容全面屏安全区) - 仅在存在底栏时生效:类名与底栏共用 detail.isAppointment 条件,不可预约的权益不会多出空白 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
eb01701709
commit
8b3ac20e34
@@ -1,6 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="page">
|
<view class="page">
|
||||||
<view v-if="detail">
|
<!-- xuchao: 底部「立即预约」是 fixed 不占位,短屏滚到底会把「权益说明」压住;
|
||||||
|
有底栏时给内容区预留 80px(底栏 68px + 12px 呼吸位)+ 安全区 -->
|
||||||
|
<view v-if="detail" :class="{ 'has-bottom-bar': detail.isAppointment }">
|
||||||
<!-- 门店信息卡片(信息+地址合并容器) -->
|
<!-- 门店信息卡片(信息+地址合并容器) -->
|
||||||
<view class="store-card">
|
<view class="store-card">
|
||||||
<view class="store-main">
|
<view class="store-main">
|
||||||
@@ -442,6 +444,11 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* 底部预约按钮 */
|
/* 底部预约按钮 */
|
||||||
|
/* xuchao: 内容区为 fixed 底栏预留的高度,短屏下「权益说明」才不会被遮住 */
|
||||||
|
.has-bottom-bar {
|
||||||
|
padding-bottom: calc(80px + env(safe-area-inset-bottom));
|
||||||
|
}
|
||||||
|
|
||||||
.bottom-bar {
|
.bottom-bar {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user