gitlab-org--gitlab-foss/app/views/projects/deploy_keys/_index.html.haml
Peter Leitzen 03f136fcd9 Prefer usage of helper expanded_by_default?
Stop using `Rails.env.test?` in views.
2019-04-29 15:01:28 +00:00

15 lines
739 B
Text

- expanded = expanded_by_default?
%section.qa-deploy-keys-settings.settings.no-animate#js-deploy-keys-settings{ class: ('expanded' if expanded) }
.settings-header
%h4
Deploy Keys
%button.btn.js-settings-toggle{ type: 'button' }
= expanded ? 'Collapse' : 'Expand'
%p
Deploy keys allow read-only or read-write (if enabled) access to your repository. Deploy keys can be used for CI, staging or production servers. You can create a deploy key or add an existing one.
.settings-content
%h5.prepend-top-0
Create a new deploy key for this project
= render @deploy_keys.form_partial_path
%hr
#js-deploy-keys{ data: { endpoint: project_deploy_keys_path(@project), project_id: @project.id } }