diff options
author | Douwe Maan <douwe@selenight.nl> | 2016-01-21 14:23:53 +0100 |
---|---|---|
committer | Douwe Maan <douwe@selenight.nl> | 2016-01-21 14:23:53 +0100 |
commit | 21facf535377ad58d07e8943033fe14efface8b2 (patch) | |
tree | 020fc70236a38f44f67faeb7a6f387dd250f01f4 /app/views/projects/blame | |
parent | a4ff270d59ef951538cb9d3962ebc8bc7d990016 (diff) | |
download | gitlab-ce-21facf535377ad58d07e8943033fe14efface8b2.tar.gz |
Use consistent markup and styling for highlighting across blobs, diffs, blame and snippets
Diffstat (limited to 'app/views/projects/blame')
-rw-r--r-- | app/views/projects/blame/show.html.haml | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/app/views/projects/blame/show.html.haml b/app/views/projects/blame/show.html.haml index d5d04954490..53dcac78a9f 100644 --- a/app/views/projects/blame/show.html.haml +++ b/app/views/projects/blame/show.html.haml @@ -12,7 +12,7 @@ %small= number_to_human_size @blob.size .file-actions = render "projects/blob/actions" - .file-content.blame.highlight + .file-content.blame.code.js-syntax-highlight %table - current_line = 1 - blame_highlighter = highlighter(@blob.name, @blob.data, nowrap: true) @@ -31,15 +31,14 @@ = commit_author_link(commit, avatar: false) authored #{time_ago_with_tooltip(commit.committed_date, skip_js: true)} - %td.lines.blame-numbers - %pre - - line_count = blame_group[:lines].count - - (current_line...(current_line + line_count)).each do |i| - = i - \ - - current_line += line_count + %td.line-numbers + - line_count = blame_group[:lines].count + - (current_line...(current_line + line_count)).each do |i| + %a.diff-line-num= i + \ + - current_line += line_count %td.lines - %pre{class: 'code highlight white'} + %pre{class: 'code highlight'} %code - blame_group[:lines].each do |line| :preserve |