Skip to content

Group visibility levels: Popover for disallowed radio buttons

  • Please check this box if this contribution uses AI-generated content as outlined in the GitLab DCO & CLA

What does this MR do and why?

As explained here, we noticed that the visibility level radio buttons might be wrongly checked when visibility level are restricted. This might be misleading and confusing for non-admin users.

This MR proposes to show all visibility level (radio buttons) and disable them when the visibility level is not allowed. Additionally we propose the usage of a popover to let the non-admin user know why the visibility level is disallowed.

Changelog: fixed

🛠 with at Siemens

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

MR Checklist (@gerardo-navarro)

Screenshots or screen recordings

Scenario 1

  • Restricted visibility level: Public
  • Visibility level of current group (that is edited in the screenshot): Public
  • Visibility level of child project: Private.
  • Explanation: When editing the group, the radio button for the visibility level public is disabled, but it is also checked (selected) as the group has currently the visibility level public (before the group is edited). The visiblity levels private and internal are visible and selectable.
Before After
image image
image

Scenario 2

  • Restricted visibility level: Public
  • Visibility level of current group (that is edited in the screenshot): Public
  • Visibility level of child project: Internal.
  • Explanation: Same as in Scenario 1. The visiblity level private is not visible (and selectable) because the child project has the visibility level internal and a parent group cannot have lower visibility level than the child project.
Before After
image grafik
grafik
grafik

Scenario 3

  • Restricted visibility level: Public
  • Visibility level of current group (that is edited in the screenshot): Public
  • Visibility level of child project: Public.
  • Explanation: Same as in Scenario 1. Now the visibility level internal is not selectable as explained in Scenario 2.
Before After
image grafik
grafik
grafik

Scenario 4 (More restricted visibility levels)

  • Restricted visibility level: Public and Private
  • Visibility level of current group (that is edited in the screenshot): Public
  • Visibility level of child project: Private.
  • Explanation: Same as in Scenario 1. But, the visibility level Private is disabled and not selectable because it is restricted.
Before After
image grafik
grafik
grafik

Scenario 5 (More restricted visibility levels)

  • Restricted visibility level: Public and Private
  • Visibility level of current group (that is edited in the screenshot): Public
  • Visibility level of child project: Internal.
  • Explanation: Same as in Scenario 1 and Scenario 2.
Before After
image grafik
grafik
grafik

Scenario 6 (Restricted because of parent group)

  • Restricted visibility level: Public
  • Visibility level of current group (that is edited in the screenshot): Public
  • Visibility level of parent group: Internal.
  • Explanation: Same as in Scenario 1. But, the visibility level Private is disabled and not selectable because it is restricted. The visibility level Public is also disabled because it is restricted and the parent group has the visibility level internal, see popover in screenshot.
Before After
grafik grafik
grafik

Scenario 7 (Restricted because of parent group)

  • Restricted visibility level: None
  • Visibility level of current group (that is edited in the screenshot): Internal
  • Visibility level of parent group: Internal.
  • Explanation: Same as in Scenario 6. The visibility level Public is also disabled because the parent group has the visibility level internal, see popover in screenshot.
Before After
grafik grafik
grafik
Screenshot of old scenarios (DEPRECATED)

Scenario 1

The current group (that is edited in the screenshot) has the visibility level public and a child project has the visibility level internal. When editing the group, the radio button for the visibility level public is disabled, but it is also checked (selected) as the group has currently the visibility level public (before the group is edited). The visiblity level private is also disabled because the child project has the visibility level internal and a parent group cannot have lower visibility level than the child project.

Before After
image image

Scenario 2

The current group (edited in the screenshot) has the visibility level public and a sub project has the visibility level private. When editing the group than radio button for the visibility level public is disabled, but it is checked (selected) as the group has currently the visibility level public (before the group is edited). When group has the visibility level public and a sub project has the visibility level public. The radio buttons for the visibility levels are allowed.

Without this MR (see screenshot in column "Before"), the visibility levels Public and Private would not be visible and the radio button for the visibility level Internal is checked which is misleading, see #455668 (closed).

Before After
image image

Scenario 3

In this screenshot, we want to create a new group and the radio button for the visibility level public is disabled because it is restricted by the admin.

Before After
image image

How to set up and validate locally

  1. Follow the steps described in the issue
  2. Change the visibility of child projects to reproduce the different scenarios described here

Ref #455668 (closed)

Edited by Gerardo Navarro

Merge request reports