fix: chat 视图 scroll-view 添加 height: 100% + min-height: 0

参考项目内已工作的 .result-view 模式:
- flex: 1 仅在 flex 布局父容器中生效
- 但 UniApp <scroll-view> 是原生组件,必须显式 height: 100%
- 同时 min-height: 0 确保 flex 子项可收缩

之前只设 flex: 1,真机上原生 scroll-view 无法计算可滚动区域。
This commit is contained in:
2026-07-19 18:32:09 +08:00
parent 30ecf9f4a3
commit f07817aaff
+6 -2
View File
@@ -3542,9 +3542,13 @@ onUnmounted(() => {
}
.chat-scroll {
position: relative;
z-index: 1;
flex: 1;
/* 删除固定 height,让 flex: 1 自适应剩余空间 */
/* 真机上设备高度、状态栏、tab 栏各不相同,硬编码 220rpx 会导致滚动失效 */
height: 100%;
min-height: 0;
/* 参考 .result-viewUniApp <scroll-view> 必须显式 height: 100% + min-height: 0 才能正确滚动 */
/* 仅 flex: 1 在真机上无法让原生 scroll-view 组件计算可滚动区域 */
}
.chat-scroll-content {