From 03bdfdb340772cb764159d09ff77b0977d52a066 Mon Sep 17 00:00:00 2001 From: Ly-sec Date: Tue, 16 Sep 2025 15:25:46 +0200 Subject: [PATCH] Notification: replace unread badge with small circle --- Modules/Bar/Widgets/NotificationHistory.qml | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/Modules/Bar/Widgets/NotificationHistory.qml b/Modules/Bar/Widgets/NotificationHistory.qml index edbe211..2446312 100644 --- a/Modules/Bar/Widgets/NotificationHistory.qml +++ b/Modules/Bar/Widgets/NotificationHistory.qml @@ -69,29 +69,20 @@ NIconButton { Loader { anchors.right: parent.right anchors.top: parent.top - anchors.rightMargin: -4 * scaling - anchors.topMargin: -4 * scaling + anchors.rightMargin: 2 * scaling + anchors.topMargin: 1 * scaling z: 2 active: showUnreadBadge && (!hideWhenZero || computeUnreadCount() > 0) sourceComponent: Rectangle { id: badge readonly property int count: computeUnreadCount() - readonly property string label: count <= 99 ? String(count) : "99+" - readonly property real pad: 8 * scaling - height: 16 * scaling - width: Math.max(height, textNode.implicitWidth + pad) + height: 8 * scaling + width: height radius: height / 2 color: Color.mError border.color: Color.mSurface border.width: 1 visible: count > 0 || !hideWhenZero - NText { - id: textNode - anchors.centerIn: parent - text: badge.label - font.pointSize: Style.fontSizeXXS * scaling - color: Color.mOnError - } } } }