2022-11-28 23:22:25 -05:00
|
|
|
% layout 'default';
|
2022-09-20 21:16:42 -04:00
|
|
|
% title "Thread #$thread->{'id'}";
|
2022-08-24 00:35:35 -04:00
|
|
|
<h2><%= title %></h2>
|
|
|
|
<div class="threads">
|
|
|
|
<article class="thread">
|
2022-09-20 21:16:42 -04:00
|
|
|
<h3 class="title"><%= $thread->{'title'} %></h3>
|
|
|
|
<h4 class="date"><%= $thread->{'date'} %></h4>
|
|
|
|
<h5 class="author"><%= $thread->{'author'} %></h5>
|
2023-05-03 21:05:57 -04:00
|
|
|
<div class="body">
|
|
|
|
<%== markdown $thread->{'body'} =%>
|
|
|
|
</div>
|
2022-08-24 00:35:35 -04:00
|
|
|
</article>
|
|
|
|
</div>
|
|
|
|
<nav>
|
2022-10-01 18:00:23 -04:00
|
|
|
<%= link_to Remark => post_remark => {thread_id => $thread->{'id'}} %>
|
2022-10-08 23:01:05 -04:00
|
|
|
<%= link_to Bump => bump_thread => {thread_id => $thread->{'id'}} %>
|
2022-10-13 23:57:58 -04:00
|
|
|
<%= link_to Flag => flag_thread => {thread_id => $thread->{'id'}} %>
|
2022-08-24 00:35:35 -04:00
|
|
|
</nav>
|
2022-12-08 01:13:59 -05:00
|
|
|
<% if (is_mod) { =%>
|
|
|
|
<nav>
|
|
|
|
<%= link_to Hide => hide_thread => {thread_id => $thread->{'id'}} %>
|
|
|
|
<%= link_to Unhide => unhide_thread => {thread_id => $thread->{'id'}} %>
|
|
|
|
<%= link_to Unflag => unflag_thread => {thread_id => $thread->{'id'}} %>
|
|
|
|
</nav>
|
|
|
|
<% } =%>
|
2022-09-20 21:16:42 -04:00
|
|
|
<% if (my $first_remark = $remarks->[0]) { =%>
|
2022-10-08 22:39:54 -04:00
|
|
|
<div class="remarks" id="remarks">
|
2022-08-24 00:35:35 -04:00
|
|
|
<h3>Remarks</h3>
|
2022-09-20 21:16:42 -04:00
|
|
|
<% for my $remark (@{$remarks}) { =%>
|
2022-08-24 00:35:35 -04:00
|
|
|
<article class="remark">
|
2022-09-21 01:28:50 -04:00
|
|
|
<nav class="id">
|
2022-09-03 13:05:54 -04:00
|
|
|
<%= link_to "#$remark->{'id'}",
|
2022-10-01 18:00:23 -04:00
|
|
|
single_remark => {remark_id => $remark->{'id'}} %>
|
2022-09-21 01:28:50 -04:00
|
|
|
</nav>
|
2022-09-20 21:16:42 -04:00
|
|
|
<h4 class="date"><%= $remark->{'date'} %></h4>
|
|
|
|
<h5 class="author"><%= $remark->{'author'} %></h5>
|
2023-05-03 21:05:57 -04:00
|
|
|
<div class="body">
|
|
|
|
<%== markdown $remark->{'body'} =%>
|
|
|
|
</div>
|
2023-04-24 23:00:09 -04:00
|
|
|
<nav class="flag">
|
2022-10-13 23:57:58 -04:00
|
|
|
<%= link_to Flag => flag_remark => {remark_id => $remark->{'id'}} %>
|
|
|
|
</nav>
|
2022-08-24 00:35:35 -04:00
|
|
|
</article>
|
|
|
|
<% } =%>
|
|
|
|
</div>
|
2022-09-21 01:28:50 -04:00
|
|
|
<nav>
|
2022-10-01 18:00:23 -04:00
|
|
|
<%= link_to Remark => post_remark => {thread_id => $thread->{'id'}} %>
|
2022-09-21 01:28:50 -04:00
|
|
|
</nav>
|
2022-08-24 00:35:35 -04:00
|
|
|
<nav>
|
|
|
|
<% if ($last_page && $last_page != 1) { =%>
|
|
|
|
<%= pagination $this_page, $last_page, ($base_path . '/{page}') %>
|
2022-08-24 22:15:52 -04:00
|
|
|
<% } =%>
|
2022-08-24 00:35:35 -04:00
|
|
|
</nav>
|
|
|
|
<% } =%>
|