From f9a1509375bb1e05365c0a913efd8babab3ef362 Mon Sep 17 00:00:00 2001 From: Katharina Fey Date: Mon, 22 Jan 2018 22:33:28 +0100 Subject: Cleaning up templates SIGNIFICANTLY --- crumbs/templates/article.html | 10 ++---- crumbs/templates/base.html | 35 +++--------------- crumbs/templates/category.html | 19 ++++------ crumbs/templates/home.html | 80 ++++++++++++++++-------------------------- crumbs/templates/normal.html | 21 +++++++++++ 5 files changed, 66 insertions(+), 99 deletions(-) diff --git a/crumbs/templates/article.html b/crumbs/templates/article.html index d313f33..0bc69ae 100755 --- a/crumbs/templates/article.html +++ b/crumbs/templates/article.html @@ -1,15 +1,9 @@ -{% extends "base.html" %} +{% extends "normal.html" %} -{% block title %}{{ article.title }} - {{ super() }}{% endblock title %} -{% block description %}{{ article.content|striptags|truncate(200)|escape }}{% endblock description %} -{% block keywords %}{% for tag in article.tags|sort %}{{ tag }}{% if not loop.last %}, {% endif %}{% endfor %}{% endblock keywords %} +{% block title %}{{ article.title }} {% endblock title %} {% block content %} - -

{{ article.title }}

- {% with type='single' %} {% include "components/card_content.html" %} {% endwith %} - {% endblock %} diff --git a/crumbs/templates/base.html b/crumbs/templates/base.html index dfe7139..e28af28 100755 --- a/crumbs/templates/base.html +++ b/crumbs/templates/base.html @@ -1,38 +1,13 @@ - {% with type='base' %} - {% include "components/html_head.html" %} - {% endwith %} - -
- - - - - {% include "components/super_gay.html" %} + {% block head %} + {% endblock head %} - - - {% block content %} + +
+ {% block wrapped %} {% endblock %} -
- diff --git a/crumbs/templates/category.html b/crumbs/templates/category.html index 92505d2..39ff421 100755 --- a/crumbs/templates/category.html +++ b/crumbs/templates/category.html @@ -1,16 +1,11 @@ -{% extends "base.html" %} +{% extends "normal.html" %} -{% block title %}{{ NEST_CATEGORY_HEAD_TITLE }} {{ category|capitalize }} - {{ super() }} CATEGORY {% endblock title %} -{% block description %}{{ NEST_CATEGORY_HEAD_DESCRIPTION }} {{ category|capitalize }}{% endblock description %} +{% block title %} {{ category }} {% endblock title %} {% block content %} - -

{{ category }}

- -{% for article in articles %} - {% with type='multi' %} - {% include "components/card_content.html" %} - {% endwith %} -{% endfor %} - + {% for article in articles %} + {% with type='multi' %} + {% include "components/card_content.html" %} + {% endwith %} + {% endfor %} {% endblock content %} diff --git a/crumbs/templates/home.html b/crumbs/templates/home.html index bb8f24a..70cd2cc 100755 --- a/crumbs/templates/home.html +++ b/crumbs/templates/home.html @@ -1,52 +1,34 @@ - - +{% extends "base.html" %} + +{# Define what html head we include #} +{% block head %} {% with type='home' %} {% include "components/html_head.html" %} {% endwith %} - - - - -
- - - - - {% with title_type='title' %} - {% include "components/title_text.html" %} - {% endwith %} - - - {% include "components/super_gay.html" %} - -

- Hi – Welcome to my dusty internet hangout place. -

-

- My name is Katharina Fey and I'm a software developer from Berlin. - I like taking photos, writing stories and starting way too many personal projects. -

- - - -

To get in touch with me, you can also send an e-mail to kookie@spacekookie.de

- - -
- - +{% endblock head %} + + +{% block wrapped %} + + + {% with title_type='title' %} {% include "components/title_text.html" %} {% endwith %} + {% include "components/super_gay.html" %} + +

+ Hi – Welcome to my dusty internet hangout place. +

+

+ My name is Katharina Fey and I'm a software developer from Berlin. + I like taking photos, writing stories and starting way too many personal projects. +

+ + + +

To get in touch with me, you can also send an e-mail to kookie@spacekookie.de

+{% endblock %} diff --git a/crumbs/templates/normal.html b/crumbs/templates/normal.html index 5cb6467..40a51b4 100644 --- a/crumbs/templates/normal.html +++ b/crumbs/templates/normal.html @@ -1,2 +1,23 @@ {% extends "base.html" %} +{# Define what html head we include #} +{% block head %} + {% with type='base' %} + {% include "components/html_head.html" %} + {% endwith %} +{% endblock head %} + +{% block wrapped %} + + + {# Include the colour bar as a divider #} + {% include "components/super_gay.html" %} + +

{% block title %}{% endblock %}

+ + {% block content %} + {% endblock %} +{% endblock %} \ No newline at end of file -- cgit v1.2.3