summaryrefslogtreecommitdiff
path: root/.config/waybar
diff options
context:
space:
mode:
authorIwanIDev <iwan@iwani.dev>2026-03-25 15:50:39 +0000
committerIwanIDev <iwan@iwani.dev>2026-03-25 15:50:39 +0000
commita255db8ef33266f1edc689264f6a2cc5dacbbc0e (patch)
treee70465b6635e0e32fe76c5a1be739c1daba9a829 /.config/waybar
parent5e12e7ca836400ba82e66eac1edd22a8d5bb3d29 (diff)
Add dotfiles from current setup
Diffstat (limited to '.config/waybar')
-rw-r--r--.config/waybar/config.jsonc71
-rw-r--r--.config/waybar/mocha.css26
-rw-r--r--.config/waybar/style.css102
3 files changed, 199 insertions, 0 deletions
diff --git a/.config/waybar/config.jsonc b/.config/waybar/config.jsonc
new file mode 100644
index 0000000..66654ce
--- /dev/null
+++ b/.config/waybar/config.jsonc
@@ -0,0 +1,71 @@
+{
+ "layer": "top", // Waybar at top layer
+ "position": "top", // Waybar position (top|bottom|left|right)
+ // "width": 1280, // Waybar width
+ // Choose the order of the modules
+ "modules-left": ["sway/workspaces"],
+ "modules-center": ["custom/music"],
+ "modules-right": ["wireplumber", "backlight", "battery", "clock", "tray", "custom/lock", "custom/power"],
+ "sway/workspaces": {
+ "disable-scroll": true,
+ "sort-by-name": true,
+ "format": " {icon} ",
+ "format-icons": {
+ "default": " ",
+ },
+ },
+ "tray": {
+ "icon-size": 21,
+ "spacing": 10
+ },
+ "custom/music": {
+ "format": " {}",
+ "escape": true,
+ "interval": 5,
+ "tooltip": false,
+ "exec": "playerctl metadata --format='{{ title }} | {{ artist }}'",
+ "on-click": "playerctl play-pause",
+ "max-length": 50
+ },
+ "clock": {
+ "timezone": "Europe/London",
+ "tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>",
+ "format-alt": " {:%d/%m/%Y}",
+ "format": " {:%H:%M}"
+ },
+ "backlight": {
+ "device": "intel_backlight",
+ "format": "{icon}",
+ "format-icons": ["", "", "", "", "", "", "", "", ""]
+ },
+ "battery": {
+ "states": {
+ "warning": 30,
+ "critical": 15
+ },
+ "format": "{icon} {capacity}%",
+ "format-charging": "󰂄 {capacity}%",
+ "format-plugged": "󰂄 {capacity}%",
+ "format-alt": "{icon} {capacity}%",
+ "format-icons": ["", "", "", "", ""]
+ },
+ "wireplumber": {
+ // "scroll-step": 1, // %, can be a float
+ "format": "{icon} {volume}%",
+ "format-muted": "",
+ "format-icons": {
+ "default": ["", "", " "]
+ },
+ "on-click": "pavucontrol"
+ },
+ "custom/lock": {
+ "tooltip": false,
+ "on-click": "sh -c '(sleep 0.5s; swaylock --grace 0)' & disown",
+ "format": "",
+ },
+ "custom/power": {
+ "tooltip": false,
+ "on-click": "swaymsg exit &",
+ "format": "⏻ "
+ }
+}
diff --git a/.config/waybar/mocha.css b/.config/waybar/mocha.css
new file mode 100644
index 0000000..0eb6a82
--- /dev/null
+++ b/.config/waybar/mocha.css
@@ -0,0 +1,26 @@
+@define-color rosewater #f5e0dc;
+@define-color flamingo #f2cdcd;
+@define-color pink #f5c2e7;
+@define-color mauve #cba6f7;
+@define-color red #f38ba8;
+@define-color maroon #eba0ac;
+@define-color peach #fab387;
+@define-color yellow #f9e2af;
+@define-color green #a6e3a1;
+@define-color teal #94e2d5;
+@define-color sky #89dceb;
+@define-color sapphire #74c7ec;
+@define-color blue #89b4fa;
+@define-color lavender #b4befe;
+@define-color text #cdd6f4;
+@define-color subtext1 #bac2de;
+@define-color subtext0 #a6adc8;
+@define-color overlay2 #9399b2;
+@define-color overlay1 #7f849c;
+@define-color overlay0 #6c7086;
+@define-color surface2 #585b70;
+@define-color surface1 #45475a;
+@define-color surface0 #313244;
+@define-color base #1e1e2e;
+@define-color mantle #181825;
+@define-color crust #11111b;
diff --git a/.config/waybar/style.css b/.config/waybar/style.css
new file mode 100644
index 0000000..29525ee
--- /dev/null
+++ b/.config/waybar/style.css
@@ -0,0 +1,102 @@
+@import "mocha.css";
+
+* {
+ font-family: FantasqueSansM Nerd Font;
+ font-size: 17px;
+ min-height: 0;
+}
+
+#waybar {
+ background: transparent;
+ color: @text;
+ margin: 5px 5px;
+}
+
+#workspaces {
+ border-radius: 1rem;
+ margin: 5px;
+ background-color: @surface0;
+ margin-left: 1rem;
+}
+
+#workspaces button {
+ color: @lavender;
+ border-radius: 1rem;
+ padding: 0.4rem;
+}
+
+#workspaces button.active {
+ color: @sky;
+ border-radius: 1rem;
+}
+
+#workspaces button:hover {
+ color: @sapphire;
+ border-radius: 1rem;
+}
+
+#custom-music,
+#tray,
+#backlight,
+#clock,
+#battery,
+#wireplumber,
+#custom-lock,
+#custom-power {
+ background-color: @surface0;
+ padding: 0.5rem 1rem;
+ margin: 5px 0;
+}
+
+#clock {
+ color: @blue;
+ border-radius: 0px 1rem 1rem 0px;
+ margin-right: 1rem;
+}
+
+#battery {
+ color: @green;
+}
+
+#battery.charging {
+ color: @green;
+}
+
+#battery.warning:not(.charging) {
+ color: @red;
+}
+
+#backlight {
+ color: @yellow;
+}
+
+#backlight, #battery {
+ border-radius: 0;
+}
+
+#wireplumber {
+ color: @maroon;
+ border-radius: 1rem 0px 0px 1rem;
+ margin-left: 1rem;
+}
+
+#custom-music {
+ color: @mauve;
+ border-radius: 1rem;
+}
+
+#custom-lock {
+ border-radius: 1rem 0px 0px 1rem;
+ color: @lavender;
+}
+
+#custom-power {
+ margin-right: 1rem;
+ border-radius: 0px 1rem 1rem 0px;
+ color: @red;
+}
+
+#tray {
+ margin-right: 1rem;
+ border-radius: 1rem;
+}