simple-gh-pages-theme 0.1.5 → 0.1.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b44373a992017401fc4506c609fee23b0231a9de89aff5aed5d222d5e7fc0cba
4
- data.tar.gz: 68ef089d1446713675933bc68e9ab52ca0604f442d9daba5c885f3960b79d5bd
3
+ metadata.gz: e58f1f0573784a6e6e508ba81f4e7be5e498883fdcc582ccbd3b3177e059d582
4
+ data.tar.gz: d7ee6d6b8980f489885b3516b68006a426e449676a020fc8fa35bc2f01d7c327
5
5
  SHA512:
6
- metadata.gz: da5b2fa9992495f1fef392f35b6b5f1e600367b0c10f9c942b1228d13f33f0deb49009a9fb952d1154c27640192f1e473d4bceeb653c33a116ea1e19840fb8f7
7
- data.tar.gz: 4013a523a0b55cfbd3307844abd4806eba63fef17927903494fee981c478a9363658f4e3c7bd840b0ec203b14766eaf056294f217dd5b1cc562fd6f6177f2560
6
+ metadata.gz: 83753f4852053453298ff3a5e144905b9d0d078e64569499510bf571fc81677dae93fe357b8b4d5210d386c0b1d770767a747a3b18003b870aa5ab80d7dd8a1a
7
+ data.tar.gz: f4f88e93e15d8d07f563aeed4bc35018377c090d3490558d6bf1069943c76bdfffbe9a45353a2b0fc0668aa48851953607ba7aa7eed9826c345537852396d296
data/_data/navigation.yml CHANGED
@@ -1,6 +1,6 @@
1
1
  - name: Home
2
2
  link: /
3
3
  - name: Posts
4
- link: /posts/
4
+ link: /posts
5
5
  - name: About
6
- link: /about/
6
+ link: /about
@@ -2,7 +2,7 @@
2
2
  <div class="line"></div>
3
3
  <div>
4
4
  <!-- prettier-ignore -->
5
- {% for category in site.categories %}
5
+ {% for category in site.categories, limit: 10 %}
6
6
  {% assign nr_of_posts = 0 %}
7
7
  {% assign cat = category | first %}
8
8
  {% assign posts = site.categories[cat] %}
@@ -23,11 +23,68 @@
23
23
  </li>
24
24
  {% endfor %}
25
25
  </div>
26
+
27
+ <button
28
+ id="show-more-categories"
29
+ onclick="showMoreCategories()"
30
+ style="
31
+ border-width: 0;
32
+ padding: 0;
33
+ background: white;
34
+ margin-top: 0;
35
+ font-size: 0.8em;
36
+ color: #272b32;
37
+ "
38
+ >
39
+ more..
40
+ </button>
41
+
42
+ <div id="extra-categories" style="display: none">
43
+ <!-- prettier-ignore -->
44
+ {% for category in site.categories offset: 10 %}
45
+ {% assign nr_of_posts = 0 %}
46
+ {% assign cat = category | first %}
47
+ {% assign posts = site.categories[cat] %}
48
+ {% assign selection = posts | where_exp:"post", "post.layout == 'post'" %}
49
+ {% assign selection = selection | where_exp:"post", "post.content.size > 1" %}
50
+ {% for post in selection %}
51
+ {% assign nr_of_posts = nr_of_posts | plus:1 %}
52
+ {% endfor %}
53
+
54
+ <li class="posts-list-item short-post category-list-item">
55
+ <span class="categories">
56
+ <h4>
57
+ <a class="category" href="/category/{{ cat }}">
58
+ {{ cat }} ({{ nr_of_posts }})
59
+ </a>
60
+ </h4>
61
+ </span>
62
+ </li>
63
+ {% endfor %}
64
+ </div>
65
+
66
+ <script>
67
+ function showMoreCategories() {
68
+ var extraCategories = document.getElementById("extra-categories");
69
+ var showMoreButtonCategories = document.getElementById(
70
+ "show-more-categories"
71
+ );
72
+
73
+ if (extraCategories.style.display === "none") {
74
+ extraCategories.style.display = "block";
75
+ showMoreButtonCategories.innerText = "less..";
76
+ } else {
77
+ extraCategories.style.display = "none";
78
+ showMoreButtonCategories.innerText = "more..";
79
+ }
80
+ }
81
+ </script>
82
+
26
83
  <h2 class="title no-decoration" style="margin-top: 20px">Tags</h2>
27
84
  <div class="line"></div>
28
85
  <div>
29
86
  <!-- prettier-ignore -->
30
- {% for tag_post in site.tags %}
87
+ {% for tag_post in site.tags limit: 10 %}
31
88
  {% assign nr_of_posts = 0 %}
32
89
  {% assign tag = tag_post | first %}
33
90
  {% assign tag_posts = site.tags[tag] %}
@@ -48,3 +105,57 @@
48
105
  </li>
49
106
  {% endfor %}
50
107
  </div>
108
+
109
+ <button
110
+ id="show-more-tags"
111
+ onclick="showMoreTags()"
112
+ style="
113
+ border-width: 0;
114
+ padding: 0;
115
+ background: white;
116
+ margin-top: 0;
117
+ font-size: 0.8em;
118
+ color: #272b32;
119
+ "
120
+ >
121
+ more..
122
+ </button>
123
+
124
+ <div id="extra-tags" style="display: none">
125
+ <!-- prettier-ignore -->
126
+ {% for tag_post in site.tags offset: 10 %}
127
+ {% assign nr_of_posts = 0 %}
128
+ {% assign tag = tag_post | first %}
129
+ {% assign tag_posts = site.tags[tag] %}
130
+ {% assign tag_posts_selection = tag_posts | where_exp:"post", "post.layout == 'post'" %}
131
+ {% assign tag_posts_selection = tag_posts_selection | where_exp:"post", "post.content.size > 1" %}
132
+ {% for post in tag_posts_selection %}
133
+ {% assign nr_of_posts = nr_of_posts | plus:1 %}
134
+ {% endfor %}
135
+
136
+ <li class="posts-list-item short-post category-list-item">
137
+ <span class="categories">
138
+ <h4>
139
+ <a class="category" href="/tag/{{ tag }}">
140
+ {{ tag }} ({{ nr_of_posts }})
141
+ </a>
142
+ </h4>
143
+ </span>
144
+ </li>
145
+ {% endfor %}
146
+ </div>
147
+
148
+ <script>
149
+ function showMoreTags() {
150
+ var extraTags = document.getElementById("extra-tags");
151
+ var showMoreButton = document.getElementById("show-more-tags");
152
+
153
+ if (extraTags.style.display === "none") {
154
+ extraTags.style.display = "block";
155
+ showMoreButton.innerText = "less..";
156
+ } else {
157
+ extraTags.style.display = "none";
158
+ showMoreButton.innerText = "more..";
159
+ }
160
+ }
161
+ </script>
data/_layouts/index.html CHANGED
@@ -7,11 +7,11 @@ title: home
7
7
  <div class="posts-top">
8
8
  <!-- prettier-ignore -->
9
9
  {% assign selection = site.posts | where_exp:"post", "post.short != true" %}
10
- {% for post in selection limit: 5 %}
10
+ {% for post in selection limit: 6 %}
11
11
  {% include post-list-item.html %}
12
12
  {% endfor %}
13
13
  <h2 style="font-family: 'Arvo'">
14
- <a href="{{site.baseurl}}/posts/">&#10095;&nbsp; All posts </a>
14
+ <a href="{{site.baseurl}}/posts">&#10095;&nbsp; All posts </a>
15
15
  </h2>
16
16
  </div>
17
17
 
data/_layouts/posts.html CHANGED
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  layout: default
3
- permalink: /posts/
3
+ permalink: /posts
4
4
  ---
5
5
 
6
6
  <div class="content">
data/assets/css/main.scss CHANGED
@@ -261,7 +261,7 @@ body {
261
261
  .social {
262
262
  margin-left: auto;
263
263
  a {
264
- padding-right: 0px;
264
+ padding-right: 4px;
265
265
  text-decoration: none;
266
266
  }
267
267
  }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple-gh-pages-theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - LiveNL
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-05-10 00:00:00.000000000 Z
11
+ date: 2023-09-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll-archives