halo-theme-xinac-fantastic/layout/tag.ftl

48 lines
2.1 KiB
Plaintext

<#include "common/article.ftl">
<#if settings.nav_enable!false>
<div class="card">
<div class="card-content">
<nav class="breadcrumb" aria-label="breadcrumbs">
<ul>
<li><a href="${tags_url!}">标签</a></li>
<li class="is-active"><a href="#" aria-current="page">${tag.name!}</a></li>
</ul>
</nav>
</div>
</div>
</#if>
<#if posts.content?size gt 0>
<#list posts.content as post>
<@article post,'index','null',true />
</#list>
<#if posts.getTotalPages() gt 0>
<div class="card card-transparent">
<nav class="pagination is-centered" role="navigation" aria-label="pagination">
<@paginationTag method="tagPosts" page="${posts.number}" total="${posts.totalPages}" display="3" slug="${tag.slug!}">
<div class="pagination-previous<#if pagination.hasPrev><#else > is-invisible is-hidden-mobile</#if>">
<a class="is-flex-grow has-text-black-ter" href="${pagination.prevPageFullPath!}">上一页</a>
</div>
<div class="pagination-next<#if pagination.hasNext><#else > is-invisible is-hidden-mobile</#if>">
<a class="is-flex-grow has-text-black-ter" href="${pagination.nextPageFullPath!}">下一页</a>
</div>
<ul class="pagination-list is-hidden-mobile">
<#list pagination.rainbowPages as number>
<#if number.isCurrent>
<li><a class="pagination-link is-current" href="${number.fullPath!}">${number.page!}</a></li>
<#else>
<li><a class="pagination-link has-text-black-ter" href="${number.fullPath!}">${number.page!}</a></li>
</#if>
</#list>
</ul>
</@paginationTag>
</nav>
</div>
</#if>
<#else>
<div class="level">
<div class="level-item has-text-centered">
空空如也
</div>
</div>
</#if>