mirror of
https://github.com/gethinode/hinode.git
synced 2025-10-08 18:44:24 +00:00
Compare commits
16 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
9ada0eee80 | ||
![]() |
ae3e20b596 | ||
![]() |
c49e6f14c1 | ||
![]() |
b4f6b1aa3d | ||
![]() |
962549f2ae | ||
![]() |
28601323c4 | ||
![]() |
a11ee72174 | ||
![]() |
8e91440261 | ||
![]() |
19879c4ecc | ||
![]() |
810dfef311 | ||
![]() |
c42fcefa73 | ||
![]() |
a3c417e378 | ||
![]() |
2bee381906 | ||
![]() |
244a3f7496 | ||
![]() |
563b526cea | ||
![]() |
fa7fad67b5 |
@@ -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
|
||||||
|
@@ -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";
|
||||||
|
|
||||||
|
@@ -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,
|
||||||
|
@@ -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>
|
||||||
|
@@ -105,11 +105,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" -}}
|
||||||
@@ -238,7 +241,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>
|
||||||
|
@@ -44,6 +44,14 @@
|
|||||||
{{ 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) -}}
|
||||||
@@ -72,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>
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
{{- /*
|
{{- /*
|
||||||
Source: https://github.com/twbs/bootstrap/blob/main/site/layouts/shortcodes/scss-docs.html
|
Source: https://github.com/twbs/bootstrap/blob/main/site/layouts/shortcodes/scss-docs.html
|
||||||
|
|
||||||
Usage: `file path="path/to/filename" lang="lang" show="true"`
|
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.
|
Prints the full content of any given file supported by the Chroma syntax highlighter.
|
||||||
*/ -}}
|
*/ -}}
|
||||||
@@ -28,6 +28,15 @@
|
|||||||
{{ 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 not $file -}}
|
{{- if not $file -}}
|
||||||
{{- errorf "%s: %q: Missing required parameters! Got: path=%q!" .Position .Name $file -}}
|
{{- errorf "%s: %q: Missing required parameters! Got: path=%q!" .Position .Name $file -}}
|
||||||
@@ -46,7 +55,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>
|
||||||
|
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "@gethinode/hinode",
|
"name": "@gethinode/hinode",
|
||||||
"version": "0.16.0",
|
"version": "0.16.3",
|
||||||
"lockfileVersion": 2,
|
"lockfileVersion": 2,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "@gethinode/hinode",
|
"name": "@gethinode/hinode",
|
||||||
"version": "0.16.0",
|
"version": "0.16.3",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@fortawesome/fontawesome-free": "^6.4.0",
|
"@fortawesome/fontawesome-free": "^6.4.0",
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@gethinode/hinode",
|
"name": "@gethinode/hinode",
|
||||||
"version": "0.16.0",
|
"version": "0.16.3",
|
||||||
"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",
|
||||||
|
Reference in New Issue
Block a user