.snippet-container
  = diff_snippet(patch, comments.first.location)
.code-comment-recap
  - comments.each do |comment|
    .comment{ id: "comment-#{comment.id}" }
      = link_to('<i class="fa fa-link"></i>'.html_safe,
                project_merge_request_path(@project, @mr, to: @to, anchor: "comment-#{comment.id}"))
      = image_tag gravatar_url(comment.user), class: 'avatar'
      .comment-header
        = comment.user.name
        %span
          wrote #{time_ago_in_words(comment.created_at)} ago
      .comment-body.markdown= emojify(comment.content)

.snippet-container
  = diff_snippet(patch, comments.first.location)
.code-comment-recap
  - comments.each do |comment|
    .comment{ id: "comment-ref-#{comment.id}" }
      = link_to('<i class="fa fa-link"></i>'.html_safe,
                project_merge_request_path(@project, @mr, to: @to, anchor: "comment-#{comment.id}"))
      = image_tag gravatar_url(comment.user), class: 'avatar'
      .comment-header
        = comment.user.name
        %span
          wrote #{time_ago_in_words(comment.created_at)} ago
      .comment-body.markdown= emojify(comment.content)

Use different element ids for comment from past versions.
Use different element ids for comment from past versions.

Using the same ID cause URLs to ignore the to and from GET parameters,
causing the browser to not open the desired page.
