Commit 793d9799 authored by Robert Speicher's avatar Robert Speicher

Show key fingerprint on DeployKeys#index

Also style all key fingerprints consistently across the app.
parent 6e5473f9
......@@ -23,6 +23,13 @@ pre {
font-family: $monospace_font;
}
code {
&.key-fingerprint {
background: $body-bg;
color: $text-color;
}
}
/**
* Wiki typography
*
......
......@@ -19,8 +19,7 @@
= link_to admin_deploy_key_path(deploy_key) do
%strong= deploy_key.title
%td
%span
(#{deploy_key.fingerprint})
%code.key-fingerprint= deploy_key.fingerprint
%td
%span.cgray
added #{time_ago_with_tooltip(deploy_key.created_at)}
......
......@@ -3,8 +3,7 @@
= link_to path_to_key(key, is_admin) do
%strong= key.title
%td
%span
(#{key.fingerprint})
%code.key-fingerprint= key.fingerprint
%td
%span.cgray
added #{time_ago_with_tooltip(key.created_at)}
......
......@@ -15,7 +15,7 @@
.col-md-8
%p
%span.light Fingerprint:
%strong= @key.fingerprint
%code.key-fingerprint= @key.fingerprint
%pre.well-pre
= @key.key
.pull-right
......
......@@ -2,24 +2,20 @@
.pull-right
- if @available_keys.include?(deploy_key)
= link_to enable_namespace_project_deploy_key_path(@project.namespace, @project, deploy_key), class: 'btn btn-sm', method: :put do
%i.fa.fa-plus
= icon('plus')
Enable
- else
- if deploy_key.destroyed_when_orphaned? && deploy_key.almost_orphaned?
= link_to 'Remove', disable_namespace_project_deploy_key_path(@project.namespace, @project, deploy_key), data: { confirm: 'You are going to remove deploy key. Are you sure?'}, method: :put, class: "btn btn-remove delete-key btn-sm pull-right"
- else
= link_to disable_namespace_project_deploy_key_path(@project.namespace, @project, deploy_key), class: 'btn btn-sm', method: :put do
%i.fa.fa-power-off
= icon('power-off')
Disable
- if project = project_for_deploy_key(deploy_key)
= link_to namespace_project_deploy_key_path(project.namespace, project, deploy_key) do
%i.fa.fa-key
%strong= deploy_key.title
- else
%i.fa.fa-key
%strong= deploy_key.title
= icon('key')
%strong= deploy_key.title
%br
%code.key-fingerprint= deploy_key.fingerprint
%p.light.prepend-top-10
- if deploy_key.public?
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment