modules/theme/gtk: update icon theme, enable by default if theme is enabled
This commit is contained in:
parent
c5fd112c30
commit
b06627bbb8
1 changed files with 12 additions and 10 deletions
|
@ -6,13 +6,17 @@
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (builtins) pathExists;
|
inherit (builtins) pathExists;
|
||||||
inherit (lib) mkIf mkOption mkEnableOption;
|
inherit (lib) mkIf mkOption;
|
||||||
inherit (lib.types) package str;
|
inherit (lib.types) bool package str;
|
||||||
|
|
||||||
cfg = config.theme.gtk;
|
cfg = config.theme.gtk;
|
||||||
in {
|
in {
|
||||||
options.theme.gtk = {
|
options.theme.gtk = {
|
||||||
enable = mkEnableOption "enable GTK theming options";
|
enable = mkOption {
|
||||||
|
type = bool;
|
||||||
|
description = "enable GTK theming options";
|
||||||
|
default = config.theme.enable;
|
||||||
|
};
|
||||||
theme = {
|
theme = {
|
||||||
name = mkOption {
|
name = mkOption {
|
||||||
type = str;
|
type = str;
|
||||||
|
@ -31,24 +35,22 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
iconTheme = {
|
iconTheme = {
|
||||||
name = mkOption {
|
name = mkOption {
|
||||||
type = str;
|
type = str;
|
||||||
description = "The name for the icon theme that will be used for GTK programs";
|
description = "The name for the icon theme that will be used for GTK programs";
|
||||||
default = "Papirus-Dark";
|
default = "kora";
|
||||||
};
|
};
|
||||||
|
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = package;
|
type = package;
|
||||||
description = "The GTK icon theme to be used";
|
description = "The GTK icon theme to be used";
|
||||||
default = pkgs.catppuccin-papirus-folders.override {
|
default = pkgs.kora-icon-theme;
|
||||||
accent = "lavender";
|
|
||||||
flavor = "macchiato";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
config = {
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
assertions = [
|
assertions = [
|
||||||
(let
|
(let
|
||||||
themePath = cfg.theme.package + /share/themes + "/${cfg.theme.name}";
|
themePath = cfg.theme.package + /share/themes + "/${cfg.theme.name}";
|
||||||
|
|
Loading…
Reference in a new issue