summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/home/theme.nix25
-rw-r--r--modules/hosts/hp-envy-office/home.nix4
2 files changed, 22 insertions, 7 deletions
diff --git a/modules/home/theme.nix b/modules/home/theme.nix
index b12f866..4128e1d 100644
--- a/modules/home/theme.nix
+++ b/modules/home/theme.nix
@@ -1,15 +1,30 @@
-{ config, lib, pkgs, ... }: {
+{ config, lib, pkgs, ... }:
+let
+ transformColorValue = color :
+ if color == "Green" then "Mint-Y"
+ else if color == "Dark-Green" then "Mint-Y-Dark"
+ else "Mint-Y-${color}"
+ ;
+in {
options = {
theme.mint = {
enable = lib.mkEnableOption "enables mint theme";
# TODO add theme.dark option instead of specifying Dark-Color
theme.color = lib.mkOption {
- type = lib.types.str;
+ type = lib.types.enum [
+ "Aqua" "Blue" "Green" "Grey" "Orange" "Pink" "Purple" "Red"
+ "Sand" "Teal" "Dark-Aqua" "Dark-Blue" "Dark-Green"
+ "Dark-Grey" "Dark-Orange" "Dark-Pink" "Dark-Purple"
+ "Dark-Red" "Dark-Sand" "Dark-Teal"
+ ];
default = "Dark-Aqua";
description = "mint-y theme color eg. 'Dark-Aqua' or 'Red'";
};
icons.color = lib.mkOption {
- type = lib.types.str;
+ type = lib.types.enum [
+ "Aqua" "Blue" "Green" "Grey" "Orange" "Pink" "Purple" "Red"
+ "Sand" "Teal"
+ ];
default = "Aqua";
description = "mint-y icons color eg. 'Aqua' or 'Red'";
};
@@ -21,11 +36,11 @@
enable = true;
theme = lib.mkIf config.theme.mint.enable {
package = pkgs.mint-themes;
- name = "Mint-Y-${config.theme.mint.theme.color}";
+ name = transformColorValue config.theme.mint.theme.color;
};
iconTheme = lib.mkIf config.theme.mint.enable {
package = pkgs.mint-y-icons;
- name = "Mint-Y-${config.theme.mint.icons.color}";
+ name = transformColorValue config.theme.mint.icons.color;
};
font = {
package = pkgs.inter;
diff --git a/modules/hosts/hp-envy-office/home.nix b/modules/hosts/hp-envy-office/home.nix
index 1df168c..ee56dc6 100644
--- a/modules/hosts/hp-envy-office/home.nix
+++ b/modules/hosts/hp-envy-office/home.nix
@@ -1,7 +1,7 @@
{ ... }: {
imports = [ ../../home ];
- theme.mint.theme.color = "Dark-Red";
- theme.mint.icons.color = "Red";
+ theme.mint.theme.color = "Dark-Green";
+ theme.mint.icons.color = "Green";
wallpapers.enable = true;
}