[libvirt] [PATCH] docs: Space out entries in news.html

Peter Krempa pkrempa at redhat.com
Fri Jun 21 08:06:01 UTC 2019


The header for the news entry blends together with the text and other
entries. This patch tries to space them out somewhat for better visual
separation.

Signed-off-by: Peter Krempa <pkrempa at redhat.com>
---

You can see the difference here:

https://github.com/pipo/libvirt/blob/screenshots/before.png
https://github.com/pipo/libvirt/blob/screenshots/after.png

 docs/libvirt.css   | 15 +++++++++++++++
 docs/news-html.xsl | 13 +++++++++----
 2 files changed, 24 insertions(+), 4 deletions(-)

diff --git a/docs/libvirt.css b/docs/libvirt.css
index 4c7afc4042..e44ef616d8 100644
--- a/docs/libvirt.css
+++ b/docs/libvirt.css
@@ -591,3 +591,18 @@ td.enumvalue {
 .deprecatedhv {
     color: darkred;
 }
+
+ul.news-section {
+    margin-top: 0.5em;
+}
+
+ul.news-section li dl dt {
+    margin: 0;
+}
+
+ul.news-section li dl dd {
+    margin-left: 1em;
+    margin-right: 0;
+    margin-top: 0.5em;
+    margin-bottom: 0.5em;
+}
diff --git a/docs/news-html.xsl b/docs/news-html.xsl
index 4d40798028..fb0178f9e2 100644
--- a/docs/news-html.xsl
+++ b/docs/news-html.xsl
@@ -58,7 +58,7 @@
         <xsl:value-of select="@title"/>
       </strong>
       <xsl:if test="*">
-        <ul>
+        <ul class="news-section">
           <xsl:apply-templates select="change"/>
         </ul>
       </xsl:if>
@@ -68,8 +68,14 @@
   <!-- Change -->
   <xsl:template match="change">
     <li>
-      <xsl:apply-templates select="summary"/>
-      <xsl:apply-templates select="description"/>
+      <dl>
+        <dt>
+          <xsl:apply-templates select="summary"/>
+        </dt>
+        <dd>
+          <xsl:apply-templates select="description"/>
+        </dd>
+      </dl>
     </li>
   </xsl:template>

@@ -80,7 +86,6 @@

   <!-- Change description -->
   <xsl:template match="description">
-    <br/>
     <xsl:apply-templates/>
   </xsl:template>

-- 
2.21.0




More information about the libvir-list mailing list