From bd3b384fde1cd58f557eb85660afa8cbaf0b657e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B5=AA=E5=AD=90?= Date: Thu, 30 May 2024 14:47:29 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=94=B9=E7=89=88=E6=9C=AC=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dist/js/bundle.js | 2 +- page-archives.php | 12 +++--------- post.php | 2 +- postlist.php | 4 +--- profile.php | 3 +-- 5 files changed, 7 insertions(+), 16 deletions(-) diff --git a/dist/js/bundle.js b/dist/js/bundle.js index 1cbdef1..c37dde0 100644 --- a/dist/js/bundle.js +++ b/dist/js/bundle.js @@ -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(); diff --git a/page-archives.php b/page-archives.php index 65cb4eb..3f1439d 100644 --- a/page-archives.php +++ b/page-archives.php @@ -20,12 +20,10 @@ if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?> $stat = Typecho_Widget::widget('Widget_Stat'); Typecho_Widget::widget('Widget_Contents_Post_Recent', 'pageSize=' . $stat->publishedPostsNum)->to($archives); $year = 0; $mon = 0; - $output = '
'; // Start archives container - + $output = '
'; // 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) { @@ -34,8 +32,7 @@ if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?> $year = $year_tmp; $mon = 0; // 重置月份 $output .= '

' . $year . '

'; // 开始新的年份div - } - + } // 检查是否需要新的月份标题 if ($mon != $mon_tmp) { if ($mon > 0) { @@ -45,13 +42,11 @@ if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?> $output .= '

';// '. $mon . ' $output .= '
    '; // 开始新的月份列表 } - // 输出文章项 $output .= '
  • '; $output .= ''; $output .= '
    ' . date('m月d日', $archives->created) . '
  • '; } - // 循环后,确保所有标签都已经关闭 if ($mon > 0) { $output .= '
'; // 结束最后一个月份的列表 @@ -60,7 +55,6 @@ if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?> $output .= '
'; // 结束最后一个年份的div } $output .= '
'; // End archives container - echo $output; ?>
diff --git a/post.php b/post.php index 6cacc85..1cb47a6 100644 --- a/post.php +++ b/post.php @@ -241,4 +241,4 @@ document.addEventListener('DOMContentLoaded', (event) => { -need('footer.php'); ?> +need('footer.php'); ?> \ No newline at end of file diff --git a/postlist.php b/postlist.php index 146092c..8392b66 100644 --- a/postlist.php +++ b/postlist.php @@ -119,6 +119,4 @@ cursor: not-allowed; } /* 分页 */ - - - \ No newline at end of file + \ No newline at end of file diff --git a/profile.php b/profile.php index 39c4da1..97cf72f 100644 --- a/profile.php +++ b/profile.php @@ -10,5 +10,4 @@
need('sns.php'); ?>
- - \ No newline at end of file + \ No newline at end of file