@terrymooreii/sia 2.1.3 → 2.1.4
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.
- package/lib/assets.js +17 -20
- package/lib/build.js +2 -2
- package/lib/config.js +1 -1
- package/lib/content.js +6 -6
- package/lib/templates.js +10 -5
- package/package.json +1 -1
- package/themes/_shared/includes/meta.njk +41 -0
- package/themes/_shared/includes/theme-script.njk +8 -0
- package/themes/developer/includes/footer.njk +5 -0
- package/themes/developer/includes/header.njk +46 -0
- package/themes/developer/includes/pagination.njk +39 -0
- package/themes/developer/includes/sidebar.njk +60 -0
- package/themes/developer/includes/tag-list.njk +7 -0
- package/themes/developer/layouts/base.njk +29 -0
- package/themes/developer/layouts/note.njk +21 -0
- package/themes/developer/layouts/page.njk +13 -0
- package/themes/developer/layouts/post.njk +47 -0
- package/themes/developer/pages/blog.njk +41 -0
- package/themes/developer/pages/feed.njk +22 -0
- package/themes/developer/pages/index.njk +65 -0
- package/themes/developer/pages/notes.njk +38 -0
- package/themes/developer/pages/tag.njk +39 -0
- package/themes/developer/pages/tags.njk +21 -0
- package/themes/developer/styles/main.css +874 -0
- package/themes/magazine/includes/footer.njk +32 -0
- package/themes/magazine/includes/header.njk +63 -0
- package/themes/magazine/includes/pagination.njk +29 -0
- package/themes/magazine/includes/tag-list.njk +7 -0
- package/themes/magazine/layouts/base.njk +23 -0
- package/themes/magazine/layouts/note.njk +25 -0
- package/themes/magazine/layouts/page.njk +13 -0
- package/themes/magazine/layouts/post.njk +79 -0
- package/themes/magazine/pages/blog.njk +35 -0
- package/themes/magazine/pages/feed.njk +22 -0
- package/themes/magazine/pages/index.njk +79 -0
- package/themes/magazine/pages/notes.njk +33 -0
- package/themes/magazine/pages/tag.njk +31 -0
- package/themes/magazine/pages/tags.njk +19 -0
- package/themes/magazine/styles/main.css +1169 -0
- package/themes/main/layouts/base.njk +21 -0
- package/themes/minimal/includes/footer.njk +14 -0
- package/themes/minimal/includes/header.njk +71 -0
- package/themes/minimal/includes/pagination.njk +26 -0
- package/themes/minimal/includes/tag-list.njk +11 -0
- package/themes/minimal/layouts/base.njk +21 -0
- package/themes/minimal/layouts/note.njk +25 -0
- package/themes/minimal/layouts/page.njk +14 -0
- package/themes/minimal/layouts/post.njk +46 -0
- package/themes/minimal/pages/blog.njk +37 -0
- package/themes/minimal/pages/feed.njk +28 -0
- package/themes/minimal/pages/index.njk +61 -0
- package/themes/minimal/pages/notes.njk +34 -0
- package/themes/minimal/pages/tag.njk +42 -0
- package/themes/minimal/pages/tags.njk +39 -0
- package/defaults/layouts/base.njk +0 -41
- /package/{defaults → themes/main}/includes/footer.njk +0 -0
- /package/{defaults → themes/main}/includes/header.njk +0 -0
- /package/{defaults → themes/main}/includes/pagination.njk +0 -0
- /package/{defaults → themes/main}/includes/tag-list.njk +0 -0
- /package/{defaults → themes/main}/layouts/note.njk +0 -0
- /package/{defaults → themes/main}/layouts/page.njk +0 -0
- /package/{defaults → themes/main}/layouts/post.njk +0 -0
- /package/{defaults → themes/main}/pages/blog.njk +0 -0
- /package/{defaults → themes/main}/pages/feed.njk +0 -0
- /package/{defaults → themes/main}/pages/index.njk +0 -0
- /package/{defaults → themes/main}/pages/notes.njk +0 -0
- /package/{defaults → themes/main}/pages/tag.njk +0 -0
- /package/{defaults → themes/main}/pages/tags.njk +0 -0
- /package/{defaults → themes/main}/styles/main.css +0 -0
- /package/{defaults/styles/minimal.css → themes/minimal/styles/main.css} +0 -0
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
<footer class="site-footer">
|
|
2
|
+
<div class="footer-container">
|
|
3
|
+
<div class="footer-brand">
|
|
4
|
+
<a href="{{ '/' | url }}" class="footer-logo">{{ site.title }}</a>
|
|
5
|
+
<p class="footer-tagline">{{ site.description }}</p>
|
|
6
|
+
</div>
|
|
7
|
+
|
|
8
|
+
<div class="footer-links">
|
|
9
|
+
<div class="footer-column">
|
|
10
|
+
<h4 class="footer-heading">Navigate</h4>
|
|
11
|
+
<nav class="footer-nav">
|
|
12
|
+
<a href="{{ '/' | url }}">Home</a>
|
|
13
|
+
<a href="{{ '/blog/' | url }}">Articles</a>
|
|
14
|
+
<a href="{{ '/notes/' | url }}">Notes</a>
|
|
15
|
+
<a href="{{ '/about/' | url }}">About</a>
|
|
16
|
+
</nav>
|
|
17
|
+
</div>
|
|
18
|
+
|
|
19
|
+
<div class="footer-column">
|
|
20
|
+
<h4 class="footer-heading">Subscribe</h4>
|
|
21
|
+
<nav class="footer-nav">
|
|
22
|
+
<a href="{{ '/feed.xml' | url }}">RSS Feed</a>
|
|
23
|
+
<a href="{{ '/tags/' | url }}">Browse Tags</a>
|
|
24
|
+
</nav>
|
|
25
|
+
</div>
|
|
26
|
+
</div>
|
|
27
|
+
</div>
|
|
28
|
+
|
|
29
|
+
<div class="footer-bottom">
|
|
30
|
+
<p>© {{ "now" | date("year") }} {{ site.title }}. Crafted with <a href="https://github.com/terrymooreii/sia">Sia</a>.</p>
|
|
31
|
+
</div>
|
|
32
|
+
</footer>
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
<header class="site-header">
|
|
2
|
+
<div class="header-container">
|
|
3
|
+
<a href="{{ '/' | url }}" class="site-logo">{{ site.title }}</a>
|
|
4
|
+
|
|
5
|
+
<nav class="main-nav">
|
|
6
|
+
<a href="{{ '/' | url }}" class="nav-link {% if page.url == '/' %}active{% endif %}">Home</a>
|
|
7
|
+
<a href="{{ '/blog/' | url }}" class="nav-link {% if page.url and '/blog' in page.url %}active{% endif %}">Articles</a>
|
|
8
|
+
<a href="{{ '/notes/' | url }}" class="nav-link {% if page.url and '/notes' in page.url %}active{% endif %}">Notes</a>
|
|
9
|
+
<a href="{{ '/about/' | url }}" class="nav-link {% if page.url and '/about' in page.url %}active{% endif %}">About</a>
|
|
10
|
+
</nav>
|
|
11
|
+
|
|
12
|
+
<div class="header-actions">
|
|
13
|
+
<button class="theme-toggle" aria-label="Toggle dark mode">
|
|
14
|
+
<svg class="sun-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5">
|
|
15
|
+
<circle cx="12" cy="12" r="5"></circle>
|
|
16
|
+
<line x1="12" y1="1" x2="12" y2="3"></line>
|
|
17
|
+
<line x1="12" y1="21" x2="12" y2="23"></line>
|
|
18
|
+
<line x1="4.22" y1="4.22" x2="5.64" y2="5.64"></line>
|
|
19
|
+
<line x1="18.36" y1="18.36" x2="19.78" y2="19.78"></line>
|
|
20
|
+
<line x1="1" y1="12" x2="3" y2="12"></line>
|
|
21
|
+
<line x1="21" y1="12" x2="23" y2="12"></line>
|
|
22
|
+
<line x1="4.22" y1="19.78" x2="5.64" y2="18.36"></line>
|
|
23
|
+
<line x1="18.36" y1="5.64" x2="19.78" y2="4.22"></line>
|
|
24
|
+
</svg>
|
|
25
|
+
<svg class="moon-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5">
|
|
26
|
+
<path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"></path>
|
|
27
|
+
</svg>
|
|
28
|
+
</button>
|
|
29
|
+
|
|
30
|
+
<button class="mobile-menu-toggle" aria-label="Toggle menu">
|
|
31
|
+
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5">
|
|
32
|
+
<line x1="3" y1="12" x2="21" y2="12"></line>
|
|
33
|
+
<line x1="3" y1="6" x2="21" y2="6"></line>
|
|
34
|
+
<line x1="3" y1="18" x2="21" y2="18"></line>
|
|
35
|
+
</svg>
|
|
36
|
+
</button>
|
|
37
|
+
</div>
|
|
38
|
+
</div>
|
|
39
|
+
|
|
40
|
+
<nav class="mobile-nav">
|
|
41
|
+
<a href="{{ '/' | url }}" class="mobile-nav-link">Home</a>
|
|
42
|
+
<a href="{{ '/blog/' | url }}" class="mobile-nav-link">Articles</a>
|
|
43
|
+
<a href="{{ '/notes/' | url }}" class="mobile-nav-link">Notes</a>
|
|
44
|
+
<a href="{{ '/tags/' | url }}" class="mobile-nav-link">Tags</a>
|
|
45
|
+
<a href="{{ '/about/' | url }}" class="mobile-nav-link">About</a>
|
|
46
|
+
</nav>
|
|
47
|
+
</header>
|
|
48
|
+
|
|
49
|
+
<script>
|
|
50
|
+
// Theme toggle
|
|
51
|
+
document.querySelector('.theme-toggle').addEventListener('click', function() {
|
|
52
|
+
const html = document.documentElement;
|
|
53
|
+
const current = html.getAttribute('data-theme');
|
|
54
|
+
const next = current === 'dark' ? 'light' : 'dark';
|
|
55
|
+
html.setAttribute('data-theme', next);
|
|
56
|
+
localStorage.setItem('theme', next);
|
|
57
|
+
});
|
|
58
|
+
|
|
59
|
+
// Mobile menu toggle
|
|
60
|
+
document.querySelector('.mobile-menu-toggle').addEventListener('click', function() {
|
|
61
|
+
document.querySelector('.site-header').classList.toggle('nav-open');
|
|
62
|
+
});
|
|
63
|
+
</script>
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
{% if pagination.totalPages > 1 %}
|
|
2
|
+
<nav class="pagination" aria-label="Pagination">
|
|
3
|
+
{% if pagination.previousUrl %}
|
|
4
|
+
<a href="{{ pagination.previousUrl }}" class="pagination-link prev">
|
|
5
|
+
<span class="pagination-arrow">←</span>
|
|
6
|
+
<span>Newer</span>
|
|
7
|
+
</a>
|
|
8
|
+
{% else %}
|
|
9
|
+
<span class="pagination-link prev disabled">
|
|
10
|
+
<span class="pagination-arrow">←</span>
|
|
11
|
+
<span>Newer</span>
|
|
12
|
+
</span>
|
|
13
|
+
{% endif %}
|
|
14
|
+
|
|
15
|
+
<span class="pagination-current">{{ pagination.currentPage }} / {{ pagination.totalPages }}</span>
|
|
16
|
+
|
|
17
|
+
{% if pagination.nextUrl %}
|
|
18
|
+
<a href="{{ pagination.nextUrl }}" class="pagination-link next">
|
|
19
|
+
<span>Older</span>
|
|
20
|
+
<span class="pagination-arrow">→</span>
|
|
21
|
+
</a>
|
|
22
|
+
{% else %}
|
|
23
|
+
<span class="pagination-link next disabled">
|
|
24
|
+
<span>Older</span>
|
|
25
|
+
<span class="pagination-arrow">→</span>
|
|
26
|
+
</span>
|
|
27
|
+
{% endif %}
|
|
28
|
+
</nav>
|
|
29
|
+
{% endif %}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
{% include "meta.njk" %}
|
|
5
|
+
{% include "theme-script.njk" %}
|
|
6
|
+
|
|
7
|
+
<link rel="stylesheet" href="{{ '/styles/main.css' | url }}">
|
|
8
|
+
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
9
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
10
|
+
<link href="https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700&family=Source+Sans+3:wght@400;500;600&family=Source+Serif+4:opsz,wght@8..60,400;8..60,500&display=swap" rel="stylesheet">
|
|
11
|
+
|
|
12
|
+
{% block head %}{% endblock %}
|
|
13
|
+
</head>
|
|
14
|
+
<body>
|
|
15
|
+
{% include "header.njk" %}
|
|
16
|
+
|
|
17
|
+
<main class="main">
|
|
18
|
+
{% block content %}{% endblock %}
|
|
19
|
+
</main>
|
|
20
|
+
|
|
21
|
+
{% include "footer.njk" %}
|
|
22
|
+
</body>
|
|
23
|
+
</html>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<article class="note">
|
|
5
|
+
<header class="note-header">
|
|
6
|
+
<time class="note-timestamp" datetime="{{ page.date | date('iso') }}">
|
|
7
|
+
{{ page.date | date('full_time') }}
|
|
8
|
+
</time>
|
|
9
|
+
</header>
|
|
10
|
+
|
|
11
|
+
<div class="note-body prose">
|
|
12
|
+
{{ content | safe }}
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
{% if page.tags %}
|
|
16
|
+
<footer class="note-footer">
|
|
17
|
+
<div class="note-tags">
|
|
18
|
+
{% for tag in page.tags %}
|
|
19
|
+
<a href="{{ ('/tags/' + (tag | slug) + '/') | url }}" class="tag">{{ tag }}</a>
|
|
20
|
+
{% endfor %}
|
|
21
|
+
</div>
|
|
22
|
+
</footer>
|
|
23
|
+
{% endif %}
|
|
24
|
+
</article>
|
|
25
|
+
{% endblock %}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<article class="page">
|
|
5
|
+
<header class="page-header">
|
|
6
|
+
<h1 class="page-title">{{ page.title }}</h1>
|
|
7
|
+
</header>
|
|
8
|
+
|
|
9
|
+
<div class="page-body prose">
|
|
10
|
+
{{ content | safe }}
|
|
11
|
+
</div>
|
|
12
|
+
</article>
|
|
13
|
+
{% endblock %}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<article class="article">
|
|
5
|
+
<header class="article-header">
|
|
6
|
+
<div class="article-meta-top">
|
|
7
|
+
{% if page.tags %}
|
|
8
|
+
<a href="{{ ('/tags/' + (page.tags[0] | slug) + '/') | url }}" class="article-category">{{ page.tags[0] }}</a>
|
|
9
|
+
{% endif %}
|
|
10
|
+
<span class="article-reading-time">{{ content | readingTime }}</span>
|
|
11
|
+
</div>
|
|
12
|
+
|
|
13
|
+
<h1 class="article-title">{{ page.title }}</h1>
|
|
14
|
+
|
|
15
|
+
{% if page.excerpt %}
|
|
16
|
+
<p class="article-subtitle">{{ page.excerpt | excerpt(200) }}</p>
|
|
17
|
+
{% endif %}
|
|
18
|
+
|
|
19
|
+
<div class="article-byline">
|
|
20
|
+
<div class="author-avatar">{{ (page.author or site.author)[0] }}</div>
|
|
21
|
+
<div class="author-info">
|
|
22
|
+
<span class="author-name">{{ page.author or site.author }}</span>
|
|
23
|
+
<time class="publish-date" datetime="{{ page.date | date('iso') }}">{{ page.date | date('long') }}</time>
|
|
24
|
+
</div>
|
|
25
|
+
</div>
|
|
26
|
+
</header>
|
|
27
|
+
|
|
28
|
+
{% if page.image %}
|
|
29
|
+
<figure class="article-hero">
|
|
30
|
+
<img src="{{ page.image | url }}" alt="{{ page.title }}">
|
|
31
|
+
{% if page.imageCaption %}
|
|
32
|
+
<figcaption>{{ page.imageCaption }}</figcaption>
|
|
33
|
+
{% endif %}
|
|
34
|
+
</figure>
|
|
35
|
+
{% endif %}
|
|
36
|
+
|
|
37
|
+
<div class="article-body prose">
|
|
38
|
+
{{ content | safe }}
|
|
39
|
+
</div>
|
|
40
|
+
|
|
41
|
+
<footer class="article-footer">
|
|
42
|
+
{% if page.tags %}
|
|
43
|
+
<div class="article-tags">
|
|
44
|
+
{% for tag in page.tags %}
|
|
45
|
+
<a href="{{ ('/tags/' + (tag | slug) + '/') | url }}" class="tag">{{ tag }}</a>
|
|
46
|
+
{% endfor %}
|
|
47
|
+
</div>
|
|
48
|
+
{% endif %}
|
|
49
|
+
|
|
50
|
+
<div class="article-share">
|
|
51
|
+
<span class="share-label">Share this article</span>
|
|
52
|
+
<div class="share-links">
|
|
53
|
+
<a href="https://twitter.com/intent/tweet?url={{ site.url }}{{ page.url }}&text={{ page.title | urlencode }}" target="_blank" rel="noopener" class="share-link" aria-label="Share on Twitter">
|
|
54
|
+
<svg viewBox="0 0 24 24" fill="currentColor"><path d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-5.214-6.817L4.99 21.75H1.68l7.73-8.835L1.254 2.25H8.08l4.713 6.231zm-1.161 17.52h1.833L7.084 4.126H5.117z"/></svg>
|
|
55
|
+
</a>
|
|
56
|
+
<a href="https://www.linkedin.com/sharing/share-offsite/?url={{ site.url }}{{ page.url }}" target="_blank" rel="noopener" class="share-link" aria-label="Share on LinkedIn">
|
|
57
|
+
<svg viewBox="0 0 24 24" fill="currentColor"><path d="M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z"/></svg>
|
|
58
|
+
</a>
|
|
59
|
+
</div>
|
|
60
|
+
</div>
|
|
61
|
+
</footer>
|
|
62
|
+
</article>
|
|
63
|
+
|
|
64
|
+
<aside class="read-more">
|
|
65
|
+
<h2 class="read-more-title">Continue Reading</h2>
|
|
66
|
+
<div class="read-more-posts">
|
|
67
|
+
{% for post in collections.posts | limit(3) %}
|
|
68
|
+
{% if post.url != page.url %}
|
|
69
|
+
<article class="read-more-card">
|
|
70
|
+
<h3 class="read-more-card-title">
|
|
71
|
+
<a href="{{ post.url | url }}">{{ post.title }}</a>
|
|
72
|
+
</h3>
|
|
73
|
+
<time class="read-more-date">{{ post.date | date('short') }}</time>
|
|
74
|
+
</article>
|
|
75
|
+
{% endif %}
|
|
76
|
+
{% endfor %}
|
|
77
|
+
</div>
|
|
78
|
+
</aside>
|
|
79
|
+
{% endblock %}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<header class="listing-header">
|
|
5
|
+
<h1 class="listing-title">Articles</h1>
|
|
6
|
+
<p class="listing-description">Thoughts, stories, and ideas</p>
|
|
7
|
+
</header>
|
|
8
|
+
|
|
9
|
+
<div class="articles-list">
|
|
10
|
+
{% for post in posts %}
|
|
11
|
+
<article class="article-row">
|
|
12
|
+
<div class="article-row-content">
|
|
13
|
+
{% if post.tags %}
|
|
14
|
+
<a href="{{ ('/tags/' + (post.tags[0] | slug) + '/') | url }}" class="row-category">{{ post.tags[0] }}</a>
|
|
15
|
+
{% endif %}
|
|
16
|
+
<h2 class="row-title">
|
|
17
|
+
<a href="{{ post.url | url }}">{{ post.title }}</a>
|
|
18
|
+
</h2>
|
|
19
|
+
<p class="row-excerpt">{{ post.excerpt | excerpt(180) }}</p>
|
|
20
|
+
<div class="row-meta">
|
|
21
|
+
<span class="row-author">{{ post.author or site.author }}</span>
|
|
22
|
+
<span class="meta-separator">·</span>
|
|
23
|
+
<time datetime="{{ post.date | date('iso') }}">{{ post.date | date('long') }}</time>
|
|
24
|
+
<span class="meta-separator">·</span>
|
|
25
|
+
<span>{{ post.content | readingTime }}</span>
|
|
26
|
+
</div>
|
|
27
|
+
</div>
|
|
28
|
+
</article>
|
|
29
|
+
{% else %}
|
|
30
|
+
<p class="empty-state">No articles yet. Check back soon!</p>
|
|
31
|
+
{% endfor %}
|
|
32
|
+
</div>
|
|
33
|
+
|
|
34
|
+
{% include "pagination.njk" %}
|
|
35
|
+
{% endblock %}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
|
|
3
|
+
<channel>
|
|
4
|
+
<title>{{ site.title }}</title>
|
|
5
|
+
<description>{{ site.description }}</description>
|
|
6
|
+
<link>{{ site.url }}</link>
|
|
7
|
+
<atom:link href="{{ site.url }}/feed.xml" rel="self" type="application/rss+xml"/>
|
|
8
|
+
<lastBuildDate>{{ buildDate }}</lastBuildDate>
|
|
9
|
+
{% for post in posts | limit(20) %}
|
|
10
|
+
<item>
|
|
11
|
+
<title>{{ post.title }}</title>
|
|
12
|
+
<link>{{ site.url }}{{ post.url }}</link>
|
|
13
|
+
<guid isPermaLink="true">{{ site.url }}{{ post.url }}</guid>
|
|
14
|
+
<pubDate>{{ post.date | date('rss') }}</pubDate>
|
|
15
|
+
<description><![CDATA[{{ post.excerpt | excerpt(300) }}]]></description>
|
|
16
|
+
{% for tag in post.tags %}
|
|
17
|
+
<category>{{ tag }}</category>
|
|
18
|
+
{% endfor %}
|
|
19
|
+
</item>
|
|
20
|
+
{% endfor %}
|
|
21
|
+
</channel>
|
|
22
|
+
</rss>
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<section class="hero">
|
|
5
|
+
<div class="hero-content">
|
|
6
|
+
<h1 class="hero-title">{{ site.title }}</h1>
|
|
7
|
+
<p class="hero-subtitle">{{ site.description }}</p>
|
|
8
|
+
</div>
|
|
9
|
+
</section>
|
|
10
|
+
|
|
11
|
+
{% set featuredPost = collections.posts[0] %}
|
|
12
|
+
{% if featuredPost %}
|
|
13
|
+
<section class="featured-section">
|
|
14
|
+
<article class="featured-article">
|
|
15
|
+
<div class="featured-content">
|
|
16
|
+
{% if featuredPost.tags %}
|
|
17
|
+
<span class="featured-category">{{ featuredPost.tags[0] }}</span>
|
|
18
|
+
{% endif %}
|
|
19
|
+
<h2 class="featured-title">
|
|
20
|
+
<a href="{{ featuredPost.url | url }}">{{ featuredPost.title }}</a>
|
|
21
|
+
</h2>
|
|
22
|
+
<p class="featured-excerpt">{{ featuredPost.excerpt | excerpt(200) }}</p>
|
|
23
|
+
<div class="featured-meta">
|
|
24
|
+
<span class="featured-author">{{ featuredPost.author or site.author }}</span>
|
|
25
|
+
<span class="featured-date">{{ featuredPost.date | date('long') }}</span>
|
|
26
|
+
<span class="featured-reading">{{ featuredPost.content | readingTime }}</span>
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
</article>
|
|
30
|
+
</section>
|
|
31
|
+
{% endif %}
|
|
32
|
+
|
|
33
|
+
<section class="latest-section">
|
|
34
|
+
<div class="section-header">
|
|
35
|
+
<h2 class="section-title">Latest Articles</h2>
|
|
36
|
+
<a href="{{ '/blog/' | url }}" class="section-link">View all →</a>
|
|
37
|
+
</div>
|
|
38
|
+
|
|
39
|
+
<div class="articles-grid">
|
|
40
|
+
{% for post in collections.posts | skip(1) | limit(6) %}
|
|
41
|
+
<article class="article-card">
|
|
42
|
+
<div class="card-content">
|
|
43
|
+
{% if post.tags %}
|
|
44
|
+
<span class="card-category">{{ post.tags[0] }}</span>
|
|
45
|
+
{% endif %}
|
|
46
|
+
<h3 class="card-title">
|
|
47
|
+
<a href="{{ post.url | url }}">{{ post.title }}</a>
|
|
48
|
+
</h3>
|
|
49
|
+
<p class="card-excerpt">{{ post.excerpt | excerpt(100) }}</p>
|
|
50
|
+
<div class="card-meta">
|
|
51
|
+
<time datetime="{{ post.date | date('iso') }}">{{ post.date | date('short') }}</time>
|
|
52
|
+
<span>·</span>
|
|
53
|
+
<span>{{ post.content | readingTime }}</span>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
</article>
|
|
57
|
+
{% endfor %}
|
|
58
|
+
</div>
|
|
59
|
+
</section>
|
|
60
|
+
|
|
61
|
+
{% if collections.notes.length %}
|
|
62
|
+
<section class="notes-section">
|
|
63
|
+
<div class="section-header">
|
|
64
|
+
<h2 class="section-title">Recent Notes</h2>
|
|
65
|
+
<a href="{{ '/notes/' | url }}" class="section-link">View all →</a>
|
|
66
|
+
</div>
|
|
67
|
+
|
|
68
|
+
<div class="notes-feed">
|
|
69
|
+
{% for note in collections.notes | limit(3) %}
|
|
70
|
+
<article class="note-preview">
|
|
71
|
+
<time datetime="{{ note.date | date('iso') }}">{{ note.date | date('short') }}</time>
|
|
72
|
+
<p>{{ note.excerpt | excerpt(150) }}</p>
|
|
73
|
+
<a href="{{ note.url | url }}" class="note-link">Read note →</a>
|
|
74
|
+
</article>
|
|
75
|
+
{% endfor %}
|
|
76
|
+
</div>
|
|
77
|
+
</section>
|
|
78
|
+
{% endif %}
|
|
79
|
+
{% endblock %}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<header class="listing-header">
|
|
5
|
+
<h1 class="listing-title">Notes</h1>
|
|
6
|
+
<p class="listing-description">Quick thoughts and observations</p>
|
|
7
|
+
</header>
|
|
8
|
+
|
|
9
|
+
<div class="notes-list">
|
|
10
|
+
{% for note in notes %}
|
|
11
|
+
<article class="note-item">
|
|
12
|
+
<time class="note-time" datetime="{{ note.date | date('iso') }}">
|
|
13
|
+
{{ note.date | date('full') }}
|
|
14
|
+
</time>
|
|
15
|
+
<div class="note-content">
|
|
16
|
+
<p>{{ note.excerpt | excerpt(250) }}</p>
|
|
17
|
+
<a href="{{ note.url | url }}" class="note-read-more">Continue reading →</a>
|
|
18
|
+
</div>
|
|
19
|
+
{% if note.tags %}
|
|
20
|
+
<div class="note-item-tags">
|
|
21
|
+
{% for tag in note.tags %}
|
|
22
|
+
<a href="{{ ('/tags/' + (tag | slug) + '/') | url }}" class="tag">{{ tag }}</a>
|
|
23
|
+
{% endfor %}
|
|
24
|
+
</div>
|
|
25
|
+
{% endif %}
|
|
26
|
+
</article>
|
|
27
|
+
{% else %}
|
|
28
|
+
<p class="empty-state">No notes yet.</p>
|
|
29
|
+
{% endfor %}
|
|
30
|
+
</div>
|
|
31
|
+
|
|
32
|
+
{% include "pagination.njk" %}
|
|
33
|
+
{% endblock %}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<header class="listing-header">
|
|
5
|
+
<span class="tag-label">Topic</span>
|
|
6
|
+
<h1 class="listing-title">{{ tag.name }}</h1>
|
|
7
|
+
<p class="listing-description">{{ tag.count }} article{% if tag.count != 1 %}s{% endif %}</p>
|
|
8
|
+
</header>
|
|
9
|
+
|
|
10
|
+
<div class="articles-list">
|
|
11
|
+
{% for post in posts %}
|
|
12
|
+
<article class="article-row">
|
|
13
|
+
<div class="article-row-content">
|
|
14
|
+
<h2 class="row-title">
|
|
15
|
+
<a href="{{ post.url | url }}">{{ post.title }}</a>
|
|
16
|
+
</h2>
|
|
17
|
+
<p class="row-excerpt">{{ post.excerpt | excerpt(180) }}</p>
|
|
18
|
+
<div class="row-meta">
|
|
19
|
+
<span class="row-author">{{ post.author or site.author }}</span>
|
|
20
|
+
<span class="meta-separator">·</span>
|
|
21
|
+
<time datetime="{{ post.date | date('iso') }}">{{ post.date | date('long') }}</time>
|
|
22
|
+
<span class="meta-separator">·</span>
|
|
23
|
+
<span>{{ post.content | readingTime }}</span>
|
|
24
|
+
</div>
|
|
25
|
+
</div>
|
|
26
|
+
</article>
|
|
27
|
+
{% endfor %}
|
|
28
|
+
</div>
|
|
29
|
+
|
|
30
|
+
{% include "pagination.njk" %}
|
|
31
|
+
{% endblock %}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{% extends "base.njk" %}
|
|
2
|
+
|
|
3
|
+
{% block content %}
|
|
4
|
+
<header class="listing-header">
|
|
5
|
+
<h1 class="listing-title">Topics</h1>
|
|
6
|
+
<p class="listing-description">Explore articles by topic</p>
|
|
7
|
+
</header>
|
|
8
|
+
|
|
9
|
+
<div class="topics-grid">
|
|
10
|
+
{% for tag in allTags %}
|
|
11
|
+
<a href="{{ ('/tags/' + tag.slug + '/') | url }}" class="topic-card">
|
|
12
|
+
<span class="topic-name">{{ tag.name }}</span>
|
|
13
|
+
<span class="topic-count">{{ tag.count }} article{% if tag.count != 1 %}s{% endif %}</span>
|
|
14
|
+
</a>
|
|
15
|
+
{% else %}
|
|
16
|
+
<p class="empty-state">No topics yet.</p>
|
|
17
|
+
{% endfor %}
|
|
18
|
+
</div>
|
|
19
|
+
{% endblock %}
|