diff options
author | TheFox0x7 <thefox0x7@gmail.com> | 2024-12-29 02:32:19 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-12-29 01:32:19 +0000 |
commit | ff96873e3e14f6eae853ec8eee59ab4482962c43 (patch) | |
tree | 34c356537f80998ccb3a5dbadad9697b3afb4d7a /templates/base | |
parent | 0ed160ffea91ac1903bd33866fa93c24e3ace65c (diff) | |
download | gitea-ff96873e3e14f6eae853ec8eee59ab4482962c43.tar.gz gitea-ff96873e3e14f6eae853ec8eee59ab4482962c43.zip |
Fix templating in pull request comparison (#33025)
Adds test for expected behavior
Closes: https://github.com/go-gitea/gitea/issues/33013
Diffstat (limited to 'templates/base')
-rw-r--r-- | templates/base/alert_details.tmpl | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/templates/base/alert_details.tmpl b/templates/base/alert_details.tmpl index 6801c8240f..6d4c1fb2db 100644 --- a/templates/base/alert_details.tmpl +++ b/templates/base/alert_details.tmpl @@ -1,7 +1,11 @@ {{.Message}} +{{if .Details}} <details> <summary>{{.Summary}}</summary> - <code> - {{.Details | SanitizeHTML}} - </code> + <code>{{.Details | SanitizeHTML}}</code> </details> +{{else}} +<div> + {{.Summary}} +</div> +{{end}} |