summaryrefslogtreecommitdiff
path: root/.config/waybar
diff options
context:
space:
mode:
authorDaniel Weipert <git@mail.dweipert.de>2024-07-19 12:11:38 +0200
committerDaniel Weipert <git@mail.dweipert.de>2024-07-19 12:15:15 +0200
commitd17c0364f1053cf8080a6e8d6438a1d43fc42532 (patch)
treead4b841b9603273de9ff04dbf4119c469c05bd71 /.config/waybar
parent485b513b2e82aa3dcf86e4b0ae8a1fa7bc4e004b (diff)
[sway+i3] pactl and other config adjustments
Diffstat (limited to '.config/waybar')
-rw-r--r--.config/waybar/config18
-rw-r--r--.config/waybar/style.css74
2 files changed, 59 insertions, 33 deletions
diff --git a/.config/waybar/config b/.config/waybar/config
index f659a30..13eeadc 100644
--- a/.config/waybar/config
+++ b/.config/waybar/config
@@ -1,8 +1,8 @@
{
"layer": "top",
- "modules-left": ["sway/workspaces", "sway/mode"],
+ "modules-left": ["sway/workspaces", "custom/workspace-add", "sway/mode"],
"modules-center": ["sway/window"],
- "modules-right": ["tray", "custom/alsa", "network", "clock"],
+ "modules-right": ["tray", "pulseaudio", "network", "clock"],
"sway/workspaces": {
"format": "{icon}",
"format-icons": {
@@ -28,6 +28,10 @@
"20": "二十"
}
},
+ "custom/workspace-add": {
+ "exec": "echo '+'",
+ "on-click": "~/.config/sway/bin/workspace-add"
+ },
"sway/window": {
"max-length": 100,
"icon": true,
@@ -36,13 +40,9 @@
"tray": {
"show-passive-items": true
},
- "custom/alsa": {
- "exec": "amixer get Master | grep '%' | awk -F '[][]' '{print $2}'",
- //"exec-if": "alsactl monitor",
- "format": "V {}",
- "on-scroll-up": "amixer set Master 1%+",
- "on-scroll-down": "amixer set Master 1%-",
- "interval": 1
+ "pulseaudio": {
+ "format": "V {volume}%",
+ "on-click-right": "pavucontrol"
},
"network": {
"format": "{ipaddr}",
diff --git a/.config/waybar/style.css b/.config/waybar/style.css
index d121dce..81a05be 100644
--- a/.config/waybar/style.css
+++ b/.config/waybar/style.css
@@ -4,34 +4,66 @@
font-size: 0.9rem;
}
+
+
widget button {
padding: 0;
border: none;
color: inherit;
}
-#workspaces {
- border: 1px solid rgba(255, 255, 255, 0.25);
+
+
+.modules-center {
+ padding: 5px 0;
+}
+
+
+
+.modules-right label,
+.modules-right box {
+ padding: 0 10px;
+}
+
+.modules-right widget:nth-child(odd) label,
+.modules-right widget:nth-child(odd) box {
+ background: rgba(255, 255, 255, 0.2);
}
+
+.modules-right widget:nth-child(even) label,
+.modules-right widget:nth-child(even) box {
+ background: rgba(255, 255, 255, 0.25);
+}
+
+
+
#workspaces button {
color: #fff;
- padding: 0;
+ padding: 0 0.35rem;
border-radius: 0;
min-height: 0;
- min-width: 25px;
- font-size: 0.75rem;
+ font-size: 0.7rem;
+ background: rgba(85, 85, 85, 0.5);
+ border: 0.5px solid transparent;
+}
+
+#workspaces button.visible {
+ background: rgba(51, 51, 51, 0.5);
}
-#workspaces button.focused {
+
+#workspaces button.visible.focused {
background: rgba(0, 0, 0, 0.8);
+ border-top-color: #fff;
}
+
#workspaces button:hover {
box-shadow: none;
- border: inherit;
+ border-color: #fff;
+ border-width: 0.5px;
background: inherit;
+ font-weight: inherit;
}
-#workspaces button + button {
- border-left: 1px solid rgba(255, 255, 255, 0.25);
-}
+
#mode {
border-bottom: 1px solid #fff;
@@ -40,23 +72,17 @@ widget button {
padding: 0 5px;
}
-.modules-center {
- padding: 5px 0;
-}
-.modules-right label,
-.modules-right box {
- padding: 0 10px;
-}
-.modules-right widget:nth-child(odd) label,
-.modules-right widget:nth-child(odd) box {
- background: rgba(255, 255, 255, 0.2);
-}
-.modules-right widget:nth-child(even) label,
-.modules-right widget:nth-child(even) box {
- background: rgba(255, 255, 255, 0.25);
+#custom-workspace-add {
+ padding: 0 0.5rem;
}
+
#tray widget + widget image {
margin-left: 5px;
}
+
+
+#pulseaudio.muted {
+ text-decoration: line-through;
+}