From 73da21d1c6621b11a8b417a74428da98ce917cdb Mon Sep 17 00:00:00 2001 From: automated-signal <37887102+automated-signal@users.noreply.github.com> Date: Fri, 28 Jun 2024 11:56:53 -0500 Subject: [PATCH] Delete Sync: Show different text when deleting entire conversation Co-authored-by: Scott Nonnenberg --- _locales/en/messages.json | 4 ++++ ts/components/conversation/ConversationHeader.tsx | 12 +++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/_locales/en/messages.json b/_locales/en/messages.json index 4ba2c38cc4..08a2123e6a 100644 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -1318,6 +1318,10 @@ "messageformat": "All messages in this chat will be deleted from this device. You can still search for this chat after you delete messages.", "description": "Description for confirmation modal to delete all messages in a conversation" }, + "icu:ConversationHeader__DeleteMessagesInConversationConfirmation__description-with-sync": { + "messageformat": "All messages in this chat will be deleted from all your devices. You can still search for this chat after you delete messages.", + "description": "Description for confirmation modal to delete all messages in a conversation" + }, "icu:ConversationHeader__ContextMenu__LeaveGroupAction__title": { "messageformat": "Leave group", "description": "This is a button to leave a group" diff --git a/ts/components/conversation/ConversationHeader.tsx b/ts/components/conversation/ConversationHeader.tsx index 866cdff35c..5d905dcbb3 100644 --- a/ts/components/conversation/ConversationHeader.tsx +++ b/ts/components/conversation/ConversationHeader.tsx @@ -957,6 +957,14 @@ function DeleteMessagesConfirmationDialog({ ); } + const dialogBody = isDeleteSyncSendEnabled + ? i18n( + 'icu:ConversationHeader__DeleteMessagesInConversationConfirmation__description-with-sync' + ) + : i18n( + 'icu:ConversationHeader__DeleteMessagesInConversationConfirmation__description' + ); + return ( - {i18n( - 'icu:ConversationHeader__DeleteMessagesInConversationConfirmation__description' - )} + {dialogBody} ); }