jekyll-theme-quartz 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 7f11567600b892222bf8da32810657e7eb331feeace92c165cb527eaa496978e
4
+ data.tar.gz: 329bd81125f3cb93ca89ac52dcea42c6bcacf75efd13a97034af0e540febdac0
5
+ SHA512:
6
+ metadata.gz: 277c784f09c68d2f0bccb12ddb0cbe16005bdbc18e52bf8733ad209fea29d611ab797e6127b0258eb80ce66cac9248ee837a82e62dbb18b325d20d1649aca765
7
+ data.tar.gz: b79680041c4966e6dfb2928e5da7eefec714d6be0af7d4e0c4fe924b12a8a4165bcdb532fe0c77dde2220c55ffe7c8364bc77be66a66bd8a091e79ddedf4a48a
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2022 vfvong
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,193 @@
1
+ # Quartz <!-- omit in toc -->
2
+
3
+ Quartz is a crystalline Jekyll theme for blog.
4
+
5
+ Check the [demo](http://vfvong.blog/jekyll-theme-quartz/).
6
+
7
+ ![screenshot](screenshot.png)
8
+
9
+ ## Highlight Features <!-- omit in toc -->
10
+
11
+ - Support the CSS resets [Normalize](https://github.com/necolas/normalize.css)
12
+ - Support [Font Awesome](https://fontawesome.com/)
13
+ - Support [MathJax](https://www.mathjax.org/)
14
+ - Support [Disqus](https://disqus.com/)
15
+ - Support [Google Analytics 4](https://analytics.google.com/analytics/web/)
16
+ - Light and dark mode, via [`prefers-color-scheme`](https://web.dev/prefers-color-scheme/)
17
+ - Archive pages implemented in pure [Liquid](https://shopify.github.io/liquid/)
18
+
19
+ ## Table of Contents <!-- omit in toc -->
20
+
21
+ - [Installation](#installation)
22
+ - [Usage](#usage)
23
+ - [Basic Configuration](#basic-configuration)
24
+ - [Specifying the Page Language](#specifying-the-page-language)
25
+ - [Customizing the Head](#customizing-the-head)
26
+ - [Navigation](#navigation)
27
+ - [Social Links](#social-links)
28
+ - [Archive Pages](#archive-pages)
29
+ - [MathJax](#mathjax)
30
+ - [Disqus](#disqus)
31
+ - [Google Analytics 4](#google-analytics-4)
32
+ - [More Customization](#more-customization)
33
+ - [Contributing](#contributing)
34
+ - [Development](#development)
35
+ - [License](#license)
36
+
37
+ ## Installation
38
+
39
+ Add this line to your Jekyll site's `Gemfile`:
40
+
41
+ ```ruby
42
+ gem "jekyll-theme-quartz"
43
+ ```
44
+
45
+ And add this line to your Jekyll site's `_config.yml`:
46
+
47
+ ```yaml
48
+ theme: jekyll-theme-quartz
49
+ ```
50
+
51
+ And then execute:
52
+
53
+ $ bundle
54
+
55
+ Or install it yourself as:
56
+
57
+ $ gem install jekyll-theme-quartz
58
+
59
+ If your website is hosted on GitHub Pages, you can install this theme via [`jekyll-remote-theme`](https://github.com/benbalter/jekyll-remote-theme).
60
+
61
+ Add the following to your `Gemfile`:
62
+
63
+ ```ruby
64
+ gem "jekyll-remote-theme"
65
+ ```
66
+
67
+ And add this line to your Jekyll site's `_config.yml`:
68
+
69
+ ```yml
70
+ plugins:
71
+ - jekyll-remote-theme
72
+ ```
73
+
74
+ Add the following to your site's `_config.yml`:
75
+
76
+ ```yml
77
+ remote_theme: vfvong/jekyll-theme-quartz
78
+ ```
79
+
80
+ ## Usage
81
+
82
+ ### Basic Configuration
83
+
84
+ You can refer to the [`_config.yml`](https://github.com/vfvong/jekyll-theme-quartz/blob/gh-pages/_config.yml) of the demo to set some basic configuration of your site.
85
+
86
+ ### Specifying the Page Language
87
+
88
+ You can specify the language on each page by setting the `lang` property. If the property is not set, the `site.lang` would be referred. If the `site.lang` is not set, the default value `en` would be applied.
89
+
90
+ ### Customizing the Head
91
+
92
+ If you want to put more data into the `<head>`, you don't need to copy the whole `_includes/head.html` file from this repo and overwrite it in your repo. You just need to create a `_includes/custom-head.html` file in your repo, and put some data into there. These data will be automatically imported into the `<head>`.
93
+
94
+ ### Navigation
95
+
96
+ The navigation in Quartz is very easy to configure, just specify the titles and URLs in the [`_data/navigation.yml`](https://github.com/vfvong/jekyll-theme-quartz/blob/gh-pages/_data/navigation.yml) file, for example,
97
+
98
+ ```yml
99
+ - title: Home
100
+ url: /
101
+ - title: About
102
+ url: /about.html
103
+ - title: Archive
104
+ url: /archive.html
105
+ ```
106
+
107
+ ### Social Links
108
+
109
+ The social links in Quartz is also very easy to connfigure. You don't need to import any large SVG file to render the icons because Quartz supports the [Font Awesome](https://fontawesome.com/). Specify the titles, URLs, and icons in the [`_data/social.yml`](https://github.com/vfvong/jekyll-theme-quartz/blob/gh-pages/_data/social.yml) file, for example,
110
+
111
+ ```yml
112
+ - title: Email
113
+ url: mailto:vfvong@gmail.com
114
+ icon: fas fa-envelope
115
+ - title: Twitter
116
+ url: https://twitter.com/vfvong
117
+ icon: fab fa-twitter
118
+ - title: GitHub
119
+ url: https://github.com/vfvong
120
+ icon: fab fa-github
121
+ ```
122
+
123
+ ### Archive Pages
124
+
125
+ Quartz provides a template `archive` to archive posts by years, categories, or tags.
126
+
127
+ If you want to show an archive page of years, just create a file and put these front matter in it:
128
+
129
+ ```yml
130
+ ---
131
+ layout: archive
132
+ type: years
133
+ title: Archive by Years
134
+ ---
135
+ ```
136
+
137
+ Similarly, if you want to show an archive page of categories, just create a file and put these front matter in it:
138
+
139
+ ```yml
140
+ ---
141
+ layout: archive
142
+ type: categories
143
+ title: Archive by Categories
144
+ ---
145
+ ```
146
+
147
+ Besides, if you want the categories and tags displayed in the post to link to the archive pages, you need to configure the paths to the category and tag archive pages in the `_config.yml` file, for example:
148
+
149
+ ```yml
150
+ categories_path: /categories/
151
+ tags_path: /tags/
152
+ ```
153
+
154
+ ### MathJax
155
+
156
+ Quartz relies on the [MathJax](https://www.mathjax.org/) to render math. The MathJax is disabled by default. You need to set `math: true` on the page where you want to enable the MathJax.
157
+
158
+ ### Disqus
159
+
160
+ To enable [Disqus](https://disqus.com/), just set the [Disqus shortname](https://help.disqus.com/en/articles/1717111-what-s-a-shortname) in the `_config.yml`, for example,
161
+
162
+ ```yml
163
+ disqus: <your disqus shortname>
164
+ ```
165
+
166
+ ### Google Analytics 4
167
+
168
+ Quartz support the [Google Analytics 4](https://support.google.com/analytics/answer/10089681). To enable it, just set the Measurement ID in the `_config.yml`, for example,
169
+
170
+ ```yml
171
+ google_analytics: G-XXXXXXXXXX
172
+ ```
173
+
174
+ ### More Customization
175
+
176
+ You can easily modify some styles of this theme, such as colors and fonts. You don't have to copy a lot of CSS into your repository, just copy [`_sass/quartz/_variables.scss`](_sass/quartz/_variables.scss) and change the variable value.
177
+
178
+ ## Contributing
179
+
180
+ Bug reports and pull requests are welcome on GitHub at [https://github.com/vfvong/jekyll-theme-quartz](https://github.com/vfvong/jekyll-theme-quartz). This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
181
+
182
+ ## Development
183
+
184
+ To set up your environment to develop this theme, run `bundle install`.
185
+
186
+ Your theme is setup just like a normal Jekyll site! To test your theme, run `bundle exec jekyll serve` and open your browser at `http://localhost:4000`. This starts a Jekyll server using your theme. Add pages, documents, data, etc. like normal to test your theme's contents. As you make modifications to your theme and to your content, your site will regenerate and you should see the changes in the browser after a refresh, just like normal.
187
+
188
+ When your theme is released, only the files in `_layouts`, `_includes`, `_sass` and `assets` tracked with Git will be bundled.
189
+ To add a custom directory to your theme-gem, please edit the regexp in `jekyll-theme-quartz.gemspec` accordingly.
190
+
191
+ ## License
192
+
193
+ The theme is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
@@ -0,0 +1,66 @@
1
+ {%- if page.type == 'categories' -%}
2
+ {%- assign taxonomies = site.categories -%}
3
+ {%- elsif page.type == 'tags' -%}
4
+ {%- assign taxonomies = site.tags -%}
5
+ {%- else -%}
6
+ {%- assign taxonomies = none -%}
7
+ {%- endif -%}
8
+
9
+ {%- assign max_count = 0 -%}
10
+ {%- for taxonomy in taxonomies -%}
11
+ {%- assign posts = taxonomy[1] -%}
12
+ {%- if posts.size > max_count -%}
13
+ {%- assign max_count = posts.size -%}
14
+ {%- endif -%}
15
+ {%- endfor -%}
16
+
17
+ <ul class="taxonomies">
18
+ {%- for i in (1..max_count) reversed -%}
19
+ {%- for taxonomy in taxonomies -%}
20
+ {%- assign taxonomy_name = taxonomy[0] -%}
21
+ {%- assign slugified_taxonomy_name = taxonomy_name | slugify -%}
22
+ {%- assign posts = taxonomy[1] -%}
23
+ {%- if posts.size == i -%}
24
+ <li>
25
+ {%- capture link -%}{{ page.permalink }}#{{ slugified_taxonomy_name }}{%- endcapture -%}
26
+ <a class="taxonomy" href="{{ link | relative_url }}">
27
+ <span>
28
+ {%- if page.type == 'tags' -%}
29
+ {{ slugified_taxonomy_name }}
30
+ {%- else -%}
31
+ {{ taxonomy_name }}
32
+ {%- endif -%}
33
+ </span>
34
+ <span>{{ posts.size }}</span>
35
+ </a>
36
+ </li>
37
+ {%- endif -%}
38
+ {%- endfor -%}
39
+ {%- endfor -%}
40
+ </ul>
41
+
42
+ {%- for i in (1..max_count) reversed -%}
43
+ {%- for taxonomy in taxonomies -%}
44
+ {%- assign taxonomy_name = taxonomy[0] -%}
45
+ {%- assign slugified_taxonomy_name = taxonomy_name | slugify -%}
46
+ {%- assign posts = taxonomy[1] -%}
47
+ {%- if posts.size == i -%}
48
+ <h2 id="{{ slugified_taxonomy_name }}">
49
+ {%- if page.type == 'tags' -%}
50
+ {{ slugified_taxonomy_name }}
51
+ {%- else -%}
52
+ {{ taxonomy_name }}
53
+ {%- endif -%}
54
+ </h2>
55
+ <ul>
56
+ {%- for post in posts -%}
57
+ <li>
58
+ <time class="archive-date" datetime="{{ page.date | date_to_xmlschema }}">{{ post.date | date: "%Y-%m-%d" }}</time>
59
+ &raquo;
60
+ <a href="{{ post.url | relative_url }}">{{ post.title | escape }}</a>
61
+ </li>
62
+ {%- endfor -%}
63
+ </ul>
64
+ {%- endif -%}
65
+ {%- endfor -%}
66
+ {%- endfor -%}
@@ -0,0 +1,27 @@
1
+ {% assign taxonomies = site.posts | group_by_exp: "post", "post.date | date: '%Y'" %}
2
+
3
+ <ul class="taxonomies">
4
+ {%- for taxonomy in taxonomies -%}
5
+ <li>
6
+ {%- capture link -%}{{ page.permalink }}#{{ taxonomy.name }}{%- endcapture -%}
7
+ <a class="taxonomy" href="{{ link | relative_url }}">
8
+ <span>{{ taxonomy.name }}</span>
9
+ <span>{{ taxonomy.size }}</span>
10
+ </a>
11
+ </li>
12
+ {%- endfor -%}
13
+ </ul>
14
+
15
+ {%- for taxonomy in taxonomies -%}
16
+ <h2 id="{{ taxonomy.name }}">{{ taxonomy.name }}</h2>
17
+ <ul>
18
+ {%- assign posts = taxonomy.items -%}
19
+ {%- for post in posts -%}
20
+ <li>
21
+ <time class="archive-date" datetime="{{ page.date | date_to_xmlschema }}">{{ post.date | date: "%Y-%m-%d" }}</time>
22
+ &raquo;
23
+ <a href="{{ post.url | relative_url }}">{{ post.title | escape }}</a>
24
+ </li>
25
+ {%- endfor -%}
26
+ </ul>
27
+ {%- endfor -%}
@@ -0,0 +1,3 @@
1
+ {% comment %}
2
+ A placeholder for customizing head.
3
+ {% endcomment %}
@@ -0,0 +1,17 @@
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.url | absolute_url }}';
6
+ };
7
+
8
+ (function() {
9
+ var d = document, s = d.createElement('script');
10
+
11
+ s.src = 'https://{{ site.disqus }}.disqus.com/embed.js';
12
+
13
+ s.setAttribute('data-timestamp', +new Date());
14
+ (d.head || d.body).appendChild(s);
15
+ })();
16
+ </script>
17
+ <noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript" rel="nofollow">comments powered by Disqus.</a></noscript>
@@ -0,0 +1,32 @@
1
+ <footer class="footer outer">
2
+ <div class="inner">
3
+ <div class="columns">
4
+ <p class="column">
5
+ &copy; <time datetime="{{ site.time | date_to_xmlschema }}">{{ site.time | date: '%Y' }}</time>
6
+ {%- if site.author -%}
7
+ &nbsp;<a href="{{ site.author.url }}" target="_blank">{{ site.author.name }}</a>
8
+ {%- endif -%}. All rights reserved.
9
+ </p>
10
+
11
+ <p class="column">
12
+ Powered by <a href="https://jekyllrb.com/" target="_blank">Jekyll</a> & <a href="https://github.com/vfvong/jekyll-theme-quartz" target="_blank">Quartz</a>
13
+ </p>
14
+
15
+ {% if site.description %}
16
+ <p class="column">
17
+ {{ site.description }}
18
+ </p>
19
+ {% endif %}
20
+
21
+ {% if site.data.social %}
22
+ <div class="column social">
23
+ {% for social in site.data.social %}
24
+ <a href="{{ social.url }}" target="_blank">
25
+ <i class="{{ social.icon | default: 'fas fa-link' }}" title="{{ social.title }}"></i>
26
+ </a>
27
+ {% endfor %}
28
+ </div>
29
+ {% endif %}
30
+ </div>
31
+ </div>
32
+ </footer>
@@ -0,0 +1,9 @@
1
+ <!-- Global site tag (gtag.js) - Google Analytics -->
2
+ <script async src="https://www.googletagmanager.com/gtag/js?id={{ site.google_analytics }}"></script>
3
+ <script>
4
+ window.dataLayer = window.dataLayer || [];
5
+ function gtag(){dataLayer.push(arguments);}
6
+ gtag('js', new Date());
7
+
8
+ gtag('config', '{{ site.google_analytics }}');
9
+ </script>
@@ -0,0 +1,12 @@
1
+ <head>
2
+ <meta charset="UTF-8">
3
+ <meta name="viewport" content="width=device-width, initial-scale=1">
4
+
5
+ <link rel="stylesheet" href="{{ 'assets/css/normalize.css' | relative_url }}"/>
6
+ <link rel="stylesheet" href="{{ 'assets/css/open-color.css' | relative_url }}"/>
7
+ <link rel="stylesheet" href="{{ 'assets/css/quartz.css' | relative_url }}"/>
8
+
9
+ <script async src="https://use.fontawesome.com/releases/v6.0.0/js/all.js"></script>
10
+
11
+ {% include custom-head.html %}
12
+ </head>
@@ -0,0 +1,18 @@
1
+ <header class="site-header outer">
2
+ <div class="inner">
3
+ <div class="site-header-small-content">
4
+ <h4 class="site-title">
5
+ <a href="{{ '/' | relative_url }}">{{ site.title }}</a>
6
+ </h4>
7
+ {% if site.data.navigation %}
8
+ <nav class="nav">
9
+ {% for item in site.data.navigation %}
10
+ <a class="nav-item {% if page.url == item.url %}active{% endif %}" href="{{ item.url | relative_url }}">
11
+ {{ item.title }}
12
+ </a>
13
+ {% endfor %}
14
+ </nav>
15
+ {% endif %}
16
+ </div>
17
+ </div>
18
+ </header>
@@ -0,0 +1,29 @@
1
+ {% assign cover = site.cover %}
2
+ {% if page.cover %}
3
+ {% assign cover = page.cover %}
4
+ {% endif %}
5
+ <header class="site-header large-header"{% if cover %} style="background-image: url({{ cover | relative_url }})"{% endif %}>
6
+ <div class="site-header-shield">
7
+ <div class="outer">
8
+ <div class="inner">
9
+ <div class="site-header-content">
10
+ <h2 class="site-title">
11
+ <a href="{{ '/' | relative_url }}">{{ site.title }}</a>
12
+ </h2>
13
+ {% if site.tagline %}
14
+ <h5 class="site-tagline">{{ site.tagline }}</h5>
15
+ {% endif %}
16
+ </div>
17
+ {% if site.data.navigation %}
18
+ <nav class="nav">
19
+ {% for item in site.data.navigation %}
20
+ <a class="nav-item {% if page.url == item.url %}active{% endif %}" href="{{ item.url | relative_url }}">
21
+ {{ item.title }}
22
+ </a>
23
+ {% endfor %}
24
+ </nav>
25
+ {% endif %}
26
+ </div>
27
+ </div>
28
+ </div>
29
+ </header>
@@ -0,0 +1,2 @@
1
+ <script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
2
+ <script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
@@ -0,0 +1,44 @@
1
+ {% assign posts = site.posts %}
2
+ {% if paginator %}
3
+ {% assign posts = paginator.posts %}
4
+ {% endif %}
5
+ {% for post in posts %}
6
+ <article class="post-card">
7
+ {% if post.cover %}
8
+ <a class="post-card-image-link" href="{{ post.url | relative_url }}">
9
+ <div class="post-card-image" style="background-image: url({{ post.cover | relative_url }})"></div>
10
+ </a>
11
+ {% endif %}
12
+ <div class="post-card-content {% unless post.cover %}no-cover{% endunless %}">
13
+ <a class="post-card-content-link" href="{{ post.url | relative_url }}">
14
+ <header class="post-card-header">
15
+ {% if post.categories.size > 0 %}
16
+ {% for category in post.categories %}
17
+ {% if forloop.index == post.categories.size %}
18
+ <span class="post-card-categories">{{ category }}</span>
19
+ {% else %}
20
+ <span class="post-card-categories">{{ category }} / </span>
21
+ {% endif %}
22
+ {% endfor %}
23
+ {% endif %}
24
+
25
+ <h2 class="post-card-title">{{ post.title }}</h2>
26
+ </header>
27
+ <section class="post-card-excerpt">
28
+ {% if post.description %}
29
+ <p>{{ post.description | truncate: 128 }}</p>
30
+ {% elsif post.excerpt %}
31
+ <p>{{ post.excerpt | strip_html | truncate: 128 }}</p>
32
+ {% else %}
33
+ <p>{{ post.content | strip_html | truncate: 128 }}</p>
34
+ {% endif %}
35
+ </section>
36
+ </a>
37
+ <footer class="post-card-meta">
38
+ <time datetime="{{ post.date | date_to_xmlschema }}">
39
+ <i class="fa-solid fa-calendar-days"></i> {{ post.date | date_to_string }}
40
+ </time>
41
+ </footer>
42
+ </div>
43
+ </article>
44
+ {% endfor %}
@@ -0,0 +1,11 @@
1
+ ---
2
+ layout: page
3
+ ---
4
+
5
+ {{ content }}
6
+
7
+ {% if page.type == "years" %}
8
+ {% include archive-by-years.html %}
9
+ {% else %}
10
+ {% include archive-by-tagories.html %}
11
+ {% endif %}
@@ -0,0 +1,32 @@
1
+ <!DOCTYPE html>
2
+ <html lang="{{ page.lang | default: site.lang | default: 'en' }}">
3
+
4
+ {% include head.html %}
5
+
6
+ <body>
7
+ <div class="wrapper">
8
+
9
+ {% if page.layout == "default" or page.layout == "home" %}
10
+ {% include header.html %}
11
+ {% else %}
12
+ {% include header-small.html %}
13
+ {% endif %}
14
+
15
+ <main class="main outer">
16
+ <div class="inner">
17
+ {{ content }}
18
+ </div>
19
+ </main>
20
+
21
+ {% include footer.html %}
22
+ </div>
23
+
24
+ {% if page.math %}
25
+ {% include mathjax.html %}
26
+ {% endif %}
27
+
28
+ {% if jekyll.environment == 'production' and site.google_analytics %}
29
+ {% include google-analytics.html %}
30
+ {% endif %}
31
+ </body>
32
+ </html>
@@ -0,0 +1,22 @@
1
+ ---
2
+ layout: default
3
+ ---
4
+
5
+ <div class="post-feed">
6
+ {% include post-cards.html %}
7
+ </div>
8
+
9
+ {% if paginator %}
10
+ <div class="pagination">
11
+ {% if paginator.previous_page %}
12
+ <a class="prev home-prev" href="{{ paginator.previous_page_path | relative_url }}"><i class="fas fa-chevron-left"></i></a>
13
+ {% else %}
14
+ <span class="prev home-prev unable"><i class="fas fa-chevron-left"></i></span>
15
+ {% endif %}
16
+ {% if paginator.next_page %}
17
+ <a class="next home-next" href="{{ paginator.next_page_path | relative_url }}"><i class="fas fa-chevron-right"></i></a>
18
+ {% else %}
19
+ <span class="next home-next unable"><i class="fas fa-chevron-right"></i></span>
20
+ {% endif %}
21
+ </div>
22
+ {% endif %}
@@ -0,0 +1,10 @@
1
+ ---
2
+ layout: default
3
+ ---
4
+
5
+ <article class="page">
6
+ <h1 class="page-title">{{ page.title }}</h1>
7
+ <div class="page-content">
8
+ {{ content }}
9
+ </div>
10
+ </article>
@@ -0,0 +1,89 @@
1
+ ---
2
+ layout: default
3
+ ---
4
+
5
+ <article class="post">
6
+ <div class="post-meta post-meta-top">
7
+ <div>
8
+ <time datetime="{{ page.date | date_to_xmlschema }}">
9
+ <i class="fa-solid fa-calendar-days"></i> {{ page.date | date_to_string }}
10
+ </time>
11
+ {%- if page.last_modified_at -%}
12
+ ~
13
+ {%- assign mdate = page.last_modified_at | date_to_xmlschema -%}
14
+ <time datetime="{{ mdate }}" itemprop="dateModified">
15
+ {{ mdate | date_to_string }}
16
+ </time>
17
+ {%- endif -%}
18
+ {%- if page.author -%}
19
+ <i class="fa-solid fa-at"></i>
20
+ {% for author in page.author %}
21
+ <span itemprop="author" itemscope itemtype="http://schema.org/Person">{{ author }}</span>
22
+ {%- if forloop.last == false %}, {% endif -%}
23
+ {% endfor %}
24
+ {%- endif -%}
25
+ </div>
26
+
27
+ {% if page.categories.size > 0 %}
28
+ <nav class="post-categories">
29
+ <i class="fa-solid fa-folder"></i>
30
+ {% for category in page.categories %}
31
+ {% if site.categories_path %}
32
+ <a class="post-category" href="{{ site.categories_path | relative_url }}#{{ category | slugify }}">{{ category }}</a> /
33
+ {% else %}
34
+ <span>{{ category }}</span> /
35
+ {% endif %}
36
+ {% endfor %}
37
+ </nav>
38
+ {% endif %}
39
+ </div>
40
+
41
+ <h1 class="post-title">{{ page.title }}</h1>
42
+
43
+ {% if page.cover %}
44
+ <figure class="post-cover" style="background-image: url({{ page.cover | relative_url }})">
45
+ </figure>
46
+ {% endif %}
47
+
48
+ <div class="post-content">
49
+ {{ content }}
50
+ </div>
51
+
52
+ {% if page.tags.size > 0 %}
53
+ <nav class="post-meta post-meta-bottom">
54
+ <i class="fa-solid fa-tag"></i>
55
+ {% for tag in page.tags %}
56
+ {% assign slugified_tag = tag | slugify %}
57
+ {% if site.tags_path %}
58
+ <a class="post-tag" href="{{ site.tags_path | relative_url }}#{{ slugified_tag }}">#{{ slugified_tag }}</a>
59
+ {% else %}
60
+ <span>#{{ slugified_tag }}</span>
61
+ {% endif %}
62
+ {% endfor %}
63
+ </nav>
64
+ {% endif %}
65
+ </article>
66
+
67
+ <aside class="pagination post-pagination">
68
+ {% if page.previous %}
69
+ <a class="prev post-prev" href="{{ page.previous.url | relative_url }}">
70
+ <i class="fas fa-chevron-left"></i> <span class="">{{ page.previous.title | markdownify | strip_html }}</span>
71
+ </a>
72
+ {% else %}
73
+ <span class="prev post-prev unable"><i class="fas fa-chevron-left"></i></span>
74
+ {% endif %}
75
+
76
+ {% if page.next %}
77
+ <a class="next post-next" href="{{ page.next.url | relative_url }}">
78
+ <span class="">{{ page.next.title | markdownify | strip_html }}</span> <i class="fas fa-chevron-right"></i>
79
+ </a>
80
+ {% else %}
81
+ <span class="next post-next unable"><i class="fas fa-chevron-right"></i></span>
82
+ {% endif %}
83
+ </aside>
84
+
85
+ {% if jekyll.environment == "production" and site.disqus and page.comments != false %}
86
+ <aside class="post-comments">
87
+ {% include disqus.html %}
88
+ </aside>
89
+ {% endif %}