Include a smaller album preview in replies
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 1 Aug 2015 20:58:26 +0000 (22:58 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 1 Aug 2015 20:58:26 +0000 (22:58 +0200)
src/main/resources/templates/include/viewReply.html

index ec8b447..765b03f 100644 (file)
                        <%if !shortText|match value=parsedText><%if !raw><a class="expand-reply-text" href="viewPost.html?post=<% reply.postId|html>&amp;raw=true"><%= View.Post.ShowMore|l10n|html></a><%/if><%/if>
                        <%if !shortText|match value=parsedText><%if !raw><a class="shrink-reply-text hidden"><%= View.Post.ShowLess|l10n|html></a><%/if><%/if>
                </div>
+               <%foreach parts part>
+                       <%if part.class.simpleName|match value==AlbumPart><!-- ← this is so ugly. -->
+                               <% part.album.images.random|store key==image>
+                               <div class="album images" style="zoom: 0.80;">
+                                       <%include include/viewAlbum.html album=part.album hideMoveButtons==true>
+                               </div>
+                       <%/if>
+               <%/foreach>
                <div class="reply-status-line status-line">
                        <div class="time"><% reply.time|date format=="MMM d, yyyy, HH:mm:ss"></div>
                        <span class='separator'>·</span>