diff --git a/README.md b/README.md index 6e61653..8936270 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,20 @@ # WarmIsland 暖屿 -一座深夜里温暖、安静、治愈的小岛 — 具有独特气质的生活博客主题。 +一座深夜里温暖、安静、治愈的小岛 — 具有独特气质的生活博客主题,适用于 [Halo CMS](https://github.com/halo-dev/halo)。 -> 本项目由AI开发完成,人工仅进行部分功能测试及问题找寻 +> 本项目由 AI 开发完成,人工仅进行部分功能测试及问题找寻 + +## 特点 + +1. **响应式设计** — 适配桌面端与移动端,支持暗色模式 +2. **插件兼容性** — 适配 8 款常用 Halo 插件,安装即用 +3. **内置灯箱** — 主题内置 LightGallery 灯箱,支持 EXIF 信息展示;安装 lightgallery.js 插件后自动禁用内置灯箱 +4. **可配置性** — 丰富的后台设置项,支持自定义首页模块、文章卡片、导航栏样式等 +5. **性能优化** — 图片懒加载、CSS/HTML 压缩、requestAnimationFrame 节流、Vue 组件按需加载 + +## 预览 + +![WarmIsland Preview](https://trae-api-cn.mchost.guru/api/ide/v1/text_to_image?prompt=A%20warm%20and%20cozy%20blog%20theme%20preview%2C%20soft%20colors%2C%20clean%20layout%2C%20minimalist%20design%2C%20dark%20mode%20support&image_size=landscape_16_9) ## 已适配插件 @@ -12,9 +24,29 @@ | [图库](https://halo.run/store/apps/app-BmQJW) | `PluginPhotos` | `/photos` | 图片展示页面,支持分组、灯箱预览 | | [友情链接](https://halo.run/store/apps/app-hqbe) | `PluginLinks` | `/links` | 友链展示页面,支持分组展示 | | [朋友圈](https://github.com/halo-sigs/plugin-friends) | `plugin-friends` | `/friends` | RSS 订阅朋友圈页面 | -| [我的装备](https://github.com/halo-sigs/plugin-equipment) | `equipment` | `/equipment` | 装备展示页面,支持分组展示 | +| [装备管理](https://github.com/chengzhongxue/plugin-equipment) | `equipment` | `/equipments` | 装备展示页面,按分组展示,支持封面图 | +| [豆瓣](https://github.com/chengzhongxue/plugin-douban) | `plugin-douban` | `/douban` | 豆瓣记录页面,支持类型/状态/标签筛选,默认电影 | +| [Steam 信息展示](https://github.com/Tim0x0/halo-plugin-steam) | `PluginSteam` | `/steam` | Steam 游戏库页面,含用户资料、统计数据、最近游玩、游戏库分页 | +| [足迹](https://github.com/acanyo/halo-plugin-footprint) | `footprint` | `/footprints` | 足迹地图页面,保留插件原有样式 + 主题导航栏 | -> **注意**:插件需要单独安装,安装后主题会自动适配对应页面。若未安装某插件,对应页面会显示提示信息。 +> **注意**:插件需要单独安装,安装后主题会自动适配对应页面。若未安装某插件,对应页面不会出现。 + +## 灯箱集成 + +主题内置 LightGallery 灯箱,为图片提供放大预览功能,并支持 EXIF 信息展示。 + +### lightgallery.js 插件兼容 + +如安装 [lightgallery.js](https://www.lightgalleryjs.com/) 灯箱插件,主题内置灯箱将自动禁用,改由插件接管灯箱功能。以下为 lightgallery.js 插件的路径匹配规则和 DOM 节点选择器: + +| 页面 | 路径匹配规则 | 匹配区域 DOM 节点 | +|------|-------------|-------------------| +| 文章详情页 | `/archives/*` | `.wi-post__body` | +| 瞬间页 | `/moments` | `.wi-moments-page__content` | +| 图库页 | `/photos` | `.wi-photos-page__grid` | +| 自定义页面 | 用户自定义 | `.wi-page__body` | + +> **注意**:自定义页面的路径匹配由用户自行设定,此处仅提供 DOM 节点选择器 `.wi-page__body`。 ## 安装 @@ -33,21 +65,6 @@ npm run build 构建产物在 `templates/` 目录下,将其复制到 Halo 主题目录即可。 -## lightgallery.js 灯箱插件集成 - -如果你使用 [lightgallery.js](https://www.lightgalleryjs.com/) 灯箱插件来为图片添加放大预览功能,以下是各页面的路径匹配规则和 DOM 节点选择器: - -### 路径匹配与 DOM 节点 - -| 页面 | 路径匹配规则 | 匹配区域 DOM 节点 | -|------|-------------|-------------------| -| 文章详情页 | `/archives/*` | `.wi-post__body` | -| 瞬间页 | `/moments` | `.wi-moments-page__content` | -| 图库页 | `/photos` | `.wi-photos-page__grid` | -| 自定义页面 | 用户自定义 | `.wi-page__body` | - -> **注意**:自定义页面的路径匹配由用户自行设定,此处仅提供 DOM 节点选择器 `.wi-page__body`。 - ## 开发 ```bash diff --git a/settings.yaml b/settings.yaml index 93bc214..b4d0454 100644 --- a/settings.yaml +++ b/settings.yaml @@ -386,13 +386,6 @@ spec: name: friends_page_title label: 页面标题 value: 朋友圈 - - group: equipment - label: 我的装备 - formSchema: - - $formkit: text - name: equipment_page_title - label: 页面标题 - value: 装备 - group: messageboard label: 留言板 formSchema: diff --git a/src/components/Footer.astro b/src/components/Footer.astro index 11fc665..b0d5d16 100644 --- a/src/components/Footer.astro +++ b/src/components/Footer.astro @@ -35,12 +35,16 @@ const today = new Date(); - + diff --git a/src/components/HeroSection.astro b/src/components/HeroSection.astro index c579877..cb46ab0 100644 --- a/src/components/HeroSection.astro +++ b/src/components/HeroSection.astro @@ -3,6 +3,7 @@
@@ -17,7 +18,9 @@ > -
+
+ +

-
+ + + diff --git a/src/pages/equipment.astro b/src/pages/equipment.astro deleted file mode 100644 index 543e6ae..0000000 --- a/src/pages/equipment.astro +++ /dev/null @@ -1,208 +0,0 @@ ---- -import Layout from "../layouts/Layout.astro"; ---- - - - - - - -
-
-
-

- 装备 -

- -
- - - -

-
-
- -
- -
-
- -
-
-
-
-
- - -
-

装备插件加载异常,请检查插件状态

-
-
-
-
- -
-
-
-

装备

- -
-
-

装备功能需要安装「装备管理」插件,前往应用市场安装

-
-
-
-
- - diff --git a/src/pages/equipments.astro b/src/pages/equipments.astro new file mode 100644 index 0000000..f99d975 --- /dev/null +++ b/src/pages/equipments.astro @@ -0,0 +1,219 @@ +--- +import Layout from "../layouts/Layout.astro"; +--- + + + + + + +
+
+
+

装备

+ +
+ +
+ +
+

+
+
+ +
+ +
+
+ +
+
+

+

+

+
+
+
+
+
+
+
+
+
+ + diff --git a/src/pages/footprints.astro b/src/pages/footprints.astro new file mode 100644 index 0000000..00120e5 --- /dev/null +++ b/src/pages/footprints.astro @@ -0,0 +1,161 @@ +--- +import Navbar from "../components/Navbar.astro"; +import MobileMenu from "../components/MobileMenu.astro"; +import "../styles/main.scss"; +--- + + + + + + + + + + + + + + + + + + + + +
+
+ +
+

足迹2024

+

每一处足迹都充满了故事,那是对人生的思考和无限的风光。

+
+ +
+
+ + +
+ +
+ + + +
+ +
+ + +
+ +
+
+ 1000 公里 +
+
+
+ + + + diff --git a/src/pages/index.astro b/src/pages/index.astro index 5033eeb..faf9587 100644 --- a/src/pages/index.astro +++ b/src/pages/index.astro @@ -10,6 +10,10 @@ import HeroSection from "../components/HeroSection.astro"; +
+ + + diff --git a/src/styles/main.scss b/src/styles/main.scss index b2124c3..6d5ee6f 100644 --- a/src/styles/main.scss +++ b/src/styles/main.scss @@ -188,6 +188,7 @@ table { position: relative; z-index: 1; background-color: var(--bg); + width: 100%; } .wi-main--wide.wi-main--home { @@ -212,5 +213,6 @@ table { .wi-main--wide { max-width: 1400px; + width: 100%; margin: 0 auto; } diff --git a/theme.yaml b/theme.yaml index af1e751..c8c3c03 100644 --- a/theme.yaml +++ b/theme.yaml @@ -19,10 +19,6 @@ spec: description: 留言板 screenshot: file: page_messageboard.html - - name: Equipment - description: 装备 - screenshot: - file: equipment.html version: "1.0.0" requires: ">=2.24.0" license: diff --git a/theme.zip b/theme.zip deleted file mode 100644 index 43be12f..0000000 Binary files a/theme.zip and /dev/null differ