mirror of
https://github.com/status-im/status-desktop.git
synced 2025-02-13 15:17:45 +00:00
- removed nested ListViews inside StackLayouts, in order to reduce the memory footprint and improve performance, and also to be able to better manage the scrolling - no more unrolled multiple listviews, which again hurt the performance; now the views instantiate the delegates dynamically on the fly - the tab bar and the search fields now stick to the top of the page, with the users list view scrolling independently - both views now uniformly use the common `ContactListItemDelegate` - the received/sent CRs are now combined into one `pendingContacts` model - factored out common search/filter criteria into a new, separate SFPM `UserFilterContainer` component - fix an issue where StatusContactVerificationIcons wasn't properly displaying the "blocked" state/icon - fix documentation comments, removed relative imports, and updated some Fixes #16612 Fixes #16958
47 lines
1.3 KiB
QML
47 lines
1.3 KiB
QML
import QtQuick 2.15
|
||
|
||
import StatusQ.Core 0.1
|
||
import StatusQ.Core.Theme 0.1
|
||
import StatusQ.Controls 0.1
|
||
|
||
import utils 1.0
|
||
import shared.popups 1.0
|
||
|
||
Item {
|
||
id: root
|
||
implicitWidth: 260
|
||
implicitHeight: visible ? 120 : 0
|
||
|
||
property string text: inviteButtonVisible ? qsTr("You don’t have any contacts yet. Invite your friends to start chatting.")
|
||
: qsTr("No users match your search")
|
||
property alias textColor: noContacts.color
|
||
property bool inviteButtonVisible: true
|
||
|
||
StatusBaseText {
|
||
id: noContacts
|
||
text: root.text
|
||
color: Theme.palette.baseColor1
|
||
anchors.top: parent.top
|
||
anchors.topMargin: Theme.padding
|
||
anchors.left: parent.left
|
||
anchors.right: parent.right
|
||
wrapMode: Text.WordWrap
|
||
horizontalAlignment: Text.AlignHCenter
|
||
}
|
||
StatusButton {
|
||
text: qsTr("Invite friends")
|
||
anchors.horizontalCenter: parent.horizontalCenter
|
||
anchors.top: noContacts.bottom
|
||
anchors.topMargin: Theme.padding
|
||
visible: root.inviteButtonVisible
|
||
onClicked: inviteFriendsPopup.createObject(root).open()
|
||
}
|
||
|
||
Component {
|
||
id: inviteFriendsPopup
|
||
InviteFriendsPopup {
|
||
destroyOnClose: true
|
||
}
|
||
}
|
||
}
|