summaryrefslogtreecommitdiff
path: root/addons/mail/static/src/js/chat_window.js
diff options
context:
space:
mode:
authorAaron Bohy <aab@odoo.com>2017-09-15 15:25:16 +0200
committerAaron Bohy <aab@odoo.com>2017-09-15 15:25:16 +0200
commit13a44d33bda1d7ff21e3de5de8b3c84f6a482a0d (patch)
treebc30e753ecc419f93a7f156d10b557ffb9e4c6c1 /addons/mail/static/src/js/chat_window.js
parenta8e7d096b85709ccf52411c450d0574f9238fd6f (diff)
parent7a91d87614f9a72df1d81ee28a5f425517e9b218 (diff)
[MERGE] im_livechat, mail: new Discuss mobile UI
- Brand new UI for Discuss client action (with tabs for for Discuss client action (with tabs for Inbox, chats, channels...) - In mobile, conversations always open in Chat Windows - Chat window UI improved (both mobile and desktop) - Channels preview (used in the systray menu, and now in the mobile UI of Discuss) improved - Other minor less tweaks Task #31446 PR #16995
Diffstat (limited to 'addons/mail/static/src/js/chat_window.js')
-rw-r--r--addons/mail/static/src/js/chat_window.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/addons/mail/static/src/js/chat_window.js b/addons/mail/static/src/js/chat_window.js
index 9f91baee764..d65660ef90c 100644
--- a/addons/mail/static/src/js/chat_window.js
+++ b/addons/mail/static/src/js/chat_window.js
@@ -11,7 +11,7 @@ var QWeb = core.qweb;
var _t = core._t;
var HEIGHT_OPEN = '400px';
-var HEIGHT_FOLDED = '28px';
+var HEIGHT_FOLDED = '34px';
return Widget.extend({
template: "mail.ChatWindow",
@@ -43,6 +43,7 @@ return Widget.extend({
this.status = this.options.status;
this.unread_msgs = unread_msgs || 0;
this.is_hidden = false;
+ this.isMobile = config.isMobile;
},
start: function () {
this.$input = this.$('.o_composer_text_field');
@@ -85,12 +86,13 @@ return Widget.extend({
status: this.status,
title: this.title,
unread_counter: this.unread_msgs,
+ widget: this,
}));
},
fold: function () {
this.$el.animate({
height: this.folded ? HEIGHT_FOLDED : HEIGHT_OPEN
- });
+ }, 200);
},
toggle_fold: function (fold) {
this.folded = _.isBoolean(fold) ? fold : !this.folded;