From f08bf1e056305827cb57e53a81706a6c7ec1c7c3 Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Thu, 21 Jun 2018 01:03:57 +0100 Subject: [PATCH] Update layouts and partials --- source/_layouts/base.html.twig | 53 ++++++++++++ source/_layouts/default.html.twig | 125 +++++++---------------------- source/_partials/meetups.html.twig | 23 ++++++ 3 files changed, 103 insertions(+), 98 deletions(-) create mode 100644 source/_layouts/base.html.twig create mode 100644 source/_partials/meetups.html.twig diff --git a/source/_layouts/base.html.twig b/source/_layouts/base.html.twig new file mode 100644 index 00000000..0c2d9ff8 --- /dev/null +++ b/source/_layouts/base.html.twig @@ -0,0 +1,53 @@ + + + + + {% if page.title is defined and page.url != '/.' %} + {{ page.title }} | + {% endif %} + {{ site.title }} - {{ site.subtitle }} + + + + + + + {% if page.meta.description %} + + {% endif %} + + {% include 'og' with { og: page.meta.og } %} + + + {% block stylesheets %}{% endblock %} + + {% for size in site.apple_touch_icon_sizes %} + + {% endfor %} + + {% for size in site.favicon_sizes %} + + {% endfor %} + + + {% block body %}{% endblock %} + + + + {% if site.google_analytics_tracking_id %} + + {% endif %} + + {% if page.has_tweets %} + + {% endif %} + + + {% block scripts %}{% endblock %} + + diff --git a/source/_layouts/default.html.twig b/source/_layouts/default.html.twig index 19c26053..f69770d9 100644 --- a/source/_layouts/default.html.twig +++ b/source/_layouts/default.html.twig @@ -1,105 +1,34 @@ - - - - - {% if page.title is defined and page.url != '/.' %} - {{ page.title }} | - {% endif %} - {{ site.title }} - {{ site.subtitle }} - +{% extends 'base' %} - - - +{% block body %} + {% include 'navbar' %} - {% if page.meta.description %} - - {% endif %} +
+
+
+ {% block content_top %}{% endblock %} + {% block content_wrapper %}{% block content %}{% endblock %}{% endblock %} + {% block content_bottom %}{% endblock %} +
- {% include 'og' with { og: page.meta.og } %} - - {% block stylesheets %} - - {% endblock %} - - {% for size in site.apple_touch_icon_sizes %} - - {% endfor %} - - {% for size in site.favicon_sizes %} - - {% endfor %} - - - {% include 'navbar.html.twig' %} - -
-
-
- {% block content_top %}{% endblock %} - {% block content_wrapper %}{% block content %}{% endblock %}{% endblock %} - {% block content_bottom %}{% endblock %} -
- - {% block sidebar_wrapper %} - - {% endblock %} -
- -
-

- © 2010-{{ 'now'|date('Y') }} {{ site.title }}. - Built with Sculpin and Tailwind CSS. -

- -
-

Things that I organise

- -
    - {% include 'meetup.html.twig' with { - name: 'Drupal Bristol', - logo: 'drupal-bristol.jpeg', - url: 'http://www.drupalbristol.org.uk', - } %} - - {% include 'meetup.html.twig' with { - name: 'DrupalCamp Bristol', - logo: 'drupalcamp-bristol.png', - url: 'http://www.drupalcampbristol.co.uk', - } %} - - {% include 'meetup.html.twig' with { - name: 'PHPSW', - logo: 'phpsw.jpeg', - url: 'http://phpsw.uk', - } %} -
+ {% block sidebar_wrapper %} + -
+ {% endblock %}
- +
+

+ © 2010-{{ 'now'|date('Y') }} {{ site.title }}. + Built with Sculpin and Tailwind CSS. +

- {% if site.google_analytics_tracking_id %} - - {% endif %} - - {% if page.has_tweets %} - - {% endif %} - - - {% block scripts %}{% endblock %} - - + {% include 'meetups' %} +
+
+{% endblock %} diff --git a/source/_partials/meetups.html.twig b/source/_partials/meetups.html.twig new file mode 100644 index 00000000..f01393e2 --- /dev/null +++ b/source/_partials/meetups.html.twig @@ -0,0 +1,23 @@ +
+

Things that I organise

+ +
    + {% include 'meetup.html.twig' with { + name: 'Drupal Bristol', + logo: 'drupal-bristol.jpeg', + url: 'http://www.drupalbristol.org.uk', + } %} + + {% include 'meetup.html.twig' with { + name: 'DrupalCamp Bristol', + logo: 'drupalcamp-bristol.png', + url: 'http://www.drupalcampbristol.co.uk', + } %} + + {% include 'meetup.html.twig' with { + name: 'PHPSW', + logo: 'phpsw.jpeg', + url: 'http://phpsw.uk', + } %} +
+