From 31d2ee6dfc5c9ac247b5e96f71cac8459c3ec754 Mon Sep 17 00:00:00 2001
From: "630892807@qq.com" <630892807@qq.com>
Date: Sun, 14 Mar 2021 20:18:56 +0800
Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E8=AF=95=E6=B5=8F=E8=A7=88=E5=99=A8?=
=?UTF-8?q?=E8=BD=AF=E9=94=AE=E7=9B=98=E9=97=AE=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
static/html/chat_page.html | 2 +-
static/js/chat-page.js | 14 ++++++++++++++
2 files changed, 15 insertions(+), 1 deletion(-)
diff --git a/static/html/chat_page.html b/static/html/chat_page.html
index 4cb3f36..ef2b80d 100644
--- a/static/html/chat_page.html
+++ b/static/html/chat_page.html
@@ -55,7 +55,7 @@
-
+
![]()
diff --git a/static/js/chat-page.js b/static/js/chat-page.js
index ae3cfa4..0f3e540 100644
--- a/static/js/chat-page.js
+++ b/static/js/chat-page.js
@@ -256,6 +256,20 @@ new Vue({
}
});
},
+ //软键盘问题
+ textareaFocus:function(){
+ if(/Android|webOS|iPhone|iPad|BlackBerry/i.test(navigator.userAgent)) {
+ $('body').scrollTop($("body")[0].scrollHeight);
+ $(".chatContext").css("margin-bottom","1px");
+ $(".chatBoxSend").css("position","static");
+ }
+ },
+ textareaBlur:function(){
+ if(/Android|webOS|iPhone|iPad|BlackBerry/i.test(navigator.userAgent)) {
+ $(".chatContext").css("margin-bottom","105px");
+ $(".chatBoxSend").css("position","fixed");
+ }
+ },
//获取日期
getNowDate : function() {// 获取日期
var d = new Date(new Date());