diff options
author | Douwe Maan <douwe@selenight.nl> | 2016-01-25 11:42:47 +0100 |
---|---|---|
committer | Douwe Maan <douwe@selenight.nl> | 2016-01-25 11:42:47 +0100 |
commit | 40d2daed89f598e0b869bdc09bf47d4defe1c5f0 (patch) | |
tree | 34476409922fbf4ccf2c6405ffd622e9172a93fb /app/views/projects | |
parent | 0f2a906211dcbf4978b465d342521dda14ade729 (diff) | |
download | gitlab-ce-40d2daed89f598e0b869bdc09bf47d4defe1c5f0.tar.gz |
Highlight note code and edit previewnote-highlighting
Diffstat (limited to 'app/views/projects')
-rw-r--r-- | app/views/projects/blob/_text.html.haml | 8 | ||||
-rw-r--r-- | app/views/projects/blob/preview.html.haml | 2 | ||||
-rw-r--r-- | app/views/projects/notes/discussions/_diff.html.haml | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/app/views/projects/blob/_text.html.haml b/app/views/projects/blob/_text.html.haml index 4429c395aee..906e5ccb360 100644 --- a/app/views/projects/blob/_text.html.haml +++ b/app/views/projects/blob/_text.html.haml @@ -2,8 +2,8 @@ .file-content.wiki = render_markup(blob.name, blob.data) - else - .file-content.code - - unless blob.empty? - = render 'shared/file_highlight', blob: blob - - else + - unless blob.empty? + = render 'shared/file_highlight', blob: blob + - else + .file-content.code .nothing-here-block Empty file diff --git a/app/views/projects/blob/preview.html.haml b/app/views/projects/blob/preview.html.haml index c5a269f334c..541dc96c45f 100644 --- a/app/views/projects/blob/preview.html.haml +++ b/app/views/projects/blob/preview.html.haml @@ -8,7 +8,7 @@ .file-content.wiki = raw render_markup(@blob.name, @content) - else - .file-content.code + .file-content.code.js-syntax-highlight - unless @diff_lines.empty? %table.text-file - @diff_lines.each do |line| diff --git a/app/views/projects/notes/discussions/_diff.html.haml b/app/views/projects/notes/discussions/_diff.html.haml index 92bbaf0961a..820e31ccd61 100644 --- a/app/views/projects/notes/discussions/_diff.html.haml +++ b/app/views/projects/notes/discussions/_diff.html.haml @@ -9,7 +9,7 @@ = diff.new_path - if diff.a_mode && diff.b_mode && diff.a_mode != diff.b_mode %span.file-mode= "#{diff.a_mode} → #{diff.b_mode}" - .diff-content + .diff-content.code.js-syntax-highlight %table - note.truncated_diff_lines.each do |line| - type = line.type |