BigW Consortium Gitlab

_parallel_diff_discussion.html.haml 925 Bytes
Newer Older
1
- expanded = [*discussions_left, *discussions_right].any?(&:expanded?)
2
%tr.notes_holder{ class: ('hide' unless expanded) }
3
  - if discussions_left
4 5
    %td.notes_line.old
    %td.notes_content.parallel.old
6
      .content{ class: ('hide' unless discussions_left.any?(&:expanded?)) }
7
        = render partial: "discussions/notes", collection: discussions_left, as: :discussion, line_type: 'old', locals: { disable_collapse_class: true }
8
  - else
9
    %td.notes_line.old= ("")
10 11
    %td.notes_content.parallel.old
      .content
12

13
  - if discussions_right
14 15
    %td.notes_line.new
    %td.notes_content.parallel.new
16
      .content{ class: ('hide' unless discussions_right.any?(&:expanded?)) }
17
        = render partial: "discussions/notes", collection: discussions_right, as: :discussion, line_type: 'new', locals: { disable_collapse_class: true }
18
  - else
19
    %td.notes_line.new= ("")
20 21
    %td.notes_content.parallel.new
      .content