diff --git a/cava/config b/cava/config index 2bc0d06..26e96d4 100644 --- a/cava/config +++ b/cava/config @@ -217,7 +217,7 @@ bar_width = 1 # a terminal that can change color definitions such as Gnome-terminal or rxvt. # default is to keep current terminal color ; background = default -; foreground = default +foreground = blue # SDL and sdl_glsl only support hex code colors, these are the default: ; background = '#111111' @@ -227,7 +227,7 @@ bar_width = 1 # Gradient mode, only hex defined colors are supported, # background must also be defined in hex or remain commented out. 1 = on, 0 = off. # You can define as many as 8 different colors. They range from bottom to top of screen -gradient = 1 +gradient = 0 gradient_count = 2 gradient_color_1 = '#9E2238' gradient_color_2 = '#9E2238' diff --git a/hypr/hyprland.conf b/hypr/hyprland.conf index 419ff3a..6a77d7a 100644 --- a/hypr/hyprland.conf +++ b/hypr/hyprland.conf @@ -23,10 +23,9 @@ $powermodemenu = $HOME/.config/rofi/scripts/dmenu_powermodemenu.sh $browser = env GTK_THEME=Adwaita:light zen-browser $privateBrowser = env GTK_THEME=Adwaita:light zen-browser --private-window $notificationCenter = pkill rofi & swaync-client -t -sw || notify-send --hint int:transient:1 "Error SwayNC is down" -$waybar = GTK_THEME="Simply_Circles_Dark" waybar +$waybar = GTK_THEME="Simply_Circles_Dark" waybar -c "$HOME/.config/waybar/config_top.jsonc" -s "$HOME/.config/waybar/style_top.css" & $mpdpass = kapuchinamusica -$dock = nwg-dock-hyprland -i 25 -w 12 -hi -x -ico view_icon -c "$HOME/.config/rofi/launchers/type-1/launcher.sh" ################# ### AUTOSTART ### diff --git a/hypr/scripts/gamemode.sh b/hypr/scripts/gamemode.sh index 4b87c16..c4f513f 100755 --- a/hypr/scripts/gamemode.sh +++ b/hypr/scripts/gamemode.sh @@ -1,6 +1,4 @@ #!/usr/bin/env sh -STATUSBAR="waybar" - HYPRGAMEMODE=$(hyprctl getoption animations:enabled | awk 'NR==1{print $2}') if [ "$HYPRGAMEMODE" = 1 ] ; then hyprctl --batch "\ @@ -13,16 +11,17 @@ if [ "$HYPRGAMEMODE" = 1 ] ; then keyword decoration:active_opacity 1;\ keyword plugin:hyprfocus:fade_opacity 1" - if pgrep $STATUSBAR > /dev/null; then - pkill $STATUSBAR - waybar -c "$HOME/.config/waybar/config_minimal.jsonc" & + if pgrep waybar > /dev/null; then + pkill waybar + # TODO: lite waybar version + waybar -c "$HOME/.config/waybar/config_top.jsonc" -s "$HOME/.config/waybar/style_top.css" & fi exit fi -if pgrep $STATUSBAR > /dev/null; then - pkill $STATUSBAR - waybar -c "$HOME/.config/waybar/config.jsonc" & +if pgrep waybar > /dev/null; then + pkill waybar + waybar -c "$HOME/.config/waybar/config_top.jsonc" -s "$HOME/.config/waybar/style_top.css" & fi hyprctl reload diff --git a/hypr/scripts/toggle_waybar.sh b/hypr/scripts/toggle_waybar.sh index 9f8036b..b03c55f 100755 --- a/hypr/scripts/toggle_waybar.sh +++ b/hypr/scripts/toggle_waybar.sh @@ -2,8 +2,6 @@ if pgrep -x waybar > /dev/null; then pkill -x waybar - pkill -x nwg-dock-hyprla else - GTK_THEME="Simply_Circles_Dark" waybar & - nwg-dock-hyprland -i 25 -w 12 -hi -x -ico view_icon -c "$HOME/.config/rofi/launchers/type-1/launcher.sh" & + GTK_THEME="Simply_Circles_Dark" waybar -c "$HOME/.config/waybar/config_top.jsonc" -s "$HOME/.config/waybar/style_top.css" & fi diff --git a/waybar/colors.css b/waybar/colors.css new file mode 100644 index 0000000..e5ccdb4 --- /dev/null +++ b/waybar/colors.css @@ -0,0 +1,12 @@ +@define-color bg-panel rgba(28, 28, 28, 0.81); +@define-color text-secondary rgba(86, 86, 86, 0.81); +@define-color bg-opaque rgba(23, 28, 39, 0.8); +@define-color border-color-section rgba(0,0,0,0); +@define-color border-color rgba(90, 104, 115, 0.8); /* Matches --noti-border-color */ +@define-color text-primary #ffffff; +@define-color text-secondary alpha(@text-primary,.2); +@define-color accent-color #D58399; +@define-color attention #FFFF00; +@define-color warning #FFAA00; +@define-color danger #FF0000; +@define-color success #00FF00; diff --git a/waybar/config_bottom.jsonc b/waybar/config_bottom.jsonc new file mode 100644 index 0000000..e69de29 diff --git a/waybar/config_top.jsonc b/waybar/config_top.jsonc new file mode 100644 index 0000000..6b28cf0 --- /dev/null +++ b/waybar/config_top.jsonc @@ -0,0 +1,220 @@ +// -*- mode: jsonc -*- +{ + //"output": "eDP-1", + "output": [ + "eDP-1", + "HDMI-A-1" + ], + // "layer": "top", // Waybar at top layer + // "position": "bottom", // Waybar position (top|bottom|left|right) + "height": 30, // Waybar height (to be removed for auto height) + "width": 1900, // Waybar width + "spacing": 0, // Gaps between modules (4px) + "reload_style_on_change": true, + // Choose the order of the modules + "modules-left": [ + "custom/separator_invisible", + "mpd", + "custom/pomodoro" + ], + "modules-center": [ + "hyprland/workspaces" + ], + "modules-right": [ + "pulseaudio", + "pulseaudio/slider", + "battery", + "network", + "clock", + "custom/separator_invisible" + ], + // Modules configuration + "hyprland/workspaces": { + "disable-scroll": true, + "all-outputs": false, + "active-only": true, + "warp-on-scroll": false, + "persistent-workspaces": { + // "1": [], + // "2": [], + // "3": [], + // "4": [], + // "5": [], + // "6": [], + // "7": [], + // "8": [], + // "9": [], + // "10": [], + // "11": [], + // "12": [] + "eDP-1": [1,2,3,4,5,6,7,8,9], + "HDMI-A-1": [10,11,12], + "FUCKOFF": [13,14] + }, + "ignore-workspaces": [ + "*13", + "*14" + ], + "format": "{icon}", + "format-icons": { + "1": "󱐡", + "2": "󰰫", + "3": "󰛿", + "4": "󱑤", + "5": "󰲨", + "6": "󰲪", + "7": "󰥱", + "8": "󰷸", + "9": "󱡝", + "10": "󰥱", + "11": "", + "12": "", + "default": "󰽢", + "empty": "󰄰" + } + }, + "mpd": { + "password": "kapuchinamusica", + "artist-len": 30, + "title-len": 30, + "unknown-tag": "n/a", + "format": "{stateIcon} {titleSmart}", + "interval": 1, + "single-icons": { + "on": "1 " + }, + "state-icons": { + "paused": "", + "playing": "" + }, + "tooltip-format": "MPD (connected)", + "tooltip-format-disconnected": "MPD (disconnected)", + "format-stopped": "", + "on-click": "mpc toggle --password kapuchinamusica" + }, + "tray": { + // "icon-size": 21, + "spacing": 10, + "icons": { + "blueman": "bluetooth", + "*": "folder-symbolic" + } + }, + "clock": { + // "timezone": "America/New_York", + "interval": 5, + "tooltip-format": "{:%A ( %B %d )}\n{calendar}", + "format": "{:%H:%M}", + "format-alt": "{:%H:%M %d.%m.%Y}", + "calendar": { + "mode": "year", + "mode-mon-col": 3, + "weeks-pos": "right", + "format": { + "months": "{}", + "days": "{}", + "weeks": "W{}", + "weekdays": "{}", + "today": "{}" + } + }, + "actions": { + "on-click-right": "mode" + } + }, + "cpu": { + "format": "󰓅 {usage}%", + "tooltip": false, + "interval": 15, + "format-icons": [ + "󰄰", "󰪞", "󰪟", "󰪠", "󰪡", "󰪢", "󰪣", "󰪤", "󰪥" + ] + }, + "memory": { + "format": "󰧑 {percentage}% 󰋊 {swapPercentage}%", + "interval": 10 + }, + "battery": { + "full-at": 98, + "states": { + "good": 85, + "warning": 30, + "critical": 18 + }, + "format": "{icon}", + "format-full": "󱈏", + "format-charging": "{icon}󱐋", + "format-plugged": "{icon}", + "format-alt": "{time} {icon}", + // "format-good": "", // An empty format will hide the module + "format-icons": ["󰂎", "", "", "󰁽", "", "󰁿", "", "󰂁", "󰂂", ""], + "tooltip-format": "{capacity}%, draws {power:2.1f}W, time is {time}" + }, + "network": { + "format-wifi": "{icon}", + "format-ethernet": "{ipaddr}/{cidr} ", + "tooltip-format": "{essid} {ifname} via {gwaddr} ", + "format-linked": "{ifname} (No IP) ", + "format-disconnected": "󰤫", + "format-icons": [ + "󰤯", "󰤟", "󰤢", "󰤥", "󰤨" + ] + }, + "pulseaudio": { + // "scroll-step": 1, // %, can be a float + "format": "{format_source} ", + "format-muted": "{format_source} ", + "format-bluetooth": "{format_source} 󰂰", + "format-bluetooth-muted": "{format_source} 󰂲", + "format-source": "", + "format-source-muted": "", + "on-click": "pwvucontrol" + }, + "pulseaudio/slider": { + "min": 0, + "max": 100, + "orientation": "horizontal" + }, + "custom/logo": { + "format": "", + "on-click": "swaync-client -t -sw", + "interval": "once", + "tooltip": false + }, + "custom/separator": { + "format": "", + "interval": "once", + "tooltip": false + }, + "custom/separator_invisible": { + "format": " ", + "interval": "once", + "tooltip": false + }, + "custom/submap": { + "format": " {icon} {text}", + "max-length": 10, + "format-icons": { + "default": "󰥻" + }, + "interval": 2, + "exec": "state=$(hyprctl submap) && [[ $state != 'default' ]] && echo $state", + "on-click": "hyprctl dispatch submap reset" + }, + "custom/pomodoro": { + "format": "{}", + "return-type": "json", + "exec": "~/.local/bin/waybar-module-pomodoro --persist -w 20 -s 5 -l 20 -i 3 -p '' -a '' --autob", + "on-click": "~/.local/bin/waybar-module-pomodoro toggle", + "on-click-right": "~/.local/bin/waybar-module-pomodoro reset" + }, + "custom/panel": { + "format": "", + "on-click": "swaync-client -t -sw" + }, + "custom/goal": { + "exec": "cat $HOME/.config/waybar/goal.txt", + "format": "󱓧 {}", + "interval": 60 + } +} diff --git a/waybar/style_bottom.css b/waybar/style_bottom.css new file mode 100644 index 0000000..e69de29 diff --git a/waybar/style_top.css b/waybar/style_top.css new file mode 100644 index 0000000..4b65b4e --- /dev/null +++ b/waybar/style_top.css @@ -0,0 +1,306 @@ +/* Colors Definitions */ +@import "colors.css"; + +/* Window */ +window#waybar { + font-family: "Iosevka Nerd Font Propo"; + font-size: 15px; + background-color: @bg-panel; + color: @text-primary; + border-radius: 0 0 10px 10px; + border: 1px solid @border-color; + border-top: none; + transition-property: background-color; + transition-duration: 0.5s; +} + +window#waybar.hidden { + opacity: 0.2; +} + +window#waybar.termite { + background-color: #3F3F3F; +} + +window#waybar.chromium { + background-color: #000000; + border: none; +} + +/* Common module styling - applied to most modules */ +#mpd, +#custom-pomodoro, +#custom-goal, +#custom-submap, +#cpu, +#memory, +#disk, +#clock, +#battery, +#temperature, +#backlight, +#network, +#pulseaudio, +#pulseaudio-slider, +#wireplumber, +#custom-logo, +#custom-media, +#custom-panel, +#custom-separator, +#tray, +#mode, +#idle_inhibitor, +#scratchpad { + padding: 0 10px; + color: @text-primary; + transition: color 0.3s ease, text-shadow 0.3s ease, background 0.3s ease; +} + +/* Workspaces */ +#workspaces { + font-size: 18px; + background-color: transparent; +} + +#workspaces button { + padding: 0 6px; + min-width: 20px; + background-color: transparent; + color: alpha(@accent-color,.5); + border: none; + border-radius: 0; +} + +#workspaces button.empty { + color: @text-secondary; +} + +#workspaces button.active.hosting-monitor { + /* background-color: rgba(0, 0, 0, 0.32); */ + /* box-shadow: inset 0 -3px @accent-color; */ + color: @accent-color; + text-shadow: 0px 0px 8px @accent-color; + animation: hover 0.8s 1; +} + +#workspaces button.urgent { + color: @bg-opaque; + font-weight: 700; + color: @attention; + text-shadow: 0px 0px 8px @attention; + transition: color 0.5s, box-shadow 0.5s, background 0.5s; +} + +#workspaces button:hover { + color: @foreground; + background-color: transparent; + text-shadow: 0px 0px 2px rgba(233, 99, 117, 1); +} + +/* Side Module Groups */ +.modules-left { + border-left: none; + border-radius: 0 0 10px 0; +} + +.modules-right { + border-right: none; + border-radius: 0 0 0 10px; +} + +/* System Modules - specific border adjustments */ +#cpu, +#memory, +#memory.swap { + margin: 0; +} + +#cpu { + border-right: none; + border-radius: 0 0 0 10px; +} + +#memory { + border-left: none; +} + +/* Custom Modules */ +#custom-pomodoro { + color: @text-secondary; +} + +#custom-pomodoro { + border-radius: 0 0 10px 10px; +} + +#custom-goal { + margin: 0; + border-left: none; + border-radius: 0 0 10px 0; +} + +#custom-submap { + color: @text-primary; +} + +/* Pomodoro States */ +#custom-pomodoro.work { + color: @accent-color; +} + +#custom-pomodoro.break { + color: @success; + text-shadow: 0px 0px 4px rgba(0, 255, 0, 1); +} + +#custom-pomodoro.pause { + color: @attention; + text-shadow: 0px 0px 4px @attention; +} + +#custom-pomodoro.break + #custom-goal, +#custom-pomodoro.pause + #custom-goal { + color: inherit; + box-shadow: inherit; +} + +/* System Info Modules */ +#cpu, +#memory, +#memory.swap, +#disk { + color: @text-primary; +} + +#pulseaudio { + padding-right: 0; +} + +#pulseaudio-slider slider { + min-height: 0px; + min-width: 0px; + opacity: 0; + background-image: none; + border: none; + box-shadow: none; +} + +#pulseaudio-slider trough { + min-height: 10px; + min-width: 25px; + border-radius: 5px; + background: alpha(@text-primary,.2); +} + +#pulseaudio-slider highlight { + min-width: 10px; + border-radius: 5px; + background: @text-primary; +} + +#pulseaudio { + border-right: none; +} + +/* MPD specific styles */ +#mpd { + font-weight: 700; + transition: color 2s, background 2s; +} + +#mpd.playing { + color: @accent-color; +} + +#mpd.stopped { + /* color: rgba(255,255,255,0.5); */ + color: transparent; + background: transparent; +} + +#mpd.paused { + font-weight: normal; + color: @text-secondary; +} + +/* Hover Effects */ +#mpd.playing:hover, +#mpd.paused:hover, +#clock:hover, +#battery:hover, +#disk:hover, +#temperature:hover, +#backlight:hover, +#network:hover, +#pulseaudio:hover, +#cpu:hover, +#memory:hover, +#wireplumber:hover, +#custom-logo:hover, +#custom-pomodoro:hover, +#custom-media:hover, +#custom-panel:hover, +#mode:hover, +#idle_inhibitor:hover, +#scratchpad:hover, +#power-profiles-daemon:hover { + color: @accent-color; + text-shadow: 0px 0px 8px @accent-color; + transition: color 0.3s, box-shadow 0.3s, background 0.3s; +} + +#pulseaudio-slider:hover highlight { + background: @accent-color; + box-shadow: 0px 0px 8px @accent-color; + transition: color 0.3s, box-shadow 0.3s, background 0.3s; +} + +/* Battery States */ +#battery.charging, +#battery.plugged { + color: @success; + text-shadow: 0px 0px 8px @success; + transition: color 0.3s, box-shadow 0.3s, background 0.3s; +} + +#battery.warning:not(.charging) { + color: @warning; + text-shadow: 0px 0px 8px @warning; + transition: color 0.3s, box-shadow 0.3s, background 0.3s; +} + +#battery.critical:not(.charging) { + color: @danger; + text-shadow: 0px 0px 8px @danger; + transition: color 0.3s, box-shadow 0.3s, background 0.3s; +} + +/* Tray */ +#tray > .needs-attention { + -gtk-icon-effect: highlight; + animation: blink-attention 2s infinite; +} + +/* Animations */ +@keyframes hover { + 0% { color: @text-primary; } + 100% { color: @accent-color; } +} + +/* Layout Utilities */ +#window, +#workspaces { + margin: 0 0px; +} + +.modules-left > widget:first-child > #workspaces { + margin-left: 0; +} + +.modules-right > widget:last-child > #workspaces { + margin-right: 0; +} + +#mode { + box-shadow: inset 0 -3px @text-primary; +}