jekyll-theme-horizon-flow 1.0.2 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0b1490345f03372f82de84d6e7cbf9bb019b71b7eaf29004d33864cc50056162
4
- data.tar.gz: 3ca9974557e6cd103bbce7f55ec75cc35b5685aab2ec9a3e42f69839cd6653ff
3
+ metadata.gz: 9c647058ba28712037b2b276685ef637181cebaf265936fa6fe33851bfd33dbd
4
+ data.tar.gz: cecdc33724d7eb33c8f82f478b7350467521716b16928e03d178e3b586421794
5
5
  SHA512:
6
- metadata.gz: 8748f115726697bef71a04e003b388606e6c41943e10eb678ba6562c6286d25ad2b04a213fcf55268688154201dd747bea7d72b1f9d06ba6aa0993a405a0d678
7
- data.tar.gz: 05dcf53e6abff5e184cd946187f9b33e01c592b2c3c4e056241322b30bab813dc8eb0404a7e01e8d905a5e24b5f0e916310f62c8e8b1face7e24fa9935bde007
6
+ metadata.gz: 135dfa6cfba4c0de80dff89de1e9d8c9faea873f01614290b43c61b5546d1f1889232de0f1c9933ac1ec8443c97efca37189b93904f5a6a135beadef6821548e
7
+ data.tar.gz: 2bf8d58ff86af1d06aa699f6242c9d3491063dc32cb927eeafa73b5a6637c9aeaa14f6d0309c5354732c576c0cef54741f60d4752b23e1e4f95345dfe249ebe5
data/README.md CHANGED
@@ -1,7 +1,5 @@
1
1
  # [Horizon Flow Jekyll Theme](https://papierkorp.github.io/jekyll-theme-horizon-flow/)
2
2
 
3
- <!-- MarkdownTOC -->
4
-
5
3
  - [Installation](#installation)
6
4
  - [Configuration](#configuration)
7
5
  - [Site URL](#site-url)
@@ -15,6 +13,7 @@
15
13
  - [Read Time](#read-time)
16
14
  - [default plugins](#default-plugins)
17
15
  - [Configurable Labels](#configurable-labels)
16
+ - [Comments](#comments)
18
17
  - [Front Matter](#front-matter)
19
18
  - [Layouts](#layouts-1)
20
19
  - [`layout: default`](#layout-default)
@@ -26,13 +25,11 @@
26
25
  - [`layout: tags`](#layout-tags)
27
26
  - [whislist](#whislist)
28
27
 
29
- <!-- /MarkdownTOC -->
30
-
31
-
32
28
 
33
29
  [![LICENSE](https://img.shields.io/badge/license-MIT-lightgrey.svg?style=flat-square)](https://raw.githubusercontent.com/papierkorp/jekyll-theme-horizon-flow/main/LICENSE.txt)
34
30
  [![Jekyll](https://img.shields.io/badge/jekyll-%3E%3D%203.6-blue.svg?style=flat-square)](https://jekyllrb.com/)
35
- [![Ruby gem](https://img.shields.io/gem/v/jekyll-theme-so-simple.svg?style=flat-square)](https://rubygems.org/gems/jekyll-theme-horizon-flow)
31
+ [![Gem Version](https://badge.fury.io/rb/jekyll-theme-horizon-flow.svg)](https://badge.fury.io/rb/jekyll-theme-horizon-flow)
32
+
36
33
 
37
34
  This is my first ever theme or anything like this so I got a whole damn LOT of Inspiration and Ideas of the [So Simple](https://github.com/mmistakes/so-simple-theme/tree/master) theme from [mmistakes](https://github.com/mmistakes). Also i almost completly copied his readme pls forgive me <3.
38
35
 
@@ -40,20 +37,19 @@ This theme can offer:
40
37
 
41
38
  * Custom Navigation
42
39
  * Dynamically created Footer with Font Awesome Icons and Social Links
43
- * Flexible customizable Footer-Sidebar (above the Footer) where you can include up to 5 elements. You can choose between 4 premade ones and self created ones
40
+ * optional, flexible and customizable Footer-Sidebar (above the Footer)
41
+ * include up to 5 elements in the Footer-sidebar, choosen between 4 premade ones and self created ones
44
42
  * SEO best practices via [Jekyll SEO Tag](https://github.com/jekyll/jekyll-seo-tag)
45
- * Javascript free besides the optional search page
43
+ * Javascript free besides the optional search page and the optional comments
46
44
  * supports tags and categories
47
45
  * offers an archive
48
46
  * Carefully designed posts for almost all Markup elements
49
47
  * Activateable TOC and to the TOP Buttons for each post
48
+ * Mobile Friendly
49
+ * Highly Customizable
50
+ * optional server-free [Comments](https://www.aleksandrhovhannisyan.com/blog/jekyll-comment-system-github-issues/#how-to-add-comments-to-a-jekyll-blog) with Github Issues (hosted on Github)
50
51
 
51
52
  ![Horizon Flow Screenshots](https://papierkorp.github.io/jekyll-theme-horizon-flow/screenshot.png)
52
- ![Horizon Flow Screenshots](https://papierkorp.github.io/jekyll-theme-horizon-flow/post.png)
53
- ![Horizon Flow Screenshots](https://papierkorp.github.io/jekyll-theme-horizon-flow/post_toc.png)
54
- ![Horizon Flow Screenshots](https://papierkorp.github.io/jekyll-theme-horizon-flow/categories.png)
55
- ![Horizon Flow Screenshots](https://papierkorp.github.io/jekyll-theme-horizon-flow/tags.png)
56
- ![Horizon Flow Screenshots](https://papierkorp.github.io/jekyll-theme-horizon-flow/archive.png)
57
53
 
58
54
 
59
55
  ## Installation
@@ -220,6 +216,7 @@ As for the possible Configurations this theme offers take note of the following:
220
216
  * [Read Time](#read-time)
221
217
  * [default plugins](#default-plugins)
222
218
  * [Configurable Labels](#configurable-labels)
219
+ * [Comments](#comments)
223
220
 
224
221
  ### Site URL
225
222
 
@@ -371,7 +368,7 @@ footer_links:
371
368
  ### Layouts
372
369
 
373
370
  In here you can define the amount of columns used to display all tags/categories/years via the `_config`.
374
- Available values are `1-5`.
371
+ Available values are `0-5`.
375
372
 
376
373
  ```yaml
377
374
  layouts:
@@ -387,7 +384,7 @@ layouts:
387
384
  ### Footer Sidebar
388
385
 
389
386
  The footer Sidebar is the content directly above the footer.
390
- Per default there are 4 elements available:
387
+ Per default there are 6 elements available:
391
388
 
392
389
  **description:** Uses the `description:` of `_config` to display all the data from there. For the best experience you should use an <h1></h1> on the top.
393
390
  **categories:** Shows random categories according to the count.
@@ -410,6 +407,8 @@ description: >- # this means to ignore newlines until
410
407
  </p>
411
408
 
412
409
  footer_sidebar:
410
+ enabled: true
411
+ auto: false # false = all elements will have the same width, true = each element takes what it needs
413
412
  arrangement: # you can rearrange the positions of the elements
414
413
  - description # will be the first one to be displayed
415
414
  - tags # second in the row ...
@@ -417,25 +416,34 @@ footer_sidebar:
417
416
  - recentposts # will be displayed last
418
417
  description:
419
418
  enabled: true # default: true
419
+ columns: 2 # default: 0 - if you include a list
420
420
  categories:
421
421
  enabled: true # default: false
422
422
  count: 100 # default: 100
423
+ columns: 5 # default: 0
423
424
  tags:
424
425
  enabled: true # default: false
425
426
  count: 100 # default: 100
427
+ columns: 5 # default: 0
426
428
  recentposts:
427
429
  enabled: true # default: true
428
- count: 10 # default: 10
430
+ count: 10 # default: 5
431
+ columns: 2 # default: 0
429
432
  custom_content:
430
433
  enabled: true
431
434
  data: >-
432
435
  <h3>EXTRACONTENT</h3>
433
436
  <p>not really content though...</p>
437
+ columns: 2 # default: 0 - if you include a list
434
438
  custom_content2:
435
439
  enabled: false
436
440
  data: "<h3>mhm</h3>"
441
+ columns: 2 # default: 0 - if you include a list
437
442
  ```
438
443
 
444
+ The default of `0` stands for automatic alignment.
445
+
446
+
439
447
  ### Table of Contents
440
448
 
441
449
  Take a look at the [Front Matter](#front-matter) on how to disable the TOC.
@@ -520,6 +528,21 @@ categories_nothing_found: "No categories available."
520
528
  ```
521
529
 
522
530
 
531
+ ### Comments
532
+
533
+ This theme enables the use of Comments per Github Issues API (taken from [here](https://www.aleksandrhovhannisyan.com/blog/jekyll-comment-system-github-issues/#how-to-add-comments-to-a-jekyll-blog)).
534
+ To enable comments you will need the following Config:
535
+
536
+ ```yaml
537
+ issues_repo: YourUsername/RepoName # e.g.: issues_repo: papierkorp/blog
538
+ ```
539
+
540
+ In addition you will have to open up a Issue for each blog post manually and copy the ID of this Issue.
541
+ Afterwards add this Front Matter to your Post:
542
+
543
+ ```yaml
544
+ comments_id: 1
545
+ ```
523
546
 
524
547
  ---
525
548
 
@@ -533,6 +556,7 @@ This theme offers the following Front-Matter:
533
556
  |--------|------------------|-----------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
534
557
  | `post` | subtitle | Adds a subtitle to the post (optional) | ---<br>subtitle: "You're going to love this." <br>--- |
535
558
  | `post` | display_toc | true or false, shows the toc button on the bottom right (default: true) | ---<br>display_toc: false <br>--- |
559
+ | `post` | display_toc2 | true or false, shows another toc on the right side permanently (default: false) | ---<br>display_toc2: true <br>--- |
536
560
  | `post` | last_modified_at | Add extra meta-data when the post was last modified. It takes the date as you write it like a string. | ---<br>last_modified_at: 10.09.2023 <br>--- |
537
561
  | `post` | search_keywords | Add extra data to the [search.json](#layout-:-search) file | ---<br>search_keywords: "words i didnt use in the tags" <br>--- |
538
562
  | `post` | toTop | true or false, shows the "To the Top" button on the bottom left (default: true) | ---<br>toTop: false <br>--- |
@@ -540,6 +564,7 @@ This theme offers the following Front-Matter:
540
564
  | `post` | noheader | Disable the whole header and only show the Content. (default: false) | ---<br>noheader: true <br>--- |
541
565
  | `post` | searchable | The post wont be included in the search. | ---<br>searchable: false <br>--- |
542
566
  | `post` | show_supplements | The supplements (date, readtime, tags...) wont be shown. | ---<br>show_supplements: false<br><br>--- |
567
+ | `post` | comments_id | If you want to enable comments (hosted on Github - needs the neccessary config set) | ---<br>comments_id: 1<br><br>--- |
543
568
  | `home` | noheader | Disable the whole header and only show the Content. (default: false) | ---<br>noheader: true <br>--- |
544
569
 
545
570
  ---
@@ -610,9 +635,4 @@ There is no front matter for it.
610
635
 
611
636
  # whislist
612
637
 
613
- - footer
614
- + make the columns in the footer-sidebar (tags, categories, recent posts) configurable
615
- + fix for mobile screens
616
- - post
617
- + fix TOC for mobile screens
618
638
  - more colors
data/_config.yml CHANGED
@@ -54,13 +54,27 @@ plugins:
54
54
  # - vendor/gems/
55
55
  # - vendor/ruby/
56
56
 
57
+ #------------------------------------AddOns------------------------------------
58
+
59
+ issues_repo: papierkorp/blog
60
+
57
61
  #------------------------------------Horizon Flow specific------------------------------------
58
62
 
59
63
  navigation:
60
64
  - title: Home
61
65
  url: /index.html
66
+ - title: Categories
67
+ url: /categories.html
68
+ - title: Tags
69
+ url: /tags.html
70
+ - title: Archive
71
+ url: /archive.html
72
+ - title: Search
73
+ url: /search.html
62
74
 
63
75
  footer_sidebar:
76
+ enabled: true
77
+ auto: true
64
78
  arrangement:
65
79
  - description
66
80
  - tags
@@ -70,31 +84,41 @@ footer_sidebar:
70
84
  enabled: true
71
85
  categories:
72
86
  enabled: true
73
- count: 100
74
- columns: 1
75
87
  tags:
76
88
  enabled: true
77
- count: 100
78
- columns: 3
79
89
  recentposts:
80
90
  enabled: true
81
- count: 10
82
- columns: 2
83
91
 
84
92
  footer_links:
85
93
  - title: Feed
86
94
  url: /feed.xml
87
95
  icon: fa fa-rss
96
+ - title: GitHub
97
+ url: https://github.com/papierkorp
98
+ icon: fa fa-github
99
+ - title: Email
100
+ url: mailto:xxx@test.de
101
+ icon: fa fa-envelope
102
+ - title: Twitter
103
+ url: https://twitter.com
104
+ icon: fa fa-twitter
105
+ - title: Facebook
106
+ url: https://facebook.com
107
+ icon: fa fa-facebook
108
+ - title: Instagram
109
+ url: https://instagram.com
110
+ icon: fa fa-instagram
111
+ - title: Impressum
112
+ url: /impressum.html
88
113
 
89
114
  defaults:
90
115
  -
91
116
  scope:
92
117
  path: "_posts"
93
118
  values:
94
- toc: yes
95
119
  display_toc: true
96
120
 
97
- paginate: 5
121
+ paginate: 3
98
122
  paginate_path: "/:num/"
99
123
 
100
124
  read_time_after: "min read"
@@ -0,0 +1,127 @@
1
+ {% assign issues_repo = site.issues_repo %}
2
+ {% assign issue_id = include.issue_id %}
3
+
4
+ <section id="comments">
5
+ <div class="comment-actions">
6
+ <h2><span id="comments-count"></span> Comments</h2>
7
+ <a
8
+ class="comment_button"
9
+ href="https://github.com/{{ issues_repo }}/issues/{{ issue_id }}"
10
+ target="_blank"
11
+ >
12
+ Comment on Github
13
+ <i class="fa fa-external-link" aria-hidden="true">
14
+
15
+ </i>
16
+ </a>
17
+ </div>
18
+ <div id="comments-wrapper">
19
+ Loading...
20
+ </div>
21
+ </section>
22
+
23
+
24
+
25
+ <script>
26
+ const commentsSection = document.getElementById('comments');
27
+ const commentsWrapper = commentsSection.querySelector('#comments-wrapper');
28
+ const commentsCount = commentsSection.querySelector('#comments-count');
29
+
30
+ const commentsObserver = new IntersectionObserver((entries, self) => {
31
+ entries.forEach((entry) => {
32
+ if (entry.isIntersecting) {
33
+ fetchComments(); // this is the important part
34
+ self.unobserve(entry.target);
35
+ }
36
+ });
37
+ }, { rootMargin: '200px 0px 0px 0px' });
38
+
39
+ commentsObserver.observe(commentsSection);
40
+
41
+ const fetchComments = async () => {
42
+ try {
43
+ const comments = await (await fetch(
44
+ 'https://api.github.com/repos/{{ issues_repo }}/issues/{{ issue_id }}/comments'
45
+ )).json();
46
+ initRenderComments(comments);
47
+ } catch (e) {
48
+ commentsWrapper.innerHTML = `<p>Unable to retrieve the comments for this post.</p>`;
49
+ }
50
+ }
51
+
52
+ const loadScript = (src) => {
53
+ const scriptElement = document.createElement('script');
54
+ document.body.appendChild(scriptElement);
55
+
56
+ return new Promise((resolve) => {
57
+ scriptElement.onload = resolve;
58
+
59
+ // Important to register onload before setting src
60
+ scriptElement.src = src;
61
+ });
62
+ }
63
+
64
+ const commentScripts = [
65
+ 'https://unpkg.com/marked@0.3.6/marked.min.js',
66
+ 'https://unpkg.com/dompurify@1.0.8/dist/purify.min.js',
67
+ 'https://unpkg.com/dayjs@1.8.21/dayjs.min.js',
68
+ 'https://unpkg.com/dayjs@1.7.8/plugin/relativeTime.js',
69
+ ];
70
+
71
+ // Reminder: this gets called when the viewport intersects with the comments section
72
+ const initRenderComments = async (comments) => {
73
+ if (!comments.length) {
74
+ commentsWrapper.innerHTML = `<p>No comments yet 👀 Be the first to post!</p>`;
75
+ return;
76
+ }
77
+
78
+ // Load all comment script dependencies async
79
+ await Promise.all(commentScripts.map((script) => loadScript(script)));
80
+ renderComments(comments);
81
+ }
82
+
83
+ const renderComments = (comments) => {
84
+ // load the relativeTime plugin for dayjs so we can express dates relative to now
85
+ dayjs.extend(dayjs_plugin_relativeTime);
86
+
87
+ commentsCount.innerText = `${comments.length}`;
88
+
89
+ const commentsList = document.createElement('ol');
90
+ commentsList.className = 'comments-list';
91
+ commentsList.setAttribute('aria-label', 'Comments on this blog post');
92
+
93
+ commentsList.innerHTML = comments
94
+ .sort((comment1, comment2) => {
95
+ return comment1.created_at < comment2.created_at ? 1 : -1;
96
+ })
97
+ .map(comment => {
98
+ const datePosted = dayjs(comment.created_at).fromNow();
99
+ const user = comment.user;
100
+ const body = DOMPurify.sanitize(marked(comment.body));
101
+ const postedByAuthor = comment.author_association === 'OWNER';
102
+ const edited = comment.created_at !== comment.updated_at;
103
+
104
+ return `<li class="comment">
105
+ <div class="commenter">
106
+ <img src="${user.avatar_url}" alt="" aria-hidden="true" class="avatar" />
107
+ <a
108
+ href="https://github.com/${user.login}"
109
+ class="username"
110
+ target="_blank"
111
+ >${user.login}</a
112
+ >
113
+ <div class="date-posted">commented <time datetime="${comment.created_at}">${datePosted}</time></div>
114
+ ${postedByAuthor ? '<span class="tag author-badge">Author</span>' : ''}
115
+ ${edited ? `<span class="comment-edited">Edited</span>` : ''}
116
+ </div>
117
+ <div class="comment-body">${body}</div>
118
+ </li>`;
119
+ })
120
+ .join('');
121
+
122
+ commentsWrapper.innerHTML = '';
123
+ commentsWrapper.appendChild(commentsList);
124
+ }
125
+
126
+
127
+ </script>
@@ -9,77 +9,79 @@
9
9
  <footer>
10
10
 
11
11
 
12
- {% if site.footer_sidebar.arrangement %}
13
- <aside class="footer_sidebar">
14
- {% for section in site.footer_sidebar.arrangement %}
15
- {% if section == 'description' and site.footer_sidebar.description.enabled %}
16
- <section class="footer_sitedescription">
17
- {{ site.description }}
18
- </section>
19
- {% elsif section == 'extracontent' and site.footer_sidebar.extracontent.enabled %}
20
- <section class="footer_extracontent">
21
- {{ site.footer_sidebar.extracontent.data }}
22
- </section>
23
- {% elsif section == 'extracontent2' and site.footer_sidebar.extracontent2.enabled %}
24
- <section class="footer_extracontent">
25
- {{ site.footer_sidebar.extracontent2.data }}
26
- </section>
27
- {% elsif section == 'categories' and site.footer_sidebar.categories.enabled %}
28
- <section class="footer_categories">
29
- <h3>Categories</h3>
30
- <ul>
31
- {% assign all_categories = "" %}
32
- {% for post in site.posts %}
33
- {% assign post_categories = post.categories %}
34
- {% for category in post_categories %}
35
- {% assign all_categories = all_categories | append: category | append: "," %}
12
+ {% if site.footer_sidebar.enabled %}
13
+ {% if site.footer_sidebar.arrangement %}
14
+ <aside class="footer_sidebar footer_aside{% if site.footer_sidebar.auto %}_auto{% endif %}">
15
+ {% for section in site.footer_sidebar.arrangement %}
16
+ {% if section == 'description' and site.footer_sidebar.description.enabled %}
17
+ <section class="footer_sitedescription footer_sitedescription{% if site.footer_sidebar.description.columns and site.footer_sidebar.description.columns >= 0 and site.footer_sidebar.description.columns <= 5 %}{{site.footer_sidebar.description.columns}}{% else %}0{% endif %}">
18
+ {{ site.description }}
19
+ </section>
20
+ {% elsif section == 'customcontent' and site.footer_sidebar.customcontent.enabled %}
21
+ <section class="footer_customcontent footer_customcontent{% if site.footer_sidebar.customcontent.columns and site.footer_sidebar.customcontent.columns >= 0 and site.footer_sidebar.customcontent.columns <= 5 %}{{site.footer_sidebar.customcontent.columns}}{% else %}0{% endif %}">
22
+ {{ site.footer_sidebar.customcontent.data }}
23
+ </section>
24
+ {% elsif section == 'customcontent2' and site.footer_sidebar.customcontent2.enabled %}
25
+ <section class="footer_customcontent2 footer_customcontent2{% if site.footer_sidebar.customcontent2.columns and site.footer_sidebar.customcontent2.columns >= 0 and site.footer_sidebar.customcontent2.columns <= 5 %}{{site.footer_sidebar.customcontent2.columns}}{% else %}0{% endif %}">
26
+ {{ site.footer_sidebar.customcontent2.data }}
27
+ </section>
28
+ {% elsif section == 'categories' and site.footer_sidebar.categories.enabled %}
29
+ <section class="footer_categories footer_categories{% if site.footer_sidebar.categories.columns and site.footer_sidebar.categories.columns >= 0 and site.footer_sidebar.categories.columns <= 5 %}{{site.footer_sidebar.categories.columns}}{% else %}0{% endif %}">
30
+ <h3>Categories</h3>
31
+ <ul>
32
+ {% assign all_categories = "" %}
33
+ {% for post in site.posts %}
34
+ {% assign post_categories = post.categories %}
35
+ {% for category in post_categories %}
36
+ {% assign all_categories = all_categories | append: category | append: "," %}
37
+ {% endfor %}
36
38
  {% endfor %}
37
- {% endfor %}
38
- {% assign unique_categories = all_categories | split: "," | uniq %}
39
-
40
- {% assign categories_count = site.footer_sidebar.categories.count | default: 100 %}
41
- {% assign categories_to_display = unique_categories | slice: 0, categories_count %}
42
-
43
- {% for category in categories_to_display %}
44
- <li><a href="{{ site.baseurl }}/categories.html#{{ category }}">{{ category }}</a></li>
45
- {% endfor %}
46
- </ul>
47
- </section>
48
- {% elsif section == 'tags' and site.footer_sidebar.tags.enabled %}
49
- <section class="footer_tags">
50
- <h3>Tags</h3>
51
- <ul>
52
- {% assign all_tags = "" %}
53
- {% for post in site.posts %}
54
- {% assign post_tags = post.tags %}
55
- {% for tag in post_tags %}
56
- {% assign all_tags = all_tags | append: tag | append: "," %}
39
+ {% assign unique_categories = all_categories | split: "," | uniq %}
40
+
41
+ {% assign categories_count = site.footer_sidebar.categories.count | default: 100 %}
42
+ {% assign categories_to_display = unique_categories | slice: 0, categories_count %}
43
+
44
+ {% for category in categories_to_display %}
45
+ <li><a href="{{ site.baseurl }}/categories.html#{{ category }}">{{ category }}</a></li>
57
46
  {% endfor %}
58
- {% endfor %}
59
- {% assign unique_tags = all_tags | split: "," | uniq %}
60
-
61
- {% assign tags_count = site.footer_sidebar.tags.count | default: 100 %}
62
- {% assign tags_to_display = unique_tags | slice: 0, tags_count %}
63
-
64
- {% for tag in tags_to_display %}
65
- <li><a href="{{ site.baseurl }}/tags#{{ tag }}">{{ tag }}</a></li>
66
- {% endfor %}
67
- </ul>
68
- </section>
69
- {% elsif section == 'recentposts' and site.footer_sidebar.recentposts.enabled %}
70
- <section class="footer_recentposts">
71
- <h3>Recent Posts</h3>
72
- <ul>
73
- {% assign recentposts_count = site.footer_sidebar.recentposts.count | default: 10 %}
74
- {% assign recent_posts = site.posts | reverse | limit: recentposts_count %}
75
- {% for post in recent_posts %}
76
- <li><a href="{{ site.baseurl }}{{ post.url }}">{{ post.title }}</a></li>
77
- {% endfor %}
78
- </ul>
79
- </section>
80
- {% endif %}
81
- {% endfor %}
82
- </aside>
47
+ </ul>
48
+ </section>
49
+ {% elsif section == 'tags' and site.footer_sidebar.tags.enabled %}
50
+ <section class="footer_tags footer_tags{% if site.footer_sidebar.tags.columns and site.footer_sidebar.tags.columns >= 0 and site.footer_sidebar.tags.columns <= 5 %}{{site.footer_sidebar.tags.columns}}{% else %}0{% endif %}">
51
+ <h3>Tags</h3>
52
+ <ul>
53
+ {% assign all_tags = "" %}
54
+ {% for post in site.posts %}
55
+ {% assign post_tags = post.tags %}
56
+ {% for tag in post_tags %}
57
+ {% assign all_tags = all_tags | append: tag | append: "," %}
58
+ {% endfor %}
59
+ {% endfor %}
60
+ {% assign unique_tags = all_tags | split: "," | uniq %}
61
+
62
+ {% assign tags_count = site.footer_sidebar.tags.count | default: 100 %}
63
+ {% assign tags_to_display = unique_tags | slice: 0, tags_count %}
64
+
65
+ {% for tag in tags_to_display %}
66
+ <li><a href="{{ site.baseurl }}/tags#{{ tag }}">{{ tag }}</a></li>
67
+ {% endfor %}
68
+ </ul>
69
+ </section>
70
+ {% elsif section == 'recentposts' and site.footer_sidebar.recentposts.enabled %}
71
+ <section class="footer_recentposts footer_recentposts{% if site.footer_sidebar.recentposts.columns and site.footer_sidebar.recentposts.columns >= 0 and site.footer_sidebar.recentposts.columns <= 5 %}{{site.footer_sidebar.recentposts.columns}}{% else %}0{% endif %}">
72
+ <h3>Recent Posts</h3>
73
+ <ul>
74
+ {% assign recentposts_count = site.footer_sidebar.recentposts.count | default: 5 %}
75
+ {% assign recent_posts = site.posts | reverse %}
76
+ {% for post in recent_posts limit:recentposts_count %}
77
+ <li><a href="{{ site.baseurl }}{{ post.url }}">{{ post.title }}</a></li>
78
+ {% endfor %}
79
+ </ul>
80
+ </section>
81
+ {% endif %}
82
+ {% endfor %}
83
+ </aside>
84
+ {% endif %}
83
85
  {% endif %}
84
86
 
85
87
 
@@ -101,4 +103,4 @@
101
103
  </div>
102
104
  {% endif %}
103
105
 
104
- </footer>
106
+ </footer>
@@ -8,7 +8,7 @@ layout: default
8
8
 
9
9
  {% if site.posts.size > 0 %}
10
10
  <!-- show all years -->
11
- <div class="archive_all_years{% if site.layouts.archive.columns and site.layouts.archive.columns >= 1 and site.layouts.archive.columns <= 5 %}{{site.layouts.archive.columns}}{% else %}2{% endif %}">
11
+ <div class="archive_all_years archive_all_years{% if site.layouts.archive.columns and site.layouts.archive.columns >= 1 and site.layouts.archive.columns <= 5 %}{{site.layouts.archive.columns}}{% else %}2{% endif %}">
12
12
  <ul>
13
13
  {% assign postsByYear = site.posts | group_by_exp: 'post', 'post.date | date: "%Y"' %}
14
14
  {% for year in postsByYear %}
@@ -52,16 +52,12 @@ layout: default
52
52
 
53
53
  <div class="archive_findresults">
54
54
 
55
- <span class="archive_date">
55
+
56
56
 
57
- <a href="{{ site.baseurl }}{{ post.url }}">
58
- <i class="archive_day">{{ post.date | date: "%d" }}</i>
59
- </a>
60
- <a href="{{ site.baseurl }}{{ post.url }}">
61
- <span>{{ post.date | date: "%b/%Y" }}</span>
62
- </a>
63
-
64
- </span>
57
+ <a class="archive_date" href="{{ site.baseurl }}{{ post.url }}">
58
+ <i class="archive_day">{{ post.date | date: "%d" }}</i>
59
+ <span>{{ post.date | date: "%b/%Y" }}</span>
60
+ </a>
65
61
 
66
62
  <span class="archive_summary">
67
63
  <h3>
@@ -17,7 +17,7 @@ layout: default
17
17
 
18
18
  {% if sortedCategories.size > 0 %}
19
19
  <!-- Show all categories sorted by count -->
20
- <div class="categories_all{% if site.layouts.categories.columns and site.layouts.categories.columns >= 1 and site.layouts.categories.columns <= 5 %}{{site.layouts.categories.columns}}{% else %}3{% endif %}">
20
+ <div class="categories_all categories_all{% if site.footer_sidebar.categories.columns and site.footer_sidebar.categories.columns >= 1 and site.footer_sidebar.categories.columns <= 5 %}{{site.footer_sidebar.categories.columns}}{% else %}3{% endif %}">
21
21
  <ul>
22
22
  {% for category in sortedCategories %}
23
23
  {% assign categoryParts = category | split: '&#x1F;' %}
@@ -55,16 +55,10 @@ layout: default
55
55
 
56
56
  {% for post in category[1] %}
57
57
  <div class="categories_findresult">
58
- <span class="categories_date">
59
-
60
- <a href="{{ site.baseurl }}{{ post.url }}">
61
- <i class="categories_day">{{ post.date | date: "%d" }}</i>
62
- </a>
63
- <a href="{{ site.baseurl }}{{ post.url }}">
64
- <span>{{ post.date | date: "%b/%Y" }}</span>
65
- </a>
66
-
67
- </span>
58
+ <a href="{{ site.baseurl }}{{ post.url }}" class="categories_date">
59
+ <i class="categories_day">{{ post.date | date: "%d" }}</i>
60
+ <span>{{ post.date | date: "%b/%Y" }}</span>
61
+ </a>
68
62
 
69
63
  <span class="categories_summary">
70
64
  <h3>
data/_layouts/home.html CHANGED
@@ -42,16 +42,17 @@ layout: default
42
42
  </p>
43
43
 
44
44
  </article>
45
+ <hr class="article-divider">
45
46
  {% endfor %}
46
47
 
47
48
  <!-- Pagination links -->
48
49
  <div class="pagination">
49
50
  {% if paginator.previous_page %}
50
- <a class="previous" href="{{ site.baseurl}}{{ paginator.previous_page_path }}"><span class="spanprevious"><i class="arrow left" title="previous page"></i></span></a>
51
+ <a class="previous" href="{{ site.baseurl}}{{ paginator.previous_page_path }}"><span class="spanprevious"><i class="fa fa-arrow-left" title="previous page"></i></span></a>
51
52
  {% endif %}
52
53
  <p class="page_count">{{ paginator.page }} / {{ paginator.total_pages }}</p>
53
54
  {% if paginator.next_page %}
54
- <a class="next" href="{{ site.baseurl}}{{ paginator.next_page_path }}"><span class="spannext"><i class="arrow right" title="next page"></i></span></a>
55
+ <a class="next" href="{{ site.baseurl}}{{ paginator.next_page_path }}"><span class="spannext"><i class="fa fa-arrow-right" title="next page"></i></span></a>
55
56
  {% endif %}
56
57
  </div>
57
58
  </section>