name: 'User Privacy Core'
description: 'Configures user privacy settings to restrict username visibility to administrators'
type: 'Privacy'

recipes:
  - core/recipes/administrator_role

install:
  - view_usernames

config:
  actions:
# TODO Uncomment these after this config action is available.
# https://www.drupal.org/project/drupal/issues/3500184
#    user.role.anonymous:
#      revokePermission: 'view usernames'
#
#    user.role.authenticated:
#      revokePermission: 'view usernames'

    user.role.administrator:
      grantPermissions:
        - 'view usernames'
