Skip to content

Commit

Permalink
更改版本号
Browse files Browse the repository at this point in the history
  • Loading branch information
jkjoy committed May 30, 2024
1 parent e86e1af commit bd3b384
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 16 deletions.
2 changes: 1 addition & 1 deletion dist/js/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
is_single = false;
post_id = 0;
is_archive = false;
VERSION = "0.4.1";
VERSION = "0.5.0";
constructor() {
super();
this.initCopyright();
Expand Down
12 changes: 3 additions & 9 deletions page-archives.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,10 @@
$stat = Typecho_Widget::widget('Widget_Stat');
Typecho_Widget::widget('Widget_Contents_Post_Recent', 'pageSize=' . $stat->publishedPostsNum)->to($archives);
$year = 0; $mon = 0;
$output = '<div class="archives">'; // Start archives container

$output = '<div class="archives">'; // Start archives container
while ($archives->next()) {
$year_tmp = date('Y', $archives->created);
$mon_tmp = date('m', $archives->created);

$mon_tmp = date('m', $archives->created);
// 检查是否需要新的年份标题
if ($year != $year_tmp) {
if ($year > 0) {
Expand All @@ -34,8 +32,7 @@
$year = $year_tmp;
$mon = 0; // 重置月份
$output .= '<div class="archive-year"><h2 class="archive--title__year">' . $year . '</h2>'; // 开始新的年份div
}

}
// 检查是否需要新的月份标题
if ($mon != $mon_tmp) {
if ($mon > 0) {
Expand All @@ -45,13 +42,11 @@
$output .= '<h3 class="archive--title__month"></h3>';// '. $mon . '
$output .= '<ul class="archive--list">'; // 开始新的月份列表
}

// 输出文章项
$output .= '<li class="archive--item">';
$output .= '<div class="archive--title"><a href="' . $archives->permalink . '">' . $archives->title . '</a></div>';
$output .= '<div class="archive--meta">' . date('m月d日', $archives->created) . '</div></li>';
}

// 循环后,确保所有标签都已经关闭
if ($mon > 0) {
$output .= '</ul>'; // 结束最后一个月份的列表
Expand All @@ -60,7 +55,6 @@
$output .= '</div>'; // 结束最后一个年份的div
}
$output .= '</div>'; // End archives container

echo $output;
?>
</div>
Expand Down
2 changes: 1 addition & 1 deletion post.php
Original file line number Diff line number Diff line change
Expand Up @@ -241,4 +241,4 @@
</style>
<?php endif; ?>
</main>
<?php $this->need('footer.php'); ?>
<?php $this->need('footer.php'); ?>
4 changes: 1 addition & 3 deletions postlist.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,4 @@ class="icon--sticky" stroke="currentColor" stroke-width="2" stroke-linecap="roun
cursor: not-allowed;
}
/* 分页 */
</style>


</style>
3 changes: 1 addition & 2 deletions profile.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,4 @@
<div class="author--sns">
<?php $this->need('sns.php'); ?>
</div>
</div>

</div>

0 comments on commit bd3b384

Please sign in to comment.