Theme WIP overhaul

This commit is contained in:
kat witch 2021-08-26 18:26:57 +01:00
parent dc099c0d4f
commit 68594e6282
No known key found for this signature in database
GPG key ID: 1B477797DCA5EC72
14 changed files with 341 additions and 193 deletions

View file

@ -8,7 +8,5 @@
alias.dark = "atelier.atelier-cave";
};
kw.hexColors = lib.mapAttrs' (k: v: lib.nameValuePair k "#${v.hex.rgb}")
(lib.filterAttrs (n: _: lib.hasInfix "base" n) config.lib.arc.base16.schemeForAlias.default);
kw.theme.enable = true;
}

View file

@ -13,7 +13,7 @@ let
};
in
{
home.file.".mozilla/tst.css".source = pkgs.firefox-tst { base16 = config.kw.hexColors; };
home.file.".mozilla/tst.css".source = pkgs.firefox-tst { inherit (config.kw.theme) base16; };
programs.zsh.shellAliases = {
ff-pm = "firefox --ProfileManager";
@ -65,7 +65,7 @@ in
id = 0;
isDefault = true;
settings = commonSettings;
userChrome = builtins.readFile (pkgs.firefox-uc { base16 = config.kw.hexColors; });
userChrome = builtins.readFile (pkgs.firefox-uc { inherit (config.kw.theme) base16; });
};
};
};

View file

@ -9,10 +9,10 @@ with lib;
main = {
term = "foot";
locked-title = false;
font = "${config.kw.font.name}:size=${toString config.kw.font.size}, Twitter Color Emoji:size=8";
font-bold = "${config.kw.font.name}:size=${toString config.kw.font.size}:style=Bold";
font-italic = "${config.kw.font.name}:size=${toString config.kw.font.size}:style=Italic";
font-bold-italic = "${config.kw.font.name}:size=${toString config.kw.font.size}:style=Bold Italic";
font = "${config.kw.theme.font.name}:size=${toString config.kw.theme.font.size}, Twitter Color Emoji:size=8";
font-bold = "${config.kw.theme.font.name}:size=${toString config.kw.theme.font.size}:style=Bold";
font-italic = "${config.kw.theme.font.name}:size=${toString config.kw.theme.font.size}:style=Italic";
font-bold-italic = "${config.kw.theme.font.name}:size=${toString config.kw.theme.font.size}:style=Bold Italic";
dpi-aware = "no";
};
cursor = {

View file

@ -1,7 +1,7 @@
{ config, pkgs, lib, witch, ... }:
let
base16 = config.kw.hexColors;
inherit (config.kw.theme) base16;
in
{
systemd.user.services = {
@ -21,7 +21,7 @@ in
programs.mako = {
enable = true;
font = "${config.kw.font.name} ${toString config.kw.font.size}";
font = "${config.kw.theme.font.name} ${toString config.kw.theme.font.size}";
defaultTimeout = 3000;
borderColor = base16.base08;
backgroundColor = "${base16.base00}BF";

View file

@ -124,9 +124,9 @@ in
};
};
fonts = {
names = [ config.kw.font.name ];
names = [ config.kw.theme.font.name ];
style = "Medium";
size = config.kw.font.size;
size = config.kw.theme.font.size;
};
terminal = "${pkgs.foot}/bin/foot";
menu = "${pkgs.j4-dmenu-desktop}/bin/j4-dmenu-desktop --no-generic --dmenu=\"${dmenu}\" --term='${footwrap}/bin/footwrap'";
@ -288,7 +288,7 @@ in
"${cfg.modifier}+Delete" = ''mode "System (l) lock, (e) logout, (s) suspend, (h) hibernate, (r) reboot, (Shift+s) shutdown"'';
};
colors = let base16 = config.kw.hexColors; in
colors = let inherit (config.kw.theme) base16; in
{
focused = {
border = base16.base01;

View file

@ -1,127 +0,0 @@
{ hextorgba, base16, font }:
let
bcolor = color: ''
background: ${hextorgba color 0.75};
'';
in
''
* {
border: none;
border-radius: 0;
background: none;
font-family: "${font.name}";
font-size: ${font.size_css};
min-height: 12px;
text-shadow: none;
box-shadow: none;
}
#mode {
color: ${base16.base06};
padding: 0 4px;
}
#clock, #memory, #cpu, #temperature, #pulseaudio, #network, #mpd, #backlight, #battery, #custom-weather, #custom-konawall, #custom-gpg-status, #idle_inhibitor, #tray {
padding: 0 8px;
transition: none;
color: ${base16.base00};
}
.modules-left, .modules-center, .modules-right {
margin: 2px 4px;
border-radius: 1em;
}
.modules-left widget label {
margin: 0 4px;
border-radius: 1em;
}
.modules-left widget:first-child {
margin-left: 0px;
}
.modules-left widget:last-child {
margin-right: 0px;
}
#workspaces, #window, #clock, #tray {
background: ${hextorgba base16.base00 0.75};
}
#workspaces {
padding: 0px;
border-radius: 1em;
}
#window {
padding: 0 8px;
}
.modules-center widget:first-child label, .modules-right widget:first-child label, #workspaces button:first-child {
border-top-left-radius: 1em;
border-bottom-left-radius: 1em;
}
.modules-center widget:last-child label, .modules-right widget:last-child label, #workspaces button:last-child, #tray {
border-top-right-radius: 1em;
border-bottom-right-radius: 1em;
}
tooltip, #tray menu {
background: ${hextorgba base16.base00 0.75};
border-radius: 1em;
}
tooltip label {
color: ${base16.base07};
}
#window {
color: ${base16.base06};
border-bottom: 2px solid transparent;
}
window#waybar.empty #window {
opacity: 0;
}
#workspaces button {
color: ${base16.base06};
}
#workspaces button.focused {
color: ${base16.base07};
background: ${base16.base0D};
}
#workspaces button:hover {
transition: none;
box-shadow: inherit;
text-shadow: inherit;
background: ${base16.base06};
color: ${base16.base0C};
}
#tray { padding: 0 10px 0 8px }
#clock { color: ${base16.base07} }
#clock.arc { ${bcolor base16.base0B} }
#clock.miku { ${bcolor base16.base0C} }
#clock.hex { ${bcolor base16.base0F} }
#custom-konawall.enabled { ${bcolor base16.base0E} }
#custom-konawall.disabled { ${bcolor base16.base0D} }
#idle_inhibitor.activated { ${bcolor base16.base0E} }
#idle_inhibitor.deactivated { ${bcolor base16.base0D} }
#custom-gpg-status.enabled { ${bcolor base16.base0B} }
#custom-gpg-status.disabled { ${bcolor base16.base08} }
#network { ${bcolor base16.base0C} }
#custom-weather { ${bcolor base16.base00} }
#pulseaudio { ${bcolor base16.base06} }
#temperature { ${bcolor base16.base0B} }
#pulseaudio.muted { ${bcolor base16.base03} }
#battery { ${bcolor base16.base0C} }
#backlight { ${bcolor base16.base0D} }
#cpu { ${bcolor base16.base08} }
#memory { ${bcolor base16.base09} }
''

View file

@ -1,16 +1,10 @@
{ config, lib, pkgs, ... }:
let
base16 = config.kw.hexColors;
in
{
xdg.configFile."waybar/style.css".source = pkgs.waybar-style { inherit (config.kw.theme) base16; };
programs.waybar = {
enable = true;
style = import ./waybar.css.nix {
inherit base16;
inherit (lib) hextorgba;
font = config.kw.font;
};
settings = [{
modules-left = [ "sway/workspaces" "sway/mode" "sway/window" ];
modules-center = [ "clock" "clock#arc" "clock#miku" "clock#hex" ];

View file

@ -1,42 +1,5 @@
{ config, lib, ... }:
{ config, pkgs, ... }:
{
xdg.configFile."wofi/wofi.css".text = let base16 = config.kw.hexColors; in
''
#scroll, #input {
background: ${base16.base01};
}
window {
font-family: ${config.kw.font.name};
background: ${lib.hextorgba base16.base00 0.75};
border-radius: 1em;
font-size: ${config.kw.font.size_css};
color: ${base16.base07};
}
#outer-box {
margin: 1em;
}
#scroll {
border: 1px solid ${base16.base03};
}
#input {
border: 1px solid ${base16.base0C};
margin: 1em;
background: ${base16.base02};
color: ${base16.base04};
}
#entry {
border-bottom: 1px dashed ${base16.base04};
padding: .75em;
}
#entry:selected {
background-color: ${base16.base0D};
}
'';
xdg.configFile."wofi/wofi.css".source = pkgs.wofi-style { inherit (config.kw.theme) base16; };
}