feat: render catalog in a html page
This commit is contained in:
34
catalog.html.j2
Normal file
34
catalog.html.j2
Normal file
@@ -0,0 +1,34 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
|
||||
<title>Cliget Catalog</title>
|
||||
<style>
|
||||
{% include 'styles.css' %}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<p>{{get_context()|length}} entries</p>
|
||||
<table>
|
||||
<thead>
|
||||
<tr><th>name</th><th>repo</th><th>description</th></tr>
|
||||
<thead>
|
||||
<tbody>
|
||||
{% for k,o in get_context().items()%}
|
||||
<tr>
|
||||
<td>
|
||||
<a id="{{k}}" href="#{{k}}"> </a>
|
||||
{%if "website" in o%}<a href="{{o.website}}">{{k}}</a>{%else%}{{k}}{%endif%}
|
||||
</td>
|
||||
<td>
|
||||
{%if "github" in o%}<a href="https://github.com/{{o.github}}">x</a>{%else%} {%endif%}
|
||||
</td>
|
||||
<td><p>{{o.desc}}</p></td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
<table>
|
||||
<p>{{get_context()|length}} entries</p>
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user