xdg.portal.config.niri replaces niri's bundled portals.conf entirely
niri-flake ships its portal preferences through xdg.portal.configPackages (niri-portals.conf in share/xdg-desktop-portal: default=gnome;gtk, Access/Notification=gtk, Secret=gnome-keyring). Setting xdg.portal.config.niri writes /etc/xdg/xdg-desktop-portal/niri-portals.conf, which is found first and fully replaces the bundled file, so copy those defaults in when you only want to override one interface such as FileChooser = termfilechooser. For xdg-desktop-portal-termfilechooser on NixOS, point cmd at the absolute ${pkg}/share/xdg-desktop-portal-termfilechooser/yazi-wrapper.sh, set env=TERMCMD=ghostty --title=termfilechooser -e (ghostty --title pins the title so a niri open-floating rule matching ^termfilechooser$ works even though yazi sets titles).