{ lib, config, pkgs, ... }: let inherit (lib) mkIf; cfg = config.desktops.wayland; in { config = mkIf cfg.enable { xdg.portal = { enable = true; extraPortals = with pkgs; [ xdg-desktop-portal-gtk ]; config.common = { default = ["gtk"]; "org.freedesktop.impl.portal.Secret" = ["gnome-keyring"]; }; }; programs.xwayland.enable = true; }; }