116 lines
3.4 KiB
Nix
116 lines
3.4 KiB
Nix
{
|
|
lib,
|
|
config,
|
|
pkgs,
|
|
flake,
|
|
...
|
|
}:
|
|
with lib; let
|
|
psCfg = config.pub-solar;
|
|
in {
|
|
home-manager.users."${psCfg.user.name}" = {
|
|
programs.waybar = with flake.self.theme.withHashtag; {
|
|
enable = true;
|
|
settings.main = {
|
|
layer = "top";
|
|
position = "top";
|
|
|
|
height = 32;
|
|
spacing = 16;
|
|
modules-left = ["sway/workspaces"];
|
|
modules-center = ["sway/mode"];
|
|
modules-right = ["network" "tray" "sway/language" "pulseaudio" "battery" "clock"];
|
|
|
|
"sway/workspaces".disable-scroll = true;
|
|
"sway/mode" = {
|
|
tooltip = false;
|
|
format = "{}";
|
|
};
|
|
"sway/window" = {
|
|
tooltip = false;
|
|
max-length = 96;
|
|
};
|
|
"sway/language" = {
|
|
format = "{}";
|
|
max-length = 2;
|
|
on-click = "${pkgs.toggle-kbd-layout}/bin/toggle-kbd-layout";
|
|
};
|
|
tray = {
|
|
icon-size = 16;
|
|
spacing = 16;
|
|
};
|
|
clock = {
|
|
tooltip-format = "<tt><small>{calendar}</small></tt>";
|
|
format-alt = "{:%a %d. %h %H:%M}";
|
|
calendar = {
|
|
mode-mon-col = "3";
|
|
on-scroll = "-1";
|
|
on-click-right = "mode";
|
|
format = {
|
|
months = "<span color='#ffead3'><b>{}</b></span>";
|
|
days = "<span color='#ecc6d9'><b>{}</b></span>";
|
|
weekdays = "<span color='#ffcc66'><b>{}</b></span>";
|
|
today = "<span color='#ff6699'><b><u>{}</u></b></span>";
|
|
};
|
|
};
|
|
};
|
|
battery = {
|
|
tooltip = false;
|
|
states = {
|
|
critical = 20;
|
|
};
|
|
full-at = 90;
|
|
format = "<span font='12'>{icon}</span> {capacity}%";
|
|
format-icons = ["" "" "" "" ""];
|
|
};
|
|
network = {
|
|
interval = 3;
|
|
tooltip = true;
|
|
format-wifi = "{bandwidthUpBits} up | {bandwidthDownBits} down";
|
|
format-ethernet = "{bandwidthUpBits} up | {bandwidthDownBits} down";
|
|
format-disconnected = "no network";
|
|
tooltip-format-wifi = "{essid} ({signalStrength}%) {ipaddr}";
|
|
tooltip-format-ethernet = "{ifname} {ipaddr}";
|
|
};
|
|
pulseaudio = {
|
|
tooltip = false;
|
|
format = "<span font='12'>{icon}</span> {volume}%";
|
|
format-bluetooth = "<span font='12'>{icon}</span> {volume}%";
|
|
format-muted = "<span font='12'>{icon}x</span>";
|
|
on-click = "pavucontrol";
|
|
format-icons = {
|
|
headphones = "";
|
|
handsfree = "";
|
|
headset = "";
|
|
phone = "";
|
|
portable = "";
|
|
car = "";
|
|
default = ["" "" ""];
|
|
};
|
|
};
|
|
};
|
|
style = ''
|
|
@define-color base00 ${base00};
|
|
@define-color base01 ${base01};
|
|
@define-color base02 ${base02};
|
|
@define-color base03 ${base03};
|
|
@define-color base04 ${base04};
|
|
@define-color base05 ${base05};
|
|
@define-color base06 ${base06};
|
|
@define-color base07 ${base07};
|
|
@define-color base08 ${base08};
|
|
@define-color base09 ${base09};
|
|
@define-color base0A ${base0A};
|
|
@define-color base0B ${base0B};
|
|
@define-color base0C ${base0C};
|
|
@define-color base0D ${base0D};
|
|
@define-color base0E ${base0E};
|
|
@define-color base0F ${base0F};
|
|
|
|
''+ builtins.readFile ./.config/waybar/style.css;
|
|
systemd.enable = true;
|
|
systemd.target = "sway-session.target";
|
|
};
|
|
};
|
|
}
|