jekyll-theme-hydeout 3.1.3 → 3.2.0

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
  SHA1:
3
- metadata.gz: 2a4d9c7cf8230e5848b3df9ae50eb03036b40a53
4
- data.tar.gz: ffd6cc0b9cfff69edb40441d679a1283459c0fbb
3
+ metadata.gz: 80f363e31b760d875a8419415d6794f3df1ffffe
4
+ data.tar.gz: 33b1b314bed14a4de9d4cd51f80ea153c635f412
5
5
  SHA512:
6
- metadata.gz: 815da07c1729fe7cb7afa77da7f5cc106db45f557741153f3317033e0df87ad9cdd0920776aacb3e20778b623a6c5f5bd0430b3d962f914a059f02c9d29c88ca
7
- data.tar.gz: ea2a0dc57874d761ed697c5f3afded93f13a0ebe3a96ba91647e7f045e9de83afc4e5414f9c73de1e2d8dab18564fca69e332eddbca674e9ab956dcc315e5031
6
+ metadata.gz: 53f7b35118c000b3395c2301d70d94a76248fdc64c2783c242f49c95c7df37e2bd73f1f19c6bc6d1b94818ba19323edf6df2484f9322679da67d34c23ed984b5
7
+ data.tar.gz: 78ccc98afddc7f62503fb1f3aeefa2834a5278bb139c2737b266b68ff8ddcaccc35b7c090c3af40be8f5861a591c276d53700deb2a0282003b09d246fa706564
data/README.md CHANGED
@@ -10,7 +10,7 @@ theme for [Jekyll](http://jekyllrb.com) 3.x and adds new functionality.
10
10
  ### Usage
11
11
 
12
12
  Hydeout is available as the `jekyll-theme-hydeout` Ruby Gem.
13
- Add `gem "jekyll-theme-hydeout", "~> 3.1"` to your Gemfile and run
13
+ Add `gem "jekyll-theme-hydeout", "~> 3.2"` to your Gemfile and run
14
14
  `bundle install`.
15
15
 
16
16
  Hydeout uses pagination, so if you have an `index.md`, you'll need to swap
@@ -62,10 +62,33 @@ $sidebar-sticky: false;
62
62
  See the [_variables](_sass/hydeout/_variables.scss) file for other variables
63
63
  you can override.
64
64
 
65
- You can also insert custom head tags (e.g. to load your own stylesheets) by
66
- defining your own `_includes/custom-head.html` or insert tags at the end
67
- of the body (e.g. for custom JS) by defining your own
68
- `_includes/custom-foot.html`.
65
+ You can see the full set of partials you can replace in the
66
+ [`_includes`](_includes) folder, but there are a few worth noting:
67
+
68
+ * `_includes/copyright.html` - Insert your own copyright here.
69
+
70
+ * `_includes/custom-head.html` - Insert custom head tags (e.g. to load your
71
+ own stylesheets)
72
+
73
+ * `_includes/custom-foot.html` - Insert custom elements at the end of the
74
+ body (e.g. for custom JS)
75
+
76
+ * `_includes/custom-nav-links.html` - Additional nav links to insert at the
77
+ end of the list of links in the sidebar.
78
+
79
+ Pro-tip: The `nav`s in the sidebar are flexboxes. Use the `order` property
80
+ to order your links.
81
+
82
+ * `_includes/custom-icon-links.html`- Additional icon links to insert at the
83
+ end of the icon links at the bottom of the sidebar. You can use the `order`
84
+ property to re-order.
85
+
86
+ * `_includes/favicons.html` - Replace references to `favicon.ico` and
87
+ `favicon.png` with your own favicons references.
88
+
89
+ * `_includes/font-includes.html` - The Abril Fatface font used for the site
90
+ title is loaded here. If you're overriding that font in the CSS, be sure
91
+ to also remove the font load reference here.
69
92
 
70
93
  ### New Features
71
94
 
@@ -0,0 +1,12 @@
1
+ {% comment %}
2
+ Dynamically generate list of links to all category pages
3
+ {% endcomment %}
4
+ {% assign pages_list = site.pages %}
5
+ {% for node in pages_list %}
6
+ {% if node.title != null %}
7
+ {% if node.layout == "category" %}
8
+ <a class="category-link {% if page.url == node.url %} active{% endif %}"
9
+ href="{{ site.baseurl }}{{ node.url }}">{{ node.title }}</a>
10
+ {% endif %}
11
+ {% endif %}
12
+ {% endfor %}
@@ -0,0 +1 @@
1
+ <!-- Optional additional links to insert for icons links -->
@@ -0,0 +1 @@
1
+ <!-- Optional additional links to insert in sidebar nav -->
@@ -0,0 +1,13 @@
1
+ {% comment %}
2
+ The code below dynamically generates a sidebar nav of pages with
3
+ `sidebar_link: true` in the front-matter. See readme for usage.
4
+ {% endcomment %}
5
+ {% assign pages_list = site.pages %}
6
+ {% for node in pages_list %}
7
+ {% if node.title != null %}
8
+ {% if node.sidebar_link %}
9
+ <a class="page-link {% if page.url == node.url %} active{% endif %}"
10
+ href="{{ site.baseurl }}{{ node.url }}">{{ node.title }}</a>
11
+ {% endif %}
12
+ {% endif %}
13
+ {% endfor %}
@@ -1,17 +1,20 @@
1
1
  <nav id="sidebar-icon-links">
2
2
  {% if site.github.repo %}
3
- <a class="icon" title="Github Project" aria-label="Github Project"
4
- href="{{ site.github.repo }}">
3
+ <a id="github-link"
4
+ class="icon" title="Github Project" aria-label="Github Project"
5
+ href="{{ site.github.repo }}">
5
6
  {% include svg/github.svg %}
6
7
  </a>
7
- <a class="icon" title="Download" aria-label="Download"
8
- href="{{ site.github.repo }}/archive/v{{ site.version }}.zip">
8
+ <a id="github-download-link"
9
+ class="icon" title="Download" aria-label="Download"
10
+ href="{{ site.github.repo }}/archive/v{{ site.version }}.zip">
9
11
  {% include svg/download.svg %}
10
12
  </a>
11
13
  {% endif %}
12
14
 
13
- <a class="icon" title="Subscribe" aria-label="Subscribe"
14
- href="{{ site.baseurl }}/feed.xml">
15
+ <a id="subscribe-link"
16
+ class="icon" title="Subscribe" aria-label="Subscribe"
17
+ href="{{ site.baseurl }}/feed.xml">
15
18
  {% include svg/feed.svg %}
16
19
  </a>
17
20
 
@@ -29,18 +32,22 @@
29
32
  {% endfor %}
30
33
 
31
34
  {% if tags_page %}
32
- <a class="icon{% if page.url == '/tags' %} active{% endif %}"
33
- title="Tags" aria-label="Tags"
34
- href="{{ site.baseurl }}{{ tags_page.url }}">
35
+ <a id="tags-link"
36
+ class="icon{% if page.url == '/tags' %} active{% endif %}"
37
+ title="Tags" aria-label="Tags"
38
+ href="{{ site.baseurl }}{{ tags_page.url }}">
35
39
  {% include svg/tags.svg %}
36
40
  </a>
37
41
  {% endif %}
38
42
 
39
43
  {% if search_page %}
40
- <a class="icon{% if page.url == '/search' %} active{% endif %}"
41
- title="Search" aria-label="Tags"
42
- href="{{ site.baseurl }}{{ search_page.url }}">
44
+ <a id="search-link"
45
+ class="icon{% if page.url == '/search' %} active{% endif %}"
46
+ title="Search" aria-label="Tags"
47
+ href="{{ site.baseurl }}{{ search_page.url }}">
43
48
  {% include svg/search.svg %}
44
49
  </a>
45
50
  {% endif %}
51
+
52
+ {% include custom-icon-links.html %}
46
53
  </nav>
@@ -0,0 +1,16 @@
1
+ <nav id="sidebar-nav-links">
2
+ {% if site.sidebar_home_link %}
3
+ <a class="home-link {% if page.url == '/' %} active{% endif %}"
4
+ href="{{ site.baseurl }}/">Home</a>
5
+ {% endif %}
6
+
7
+ {% comment %}
8
+ The code below dynamically generates a sidebar nav of pages with
9
+ `sidebar_link: true` in the front-matter. See readme for usage.
10
+ {% endcomment %}
11
+
12
+ {% include page-links.html %}
13
+ {% include category-links.html %}
14
+
15
+ {% include custom-nav-links.html %}
16
+ </nav>
@@ -1,16 +1,21 @@
1
1
  <div id="sidebar">
2
2
  <header>
3
- <{% if page.layout == "home" %}h1{% else %}div{% endif %} class="site-title">
3
+ <{% if page.layout == "index" %}h1{% else %}div{% endif %} class="site-title">
4
4
  <a href="{{ site.baseurl }}/">
5
5
  {% unless page.url == "/" %}
6
6
  <span class="back-arrow icon">{% include svg/back-arrow.svg %}</span>
7
7
  {% endunless %}
8
8
  {{ site.title }}
9
9
  </a>
10
- </{% if page.layout == "home" %}h1{% else %}div{% endif %}>
10
+ </{% if page.layout == "index" %}h1{% else %}div{% endif %}>
11
11
  <p class="lead">{{ site.description }}</p>
12
12
  </header>
13
- {% include sidebar-nav.html %}
13
+ {% include sidebar-nav-links.html %}
14
+
15
+ {% if site.version %}
16
+ <span class="site-version">Currently v{{ site.version }}</span>
17
+ {% endif %}
18
+
14
19
  {% include sidebar-icon-links.html %}
15
20
  {% include copyright.html %}
16
21
  </div>
@@ -3,6 +3,8 @@ layout: default
3
3
  ---
4
4
 
5
5
  <div class="content">
6
+ {{ content }}
7
+
6
8
  {% for post in paginator.posts %}
7
9
  <article class="post-body">
8
10
  <h2 class="post-title">
@@ -37,12 +37,7 @@ body {
37
37
 
38
38
  #sidebar {
39
39
  flex: 0 0 auto;
40
-
41
- // Use header + last-child to control vertical spacing so we can make
42
- // certain elements appear to be part of sidebar
43
- padding: 0 $section-spacing;
44
- header { margin-top: $section-spacing; }
45
- header ~ *:last-child { margin-bottom: $section-spacing; }
40
+ padding: $section-spacing;
46
41
 
47
42
  .site-title {
48
43
  font-family: "Abril Fatface", serif;
@@ -50,7 +45,7 @@ body {
50
45
  font-size: $large-font-size;
51
46
  color: rgba(255,255,255,.75);
52
47
  margin-top: 0;
53
- margin-bottom: 0;
48
+ margin-bottom: $heading-spacing;
54
49
 
55
50
  a {
56
51
  color: inherit;
@@ -86,7 +81,7 @@ body {
86
81
  // Hide secondary nav content in sidebar
87
82
  // Hide lead paragraph in sidebar
88
83
  #sidebar {
89
- header ~ *, p.lead {
84
+ header ~ *, header ~ nav, p.lead {
90
85
  display: none;
91
86
  }
92
87
  }
@@ -95,7 +90,7 @@ body {
95
90
  .container > header {
96
91
  background: transparent;
97
92
  color: white;
98
- margin: 0 $section-spacing $section-spacing;
93
+ margin: -$section-spacing $section-spacing $section-spacing;
99
94
 
100
95
  h1, h2 {
101
96
  color: white;
@@ -106,11 +101,6 @@ body {
106
101
  }
107
102
  }
108
103
 
109
- // Index pages need more padding on bottom
110
- .index #sidebar {
111
- margin-bottom: $section-spacing;
112
- }
113
-
114
104
 
115
105
  /* -----------------------------------------------------------
116
106
  Mobile view for home page)
@@ -132,6 +122,16 @@ body {
132
122
  header ~ *, p.lead {
133
123
  display: block;
134
124
  }
125
+
126
+ header ~ nav {
127
+ display: flex;
128
+ }
129
+
130
+ // Slightly more bottom padding to compensate for heading not match 100% of
131
+ // line-height on top
132
+ > *:last-child {
133
+ margin-bottom: 0.5rem;
134
+ }
135
135
  }
136
136
 
137
137
 
@@ -147,12 +147,17 @@ body {
147
147
  > * { max-height: 100vh; overflow: auto; }
148
148
  }
149
149
 
150
+ /* Undo mobile CSS */
151
+
150
152
  #sidebar, .home #sidebar {
151
153
  width: $sidebar-width;
152
154
  text-align: left;
155
+
156
+ > *:last-child {
157
+ margin-bottom: 0;
158
+ }
153
159
  }
154
160
 
155
- // Undo mobile CSS
156
161
  #sidebar {
157
162
  .site-title {
158
163
  font-size: 3.25rem;
@@ -165,6 +170,12 @@ body {
165
170
  p.lead, header ~ * {
166
171
  display: block;
167
172
  }
173
+
174
+ header ~ nav {
175
+ display: flex;
176
+ }
177
+
178
+
168
179
  }
169
180
 
170
181
  .index #sidebar { margin-bottom: 0; }
@@ -223,8 +234,24 @@ body {
223
234
  }
224
235
  }
225
236
 
226
- #sidebar-nav {
227
- margin-bottom: 1rem;
237
+ #sidebar nav {
238
+ display: flex;
239
+ }
240
+
241
+ #sidebar-nav-links {
242
+ flex-flow: column nowrap;
243
+ }
244
+
245
+ #sidebar-icon-links {
246
+ max-width: 100%;
247
+ flex-flow: row wrap;
248
+ justify-content: center;
249
+ margin-top: 1rem;
250
+
251
+ @media (min-width: $large-breakpoint) {
252
+ margin-left: -0.25em;
253
+ justify-content: flex-start;
254
+ }
228
255
  }
229
256
 
230
257
  #sidebar nav > * {
@@ -235,7 +262,7 @@ body {
235
262
  #sidebar nav > .icon {
236
263
  font-size: 1.5rem;
237
264
  display: inline-block;
238
- + a { margin-left: 0.5em; }
265
+ margin: 0 0.25em;
239
266
  }
240
267
 
241
268
 
@@ -37,7 +37,6 @@ $large-font-size: 1.25rem !default;
37
37
  $code-font-family: Menlo, Monaco, "Courier New", monospace !default;
38
38
  $code-color: #bf616a !default;
39
39
 
40
-
41
40
  // Hyde theming
42
41
  $sidebar-bg-color: #202020 !default;
43
42
  $sidebar-sticky: true !default;
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-theme-hydeout
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.3
4
+ version: 3.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Fong
@@ -89,22 +89,26 @@ extra_rdoc_files: []
89
89
  files:
90
90
  - LICENSE.md
91
91
  - README.md
92
+ - _includes/category-links.html
92
93
  - _includes/comments.html
93
94
  - _includes/copyright.html
94
95
  - _includes/custom-foot.html
95
96
  - _includes/custom-head.html
97
+ - _includes/custom-icon-links.html
98
+ - _includes/custom-nav-links.html
96
99
  - _includes/disqus.html
97
100
  - _includes/favicons.html
98
101
  - _includes/font-includes.html
99
102
  - _includes/google-analytics.html
100
103
  - _includes/head.html
104
+ - _includes/page-links.html
101
105
  - _includes/pagination.html
102
106
  - _includes/post-meta.html
103
107
  - _includes/post-tags.html
104
108
  - _includes/related_posts.html
105
109
  - _includes/search-form.html
106
110
  - _includes/sidebar-icon-links.html
107
- - _includes/sidebar-nav.html
111
+ - _includes/sidebar-nav-links.html
108
112
  - _includes/sidebar.html
109
113
  - _includes/svg/back-arrow.svg
110
114
  - _includes/svg/download.svg
@@ -1,34 +0,0 @@
1
- <nav id="sidebar-nav">
2
- <a class="{% if page.url == '/' %} active{% endif %}"
3
- href="{{ site.baseurl }}/">Home</a>
4
-
5
- {% comment %}
6
- The code below dynamically generates a sidebar nav of pages with
7
- `sidebar_link: true` in the front-matter. See readme for usage.
8
- {% endcomment %}
9
- {% assign pages_list = site.pages %}
10
- {% for node in pages_list %}
11
- {% if node.title != null %}
12
- {% if node.sidebar_link %}
13
- <a class="{% if page.url == node.url %} active{% endif %}"
14
- href="{{ site.baseurl }}{{ node.url }}">{{ node.title }}</a>
15
- {% endif %}
16
- {% endif %}
17
- {% endfor %}
18
-
19
- {% comment %}
20
- Now do it again, but for category pages
21
- {% endcomment %}
22
- {% for node in pages_list %}
23
- {% if node.title != null %}
24
- {% if node.layout == "category" %}
25
- <a class="{% if page.url == node.url %} active{% endif %}"
26
- href="{{ site.baseurl }}{{ node.url }}">{{ node.title }}</a>
27
- {% endif %}
28
- {% endif %}
29
- {% endfor %}
30
-
31
- {% if site.version %}
32
- <span>Currently v{{ site.version }}</span>
33
- {% endif %}
34
- </nav>