nix/modules/home/theming/stylix.nix

58 lines
1.2 KiB
Nix
Raw Normal View History

2024-12-25 23:55:11 +01:00
{ config, lib, inputs, pkgs, ... }:
with lib;
let
cfg = config.settings.theming.stylix;
in {
options = {
settings.theming.stylix.enable = lib.mkOption {
type = lib.types.bool;
description = ''
Enable stylix configuration
'';
};
2025-01-09 17:14:10 +01:00
settings.theming.stylix.wallpaper = lib.mkOption {
type = lib.types.enum ["wallpaper-2" "kiiwy"];
description = ''
Choose wallpaper
'';
};
settings.theming.stylix.theme = lib.mkOption {
type = lib.types.string;
description = ''
Choose theme name. Use "theme" to use them based on wallpaper generation
'';
};
2024-12-25 23:55:11 +01:00
};
imports = [
inputs.stylix.homeManagerModules.stylix
];
config = mkIf cfg.enable {
stylix.enable = true;
2025-01-09 17:14:10 +01:00
stylix.image = ../../../assets/${cfg.wallpaper};
2024-12-25 23:55:11 +01:00
stylix.polarity = "dark";
2025-01-09 17:14:10 +01:00
stylix.base16Scheme = if (cfg.wallpaper == "theme") then
theme
else
"${pkgs.base16-schemes}/share/themes/da-one-ocean.yaml";
2024-12-25 23:55:11 +01:00
stylix.autoEnable = true;
stylix.cursor = {
package = pkgs.phinger-cursors;
name = "phinger-cursors-dark";
size = 24;
};
stylix.fonts.sizes.applications = 10;
};
}