diff --git a/addons/mail/static/src/core/message_model.js b/addons/mail/static/src/core/message_model.js index 287db295303..8183f873e20 100644 --- a/addons/mail/static/src/core/message_model.js +++ b/addons/mail/static/src/core/message_model.js @@ -118,10 +118,6 @@ export class Message { return this.datetime.toLocaleString(DateTime.DATETIME_SHORT); } - get isAutomatedMessage() { - return this.type === "auto_comment"; - } - get isSelfMentioned() { return this.recipients.some((recipient) => recipient === this._store.self); } diff --git a/addons/mail/static/src/core_ui/message.js b/addons/mail/static/src/core_ui/message.js index fe360529f6b..82d82a87828 100644 --- a/addons/mail/static/src/core_ui/message.js +++ b/addons/mail/static/src/core_ui/message.js @@ -459,8 +459,12 @@ export class Message extends Component { this.state.isEditing = false; } - onClickNotificationIcon(ev) { - this.popover.open(ev.target, { message: this.message }); + onClickNotification(ev) { + if (this.message.failureNotifications.length > 0) { + this.onClickFailure(ev); + } else { + this.popover.open(ev.target, { message: this.message }); + } } onClickFailure(ev) { diff --git a/addons/mail/static/src/core_ui/message.xml b/addons/mail/static/src/core_ui/message.xml index a81d71b6644..effc93503bd 100644 --- a/addons/mail/static/src/core_ui/message.xml +++ b/addons/mail/static/src/core_ui/message.xml @@ -73,76 +73,65 @@
- - - - +
-
-
+
- + +
+ 'border': state.isEditing, + 'bg-info-light border border-info opacity-25': !message.isSelfAuthored and !message.isNote, + 'bg-success-light border border-success opacity-25': message.isSelfAuthored and !message.isNote, + }" t-attf-class="{{ isAlignedRight ? 'rounded-start-3' : 'rounded-end-3' }}"/>
- Subject: - - (edited) - + + + Subject: + + (edited) + +
-
-
-
-
- -
-
-
diff --git a/addons/mail/static/src/core_ui/message_reactions.xml b/addons/mail/static/src/core_ui/message_reactions.xml index 261a09a3f83..924a72d4610 100644 --- a/addons/mail/static/src/core_ui/message_reactions.xml +++ b/addons/mail/static/src/core_ui/message_reactions.xml @@ -4,9 +4,9 @@
+ t-attf-class="{{ props.message.isDiscussion ? 'mt-n2' : 'mt-1' }}">