diff --git a/modules/features/hypr/default.nix b/modules/features/hypr/default.nix index 92b55b3..286e5df 100644 --- a/modules/features/hypr/default.nix +++ b/modules/features/hypr/default.nix @@ -44,6 +44,7 @@ otter-launcher = self'.packages.otter-launcher; quickshell = self'.packages.quickshell; waybar = self'.packages.waybar; + way-edges = self'.packages.way-edges; }; }; wpaperd = let diff --git a/modules/features/way-edges/config.jsonc b/modules/features/way-edges/config.jsonc new file mode 100644 index 0000000..4bc0189 --- /dev/null +++ b/modules/features/way-edges/config.jsonc @@ -0,0 +1,60 @@ +{ + "allow-trailing-commas": true, + "widgets": [ + { + "type": "slider", + "edge": "right", + "position": "top", + "thickness": 30, + "length": "25%", + "margins": { + "top": "50%" + }, + "border-width": 4, + "border-color": "#cba6f7ff", + "fg-color": "#cba6f7bb", + "bg-color": "#31324466", + "fg-text-color": "#11111bff", + "bg-text-color": "#bac2dedd", + "transition-duration": 100, + "redraw-only-on-internal-update": true, + "radius": 10, // corner radius + "obtuse-angle": 90, // in degrees(90~180). controls how much curve the widget has + "scroll-unit": 0.005, + "pinnable": false, + "preset": { + "type": "speaker", + "animation-curve": "Linear", // mute animation + "mute-text-color": "#f38ba8ff", + "mute-color": "#f38ba8bb", + }, + }, + { + "type": "slider", + "edge": "right", + "position": "top", + "thickness": 30, + "length": "25%", + "margins": { + "top": "25%" + }, + "border-width": 4, + "border-color": "#f9e2afff", + "fg-color": "#f9e2afbb", + "bg-color": "#31324466", + "fg-text-color": "#11111bff", + "bg-text-color": "#bac2dedd", + "transition-duration": 100, + "redraw-only-on-internal-update": true, + "radius": 10, // corner radius + "obtuse-angle": 90, // in degrees(90~180). controls how much curve the widget has + "scroll-unit": 0.005, + "pinnable": false, + "preset": { + "type": "backlight", + "device": "intel_backlight", // this is the name of the device. Find it under `/sys/class/backlight/` It should be something like `nvidia_0`, `intel_0`, etc. + }, + }, + ] +} + diff --git a/modules/features/way-edges/default.nix b/modules/features/way-edges/default.nix new file mode 100644 index 0000000..0ae116e --- /dev/null +++ b/modules/features/way-edges/default.nix @@ -0,0 +1,20 @@ +{ + inputs, + moduleWithSystem, + ... +}: { + flake.nixosModules.way-edges = moduleWithSystem ({self', ...}: { + environment.systemPackages = with self'.packages; [ + way-edges + ]; + }); + perSystem = {pkgs, ...}: { + packages.way-edges = inputs.wrappers.lib.wrapPackage ({...}: { + inherit pkgs; + package = pkgs.way-edges; + flags = { + "--config-path" = ./config.jsonc; + }; + }); + }; +}