mirror of
https://github.com/gethinode/hinode.git
synced 2025-10-12 12:33:20 +00:00
Compare commits
17 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
6283970443 | ||
![]() |
200ca109b1 | ||
![]() |
acded37e83 | ||
![]() |
782a40e1e8 | ||
![]() |
7b2bb803b3 | ||
![]() |
0e0561b081 | ||
![]() |
e3cf2e1337 | ||
![]() |
c18316250b | ||
![]() |
29a8666d7d | ||
![]() |
431125e46c | ||
![]() |
dae6541185 | ||
![]() |
41d0edb6c1 | ||
![]() |
5d9d11c388 | ||
![]() |
3b26c04bdd | ||
![]() |
01d41ae38e | ||
![]() |
22d5859432 | ||
![]() |
551b185dd9 |
@@ -1,7 +1,6 @@
|
|||||||
# toml-docs-start main
|
# toml-docs-start main
|
||||||
title = "Hinode"
|
title = "Hinode"
|
||||||
copyright = "Copyright © 2024 Mark Dumay."
|
copyright = "Copyright © 2024 Mark Dumay."
|
||||||
paginate = 9
|
|
||||||
enableGitInfo = true
|
enableGitInfo = true
|
||||||
# toml-docs-end main
|
# toml-docs-end main
|
||||||
|
|
||||||
@@ -49,6 +48,9 @@ home = ["HTML", "RSS", "REDIR"]
|
|||||||
[taxonomies]
|
[taxonomies]
|
||||||
tag = 'tags'
|
tag = 'tags'
|
||||||
|
|
||||||
|
[pagination]
|
||||||
|
pagerSize = 9
|
||||||
|
|
||||||
[privacy]
|
[privacy]
|
||||||
[privacy.vimeo]
|
[privacy.vimeo]
|
||||||
disabled = false
|
disabled = false
|
||||||
@@ -95,7 +97,7 @@ home = ["HTML", "RSS", "REDIR"]
|
|||||||
[module]
|
[module]
|
||||||
[module.hugoVersion]
|
[module.hugoVersion]
|
||||||
extended = true
|
extended = true
|
||||||
min = "0.132.0"
|
min = "0.134.0"
|
||||||
max = ""
|
max = ""
|
||||||
[[module.mounts]]
|
[[module.mounts]]
|
||||||
source = "archetypes"
|
source = "archetypes"
|
||||||
|
@@ -112,7 +112,8 @@ arguments:
|
|||||||
title:
|
title:
|
||||||
type:
|
type:
|
||||||
- string
|
- string
|
||||||
- 'hstring.RenderedString'
|
- hstring.RenderedString
|
||||||
|
- hstring.HTML
|
||||||
optional: true
|
optional: true
|
||||||
comment: Alternate text of the image.
|
comment: Alternate text of the image.
|
||||||
caption:
|
caption:
|
||||||
|
@@ -72,6 +72,7 @@ arguments:
|
|||||||
- string
|
- string
|
||||||
- template.HTML
|
- template.HTML
|
||||||
- hstring.RenderedString
|
- hstring.RenderedString
|
||||||
|
- hstring.HTML
|
||||||
optional: true
|
optional: true
|
||||||
group: partial
|
group: partial
|
||||||
comment: Link description.
|
comment: Link description.
|
||||||
|
@@ -1,7 +1,6 @@
|
|||||||
resourcedir = '../resources/'
|
resourcedir = '../resources/'
|
||||||
title = "Hinode"
|
title = "Hinode"
|
||||||
copyright = "Copyright © 2024 Mark Dumay."
|
copyright = "Copyright © 2024 Mark Dumay."
|
||||||
paginate = 9
|
|
||||||
enableGitInfo = true
|
enableGitInfo = true
|
||||||
|
|
||||||
# additional settings
|
# additional settings
|
||||||
@@ -39,6 +38,9 @@ home = ["HTML", "RSS", "REDIR"]
|
|||||||
[taxonomies]
|
[taxonomies]
|
||||||
tag = 'tags'
|
tag = 'tags'
|
||||||
|
|
||||||
|
[pagination]
|
||||||
|
pagerSize = 9
|
||||||
|
|
||||||
[privacy]
|
[privacy]
|
||||||
[privacy.vimeo]
|
[privacy.vimeo]
|
||||||
disabled = false
|
disabled = false
|
||||||
|
2
go.mod
2
go.mod
@@ -11,7 +11,7 @@ require (
|
|||||||
github.com/gethinode/mod-leaflet v1.1.1 // indirect
|
github.com/gethinode/mod-leaflet v1.1.1 // indirect
|
||||||
github.com/gethinode/mod-lottie v1.5.7 // indirect
|
github.com/gethinode/mod-lottie v1.5.7 // indirect
|
||||||
github.com/gethinode/mod-simple-datatables v1.0.8 // indirect
|
github.com/gethinode/mod-simple-datatables v1.0.8 // indirect
|
||||||
github.com/gethinode/mod-utils/v2 v2.5.0 // indirect
|
github.com/gethinode/mod-utils/v2 v2.5.2 // indirect
|
||||||
github.com/nextapps-de/flexsearch v0.0.0-20240501124520-961c3ae84a87 // indirect
|
github.com/nextapps-de/flexsearch v0.0.0-20240501124520-961c3ae84a87 // indirect
|
||||||
github.com/twbs/bootstrap v5.3.3+incompatible // indirect
|
github.com/twbs/bootstrap v5.3.3+incompatible // indirect
|
||||||
)
|
)
|
||||||
|
2
go.sum
2
go.sum
@@ -268,6 +268,8 @@ github.com/gethinode/mod-utils/v2 v2.4.0 h1:mmG4hWaeA4krAg933pibH+TrjFmPHkAi/DUb
|
|||||||
github.com/gethinode/mod-utils/v2 v2.4.0/go.mod h1:GTYeknoLujNjfDxI+V9Dcug26CYJSTJ0B/U2dagw9oY=
|
github.com/gethinode/mod-utils/v2 v2.4.0/go.mod h1:GTYeknoLujNjfDxI+V9Dcug26CYJSTJ0B/U2dagw9oY=
|
||||||
github.com/gethinode/mod-utils/v2 v2.5.0 h1:9QboNU9KTpmJDS9JBjxavbknLVBJilocqo5KhC2FdME=
|
github.com/gethinode/mod-utils/v2 v2.5.0 h1:9QboNU9KTpmJDS9JBjxavbknLVBJilocqo5KhC2FdME=
|
||||||
github.com/gethinode/mod-utils/v2 v2.5.0/go.mod h1:GTYeknoLujNjfDxI+V9Dcug26CYJSTJ0B/U2dagw9oY=
|
github.com/gethinode/mod-utils/v2 v2.5.0/go.mod h1:GTYeknoLujNjfDxI+V9Dcug26CYJSTJ0B/U2dagw9oY=
|
||||||
|
github.com/gethinode/mod-utils/v2 v2.5.2 h1:URGTpJo0dN4/oF2yL6o2d2pkcSlG1F0hgIF9UqpIs/E=
|
||||||
|
github.com/gethinode/mod-utils/v2 v2.5.2/go.mod h1:GTYeknoLujNjfDxI+V9Dcug26CYJSTJ0B/U2dagw9oY=
|
||||||
github.com/nextapps-de/flexsearch v0.0.0-20230711092928-1243fd883ec3 h1:H/qVR5O4BXjRjD+5PZB+r4ug2BSJ2Of4RtwOntd+OKo=
|
github.com/nextapps-de/flexsearch v0.0.0-20230711092928-1243fd883ec3 h1:H/qVR5O4BXjRjD+5PZB+r4ug2BSJ2Of4RtwOntd+OKo=
|
||||||
github.com/nextapps-de/flexsearch v0.0.0-20230711092928-1243fd883ec3/go.mod h1:5GdMfPAXzbA2gXBqTjC6l27kioSYzHlqDMh0+wyx7sU=
|
github.com/nextapps-de/flexsearch v0.0.0-20230711092928-1243fd883ec3/go.mod h1:5GdMfPAXzbA2gXBqTjC6l27kioSYzHlqDMh0+wyx7sU=
|
||||||
github.com/nextapps-de/flexsearch v0.0.0-20240108021025-afd75f742f22 h1:re7L8FxbXQpnX8BgzkdUnDpsUmloGNyLmiy2ZCln8pg=
|
github.com/nextapps-de/flexsearch v0.0.0-20240108021025-afd75f742f22 h1:re7L8FxbXQpnX8BgzkdUnDpsUmloGNyLmiy2ZCln8pg=
|
||||||
|
@@ -2,11 +2,16 @@
|
|||||||
"htmlElements": {
|
"htmlElements": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"a",
|
"a",
|
||||||
|
"blockquote",
|
||||||
"body",
|
"body",
|
||||||
"button",
|
"button",
|
||||||
|
"code",
|
||||||
"div",
|
"div",
|
||||||
|
"em",
|
||||||
"footer",
|
"footer",
|
||||||
"form",
|
"form",
|
||||||
|
"h2",
|
||||||
|
"h3",
|
||||||
"head",
|
"head",
|
||||||
"html",
|
"html",
|
||||||
"img",
|
"img",
|
||||||
@@ -20,13 +25,20 @@
|
|||||||
"ol",
|
"ol",
|
||||||
"p",
|
"p",
|
||||||
"path",
|
"path",
|
||||||
|
"pre",
|
||||||
"script",
|
"script",
|
||||||
"small",
|
"small",
|
||||||
"span",
|
"span",
|
||||||
"strong",
|
"strong",
|
||||||
"svg",
|
"svg",
|
||||||
"symbol",
|
"symbol",
|
||||||
|
"table",
|
||||||
|
"tbody",
|
||||||
|
"td",
|
||||||
|
"th",
|
||||||
|
"thead",
|
||||||
"title",
|
"title",
|
||||||
|
"tr",
|
||||||
"ul",
|
"ul",
|
||||||
"use"
|
"use"
|
||||||
],
|
],
|
||||||
@@ -35,17 +47,29 @@
|
|||||||
"align-items-center",
|
"align-items-center",
|
||||||
"align-self-center",
|
"align-self-center",
|
||||||
"align-self-end",
|
"align-self-end",
|
||||||
|
"anchor",
|
||||||
"ball",
|
"ball",
|
||||||
"bg-body",
|
"bg-body",
|
||||||
|
"bg-body-tertiary",
|
||||||
"bg-opacity-10",
|
"bg-opacity-10",
|
||||||
"bg-primary",
|
"bg-primary",
|
||||||
|
"blockquote-alert",
|
||||||
|
"blockquote-alert-heading",
|
||||||
|
"blockquote-alert-important",
|
||||||
|
"border",
|
||||||
"border-0",
|
"border-0",
|
||||||
|
"border-bottom",
|
||||||
|
"border-none",
|
||||||
|
"border-primary",
|
||||||
|
"border-top",
|
||||||
"bottom-0",
|
"bottom-0",
|
||||||
"bottom-bar",
|
"bottom-bar",
|
||||||
"breadcrumb",
|
"breadcrumb",
|
||||||
"breadcrumb-item",
|
"breadcrumb-item",
|
||||||
"btn",
|
"btn",
|
||||||
"btn-close",
|
"btn-close",
|
||||||
|
"btn-outline-primary",
|
||||||
|
"btn-outline-secondary",
|
||||||
"btn-primary",
|
"btn-primary",
|
||||||
"btn-social",
|
"btn-social",
|
||||||
"card",
|
"card",
|
||||||
@@ -55,6 +79,7 @@
|
|||||||
"card-title",
|
"card-title",
|
||||||
"card-zoom",
|
"card-zoom",
|
||||||
"checkbox",
|
"checkbox",
|
||||||
|
"chroma",
|
||||||
"col",
|
"col",
|
||||||
"col-12",
|
"col-12",
|
||||||
"col-6",
|
"col-6",
|
||||||
@@ -70,12 +95,15 @@
|
|||||||
"collapsed",
|
"collapsed",
|
||||||
"container-fluid",
|
"container-fluid",
|
||||||
"container-xxl",
|
"container-xxl",
|
||||||
|
"d-block",
|
||||||
"d-flex",
|
"d-flex",
|
||||||
|
"d-grid",
|
||||||
"d-inline",
|
"d-inline",
|
||||||
"d-lg-block",
|
"d-lg-block",
|
||||||
"d-md-block",
|
"d-md-block",
|
||||||
"d-md-none",
|
"d-md-none",
|
||||||
"d-none",
|
"d-none",
|
||||||
|
"data-table",
|
||||||
"display-1",
|
"display-1",
|
||||||
"display-4",
|
"display-4",
|
||||||
"emphasis",
|
"emphasis",
|
||||||
@@ -85,6 +113,7 @@
|
|||||||
"fa-2x",
|
"fa-2x",
|
||||||
"fa-book-open",
|
"fa-book-open",
|
||||||
"fa-ellipsis",
|
"fa-ellipsis",
|
||||||
|
"fa-exclamation",
|
||||||
"fa-face-frown",
|
"fa-face-frown",
|
||||||
"fa-facebook",
|
"fa-facebook",
|
||||||
"fa-fw",
|
"fa-fw",
|
||||||
@@ -94,6 +123,7 @@
|
|||||||
"fa-medium",
|
"fa-medium",
|
||||||
"fa-moon",
|
"fa-moon",
|
||||||
"fa-share-nodes",
|
"fa-share-nodes",
|
||||||
|
"fa-sort",
|
||||||
"fa-sun",
|
"fa-sun",
|
||||||
"fa-whatsapp",
|
"fa-whatsapp",
|
||||||
"fa-x-twitter",
|
"fa-x-twitter",
|
||||||
@@ -102,6 +132,7 @@
|
|||||||
"fixed-top",
|
"fixed-top",
|
||||||
"flex-column",
|
"flex-column",
|
||||||
"flex-fill",
|
"flex-fill",
|
||||||
|
"font-monospace",
|
||||||
"footer",
|
"footer",
|
||||||
"form-control",
|
"form-control",
|
||||||
"fs-3",
|
"fs-3",
|
||||||
@@ -110,14 +141,20 @@
|
|||||||
"fs-lg-5",
|
"fs-lg-5",
|
||||||
"fw-30",
|
"fw-30",
|
||||||
"fw-bold",
|
"fw-bold",
|
||||||
|
"fw-semibold",
|
||||||
"g-4",
|
"g-4",
|
||||||
"gap-1",
|
"gap-1",
|
||||||
|
"gap-2",
|
||||||
"h-100",
|
"h-100",
|
||||||
|
"h6",
|
||||||
|
"heading",
|
||||||
|
"highlight",
|
||||||
"hstack",
|
"hstack",
|
||||||
"img-fluid",
|
"img-fluid",
|
||||||
"img-wrap",
|
"img-wrap",
|
||||||
"invisible",
|
"invisible",
|
||||||
"is-search",
|
"is-search",
|
||||||
|
"justify-content-between",
|
||||||
"justify-content-center",
|
"justify-content-center",
|
||||||
"justify-content-end",
|
"justify-content-end",
|
||||||
"justify-content-start",
|
"justify-content-start",
|
||||||
@@ -137,9 +174,12 @@
|
|||||||
"ms-auto",
|
"ms-auto",
|
||||||
"ms-md-3",
|
"ms-md-3",
|
||||||
"mt-3",
|
"mt-3",
|
||||||
|
"mt-4",
|
||||||
"mt-5",
|
"mt-5",
|
||||||
|
"mt-md-0",
|
||||||
"mx-auto",
|
"mx-auto",
|
||||||
"mx-md-0",
|
"mx-md-0",
|
||||||
|
"my-2",
|
||||||
"my-auto",
|
"my-auto",
|
||||||
"my-md-0",
|
"my-md-0",
|
||||||
"my-md-auto",
|
"my-md-auto",
|
||||||
@@ -153,6 +193,7 @@
|
|||||||
"navbar-fixed-top",
|
"navbar-fixed-top",
|
||||||
"navbar-mode-selector",
|
"navbar-mode-selector",
|
||||||
"navbar-nav",
|
"navbar-nav",
|
||||||
|
"navbar-nav-scroll",
|
||||||
"navbar-toggler",
|
"navbar-toggler",
|
||||||
"no-js",
|
"no-js",
|
||||||
"order-0",
|
"order-0",
|
||||||
@@ -160,22 +201,30 @@
|
|||||||
"order-md-0",
|
"order-md-0",
|
||||||
"order-md-1",
|
"order-md-1",
|
||||||
"p-0",
|
"p-0",
|
||||||
|
"p-1",
|
||||||
"p-2",
|
"p-2",
|
||||||
"p-3",
|
"p-3",
|
||||||
"p-4",
|
"p-4",
|
||||||
|
"pb-2",
|
||||||
|
"pb-3",
|
||||||
"pb-4",
|
"pb-4",
|
||||||
"pb-5",
|
"pb-5",
|
||||||
"pb-md-0",
|
"pb-md-0",
|
||||||
|
"pe-3",
|
||||||
"position-fixed",
|
"position-fixed",
|
||||||
"position-relative",
|
"position-relative",
|
||||||
"ps-1",
|
"ps-1",
|
||||||
"pt-4",
|
"ps-3",
|
||||||
"pt-5",
|
"pt-5",
|
||||||
"pt-md-3",
|
"pt-md-3",
|
||||||
"px-4",
|
"px-4",
|
||||||
"px-xxl-0",
|
"px-xxl-0",
|
||||||
|
"py-1",
|
||||||
"py-3",
|
"py-3",
|
||||||
"rounded",
|
"rounded",
|
||||||
|
"rounded-2",
|
||||||
|
"rounded-bottom",
|
||||||
|
"rounded-top",
|
||||||
"row",
|
"row",
|
||||||
"row-cols-1",
|
"row-cols-1",
|
||||||
"row-cols-2",
|
"row-cols-2",
|
||||||
@@ -192,6 +241,22 @@
|
|||||||
"sticky-top",
|
"sticky-top",
|
||||||
"stretched-link",
|
"stretched-link",
|
||||||
"svg-inline--fa",
|
"svg-inline--fa",
|
||||||
|
"syntax-highlight",
|
||||||
|
"table",
|
||||||
|
"table-bordered",
|
||||||
|
"table-borderless",
|
||||||
|
"table-hover",
|
||||||
|
"table-responsive",
|
||||||
|
"table-responsive-lg",
|
||||||
|
"table-responsive-md",
|
||||||
|
"table-responsive-sm",
|
||||||
|
"table-responsive-xl",
|
||||||
|
"table-responsive-xxl",
|
||||||
|
"table-sm",
|
||||||
|
"table-striped",
|
||||||
|
"table-striped-columns",
|
||||||
|
"table-success",
|
||||||
|
"text-body",
|
||||||
"text-body-secondary",
|
"text-body-secondary",
|
||||||
"text-center",
|
"text-center",
|
||||||
"text-decoration-none",
|
"text-decoration-none",
|
||||||
@@ -206,13 +271,25 @@
|
|||||||
"toast-container",
|
"toast-container",
|
||||||
"toast-header",
|
"toast-header",
|
||||||
"toc",
|
"toc",
|
||||||
|
"toc-button",
|
||||||
|
"toc-panel",
|
||||||
"toc-sidebar",
|
"toc-sidebar",
|
||||||
"toggler-icon",
|
"toggler-icon",
|
||||||
"top-bar"
|
"top-bar"
|
||||||
],
|
],
|
||||||
"ids": [
|
"ids": [
|
||||||
|
"TableOfContents",
|
||||||
|
"accented-tables",
|
||||||
|
"aligned-cells-and-headers",
|
||||||
|
"always-responsive",
|
||||||
|
"basic-tables",
|
||||||
"blogs",
|
"blogs",
|
||||||
|
"bordered-tables",
|
||||||
|
"breakpoint-specific",
|
||||||
"btn-webshare",
|
"btn-webshare",
|
||||||
|
"colored-tables",
|
||||||
|
"data-tables",
|
||||||
|
"default-alignment",
|
||||||
"fa-face-frown",
|
"fa-face-frown",
|
||||||
"fab-facebook",
|
"fab-facebook",
|
||||||
"fab-github",
|
"fab-github",
|
||||||
@@ -222,16 +299,26 @@
|
|||||||
"fab-x-twitter",
|
"fab-x-twitter",
|
||||||
"fas-book-open",
|
"fas-book-open",
|
||||||
"fas-ellipsis",
|
"fas-ellipsis",
|
||||||
|
"fas-exclamation",
|
||||||
"fas-link",
|
"fas-link",
|
||||||
"fas-moon",
|
"fas-moon",
|
||||||
"fas-share-nodes",
|
"fas-share-nodes",
|
||||||
|
"fas-sort",
|
||||||
"fas-sun",
|
"fas-sun",
|
||||||
|
"hoverable-rows",
|
||||||
"navbar-0-collapse",
|
"navbar-0-collapse",
|
||||||
"navbar-mode",
|
"navbar-mode",
|
||||||
"navbar-mode-checkbox",
|
"navbar-mode-checkbox",
|
||||||
|
"responsive-tables",
|
||||||
|
"small-tables",
|
||||||
|
"striped-columns",
|
||||||
|
"striped-rows",
|
||||||
|
"table-borders",
|
||||||
|
"tables-without-borders",
|
||||||
"toast-container",
|
"toast-container",
|
||||||
"toast-copied-code-message",
|
"toast-copied-code-message",
|
||||||
"toast-message-email-4"
|
"toast-message-email-4",
|
||||||
|
"toc-collapse"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
40
layouts/_default/_markup/render-table.html
Normal file
40
layouts/_default/_markup/render-table.html
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
{{/* Adapted from https://gohugo.io/render-hooks/tables/ */}}
|
||||||
|
|
||||||
|
<!-- Ensure presence of `.table` class attribute to trigger Bootstrap styling -->
|
||||||
|
{{ $attr := .Attributes }}
|
||||||
|
{{ $class := split $attr.class " " }}
|
||||||
|
{{ if not (in $class "table") }}
|
||||||
|
{{ $attr = merge $attr (dict "class" (trim (delimit ($class | append "table") " ") " ")) }}
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
{{ $align := dict "left" "start" "center" "center" "right" "end" }}
|
||||||
|
|
||||||
|
<table
|
||||||
|
{{- range $k, $v := $attr }}
|
||||||
|
{{- if $v }}
|
||||||
|
{{- printf " %s=%q" $k $v | safeHTMLAttr }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}>
|
||||||
|
<thead>
|
||||||
|
{{- range .THead }}
|
||||||
|
<tr>
|
||||||
|
{{- range . }}
|
||||||
|
<th {{ with .Alignment }}class="text-{{ index $align . }}"{{ end }}>
|
||||||
|
{{- .Text -}}
|
||||||
|
</th>
|
||||||
|
{{- end }}
|
||||||
|
</tr>
|
||||||
|
{{- end }}
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
{{- range .TBody }}
|
||||||
|
<tr>
|
||||||
|
{{- range . }}
|
||||||
|
<td {{ with .Alignment }}class="text-{{ index $align . }}"{{ end }}>
|
||||||
|
{{- .Text -}}
|
||||||
|
</td>
|
||||||
|
{{- end }}
|
||||||
|
</tr>
|
||||||
|
{{- end }}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
@@ -51,7 +51,7 @@
|
|||||||
{{ else }}
|
{{ else }}
|
||||||
{{ $paginator = $page.Paginate $pages }}
|
{{ $paginator = $page.Paginate $pages }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ $pages = first $paginator.PageSize (after (mul (sub $paginator.PageNumber 1) $paginator.PageSize) $pages) }}
|
{{ $pages = first $paginator.PagerSize (after (mul (sub $paginator.PageNumber 1) $paginator.PagerSize) $pages) }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ $cardWrapper := "" }}
|
{{ $cardWrapper := "" }}
|
||||||
|
@@ -24,19 +24,17 @@
|
|||||||
{{- $class := delimit $main " " -}}
|
{{- $class := delimit $main " " -}}
|
||||||
{{ if or $sortable $paging $searchable }}{{ $class = trim (printf "%s data-table" $class) " " }}{{ end }}
|
{{ if or $sortable $paging $searchable }}{{ $class = trim (printf "%s data-table" $class) " " }}{{ end }}
|
||||||
{{- $input := $input | $page.RenderString }}
|
{{- $input := $input | $page.RenderString }}
|
||||||
{{- $input = replace $input "style=\"text-align:left\"" "class=\"text-start\"" -}}
|
{{ $regex := `<table\s*class="(.+?)"` }}
|
||||||
{{- $input = replace $input "style=\"text-align:center\"" "class=\"text-center\"" -}}
|
{{ $current := (index (index (findRESubmatch $regex $input) 0) 1) }}
|
||||||
{{- $input = replace $input "style=\"text-align:right\"" "class=\"text-end\"" -}}
|
{{ $target := delimit (((split $current " ") | append "table" | append $class) | uniq) " " }}
|
||||||
|
|
||||||
{{ $attributes := "" }}
|
{{ $attributes := "" }}
|
||||||
{{ if $sortable }}{{ $attributes = printf "%s data-table-sortable=true" $attributes }}{{ end }}
|
{{ if $sortable }}{{ $attributes = printf "%s data-table-sortable=true" $attributes }}{{ end }}
|
||||||
{{ if $paging }}{{ $attributes = printf "%s data-table-paging=true" $attributes }}{{ end }}
|
{{ if $paging }}{{ $attributes = printf "%s data-table-paging=true" $attributes }}{{ end }}
|
||||||
{{ if $searchable }}{{ $attributes = printf "%s data-table-searchable=true" $attributes }}{{ end }}
|
{{ if $searchable }}{{ $attributes = printf "%s data-table-searchable=true" $attributes }}{{ end }}
|
||||||
|
|
||||||
{{- $old := "<table>" -}}
|
{{- $new := printf `<table class="%s" %s` $target (trim $attributes " ") -}}
|
||||||
{{- $new := printf "<table class=\"table %s\" %s>" $class (trim $attributes " ") -}}
|
{{ $input := replaceRE $regex $new $input 1 -}}
|
||||||
|
|
||||||
{{ $input := replace $input $old $new -}}
|
|
||||||
{{- with $responsive }}<div class="{{ delimit . " " }}">{{ end -}}
|
{{- with $responsive }}<div class="{{ delimit . " " }}">{{ end -}}
|
||||||
{{ $input | safeHTML }}
|
{{ $input | safeHTML }}
|
||||||
{{- with $responsive }}</div>{{ end -}}
|
{{- with $responsive }}</div>{{ end -}}
|
@@ -73,7 +73,7 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
{{- if site.Params.style.purge -}}
|
{{- if site.Params.style.purge -}}
|
||||||
{{- $post_options := dict "config" "config" "noMap" hugo.IsProduction -}}
|
{{- $post_options := dict "config" "config" "noMap" hugo.IsProduction -}}
|
||||||
{{- $css = $css | resources.PostCSS $post_options -}}
|
{{- $css = $css | css.PostCSS $post_options -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{- if not hugo.IsProduction -}}
|
{{- if not hugo.IsProduction -}}
|
||||||
|
@@ -30,20 +30,21 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<!-- Main code -->
|
<!-- Main code -->
|
||||||
{{ if or $sortable $paging $searchable }}{{ $class = trim (printf "%s data-table" $class) " " }}{{ end }}
|
{{ if or $sortable $paging $searchable }}{{ $class = trim (printf "%s data-table" $class) " " }}{{ end }}
|
||||||
|
|
||||||
{{- $input := .Inner | .Page.RenderString }}
|
{{- $input := .Inner | .Page.RenderString }}
|
||||||
{{- $input = replace $input "style=\"text-align:left\"" "class=\"text-start\"" -}}
|
{{ $regex := `<table\s*class="(.+?)"` }}
|
||||||
{{- $input = replace $input "style=\"text-align:center\"" "class=\"text-center\"" -}}
|
{{ $current := (index (index (findRESubmatch $regex $input) 0) 1) }}
|
||||||
{{- $input = replace $input "style=\"text-align:right\"" "class=\"text-end\"" -}}
|
{{ $target := delimit (((split $current " ") | append "table" | append $class) | uniq) " " }}
|
||||||
|
|
||||||
{{ $attributes := "" }}
|
{{ $attributes := "" }}
|
||||||
{{ if $sortable }}{{ $attributes = printf "%s data-table-sortable=true" $attributes }}{{ end }}
|
{{ if $sortable }}{{ $attributes = printf "%s data-table-sortable=true" $attributes }}{{ end }}
|
||||||
{{ if $paging }}{{ $attributes = printf "%s data-table-paging=true" $attributes }}{{ end }}
|
{{ if $paging }}{{ $attributes = printf "%s data-table-paging=true" $attributes }}{{ end }}
|
||||||
{{ if $searchable }}{{ $attributes = printf "%s data-table-searchable=true" $attributes }}{{ end }}
|
{{ if $searchable }}{{ $attributes = printf "%s data-table-searchable=true" $attributes }}{{ end }}
|
||||||
|
|
||||||
{{- $old := "<table>" -}}
|
{{- $new := printf `<table class="%s" %s` $target (trim $attributes " ") -}}
|
||||||
{{- $new := printf "<table class=\"table %s\" %s>" $class (trim $attributes " ") -}}
|
{{ $input := replaceRE $regex $new $input 1 -}}
|
||||||
{{ $input := replace $input $old $new -}}
|
|
||||||
{{ if not $error }}
|
{{ if not $error }}
|
||||||
{{ if eq $breakpoint "none" }}
|
{{ if eq $breakpoint "none" }}
|
||||||
{{ $input | safeHTML }}
|
{{ $input | safeHTML }}
|
||||||
|
697
package-lock.json
generated
697
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@gethinode/hinode",
|
"name": "@gethinode/hinode",
|
||||||
"version": "0.26.6",
|
"version": "0.26.7",
|
||||||
"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",
|
||||||
@@ -71,14 +71,14 @@
|
|||||||
"autoprefixer": "^10.4.20",
|
"autoprefixer": "^10.4.20",
|
||||||
"cssnano": "^7.0.5",
|
"cssnano": "^7.0.5",
|
||||||
"cssnano-preset-advanced": "^7.0.5",
|
"cssnano-preset-advanced": "^7.0.5",
|
||||||
"hugo-bin": "0.130.1",
|
"hugo-bin": "0.131.0",
|
||||||
"purgecss-whitelister": "^2.4.0"
|
"purgecss-whitelister": "^2.4.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@gethinode/netlify-plugin-dartsass": "^0.3.0",
|
"@gethinode/netlify-plugin-dartsass": "^0.3.0",
|
||||||
"eslint": "^8.57.0",
|
"eslint": "^8.57.0",
|
||||||
"eslint-config-standard": "^17.1.0",
|
"eslint-config-standard": "^17.1.0",
|
||||||
"eslint-plugin-import": "^2.29.1",
|
"eslint-plugin-import": "^2.30.0",
|
||||||
"eslint-plugin-n": "^16.6.2",
|
"eslint-plugin-n": "^16.6.2",
|
||||||
"eslint-plugin-promise": "^6.6.0",
|
"eslint-plugin-promise": "^6.6.0",
|
||||||
"markdownlint-cli2": "^0.13.0",
|
"markdownlint-cli2": "^0.13.0",
|
||||||
|
@@ -6,7 +6,7 @@ homepage = "https://gethinode.com"
|
|||||||
demosite = "https://demo.gethinode.com"
|
demosite = "https://demo.gethinode.com"
|
||||||
tags = ["blog", "documentation", "minimal", "modern", "customizable", "search", "bootstrap"]
|
tags = ["blog", "documentation", "minimal", "modern", "customizable", "search", "bootstrap"]
|
||||||
features = ["security aware", "fast by default", "seo-ready", "development tools", "bootstrap framework", "netlify-ready", "full text search", "page layouts", "versioned documentation"]
|
features = ["security aware", "fast by default", "seo-ready", "development tools", "bootstrap framework", "netlify-ready", "full text search", "page layouts", "versioned documentation"]
|
||||||
min_version = "0.132.0"
|
min_version = "0.134.0"
|
||||||
|
|
||||||
[author]
|
[author]
|
||||||
name = "Mark Dumay"
|
name = "Mark Dumay"
|
||||||
|
Reference in New Issue
Block a user