Compare commits

...

54 Commits

Author SHA1 Message Date
Mark Dumay
56ea9eec47 Merge pull request #363 from gethinode/develop
Add canonifyAssetsURLs option
2023-07-26 17:31:55 +02:00
mark
b845e210b7 Add canonifyAssetsURLs option 2023-07-26 17:13:53 +02:00
Mark Dumay
e8bba05213 Merge pull request #362 from gethinode/main
Sync with main
2023-07-26 15:19:14 +02:00
Mark Dumay
74d0d625c6 Merge pull request #361 from gethinode/permalink
Use relative permalinks by default
2023-07-26 15:04:36 +02:00
mark
9d98a3568c Bump package release 2023-07-26 14:58:01 +02:00
Mark Dumay
dc55571f7a Merge pull request #360 from gethinode/main
Sync with main
2023-07-26 14:55:57 +02:00
Mark Dumay
b7ab9d5690 Merge pull request #359 from gethinode/develop
Refinement
2023-07-26 14:49:44 +02:00
mark
5d20be19a8 Update path for color script 2023-07-26 14:43:15 +02:00
mark
ecae077e2d Use relative permalinks by default 2023-07-26 14:41:55 +02:00
Mark Dumay
132c316ff0 Merge branch 'main' into develop 2023-07-26 14:38:08 +02:00
mark
a3b9081b4d Bump package version 2023-07-26 14:03:25 +02:00
mark
8a689a95de Bump dependencies 2023-07-26 14:02:44 +02:00
mark
9bd04a5b2a Fix complement error for undefined core modules 2023-07-26 09:19:30 +02:00
mark
8dc884f846 Add npm install command 2023-07-26 09:02:31 +02:00
Mark Dumay
4cb558440b Merge pull request #357 from gethinode/hugo-mod-dependencies
Update Hugo module dependencies
2023-07-24 20:01:52 +02:00
mark
0d78918aa4 Set dark mode to disabled by default 2023-07-24 17:18:23 +02:00
mark
ba7ab907ef Fix behavior of critical scripts 2023-07-24 17:18:06 +02:00
markdumay
af557ac054 fix: update Hugo module dependencies 2023-07-23 03:15:51 +00:00
Mark Dumay
9ada0eee80 Merge pull request #355 from gethinode/develop
Fix behavior in default state
2023-07-22 14:57:41 +02:00
Mark Dumay
ae3e20b596 Merge branch 'main' into develop 2023-07-22 14:46:19 +02:00
mark
c49e6f14c1 Bump package version 2023-07-22 14:45:17 +02:00
mark
b4f6b1aa3d Move bootstrap mod check to base template 2023-07-22 14:44:46 +02:00
mark
962549f2ae Allow undefined main menu 2023-07-22 13:13:40 +02:00
Mark Dumay
28601323c4 Update README.md 2023-07-22 07:52:46 +02:00
Mark Dumay
a11ee72174 Merge pull request #354 from gethinode/develop
Bump package version
2023-07-22 06:31:01 +02:00
Mark Dumay
8e91440261 Merge branch 'main' into develop 2023-07-22 06:21:36 +02:00
mark
19879c4ecc Bump package version 2023-07-22 06:21:01 +02:00
Mark Dumay
810dfef311 Merge pull request #353 from gethinode/develop
Fix overflow of syntax highlight
2023-07-22 06:19:56 +02:00
Mark Dumay
c42fcefa73 Merge branch 'main' into develop 2023-07-22 06:12:58 +02:00
mark
a3c417e378 Fix overflow of syntax highlight 2023-07-22 06:10:11 +02:00
Mark Dumay
2bee381906 Merge pull request #352 from gethinode/develop
Enable filename-only in file and docs shortcode
2023-07-21 16:15:34 +02:00
Mark Dumay
244a3f7496 Merge branch 'main' into develop 2023-07-21 16:08:16 +02:00
mark
563b526cea Bump package release 2023-07-21 16:07:09 +02:00
mark
fa7fad67b5 Add full arg to shortcode 2023-07-21 16:06:32 +02:00
Mark Dumay
966906778d Merge pull request #350 from gethinode/develop
Clean-up after modules
2023-07-21 15:48:58 +02:00
mark
135128a5f9 Promote to v0.16 release 2023-07-21 15:27:07 +02:00
Mark Dumay
25663974ce Merge branch 'main' into develop 2023-07-21 15:11:26 +02:00
mark
af5643f98f fix #336 2023-07-21 14:59:18 +02:00
mark
743126d9b9 Remove obsolete files now part of mod-fontawesome 2023-07-21 14:51:27 +02:00
mark
b0187e3a75 Bump dependencies 2023-07-21 14:50:56 +02:00
mark
c7613ab7a8 Add force-check if file exists 2023-07-21 14:47:59 +02:00
mark
2a6a119762 Fix docs typo 2023-07-21 14:47:44 +02:00
mark
b556f4f4ec feat: add file shortcode 2023-07-21 14:47:29 +02:00
mark
9fa95da778 Add katex to safelist for css purge 2023-07-21 11:30:57 +02:00
Mark Dumay
3a07b36447 Merge pull request #349 from gethinode/develop
Improve default mounts
2023-07-21 10:06:53 +02:00
mark
ca5ed02bf9 Bump package release 2023-07-21 09:59:34 +02:00
Mark Dumay
d19321af56 Merge branch 'main' into develop 2023-07-21 09:57:27 +02:00
mark
142e21d792 Adjust default mounts 2023-07-21 09:56:21 +02:00
mark
4c00655584 Add JS and SCSS debugging option 2023-07-21 09:45:21 +02:00
mark
38a2b9ff72 Improve syntax color 2023-07-21 09:32:53 +02:00
mark
efe8837eb3 Add leaflet to purge CSS safelist 2023-07-21 08:55:01 +02:00
mark
130e95ace5 Update mod-flexsearch 2023-07-21 08:38:12 +02:00
mark
e6e38ac7c3 Show I18n warnings when running prod server 2023-07-21 08:37:54 +02:00
mark
3c0a6079af Update purge script to use modules 2023-07-21 08:37:15 +02:00
40 changed files with 385 additions and 117 deletions

View File

@@ -1,5 +1,5 @@
assets/js/critical/color.js
assets/js/analytics.js assets/js/analytics.js
assets/js/color.js
assets/js/flexsearch.js assets/js/flexsearch.js
assets/js/vendor assets/js/vendor
node_modules node_modules

View File

@@ -56,10 +56,11 @@
- [PageSpeed Insights][pagespeed] - [PageSpeed Insights][pagespeed]
- [Mozilla Observatory][observatory] - [Mozilla Observatory][observatory]
Hinode is a clean documentation and blog theme for [Hugo][hugo], an open-source static site generator. Based on the [Bootstrap 5][bootstrap] framework, the rendered site is fast, secure, and responsive. Hinode uses [FlexSearch][flexsearch] to enable full text search across your site. Finally, the theme uses [Node Package Manager][npm] to automate the build process and to keep track of dependencies. Hinode is a clean documentation and blog theme for [Hugo][hugo], an open-source static site generator. Based on the [Bootstrap 5][bootstrap] framework, the rendered site is fast, secure, and responsive. Hinode uses [FlexSearch][flexsearch] to enable full text search across your site. Finally, the theme supports [Node Package Manager][npm] to automate the build process and to keep track of dependencies.
Additional features include: Additional features include:
- Flexible configuration of Hugo modules
- Switching between light mode and dark mode - Switching between light mode and dark mode
- Support for multiple languages - Support for multiple languages
- Reusable Bootstrap components through configurable shortcodes and partials - Reusable Bootstrap components through configurable shortcodes and partials

View File

@@ -1,3 +1,5 @@
{{- if site.Params.main.enableDarkMode -}}
/*! /*!
* Color mode toggler for Bootstrap's docs (https://getbootstrap.com/) * Color mode toggler for Bootstrap's docs (https://getbootstrap.com/)
* Copyright 2011-2022 The Bootstrap Authors * Copyright 2011-2022 The Bootstrap Authors
@@ -68,3 +70,5 @@
}) })
}) })
})() })()
{{- end -}}

View File

@@ -5,10 +5,6 @@
@import "common/variables.scss"; @import "common/variables.scss";
@import "common/icons.scss"; @import "common/icons.scss";
{{ if not (in site.Params.modules.core "bootstrap") }}
{{ errorf "Bootstrap is a required module, please add it to 'modules.core' in your site parameters" }}
{{ end }}
// Import Bootstrap configuration (mounted by core Bootstrap module) // Import Bootstrap configuration (mounted by core Bootstrap module)
@import "bootstrap.scss"; @import "bootstrap.scss";

View File

@@ -6,9 +6,9 @@
/* LineLink */ .chroma .lnlinks { outline: none; text-decoration: none; color: inherit } /* LineLink */ .chroma .lnlinks { outline: none; text-decoration: none; color: inherit }
/* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; } /* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; }
/* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; } /* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; }
/* LineHighlight */ .chroma .hl { background-color: #ffffcc } /* LineHighlight */ .chroma .hl { background-color: #b8b800 }
/* LineNumbersTable */ .chroma .lnt { white-space: pre; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #64686c } /* LineNumbersTable */ .chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #64686c }
/* LineNumbers */ .chroma .ln { white-space: pre; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #6e7681 } /* LineNumbers */ .chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #6e7681 }
/* Line */ .chroma .line { display: flex; } /* Line */ .chroma .line { display: flex; }
/* Keyword */ .chroma .k { color: #ff7b72 } /* Keyword */ .chroma .k { color: #ff7b72 }
/* KeywordConstant */ .chroma .kc { color: #79c0ff } /* KeywordConstant */ .chroma .kc { color: #79c0ff }

View File

@@ -7,8 +7,8 @@
/* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; } /* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; }
/* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; } /* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; }
/* LineHighlight */ .chroma .hl { background-color: #ffffcc } /* LineHighlight */ .chroma .hl { background-color: #ffffcc }
/* LineNumbersTable */ .chroma .lnt { white-space: pre; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } /* LineNumbersTable */ .chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
/* LineNumbers */ .chroma .ln { white-space: pre; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } /* LineNumbers */ .chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f }
/* Line */ .chroma .line { display: flex; } /* Line */ .chroma .line { display: flex; }
/* Keyword */ .chroma .k { color: #000000; font-weight: bold } /* Keyword */ .chroma .k { color: #000000; font-weight: bold }
/* KeywordConstant */ .chroma .kc { color: #000000; font-weight: bold } /* KeywordConstant */ .chroma .kc { color: #000000; font-weight: bold }

View File

@@ -10,6 +10,7 @@
.syntax-highlight { .syntax-highlight {
background-color: var(--bs-light) if($enable-important-utilities, !important, null); background-color: var(--bs-light) if($enable-important-utilities, !important, null);
overflow-x: auto;
} }
.preview-background { .preview-background {
@@ -29,6 +30,7 @@
.syntax-highlight { .syntax-highlight {
background-color: var(--bs-tertiary-bg) if($enable-important-utilities, !important, null); background-color: var(--bs-tertiary-bg) if($enable-important-utilities, !important, null);
overflow-x: auto;
} }
.bg, .bg,

View File

@@ -87,15 +87,24 @@ home = ["HTML", "RSS", "REDIR"]
extended = true extended = true
min = "0.110.0" min = "0.110.0"
max = "" max = ""
[[module.mounts]]
source = "archetypes"
target = "archetypes"
[[module.mounts]] [[module.mounts]]
source = "assets" source = "assets"
target = "assets" target = "assets"
[[module.mounts]]
source = "i18n"
target = "i18n"
[[module.mounts]]
source = "layouts"
target = "layouts"
[[module.mounts]] [[module.mounts]]
source = "static" source = "static"
target = "static" target = "static"
[[module.mounts]] [[module.mounts]]
source = "static/fonts" source = "netlify.toml"
target = "static/fonts" target = "assets/config/netlify.toml"
# toml-docs-start modules # toml-docs-start modules
[[module.imports]] [[module.imports]]
path = "github.com/gethinode/mod-bootstrap" path = "github.com/gethinode/mod-bootstrap"

View File

@@ -4,6 +4,7 @@
description = "Hinode is a clean documentation and blog theme for your Hugo site based on Bootstrap 5." description = "Hinode is a clean documentation and blog theme for your Hugo site based on Bootstrap 5."
enableDarkMode = true enableDarkMode = true
modes = ["light", "dark"] modes = ["light", "dark"]
canonifyAssetsURLs = false
# toml-docs-end main # toml-docs-end main
# toml-docs-start modules # toml-docs-start modules
@@ -14,6 +15,12 @@
disableTemplate = ["katex"] disableTemplate = ["katex"]
# toml-docs-end modules # toml-docs-end modules
# toml-docs-start debugging
[debugging]
showJS = false
showSCSS = false
# toml-docs-end debugging
# toml-docs-start docs # toml-docs-start docs
[docs] [docs]
github = "https://github.com/gethinode/hinode" github = "https://github.com/gethinode/hinode"

View File

@@ -21,12 +21,15 @@ const purgecss = require('@fullhuman/postcss-purgecss')({
'./assets/scss/components/_syntax-light.scss', './assets/scss/components/_syntax-light.scss',
'./assets/scss/theme/fonts.scss', './assets/scss/theme/fonts.scss',
'./assets/scss/theme/theme.scss', './assets/scss/theme/theme.scss',
'./node_modules/bootstrap/scss/_carousel.scss', './_vendor/github.com/gethinode/mod-flexsearch/assets/scss/modules/flexsearch/flexsearch.scss',
'./node_modules/bootstrap/scss/_dropdown.scss', './_vendor/github.com/gethinode/mod-katex/dist/katex.scss',
'./node_modules/bootstrap/scss/_reboot.scss', './_vendor/github.com/gethinode/mod-leaflet/dist/leaflet.scss',
'./node_modules/bootstrap/scss/_tooltip.scss', './_vendor/github.com/twbs/bootstrap/scss/_carousel.scss',
'./node_modules/bootstrap/scss/_transitions.scss', './_vendor/github.com/twbs/bootstrap/scss/_dropdown.scss',
'./node_modules/bootstrap/scss/_utilities.scss' './_vendor/github.com/twbs/bootstrap/scss/_reboot.scss',
'./_vendor/github.com/twbs/bootstrap/scss/_tooltip.scss',
'./_vendor/github.com/twbs/bootstrap/scss/_transitions.scss',
'./_vendor/github.com/twbs/bootstrap/scss/_utilities.scss'
]) ])
] ]
}) })

6
go.mod
View File

@@ -4,8 +4,8 @@ go 1.19
require ( require (
github.com/gethinode/mod-bootstrap v1.1.0 // indirect github.com/gethinode/mod-bootstrap v1.1.0 // indirect
github.com/gethinode/mod-flexsearch v1.1.0 // indirect github.com/gethinode/mod-flexsearch v1.1.4 // indirect
github.com/gethinode/mod-fontawesome v1.2.0 // indirect github.com/gethinode/mod-fontawesome v1.2.1 // indirect
github.com/gethinode/mod-katex v1.0.2 // indirect github.com/gethinode/mod-katex v1.0.2 // indirect
github.com/gethinode/mod-leaflet v0.3.1 // indirect github.com/gethinode/mod-leaflet v0.3.3 // indirect
) )

12
go.sum
View File

@@ -6,12 +6,22 @@ github.com/gethinode/mod-flexsearch v1.0.1 h1:FJkRsUzSnQTXl3MWCigT4E6vfff870UWTn
github.com/gethinode/mod-flexsearch v1.0.1/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4= github.com/gethinode/mod-flexsearch v1.0.1/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4=
github.com/gethinode/mod-flexsearch v1.1.0 h1:7BCMyQDlYlskNXuazt8Jg/jg9WREexu2xVkYqThkAX4= github.com/gethinode/mod-flexsearch v1.1.0 h1:7BCMyQDlYlskNXuazt8Jg/jg9WREexu2xVkYqThkAX4=
github.com/gethinode/mod-flexsearch v1.1.0/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4= github.com/gethinode/mod-flexsearch v1.1.0/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4=
github.com/gethinode/mod-flexsearch v1.1.1 h1:zHypfKR/rWPAwqNXvo09Pp3vGqU4w3r7d2VtMudIzkI=
github.com/gethinode/mod-flexsearch v1.1.1/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4=
github.com/gethinode/mod-flexsearch v1.1.2 h1:vA/jHxLq9xxkYGS9cmAoLNIkEBW+iLVCcQ8qKyEa+R4=
github.com/gethinode/mod-flexsearch v1.1.2/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4=
github.com/gethinode/mod-flexsearch v1.1.3 h1:lzmSvnJL6ABjp03avYzSvJJ7hw01CpHap1JGUbDIELg=
github.com/gethinode/mod-flexsearch v1.1.3/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4=
github.com/gethinode/mod-flexsearch v1.1.4 h1:dJvwBxYlLe/VGlctLn8k89STJ5toATIjNnXIlNeanOY=
github.com/gethinode/mod-flexsearch v1.1.4/go.mod h1:TXbGbWsvmhBdsTzRt887mcpFfr4ORpzG3+h/l4W3YM4=
github.com/gethinode/mod-fontawesome v1.0.2 h1:ZSK6D20/w4y5GnfYfTBB58uHD0ChIfkpKfRGwioS9rg= github.com/gethinode/mod-fontawesome v1.0.2 h1:ZSK6D20/w4y5GnfYfTBB58uHD0ChIfkpKfRGwioS9rg=
github.com/gethinode/mod-fontawesome v1.0.2/go.mod h1:Ki1qkWEOiF0hQpCgWeZRw+HkpL6nd1DxKFptU0O2feI= github.com/gethinode/mod-fontawesome v1.0.2/go.mod h1:Ki1qkWEOiF0hQpCgWeZRw+HkpL6nd1DxKFptU0O2feI=
github.com/gethinode/mod-fontawesome v1.1.0 h1:rsDzUI+3ZlS/do2ff3ne8/z3KwHeysmuA+WsXlumXXk= github.com/gethinode/mod-fontawesome v1.1.0 h1:rsDzUI+3ZlS/do2ff3ne8/z3KwHeysmuA+WsXlumXXk=
github.com/gethinode/mod-fontawesome v1.1.0/go.mod h1:Ki1qkWEOiF0hQpCgWeZRw+HkpL6nd1DxKFptU0O2feI= github.com/gethinode/mod-fontawesome v1.1.0/go.mod h1:Ki1qkWEOiF0hQpCgWeZRw+HkpL6nd1DxKFptU0O2feI=
github.com/gethinode/mod-fontawesome v1.2.0 h1:2nWYEjpUKu6IJ6kOh2WDlDUqRQ/dUGw6mJWIdMTA3O0= github.com/gethinode/mod-fontawesome v1.2.0 h1:2nWYEjpUKu6IJ6kOh2WDlDUqRQ/dUGw6mJWIdMTA3O0=
github.com/gethinode/mod-fontawesome v1.2.0/go.mod h1:Ki1qkWEOiF0hQpCgWeZRw+HkpL6nd1DxKFptU0O2feI= github.com/gethinode/mod-fontawesome v1.2.0/go.mod h1:Ki1qkWEOiF0hQpCgWeZRw+HkpL6nd1DxKFptU0O2feI=
github.com/gethinode/mod-fontawesome v1.2.1 h1:k7z5ZRsNxCohZjlZm8jVAzmTPk17c6xMYBAjAXHs13I=
github.com/gethinode/mod-fontawesome v1.2.1/go.mod h1:Ki1qkWEOiF0hQpCgWeZRw+HkpL6nd1DxKFptU0O2feI=
github.com/gethinode/mod-katex v1.0.0 h1:me/3dIIZBkfk1mRIFt8QiAGYwYDoSG5bc2hHRtIutFc= github.com/gethinode/mod-katex v1.0.0 h1:me/3dIIZBkfk1mRIFt8QiAGYwYDoSG5bc2hHRtIutFc=
github.com/gethinode/mod-katex v1.0.0/go.mod h1:byAfpI3wuqNJIooTGVEGc1cjBhhCy4+CcK1H6495MYg= github.com/gethinode/mod-katex v1.0.0/go.mod h1:byAfpI3wuqNJIooTGVEGc1cjBhhCy4+CcK1H6495MYg=
github.com/gethinode/mod-katex v1.0.1 h1:809QUztxmKgMNchU+v03iMO7Ma+ISc3ZzhXYauc21rs= github.com/gethinode/mod-katex v1.0.1 h1:809QUztxmKgMNchU+v03iMO7Ma+ISc3ZzhXYauc21rs=
@@ -22,3 +32,5 @@ github.com/gethinode/mod-leaflet v0.2.3 h1:QQI4h+IH0jZ7fx4q0um2YIEiYBoW3OAfW8qHz
github.com/gethinode/mod-leaflet v0.2.3/go.mod h1:uGggt87x4Fw7wBoJpSiUvNkYg+s/Ujne7klAX2rxMRk= github.com/gethinode/mod-leaflet v0.2.3/go.mod h1:uGggt87x4Fw7wBoJpSiUvNkYg+s/Ujne7klAX2rxMRk=
github.com/gethinode/mod-leaflet v0.3.1 h1:H5MaOa+BB1KuVw7abTqfIn/SNzzRsAyx/WQoSe+2Ykc= github.com/gethinode/mod-leaflet v0.3.1 h1:H5MaOa+BB1KuVw7abTqfIn/SNzzRsAyx/WQoSe+2Ykc=
github.com/gethinode/mod-leaflet v0.3.1/go.mod h1:uGggt87x4Fw7wBoJpSiUvNkYg+s/Ujne7klAX2rxMRk= github.com/gethinode/mod-leaflet v0.3.1/go.mod h1:uGggt87x4Fw7wBoJpSiUvNkYg+s/Ujne7klAX2rxMRk=
github.com/gethinode/mod-leaflet v0.3.3 h1:isnjja6VRFvVWBatYSouh46TXSJg2C4/E2BQTrQw+yI=
github.com/gethinode/mod-leaflet v0.3.3/go.mod h1:uGggt87x4Fw7wBoJpSiUvNkYg+s/Ujne7klAX2rxMRk=

View File

@@ -37,6 +37,8 @@
translation: "Wörter" translation: "Wörter"
- id: copyright - id: copyright
translation: "Copyright" translation: "Copyright"
- id: rights
translation: "Alle Rechte vorbehalten"
- id: photoBy - id: photoBy
translation: "Foto von" translation: "Foto von"
- id: photoOn - id: photoOn

View File

@@ -45,6 +45,8 @@
translation: "words" translation: "words"
- id: copyright - id: copyright
translation: "Copyright" translation: "Copyright"
- id: rights
translation: "All rights reserved"
- id: photoBy - id: photoBy
translation: "Photo by" translation: "Photo by"
- id: photoOn - id: photoOn
@@ -138,7 +140,7 @@
- id: show - id: show
translation: "Show" translation: "Show"
- id: comments - id: comments
translation: "comments" translation: "Comments"
# Related posts # Related posts
- id: seeAlso - id: seeAlso

View File

@@ -37,6 +37,8 @@
translation: "woorden" translation: "woorden"
- id: copyright - id: copyright
translation: "Copyright" translation: "Copyright"
- id: rights
translation: "Alle rechten voorbehouden"
- id: photoBy - id: photoBy
translation: "Foto van" translation: "Foto van"
- id: photoOn - id: photoOn
@@ -129,7 +131,7 @@
- id: show - id: show
translation: "Tonen" translation: "Tonen"
- id: comments - id: comments
translation: "commentaar" translation: "Reacties"
# Related posts # Related posts
- id: seeAlso - id: seeAlso

View File

@@ -12,6 +12,10 @@
{{- end -}} {{- end -}}
{{- end -}} {{- end -}}
{{- if and .IsPage (not (in .Site.Params.modules.core "bootstrap")) -}}
{{- errorf "Bootstrap is a required module, please add it to 'modules.core' in your site parameters" -}}
{{- end -}}
<!doctype html> <!doctype html>
<html lang="{{ .Site.Language.Lang }}" class="no-js"> <html lang="{{ .Site.Language.Lang }}" class="no-js">
<head> <head>
@@ -19,9 +23,7 @@
</head> </head>
<body> <body>
{{- if site.Params.main.enableDarkMode -}} {{- partial "footer/scripts.html" (dict "filename" "js/critical.bundle.js" "match" "js/critical/**.js" "header" true "page" .) -}}
{{- partial "footer/scripts.html" (dict "filename" "js/critical.bundle.js" "match" "js/critical/**.js" "header" true "page" .) -}}
{{- end -}}
<div class="d-flex flex-column min-vh-100{{ if and .IsHome .Site.Params.home.style }} {{ .Site.Params.home.style }}{{ end }}"> <div class="d-flex flex-column min-vh-100{{ if and .IsHome .Site.Params.home.style }} {{ .Site.Params.home.style }}{{ end }}">
<div class="{{ if .Site.Params.navigation.fixed }}mb-4{{ end }}"> <div class="{{ if .Site.Params.navigation.fixed }}mb-4{{ end }}">
{{- partial "assets/navbar.html" (dict {{- partial "assets/navbar.html" (dict

View File

@@ -67,7 +67,7 @@
{{ with .NextInSection -}} {{ with .NextInSection -}}
{{ $next := . -}} {{ $next := . -}}
{{ with .OutputFormats.Get "html" -}} {{ with .OutputFormats.Get "html" -}}
<a class="next" href="{{ $next.Permalink }}"><i class="fas fa-arrow-left"></i> {{ $next.Title }}</a> <a class="next" href="{{ $next.RelPermalink }}"><i class="fas fa-arrow-left"></i> {{ $next.Title }}</a>
{{- end -}} {{- end -}}
{{ end -}} {{ end -}}
</div> </div>
@@ -75,7 +75,7 @@
{{ with .PrevInSection -}} {{ with .PrevInSection -}}
{{ $prev := . -}} {{ $prev := . -}}
{{ with .OutputFormats.Get "html" -}} {{ with .OutputFormats.Get "html" -}}
<a class="previous" href="{{ $prev.Permalink }}">{{ $prev.Title }} <i class="fas fa-arrow-right"></i></a> <a class="previous" href="{{ $prev.RelPermalink }}">{{ $prev.Title }} <i class="fas fa-arrow-right"></i></a>
{{- end -}} {{- end -}}
{{ end -}} {{ end -}}
</div> </div>

View File

@@ -7,10 +7,10 @@
{{ $square150 := .Resize "150x150 CatmullRom" }} {{ $square150 := .Resize "150x150 CatmullRom" }}
{{ $wide310 := .Fill "310x150 CatmullRom" }} {{ $wide310 := .Fill "310x150 CatmullRom" }}
{{ $square310 := .Resize "310x310 CatmullRom" }} {{ $square310 := .Resize "310x310 CatmullRom" }}
<square70x70logo src="{{ $square70.Permalink }}" /> <square70x70logo src="{{ $square70.RelPermalink }}" />
<square150x150logo src="{{ $square150.Permalink }}" /> <square150x150logo src="{{ $square150.RelPermalink }}" />
<wide310x150logo src="{{ $wide310.Permalink }}" /> <wide310x150logo src="{{ $wide310.RelPermalink }}" />
<square310x310logo src="{{ $square310.Permalink }}" /> <square310x310logo src="{{ $square310.RelPermalink }}" />
{{ end }} {{ end }}
<TileColor>#000000</TileColor> <TileColor>#000000</TileColor>
</tile> </tile>

View File

@@ -3,7 +3,7 @@
{{- range $index, $item := .Page.Ancestors.Reverse -}} {{- range $index, $item := .Page.Ancestors.Reverse -}}
{{- $title := .Title -}} {{- $title := .Title -}}
{{- if .IsHome }}{{ $title = T "home" }}{{ end -}} {{- if .IsHome }}{{ $title = T "home" }}{{ end -}}
{{- $address := or .Permalink (.Params.Redirect | absLangURL) -}} {{- $address := or .RelPermalink (.Params.Redirect | relLangURL) -}}
{{ if $address }} {{ if $address }}
<li class="breadcrumb-item"><a href="{{ $address }}">{{ $title }}</a></li> <li class="breadcrumb-item"><a href="{{ $address }}">{{ $title }}</a></li>
{{ else }} {{ else }}

View File

@@ -107,12 +107,12 @@
"orientation" $orientation "orientation" $orientation
) -}} ) -}}
{{- if $element.Permalink -}} {{- if $element.RelPermalink -}}
{{- $params = merge $params (dict "path" $element.File.Path) -}} {{- $params = merge $params (dict "path" $element.File.Path) -}}
{{- else -}} {{- else -}}
{{- $params = merge $params (dict {{- $params = merge $params (dict
"title" $element.Title "title" $element.Title
"href" $element.Permalink "href" $element.RelPermalink
"description" (or $element.Description $element.Content) "description" (or $element.Description $element.Content)
"thumbnail" $element.Params.thumbnail "thumbnail" $element.Params.thumbnail
"icon" $element.Params.icon "icon" $element.Params.icon

View File

@@ -111,7 +111,7 @@
{{- with $page -}} {{- with $page -}}
{{- if not $title }}{{ $title = .Title }}{{ end -}} {{- if not $title }}{{ $title = .Title }}{{ end -}}
{{- if not $href }}{{ $href = .Permalink }}{{ end -}} {{- if not $href }}{{ $href = .RelPermalink }}{{ end -}}
{{- if not $description }}{{ $description = .Description }}{{ end -}} {{- if not $description }}{{ $description = .Description }}{{ end -}}
{{- if not $thumbnail }}{{ $thumbnail = .Params.thumbnail }}{{ end -}} {{- if not $thumbnail }}{{ $thumbnail = .Params.thumbnail }}{{ end -}}
{{- if not $icon }}{{ $icon = .Params.icon }}{{ end -}} {{- if not $icon }}{{ $icon = .Params.icon }}{{ end -}}

View File

@@ -1,6 +1,6 @@
{{- $params := .Site.Params.comments -}} {{- $params := .Site.Params.comments -}}
{{- with $params -}} {{- with $params -}}
<h2>Comments</h2> <h2>{{ T "comments" }}</h2>
<script src="https://utteranc.es/client.js" <script src="https://utteranc.es/client.js"
repo="{{ $params.repo }}" repo="{{ $params.repo }}"
issue-term="{{ default "pathname" $params.issueTerm }}" issue-term="{{ default "pathname" $params.issueTerm }}"

View File

@@ -1,16 +0,0 @@
{{- $icon := .icon -}}
{{- if not $icon -}}
{{- errorf "partial [assets/icon.html] - Expected value for param 'icon'" -}}
{{- end -}}
{{- $icon_class := split $icon " " -}}
{{- $attr := delimit (after 1 $icon_class) " " -}}
{{- if eq (index $icon_class 0) "fas" -}}
<i class="fa-solid fa-{{ $attr}}"></i>
{{- else if eq (index $icon_class 0) "fab" -}}
<i class="fa-brands fa-{{ $attr }}"></i>
{{- else if eq (index $icon_class 0) "fa" -}}
<i class="fa-regular fa-{{ $attr }}"></i>
{{- else -}}
{{- errorf "partial [assets/icon.html] - Unrecognized icon class: %s" $icon_class -}}
{{- end -}}

View File

@@ -15,6 +15,7 @@
--> -->
{{- $validRatios := slice "1x1" "4x3" "16x9" "21x9" -}} {{- $validRatios := slice "1x1" "4x3" "16x9" "21x9" -}}
{{- $absoluteURL := site.Params.main.canonifyAssetsURLs | default false -}}
{{- $ratio := .ratio -}} {{- $ratio := .ratio -}}
{{- $url := .url -}} {{- $url := .url -}}
{{- $mode := false -}} {{- $mode := false -}}
@@ -68,6 +69,7 @@
<!-- Generate a image set of type webp --> <!-- Generate a image set of type webp -->
{{- define "partials/image-scaled.html " -}} {{- define "partials/image-scaled.html " -}}
{{- $absoluteURL := site.Params.main.canonifyAssetsURLs | default false -}}
{{- $img := .img -}} {{- $img := .img -}}
{{- $ratio := .ratio -}} {{- $ratio := .ratio -}}
{{- $imgset := "" -}} {{- $imgset := "" -}}
@@ -98,7 +100,11 @@
{{- $scaled = $img.Fit (printf "%s webp" $dim) -}} {{- $scaled = $img.Fit (printf "%s webp" $dim) -}}
{{- end -}} {{- end -}}
{{- $scaled = $scaled | resources.Copy (replace $img.RelPermalink $clean (printf "-%s.webp" $dim)) -}} {{- $scaled = $scaled | resources.Copy (replace $img.RelPermalink $clean (printf "-%s.webp" $dim)) -}}
{{- $imgset = printf "%s, %s %sw" $imgset $scaled.Permalink (index $widths $index) -}} {{- if $absoluteURL -}}
{{- $imgset = printf "%s, %s %sw" $imgset $scaled.Permalink (index $widths $index) -}}
{{- else -}}
{{- $imgset = printf "%s, %s %sw" $imgset $scaled.RelPermalink (index $widths $index) -}}
{{- end -}}
{{- end -}} {{- end -}}
{{- $imgset = strings.TrimPrefix ", " $imgset -}} {{- $imgset = strings.TrimPrefix ", " $imgset -}}
{{- end -}} {{- end -}}
@@ -108,6 +114,7 @@
<!-- Define the img with optional caption --> <!-- Define the img with optional caption -->
{{- define "partials/image-definition.html" -}} {{- define "partials/image-definition.html" -}}
{{- $absoluteURL := site.Params.main.canonifyAssetsURLs | default false -}}
{{- $ratio := .ratio -}} {{- $ratio := .ratio -}}
{{- $url := .url -}} {{- $url := .url -}}
{{- $outerClass := .outerClass -}} {{- $outerClass := .outerClass -}}
@@ -125,7 +132,11 @@
{{- $img := partial "utilities/GetImage.html" (dict "url" $url) -}} {{- $img := partial "utilities/GetImage.html" (dict "url" $url) -}}
{{- if $img -}} {{- if $img -}}
{{- $fallback := partial "partials/image-default.html" (dict "img" $img "ratio" $ratio) -}} {{- $fallback := partial "partials/image-default.html" (dict "img" $img "ratio" $ratio) -}}
{{- $fallbackURL = $fallback.RelPermalink -}} {{- if $absoluteURL -}}
{{- $fallbackURL = $fallback.Permalink -}}
{{- else -}}
{{- $fallbackURL = $fallback.RelPermalink -}}
{{- end -}}
{{- $imgset = partial "partials/image-scaled.html " (dict "img" $img "ratio" $ratio) -}} {{- $imgset = partial "partials/image-scaled.html " (dict "img" $img "ratio" $ratio) -}}
{{- end -}} {{- end -}}
{{- end -}} {{- end -}}
@@ -145,7 +156,7 @@
srcset="{{ . }}" srcset="{{ . }}"
sizes="100vw" sizes="100vw"
{{- end }} {{- end }}
src="{{ absURL $fallbackURL }}" src="{{ $fallbackURL }}"
alt="{{ $title }}"> alt="{{ $title }}">
</div> </div>
{{- if $caption -}} {{- if $caption -}}

View File

@@ -93,6 +93,7 @@
</li> </li>
{{- end -}} {{- end -}}
{{- $absoluteURL := site.Params.main.canonifyAssetsURLs | default false -}}
{{- $supportedFlags := slice "true" "false" -}} {{- $supportedFlags := slice "true" "false" -}}
{{- $id := printf "navbar-collapse-%d" 0 -}} {{- $id := printf "navbar-collapse-%d" 0 -}}
@@ -105,11 +106,14 @@
{{- errorf "partial [assets/navbar.html] - Missing value for param 'page'" -}} {{- errorf "partial [assets/navbar.html] - Missing value for param 'page'" -}}
{{- end -}} {{- end -}}
{{- $menuName := "main" }} {{- $defaultMenu := "main" }}
{{- with .menus }}{{ $menuName = .}}{{ end -}} {{- $menuName := $defaultMenu }}
{{- with .menus }}{{ $menuName = . }}{{ end -}}
{{- $menus := index site.Menus $menuName -}} {{- $menus := index site.Menus $menuName -}}
{{- if or (ne (printf "%T" $menus) "navigation.Menu") (ne (index $menus 0).Menu $menuName) -}} {{- if or (ne (printf "%T" $menus) "navigation.Menu") (ne (index $menus 0).Menu $menuName) -}}
{{- errorf "partial [assets/navbar.html] - Invalid value for param 'menus': %s" $menuName -}} {{- if ne $menuName $defaultMenu }}
{{- errorf "partial [assets/navbar.html] - Invalid value for param 'menus': %s" $menuName -}}
{{- end -}}
{{- end -}} {{- end -}}
{{- $size := "md" -}} {{- $size := "md" -}}
@@ -147,7 +151,7 @@
{{- end -}} {{- end -}}
{{- end -}} {{- end -}}
{{- $enableDarkMode := default true site.Params.main.enableDarkMode -}} {{- $enableDarkMode := default false site.Params.main.enableDarkMode -}}
{{- with .mode -}} {{- with .mode -}}
{{- $darkModeParam := . -}} {{- $darkModeParam := . -}}
{{- if in $supportedFlags $darkModeParam -}} {{- if in $supportedFlags $darkModeParam -}}
@@ -202,7 +206,7 @@
<!-- Insert the brand logo or name --> <!-- Insert the brand logo or name -->
<a class="navbar-brand mx-auto" href="{{ site.Home.RelPermalink }}"> <a class="navbar-brand mx-auto" href="{{ site.Home.RelPermalink }}">
{{- if $logo -}} {{- if $logo -}}
<img src="{{ $logo }}" alt="{{ $title }} logo" height="30"> <img src="{{if $absoluteURL }}{{ absURL $logo }}{{ else }}{{ $logo }}{{ end }}" alt="{{ $title }} logo" height="30">
{{- else -}} {{- else -}}
<span class="fw-bold">{{ $title }}</span> <span class="fw-bold">{{ $title }}</span>
{{- end -}} {{- end -}}
@@ -238,7 +242,7 @@
{{- end -}} {{- end -}}
<!-- Insert divider if applicable --> <!-- Insert divider if applicable -->
{{- if or $enableLanguage $enableVersions -}} {{- if and $menus (or $enableLanguage $enableVersions) -}}
<li class="nav-item py-2 py-md-1 col-12 col-md-auto d-none d-{{ $size }}-block"> <li class="nav-item py-2 py-md-1 col-12 col-md-auto d-none d-{{ $size }}-block">
<div class="vr d-none d-md-flex h-100 mx-md-2"></div> <div class="vr d-none d-md-flex h-100 mx-md-2"></div>
</li> </li>
@@ -258,7 +262,7 @@
<ul class="dropdown-menu dropdown-menu-end "> <ul class="dropdown-menu dropdown-menu-end ">
{{- if $page.IsTranslated -}} {{- if $page.IsTranslated -}}
{{- range $page.AllTranslations -}} {{- range $page.AllTranslations -}}
<li><a class="dropdown-item {{ if eq .Language.Lang $currentLang }}active{{ end }}" href="{{ .Permalink }}">{{ .Language.LanguageName }}</a></li> <li><a class="dropdown-item {{ if eq .Language.Lang $currentLang }}active{{ end }}" href="{{ .RelPermalink }}">{{ .Language.LanguageName }}</a></li>
{{- end -}} {{- end -}}
{{- else -}} {{- else -}}
{{- range site.Languages -}} {{- range site.Languages -}}

View File

@@ -49,7 +49,7 @@
{{- with $page -}} {{- with $page -}}
{{- if not $title }}{{ $title = .Title }}{{ end -}} {{- if not $title }}{{ $title = .Title }}{{ end -}}
{{- if not $href }}{{ $href = .Permalink }}{{ end -}} {{- if not $href }}{{ $href = .RelPermalink }}{{ end -}}
{{- if not $content }}{{ $content = .Content }}{{ end -}} {{- if not $content }}{{ $content = .Content }}{{ end -}}
{{- if not $thumbnail }}{{ $thumbnail = .Params.thumbnail }}{{ end -}} {{- if not $thumbnail }}{{ $thumbnail = .Params.thumbnail }}{{ end -}}
{{- end -}} {{- end -}}

View File

@@ -10,7 +10,7 @@
{{ T "shareLink" }} {{ T "shareLink" }}
{{- range $index, $item := $list -}} {{- range $index, $item := $list -}}
{{- $url := $item.url -}} {{- $url := $item.url -}}
{{- $url = replace $url "{url}" $page.Permalink -}} {{- $url = replace $url "{url}" $page.RelPermalink -}}
{{- $url = replace $url "{title}" (urlquery $page.Title) -}} {{- $url = replace $url "{title}" (urlquery $page.Title) -}}
{{- $url = $url | safeURL -}} {{- $url = $url | safeURL -}}
{{- $target := "" -}} {{- $target := "" -}}

View File

@@ -1,7 +1,7 @@
<footer class="container-fluid text-center p-3"> <footer class="container-fluid text-center p-3">
<div class="container-xxl text-center"> <div class="container-xxl text-center">
<small class="text-secondary"> <small class="text-secondary">
{{- $copyright := printf "%s © %s %s All rights reserved." (i18n "copyright") (dateFormat "2006" now) .Site.Title }} {{- $copyright := printf "%s © %s %s %s." (T "copyright") (dateFormat "2006" now) .Site.Title (T "rights") }}
{{ cond (gt (len .Site.Copyright) 0) .Site.Copyright $copyright }} {{ cond (gt (len .Site.Copyright) 0) .Site.Copyright $copyright }}
{{ .Site.Params.footer.license | safeHTML }} {{ .Site.Params.footer.license | safeHTML }}
</small> </small>

View File

@@ -1,3 +1,4 @@
{{- $absoluteURL := site.Params.main.canonifyAssetsURLs | default false -}}
{{- $filename := .filename | default "js/main.bundle.js" -}} {{- $filename := .filename | default "js/main.bundle.js" -}}
{{- $match := .match | default "{js/*.js,js/vendor/**.js}" -}} {{- $match := .match | default "{js/*.js,js/vendor/**.js}" -}}
{{- $page := .page -}} {{- $page := .page -}}
@@ -10,7 +11,7 @@
{{- $modules = site.Params.modules.core -}} {{- $modules = site.Params.modules.core -}}
{{- end -}} {{- end -}}
{{- $bundle := partial "utilities/bundle" (dict "match" $match "filename" $filename "modules" $modules "basepath" "js/modules" "all" true) -}} {{- $bundle := partial "utilities/bundle" (dict "match" $match "filename" $filename "modules" $modules "basepath" "js/modules" "all" true "debugging" site.Params.debugging.showJS) -}}
{{- $js := $bundle -}} {{- $js := $bundle -}}
{{- if not $skipTemplate -}} {{- if not $skipTemplate -}}
{{- $js = $bundle | resources.ExecuteAsTemplate $filename $page -}} {{- $js = $bundle | resources.ExecuteAsTemplate $filename $page -}}
@@ -23,9 +24,11 @@
{{- end }} {{- end }}
{{- end -}} {{- end -}}
{{- if not hugo.IsProduction -}} {{- if gt (len $js.Content) 0 -}}
<script src="{{ $js.Permalink }}"></script> {{- if not hugo.IsProduction -}}
{{ else -}} <script src="{{ if $absoluteURL }}{{ $js.Permalink }}{{ else }}{{ $js.RelPermalink }}{{ end }}"></script>
{{ $js = $js | minify | fingerprint -}} {{ else -}}
<script src="{{ $js.Permalink }}" integrity="{{ $js.Data.Integrity }}" crossorigin="anonymous"></script> {{ $js = $js | minify | fingerprint -}}
<script src="{{ if $absoluteURL }}{{ $js.Permalink }}{{ else }}{{ $js.RelPermalink }}{{ end }}" integrity="{{ $js.Data.Integrity }}" crossorigin="anonymous"></script>
{{ end -}}
{{ end -}} {{ end -}}

View File

@@ -1,10 +1,11 @@
<!-- Source: https://davelage.com/posts/hugo-favicons/ --> <!-- Source: https://davelage.com/posts/hugo-favicons/ -->
{{- $absoluteURL := site.Params.main.canonifyAssetsURLs | default false -}}
{{ if .Site.Params.favicon.logo -}} {{ if .Site.Params.favicon.logo -}}
{{ $favicon := resources.Get .Site.Params.favicon.logo -}} {{ $favicon := resources.Get .Site.Params.favicon.logo -}}
{{ range $i := .Site.Params.favicon.sizes -}} {{ range $i := .Site.Params.favicon.sizes -}}
{{ $image := $favicon.Resize (printf "%dx%d CatmullRom" $i $i) -}} {{ $image := $favicon.Resize (printf "%dx%d CatmullRom" $i $i) -}}
<link rel="icon" type="image/png" sizes="{{$i}}x{{$i}}" href="{{ $image.Permalink }}"> <link rel="icon" type="image/png" sizes="{{$i}}x{{$i}}" href="{{ if $absoluteURL }}{{ $image.Permalink }}{{ else }}{{ $image.RelPermalink }}{{ end }}">
{{ end -}} {{ end -}}
{{ $image := $favicon.Resize "180x CatmullRom" -}} {{ $image := $favicon.Resize "180x CatmullRom" -}}
<link rel="apple-touch-icon" sizes="180x180" href="{{ $image.Permalink }}"> <link rel="apple-touch-icon" sizes="180x180" href="{{ if $absoluteURL }}{{ $image.Permalink }}{{ else }}{{ $image.RelPermalink }}{{ end }}">
{{ end -}} {{ end -}}

View File

@@ -11,7 +11,7 @@
Variable names are converted from kebab case to snake case to make them compatible with Hugo's variable naming Variable names are converted from kebab case to snake case to make them compatible with Hugo's variable naming
convention. For example, the css variable '--accordion-icon-active-color' is available as convention. For example, the css variable '--accordion-icon-active-color' is available as
''.accordion_icon_active_color' within the Hugo template. The processed svg files are published to the "icons" '.accordion_icon_active_color' within the Hugo template. The processed svg files are published to the "icons"
folder. folder.
The partial supports the following arguments: The partial supports the following arguments:

View File

@@ -1,3 +1,4 @@
{{- $absoluteURL := site.Params.main.canonifyAssetsURLs | default false -}}
{{- $source := .source | default "scss/app.scss" -}} {{- $source := .source | default "scss/app.scss" -}}
{{- $target := .target | default "css/main.css" -}} {{- $target := .target | default "css/main.css" -}}
{{- $page := .page -}} {{- $page := .page -}}
@@ -6,7 +7,7 @@
{{- $modules := "" -}} {{- $modules := "" -}}
{{ if $core }} {{ if $core }}
{{- if reflect.IsSlice site.Params.modules.excludeSCSS -}} {{- if reflect.IsSlice site.Params.modules.excludeSCSS -}}
{{- $modules = complement site.Params.modules.excludeSCSS site.Params.modules.core -}} {{- $modules = complement site.Params.modules.excludeSCSS (or site.Params.modules.core slice) -}}
{{ else }} {{ else }}
{{- $modules = site.Params.modules.core -}} {{- $modules = site.Params.modules.core -}}
{{ end }} {{ end }}
@@ -29,17 +30,8 @@
"import-fonts" (printf "%t" (not (hasPrefix (lower site.Params.style.themeFontPath) "http"))) "import-fonts" (printf "%t" (not (hasPrefix (lower site.Params.style.themeFontPath) "http")))
-}} -}}
<!-- TODO: remove debug statement -->
{{ $match := "scss/**.scss" }}
{{ $files := sort (resources.Match $match) "Key" "asc" }}
{{ warnf "Processing pattern: %s" $match}}
{{- range $index, $file := $files -}}
{{/*- warnf " - Processing file: %s" $file.Key */}}
{{- end -}}
{{- $options := (dict "transpiler" "libsass" "targetPath" $target "enableSourceMap" (not hugo.IsProduction) "vars" $vars) -}} {{- $options := (dict "transpiler" "libsass" "targetPath" $target "enableSourceMap" (not hugo.IsProduction) "vars" $vars) -}}
{{- $bundle := partial "utilities/bundle" (dict "match" $source "filename" (printf "scss/bundle-%d.scss" now.UnixNano) "modules" $modules "basepath" "scss") -}} {{- $bundle := partial "utilities/bundle" (dict "match" $source "filename" (printf "scss/bundle-%d.scss" now.UnixNano) "modules" $modules "basepath" "scss" "debugging" site.Params.debugging.showSCSS) -}}
{{/* warnf "Bundle: %s" $bundle.Content */}}
{{- $css := $bundle | resources.ExecuteAsTemplate $target . | toCSS $options -}} {{- $css := $bundle | resources.ExecuteAsTemplate $target . | toCSS $options -}}
@@ -52,8 +44,8 @@
{{- end -}} {{- end -}}
{{- if not hugo.IsProduction -}} {{- if not hugo.IsProduction -}}
<link rel="stylesheet" href="{{ $css.Permalink }}"> <link rel="stylesheet" href="{{ if $absoluteURL }}{{ $css.Permalink }}{{ else }}{{ $css.RelPermalink }}{{ end }}">
{{- else -}} {{- else -}}
{{- $css = $css | fingerprint | resources.PostProcess -}} {{- $css = $css | fingerprint | resources.PostProcess -}}
<link rel="stylesheet" href="{{ $css.Permalink }}" integrity="{{ $css.Data.Integrity }}" crossorigin="anonymous"> <link rel="stylesheet" href="{{ if $absoluteURL }}{{ $css.Permalink }}{{ else }}{{ $css.RelPermalink }}{{ end }}" integrity="{{ $css.Data.Integrity }}" crossorigin="anonymous">
{{- end -}} {{- end -}}

View File

@@ -18,6 +18,8 @@
{{- errorf "partial [assets/bundle.html] - Cannot derive file extension of match pattern: %s" $match -}} {{- errorf "partial [assets/bundle.html] - Cannot derive file extension of match pattern: %s" $match -}}
{{- end -}} {{- end -}}
{{- $debugging := .debugging | default false -}}
{{- if $modules -}} {{- if $modules -}}
{{- $match = trim $match "{}" -}} {{- $match = trim $match "{}" -}}
{{- $matches := slice $match -}} {{- $matches := slice $match -}}
@@ -46,10 +48,11 @@
{{ $sorted = $sorted | append $file.resource }} {{ $sorted = $sorted | append $file.resource }}
{{- end -}} {{- end -}}
<!-- TODO: remove temp debug statement --> {{- if $debugging -}}
{{ warnf "Processing pattern: %s" $match}} {{ warnf "Processing pattern: %s" $match}}
{{- range $index, $file := $sorted -}} {{- range $index, $file := $sorted -}}
{{- warnf " - Processing file: %s" $file }} {{- warnf " - Processing file: %s" $file }}
{{- end -}}
{{- end -}} {{- end -}}
{{/* warnf "FILES: %s" $sorted */}} {{/* warnf "FILES: %s" $sorted */}}

View File

@@ -44,13 +44,23 @@
{{ errorf "Invalid value for param 'show': %s" $showParam -}} {{ errorf "Invalid value for param 'show': %s" $showParam -}}
{{ end -}} {{ end -}}
{{ $fullParam := "true" -}}
{{ $full := true -}}
{{ with .Get "full" }}{{ $fullParam = . }}{{ end -}}
{{ if in $supportedFlags $fullParam -}}
{{ if eq $fullParam "true" }}{{ $full = true }}{{ else }}{{ $full = false }}{{ end -}}
{{ else -}}
{{ errorf "Invalid value for param 'full': %s" $fullParam -}}
{{ end -}}
{{- /* If any parameters are missing, print an error and exit */ -}} {{- /* If any parameters are missing, print an error and exit */ -}}
{{- if or (not $name) (not $file) -}} {{- if or (not $name) (not $file) -}}
{{- errorf "%s: %q: Missing required parameters! Got: name=%q file=%q!" .Position .Name $name $file -}} {{- errorf "%s: %q: Missing required parameters! Got: name=%q file=%q!" .Position .Name $name $file -}}
{{- else -}} {{- else -}}
{{- $regex := printf `%s((?:.|\n)*)%s` $capture_start $capture_end -}} {{- /* Force-check if the file exists */ -}}
{{ $tmp := os.Stat $file }}
{{- $regex := printf `%s((?:.|\n)*)%s` $capture_start $capture_end -}}
{{- $match := findRE $regex (readFile $file) -}} {{- $match := findRE $regex (readFile $file) -}}
{{- $match = index $match 0 -}} {{- $match = index $match 0 -}}
@@ -70,7 +80,7 @@
data-bs-target=".multi-{{ $id }}" data-bs-target=".multi-{{ $id }}"
aria-expanded="false" aria-expanded="false"
aria-controls="body-{{ $id }} footer-{{ $id }}"> aria-controls="body-{{ $id }} footer-{{ $id }}">
<small>{{ strings.TrimPrefix $basePath $file }}</small> <small>{{ if $full }}{{ strings.TrimPrefix $basePath $file }}{{ else }}{{ path.Base $file }}{{ end }}</small>
</a> </a>
</li> </li>
</ul> </ul>

View File

@@ -1,5 +0,0 @@
{{- if not (.Get 0) -}}
{{- errorf "Expected icon name: %s" .Position -}}
{{- else -}}
{{- partial "assets/icon.html" (dict "icon" (printf "fa %s" (delimit .Params " "))) }}
{{- end -}}

View File

@@ -1,5 +0,0 @@
{{- if not (.Get 0) -}}
{{- errorf "Expected icon name: %s" .Position -}}
{{- else -}}
{{- partial "assets/icon.html" (dict "icon" (printf "fab %s" (delimit .Params " "))) }}
{{- end -}}

View File

@@ -1,5 +0,0 @@
{{- if not (.Get 0) -}}
{{- errorf "Expected icon name: %s" .Position -}}
{{- else -}}
{{- partial "assets/icon.html" (dict "icon" (printf "fas %s" (delimit .Params " "))) }}
{{- end -}}

View File

@@ -0,0 +1,68 @@
{{- /*
Source: https://github.com/twbs/bootstrap/blob/main/site/layouts/shortcodes/scss-docs.html
Usage: `file path="path/to/filename" lang="lang" show="true" full="true"`
Prints the full content of any given file supported by the Chroma syntax highlighter.
*/ -}}
{{- $basePath := .Site.Params.docs.basePath -}}
{{- $file := .Get "path" }}
{{- if hasPrefix $file "./" -}}
{{- $file = path.Clean $file -}}
{{- else -}}
{{- $file = path.Join $basePath (path.Clean $file) -}}
{{- end -}}
{{- $extension := strings.TrimLeft "." (path.Ext $file) }}
{{- $lang := .Get "lang" | default $extension -}}
{{- $id := printf "docs-collapse-%d" .Ordinal -}}
{{ $supportedFlags := slice "true" "false" -}}
{{ $showParam := "true" -}}
{{ $show := true -}}
{{ with .Get "show" }}{{ $showParam = . }}{{ end -}}
{{ if in $supportedFlags $showParam -}}
{{ if eq $showParam "true" }}{{ $show = true }}{{ else }}{{ $show = false }}{{ end -}}
{{ else -}}
{{ errorf "Invalid value for param 'show': %s" $showParam -}}
{{ end -}}
{{ $fullParam := "true" -}}
{{ $full := true -}}
{{ with .Get "full" }}{{ $fullParam = . }}{{ end -}}
{{ if in $supportedFlags $fullParam -}}
{{ if eq $fullParam "true" }}{{ $full = true }}{{ else }}{{ $full = false }}{{ end -}}
{{ else -}}
{{ errorf "Invalid value for param 'full': %s" $fullParam -}}
{{ end -}}
{{- /* If any parameters are missing, print an error and exit */ -}}
{{- if not $file -}}
{{- errorf "%s: %q: Missing required parameters! Got: path=%q!" .Position .Name $file -}}
{{- else -}}
{{- /* Force-check if the file exists */ -}}
{{ $tmp := os.Stat $file }}
{{- $content := readFile $file -}}
<ul class="nav nav-tabs">
<li class="nav-item">
<a class="nav-link active font-monospace"
href="#body-{{ $id }}"
aria-current="page"
data-bs-toggle="collapse"
data-bs-target=".multi-{{ $id }}"
aria-expanded="false"
aria-controls="body-{{ $id }} footer-{{ $id }}">
<small>{{ if $full }}{{ strings.TrimPrefix $basePath $file }}{{ else }}{{ path.Base $file }}{{ end }}</small>
</a>
</li>
</ul>
<div class="border-start border-end border-bottom mb-3">
<div class="collapse multi-{{ $id }}{{ if $show }} show{{ end }} syntax-highlight" id="body-{{ $id }}">
{{- highlight (trim $content "\r\n") $lang "" -}}
</div>
<div class="collapse multi-{{ $id }}{{ if not $show }} show{{ end }} p-3" id="footer-{{ $id }}"><i>...</i></div>
</div>
{{- end -}}

166
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{ {
"name": "@gethinode/hinode", "name": "@gethinode/hinode",
"version": "0.16.0-beta", "version": "0.16.5",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "@gethinode/hinode", "name": "@gethinode/hinode",
"version": "0.16.0-beta", "version": "0.16.5",
"license": "MIT", "license": "MIT",
"devDependencies": { "devDependencies": {
"@fortawesome/fontawesome-free": "^6.4.0", "@fortawesome/fontawesome-free": "^6.4.0",
@@ -23,6 +23,7 @@
"markdownlint-cli2": "^0.8.1", "markdownlint-cli2": "^0.8.1",
"postcss-cli": "^10.1.0", "postcss-cli": "^10.1.0",
"purgecss-whitelister": "^2.4.0", "purgecss-whitelister": "^2.4.0",
"replace-in-files-cli": "^2.2.0",
"rimraf": "^5.0.0", "rimraf": "^5.0.0",
"shx": "^0.3.4", "shx": "^0.3.4",
"stylelint": "^15.6.0", "stylelint": "^15.6.0",
@@ -3552,6 +3553,12 @@
"url": "https://github.com/sponsors/ljharb" "url": "https://github.com/sponsors/ljharb"
} }
}, },
"node_modules/is-typedarray": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz",
"integrity": "sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==",
"dev": true
},
"node_modules/is-weakref": { "node_modules/is-weakref": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz",
@@ -5545,6 +5552,84 @@
"url": "https://github.com/sponsors/ljharb" "url": "https://github.com/sponsors/ljharb"
} }
}, },
"node_modules/replace-in-files-cli": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/replace-in-files-cli/-/replace-in-files-cli-2.2.0.tgz",
"integrity": "sha512-EI2Psum9Ay9y2IDWx36+hOvn+BX6LdQ8HXZ06L32obGrJb9w7YDMTywIQgysOXwQo5MsORtIA4l/g25r2Cp1gA==",
"dev": true,
"dependencies": {
"escape-string-regexp": "^5.0.0",
"globby": "^12.0.2",
"meow": "^10.1.1",
"normalize-path": "^3.0.0",
"write-file-atomic": "^3.0.3"
},
"bin": {
"replace-in-files": "cli.js"
},
"engines": {
"node": "^12.20.0 || ^14.13.1 || >=16.0.0"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/replace-in-files-cli/node_modules/array-union": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/array-union/-/array-union-3.0.1.tgz",
"integrity": "sha512-1OvF9IbWwaeiM9VhzYXVQacMibxpXOMYVNIvMtKRyX9SImBXpKcFr8XvFDeEslCyuH/t6KRt7HEO94AlP8Iatw==",
"dev": true,
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/replace-in-files-cli/node_modules/escape-string-regexp": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz",
"integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==",
"dev": true,
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/replace-in-files-cli/node_modules/globby": {
"version": "12.2.0",
"resolved": "https://registry.npmjs.org/globby/-/globby-12.2.0.tgz",
"integrity": "sha512-wiSuFQLZ+urS9x2gGPl1H5drc5twabmm4m2gTR27XDFyjUHJUNsS8o/2aKyIF6IoBaR630atdher0XJ5g6OMmA==",
"dev": true,
"dependencies": {
"array-union": "^3.0.1",
"dir-glob": "^3.0.1",
"fast-glob": "^3.2.7",
"ignore": "^5.1.9",
"merge2": "^1.4.1",
"slash": "^4.0.0"
},
"engines": {
"node": "^12.20.0 || ^14.13.1 || >=16.0.0"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/replace-in-files-cli/node_modules/write-file-atomic": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.3.tgz",
"integrity": "sha512-AvHcyZ5JnSfq3ioSyjrBkH9yW4m7Ayk8/9My/DD9onKeu/94fwrMocemO2QAJFAlnnDN+ZDS+ZjAR5ua1/PV/Q==",
"dev": true,
"dependencies": {
"imurmurhash": "^0.1.4",
"is-typedarray": "^1.0.0",
"signal-exit": "^3.0.2",
"typedarray-to-buffer": "^3.1.5"
}
},
"node_modules/require-directory": { "node_modules/require-directory": {
"version": "2.1.1", "version": "2.1.1",
"resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
@@ -6643,6 +6728,15 @@
"url": "https://github.com/sponsors/sindresorhus" "url": "https://github.com/sponsors/sindresorhus"
} }
}, },
"node_modules/typedarray-to-buffer": {
"version": "3.1.5",
"resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz",
"integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==",
"dev": true,
"dependencies": {
"is-typedarray": "^1.0.0"
}
},
"node_modules/uc.micro": { "node_modules/uc.micro": {
"version": "1.0.6", "version": "1.0.6",
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz", "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",
@@ -9381,6 +9475,12 @@
"has-symbols": "^1.0.2" "has-symbols": "^1.0.2"
} }
}, },
"is-typedarray": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz",
"integrity": "sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==",
"dev": true
},
"is-weakref": { "is-weakref": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz",
@@ -10710,6 +10810,59 @@
"functions-have-names": "^1.2.2" "functions-have-names": "^1.2.2"
} }
}, },
"replace-in-files-cli": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/replace-in-files-cli/-/replace-in-files-cli-2.2.0.tgz",
"integrity": "sha512-EI2Psum9Ay9y2IDWx36+hOvn+BX6LdQ8HXZ06L32obGrJb9w7YDMTywIQgysOXwQo5MsORtIA4l/g25r2Cp1gA==",
"dev": true,
"requires": {
"escape-string-regexp": "^5.0.0",
"globby": "^12.0.2",
"meow": "^10.1.1",
"normalize-path": "^3.0.0",
"write-file-atomic": "^3.0.3"
},
"dependencies": {
"array-union": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/array-union/-/array-union-3.0.1.tgz",
"integrity": "sha512-1OvF9IbWwaeiM9VhzYXVQacMibxpXOMYVNIvMtKRyX9SImBXpKcFr8XvFDeEslCyuH/t6KRt7HEO94AlP8Iatw==",
"dev": true
},
"escape-string-regexp": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz",
"integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==",
"dev": true
},
"globby": {
"version": "12.2.0",
"resolved": "https://registry.npmjs.org/globby/-/globby-12.2.0.tgz",
"integrity": "sha512-wiSuFQLZ+urS9x2gGPl1H5drc5twabmm4m2gTR27XDFyjUHJUNsS8o/2aKyIF6IoBaR630atdher0XJ5g6OMmA==",
"dev": true,
"requires": {
"array-union": "^3.0.1",
"dir-glob": "^3.0.1",
"fast-glob": "^3.2.7",
"ignore": "^5.1.9",
"merge2": "^1.4.1",
"slash": "^4.0.0"
}
},
"write-file-atomic": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.3.tgz",
"integrity": "sha512-AvHcyZ5JnSfq3ioSyjrBkH9yW4m7Ayk8/9My/DD9onKeu/94fwrMocemO2QAJFAlnnDN+ZDS+ZjAR5ua1/PV/Q==",
"dev": true,
"requires": {
"imurmurhash": "^0.1.4",
"is-typedarray": "^1.0.0",
"signal-exit": "^3.0.2",
"typedarray-to-buffer": "^3.1.5"
}
}
}
},
"require-directory": { "require-directory": {
"version": "2.1.1", "version": "2.1.1",
"resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
@@ -11498,6 +11651,15 @@
"integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==",
"dev": true "dev": true
}, },
"typedarray-to-buffer": {
"version": "3.1.5",
"resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz",
"integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==",
"dev": true,
"requires": {
"is-typedarray": "^1.0.0"
}
},
"uc.micro": { "uc.micro": {
"version": "1.0.6", "version": "1.0.6",
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz", "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",

View File

@@ -1,6 +1,6 @@
{ {
"name": "@gethinode/hinode", "name": "@gethinode/hinode",
"version": "0.16.0-beta", "version": "0.16.5",
"description": "Hinode is a clean documentation and blog theme for Hugo, an open-source static site generator", "description": "Hinode is a clean documentation and blog theme for Hugo, an open-source static site generator",
"keywords": [ "keywords": [
"hugo", "hugo",
@@ -19,8 +19,8 @@
"scripts": { "scripts": {
"prestart": "npm run clean && npm run mod:vendor", "prestart": "npm run clean && npm run mod:vendor",
"start": "hugo server --bind=0.0.0.0 --disableFastRender", "start": "hugo server --bind=0.0.0.0 --disableFastRender",
"start:prod": "hugo server --bind=0.0.0.0 --disableFastRender -e production", "start:prod": "hugo server --bind=0.0.0.0 --disableFastRender --printI18nWarnings -e production",
"prebuild": "npm run clean", "prebuild": "npm run clean && npm run -s mod:install",
"build": "hugo --gc --minify", "build": "hugo --gc --minify",
"build:debug": "hugo -e debug --debug", "build:debug": "hugo -e debug --debug",
"build:preview": "npm run build -D -F", "build:preview": "npm run build -D -F",
@@ -32,6 +32,7 @@
"lint:markdown": "markdownlint-cli2 \"*.md\" \"content/**/*.md\"", "lint:markdown": "markdownlint-cli2 \"*.md\" \"content/**/*.md\"",
"lint:markdown-fix": "markdownlint-cli2-fix \"*.md\" \"content/**/*.md\"", "lint:markdown-fix": "markdownlint-cli2-fix \"*.md\" \"content/**/*.md\"",
"mod:clean": "hugo mod clean", "mod:clean": "hugo mod clean",
"mod:install": "hugo mod get ./... && npm run -s mod:vendor && npm run -s mod:tidy",
"mod:update": "hugo mod get -u ./... && npm run -s mod:vendor && npm run -s mod:tidy", "mod:update": "hugo mod get -u ./... && npm run -s mod:vendor && npm run -s mod:tidy",
"mod:tidy": "hugo mod tidy", "mod:tidy": "hugo mod tidy",
"mod:vendor": "rimraf _vendor && hugo mod vendor", "mod:vendor": "rimraf _vendor && hugo mod vendor",
@@ -39,10 +40,11 @@
"env": "hugo env", "env": "hugo env",
"precheck": "npm version", "precheck": "npm version",
"check": "hugo version", "check": "hugo version",
"create:syntax": "npm run -s create:syntax-light & npm run -s create:syntax-dark", "create:syntax": "npm run -s create:syntax-light & npm run -s create:syntax-dark && npm run -s update:syntax-dark",
"create:syntax-light": "hugo gen chromastyles --style=github > ./assets/scss/components/_syntax-light.scss", "create:syntax-light": "hugo gen chromastyles --style=github > ./assets/scss/components/_syntax-light.scss",
"create:syntax-dark": "hugo gen chromastyles --style=github-dark > ./assets/scss/components/_syntax-dark.scss", "create:syntax-dark": "hugo gen chromastyles --style=github-dark > ./assets/scss/components/_syntax-dark.scss",
"upgrade": "npx npm-check-updates -u" "update:syntax-dark": "replace-in-files --string=\"#ffffcc\" --replacement=\"#b8b800\" ./assets/scss/components/_syntax-dark.scss",
"upgrade": "npx npm-check-updates -u && mod:update"
}, },
"repository": { "repository": {
"type": "git", "type": "git",
@@ -69,6 +71,7 @@
"markdownlint-cli2": "^0.8.1", "markdownlint-cli2": "^0.8.1",
"postcss-cli": "^10.1.0", "postcss-cli": "^10.1.0",
"purgecss-whitelister": "^2.4.0", "purgecss-whitelister": "^2.4.0",
"replace-in-files-cli": "^2.2.0",
"rimraf": "^5.0.0", "rimraf": "^5.0.0",
"shx": "^0.3.4", "shx": "^0.3.4",
"stylelint": "^15.6.0", "stylelint": "^15.6.0",