Problem/Motivation

Follow-up for #987978-57: Move "administrator role" setting to new Role Settings form:

we probably want to visually promote the value to the role overview page. Sort of the "settings summary" pattern. Or a whole new column in that table (there's plenty of space for it) to indicate anything special about each role. Not sure what the column should be labeled, what values it would contain, etc. But if I'm scanning my collection of roles, it'd be nice to know which one(s) are the admin role(s)

Steps to reproduce

  1. Install core (any version D8/9):
  2. Visit /admin/people/roles
  3. Wonder which one is the 'Administrator role'

Proposed resolution

Somehow indicate which role at /admin/people/roles is the 'Administrator role'.

Remaining tasks

  1. Decide on the UI
  2. Implement
  3. Add / update tests
  4. Reviews / refinements
  5. RTBC
  6. Commit

User interface changes

TBD.

API changes

Unlikely.

Data model changes

None.

Release notes snippet

TBD.

Comments

dww created an issue. See original summary.

aaronmchale’s picture

We briefly discussed this at #3228187: Drupal Usability Meeting 2021-08-20 today.

I brought it up to get some initial thoughts on this issue.

One of the main initial reasons for this issue is because right now it's technically possible for more than one role to be marked as the "admin role", but in the UI we only ever show one role (in the form of a dropdown on the new Role Settings form). When #3229029: Introduce a role.settings config object and move 'Administrator role' out of the Role entity config is fixed, this specific problem will be resolved.

With that in mind we weren't able to agree on any initial recommendations, but one idea that was proposed was to simply add some help text above the role list, either stating which role is the admin role, or just linking to the Role Settings.

We felt that whatever option is chosen here, should align with the idea that the role settings screen opens up the possibility of having other "dynamically defined roles" (e.g. Anonymous, Authenticated, etc); So we felt that an option that - much like the Role Settings form - is extensible and can be expanded to facilitate these other roles, would be the best outcome here.

We also considered what it would look like if the Administrator role had a red asterisk next to it (like required form fields do), with some help text. However, we felt that this idea didn't align with the statement above, that is to say we did feel that was an option which could be easily extended for other roles.

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.0-rc1 was released on November 26, 2021, which means new developments and disruptive changes should now be targeted for the 9.4.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.4.x-dev » 9.5.x-dev

Drupal 9.4.0-alpha1 was released on May 6, 2022, which means new developments and disruptive changes should now be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.5.x-dev » 10.1.x-dev

Drupal 9.5.0-beta2 and Drupal 10.0.0-beta2 were released on September 29, 2022, which means new developments and disruptive changes should now be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 10.1.x-dev » 11.x-dev

Drupal core is moving towards using a “main” branch. As an interim step, a new 11.x branch has been opened, as Drupal.org infrastructure cannot currently fully support a branch named main. New developments and disruptive changes should now be targeted for the 11.x branch, which currently accepts only minor-version allowed changes. For more information, see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

liam morland’s picture

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.