notifcard: filter default action identifier and empty action labels

This commit is contained in:
Damocles 2026-04-17 10:50:46 +02:00
parent 5e9a8b0a44
commit 2e3f3a9f3c

View file

@ -198,13 +198,14 @@ Item {
visible: text !== "" visible: text !== ""
} }
// Action buttons // Action buttons filter "default" (click-notification convention) and empty labels
Row { Row {
spacing: 6 spacing: 6
visible: !!(root.notif?.actions?.length) visible: _actionRepeater.count > 0
Repeater { Repeater {
model: root.notif?.actions ?? [] id: _actionRepeater
model: (root.notif?.actions ?? []).filter(a => a.text && a.identifier !== "default")
delegate: Rectangle { delegate: Rectangle {
required property var modelData required property var modelData
width: _actText.implicitWidth + 12 width: _actText.implicitWidth + 12