From 20ecfd1033be96275d6c4f61368ab5709a1da3fa Mon Sep 17 00:00:00 2001 From: Bernhard Owen Josephus Date: Fri, 24 Mar 2023 08:33:58 -0700 Subject: [PATCH 1/2] change chat preview alternate text for DM and room --- src/languages/en.js | 1 + src/languages/es.js | 1 + src/libs/SidebarUtils.js | 4 ++-- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/languages/en.js b/src/languages/en.js index 765be98ed4dc..79f2f22cb7f7 100755 --- a/src/languages/en.js +++ b/src/languages/en.js @@ -1167,6 +1167,7 @@ export default { }, report: { genericAddCommentFailureMessage: 'Unexpected error while posting the comment, please try again later', + roomNoChat: 'No activity yet', }, chronos: { oooEventSummaryFullDay: ({summary, dayCount, date}) => `${summary} for ${dayCount} ${dayCount === 1 ? 'day' : 'days'} until ${date}`, diff --git a/src/languages/es.js b/src/languages/es.js index f7012c3d6654..bb83f82b7521 100644 --- a/src/languages/es.js +++ b/src/languages/es.js @@ -1168,6 +1168,7 @@ export default { }, report: { genericAddCommentFailureMessage: 'Error inesperado al agregar el comentario, por favor inténtalo más tarde', + roomNoChat: 'Sin actividad todavía', }, chronos: { oooEventSummaryFullDay: ({summary, dayCount, date}) => `${summary} por ${dayCount} ${dayCount === 1 ? 'día' : 'días'} hasta el ${date}`, diff --git a/src/libs/SidebarUtils.js b/src/libs/SidebarUtils.js index 3e6fd500c98e..1815ec1b5d31 100644 --- a/src/libs/SidebarUtils.js +++ b/src/libs/SidebarUtils.js @@ -275,9 +275,9 @@ function getOptionData(reportID) { } if (result.isChatRoom || result.isPolicyExpenseChat) { - result.alternateText = lastMessageText || subtitle; + result.alternateText = lastMessageText || Localize.translate(preferredLocale, 'report.roomNoChat'); } else { - if (hasMultipleParticipants && !lastMessageText) { + if (!lastMessageText) { // Here we get the beginning of chat history message and append the display name for each user, adding pronouns if there are any. // We also add a fullstop after the final name, the word "and" before the final name and commas between all previous names. lastMessageText = Localize.translate(preferredLocale, 'reportActionsView.beginningOfChatHistory') From a7d5444def12e562ff1ced552f575fa3a5ab3ca9 Mon Sep 17 00:00:00 2001 From: Bernhard Owen Josephus Date: Fri, 24 Mar 2023 23:48:22 -0700 Subject: [PATCH 2/2] change chat preview alternate text for DM and room --- src/languages/en.js | 4 ++-- src/languages/es.js | 4 ++-- src/libs/SidebarUtils.js | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/languages/en.js b/src/languages/en.js index 79f2f22cb7f7..9861eb3b0f5a 100755 --- a/src/languages/en.js +++ b/src/languages/en.js @@ -244,7 +244,7 @@ export default { beginningOfChatHistoryAnnounceRoomPartTwo: ({workspaceName}) => ` to chat about anything ${workspaceName} related.`, beginningOfChatHistoryUserRoomPartOne: 'Collaboration starts here! 🎉\nUse this space to chat about anything ', beginningOfChatHistoryUserRoomPartTwo: ' related.', - beginningOfChatHistory: 'This is the beginning of your chat history with ', + beginningOfChatHistory: 'This is the beginning of your chat with ', beginningOfChatHistoryPolicyExpenseChatPartOne: 'Collaboration between ', beginningOfChatHistoryPolicyExpenseChatPartTwo: ' and ', beginningOfChatHistoryPolicyExpenseChatPartThree: ' starts here! 🎉 This is the place to chat, request money and settle up.', @@ -1167,7 +1167,7 @@ export default { }, report: { genericAddCommentFailureMessage: 'Unexpected error while posting the comment, please try again later', - roomNoChat: 'No activity yet', + noActivityYet: 'No activity yet', }, chronos: { oooEventSummaryFullDay: ({summary, dayCount, date}) => `${summary} for ${dayCount} ${dayCount === 1 ? 'day' : 'days'} until ${date}`, diff --git a/src/languages/es.js b/src/languages/es.js index bb83f82b7521..481608071def 100644 --- a/src/languages/es.js +++ b/src/languages/es.js @@ -243,7 +243,7 @@ export default { beginningOfChatHistoryAnnounceRoomPartTwo: ({workspaceName}) => ` para chatear sobre cualquier cosa relacionada con ${workspaceName}.`, beginningOfChatHistoryUserRoomPartOne: 'Este es el lugar para colaborar! 🎉\nUsa este espacio para chatear sobre cualquier cosa relacionada con ', beginningOfChatHistoryUserRoomPartTwo: '.', - beginningOfChatHistory: 'Aquí comienza tu historial de conversaciones con ', + beginningOfChatHistory: 'Aquí comienzan tus conversaciones con ', beginningOfChatHistoryPolicyExpenseChatPartOne: '¡La colaboración entre ', beginningOfChatHistoryPolicyExpenseChatPartTwo: ' y ', beginningOfChatHistoryPolicyExpenseChatPartThree: ' empieza aquí! 🎉 Este es el lugar donde chatear, pedir dinero y pagar.', @@ -1168,7 +1168,7 @@ export default { }, report: { genericAddCommentFailureMessage: 'Error inesperado al agregar el comentario, por favor inténtalo más tarde', - roomNoChat: 'Sin actividad todavía', + noActivityYet: 'Sin actividad todavía', }, chronos: { oooEventSummaryFullDay: ({summary, dayCount, date}) => `${summary} por ${dayCount} ${dayCount === 1 ? 'día' : 'días'} hasta el ${date}`, diff --git a/src/libs/SidebarUtils.js b/src/libs/SidebarUtils.js index 1815ec1b5d31..d333b194c355 100644 --- a/src/libs/SidebarUtils.js +++ b/src/libs/SidebarUtils.js @@ -275,7 +275,7 @@ function getOptionData(reportID) { } if (result.isChatRoom || result.isPolicyExpenseChat) { - result.alternateText = lastMessageText || Localize.translate(preferredLocale, 'report.roomNoChat'); + result.alternateText = lastMessageText || Localize.translate(preferredLocale, 'report.noActivityYet'); } else { if (!lastMessageText) { // Here we get the beginning of chat history message and append the display name for each user, adding pronouns if there are any.