redsunlib/templates/post.html

70 lines
2.5 KiB
HTML
Raw Normal View History

2020-10-26 09:25:59 +13:00
<html>
<head>
<title>{{ post.title }} - r/{{ post.community }}</title>
<meta name="author" content="u/{{ post.author }}">
<meta name="description" content="View on Libreddit, an alternative private front-end to Reddit.">
2020-10-26 15:05:09 +13:00
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
2020-10-26 09:25:59 +13:00
<link rel="stylesheet" href="/style.css">
<style>
2020-10-26 15:05:09 +13:00
#sort > #sort_{{ sort }} {
2020-10-26 09:25:59 +13:00
background: aqua;
color: black;
2020-10-26 15:05:09 +13:00
}
2020-10-26 09:25:59 +13:00
</style>
</head>
<body>
<header>
<a href="/"><span style="color:white">lib</span>reddit.</a>
<a style="color:white" href="https://github.com/spikecodes/libreddit">GITHUB</a>
</header>
<main>
<div class="post" style="border: 2px solid #555;background: #222;">
<div class="post_left" style="background: #333;">
<button class="post_upvote"></button>
<h3 class="post_score">{{ post.score }}</h3>
<button class="post_upvote"></button>
</div>
<div class="post_right">
<p>
<b><a class="post_subreddit" href="/r/{{ post.community }}">r/{{ post.community }}</a></b>
&bull;
Posted by
<a class="post_author" href="/u/{{ post.author }}">u/{{ post.author }}</a>
<span style="float: right;">{{ post.time }}</span>
</p>
2020-11-17 15:49:08 +13:00
<h3 class="post_title">
{{ post.title }}
{% if post.flair.0 != "" %}
<small style="color:{{ post.flair.2 }}; background:{{ post.flair.1 }}">{{ post.flair.0 }}</small>
{% endif %}
</h3>
2020-10-26 09:25:59 +13:00
{{ post.media }}
<h4 class="post_body">{{ post.body }}</h4>
</div>
</div>
<div id="sort">
<div id="sort_confidence"><a href="{{ post.url }}confidence">Best</a></div>
<div id="sort_top"><a href="{{ post.url }}top">Top</a></div>
<div id="sort_new"><a href="{{ post.url }}new">New</a></div>
<div id="sort_controversial"><a href="{{ post.url }}controversial">Controversial</a></div>
<div id="sort_old"><a href="{{ post.url }}old">Old</a></div>
</div>
{% for comment in comments %}
<div class="comment">
<div class="comment_left">
<button class="comment_upvote"></button>
<h3 class="comment_score">{{ comment.score }}</h3>
<button class="comment_upvote"></button>
</div>
<div class="comment_right">
<p>
Posted by <a class="comment_author" href="/u/{{ comment.author }}">u/{{ comment.author }}</a>
<span style="float: right;">{{ comment.time }}</span>
</p>
<h4 class="comment_body">{{ comment.body }}</h4>
</div>
</div><br>
{% endfor %}
</main>
</body>
</html>