changeset 129:523a80fc32b4

Fixed a fallout from switching to standard HTML.
author Ruslan Ermilov <ru@nginx.com>
date Fri, 21 Oct 2011 14:00:34 +0000
parents 5530e24f9d58
children 3052a722a1a4
files xsls/news.xsls xsls/style.xsls
diffstat 2 files changed, 14 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/xsls/news.xsls	Fri Oct 21 09:51:45 2011 +0000
+++ b/xsls/news.xsls	Fri Oct 21 14:00:34 2011 +0000
@@ -45,21 +45,25 @@
     X:var year = { !{substring(../event[position()=1]/@date, 1, 4)} }
     X:var y = { !{substring(@date, 1, 4)} }
 
-    X:if "(not($YEAR) and ($year = $y or position() &lt; 11)) or $YEAR=$y" {
-        <table width="100%">
+    X:if "position() = 1" {
+        X:text disable-output-escaping="yes" {
+            &lt;table class="news"&gt;
+        }
+    }
 
+    X:if "(not($YEAR) and ($year = $y or position() &lt; 11)) or $YEAR=$y" {
         <tr>
-        <td valign="top" align="right" width="15%">
+        <td align="right">
             <a name="{@date}" /> !{@date} X:text {&#xA0;&#xA0;}
         </td>
         <td> !! "para"; </td>
         </tr>
+    }
 
-        <tr><td colspan="2">
-        X:text disable-output-escaping="yes" {&amp;nbsp;}
-        </td></tr>
-
-        </table>
+    X:if "position() = last()" {
+        X:text disable-output-escaping="yes" {
+            &lt;/table&gt;
+        }
     }
 }
 
--- a/xsls/style.xsls	Fri Oct 21 09:51:45 2011 +0000
+++ b/xsls/style.xsls	Fri Oct 21 14:00:34 2011 +0000
@@ -6,6 +6,8 @@
         html              { -webkit-text-size-adjust: none; }
         body              { font-family:    Georgia, serif; }
         p                 { text-align:     justify; }
+        table.news p      { margin-top:     0; }
+        table.news td     { vertical-align: top; }
         div.directive     { background:     #EEEEEE;
                             padding:        10pt 10pt 10pt 20pt; }
         div.directive td  { vertical-align: baseline; }