diff --git a/ui/app/AppLayouts/Chat/components/PrivateChatPopup.qml b/ui/app/AppLayouts/Chat/components/PrivateChatPopup.qml index dba5763b8a..86aef8681d 100644 --- a/ui/app/AppLayouts/Chat/components/PrivateChatPopup.qml +++ b/ui/app/AppLayouts/Chat/components/PrivateChatPopup.qml @@ -29,6 +29,7 @@ ModalPopup { id: contactFieldAndList anchors.top: parent.top anchors.bottom: parent.bottom + addContactEnabled: false onUserClicked: function (isContact, pubKey, ensName) { chatsModel.channelView.joinPrivateChat(pubKey, Utils.isChatKey(pubKey) ? "" : ensName); popup.close(); diff --git a/ui/shared/ContactsListAndSearch.qml b/ui/shared/ContactsListAndSearch.qml index 2a5f6e19f4..e1a7e73759 100644 --- a/ui/shared/ContactsListAndSearch.qml +++ b/ui/shared/ContactsListAndSearch.qml @@ -19,6 +19,7 @@ Item { signal userClicked(bool isContact, string pubKey, string ensName, string address) property var pubKeys: ([]) property bool hideCommunityMembers: false + property bool addContactEnabled: true id: root width: parent.width @@ -175,7 +176,7 @@ Item { hasExistingContacts: existingContacts.visible loading: false width: searchResultsWidth > 0 ? searchResultsWidth : parent.width - + addContactEnabled: root.addContactEnabled onResultClicked: { if (!validate()) { return diff --git a/ui/shared/SearchResults.qml b/ui/shared/SearchResults.qml index e89651f2ac..685104cb49 100644 --- a/ui/shared/SearchResults.qml +++ b/ui/shared/SearchResults.qml @@ -19,6 +19,7 @@ Item { property string pubKey: "" property string address: "" property bool resultClickable: true + property bool addContactEnabled: true property bool isAddedContact: pubKey != "" ? chatsModel.messageView.isAddedContact(pubKey) : false @@ -120,7 +121,7 @@ Item { anchors.right: parent.right anchors.rightMargin: Style.current.padding anchors.verticalCenter: parent.verticalCenter - visible: !isAddedContact && !checkIcon.visible + visible: addContactEnabled && !isAddedContact && !checkIcon.visible MouseArea { anchors.fill: parent hoverEnabled: true