From 8e24990eac6f620c8f10456052a76875752ff630 Mon Sep 17 00:00:00 2001 From: Jonah Aragon Date: Mon, 1 Apr 2019 13:50:01 -0500 Subject: [PATCH] Make the layouts more modular --- _includes/{sections => }/footer.html | 0 _includes/head.html | 46 ++++++++++++++++++ _layouts/default.html | 70 ++++++---------------------- index.html | 29 ++++-------- privacy-policy.html | 2 +- 5 files changed, 72 insertions(+), 75 deletions(-) rename _includes/{sections => }/footer.html (100%) create mode 100644 _includes/head.html diff --git a/_includes/sections/footer.html b/_includes/footer.html similarity index 100% rename from _includes/sections/footer.html rename to _includes/footer.html diff --git a/_includes/head.html b/_includes/head.html new file mode 100644 index 00000000..a153c763 --- /dev/null +++ b/_includes/head.html @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + {% if page.title %} + {{ page.title }} | {{ site.title }} + {% else %} + {{ site.title }} + {% endif %} + + + + + + + + + + + + + + + + + + + + + diff --git a/_layouts/default.html b/_layouts/default.html index 9d52a4bf..8bb12370 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -1,60 +1,20 @@ - - - - - - - - - - - - - - - - - - - - - {% if page.title %} - {{ page.title }} | {{ site.title }} - {% else %} - {{ site.title }} - {% endif %} - - - - - - - - - - - - - - - - - - - - - - - - - {% include nav.html %} - -
- +{% include head.html %} + +
+ {% include nav.html %} +
+
+
+
{{ content }} +
+
+ {% include footer.html %} +
+
- {% include scripts.html %} - + {% include scripts.html %} + diff --git a/index.html b/index.html index 1f260caa..5d79f5b6 100644 --- a/index.html +++ b/index.html @@ -1,24 +1,15 @@ --- layout: default --- -
- + - {% include sections/header.html %} - - {% include sections/quotes.html %} - - {% include sections/warrant-canary.html %} - - {% include sections/privacy-resources.html %} - - {% include sections/participate.html %} - - {% include sections/footer.html %} - -
+{% include sections/header.html %} +{% include sections/quotes.html %} +{% include sections/warrant-canary.html %} +{% include sections/privacy-resources.html %} +{% include sections/participate.html %} diff --git a/privacy-policy.html b/privacy-policy.html index dc164949..3461bb2a 100644 --- a/privacy-policy.html +++ b/privacy-policy.html @@ -90,6 +90,6 @@ active_page: privacy_policy


- {% include sections/footer.html %} + {% include footer.html %}