Browse Source

修复chat/index页面横向滚动问题

pull/12/head
徐飞洋 2 months ago
parent
commit
665536c73c
  1. 1
      pages/chat/index.wxml
  2. 9
      pages/chat/index.wxss

1
pages/chat/index.wxml

@ -21,6 +21,7 @@
<!-- 聊天列表 --> <!-- 聊天列表 -->
<scroll-view <scroll-view
scroll-y="true" scroll-y="true"
scroll-x="false"
class="chat-scroll-view" class="chat-scroll-view"
refresher-enabled="{{true}}" refresher-enabled="{{true}}"
refresher-triggered="{{isRefreshing}}" refresher-triggered="{{isRefreshing}}"

9
pages/chat/index.wxss

@ -35,6 +35,13 @@
.chat-scroll-view { .chat-scroll-view {
flex: 1; flex: 1;
overflow-y: auto; overflow-y: auto;
overflow-x: hidden;
width: 100%;
}
/* 确保容器不产生横向滚动 */
.chat-container {
overflow-x: hidden;
} }
/* 聊天项 */ /* 聊天项 */
@ -45,6 +52,8 @@
background-color: #fff; background-color: #fff;
border-bottom: 1rpx solid #f0f0f0; border-bottom: 1rpx solid #f0f0f0;
transition: background-color 0.2s; transition: background-color 0.2s;
box-sizing: border-box;
overflow: hidden;
} }
.chat-item:active { .chat-item:active {

Loading…
Cancel
Save