2022-05-26 15:46:02 +00:00
|
|
|
import QtQuick 2.14
|
|
|
|
import QtQuick.Layouts 1.14
|
|
|
|
|
|
|
|
import StatusQ.Core 0.1
|
|
|
|
import StatusQ.Core.Theme 0.1
|
|
|
|
import StatusQ.Components 0.1
|
|
|
|
import StatusQ.Controls 0.1
|
|
|
|
|
|
|
|
ColumnLayout {
|
|
|
|
id: root
|
|
|
|
|
|
|
|
property alias archiveSupportOptionVisible: archiveSupport.visible
|
|
|
|
|
|
|
|
property alias archiveSupportEnabled: archiveSupportToggle.checked
|
|
|
|
property alias requestToJoinEnabled: requestToJoinToggle.checked
|
|
|
|
property alias pinMessagesEnabled: pinMessagesToggle.checked
|
2022-10-07 16:33:23 +00:00
|
|
|
property alias encrypted: encryptedToggle.checked
|
|
|
|
|
|
|
|
property bool encryptReadOnly: false
|
2022-05-26 15:46:02 +00:00
|
|
|
|
|
|
|
spacing: 0
|
|
|
|
|
|
|
|
QtObject {
|
|
|
|
id: d
|
2022-08-03 00:07:27 +00:00
|
|
|
readonly property int optionHeight: 64
|
2022-05-26 15:46:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
RowLayout {
|
|
|
|
id: archiveSupport
|
|
|
|
|
|
|
|
Layout.fillWidth: true
|
2022-08-03 00:07:27 +00:00
|
|
|
Layout.preferredHeight: d.optionHeight
|
2022-05-26 15:46:02 +00:00
|
|
|
|
|
|
|
StatusBaseText {
|
|
|
|
Layout.fillWidth: true
|
2022-08-03 00:07:27 +00:00
|
|
|
text: qsTr("Community history service")
|
|
|
|
TapHandler {
|
|
|
|
onTapped: archiveSupportToggle.toggle()
|
|
|
|
}
|
2022-05-26 15:46:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
StatusCheckBox {
|
|
|
|
id: archiveSupportToggle
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
RowLayout {
|
|
|
|
Layout.fillWidth: true
|
2022-08-03 00:07:27 +00:00
|
|
|
Layout.preferredHeight: d.optionHeight
|
2022-05-26 15:46:02 +00:00
|
|
|
|
|
|
|
StatusBaseText {
|
|
|
|
Layout.fillWidth: true
|
2022-08-03 00:07:27 +00:00
|
|
|
text: qsTr("Request to join required")
|
|
|
|
TapHandler {
|
|
|
|
onTapped: requestToJoinToggle.toggle()
|
|
|
|
}
|
2022-05-26 15:46:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
StatusCheckBox {
|
|
|
|
id: requestToJoinToggle
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
RowLayout {
|
|
|
|
Layout.fillWidth: true
|
2022-08-03 00:07:27 +00:00
|
|
|
Layout.preferredHeight: d.optionHeight
|
2022-05-26 15:46:02 +00:00
|
|
|
|
|
|
|
StatusBaseText {
|
|
|
|
Layout.fillWidth: true
|
2022-08-03 00:07:27 +00:00
|
|
|
text: qsTr("Any member can pin a message")
|
|
|
|
TapHandler {
|
|
|
|
onTapped: pinMessagesToggle.toggle()
|
|
|
|
}
|
2022-05-26 15:46:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
StatusCheckBox {
|
|
|
|
id: pinMessagesToggle
|
|
|
|
}
|
|
|
|
}
|
2022-10-07 16:33:23 +00:00
|
|
|
|
|
|
|
RowLayout {
|
|
|
|
Layout.fillWidth: true
|
|
|
|
Layout.preferredHeight: d.optionHeight
|
|
|
|
visible: requestToJoinToggle.checked
|
|
|
|
|
|
|
|
StatusBaseText {
|
|
|
|
Layout.fillWidth: true
|
|
|
|
text: qsTr("Encrypted")
|
|
|
|
TapHandler {
|
|
|
|
enabled: !encryptReadOnly
|
|
|
|
onTapped: encryptedToggle.toggle()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
StatusCheckBox {
|
|
|
|
id: encryptedToggle
|
|
|
|
enabled: !encryptReadOnly
|
|
|
|
}
|
|
|
|
}
|
2022-05-26 15:46:02 +00:00
|
|
|
}
|