Z7BQUZ2VVUNF5ME5QWKITLDG343SX3DQAQDTPQ36T4LIY6UAFVWQC
CM2R5CCC4BV75P2MBA4X6OS2H6GQ5BAS34LSU6Y5X3SVKBAFT24AC
2EFJUR2TVLHO4R4YRZFLOJKC742HPFI5MOA7II3Y3Z3KOHDNE5JAC
532JIID6XB4NFSIFUA64VEBKWSEJB4AY5OUBIEFUDMWXO7UAZW2QC
BYZGRIFZY253OFK442SR6X743U4LAX4NLFBQ4XPKXEDPPXNNUM4AC
ZGEGHEOD2S77CSNWOOFVB7Q3RGOU3WOWDOXJ4S2LKAS2JMS3UAZAC
EVVP46IQ4U6JEDWVJ4D6KT77ABOMY7XKIO2ITX4DHJDRTGTYCUTQC
JOK7DA5XBOK2MIVR7ORTSAEMQ6U5642I537IGUYBX67DPFF5QJ3QC
TXA66OLAOYNGEDRBC4SKWDZPLBZXUU7WHDIAYN4TXGEJR6WIJOIQC
# Theme adapted from https://github.com/catppuccin/qutebrowser/blob/6737f1c36a9d05be05b7961945e7028c0f70831f/setup.py
p: {
colors = {
completion = {
category = {
bg = p.base;
fg = p.green;
border = {
bottom = p.mantle;
top = p.overlay2;
};
};
even.bg = p.mantle;
odd.bg = p.crust;
fg = p.subtext0;
item = {
selected = {
bg = p.surface2;
fg = p.text;
border = {
bottom = p.surface2;
top = p.surface2;
};
match.fg = p.rosewater;
};
};
match.fg = p.text;
scrollbar = {
bg = p.crust;
fg = p.surface2;
};
};
downloads = {
bar.bg = p.base;
error.bg = p.base;
start.bg = p.base;
stop.bg = p.base;
error.fg = p.red;
start.fg = p.blue;
stop.fg = p.green;
system.fg = "none";
system.bg = "none";
};
hints.match.fg = p.subtext1;
keyhint = {
bg = p.mantle;
fg = p.text;
suffix.fg = p.subtext1;
};
messages = {
error.bg = p.overlay0;
info.bg = p.overlay0;
warning.bg = p.overlay0;
error.border = p.mantle;
info.border = p.mantle;
warning.border = p.mantle;
error.fg = p.red;
info.fg = p.text;
warning.fg = p.peach;
};
prompts = {
bg = p.mantle;
border = "1px solid ${p.overlay0}";
fg = p.text;
selected.bg = p.surface2;
selected.fg = p.rosewater;
};
statusbar = {
normal.bg = p.base;
insert.bg = p.crust;
command.bg = p.base;
caret.bg = p.base;
caret.selection.bg = p.base;
progress.bg = p.base;
passthrough.bg = p.base;
normal.fg = p.text;
insert.fg = p.rosewater;
command.fg = p.text;
passthrough.fg = p.peach;
caret.fg = p.peach;
caret.selection.fg = p.peach;
url.error.fg = p.red;
url.fg = p.text;
url.hover.fg = p.sky;
url.success.http.fg = p.teal;
url.success.https.fg = p.green;
url.warn.fg = p.yellow;
private.bg = p.mantle;
private.fg = p.subtext1;
command.private.bg = p.base;
command.private.fg = p.subtext1;
};
tabs = {
bar.bg = p.crust;
even.bg = p.surface2;
odd.bg = p.surface1;
even.fg = p.overlay2;
odd.fg = p.overlay2;
indicator.error = p.red;
indicator.system = "none";
selected.even.bg = p.base;
selected.odd.bg = p.base;
selected.even.fg = p.text;
selected.odd.fg = p.text;
};
contextmenu = {
menu.bg = p.base;
menu.fg = p.text;
disabled.bg = p.mantle;
disabled.fg = p.overlay0;
selected.bg = p.overlay0;
selected.fg = p.rosewater;
};
};
hints.border = "1px solid ${p.mantle}";
}
{lib}: theme: let
inherit (builtins) isAttrs mapAttrs concatStringsSep;
inherit (lib) flatten removePrefix;
recurse = path: f: val:
if isAttrs val
then mapAttrs (n: v: recurse (path + "." + n) f v) val
else f path val;
recurse' = recurse "theme";
helixBase64 = {
# TODO: Cleaner, more idiomatic solution
palette = {
base00 = theme.primary.background;
base01 = theme.dark.gray;
base02 = theme.bright.gray;
base03 = theme.bright.black;
base04 = theme.bright.white;
base05 = theme.primary.foreground;
base06 = theme.bright.white;
base07 = theme.bright.white;
base08 = theme.bright.red;
base09 = theme.bright.yellow;
base0A = theme.bright.yellow;
base0B = theme.bright.green;
base0C = theme.bright.cyan;
base0D = theme.bright.blue;
base0E = theme.bright.magenta;
base0F = theme.bright.white;
};
"ui.background" = {bg = "base00";};
"ui.virtual" = "base03";
"ui.menu" = {
fg = "base05";
bg = "base01";
};
"ui.menu.selected" = {
fg = "base01";
bg = "base04";
};
"ui.linenr" = {
fg = "base03";
bg = "base01";
};
"ui.popup" = {bg = "base01";};
"ui.window" = {bg = "base01";};
"ui.linenr.selected" = {
fg = "base04";
bg = "base01";
modifiers = ["bold"];
};
"ui.selection" = {bg = "base02";};
"comment" = {
fg = "base03";
modifiers = ["italic"];
};
"ui.statusline" = {
fg = "base04";
bg = "base01";
};
"ui.cursor" = {
fg = "base04";
modifiers = ["reversed"];
};
"ui.cursor.primary" = {
fg = "base05";
modifiers = ["reversed"];
};
"ui.text" = "base05";
"operator" = "base05";
"ui.text.focus" = "base05";
"variable" = "base08";
"constant.numeric" = "base09";
"constant" = "base09";
"attributes" = "base09";
"type" = "base0A";
"ui.cursor.match" = {
fg = "base0A";
modifiers = ["underlined"];
};
"string" = "base0B";
"variable.other.member" = "base0B";
"constant.character.escape" = "base0C";
"function" = "base0D";
"constructor" = "base0D";
"special" = "base0D";
"keyword" = "base0E";
"label" = "base0E";
"namespace" = "base0E";
"ui.help" = {
fg = "base06";
bg = "base01";
};
"markup.heading" = "base0D";
"markup.list" = "base08";
"markup.bold" = {
fg = "base0A";
modifiers = ["bold"];
};
"markup.italic" = {
fg = "base0E";
modifiers = ["italic"];
};
"markup.link.url" = {
fg = "base09";
modifiers = ["underlined"];
};
"markup.link.text" = "base08";
"markup.quote" = "base0C";
"markup.raw" = "base0B";
"diff.plus" = "base0B";
"diff.delta" = "base09";
"diff.minus" = "base08";
"diagnostic" = {modifiers = ["underlined"];};
"ui.gutter" = {bg = "base01";};
"info" = "base0D";
"hint" = "base03";
"debug" = "base03";
"warning" = "base09";
"error" = "base08";
};
in
theme
// {
noHash = recurse' (_: color: removePrefix "#" color) theme;
apps =
{
helix = helixBase64;
}
// (
if theme ? apps
then theme.apps
else {}
);
}
theme: let
bg = theme.dark.black;
fg = theme.bright.white;
in {
colors = {
downloads = {
bar.bg = bg;
start.bg = theme.dark.blue;
stop.bg = theme.bright.green;
};
tabs = rec {
bar.bg = bg;
odd.bg = bg;
odd.fg = fg;
even = odd;
selected = rec {
odd.bg = theme.bright.white;
odd.fg = theme.dark.black;
even = odd;
};
indicator.start = theme.dark.blue;
indicator.stop = theme.bright.green;
};
statusbar = rec {
url = {
inherit fg;
error.fg = theme.bright.red;
warn.fg = theme.bright.yellow;
hover.fg = theme.bright.cyan;
success.http.fg = fg;
success.https.fg = fg;
};
normal.bg = bg;
normal.fg = fg;
private.bg = theme.dark.magenta;
private.fg = bg;
insert.bg = theme.dark.green;
insert.fg = bg;
passthrough.bg = theme.dark.blue;
passthrough.fg = bg;
command = {
inherit bg fg;
private = {inherit bg fg;};
};
};
completion = rec {
inherit fg;
category.bg = theme.bright.black;
category.fg = fg;
odd.bg = bg;
even = odd;
match.fg = theme.bright.red;
item.selected = {
inherit match;
bg = fg;
fg = bg;
border.top = fg;
border.bottom = fg;
};
};
};
}
theme: {
# TODO: Cleaner, more idiomatic solution
palette = {
base00 = theme.primary.background;
base01 = theme.dark.gray;
base02 = theme.bright.gray;
base03 = theme.bright.black;
base04 = theme.bright.white;
base05 = theme.primary.foreground;
base06 = theme.bright.white;
base07 = theme.bright.white;
base08 = theme.bright.red;
base09 = theme.bright.yellow;
base0A = theme.bright.yellow;
base0B = theme.bright.green;
base0C = theme.bright.cyan;
base0D = theme.bright.blue;
base0E = theme.bright.magenta;
base0F = theme.bright.white;
};
"ui.background" = {bg = "base00";};
"ui.virtual" = "base03";
"ui.menu" = {
fg = "base05";
bg = "base01";
};
"ui.menu.selected" = {
fg = "base01";
bg = "base04";
};
"ui.linenr" = {
fg = "base03";
bg = "base01";
};
"ui.popup" = {bg = "base01";};
"ui.window" = {bg = "base01";};
"ui.linenr.selected" = {
fg = "base04";
bg = "base01";
modifiers = ["bold"];
};
"ui.selection" = {bg = "base02";};
"comment" = {
fg = "base03";
modifiers = ["italic"];
};
"ui.statusline" = {
fg = "base04";
bg = "base01";
};
"ui.cursor" = {
fg = "base04";
modifiers = ["reversed"];
};
"ui.cursor.primary" = {
fg = "base05";
modifiers = ["reversed"];
};
"ui.text" = "base05";
"operator" = "base05";
"ui.text.focus" = "base05";
"variable" = "base08";
"constant.numeric" = "base09";
"constant" = "base09";
"attributes" = "base09";
"type" = "base0A";
"ui.cursor.match" = {
fg = "base0A";
modifiers = ["underlined"];
};
"string" = "base0B";
"variable.other.member" = "base0B";
"constant.character.escape" = "base0C";
"function" = "base0D";
"constructor" = "base0D";
"special" = "base0D";
"keyword" = "base0E";
"label" = "base0E";
"namespace" = "base0E";
"ui.help" = {
fg = "base06";
bg = "base01";
};
"markup.heading" = "base0D";
"markup.list" = "base08";
"markup.bold" = {
fg = "base0A";
modifiers = ["bold"];
};
"markup.italic" = {
fg = "base0E";
modifiers = ["italic"];
};
"markup.link.url" = {
fg = "base09";
modifiers = ["underlined"];
};
"markup.link.text" = "base08";
"markup.quote" = "base0C";
"markup.raw" = "base0B";
"diff.plus" = "base0B";
"diff.delta" = "base09";
"diff.minus" = "base08";
"diagnostic" = {modifiers = ["underlined"];};
"ui.gutter" = {bg = "base01";};
"info" = "base0D";
"hint" = "base03";
"debug" = "base03";
"warning" = "base09";
"error" = "base08";
}
{lib}: theme: let
inherit (builtins) isAttrs mapAttrs concatStringsSep;
inherit (lib) flatten removePrefix;
recurse = path: f: val:
if isAttrs val
then mapAttrs (n: v: recurse (path + "." + n) f v) val
else f path val;
recurse' = recurse "theme";
in
theme
// {
noHash = recurse' (_: color: removePrefix "#" color) theme;
apps =
{
helix = import ./helix.nix theme;
qutebrowser = import ./qutebrowser.nix theme;
}
// (theme.apps or {});
}
tabs = rec {
bar.bg = bg;
odd.bg = bg;
odd.fg = fg;
even = odd;
selected = rec {
odd.bg = theme.bright.white;
odd.fg = theme.dark.black;
even = odd;
};
# TODO: The terminal shouldn't be hardcoded
editor.command = ["alacritty" "-c" "hx" "{file}"];
normal.bg = bg;
normal.fg = fg;
private.bg = theme.dark.magenta;
private.fg = bg;
insert.bg = theme.dark.green;
insert.fg = bg;
passthrough.bg = theme.dark.blue;
passthrough.fg = bg;
command = {
inherit bg fg;
private = {inherit bg fg;};
};
content = {
canvas_reading = true;
blocking.method = "both";
blocking.whitelist = ["*.amplitude.com" "amplitude.com"];
tabs = {
indicator.width = 3;
};
# TODO: The terminal shouldn't be hardcoded
editor.command = ["kitty" "hx" "{file}"];
fonts = {
# default_family = "Cozette";
# default_size = "13px";
default_family = "Iosevka";
default_size = "13px";
};
content = {
canvas_reading = true;
blocking.method = "both";
blocking.whitelist = ["*.amplitude.com" "amplitude.com"];
};
};