Only show the album image
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 25 Jul 2015 14:57:31 +0000 (16:57 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 25 Jul 2015 14:57:31 +0000 (16:57 +0200)
src/main/resources/i18n/sone.en.properties
src/main/resources/static/css/sone.css
src/main/resources/templates/include/viewPost.html

index f8f3211..12927a5 100644 (file)
@@ -370,7 +370,7 @@ View.Post.ShowSource=Toggle Parser
 View.Post.NotDownloaded=This post has not yet been downloaded, or it has been deleted.
 View.Post.ShowMore=show more
 View.Post.ShowLess=show less
-View.Post.LinkedAlbum.SizeAndAuthor={1,number} by {0}
+View.Post.LinkedAlbum.SizeAndAuthor={1,number} {1,choice,0#images|1#image|1<images} by [link]{0}[/link]
 
 View.UpdateStatus.Text.ChooseSenderIdentity=Choose the sender identity
 
index b7ae3b7..8b588b8 100644 (file)
@@ -355,6 +355,7 @@ textarea {
 
 #sone .post .linked-album {
        display: table;
+       margin-top: 1ex;
        border-collapse: collapse;
 }
 
@@ -392,8 +393,12 @@ textarea {
 }
 
 #sone .post .linked-image .about-image .title {
+       font-size: 110%;
        font-weight: bold;
-       margin-bottom: 0.5ex;
+}
+
+#sone .post .linked-image .about-image .description {
+       margin-top: 0.5ex;
 }
 
 #sone .post .status-line {
index 1b8d1ad..d150d4f 100644 (file)
                        <%if !shortText|match value=parsedText><%if !raw><a class="shrink-post-text hidden"><%= View.Post.ShowLess|l10n|html></a><%/if><%/if>
                </div>
                <%foreach parts part>
-                       <%if part.class.simpleName|match value==AlbumPart>
+                       <%if part.class.simpleName|match value==AlbumPart><!-- ← this is so ugly. -->
                                <div class="linked-album">
-                                       <div class="album-header">
-                                               <div class="album-title"><% part.album.title|html></div>
-                                               <div class="album-author"><%= View.Post.LinkedAlbum.SizeAndAuthor|l10n 0=part.album.sone.niceName 1=part.album.images.size|html></div>
-                                       </div>
-                                       <%foreach part.album.images image>
-                                               <div class="linked-image">
-                                                       <div class="image-left">
-                                                               <div class="image">
-                                                                       <a href="imageBrowser.html?image=<%image.id|html>"><% image|image-link max-width==160 max-height==90 mode==enlarge title=image.title></a>
-                                                               </div>
-                                                       </div>
-                                                       <div class="about-image">
-                                                               <div class="title"><% image.title|html></div>
-                                                               <div class="description"><% image.description|parse sone=post.sone|render></div>
+                                       <div class="linked-image">
+                                               <div class="image-left">
+                                                       <div class="image">
+                                                               <a href="imageBrowser.html?album=<% part.album.id|html>"><% part.album.albumImage|image-link max-width==160 max-height==90 mode==enlarge title=part.album.title></a>
                                                        </div>
                                                </div>
-                                       <%/foreach>
+                                               <div class="about-image">
+                                                       <div class="title"><% part.album.title|html></div>
+                                                       <div><% =View.Post.LinkedAlbum.SizeAndAuthor|l10n 0=part.album.sone.niceName 1=part.album.images.size|html|replace needle=="[link]" replacement=='<a href="viewSone.html?sone=<sone-id>">'|replace needle=='[/link]' replacement=='</a>'|replace needle=='<sone-id>' replacement=part.album.sone.id></div>
+                                                       <div class="description"><% part.album.description|parse sone=part.album.sone|render></div>
+                                               </div>
+                                       </div>
                                </div>
                        <%/if>
                <%/foreach>