From c8ab72f878734fa1c5500bb122280fb0b22c0e8e Mon Sep 17 00:00:00 2001 From: Viyurz Date: Mon, 21 Oct 2024 09:58:57 +0200 Subject: [PATCH] [eww] Add window title & update slider --- .config/eww/eww.scss | 11 ++--------- .config/eww/eww.yuck | 10 ++++++++++ README.md | 2 +- 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/.config/eww/eww.scss b/.config/eww/eww.scss index 483ae16..f1f033e 100644 --- a/.config/eww/eww.scss +++ b/.config/eww/eww.scss @@ -18,9 +18,6 @@ .bar > * > *:nth-child(even) { color: $accent1; - scale slider { - background-color: $disabled; - } scale trough { background-color: $background1; } @@ -31,11 +28,8 @@ .bar > * > *:nth-child(odd) { color: $accent2; - scale slider { - background-color: $disabled2; - } scale trough { - background-color: $background2; + background-color: $disabled2; } scale trough highlight { background-color: $accent2; @@ -51,8 +45,7 @@ scale { } scale slider { - min-height: 1px; - min-width: 1px; + all: unset; } scale trough { diff --git a/.config/eww/eww.yuck b/.config/eww/eww.yuck index 486b065..bec2371 100644 --- a/.config/eww/eww.yuck +++ b/.config/eww/eww.yuck @@ -12,6 +12,9 @@ (defpoll day :interval "1m" "date +'%d'") (defpoll year :interval "1m" "date +'%Y'") +; Window Title +(deflisten window-title "hyprctl activewindow -j | jq --raw-output .title; socat -u UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - | stdbuf -o0 awk -F '>>|,' '/^activewindow>>/{print $3}'") + ; Widgets @@ -21,6 +24,12 @@ ) ) +(defwidget bar-middle [] + (label :limit-width 2 + :text "${window-title}" + ) +) + (defwidget bar-right [] (box :halign "end" :space-evenly false @@ -95,6 +104,7 @@ (defwidget bar [] (box (bar-left) + (bar-middle) (bar-right) ) ) diff --git a/README.md b/README.md index 8ca0801..b2c5f0a 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ cfg pull Required packages: ``` -paru -S blueman bottom cliphist eww fastfetch firefox git gnome-keyring grim hyprcursor hypridle hyprland hyprlock hyprpaper imagemagick jq kitty mako networkmanager network-manager-applet nm-connection-editor noto-fonts noto-fonts-cjk noto-fonts-emoji oh-my-zsh-git otf-font-awesome pacman-contrib pastel pavucontrol pipewire-alsa pipewire-jack pipewire-pulse polkit-gnome python-pywal python-pywalfox rose-pine-cursor rose-pine-hyprcursor slurp swayosd-git ttf-jetbrains-mono-nerd udiskie waybar wl-clipboard wlogout wofi xdg-desktop-portal-hyprland zoxide zsh zsh-autosuggestions +paru -S blueman bottom cliphist eww fastfetch firefox git gnome-keyring grim hyprcursor hypridle hyprland hyprlock hyprpaper imagemagick jq kitty mako networkmanager network-manager-applet nm-connection-editor noto-fonts noto-fonts-cjk noto-fonts-emoji oh-my-zsh-git otf-font-awesome pacman-contrib pastel pavucontrol pipewire-alsa pipewire-jack pipewire-pulse polkit-gnome python-pywal python-pywalfox rose-pine-cursor rose-pine-hyprcursor slurp socat swayosd-git ttf-jetbrains-mono-nerd udiskie waybar wl-clipboard wlogout wofi xdg-desktop-portal-hyprland zoxide zsh zsh-autosuggestions ``` Optional packages: