2016-02-29 12:19:00 -05:00
|
|
|
%li.key-list-item
|
2018-04-09 13:36:21 -04:00
|
|
|
.float-left.append-right-10
|
2017-08-21 10:01:05 -04:00
|
|
|
- if key.valid?
|
2018-04-09 17:50:40 -04:00
|
|
|
= icon 'key', class: 'settings-list-icon d-none d-sm-block'
|
2017-08-21 10:01:05 -04:00
|
|
|
- else
|
2018-04-09 17:50:40 -04:00
|
|
|
= icon 'exclamation-triangle', class: 'settings-list-icon d-none d-sm-block has-tooltip',
|
2017-08-30 16:20:00 -04:00
|
|
|
title: key.errors.full_messages.join(', ')
|
2017-08-21 10:01:05 -04:00
|
|
|
|
|
|
|
|
2016-03-03 03:47:44 -05:00
|
|
|
.key-list-item-info
|
2016-02-29 12:19:00 -05:00
|
|
|
= link_to path_to_key(key, is_admin), class: "title" do
|
|
|
|
= key.title
|
|
|
|
.description
|
|
|
|
= key.fingerprint
|
2016-12-21 09:59:54 -05:00
|
|
|
.last-used-at
|
|
|
|
last used:
|
|
|
|
= key.last_used_at ? time_ago_with_tooltip(key.last_used_at) : 'n/a'
|
2018-04-09 13:42:45 -04:00
|
|
|
.float-right
|
2016-02-29 12:19:00 -05:00
|
|
|
%span.key-created-at
|
2016-03-21 14:11:32 -04:00
|
|
|
created #{time_ago_with_tooltip(key.created_at)}
|
2016-02-29 12:19:00 -05:00
|
|
|
= link_to path_to_key(key, is_admin), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-transparent prepend-left-10" do
|
|
|
|
%span.sr-only Remove
|
|
|
|
= icon('trash')
|