style: refactor layout

This commit is contained in:
Erzbir
2025-08-10 17:21:56 +08:00
parent 9cf5c1540a
commit 66034a343f
16 changed files with 105 additions and 120 deletions
+16 -17
View File
@@ -8,20 +8,20 @@
<header>
<h1 class="post-title" th:text="${post.spec.title}">Post Title</h1>
<div class="post-meta">
<span class="post-date"
th:text="${#dates.format(post.spec.publishTime,'yyyy-MM-dd')}">Publish Time</span>
<time class="post-date"
th:text="${#dates.format(post.spec.publishTime,'yyyy-MM-dd')}">Publish Time
</time>
<span class="post-author" th:text="${post.owner.displayName}">Author</span>
</div>
<span class="post-tags">
<span class="post-tag" th:each="tag : ${post.tags}">
<a data-pjax
th:href="@{${tag.status.permalink}}"
th:title="${tag.spec.displayName}"
th:text="'#'+${tag.spec.displayName}"
>#Tag
</a>
</span>
</span>
<span class="post-tag" th:each="tag : ${post.tags}">
<a data-pjax
th:href="@{${tag.status.permalink}}"
th:title="${tag.spec.displayName}"
th:text="'#'+${tag.spec.displayName}"
>#Tag</a>
</span>
</span>
</header>
<section class="post-content">
<div th:utext="${post.content.content}" id="content">Post Content</div>
@@ -31,7 +31,7 @@
<button id="toc-toggle" class="toc-toggle" aria-label="Hide Table of Contents"></button>
<div id="toc-content" class="toc-content"></div>
</nav>
<section class="pagination">
<nav class="pagination">
<div class="pagination__title">
<span class="pagination__title-h" th:text="#{page.post.pagination}">READ OTHER POSTS</span>
<hr/>
@@ -48,10 +48,9 @@
</a>
</span>
</div>
</section>
<section class="comment" th:if="${haloCommentEnabled}">
<h2 th:text="#{page.post.comment}">Comments</h2>
<halo:comment group="content.halo.run" kind="Post" th:attr="name=${post.metadata.name}"/>
</section>
</nav>
<th:block
th:replace="~{modules/comment :: comment(group = 'content.halo.run', kind = 'Post', name = ${post.metadata.name})}"
th:if="${haloCommentEnabled}"/>
</th:block>
</html>