diff options
author | Alexander Neonxp Kiryukhin <i@neonxp.ru> | 2024-12-17 20:37:32 +0300 |
---|---|---|
committer | Alexander Neonxp Kiryukhin <i@neonxp.ru> | 2024-12-17 20:37:32 +0300 |
commit | c0073e38e6ee3753f6cece23f60c608162a06918 (patch) | |
tree | da60ecf78e390f0b52e7857a2a0d527c274a700a /layouts | |
parent | a7d25c3f329ba0c9906acd486a1c12707c617f2d (diff) |
Auto-commit 2024-12-17
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/_default/list.txt | 3 | ||||
-rw-r--r-- | layouts/_default/page.txt | 3 | ||||
-rw-r--r-- | layouts/_default/single.txt | 8 | ||||
-rw-r--r-- | layouts/partials/head/js.html | 4 | ||||
-rw-r--r-- | layouts/partials/header.html | 6 |
5 files changed, 19 insertions, 5 deletions
diff --git a/layouts/_default/list.txt b/layouts/_default/list.txt new file mode 100644 index 0000000..3dbd917 --- /dev/null +++ b/layouts/_default/list.txt @@ -0,0 +1,3 @@ +{{ range .Pages.ByPublishDate.Reverse }} +{{ .Date.Format "2006-01-02" }} {{ .Title }} {{ with .OutputFormats.Get "txt" -}} {{ .RelPermalink }}{{ end }} +{{ end }}
\ No newline at end of file diff --git a/layouts/_default/page.txt b/layouts/_default/page.txt deleted file mode 100644 index 8df585d..0000000 --- a/layouts/_default/page.txt +++ /dev/null @@ -1,3 +0,0 @@ -{{ .Title }} - -{{ .Plain }}
\ No newline at end of file diff --git a/layouts/_default/single.txt b/layouts/_default/single.txt new file mode 100644 index 0000000..51f0239 --- /dev/null +++ b/layouts/_default/single.txt @@ -0,0 +1,8 @@ +{{ .Title }} + +{{ $content := .RawContent -}} +{{ $content := $content | replaceRE "(?s:< !--more-- >)" "" -}} +{{ $content }} + +--- +NeonXP at {{ .Date.Format "2006-01-02" }} diff --git a/layouts/partials/head/js.html b/layouts/partials/head/js.html index f4dc60e..bb53b7b 100644 --- a/layouts/partials/head/js.html +++ b/layouts/partials/head/js.html @@ -10,4 +10,6 @@ {{- end }} {{- end }} {{- end }} -<script src="/js/bootstrap.bundle.min.js"></script>
\ No newline at end of file +<script src="/js/bootstrap.bundle.min.js"></script> +<script src="/js/fuse.min.js"></script> +<script src="/js/search.js"></script>
\ No newline at end of file diff --git a/layouts/partials/header.html b/layouts/partials/header.html index 4cb6113..0c951c5 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -9,7 +9,11 @@ </button> <div class="collapse navbar-collapse" id="navbarSupportedContent"> {{ partial "hmenu.html" (dict "menuID" "main" "page" .) }} + <div class="d-flex"> + <input class="form-control me-2" id="search-input" type="search" placeholder="Поиск по сайту" aria-label="Поиск по сайту"> + </div> </div> </div> </nav> -<div class="navbar-filler"></div>
\ No newline at end of file +<div class="navbar-filler"></div> +<div id="search-results" class="list-group rounded border shadow hidden"></div>
\ No newline at end of file |