draft initial http application

This commit is contained in:
yggverse 2026-01-07 23:25:02 +02:00
parent 4c99208535
commit 353c78b2f0
12 changed files with 406 additions and 0 deletions

View file

@ -0,0 +1,24 @@
{% extends "layout" %}
{% block content %}
{% if rows %}
{% for row in rows %}
<div>
<a name="{{ row.content_id }}"></a>
<h2><a href="/{{ row.link }}">{{ row.title }}</a></h2>
{% if row.time %}<p>{{ row.time }}</p>{% endif %}
<div>
{{ row.description }}
</div>
</div>
{% endfor %}
{% else %}
<div>Nothing.</div>
{% endif %}
{% if next %}<a href="{{ next }}">Next</a>{% endif %}
{% if back %}<a href="{{ back }}">Back</a>{% endif %}
{% if total %}
<span>
Page {{ page }} / {{ pages }} ({{ total }} torrent{{ total | pluralize(plural="s") }} total)
</span>
{% endif %}
{% endblock content %}

View file

@ -0,0 +1,12 @@
{% extends "layout" %}
{% block content %}
<div>
<h1>{{ title }}</h1>
<div>
{{ description }}
</div>
<div>
<a href="{{ link }}">{{ time }}</a>
</div>
</div>
{% endblock content %}

View file

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>{{ title }}</title>
{% if meta.description %}
<meta name="description" content="{{ meta.description }}" />
{% endif %}
</head>
<body>
<header>
<a href="/">{{ meta.title }}</a>
<form action="/" method="GET">
<input type="text" name="search" value="{% if search %}{{ search }}{% endif %}" placeholder="Keyword..." />
<input type="submit" value="Search" />
</form>
</header>
<main>
{% block content %}{% endblock content %}
</main>
</body>
</html>