hexo-theme-stellar 2.0.0-rc.1 → 2.0.0-rc.3
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/CHANGELOG.md +58 -0
- package/README.md +54 -62
- package/README_EN.md +62 -39
- package/_config.yml +173 -68
- package/_data/icons.yml +1 -0
- package/assets/icon-v2-x512.webp +0 -0
- package/languages/en.yml +1 -0
- package/languages/zh-CN.yml +1 -0
- package/languages/zh-TW.yml +1 -0
- package/layout/404.ejs +4 -1
- package/layout/_partial/comments/beaudar/layout.ejs +1 -1
- package/layout/_partial/comments/giscus/layout.ejs +1 -1
- package/layout/_partial/comments/utterances/layout.ejs +1 -1
- package/layout/_partial/cover/wiki_cover.ejs +2 -1
- package/layout/_partial/head.ejs +21 -15
- package/layout/_partial/main/article/post_footer.ejs +1 -1
- package/layout/_partial/main/article/post_read_next.ejs +4 -1
- package/layout/_partial/main/footer.ejs +8 -8
- package/layout/_partial/main/navbar/article_banner.ejs +3 -1
- package/layout/_partial/main/pin_slider.ejs +33 -20
- package/layout/_partial/menubtn.ejs +1 -1
- package/layout/_partial/primitives/region.ejs +3 -3
- package/layout/_partial/primitives/shell.ejs +2 -1
- package/layout/_partial/scripts/defines.ejs +20 -119
- package/layout/_partial/scripts/runtime.ejs +10 -4
- package/layout/_partial/scripts.ejs +7 -27
- package/layout/_partial/search/dialog.ejs +1 -1
- package/layout/_partial/sidebar/brand.ejs +1 -1
- package/layout/_partial/widgets/related.ejs +1 -1
- package/layout/_partial/widgets/tagtree.ejs +2 -2
- package/layout/archive.ejs +14 -23
- package/layout/index.ejs +4 -0
- package/layout/layout.ejs +7 -4
- package/layout/page.ejs +1 -1
- package/layout/settings.ejs +1 -1
- package/package.json +17 -6
- package/scripts/commands/stellar.js +15 -3
- package/scripts/events/index.js +10 -23
- package/scripts/events/lib/authors.js +1 -0
- package/scripts/events/lib/doc_tree.js +8 -7
- package/scripts/events/lib/notebooks.js +6 -21
- package/scripts/filters/index.js +8 -3
- package/scripts/filters/lib/img.js +15 -0
- package/scripts/filters/lib/img_lazyload.js +1 -0
- package/scripts/filters/lib/img_onerror.js +21 -12
- package/scripts/filters/lib/md_link.js +26 -0
- package/scripts/filters/lib/page-view-model.js +36 -16
- package/scripts/generators/author.js +0 -1
- package/scripts/generators/notebooks.js +2 -2
- package/scripts/generators/search.js +3 -3
- package/scripts/generators/stellar-icons.js +2 -0
- package/scripts/helpers/collection.js +3 -3
- package/scripts/helpers/comments_model.js +2 -2
- package/scripts/helpers/extension_assets.js +16 -2
- package/scripts/helpers/json_ld.js +5 -4
- package/scripts/helpers/md_link.js +7 -0
- package/scripts/helpers/page_meta.js +2 -0
- package/scripts/helpers/post_view_model.js +15 -12
- package/scripts/helpers/script_json.js +3 -0
- package/scripts/lib/brand.js +2 -2
- package/scripts/lib/browser-runtime.js +4 -11
- package/scripts/lib/collection-pipeline/adapters/notebook.js +4 -6
- package/scripts/lib/collection-pipeline/adapters/post.js +5 -2
- package/scripts/lib/collection-pipeline/adapters/topic.js +15 -10
- package/scripts/lib/collection-pipeline/index.js +13 -8
- package/scripts/lib/comments.js +20 -2
- package/scripts/lib/config-schema.js +13 -3
- package/scripts/lib/content-config.js +35 -23
- package/scripts/lib/content-defaults.js +8 -4
- package/scripts/lib/contribution-contract.js +8 -16
- package/scripts/lib/contribution-registry.js +103 -52
- package/scripts/lib/doctor.js +14 -10
- package/scripts/lib/hero-effect-registry.js +0 -8
- package/scripts/lib/html-images.js +7 -6
- package/scripts/lib/image-metadata.js +308 -0
- package/scripts/lib/internal-constants.js +3 -29
- package/scripts/lib/models/index.js +21 -1533
- package/scripts/lib/models/notebook.js +292 -0
- package/scripts/lib/models/post.js +72 -0
- package/scripts/lib/models/shared.js +571 -0
- package/scripts/lib/models/topic.js +201 -0
- package/scripts/lib/models/wiki.js +413 -0
- package/scripts/lib/page-view-model-registry.js +126 -82
- package/scripts/lib/partial-navigation.js +64 -0
- package/scripts/lib/resource-assets.js +19 -0
- package/scripts/lib/script-json.js +13 -0
- package/scripts/lib/source-config.js +26 -16
- package/scripts/schema/config-rules.js +33 -26
- package/scripts/schema/config-schema.js +2 -1
- package/scripts/schema/content-config-rules.js +3 -1
- package/scripts/schema/content-config-schema.js +6 -4
- package/scripts/schema/model-schema.js +21 -13
- package/scripts/tags/lib/albums.js +1 -1
- package/scripts/tags/lib/friends.js +1 -1
- package/scripts/tags/lib/ghcard.js +1 -1
- package/scripts/tags/lib/posters.js +1 -1
- package/scripts/tags/lib/sites.js +2 -2
- package/source/css/_appearances/_mixins.styl +14 -16
- package/source/css/_appearances/minimal.styl +80 -46
- package/source/css/_common/button.styl +2 -2
- package/source/css/_common/cap.styl +1 -1
- package/source/css/_common/highlight.styl +2 -3
- package/source/css/_common/html.styl +5 -1
- package/source/css/_common/input.styl +1 -1
- package/source/css/_common/md-link.styl +13 -0
- package/source/css/_common/span.styl +1 -1
- package/source/css/_common/title.styl +2 -2
- package/source/css/_common/toast.styl +1 -1
- package/source/css/_components/collection.styl +3 -3
- package/source/css/_components/layout.styl +42 -8
- package/source/css/_components/list.styl +5 -3
- package/source/css/_components/md.styl +1 -2
- package/source/css/_components/pages/archives.styl +4 -4
- package/source/css/_components/pages/article-story.styl +1 -1
- package/source/css/_components/pages/article-tech.styl +2 -2
- package/source/css/_components/partial/article-footer.styl +1 -1
- package/source/css/_components/partial/article-share.styl +3 -0
- package/source/css/_components/partial/bread-nav.styl +2 -2
- package/source/css/_components/partial/cover.styl +4 -4
- package/source/css/_components/partial/footer.styl +2 -2
- package/source/css/_components/partial/paginator.styl +1 -1
- package/source/css/_components/partial/post-panel.styl +3 -3
- package/source/css/_components/partial/related.styl +14 -3
- package/source/css/_components/pin-slider.styl +7 -4
- package/source/css/_components/sidebar/brand.styl +3 -3
- package/source/css/_components/sidebar/search.styl +44 -20
- package/source/css/_components/tag-plugins/banner.styl +1 -1
- package/source/css/_components/tag-plugins/chat.styl +2 -2
- package/source/css/_components/tag-plugins/copy.styl +1 -1
- package/source/css/_components/tag-plugins/emoji.styl +1 -0
- package/source/css/_components/tag-plugins/folders.styl +2 -2
- package/source/css/_components/tag-plugins/folding.styl +2 -2
- package/source/css/_components/tag-plugins/friends.styl +2 -2
- package/source/css/_components/tag-plugins/friends_posts.styl +4 -2
- package/source/css/_components/tag-plugins/gallery.styl +4 -3
- package/source/css/_components/tag-plugins/hashtag.styl +1 -1
- package/source/css/_components/tag-plugins/image.styl +2 -0
- package/source/css/_components/tag-plugins/inline-labels.styl +2 -2
- package/source/css/_components/tag-plugins/link.styl +1 -1
- package/source/css/_components/tag-plugins/mark.styl +2 -2
- package/source/css/_components/tag-plugins/mbti.styl +6 -4
- package/source/css/_components/tag-plugins/mdrender.styl +1 -1
- package/source/css/_components/tag-plugins/navbar.styl +1 -1
- package/source/css/_components/tag-plugins/note.styl +1 -1
- package/source/css/_components/tag-plugins/okr.styl +2 -2
- package/source/css/_components/tag-plugins/poetry.styl +2 -2
- package/source/css/_components/tag-plugins/quot.styl +4 -2
- package/source/css/_components/tag-plugins/rating.styl +2 -2
- package/source/css/_components/tag-plugins/read/paper.styl +3 -3
- package/source/css/_components/tag-plugins/read/reel.styl +3 -3
- package/source/css/_components/tag-plugins/sites.styl +2 -2
- package/source/css/_components/tag-plugins/tabs.styl +1 -1
- package/source/css/_components/tag-plugins/timeline.styl +6 -6
- package/source/css/_components/tag-plugins/toc.styl +2 -2
- package/source/css/_components/tag-plugins/vote.styl +2 -2
- package/source/css/_components/widgets/ghrepo.styl +1 -1
- package/source/css/_components/widgets/ghuser.styl +4 -4
- package/source/css/_components/widgets/markdown.styl +3 -0
- package/source/css/_components/widgets/settings.styl +2 -2
- package/source/css/_components/widgets/toc.styl +24 -3
- package/source/css/_components/widgets/widgets.styl +1 -1
- package/source/css/_components/wiki-card.styl +3 -3
- package/source/css/_custom.styl +1 -0
- package/source/css/_defines/func.styl +2 -2
- package/source/css/_defines/theme_base.styl +0 -2
- package/source/css/_defines/typography.styl +10 -0
- package/source/css/_plugins/card-hover.styl +46 -43
- package/source/css/_plugins/index.styl +1 -1
- package/source/css/comments/artalk.styl +1 -1
- package/source/css/comments/twikoo.styl +2 -2
- package/source/css/comments/waline.styl +1 -1
- package/source/css/plugins/swiper.styl +2 -1
- package/source/js/color.js +21 -85
- package/source/js/main.js +63 -56
- package/source/js/navigation-init.js +58 -0
- package/source/js/plugins/adaptive-text.js +51 -25
- package/source/js/plugins/card-hover.js +5 -3
- package/source/js/plugins/download-file.js +26 -28
- package/source/js/plugins/video.js +22 -63
- package/source/js/profile.js +2 -0
- package/source/js/runtime/asset-loader.js +43 -34
- package/source/js/runtime/extension-registry.js +78 -57
- package/source/js/runtime/extensions/adaptive-text.js +14 -0
- package/source/js/runtime/extensions/card-hover.js +3 -2
- package/source/js/runtime/extensions/code-copy.js +19 -0
- package/source/js/runtime/extensions/comments.js +4 -3
- package/source/js/runtime/extensions/deferred-icons.js +13 -7
- package/source/js/runtime/extensions/diagrams.js +20 -0
- package/source/js/runtime/extensions/hero-effect.js +7 -3
- package/source/js/runtime/extensions/heti.js +12 -0
- package/source/js/runtime/extensions/lazy-loading.js +74 -0
- package/source/js/runtime/extensions/lightbox.js +28 -0
- package/source/js/runtime/extensions/link-prefetch.js +5 -0
- package/source/js/runtime/extensions/mathjax.js +24 -0
- package/source/js/runtime/extensions/page-controls.js +14 -0
- package/source/js/runtime/extensions/partial-navigation.js +172 -0
- package/source/js/runtime/extensions/reveal.js +29 -8
- package/source/js/runtime/extensions/search.js +4 -1
- package/source/js/runtime/extensions/services.js +113 -16
- package/source/js/runtime/extensions/settings.js +14 -10
- package/source/js/runtime/extensions/swiper.js +22 -0
- package/source/js/runtime/image-color.js +211 -0
- package/source/js/runtime/index.js +60 -43
- package/source/js/runtime/legacy-request-adapter.js +2 -0
- package/source/js/runtime/request-cache.js +26 -0
- package/source/js/search/algolia-search.js +1 -1
- package/source/js/search/highlight.js +6 -9
- package/source/js/search/local-search.js +128 -81
- package/source/js/services/artalk_latest_comment.js +6 -4
- package/source/js/services/contributors.js +6 -3
- package/source/js/services/friends.js +7 -4
- package/source/js/services/friends_and_posts.js +7 -4
- package/source/js/services/ghinfo.js +6 -3
- package/source/js/services/giscus_latest_comment.js +6 -3
- package/source/js/services/mdrender.js +10 -9
- package/source/js/services/memos.js +9 -3
- package/source/js/services/rating.js +13 -10
- package/source/js/services/rss.js +6 -3
- package/source/js/services/siteinfo.js +43 -14
- package/source/js/services/sites.js +9 -6
- package/source/js/services/timeline.js +6 -3
- package/source/js/services/twikoo_latest_comment.js +10 -5
- package/source/js/services/vote.js +11 -8
- package/source/js/services/waline_latest_comment.js +6 -3
- package/source/js/services/weibo.js +6 -3
- package/source/js/tagtree.js +7 -7
- package/scripts/events/lib/fix_image_tags.js +0 -44
- package/scripts/events/lib/get_image_ratios.js +0 -110
- package/source/js/runtime/extensions/feature.js +0 -200
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,63 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2.0.0-rc.3
|
|
4
|
+
|
|
5
|
+
> 发布日期:2026-09-10
|
|
6
|
+
|
|
7
|
+
本节记录从公开候选 `2.0.0-rc.2` 到 `2.0.0-rc.3` 最终文件树的净变化。
|
|
8
|
+
|
|
9
|
+
### 新功能
|
|
10
|
+
|
|
11
|
+
- 默认启用同集合局部导航:外壳兼容时更新正文、右栏和页面元数据,保留导航区域;支持历史滚动恢复,不兼容页面或请求失败时整页跳转。
|
|
12
|
+
- 图片尺寸与 HSLA 平均色在 server/generate 时自动增量提取并持久缓存,补全生成 HTML,不修改 Markdown 或原图;新增 `hexo stellar images` 及 `--dry-run/--page/--refresh` 选项。
|
|
13
|
+
- Markdown 文本链接、文章参考链接、远程 Markdown 与评论链接支持站点图标增强;站点信息支持 `appicon/favicon`,保留 `icon` 回退,行内请求失败显示断链图标。
|
|
14
|
+
- 新增字体平滑与设计字重映射;卡片 Spotlight 与 Tilt 可独立开关。
|
|
15
|
+
- 第三方 JS/CSS 地址可在对应搜索、评论、Feature 或 Markdown 服务配置中覆盖;Artalk 默认使用服务端配套资源。
|
|
16
|
+
|
|
17
|
+
### 修复与改进
|
|
18
|
+
|
|
19
|
+
- 共享 Collection 模型并隔离构建缓存,复用 PageViewModel 和归档文章投影,减少重复解析与校验;忽略 Collection 目录中的 macOS `.DS_Store` 文件。
|
|
20
|
+
- 完善 Extension 的页面/文档作用域、异步取消及卸载清理;修复 Flying Pages 初始化、图片懒加载与 Safari 错误占位时序,Reveal 待入场透明度在卸载时恢复。
|
|
21
|
+
- 修复文章上下篇、作者页 Topic 文章与作者横幅;Topic 文章默认继承全局分享配置,Wiki 与 Notebook 仍默认关闭分享。
|
|
22
|
+
- Doctor 与构建统一恢复可用的配置:普通字段问题和不适用的表现参数给出 warning,缺少集合显示名时使用 Collection ID;根结构与归属冲突仍阻止构建。
|
|
23
|
+
- 本地搜索按章节组织结果并分批查询、渲染,改进摘要、高亮、加载更多和结束提示。
|
|
24
|
+
- 调整 minimal 外观、暗色背景、移动导航、品牌、目录吸顶与当前条目滚动;修复 Markdown Widget 背景、稀疏 Wiki 网格宽度、画廊列数以及轮播、图片标签、头像、MBTI 卡片的比例与布局。
|
|
25
|
+
- GitHub 卡片默认服务切换为 `https://github-stats-extended.vercel.app`;图片颜色处理新增 Sharp 直接依赖。
|
|
26
|
+
|
|
27
|
+
### 升级注意(配置变更与破坏性改动)
|
|
28
|
+
|
|
29
|
+
- 将 `footer.sections` 改为 `footer.sitemap`;分组保留 `title/items`,但 items 中的 `{title, url}` 对象需改写为 `'[标题](地址)'` Markdown 字符串。默认 sitemap 为空数组;默认页脚正文新增 CC BY-NC-SA 4.0 说明,可自行覆盖 `footer.content`。
|
|
30
|
+
- 将 `features.card_hover.enabled` 替换为独立的 `spotlight` 与 `tilt` 布尔值;希望保持原先全部开启效果时两项均设为 `true`,默认均为 `false`。
|
|
31
|
+
- `features.partial_navigation.enabled` 默认开启,含非主题管理可执行脚本的页面使用整页导航;需要全部整页跳转时将其关闭。
|
|
32
|
+
- `features.image_optimization.enabled` 默认开启,首次处理远程图片可能增加构建时间;关闭后仍复用站点 `source/_data/caches/images_metadata.json`。`features.lazy_loading.auto_aspect_ratio` 继续控制尺寸/比例补全。
|
|
33
|
+
- 第三方资源覆盖不保证任意上游 API 版本兼容;KaTeX 自定义 CSS 时需配套更新 `css_integrity`,或设为 `null` 不附加 SRI。仅覆盖 CSS 地址时会清除继承的旧哈希。
|
|
34
|
+
|
|
35
|
+
Full Changelog: [2.0.0-rc.2...2.0.0-rc.3](https://github.com/xaoxuu/hexo-theme-stellar/compare/2.0.0-rc.2...2.0.0-rc.3)
|
|
36
|
+
|
|
37
|
+
## 2.0.0-rc.2
|
|
38
|
+
|
|
39
|
+
> 发布日期:2026-09-07
|
|
40
|
+
|
|
41
|
+
本节记录从公开候选 `2.0.0-rc.1` 到 `2.0.0-rc.2` 最终文件树的净变化。
|
|
42
|
+
|
|
43
|
+
### 新功能
|
|
44
|
+
|
|
45
|
+
- Notebook 列表、设置页与错误页的专属配置统一收敛到 `profiles`;404 页新增默认关闭的评论区,可独立覆盖标题、线程、Provider 与参数。
|
|
46
|
+
- 可信页面注入补全 `head_begin/head_end/body_begin/body_end` 四个位置,站点主题配置与页面 Front Matter 使用同一合并顺序和原样输出语义。
|
|
47
|
+
|
|
48
|
+
### 修复与工程变化
|
|
49
|
+
|
|
50
|
+
- 将 `hexo-front-matter` 声明为主题直接依赖,避免源码配置与 `stellar new note` 依赖 Hexo 宿主的传递依赖。
|
|
51
|
+
- 重构中英文 README,明确 npm、源码与 Blueprint 三种安装入口,并补充随 npm 包分发的 Stellar 图标、项目描述、关键词和作者元数据。
|
|
52
|
+
|
|
53
|
+
### 升级注意(配置变更与破坏性改动)
|
|
54
|
+
|
|
55
|
+
- 从 RC1 升级时,将顶层 `notebook` 移到 `profiles.notebook`,将 `settings.about` 移到 `profiles.settings.about`,将 `error_page.image` 移到 `profiles.error.image`。
|
|
56
|
+
- `profiles.notebook_index` 更名为 `profiles.notebooks`,`profiles.note_index` 更名为 `profiles.notebook`;Note 内容页继续使用 `profiles.note`。
|
|
57
|
+
- `inject` 内容会作为可信 HTML 原样输出;只应配置维护者完全信任的内容,站点级内容在前、页面 Front Matter 在后。
|
|
58
|
+
|
|
59
|
+
Full Changelog: [2.0.0-rc.1...2.0.0-rc.2](https://github.com/xaoxuu/hexo-theme-stellar/compare/2.0.0-rc.1...2.0.0-rc.2)
|
|
60
|
+
|
|
3
61
|
## 2.0.0-rc.1
|
|
4
62
|
|
|
5
63
|
> 发布日期:2026-09-07
|
package/README.md
CHANGED
|
@@ -1,81 +1,87 @@
|
|
|
1
|
-
|
|
1
|
+
<div align="center">
|
|
2
|
+
<img src="assets/icon-v2-x512.webp" width="160" alt="Stellar">
|
|
3
|
+
<h1>Stellar</h1>
|
|
4
|
+
<p>每个人的独立博客</p>
|
|
5
|
+
<p>基于 Hexo 的全能个人知识库,开箱即用,内置海量标签和动态数据组件。可用于个人博客、项目文档、知识库、专栏、笔记等。</p>
|
|
6
|
+
<p><a href="README.md">简体中文</a> · <a href="README_EN.md">English</a></p>
|
|
7
|
+
<p>
|
|
8
|
+
<a href="https://github.com/xaoxuu/hexo-theme-stellar/releases"><img src="https://img.shields.io/github/v/release/xaoxuu/hexo-theme-stellar" alt="release"></a>
|
|
9
|
+
<a href="https://www.npmjs.com/package/hexo-theme-stellar"><img src="https://img.shields.io/npm/v/hexo-theme-stellar" alt="npm"></a>
|
|
10
|
+
<a href="https://www.npmjs.com/package/hexo-theme-stellar"><img src="https://img.shields.io/npm/dm/hexo-theme-stellar" alt="npm downloads"></a>
|
|
11
|
+
<a href="https://github.com/xaoxuu/hexo-theme-stellar"><img src="https://img.shields.io/github/stars/xaoxuu/hexo-theme-stellar" alt="stars"></a>
|
|
12
|
+
<a href="LICENSE"><img src="https://img.shields.io/github/license/xaoxuu/hexo-theme-stellar" alt="license"></a>
|
|
13
|
+
</p>
|
|
14
|
+
<p>
|
|
15
|
+
<a href="https://xaoxuu.com/wiki/stellar/start/install/">创建第一个博客</a> ·
|
|
16
|
+
<a href="https://xaoxuu.com/wiki/stellar/support/examples/">站点示例</a> ·
|
|
17
|
+
<a href="https://xaoxuu.com/wiki/stellar/">完整文档</a>
|
|
18
|
+
</p>
|
|
19
|
+
</div>
|
|
2
20
|
|
|
3
|
-
|
|
21
|
+
## 在纷繁中建立秩序
|
|
4
22
|
|
|
5
|
-
|
|
23
|
+
> 真正的简约不止删繁就简,而是在纷繁中建立秩序。
|
|
6
24
|
|
|
7
|
-
|
|
25
|
+
### 完善的内容组织体系
|
|
8
26
|
|
|
9
|
-
|
|
27
|
+
从普通文章开始。项目需要稳定的文档目录时,用 Wiki;文章逐渐形成系列时,收进专栏;零散知识需要长期积累时,放进笔记本。它们共享同一套导航、搜索、侧栏与阅读体验,没有启用的内容系统不会增加额外负担。
|
|
10
28
|
|
|
11
|
-
|
|
29
|
+
### 灵活的排版与表达方式
|
|
12
30
|
|
|
13
|
-
|
|
14
|
-
[](https://github.com/xaoxuu/hexo-theme-stellar/blob/main/LICENSE)
|
|
15
|
-
[](https://github.com/xaoxuu/hexo-theme-stellar)
|
|
16
|
-
[](https://www.npmjs.com/package/hexo-theme-stellar)
|
|
17
|
-
[](https://github.com/xaoxuu/hexo-theme-stellar/releases)
|
|
31
|
+
从外观预设、配色和字体,到分栏、选项卡、折叠块与图库,站点的样子和内容的表达方式都可以按需组合。本地搜索可以直接定位到相关章节,响应式布局会在窄屏上把主要空间留给正文。
|
|
18
32
|
|
|
19
|
-
|
|
33
|
+
### 静态页面,也能常看常新
|
|
20
34
|
|
|
21
|
-
|
|
35
|
+
手写内容沉淀观点,外部数据保持新鲜。远程内容、社区数据和外部服务可以按需加载,与静态正文保持解耦;经常变化的数据不必每次都随整站重新生成。
|
|
22
36
|
|
|
23
|
-
|
|
37
|
+
## 站点示例
|
|
24
38
|
|
|
25
|
-
|
|
39
|
+
[Stellar Examples](https://github.com/xaoxuu/hexo-theme-stellar-examples/) 提供可以直接运行的示例站,适合先体验接近自己目标的站点,再逐步替换内容与配置。更多真实站点见[站点示例](https://xaoxuu.com/wiki/stellar/support/examples/)。
|
|
26
40
|
|
|
27
|
-
|
|
41
|
+
## 开始使用
|
|
28
42
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
## 写作、检索和阅读是一件事
|
|
32
|
-
|
|
33
|
-
提示框、折叠、标签页、图库、时间线、聊天和表格等内容组件可以互相组合。Markdown 表达不够时,不需要临时拼一套风格各异的插件。
|
|
34
|
-
|
|
35
|
-
本地搜索由主题生成索引,结果可以直接落到文章章节;桌面端目录和信息栏到了手机上会变成抽屉,把位置让给正文。
|
|
43
|
+
### 环境要求
|
|
36
44
|
|
|
37
|
-
|
|
45
|
+
- Node.js 22 或更高版本
|
|
46
|
+
- Hexo 8 或更高版本
|
|
38
47
|
|
|
39
|
-
|
|
48
|
+
### 从蓝图创建
|
|
40
49
|
|
|
41
|
-
|
|
50
|
+
准备好 Git 和 npm 后,一条命令即可启动交互式蓝图安装器:
|
|
42
51
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
| 星迹 · Blog | 使用经典侧栏整理文章、分类与专栏 |
|
|
47
|
-
| 个人知识库 · Knowledge | 把博客、项目资料和长期主题放在一起 |
|
|
48
|
-
| 项目文档 · Docs | 给一个项目维护清晰的文档目录 |
|
|
52
|
+
```bash
|
|
53
|
+
sh -c "$(curl -fsSL https://github.com/xaoxuu/hexo-theme-stellar-examples/raw/main/install.sh)"
|
|
54
|
+
```
|
|
49
55
|
|
|
50
|
-
|
|
56
|
+
安装器会读取示例仓库的 [`blueprints.json`](https://github.com/xaoxuu/hexo-theme-stellar-examples/blob/main/blueprints.json),展示当前可用的蓝图,并依次确认蓝图、项目目录、依赖安装和创建计划。
|
|
51
57
|
|
|
52
|
-
|
|
58
|
+
### 从 npm 安装
|
|
53
59
|
|
|
54
|
-
|
|
60
|
+
在博客根目录安装 npm 当前提供的默认版本,并确认实际安装结果:
|
|
55
61
|
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
hexo-
|
|
59
|
-
node: '>= 22'
|
|
60
|
-
npm: '>= 10'
|
|
62
|
+
```bash
|
|
63
|
+
npm install hexo-theme-stellar
|
|
64
|
+
npm ls hexo-theme-stellar
|
|
61
65
|
```
|
|
62
66
|
|
|
63
|
-
###
|
|
67
|
+
### 跟随最新源码
|
|
64
68
|
|
|
65
|
-
|
|
69
|
+
将官方仓库的 `main` 分支添加为子模块,并安装主题自身的依赖:
|
|
66
70
|
|
|
67
71
|
```bash
|
|
68
72
|
git submodule add -b main https://github.com/xaoxuu/hexo-theme-stellar.git themes/stellar
|
|
69
73
|
npm install --prefix themes/stellar
|
|
70
74
|
```
|
|
71
75
|
|
|
72
|
-
|
|
76
|
+
### 启用并检查
|
|
77
|
+
|
|
78
|
+
在博客 `_config.yml` 中启用主题:
|
|
73
79
|
|
|
74
80
|
```yaml
|
|
75
81
|
theme: stellar
|
|
76
82
|
```
|
|
77
83
|
|
|
78
|
-
|
|
84
|
+
然后运行 Doctor 并生成站点:
|
|
79
85
|
|
|
80
86
|
```bash
|
|
81
87
|
npx hexo stellar doctor
|
|
@@ -84,29 +90,15 @@ npx hexo generate
|
|
|
84
90
|
|
|
85
91
|
完整步骤见[环境与安装](https://xaoxuu.com/wiki/stellar/start/install/)和[创建第一个站点](https://xaoxuu.com/wiki/stellar/start/first-site/)。
|
|
86
92
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
```bash
|
|
90
|
-
npm install hexo-theme-stellar
|
|
91
|
-
```
|
|
93
|
+
## 文档与社区
|
|
92
94
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
- [从第一篇文章开始](https://xaoxuu.com/wiki/stellar/start/first-site/)
|
|
98
|
-
- [把博客变成自己的样子](https://xaoxuu.com/wiki/stellar/start/configuration/)
|
|
99
|
-
- [用 Wiki 写项目文档](https://xaoxuu.com/wiki/stellar/guides/wiki/)
|
|
100
|
-
- [把文章整理成专栏](https://xaoxuu.com/wiki/stellar/guides/topic/)
|
|
101
|
-
- [建立自己的笔记本](https://xaoxuu.com/wiki/stellar/guides/notebook/)
|
|
95
|
+
- [配置自己的站点](https://xaoxuu.com/wiki/stellar/start/configuration/)
|
|
96
|
+
- [使用内容组件](https://xaoxuu.com/wiki/stellar/reference/tags/)
|
|
97
|
+
- [管理 Wiki、专栏与笔记本](https://xaoxuu.com/wiki/stellar/reference/collection/)
|
|
102
98
|
- [主题配置参考](https://xaoxuu.com/wiki/stellar/reference/theme/)
|
|
103
99
|
- [从 v1 迁移到 v2](https://xaoxuu.com/wiki/stellar/migration/v1-to-v2/)
|
|
104
|
-
|
|
105
|
-
## 社区
|
|
106
|
-
|
|
107
100
|
- [Issues](https://github.com/xaoxuu/hexo-theme-stellar/issues/):反馈可以复现的问题
|
|
108
101
|
- [Discussions](https://github.com/xaoxuu/hexo-theme-stellar/discussions/):交流使用经验和想法
|
|
109
|
-
- [蓝图与展示墙](https://xaoxuu.com/wiki/stellar/support/examples/):看看不同的人怎样使用 Stellar
|
|
110
102
|
- [贡献指南](CONTRIBUTING.md):参与主题开发与文档维护
|
|
111
103
|
|
|
112
104
|
## 开源许可
|
package/README_EN.md
CHANGED
|
@@ -1,79 +1,102 @@
|
|
|
1
|
-
|
|
1
|
+
<div align="center">
|
|
2
|
+
<img src="assets/icon-v2-x512.webp" width="160" alt="Stellar">
|
|
3
|
+
<h1>Stellar</h1>
|
|
4
|
+
<p>A blog that grows with your work</p>
|
|
5
|
+
<p>A complete, versatile, and feature-rich personal knowledge base designed to grow over time.</p>
|
|
6
|
+
<p><a href="README_EN.md">English</a> · <a href="README.md">简体中文</a></p>
|
|
7
|
+
<p>
|
|
8
|
+
<a href="https://github.com/xaoxuu/hexo-theme-stellar/releases"><img src="https://img.shields.io/github/v/release/xaoxuu/hexo-theme-stellar" alt="release"></a>
|
|
9
|
+
<a href="https://www.npmjs.com/package/hexo-theme-stellar"><img src="https://img.shields.io/npm/v/hexo-theme-stellar" alt="npm"></a>
|
|
10
|
+
<a href="https://www.npmjs.com/package/hexo-theme-stellar"><img src="https://img.shields.io/npm/dm/hexo-theme-stellar" alt="npm downloads"></a>
|
|
11
|
+
<a href="https://github.com/xaoxuu/hexo-theme-stellar"><img src="https://img.shields.io/github/stars/xaoxuu/hexo-theme-stellar" alt="stars"></a>
|
|
12
|
+
<a href="LICENSE"><img src="https://img.shields.io/github/license/xaoxuu/hexo-theme-stellar" alt="license"></a>
|
|
13
|
+
</p>
|
|
14
|
+
<p>
|
|
15
|
+
<a href="https://xaoxuu.com/wiki/stellar/start/install/">Create your first blog</a> ·
|
|
16
|
+
<a href="https://xaoxuu.com/wiki/stellar/support/examples/">Site examples</a> ·
|
|
17
|
+
<a href="https://xaoxuu.com/wiki/stellar/">Documentation</a>
|
|
18
|
+
</p>
|
|
19
|
+
</div>
|
|
2
20
|
|
|
3
|
-
|
|
21
|
+
## Bring order to everything you publish
|
|
4
22
|
|
|
5
|
-
|
|
23
|
+
> True simplicity is not just subtraction; it is creating order within complexity.
|
|
6
24
|
|
|
7
|
-
|
|
25
|
+
### A complete system for organizing content
|
|
8
26
|
|
|
9
|
-
|
|
27
|
+
Start with regular posts. Give a project its own Wiki when it needs stable documentation, collect related posts into a Topic, and keep evolving knowledge in a Notebook. They share the same navigation, search, sidebars, and reading experience, while unused content systems stay out of the way.
|
|
10
28
|
|
|
11
|
-
|
|
12
|
-
[](https://github.com/xaoxuu/hexo-theme-stellar/blob/main/LICENSE)
|
|
13
|
-
[](https://github.com/xaoxuu/hexo-theme-stellar)
|
|
14
|
-
[](https://www.npmjs.com/package/hexo-theme-stellar)
|
|
29
|
+
### Flexible layout and expression
|
|
15
30
|
|
|
16
|
-
|
|
31
|
+
From appearance presets, colors, and type to columns, tabs, folding sections, and galleries, you can shape both the site and the way its content is presented. Local search can take readers directly to a matching section, while responsive layouts leave the main space to the article on narrow screens.
|
|
17
32
|
|
|
18
|
-
|
|
33
|
+
### Static pages that stay fresh
|
|
19
34
|
|
|
20
|
-
|
|
35
|
+
Your writing preserves ideas while external data stays current. Remote content, community data, and external services can load on demand without being coupled to the static article, so frequently changing data does not require a full-site rebuild.
|
|
21
36
|
|
|
22
|
-
##
|
|
37
|
+
## Site examples
|
|
23
38
|
|
|
24
|
-
|
|
39
|
+
[Stellar Examples](https://github.com/xaoxuu/hexo-theme-stellar-examples/) provides runnable sites you can explore before replacing their content and configuration at your own pace. Visit [Site examples](https://xaoxuu.com/wiki/stellar/support/examples/) for more real sites.
|
|
25
40
|
|
|
26
|
-
|
|
41
|
+
## Get started
|
|
27
42
|
|
|
28
|
-
|
|
43
|
+
### Requirements
|
|
29
44
|
|
|
30
|
-
|
|
45
|
+
- Node.js 22 or newer
|
|
46
|
+
- Hexo 8 or newer
|
|
31
47
|
|
|
32
|
-
|
|
48
|
+
### Create from a Blueprint
|
|
33
49
|
|
|
34
|
-
|
|
35
|
-
| --- | --- |
|
|
36
|
-
| Light Blog | Essays, personal notes, and distraction-free reading |
|
|
37
|
-
| Blog | A classic sidebar blog with categories and series |
|
|
38
|
-
| Knowledge | A personal site combining articles and long-lived knowledge |
|
|
39
|
-
| Docs | Documentation for a single project |
|
|
50
|
+
With Git and npm available, launch the interactive Blueprint installer with one command:
|
|
40
51
|
|
|
41
|
-
|
|
52
|
+
```bash
|
|
53
|
+
sh -c "$(curl -fsSL https://github.com/xaoxuu/hexo-theme-stellar-examples/raw/main/install.sh)"
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
The installer reads the example repository's [`blueprints.json`](https://github.com/xaoxuu/hexo-theme-stellar-examples/blob/main/blueprints.json), presents the available Blueprints, then confirms the Blueprint, project directory, dependency installation, and creation plan.
|
|
57
|
+
|
|
58
|
+
### Install from npm
|
|
59
|
+
|
|
60
|
+
Install the default version currently provided by npm, then confirm what was installed:
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
npm install hexo-theme-stellar
|
|
64
|
+
npm ls hexo-theme-stellar
|
|
65
|
+
```
|
|
42
66
|
|
|
43
|
-
|
|
67
|
+
### Follow the latest source
|
|
44
68
|
|
|
45
|
-
|
|
69
|
+
Add the official repository's `main` branch as a submodule and install the theme's own dependencies:
|
|
46
70
|
|
|
47
71
|
```bash
|
|
48
72
|
git submodule add -b main https://github.com/xaoxuu/hexo-theme-stellar.git themes/stellar
|
|
49
73
|
npm install --prefix themes/stellar
|
|
50
74
|
```
|
|
51
75
|
|
|
52
|
-
Enable
|
|
76
|
+
### Enable and check
|
|
77
|
+
|
|
78
|
+
Enable the theme in your site's `_config.yml`:
|
|
53
79
|
|
|
54
80
|
```yaml
|
|
55
81
|
theme: stellar
|
|
56
82
|
```
|
|
57
83
|
|
|
58
|
-
Then
|
|
84
|
+
Then run Doctor and generate the site:
|
|
59
85
|
|
|
60
86
|
```bash
|
|
61
87
|
npx hexo stellar doctor
|
|
62
88
|
npx hexo generate
|
|
63
89
|
```
|
|
64
90
|
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
## Stable npm release
|
|
68
|
-
|
|
69
|
-
```bash
|
|
70
|
-
npm install hexo-theme-stellar
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
This command may still install v1. Run `npm ls hexo-theme-stellar` before using any v2 configuration.
|
|
91
|
+
See [Installation](https://xaoxuu.com/wiki/stellar/start/install/) and [Create your first site](https://xaoxuu.com/wiki/stellar/start/first-site/) for the complete workflow.
|
|
74
92
|
|
|
75
|
-
##
|
|
93
|
+
## Documentation and community
|
|
76
94
|
|
|
95
|
+
- [Configure your site](https://xaoxuu.com/wiki/stellar/start/configuration/)
|
|
96
|
+
- [Use content components](https://xaoxuu.com/wiki/stellar/reference/tags/)
|
|
97
|
+
- [Manage Wikis, Topics, and Notebooks](https://xaoxuu.com/wiki/stellar/reference/collection/)
|
|
98
|
+
- [Theme configuration reference](https://xaoxuu.com/wiki/stellar/reference/theme/)
|
|
99
|
+
- [Migrate from v1 to v2](https://xaoxuu.com/wiki/stellar/migration/v1-to-v2/)
|
|
77
100
|
- [Issues](https://github.com/xaoxuu/hexo-theme-stellar/issues/) for reproducible problems
|
|
78
101
|
- [Discussions](https://github.com/xaoxuu/hexo-theme-stellar/discussions/) for ideas and usage questions
|
|
79
102
|
- [Contributing](CONTRIBUTING.md) for code and documentation work
|