summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorXaver Maierhofer <xaver.maierhofer@xwissen.info>2019-05-14 18:02:59 +0200
committertechknowlogick <techknowlogick@gitea.io>2019-05-14 12:02:59 -0400
commit95d3d42c5fd51bcc64774841edad158f6e5ef60f (patch)
tree965b52b5bcad59fe35a67128fd975ba25a94899c
parente55c874dd2a6162a374a9fac46c55db57bd17c5f (diff)
downloadgitea-95d3d42c5fd51bcc64774841edad158f6e5ef60f.tar.gz
gitea-95d3d42c5fd51bcc64774841edad158f6e5ef60f.zip
Fix code overflow (#6914)
-rw-r--r--public/css/index.css1
-rw-r--r--public/less/_admin.less6
-rw-r--r--templates/admin/config.tmpl2
3 files changed, 8 insertions, 1 deletions
diff --git a/public/css/index.css b/public/css/index.css
index 47e2519c5b..fa449ec69f 100644
--- a/public/css/index.css
+++ b/public/css/index.css
@@ -942,6 +942,7 @@ tbody.commit-list{vertical-align:baseline}
.admin dl.admin-dl-horizontal dd{margin-left:275px}
.admin dl.admin-dl-horizontal dt{font-weight:bolder;float:left;width:285px;clear:left;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.admin.config #test-mail-btn{margin-left:5px}
+.admin code,.admin pre{white-space:pre-wrap;word-wrap:break-word}
.explore{padding-top:15px}
.explore .navbar{justify-content:center;padding-top:15px!important;margin-top:-15px!important;margin-bottom:15px!important;background-color:#fafafa!important;border-width:1px!important}
.explore .navbar .octicon{width:16px;text-align:center;margin-right:5px}
diff --git a/public/less/_admin.less b/public/less/_admin.less
index af68a43dbd..0bd685142a 100644
--- a/public/less/_admin.less
+++ b/public/less/_admin.less
@@ -65,4 +65,10 @@
margin-left: 5px;
}
}
+
+ code,
+ pre {
+ white-space: pre-wrap;
+ word-wrap: break-word;
+ }
}
diff --git a/templates/admin/config.tmpl b/templates/admin/config.tmpl
index b4fcb4d610..7a81eb2668 100644
--- a/templates/admin/config.tmpl
+++ b/templates/admin/config.tmpl
@@ -254,7 +254,7 @@
<dt>{{.i18n.Tr "admin.config.session_provider"}}</dt>
<dd>{{.SessionConfig.Provider}}</dd>
<dt>{{.i18n.Tr "admin.config.provider_config"}}</dt>
- <dd><code>{{if .SessionConfig.ProviderConfig}}{{.SessionConfig.ProviderConfig}}{{else}}-{{end}}</code></dd>
+ <dd><pre>{{if .SessionConfig.ProviderConfig}}{{.SessionConfig.ProviderConfig | JsonPrettyPrint}}{{else}}-{{end}}</pre></dd>
<dt>{{.i18n.Tr "admin.config.cookie_name"}}</dt>
<dd>{{.SessionConfig.CookieName}}</dd>
<dt>{{.i18n.Tr "admin.config.gc_interval_time"}}</dt>