{ config, lib, pkgs, ... }@inputs:

let
  cfg = config.sydnix.niri;
in {
  options.sydnix.niri.enable =
    lib.mkEnableOption "Niri";

  config = lib.mkIf cfg.enable {
    nixpkgs.overlays = [ inputs.niri.overlays.niri ];

    programs.niri = {
      enable = true;
      package = pkgs.niri-unstable;
    };

    security.pam.services.swaylock = {};
  };
}

