From e5d7c4fef282041f7723ca1f99477688b1da46df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexandre=20K=C3=BChn?= Date: Mon, 22 Jan 2024 10:58:09 +0100 Subject: [PATCH] [FIX] mail: squashed message don't grow on mousehover MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Before this commit, when a message without bubble layout is squashed (e.g. with `/who` command twice in a channel), mouse-hovering on the squashed message pushed increased the height of the message. This happens because the sidebar of squashed message contains the date and it uses 12-hour format with AM/PM. This design requires cautious use of content in the sidebar, and had 24-hour format to make it work. A recent refactoring changed it to 12-hour format as localization was a better concern. However, the UI is not designed for it, and there's not much value in having 12-hour format rather than 24-hour format. Indeed, users assume AM if no AM/PM is shown, except if hour is greater than 12 which is quite obvious the current time. 12-hour format is best for some users, but we can't have it without overhauling parts of the UI which is not worth it at the time of this commit. Therefore using 24-hour format is the better tradeoff. Also took the opportunity of this PR to better align the date and seen indicator in squashed message sidebar. Task-3637270 closes odoo/odoo#150369 Signed-off-by: Sébastien Theys (seb) --- addons/mail/static/src/core/common/message.xml | 4 ++-- addons/mail/static/src/core/common/message_service.js | 4 ++-- addons/mail/static/tests/message/message_tests.js | 10 ++++++++-- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/addons/mail/static/src/core/common/message.xml b/addons/mail/static/src/core/common/message.xml index 45b3fbfa3e7..ade64face50 100644 --- a/addons/mail/static/src/core/common/message.xml +++ b/addons/mail/static/src/core/common/message.xml @@ -19,10 +19,10 @@ - + -
+