diff options
Diffstat (limited to 'templates/web/index.html')
-rw-r--r-- | templates/web/index.html | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/templates/web/index.html b/templates/web/index.html new file mode 100644 index 0000000..1d1d869 --- /dev/null +++ b/templates/web/index.html @@ -0,0 +1,32 @@ +{% extends "base.html" %} + +{% block title %}{{ settings.name }}{% endblock %} + +{% block content %} + <header> + <h1>{{ settings.name }}</h1> + <aside><form method="get" action="{{ url_for('search') }}"><input name="q" value="{{ q }}"><input type="submit" value="Search"></form></aside> + </header> + <ul> + {% for entry in entries %} + <li id="{{ entry.eid }}"> + <a href="{{ url_for('entry', eid=entry.eid) }}">{{ entry }}</a> + </li> + {% endfor %} + </dl> + {% if entries|count == 0 %} + <h4>no results</h4> + {% endif %} + <footer> + <nav> + {% if entries|count > 0 %} + {% if q %} + <a href="{{ url_for('search', q=q, p=page+1) }}">more</a> + {% else %} + <a href="{{ url_for('index', p=page+1) }}">more</a> + {% endif %} + {% endif %} + </nav> + </footer> +{% endblock %} + |