Skip to content

Improve shared runner toggle interactions

What does this MR do and why?

Description

This change updates the shared runners settings by removing some elements and improving their loading state.

It adds a more prominent warning for users when their settings cannot be changed.

Changelog: changed

Related to #349794 (closed), #358778 (closed), #330177 (closed)

Why this change?

I started with the intention of adding a few tests to this feature, but I found the current interaction clunky, especially, the loading state.

I took the opportunity to improve these toggles with some newer states provided by gl-toggle.

Screenshots or screen recordings

before after
2022-04-26_16.25.17 2022-04-26_16.15.02
image image

How to set up and validate locally

Given two groups, one group and one subgroup.

Group can be changed

  1. Visit Group -> CI/CD Settings
  2. Enable/disable the toggle in the group to check how the data is stored.

Subgroup cannot be changed

  1. Enable the "Shared runners" toggle in the group
  2. Visit Subgroup -> CI/CD Settings
  3. Confirm the form is disabled in the subgroup.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Miguel Rincon

Merge request reports