From abe1790ac17ff23c0d4abd8b903653c141282972 Mon Sep 17 00:00:00 2001 From: xy <10816187@qq.com> Date: Sun, 16 Aug 2026 15:40:26 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=9A=97=E8=89=B2=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E3=80=81=E4=B8=BB=E9=A2=98=E5=88=87=E6=8D=A2=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Post/List.astro | 16 ++++---- src/components/ThemeIcon.astro | 75 ++++++++++++++++++++++++++++++++++ src/layouts/Layout.astro | 2 +- src/layouts/PageHeader.astro | 7 +++- src/pages/archive.astro | 3 ++ src/pages/post/[...slug].astro | 8 +++- src/styles/global.css | 23 ++++++++--- 7 files changed, 117 insertions(+), 17 deletions(-) create mode 100644 src/components/ThemeIcon.astro diff --git a/src/components/Post/List.astro b/src/components/Post/List.astro index 8887ebc..37fd9d2 100644 --- a/src/components/Post/List.astro +++ b/src/components/Post/List.astro @@ -28,12 +28,12 @@ const {posts} = Astro.props align-items: baseline; gap: 20px; padding: 26px 0; - border-bottom: 1px solid #e8e8e8; + border-bottom: var(--border-secondary); } .post .d { font-size: 14px; - color: #b8b8b8; + color: var(--text-secondary); min-width: 80px; letter-spacing: 1px; } @@ -42,18 +42,18 @@ const {posts} = Astro.props font-size: 16px; font-weight: normal; flex: 1; + } + + .post h2 a { + color: var(--text-primary); + text-decoration: none; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; } - .post h2 a { - color: #181818; - text-decoration: none; - } - .post h2 a:hover { - color: #334155; + color: var(--text-title-hover); text-decoration: underline; text-underline-offset: 6px; } diff --git a/src/components/ThemeIcon.astro b/src/components/ThemeIcon.astro new file mode 100644 index 0000000..3c3239a --- /dev/null +++ b/src/components/ThemeIcon.astro @@ -0,0 +1,75 @@ +--- +--- +
+ +
+ + + + diff --git a/src/layouts/Layout.astro b/src/layouts/Layout.astro index 974e2fd..2452297 100644 --- a/src/layouts/Layout.astro +++ b/src/layouts/Layout.astro @@ -42,7 +42,7 @@ const pageTitle = title ? `${title} - ${siteTitle}` : siteTitle;