Fix popover: show all accounts with per-row bars and a dark window
The native tooltip never rendered. Two waybar quirks stacked: 1. custom/ocd had tooltip-format set. For a custom module with return-type json, a tooltip-format overrides the JSON tooltip field and waybar falls back to the label text (Waybar #3022). So the popover showed the single rotating account label instead of all accounts. Remove tooltip-format; waybar now uses the daemon's JSON tooltip field. 2. The daemon joined tooltip lines with newline. waybar custom modules break on newline (the tooltip vanishes; Waybar #3153). The wiki says to use carriage return instead. Switch the separator to \r. Reformat the tooltip so each limit (5h/1w/1m) is on its own row under the account, with a blank row between accounts for a bigger gap, as requested. Add a dark tooltip background. waybar scopes tooltip CSS globally (wiki / PR #4930): style all bar tooltips with the existing theme dark color @background/@foreground so the popover matches the bar instead of rendering backgroundless.
This commit is contained in:
1 parent
c4647dda6b
commit
09668a7c9a
3 files changed
+47
-8
No files matched your search
@@ -21,7 +21,9 @@
|
||||
"return-type": "json",
|
||||
"interval": 1,
|
||||
"format": "{}",
|
||||
"tooltip-format": "{}",
|
||||
// No "tooltip-format": waybar uses the JSON "tooltip" field written by
|
||||
// the daemon. Setting tooltip-format here overrides it and falls back to
|
||||
// the label text (Waybar issue #3022).
|
||||
"on-click": "~/.config/waybar/scripts/ocd-waybar-ctl advance",
|
||||
"on-click-right": "~/.config/waybar/scripts/ocd-waybar-ctl lock"
|
||||
},
|
||||
@@ -9,4 +9,19 @@
|
||||
}
|
||||
#custom-ocd.ocd-locked {
|
||||
color: #5aa6e0;
|
||||
}
|
||||
|
||||
/* Dark popover background for the ocd tooltip window.
|
||||
Waybar scopes tooltip styles globally: this rule applies to every
|
||||
tooltip in the bar, not just ours (Waybar wiki / PR #4930). It uses
|
||||
@background / @foreground, the same dark theme color the rest of
|
||||
the bar already uses (imported by omarchy's theme file), so the
|
||||
change matches the bar instead of introducing a new color.
|
||||
Also make the tooltip font monospace so the block-char bars line up. */
|
||||
tooltip {
|
||||
background-color: @background;
|
||||
color: @foreground;
|
||||
padding: 6px 8px;
|
||||
border-radius: 6px;
|
||||
font-family: monospace;
|
||||
}
|
||||
Reference in new issue
Block a user