[llvm] [Docs] Fix large vertical space at top of pages (PR #81599)
J. Ryan Stinnett via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 16 03:16:11 PST 2024
https://github.com/jryans updated https://github.com/llvm/llvm-project/pull/81599
>From e57d3a61075c791c36f05f89cafbbdb05e8ee191 Mon Sep 17 00:00:00 2001
From: "J. Ryan Stinnett" <jryans at gmail.com>
Date: Tue, 13 Feb 2024 12:26:06 +0000
Subject: [PATCH 1/2] [Docs] Fix large vertical space at top of pages
This fixes a large vertical blank space at the top of the page that was caused
by the floating sidebar.
---
llvm/docs/_themes/llvm-theme/static/llvm-theme.css | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/llvm/docs/_themes/llvm-theme/static/llvm-theme.css b/llvm/docs/_themes/llvm-theme/static/llvm-theme.css
index 4b04e0cbaccfd3..d8a56a0c262f7b 100644
--- a/llvm/docs/_themes/llvm-theme/static/llvm-theme.css
+++ b/llvm/docs/_themes/llvm-theme/static/llvm-theme.css
@@ -369,3 +369,16 @@ div.viewcode-block:target {
border-top: 1px solid #ac9;
border-bottom: 1px solid #ac9;
}
+
+/*
+Move sidebar to the right without using floats. This fixes a large vertical
+blank space at the top of the page that was caused by the floating sidebar.
+*/
+body {
+ position: relative;
+}
+div.sphinxsidebar {
+ float: none;
+ position: absolute;
+ right: 0;
+}
>From f398344504b175ba1dc5146602b6794ca40e7086 Mon Sep 17 00:00:00 2001
From: "J. Ryan Stinnett" <jryans at gmail.com>
Date: Fri, 16 Feb 2024 11:04:53 +0000
Subject: [PATCH 2/2] Fold into existing rulesets
---
.../_themes/llvm-theme/static/llvm-theme.css | 18 ++++--------------
1 file changed, 4 insertions(+), 14 deletions(-)
diff --git a/llvm/docs/_themes/llvm-theme/static/llvm-theme.css b/llvm/docs/_themes/llvm-theme/static/llvm-theme.css
index d8a56a0c262f7b..0fc5b261dbd057 100644
--- a/llvm/docs/_themes/llvm-theme/static/llvm-theme.css
+++ b/llvm/docs/_themes/llvm-theme/static/llvm-theme.css
@@ -26,6 +26,7 @@ body {
border: 1px solid #aaa;
margin: 0px 80px 0px 80px;
min-width: 740px;
+ position: relative;
}
div.logo {
@@ -94,9 +95,11 @@ div.sphinxsidebar {
margin: 0;
padding: 0.5em 15px 15px 0;
width: 210px;
- float: right;
font-size: 1em;
text-align: left;
+ float: none;
+ position: absolute;
+ right: 0;
}
div.sphinxsidebar h3, div.sphinxsidebar h4 {
@@ -369,16 +372,3 @@ div.viewcode-block:target {
border-top: 1px solid #ac9;
border-bottom: 1px solid #ac9;
}
-
-/*
-Move sidebar to the right without using floats. This fixes a large vertical
-blank space at the top of the page that was caused by the floating sidebar.
-*/
-body {
- position: relative;
-}
-div.sphinxsidebar {
- float: none;
- position: absolute;
- right: 0;
-}
More information about the llvm-commits
mailing list