From b60389dbfc2a23ba6ea6de757017859918da053b Mon Sep 17 00:00:00 2001 From: Nick Date: Fri, 16 Jul 2021 14:18:33 -0600 Subject: [PATCH] Tutorials looking better! --- tutorials/static/tutorials/calendar.svg | 1 + tutorials/static/tutorials/reading-book.svg | 1 + .../templates/tutorials/tutorial_page.html | 104 ++++++++++++------ 3 files changed, 72 insertions(+), 34 deletions(-) create mode 100644 tutorials/static/tutorials/calendar.svg create mode 100644 tutorials/static/tutorials/reading-book.svg diff --git a/tutorials/static/tutorials/calendar.svg b/tutorials/static/tutorials/calendar.svg new file mode 100644 index 0000000..b8d99b0 --- /dev/null +++ b/tutorials/static/tutorials/calendar.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/tutorials/static/tutorials/reading-book.svg b/tutorials/static/tutorials/reading-book.svg new file mode 100644 index 0000000..6837231 --- /dev/null +++ b/tutorials/static/tutorials/reading-book.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/tutorials/templates/tutorials/tutorial_page.html b/tutorials/templates/tutorials/tutorial_page.html index 7840708..6ad090a 100644 --- a/tutorials/templates/tutorials/tutorial_page.html +++ b/tutorials/templates/tutorials/tutorial_page.html @@ -1,51 +1,87 @@ {% extends "sitewide/base.html" %} +{% load static %} + {% load wagtailcore_tags wagtailimages_tags %} {% block head %} - {% include "sitewide/pretty_socials.html" with title=page.title description=page.intro wagtail_image=page.promo_image %} +{% include "sitewide/pretty_socials.html" with title=page.title description=page.intro wagtail_image=page.promo_image %} {% endblock %} {% block title %}{{ page.title }} | ZappyCode{% endblock %} {% block content %} -
-
+
+
+
-

{{ page.title }}

-

{{ page.intro }}

-

Written by Resident Baller:

- {% if page.owner.pic %} - - {% endif %} -

{{ page.owner.username }}

-
- {{ page.get_read_time }} - {{ page.date|date:"M j, Y" }} +
+
+

{{ page.title }}

+ {% image page.promo_image width-1000 class="img-fluid py-3" %} +
{{ page.intro }}
+
+
+
+
+
+
+ {% if page.owner.pic %} + + {% else %} + + {% endif %} +
+
+ +
+
+ +
+
+
+
+
{{ page.owner.username }}
+
+
+
{{ page.get_read_time }}
+
+
+
{{ page.date|date:"M j, Y" }}
+
+
+
-
- {% for block in page.body %} - {% if block.block_type == 'image' %} - - {% image block.value width-1000 class="img-fluid" %} - - {% else %} - {% include_block block %} - {% endif %} - {% endfor %} - {% if courses %} -
-

Here's some courses you might like:

-
    - {% for course in courses %} -
  • {{ course.title }}
  • +
    +
    +
    + {% for block in page.body %} + {% if block.block_type == 'image' %} +
    + {% image block.value width-1000 class="img-fluid pb-2" %} +
    + {% else %} + {% include_block block %} + {% endif %} {% endfor %} -
- {% endif %} -
+ {% if courses %} +
+

Here's some courses you might like:

+ + {% endif %} + +
+
-
+ + -{% endblock %} +{% endblock %} \ No newline at end of file