From 3e12b6d132416e4b3926b2790cedfed6ddacdfd4 Mon Sep 17 00:00:00 2001 From: Sebastian Castro Date: Fri, 17 Apr 2020 09:57:50 +0200 Subject: [PATCH] chat: fix coloring with dark background, and scrolling chattext when new message come in --- src/static/js/chat.js | 2 +- src/static/skins/colibris/src/components/chat.css | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/static/js/chat.js b/src/static/js/chat.js index 279ce7b45..2d60f73ff 100755 --- a/src/static/js/chat.js +++ b/src/static/js/chat.js @@ -89,7 +89,7 @@ var chat = (function() scrollDown: function() { if($('.chat-content').is(':visible')){ - if(!self.lastMessage || !self.lastMessage.position() || self.lastMessage.position().top < $('#chattext').height()) { + if(!self.lastMessage || !self.lastMessage.position() || self.lastMessage.position().top < ($('#chattext').outerHeight() + 20)) { // if we use a slow animate here we can have a race condition when a users focus can not be moved away // from the last message recieved. $('#chattext').animate({scrollTop: $('#chattext')[0].scrollHeight}, { duration: 400, queue: false }); diff --git a/src/static/skins/colibris/src/components/chat.css b/src/static/skins/colibris/src/components/chat.css index 14c645ecb..90c06c38e 100644 --- a/src/static/skins/colibris/src/components/chat.css +++ b/src/static/skins/colibris/src/components/chat.css @@ -1,5 +1,6 @@ #chatbox { background-color: transparent !important; + color: var(--text-color); } .chat-content { background: none;