Merge branch 'master' of https://github.com/fnp/librarian
[librarian.git] / librarian / epub / xsltTitle.xsl
1 <?xml version="1.0" encoding="UTF-8"?>\r
2 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:dc="http://purl.org/dc/elements/1.1/">\r
3   <xsl:output method="html" version="1.0" encoding="utf-8" />\r
4   <xsl:output doctype-system="http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" />\r
5   <xsl:output doctype-public="-//W3C//DTD XHTML 1.1//EN" />\r
6 \r
7   <xsl:template match="/">\r
8     <html xmlns="http://www.w3.org/1999/xhtml">\r
9       <head>\r
10         <link rel="stylesheet" href="style.css" type="text/css" />\r
11         <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />\r
12         <title>\r
13           <xsl:text>Strona tytuĹ‚owa</xsl:text>\r
14         </title>\r
15       </head>\r
16       <body>\r
17         <div id="book-text" xmlns="http://www.w3.org/1999/xhtml">\r
18           <div class='title-page'>\r
19             <xsl:choose>\r
20               <xsl:when test="//autor_utworu | //nazwa_utworu">\r
21                 <xsl:apply-templates select="//autor_utworu | //nazwa_utworu | //podtytul | //dzielo_nadrzedne" mode="poczatek"/>\r
22               </xsl:when>\r
23               <xsl:otherwise>\r
24                 <xsl:apply-templates select="//dc:creator | //dc:title | //podtytul | //dzielo_nadrzedne" mode="poczatek"/>\r
25               </xsl:otherwise>\r
26             </xsl:choose>\r
27           </div>\r
28           <p class="info">Publikacja zrealizowana w ramach projektu WolneLektury.pl</p>\r
29           <p class="info">\r
30             <img src="logo_wolnelektury.png" alt="WolneLektury.pl" />\r
31           </p>\r
32         </div>\r
33       </body>\r
34     </html>\r
35   </xsl:template>\r
36 \r
37   <xsl:template match="text()" >\r
38     <xsl:value-of select="." disable-output-escaping="yes" />\r
39   </xsl:template>\r
40 \r
41   <xsl:template match="node()" mode="poczatek">\r
42     <xsl:value-of select="." />\r
43   </xsl:template>\r
44 \r
45   <xsl:template match="dc:creator" mode="poczatek">\r
46     <div class="author" xmlns="http://www.w3.org/1999/xhtml">\r
47       <xsl:apply-templates />\r
48     </div>\r
49   </xsl:template>\r
50 \r
51   <xsl:template match="autor_utworu" mode="poczatek">\r
52     <div class="author" xmlns="http://www.w3.org/1999/xhtml">\r
53       <xsl:apply-templates />\r
54     </div>\r
55   </xsl:template>\r
56 \r
57   <xsl:template match="dzielo_nadrzedne" mode="poczatek">\r
58     <div class="collection" xmlns="http://www.w3.org/1999/xhtml">\r
59       <xsl:apply-templates />\r
60     </div>\r
61   </xsl:template>\r
62 \r
63   <xsl:template match="nazwa_utworu" mode="poczatek" >\r
64     <h1 class="title" xmlns="http://www.w3.org/1999/xhtml">\r
65       <xsl:apply-templates />\r
66     </h1>\r
67   </xsl:template>\r
68 \r
69   <xsl:template match="dc:title" mode="poczatek" >\r
70     <h1 class="title" xmlns="http://www.w3.org/1999/xhtml">\r
71       <xsl:apply-templates />\r
72     </h1>\r
73   </xsl:template>\r
74 \r
75   <xsl:template match="podtytul" mode="poczatek">\r
76     <div class="subtitle" xmlns="http://www.w3.org/1999/xhtml">\r
77       <xsl:apply-templates />\r
78     </div>\r
79   </xsl:template>\r
80 \r
81   <xsl:template match="pe|pa|pr|pt" />\r
82 \r
83   <xsl:template match="extra" />\r
84 \r
85   <xsl:template match="pe|pa|pr|pt" />\r
86 \r
87   <xsl:template match="extra" />\r
88 \r
89   <xsl:template match="motyw" />\r
90 \r
91 </xsl:stylesheet>