From 93f602adf2211d1925bde3255f404b8ee0719a8f Mon Sep 17 00:00:00 2001 From: Jonathan Rainville Date: Fri, 16 Jul 2021 11:06:52 -0400 Subject: [PATCH] fix(delete): fix delete button color and typo in warning --- ui/app/AppLayouts/Chat/components/MessageContextMenu.qml | 8 +++++++- ui/shared/PopupMenu.qml | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml b/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml index b66a74cf6f..7ac3b98261 100644 --- a/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml +++ b/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml @@ -278,6 +278,11 @@ PopupMenu { enabled: !isSticker && !emojiOnly } + Separator { + visible: deleteMessageAction.enabled + height: visible ? Style.current.halfPadding : 0 + } + Action { text: qsTr("Jump to") onTriggered: { @@ -301,7 +306,7 @@ PopupMenu { let confirmationDialog = openPopup(genericConfirmationDialog, { title: qsTr("Confirm deleting this message"), - confirmationText: qsTr("Are you sure you want to delete this message? Be aware that other clients are not garanteed to delete the message as well."), + confirmationText: qsTr("Are you sure you want to delete this message? Be aware that other clients are not guaranteed to delete the message as well."), height: 260, "checkbox.visible": true, executeConfirm: function () { @@ -315,6 +320,7 @@ PopupMenu { }) } icon.source: "../../../img/delete.svg" + icon.color: Style.current.danger icon.width: 16 icon.height: 16 enabled: isCurrentUser diff --git a/ui/shared/PopupMenu.qml b/ui/shared/PopupMenu.qml index c74b2dcebb..0b653938bd 100644 --- a/ui/shared/PopupMenu.qml +++ b/ui/shared/PopupMenu.qml @@ -16,7 +16,7 @@ Menu { delegate: MenuItem { property color textColor: this.action.icon.color.toString() !== "#00000000" ? this.action.icon.color : Style.current.textColor - property color hoverColor: this.action.type === "danger" ? Style.current.buttonWarnBackgroundColor : Style.current.backgroundHover + property color hoverColor: popupMenuItem.action.icon.color === Style.current.danger ? Style.current.buttonWarnBackgroundColor : Style.current.backgroundHover property int subMenuIndex: { if (!this.subMenu) { return -1