mirror of
https://github.com/rywng/dotfiles.git
synced 2024-11-24 11:51:50 +08:00
feat(waybar): better calendar
This commit is contained in:
parent
3415baa46e
commit
96281526f5
@ -54,6 +54,7 @@ window#waybar {
|
|||||||
|
|
||||||
#clock {
|
#clock {
|
||||||
color: @foreground;
|
color: @foreground;
|
||||||
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
#battery {
|
#battery {
|
||||||
|
@ -1,72 +1,97 @@
|
|||||||
{
|
{
|
||||||
"sway/workspaces": {
|
"sway/workspaces": {
|
||||||
"show_special": true,
|
"show_special": true,
|
||||||
"on-click": "activate"
|
"on-click": "activate"
|
||||||
},
|
},
|
||||||
"sway/window": {
|
"sway/window": {
|
||||||
"max-length": 50
|
"max-length": 50
|
||||||
},
|
},
|
||||||
"tray": {
|
"tray": {
|
||||||
"spacing": 10
|
"spacing": 10
|
||||||
},
|
},
|
||||||
"cpu": {
|
"cpu": {
|
||||||
"format": " {load}",
|
"format": " {load}",
|
||||||
"format-alt": " {usage}% @ {avg_frequency}GHz"
|
"format-alt": " {usage}% @ {avg_frequency}GHz"
|
||||||
},
|
},
|
||||||
"memory": {
|
"memory": {
|
||||||
"format": " {used:0.1f}G / {total:0.1f}G",
|
"format": " {used:0.1f} / {total:0.1f}G",
|
||||||
"format-alt": " Swap: {swapUsed:0.1f}G / {swapTotal:0.1f}G"
|
"format-alt": " Swap: {swapUsed:0.1f}G / {swapTotal:0.1f}G"
|
||||||
},
|
},
|
||||||
"network": {
|
"network": {
|
||||||
"format-wifi": " {essid} ({signalStrength}%)",
|
"format-wifi": " {essid} ({signalStrength}%)",
|
||||||
"format-ethernet": " {ifname}",
|
"format-ethernet": " {ifname}",
|
||||||
"format-linked": " {ifname}",
|
"format-linked": " {ifname}",
|
||||||
"format-disconnected": " Disconnected",
|
"format-disconnected": " Disconnected",
|
||||||
"format-alt": " {ifname}: {ipaddr}/{cidr}",
|
"format-alt": " {ifname}: {ipaddr}/{cidr}",
|
||||||
"tooltip-format": "{ifname} via {gwaddr}"
|
"tooltip-format": "{ifname} via {gwaddr}"
|
||||||
},
|
},
|
||||||
"battery": {
|
"battery": {
|
||||||
"states": {
|
"states": {
|
||||||
"good": 75,
|
"good": 75,
|
||||||
"warning": 15,
|
"warning": 15,
|
||||||
"critical": 5
|
"critical": 5
|
||||||
},
|
},
|
||||||
"format": "{icon} {capacity}%",
|
"format": "{icon} {capacity}%",
|
||||||
"format-charging": " {capacity}%",
|
"format-charging": " {capacity}%",
|
||||||
"format-plugged": " {capacity}%",
|
"format-plugged": " {capacity}%",
|
||||||
"format-alt": "{icon} ETA: {time}",
|
"format-alt": "{icon} ETA: {time}",
|
||||||
"format-icons": ["", "", "", "", ""]
|
"format-icons": [
|
||||||
},
|
"",
|
||||||
"clock": {
|
"",
|
||||||
"format": "{: %H:%M %m-%d}",
|
"",
|
||||||
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>"
|
"",
|
||||||
},
|
""
|
||||||
"custom/notification": {
|
]
|
||||||
"tooltip": true,
|
},
|
||||||
"format": "{icon}",
|
"clock": {
|
||||||
"format-icons": {
|
"format": "{: %H:%M}",
|
||||||
"notification": " <span foreground='red'><sup></sup></span> <span weight=\"bold\">Unread</span>",
|
"format-alt": "{: %m-%d}",
|
||||||
"none": " <span style=\"italic\">Empty</span>",
|
"tooltip-format": "<tt><small>{calendar}</small></tt>",
|
||||||
"dnd-notification": " <span style=\"italic\">DND on</span>",
|
"calendar": {
|
||||||
"dnd-none": " <span style=\"italic\">DND on</span>"
|
"mode": "year",
|
||||||
},
|
"mode-mon-col": 3,
|
||||||
"return-type": "json",
|
"on-scroll": 1,
|
||||||
"exec-if": "which swaync-client",
|
"on-click-right": "mode",
|
||||||
"exec": "swaync-client -swb",
|
"format": {
|
||||||
"on-click": "swaync-client -t -sw",
|
"months": "<span color='#98971a'><b>{}</b></span>",
|
||||||
"on-click-right": "swaync-client -d -sw",
|
"days": "<span color='#ebdbb2'><b>{}</b></span>",
|
||||||
"escape": true
|
"weeks": "<span color='#458588'><b>W{}</b></span>",
|
||||||
},
|
"weekdays": "<span color='#d79921'><b>{}</b></span>",
|
||||||
"custom/player": {
|
"today": "<span color='#d65d0e'><b><u>{}</u></b></span>"
|
||||||
"format": "{icon} <span style=\"italic\">{}</span>",
|
}
|
||||||
"format-icons": {
|
},
|
||||||
"Playing": " ",
|
"actions": {
|
||||||
"Paused": " "
|
"on-click-right": "mode",
|
||||||
},
|
"on-scroll-down": "shift_up",
|
||||||
"return-type": "json",
|
"on-scroll-up": "shift_down"
|
||||||
"exec": "playerctl -a metadata --format '{\"text\": \"{{playerName}}: {{artist}} - {{markup_escape(title)}}\", \"tooltip\": \"{{markup_escape(title)}} - {{markup_escape(album)}}\", \"class\": \"{{status}}\", \"alt\": \"{{status}}\" }' -F",
|
}
|
||||||
"max-length": 40,
|
},
|
||||||
"on-click": "playerctl play-pause",
|
"custom/notification": {
|
||||||
"on-click-right": "pavucontrol"
|
"tooltip": true,
|
||||||
}
|
"format": "{icon}",
|
||||||
|
"format-icons": {
|
||||||
|
"notification": " <span foreground='red'><sup></sup></span> <span weight=\"bold\">Unread</span>",
|
||||||
|
"none": " <span style=\"italic\">Empty</span>",
|
||||||
|
"dnd-notification": " <span style=\"italic\">DND on</span>",
|
||||||
|
"dnd-none": " <span style=\"italic\">DND on</span>"
|
||||||
|
},
|
||||||
|
"return-type": "json",
|
||||||
|
"exec-if": "which swaync-client",
|
||||||
|
"exec": "swaync-client -swb",
|
||||||
|
"on-click": "swaync-client -t -sw",
|
||||||
|
"on-click-right": "swaync-client -d -sw",
|
||||||
|
"escape": true
|
||||||
|
},
|
||||||
|
"custom/player": {
|
||||||
|
"format": "{icon} <span style=\"italic\">{}</span>",
|
||||||
|
"format-icons": {
|
||||||
|
"Playing": " ",
|
||||||
|
"Paused": " "
|
||||||
|
},
|
||||||
|
"return-type": "json",
|
||||||
|
"exec": "playerctl -a metadata --format '{\"text\": \"{{playerName}}: {{artist}} - {{markup_escape(title)}}\", \"tooltip\": \"{{markup_escape(title)}} - {{markup_escape(album)}}\", \"class\": \"{{status}}\", \"alt\": \"{{status}}\" }' -F",
|
||||||
|
"max-length": 40,
|
||||||
|
"on-click": "playerctl play-pause",
|
||||||
|
"on-click-right": "pavucontrol"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user