pinwheel: Add colors module to define common colors

This commit is contained in:
Alexander Heldt
2023-10-21 22:47:20 +02:00
parent 4a1a50d24f
commit ca1b71261d
6 changed files with 50 additions and 49 deletions

View File

@@ -2,13 +2,7 @@
let
hyprlandEnabled = config.mod.hyprland.enable;
bmr =
let
foreground = "#f9c22b";
foreground-dim = "#a57b06";
background = "#262626";
in
pkgs.writeShellScript "bmr" ''
bmr = pkgs.writeShellScript "bmr" ''
${pkgs.bemenu}/bin/bemenu-run \
--fn 'DejaVuSansM Nerd Font Mono 16' \
--hp 10 \
@@ -16,10 +10,10 @@ let
--cw 12 \
--ch 25 \
--fixed-height \
--ff "${foreground}" --fb "${background}" \
--hf "${foreground}" --hb "${background}" \
--af "${foreground-dim}" --ab "${background}" \
--nf "${foreground-dim}" --nb "${background}" \
--ff "#${config.lib.colors.foreground}" --fb "#${config.lib.colors.background}" \
--hf "#${config.lib.colors.foreground}" --hb "#${config.lib.colors.background}" \
--af "#${config.lib.colors.foreground-dim}" --ab "#${config.lib.colors.background}" \
--nf "#${config.lib.colors.foreground-dim}" --nb "#${config.lib.colors.background}" \
--prompt ""
'';
in

View File

@@ -0,0 +1,12 @@
{
lib = {
colors = {
foreground = "f9c22b";
foreground-dim = "a57b06";
background = "262626";
gray = "3a3a3a";
warning = "ff6969";
};
};
}

View File

@@ -1,5 +1,4 @@
{ pkgs, ... }:
{ pkgs, config, ... }:
{
home-manager.users.alex = {
services.dunst = {
@@ -13,7 +12,7 @@
offset = "10x50";
origin = "top-right";
transparency = 10;
frame_color = "#a57b06";
frame_color = "#${config.lib.colors.foreground-dim}";
font = "DejaVuSansM Nerd Font Mono 14";
};
@@ -24,8 +23,8 @@
};
urgency_normal = {
background = "#262626";
foreground = "#f9c22b";
background = "#${config.lib.colors.background}";
foreground = "#${config.lib.colors.foreground}";
timeout = 10;
};

View File

@@ -61,10 +61,13 @@ in
};
general = {
layout = "dwindle";
gaps_in = 0; # gaps between windows
gaps_out = 0; # gaps between windows and monitor edges
layout = "dwindle";
"col.active_border" = "rgba(${config.lib.colors.foreground}ff)";
"col.inactive_border" = "rgba(${config.lib.colors.background}ff)";
};
dwindle = {

View File

@@ -1,4 +1,4 @@
{ pkgs, ... }:
{ pkgs, config, ... }:
{
home-manager.users.alex = {
programs.tmux = {
@@ -24,19 +24,18 @@
set-option -g allow-rename off
# Status line colors
set -g status-fg '#f9c22b'
set -g status-bg '#303030'
set -g status-fg '#${config.lib.colors.foreground}'
set -g status-bg '#${config.lib.colors.background}'
# Remove date/time etc. on the right side
set -g status-right ""
# Status window colors
set -g window-status-current-style bg='#3a3a3a',fg='#f9c22b'
set -g window-status-current-style bg='#3a3a3a',fg='#f9c22b'
set -g window-status-style bg='#303030',fg='#767676'
set -g window-status-current-style bg='#${config.lib.colors.background}',fg='#${config.lib.colors.foreground}'
set -g window-status-style bg='#${config.lib.colors.background}',fg='#${config.lib.colors.foreground-dim}'
set -g pane-border-style fg='#3a3a3a'
set -g pane-active-border-style fg='#f9c22b'
set -g pane-border-style fg='#${config.lib.colors.gray}'
set -g pane-active-border-style fg='#${config.lib.colors.foreground}'
bind r source-file ~/.config/tmux/tmux.conf \; display "Config reloaded"

View File

@@ -216,21 +216,15 @@ in
};
};
style = let
foreground = "#f9c22b";
foreground-dim = "#a57b06";
background = "#262626";
warning = "#FF6969";
in
''
style = ''
* {
font-family: 'DejaVuSansM Nerd Font Mono';
font-size: 22px;
}
#workspaces button {
color: ${foreground-dim};
background-color: ${background};
color: #${config.lib.colors.foreground-dim};
background-color: #${config.lib.colors.background};
border: none;
}
@@ -243,25 +237,25 @@ in
}
#workspaces button.active {
color: ${foreground};
background-color: ${background};
color: #${config.lib.colors.foreground};
background-color: #${config.lib.colors.background};
}
window#waybar {
color: ${foreground};
background-color: ${background};
color: #${config.lib.colors.foreground};
background-color: #${config.lib.colors.background};
}
#wireplumber.muted {
color: ${warning};
color: #${config.lib.colors.warning};
}
#custom-mullvad.disconnected {
color: ${warning};
color: #${config.lib.colors.warning};
}
#custom-work-vpn-status {
color: ${warning};
color: #${config.lib.colors.warning};
}
#clock {