mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
Fix whitespace rendering in diff (#13415)
- Introduce new .code-inner class that sets the CSS attributes on rendered code lines like view,blame and diff. - Rename .wrap class to .word-break to reflect what it actually does - Remove .raw which was only used on webhook page - Set white-space: pre-wrap except on blame where it can break the layout Fixes: https://github.com/go-gitea/gitea/issues/13406
This commit is contained in:
@@ -44,12 +44,12 @@
|
||||
<div class="ui bottom attached tab segment active" data-tab="request-{{.ID}}">
|
||||
{{if .RequestInfo}}
|
||||
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5>
|
||||
<pre class="raw"><strong>Request URL:</strong> {{.URL}}
|
||||
<pre class="webhook-info"><strong>Request URL:</strong> {{.URL}}
|
||||
<strong>Request method:</strong> {{if .HTTPMethod}}{{.HTTPMethod}}{{else}}POST{{end}}
|
||||
{{ range $key, $val := .RequestInfo.Headers }}<strong>{{$key}}:</strong> {{$val}}
|
||||
{{end}}</pre>
|
||||
<h5>{{$.i18n.Tr "repo.settings.webhook.payload"}}</h5>
|
||||
<pre class="raw"><code class="json">{{.PayloadContent}}</code></pre>
|
||||
<pre class="webhook-info"><code class="json">{{.PayloadContent}}</code></pre>
|
||||
{{else}}
|
||||
N/A
|
||||
{{end}}
|
||||
@@ -57,10 +57,10 @@
|
||||
<div class="ui bottom attached tab segment" data-tab="response-{{.ID}}">
|
||||
{{if .ResponseInfo}}
|
||||
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5>
|
||||
<pre class="raw">{{ range $key, $val := .ResponseInfo.Headers }}<strong>{{$key}}:</strong> {{$val}}
|
||||
<pre class="webhook-info">{{ range $key, $val := .ResponseInfo.Headers }}<strong>{{$key}}:</strong> {{$val}}
|
||||
{{end}}</pre>
|
||||
<h5>{{$.i18n.Tr "repo.settings.webhook.body"}}</h5>
|
||||
<pre class="raw"><code>{{.ResponseInfo.Body}}</code></pre>
|
||||
<pre class="webhook-info"><code>{{.ResponseInfo.Body}}</code></pre>
|
||||
{{else}}
|
||||
N/A
|
||||
{{end}}
|
||||
|
Reference in New Issue
Block a user