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