调整部分与原版一致
This commit is contained in:
+42
-8
@@ -1,5 +1,4 @@
|
||||
<?php if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?>
|
||||
<main class="site--main">
|
||||
<div class="post--ingle__comments">
|
||||
<div id="comments" class="responsesWrapper">
|
||||
<?php $this->comments()->to($comments); ?>
|
||||
@@ -22,11 +21,48 @@
|
||||
</svg><?php $this->commentsNum(_t('暂无评论'), _t('仅有 1 条评论'), _t('已有 %d 条评论')); ?>
|
||||
</h3>
|
||||
<?php if ($comments->have()): ?>
|
||||
|
||||
<nav class="commentnav u-textAlignCenter"></nav>
|
||||
<ol class="commentlist sulliComment--list"> </ol>
|
||||
<?php $comments->listComments(); ?>
|
||||
|
||||
<?php function threadedComments($comments, $options) {
|
||||
$commentClass = '';
|
||||
if ($comments->authorId) {
|
||||
if ($comments->authorId == $comments->ownerId) {
|
||||
$commentClass .= ' comment-by-author';
|
||||
} else {
|
||||
$commentClass .= ' comment-by-user';
|
||||
}
|
||||
}
|
||||
|
||||
$commentLevelClass = $comments->levels > 0 ? ' comment-child' : ' comment-parent';
|
||||
?>
|
||||
<li id="li-<?php $comments->theId(); ?>" class="comment-body<?php
|
||||
if ($comments->levels > 0) {
|
||||
echo ' comment-child';
|
||||
$comments->levelsAlt(' comment-level-odd', ' comment-level-even');
|
||||
} else {
|
||||
echo ' comment-parent';
|
||||
}
|
||||
$comments->alt(' comment-odd', ' comment-even');
|
||||
echo $commentClass;
|
||||
?>">
|
||||
<div id="<?php $comments->theId(); ?>">
|
||||
<div class="comment-author">
|
||||
<?php $comments->gravatar('40', ''); ?>
|
||||
<cite class="fn"><?php $comments->author(); ?></cite>
|
||||
</div>
|
||||
<div class="comment-meta">
|
||||
<a href="<?php $comments->permalink(); ?>"><?php $comments->date('Y-m-d H:i'); ?></a>
|
||||
<span class="comment-reply"><?php $comments->reply(); ?></span>
|
||||
</div>
|
||||
<?php $comments->content(); ?>
|
||||
<?php $singleCommentOptions->commentStatus(); ?>
|
||||
</div>
|
||||
<?php if ($comments->children) { ?>
|
||||
<div class="comment-children">
|
||||
<?php $comments->threadedComments($options); ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</li>
|
||||
<?php } ?>
|
||||
|
||||
<?php
|
||||
$comments->pageNav(
|
||||
@@ -74,7 +110,5 @@
|
||||
<?php else: ?>
|
||||
<?php _e(''); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
Reference in New Issue
Block a user