Add unlimited members alert to Project/Group members page
What does this MR do and why?
Implements solution to https://gitlab.com/gitlab-org/gitlab/-/issues/376224.
This MR adds a new alert that will appear on the Group and Project members page.
Updates
Alert was moved to appear above the breadcrumbs based on !110748 (comment 1291487675). Screenshots have been updated.
Display Conditions
During development, the display conditions were fine tuned (see https://gitlab.com/gitlab-org/gitlab/-/issues/376224#note_1281287346).
The alert will be displayed when the following conditions are met:
- The namespace is private and on a trial
- The user is an owner of the namespace
- If in a Project, the user can admin the project
- The user has not dismissed the alert
Once the alert is visible to the user / namespace owner, it will stop showing when:
- The user dismisses the alert
- The namespace is no longer on a trial
- The namespace is made public
- The user loses admin rights to the namespace
Alerts are scoped to a namespace, using UserGroupCallouts
. Dismissing an alert for one namespace will not dismiss it for others.
Dismissing an alert anywhere in a namespace hierarchy will dismiss it for the whole namespace. E.G. if you dismiss the alert in a child project or subgroup, it will no longer appear anywhere in the namespace.
Call To Actions
The primary CTA will always bring the user to the namespace billing page, i.e. /groups/{unique_group_UR_path}/-/billings
Screenshots or screen recordings
How to set up and validate locally
- Setup your local GDK to simulate a SAAS instance.
- Navigate to the following locations:
- Group -> Members
- Group -> Subgroup -> Members
- Project -> Members
Note: Because it is a pain to setup a trial for a group locally, go to the file ee/app/helpers/ee/users/group_callouts_helper.rb
and on line 13, replace group.trial_active?
with true
.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #376224