Improve the handling of switching link preivews on and off.
First make sure that the global setting is tied into the room setting, previously it was a bit of a patchwork that worked more by luck than judgement. The two levels of global and room level are properly tied together in a hierarchy. Add a message in the room when global notifcations re turned off. This has caused confusion in the past when people don't realise there are 2 levels.
This commit is contained in:
@@ -267,6 +267,7 @@ FormCard.FormCardPage {
|
||||
}
|
||||
}
|
||||
FormCard.FormCheckDelegate {
|
||||
enabled: root.connection.globalUrlPreviewEnabled
|
||||
text: i18n("Enable URL previews")
|
||||
// Most users won't see the above setting so tell them the default.
|
||||
description: room.defaultUrlPreviewState ? i18n("URL previews are enabled by default in this room") : i18n("URL previews are disabled by default in this room")
|
||||
@@ -276,6 +277,19 @@ FormCard.FormCardPage {
|
||||
}
|
||||
}
|
||||
}
|
||||
Kirigami.InlineMessage {
|
||||
Layout.fillWidth: true
|
||||
Layout.maximumWidth: Kirigami.Units.gridUnit * 30
|
||||
Layout.topMargin: Kirigami.Units.largeSpacing
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
text: i18nc("As in the user has switched off showing previews of hyperlinks in timeline messages", "URL previews are currently disabled for your account")
|
||||
type: Kirigami.MessageType.Information
|
||||
visible: !root.connection.globalUrlPreviewEnabled
|
||||
actions: Kirigami.Action {
|
||||
text: i18n("Enable")
|
||||
onTriggered: root.connection.globalUrlPreviewEnabled = true
|
||||
}
|
||||
}
|
||||
FormCard.FormHeader {
|
||||
title: i18n("Official Parent Spaces")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user