From b1cf7f4df11dfac879d65125880d18a03fef22c0 Mon Sep 17 00:00:00 2001 From: silverwind Date: Tue, 1 Dec 2020 05:00:14 +0100 Subject: [PATCH] Add class to page content to unify top margin (#13766) * Add class to page content to unify top margin Previously pages would individually set this margin but some didn't so content would stick to the header without any space. Resolve this by adding a new class that is added on all pages. The only place where we remove this margin again is on the pages with menu or wrapper in the header. * fix admin notices * fix team pages * fix loading segment on gitgraph for arc-green * fix last missing case Co-authored-by: techknowlogick --- templates/admin/auth/edit.tmpl | 2 +- templates/admin/auth/list.tmpl | 2 +- templates/admin/auth/new.tmpl | 2 +- templates/admin/config.tmpl | 2 +- templates/admin/dashboard.tmpl | 2 +- templates/admin/emails/list.tmpl | 2 +- templates/admin/hook_new.tmpl | 2 +- templates/admin/hooks.tmpl | 2 +- templates/admin/monitor.tmpl | 2 +- templates/admin/notice.tmpl | 2 +- templates/admin/org/list.tmpl | 2 +- templates/admin/queue.tmpl | 2 +- templates/admin/repo/list.tmpl | 2 +- templates/admin/repo/unadopted.tmpl | 2 +- templates/admin/user/edit.tmpl | 2 +- templates/admin/user/list.tmpl | 2 +- templates/admin/user/new.tmpl | 2 +- templates/explore/code.tmpl | 2 +- templates/explore/navbar.tmpl | 2 +- templates/explore/organizations.tmpl | 2 +- templates/explore/repos.tmpl | 2 +- templates/explore/users.tmpl | 2 +- templates/home.tmpl | 2 +- templates/install.tmpl | 2 +- templates/org/create.tmpl | 2 +- templates/org/home.tmpl | 2 +- templates/org/member/members.tmpl | 2 +- templates/org/settings/delete.tmpl | 2 +- templates/org/settings/hook_new.tmpl | 2 +- templates/org/settings/hooks.tmpl | 2 +- templates/org/settings/labels.tmpl | 2 +- templates/org/settings/options.tmpl | 2 +- templates/org/team/members.tmpl | 2 +- templates/org/team/new.tmpl | 2 +- templates/org/team/repositories.tmpl | 2 +- templates/org/team/teams.tmpl | 2 +- templates/post-install.tmpl | 2 +- templates/repo/activity.tmpl | 2 +- templates/repo/branch/list.tmpl | 2 +- templates/repo/commit_page.tmpl | 2 +- templates/repo/commits.tmpl | 2 +- templates/repo/create.tmpl | 2 +- templates/repo/diff/compare.tmpl | 2 +- templates/repo/editor/delete.tmpl | 2 +- templates/repo/editor/edit.tmpl | 2 +- templates/repo/editor/upload.tmpl | 2 +- templates/repo/empty.tmpl | 2 +- templates/repo/forks.tmpl | 2 +- templates/repo/graph.tmpl | 2 +- templates/repo/home.tmpl | 2 +- templates/repo/issue/choose.tmpl | 2 +- templates/repo/issue/labels.tmpl | 2 +- templates/repo/issue/list.tmpl | 2 +- templates/repo/issue/milestone_issues.tmpl | 2 +- templates/repo/issue/milestone_new.tmpl | 2 +- templates/repo/issue/milestones.tmpl | 2 +- templates/repo/issue/new.tmpl | 2 +- templates/repo/issue/view.tmpl | 2 +- templates/repo/migrate/git.tmpl | 2 +- templates/repo/migrate/gitea.tmpl | 2 +- templates/repo/migrate/github.tmpl | 2 +- templates/repo/migrate/gitlab.tmpl | 2 +- templates/repo/migrate/migrate.tmpl | 2 +- templates/repo/migrate/migrating.tmpl | 2 +- templates/repo/projects/list.tmpl | 2 +- templates/repo/projects/new.tmpl | 2 +- templates/repo/projects/view.tmpl | 2 +- templates/repo/pulls/commits.tmpl | 2 +- templates/repo/pulls/files.tmpl | 2 +- templates/repo/pulls/fork.tmpl | 2 +- templates/repo/release/list.tmpl | 2 +- templates/repo/release/new.tmpl | 2 +- templates/repo/search.tmpl | 2 +- templates/repo/settings/branches.tmpl | 2 +- templates/repo/settings/collaboration.tmpl | 2 +- templates/repo/settings/deploy_keys.tmpl | 2 +- templates/repo/settings/githook_edit.tmpl | 2 +- templates/repo/settings/githooks.tmpl | 2 +- templates/repo/settings/lfs.tmpl | 2 +- templates/repo/settings/lfs_file.tmpl | 2 +- templates/repo/settings/lfs_file_find.tmpl | 2 +- templates/repo/settings/lfs_locks.tmpl | 2 +- templates/repo/settings/lfs_pointers.tmpl | 2 +- templates/repo/settings/options.tmpl | 2 +- templates/repo/settings/protected_branch.tmpl | 2 +- templates/repo/settings/webhook/base.tmpl | 2 +- templates/repo/settings/webhook/new.tmpl | 2 +- templates/repo/watchers.tmpl | 2 +- templates/repo/wiki/new.tmpl | 2 +- templates/repo/wiki/pages.tmpl | 2 +- templates/repo/wiki/revision.tmpl | 2 +- templates/repo/wiki/start.tmpl | 2 +- templates/repo/wiki/view.tmpl | 2 +- templates/status/404.tmpl | 16 +++++++++------- templates/status/500.tmpl | 2 +- templates/user/auth/activate.tmpl | 2 +- templates/user/auth/change_passwd.tmpl | 2 +- templates/user/auth/finalize_openid.tmpl | 2 +- templates/user/auth/forgot_passwd.tmpl | 2 +- templates/user/auth/grant.tmpl | 2 +- templates/user/auth/grant_error.tmpl | 4 ++-- templates/user/auth/link_account.tmpl | 3 +-- templates/user/auth/prohibit_login.tmpl | 2 +- templates/user/auth/reset_passwd.tmpl | 2 +- templates/user/auth/signin.tmpl | 2 +- templates/user/auth/signin_navbar.tmpl | 2 -- templates/user/auth/signin_openid.tmpl | 2 +- templates/user/auth/signup.tmpl | 2 +- templates/user/auth/signup_openid_connect.tmpl | 2 +- templates/user/auth/signup_openid_register.tmpl | 2 +- templates/user/auth/twofa.tmpl | 2 +- templates/user/auth/twofa_scratch.tmpl | 2 +- templates/user/auth/u2f.tmpl | 2 +- templates/user/dashboard/dashboard.tmpl | 2 +- templates/user/dashboard/issues.tmpl | 2 +- templates/user/dashboard/milestones.tmpl | 2 +- .../user/notification/notification_div.tmpl | 2 +- templates/user/profile.tmpl | 2 +- templates/user/project.tmpl | 2 +- templates/user/settings/account.tmpl | 2 +- templates/user/settings/applications.tmpl | 2 +- .../user/settings/applications_oauth2_edit.tmpl | 2 +- templates/user/settings/keys.tmpl | 2 +- templates/user/settings/organization.tmpl | 2 +- templates/user/settings/profile.tmpl | 2 +- templates/user/settings/repos.tmpl | 2 +- templates/user/settings/security.tmpl | 2 +- templates/user/settings/twofa_enroll.tmpl | 2 +- web_src/less/_admin.less | 4 ---- web_src/less/_base.less | 15 ++++++++++++++- web_src/less/_dashboard.less | 1 - web_src/less/_explore.less | 1 - web_src/less/_repository.less | 1 - 133 files changed, 150 insertions(+), 145 deletions(-) diff --git a/templates/admin/auth/edit.tmpl b/templates/admin/auth/edit.tmpl index 24f6b37c8..3347a91bf 100644 --- a/templates/admin/auth/edit.tmpl +++ b/templates/admin/auth/edit.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/auth/list.tmpl b/templates/admin/auth/list.tmpl index 60b8f6fbe..851254c09 100644 --- a/templates/admin/auth/list.tmpl +++ b/templates/admin/auth/list.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/auth/new.tmpl b/templates/admin/auth/new.tmpl index e72a82cbb..c252f7d3f 100644 --- a/templates/admin/auth/new.tmpl +++ b/templates/admin/auth/new.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/config.tmpl b/templates/admin/config.tmpl index 4d88c59fe..00ad7a9a0 100644 --- a/templates/admin/config.tmpl +++ b/templates/admin/config.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/dashboard.tmpl b/templates/admin/dashboard.tmpl index 911cdb9fe..e6d9f57c2 100644 --- a/templates/admin/dashboard.tmpl +++ b/templates/admin/dashboard.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/emails/list.tmpl b/templates/admin/emails/list.tmpl index 8a60088f0..752c01044 100644 --- a/templates/admin/emails/list.tmpl +++ b/templates/admin/emails/list.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/hook_new.tmpl b/templates/admin/hook_new.tmpl index 26169acaa..8eeb0e526 100644 --- a/templates/admin/hook_new.tmpl +++ b/templates/admin/hook_new.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/hooks.tmpl b/templates/admin/hooks.tmpl index 3265a1d69..c09c6fcaf 100644 --- a/templates/admin/hooks.tmpl +++ b/templates/admin/hooks.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "repo/settings/webhook/list" .}} diff --git a/templates/admin/monitor.tmpl b/templates/admin/monitor.tmpl index c3600fa99..5a38b92ee 100644 --- a/templates/admin/monitor.tmpl +++ b/templates/admin/monitor.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/notice.tmpl b/templates/admin/notice.tmpl index d1d264c8c..3320f5884 100644 --- a/templates/admin/notice.tmpl +++ b/templates/admin/notice.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/org/list.tmpl b/templates/admin/org/list.tmpl index 4a0fd1611..92b119d65 100644 --- a/templates/admin/org/list.tmpl +++ b/templates/admin/org/list.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/queue.tmpl b/templates/admin/queue.tmpl index 567e72e03..6524c9839 100644 --- a/templates/admin/queue.tmpl +++ b/templates/admin/queue.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/repo/list.tmpl b/templates/admin/repo/list.tmpl index df38831b6..fbadfeea7 100644 --- a/templates/admin/repo/list.tmpl +++ b/templates/admin/repo/list.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/repo/unadopted.tmpl b/templates/admin/repo/unadopted.tmpl index 7a046c602..26c91c315 100644 --- a/templates/admin/repo/unadopted.tmpl +++ b/templates/admin/repo/unadopted.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/user/edit.tmpl b/templates/admin/user/edit.tmpl index e29b18f5b..7f1706e55 100644 --- a/templates/admin/user/edit.tmpl +++ b/templates/admin/user/edit.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/user/list.tmpl b/templates/admin/user/list.tmpl index d6dd7d5c0..dafeadaf9 100644 --- a/templates/admin/user/list.tmpl +++ b/templates/admin/user/list.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/admin/user/new.tmpl b/templates/admin/user/new.tmpl index b05f81717..885045dd0 100644 --- a/templates/admin/user/new.tmpl +++ b/templates/admin/user/new.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "admin/navbar" .}}
{{template "base/alert" .}} diff --git a/templates/explore/code.tmpl b/templates/explore/code.tmpl index bf7f85c5a..9c880e59f 100644 --- a/templates/explore/code.tmpl +++ b/templates/explore/code.tmpl @@ -1,5 +1,5 @@ {{template "base/head" .}} -
+
{{template "explore/navbar" .}}
diff --git a/templates/explore/navbar.tmpl b/templates/explore/navbar.tmpl index ce86c0a8c..93810dcf4 100644 --- a/templates/explore/navbar.tmpl +++ b/templates/explore/navbar.tmpl @@ -1,4 +1,4 @@ -