szurubooru/client/html/home.tpl
rr- 54e3099c56 client/general: refactor control flow
- Controller lifetime is bound to route lifetime
- View lifetime is bound to controller lifetime
- Control lifetime is bound to view lifetime
- Enhanced event dispatching
- Enhanced responsiveness in some places
- Views communicate user input to controllers via new event system
2016-06-18 10:35:20 +02:00

33 lines
1.2 KiB
Smarty

<div class='content-wrapper transparent' id='home'>
<div class='messages'></div>
<header>
<h1><%= ctx.name %></h1>
<aside class='stats-container'></aside>
</header>
<% if (ctx.canListPosts) { %>
<form class='horizontal'>
<div class='input'>
<%= ctx.makeButton({name: 'all-posts', value: 'Browse all posts'}) %>
<span class='separator'>or</span>
<%= ctx.makeTextInput({name: 'search-text', placeholder: 'enter some tags'}) %>
</div>
<div class='buttons'>
<input type='submit' value='Search'/>
</div>
</form>
<% } %>
<% if (ctx.featuredPost) { %>
<aside>
Featured post: <%= ctx.makePostLink(ctx.featuredPost.id) %>,
posted
<%= ctx.makeRelativeTime(ctx.featuredPost.creationTime) %>
by
<%= ctx.makeUserLink(ctx.featuredPost.user) %>
</aside>
<% } %>
<div class='post-container'></div>
<footer>
Build <a class='version' href='https://github.com/rr-/szurubooru/commits/master'><%= ctx.version %></a>
from <%= ctx.makeRelativeTime(ctx.buildDate) %>
</footer>
</div>