295 lines
7.0 KiB
Nix
295 lines
7.0 KiB
Nix
{ pkgs, ... }:
|
|
{
|
|
programs.waybar = {
|
|
enable = true;
|
|
settings.mainBar = {
|
|
layer = "top";
|
|
position = "top";
|
|
# mod = "dock";
|
|
# exclusive = true;
|
|
# gtk-layer-shell = true;
|
|
margin-bottom = -1;
|
|
# passthrough = false;
|
|
height = 32;
|
|
modules-left = [
|
|
"niri/workspaces"
|
|
"niri/window"
|
|
];
|
|
modules-center = [ "clock" ];
|
|
modules-right = [
|
|
"cpu"
|
|
"memory"
|
|
"tray"
|
|
"bluetooth"
|
|
"pulseaudio"
|
|
"network"
|
|
"battery"
|
|
];
|
|
|
|
"niri/workspaces" = {
|
|
format = "{icon}";
|
|
format-icons = {
|
|
|
|
# Icons by state
|
|
active = "";
|
|
default = "";
|
|
};
|
|
};
|
|
|
|
"niri/window" = {
|
|
format = "{}";
|
|
};
|
|
|
|
cpu = {
|
|
interval = 5;
|
|
format = " {usage}%";
|
|
max-length = 10;
|
|
};
|
|
|
|
memory = {
|
|
interval = 10;
|
|
format = " {percentage}%";
|
|
max-length = 10;
|
|
tooltip = true;
|
|
tooltip-format = "RAM - {used:0.1f}GiB used";
|
|
};
|
|
|
|
tray = {
|
|
icon-size = 18;
|
|
spacing = 3;
|
|
};
|
|
|
|
clock = {
|
|
format = " {:%R\n %d.%m.%Y}";
|
|
tooltip-format = "<tt><small>{calendar}</small></tt>";
|
|
calendar = {
|
|
mode = "year";
|
|
mode-mon-col = 3;
|
|
weeks-pos = "right";
|
|
on-scroll = 1;
|
|
on-click-right = "mode";
|
|
format = {
|
|
months = "<span color='#ffead3'><b>{}</b></span>";
|
|
days = "<span color='#ecc6d9'><b>{}</b></span>";
|
|
weeks = "<span color='#99ffdd'><b>W{}</b></span>";
|
|
weekdays = "<span color='#ffcc66'><b>{}</b></span>";
|
|
today = "<span color='#ff6699'><b><u>{}</u></b></span>";
|
|
};
|
|
};
|
|
|
|
actions = {
|
|
on-click-right = "mode";
|
|
on-click-forward = "tz_up";
|
|
on-click-backward = "tz_down";
|
|
on-scroll-up = "shift_up";
|
|
on-scroll-down = "shift_down";
|
|
};
|
|
};
|
|
|
|
network = {
|
|
format-wifi = " {icon}";
|
|
tooltip-format-wifi = "{essid} ({signalStrength}%)";
|
|
format-ethernet = " ";
|
|
format-disconnected = " ";
|
|
format-icons = [
|
|
" "
|
|
" "
|
|
" "
|
|
" "
|
|
" "
|
|
];
|
|
# tooltip = false;
|
|
};
|
|
|
|
battery = {
|
|
states = {
|
|
good = 95;
|
|
warning = 30;
|
|
critical = 20;
|
|
};
|
|
format = " {icon} {capacity}%";
|
|
format-charging = " {capacity}%";
|
|
format-plugged = " {capacity}%";
|
|
format-alt = "{time} {icon}";
|
|
format-icons = [
|
|
""
|
|
""
|
|
""
|
|
""
|
|
""
|
|
""
|
|
""
|
|
""
|
|
""
|
|
""
|
|
""
|
|
];
|
|
};
|
|
|
|
# not actually pulseaudio-specific (I use pipewire!)
|
|
pulseaudio = {
|
|
max-volume = 100;
|
|
scroll-step = 10;
|
|
format = "{icon}";
|
|
tooltip-format = "{desc} ({volume}%)";
|
|
format-muted = "🔇";
|
|
format-icons = {
|
|
default = [
|
|
" "
|
|
" "
|
|
" "
|
|
];
|
|
};
|
|
on-click = "${pkgs.pwvucontrol}/bin/pwvucontrol";
|
|
};
|
|
|
|
bluetooth = {
|
|
format = " ({status}) ";
|
|
format-connected = " {device_alias}";
|
|
format-connected-battery = " {device_alias} {device_battery_percentage}%";
|
|
tooltip-format = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
|
|
tooltip-format-connected = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
|
|
tooltip-format-enumerate-connected = "{device_alias}\t{device_address}";
|
|
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
|
|
|
|
on-click = "${pkgs.blueman}/bin/blueman-manager";
|
|
};
|
|
};
|
|
|
|
style = ''
|
|
/*base background color*/
|
|
/* color picked from a celeste background bc it looks pretty and matches my background */
|
|
@define-color bg_main rgba(39.6, 51.4, 76.1, 1.0);
|
|
|
|
@define-color bg_main_tooltip rgba(0, 0, 0, 0.7);
|
|
|
|
/*base background color of selections */
|
|
@define-color bg_hover rgba(200, 200, 200, 0.3);
|
|
/*base background color of active elements */
|
|
@define-color bg_active rgba(100, 100, 100, 0.5);
|
|
|
|
/*base border color*/
|
|
@define-color border_main rgba(255, 255, 255, 0.2);
|
|
|
|
/*text color for entries, views and content in general */
|
|
@define-color content_main white;
|
|
/*text color for entries that are unselected */
|
|
@define-color content_inactive rgba(255, 255, 255, 0.25);
|
|
|
|
* {
|
|
text-shadow: none;
|
|
box-shadow: none;
|
|
border: none;
|
|
border-radius: 0;
|
|
font-family: "Segoe UI", "Ubuntu";
|
|
font-weight: 600;
|
|
font-size: 12.7px;
|
|
}
|
|
|
|
window#waybar {
|
|
background: @bg_main;
|
|
border-top: 0;
|
|
color: @content_main;
|
|
}
|
|
|
|
tooltip {
|
|
background: @bg_main_tooltip;
|
|
border-radius: 5px;
|
|
border-width: 1px;
|
|
border-style: solid;
|
|
border-color: @border_main;
|
|
}
|
|
|
|
tooltip label {
|
|
color: @content_main;
|
|
}
|
|
|
|
#taskbar {
|
|
}
|
|
|
|
#taskbar button {
|
|
min-width: 130px;
|
|
border-bottom: 3px solid rgba(255, 255, 255, 0.3);
|
|
margin-left: 2px;
|
|
margin-right: 2px;
|
|
padding-left: 8px;
|
|
padding-right: 8px;
|
|
color: white;
|
|
transition: all 0.25s cubic-bezier(0.165, 0.84, 0.44, 1);
|
|
}
|
|
|
|
#taskbar button.active {
|
|
border-bottom: 3px solid white;
|
|
background: @bg_active;
|
|
}
|
|
|
|
#taskbar button:hover {
|
|
border-bottom: 3px solid white;
|
|
background: @bg_hover;
|
|
color: @content_main;
|
|
}
|
|
|
|
#cpu, #memory {
|
|
padding:3px;
|
|
}
|
|
|
|
#window {
|
|
border-radius: 10px;
|
|
margin-left: 20px;
|
|
margin-right: 20px;
|
|
}
|
|
|
|
#tray {
|
|
margin-left: 5px;
|
|
margin-right: 5px;
|
|
}
|
|
|
|
#tray > .passive {
|
|
border-bottom: none;
|
|
}
|
|
|
|
#tray > .active {
|
|
border-bottom: 3px solid white;
|
|
}
|
|
|
|
#tray > .needs-attention {
|
|
border-bottom: 3px solid @warning_color;
|
|
}
|
|
|
|
#tray > widget {
|
|
transition: all 0.25s cubic-bezier(0.165, 0.84, 0.44, 1);
|
|
}
|
|
|
|
#tray > widget:hover {
|
|
background: @bg_hover;
|
|
}
|
|
|
|
#pulseaudio {
|
|
font-family: "JetBrains Mono Nerd Font";
|
|
padding-left: 3px;
|
|
padding-right: 3px;
|
|
transition: all 0.25s cubic-bezier(0.165, 0.84, 0.44, 1);
|
|
}
|
|
|
|
#pulseaudio:hover {
|
|
background: @bg_hover;
|
|
}
|
|
|
|
#network {
|
|
padding-left: 3px;
|
|
padding-right: 3px;
|
|
}
|
|
|
|
#clock {
|
|
padding-right: 5px;
|
|
padding-left: 5px;
|
|
transition: all 0.25s cubic-bezier(0.165, 0.84, 0.44, 1);
|
|
}
|
|
|
|
#clock:hover {
|
|
background: @bg_hover;
|
|
}
|
|
'';
|
|
};
|
|
}
|