From af3afa6a143a73412daac15e350e1d3f6a7b08d0 Mon Sep 17 00:00:00 2001 From: Damocles Date: Fri, 17 Apr 2026 10:02:02 +0200 Subject: [PATCH 1/4] devshell: add libnotify --- flake.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/flake.nix b/flake.nix index c33a922..4bdd245 100644 --- a/flake.nix +++ b/flake.nix @@ -81,6 +81,7 @@ rust-analyzer clippy rustfmt + libnotify ]; }; } From dd88b8a4c205388802a7659791ab3e8fffb17d8c Mon Sep 17 00:00:00 2001 From: Damocles Date: Fri, 17 Apr 2026 10:04:12 +0200 Subject: [PATCH 2/4] notifcenter: fix undefined->bool warning on actions visible binding --- modules/NotifCenter.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/NotifCenter.qml b/modules/NotifCenter.qml index 7c3f2f8..a6bde51 100644 --- a/modules/NotifCenter.qml +++ b/modules/NotifCenter.qml @@ -437,7 +437,7 @@ M.HoverPanel { // Actions Row { spacing: 4 - visible: notifDelegate._notif?.actions && notifDelegate._notif.actions.length > 0 + visible: !!(notifDelegate._notif?.actions?.length) Repeater { model: notifDelegate._notif?.actions ?? [] From b31fab5148fb3dad0fd10ed084b26d435e05dccf Mon Sep 17 00:00:00 2001 From: Damocles Date: Fri, 17 Apr 2026 10:05:17 +0200 Subject: [PATCH 3/4] notifs: handle file:// urls in appIcon source --- modules/NotifCenter.qml | 4 ++-- modules/NotifPopup.qml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/NotifCenter.qml b/modules/NotifCenter.qml index a6bde51..0bc8549 100644 --- a/modules/NotifCenter.qml +++ b/modules/NotifCenter.qml @@ -271,7 +271,7 @@ M.HoverPanel { const ic = notifDelegate.modelData.appIcon; if (!ic) return ""; - return ic.startsWith("/") ? ic : Quickshell.iconPath(ic, "dialog-information"); + return (ic.startsWith("/") || ic.startsWith("file://")) ? ic : Quickshell.iconPath(ic, "dialog-information"); } visible: status === Image.Ready fillMode: Image.PreserveAspectFit @@ -382,7 +382,7 @@ M.HoverPanel { const ic = notifDelegate._notif?.appIcon; if (!ic) return ""; - return ic.startsWith("/") ? ic : Quickshell.iconPath(ic, "dialog-information"); + return (ic.startsWith("/") || ic.startsWith("file://")) ? ic : Quickshell.iconPath(ic, "dialog-information"); } visible: status === Image.Ready fillMode: Image.PreserveAspectFit diff --git a/modules/NotifPopup.qml b/modules/NotifPopup.qml index e6d33bf..493975b 100644 --- a/modules/NotifPopup.qml +++ b/modules/NotifPopup.qml @@ -168,7 +168,7 @@ PanelWindow { const ic = popupItem.modelData.appIcon; if (!ic) return ""; - return ic.startsWith("/") ? ic : Quickshell.iconPath(ic, "dialog-information"); + return (ic.startsWith("/") || ic.startsWith("file://")) ? ic : Quickshell.iconPath(ic, "dialog-information"); } visible: status === Image.Ready fillMode: Image.PreserveAspectFit From d6b1a7ae581f814346a3b0dcdfb496a439841a79 Mon Sep 17 00:00:00 2001 From: Damocles Date: Fri, 17 Apr 2026 10:06:47 +0200 Subject: [PATCH 4/4] notifications: show ! suffix and red color on count when critical notifications present --- modules/Notifications.qml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/modules/Notifications.qml b/modules/Notifications.qml index c4abc02..a21a972 100644 --- a/modules/Notifications.qml +++ b/modules/Notifications.qml @@ -1,5 +1,6 @@ import QtQuick import Quickshell +import Quickshell.Services.Notifications import "." as M M.BarSection { @@ -14,6 +15,8 @@ M.BarSection { required property var bar + readonly property bool hasUrgent: M.NotifService.list.some(n => n.urgency === NotificationUrgency.Critical && n.state !== "dismissed") + M.BarIcon { icon: { if (M.NotifService.dnd) @@ -25,7 +28,8 @@ M.BarSection { } M.BarLabel { id: countLabel - label: M.NotifService.count > 0 ? String(M.NotifService.count) : "" + label: M.NotifService.count > 0 ? String(M.NotifService.count) + (root.hasUrgent ? "!" : "") : "" + color: root.hasUrgent ? M.Theme.base08 : root.accentColor anchors.verticalCenter: parent.verticalCenter transform: Scale {