aboutsummaryrefslogtreecommitdiff
path: root/tmpl/index.tmpl
diff options
context:
space:
mode:
Diffstat (limited to 'tmpl/index.tmpl')
-rw-r--r--tmpl/index.tmpl86
1 files changed, 84 insertions, 2 deletions
diff --git a/tmpl/index.tmpl b/tmpl/index.tmpl
index 08a86af..366edd1 100644
--- a/tmpl/index.tmpl
+++ b/tmpl/index.tmpl
@@ -27,6 +27,26 @@
<link rel="stylesheet" href="/static/style.css" />
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
+ <style>
+ .tp-columns {
+ display: flex;
+ flex-direction: row;
+ @media(max-width: 50rem) {
+ flex-wrap: wrap;
+ gap: 0rem;
+ }
+ gap: 2rem;
+ align-items: stretch;
+ }
+
+ .tp-columns div {
+ min-width: 18em;
+ /* max-width: 40rem; */
+ width: 100%;
+ margin-left: auto;
+ margin-right: auto;
+ }
+ </style>
</head>
<body>
<header>
@@ -41,8 +61,70 @@
</div>
</div>
</header>
- <main>
- e
+ <main class="tp-columns">
+ <div class="tp-columns">
+ <div id="yours">
+ <table class="wide">
+ <tr>
+ <th colspan=3>Your Works</th>
+ </tr>
+ {{- /* TODO: It's better to use a caption but it's too hard to get the formatting right */ -}}
+ <tr>
+ <th class="min" scope="col">ID</th>
+ <th class="min" scope="col">Flags</th>
+ <th scope="col">Title</th>
+ </tr>
+ {{- /*
+ {% for w in wyours %}
+ <tr>
+ <th scope="row" class="min">{{ w.id }}</th>
+ <td class="min flags">{%if w.public%}<abbr title="Public">P</abbr>{%else%}<abbr title="Private">x</abbr>{%endif%}{%if w.active%}<abbr title="Active">!</abbr>{%else%}<abbr title="Inactive">-</abbr>{%endif%}{%if w.anonymous%}<abbr title="Anonymous">*</abbr>{%else%}<abbr title="Non-anonymous"</abbr>@</abbr>{%endif%}</td>
+ <td><a href="{{ url_for(".work", id=w.id) }}">{{ w.title }}</a></td>
+ </tr>
+ {% endfor %}
+ */ -}}
+ <tr>
+ <th colspan="3">
+ <div class="flex-justify">
+ <a class="btn-primary btn" href="{{- /* url_for(".new") */ -}}">New</a>
+ </div>
+ </th>
+ </tr>
+ </table>
+ </div>
+ <div id="others">
+ <table class="wide">
+ <tr>
+ <th colspan=3>Active Works from Others</th>
+ </tr>
+ <tr>
+ <th class="min" scope="col">ID</th>
+ <th class="min" scope="col">Author</th>
+ <th scope="col">Title</th>
+ </tr>
+ {{- /*
+ {% for w in wothers %}
+ <tr>
+ <th scope="row" class="min">{{ w.id }}</th>
+ {% if w.anonymous %}
+ <td class="min anonymous">Anonymous</td>
+ {% else %}
+ <td class="min"><a href="{{ url_for(".user", oid=w.user.oid) }}">{{ w.user.name }}</a></td>
+ {% endif %}
+ <td><a href="{{ url_for(".work", id=w.id) }}">{{ w.title }}</a></td>
+ </tr>
+ {% endfor %}
+ */ -}}
+ <tr>
+ <th colspan="3">
+ <div class="flex-justify">
+ <a class="btn-primary btn" href="{{- /* url_for(".list_") */ -}}">List all</a>
+ </div>
+ </th>
+ </tr>
+ </table>
+ </div>
+ </div>
</main>
</body>
</html>