Add image repository level delete functionality to the Image Repository detail view

Problem to solve

The Package stage allows you to publish, consume, and discover images, all in one place. Users publish and pull images using GitLab CI/CD, the command line, or the GitLab API.

When handling large numbers of image repositories, it is not uncommon for users to want to delete the image repository after viewing the details. Currently, this requires unique navigation back to the list view to delete the image repository, which can cause a loss of context for users.

Intended users

Personas are described at https://about.gitlab.com/handbook/marketing/product-marketing/roles-personas/

User experience goal

Improve the delete image repository experience by allowing users to delete an image repository while currently viewing the details.

Proposal

Add a delete image repository button to the UI. A confirmation model will pop up. After confirming, the image repository will enter a disabled "Repository is being deleted".

Image Repository delete button
Add_delete_button_to_image_repository_list_view
Image repository has been marked for deletion
Add_alert_saying_the_registry_has_been_marked_for_deltion
FINAL COPY

Alert/Banner

Title: Image repository will be deleted (unchanged)

Body: This image repository will be deleted. Learn more. (link)

Confirmation Modal

Title: Delete image repository?

Body: Deleting the image repository will delete all images and tags inside. This action cannot be undone.

Buttons: Confirm and Cancel

Further details

I have included a post-deletion state including an alert saying that this image repository was marked for deletion. It is assumed that the user will need to confirm the delete action before returning to this screen. The image repository list view should also appear disabled.

The MVC does not include a way to "un-delete" the image repository. This is something we may need to consider.

Edited by Tim Rizzi