From 21abd9005d87265c5ef314334b8fa354ef372ea1 Mon Sep 17 00:00:00 2001 From: Donovan Glover Date: Sun, 25 Jun 2023 12:11:21 -0400 Subject: [PATCH] waybar: Don't hardcode color values Stylix exposes the generated color palette as part of config.lib, so hard-coding color values isn't necessary. --- home/waybar.nix | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/home/waybar.nix b/home/waybar.nix index 5e5a286..7cb4ac2 100644 --- a/home/waybar.nix +++ b/home/waybar.nix @@ -1,4 +1,4 @@ -{ lib, ... }: +{ config, lib, ... }: { programs.waybar = { @@ -87,22 +87,22 @@ }; style = lib.mkForce /* css */ '' - @define-color base00 #272822; - @define-color base01 #383830; - @define-color base02 #49483e; - @define-color base03 #75715e; - @define-color base04 #a59f85; - @define-color base05 #f8f8f2; - @define-color base06 #f5f4f1; - @define-color base07 #f9f8f5; - @define-color base08 #f92672; - @define-color base09 #fd971f; - @define-color base0A #f4bf75; - @define-color base0B #a6e22e; - @define-color base0C #a1efe4; - @define-color base0D #66d9ef; - @define-color base0E #ae81ff; - @define-color base0F #cc6633; + @define-color base00 #${config.lib.stylix.colors.base00}; + @define-color base01 #${config.lib.stylix.colors.base01}; + @define-color base02 #${config.lib.stylix.colors.base02}; + @define-color base03 #${config.lib.stylix.colors.base03}; + @define-color base04 #${config.lib.stylix.colors.base04}; + @define-color base05 #${config.lib.stylix.colors.base05}; + @define-color base06 #${config.lib.stylix.colors.base06}; + @define-color base07 #${config.lib.stylix.colors.base07}; + @define-color base08 #${config.lib.stylix.colors.base08}; + @define-color base09 #${config.lib.stylix.colors.base09}; + @define-color base0A #${config.lib.stylix.colors.base0A}; + @define-color base0B #${config.lib.stylix.colors.base0B}; + @define-color base0C #${config.lib.stylix.colors.base0C}; + @define-color base0D #${config.lib.stylix.colors.base0D}; + @define-color base0E #${config.lib.stylix.colors.base0E}; + @define-color base0F #${config.lib.stylix.colors.base0F}; * { color: @base05;