From 15a1646d4a9e4d14f6303cbc793871daba6fd855 Mon Sep 17 00:00:00 2001 From: Khushboo Mehta Date: Fri, 17 Sep 2021 17:08:16 +0200 Subject: [PATCH] fix(@desktop/profile): Blocked contacts counter doesn't show actual number fixes #3421 --- .../Profile/Sections/ContactsContainer.qml | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/ui/app/AppLayouts/Profile/Sections/ContactsContainer.qml b/ui/app/AppLayouts/Profile/Sections/ContactsContainer.qml index eb6d9e27f6..8c01abd80f 100644 --- a/ui/app/AppLayouts/Profile/Sections/ContactsContainer.qml +++ b/ui/app/AppLayouts/Profile/Sections/ContactsContainer.qml @@ -69,9 +69,9 @@ Item { id: blockedContactsButton anchors.top: addNewContact.bottom anchors.topMargin: Style.current.bigPadding - width: blockButton.width + blockButtonLabel.width + Style.current.padding + width: parent.width visible: profileModel.contacts.blockedContacts.rowCount() > 0 - height: addButton.height + height: 64 StatusRoundButton { id: blockButton @@ -93,6 +93,16 @@ Item { font.pixelSize: 15 } + StyledText { + id: numberOfBlockedContacts + text: profileModel.contacts.blockedContacts.rowCount() + color: Style.current.darkGrey + anchors.right: parent.right + anchors.rightMargin: Style.current.padding + anchors.verticalCenter: blockButton.verticalCenter + font.pixelSize: 15 + } + MouseArea { anchors.fill: parent cursorShape: Qt.PointingHandCursor @@ -213,7 +223,7 @@ Item { ContactList { id: contactListView - anchors.top: blockedContactsButton.bottom + anchors.top: blockedContactsButton.visible ? blockedContactsButton.bottom : addNewContact.bottom anchors.topMargin: Style.current.bigPadding anchors.bottom: parent.bottom contacts: profileModel.contacts.addedContacts