@linxin666/dsh-client-ui-skin-center 0.4.2 → 0.4.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/README.i18n.yaml +2 -2
- package/README.md +17 -1
- package/README.zh.md +17 -1
- package/contracts/semantic-attrs-v1.md +7 -6
- package/lib/client.js +825 -556
- package/lib/client.js.map +1 -1
- package/lib/index.js +135 -430
- package/package.json +1 -1
- package/skins/blue-fantasy/patches.css +42 -1
package/README.i18n.yaml
CHANGED
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
# side as of the last confirmed-consistent state. Both languages carry equal authority;
|
|
3
3
|
# after editing either side, bring the other along and re-record with:
|
|
4
4
|
# node scripts/verify-docs.mjs --write <dir>
|
|
5
|
-
README.md:
|
|
6
|
-
README.zh.md:
|
|
5
|
+
README.md: 8fc72ea8f5f3518ef2ca8c2149ab02924dbdc8db
|
|
6
|
+
README.zh.md: 7ed5f3ff164123f0381713bab88161ec37f7ebba
|
package/README.md
CHANGED
|
@@ -15,6 +15,22 @@ English | [中文](README.zh.md)
|
|
|
15
15
|
- Wallpaper Engine bridge: the card can use the machine's local Wallpaper Engine library as the GUI backdrop. The host half (`src/we-library.ts` + `src/we-routes.ts`) locates the WE install (Steam app 431960: registry, every path in `libraryfolders.vdf`, durable `appmanifest_431960.acf` ownership, and probe paths on Windows), scans its projects and workshop content plus optional manual folders, and serves the inventory, media (Range-streamed), previews, web-wallpaper project files (with the WE API shim injected), and scene main-texture PNGs (decoded in-process from PKG/TEX by `src/pkg-extract.ts`, cached on disk) through same-origin `/api/skin-center/we/*` routes. Video wallpapers render in a `<video>`, web wallpapers in a sandboxed `<iframe>`, scene wallpapers live in the built-in WebGL player (2D layered scenes and 3D model scenes replayed with WE material/shader semantics); scene-embedded scripts are ignored while supported image, reflection, water and particle passes remain live, and a "static frame" render mode pins a zero-animation-cost image for any type. Per-wallpaper Import copies the project into `<harness-home>/skin-center/wallpapers/` so it survives Steam library changes, with update detection against the workshop original. Wallpapers are the user's own local files and are never uploaded or redistributed — Workshop content belongs to its authors. The Manual folders row accepts loose `.mp4`/`.webm` media, one project, a project collection, a Wallpaper Engine install root, or a Steam library root (`~` expands to the home directory).
|
|
16
16
|
- Legacy migration: on the first boot after the v2 upgrade, a one-shot bridge (`src/legacy-bridge.ts`) reads the retired `dsh-skin` managed section from the harness home `cordis.patch.yml` (where the v1 CLI wrote it; the active profile's `cordis.patch.yml` is probed as a secondary location), migrates the active skin id into the v2 selection store, and strips the legacy rows. The migration is idempotent and fails closed (the old state stays untouched on any error). It logs only when it migrated, cleaned, or failed — the nothing-to-migrate steady state stays silent (issue #788).
|
|
17
17
|
|
|
18
|
+
## Most popular skins
|
|
19
|
+
|
|
20
|
+
The three most-liked skins in the Workshop's skin category on [dsh-market.com](https://dsh-market.com), in the site's default popularity order:
|
|
21
|
+
|
|
22
|
+
| Skin | Author | Look |
|
|
23
|
+
|---|---|---|
|
|
24
|
+
| [Abyssal Maid Atelier](https://dsh-market.com/#skin:maid-atelier) (`maid-atelier`) | Small-tailqwq | Twin-maid atelier backdrop, deep-sea blue lace surfaces and a chibi sidebar |
|
|
25
|
+
| [Whale Song](https://dsh-market.com/#skin:whale-song) (`whale-song`) | dsh-web | Deep-sea whale goddess backdrop, ice-blue ocean palette and gold hairlines |
|
|
26
|
+
| [Blue Fantasy](https://dsh-market.com/#skin:blue-fantasy) (`blue-fantasy`) | powerdog996 (DreamSkin community), adapted by dsh-web | Whale-illustration backdrop, periwinkle indigo palette and translucent panels |
|
|
27
|
+
|
|
28
|
+
| Abyssal Maid Atelier | Whale Song | Blue Fantasy |
|
|
29
|
+
|---|---|---|
|
|
30
|
+
|  |  |  |
|
|
31
|
+
|
|
32
|
+
Install any of them from the Workshop in one click; `blue-fantasy` is also the skin this package ships as its built-in default.
|
|
33
|
+
|
|
18
34
|
## Install
|
|
19
35
|
|
|
20
36
|
```sh
|
|
@@ -51,7 +67,7 @@ skin-center is a self-contained bundle meeting the official DSH plugin standard
|
|
|
51
67
|
|
|
52
68
|
## Telemetry
|
|
53
69
|
|
|
54
|
-
The browser half sends one anonymous install heartbeat per UTC day to dsh-market.com: a random localStorage id plus this package's name, nothing else. The server stores only a salted hash of that id, never IP addresses, and exposes aggregate counts only. See [docs/telemetry.md](
|
|
70
|
+
The browser half sends one anonymous install heartbeat per UTC day to dsh-market.com: a random localStorage id plus this package's name, nothing else. The server stores only a salted hash of that id, never IP addresses, and exposes aggregate counts only. See [docs/telemetry.md](../../docs/telemetry.md) for the full contract.
|
|
55
71
|
|
|
56
72
|
## Directory structure
|
|
57
73
|
|
package/README.zh.md
CHANGED
|
@@ -15,6 +15,22 @@
|
|
|
15
15
|
- Wallpaper Engine 桥:卡片可把本机 Wallpaper Engine 库用作 GUI 背景。host 半区(`src/we-library.ts` + `src/we-routes.ts`)定位 WE 安装(Steam 应用 431960:Windows 注册表、`libraryfolders.vdf` 中的全部库路径、持久的 `appmanifest_431960.acf` 所有权事实与探测路径),扫描项目与创意工坊内容及可选手动文件夹,经同源 `/api/skin-center/we/*` 路由提供清单、媒体(Range 流式)、预览图、web 壁纸项目文件(注入 WE API shim)与场景壁纸主贴图 PNG(由 `src/pkg-extract.ts` 进程内解码 PKG/TEX,磁盘缓存)。视频壁纸用 `<video>` 渲染,web 壁纸用沙箱 `<iframe>`,场景壁纸经内置 WebGL 播放器实时渲染(2D 图层场景与 3D 模型场景按 WE 材质/着色器语义回放);场景内嵌脚本会被忽略,但受支持的图像、反射、水面与粒子通道仍保持实时渲染,「静态帧」模式可为任意类型钉一张零动画开销的图。单张壁纸的导入会把项目复制进 `<harness-home>/skin-center/wallpapers/`,脱离 Steam 库变更也能用,并检测创意工坊原作更新。壁纸都是用户本机文件,从不上传或再分发——创意工坊内容归原作者。「手动文件夹」行可接收零散 `.mp4`/`.webm` 媒体、单个项目、项目合集、Wallpaper Engine 安装根目录或 Steam 库根目录(`~` 展开为主目录)。
|
|
16
16
|
- 旧版迁移:v2 升级后的首次启动,一次性桥(`src/legacy-bridge.ts`)读取 harness home 根 `cordis.patch.yml`(v1 CLI 写入处;活动 profile 的 `cordis.patch.yml` 作为次级位置也会探测)里已退役的 `dsh-skin` 受管段,把活动皮肤 id 迁进 v2 选择存储,并清除旧行。迁移幂等且 fail-closed(出错时旧状态原样保留)。仅在发生迁移、清理或失败时输出日志,无 legacy 状态的稳态保持静默(issue #788)。
|
|
17
17
|
|
|
18
|
+
## 人气皮肤
|
|
19
|
+
|
|
20
|
+
[dsh-market.com](https://dsh-market.com) 创意工坊皮肤分类里人气最高的三款皮肤,按网站默认的「按人气」排序:
|
|
21
|
+
|
|
22
|
+
| 皮肤 | 作者 | 外观 |
|
|
23
|
+
|---|---|---|
|
|
24
|
+
| [深海女仆工坊](https://dsh-market.com/#skin:maid-atelier)(`maid-atelier`) | Small-tailqwq | 双女仆工坊背景、深海蓝蕾丝界面与 Q 版侧栏 |
|
|
25
|
+
| [鲸吟](https://dsh-market.com/#skin:whale-song)(`whale-song`) | dsh-web | 深海鲸语女神背景 · 冰蓝海洋调色板 · 金色细线点缀 |
|
|
26
|
+
| [蓝色幻想](https://dsh-market.com/#skin:blue-fantasy)(`blue-fantasy`) | powerdog996(DreamSkin 社区)· dsh-web 适配 | 鲸鱼插画背景 · periwinkle 靛蓝调色板 · 半透明面板 |
|
|
27
|
+
|
|
28
|
+
| 深海女仆工坊 | 鲸吟 | 蓝色幻想 |
|
|
29
|
+
|---|---|---|
|
|
30
|
+
|  |  |  |
|
|
31
|
+
|
|
32
|
+
三款都可从创意工坊一键安装;其中 `blue-fantasy` 同时也是本包内置的默认皮肤。
|
|
33
|
+
|
|
18
34
|
## 安装
|
|
19
35
|
|
|
20
36
|
```sh
|
|
@@ -51,7 +67,7 @@ dsh plugin --profile web add @linxin666/dsh-client-ui-skin-center
|
|
|
51
67
|
|
|
52
68
|
## 数据遥测
|
|
53
69
|
|
|
54
|
-
浏览器半区每个 UTC 日向 dsh-market.com 发送一次匿名安装心跳:仅含一个 localStorage 随机 ID 与本包名,无其他数据。服务端只存储该 ID 的加盐哈希,不存 IP,且只暴露聚合计数。完整契约见 [docs/telemetry.md](
|
|
70
|
+
浏览器半区每个 UTC 日向 dsh-market.com 发送一次匿名安装心跳:仅含一个 localStorage 随机 ID 与本包名,无其他数据。服务端只存储该 ID 的加盐哈希,不存 IP,且只暴露聚合计数。完整契约见 [docs/telemetry.md](../../docs/telemetry.md)。
|
|
55
71
|
|
|
56
72
|
## 目录结构
|
|
57
73
|
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
| `data-dsh-wallpaper-active` | html + body(body/html 级,另行管理) | WE 壁纸挂载期间置 `true`,卸载 / 禁用清除;供皮肤 CSS 与壁纸中和规则锚定(#734) |
|
|
46
46
|
| `data-dsh-wallpaper-surface` | 官方 shell 全视口背景元素 + 侧栏工作区淡化条(元素级) | `WallpaperController.markWallpaperSurfaces()` 在 WE 壁纸挂载期间打标(全视口 bg-base 背景 + `data-slot="sidebar.workspaces"` 内渐变淡化条),命中 `html[data-dsh-wallpaper-active] [data-dsh-wallpaper-surface]` 中和;卸载清除,不含哈希类依赖(#734) |
|
|
47
47
|
|
|
48
|
-
## part 组(
|
|
48
|
+
## part 组(81 行,含各 owner 行)
|
|
49
49
|
|
|
50
50
|
shell 区域(owner: shell):
|
|
51
51
|
|
|
@@ -92,16 +92,16 @@ family / 插件区域:
|
|
|
92
92
|
| `summon-button` | pet | 召唤钮;`[data-testid="pet-summon"]` |
|
|
93
93
|
| `preset-panel` | preset-center | 创意工坊「预设」标签页面板根;`[data-dsh-plugin="preset-center"] [data-dsh-part="preset-panel"]` |
|
|
94
94
|
| `plugin-item` | web-ui-settings | 家族插件设置卡;`[data-slot="web-ui.plugin.item"]` 内 entry |
|
|
95
|
-
| `
|
|
96
|
-
| `card` | skill-explorer | 技能中心模态卡;`[data-dsh-plugin="skill-explorer"] [data-dsh-part="card"]` |
|
|
97
|
-
| `tab-bar` / `tab` | skill-explorer | 技能中心页签条/页签;`[data-dsh-plugin="skill-explorer"] [data-dsh-part="tab-bar"]` / `[data-dsh-plugin="skill-explorer"] [data-dsh-part="tab"]` |
|
|
95
|
+
| `tab-bar` / `tab` | skill-explorer | 技能中心页签条/页签(中间列面板,同 ssh);`[data-dsh-plugin="skill-explorer"] [data-dsh-part="tab-bar"]` / `[data-dsh-plugin="skill-explorer"] [data-dsh-part="tab"]` |
|
|
98
96
|
| `skill-row` | skill-explorer | 技能卡行;`[data-dsh-plugin="skill-explorer"] [data-dsh-part="skill-row"]` |
|
|
99
|
-
| `filter-bar` | skill-explorer | 技能列表筛选条(搜索框 +
|
|
97
|
+
| `filter-bar` | skill-explorer | 技能列表筛选条(搜索框 + 工作区选择 + 刷新);`[data-dsh-plugin="skill-explorer"] [data-dsh-part="filter-bar"]` |
|
|
100
98
|
| `entry` | session-id | 侧栏 footer 触发器;`button[data-dsh-part="entry"]`(`[data-dsh-plugin="session-id"]` 容器内) |
|
|
101
99
|
| `panel` | session-id | 会话 ID 模态面板;`[role="dialog"]` 根(`[data-dsh-part="panel"]`) |
|
|
102
100
|
| `row` | session-id | 会话列表行;面板内行容器(`[data-dsh-part="row"]`) |
|
|
103
101
|
| `copy` | session-id | 每行复制按钮;`button[data-dsh-part="copy"]` |
|
|
104
102
|
| `search` | session-id | 面板搜索输入框;`input[type="search"][data-dsh-part="search"]` |
|
|
103
|
+
| `entry` | dsh-update | 侧栏 footer 更新触发器;`[data-dsh-plugin="update"] [data-dsh-part="entry"]` |
|
|
104
|
+
| `panel` | dsh-update | 更新面板模态根;`[data-dsh-plugin="update"] [data-dsh-part="panel"]` |
|
|
105
105
|
| `sprite` | miku-pet | 宠物帧舞台;`[data-dsh-plugin="miku-pet"] [data-dsh-part="sprite"]` |
|
|
106
106
|
| `menu` | miku-pet | 悬停菜单(两级);`[data-dsh-part="menu"]` |
|
|
107
107
|
| `stats` | miku-pet | 左侧属性彩条;`[data-dsh-part="stats"]` |
|
|
@@ -136,7 +136,7 @@ family / 插件区域:
|
|
|
136
136
|
| `lever-burst` | liangshen | 拨下命中后的中奖特效浮层(闪光 / 冲击环 / 火花 / 横幅);`[data-dsh-part="lever-burst"]`,`prefers-reduced-motion` 下退化为淡出 |
|
|
137
137
|
| `lever-banner` | liangshen | 特效中的梁神横幅(模式名 + 文言文/二进制/摩斯三行);burst 内 `[data-dsh-part="lever-banner"]` |
|
|
138
138
|
|
|
139
|
-
## plugin 组(
|
|
139
|
+
## plugin 组(14 个)
|
|
140
140
|
|
|
141
141
|
| data-dsh-plugin | owner | 锚定方式 |
|
|
142
142
|
| --- | --- | --- |
|
|
@@ -145,6 +145,7 @@ family / 插件区域:
|
|
|
145
145
|
| `git-graph` | dsh-git-graph | slot entry id `git-graph`;`[data-gitgraph-chip-anchor]` / `[data-gitgraph-dialog]` |
|
|
146
146
|
| `pet` | dsh-pet | `[data-dsh-pet-root]`;一级设置分区 settings.section id `pet`(只列内置与已安装宠物) |
|
|
147
147
|
| `remote-web-ui` | dsh-remote-web-ui | slot entry id `remote-web-ui` |
|
|
148
|
+
| `update` | dsh-update | footer action slot entry id `update`;`[data-dsh-plugin="update"]`(面板根 + 入口触发器) |
|
|
148
149
|
| `web-ui-settings` | dsh-web-settings | settings.section id `web-ui-plugins` |
|
|
149
150
|
| `skill-explorer` | dsh-skill-explorer | `[data-dsh-skill-explorer-view]` / `[data-dsh-skill-explorer-entry]` |
|
|
150
151
|
| `dsh-web-ui-market` | dsh-market | 创意工坊商店一级页(settings.section id `dsh-web-ui-market`),商店卡与目录条目容器 |
|