File: _email_line.html.haml

package info (click to toggle)
gitlab 17.6.5-19
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 629,368 kB
  • sloc: ruby: 1,915,304; javascript: 557,307; sql: 60,639; xml: 6,509; sh: 4,567; makefile: 1,239; python: 406
file content (21 lines) | stat: -rw-r--r-- 842 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
-# This template is used when rendering diffs in email notifications
-# Called inside: app/views/notify/repository_push_email.html.haml
-#                app/views/notify/_note_email.html.haml

%tr.line_holder{ class: line.type }
  - case line.type
  - when 'match'
    = diff_match_line line.old_pos, line.new_pos, text: line.text
  - when 'old-nonewline', 'new-nonewline'
    %td.old_line.diff-line-num
    %td.new_line.diff-line-num
    %td.line_content.match= line.text
  - else
    %td.old_line.diff-line-num{ class: line.type, data: { linenumber: line.old_pos } }
      = diff_link_number(line.type, "new", line.old_pos)

    %td.new_line.diff-line-num{ class: line.type, data: { linenumber: line.new_pos } }
      = diff_link_number(line.type, "old", line.new_pos)

    %td.line_content{ class: line.type }<
      %pre= line.rich_text