Remove the gray background and switch to underlined links.
This change is done by using the fact that docutils name the top level
element based on the pagee name. This means that in the stylesheet we
can apply selectors directly to the specific page.
This removes the need to have a RST 'container' named 'panel' in the
file.
Specific selectors are used only for elements on the directory page.
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
---
docs/kbase.rst | 2 +-
docs/libvirt.css | 20 ++++++++------------
2 files changed, 9 insertions(+), 13 deletions(-)
diff --git a/docs/kbase.rst b/docs/kbase.rst
index 78daaa5989..8f888c27cd 100644
--- a/docs/kbase.rst
+++ b/docs/kbase.rst
@@ -2,7 +2,7 @@
Knowledge base
==============
-.. container:: panel widepanel
+.. container::
`Debug logs <kbase/debuglogs.html>`__
Configuration of logging and tips on how to file a good bug report.
diff --git a/docs/libvirt.css b/docs/libvirt.css
index 3d94029787..01627f2113 100644
--- a/docs/libvirt.css
+++ b/docs/libvirt.css
@@ -402,14 +402,6 @@ div.panel {
background: rgb(230, 230, 230);
}
-div.widepanel {
- width: 70em;
- max-width: 95%;
- margin-left: 0px;
- float: left;
- background: rgb(230, 230, 230);
-}
-
div.panel h2 {
margin-top: 0px;
padding: 0.5em;
@@ -479,7 +471,8 @@ br.clear {
font-size: smaller;
}
-div.panel dd {
+div.panel dd,
+#knowledge-base dd {
font-size: smaller;
}
@@ -489,7 +482,8 @@ div.panel a {
div.panel ul,
div.panel p,
-div.panel dl {
+div.panel dl,
+#knowledge-base p {
padding: 0.5em;
margin: 0px;
}
@@ -498,10 +492,12 @@ div.panel dl {
div.panel ul {
margin-left: 1em;
}
-div.panel dt {
+div.panel dt,
+#knowledge-base dt {
margin: 0px;
}
-div.panel dd {
+div.panel dd,
+#knowledge-base dd {
margin: 0px;
margin-bottom: 1em;
}
--
2.26.2
On a Monday in 2020, Peter Krempa wrote: >Remove the gray background and switch to underlined links. > Here, I prefer the old look. The difference with the ToC might be that the ToC entries are indented. >This change is done by using the fact that docutils name the top level >element based on the pagee name. This means that in the stylesheet we *page >can apply selectors directly to the specific page. > >This removes the need to have a RST 'container' named 'panel' in the >file. > >Specific selectors are used only for elements on the directory page. > >Signed-off-by: Peter Krempa <pkrempa@redhat.com> >--- > docs/kbase.rst | 2 +- > docs/libvirt.css | 20 ++++++++------------ > 2 files changed, 9 insertions(+), 13 deletions(-) > Jano
On Mon, Aug 03, 2020 at 14:30:30 +0200, Ján Tomko wrote: > On a Monday in 2020, Peter Krempa wrote: > > Remove the gray background and switch to underlined links. > > > > Here, I prefer the old look. The difference with the ToC might be > that the ToC entries are indented. Both links and background? In case you prefer the old links I might want to get rid of the background at least.
On a Monday in 2020, Peter Krempa wrote: >On Mon, Aug 03, 2020 at 14:30:30 +0200, Ján Tomko wrote: >> On a Monday in 2020, Peter Krempa wrote: >> > Remove the gray background and switch to underlined links. >> > >> >> Here, I prefer the old look. The difference with the ToC might be >> that the ToC entries are indented. > >Both links and background? In case you prefer the old links I might want >to get rid of the background at least. > Sorry, I only compared the overall look. After some experimenting, what concerns me most is the spacing: In the old version the gray panel aligns with the 'Knowledge base' heading. In the white one, the K aligns with 'Debug logs' and it's too close to the heading. So I miss mostly: padding: 0.5 em; that came from the panel. 1. I'm okay with dropping the gray background, since the kbase page is different. (The bikeshedding question is: will we eventually fill it enough to warrant a return of the gray panels and put three of them on a computer screen?) 2. The 0.5 em padding should stay (I guess keeping another panel class for this makes sense then. 3. The links look slightly better and more consistent with the rest of the website with text-decoration: none; but I don't have a strong preference here - we do have underlined links on white background elsewhere. Unrelated to this patch: 4. We have a 0.5 em padding for both `div.panel dl` and `div.panel p`, which add up to 1 em for the paragraphs inside `dd`. Since what we're adding there should be a one-sentence description of the document, can we somehow convince the rst tools not to put a paragraph there? Or just adjust the padding back for `div.panel p dd`? HTML, I'll be missing you. Jano
On Tue, Aug 04, 2020 at 01:13:16PM +0200, Ján Tomko wrote: > On a Monday in 2020, Peter Krempa wrote: > > On Mon, Aug 03, 2020 at 14:30:30 +0200, Ján Tomko wrote: > > > On a Monday in 2020, Peter Krempa wrote: > > > > Remove the gray background and switch to underlined links. > > > > > > > > > > Here, I prefer the old look. The difference with the ToC might be > > > that the ToC entries are indented. > > > > Both links and background? In case you prefer the old links I might want > > to get rid of the background at least. > > > > Sorry, I only compared the overall look. > > After some experimenting, what concerns me most is the spacing: > > In the old version the gray panel aligns with the 'Knowledge base' > heading. > > In the white one, the K aligns with 'Debug logs' and it's too close > to the heading. > > So I miss mostly: > padding: 0.5 em; > that came from the panel. > > 1. I'm okay with dropping the gray background, since the kbase page is > different. (The bikeshedding question is: will we eventually fill it > enough to warrant a return of the gray panels and put three of them > on a computer screen?) As we migrate the wiki content it'll mostly end up in the kbase, and I expect we'll want to split the kbase index into a series of groups with panels, like we do for the main docs page and front page. This was the main reason why I had the page rendered the way it currently is. Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
© 2016 - 2026 Red Hat, Inc.