From e3897148f9e612e363854d790a1e77807dac8d0d Mon Sep 17 00:00:00 2001 From: wxiaoguang Date: Fri, 2 Jun 2023 18:02:20 +0800 Subject: [PATCH] Minor UI improvements: logo alignment, auth map editor, auth name display (#25043) Some minor UI improvements together (then no need to review 3 small PRs) # The Map for auth sources Close #24826 Now the LDAP and OAuth2 both have multiple line editor for the map (and it can be resized by the handler)
![image](https://github.com/go-gitea/gitea/assets/2114189/7eed1618-0d71-4df2-84bd-ca20a06c02db) ![image](https://github.com/go-gitea/gitea/assets/2114189/a94dc6dc-0e3b-4185-bac1-8d16561b8e62)
# The account link display Before, the UI is misaligned This PR fixes the misalignment, remove "float right", and show the auth source name and auth type (in the tooltip). And the "active" color is changed from dark red to primary color. Before:
![image](https://github.com/go-gitea/gitea/assets/2114189/3bb4a8f2-2f66-4d62-ac96-096f14aeb819)
After:
![image](https://github.com/go-gitea/gitea/assets/2114189/05ca46ae-7769-422d-a52a-b7402679cd05)
# The UI logo alignment Changed file: `css/base.css`. Before, there were some "fine tunes", these "fine tunes" only causes misalignment.
![image](https://github.com/go-gitea/gitea/assets/2114189/395b03c2-6e8c-4742-abf9-8d548dab908d)
After this PR:
![image](https://github.com/go-gitea/gitea/assets/2114189/3339acdc-7391-45bc-b6ec-a5b3bc7830a6) ![image](https://github.com/go-gitea/gitea/assets/2114189/656a7bee-cdfb-4232-aee9-25b76cae8e00)
--- templates/admin/auth/edit.tmpl | 4 ++-- templates/admin/auth/source/ldap.tmpl | 2 +- templates/admin/auth/source/oauth.tmpl | 2 +- .../user/settings/security/accountlinks.tmpl | 18 +++++++++--------- web_src/css/base.css | 12 ------------ 5 files changed, 13 insertions(+), 25 deletions(-) diff --git a/templates/admin/auth/edit.tmpl b/templates/admin/auth/edit.tmpl index b81e7b5ff3..af9d4c4bc5 100644 --- a/templates/admin/auth/edit.tmpl +++ b/templates/admin/auth/edit.tmpl @@ -133,7 +133,7 @@
- +
@@ -360,7 +360,7 @@
- +
diff --git a/templates/admin/auth/source/ldap.tmpl b/templates/admin/auth/source/ldap.tmpl index 909cf77047..26eef890b2 100644 --- a/templates/admin/auth/source/ldap.tmpl +++ b/templates/admin/auth/source/ldap.tmpl @@ -106,7 +106,7 @@
- +
diff --git a/templates/admin/auth/source/oauth.tmpl b/templates/admin/auth/source/oauth.tmpl index 277ebdb011..a0c5a87d0f 100644 --- a/templates/admin/auth/source/oauth.tmpl +++ b/templates/admin/auth/source/oauth.tmpl @@ -100,7 +100,7 @@
- +
diff --git a/templates/user/settings/security/accountlinks.tmpl b/templates/user/settings/security/accountlinks.tmpl index 29fbe6832c..b9f8af34c7 100644 --- a/templates/user/settings/security/accountlinks.tmpl +++ b/templates/user/settings/security/accountlinks.tmpl @@ -25,16 +25,16 @@
{{if .AccountLinks}} {{range $loginSource, $provider := .AccountLinks}} -
-
- -
-
- {{$provider}} - {{if $loginSource.IsActive}}{{$.locale.Tr "repo.settings.active"}}{{end}} +
+
+ + {{$loginSource.Name}} + {{if $loginSource.IsActive}}{{$.locale.Tr "repo.settings.active"}}{{end}} +
+
{{end}} {{end}} diff --git a/web_src/css/base.css b/web_src/css/base.css index d143b20f81..49bdfed1b7 100644 --- a/web_src/css/base.css +++ b/web_src/css/base.css @@ -952,18 +952,6 @@ img.ui.avatar, .following.bar #navbar { width: 100vw; min-height: 52px; - padding: 0 16px; -} - -@media (max-width: 767px) { - .following.bar #navbar { - padding-left: 4px; - padding-right: 0; - } -} - -.following.bar #navbar .brand { - margin: 0; } .following.bar #navbar .dropdown .avatar {