diff options
Diffstat (limited to 'app/views/shared/snippets/_snippet.html.haml')
-rw-r--r-- | app/views/shared/snippets/_snippet.html.haml | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/app/views/shared/snippets/_snippet.html.haml b/app/views/shared/snippets/_snippet.html.haml new file mode 100644 index 00000000000..69a713ad9aa --- /dev/null +++ b/app/views/shared/snippets/_snippet.html.haml @@ -0,0 +1,21 @@ +%li.snippet-row + .snippet-title + = link_to reliable_snippet_path(snippet) do + = truncate(snippet.title, length: 60) + - if snippet.private? + %span.label.label-gray + %i.fa.fa-lock + private + %span.monospace.pull-right + = snippet.file_name + + %small.pull-right.cgray + - if snippet.project_id? + = link_to snippet.project.name_with_namespace, namespace_project_path(snippet.project.namespace, snippet.project) + + .snippet-info + = link_to user_snippets_path(snippet.author) do + = image_tag avatar_icon(snippet.author_email), class: "avatar s24", alt: '' + = snippet.author_name + authored #{time_ago_with_tooltip(snippet.created_at)} + |