diff options
author | Jacob Schatz <jschatz@gitlab.com> | 2017-02-24 19:44:07 +0300 |
---|---|---|
committer | Jacob Schatz <jschatz@gitlab.com> | 2017-02-24 19:44:07 +0300 |
commit | d6f18f8e1989aac4b96ad377f854cf2724f77c19 (patch) | |
tree | 3e3ecca51d50734e4489ae8f921acaddfa920332 | |
parent | 983b90e467c810bd723c4d4f59a52fdfcfc77f21 (diff) | |
parent | c1714355276476776ec3f16686722f49cac3895d (diff) |
Merge branch '28367-fix-unfold-diff-line-number-copy-paste' into 'master'
fixes line number copy issue for unfolded parallel view diff
Closes #28367
See merge request !9365
-rw-r--r-- | app/views/projects/blob/diff.html.haml | 4 | ||||
-rw-r--r-- | changelogs/unreleased/28367-fix-unfold-diff-line-number-copy-paste.yml | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/app/views/projects/blob/diff.html.haml b/app/views/projects/blob/diff.html.haml index d1f7f65bf53..c48d9dd982c 100644 --- a/app/views/projects/blob/diff.html.haml +++ b/app/views/projects/blob/diff.html.haml @@ -19,10 +19,10 @@ = line_content - when :parallel %td.old_line.diff-line-num{ data: { linenumber: line_old } } - = link_to raw(line_old), "##{line_old}" + %a{ href: "##{line_old}", data: { linenumber: line_old } } = line_content %td.new_line.diff-line-num{ data: { linenumber: line_new } } - = link_to raw(line_new), "##{line_new}" + %a{ href: "##{line_new}", data: { linenumber: line_new } } = line_content - if @form.unfold? && @form.bottom? && @form.to < @blob.lines.size diff --git a/changelogs/unreleased/28367-fix-unfold-diff-line-number-copy-paste.yml b/changelogs/unreleased/28367-fix-unfold-diff-line-number-copy-paste.yml new file mode 100644 index 00000000000..6fc89fd91dd --- /dev/null +++ b/changelogs/unreleased/28367-fix-unfold-diff-line-number-copy-paste.yml @@ -0,0 +1,4 @@ +--- +title: Fixes includes line number during unfold copy n paste in parallel diff view +merge_request: 9365 +author: |