fix: update permalink handling in subpath setting

This commit is contained in:
geekifan
2025-05-11 17:58:59 +08:00
parent 102129f36a
commit f615f3bd8a
6 changed files with 89 additions and 88 deletions

View File

@ -38,7 +38,7 @@
<div id="h_{{ $index }}" class="card-header d-flex justify-content-between hide-border-bottom">
<span class="ms-2">
<i class="far fa-folder{{ if gt (len $subcategories) 0 }}-open{{ end }} fa-fw"></i>
<a href="{{ "/categories/" | relLangURL }}{{ $parentName | urlize }}" class="mx-2">{{ $parentName }}</a>
<a href="{{ "categories/" | absLangURL }}{{ $parentName | urlize }}" class="mx-2">{{ $parentName }}</a>
<span class="text-muted small font-weight-light">
{{ if gt (len $subcategories) 0 }}
{{ len $subcategories }}
@ -86,7 +86,7 @@
<li class="list-group-item">
<i class="far fa-folder fa-fw"></i>
<a href="{{ "/categories/" | relLangURL }}{{ $subCategoryName | urlize }}" class="mx-2">{{ $subCategoryName }}</a>
<a href="{{ "categories/" | absLangURL }}{{ $subCategoryName | urlize }}" class="mx-2">{{ $subCategoryName }}</a>
<span class="text-muted small font-weight-light">
{{ len $subPages }}
{{ if gt (len $subPages) 1 }}

View File

@ -14,7 +14,7 @@
{{ range $sorted_tags }}
<div>
<a class="tag" href="{{ "/tags/" | relLangURL }}{{ . | urlize }}/">
<a class="tag" href="{{ "tags/" | absLangURL }}{{ . | urlize }}/">
{{ . -}}
<span class="text-muted">{{ len (index $.Site.Taxonomies.tags .) }}</span>
</a>