You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gitea/templates/repo/diff
Giteabot 233a399706
Fix broken code editor diff preview (#23307) (#23320)
Backport #23307

Close #23265, the code editor diff preview has been broken for long
time.

* Fix the regression for `data-line-num`
    * `.code-diff` is necessary to show the line number
* Fix the regression for #12434
* The diff:
[12434](https://github.com/go-gitea/gitea/pull/12434/files?diff=unified&w=1)
    * It hides the Type(4) (aka HunkHeader)  for unexpected cases.


Diff with ignoring whitespaces:
https://github.com/go-gitea/gitea/pull/23307/files?diff=unified&w=1

Before: see the issue #23265

After:


![image](https://user-images.githubusercontent.com/2114189/222942810-286dc9af-0b39-4e9d-8585-8c299b881241.png)

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2 years ago
..
blob_excerpt.tmpl Move helpers to be prefixed with `gt-` (#22879) 2 years ago
box.tmpl Improve PR Review Box UI (#22986) 2 years ago
comment_form.tmpl Refactor hiding-methods, remove jQuery show/hide, remove `.hide` class, remove inline style=display:none (#22950) 2 years ago
comment_form_datahandler.tmpl Make sure fmt catches all templates (#20979) 3 years ago
comments.tmpl Fix broken pull request files (#22962) 2 years ago
compare.tmpl Refactor hiding-methods, remove jQuery show/hide, remove `.hide` class, remove inline style=display:none (#22950) 2 years ago
conversation.tmpl Refactor hiding-methods, remove jQuery show/hide, remove `.hide` class, remove inline style=display:none (#22950) 2 years ago
csv_diff.tmpl Fix CSV diff for added/deleted files (#21189) 2 years ago
escape_title.tmpl Switch Unicode Escaping to a VSCode-like system (#19990) 3 years ago
image_diff.tmpl Refactor hiding-methods, remove jQuery show/hide, remove `.hide` class, remove inline style=display:none (#22950) 2 years ago
new_comment.tmpl Do not reload page after adding comments in Pull Request reviews (#13877) 4 years ago
new_review.tmpl Improve PR Review Box UI (#22986) 2 years ago
options_dropdown.tmpl Add filetree on left of diff view (#21012) 2 years ago
section_code.tmpl Switch Unicode Escaping to a VSCode-like system (#19990) 3 years ago
section_split.tmpl Move helpers to be prefixed with `gt-` (#22879) 2 years ago
section_unified.tmpl Fix broken code editor diff preview (#23307) (#23320) 2 years ago
stats.tmpl Move helpers to be prefixed with `gt-` (#22879) 2 years ago
whitespace_dropdown.tmpl Move helpers to be prefixed with `gt-` (#22879) 2 years ago