@xingwangzhe/stalux 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +192 -0
- package/package.json +108 -0
- package/scripts/cli.mjs +103 -0
- package/src/assets/BiCcCircle.svg +1 -0
- package/src/assets/astro.svg +1 -0
- package/src/assets/background/README.md +3 -0
- package/src/assets/background/pattern-1.min.svg +1 -0
- package/src/assets/background/pattern-10.min.svg +1 -0
- package/src/assets/background/pattern-11.min.svg +1 -0
- package/src/assets/background/pattern-12.min.svg +1 -0
- package/src/assets/background/pattern-13.min.svg +1 -0
- package/src/assets/background/pattern-14.min.svg +1 -0
- package/src/assets/background/pattern-15.min.svg +1 -0
- package/src/assets/background/pattern-16.min.svg +1 -0
- package/src/assets/background/pattern-17.min.svg +1 -0
- package/src/assets/background/pattern-18.min.svg +1 -0
- package/src/assets/background/pattern-19.min.svg +1 -0
- package/src/assets/background/pattern-2.min.svg +1 -0
- package/src/assets/background/pattern-20.min.svg +1 -0
- package/src/assets/background/pattern-21.min.svg +1 -0
- package/src/assets/background/pattern-22.min.svg +1 -0
- package/src/assets/background/pattern-23.min.svg +1 -0
- package/src/assets/background/pattern-24.min.svg +1 -0
- package/src/assets/background/pattern-25.min.svg +1 -0
- package/src/assets/background/pattern-26.min.svg +1 -0
- package/src/assets/background/pattern-27.min.svg +1 -0
- package/src/assets/background/pattern-28.min.svg +1 -0
- package/src/assets/background/pattern-29.min.svg +1 -0
- package/src/assets/background/pattern-3.min.svg +1 -0
- package/src/assets/background/pattern-30.min.svg +1 -0
- package/src/assets/background/pattern-31.min.svg +1 -0
- package/src/assets/background/pattern-32.min.svg +1 -0
- package/src/assets/background/pattern-33.min.svg +1 -0
- package/src/assets/background/pattern-34.min.svg +1 -0
- package/src/assets/background/pattern-35.min.svg +1 -0
- package/src/assets/background/pattern-36.min.svg +1 -0
- package/src/assets/background/pattern-37.min.svg +1 -0
- package/src/assets/background/pattern-38.min.svg +1 -0
- package/src/assets/background/pattern-39.min.svg +1 -0
- package/src/assets/background/pattern-4.min.svg +1 -0
- package/src/assets/background/pattern-40.min.svg +1 -0
- package/src/assets/background/pattern-41.min.svg +1 -0
- package/src/assets/background/pattern-42.min.svg +1 -0
- package/src/assets/background/pattern-5.min.svg +1 -0
- package/src/assets/background/pattern-6.min.svg +1 -0
- package/src/assets/background/pattern-7.min.svg +1 -0
- package/src/assets/background/pattern-8.min.svg +1 -0
- package/src/assets/background/pattern-9.min.svg +1 -0
- package/src/assets/background.svg +1 -0
- package/src/assets/cc-icon.svg +4 -0
- package/src/assets/fonts/GoogleSansCode-Italic.woff2 +0 -0
- package/src/assets/fonts/GoogleSansCode.woff2 +0 -0
- package/src/assets/fonts/LXGWWenKai-Regular.ttf +0 -0
- package/src/assets/fonts/LXGWWenKai-Regular.woff2 +0 -0
- package/src/components/stalux/analytics/clarity.astro +25 -0
- package/src/components/stalux/analytics/google.astro +31 -0
- package/src/components/stalux/analytics/umami.astro +16 -0
- package/src/components/stalux/archives/archivesList.astro +116 -0
- package/src/components/stalux/archives/toArchive.astro +14 -0
- package/src/components/stalux/categories/categoriesCard.astro +49 -0
- package/src/components/stalux/categories/categoriesList.astro +17 -0
- package/src/components/stalux/common/author.astro +35 -0
- package/src/components/stalux/common/date.astro +59 -0
- package/src/components/stalux/common/search.astro +14 -0
- package/src/components/stalux/common/textType.astro +16 -0
- package/src/components/stalux/common/verCount.astro +10 -0
- package/src/components/stalux/footer/FooterBadges.astro +150 -0
- package/src/components/stalux/footer/FooterBeian.astro +91 -0
- package/src/components/stalux/footer/FooterCopyright.astro +40 -0
- package/src/components/stalux/footer/FooterStats.astro +108 -0
- package/src/components/stalux/footer/FooterThemeInfo.astro +67 -0
- package/src/components/stalux/layout/footer.astro +87 -0
- package/src/components/stalux/layout/head.astro +194 -0
- package/src/components/stalux/layout/listPage.astro +26 -0
- package/src/components/stalux/layout/navs.astro +174 -0
- package/src/components/stalux/links/linkCard.astro +50 -0
- package/src/components/stalux/links/linkList.astro +20 -0
- package/src/components/stalux/links/socialMedia.astro +102 -0
- package/src/components/stalux/posts/PhotoSwipeStyle.astro +3 -0
- package/src/components/stalux/posts/PostTaxonomy.astro +65 -0
- package/src/components/stalux/posts/WalineComment.astro +609 -0
- package/src/components/stalux/posts/postAuthor.astro +23 -0
- package/src/components/stalux/posts/postCC.astro +52 -0
- package/src/components/stalux/posts/postCard.astro +83 -0
- package/src/components/stalux/posts/postContent.astro +174 -0
- package/src/components/stalux/posts/postLeft.astro +41 -0
- package/src/components/stalux/posts/postList.astro +25 -0
- package/src/components/stalux/posts/postNavigation.astro +137 -0
- package/src/components/stalux/posts/postRight.astro +33 -0
- package/src/components/stalux/posts/postToc.astro +88 -0
- package/src/components/stalux/posts/randomPost.astro +134 -0
- package/src/components/stalux/tags/tagHeader.astro +50 -0
- package/src/components/stalux/tags/tagsCloud.astro +100 -0
- package/src/components/stalux/words/wordCard.astro +62 -0
- package/src/components/stalux/words/wordList.astro +70 -0
- package/src/config.ts +58 -0
- package/src/i18n/en.json +193 -0
- package/src/i18n/zh-CN.json +193 -0
- package/src/index.ts +215 -0
- package/src/internal/components-plugin.ts +54 -0
- package/src/internal/dev-toolbar.ts +33 -0
- package/src/internal/override.ts +99 -0
- package/src/internal/pagefind.ts +40 -0
- package/src/layouts/PostLayout.astro +90 -0
- package/src/layouts/Stalux.astro +91 -0
- package/src/pages/404.astro +103 -0
- package/src/pages/about.astro +59 -0
- package/src/pages/about.md.ts +15 -0
- package/src/pages/api/post.abbrlink.json.ts +20 -0
- package/src/pages/archives.astro +23 -0
- package/src/pages/archives.md.ts +24 -0
- package/src/pages/atom.xml.ts +29 -0
- package/src/pages/categories/[category].astro +35 -0
- package/src/pages/categories/[category].md.ts +34 -0
- package/src/pages/categories/index.astro +23 -0
- package/src/pages/categories/index.md.ts +27 -0
- package/src/pages/index.astro +30 -0
- package/src/pages/index.md.ts +18 -0
- package/src/pages/links.astro +23 -0
- package/src/pages/links.md.ts +18 -0
- package/src/pages/llms-full.txt.ts +25 -0
- package/src/pages/llms.txt.ts +26 -0
- package/src/pages/posts/[post].astro +69 -0
- package/src/pages/posts/[post].md.ts +109 -0
- package/src/pages/rss.xml.ts +29 -0
- package/src/pages/tags/[tag].astro +37 -0
- package/src/pages/tags/[tag].md.ts +34 -0
- package/src/pages/tags/index.astro +23 -0
- package/src/pages/tags/index.md.ts +27 -0
- package/src/pages/words.astro +24 -0
- package/src/pages/words.md.ts +14 -0
- package/src/plugins/feature-flags.ts +68 -0
- package/src/plugins/satteri-temml.ts +81 -0
- package/src/schemas/collections.ts +140 -0
- package/src/schemas/config.ts +226 -0
- package/src/scripts/background.ts +59 -0
- package/src/styles/base/init.css +286 -0
- package/src/styles/base/math.css +411 -0
- package/src/styles/components/archives/archivesList.module.css +378 -0
- package/src/styles/components/archives/toArchive.module.css +3 -0
- package/src/styles/components/categories/categoriesCard.module.css +87 -0
- package/src/styles/components/categories/categoriesList.module.css +27 -0
- package/src/styles/components/common/author.module.css +73 -0
- package/src/styles/components/common/date.module.css +15 -0
- package/src/styles/components/common/textType.module.css +10 -0
- package/src/styles/components/footer/footer.module.css +44 -0
- package/src/styles/components/layout/navs.module.css +250 -0
- package/src/styles/components/links/linkCard.module.css +99 -0
- package/src/styles/components/links/linkList.module.css +67 -0
- package/src/styles/components/links/socialLinks.module.css +22 -0
- package/src/styles/components/markdown.css +528 -0
- package/src/styles/components/posts/postAuthor.module.css +32 -0
- package/src/styles/components/posts/postCC.module.css +138 -0
- package/src/styles/components/posts/postCard.module.css +156 -0
- package/src/styles/components/posts/postCategories.module.css +50 -0
- package/src/styles/components/posts/postContent.module.css +230 -0
- package/src/styles/components/posts/postLayout.module.css +142 -0
- package/src/styles/components/posts/postLeft.module.css +38 -0
- package/src/styles/components/posts/postList.module.css +24 -0
- package/src/styles/components/posts/postNavigation.module.css +187 -0
- package/src/styles/components/posts/postRight.module.css +60 -0
- package/src/styles/components/posts/postSidebar.module.css +57 -0
- package/src/styles/components/posts/postTags.module.css +51 -0
- package/src/styles/components/posts/postTaxonomy.module.css +87 -0
- package/src/styles/components/posts/postToc.module.css +74 -0
- package/src/styles/components/posts/randomPost.module.css +131 -0
- package/src/styles/components/tags/tagHeader.module.css +44 -0
- package/src/styles/components/tags/tagsCloud.module.css +124 -0
- package/src/styles/components/words/wordCard.module.css +130 -0
- package/src/styles/components/words/wordList.module.css +39 -0
- package/src/styles/pages/archives.module.css +18 -0
- package/src/styles/pages/categories.module.css +13 -0
- package/src/styles/pages/home.module.css +51 -0
- package/src/styles/pages/listPage.module.css +13 -0
- package/src/styles/pages/tags.module.css +12 -0
- package/src/styles/pages/words.module.css +13 -0
- package/src/styles/shared/animations.css +87 -0
- package/src/styles/shared/stagger.css +20 -0
- package/src/utils/ai-discovery.ts +547 -0
- package/src/utils/badge-generator.ts +68 -0
- package/src/utils/cc.ts +46 -0
- package/src/utils/collections-stats.ts +48 -0
- package/src/utils/config-utils.ts +107 -0
- package/src/utils/count-words.ts +20 -0
- package/src/utils/dayjs.ts +106 -0
- package/src/utils/feed.ts +70 -0
- package/src/utils/i18n.ts +64 -0
- package/src/utils/lucide-icons.ts +52 -0
- package/src/utils/semantic-time.ts +11 -0
- package/src/utils/taxonomy.ts +44 -0
- package/src/utils/toc-scrollspy.ts +95 -0
- package/src/utils/waline.ts +27 -0
- package/src/utils/word-count-utils.ts +83 -0
- package/template/astro.config.mjs +51 -0
- package/template/package.json +27 -0
- package/template/public/robots.txt +3 -0
- package/template/src/content.config.ts +11 -0
- package/template/stalux/about/index.md +14 -0
- package/template/stalux/config/ai-discovery.yml +2 -0
- package/template/stalux/config/author.yml +4 -0
- package/template/stalux/config/comment.yml +5 -0
- package/template/stalux/config/footer.yml +13 -0
- package/template/stalux/config/head.yml +7 -0
- package/template/stalux/config/links.yml +4 -0
- package/template/stalux/config/media-links.yml +8 -0
- package/template/stalux/config/navs.yml +23 -0
- package/template/stalux/config/promote.yml +2 -0
- package/template/stalux/config/site.yml +7 -0
- package/template/stalux/config/typetexts.yml +5 -0
- package/template/stalux/posts/hello-stalux.md +47 -0
- package/template/stalux/words/_template.md +12 -0
- package/template/stalux/words/einstein-imagination.md +8 -0
- package/template/tsconfig.json +9 -0
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
.postContainer {
|
|
2
|
+
background-color: var(--card-bg);
|
|
3
|
+
border-radius: var(--radius-lg);
|
|
4
|
+
border: var(--border-thin) solid var(--card-border);
|
|
5
|
+
box-shadow: var(--card-box-shadow);
|
|
6
|
+
padding: var(--space-lg);
|
|
7
|
+
transition:
|
|
8
|
+
transform var(--transition-fast) ease,
|
|
9
|
+
box-shadow var(--transition-fast) ease;
|
|
10
|
+
cursor: pointer;
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-direction: column;
|
|
13
|
+
height: 100%;
|
|
14
|
+
gap: var(--space-lg);
|
|
15
|
+
box-sizing: border-box;
|
|
16
|
+
opacity: 0;
|
|
17
|
+
animation: fadeInUp 0.6s ease-in-out forwards;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
@keyframes fadeInUp {
|
|
21
|
+
from {
|
|
22
|
+
transform: translateY(12px);
|
|
23
|
+
opacity: 0;
|
|
24
|
+
}
|
|
25
|
+
to {
|
|
26
|
+
transform: translateY(0);
|
|
27
|
+
opacity: 1;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/* 封面图片 */
|
|
32
|
+
.postCover {
|
|
33
|
+
width: 100%;
|
|
34
|
+
height: 180px;
|
|
35
|
+
border-radius: var(--radius-md);
|
|
36
|
+
overflow: hidden;
|
|
37
|
+
flex-shrink: 0;
|
|
38
|
+
margin-bottom: 0.5rem;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.postCover img {
|
|
42
|
+
width: 100%;
|
|
43
|
+
height: 100%;
|
|
44
|
+
object-fit: cover;
|
|
45
|
+
transition: transform var(--transition-fast) ease;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.postContainer:hover .postCover img,
|
|
49
|
+
.postContainer:focus-within .postCover img {
|
|
50
|
+
transform: scale(1.05);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/* 文章元数据布局 */
|
|
54
|
+
.postMeta {
|
|
55
|
+
display: flex;
|
|
56
|
+
flex-direction: column;
|
|
57
|
+
gap: 0.6rem;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/* 卡片悬停和焦点效果 */
|
|
61
|
+
.postContainer {
|
|
62
|
+
transition:
|
|
63
|
+
transform var(--transition-fast) ease,
|
|
64
|
+
box-shadow var(--transition-fast) ease,
|
|
65
|
+
opacity var(--transition-fast) ease;
|
|
66
|
+
}
|
|
67
|
+
.postContainer:hover,
|
|
68
|
+
.postContainer:focus-within {
|
|
69
|
+
transform: translateY(-6px);
|
|
70
|
+
box-shadow: var(--card-box-shadow-hover);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.time {
|
|
74
|
+
display: inline-flex;
|
|
75
|
+
gap: 0.45rem;
|
|
76
|
+
align-items: center;
|
|
77
|
+
flex-wrap: wrap;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/* 日期和更新标签 */
|
|
81
|
+
.postDate,
|
|
82
|
+
.postUpdated {
|
|
83
|
+
display: inline-flex;
|
|
84
|
+
align-items: center;
|
|
85
|
+
gap: 0.35rem;
|
|
86
|
+
width: fit-content;
|
|
87
|
+
padding: 0.28rem 0.6rem;
|
|
88
|
+
border-radius: 10px;
|
|
89
|
+
font-size: 0.9rem;
|
|
90
|
+
line-height: 1.1;
|
|
91
|
+
color: #e8f2ff;
|
|
92
|
+
}
|
|
93
|
+
.postDate {
|
|
94
|
+
background: var(--date-bg);
|
|
95
|
+
border: 1px solid var(--date-border);
|
|
96
|
+
color: #e8f2ff;
|
|
97
|
+
}
|
|
98
|
+
.postUpdated {
|
|
99
|
+
background: var(--updated-bg);
|
|
100
|
+
border: 1px solid var(--updated-border);
|
|
101
|
+
color: #fff7de;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
/* 标签:胶囊形状 */
|
|
105
|
+
.postTags {
|
|
106
|
+
display: flex;
|
|
107
|
+
gap: 0.4rem;
|
|
108
|
+
flex-wrap: wrap;
|
|
109
|
+
align-items: center;
|
|
110
|
+
}
|
|
111
|
+
.postTags a {
|
|
112
|
+
text-decoration: none;
|
|
113
|
+
}
|
|
114
|
+
.postTag {
|
|
115
|
+
display: inline-block;
|
|
116
|
+
padding: 0.22rem 0.7rem;
|
|
117
|
+
border-radius: 9999px;
|
|
118
|
+
background: var(--tag-bg);
|
|
119
|
+
color: #fff;
|
|
120
|
+
font-size: 0.85rem;
|
|
121
|
+
line-height: 1;
|
|
122
|
+
}
|
|
123
|
+
.postTag:focus,
|
|
124
|
+
.postTag:hover {
|
|
125
|
+
background: var(--tag-bg-hover);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/* 分类:矩形块 */
|
|
129
|
+
.postCategories {
|
|
130
|
+
display: flex;
|
|
131
|
+
gap: 0.4rem;
|
|
132
|
+
flex-wrap: wrap;
|
|
133
|
+
align-items: center;
|
|
134
|
+
}
|
|
135
|
+
.postCategories a {
|
|
136
|
+
text-decoration: none;
|
|
137
|
+
}
|
|
138
|
+
.postCategory {
|
|
139
|
+
display: inline-block;
|
|
140
|
+
padding: 0.18rem 0.5rem;
|
|
141
|
+
border-radius: 6px;
|
|
142
|
+
background: var(--category-bg);
|
|
143
|
+
color: #fff;
|
|
144
|
+
font-size: 0.84rem;
|
|
145
|
+
line-height: 1;
|
|
146
|
+
}
|
|
147
|
+
.postCategory:focus,
|
|
148
|
+
.postCategory:hover {
|
|
149
|
+
background: var(--category-bg-hover);
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
/* 阅读更多链接对齐 */
|
|
153
|
+
.readMore {
|
|
154
|
+
margin-top: 0.6rem;
|
|
155
|
+
align-self: flex-start;
|
|
156
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
.categoriesContainer {
|
|
2
|
+
display: flex;
|
|
3
|
+
flex-direction: column;
|
|
4
|
+
gap: var(--space-xs);
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.title {
|
|
8
|
+
margin: 0;
|
|
9
|
+
font-size: var(--font-size-base);
|
|
10
|
+
font-weight: 600;
|
|
11
|
+
color: var(--white-90p);
|
|
12
|
+
padding-bottom: var(--space-sm);
|
|
13
|
+
border-bottom: var(--border-thin) solid var(--white-20p);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.categoryList {
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
gap: var(--space-sm);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.category {
|
|
23
|
+
display: inline-flex;
|
|
24
|
+
padding: var(--space-sm) var(--space-xs);
|
|
25
|
+
background: var(--white-05p);
|
|
26
|
+
color: var(--white-80p);
|
|
27
|
+
border-left: var(--border-thick) solid var(--accent-60p);
|
|
28
|
+
text-decoration: none;
|
|
29
|
+
transition:
|
|
30
|
+
color var(--transition-medium),
|
|
31
|
+
transform var(--transition-medium);
|
|
32
|
+
border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
|
|
33
|
+
font-size: var(--font-size-small);
|
|
34
|
+
transform: translateX(0);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.category:hover {
|
|
38
|
+
transform: translateX(4px);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.category:active {
|
|
42
|
+
transform: translateX(2px);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.empty {
|
|
46
|
+
color: var(--white-50p);
|
|
47
|
+
font-size: var(--font-size-small);
|
|
48
|
+
text-align: center;
|
|
49
|
+
padding: var(--space-md) 0;
|
|
50
|
+
}
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
/* 文章内容 - 主要文章区域 */
|
|
2
|
+
/* 注意:正文内容的排版样式(标题、段落、代码块、表格、引用块等)
|
|
3
|
+
统一在 src/styles/components/markdown.css 中管理。
|
|
4
|
+
本文件只负责文章区域的布局容器样式。 */
|
|
5
|
+
|
|
6
|
+
.articleContent {
|
|
7
|
+
flex: 1;
|
|
8
|
+
width: 100%;
|
|
9
|
+
min-height: 100vh;
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
box-sizing: border-box;
|
|
13
|
+
background: var(--black-10p);
|
|
14
|
+
border-radius: var(--radius-lg);
|
|
15
|
+
padding: var(--space-xl);
|
|
16
|
+
box-shadow: var(--shadow-sidebar);
|
|
17
|
+
transition: all var(--transition-normal) ease;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/* 文章标题 */
|
|
21
|
+
.articleHeader {
|
|
22
|
+
margin-bottom: 3rem;
|
|
23
|
+
padding-bottom: 2rem;
|
|
24
|
+
animation: fadeInUp 0.6s ease forwards;
|
|
25
|
+
opacity: 0;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.title {
|
|
29
|
+
font-size: 2.5rem;
|
|
30
|
+
font-weight: 700;
|
|
31
|
+
color: var(--white-full);
|
|
32
|
+
margin: 0 0 1.5rem;
|
|
33
|
+
line-height: 1.2;
|
|
34
|
+
text-align: center;
|
|
35
|
+
word-break: break-word;
|
|
36
|
+
text-shadow: var(--stalux-text-shadow);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.metadata {
|
|
40
|
+
display: flex;
|
|
41
|
+
flex-wrap: wrap;
|
|
42
|
+
justify-content: center;
|
|
43
|
+
gap: 1.5rem;
|
|
44
|
+
font-size: 0.95rem;
|
|
45
|
+
color: #ffffffb3;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.metaItem {
|
|
49
|
+
display: inline-flex;
|
|
50
|
+
align-items: center;
|
|
51
|
+
gap: 0.5rem;
|
|
52
|
+
transition: color var(--transition-fast) ease;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/* 文章阅读量统计 */
|
|
56
|
+
.pageStats {
|
|
57
|
+
margin-top: 1rem;
|
|
58
|
+
padding-top: 0.8rem;
|
|
59
|
+
border-top: 1px solid var(--white-10p);
|
|
60
|
+
font-size: 0.9rem;
|
|
61
|
+
color: #ffffffb3;
|
|
62
|
+
display: flex;
|
|
63
|
+
justify-content: center;
|
|
64
|
+
align-items: center;
|
|
65
|
+
gap: 1rem;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.pageStats span {
|
|
69
|
+
display: inline-flex;
|
|
70
|
+
align-items: center;
|
|
71
|
+
gap: 0.3rem;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.readingTime {
|
|
75
|
+
display: inline-flex;
|
|
76
|
+
align-items: center;
|
|
77
|
+
gap: 0.3rem;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
#vercount_value_page_pv {
|
|
81
|
+
font-weight: 600;
|
|
82
|
+
color: #ffffffb3;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
#vercount_container_page_pv {
|
|
86
|
+
transition: opacity 0.3s ease;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/* 阅读量单独一行并居中 */
|
|
90
|
+
.metaRow {
|
|
91
|
+
flex-basis: 100%;
|
|
92
|
+
display: flex;
|
|
93
|
+
justify-content: center;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
/* 文章身体 */
|
|
97
|
+
.body {
|
|
98
|
+
flex: 1;
|
|
99
|
+
animation: fadeInUp 0.6s ease 0.1s forwards;
|
|
100
|
+
opacity: 0;
|
|
101
|
+
/* 限制 Markdown 内容最大宽度,居中显示,避免侵占左右侧栏 */
|
|
102
|
+
width: min(900px, 100%);
|
|
103
|
+
max-width: 100%;
|
|
104
|
+
margin: 0 auto;
|
|
105
|
+
box-sizing: border-box;
|
|
106
|
+
padding: 0 1rem 2rem;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/* “查看 Markdown 原文”按钮 */
|
|
110
|
+
.sourceLinkRow {
|
|
111
|
+
margin-top: 1.2rem;
|
|
112
|
+
display: flex;
|
|
113
|
+
justify-content: center;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.sourceLink {
|
|
117
|
+
display: inline-flex;
|
|
118
|
+
align-items: center;
|
|
119
|
+
gap: 0.4rem;
|
|
120
|
+
padding: 0.5rem 1.1rem;
|
|
121
|
+
font-size: 0.85rem;
|
|
122
|
+
font-weight: 500;
|
|
123
|
+
color: var(--white-full);
|
|
124
|
+
text-decoration: none;
|
|
125
|
+
background: var(--white-10p);
|
|
126
|
+
border-top: 1px solid var(--white-20p);
|
|
127
|
+
border-right: 1px solid var(--white-20p);
|
|
128
|
+
border-left: 1px solid var(--white-20p);
|
|
129
|
+
border-bottom: 0;
|
|
130
|
+
border-radius: var(--radius-full, 999px);
|
|
131
|
+
transition:
|
|
132
|
+
background var(--transition-fast) ease,
|
|
133
|
+
transform var(--transition-fast) ease;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.sourceLink:hover,
|
|
137
|
+
.sourceLink:focus,
|
|
138
|
+
.sourceLink:active {
|
|
139
|
+
background: var(--accent, #ffffff22);
|
|
140
|
+
border-top-color: var(--accent, #ffffff44);
|
|
141
|
+
border-right-color: var(--accent, #ffffff44);
|
|
142
|
+
border-left-color: var(--accent, #ffffff44);
|
|
143
|
+
transform: translateY(-1px);
|
|
144
|
+
text-decoration: none;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
/* 覆盖全局 a::after 伪元素下划线动画 */
|
|
148
|
+
.sourceLink::after {
|
|
149
|
+
display: none !important;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
/* 文章页脚 */
|
|
153
|
+
.articleFooter {
|
|
154
|
+
margin-top: 3rem;
|
|
155
|
+
padding-top: 2rem;
|
|
156
|
+
border-top: 1px solid var(--white-10p);
|
|
157
|
+
animation: fadeInUp 0.6s ease 0.2s forwards;
|
|
158
|
+
opacity: 0;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.footerContent {
|
|
162
|
+
display: flex;
|
|
163
|
+
flex-direction: column;
|
|
164
|
+
gap: var(--space-lg);
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/* ---------- 响应式设计 ---------- */
|
|
168
|
+
|
|
169
|
+
@media (max-width: 1024px) {
|
|
170
|
+
.title {
|
|
171
|
+
font-size: 2rem;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.metadata {
|
|
175
|
+
gap: 1rem;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
@media (max-width: 768px) {
|
|
180
|
+
.articleContent {
|
|
181
|
+
margin: 0;
|
|
182
|
+
width: 100%;
|
|
183
|
+
padding: 0;
|
|
184
|
+
box-sizing: border-box;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.body {
|
|
188
|
+
width: 100%;
|
|
189
|
+
margin: 0;
|
|
190
|
+
padding: 0 0.75rem;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.articleHeader {
|
|
194
|
+
margin-bottom: 2rem;
|
|
195
|
+
padding: 1rem 1rem 0;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
.title {
|
|
199
|
+
font-size: 1.75rem;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
.metadata {
|
|
203
|
+
flex-direction: column;
|
|
204
|
+
gap: 0.75rem;
|
|
205
|
+
font-size: 0.85rem;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
.articleFooter {
|
|
209
|
+
margin-top: 2rem;
|
|
210
|
+
padding-top: 1.5rem;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
/* 响应式设计 */
|
|
214
|
+
.pageStats {
|
|
215
|
+
font-size: 0.85rem;
|
|
216
|
+
margin-top: 0.8rem;
|
|
217
|
+
padding-top: 0.6rem;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
@keyframes fadeInUp {
|
|
222
|
+
from {
|
|
223
|
+
opacity: 0;
|
|
224
|
+
transform: translateY(20px);
|
|
225
|
+
}
|
|
226
|
+
to {
|
|
227
|
+
opacity: 1;
|
|
228
|
+
transform: translateY(0);
|
|
229
|
+
}
|
|
230
|
+
}
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
/* 文章布局 - 文章页面的三列布局 */
|
|
2
|
+
|
|
3
|
+
.postLayout {
|
|
4
|
+
width: 100%;
|
|
5
|
+
min-height: 100vh;
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-direction: column;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.container {
|
|
11
|
+
flex: 1;
|
|
12
|
+
display: grid;
|
|
13
|
+
grid-template-columns: 280px 1fr 280px;
|
|
14
|
+
gap: 4rem;
|
|
15
|
+
max-width: 100%;
|
|
16
|
+
margin: 0 auto;
|
|
17
|
+
padding: 1.5rem 1rem;
|
|
18
|
+
width: 100%;
|
|
19
|
+
box-sizing: border-box;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/* 三列布局间距调整 */
|
|
23
|
+
.container > :nth-child(1) {
|
|
24
|
+
/* 左侧边栏 */
|
|
25
|
+
margin: 0;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.container > :nth-child(2) {
|
|
29
|
+
/* 中间内容 */
|
|
30
|
+
min-width: 0;
|
|
31
|
+
/* 防止长内容溢出 */
|
|
32
|
+
margin: 0;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.container > :nth-child(3) {
|
|
36
|
+
/* 右侧边栏 */
|
|
37
|
+
margin: 0;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/* 响应式设计 */
|
|
41
|
+
|
|
42
|
+
/* 大屏幕 */
|
|
43
|
+
@media (min-width: 1600px) {
|
|
44
|
+
.container {
|
|
45
|
+
grid-template-columns: 300px 1fr 300px;
|
|
46
|
+
gap: 4.5rem;
|
|
47
|
+
padding: 2rem 1.5rem;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/* 中大屏幕 */
|
|
52
|
+
@media (max-width: 1400px) {
|
|
53
|
+
.container {
|
|
54
|
+
grid-template-columns: 260px 1fr 260px;
|
|
55
|
+
gap: 3.5rem;
|
|
56
|
+
padding: 1.5rem 1rem;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/* 中屏幕 - 侧栏隐藏后改为单列 */
|
|
61
|
+
@media (max-width: 1200px) {
|
|
62
|
+
.container {
|
|
63
|
+
grid-template-columns: 1fr;
|
|
64
|
+
gap: 2rem;
|
|
65
|
+
padding: 1rem 0.75rem;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/* 手机端 */
|
|
70
|
+
@media (max-width: 768px) {
|
|
71
|
+
.postLayout {
|
|
72
|
+
padding: 0;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.container {
|
|
76
|
+
display: flex;
|
|
77
|
+
flex-direction: column;
|
|
78
|
+
gap: 2rem;
|
|
79
|
+
padding: 0;
|
|
80
|
+
margin: 0;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/* 手机端重排:先内容,后侧栏 */
|
|
84
|
+
.container > :nth-child(2) {
|
|
85
|
+
order: 1;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.container > :nth-child(1) {
|
|
89
|
+
order: 2;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.container > :nth-child(3) {
|
|
93
|
+
order: 3;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/* 小屏幕手机 */
|
|
98
|
+
@media (max-width: 480px) {
|
|
99
|
+
.postLayout {
|
|
100
|
+
padding: 0;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.container {
|
|
104
|
+
gap: 1.25rem;
|
|
105
|
+
padding: 0;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/* 打印样式 */
|
|
110
|
+
@media print {
|
|
111
|
+
.container {
|
|
112
|
+
grid-template-columns: 1fr;
|
|
113
|
+
gap: 2rem;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.container > :nth-child(1),
|
|
117
|
+
.container > :nth-child(3) {
|
|
118
|
+
display: none;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/* 减少动画 */
|
|
123
|
+
@media (prefers-reduced-motion: reduce) {
|
|
124
|
+
.postLayout * {
|
|
125
|
+
animation-duration: 0.01ms !important;
|
|
126
|
+
animation-iteration-count: 1 !important;
|
|
127
|
+
transition-duration: 0.01ms !important;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
/* 高对比模式 */
|
|
132
|
+
@media (prefers-contrast: more) {
|
|
133
|
+
.container {
|
|
134
|
+
gap: 2rem;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
/* 无障碍访问焦点 */
|
|
139
|
+
.container :focus-visible {
|
|
140
|
+
outline: 2px solid var(--accent-80p);
|
|
141
|
+
outline-offset: 2px;
|
|
142
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/* 左侧边栏 */
|
|
2
|
+
|
|
3
|
+
.leftSidebar {
|
|
4
|
+
position: sticky;
|
|
5
|
+
top: 20px;
|
|
6
|
+
width: 100%;
|
|
7
|
+
height: fit-content;
|
|
8
|
+
max-height: calc(100vh - 40px);
|
|
9
|
+
overflow-y: auto;
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
gap: var(--space-lg);
|
|
13
|
+
padding: var(--space-lg) 0;
|
|
14
|
+
|
|
15
|
+
/* 隐藏滚动条但保留滚动功能 */
|
|
16
|
+
scrollbar-width: none;
|
|
17
|
+
-ms-overflow-style: none;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.leftSidebar::-webkit-scrollbar {
|
|
21
|
+
display: none;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
@media (max-width: 1200px) {
|
|
25
|
+
.leftSidebar {
|
|
26
|
+
display: none;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.sidebarContainer {
|
|
31
|
+
display: flex;
|
|
32
|
+
flex-direction: column;
|
|
33
|
+
background: var(--black-10p);
|
|
34
|
+
border-radius: var(--radius-lg);
|
|
35
|
+
padding: var(--space-md);
|
|
36
|
+
box-shadow: var(--shadow-sidebar);
|
|
37
|
+
transition: all var(--transition-normal) ease;
|
|
38
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
.container {
|
|
2
|
+
width: 100%;
|
|
3
|
+
height: auto;
|
|
4
|
+
margin: 5px 0;
|
|
5
|
+
ul {
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-wrap: wrap;
|
|
8
|
+
gap: 2rem;
|
|
9
|
+
padding: 0;
|
|
10
|
+
margin: 3em;
|
|
11
|
+
list-style: none;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
@media (max-width: 768px) {
|
|
15
|
+
ul {
|
|
16
|
+
margin: 1rem;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
ul > li {
|
|
21
|
+
flex: 1 1 22rem; /* 最小宽度 22rem,自动填充每行 */
|
|
22
|
+
margin: 0;
|
|
23
|
+
}
|
|
24
|
+
}
|