From e62e7bb6b14555c9bbe5d40d217103984f4f80e6 Mon Sep 17 00:00:00 2001 From: Andrew Lee Date: Sun, 27 Oct 2019 09:57:37 -0400 Subject: Rewrite progress --- _includes/analytics-providers/custom.html | 3 + _includes/analytics-providers/google-gtag.html | 9 + .../analytics-providers/google-universal.html | 7 + _includes/analytics-providers/google.html | 14 ++ _includes/analytics.html | 14 ++ _includes/archive-single.html | 38 +++ _includes/author-profile-custom-links.html | 7 + _includes/author-profile.html | 263 +++++++++++++++++++++ _includes/breadcrumbs.html | 39 +++ _includes/browser-upgrade.html | 3 + _includes/category-list.html | 26 ++ _includes/comment.html | 22 ++ _includes/comments-providers/custom.html | 3 + _includes/comments-providers/discourse.html | 13 + _includes/comments-providers/disqus.html | 15 ++ _includes/comments-providers/facebook.html | 8 + _includes/comments-providers/scripts.html | 18 ++ _includes/comments-providers/staticman.html | 40 ++++ _includes/comments-providers/staticman_v2.html | 40 ++++ _includes/comments-providers/utterances.html | 20 ++ _includes/comments.html | 159 +++++++++++++ _includes/documents-collection.html | 19 ++ _includes/feature_row | 53 +++++ _includes/figure | 12 + _includes/footer.html | 19 ++ _includes/footer/custom.html | 3 + _includes/gallery | 51 ++++ _includes/group-by-array | 47 ++++ _includes/head.html | 41 ++++ _includes/head/custom.html | 5 + _includes/masthead.html | 46 ++++ _includes/nav_list | 47 ++++ _includes/page__hero.html | 72 ++++++ _includes/page__hero_video.html | 4 + _includes/page__taxonomy.html | 7 + _includes/paginator.html | 69 ++++++ _includes/post_pagination.html | 14 ++ _includes/posts-category.html | 3 + _includes/posts-tag.html | 3 + _includes/read-time.html | 15 ++ _includes/scripts.html | 39 +++ _includes/search/algolia-search-scripts.html | 54 +++++ _includes/search/google-search-scripts.html | 30 +++ _includes/search/lunr-search-scripts.html | 10 + _includes/search/search_form.html | 26 ++ _includes/seo.html | 161 +++++++++++++ _includes/sidebar.html | 24 ++ _includes/skip-links.html | 8 + _includes/social-share.html | 11 + _includes/tag-list.html | 26 ++ _includes/toc | 7 + _includes/toc.html | 85 +++++++ _includes/video | 13 + 53 files changed, 1785 insertions(+) create mode 100644 _includes/analytics-providers/custom.html create mode 100644 _includes/analytics-providers/google-gtag.html create mode 100644 _includes/analytics-providers/google-universal.html create mode 100644 _includes/analytics-providers/google.html create mode 100644 _includes/analytics.html create mode 100644 _includes/archive-single.html create mode 100644 _includes/author-profile-custom-links.html create mode 100644 _includes/author-profile.html create mode 100644 _includes/breadcrumbs.html create mode 100644 _includes/browser-upgrade.html create mode 100644 _includes/category-list.html create mode 100644 _includes/comment.html create mode 100644 _includes/comments-providers/custom.html create mode 100644 _includes/comments-providers/discourse.html create mode 100644 _includes/comments-providers/disqus.html create mode 100644 _includes/comments-providers/facebook.html create mode 100644 _includes/comments-providers/scripts.html create mode 100644 _includes/comments-providers/staticman.html create mode 100644 _includes/comments-providers/staticman_v2.html create mode 100644 _includes/comments-providers/utterances.html create mode 100644 _includes/comments.html create mode 100644 _includes/documents-collection.html create mode 100644 _includes/feature_row create mode 100644 _includes/figure create mode 100644 _includes/footer.html create mode 100644 _includes/footer/custom.html create mode 100644 _includes/gallery create mode 100644 _includes/group-by-array create mode 100644 _includes/head.html create mode 100644 _includes/head/custom.html create mode 100644 _includes/masthead.html create mode 100644 _includes/nav_list create mode 100644 _includes/page__hero.html create mode 100644 _includes/page__hero_video.html create mode 100644 _includes/page__taxonomy.html create mode 100644 _includes/paginator.html create mode 100644 _includes/post_pagination.html create mode 100644 _includes/posts-category.html create mode 100644 _includes/posts-tag.html create mode 100644 _includes/read-time.html create mode 100644 _includes/scripts.html create mode 100644 _includes/search/algolia-search-scripts.html create mode 100644 _includes/search/google-search-scripts.html create mode 100644 _includes/search/lunr-search-scripts.html create mode 100644 _includes/search/search_form.html create mode 100644 _includes/seo.html create mode 100644 _includes/sidebar.html create mode 100644 _includes/skip-links.html create mode 100644 _includes/social-share.html create mode 100644 _includes/tag-list.html create mode 100644 _includes/toc create mode 100644 _includes/toc.html create mode 100644 _includes/video (limited to '_includes') diff --git a/_includes/analytics-providers/custom.html b/_includes/analytics-providers/custom.html new file mode 100644 index 0000000..c34b97a --- /dev/null +++ b/_includes/analytics-providers/custom.html @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/_includes/analytics-providers/google-gtag.html b/_includes/analytics-providers/google-gtag.html new file mode 100644 index 0000000..16d0cf1 --- /dev/null +++ b/_includes/analytics-providers/google-gtag.html @@ -0,0 +1,9 @@ + + + diff --git a/_includes/analytics-providers/google-universal.html b/_includes/analytics-providers/google-universal.html new file mode 100644 index 0000000..68c2674 --- /dev/null +++ b/_includes/analytics-providers/google-universal.html @@ -0,0 +1,7 @@ + + diff --git a/_includes/analytics-providers/google.html b/_includes/analytics-providers/google.html new file mode 100644 index 0000000..c5742b9 --- /dev/null +++ b/_includes/analytics-providers/google.html @@ -0,0 +1,14 @@ + diff --git a/_includes/analytics.html b/_includes/analytics.html new file mode 100644 index 0000000..371469f --- /dev/null +++ b/_includes/analytics.html @@ -0,0 +1,14 @@ +{% if jekyll.environment == 'production' and site.analytics.provider and page.analytics != false %} + +{% case site.analytics.provider %} +{% when "google" %} + {% include /analytics-providers/google.html %} +{% when "google-universal" %} + {% include /analytics-providers/google-universal.html %} +{% when "google-gtag" %} + {% include /analytics-providers/google-gtag.html %} +{% when "custom" %} + {% include /analytics-providers/custom.html %} +{% endcase %} + +{% endif %} \ No newline at end of file diff --git a/_includes/archive-single.html b/_includes/archive-single.html new file mode 100644 index 0000000..489f000 --- /dev/null +++ b/_includes/archive-single.html @@ -0,0 +1,38 @@ +{% if post.header.teaser %} + {% capture teaser %}{{ post.header.teaser }}{% endcapture %} +{% else %} + {% assign teaser = site.teaser %} +{% endif %} + +{% if post.id %} + {% assign title = post.title | markdownify | remove: "

" | remove: "

" %} +{% else %} + {% assign title = post.title %} +{% endif %} + +
+
+ {% if include.type == "grid" and teaser %} +
+ +
+ {% endif %} +

+ {% if post.link %} + {{ title }} Permalink + {% else %} + {{ title }} + {% endif %} +

+ {% if post.read_time %} +

{% include read-time.html %}

+ {% endif %} + {% if post.excerpt %}

{{ post.excerpt | markdownify | strip_html | truncate: 160 }}

{% endif %} +
+
diff --git a/_includes/author-profile-custom-links.html b/_includes/author-profile-custom-links.html new file mode 100644 index 0000000..b89ffcb --- /dev/null +++ b/_includes/author-profile-custom-links.html @@ -0,0 +1,7 @@ + \ No newline at end of file diff --git a/_includes/author-profile.html b/_includes/author-profile.html new file mode 100644 index 0000000..b7d6214 --- /dev/null +++ b/_includes/author-profile.html @@ -0,0 +1,263 @@ +{% assign author = page.author | default: page.authors[0] | default: site.author %} +{% assign author = site.data.authors[author] | default: author %} + +
+ + {% if author.avatar %} +
+ {% if author.avatar contains "://" %} + {% assign author_src = author.avatar %} + {% else %} + {% assign author_src = author.avatar | relative_url %} + {% endif %} + + {% if author.home %} + {% if author.home contains "://" %} + {% assign author_link = author.home %} + {% else %} + {% assign author_link = author.home | relative_url %} + {% endif %} + + {{ author.name }} + + {% else %} + {{ author.name }} + {% endif %} +
+ {% endif %} + +
+ {% if author.home %} +

{{ author.name }}

+ {% else %} +

{{ author.name }}

+ {% endif %} + {% if author.bio %} +
+ {{ author.bio | markdownify }} +
+ {% endif %} +
+ +
+ + +
+
diff --git a/_includes/breadcrumbs.html b/_includes/breadcrumbs.html new file mode 100644 index 0000000..cba3d41 --- /dev/null +++ b/_includes/breadcrumbs.html @@ -0,0 +1,39 @@ +{% case site.category_archive.type %} + {% when "liquid" %} + {% assign path_type = "#" %} + {% when "jekyll-archives" %} + {% assign path_type = nil %} +{% endcase %} + +{% if page.collection != 'posts' %} + {% assign path_type = nil %} + {% assign crumb_path = '/' %} +{% else %} + {% assign crumb_path = site.category_archive.path %} +{% endif %} + + diff --git a/_includes/browser-upgrade.html b/_includes/browser-upgrade.html new file mode 100644 index 0000000..ec6ad0a --- /dev/null +++ b/_includes/browser-upgrade.html @@ -0,0 +1,3 @@ + diff --git a/_includes/category-list.html b/_includes/category-list.html new file mode 100644 index 0000000..d684a28 --- /dev/null +++ b/_includes/category-list.html @@ -0,0 +1,26 @@ +{% case site.category_archive.type %} + {% when "liquid" %} + {% assign path_type = "#" %} + {% when "jekyll-archives" %} + {% assign path_type = nil %} +{% endcase %} + +{% if site.category_archive.path %} + {% comment %} + + + {% endcomment %} + {% capture page_categories %}{% for category in page.categories %}{{ category | downcase }}|{{ category }}{% unless forloop.last %},{% endunless %}{% endfor %}{% endcapture %} + {% assign category_hashes = page_categories | split: ',' | sort %} + +

+ {{ site.data.ui-text[site.locale].categories_label | default: "Categories:" }} + + {% for hash in category_hashes %} + {% assign keyValue = hash | split: '|' %} + {% capture category_word %}{{ keyValue[1] | strip_newlines }}{% endcapture %} + {% unless forloop.last %}, {% endunless %} + {% endfor %} + +

+{% endif %} \ No newline at end of file diff --git a/_includes/comment.html b/_includes/comment.html new file mode 100644 index 0000000..cebedab --- /dev/null +++ b/_includes/comment.html @@ -0,0 +1,22 @@ +
+
+ {{ include.name }} +
+
+ +

+ {% if include.date %} + {% if include.index %}{% endif %} + {% endif %} +

+
{{ include.message | markdownify }}
+
+
diff --git a/_includes/comments-providers/custom.html b/_includes/comments-providers/custom.html new file mode 100644 index 0000000..9099369 --- /dev/null +++ b/_includes/comments-providers/custom.html @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/_includes/comments-providers/discourse.html b/_includes/comments-providers/discourse.html new file mode 100644 index 0000000..aca62cc --- /dev/null +++ b/_includes/comments-providers/discourse.html @@ -0,0 +1,13 @@ +{% if site.comments.discourse.server %} +{% capture canonical %}{% if site.permalink contains '.html' %}{{ page.url | absolute_url }}{% else %}{{ page.url | absolute_url | remove:'index.html' | strip_slash }}{% endif %}{% endcapture %} + + +{% endif %} diff --git a/_includes/comments-providers/disqus.html b/_includes/comments-providers/disqus.html new file mode 100644 index 0000000..8cf7aca --- /dev/null +++ b/_includes/comments-providers/disqus.html @@ -0,0 +1,15 @@ +{% if site.comments.disqus.shortname %} + + +{% endif %} diff --git a/_includes/comments-providers/facebook.html b/_includes/comments-providers/facebook.html new file mode 100644 index 0000000..009dc1c --- /dev/null +++ b/_includes/comments-providers/facebook.html @@ -0,0 +1,8 @@ +
+ \ No newline at end of file diff --git a/_includes/comments-providers/scripts.html b/_includes/comments-providers/scripts.html new file mode 100644 index 0000000..4e3f585 --- /dev/null +++ b/_includes/comments-providers/scripts.html @@ -0,0 +1,18 @@ +{% if site.comments.provider and page.comments %} +{% case site.comments.provider %} + {% when "disqus" %} + {% include /comments-providers/disqus.html %} + {% when "discourse" %} + {% include /comments-providers/discourse.html %} + {% when "facebook" %} + {% include /comments-providers/facebook.html %} + {% when "staticman" %} + {% include /comments-providers/staticman.html %} + {% when "staticman_v2" %} + {% include /comments-providers/staticman_v2.html %} + {% when "utterances" %} + {% include /comments-providers/utterances.html %} + {% when "custom" %} + {% include /comments-providers/custom.html %} +{% endcase %} +{% endif %} \ No newline at end of file diff --git a/_includes/comments-providers/staticman.html b/_includes/comments-providers/staticman.html new file mode 100644 index 0000000..ae3991d --- /dev/null +++ b/_includes/comments-providers/staticman.html @@ -0,0 +1,40 @@ +{% if site.repository and site.staticman.branch %} + +{% endif %} diff --git a/_includes/comments-providers/staticman_v2.html b/_includes/comments-providers/staticman_v2.html new file mode 100644 index 0000000..ae3991d --- /dev/null +++ b/_includes/comments-providers/staticman_v2.html @@ -0,0 +1,40 @@ +{% if site.repository and site.staticman.branch %} + +{% endif %} diff --git a/_includes/comments-providers/utterances.html b/_includes/comments-providers/utterances.html new file mode 100644 index 0000000..129ab77 --- /dev/null +++ b/_includes/comments-providers/utterances.html @@ -0,0 +1,20 @@ + diff --git a/_includes/comments.html b/_includes/comments.html new file mode 100644 index 0000000..40b0359 --- /dev/null +++ b/_includes/comments.html @@ -0,0 +1,159 @@ +
+ {% capture comments_label %}{{ site.data.ui-text[site.locale].comments_label | default: "Comments" }}{% endcapture %} + {% case site.comments.provider %} + {% when "discourse" %} +

{{ comments_label }}

+
+ {% when "disqus" %} +

{{ comments_label }}

+
+ {% when "facebook" %} +

{{ comments_label }}

+
+ {% when "staticman_v2" %} +
+ {% if site.repository and site.staticman.branch %} + +
+ {% if site.data.comments[page.slug] %} +

{{ site.data.ui-text[site.locale].comments_title | default: "Comments" }}

+ {% assign comments = site.data.comments[page.slug] | sort %} + + {% for comment in comments %} + {% assign email = comment[1].email %} + {% assign name = comment[1].name %} + {% assign url = comment[1].url %} + {% assign date = comment[1].date %} + {% assign message = comment[1].message %} + {% include comment.html index=forloop.index email=email name=name url=url date=date message=message %} + {% endfor %} + {% endif %} +
+ + + +
+

{{ site.data.ui-text[site.locale].comments_label | default: "Leave a Comment" }}

+

{{ site.data.ui-text[site.locale].comment_form_info | default: "Your email address will not be published. Required fields are marked" }} *

+
+
+ + {{ site.data.ui-text[site.locale].loading_label | default: "Loading..." }} +
+ +
+ + + +
+
+ + +
+
+ + +
+
+ + +
+ + + + + {% if site.reCaptcha.siteKey %} +
+
+
+ {% endif %} +
+ +
+
+
+ + {% if site.reCaptcha.siteKey %}{% endif %} + {% endif %} +
+ {% when "staticman" %} +
+ {% if site.repository and site.staticman.branch %} + +
+ {% if site.data.comments[page.slug] %} +

{{ site.data.ui-text[site.locale].comments_title | default: "Comments" }}

+ {% assign comments = site.data.comments[page.slug] | sort %} + + {% for comment in comments %} + {% assign email = comment[1].email %} + {% assign name = comment[1].name %} + {% assign url = comment[1].url %} + {% assign date = comment[1].date %} + {% assign message = comment[1].message %} + {% include comment.html index=forloop.index email=email name=name url=url date=date message=message %} + {% endfor %} + {% endif %} +
+ + + +
+

{{ site.data.ui-text[site.locale].comments_label | default: "Leave a Comment" }}

+

{{ site.data.ui-text[site.locale].comment_form_info | default: "Your email address will not be published. Required fields are marked" }} *

+
+
+ + {{ site.data.ui-text[site.locale].loading_label | default: "Loading..." }} +
+ +
+ + + +
+
+ + +
+
+ + +
+
+ + +
+ + + + +
+ +
+
+
+ + {% endif %} +
+ {% when "utterances" %} +

{{ comments_label }}

+
+ {% when "custom" %} +
+ {% endcase %} +
diff --git a/_includes/documents-collection.html b/_includes/documents-collection.html new file mode 100644 index 0000000..13b4006 --- /dev/null +++ b/_includes/documents-collection.html @@ -0,0 +1,19 @@ +{% assign entries = site[include.collection] %} + +{% if include.sort_by == 'title' %} + {% if include.sort_order == 'reverse' %} + {% assign entries = entries | sort: 'title' | reverse %} + {% else %} + {% assign entries = entries | sort: 'title' %} + {% endif %} +{% elsif include.sort_by == 'date' %} + {% if include.sort_order == 'reverse' %} + {% assign entries = entries | sort: 'date' | reverse %} + {% else %} + {% assign entries = entries | sort: 'date' %} + {% endif %} +{% endif %} + +{%- for post in entries -%} + {% include archive-single.html %} +{%- endfor -%} diff --git a/_includes/feature_row b/_includes/feature_row new file mode 100644 index 0000000..89dfc1b --- /dev/null +++ b/_includes/feature_row @@ -0,0 +1,53 @@ +{% if include.id %} + {% assign feature_row = page[include.id] %} +{% else %} + {% assign feature_row = page.feature_row %} +{% endif %} + +
+ + {% for f in feature_row %} + + {% if f.url contains "://" %} + {% capture f_url %}{{ f.url }}{% endcapture %} + {% else %} + {% capture f_url %}{{ f.url | relative_url }}{% endcapture %} + {% endif %} + +
+
+ {% if f.image_path %} +
+ {% if f.alt %}{{ f.alt }}{% endif %} + {% if f.image_caption %} + {{ f.image_caption | markdownify | remove: "

" | remove: "

" }}
+ {% endif %} +
+ {% endif %} + +
+ {% if f.title %} +

{{ f.title }}

+ {% endif %} + + {% if f.excerpt %} +
+ {{ f.excerpt | markdownify }} +
+ {% endif %} + + {% if f.url %} +

{{ f.btn_label | default: site.data.ui-text[site.locale].more_label | default: "Learn More" }}

+ {% endif %} +
+
+
+ {% endfor %} + +
\ No newline at end of file diff --git a/_includes/figure b/_includes/figure new file mode 100644 index 0000000..8e9bdd5 --- /dev/null +++ b/_includes/figure @@ -0,0 +1,12 @@ +
+ {% if include.alt %}{{ include.alt }}{% endif %} + {% if include.caption %} +
+ {{ include.caption | markdownify | remove: "

" | remove: "

" }} +
{% endif %}
diff --git a/_includes/footer.html b/_includes/footer.html new file mode 100644 index 0000000..2bc7896 --- /dev/null +++ b/_includes/footer.html @@ -0,0 +1,19 @@ + + + diff --git a/_includes/footer/custom.html b/_includes/footer/custom.html new file mode 100644 index 0000000..d512599 --- /dev/null +++ b/_includes/footer/custom.html @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/_includes/gallery b/_includes/gallery new file mode 100644 index 0000000..97022aa --- /dev/null +++ b/_includes/gallery @@ -0,0 +1,51 @@ +{% if include.id %} + {% assign gallery = page[include.id] %} +{% else %} + {% assign gallery = page.gallery %} +{% endif %} + +{% if include.layout %} + {% assign gallery_layout = include.layout %} +{% else %} + {% if gallery.size == 2 %} + {% assign gallery_layout = 'half' %} + {% elsif gallery.size >= 3 %} + {% assign gallery_layout = 'third' %} + {% else %} + {% assign gallery_layout = '' %} + {% endif %} +{% endif %} + + \ No newline at end of file diff --git a/_includes/group-by-array b/_includes/group-by-array new file mode 100644 index 0000000..708de41 --- /dev/null +++ b/_includes/group-by-array @@ -0,0 +1,47 @@ + + + +{% assign __empty_array = '' | split: ',' %} +{% assign group_names = __empty_array %} +{% assign group_items = __empty_array %} + + +{% assign __names = include.collection | map: include.field %} + + +{% assign __names = __names | join: ',' | join: ',' | split: ',' %} + + +{% assign __names = __names | sort %} +{% for name in __names %} + + +{% unless name == previous %} + + +{% assign group_names = group_names | push: name %} +{% endunless %} + +{% assign previous = name %} +{% endfor %} + + + +{% for name in group_names %} + + +{% assign __item = __empty_array %} +{% for __element in include.collection %} +{% if __element[include.field] contains name %} +{% assign __item = __item | push: __element %} +{% endif %} +{% endfor %} + + +{% assign group_items = group_items | push: __item %} +{% endfor %} \ No newline at end of file diff --git a/_includes/head.html b/_includes/head.html new file mode 100644 index 0000000..8963379 --- /dev/null +++ b/_includes/head.html @@ -0,0 +1,41 @@ + + +{% include seo.html %} + + + + + + + + + + + + + +{% if site.head_scripts %} + {% for script in site.head_scripts %} + {% if script contains "://" %} + {% capture script_path %}{{ script }}{% endcapture %} + {% else %} + {% capture script_path %}{{ script | relative_url }}{% endcapture %} + {% endif %} + + {% endfor %} +{% endif %} diff --git a/_includes/head/custom.html b/_includes/head/custom.html new file mode 100644 index 0000000..978d84f --- /dev/null +++ b/_includes/head/custom.html @@ -0,0 +1,5 @@ + + + + + diff --git a/_includes/masthead.html b/_includes/masthead.html new file mode 100644 index 0000000..3fe9fc1 --- /dev/null +++ b/_includes/masthead.html @@ -0,0 +1,46 @@ +{% if site.logo contains "://" %} + {% capture logo_path %}{{ site.logo }}{% endcapture %} +{% else %} + {% capture logo_path %}{{ site.logo }}{% endcapture %} +{% endif %} + +
+
+
+ +
+
+
diff --git a/_includes/nav_list b/_includes/nav_list new file mode 100644 index 0000000..b1d06c3 --- /dev/null +++ b/_includes/nav_list @@ -0,0 +1,47 @@ +{% assign navigation = site.data.navigation[include.nav] %} + + \ No newline at end of file diff --git a/_includes/page__hero.html b/_includes/page__hero.html new file mode 100644 index 0000000..98bff72 --- /dev/null +++ b/_includes/page__hero.html @@ -0,0 +1,72 @@ +{% if page.header.image contains "://" %} + {% capture img_path %}{{ page.header.image }}{% endcapture %} +{% else %} + {% capture img_path %}{{ page.header.image | relative_url }}{% endcapture %} +{% endif %} + +{% if page.header.cta_url contains "://" %} + {% capture cta_path %}{{ page.header.cta_url }}{% endcapture %} +{% else %} + {% capture cta_path %}{{ page.header.cta_url | relative_url }}{% endcapture %} +{% endif %} + +{% if page.header.overlay_image contains "://" %} + {% capture overlay_img_path %}{{ page.header.overlay_image }}{% endcapture %} +{% elsif page.header.overlay_image %} + {% capture overlay_img_path %}{{ page.header.overlay_image | relative_url }}{% endcapture %} +{% endif %} + +{% if page.header.overlay_filter contains "rgba" %} + {% capture overlay_filter %}{{ page.header.overlay_filter }}{% endcapture %} +{% elsif page.header.overlay_filter %} + {% capture overlay_filter %}rgba(0, 0, 0, {{ page.header.overlay_filter }}){% endcapture %} +{% endif %} + +{% if page.header.image_description %} + {% assign image_description = page.header.image_description %} +{% else %} + {% assign image_description = page.title %} +{% endif %} + +{% assign image_description = image_description | markdownify | strip_html | strip_newlines | escape_once %} + +
+ {% if page.header.overlay_color or page.header.overlay_image %} +
+

+ {% if paginator and site.paginate_show_page_num %} + {{ site.title }}{% unless paginator.page == 1 %} {{ site.data.ui-text[site.locale].page | default: "Page" }} {{ paginator.page }}{% endunless %} + {% else %} + {{ page.title | default: site.title | markdownify | remove: "

" | remove: "

" }} + {% endif %} +

+ {% if page.header.show_overlay_excerpt != false and page.excerpt %} +

{{ page.excerpt | markdownify | remove: "

" | remove: "

" }}

+ {% endif %} + {% if page.read_time %} +

{% include read-time.html %}

+ {% endif %} + {% if page.header.cta_url %} +

{{ page.header.cta_label | default: site.data.ui-text[site.locale].more_label | default: "Learn More" }}

+ {% endif %} + {% if page.header.actions %} +

+ {% for action in page.header.actions %} + {% if action.url contains "://" %} + {% assign url = action.url %} + {% else %} + {% assign url = action.url | relative_url %} + {% endif %} + {{ action.label | default: site.data.ui-text[site.locale].more_label | default: "Learn More" }} + {% endfor %} + {% endif %} +

+ {% else %} + {{ image_description }} + {% endif %} + {% if page.header.caption %} + {{ page.header.caption | markdownify | remove: "

" | remove: "

" }}
+ {% endif %} +
diff --git a/_includes/page__hero_video.html b/_includes/page__hero_video.html new file mode 100644 index 0000000..8586a95 --- /dev/null +++ b/_includes/page__hero_video.html @@ -0,0 +1,4 @@ +{% capture video_id %}{{ page.header.video.id }}{% endcapture %} +{% capture video_provider %}{{ page.header.video.provider }}{% endcapture %} + +{% include video id=video_id provider=video_provider %} diff --git a/_includes/page__taxonomy.html b/_includes/page__taxonomy.html new file mode 100644 index 0000000..75c76c8 --- /dev/null +++ b/_includes/page__taxonomy.html @@ -0,0 +1,7 @@ +{% if site.tag_archive.type and page.tags[0] %} + {% include tag-list.html %} +{% endif %} + +{% if site.category_archive.type and page.categories[0] %} + {% include category-list.html %} +{% endif %} \ No newline at end of file diff --git a/_includes/paginator.html b/_includes/paginator.html new file mode 100644 index 0000000..592a2cf --- /dev/null +++ b/_includes/paginator.html @@ -0,0 +1,69 @@ +{% if paginator.total_pages > 1 %} + +{% endif %} diff --git a/_includes/post_pagination.html b/_includes/post_pagination.html new file mode 100644 index 0000000..a93c627 --- /dev/null +++ b/_includes/post_pagination.html @@ -0,0 +1,14 @@ +{% if page.previous or page.next %} + +{% endif %} \ No newline at end of file diff --git a/_includes/posts-category.html b/_includes/posts-category.html new file mode 100644 index 0000000..98be3e9 --- /dev/null +++ b/_includes/posts-category.html @@ -0,0 +1,3 @@ +{%- for post in site.categories[include.taxonomy] -%} + {% include archive-single.html %} +{%- endfor -%} diff --git a/_includes/posts-tag.html b/_includes/posts-tag.html new file mode 100644 index 0000000..180a2f3 --- /dev/null +++ b/_includes/posts-tag.html @@ -0,0 +1,3 @@ +{%- for post in site.tags[include.taxonomy] -%} + {% include archive-single.html %} +{%- endfor -%} diff --git a/_includes/read-time.html b/_includes/read-time.html new file mode 100644 index 0000000..5885744 --- /dev/null +++ b/_includes/read-time.html @@ -0,0 +1,15 @@ +{% assign words_per_minute = page.words_per_minute | default: site.words_per_minute | default: 200 %} + +{% if post.read_time %} + {% assign words = post.content | strip_html | number_of_words %} +{% elsif page.read_time %} + {% assign words = page.content | strip_html | number_of_words %} +{% endif %} + +{% if words < words_per_minute %} + {{ site.data.ui-text[site.locale].less_than | default: "less than" }} 1 {{ site.data.ui-text[site.locale].minute_read | default: "minute read" }} +{% elsif words == words_per_minute %} + 1 {{ site.data.ui-text[site.locale].minute_read | default: "minute read" }} +{% else %} + {{ words | divided_by:words_per_minute }} {{ site.data.ui-text[site.locale].minute_read | default: "minute read" }} +{% endif %} diff --git a/_includes/scripts.html b/_includes/scripts.html new file mode 100644 index 0000000..5530028 --- /dev/null +++ b/_includes/scripts.html @@ -0,0 +1,39 @@ +{% if site.footer_scripts %} + {% for script in site.footer_scripts %} + {% if script contains "://" %} + {% capture script_path %}{{ script }}{% endcapture %} + {% else %} + {% capture script_path %}{{ script | relative_url }}{% endcapture %} + {% endif %} + + {% endfor %} +{% else %} + + +{% endif %} + +{% if site.search == true or page.layout == "search" %} + {%- assign search_provider = site.search_provider | default: "lunr" -%} + {%- case search_provider -%} + {%- when "lunr" -%} + {% include_cached search/lunr-search-scripts.html %} + {%- when "google" -%} + {% include_cached search/google-search-scripts.html %} + {%- when "algolia" -%} + {% include_cached search/algolia-search-scripts.html %} + {%- endcase -%} +{% endif %} + +{% include analytics.html %} +{% include /comments-providers/scripts.html %} + +{% if site.after_footer_scripts %} + {% for script in site.after_footer_scripts %} + {% if script contains "://" %} + {% capture script_path %}{{ script }}{% endcapture %} + {% else %} + {% capture script_path %}{{ script | relative_url }}{% endcapture %} + {% endif %} + + {% endfor %} +{% endif %} diff --git a/_includes/search/algolia-search-scripts.html b/_includes/search/algolia-search-scripts.html new file mode 100644 index 0000000..a6bc9d2 --- /dev/null +++ b/_includes/search/algolia-search-scripts.html @@ -0,0 +1,54 @@ + + + + + + diff --git a/_includes/search/google-search-scripts.html b/_includes/search/google-search-scripts.html new file mode 100644 index 0000000..4af7423 --- /dev/null +++ b/_includes/search/google-search-scripts.html @@ -0,0 +1,30 @@ + \ No newline at end of file diff --git a/_includes/search/lunr-search-scripts.html b/_includes/search/lunr-search-scripts.html new file mode 100644 index 0000000..574c390 --- /dev/null +++ b/_includes/search/lunr-search-scripts.html @@ -0,0 +1,10 @@ +{% assign lang = site.locale | slice: 0,2 | default: "en" %} +{% case lang %} +{% when "gr" %} + {% assign lang = "gr" %} +{% else %} + {% assign lang = "en" %} +{% endcase %} + + + \ No newline at end of file diff --git a/_includes/search/search_form.html b/_includes/search/search_form.html new file mode 100644 index 0000000..c346379 --- /dev/null +++ b/_includes/search/search_form.html @@ -0,0 +1,26 @@ +
+ {%- assign search_provider = site.search_provider | default: "lunr" -%} + {%- case search_provider -%} + {%- when "lunr" -%} +
+ + +
+
+ {%- when "google" -%} +
+ + +
+
+ +
+ {%- when "algolia" -%} + +
+ {%- endcase -%} +
diff --git a/_includes/seo.html b/_includes/seo.html new file mode 100644 index 0000000..ead2d1f --- /dev/null +++ b/_includes/seo.html @@ -0,0 +1,161 @@ + +{%- if site.url -%} + {%- assign seo_url = site.url | append: site.baseurl -%} +{%- endif -%} +{%- assign seo_url = seo_url | default: site.github.url -%} + +{% assign title_separator = site.title_separator | default: '-' | replace: '|', '|' %} + +{%- if page.title -%} + {%- assign seo_title = page.title | append: " " | append: title_separator | append: " " | append: site.title -%} +{%- endif -%} + +{%- if seo_title -%} + {%- assign seo_title = seo_title | markdownify | strip_html | strip_newlines | escape_once -%} +{%- endif -%} + +{% if page.canonical_url %} + {%- assign canonical_url = page.canonical_url %} +{% else %} + {%- assign canonical_url = page.url | replace: "index.html", "" | absolute_url %} +{% endif %} + +{%- assign seo_description = page.description | default: page.excerpt | default: site.description -%} +{%- if seo_description -%} + {%- assign seo_description = seo_description | markdownify | strip_html | strip_newlines | escape_once -%} +{%- endif -%} + +{%- assign author = page.author | default: page.authors[0] | default: site.author -%} +{%- assign author = site.data.authors[author] | default: author -%} + +{%- if author.twitter -%} + {%- assign author_twitter = author.twitter | replace: "@", "" -%} +{%- endif -%} + +{%- assign page_large_image = page.header.og_image | default: page.header.overlay_image | default: page.header.image -%} +{%- unless page_large_image contains '://' -%} + {%- assign page_large_image = page_large_image | absolute_url -%} +{%- endunless -%} +{%- assign page_large_image = page_large_image | escape -%} + +{%- assign page_teaser_image = page.header.teaser | default: site.og_image -%} +{%- unless page_teaser_image contains '://' -%} + {%- assign page_teaser_image = page_teaser_image | absolute_url -%} +{%- endunless -%} +{%- assign page_teaser_image = page_teaser_image | escape -%} + +{%- assign site_og_image = site.og_image -%} +{%- unless site_og_image contains '://' -%} + {%- assign site_og_image = site_og_image | absolute_url -%} +{%- endunless -%} +{%- assign site_og_image = site_og_image | escape -%} + +{%- if page.date -%} + {%- assign og_type = "article" -%} +{%- else -%} + {%- assign og_type = "website" -%} +{%- endif -%} + +{{ seo_title | default: site.title }}{% if paginator %}{% unless paginator.page == 1 %} {{ title_separator }} {{ site.data.ui-text[site.locale].page | default: "Page" }} {{ paginator.page }}{% endunless %}{% endif %} + + +{% if author.name %} + +{% endif %} + + + + + + + +{% if page.excerpt %} + +{% endif %} + +{% if page_large_image %} + +{% elsif page_teaser_image %} + +{% endif %} + +{% if site.twitter.username %} + + + + + + {% if page_large_image %} + + + {% else %} + + {% if page_teaser_image %} + + {% endif %} + {% endif %} + + {% if author_twitter %} + + {% endif %} +{% endif %} + +{% if page.date %} + +{% endif %} + +{% if og_type == "article" and page.last_modified_at %} + +{% endif %} + +{% if site.facebook %} + {% if site.facebook.publisher %} + + {% endif %} + + {% if site.facebook.app_id %} + + {% endif %} +{% endif %} + + + +{% if paginator.previous_page %} + +{% endif %} +{% if paginator.next_page %} + +{% endif %} + + + +{% if site.google_site_verification %} + +{% endif %} +{% if site.bing_site_verification %} + +{% endif %} +{% if site.alexa_site_verification %} + +{% endif %} +{% if site.yandex_site_verification %} + +{% endif %} +{% if site.naver_site_verification %} + +{% endif %} + diff --git a/_includes/sidebar.html b/_includes/sidebar.html new file mode 100644 index 0000000..2a1884e --- /dev/null +++ b/_includes/sidebar.html @@ -0,0 +1,24 @@ +{% if page.author_profile or layout.author_profile or page.sidebar %} + +{% endif %} \ No newline at end of file diff --git a/_includes/skip-links.html b/_includes/skip-links.html new file mode 100644 index 0000000..2cd9f17 --- /dev/null +++ b/_includes/skip-links.html @@ -0,0 +1,8 @@ + diff --git a/_includes/social-share.html b/_includes/social-share.html new file mode 100644 index 0000000..0b37798 --- /dev/null +++ b/_includes/social-share.html @@ -0,0 +1,11 @@ +
+ {% if site.data.ui-text[site.locale].share_on_label %} + + {% endif %} + + + + + + LinkedIn +
diff --git a/_includes/tag-list.html b/_includes/tag-list.html new file mode 100644 index 0000000..e0d02bf --- /dev/null +++ b/_includes/tag-list.html @@ -0,0 +1,26 @@ +{% case site.tag_archive.type %} + {% when "liquid" %} + {% assign path_type = "#" %} + {% when "jekyll-archives" %} + {% assign path_type = nil %} +{% endcase %} + +{% if site.tag_archive.path %} + {% comment %} + + + {% endcomment %} + {% capture page_tags %}{% for tag in page.tags %}{{ tag | downcase }}|{{ tag }}{% unless forloop.last %},{% endunless %}{% endfor %}{% endcapture %} + {% assign tag_hashes = page_tags | split: ',' | sort %} + +

+ {{ site.data.ui-text[site.locale].tags_label | default: "Tags:" }} + + {% for hash in tag_hashes %} + {% assign keyValue = hash | split: '|' %} + {% capture tag_word %}{{ keyValue[1] | strip_newlines }}{% endcapture %} + {% unless forloop.last %}, {% endunless %} + {% endfor %} + +

+{% endif %} \ No newline at end of file diff --git a/_includes/toc b/_includes/toc new file mode 100644 index 0000000..6423ccd --- /dev/null +++ b/_includes/toc @@ -0,0 +1,7 @@ + \ No newline at end of file diff --git a/_includes/toc.html b/_includes/toc.html new file mode 100644 index 0000000..54ab8b0 --- /dev/null +++ b/_includes/toc.html @@ -0,0 +1,85 @@ +{% capture tocWorkspace %} + {% comment %} + Version 1.0.5 + https://github.com/allejo/jekyll-toc + + "...like all things liquid - where there's a will, and ~36 hours to spare, there's usually a/some way" ~jaybe + + Usage: + {% include toc.html html=content sanitize=true class="inline_toc" id="my_toc" h_min=2 h_max=3 %} + + Parameters: + * html (string) - the HTML of compiled markdown generated by kramdown in Jekyll + + Optional Parameters: + * sanitize (bool) : false - when set to true, the headers will be stripped of any HTML in the TOC + * class (string) : '' - a CSS class assigned to the TOC + * id (string) : '' - an ID to assigned to the TOC + * h_min (int) : 1 - the minimum TOC header level to use; any header lower than this value will be ignored + * h_max (int) : 6 - the maximum TOC header level to use; any header greater than this value will be ignored + * ordered (bool) : false - when set to true, an ordered list will be outputted instead of an unordered list + * item_class (string) : '' - add custom class for each list item; has support for '%level%' placeholder, which is the current heading level + * baseurl (string) : '' - add a base url to the TOC links for when your TOC is on another page than the actual content + + Output: + An ordered or unordered list representing the table of contents of a markdown block. This snippet will only generate the table of contents and will NOT output the markdown given to it + {% endcomment %} + + {% capture my_toc %}{% endcapture %} + {% assign orderedList = include.ordered | default: false %} + {% assign minHeader = include.h_min | default: 1 %} + {% assign maxHeader = include.h_max | default: 6 %} + {% assign nodes = include.html | split: ' maxHeader %} + {% continue %} + {% endif %} + + {% if firstHeader %} + {% assign firstHeader = false %} + {% assign minHeader = headerLevel %} + {% endif %} + + {% assign indentAmount = headerLevel | minus: minHeader | add: 1 %} + {% assign _workspace = node | split: '' | first }}>{% endcapture %} + {% assign header = _workspace[0] | replace: _hAttrToStrip, '' %} + + {% assign space = '' %} + {% for i in (1..indentAmount) %} + {% assign space = space | prepend: ' ' %} + {% endfor %} + + {% unless include.item_class == blank %} + {% capture listItemClass %}{:.{{ include.item_class | replace: '%level%', headerLevel }}}{% endcapture %} + {% endunless %} + + {% capture my_toc %}{{ my_toc }} +{{ space }}{{ listModifier }} {{ listItemClass }} [{% if include.sanitize %}{{ header | strip_html }}{% else %}{{ header }}{% endif %}]({% if include.baseurl %}{{ include.baseurl }}{% endif %}#{{ html_id }}){% endcapture %} + {% endfor %} + + {% if include.class %} + {% capture my_toc %}{:.{{ include.class }}} +{{ my_toc | lstrip }}{% endcapture %} + {% endif %} + + {% if include.id %} + {% capture my_toc %}{: #{{ include.id }}} +{{ my_toc | lstrip }}{% endcapture %} + {% endif %} +{% endcapture %}{% assign tocWorkspace = '' %}{{ my_toc | markdownify | strip }} \ No newline at end of file diff --git a/_includes/video b/_includes/video new file mode 100644 index 0000000..8955c7c --- /dev/null +++ b/_includes/video @@ -0,0 +1,13 @@ +{% capture video_id %}{{ include.id }}{% endcapture %} +{% capture video_provider %}{{ include.provider }}{% endcapture %} + + +
+{% if video_provider == "vimeo" %} + +{% elsif video_provider == "youtube" %} + +{% elsif video_provider == "google-drive" %} + +{% endif %} +
-- cgit v1.2.3