Initial commit
This commit is contained in:
11
themes/kestrel/layouts/partials/icon.html
Normal file
11
themes/kestrel/layouts/partials/icon.html
Normal file
@@ -0,0 +1,11 @@
|
||||
{{- if isset .ctx.Site.Data.m10c.icons .name -}}
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="icon icon-{{ .name }}">
|
||||
<title>{{ .title | default .name }}</title>
|
||||
{{ safeHTML (index .ctx.Site.Data.m10c.icons .name) }}
|
||||
</svg>
|
||||
{{- else -}}
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="icon icon-link">
|
||||
<path d="M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"></path>
|
||||
<path d="M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"></path>
|
||||
</svg>
|
||||
{{- end -}}
|
27
themes/kestrel/layouts/partials/pagination.html
Normal file
27
themes/kestrel/layouts/partials/pagination.html
Normal file
@@ -0,0 +1,27 @@
|
||||
{{ with $.Paginator }}
|
||||
{{ if gt .TotalPages 1 }}
|
||||
<ul class="pagination">
|
||||
{{ with .Prev }}
|
||||
<li class="page-item">
|
||||
<a class="page-link" href="{{ .URL }}">
|
||||
{{ partial "icon.html" (dict "ctx" $ "name" "arrow-left") }}
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ range .Pagers }}
|
||||
<li class="page-item{{ if eq .PageNumber $.Paginator.PageNumber }} active{{ end }}">
|
||||
<a class="page-link" href="{{ .URL }}">
|
||||
{{ .PageNumber }}
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ with .Next }}
|
||||
<li class="page-item">
|
||||
<a class="page-link" href="{{ .URL }}">
|
||||
{{ partial "icon.html" (dict "ctx" $ "name" "arrow-right") }}
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ end }}
|
||||
{{ end }}
|
Reference in New Issue
Block a user