mirror of
https://ghfast.top/https://github.com/zsjy/halo-theme-dream2.0-plus.git
synced 2025-03-15 16:39:40 +08:00
feat: 侧边栏显示树形,限制数量改为对各分级的限制
This commit is contained in:
parent
8bfd5de86a
commit
e829972075
@ -6,20 +6,20 @@
|
||||
isEmpty = ${#lists.isEmpty(categories)}">
|
||||
<div class="card-title">
|
||||
<i class="ri-apps-line card-title-label"></i><span>分类</span>
|
||||
<a th:if="${#lists.size(categories) > num && theme.config.sidebar.categories_more}" class="card-more" th:href="@{/categories}">更多<i
|
||||
<a th:if="${theme.config.sidebar.categories_more}" class="card-more" th:href="@{/categories}">更多<i
|
||||
class="ri-arrow-right-double-line"></i></a>
|
||||
</div>
|
||||
<div th:if="${isEmpty}" class="card-empty">暂无分类</div>
|
||||
<div th:unless="${isEmpty}" class="card-content">
|
||||
<ul class="menu-list">
|
||||
<th:block th:fragment="categories (categories, noLimit)">
|
||||
<li th:each="category,itemIndex : ${categories}" th:unless="${itemIndex.index >= num && noLimit == null}">
|
||||
<li th:each="category,itemIndex : ${categories}" th:unless="${itemIndex.index >= num}">
|
||||
<a class="level is-marginless" th:href="${category.status.permalink}">
|
||||
<span class="level-item" th:text="${category.spec.displayName}"></span>
|
||||
<span class="level-item tag" th:text="${category.status.postCount}"></span>
|
||||
</a>
|
||||
<ul th:if="${!#lists.isEmpty(category.children)}">
|
||||
<th:block th:replace="~{:: categories (${category.children}, true)}"/>
|
||||
<th:block th:replace="~{:: categories (${category.children})}"/>
|
||||
</ul>
|
||||
</li>
|
||||
</th:block>
|
||||
|
@ -8,7 +8,7 @@
|
||||
|
||||
<div class="card-title">
|
||||
<i class="ri-cloud-line card-title-label"></i><span>标签云</span>
|
||||
<a th:if="${tags.hasNext && theme.config.sidebar.tagcloud_more}" class="card-more" th:href="@{/tags}">更多<i class="ri-arrow-right-double-line"></i></a>
|
||||
<a th:if="${theme.config.sidebar.tagcloud_more}" class="card-more" th:href="@{/tags}">更多<i class="ri-arrow-right-double-line"></i></a>
|
||||
</div>
|
||||
<div th:if="${isEmpty}" class="card-empty">暂无标签</div>
|
||||
<div th:unless="${isEmpty}" class="card-content">
|
||||
|
@ -7,7 +7,7 @@
|
||||
enableTagsColor = ${theme.config.sidebar.enable_tag_color}">
|
||||
<div class="card-title">
|
||||
<i class="ri-price-tag-3-line card-title-label"></i><span>标签</span>
|
||||
<a th:if="${tags.hasNext && theme.config.sidebar.tags_more}" class="card-more" th:href="@{/tags}">更多<i class="ri-arrow-right-double-line"></i></a>
|
||||
<a th:if="${theme.config.sidebar.tags_more}" class="card-more" th:href="@{/tags}">更多<i class="ri-arrow-right-double-line"></i></a>
|
||||
</div>
|
||||
<div th:if="${isEmpty}" class="card-empty">暂无标签</div>
|
||||
<div th:unless="${isEmpty}" class="card-content">
|
||||
|
Loading…
x
Reference in New Issue
Block a user