diff --git a/pages/message/chat.scss b/pages/message/chat.scss index 320ab16..72447c2 100644 --- a/pages/message/chat.scss +++ b/pages/message/chat.scss @@ -6,13 +6,15 @@ $text-color-sub: #999; $primary-color: #0877F1; .chat-page { + position: fixed; + top: 0; + left: 0; + right: 0; + bottom: 0; display: flex; flex-direction: column; - height: 100vh; background-color: #f5f5f5; overflow: hidden; - position: relative; - width: 100%; } /* 患者信息栏样式 - 固定在顶部 */ @@ -24,10 +26,8 @@ $primary-color: #0877F1; background: #fff; border-bottom: 1rpx solid #f0f0f0; padding: 20rpx 32rpx; - z-index: 100; - flex-shrink: 0; /* 防止被压缩 */ - width: 100%; - box-sizing: border-box; + z-index: 10; + flex-shrink: 0; } .patient-info-content { @@ -91,15 +91,14 @@ $primary-color: #0877F1; } .chat-content { - flex: 1; + position: fixed; + top: 100rpx; /* 患者信息栏高度,根据实际调整 */ + left: 0; + right: 0; + bottom: 200rpx; /* 输入框高度,根据实际调整 */ box-sizing: border-box; overflow-x: hidden; overflow-y: auto; - min-height: 0; - margin-top: 120rpx; - margin-bottom: 0; - position: relative; - z-index: 1; } .chat-content-compressed { @@ -364,19 +363,31 @@ $primary-color: #0877F1; } .input-section { + position: fixed; + bottom: 0; + left: 0; + right: 0; background: #fff; - border-top: 1rpx solid #e0e0e0; - position: relative; z-index: 200; - padding-bottom: env(safe-area-inset-bottom); flex-shrink: 0; + transform: translateZ(0); /* 开启硬件加速,提升性能 */ + display: flex; + flex-direction: column; +} + +.ai-assistant-slot { + width: 100%; + background: #fff; } .input-toolbar { display: flex; align-items: center; - padding: 16rpx 20rpx; + padding: 12rpx 20rpx; + padding-bottom: env(safe-area-inset-bottom); gap: 12rpx; + border-top: 1rpx solid #e0e0e0; + background: #fff; } .voice-toggle-btn { @@ -499,7 +510,8 @@ $primary-color: #0877F1; justify-content: flex-start; background: #fff; border-top: 1rpx solid #eee; - padding: 20rpx 0 40rpx 60rpx; + padding: 20rpx 0 20rpx 60rpx; + padding-bottom: env(safe-area-inset-bottom); gap: 40rpx 50rpx; flex-wrap: wrap; background-color: #f5f5f5; diff --git a/pages/message/components/ai-assistant-buttons.vue b/pages/message/components/ai-assistant-buttons.vue index 40b93af..634cf87 100644 --- a/pages/message/components/ai-assistant-buttons.vue +++ b/pages/message/components/ai-assistant-buttons.vue @@ -383,7 +383,6 @@ defineExpose({ gap: 16rpx; padding: 16rpx 24rpx; background-color: #f8f9fa; - border-bottom: 1rpx solid #e5e5e5; .ai-button { display: flex; diff --git a/pages/message/components/chat-input.vue b/pages/message/components/chat-input.vue index fb83473..515345b 100644 --- a/pages/message/components/chat-input.vue +++ b/pages/message/components/chat-input.vue @@ -1,5 +1,10 @@