-
Notifications
You must be signed in to change notification settings - Fork 42
(Widget) Notifications
github-actions edited this page Jan 31, 2025
·
1 revision
Option | Type | Default | Description |
---|---|---|---|
label |
string | "{count} new notifications" |
The format string for the notifications widget. |
label_alt |
string | "{count} new notifications"' |
The alternative format string for the notifications widget. |
tooltip |
boolean | True |
Whether to show the tooltip on hover. |
hide_empty |
boolean | False |
Whether to hide the widget when there are no notifications. |
callbacks |
dict | {'on_left': 'toggle_label', 'on_middle': 'do_nothing', 'on_right': 'do_nothing'} |
Callbacks for mouse events on the memory widget. |
container_padding |
dict | {'top': 0, 'left': 0, 'bottom': 0, 'right': 0} |
Explicitly set padding inside widget container. |
animation |
dict | {'enabled': True, 'type': 'fadeInOut', 'duration': 200} |
Animation settings for the widget. |
container_padding |
dict | {'top': 0, 'left': 0, 'bottom': 0, 'right': 0} |
Explicitly set padding inside widget container. |
notifications:
type: "yasb.notifications.NotificationsWidget"
options:
label: "<span>\uf476</span> {count}"
label_alt: "{count} notifications"
hide_empty: true
tooltip: false
callbacks:
on_left: "toggle_notification"
on_right: "do_nothing"
on_middle: "toggle_label"
container_padding:
top: 0
left: 8
bottom: 0
right: 8
-
label: The format string for the notifications widget. The string can contain the
{count}
placeholder which will be replaced with the number of notifications. -
label_alt: The alternative format string for the notifications widget. The string can contain the
{count}
placeholder which will be replaced with the number of notifications. - tooltip: Whether to show the tooltip on hover.
- hide_empty: Whether to hide the widget when there are no notifications.
-
callbacks: Callbacks for mouse events on the memory widget. The following callbacks are available:
-
on_left
: Callback for left-click event. -
on_middle
: Callback for middle-click event. -
on_right
: Callback for right-click event.
-
- container_padding: Explicitly set padding inside widget container. The padding can be set for each side of the container.
-
animation: A dictionary specifying the animation settings for the widget. It contains three keys:
enabled
,type
, andduration
. Thetype
can befadeInOut
and theduration
is the animation duration in milliseconds.
.notification-widget {
padding: 0 0px 0 4px;
}
.notification-widget .widget-container {
background-color:rgba(17, 17, 27, 0.75);
margin: 3px 0 3px 0;
border-radius: 12px;
border: 1px solid #45475a;
}
.notification-widget .icon {
font-size: 12px;
}
.notification-widget .icon.new-notification {
color: #89b4fa;
}
.notification-widget .label.new-notification {
color: #89b4fa;
}
- Home
- Installation
- Configuration
- Styling
- YASB CLI
- FAQ
- Widgets:
- Active Windows Title
- Applications
- Battery
- Bluetooth
- Brightness
- CPU
- Clock
- Custom
- Github
- GlazeWM Workspaces
- GlazeWM Tiling Direction
- Home
- Disk
- Language
- Libre Hardware Monitor
- Media
- Memory
- Microphone
- Notifications
- OBS
- Server Monitor
- Traffic
- Taskbar
- Power Menu
- Update Check
- Volume
- Wallpapers
- Weather
- WiFi
- WHKD
- Windows-Desktops
- Komorebi Workspaces
- Komorebi Layout
- Writing Widget