File: _parallel_diff_discussion.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 (17 lines) | stat: -rw-r--r-- 877 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
- expanded = [*discussions_left, *discussions_right].any?(&:expanded?)
%tr.notes_holder{ class: ('hide' unless expanded) }
  - if discussions_left
    %td.notes-content.parallel.old{ colspan: 2 }
      .content{ class: ('hide' unless discussions_left.any?(&:expanded?)) }
        = render partial: "discussions/notes", collection: discussions_left, as: :discussion, line_type: 'old', locals: { disable_collapse_class: true }
  - else
    %td.notes-content.parallel.old{ colspan: 2 }
      .content

  - if discussions_right
    %td.notes-content.parallel.new{ colspan: 2 }
      .content{ class: ('hide' unless discussions_right.any?(&:expanded?)) }
        = render partial: "discussions/notes", collection: discussions_right, as: :discussion, line_type: 'new', locals: { disable_collapse_class: true }
  - else
    %td.notes-content.parallel.new{ colspan: 2 }
      .content