blob: d5948e3c48d6386d6d2da5063a8868b9e77caa59 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
[[ media.forEach(function(media){ ]]
<div class="media">
[[ if (media.type == "image") { ]]
<a class="medialink" href="[[- media.url ]]" target="_blank"><img src="[[- media.url ]]"></a>
[[ } else { ]]
<a class="medialink" href="[[- media.url ]]" target="_blank">[[- media.shortUrl ]]</a>
[[ } ]]
<br>
<a href="/staff/media/[[- media._id ]]">[view]</a>
<a href="/staff/users/[[- media.user.username ]]">[[- media.user.username ]]</a>
[[- media.date ]]
</div>
[[ }) ]]
</table>
<style>
.media {
height: 28vw;
width: 24vw;
margin: 1vw;
display: inline-block;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.staff .body a.medialink {
width: 24vw;
height: 24vw;
display: block;
overflow: hidden;
color: #00f;
border: 0;
text-decoration: underline;
}
.staff .body a.medialink img {
max-width: 100%;
}
</style>
|