调整样式
This commit is contained in:
parent
7c1b7260c6
commit
81baad8133
|
@ -1,3 +1,7 @@
|
||||||
## 说明
|
## 说明
|
||||||
|
|
||||||
从hexo的Chic移植而来
|
从`hexo`的`Chic`移植而来
|
||||||
|
|
||||||
|
友情链接页面参考`hexo`主题`blank`配合插件`Links`使用
|
||||||
|
|
||||||
|
评论列表参考`wordpress`主题`farallon`
|
|
@ -862,41 +862,76 @@ html {
|
||||||
}
|
}
|
||||||
.post-nav:before,
|
.post-nav:before,
|
||||||
.post-nav:after {
|
.post-nav:after {
|
||||||
content: " ";
|
content: "";
|
||||||
display: table;
|
display: table;
|
||||||
}
|
}
|
||||||
.post-nav a.prev,
|
|
||||||
.post-nav a.next {
|
.post-nav:after {
|
||||||
|
clear: both;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-nav {
|
||||||
|
width: 100%; /* 确保宽度足够 */
|
||||||
|
overflow: hidden; /* 清除浮动 */
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-nav .prev,
|
||||||
|
.post-nav .next {
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
transition-property: transform;
|
transition: transform 0.3s ease-out;
|
||||||
transition-timing-function: ease-out;
|
display: inline-block; /* 确保 span 转换为行内块级元素 */
|
||||||
transition-duration: 0.3s;
|
|
||||||
}
|
}
|
||||||
.post-nav a.prev {
|
|
||||||
|
.post-nav .prev {
|
||||||
float: left;
|
float: left;
|
||||||
|
text-align: left; /* 确保文字左对齐 */
|
||||||
}
|
}
|
||||||
.post-nav a.prev::before {
|
|
||||||
|
.post-nav .prev::before {
|
||||||
content: "<";
|
content: "<";
|
||||||
margin-right: 0.5em;
|
margin-right: 0.5em;
|
||||||
}
|
}
|
||||||
.post-nav a.prev:hover {
|
|
||||||
|
.post-nav .prev:hover {
|
||||||
transform: translateX(-4px);
|
transform: translateX(-4px);
|
||||||
}
|
}
|
||||||
.post-nav a.next {
|
|
||||||
|
.post-nav .next {
|
||||||
float: right;
|
float: right;
|
||||||
|
text-align: right; /* 确保文字右对齐 */
|
||||||
|
font-weight: normal; /* 确保链接文字正常粗细 */
|
||||||
}
|
}
|
||||||
.post-nav a.next::after {
|
|
||||||
|
.post-nav .next::after {
|
||||||
content: ">";
|
content: ">";
|
||||||
margin-left: 0.5em;
|
margin-left: 0.5em;
|
||||||
}
|
}
|
||||||
.post-nav a.next:hover {
|
|
||||||
|
.post-nav .next:hover {
|
||||||
transform: translateX(4px);
|
transform: translateX(4px);
|
||||||
}
|
}
|
||||||
.post-nav a.prev::before,
|
|
||||||
.post-nav a.next::after {
|
.post-nav .prev::before,
|
||||||
|
.post-nav .next::after {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.post-nav .prev a,
|
||||||
|
.post-nav .next a {
|
||||||
|
text-decoration: none; /* 去掉链接下划线 */
|
||||||
|
color: inherit; /* 继承父级颜色 */
|
||||||
|
display: inline-block; /* 使 a 元素成为行内块级元素 */
|
||||||
|
font-weight: normal; /* 确保链接文字正常粗细 */
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-nav .prev a {
|
||||||
|
text-align: left; /* 确保 a 元素文字左对齐 */
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-nav .next a {
|
||||||
|
text-align: right; /* 确保 a 元素文字右对齐 */
|
||||||
|
}
|
||||||
.tag:not(:last-child) a::after {
|
.tag:not(:last-child) a::after {
|
||||||
content: " / ";
|
content: " / ";
|
||||||
}
|
}
|
||||||
|
|
8
post.php
8
post.php
|
@ -12,11 +12,9 @@
|
||||||
发布日期:
|
发布日期:
|
||||||
</span> <?php $this->date('Y-m-d'); ?><span class="dot"></span>
|
</span> <?php $this->date('Y-m-d'); ?><span class="dot"></span>
|
||||||
<span class="post-category">
|
<span class="post-category">
|
||||||
分类:
|
所属分类:
|
||||||
</span><?php $this->category(','); ?> <span class="dot"></span>
|
</span><?php $this->category(','); ?> <span class="dot"></span>
|
||||||
<span> 浏览:</span><?php get_post_view($this) ?>次<span class="dot"></span>
|
<span> 浏览:</span><?php get_post_view($this) ?>次<span class="dot"></span>
|
||||||
<span>评论:</span><a href="<?php $this->permalink() ?>#comments">
|
|
||||||
<?php $this->commentsNum('0', '1', '%d '); ?></a>
|
|
||||||
<?php if($this->user->hasLogin() && $this->user->pass('editor', true)): ?>
|
<?php if($this->user->hasLogin() && $this->user->pass('editor', true)): ?>
|
||||||
<span><span class="dot"></span>
|
<span><span class="dot"></span>
|
||||||
<a href="<?php $this->options->adminUrl('write-post.php?cid=' . $this->cid); ?>" target="_blank" title="编辑文章">
|
<a href="<?php $this->options->adminUrl('write-post.php?cid=' . $this->cid); ?>" target="_blank" title="编辑文章">
|
||||||
|
@ -59,8 +57,8 @@
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
<section class="post-nav">
|
<section class="post-nav">
|
||||||
<a class="prev" rel="prev"><?php $this->thePrev('%s', '没有了'); ?></a>
|
<span class="prev" rel="prev"><?php $this->thePrev('%s', '没有了'); ?></span>
|
||||||
<a class="next" rel="next"><?php $this->theNext('%s', '没有了'); ?></a>
|
<span class="next" rel="next"><?php $this->theNext('%s', '没有了'); ?></span>
|
||||||
</section>
|
</section>
|
||||||
<!-- 判断如果允许评论则显示评论的div -->
|
<!-- 判断如果允许评论则显示评论的div -->
|
||||||
<?php if ($this->allow('comment')): ?>
|
<?php if ($this->allow('comment')): ?>
|
||||||
|
|
Loading…
Reference in New Issue