summaryrefslogtreecommitdiff
path: root/pkgs/astal
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--pkgs/astal/default.nix62
-rw-r--r--pkgs/astal/theme.nix41
2 files changed, 50 insertions, 53 deletions
diff --git a/pkgs/astal/default.nix b/pkgs/astal/default.nix
index dc19a19..a7e86fe 100644
--- a/pkgs/astal/default.nix
+++ b/pkgs/astal/default.nix
@@ -6,36 +6,38 @@
runCommand,
dart-sass,
...
-}:
-
-let
+}: let
apkgs = inputs.astal.packages.${system};
scss = "${dart-sass}/bin/sass";
- theme = import ./theme.nix { inherit options; };
+ theme = import ./theme.nix {inherit options;};
in
-inputs.astal.lib.mkLuaPackage {
- pkgs = pkgs // {
- # use luajit
- lua = pkgs.luajit;
- };
- src = runCommand "src" {} ''
- mkdir -p $out
- cp -r ${./src}/{*.lua,widget} $out/
- cp -r ${./src}/style/* .
- echo '${theme}' > theme.scss
- cat theme.scss style.scss widget/* > main.scss
- ${scss} main.scss $out/main.css
- '';
- name = "astal";
- extraPackages = (with apkgs; [
- battery
- hyprland
- mpris
- network
- notifd
- tray
- wireplumber
- ]) ++ (with pkgs; [
- networkmanager
- ]);
-}
+ inputs.astal.lib.mkLuaPackage {
+ pkgs =
+ pkgs
+ // {
+ # use luajit
+ lua = pkgs.luajit;
+ };
+ src = runCommand "src" {} ''
+ mkdir -p $out
+ cp -r ${./src}/{*.lua,widget} $out/
+ cp -r ${./src}/style/* .
+ echo '${theme}' > theme.scss
+ cat theme.scss style.scss widget/* > main.scss
+ ${scss} main.scss $out/main.css
+ '';
+ name = "astal";
+ extraPackages =
+ (with apkgs; [
+ battery
+ hyprland
+ mpris
+ network
+ notifd
+ tray
+ wireplumber
+ ])
+ ++ (with pkgs; [
+ networkmanager
+ ]);
+ }
diff --git a/pkgs/astal/theme.nix b/pkgs/astal/theme.nix
index 1efd1fe..2802d6c 100644
--- a/pkgs/astal/theme.nix
+++ b/pkgs/astal/theme.nix
@@ -1,33 +1,28 @@
-{
- options,
- ...
-}:
+{options, ...}: ''
-''
-
-$fg: #${options.theme.colors.fg};
-$bg: #${options.theme.colors.bg};
+ $fg: #${options.theme.colors.fg};
+ $bg: #${options.theme.colors.bg};
-$surface-fg: #${options.theme.colors.surface.fg};
-$surface-bg: #${options.theme.colors.surface.bg};
+ $surface-fg: #${options.theme.colors.surface.fg};
+ $surface-bg: #${options.theme.colors.surface.bg};
-$hover-fg: #${options.theme.colors.hover.fg};
-$hover-bg: #${options.theme.colors.hover.bg};
+ $hover-fg: #${options.theme.colors.hover.fg};
+ $hover-bg: #${options.theme.colors.hover.bg};
-$primary: #${options.theme.colors.primary};
-$success: #${options.theme.colors.success};
-$warning: #${options.theme.colors.warning};
-$error: #${options.theme.colors.error};
+ $primary: #${options.theme.colors.primary};
+ $success: #${options.theme.colors.success};
+ $warning: #${options.theme.colors.warning};
+ $error: #${options.theme.colors.error};
-$border: ${toString options.theme.borderWidth}px;
+ $border: ${toString options.theme.borderWidth}px;
-$inner-radius: ${toString options.theme.innerRadius}px;
-$outer-radius: ${toString options.theme.outerRadius}px;
+ $inner-radius: ${toString options.theme.innerRadius}px;
+ $outer-radius: ${toString options.theme.outerRadius}px;
-$inner-gap: ${toString options.theme.innerGap}px;
-$outer-gap: ${toString options.theme.outerGap}px;
+ $inner-gap: ${toString options.theme.innerGap}px;
+ $outer-gap: ${toString options.theme.outerGap}px;
-$font-name: "${options.theme.font.regular}", "${options.theme.font.monospace}";
-$font-size: ${toString options.theme.font.size}px;
+ $font-name: "${options.theme.font.regular}", "${options.theme.font.monospace}";
+ $font-size: ${toString options.theme.font.size}px;
''