some minor refactor

This commit is contained in:
2025-01-02 17:53:12 +01:00
parent d44ad67865
commit eb6727e458
20 changed files with 139 additions and 51 deletions

View File

@@ -0,0 +1,28 @@
{
lib,
config,
...
}: let
inherit (lib) mkOption types;
bgs = {
wallpaper_1 = "~/media/images/bg_1.jpg";
wallpaper_2 = "~/media/images/bg_2.jpg";
wallpaper_3 = "~/media/images/bg_3.jpg";
};
bgList = builtins.attrNames bgs;
in {
options.theme = {
background = {
lockscreen = mkOption {
type = types.enum bgList;
apply = name: bgs.${name};
example = "wallpaper_2";
};
desktop = mkOption {
type = types.enum bgList;
apply = name: bgs.${name};
example = "wallpaper_1";
};
};
};
}