2021-04-20 12:31:36 +00:00
|
|
|
import QtQuick 2.12
|
|
|
|
import QtQuick.Controls 2.12
|
|
|
|
import QtQuick.Dialogs 1.3
|
|
|
|
import QtQuick.Layouts 1.13
|
|
|
|
import QtGraphicalEffects 1.13
|
2021-09-28 15:04:06 +00:00
|
|
|
|
|
|
|
import utils 1.0
|
2021-10-27 21:27:49 +00:00
|
|
|
import shared.controls 1.0
|
|
|
|
import shared 1.0
|
|
|
|
import shared.panels 1.0
|
|
|
|
import shared.status 1.0
|
2021-07-15 11:15:56 +00:00
|
|
|
import StatusQ.Components 0.1
|
|
|
|
import StatusQ.Popups 0.1
|
|
|
|
|
|
|
|
Column {
|
2021-04-20 12:31:36 +00:00
|
|
|
id: root
|
|
|
|
|
|
|
|
property string headerTitle: ""
|
|
|
|
|
2022-01-10 16:44:54 +00:00
|
|
|
property var rootStore
|
|
|
|
property var contactsStore
|
2021-07-16 12:36:27 +00:00
|
|
|
property var community
|
2021-04-20 12:31:36 +00:00
|
|
|
property alias contactListSearch: contactFieldAndList
|
|
|
|
|
2021-07-15 11:15:56 +00:00
|
|
|
StatusDescriptionListItem {
|
2022-04-04 11:26:30 +00:00
|
|
|
title: qsTr("Share community")
|
2021-07-21 09:49:03 +00:00
|
|
|
subTitle: `${Constants.communityLinkPrefix}${root.community && root.community.id.substring(0, 4)}...${root.community && root.community.id.substring(root.community.id.length -2)}`
|
2022-03-07 11:35:30 +00:00
|
|
|
tooltip.text: qsTr("Copied!")
|
2021-07-15 11:15:56 +00:00
|
|
|
icon.name: "copy"
|
|
|
|
iconButton.onClicked: {
|
2022-01-10 16:44:54 +00:00
|
|
|
let link = `${Constants.communityLinkPrefix}${root.community.id}`
|
|
|
|
root.rootStore.copyToClipboard(link)
|
|
|
|
tooltip.visible = !tooltip.visible
|
2021-07-15 11:15:56 +00:00
|
|
|
}
|
|
|
|
width: parent.width
|
|
|
|
}
|
|
|
|
|
|
|
|
StatusModalDivider {
|
2021-08-04 12:34:06 +00:00
|
|
|
bottomPadding: Style.current.padding
|
|
|
|
}
|
|
|
|
|
|
|
|
StyledText {
|
|
|
|
id: headline
|
|
|
|
text: qsTr("Contacts")
|
|
|
|
font.pixelSize: Style.current.primaryTextFontSize
|
|
|
|
color: Style.current.secondaryText
|
|
|
|
anchors.left: parent.left
|
|
|
|
anchors.leftMargin: Style.current.padding
|
2021-04-20 12:31:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
ContactsListAndSearch {
|
|
|
|
id: contactFieldAndList
|
2021-07-15 11:15:56 +00:00
|
|
|
anchors.horizontalCenter: parent.horizontalCenter
|
|
|
|
width: parent.width - 32
|
2022-01-10 16:44:54 +00:00
|
|
|
contactsStore: root.contactsStore
|
|
|
|
community: root.community
|
2021-04-20 12:31:36 +00:00
|
|
|
showCheckbox: true
|
2021-05-17 09:56:55 +00:00
|
|
|
hideCommunityMembers: true
|
2021-08-04 12:34:06 +00:00
|
|
|
showSearch: false
|
2022-01-28 08:19:49 +00:00
|
|
|
rootStore: root.rootStore
|
2021-04-20 12:31:36 +00:00
|
|
|
}
|
|
|
|
}
|