szurubooru/client/html/snapshots_page.tpl

32 lines
1.3 KiB
Smarty
Raw Normal View History

<div class='snapshot-list'>
2017-02-09 00:48:06 +01:00
<% if (ctx.response.results.length) { %>
<ul>
2017-02-09 00:48:06 +01:00
<% for (let item of ctx.response.results) { %>
<li>
<div class='header operation-<%= item.operation %>'>
<span class='time'>
<%= ctx.makeRelativeTime(item.time) %>
</span>
<%= ctx.makeUserLink(item.user) %>
<%= item.operation %>
<%= ctx.makeResourceLink(item.type, item.id) %>
</div>
<div class='details'><!--
--><% if (item.operation === 'created') { %><!--
--><%= ctx.makeItemCreation(item.type, item.data) %><!--
--><% } else if (item.operation === 'modified') { %><!--
--><%= ctx.makeItemModification(item.type, item.data) %><!--
--><% } else if (item.operation === 'merged') { %><!--
-->Merged to <%= ctx.makeResourceLink(item.data[0], item.data[1]) %><!--
--><% } %><!--
--></div>
</li>
<% } %>
</ul>
<% } %>
</div>