@@ -0,0 +1,10 @@
|
||||
<ul th:fragment="next (categories)">
|
||||
<li th:fragment="single (categories)" th:each="category : ${categories}">
|
||||
<a th:href="@{${category.status.permalink}}">
|
||||
<span th:text="${category.spec.displayName}+' ('+${category.status.visiblePostCount?:0}+' 篇文章)'"> </span>
|
||||
</a>
|
||||
<th:block th:if="${not #lists.isEmpty(category.children)}">
|
||||
<th:block th:replace="~{modules/category-tree :: next (categories=${category.children})}"></th:block>
|
||||
</th:block>
|
||||
</li>
|
||||
</ul>
|
||||
@@ -0,0 +1,30 @@
|
||||
<footer class="footer">
|
||||
<div class="footer__inner">
|
||||
<div class="copyright">
|
||||
<span>
|
||||
© <span th:text="${#dates.year(#dates.createNow())}">2024</span> Powered by
|
||||
<a th:href="${theme.config.footer.footer_powered_link}" th:text="${theme.config.footer.footer_powered_text}"></a>
|
||||
</span>
|
||||
</div>
|
||||
<div class="beian">
|
||||
<span th:if="${not #strings.isEmpty(theme.config.beian.icp_text)}">
|
||||
<a
|
||||
href="https://beian.miit.gov.cn/"
|
||||
target="_blank"
|
||||
th:href="${theme.config.beian.icp_link}"
|
||||
th:text="${theme.config.beian.icp_text}"
|
||||
></a
|
||||
></span>
|
||||
<span th:if="${not #strings.isEmpty(theme.config.beian.gongan_text)}">
|
||||
<img th:src="@{/assets/image/gongan.png}" style="display:inline-block; height: 1.2em;">
|
||||
<a
|
||||
href="https://www.beian.gov.cn/"
|
||||
target="_blank"
|
||||
th:href="${theme.config.beian.gongan_link}"
|
||||
th:text="${theme.config.beian.gongan_text}"
|
||||
></a
|
||||
></span>
|
||||
</div>
|
||||
<halo:footer />
|
||||
</div>
|
||||
</footer>
|
||||
@@ -0,0 +1,73 @@
|
||||
<header class="header" xmlns:th="http://www.w3.org/1999/xhtml">
|
||||
<div th:fragment="header" th:with="menu = ${menuFinder.getPrimary()}">
|
||||
<div class="header__inner">
|
||||
<a class="logo" href="/" style="text-decoration: none">
|
||||
<img class="icon" th:if="${not #strings.isEmpty(theme.config.basic.logo)}" th:src="${theme.config.basic.logo}" alt="Logo" />
|
||||
<div class="text" th:if="${not #strings.isEmpty(theme.config.basic.title)}" th:text="${theme.config.basic.title}"></div>
|
||||
</a>
|
||||
<div class="dividing"></div>
|
||||
<button
|
||||
type="button"
|
||||
class="button"
|
||||
th:if="${pluginFinder.available('PluginSearchWidget')}"
|
||||
onclick="SearchWidget.open()"
|
||||
>
|
||||
<th:block th:unless="${theme.config.basic.pixel_style}">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="1.5rem" height="1.5rem" viewBox="0 0 24 24">
|
||||
<path
|
||||
fill="currentColor"
|
||||
d="m19.6 21l-6.3-6.3q-.75.6-1.725.95T9.5 16q-2.725 0-4.612-1.888T3 9.5q0-2.725 1.888-4.612T9.5 3q2.725 0 4.612 1.888T16 9.5q0 1.1-.35 2.075T14.7 13.3l6.3 6.3l-1.4 1.4ZM9.5 14q1.875 0 3.188-1.313T14 9.5q0-1.875-1.313-3.188T9.5 5Q7.625 5 6.312 6.313T5 9.5q0 1.875 1.313 3.188T9.5 14Z"
|
||||
/>
|
||||
</svg>
|
||||
</th:block>
|
||||
<th:block th:if="${theme.config.basic.pixel_style}">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="1.5rem" height="1.5rem" viewBox="0 0 24 24"><path fill="currentColor" d="M6 2h8v2H6zM4 6V4h2v2zm0 8H2V6h2zm2 2H4v-2h2zm8 0v2H6v-2zm2-2h-2v2h2v2h2v2h2v2h2v-2h-2v-2h-2v-2h-2zm0-8h2v8h-2zm0 0V4h-2v2z"/></svg>
|
||||
</th:block>
|
||||
</button>
|
||||
<button type="button" class="button" x-data="themeMode()" @click="handleToggleThemeMode()">
|
||||
<th:block th:unless="${theme.config.basic.pixel_style}">
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
style="vertical-align: -0.125em"
|
||||
width="1.5rem"
|
||||
height="1.5rem"
|
||||
preserveAspectRatio="xMidYMid meet"
|
||||
viewBox="0 0 24 24"
|
||||
>
|
||||
<path
|
||||
fill="currentColor"
|
||||
d="M7.5 2c-1.79 1.15-3 3.18-3 5.5s1.21 4.35 3.03 5.5C4.46 13 2 10.54 2 7.5A5.5 5.5 0 0 1 7.5 2m11.57 1.5l1.43 1.43L4.93 20.5L3.5 19.07L19.07 3.5m-6.18 2.43L11.41 5L9.97 6l.42-1.7L9 3.24l1.75-.12l.58-1.65L12 3.1l1.73.03l-1.35 1.13l.51 1.67m-3.3 3.61l-1.16-.73l-1.12.78l.34-1.32l-1.09-.83l1.36-.09l.45-1.29l.51 1.27l1.36.03l-1.05.87l.4 1.31M19 13.5a5.5 5.5 0 0 1-5.5 5.5c-1.22 0-2.35-.4-3.26-1.07l7.69-7.69c.67.91 1.07 2.04 1.07 3.26m-4.4 6.58l2.77-1.15l-.24 3.35l-2.53-2.2m4.33-2.7l1.15-2.77l2.2 2.54l-3.35.23m1.15-4.96l-1.14-2.78l3.34.24l-2.2 2.54M9.63 18.93l2.77 1.15l-2.53 2.19l-.24-3.34Z"
|
||||
/>
|
||||
</svg>
|
||||
</th:block>
|
||||
<th:block th:if="${theme.config.basic.pixel_style}">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="1.5rem" height="1.5rem" viewBox="0 0 24 24"><path fill="currentColor" d="M11 0h2v4h-2zm1 12H8v2H4v2H2v4h2v2h10v-2h2v-4h-2v-2h-2zm0 2v2h2v4H4v-4h4v2h2v-2H8v-2zM8 6h6v2H8zm0 2v2H6V8zm8 2h-2V8h2zm0 0h2v2h-2zm4-8h2v2h-2zm0 2v2h-2V4zM2 2h2v2H2zm2 2h2v2H4zm20 7h-4v2h4z"/></svg>
|
||||
</th:block>
|
||||
</button>
|
||||
</div>
|
||||
<nav class="menu">
|
||||
<ul th:if="${menu != null} and ${not #lists.isEmpty(menu.menuItems)}" class="menu__inner">
|
||||
<li th:each="menuItem : ${menu.menuItems}" x-data="menu()" @mouseenter="handleToggleMenu()" @mouseleave="handleToggleMenu()">
|
||||
<a
|
||||
class="text-gray-600 hover:text-blue-600"
|
||||
th:href="${menuItem.status.href}"
|
||||
th:text="${menuItem.status.displayName + (not #lists.isEmpty(menuItem.children) ? '▾' : '')}"
|
||||
></a>
|
||||
<ul
|
||||
th:if="${not #lists.isEmpty(menuItem.children)}"
|
||||
class="menu__sub-inner"
|
||||
:class="{'open': isOpen}"
|
||||
>
|
||||
<li th:each="childMenuItem : ${menuItem.children}">
|
||||
<a
|
||||
class="text-gray-600 hover:text-blue-600"
|
||||
th:href="${childMenuItem.status.href} "
|
||||
th:text="${childMenuItem.status.displayName} "
|
||||
></a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
</header>
|
||||
@@ -0,0 +1,36 @@
|
||||
<!DOCTYPE html>
|
||||
<html
|
||||
xmlns:th="https://www.thymeleaf.org"
|
||||
th:lang="${#locale.toLanguageTag}"
|
||||
th:fragment="html (header, content, footer)">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<link rel="icon" type="image/x-icon" th:href="${theme.config.basic.favicon}">
|
||||
<title th:text="${title}"></title>
|
||||
<link rel="manifest" th:href="@{/assets/dist/manifest.json}" />
|
||||
<link rel="stylesheet" th:href="@{/assets/dist/main.css?version={version}(version=${theme.spec.version})}" href="./assets/dist/style.css" />
|
||||
</head>
|
||||
<!-- 根据情况判断是否添加开启像素化样式 -->
|
||||
<body class="main" th:classappend="${theme.config.basic.pixel_style} ? 'pixel_style' : '' ">
|
||||
<div class="center headings--one-size container">
|
||||
<th:block th:if="${header != null}">
|
||||
<th:block th:replace="${header}" />
|
||||
</th:block>
|
||||
<th:block th:if="${header == null}">
|
||||
<th:block th:replace="~{modules/header :: header(isHome = true)}" />
|
||||
</th:block>
|
||||
|
||||
<th:block th:replace="${content}" />
|
||||
|
||||
<th:block th:if="${footer == null}">
|
||||
<th:block th:replace="~{modules/footer}" />
|
||||
</th:block>
|
||||
<th:block th:if="${footer != null}">
|
||||
<th:block th:replace="${footer}" />
|
||||
</th:block>
|
||||
</div>
|
||||
<script th:src="@{/assets/dist/main.js?version={version}(version=${theme.spec.version})}"></script>
|
||||
</body>
|
||||
</html>
|
||||
在新议题中引用
屏蔽一个用户