garth-jekyll-theme 0.1.6 → 0.1.7
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 +4 -4
- data/_includes/header.html +3 -1
- data/_includes/nav.html +14 -0
- data/_includes/scripts.js +14 -0
- data/_layouts/default.html +1 -0
- data/_sass/theme.scss +4 -9
- data/_sass/type.scss +14 -0
- data/_sass/variables.scss +4 -0
- metadata +5 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ef5e9f8ca40863e315aec4f67570a257293e815f
|
4
|
+
data.tar.gz: 5ae09930da05c4381596fa79bca73cc9d500aee9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 089a70b24fbce26d5b0a631aa7a63ce2519083da02b21d6b2bdbea9a851ee75e4d312f05ec6f8cacbc3beb46c26711cd8d4e325059d4f5a67ae4f8901767625d
|
7
|
+
data.tar.gz: 26953156b713e39985708500c2ad9fa0e1e3ac6b55fec996687d987da8b01674da424ec81b6b48cf1dc19b40886394ffb43be742c737b91eb99ed6b44285bbba
|
data/_includes/header.html
CHANGED
@@ -2,10 +2,12 @@
|
|
2
2
|
|
3
3
|
<a href="{{ page.url }}" title="{{ page.title }}">
|
4
4
|
|
5
|
-
<img class="avatar" src="{{ site.logo | replace: "300", "72" }}" alt="{{ site.title }}" srcset="{{ site.logo | replace: "300", "72" }} 72w, {{ site.logo | replace: "300", "144" }} 144w">
|
5
|
+
<img class="avatar" src="{{ site.logo | replace: "300", "72" }}" alt="{{ site.title }}" srcset="{{ site.logo | replace: "300", "72" }} 72w, {{ site.logo | replace: "300", "144" }} 144w" width="72" height="72">
|
6
6
|
|
7
7
|
</a>
|
8
8
|
|
9
|
+
{% include nav.html %}
|
10
|
+
|
9
11
|
<div class="container">
|
10
12
|
|
11
13
|
<h1>{{ page.title }}</h1>
|
data/_includes/nav.html
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
<nav class="nav">
|
2
|
+
<button class="button button--nav">Menu</button>
|
3
|
+
{% if data.nav %}
|
4
|
+
{% for item in data.nav %}
|
5
|
+
<a href="{{ item.url }}" title="{{ item.name }}">{{ item.name }}</a>
|
6
|
+
{% endfor %}
|
7
|
+
{% else %}
|
8
|
+
{% for page in site.pages %}
|
9
|
+
{% if page.title %}
|
10
|
+
<a href="{{ page.url }}" title="{{ page.title }}">{{ page.title }}</a>
|
11
|
+
{% endif %}
|
12
|
+
{% endfor %}
|
13
|
+
{% endif %}
|
14
|
+
</nav>
|
@@ -0,0 +1,14 @@
|
|
1
|
+
// Data attribute switch
|
2
|
+
var toggleState = function (elem, one, two) {
|
3
|
+
var elem = document.querySelector(elem);
|
4
|
+
elem.setAttribute('data-state', elem.getAttribute('data-state') === one ? two : one);
|
5
|
+
};
|
6
|
+
|
7
|
+
// Mobile navigation toggle selector
|
8
|
+
var buttonMenu = document.querySelector('.button--nav');
|
9
|
+
if (typeof(buttonMenu) != 'undefined' && buttonMenu != null) {
|
10
|
+
buttonMenu.onclick = function (e) {
|
11
|
+
toggleState('.nav', 'open', 'closed');
|
12
|
+
e.preventDefault();
|
13
|
+
};
|
14
|
+
};
|
data/_layouts/default.html
CHANGED
data/_sass/theme.scss
CHANGED
data/_sass/type.scss
ADDED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: garth-jekyll-theme
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Darnes
|
@@ -19,13 +19,17 @@ files:
|
|
19
19
|
- _includes/favicons.html
|
20
20
|
- _includes/footer.html
|
21
21
|
- _includes/header.html
|
22
|
+
- _includes/nav.html
|
22
23
|
- _includes/pagination.html
|
23
24
|
- _includes/posts.html
|
25
|
+
- _includes/scripts.js
|
24
26
|
- _layouts/default.html
|
25
27
|
- _layouts/front.html
|
26
28
|
- _layouts/page.html
|
27
29
|
- _layouts/post.html
|
28
30
|
- _sass/theme.scss
|
31
|
+
- _sass/type.scss
|
32
|
+
- _sass/variables.scss
|
29
33
|
homepage: https://github.com/daviddarnes/garth-jekyll-theme
|
30
34
|
licenses:
|
31
35
|
- MIT
|