treewide: use mkTarget (batch 2) (#1362)
Link: https://github.com/nix-community/stylix/pull/1362 Reviewed-by: Flameopathic <64027365+Flameopathic@users.noreply.github.com> Reviewed-by: NAHO <90870942+trueNAHO@users.noreply.github.com>
This commit is contained in:
parent
8dd18dd395
commit
7ffb31da69
33 changed files with 1355 additions and 1238 deletions
|
|
@ -1,14 +1,21 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
cfg = config.stylix.targets.lightdm;
|
||||
in
|
||||
{
|
||||
options.stylix.targets.lightdm = {
|
||||
enable = config.lib.stylix.mkEnableTarget "LightDM" true;
|
||||
mkTarget,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
mkTarget {
|
||||
name = "lightdm";
|
||||
humanName = "LightDM";
|
||||
|
||||
extraOptions = {
|
||||
useWallpaper = config.lib.stylix.mkEnableWallpaper "LightDM" true;
|
||||
};
|
||||
|
||||
config.services.xserver.displayManager.lightdm.background = lib.mkIf (
|
||||
config.stylix.enable && cfg.enable && cfg.useWallpaper
|
||||
) config.stylix.image;
|
||||
configElements =
|
||||
{ cfg, image }:
|
||||
{
|
||||
services.xserver.displayManager.lightdm.background =
|
||||
lib.mkIf cfg.useWallpaper image;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue