Use danger variant for project delete modal
What does this MR do and why?
For the "delete projects" modal in app/views/projects/no_repo.html.haml
:
- Uses danger variant for modal button
- Updates modal button text
#344157 (closed) (for &6854 (closed)).
Two follow-up issues have been created for this template:
- Use
delete_project_modal.vue
for "Delete Project" button onapp/views/projects/no_repo.html.haml
- Add Pajamas-compliant empty state to
app/views/projects/no_repo.html.haml
Screenshots or screen recordings
Before | After |
---|---|
How to set up and validate locally
- Enable feature flag
Feature.enable(:bootstrap_confirmation_modals)
- Apply this diff:
diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb
index d2e3c7d0272..f486973a18d 100644
--- a/app/controllers/projects_controller.rb
+++ b/app/controllers/projects_controller.rb
@@ -349,6 +349,7 @@ def unfoldered_environment_names
#
# pages list order: repository readme, wiki home, issues list, customize workflow
def render_landing_page
+ return render 'projects/no_repo'
if can?(current_user, :download_code, @project)
return render 'projects/no_repo' unless @project.repository_exists?
- Go to any project. The "no repo" template should render.
- Click "delete project". Observe modal.
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 #344157 (closed)
Edited by Tom Quirk