Prepare for showing the album image.
[Sone.git] / src / main / resources / templates / imageBrowser.html
1 <%include include/head.html>
2
3         <div class="page-id hidden">image-browser</div>
4
5         <%if albumRequested>
6
7                 <%ifnull album>
8
9                         <p><%= Page.ImageBrowser.Album.Error.NotFound.Text|l10n|html></p>
10
11                 <%elseifnull album.name>
12
13                         <p><%= Page.ImageBrowser.Album.Error.NotFound.Text|l10n|html></p>
14
15                 <%else>
16
17                         <h1><%= Page.ImageBrowser.Album.Title|l10n|replace needle='{album}' replacementKey=album.name|html></h1>
18
19                         <div class="backlinks">
20                                 <%foreach album.backlinks backlink backlinks>
21                                         <div class="backlink">
22                                                 <a href="<% backlink.target|html>"><% backlink.name|html></a>
23                                         </div>
24                                         <%if ! backlinks.last>
25                                                 <div class="separator">&gt;</div>
26                                         <%/if>
27                                 <%/foreach>
28                         </div>
29
30                         <%foreach album.albums album>
31                                 <div class="album">
32                                         <div class="image">
33                                                 <a href="imageBrowser.html?album=<% album.id|html>">
34                                                         <%ifnull album.image>
35                                                                 <img src="images/unknown-image-0.png" width="200" height="150" alt="<% album.name|html>" title="<% album.name|html>" />
36                                                         <%else><!-- TODO -->
37                                                                 <img src="images/unknown-image-0.png" width="200" height="150" alt="<% album.name|html>" title="<% album.name|html>" />
38                                                         <%/if>
39                                                 </a>
40                                         </div>
41                                 </div>
42                         <%/foreach>
43
44                         <div id="description">
45                                 <% album.description|html>
46                         </div>
47
48                         <%if album.sone.current>
49                                 <%include include/createAlbum.html>
50                         <%/if>
51
52                 <%/if>
53
54         <%elseif imageRequested>
55
56         <%elseif soneRequested>
57
58                 <%ifnull sone>
59
60                         <p><%= Page.ImageBrowser.Sone.Error.NotFound.Text|l10n|html></p>
61
62                 <%else>
63
64                         <h1><%= Page.ImageBrowser.Sone.Title|l10n|replace needle='{sone}' replacementKey=sone.niceName|html></h1>
65
66                         <%foreach sone.albums album>
67                                 <div class="album">
68                                         <div class="image">
69                                                 <a href="imageBrowser.html?album=<% album.id|html>">
70                                                         <%ifnull album.image>
71                                                                 <img src="images/unknown-image-0.png" width="200" height="150" alt="<% album.name|html>" title="<% album.name|html>" />
72                                                         <%else><!-- TODO -->
73                                                                 <img src="images/unknown-image-0.png" width="200" height="150" alt="<% album.name|html>" title="<% album.name|html>" />
74                                                         <%/if>
75                                                 </a>
76                                         </div>
77                                 </div>
78                         <%/foreach>
79
80                         <%if sone.current>
81                                 <%include include/createAlbum.html>
82                         <%/if>
83
84                 <%/if>
85
86         <%/if>
87
88 <%include include/tail.html>