jekyll-theme-nix 1.1.1 → 1.1.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 182a9cc805dbd06edc0ead2a90dec27f3063bf872cf15a7ed2be504939e946c3
4
- data.tar.gz: 1e1b44b75de9fd8626fc0b88688fe8d30dcc962625e1b44af0456ab1b0ab3dca
3
+ metadata.gz: 84ca04bcd2a552ae5617a8c8db93d3efe43e4c30679366e0281f9fca15568afe
4
+ data.tar.gz: ac72b36c0f0538fd41988c00193e7e3a17892fe05e906df77994cc937c7f8f03
5
5
  SHA512:
6
- metadata.gz: 323a21b52eedd590a20049c2281153e3cd46193f8ef330e3cc98c058d5675b0f443a80ed01cc9931cc5dcacc4cb52f066cb7a2acee6baac09bac2becc8dd95cd
7
- data.tar.gz: 8ad6b52905791f998bd5abc9997557505a06e3e7e08f69c33bbdc9f61327f4d4127a25bc04f38422639098d59a472c228980e532397c29451e2bbbe15dd84e25
6
+ metadata.gz: 6aa074397ff46ab67e139fbaf8ded06955ab28672a01f671e173e2bd625722024cc78392d45b5a808592618cb63ba10635c79435c2ff576c825b61015b32532b
7
+ data.tar.gz: 7fec7f165cfe7cbf47c424354fde3af50327622ef8ceee20d937981fe2244b5899ce088be4441e8951461566490f78ae9d1d2cf90b02bc90d1f7a51ed79e5b9c
data/README.md CHANGED
@@ -1,8 +1,8 @@
1
1
  # Jekyll Theme Nix
2
2
 
3
- A barebones theme for [Jekyll](https://github.com/jekyll/jekyll), which doesn't need any dependencies except `jekyll-redirect-from`, if you want to redirect pages. It is optimized for fast build speeds as well.
3
+ A barebones theme for [Jekyll](https://github.com/jekyll/jekyll), which doesn't need any dependencies except `jekyll-redirect-from`, if you want to redirect pages without any web server configuration. It is optimized for fast build speeds as well.
4
4
 
5
- Its purpose is to be a minimalistic, single-author theme. Because there is no menu, pages can be manually linked in the body of `index.md`.
5
+ Its purpose is to be a minimalist, single-author theme. Because there is no menu, pages can be manually linked in the body of `index.md`.
6
6
 
7
7
  It also changes as little as possible from the default browser settings to improve legibility.
8
8
 
@@ -10,7 +10,9 @@ It also changes as little as possible from the default browser settings to impro
10
10
 
11
11
  ![Screenshot](/screenshot.png)
12
12
 
13
- If this theme feels to bloated to you, you can try [“Nixer”](https://github.com/michaelnordmeyer/jekyll-theme-nixer), the ultra-minimalistic version of “Nix”.
13
+ If this theme feels to bloated to you, you can try [“Nixer”](https://github.com/michaelnordmeyer/jekyll-theme-nixer), the ultra-minimalist version of “Nix”.
14
+
15
+ [I wrote up what inspired me to create both themes](https://michaelnordmeyer.com/i-created-two-ultra-minimalistic-jekyll-themes).
14
16
 
15
17
  ## Limited Features
16
18
 
@@ -28,19 +30,11 @@ If this theme feels to bloated to you, you can try [“Nixer”](https://github.
28
30
 
29
31
  ### Default Colors
30
32
 
31
- The default browser link colors don't look great, if they're inverted in dark mode, just like white is inverted to black for the background:
32
-
33
- - Link: <span style="background-color: white; color: #0000ee">&nbsp;#0000ee&nbsp;</span> => <span style="background-color: black; color: #ffff11">&nbsp;#ffff11&nbsp;</span>
34
- - Link visited: <span style="background-color: white; color: #551a8b">&nbsp;#551a8b&nbsp;</span> => <span style="background-color: black; color: #aae574">&nbsp;#aae574&nbsp;</span>
35
-
36
- Therefore, they're set to somewhat lighter versions of the default colors:
37
-
38
- - Link: <span style="background-color: white; color: #0000ee">&nbsp;#0000ee&nbsp;</span> => <span style="background-color: black; color: lightskyblue">&nbsp;lightskyblue&nbsp;</span>
39
- - Link visited: <span style="background-color: white; color: #551a8b">&nbsp;#551a8b&nbsp;</span> => <span style="background-color: black; color: plum">&nbsp;plum&nbsp;</span>
33
+ The default colors are the colors of the respective browsers, both in light mode and in dark mode.
40
34
 
41
35
  ### Favicon
42
36
 
43
- The favicon is currently `icon.webp` for the light mode, and there's also a dark variant `icon-dark.webp`.
37
+ `/assets/icons/icon.webp` is the favicon for the light mode, and there's also a dark variant `/assets/icons/icon-dark.webp` for dark mode. They will be used automatically or you can replace them by creating new ones in the same location.
44
38
 
45
39
  ### Nix?
46
40
 
@@ -50,39 +44,47 @@ Or, if you will, it could be UNIX without the “U”, because of the theme's so
50
44
 
51
45
  ## Installation
52
46
 
53
- Installation from Gem is recommended, but using a remote theme is also possible, even though it will increase build time a little, depending on your internet connection, because the theme will be downloaded during each build. Gems are installed locally.
47
+ Installation from Gem is recommended, but using a remote theme is also possible, even though it will increase build times a little, depending on your internet connection and the size of the theme download, because it will be downloaded during each build. Gems are installed locally.
54
48
 
55
- GitHub pages gem users need to use the remote theme method.
49
+ GitHub Pages gem users need to use the remote theme method.
56
50
 
57
51
  ### Installation from Gem
58
52
 
59
53
  Add this line to your Jekyll site's `Gemfile`:
60
54
 
61
55
  ```ruby
62
- gem "jekyll-theme-nix"
56
+ gem "jekyll-theme-nix", group: [:jekyll_plugins]
63
57
  ```
64
58
 
65
- And add this line to your Jekyll site's `_config.yml`:
59
+ Then run `bundle` in your terminal.
66
60
 
67
- ```yaml
68
- theme: jekyll-theme-nix
61
+ ```sh
62
+ bundle
69
63
  ```
70
64
 
71
- Make sure that this is the only `theme:` in `_config.yml`, and that there are no other `remote-theme:`. Afterwards run `bundle install`, and `bundle update` to update it, if there's a new version.
65
+ Also add the theme to your Jekyll site's `_config.yml`:
72
66
 
73
- ```sh
74
- bundle install
67
+ ```yaml
68
+ theme: jekyll-theme-nix
75
69
  ```
76
70
 
71
+ Make sure that this is the only `theme:` in `_config.yml`, and that there are no other `remote-theme:`.
72
+
77
73
  ### Installation as Remote Theme
78
74
 
79
75
  Add this line to your Jekyll site's `Gemfile`:
80
76
 
81
77
  ```ruby
82
- gem "jekyll-remote-theme"
78
+ gem "jekyll-remote-theme", group: [:jekyll_plugins]
79
+ ```
80
+
81
+ Then run `bundle` in your terminal.
82
+
83
+ ```sh
84
+ bundle
83
85
  ```
84
86
 
85
- And add this line to your Jekyll site's `_config.yml`:
87
+ Finally add the remote theme to your Jekyll site's `_config.yml`:
86
88
 
87
89
  ```yaml
88
90
  remote_theme: michaelnordmeyer/jekyll-theme-nix
@@ -90,12 +92,10 @@ remote_theme: michaelnordmeyer/jekyll-theme-nix
90
92
 
91
93
  Make sure that this is the only `remote_theme:` in `_config.yml`, and that there are no other `theme:`.
92
94
 
93
- Finally, add `jekyll-remote-theme` to your plugin section in `_config.yml` as well.
94
-
95
- ## Feed.xml and Sitemap.xml
95
+ ## Styled Atom Feed and Sitemap.xml
96
96
 
97
- Both are included in the theme and don't need dependencies to `jekyll-feed` and `jekyll-sitemap` plugins. For a standard Jekyll installation, they work out-of-the-box if both files are copied to the Jekyll directory.
97
+ Both are included in the demo. For a standard Jekyll installation, they work out-of-the-box if the files `feed.xslt.xml` and `sitemap.xsl` are copied to the site’s Jekyll directory.
98
98
 
99
- If hosted with the Github pages plugin, those plugins are already included and will automatically be used instead. To overwrite this, both files have to be copied manually from the theme's repository root to the site's repository root.
99
+ The XSLT files style the XML files. If a user selects the link to the feed, a styled version of the feed will be shown in the browser with an explainer of what web feeds are.
100
100
 
101
- Because feeds are generated once, they can only support one icon, which why the light variant was chosen.
101
+ Because feeds are generated once, they can only support one icon. The light variant was chosen for the feed.
data/_config.yml CHANGED
@@ -1,18 +1,18 @@
1
- ## Remove URL for Github Pages
1
+ ## Remove URL for GitHub Pages plugin
2
2
  url: https://jekyll-theme-nix.michaelnordmeyer.com
3
3
  title: Jekyll Theme Nix
4
- author:
5
- name: Michael Nordmeyer
6
- uri: https://jekyll-theme-nix.michaelnordmeyer.com
7
4
  description: "A barebones theme for Jekyll"
8
5
 
9
6
  plugins:
7
+ - jekyll-feed
10
8
  - jekyll-include-cache
11
- # - jekyll-redirect-from
9
+ - jekyll-redirect-from
10
+ - jekyll-sitemap
12
11
 
13
- ## Jekyll build settings
14
- exclude: [jekyll-theme-nix*, LICENSE, Rakefile.rb, README.md]
12
+ ## Jekyll build settings https://jekyllrb.com/docs/configuration/default/
13
+ exclude: [CODE_OF_CONDUCT.md, jekyll-theme-nix*, LICENSE, Rakefile.rb, README.md, screenshot.png]
15
14
  ignore_theme_config: true # Since Jekyll 4.0, see: https://jekyllrb.com/docs/themes/#pre-configuring-theme-gems40, https://jekyllrb.com/docs/configuration/options/
15
+ include: [.well-known]
16
16
  kramdown:
17
17
  show_warnings: true
18
18
  syntax_highlighter_opts:
@@ -26,17 +26,50 @@ liquid:
26
26
  sass:
27
27
  style: compressed
28
28
  strict_front_matter: true # default: false
29
- timezone: Europe/Berlin # default: local timezone
30
29
  # remote_theme: michaelnordmeyer/jekyll-theme-nix
31
30
  # theme: jekyll-theme-nix
31
+ timezone: Europe/Berlin # default: local timezone
32
32
 
33
- ## Custom theme settings to not overwrite anything from Jekyll or plugins
33
+ ## Custom settings used by plugins and the theme
34
+ author:
35
+ name: Michael Nordmeyer
36
+ # email: xxx@example.com
37
+ uri: https://michaelnordmeyer.com/
38
+ copyright: Copyright © Michael Nordmeyer
39
+ license_link: https://raw.githubusercontent.com/michaelnordmeyer/jekyll-theme-nix/main/LICENSE
40
+ # date_format: "%b %-d, %Y" # default: "%Y-%m-%d"
34
41
  lang: en-US # default: en (is not by Jekyll, but used by many other plugins)
42
+ title_separator: " • " # default: " | "
43
+ ## Custom theme settings
44
+ favicon: /assets/icons/icon.webp # optional, but mandatory if favicon_dark is used, needs to be 180x180
45
+ favicon_dark: /assets/icons/icon-dark.webp # optional, needs to be 180x180
35
46
  theme_settings:
36
- # date_format: "%b %-d, %Y" # default: "%Y-%m-%d"
37
- favicon: /icon.webp # optional, needs to be 180x180
38
- favicon_dark: /icon-dark.webp # optional, needs to be 180x180
39
- favicon_media_type: image/webp # mandatory, if favicon is set
40
- feed:
41
- posts_limit: 999
42
- # title_separator: "|" # default: "•"
47
+ # redirect_page_title: "Redirecting…" # default: "Redirecting…"
48
+ # redirect_page_from: "Redirecting from" # default: "Redirecting from"
49
+ # redirect_page_to: "to" # default: "to"
50
+ # redirect_page_text: "Click here if you are not being redirected." # default: "Click here if you are not being redirected.""
51
+
52
+ ## https://jekyllrb.com/docs/configuration/front-matter-defaults/
53
+ # Only works for all posts, but can work for a subset of pages
54
+ defaults:
55
+ - scope:
56
+ path: "" # an empty string here means all files in the project (allows globs, but is slow)
57
+ type: posts # type (optional): posts, pages, drafts, or any collection
58
+ values:
59
+ layout: post
60
+ - scope:
61
+ path: ""
62
+ type: pages
63
+ values:
64
+ layout: page
65
+ permalink: /:path/:basename
66
+ - scope:
67
+ path: error
68
+ type: pages
69
+ values:
70
+ layout: error
71
+ sitemap: false
72
+ - scope:
73
+ path: ""
74
+ values:
75
+ layout: default
@@ -0,0 +1,19 @@
1
+ <!DOCTYPE html>
2
+ <html lang="{{ page.lang | default: site.lang | default: 'en' }}">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1">
6
+ {%- if site.favicon %}
7
+ {%- if site.favicon_dark %}
8
+ <link rel="icon" type="{{ site.favicon_media_type }}" media="(prefers-color-scheme: light)" href="{{ site.favicon | relative_url }}">
9
+ <link rel="icon" type="{{ site.favicon_media_type }}" media="(prefers-color-scheme: dark)" href="{{ site.favicon_dark | relative_url }}">
10
+ {%- else %}
11
+ <link rel="icon" type="{{ site.favicon_media_type }}" href="{{ site.favicon | relative_url }}">
12
+ {%- endif %}
13
+ {%- endif %}
14
+ <meta name="color-scheme" content="light dark">
15
+ <meta name="theme-color" media="(prefers-color-scheme: light)" content="white">
16
+ <meta name="theme-color" media="(prefers-color-scheme: dark)" content="black">
17
+ {%- if page.sitemap == false %}
18
+ <meta name="robots" content="noindex">
19
+ {%- endif %}
@@ -0,0 +1,5 @@
1
+ <header>
2
+ <nav>
3
+ <a rel="author" href="{{ '/' | relative_url }}" accesskey="h" title="Home">{{ site.title }}</a>
4
+ </nav>
5
+ </header>
@@ -0,0 +1,48 @@
1
+ <style>
2
+ :root {
3
+ --default-font-px: 16;
4
+ --font-size: 1rem;
5
+ --font-family: sans-serif;
6
+ --spacing: 1em;
7
+ --line-height: 1.5;
8
+ /* Calculate integer pixel values depending on the font size (1rem = 16px) */
9
+ --border-size: calc(var(--font-size) * 1/var(--default-font-px));
10
+ --x-script: calc(var(--font-size) * 11/var(--default-font-px));
11
+ --small-font-size: calc(var(--font-size) * 14/var(--default-font-px));
12
+ --big-font-size: calc(var(--font-size) * 32/var(--default-font-px));
13
+ }
14
+ html {
15
+ max-width: 720px;
16
+ margin: 0 auto;
17
+ padding: calc(var(--spacing) * 1/2);
18
+ font: var(--font-size) / var(--line-height) var(--font-family);
19
+ /* font-size-adjust: from-font; */
20
+ -moz-text-size-adjust: none;
21
+ -webkit-text-size-adjust: none;
22
+ text-size-adjust: none;
23
+ }
24
+ body { margin: 0; }
25
+ img, table { margin: 0 auto; }
26
+ table { border-collapse: collapse; }
27
+ th, td { padding: calc(var(--spacing) * 1/4); border: var(--border-size) solid color-mix(in srgb, currentcolor 50%, transparent); }
28
+ img { display: block; max-width: 100%; height: auto; }
29
+ figure { margin-left: 0; margin-right: 0; max-width: 100%; text-align: center; font-size: var(--small-font-size); line-height: 1; }
30
+ blockquote { margin: var(--spacing) calc(var(--spacing) * 3/2) var(--spacing) calc(var(--spacing) * 1/2); padding-left: var(--spacing); border-left: var(--border-size) solid color-mix(in srgb, currentcolor 50%, transparent); }
31
+ sub, sup { font-size: var(--x-script); line-height: 0; }
32
+ hr { margin: calc(var(--spacing) * 2) 0; border: 0; border-top: var(--border-size) solid; }
33
+ h1, h2, h3, h4, h5, h6 { line-height: 1.2; text-wrap: balance; }
34
+ h1 { font-size: var(--big-font-size); }
35
+ body > header > nav > h1 { margin-bottom: var(--spacing); text-align: center; line-height: 1.2; }
36
+ body > header a { text-decoration: none; color: currentcolor; }
37
+ body > header > nav > a { display: block; margin-block-start: calc(var(--spacing) * 2/3); margin-block-end: var(--spacing); text-align: center; font-size: var(--big-font-size); font-weight: bold; line-height: 1.2; }
38
+ body > header a:visited { color: currentcolor; }
39
+ body > main > section > ul { padding: 0; }
40
+ body > main > section > ul > li { margin: calc(var(--spacing) * 1/2) 0; list-style-type: none; line-height: 1.25; }
41
+ body > main > section > ul > li time { font-size: var(--small-font-size); }
42
+ article > header { margin-bottom: calc(var(--spacing) * 2); }
43
+ article > header > h1 { margin-bottom: 0; }
44
+ article h1 { font-size: var(--big-font-size); }
45
+ header > time { display: block; color: color-mix(in srgb, currentcolor 50%, transparent); }
46
+ hr:has(+div[role="doc-endnotes"]) { margin-bottom: var(--spacing); }
47
+ div[role="doc-endnotes"] { margin-top: 0; font-size: var(--small-font-size); line-height: var(--line-height); }
48
+ </style>
@@ -1,59 +1,10 @@
1
- <!DOCTYPE html>
2
- <html lang="{{ page.lang | default: site.lang | default: 'en' }}">
3
- <head>
4
- <meta charset="utf-8">
5
- <meta name="viewport" content="width=device-width, initial-scale=1">
6
- <link rel="icon" type="{{ site.theme_settings.favicon_media_type }}" media="(prefers-color-scheme: light)" href="{{ site.theme_settings.favicon | relative_url }}">
7
- <link rel="icon" type="{{ site.theme_settings.favicon_media_type }}" media="(prefers-color-scheme: dark)" href="{{ site.theme_settings.favicon_dark | relative_url }}">
8
- <meta name="theme-color" media="(prefers-color-scheme: light)" content="white">
9
- <meta name="theme-color" media="(prefers-color-scheme: dark)" content="black">
10
- <style>
11
- :root { color-scheme: light dark; }
12
- html {
13
- max-width: 43rem;
14
- margin: 0 auto;
15
- padding: 1em;
16
- font: 1rem / 1.5 sans-serif;
17
- }
18
- body { margin: 0; }
19
- img, table { margin: 0 auto; }
20
- table { border-collapse: collapse; }
21
- th, td { padding: 0.25em; border: 1px solid lightgrey; }
22
- img { display: block; max-width: 100%; height: auto; }
23
- figure { margin: 0; text-align: center; font-size: small; }
24
- blockquote { margin: 1em 1.5em 1em 0.5em; padding-left: 1em; border-left: 1px solid lightgrey; }
25
- sub, sup { line-height: 0; }
26
- hr { border: 0; border-top: 1px solid; }
27
- h1, h2, h3, h4, h5, h6 { line-height: 1.2; }
28
- body > header > h1 { margin-bottom: 2rem; text-align: center; }
29
- body > header > h1 > a { text-decoration: none; color: black }
30
- body > header > a { display: block; margin-block-start: 0.67em; margin-block-end: 1em; text-align: center; font-size: 2em; font-weight: bold; text-decoration: none; line-height: 1.2; }
31
- body > header a:visited { color: black; }
32
- body > main > ul { padding: 0; }
33
- body > main > ul > li { margin: 0.5em 0; list-style-type: none; line-height: 1.25; }
34
- body > main > ul > li time { font-size: small; }
35
- article > header { margin-bottom: 2rem; }
36
- article > header > h1 { margin-bottom: 0; }
37
- article h1 { font-size: 2rem; }
38
- header > time { display: block; color: grey; }
39
- @media (prefers-color-scheme: dark) {
40
- html { background-color: black; color: white; }
41
- a { color: lightskyblue; }
42
- a:visited { color: plum; }
43
- body > header > h1 > a,
44
- body > header > a { text-decoration: none; color: white }
45
- body > header > h1 > a:visited,
46
- body > header > a:visited { color: white; }
47
- header > time { color: darkgrey; }
48
- th, td { border-color: grey; }
49
- }
50
- .footnotes { margin: 0; font-size: small; }
51
- </style>
52
- <title>{%- if page.title -%}{{ page.title | smartify }} • {{ site.title | smartify }}{%- else -%}{{ site.title | smartify }} • {{ site.description | smartify }}{%- endif -%}</title>
1
+ {% include head.html %}
2
+ <title>{%- if page.title -%}{{ page.title | smartify }}{{ site.title_separator | default: ' | ' }}{{ site.title | smartify }}{%- else -%}{{ site.title | smartify }}{{ site.title_separator | default: ' | ' }}{{ site.description | smartify }}{%- endif -%}</title>
53
3
  <meta name="description" content="{% if page.excerpt %}{{ page.excerpt | strip_html | smartify }}{% else %}{{ site.description | smartify }}{% endif %}">
54
4
  <meta name="author" content="{{ site.author.name }}">
55
5
  <link rel="canonical" href="{{ page.url | absolute_url }}">
56
- <link type="application/atom+xml" rel="alternate" href="{{ '/feed.xml' | relative_url }}" title="{{ site.title | smartify }}">
6
+ {% feed_meta %}
7
+ {% include_cached style.html %}
57
8
  </head>
58
9
  <body>
59
10
  {{ content }}
data/_layouts/error.html CHANGED
@@ -1,42 +1,13 @@
1
- <!DOCTYPE html>
2
- <html lang="{{ page.lang | default: site.lang | default: 'en' }}">
3
- <head>
4
- <meta charset="utf-8">
5
- <meta name="viewport" content="width=device-width, initial-scale=1">
6
- <link rel="icon" type="{{ site.theme_settings.favicon_media_type }}" media="(prefers-color-scheme: light)" href="{{ site.theme_settings.favicon | relative_url }}">
7
- <link rel="icon" type="{{ site.theme_settings.favicon_media_type }}" media="(prefers-color-scheme: dark)" href="{{ site.theme_settings.favicon_dark | relative_url }}">
8
- <style>
9
- :root { color-scheme: light dark; }
10
- html {
11
- max-width: 43rem;
12
- margin: 0 auto;
13
- padding: 1em;
14
- font: 1rem / 1.5 sans-serif;
15
- }
16
- body { margin: 0; }
17
- body > header > a { display: block; margin-block-start: 0.67em; margin-block-end: 1em; text-align: center; font-size: 2rem; font-weight: bold; }
18
- article > header { margin-bottom: 2rem; }
19
- article > header > h1 { margin-bottom: 0; }
20
- article h1 { font-size: 2rem; line-height: 1.2; }
21
- @media (prefers-color-scheme: dark) {
22
- html { background-color: black; color: white; }
23
- a { color: lightskyblue; }
24
- a:visited { color: plum; }
25
- }
26
- </style>
27
- <meta name="theme-color" content="#white">
1
+ {% include head.html %}
28
2
  <title>{%- if page.title -%}{{ page.title | smartify }}{%- else -%}{{ site.title | smartify }}{%- endif -%}</title>
29
- <meta name="description" content="Error page">
30
- <meta name="robots" content="noindex,follow">
3
+ {% include_cached style.html %}
31
4
  </head>
32
5
  <body>
33
- <header>
34
- <a rel="author" href="{{ '/' | relative_url }}" accesskey="h" title="Home">{{ site.title }}</a>
35
- </header>
6
+ {% include_cached header.html %}
36
7
  <main aria-label="Content">
37
8
  <article itemscope itemtype="https://schema.org/WebPage">
38
9
  <header>
39
- <h1 itemprop="headline">{{ page.title | smartify }}</h1>
10
+ <h1 itemprop="headline name">{{ page.title | smartify }}</h1>
40
11
  </header>
41
12
  <div itemprop="mainContentOfPage" itemscope itemtype="https://schema.org/WebPageElement">
42
13
  {{ content }}
data/_layouts/home.html CHANGED
@@ -1,24 +1,35 @@
1
1
  ---
2
2
  layout: default
3
3
  ---
4
- <header>
5
- <h1><a rel="author" href="{{ '/' | relative_url }}">{{ site.title }}</a></h1>
4
+ <header>
5
+ <nav>
6
+ <h1><a rel="author" href="{{ '/' | relative_url }}" accesskey="h" title="Home">{{ site.title }}</a></h1>
7
+ </nav>
6
8
  </header>
7
9
  <main aria-label="Content" itemscope itemtype="https://schema.org/Blog">
10
+ {%- assign content_without_newlines = content | strip_newlines -%}
11
+ {% if content_without_newlines != "" %}
12
+ <section aria-label="Introduction">
8
13
  {{ content }}
14
+ </section>
15
+ {%- endif %}
9
16
 
10
17
  {%- if site.posts.size > 0 -%}
11
18
  {%- if page.list_title %}
12
- <h2>{{ page.list_title | smartify }}</h2>
13
- {%- endif -%}
14
- {%- assign date_format = site.theme_settings.date_format | default: "%Y-%m-%d" %}
15
- <ul>
19
+ <section aria-labelledby="{{ page.list_title | downcase | url_encode }}">
20
+ <h2 id="{{ page.list_title | downcase | url_encode }}">{{ page.list_title | smartify }}</h2>
21
+ {%- else -%}
22
+ <section aria-label="Posts">
23
+ {%- endif -%}
24
+ {%- assign date_format = site.date_format | default: "%Y-%m-%d" %}
25
+ <ul>
16
26
  {%- for post in site.posts %}
17
- <li itemscope itemtype="https://schema.org/BlogPosting">
18
- <time itemprop="datePublished" datetime="{{ post.date | date_to_xmlschema }}">{{ post.date | date: date_format }}</time>
19
- <a href="{{ post.url | relative_url }}" itemprop="headline">{{ post.title | smartify }}</a>
20
- </li>
27
+ <li itemscope itemtype="https://schema.org/BlogPosting">
28
+ <time itemprop="datePublished" datetime="{{ post.date | date_to_xmlschema }}">{{ post.date | date: date_format }}</time>
29
+ <a href="{{ post.url | relative_url }}" itemprop="headline name">{{ post.title | smartify }}</a>
30
+ </li>
21
31
  {%- endfor %}
22
- </ul>
32
+ </ul>
33
+ </section>
23
34
  {%- endif %}
24
35
  </main>
data/_layouts/page.html CHANGED
@@ -1,13 +1,11 @@
1
1
  ---
2
2
  layout: default
3
3
  ---
4
- <header>
5
- <a rel="author" href="{{ '/' | relative_url }}" accesskey="h" title="Home">{{ site.title }}</a>
6
- </header>
4
+ {% include_cached header.html %}
7
5
  <main aria-label="Content">
8
6
  <article itemscope itemtype="https://schema.org/WebPage">
9
7
  <header>
10
- <h1 itemprop="headline">{{ page.title | smartify }}</h1>
8
+ <h1 itemprop="headline name">{{ page.title | smartify }}</h1>
11
9
  </header>
12
10
  <div itemprop="mainContentOfPage" itemscope itemtype="https://schema.org/WebPageElement">
13
11
  {{ content }}
data/_layouts/post.html CHANGED
@@ -1,14 +1,12 @@
1
1
  ---
2
2
  layout: default
3
3
  ---
4
- <header>
5
- <a rel="author" href="{{ '/' | relative_url }}" accesskey="h" title="Home">{{ site.title }}</a>
6
- </header>
4
+ {% include_cached header.html %}
7
5
  <main aria-label="Content">
8
6
  <article itemscope itemtype="https://schema.org/BlogPosting">
9
7
  <header>
10
- <h1 itemprop="headline">{{ page.title | smartify }}</h1>
11
- {%- assign date_format = site.theme_settings.date_format | default: "%Y-%m-%d" %}
8
+ <h1 itemprop="headline name">{{ page.title | smartify }}</h1>
9
+ {%- assign date_format = site.date_format | default: "%Y-%m-%d" %}
12
10
  <time itemprop="datePublished" datetime="{{ page.date | date_to_xmlschema }}">{{ page.date | date: date_format }}</time>
13
11
  </header>
14
12
  <div itemprop="articleBody">
@@ -0,0 +1,25 @@
1
+ {% include head.html %}
2
+ <meta http-equiv="refresh" content="0; url={{ page.redirect.to | absolute_url }}">
3
+ <title>{{ site.theme_settings.redirect_page_title | default: "Redirecting…" | smartify }}</title>
4
+ <link rel="canonical" href="{{ page.redirect.to | absolute_url }}">
5
+ {% include_cached style.html %}
6
+ </head>
7
+ <body>
8
+ {% include_cached header.html %}
9
+ <main aria-label="Content">
10
+ <article itemscope itemtype="https://schema.org/WebPage">
11
+ <header>
12
+ <h1 itemprop="headline name">{{ site.theme_settings.redirect_page_title | default: "Redirecting…" | smartify }}</h1>
13
+ </header>
14
+ <div itemprop="mainContentOfPage" itemscope itemtype="https://schema.org/WebPageElement">
15
+ <p>
16
+ {{ site.theme_settings.redirect_page_from | default: "Redirecting from" | smartify }} {{ page.redirect.from | relative_url }} {{ site.theme_settings.redirect_page_to | default: "to" | smartify }} {{ page.redirect.to | absolute_url }}.
17
+ </p>
18
+ <p>
19
+ <a href="{{ page.redirect.to | absolute_url }}">{{ site.theme_settings.redirect_page_text | default: "Click here if you are not being redirected." | smartify }}</a>
20
+ </p>
21
+ </div>
22
+ </article>
23
+ </main>
24
+ </body>
25
+ </html>
Binary file
Binary file
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-theme-nix
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Nordmeyer
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2024-01-04 00:00:00.000000000 Z
10
+ date: 2025-03-15 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: jekyll
@@ -30,21 +29,90 @@ dependencies:
30
29
  - - "<"
31
30
  - !ruby/object:Gem::Version
32
31
  version: '5.0'
32
+ - !ruby/object:Gem::Dependency
33
+ name: jekyll-feed
34
+ requirement: !ruby/object:Gem::Requirement
35
+ requirements:
36
+ - - "~>"
37
+ - !ruby/object:Gem::Version
38
+ version: '0.17'
39
+ type: :runtime
40
+ prerelease: false
41
+ version_requirements: !ruby/object:Gem::Requirement
42
+ requirements:
43
+ - - "~>"
44
+ - !ruby/object:Gem::Version
45
+ version: '0.17'
33
46
  - !ruby/object:Gem::Dependency
34
47
  name: jekyll-include-cache
35
48
  requirement: !ruby/object:Gem::Requirement
36
49
  requirements:
37
50
  - - "~>"
38
51
  - !ruby/object:Gem::Version
39
- version: 0.2.1
52
+ version: '0.2'
53
+ type: :runtime
54
+ prerelease: false
55
+ version_requirements: !ruby/object:Gem::Requirement
56
+ requirements:
57
+ - - "~>"
58
+ - !ruby/object:Gem::Version
59
+ version: '0.2'
60
+ - !ruby/object:Gem::Dependency
61
+ name: jekyll-redirect-from
62
+ requirement: !ruby/object:Gem::Requirement
63
+ requirements:
64
+ - - "~>"
65
+ - !ruby/object:Gem::Version
66
+ version: '0.16'
67
+ type: :runtime
68
+ prerelease: false
69
+ version_requirements: !ruby/object:Gem::Requirement
70
+ requirements:
71
+ - - "~>"
72
+ - !ruby/object:Gem::Version
73
+ version: '0.16'
74
+ - !ruby/object:Gem::Dependency
75
+ name: jekyll-sitemap
76
+ requirement: !ruby/object:Gem::Requirement
77
+ requirements:
78
+ - - "~>"
79
+ - !ruby/object:Gem::Version
80
+ version: '1.4'
40
81
  type: :runtime
41
82
  prerelease: false
42
83
  version_requirements: !ruby/object:Gem::Requirement
43
84
  requirements:
44
85
  - - "~>"
45
86
  - !ruby/object:Gem::Version
46
- version: 0.2.1
47
- description:
87
+ version: '1.4'
88
+ - !ruby/object:Gem::Dependency
89
+ name: bundler
90
+ requirement: !ruby/object:Gem::Requirement
91
+ requirements:
92
+ - - "~>"
93
+ - !ruby/object:Gem::Version
94
+ version: '2.4'
95
+ type: :development
96
+ prerelease: false
97
+ version_requirements: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - "~>"
100
+ - !ruby/object:Gem::Version
101
+ version: '2.4'
102
+ - !ruby/object:Gem::Dependency
103
+ name: rake
104
+ requirement: !ruby/object:Gem::Requirement
105
+ requirements:
106
+ - - "~>"
107
+ - !ruby/object:Gem::Version
108
+ version: '13.0'
109
+ type: :development
110
+ prerelease: false
111
+ version_requirements: !ruby/object:Gem::Requirement
112
+ requirements:
113
+ - - "~>"
114
+ - !ruby/object:Gem::Version
115
+ version: '13.0'
48
116
  email:
49
117
  - michaelnordmeyer@users.noreply.github.com
50
118
  executables: []
@@ -55,16 +123,22 @@ files:
55
123
  - LICENSE
56
124
  - README.md
57
125
  - _config.yml
126
+ - _includes/head.html
127
+ - _includes/header.html
128
+ - _includes/style.html
58
129
  - _layouts/default.html
59
130
  - _layouts/error.html
60
131
  - _layouts/home.html
61
132
  - _layouts/page.html
62
133
  - _layouts/post.html
134
+ - _layouts/redirect.html
135
+ - assets/icons/icon-dark.webp
136
+ - assets/icons/icon.webp
63
137
  homepage: https://github.com/michaelnordmeyer/jekyll-theme-nix
64
138
  licenses:
65
139
  - MIT
66
- metadata: {}
67
- post_install_message:
140
+ metadata:
141
+ plugin_type: theme
68
142
  rdoc_options: []
69
143
  require_paths:
70
144
  - lib
@@ -72,16 +146,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
72
146
  requirements:
73
147
  - - ">="
74
148
  - !ruby/object:Gem::Version
75
- version: '0'
149
+ version: 2.7.0
76
150
  required_rubygems_version: !ruby/object:Gem::Requirement
77
151
  requirements:
78
152
  - - ">="
79
153
  - !ruby/object:Gem::Version
80
154
  version: '0'
81
155
  requirements: []
82
- rubygems_version: 3.5.3
83
- signing_key:
156
+ rubygems_version: 3.6.3
84
157
  specification_version: 4
85
- summary: A very minimalistic, single-author Jekyll theme with almost default browser
158
+ summary: A very minimalist, single-author Jekyll theme with almost default browser
86
159
  styling, and a dark mode.
87
160
  test_files: []