Skip to content

Commit

Permalink
feat: up2.2.3
Browse files Browse the repository at this point in the history
1. 感谢网友发现短代码处没有加php,应该解决了不用开启短代码的问题
2. 暗黑模式上一些颜色的适配
3. 私密回复的bug,不应该转义啊
4. 修复非作者的网址不能跳转问题
5. 修复归档pjax未加载js的问题
  • Loading branch information
dyedd committed Jan 15, 2021
1 parent ed10fab commit cb69a35
Show file tree
Hide file tree
Showing 11 changed files with 34 additions and 12 deletions.
11 changes: 11 additions & 0 deletions assets/css/comments.css
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,9 @@ ol.comment-list {
background-color: #3a3f51;
}

.comment-mail-me {
margin-right: .5rem;
}
/*
暗黑模式
*/
Expand All @@ -188,3 +191,11 @@ ol.comment-list {
.theme-dark .comment-respond {
border: none;
}

.theme-dark .secret {
color: var(--theme-text-color);
}

.theme-dark .comment-mail-me {
color: var(--dark-text-gray-color);
}
4 changes: 2 additions & 2 deletions assets/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -828,8 +828,8 @@ article .sticky {
background-color: var(--dark-content);
}

.theme-dark .page-link .icon {
color: var(--dark-text-gray-color);
.theme-dark #icon-you path, .theme-dark #icon-zuo path {
fill: var(--dark-text-gray-color);
}

.theme-dark footer {
Expand Down
3 changes: 2 additions & 1 deletion assets/css/post.css
Original file line number Diff line number Diff line change
Expand Up @@ -814,8 +814,9 @@ pre::after {
border-bottom: 1px solid var(--dark-text-gray-color);
}

.theme-dark .article-content blockquote p {
.theme-dark .article-content blockquote {
color: var(--dark-text-gray-color);
background: none;
}

.theme-dark .links-title h4 {
Expand Down
2 changes: 1 addition & 1 deletion assets/js/icon.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion component/index.article.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
<?php $this->fields->excerpt(); ?>
<?php else: ?>
<?php $this->excerpt(100); ?>
<? endif; ?>
<?php endif; ?>
</div>
<div class="post-category">
<svg class="icon" aria-hidden="true">
Expand Down
1 change: 1 addition & 0 deletions component/index.footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ function () {
lanstar.addCatalog();
lanstar.addComment();
lanstar.addPageLike();
lanstar.addArchiveToggle();
<?php $this->options->pjax_complete(); ?>
});
</script>
Expand Down
8 changes: 8 additions & 0 deletions docs/history.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
### [2.2.3](https://github.com/dyedd/lanstar/releases/tag/2.2.3)

1. 感谢网友发现短代码处没有加php,应该解决了不用开启短代码的问题
2. 暗黑模式上一些颜色的适配
3. 私密回复的bug,不应该转义啊
4. 修复非作者的网址不能跳转问题
5. 修复归档pjax未加载js的问题

### [2.2.2](https://github.com/dyedd/lanstar/releases/tag/2.2.2)

1. 修复评论无法回复
Expand Down
1 change: 1 addition & 0 deletions docs/start.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ syntax error, unexpected 'endwhile' (T_ENDWHILE), expecting elseif (T_ELSEIF) or

因为非常重要,特地放在开头,希望大家能够引起大家的重视。

`2.2.3`已修复,可以不用开启短代码了
---

### 下载
Expand Down
2 changes: 1 addition & 1 deletion index.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*
* @package Lanstar
* @author 染念
* @version 2.2.2
* @version 2.2.3
* @link https://dyedd.cn
*/

Expand Down
10 changes: 5 additions & 5 deletions layout/comments.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,12 @@ function threadedComments($comments, $options)
<div id="<?php $comments->theId(); ?>" class="comment-body">
<div class="comment-info">
<div class="comment-head">
<?php
$pcomments = get_comment($comments->parent);
if ($pcomments) echo '<code style="margin:0 .3em 0 0;padding:0;font-size:.9em;">@' . $pcomments['author'] . '</code>';
?>
<a class="comment-user-name me-1"
href="/author/<?php echo $comments->authorId > 0 ? $comments->authorId : $comments->url; ?>"
href="<?php echo $comments->authorId > 0 ? '/author/' . $comments->authorId : $comments->url; ?>"
rel="external nofollow">
<?php echo $comments->author; ?>
</a>
Expand All @@ -51,10 +55,6 @@ function threadedComments($comments, $options)
</span>
</div>
<div class="comment-content">
<?php
$pcomments = get_comment($comments->parent);
if ($pcomments) echo '<code style="float:left;margin:.1em .5em;padding:0;fonts-size:.9em;">@' . $pcomments['author'] . '</code>';
?>
<?php $comments->content(); ?>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion libs/comments.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public static function parseSecret($text)
public static function insertSecret($comment)
{
if ($_POST['secret']) {
$comment['text'] = '[secret]' . $comment['text'] . '[/\secret]';
$comment['text'] = '[secret]' . $comment['text'] . '[/secret]';
}
return $comment;
}
Expand Down

0 comments on commit cb69a35

Please sign in to comment.