jekyll-theme-systemhalted 0.1.1
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 +7 -0
- data/CHANGELOG.md +4 -0
- data/LICENSE.md +9 -0
- data/README.md +155 -0
- data/_data/taxonomy.yml +11 -0
- data/_includes/comments.html +14 -0
- data/_includes/footer.html +46 -0
- data/_includes/head.html +76 -0
- data/_includes/share-buttons.html +39 -0
- data/_includes/sidebar.html +32 -0
- data/_layouts/category.html +21 -0
- data/_layouts/collections.html +34 -0
- data/_layouts/default.html +68 -0
- data/_layouts/page.html +8 -0
- data/_layouts/post.html +108 -0
- data/assets/android-chrome-192x192.png +0 -0
- data/assets/android-chrome-512x512.png +0 -0
- data/assets/apple-touch-icon-precomposed.png +0 -0
- data/assets/apple-touch-icon.png +0 -0
- data/assets/css/nord.css +1759 -0
- data/assets/favicon-16x16.png +0 -0
- data/assets/favicon-32x32.png +0 -0
- data/assets/favicon.ico +0 -0
- data/assets/images/404.jpg +0 -0
- data/assets/images/bg-arrow.png +0 -0
- data/assets/images/bgimage1.jpg +0 -0
- data/assets/images/bgimage2.jpg +0 -0
- data/assets/images/example.png +0 -0
- data/assets/images/example1.png +0 -0
- data/assets/js/elasticlunr.min.js +10 -0
- data/assets/js/script.js +416 -0
- data/assets/js/search-data.js +26 -0
- data/assets/js/search.js +72 -0
- data/assets/site.webmanifest +1 -0
- data/lib/jekyll-theme-systemhalted/version.rb +5 -0
- data/lib/jekyll-theme-systemhalted.rb +3 -0
- metadata +167 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: ac7ded62652553410b0060512372e1684a01a9ab3f29a4ec11bd030dae6ec5b8
|
|
4
|
+
data.tar.gz: c10c055db1cf0141a51c03f71df949288a3c2318f5923d510719867bca3914ce
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: 7b2ed72ce0772f3a3d88f34d7538b405abd1f2560433a72f074cf6b5d61f0637e26bc287829ee5ad85fdeb1c7e5373180623a2928509aa9d3c5de0300c3564ed
|
|
7
|
+
data.tar.gz: 61e03be56d0ca29e36ad4ff1875c27e338eeab71abfc7bd63666bdfeeefac2ca94d152b380aed05f7cbc7d7adb09d07e8ed4a8f052a050cadb886900b3ccee2e
|
data/CHANGELOG.md
ADDED
data/LICENSE.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Released under MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2020 Palak Mathur.
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
6
|
+
|
|
7
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
8
|
+
|
|
9
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
# Systemhalted Theme
|
|
2
|
+
[](https://badge.fury.io/rb/jekyll-theme-systemhalted)
|
|
3
|
+
A Jekyll theme for personal blogs with a bold homepage grid, archive views, tags/categories, a search overlay, theme toggle, and optional Disqus comments.
|
|
4
|
+
|
|
5
|
+
## Features
|
|
6
|
+
- Responsive post grid with featured images.
|
|
7
|
+
- Search overlay powered by elasticlunr (no external services).
|
|
8
|
+
- Archives, categories, tags, and featured posts pages.
|
|
9
|
+
- Light/dark theme toggle.
|
|
10
|
+
- Optional Disqus comments and share buttons.
|
|
11
|
+
- Sidebar navigation driven by `_config.yml`.
|
|
12
|
+
|
|
13
|
+
## Requirements
|
|
14
|
+
- Ruby and Bundler installed locally.
|
|
15
|
+
- Jekyll (installed via Bundler).
|
|
16
|
+
|
|
17
|
+
## Using the theme gem
|
|
18
|
+
1) Add the theme to your site's `Gemfile`:
|
|
19
|
+
`gem "jekyll-theme-systemhalted"`
|
|
20
|
+
2) Update your site's `_config.yml`:
|
|
21
|
+
- `theme: jekyll-theme-systemhalted`
|
|
22
|
+
- Update `title`, `tagline`, `description`, `url`, `baseurl`, `sidebar.items`
|
|
23
|
+
- Plugins:
|
|
24
|
+
```yaml
|
|
25
|
+
plugins:
|
|
26
|
+
- jekyll-paginate
|
|
27
|
+
- jekyll-gist
|
|
28
|
+
- jekyll-seo-tag
|
|
29
|
+
- jekyll-sitemap
|
|
30
|
+
- jekyll-feed
|
|
31
|
+
```
|
|
32
|
+
3) Install and run:
|
|
33
|
+
`bundle install`
|
|
34
|
+
`bundle exec jekyll serve --livereload`
|
|
35
|
+
|
|
36
|
+
## Theme development / demo site
|
|
37
|
+
The demo site lives in `example/`. To preview the theme locally:
|
|
38
|
+
1) Install dependencies:
|
|
39
|
+
`bundle config set --local path vendor/bundle`
|
|
40
|
+
`bundle install`
|
|
41
|
+
2) Run the demo site:
|
|
42
|
+
`bundle exec jekyll serve --source example --destination example/_site --livereload`
|
|
43
|
+
|
|
44
|
+
Jekyll outputs to `_site/` in the source directory. Do not edit generated files directly.
|
|
45
|
+
|
|
46
|
+
## Tests
|
|
47
|
+
Run the test suite:
|
|
48
|
+
`bundle exec ruby -Itest -Ilib test/*_test.rb`
|
|
49
|
+
|
|
50
|
+
## Writing posts
|
|
51
|
+
In the demo site, posts live in `example/collections/_posts/` and use the filename format `YYYY-MM-DD-title.md`.
|
|
52
|
+
In your own site, follow your configured `collections_dir`.
|
|
53
|
+
|
|
54
|
+
Front matter example:
|
|
55
|
+
```
|
|
56
|
+
---
|
|
57
|
+
layout: post
|
|
58
|
+
title: Sample Post
|
|
59
|
+
date: 2025-12-31
|
|
60
|
+
categories: [Tech]
|
|
61
|
+
tags: [jekyll, notes]
|
|
62
|
+
comments: true
|
|
63
|
+
featured: true
|
|
64
|
+
featured_image: assets/images/2025-12-hero.jpg
|
|
65
|
+
featured_image_alt: Brief alt text for the image
|
|
66
|
+
featured_image_caption: Photo credit or context
|
|
67
|
+
description: One-line summary for previews.
|
|
68
|
+
---
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Drafts live in `example/collections/_drafts/` for the demo site. Preview drafts with:
|
|
72
|
+
`bundle exec jekyll serve --source example --destination example/_site --livereload --drafts`
|
|
73
|
+
|
|
74
|
+
## Pages
|
|
75
|
+
The demo site's pages live under `example/`. In your own site, create pages at your site root.
|
|
76
|
+
Use `layout: page` for standard content pages or `layout: default` if you want a fully custom layout.
|
|
77
|
+
|
|
78
|
+
Key pages included in the demo site (copy these into your own site if you want them):
|
|
79
|
+
- `index.html`: paginated home grid.
|
|
80
|
+
- `archives.html`: year-grouped archive with client-side sorting.
|
|
81
|
+
- `categories.html`: category taxonomy grouped by theme.
|
|
82
|
+
- `tags.html`: tag archive.
|
|
83
|
+
- `featured.html`: posts with `featured: true`.
|
|
84
|
+
- `about.md`, `404.md`: static pages.
|
|
85
|
+
|
|
86
|
+
## Collections
|
|
87
|
+
Collections live under `example/collections/` in the demo site (see `collections_dir` in `example/_config.yml`).
|
|
88
|
+
To add a collection:
|
|
89
|
+
1) Define it in your site's `_config.yml` under `collections:` with `output: true`.
|
|
90
|
+
2) Add docs in `collections/_<name>/` (relative to your `collections_dir`).
|
|
91
|
+
3) Create a listing page using `layout: collections` and `collection_name: <name>`.
|
|
92
|
+
|
|
93
|
+
Any collection with `output: true` is included in search (see Search below).
|
|
94
|
+
|
|
95
|
+
## Search
|
|
96
|
+
Search is fully client-side and uses elasticlunr.
|
|
97
|
+
- `assets/js/search-data.js` is generated at build time via Liquid.
|
|
98
|
+
- `assets/js/script.js` builds the elasticlunr index in the browser.
|
|
99
|
+
- Data includes posts and any output collections (excluding `/404.html`).
|
|
100
|
+
|
|
101
|
+
To exclude a document from search, add this to its front matter:
|
|
102
|
+
```
|
|
103
|
+
search_exclude: true
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
If you change which fields should be indexed or displayed, edit:
|
|
107
|
+
- `assets/js/search-data.js` (document fields and snippets)
|
|
108
|
+
- `assets/js/script.js` (elasticlunr fields and rendering)
|
|
109
|
+
|
|
110
|
+
## Sidebar navigation
|
|
111
|
+
Edit `sidebar.items` in your site's `_config.yml`:
|
|
112
|
+
```
|
|
113
|
+
sidebar:
|
|
114
|
+
items:
|
|
115
|
+
- title: "Home"
|
|
116
|
+
url: "/"
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
The sidebar also includes an "Annotate me" toggle that loads Hypothes.is on demand. Remove it from `_includes/sidebar.html` if you do not want annotation support.
|
|
120
|
+
|
|
121
|
+
## Categories and tags
|
|
122
|
+
Category themes are defined in `_data/taxonomy.yml` and used on `categories.html` and in related-post logic.
|
|
123
|
+
Tags are generated from post front matter and listed on `tags.html`.
|
|
124
|
+
|
|
125
|
+
## Comments and analytics
|
|
126
|
+
Disqus comments are supported:
|
|
127
|
+
- Set `disqus_shortname` in `_config.yml`.
|
|
128
|
+
- Enable per post with `comments: true`.
|
|
129
|
+
|
|
130
|
+
Google Analytics:
|
|
131
|
+
- Set `google_analytics_id` in `_config.yml` to enable `gtag.js`.
|
|
132
|
+
|
|
133
|
+
## Assets and styling
|
|
134
|
+
- Main CSS: `assets/css/nord.css`
|
|
135
|
+
- JS bundle: `assets/js/script.js`
|
|
136
|
+
- Search data: `assets/js/search-data.js`
|
|
137
|
+
- Fonts and icons are loaded in `_includes/head.html` (Google Fonts and Font Awesome CDN).
|
|
138
|
+
- Favicons live in `assets/`
|
|
139
|
+
|
|
140
|
+
## Deployment
|
|
141
|
+
Build the site:
|
|
142
|
+
`JEKYLL_ENV=production bundle exec jekyll build`
|
|
143
|
+
|
|
144
|
+
For the demo site:
|
|
145
|
+
`JEKYLL_ENV=production bundle exec jekyll build --source example --destination example/_site`
|
|
146
|
+
|
|
147
|
+
Then deploy the `_site/` folder to any static host.
|
|
148
|
+
|
|
149
|
+
If deploying to GitHub Pages:
|
|
150
|
+
- For `username.github.io`, set `url: https://username.github.io` and `baseurl: ""`.
|
|
151
|
+
- For `username.github.io/repo`, set `url: https://username.github.io` and `baseurl: "/repo"`.
|
|
152
|
+
|
|
153
|
+
## Notes
|
|
154
|
+
- Use relative URLs (`| relative_url`) for internal links and assets.
|
|
155
|
+
- Keep filenames kebab-case and asset names short.
|
data/_data/taxonomy.yml
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<div id="disqus_thread"></div>
|
|
2
|
+
<script>
|
|
3
|
+
var disqus_config = function () {
|
|
4
|
+
this.page.url = "{{ page.url | absolute_url }}";
|
|
5
|
+
this.page.identifier = "{{ page.id | default: page.url }}";
|
|
6
|
+
};
|
|
7
|
+
(function() {
|
|
8
|
+
var d = document, s = d.createElement('script');
|
|
9
|
+
s.src = 'https://{{ site.disqus_shortname }}.disqus.com/embed.js';
|
|
10
|
+
s.setAttribute('data-timestamp', +new Date());
|
|
11
|
+
(d.head || d.body).appendChild(s);
|
|
12
|
+
})();
|
|
13
|
+
</script>
|
|
14
|
+
<noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<footer class="site-footer">
|
|
2
|
+
<div class="container">
|
|
3
|
+
<div class="footer-inner">
|
|
4
|
+
<div class="footer-brand">
|
|
5
|
+
<div class="footer-avatar">
|
|
6
|
+
<img src="{{ '/assets/favicon.ico' | relative_url }}" alt="{{ site.title }} Logo">
|
|
7
|
+
</div>
|
|
8
|
+
<div>
|
|
9
|
+
<div class="footer-title">{{ site.title }}</div>
|
|
10
|
+
<div class="footer-subtitle">{{ site.tagline }}</div>
|
|
11
|
+
{% if site.description %}
|
|
12
|
+
<p class="footer-description">{{ site.description }}</p>
|
|
13
|
+
{% endif %}
|
|
14
|
+
</div>
|
|
15
|
+
</div>
|
|
16
|
+
|
|
17
|
+
<div class="footer-links">
|
|
18
|
+
<div class="footer-column">
|
|
19
|
+
<div class="footer-heading">Browse</div>
|
|
20
|
+
<a href="{{ '/' | relative_url }}">Home</a>
|
|
21
|
+
<a href="{{ '/featured/' | relative_url }}">Featured</a>
|
|
22
|
+
<a href="{{ '/archives/' | relative_url }}">Archives</a>
|
|
23
|
+
<a href="{{ '/categories/' | relative_url }}">Categories</a>
|
|
24
|
+
</div>
|
|
25
|
+
<div class="footer-column">
|
|
26
|
+
<div class="footer-heading">Connect</div>
|
|
27
|
+
<a href="mailto:{{ site.author.email | default: 'contact@example.com' }}">Email</a>
|
|
28
|
+
<a href="{{ '/feed.xml' | relative_url }}">RSS</a>
|
|
29
|
+
</div>
|
|
30
|
+
</div>
|
|
31
|
+
|
|
32
|
+
<div class="footer-subscribe">
|
|
33
|
+
<div class="footer-heading">Subscribe</div>
|
|
34
|
+
<p class="footer-description">Get new posts via RSS or drop me a note.</p>
|
|
35
|
+
<div class="footer-cta">
|
|
36
|
+
<a class="footer-button" href="{{ '/feed.xml' | relative_url }}">View RSS Feed</a>
|
|
37
|
+
<a class="footer-button ghost" href="mailto:{{ site.author.email | default: 'contact@example.com' }}">Say hello</a>
|
|
38
|
+
</div>
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
<div class="footer-meta">
|
|
42
|
+
<span>© {{ 'now' | date: '%Y' }} {{ site.author.name }}</span>
|
|
43
|
+
<span class="footer-meta-secondary">Created with love using <a href="https://github.com/systemhalted/systemhalted-theme">systemhalted-theme</a>.</span>
|
|
44
|
+
</div>
|
|
45
|
+
</div>
|
|
46
|
+
</footer>
|
data/_includes/head.html
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
<head>
|
|
2
|
+
<link href="http://gmpg.org/xfn/11" rel="profile">
|
|
3
|
+
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
|
4
|
+
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1">
|
|
6
|
+
|
|
7
|
+
<!-- Basic meta elements -->
|
|
8
|
+
<meta charset="utf-8" />
|
|
9
|
+
|
|
10
|
+
<!-- Enable responsiveness on mobile devices -->
|
|
11
|
+
<meta name="viewport" content="width=device-width,initial-scale=1.0,shrink-to-fit=no" />
|
|
12
|
+
|
|
13
|
+
{% if page.url and site.baseurl %}
|
|
14
|
+
<link rel="canonical" href="{{ page.url | absolute_url }}">
|
|
15
|
+
{% endif %}
|
|
16
|
+
|
|
17
|
+
<script>
|
|
18
|
+
(function() {
|
|
19
|
+
var storageKey = 'theme';
|
|
20
|
+
var lightClass = 'theme-nord-light';
|
|
21
|
+
var darkClass = 'theme-nord-dark';
|
|
22
|
+
var root = document.documentElement;
|
|
23
|
+
var saved = null;
|
|
24
|
+
|
|
25
|
+
function normalizeTheme(value) {
|
|
26
|
+
return value === 'dark' || value === 'light' ? value : null;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
try {
|
|
30
|
+
saved = normalizeTheme(localStorage.getItem(storageKey));
|
|
31
|
+
} catch (e) {
|
|
32
|
+
saved = null;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
if (!saved) {
|
|
36
|
+
try {
|
|
37
|
+
if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {
|
|
38
|
+
saved = 'dark';
|
|
39
|
+
} else {
|
|
40
|
+
saved = 'light';
|
|
41
|
+
}
|
|
42
|
+
} catch (e) {
|
|
43
|
+
saved = 'light';
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
root.classList.remove(lightClass, darkClass);
|
|
48
|
+
root.classList.add(saved === 'dark' ? darkClass : lightClass);
|
|
49
|
+
})();
|
|
50
|
+
</script>
|
|
51
|
+
|
|
52
|
+
<link rel="stylesheet" href="{{ '/assets/css/nord.css' | relative_url }}">
|
|
53
|
+
|
|
54
|
+
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Rubik:wght@400;500;600;700;800&family=Source+Code+Pro:wght@400;500;600&family=UnifrakturMaguntia&display=swap">
|
|
55
|
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
|
56
|
+
|
|
57
|
+
<link rel="apple-touch-icon-precomposed" sizes="144x144" href="{{ '/assets/apple-touch-icon-precomposed.png' | relative_url }}">
|
|
58
|
+
<link rel="icon" type="image/svg+xml" href="{{ '/assets/favicon.ico' | relative_url }}">
|
|
59
|
+
<link rel="shortcut icon" href="{{ '/assets/favicon.ico' | relative_url }}">
|
|
60
|
+
|
|
61
|
+
<link rel="alternate" type="application/rss+xml" href="{{ '/feed.xml' | relative_url }}">
|
|
62
|
+
|
|
63
|
+
{% if site.google_analytics_id %}
|
|
64
|
+
<!-- Global site tag (gtag.js) - Google Analytics -->
|
|
65
|
+
<script async src="https://www.googletagmanager.com/gtag/js?id={{ site.google_analytics_id }}"></script>
|
|
66
|
+
<script>
|
|
67
|
+
window.dataLayer = window.dataLayer || [];
|
|
68
|
+
function gtag(){dataLayer.push(arguments);}
|
|
69
|
+
gtag('js', new Date());
|
|
70
|
+
|
|
71
|
+
gtag('config', '{{ site.google_analytics_id }}');
|
|
72
|
+
</script>
|
|
73
|
+
{% endif %}
|
|
74
|
+
|
|
75
|
+
{% seo %}
|
|
76
|
+
</head>
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{% if include.pageurl != nil and include.pageurl != '' %}
|
|
2
|
+
{% assign pageurl = include.pageurl %}
|
|
3
|
+
{% else %}
|
|
4
|
+
{% assign pageurl = page.url %}
|
|
5
|
+
{% endif %}
|
|
6
|
+
|
|
7
|
+
<style>
|
|
8
|
+
#share-buttons {display: inline-block; vertical-align: middle; }
|
|
9
|
+
#share-buttons:after {content: ""; display: block; clear: both;}
|
|
10
|
+
#share-buttons > div {
|
|
11
|
+
position: relative;
|
|
12
|
+
text-align: left;
|
|
13
|
+
height: 36px;
|
|
14
|
+
width: 32px;
|
|
15
|
+
float: left;
|
|
16
|
+
text-align: center;
|
|
17
|
+
}
|
|
18
|
+
#share-buttons > div > svg {height: 16px; fill: #d5d5d5; margin-top: 10px;}
|
|
19
|
+
#share-buttons > div:hover {cursor: pointer;}
|
|
20
|
+
#share-buttons > div.facebook:hover > svg {fill: #3B5998;}
|
|
21
|
+
#share-buttons > div.twitter:hover > svg {fill: #55ACEE;}
|
|
22
|
+
#share-buttons > div.linkedin:hover > svg {fill: #0077b5;}
|
|
23
|
+
#share-buttons > div.pinterest:hover > svg {fill: #CB2027;}
|
|
24
|
+
#share-buttons > div.mail:hover > svg {fill: #7D7D7D;}
|
|
25
|
+
#share-buttons > div.instagram:hover > svg {fill: #C73B92;}
|
|
26
|
+
#share-buttons > div.facebook > svg {height: 18px; margin-top: 9px;}
|
|
27
|
+
#share-buttons > div.twitter > svg {height: 20px; margin-top: 8px;}
|
|
28
|
+
#share-buttons > div.linkedin > svg {height: 19px; margin-top: 7px;}
|
|
29
|
+
#share-buttons > div.pinterest > svg {height: 20px; margin-top: 9px;}
|
|
30
|
+
#share-buttons > div.mail > svg {height: 14px; margin-top: 11px;}
|
|
31
|
+
</style>
|
|
32
|
+
|
|
33
|
+
<span style="color: silver;">Share on: </span><div id="share-buttons">
|
|
34
|
+
<div class="facebook" title="Share this on Facebook" onclick="window.open('http://www.facebook.com/share.php?u={{ site.url }}{{ pageurl }}');"><svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1343 12v264h-157q-86 0-116 36t-30 108v189h293l-39 296h-254v759h-306v-759h-255v-296h255v-218q0-186 104-288.5t277-102.5q147 0 228 12z"/></svg></div>
|
|
35
|
+
<div class="twitter" title="Share this on Twitter" onclick="window.open('http://twitter.com/home?status={{ site.url }}{{ pageurl }}');"><svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1684 408q-67 98-162 167 1 14 1 42 0 130-38 259.5t-115.5 248.5-184.5 210.5-258 146-323 54.5q-271 0-496-145 35 4 78 4 225 0 401-138-105-2-188-64.5t-114-159.5q33 5 61 5 43 0 85-11-112-23-185.5-111.5t-73.5-205.5v-4q68 38 146 41-66-44-105-115t-39-154q0-88 44-163 121 149 294.5 238.5t371.5 99.5q-8-38-8-74 0-134 94.5-228.5t228.5-94.5q140 0 236 102 109-21 205-78-37 115-142 178 93-10 186-50z"/></svg></div>
|
|
36
|
+
<div class="linkedin" title="Share this on Linkedin" onclick="window.open('https://www.linkedin.com/shareArticle?mini=true&url={{ site.url }}{{ pageurl }}&title=&summary=&source=');"><svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M477 625v991h-330v-991h330zm21-306q1 73-50.5 122t-135.5 49h-2q-82 0-132-49t-50-122q0-74 51.5-122.5t134.5-48.5 133 48.5 51 122.5zm1166 729v568h-329v-530q0-105-40.5-164.5t-126.5-59.5q-63 0-105.5 34.5t-63.5 85.5q-11 30-11 81v553h-329q2-399 2-647t-1-296l-1-48h329v144h-2q20-32 41-56t56.5-52 87-43.5 114.5-15.5q171 0 275 113.5t104 332.5z"/></svg></div>
|
|
37
|
+
{% if page.image %}<div class="pinterest" title="Share this on Pinterest" onclick="window.open('https://pinterest.com/pin/create/button/?url=&media={{ site.url }}{{ page.image }}&description=');"><svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M256 597q0-108 37.5-203.5t103.5-166.5 152-123 185-78 202-26q158 0 294 66.5t221 193.5 85 287q0 96-19 188t-60 177-100 149.5-145 103-189 38.5q-68 0-135-32t-96-88q-10 39-28 112.5t-23.5 95-20.5 71-26 71-32 62.5-46 77.5-62 86.5l-14 5-9-10q-15-157-15-188 0-92 21.5-206.5t66.5-287.5 52-203q-32-65-32-169 0-83 52-156t132-73q61 0 95 40.5t34 102.5q0 66-44 191t-44 187q0 63 45 104.5t109 41.5q55 0 102-25t78.5-68 56-95 38-110.5 20-111 6.5-99.5q0-173-109.5-269.5t-285.5-96.5q-200 0-334 129.5t-134 328.5q0 44 12.5 85t27 65 27 45.5 12.5 30.5q0 28-15 73t-37 45q-2 0-17-3-51-15-90.5-56t-61-94.5-32.5-108-11-106.5z"/></svg></div>{% endif %}
|
|
38
|
+
<div class="mail" title="Share this through Email" onclick="window.open('mailto:?&body={{ site.url }}{{ pageurl }}');"><svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1792 710v794q0 66-47 113t-113 47h-1472q-66 0-113-47t-47-113v-794q44 49 101 87 362 246 497 345 57 42 92.5 65.5t94.5 48 110 24.5h2q51 0 110-24.5t94.5-48 92.5-65.5q170-123 498-345 57-39 100-87zm0-294q0 79-49 151t-122 123q-376 261-468 325-10 7-42.5 30.5t-54 38-52 32.5-57.5 27-50 9h-2q-23 0-50-9t-57.5-27-52-32.5-54-38-42.5-30.5q-91-64-262-182.5t-205-142.5q-62-42-117-115.5t-55-136.5q0-78 41.5-130t118.5-52h1472q65 0 112.5 47t47.5 113z"/></svg></div>
|
|
39
|
+
</div>
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
<!-- Target for toggling the sidebar `.sidebar-checkbox` is for regular
|
|
2
|
+
styles, `#sidebar-checkbox` for behavior. -->
|
|
3
|
+
<input type="checkbox" class="sidebar-checkbox" id="sidebar-checkbox">
|
|
4
|
+
|
|
5
|
+
<!-- Toggleable sidebar -->
|
|
6
|
+
<aside class="sidebar" id="sidebar">
|
|
7
|
+
<div class="sidebar-item">
|
|
8
|
+
<p>{{ site.description }}</p>
|
|
9
|
+
</div>
|
|
10
|
+
|
|
11
|
+
<nav class="sidebar-nav">
|
|
12
|
+
{% for item in site.sidebar.items %}
|
|
13
|
+
|
|
14
|
+
<a
|
|
15
|
+
class="sidebar-nav-item{% if page.url == item.url %} active{% endif %}"
|
|
16
|
+
href="{{ item.url | relative_url }}">
|
|
17
|
+
{{ item.title }}
|
|
18
|
+
</a>
|
|
19
|
+
{% endfor %}
|
|
20
|
+
|
|
21
|
+
<!-- Manually entered links stay as-is -->
|
|
22
|
+
<button class="sidebar-nav-item sidebar-nav-action" id="annotate-toggle" type="button">
|
|
23
|
+
Annotate me
|
|
24
|
+
</button>
|
|
25
|
+
</nav>
|
|
26
|
+
|
|
27
|
+
<div class="sidebar-item">
|
|
28
|
+
<p>
|
|
29
|
+
© {{ site.time | date: '%Y' }}. All rights reserved.
|
|
30
|
+
</p>
|
|
31
|
+
</div>
|
|
32
|
+
</aside>
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: page
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
<h1>{{ page.title }}</h1>
|
|
6
|
+
|
|
7
|
+
{% assign cat = page.category %}
|
|
8
|
+
{% assign posts = site.categories[cat] | sort: 'date' | reverse %}
|
|
9
|
+
|
|
10
|
+
{% if posts %}
|
|
11
|
+
<ul>
|
|
12
|
+
{% for post in posts %}
|
|
13
|
+
<li>
|
|
14
|
+
<span class="post-date">{{ post.date | date: "%Y-%m-%d" }}</span>
|
|
15
|
+
<a href="{{ post.url | relative_url }}">{{ post.title }}</a>
|
|
16
|
+
</li>
|
|
17
|
+
{% endfor %}
|
|
18
|
+
</ul>
|
|
19
|
+
{% else %}
|
|
20
|
+
<p>No posts yet in this category.</p>
|
|
21
|
+
{% endif %}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: default
|
|
3
|
+
---
|
|
4
|
+
<div class="page">
|
|
5
|
+
<h1>{{ page.title }}</h1>
|
|
6
|
+
|
|
7
|
+
{% assign coll_name = page.collection_name %}
|
|
8
|
+
{% assign docs = site[coll_name] | sort: "date" | reverse %}
|
|
9
|
+
{% assign show_dates = page.show_dates | default: false %}
|
|
10
|
+
|
|
11
|
+
{% if docs and docs.size > 0 %}
|
|
12
|
+
<ul class="collection-list">
|
|
13
|
+
{% for doc in docs %}
|
|
14
|
+
<li class="collection-item">
|
|
15
|
+
|
|
16
|
+
{% if show_dates and doc.date %}
|
|
17
|
+
<div class="collection-item-date">
|
|
18
|
+
{{ doc.date | date: "%B %d, %Y" }}
|
|
19
|
+
</div>
|
|
20
|
+
{% endif %}
|
|
21
|
+
|
|
22
|
+
<div class="collection-item-title">
|
|
23
|
+
<a href="{{ doc.url | relative_url }}">
|
|
24
|
+
{{ doc.title }}
|
|
25
|
+
</a>
|
|
26
|
+
</div>
|
|
27
|
+
|
|
28
|
+
</li>
|
|
29
|
+
{% endfor %}
|
|
30
|
+
</ul>
|
|
31
|
+
{% else %}
|
|
32
|
+
<p>No documents in this collection yet.</p>
|
|
33
|
+
{% endif %}
|
|
34
|
+
</div>
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en-us" class="theme-nord-light">
|
|
3
|
+
|
|
4
|
+
{% include head.html %}
|
|
5
|
+
|
|
6
|
+
<body>
|
|
7
|
+
<a class="skip-link" href="#main-content">Skip to content</a>
|
|
8
|
+
|
|
9
|
+
{% include sidebar.html %}
|
|
10
|
+
|
|
11
|
+
<!-- Wrap is the content to shift when toggling the sidebar. We wrap the
|
|
12
|
+
content to avoid any CSS collisions with our real content. -->
|
|
13
|
+
<div class="wrap">
|
|
14
|
+
<div class="masthead">
|
|
15
|
+
<div class="container">
|
|
16
|
+
<div class="masthead-inner">
|
|
17
|
+
<label for="sidebar-checkbox" class="sidebar-toggle" aria-label="Toggle sidebar" aria-controls="sidebar" aria-expanded="false" role="button" tabindex="0"></label>
|
|
18
|
+
<h3 class="masthead-title">
|
|
19
|
+
<a class="masthead-wordmark" href="{{ site.baseurl }}/" title="Home">{{ site.title }}</a>
|
|
20
|
+
{% if site.tagline %}
|
|
21
|
+
<span class="masthead-byline">{{ site.tagline }}</span>
|
|
22
|
+
{% endif %}
|
|
23
|
+
</h3>
|
|
24
|
+
<div class="masthead-actions">
|
|
25
|
+
<button id="theme-toggle" class="icon-button theme-toggle" type="button" aria-pressed="false" aria-label="Switch to dark mode" title="Switch to dark mode">
|
|
26
|
+
<i class="fa fa-paint-brush" aria-hidden="true"></i>
|
|
27
|
+
<span class="theme-toggle-label">Dark mode</span>
|
|
28
|
+
</button>
|
|
29
|
+
<button id="search-toggle" class="icon-button search-toggle" type="button" aria-expanded="false" aria-controls="search-overlay" aria-label="Open search" title="Search">
|
|
30
|
+
<i class="fa fa-search" aria-hidden="true"></i>
|
|
31
|
+
<span class="sr-only">Search</span>
|
|
32
|
+
</button>
|
|
33
|
+
</div>
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
|
|
38
|
+
<div id="search-overlay" class="search-overlay" aria-hidden="true">
|
|
39
|
+
<div class="search-dialog" role="dialog" aria-modal="true" aria-label="Search">
|
|
40
|
+
<div class="search-header">
|
|
41
|
+
<label class="sr-only" for="search-input">Search posts</label>
|
|
42
|
+
<input id="search-input" class="search-input" type="search" placeholder="Search posts and notes..." autocomplete="off">
|
|
43
|
+
<button id="search-close" class="icon-button search-close" type="button" aria-label="Close search">
|
|
44
|
+
<i class="fa fa-times" aria-hidden="true"></i>
|
|
45
|
+
</button>
|
|
46
|
+
</div>
|
|
47
|
+
<div id="search-status" class="search-status is-hidden" role="status" aria-live="polite"></div>
|
|
48
|
+
<div id="search-results" class="search-results">
|
|
49
|
+
<p class="search-empty">Type to search the archive.</p>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
|
|
54
|
+
<main id="main-content" class="container content" tabindex="-1">
|
|
55
|
+
{{ content }}
|
|
56
|
+
</main>
|
|
57
|
+
|
|
58
|
+
{% include footer.html %}
|
|
59
|
+
</div>
|
|
60
|
+
|
|
61
|
+
<script src="{{ '/assets/js/elasticlunr.min.js' | relative_url }}"></script>
|
|
62
|
+
<script src="{{ '/assets/js/search-data.js' | relative_url }}"></script>
|
|
63
|
+
<script src='{{ site.baseurl }}/assets/js/script.js'></script>
|
|
64
|
+
{% if site.disqus_shortname and page.layout == "post" and page.comments == true %}
|
|
65
|
+
<script id="dsq-count-scr" src="//{{ site.disqus_shortname }}.disqus.com/count.js" async></script>
|
|
66
|
+
{% endif %}
|
|
67
|
+
</body>
|
|
68
|
+
</html>
|
data/_layouts/page.html
ADDED
data/_layouts/post.html
ADDED
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: default
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
<div class="post">
|
|
6
|
+
<h1 class="post-title">{{ page.title }}</h1>
|
|
7
|
+
|
|
8
|
+
<span class="post-date">{{ page.date | date_to_string }}</span>
|
|
9
|
+
|
|
10
|
+
{% if page.featured_image %}
|
|
11
|
+
<figure class="post-featured">
|
|
12
|
+
<img src="{{ page.featured_image | relative_url }}" alt="{{ page.featured_image_alt | default: page.title }}">
|
|
13
|
+
{% if page.featured_image_caption %}
|
|
14
|
+
<figcaption>{{ page.featured_image_caption }}</figcaption>
|
|
15
|
+
{% endif %}
|
|
16
|
+
</figure>
|
|
17
|
+
{% endif %}
|
|
18
|
+
|
|
19
|
+
{% include share-buttons.html %}
|
|
20
|
+
<p>
|
|
21
|
+
{{ content }}
|
|
22
|
+
</div>
|
|
23
|
+
|
|
24
|
+
<div class="post-categories">
|
|
25
|
+
{% if post %}
|
|
26
|
+
{% assign categories = post.categories %}
|
|
27
|
+
{% else %}
|
|
28
|
+
{% assign categories = page.categories %}
|
|
29
|
+
{% endif %}
|
|
30
|
+
{% for category in categories %}
|
|
31
|
+
<a href="{{site.baseurl}}/categories/#{{category|slugize}}">{{category}}</a>
|
|
32
|
+
{% unless forloop.last %} {% endunless %}
|
|
33
|
+
{% endfor %}
|
|
34
|
+
</div>
|
|
35
|
+
|
|
36
|
+
{% if post %}
|
|
37
|
+
{% assign tags = post.tags %}
|
|
38
|
+
{% else %}
|
|
39
|
+
{% assign tags = page.tags %}
|
|
40
|
+
{% endif %}
|
|
41
|
+
{% if tags and tags != empty %}
|
|
42
|
+
<div class="post-tags">
|
|
43
|
+
{% for tag in tags %}
|
|
44
|
+
<a href="{{ site.baseurl }}/tags/#{{ tag | slugify }}">{{ tag }}</a>
|
|
45
|
+
{% unless forloop.last %} {% endunless %}
|
|
46
|
+
{% endfor %}
|
|
47
|
+
</div>
|
|
48
|
+
{% endif %}
|
|
49
|
+
|
|
50
|
+
{%- comment -%}
|
|
51
|
+
Build related posts by finding other posts in categories that share the same theme(s) as this page.
|
|
52
|
+
{%- endcomment -%}
|
|
53
|
+
{% assign themes = site.data.taxonomy.themes %}
|
|
54
|
+
{% assign page_categories = page.categories %}
|
|
55
|
+
{% if page_categories == nil or page_categories == empty %}
|
|
56
|
+
{% assign page_categories = post.categories %}
|
|
57
|
+
{% endif %}
|
|
58
|
+
{% if page_categories == nil %}
|
|
59
|
+
{% assign page_categories = "" | split: "" %}
|
|
60
|
+
{% endif %}
|
|
61
|
+
{% assign matched_theme_ids = "" | split: "," %}
|
|
62
|
+
|
|
63
|
+
{% for theme in themes %}
|
|
64
|
+
{% assign has_match = false %}
|
|
65
|
+
{% for cat in theme.categories %}
|
|
66
|
+
{% if page_categories contains cat %}
|
|
67
|
+
{% assign has_match = true %}
|
|
68
|
+
{% endif %}
|
|
69
|
+
{% endfor %}
|
|
70
|
+
{% if has_match %}
|
|
71
|
+
{% assign matched_theme_ids = matched_theme_ids | push: theme.id %}
|
|
72
|
+
{% endif %}
|
|
73
|
+
{% endfor %}
|
|
74
|
+
|
|
75
|
+
{% assign theme_posts = "" | split: "" %}
|
|
76
|
+
{% for theme in themes %}
|
|
77
|
+
{% if matched_theme_ids contains theme.id %}
|
|
78
|
+
{% for cat in theme.categories %}
|
|
79
|
+
{% assign cat_posts = site.categories[cat] %}
|
|
80
|
+
{% if cat_posts %}
|
|
81
|
+
{% assign theme_posts = theme_posts | concat: cat_posts %}
|
|
82
|
+
{% endif %}
|
|
83
|
+
{% endfor %}
|
|
84
|
+
{% endif %}
|
|
85
|
+
{% endfor %}
|
|
86
|
+
|
|
87
|
+
{% assign related_posts = theme_posts | uniq | sort: "date" | reverse %}
|
|
88
|
+
{% assign related_posts = related_posts | where_exp: "related_post", "related_post.url != page.url" %}
|
|
89
|
+
|
|
90
|
+
{% if related_posts.size >= 1 %}
|
|
91
|
+
<div class="related">
|
|
92
|
+
<h2>Related posts</h2>
|
|
93
|
+
<ul class="related-posts">
|
|
94
|
+
{% for post in related_posts limit:5 %}
|
|
95
|
+
<li>
|
|
96
|
+
<h3>
|
|
97
|
+
<a href="{{ site.baseurl }}{{ post.url }}">
|
|
98
|
+
{{ post.title }}
|
|
99
|
+
<small>{{ post.date | date_to_string }}</small>
|
|
100
|
+
</a>
|
|
101
|
+
</h3>
|
|
102
|
+
</li>
|
|
103
|
+
{% endfor %}
|
|
104
|
+
</ul>
|
|
105
|
+
</div>
|
|
106
|
+
{% if page.comments == true %}{% include comments.html %}{% endif %}
|
|
107
|
+
|
|
108
|
+
{% endif %}
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|