Merge pull request 'desktop' (#1) from desktop into main

Reviewed-on: #1
This commit is contained in:
Nicholai 2025-11-25 10:52:27 +00:00
commit 0b9e9f0ca7
4 changed files with 190 additions and 69 deletions

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
nohup.out

View File

@ -1,10 +1,18 @@
{ {
"layer": "top", "layer": "top",
"position": "top", "position": "top",
"modules-left": ["hyprland/workspaces", "custom/weather","custom/wallpaper","hyprland/window"], "modules-left": [
"modules-center": ["clock"], "hyprland/workspaces",
"modules-right": ["network", "bluetooth", "temperature","custom/power_profile","custom/battery","backlight","pulseaudio","pulseaudio#microphone","tray","idle_inhibitor","cpu","memory","battery#bat2"], "tray"
],
"modules-center": [
"clock"
],
"modules-right": [
"custom/temps",
"pulseaudio",
"pulseaudio#microphone"
],
// "modules-left": [], // "modules-left": [],
"sway/mode": { "sway/mode": {
"format": "<span style=\"italic\">{}</span>" "format": "<span style=\"italic\">{}</span>"
@ -71,18 +79,24 @@
"tooltip-format-disconnected": "MPD (disconnected)" "tooltip-format-disconnected": "MPD (disconnected)"
}, },
"hyprland/workspaces": { "hyprland/workspaces": {
"format": "{icon}", "format": "{icon}",
"format-icons": { "format-icons": {
"1": "1", "1": "1",
"2": "2", "2": "2",
"3": "3", "3": "3",
"4": "4", "4": "4",
"5": "5", "5": "5",
"default": "●" "default": "●"
}, },
"persistent-workspaces": { "persistent-workspaces": {
"Virtual-1": [1, 2, 3, 4, 5] "Virtual-1": [
}, 1,
2,
3,
4,
5
]
},
"on-click": "activate" "on-click": "activate"
}, },
"idle_inhibitor": { "idle_inhibitor": {
@ -109,16 +123,20 @@
"memory": { "memory": {
"format": "{}% " "format": "{}% "
}, },
"temperature": { "custom/temps": {
"thermal-zone": 1, "exec": "~/.config/waybar/scripts/temps.sh",
"critical-threshold": 80, "interval": 2,
"format": "{temperatureF}°F ", "return-type": "json",
"format-critical": "{temperatureF}°F ", "format": "{}",
"tooltip": true "tooltip": true
}, },
"backlight": { "backlight": {
"format": "{icon} {percent}%", "format": "{icon} {percent}%",
"format-icons": ["󰃞", "󰃟", "󰃠"], "format-icons": [
"󰃞",
"󰃟",
"󰃠"
],
"on-scroll-up": "brightnessctl set 5%+", "on-scroll-up": "brightnessctl set 5%+",
"on-scroll-down": "brightnessctl set 5%-", "on-scroll-down": "brightnessctl set 5%-",
"min-length": 6 "min-length": 6
@ -136,7 +154,19 @@
"format-charging": " {capacity}%", "format-charging": " {capacity}%",
"format-plugged": " {capacity}%", "format-plugged": " {capacity}%",
"format-alt": "{time} {icon}", "format-alt": "{time} {icon}",
"format-icons": ["󰂎", "󰁺", "󰁻", "󰁼", "󰁽", "󰁾", "󰁿", "󰂀", "󰂁", "󰂂", "󰁹"], "format-icons": [
"󰂎",
"󰁺",
"󰁻",
"󰁼",
"󰁽",
"󰁾",
"󰁿",
"󰂀",
"󰂁",
"󰂂",
"󰁹"
],
"tooltip": true, "tooltip": true,
"tooltip-format": "{status} • {capacity}%\n{timeTo}\nHealth: {health}", "tooltip-format": "{status} • {capacity}%\n{timeTo}\nHealth: {health}",
"max-length": 15 "max-length": 15
@ -176,7 +206,11 @@
"phone": "", "phone": "",
"portable": "", "portable": "",
"car": "", "car": "",
"default": ["", "", ""] "default": [
"",
"",
""
]
} }
}, },
"pulseaudio#microphone": { "pulseaudio#microphone": {

18
scripts/temps.sh Executable file
View File

@ -0,0 +1,18 @@
#!/bin/bash
# Get CPU temp from k10temp (Tctl)
cpu_temp=$(sensors k10temp-pci-00c3 2>/dev/null | grep 'Tctl:' | awk '{print $2}' | sed 's/+//;s/°C//')
# Get GPU temp from amdgpu
gpu_temp=$(sensors amdgpu-pci-1600 2>/dev/null | grep 'edge:' | awk '{print $2}' | sed 's/+//;s/°C//')
# Get Coolant temp from Kraken
coolant_temp=$(sensors kraken2023-hid-3-9 2>/dev/null | grep 'Coolant' | awk '{print $3}' | sed 's/+//;s/°C//')
# Round temps
cpu_temp=$(printf "%.0f" "$cpu_temp" 2>/dev/null || echo "N/A")
gpu_temp=$(printf "%.0f" "$gpu_temp" 2>/dev/null || echo "N/A")
coolant_temp=$(printf "%.0f" "$coolant_temp" 2>/dev/null || echo "N/A")
# Output
echo "{\"text\":\" ${cpu_temp}° ${gpu_temp}° ${coolant_temp}°\", \"tooltip\":\"CPU: ${cpu_temp}°C | GPU: ${gpu_temp}°C | Coolant: ${coolant_temp}°C\"}"

160
style.css
View File

@ -1,39 +1,53 @@
* { * {
border: none; border: none;
border-radius: 4px; border-radius: 8px;
/* Increased border-radius by 2x */
/* `ttf-font-awesome` is required to be installed for icons */ /* `ttf-font-awesome` is required to be installed for icons */
font-family: "JetBrainsMono Nerd Font"; font-family: "JetBrainsMono Nerd Font";
/* adjust font-size value to your liking: */ /* adjust font-size value to your liking: */
font-size: 16px; font-size: 18px;
font-weight: bold; font-weight: bold;
min-height: 0; min-height: 0;
min-width: 28px;
/* Ensures consistent minimum width */
} }
window#waybar { window#waybar {
background-color: rgba(0, 0, 0, 0.9); background-color: rgba(0, 0, 0, 0);
color: #ffffff; color: #ffffff;
margin-top: 8px;
/* Add top margin to prevent touching screen top */
margin-bottom: 8px;
/* Optional: Also add bottom margin for consistency */
} }
#workspaces button { #workspaces button {
padding: 2px 8px; padding: 4px 8px;
margin: 0 2px; /* Reduced vertical padding further */
margin: 1px 2px;
/* Reduced vertical margins further */
background-color: rgba(255, 255, 255, 0.1); background-color: rgba(255, 255, 255, 0.1);
color: rgba(255, 255, 255, 0.6); color: rgba(255, 255, 255, 0.6);
border-radius: 6px; border-radius: 10px;
/* Increased border-radius by 2x */
transition: all 0.3s ease; transition: all 0.3s ease;
border: 1px solid transparent; border: 1px solid transparent;
min-height: 4px;
/* Reduced height even more */
font-size: 8px;
/* Reduced even more */
} }
#workspaces button:hover { #workspaces button:hover {
background-color: rgba(255, 255, 255, 0.2); background-color: rgba(255, 255, 255, 0.2);
color: #000000; color: rgba(0, 0, 0, 0.4);
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3); box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
} }
#workspaces button.active { #workspaces button.active {
background-color: rgba(255, 255, 255, 0.3); background-color: rgba(255, 255, 255, 0.3);
color: #000000; color: rgba(0, 0, 0, 0.4);
border: 1px solid rgba(255, 255, 255, 0.5); border: 1px solid rgba(255, 255, 255, 0.5);
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4); box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
} }
@ -46,6 +60,13 @@ window#waybar {
#mode { #mode {
background-color: #64727d; background-color: #64727d;
padding: 6px 10px;
/* Added consistent vertical padding */
margin: 6px 3px;
min-height: 28px;
/* Ensures consistent minimum height */
border-radius: 8px;
/* Increased border-radius by 2x */
} }
#clock, #clock,
@ -61,25 +82,43 @@ window#waybar {
#mode, #mode,
#idle_inhibitor, #idle_inhibitor,
#mpd { #mpd {
padding: 0 10px; padding: 6px 10px;
/* Added consistent vertical padding for height consistency */
margin: 6px 3px; margin: 6px 3px;
color: #000000; color: rgba(0, 0, 0, 0.4);
min-height: 28px;
/* Ensures consistent minimum height */
border-radius: 8px;
/* Increased border-radius by 2x */
} }
#window { #window {
margin: 0 4px; margin: 6px 4px;
/* Added vertical margins to match other modules */
padding: 6px 10px;
/* Added consistent vertical padding */
min-height: 28px;
/* Ensures consistent minimum height */
border-radius: 8px;
/* Increased border-radius by 2x */
} }
#workspaces { #workspaces {
margin: 0 6px; margin: 1px 3px;
padding: 2px 6px; /* Reduced vertical margins */
padding: 6px 8px 6px 8px;
/* Reduced vertical padding to 0, kept horizontal padding */
background-color: rgba(0, 0, 0, 0.4); background-color: rgba(0, 0, 0, 0.4);
border-radius: 8px; border-radius: 8px;
/* Increased border-radius by 2x */
min-height: 3px;
/* Reduced height even more */
} }
/* If workspaces is the leftmost module, omit left margin */ /* If workspaces is the leftmost module, use smaller left margin */
.modules-left>widget:first-child>#workspaces { .modules-left>widget:first-child>#workspaces {
margin-left: 0; margin-left: 4px;
/* Keep some margin from left screen edge */
} }
/* If workspaces is the rightmost module, omit right margin */ /* If workspaces is the rightmost module, omit right margin */
@ -88,18 +127,18 @@ window#waybar {
} }
#clock { #clock {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#battery { #battery {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#battery.charging { #battery.charging {
color: #ffffff; color: #ffffff;
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
} }
#battery.critical:not(.charging) { #battery.critical:not(.charging) {
@ -109,26 +148,26 @@ window#waybar {
} }
label:focus { label:focus {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
} }
#cpu { #cpu {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#memory { #memory {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#backlight { #backlight {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#network { #network {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
@ -137,33 +176,39 @@ label:focus {
} }
#pulseaudio { #pulseaudio {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#pulseaudio.muted { #pulseaudio.muted {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#custom-media { #custom-media {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
padding: 6px 10px;
/* Added consistent vertical padding */
min-height: 28px;
/* Ensures consistent minimum height */
border-radius: 8px;
/* Increased border-radius by 2x */
min-width: 100px; min-width: 100px;
} }
#custom-media.custom-spotify { #custom-media.custom-spotify {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#custom-media.custom-vlc { #custom-media.custom-vlc {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#temperature { #temperature {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
@ -172,13 +217,25 @@ label:focus {
color: #ffffff; color: #ffffff;
} }
#custom-temps {
background-color: rgba(0, 0, 0, 0.4);
color: #ffffff;
padding: 6px 10px;
/* Added consistent vertical padding */
margin: 6px 3px;
min-height: 28px;
/* Ensures consistent minimum height */
border-radius: 8px;
/* Increased border-radius by 2x */
}
#tray { #tray {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#idle_inhibitor { #idle_inhibitor {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
@ -188,7 +245,7 @@ label:focus {
} }
#mpd { #mpd {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
@ -198,21 +255,27 @@ label:focus {
} }
#mpd.stopped { #mpd.stopped {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#mpd.paused { #mpd.paused {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#language { #language {
background: #000000; background: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
padding: 0 5px; padding: 6px 10px;
/* Standardized vertical padding */
margin: 6px 3px; margin: 6px 3px;
min-width: 16px; min-height: 28px;
/* Ensures consistent minimum height */
border-radius: 8px;
/* Increased border-radius by 2x */
min-width: 28px;
/* Increased for consistency */
} }
#custom-weather, #custom-weather,
@ -222,49 +285,54 @@ label:focus {
#bluetooth, #bluetooth,
#pulseaudio-microphone, #pulseaudio-microphone,
#battery-bat2 { #battery-bat2 {
padding: 0 10px; padding: 6px 10px;
/* Added consistent vertical padding for height consistency */
margin: 6px 3px; margin: 6px 3px;
color: #000000; color: #000000;
min-height: 28px;
/* Ensures consistent minimum height */
border-radius: 8px;
/* Increased border-radius by 2x */
} }
#custom-weather { #custom-weather {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#custom-wallpaper { #custom-wallpaper {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#custom-power_profile { #custom-power_profile {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#bluetooth { #bluetooth {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#pulseaudio-microphone { #pulseaudio-microphone {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#pulseaudio-microphone.muted { #pulseaudio-microphone.muted {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: #ffffff; color: #ffffff;
} }
#battery-bat2 { #battery-bat2 {
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
color: white; color: white;
} }
#battery-bat2.charging { #battery-bat2.charging {
color: #ffffff; color: #ffffff;
background-color: #000000; background-color: rgba(0, 0, 0, 0.4);
} }
#battery-bat2.critical:not(.charging) { #battery-bat2.critical:not(.charging) {