Fixes: 7ffb31da69 ("treewide: use mkTarget (batch 2) (#1362)")
Link: https://github.com/nix-community/stylix/pull/1370
Reviewed-by: awwpotato <awwpotato@voidq.com>
Tested-by: repparw <45952970+repparw@users.noreply.github.com>
48 lines
1.3 KiB
Nix
48 lines
1.3 KiB
Nix
{ mkTarget, lib, ... }:
|
|
mkTarget {
|
|
name = "tofi";
|
|
humanName = "Tofi";
|
|
|
|
configElements = [
|
|
(
|
|
{ fonts }:
|
|
{
|
|
programs.tofi.settings = {
|
|
font = fonts.monospace.name;
|
|
font-size = toString fonts.sizes.popups;
|
|
};
|
|
}
|
|
)
|
|
(
|
|
{ colors, opacity }:
|
|
{
|
|
programs.tofi.settings =
|
|
with colors.withHashtag;
|
|
let
|
|
opacity' = lib.toHexString (
|
|
((builtins.ceil (opacity.popups * 100)) * 255) / 100
|
|
);
|
|
background = base00 + opacity';
|
|
foreground = base05;
|
|
darkForeground = base04 + opacity';
|
|
selection = base03 + opacity';
|
|
in
|
|
{
|
|
background-color = background;
|
|
outline-color = darkForeground;
|
|
border-color = foreground;
|
|
text-color = foreground;
|
|
prompt-color = base0A;
|
|
prompt-background = background;
|
|
placeholder-color = selection;
|
|
input-background = background;
|
|
default-result-background = background;
|
|
selection-color = selection;
|
|
selection-background = background;
|
|
border-width = lib.mkDefault 4;
|
|
outline-width = lib.mkDefault 2;
|
|
};
|
|
}
|
|
)
|
|
];
|
|
}
|