From a8021bdf632510d5c52ad048e6a660901d7e73f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 1 Jun 2021 12:04:01 +0200 Subject: [PATCH] MOBILE-3320 messages: Fix undefined on discussion 3.4 --- .../messages/pages/discussion/discussion.html | 14 +++++++++----- .../messages/pages/discussion/discussion.page.ts | 1 + .../messages/pages/discussions-35/discussions.html | 2 +- src/theme/theme.base.scss | 2 ++ 4 files changed, 13 insertions(+), 6 deletions(-) diff --git a/src/addons/messages/pages/discussion/discussion.html b/src/addons/messages/pages/discussion/discussion.html index 55faa023b..6ff35dea0 100644 --- a/src/addons/messages/pages/discussion/discussion.html +++ b/src/addons/messages/pages/discussion/discussion.html @@ -92,12 +92,16 @@ [@coreSlideInOut]="message.useridfrom == currentUserId ? '' : 'fromLeft'"> -
+
- -
{{ members[message.useridfrom].fullname }}
+ aria-hidden="true"> + + {{ members[message.useridfrom].fullname }} +
+
+ {{ message.useridfrom == currentUserId + ? ('addon.messages.you' | translate) + : members[message.useridfrom].fullname }}
diff --git a/src/addons/messages/pages/discussion/discussion.page.ts b/src/addons/messages/pages/discussion/discussion.page.ts index a9531d9b0..b107bfd10 100644 --- a/src/addons/messages/pages/discussion/discussion.page.ts +++ b/src/addons/messages/pages/discussion/discussion.page.ts @@ -250,6 +250,7 @@ export class AddonMessagesDiscussionPage implements OnInit, OnDestroy, AfterView this.title = user.fullname; } this.conversationImage = user.profileimageurl; + this.members[user.id] = user; return; }).catch(() => { diff --git a/src/addons/messages/pages/discussions-35/discussions.html b/src/addons/messages/pages/discussions-35/discussions.html index 36e69fa31..b32c97873 100644 --- a/src/addons/messages/pages/discussions-35/discussions.html +++ b/src/addons/messages/pages/discussions-35/discussions.html @@ -19,7 +19,7 @@ + [disabled]="!loaded" searchArea="AddonMessagesDiscussions" [autoFocus]="false"> diff --git a/src/theme/theme.base.scss b/src/theme/theme.base.scss index 1640b53e4..d110bb84a 100644 --- a/src/theme/theme.base.scss +++ b/src/theme/theme.base.scss @@ -185,6 +185,8 @@ ion-header ion-toolbar { // Ionic icon. ion-icon { + position: relative; + &.icon-slash::after, &.icon-backslash::after { content: " ";