fortyone-jekyll-theme 1.1.0 → 1.2.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
  SHA1:
3
- metadata.gz: 0a5adc449fce0f3dccedfd55debed6f3cc849813
4
- data.tar.gz: 320b31f14bcb480bb2d30e678688beb72705237a
3
+ metadata.gz: 3521e50cafb9d82c7d962a2b26ac4e11c1424031
4
+ data.tar.gz: 001e6ed03492ecd490ced5a72aae931b4c5d26f6
5
5
  SHA512:
6
- metadata.gz: 70c84a3f148ba50650a795d701d4fddcf46125d1f16d33c045bf8fd2c4af62960056cc11a23a3b3053a5e5050244e7b136d40469f272199cd9a402dced988ec9
7
- data.tar.gz: 5b2f7e44b0c41e78659387eabd444517b4ad64080b7274857e0d2a6722b246613e1fc304f00eeb3be8ed8788c5811816bfe044f6340be70d7954702d556c6848
6
+ metadata.gz: afdb393a03d1cc09f2d1d682c604b806f4dc93e355c5a58834926e49c3bd9783067827c35b5a94b0ba1201dfda20c677c8e9bc6d2e18851c1d9dddbc6f3adcae
7
+ data.tar.gz: 640c7e52518b8357d188b77682c3a505ac7ff6249d16357d652f1b86e436b31db4b50ca75beda80304116b0fd64e2627a3ec43fdb1e37da81b25f308f25d92c5
data/README.md CHANGED
@@ -8,7 +8,8 @@ Add to your `Gemfile`:
8
8
 
9
9
  ```
10
10
  gem 'fortyone-jekyll-theme'
11
- ```
11
+
12
+ ```
12
13
 
13
14
  and to `_config.yml`:
14
15
 
@@ -20,13 +21,18 @@ theme: fortyone-jekyll-theme
20
21
 
21
22
  ## [FortyOne Demo](https://agustibr.gitlab.io/fortyone-jekyll-theme/)
22
23
 
23
- + landing template items from a collection
24
- + home tiles accepts pages, posts or collections
25
- + Added `alltags` template
26
- + Modified `allposts` template
27
- + You can [Customize the theme's CSS](https://help.github.com/articles/customizing-css-and-html-in-your-jekyll-theme/#customizing-your-jekyll-themes-css)
28
- + added pagination to post layout
29
- + `sass` variables easily overriden, just set them before `@import "{{ site.theme }}";` [_sass/libs/_vars.scss](https://gitlab.com/agustibr/fortyone-jekyll-theme/blob/master/_sass/libs/_vars.scss)
24
+ + layouts:
25
+ + `landing` list items from a collection
26
+ + `alltags` listing all tags of the site, with related posts
27
+ + `categories` listing all categories of the site, with related posts
28
+ + `allposts` listing posts in a chronological order
29
+ + `collection` listing all contents of a given collection
30
+ + `post` with pagination to navigate through posts
31
+ + `page` generic template
32
+ + `home` with tiles from pages,or posts, or collections. (setup in _config.yml)
33
+ + `default` the base template of all layouts
34
+ + [Customize the theme's Sass](https://help.github.com/articles/customizing-css-and-html-in-your-jekyll-theme/#customizing-your-jekyll-themes-css)
35
+ with `sass` variables easily overriden, just set them before `@import "{{ site.theme }}";` [_sass/libs/_vars.scss](https://gitlab.com/agustibr/fortyone-jekyll-theme/blob/master/_sass/libs/_vars.scss)
30
36
 
31
37
  # Credits
32
38
 
@@ -1,6 +1,6 @@
1
1
  {% assign menu_home = site.pages | where: "layout", "home" | first %}
2
- {% assign menu_links = site.pages | where: "nav-menu", true %}
3
- {% assign menu_cta_links = site.pages | where: "nav-menu-cta", true %}
2
+ {% assign menu_links = site.pages | where: "nav-menu", true | sort: 'order' %}
3
+ {% assign menu_cta_links = site.pages | where: "nav-menu-cta", true | sort: 'order' %}
4
4
 
5
5
  <!-- Header -->
6
6
  <header id="header"{% if page.layout == "landing" %} class="alt style{{ page.style }}"{% endif %}{% if page.layout == "home" %} class="alt"{% endif %}>
@@ -1,8 +1,12 @@
1
1
  ---
2
2
  layout: post
3
3
  ---
4
+
5
+ {% assign collection= site.collections | where: "label", page.collection | first %}
6
+ {% assign items = collection.docs | sort: 'order' %}
7
+
4
8
  <div class="row">
5
- {% for post in site.posts %}
9
+ {% for post in collection %}
6
10
  {% assign loopindex = forloop.index | modulo: 3 %}
7
11
  {% if loopindex == 0 %}
8
12
  <div class="4u$ 12u$(medium)">
@@ -0,0 +1,66 @@
1
+ ---
2
+ layout: post
3
+ ---
4
+
5
+ {{ content }}
6
+
7
+ {% comment%}
8
+ https://stackoverflow.com/a/28105741
9
+
10
+ Here we generate all the tags.
11
+ from: https://codinfox.github.io/dev/2015/03/06/use-tags-and-categories-in-your-jekyll-based-github-pages/
12
+ {% endcomment%}
13
+
14
+ {% assign rawtags = "" %}
15
+
16
+ {% assign collection= site.collections | where: "label", page.collection | first %}
17
+ {% assign items = collection.docs | sort: 'order' %}
18
+
19
+ {% for post in items %}
20
+ {% assign ttags = post.categories | join:'|' | append:'|' %}
21
+ {% assign rawtags = rawtags | append:ttags %}
22
+ {% endfor %}
23
+
24
+ {% assign rawtags = rawtags | split:'|' | sort %}
25
+
26
+ {% assign tags = "" %}
27
+
28
+ {% for tag in rawtags %}
29
+ {% if tag != "" %}
30
+
31
+ {% if tags == "" %}
32
+ {% assign tags = tag | split:'|' %}
33
+ {% endif %}
34
+
35
+ {% unless tags contains tag %}
36
+ {% assign tags = tags | join:'|' | append:'|' | append:tag | split:'|' %}
37
+ {% endunless %}
38
+ {% endif %}
39
+ {% endfor %}
40
+
41
+ <div>
42
+ <p>
43
+ {% for tag in tags %}
44
+ <a href="#{{ tag | slugify }}" class=""> {{ tag }} </a> &nbsp;&nbsp;
45
+ {% endfor %}
46
+ </p>
47
+
48
+ {% for tag in tags %}
49
+ <h3 id="{{ tag | slugify }}">{{ tag }}</h2>
50
+ {% for post in items %}
51
+ {% if post.categories contains tag %}
52
+ <ul class="actions">
53
+ <li>
54
+ <a class="button special" href="{{ post.url | absolute_url }}">
55
+ {{ post.title }}
56
+ </a>
57
+ {% for tag in post.categories %}
58
+ <a class="button" href="{{ page.url | absolute_url }}#{{ tag | slugify }}">{{ tag }}</a>
59
+ {% endfor %}
60
+ </li>
61
+ </ul>
62
+ {% endif %}
63
+ {% endfor %}
64
+ {% endfor %}
65
+
66
+ </div>
@@ -0,0 +1,31 @@
1
+ ---
2
+ layout: post
3
+ ---
4
+
5
+ {{ content }}
6
+
7
+ {% assign collection= site.collections | where: "label", page.collection | first %}
8
+ {% assign items = collection.docs | sort: 'order' %}
9
+
10
+ <div class="row">
11
+ {% for post in items %}
12
+ {% assign loopindex = forloop.index | modulo: 3 %}
13
+ {% if loopindex == 0 %}
14
+ <div class="4u$ 12u$(medium)">
15
+ {% else %}
16
+ <div class="4u 12u$(medium)">
17
+ {% endif %}
18
+ <a href="{{ post.url | relative_url }}">
19
+ <div class="box">
20
+ <h3>{{ post.title }}</h2>
21
+ {% if post.image %}
22
+ <span class="image fit">
23
+ <img src="{{ post.image | absolute_url }}" alt="" />
24
+ </span>
25
+ {% endif %}
26
+ <p>{{ post.excerpt | strip_html | truncatewords: 15 }}</p>
27
+ </div>
28
+ </a>
29
+ </div>
30
+ {% endfor %}
31
+ </div>
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fortyone-jekyll-theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Banchich
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2019-04-24 00:00:00.000000000 Z
12
+ date: 2019-09-12 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: jekyll
@@ -60,6 +60,8 @@ files:
60
60
  - _includes/pagination.html
61
61
  - _layouts/allposts.html
62
62
  - _layouts/alltags.html
63
+ - _layouts/categories.html
64
+ - _layouts/collection.html
63
65
  - _layouts/default.html
64
66
  - _layouts/home.html
65
67
  - _layouts/landing.html
@@ -138,5 +140,5 @@ rubyforge_project:
138
140
  rubygems_version: 2.6.8
139
141
  signing_key:
140
142
  specification_version: 4
141
- summary: A Fork from Jekyll version of the "Forty" theme by HTML5 UP.
143
+ summary: Jekyll theme of the "Forty" theme by HTML5 UP.
142
144
  test_files: []