From 9849a13999053004a5ac96e8ff21fc032a6f422a Mon Sep 17 00:00:00 2001 From: Markus Date: Fri, 28 Jul 2023 14:35:43 +0200 Subject: [PATCH 1/2] [fix] @ mentions in chat now redirect to user page --- webapp/components/Chat/Chat.vue | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/webapp/components/Chat/Chat.vue b/webapp/components/Chat/Chat.vue index c2e767272..348527a3c 100644 --- a/webapp/components/Chat/Chat.vue +++ b/webapp/components/Chat/Chat.vue @@ -27,6 +27,7 @@ @fetch-more-rooms="fetchRooms" @add-room="toggleUserSearch" @show-demo-options="showDemoOptions = $event" + @open-user-tag="redirectToUserProfile($event.detail[0])" >
From f1fc2e07f700f47d340231f66a3c5e9628e41af2 Mon Sep 17 00:00:00 2001 From: Markus Date: Fri, 28 Jul 2023 14:36:32 +0200 Subject: [PATCH 2/2] fixed linting --- webapp/components/Chat/Chat.vue | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/webapp/components/Chat/Chat.vue b/webapp/components/Chat/Chat.vue index 348527a3c..eb0ce4433 100644 --- a/webapp/components/Chat/Chat.vue +++ b/webapp/components/Chat/Chat.vue @@ -449,12 +449,12 @@ export default { }) }, - redirectToUserProfile({user}){ - let userID = user.id - let userName = user.name.toLowerCase().replaceAll(" ", "-") - let url = `/profile/${userID}/${userName}` - this.$router.push({ path: url }); - } + redirectToUserProfile({ user }) { + const userID = user.id + const userName = user.name.toLowerCase().replaceAll(' ', '-') + const url = `/profile/${userID}/${userName}` + this.$router.push({ path: url }) + }, }, }