gitlab-org--gitlab-foss/app/views/search/results/_snippet_title.html.haml
Vinnie Okada 83e2a1ca12 Update path helper references
Use the path helpers for nested project resources, for Rails 4.1.9
compatibility.
2015-02-19 21:25:28 -07:00

23 lines
868 B
Text

.search-result-row
%h4.snippet-title.term
= link_to reliable_snippet_path(snippet_title) do
= truncate(snippet_title.title, length: 60)
- if snippet_title.private?
%span.label.label-gray
%i.fa.fa-lock
private
%span.cgray.monospace.tiny.pull-right.term
= snippet_title.file_name
%small.pull-right.cgray
- if snippet_title.project_id?
= link_to snippet_title.project.name_with_namespace, namespace_project_path(snippet_title.project.namespace, snippet_title.project)
.snippet-info
= "##{snippet_title.id}"
%span
by
= link_to user_snippets_path(snippet_title.author) do
= image_tag avatar_icon(snippet_title.author_email), class: "avatar avatar-inline s16", alt: ''
= snippet_title.author_name
%span.light #{time_ago_with_tooltip(snippet_title.created_at)}