{ pkgs, config, ... }: let terminal = "${config.programs.kitty.package}/bin/kitty -1"; in { programs.waybar = { enable = true; systemd.enable = true; style = ./waybar.css; settings = { mainBar = { layer = "top"; position = "top"; height = 30; modules-left = [ "hyprland/workspaces" ]; modules-center = [ "clock" ]; modules-right = [ "wireplumber" "power-profiles-daemon" "network" "battery" ]; wireplumber = { format = "󰕾 {volume}%"; format-muted = "󰖁"; on-click = "${pkgs.wireplumber}/bin/wpctl set-mute @DEFAULT_SINK@ toggle"; }; network = let nmtui = pkgs.writeScriptBin "nmtui.sh" '' #!${pkgs.stdenv.shell} unset COLORTERM TERM=xterm-old ${pkgs.networkmanager}/bin/nmtui ''; in { format-wifi = "󰖩 {essid} ({signalStrength}%)"; format-ethernet = "󰈀 {ifname}: {ipaddr}/{cidr}"; format-disconnected = "󰌙 "; tooltip-format = "{ifname}: {ipaddr}"; on-click = "${terminal} --execute ${nmtui}/bin/nmtui.sh"; }; power-profiles-daemon = { format = "{icon}"; format-icons = { performance = "󰓅"; balanced = "󰾅"; power-saver = "󰾆"; }; }; battery = { states = { warning = 30; critical = 15; }; format = "󱐋 {capacity}%"; format-discharging = "{icon} {capacity}%"; format-icons = [ "󰂎" "󰁺" "󰁻" "󰁼" "󰁽" "󰁾" "󰁿" "󰂀" "󰂁" "󰂂" "󰁹" ]; }; }; }; }; }