[exim-cvs] Added ToC link to bottom nav bar and chapter titl…

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Exim Git Commits Mailing List
Fecha:  
A: exim-cvs
Asunto: [exim-cvs] Added ToC link to bottom nav bar and chapter title
Gitweb: http://git.exim.org/exim-website.git/commitdiff/7dafcc0c48188949d5742fa4ce5ab1b279a4a5df
Commit:     7dafcc0c48188949d5742fa4ce5ab1b279a4a5df
Parent:     5e3d220fcfd14b6953ee72a3df1f4737a4ce86f9
Author:     Nigel Metheringham <nigel.metheringham@???>
AuthorDate: Sat Jun 9 20:44:22 2012 +0100
Committer:  Nigel Metheringham <nigel.metheringham@???>
CommitDate: Sat Jun 9 20:44:22 2012 +0100


    Added ToC link to bottom nav bar and chapter title
---
 templates/doc/chapter.xsl     |   15 ++++++++++-----
 templates/web/doc/chapter.css |    9 ++++++++-
 2 files changed, 18 insertions(+), 6 deletions(-)


diff --git a/templates/doc/chapter.xsl b/templates/doc/chapter.xsl
index f715219..06e320d 100644
--- a/templates/doc/chapter.xsl
+++ b/templates/doc/chapter.xsl
@@ -41,8 +41,8 @@

          <!-- Navigation -->
          <a class="previous_page" href="{prev_url}"><![CDATA[<-previous]]></a>
-     <xsl:if test="next_url">
-            <a class="next_page" href="{next_url}"><![CDATA[next->]]></a>
+         <xsl:if test="next_url">
+            <a class="next_page"  href="{next_url}"><![CDATA[next->]]></a>
          </xsl:if>


          <!-- Chapter Wrapper -->
@@ -60,7 +60,9 @@


             <!-- Chapter Title -->
             <h2 id="{@id}" class="{@class}">
-               <xsl:value-of select="concat('Chapter ',chapter_id,' - ',title)"/>
+               <a href="{toc_url}">
+                  <xsl:value-of select="concat('Chapter ',chapter_id,' - ',title)"/>
+               </a>
             </h2>


             <!-- Chapter Info -->
@@ -70,7 +72,10 @@


          <!-- Navigation -->
             <a class="previous_page" href="{prev_url}"><![CDATA[<-previous]]></a>
-            <a class="next_page"     href="{next_url}"><![CDATA[next->]]></a>
+            <a class="toc_page"      href="{prev_url}"><![CDATA[Table of Contents]]></a>
+            <xsl:if test="next_url">
+               <a class="next_page"  href="{next_url}"><![CDATA[next->]]></a>
+            </xsl:if>


       </xsl:template>


@@ -107,6 +112,6 @@
       </xsl:template>


    <!-- Ignore -->
-      <xsl:template match="chapter_id|prev_url|next_url|canonical_url|current_url|old_versions"/>
+      <xsl:template match="chapter_id|prev_url|next_url|toc_url|canonical_url|current_url|old_versions"/>


</xsl:stylesheet>
diff --git a/templates/web/doc/chapter.css b/templates/web/doc/chapter.css
index 3eab804..9f9b22e 100644
--- a/templates/web/doc/chapter.css
+++ b/templates/web/doc/chapter.css
@@ -33,7 +33,7 @@ body.no-js #old_version_warning span.closebar {
display: none;
}

-.previous_page, .next_page {
+.previous_page, .next_page, .toc_page {
   font-size:      1.2em;
 }


@@ -47,6 +47,13 @@ body.no-js #old_version_warning span.closebar {
   clear:        right;
 }


+.toc_page {
+  position:     absolute;
+  right:        13em;
+  left:         13em;
+  text-align:   center;
+}
+
 #chapter {
   line-height: 1.5;
 }