65 lines
2.5 KiB
Plaintext
65 lines
2.5 KiB
Plaintext
|
|
<#--判断主页显示社交链接-->
|
|
<#if is_index??>
|
|
<section class="home-title">
|
|
<h1>${blog_title!}</h1>
|
|
<span>${user.description!}</span>
|
|
<div class="home-social">
|
|
<#if settings.home_social?? && settings.home_social != ''>
|
|
${settings.home_social!}
|
|
</#if>
|
|
</div>
|
|
</section>
|
|
</#if>
|
|
<#--判断页面显示标题-->
|
|
<#if is_tag??>
|
|
<section class="home-title">
|
|
<h1>包含“${tag.name}”标签的文章</h1>
|
|
</section>
|
|
</#if>
|
|
<#if is_category??>
|
|
<section class="home-title">
|
|
<h1>“${category.name}”分类下的文章</h1>
|
|
</section>
|
|
</#if>
|
|
<#if is_search??>
|
|
<section class="home-title">
|
|
<h1>包含“${keyword!}”关键字的文章</h1>
|
|
</section>
|
|
</#if>
|
|
<#--显示文章-->
|
|
<section class="home-posts">
|
|
<#list posts.content as post>
|
|
<div class="post-item">
|
|
<h2>
|
|
<a href="${post.fullPath!}">${post.title!}</a>
|
|
</h2>
|
|
<#--显示文章简介-->
|
|
<p>${post.summary!}</p>
|
|
<#--文章标签等-->
|
|
<div class="post-meta">
|
|
<time class="date">
|
|
${post.createTime?string('yyyy-MM-dd')!}
|
|
</time>
|
|
<span class="category">
|
|
<#list post.categories as category>
|
|
<a href="${category.fullPath!}" >
|
|
${category.name!}
|
|
</a>
|
|
</#list>
|
|
</span>
|
|
<span class="tags">
|
|
<#list post.tags as tag>
|
|
<a href="${tag.fullPath}" class="tag">${tag.name}</a>
|
|
</#list>
|
|
</span>
|
|
<span class="comments">
|
|
${post.commentCount!}°C
|
|
</span>
|
|
<span class="visits">
|
|
${post.visits!}
|
|
</span>
|
|
</div>
|
|
</div>
|
|
</#list>
|
|
</section> |