diff options
author | Valentin Popov <valentin@popov.link> | 2022-11-10 02:18:30 +0300 |
---|---|---|
committer | Valentin Popov <valentin@popov.link> | 2022-11-10 02:18:30 +0300 |
commit | 06e11038cac44178629ce41ffcc04c2060cc1f09 (patch) | |
tree | 056ed58ea516700a288b36897f8ccc14abfeedcc /templates | |
parent | 2196ad61546f9f91340970c252158ef9dd440bea (diff) | |
download | popov.link-06e11038cac44178629ce41ffcc04c2060cc1f09.tar.xz popov.link-06e11038cac44178629ce41ffcc04c2060cc1f09.zip |
Added a project section
Signed-off-by: Valentin Popov <valentin@popov.link>
Diffstat (limited to 'templates')
-rw-r--r-- | templates/project.html | 10 | ||||
-rw-r--r-- | templates/projects.html | 30 |
2 files changed, 40 insertions, 0 deletions
diff --git a/templates/project.html b/templates/project.html new file mode 100644 index 0000000..c261549 --- /dev/null +++ b/templates/project.html @@ -0,0 +1,10 @@ +{% extends 'base.html' %} + +{% block content %} +<h1>{{ page.title | safe }}</h1> + +<section> + {{ page.content | safe }} +</section> + +{% endblock content %}
\ No newline at end of file diff --git a/templates/projects.html b/templates/projects.html new file mode 100644 index 0000000..b828415 --- /dev/null +++ b/templates/projects.html @@ -0,0 +1,30 @@ +{% extends 'base.html' %} + +{% block content %} +<h1>{{ section.title | safe }}</h1> + +{% for year, projects in section.pages | group_by(attribute='year') %} + +<section> + <h2>{{ year | safe }}</h2> + + <div class="projects"> + {% for project in projects %} + + <div class="project"> + <a href="{{ project.permalink | safe }}"> + {% set preview = resize_image(path=project.extra.preview, width=292, height=219, op='fit') %} + <img src="{{ preview.url | safe }}" alt="preview" width="292" height="219"> + </a> + + <a href="{{ project.permalink | safe }}"> + <div>{{ project.summary | safe }}</div> + </a> + </div> + + {% endfor %} + </div> +</section> +{% endfor %} + +{% endblock content %}
\ No newline at end of file |