Regenerated

This commit is contained in:
2026-03-23 19:50:22 +00:00
parent 2654f48628
commit fd05613d2f
8419 changed files with 31 additions and 579 deletions
@@ -0,0 +1,127 @@
:root {
--base: #1e1e2e;
--mantle: #181825;
--crust: #11111b;
--text: #cdd6f4;
--subtext1: #bac2de;
--subtext0: #a6adc8;
--overlay2: #9399b2;
--overlay1: #7f849c;
--overlay0: #6c7086;
--surface2: #585b70;
--surface1: #45475a;
--surface0: #313244;
--lavender: #b4befe;
--blue: #89b4fa;
--sapphire: #74c7ec;
--teal: #94e2d5;
--green: #a6e3a1;
--yellow: #f9e2af;
--peach: #fab387;
--maroon: #eba0ac;
--red: #f38ba8;
--mauve: #cba6f7;
--pink: #f5c2e7;
--flamingo: #f2cdcd;
--rosewater: #f5e0dc;
}
* {
all: unset;
color: var(--text);
font-family:
FiraCode Nerd Font,
monospace;
font-size: 12px;
}
window {
border: 1px solid var(--surface0);
background-color: #1e1e2ee6;
border-radius: 8px;
margin: 0;
padding: 0;
box-shadow: 0 2px 10px #0003;
}
box {
spacing: 8px;
background-color: #0000;
padding: 4px 8px;
}
label {
color: var(--text);
padding: 2px 6px;
}
button {
color: var(--text);
background-color: var(--surface1);
border-radius: 4px;
padding: 2px 8px;
transition: all 0.2s;
}
button:hover {
background-color: var(--surface2);
color: var(--lavender);
}
button:active {
background-color: var(--blue);
color: var(--crust);
}
.workspace {
color: var(--subtext1);
background-color: #0000;
border-radius: 4px;
margin: 0 2px;
padding: 2px 8px;
}
.workspace.active {
background-color: var(--blue);
color: var(--base);
}
.workspace.urgent {
background-color: var(--red);
color: var(--crust);
}
.workspace.focused {
background-color: var(--lavender);
color: var(--base);
}
#clock {
color: var(--peach);
background-color: #0000;
padding: 2px 8px;
}
#cpu,
#ram,
#temp {
color: var(--green);
background-color: #0000;
padding: 2px 8px;
}
#volume {
color: var(--mauve);
}
#battery {
color: var(--green);
}
#battery.discharging {
color: var(--yellow);
}
#battery.critical {
color: var(--red);
}
@@ -0,0 +1,79 @@
;; Main bar widget
(defwidget bar []
(box :class "bar" :orientation "h" :space-evenly false :font "FiraCode Nerd Font 10"
;; Left: Workspaces (Hyprland)
(box :class "workspaces" :orientation "h"
(label :class "workspace" :id "workspace_1" :text "1")
(label :class "workspace" :id "workspace_2" :text "2")
(label :class "workspace" :id "workspace_3" :text "3")
(label :class "workspace" :id "workspace_4" :text "4")
(label :class "workspace" :id "workspace_5" :text "5")
)
;; Center: Empty (placeholder for alignment)
(box :halign "center" :hexpand true)
;; Right: System modules
(box :class "right-items" :orientation "h" :spacing 8
;; Idle inhibitor
(button :class "idle-inhibitor" :onclick "eww update idle_inhibitor_icon='\uF472'; notify-send 'Idle inhibitor' 'Activated'"
:label (label :id "idle_inhibitor_icon" :text "\uF472"))
;; PulseAudio
(button :class "pulseaudio" :onclick "pavucontrol"
:label (label :id "pulseaudio_label" :text "\uF028 100%"))
;; Network
(button :class "network" :onclick "impala" :onclick-right "nm-connection-editor"
:label (label :id "network_label" :text "Disconnected !"))
;; Battery
(button :class "battery" :label (label :id "battery_label" :text "100% \uF0E4"))
;; Tray placeholder (requires external tray like waybar-tray)
(box :class "tray" :orientation "h" :spacing 4
(label :text "Tray"))
;; Clock
(button :class "clock" :onclick "flatpak run eu.betterbird.Betterbird -calendar"
:label (label :id "clock_label" :text "Mon, 01 Jan 2024 - 12:00"))
)
)
)
;; Window definition
(defwindow bar-window
:geometry (geometry :x 0 :y 0 :width 1920 :height 34 :anchor "top left")
:layer "top"
:exclusivity "ignore"
(bar)
)
;; Scripts to update dynamic content
(defpoll [1000] ;; Update every second
;; Update PulseAudio volume
(setq pulseaudio-volume (exec "pamixer --get-volume"))
(setq pulseaudio-muted (exec "pamixer --get-mute"))
(if (string= pulseaudio-muted "true")
(eww update pulseaudio_label="\uF026")
(eww update pulseaudio_label=(strfmt "{}% {}" pulseaudio-volume (if (> (string->number pulseaudio-volume) 50) "\uF028" "\uF027"))
)
;; Update network status
(setq network-essid (exec "nmcli -t -f TYPE,NAME dev status | awk -F: '/wifi/{print $2}'"))
(if (string-empty? network-essid)
(eww update network_label="Disconnected !")
(eww update network_label=(strfmt "\uF1EB ({})" network-essid))
)
;; Update clock
(eww update clock_label=(strftime "%a, %d %b %Y - %H:%M"))
;; Update battery status
(setq battery-capacity (exec "cat /sys/class/power_supply/BAT0/capacity"))
(setq battery-status (exec "cat /sys/class/power_supply/BAT0/status"))
(if (string= battery-status "Charging")
(eww update battery_label=(strfmt "{}% \uF0E4" battery-capacity))
(eww update battery_label=(strfmt "{}% \uF079" battery-capacity))
)
)