Add stylix.imageScalingMode support to all modules except: - hyprlock - hyprpaper - kde - lightdm - sway Closes: https://github.com/danth/stylix/issues/677 Link: https://github.com/danth/stylix/pull/678 Reviewed-by: NAHO <90870942+trueNAHO@users.noreply.github.com> Reviewed-by: Daniel Thwaites <danth@danth.me>
17 lines
457 B
Nix
17 lines
457 B
Nix
{ config, lib, ... }:
|
|
|
|
{
|
|
options.stylix.targets.wpaperd.enable = config.lib.stylix.mkEnableTarget "wpaperd" true;
|
|
|
|
config = lib.mkIf (config.stylix.enable && config.stylix.targets.wpaperd.enable) {
|
|
programs.wpaperd.settings.any = {
|
|
path = "${config.stylix.image}";
|
|
mode = let
|
|
inherit (config.stylix) imageScalingMode;
|
|
in
|
|
if imageScalingMode == "fill"
|
|
then "fit"
|
|
else imageScalingMode;
|
|
};
|
|
};
|
|
}
|