dsh-nook 0.3.0 → 0.3.1
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.md +40 -62
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,89 +1,67 @@
|
|
|
1
|
-
# Nook
|
|
1
|
+
# Nook · 角落小窝
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://www.npmjs.com/package/dsh-nook)
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
**在对话的角落,安放一处安静的微缩风景。**
|
|
6
|
+
*A quiet little world in the corner of your conversation.*
|
|
6
7
|
|
|
7
|
-
|
|
8
|
+

|
|
8
9
|
|
|
9
|
-
|
|
10
|
+
Nook 把一张治愈系 3D 微缩沙盘放在 DeepSeek Harness 对话面板的右下角。它不占正文的布局空间,四周用面板自己的底色做渐变,像一小块风景从白底里悄悄浮现。想细看就点一下——它 zoom out 铺满对话区;光标回到输入框,它自己缩回角落。
|
|
10
11
|
|
|
11
|
-
|
|
12
|
+
- **安静**:场景永远在文字下面,点一下才铺满,聚焦输入框就自动收回。
|
|
13
|
+
- **可换**:32 个场景(自然 / 水畔 / 城镇 / 旅途 / 集市 / 庭院 / 夜空 / 室内各 4 个),随机或指定,选择会记住。
|
|
14
|
+
- **可调**:画面浓度 35%–100%,淡到只剩一层颜色也行。
|
|
15
|
+
- **离线**:场景与 three.js 全部随包分发,运行时不联网。
|
|
12
16
|
|
|
13
|
-
|
|
14
|
-
- **开关**:菜单第一项控制这块场景是否显示。
|
|
15
|
-
- **换一个场景**:随机换一个(会跳过当前这个),菜单随即收起,好让你看到新场景。
|
|
16
|
-
- **场景列表**:32 个场景按题材分组,点选后固定使用这个场景(刷新也保持),选中后菜单收起。
|
|
17
|
-
- **画面浓度**:`−` / `+` 调节浓淡(35%–100%),越淡越像背景里晕开的一层颜色。
|
|
17
|
+
## 安装
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
- **Scene list** is grouped by theme; picking one pins it across reloads and closes the menu.
|
|
23
|
-
- **Presence** (`−` / `+`) fades the diorama (35%–100%); fainter reads as a tint in the corner.
|
|
19
|
+
```bash
|
|
20
|
+
dsh plugin --profile web add dsh-nook
|
|
21
|
+
```
|
|
24
22
|
|
|
25
|
-
|
|
23
|
+
或在 **插件 → 添加插件** 里输入 `dsh-nook`。入口在输入框工具行、模型选择器左侧。
|
|
26
24
|
|
|
27
|
-
|
|
25
|
+
## 场景
|
|
28
26
|
|
|
29
|
-
|
|
27
|
+

|
|
30
28
|
|
|
31
|
-
|
|
29
|
+
菜单里按题材分组,点一下就固定下来,刷新也还在。
|
|
32
30
|
|
|
33
|
-
|
|
34
|
-
| --- | --- | --- |
|
|
35
|
-
| `enabled` | `true` | 默认是否显示场景 |
|
|
36
|
-
| `scene` | `random` | `random` 或 `scenes/catalog.json` 里的某个场景 id |
|
|
37
|
-
| `opacity` | `1` | 场景浓度,0.35–1 |
|
|
38
|
-
| `rotateSeconds` | `0` | 每隔 N 秒随机换一个场景,0 为关闭;固定了某个场景时不轮换 |
|
|
31
|
+
## 配置
|
|
39
32
|
|
|
40
|
-
|
|
33
|
+
`cordis.patch.yml` 里 `nook` 这一行的 `config`,改完重新激活插件生效:
|
|
41
34
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
aspect-ratio: 5 / 4;
|
|
49
|
-
right: 10px; bottom: 108px;
|
|
50
|
-
```
|
|
51
|
-
|
|
52
|
-
`--dsh-chat-content-width` 是对话面板实时公布的正文栏宽,所以拖动会话宽度时场景窗会跟着变;窗口够宽时它基本填满右侧留白,太窄没有留白时退回 180px 的最小尺寸。底部 108px 让出约一行输入框的高度。
|
|
53
|
-
|
|
54
|
-
## 场景 / Scenes
|
|
35
|
+
| key | 默认 | 说明 |
|
|
36
|
+
| --- | --- | --- |
|
|
37
|
+
| `enabled` | `true` | 默认是否显示 |
|
|
38
|
+
| `scene` | `random` | `random` 或 `scenes/catalog.json` 里的场景 id |
|
|
39
|
+
| `opacity` | `1` | 画面浓度,0.35–1 |
|
|
40
|
+
| `rotateSeconds` | `0` | 每隔 N 秒随机换一个,0 为关闭 |
|
|
55
41
|
|
|
56
|
-
|
|
42
|
+
在界面里做过的选择优先于配置,存在浏览器本地。
|
|
57
43
|
|
|
58
|
-
##
|
|
44
|
+
## 致谢 / Thanks
|
|
59
45
|
|
|
60
|
-
-
|
|
61
|
-
-
|
|
62
|
-
-
|
|
63
|
-
- 场景画在正文下面(`z-index` 更低),文字和控件始终在场景之上;窄窗口下羽化区和正文右缘会略微重叠。
|
|
64
|
-
- 输入框展开成多行时会盖住场景已经淡化的下缘;放大态下场景在输入框之上,草稿超过约一行时输入框顶部会被淡化后的场景压住一点。
|
|
65
|
-
- 没有会话的冷启动首页不渲染输入框工具行,因此那里也不显示场景(装饰必须留一个关闭入口)。
|
|
66
|
-
- 对话面板有多处(例如右侧栏的对话),它们共用同一份设置,各自一份 iframe。
|
|
67
|
-
- 场景页面与主页面同源(同源才能加载 ES module);页面都是本地内置、构建时抓取并检查过没有外部请求的静态 HTML。
|
|
68
|
-
- 图形完全本地内置(`scenes/`),运行时不联网;`scripts/build-scenes.mjs` 可以重新抓取并生成同一批场景。
|
|
69
|
-
- 系统开启「减少动态效果」时,场景渲染约 1.6 秒后定格,画面保留但停止运动。
|
|
46
|
+
- 场景素材全部来自 **[Fable-Kawaii-3D-ThreeJS](https://huggingface.co/datasets/liumindmind/Fable-Kawaii-3D-ThreeJS)**(作者 [liumindmind](https://huggingface.co/liumindmind),MIT 许可)。谢谢作者把这些安静又可爱的微缩世界开源出来——这个插件做的事情只是把它们放进对话的角落,并努力不打扰人。README 里的示例图也来自该数据集的官方预览图。
|
|
47
|
+
- [three.js](https://github.com/mrdoob/three.js) r160(MIT),随场景一起本地分发。
|
|
48
|
+
- 每个场景页只做了三处改动:three.js 指向本地副本、注入一个「定格/恢复」钩子、隐藏场景自带的说明浮层。
|
|
70
49
|
|
|
71
|
-
##
|
|
50
|
+
## 开发
|
|
72
51
|
|
|
73
52
|
```bash
|
|
74
|
-
node scripts/build-scenes.mjs
|
|
53
|
+
node scripts/build-scenes.mjs # 重新抓取并生成场景
|
|
54
|
+
node --experimental-vm-modules scripts/check-scenes.mjs # 32 个场景构建自检
|
|
75
55
|
```
|
|
76
56
|
|
|
77
|
-
|
|
57
|
+
发布:改 `version` → `git tag v<version> && git push origin v<version>`,GitHub Actions 会先跑场景自检再 `npm publish --provenance`。
|
|
78
58
|
|
|
79
|
-
##
|
|
59
|
+
## English
|
|
80
60
|
|
|
81
|
-
|
|
82
|
-
node --experimental-vm-modules scripts/check-scenes.mjs
|
|
83
|
-
```
|
|
61
|
+
**Nook** keeps one kawaii 3D diorama in the bottom-right corner of the DSH conversation. It takes no layout space and no clicks; its rim melts into the panel fill, so it reads as a small landscape surfacing out of the page. Click it to fill the conversation, focus the composer and it settles back on its own. 32 scenes, randomly picked or chosen by hand, with an adjustable presence; everything is vendored, so it never touches the network.
|
|
84
62
|
|
|
85
|
-
|
|
63
|
+
Scenes come from [Fable-Kawaii-3D-ThreeJS](https://huggingface.co/datasets/liumindmind/Fable-Kawaii-3D-ThreeJS) by liumindmind (MIT) — with thanks.
|
|
86
64
|
|
|
87
|
-
##
|
|
65
|
+
## License
|
|
88
66
|
|
|
89
|
-
|
|
67
|
+
MIT · scenes and preview images © the Fable-Kawaii-3D-ThreeJS authors (MIT) · three.js © three.js authors (MIT). See [LICENSE](LICENSE).
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-nook",
|
|
3
|
-
"version": "0.3.
|
|
4
|
-
"description": "Nook
|
|
3
|
+
"version": "0.3.1",
|
|
4
|
+
"description": "Nook · 角落小窝 — a quiet kawaii 3D diorama in the corner of the DeepSeek Harness conversation. 32 scenes, click to fill the panel.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"dsh",
|
|
7
7
|
"dsh-plugin",
|