dsh-any-background 0.2.9 → 0.3.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/README.md +48 -27
- package/README.zh.md +48 -26
- package/lib/client.js +1294 -271
- package/lib/client.js.map +1 -1
- package/lib/index.js +200 -42
- package/package.json +23 -11
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<a href="https://www.npmjs.com/package/dsh-any-background"><img alt="npm version" src="https://img.shields.io/npm/v/dsh-any-background?color=4d6bfe"></a>
|
|
5
5
|
<a href="https://www.npmjs.com/package/dsh-any-background"><img alt="npm monthly downloads" src="https://img.shields.io/npm/dm/dsh-any-background?color=4d6bfe"></a>
|
|
6
6
|
<a href="https://github.com/Tkingxiao/dsh-any-background/blob/main/LICENSE"><img alt="License: MIT" src="https://img.shields.io/npm/l/dsh-any-background?color=4d6bfe"></a>
|
|
7
|
-
<a href="https://www.npmjs.com/package/@deepseek-ai/dsh?activeTab=versions"><img alt="Supported DSH
|
|
7
|
+
<a href="https://www.npmjs.com/package/@deepseek-ai/dsh?activeTab=versions"><img alt="Supported DSH versions: 0.1.5-rc.2 ~ 0.1.7-alpha.1" src="https://img.shields.io/badge/DSH-0.1.5--rc.2%20~%200.1.7--alpha.1-4d6bfe" /></a>
|
|
8
8
|
<a href="https://github.com/topics/dsh-better-sidebar"><img alt="Plugin ecosystem: GitHub topic dsh-better-sidebar" src="https://img.shields.io/badge/plugin%20ecosystem-topic%20dsh--better--sidebar-4d6bfe" /></a><br /><br />
|
|
9
9
|
<a href="https://github.com/Tkingxiao/dsh-any-background"><img src="https://img.shields.io/github/stars/Tkingxiao/dsh-any-background?style=social" alt="GitHub stars"></a>
|
|
10
10
|
<a href="https://dsh.directory/plugins/tkingxiao/dsh-any-background"><img src="https://dsh.directory/badges/listed.svg" alt="dsh.directory listed"></a>
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
|
|
13
13
|
English | [中文](README.zh.md)
|
|
14
14
|
|
|
15
|
-
A **DeepSeek Harness** appearance plugin: custom theme color, background wallpaper (image / video / algorithmically generated), and fine-grained per-surface opacity & blur controls.
|
|
15
|
+
A **DeepSeek Harness** appearance plugin: custom theme color, background wallpaper (image / video / algorithmically generated), and fine-grained per-surface opacity & blur controls. Compatible with **DSH 0.1.5-rc.2 ~ 0.1.7-alpha.1** (official-Sidebar features such as the "Theme" card appear only on hosts that expose the Sidebar registry API; older hosts skip them automatically).
|
|
16
16
|
|
|
17
17
|
---
|
|
18
18
|
|
|
@@ -71,42 +71,52 @@ A **DeepSeek Harness** appearance plugin: custom theme color, background wallpap
|
|
|
71
71
|
- **Position Editor** — One shared editor for images and videos: drag to pan, scroll or pinch to zoom, one-click reset. Image and video placements are stored separately and never overwrite each other.
|
|
72
72
|
- **Layout Modes** — Fit / Fill / Stretch / Tile / Center for both images and videos; in Fit mode the editor-committed framing stays consistent across window resizes and cross-monitor moves.
|
|
73
73
|
- **Generated Dynamic Backgrounds** — Choose mesh gradient, Shader, or geometric patterns with adjustable spread, intensity, and seed locking.
|
|
74
|
-
- **Per-surface Interface Opacity** — Independent sliders for the main background, sidebar, cards & panels (including the dropdowns and menus around the dialog), the input & controls (composer box, Cordis panel), the settings panel, the conversation text frame, the trajectory view, the
|
|
74
|
+
- **Per-surface Interface Opacity** — Independent sliders for the main background, sidebar, cards & panels (including the dropdowns and menus around the dialog), the input & controls (composer box, Cordis panel), the settings panel, the conversation text frame, the trajectory view, the right sidebar (or bettersidebar), produced / highlighted content, and the header popovers (Agent Team panel, background-job list and the session-header dropdowns).
|
|
75
75
|
- **Per-surface Interface Blur** — Frosted-glass `backdrop-filter` blur (0–60 px) per surface, including a real backdrop on the composer, the Cordis panel and popover surfaces via stable host selectors.
|
|
76
76
|
- **Produced / Highlights** — Code blocks in conversation content (with their language banner), inline `code` highlight chips and produced chips share one opacity + blur slider. The opacity is the alpha of **each surface's own background color** (no second color stacked on top of the original), and the blur frosts that same layer so the wallpaper shows through the content.
|
|
77
|
-
- **
|
|
77
|
+
- **Right sidebar / bettersidebar surface** — One slider pair (`panelOpacity` / `blurs.panel`), two identities: without dsh-better-sidebar it reads "右方侧边栏" (Right sidebar) and drives the official right Sidebar's surface tokens and frosted blur (works on 0.1.5-rc.2 through 0.1.7); with dsh-better-sidebar installed it reads "bettersidebar" and takes over that plugin's bottom workbench panel (the official sidebar keeps responding too). The row is always visible.
|
|
78
|
+
- **Header popovers** — The session-header dropdowns get their own opacity + blur pair: the Agent Team panel, the background-job list, the open-in-app / session-log menus and the subagent lineage tree. On 0.1.7 the open-in-app picker moved to a portal and the session-row menu became a dynamic slot, so the plugin observes the stable `conversation.session.header*` slot anchors and tags the open popover at runtime instead of relying on class shapes.
|
|
79
|
+
- **Sidebar "Theme" page (dual mode)** — The same five pages (Color / Interface / Font / Background / Profiles) register into two surfaces: without dsh-better-sidebar, a "Theme" card is contributed to the **official right Sidebar's guide page** through its public extension points (`sidebarRightTabs` + the `sidebar.right.pane.tab` keyed seat); with dsh-better-sidebar installed, the page registers in that plugin's sidebar instead and the official guide card withdraws itself, so the two never duplicate. Settings panel, official sidebar and better-sidebar all share one page implementation and one state store — a change in any of them shows up everywhere. The shell adapts to the panel width, and a narrow panel tightens padding and falls back to a single column. On a host without the right Sidebar the registration silently never happens.
|
|
78
80
|
- **Conversation View Cards** — The message list is wrapped in a translucent card automatically, and the trajectory page gets whole-page opacity & blur controls, letting the wallpaper shine through the content.
|
|
79
81
|
- **Theme Export / Import** — One-click export to a self-contained `dsh-any-theme.json` (config + wallpaper, video embedded as a data URL) and import to restore it anywhere.
|
|
80
82
|
- **Appearance Presets & Profiles** — Six one-click presets (Default / Frosted glass / Minimal / Midnight / Cyber / Warm daylight) plus named profiles: save the current look and re-apply it anytime. A two-step confirm guards deletion.
|
|
81
83
|
- **Wallpaper Rotation** — Add images to a rotation pool (thumbnail picker included) and let the wallpaper change by shuffle or order on every refresh, daily, or weekly. Advancing copies the chosen image into the active wallpaper slot, so export/import and color extraction keep working unchanged.
|
|
82
84
|
- **Day/Night Auto Switch** — Assign a day profile and a night profile; the plugin switches automatically at fixed clock times or by following the OS dark mode.
|
|
83
85
|
- **Custom Font** — Upload a ttf / otf / woff / woff2 file (up to 100 MB) and apply it to the whole interface through `@font-face`; toggle it off or remove it at any time. Fonts stream as raw bytes and persist in the plugin data dir; code blocks keep their monospace stack.
|
|
84
|
-
- **Per-part Text Outline** — The same
|
|
86
|
+
- **Per-part Text Outline** — The same surface groups as the interface page (now ten, including the header popovers), each with its own `-webkit-text-stroke`: width 0–4 px (0 = off) and a color of auto-contrast / gray / black / white / accent / custom. Code blocks, inline `code`, icons and the host's `background-clip: text` shimmer chrome (the "深度求索中" turn-status line and the turn-process rows) are exempted automatically, so multi-color syntax never smears and gradient text is never flattened into a stroke-coloured blob.
|
|
85
87
|
- **Forced Interface Scheme** — Force light or dark token palettes regardless of the accent color's lightness; in `Auto` both the surface and font directions follow the accent's lightness (dark pick → light fonts, light pick → dark fonts), falling back to the wallpaper's perceived brightness when no color is picked.
|
|
86
88
|
- **File-based Persistence** — All settings are stored on the filesystem under `~/.dsh/.dsh-any-background-data/`, not `localStorage`.
|
|
87
89
|
- **Bilingual** — Full Chinese / English UI with automatic locale detection.
|
|
88
90
|
- **Theme Watchdog** — Re-asserts the custom theme if the host resets it.
|
|
89
91
|
|
|
90
|
-
## Changelog
|
|
91
|
-
|
|
92
|
-
### v0.2.
|
|
93
|
-
|
|
94
|
-
- **
|
|
95
|
-
- **
|
|
96
|
-
- **
|
|
97
|
-
- **
|
|
98
|
-
|
|
99
|
-
- **
|
|
100
|
-
- **
|
|
101
|
-
-
|
|
102
|
-
-
|
|
103
|
-
|
|
104
|
-
### v0.2.
|
|
105
|
-
|
|
106
|
-
-
|
|
107
|
-
-
|
|
108
|
-
-
|
|
109
|
-
-
|
|
92
|
+
## Changelog (latest two releases)
|
|
93
|
+
|
|
94
|
+
### v0.3.0 (DSH 0.1.7 adaptation, compatible with 0.1.5-rc.2 ~ 0.1.7-alpha.1)
|
|
95
|
+
|
|
96
|
+
- **0.1.7 right Sidebar**: the host reworked that panel — it is now a *stationary* frame whose docked children (`[data-dockkit-host="dock"]` / `[data-dockkit-empty]`) carry the slide transform, and the panel no longer paints its own background. The plugin follows the new shape: the blur rides the sliding children so it travels with the sidebar instead of staying pinned, and the surface tokens are re-scoped where the panel actually renders. The previous unconditional `position:fixed` promotion was removed — on 0.1.7 it detached the panel from the animated track.
|
|
97
|
+
- **0.1.6 right Sidebar blur restored**: `[data-dockkit-host]` only exists from 0.1.7, so the child-based blur selector matched nothing on 0.1.6 (which slides the panel itself). A second, `:has()`-gated arm now frosts the panel wrapper there, and the pre-0.1.7 promotion is re-applied only where it is needed.
|
|
98
|
+
- **Gradient "shimmer" text is no longer flattened by the outline feature**: `-webkit-text-stroke` is inherited, so the conversation-frame rule reached the `background-clip: text` activity chrome — the "深度求索中" turn-status line (0.1.5/0.1.6) and the turn-process/shimmer rows (0.1.7) turned into a flat stroke-coloured blob. They are now explicitly exempt, matched by `[role="status"]`, `[data-turn-process]` and the TextShimmer marker.
|
|
99
|
+
- **New "Header popovers" surface**: the Agent Team panel, background-job list, open-in-app / session-log menus and the subagent lineage tree get their own opacity + blur sliders, plus a matching outline group. Because these popovers are portalled to `<body>` (severed from the header) and 0.1.7 moved open-in-app to a portal and made the session-row menu a dynamic slot, a runtime tagger watches the stable `conversation.session.header*` slot anchors and marks the open popover. The exempt confirm dialogs and session-row menu are pinned opaque with real color literals — no self-referencing `var()` fallback, which is a CSS cycle that would render them fully transparent.
|
|
100
|
+
- **Host release detection**: the client context exposes no host version (`window.__DSH_BOOT__.version` is a module-table tag, not a release), so the release plus a generation bucket is resolved on the Node half from the launcher's on-disk layout and handed to the client through the `read` RPC payload. Feature gates use it; when it cannot be determined they fall back to capability probing rather than guessing.
|
|
101
|
+
- **Native support for the official right Sidebar**: a "Theme" card is contributed to the official Sidebar's guide page through its public extension points (a page type in `ctx.sidebarRightTabs` plus the keyed `sidebar.right.pane.tab` body seat), opening the same five pages as the settings panel. Active without dsh-better-sidebar; when that plugin is present, its own "Theme" page takes over and the official guide card withdraws itself. Registration waits on the service at runtime — hosts without the Sidebar registry API skip it silently, so older hosts are unaffected.
|
|
102
|
+
- **The right-sidebar slider row follows the environment**: the Interface page's panel group (`panelOpacity` / `blurs.panel`) reads "右方侧边栏" (Right sidebar) without better-sidebar — driving the official right Sidebar's surface tokens and frosted blur on 0.1.5-rc.2 through 0.1.7 — and "bettersidebar" with it. The row is now always visible instead of hiding when better-sidebar is absent.
|
|
103
|
+
- The better-sidebar presence probe no longer counts `[data-sidebar-right-panel]`: on every host generation that is the official right Sidebar's stable marker (present whenever a session is open), so counting it pinned the "bettersidebar" verdict to true forever.
|
|
104
|
+
- Compatibility declarations now cover `0.1.5-rc.2`, `0.1.5-rc.3`, `0.1.6-alpha.1`, `0.1.6-alpha.2` and `0.1.7-alpha.1`; peerDependencies widened to span every generation of the client packages; `@deepseek-ai/dsh-home-paths` stays at the lockfile-consistent `^0.1.0-rc.6` (build-time only — the host injects its own copy at runtime).
|
|
105
|
+
|
|
106
|
+
### v0.2.10 (Last version 0.15 RC2 update)
|
|
107
|
+
|
|
108
|
+
- A "Theme" page in dsh-better-sidebar's sidebar: with better-sidebar installed, the sidebar gains a "Theme" card that opens the same five pages as the settings panel (Color / Interface / Font / Background / Profiles). Both surfaces share one page implementation and one state store, so a change in either place shows up in the other. The shell adapts to the panel width — card grids fill as many columns as fit (two from roughly 430px, three or four in a wider panel) and only a narrow panel tightens padding and drops back to a single column.
|
|
109
|
+
- Phone-width support for the settings panel: once the content column gets narrow, headings, card paddings, the color orb and the wheel card tighten up, and the card grids stop overflowing. Background type cards switch to width-based columns instead of being squeezed into one.
|
|
110
|
+
- The crash fallback now shows the error stack, so a broken panel explains itself without devtools.
|
|
111
|
+
- Fixed `getSnapshot is not a function` crashing the panel on some installs: the installed dsh-client-store is an older build whose `defineStore()` returns a declaration, not an instance, and the code treated it as an instance — which also silently disconnected the state sync (the settings panel kept showing defaults). The store is now normalized into one shared instance that both surfaces read; an unexpected shape in the future only warns and skips the sidebar page.
|
|
112
|
+
- Fixed the background editor's pan and pinch never working on touch devices: the listeners were attached to a node inside a Portal that has no node on its first render, and the effect's dependencies never changed, so it never ran again. The modal node is held in state now, so the effect runs as soon as the node exists. Touch handling also moved from the preview card to the full-screen overlay (pinching the backdrop no longer zooms the page), and a gesture that ends outside the preview no longer closes the editor.
|
|
113
|
+
- Fixed slider thumbs snapping back mid-drag: the sync effect depended on inline arrow functions, so any parent re-render wrote the last committed value back into the input. The formatter is read through a ref, and only a real value change moves the thumb.
|
|
114
|
+
- Fixed the Interface and Font pages showing stale values after applying a preset or importing a theme: they did not subscribe to the store. They follow `metaRev` now (the background page's layout chips follow `bgRev`).
|
|
115
|
+
- Fixed settings being silently lost when a healthy config file was mistaken for a corrupt one: any read failure (file in use, antivirus, permissions) used to archive the good file, and the next launch then treated the install as a first run and wrote defaults over it. Only a JSON parse failure counts as corruption now; a read failure just falls back to the defaults and leaves the file alone.
|
|
116
|
+
- Fixed oversized uploads failing silently: the server answered 413 but the client never read the body. All three upload entries (video / wallpaper / font) now say "file too large, limit 100 MB", and an oversized video no longer plays as if it had been saved.
|
|
117
|
+
- Fixed the night schedule throwing on hosts without `matchMedia`, which aborted the boot restore and repeated every 30 seconds.
|
|
118
|
+
- Streaming no longer re-runs the full blur/opacity pass on every token (the observer's short-circuit condition could never hold on the real host). Bursts are coalesced into one animation frame and skipped when neither the values nor the targets moved.
|
|
119
|
+
- Also: config writes are atomic now (temp file + rename, temp cleaned up on failure) with the parsed result cached by mtime/size; and a batch of leak and race fixes (document listeners left behind when a panel closed mid-drag, stale animation frames overwriting a regenerated background, rotation writes clobbering debounced saves, leftover styles after disabling the plugin).
|
|
110
120
|
|
|
111
121
|
## Installation
|
|
112
122
|
|
|
@@ -150,10 +160,21 @@ pnpm dsh web
|
|
|
150
160
|
|
|
151
161
|
## Compatibility
|
|
152
162
|
|
|
153
|
-
- **[`dsh web`](https://github.com/deepseek-ai/deepseek-harness) 0.1.5-rc.2** —
|
|
154
|
-
- **[DSHA](https://github.com/DSH-APP/DSHA)** — DeepSeek Harness Android launcher (ROOT-free, Termux-free). Its bundled `dsh` is `0.1.5-rc.2`, the
|
|
163
|
+
- **[`dsh web`](https://github.com/deepseek-ai/deepseek-harness) 0.1.5-rc.2 ~ 0.1.7-alpha.1** — The range covers all five published releases (`0.1.6-alpha.2` and `0.1.7-alpha.1` verified hands-on); `engines.dsh` and `dsh.compatibility.dshReleases` list them explicitly. The host release is resolved on the Node half at runtime, and features that depend on a specific host generation (the right Sidebar's panel blur, the official Sidebar's "Theme" card) enable themselves only where the corresponding host structure exists; everything else behaves identically across the range.
|
|
164
|
+
- **[DSHA](https://github.com/DSH-APP/DSHA)** — DeepSeek Harness Android launcher (ROOT-free, Termux-free). Its bundled `dsh` is `0.1.5-rc.2`, inside the supported range; the mobile UI shell is provided by `dsh-web-mobile`.
|
|
155
165
|
- **[deepseek-harness-desktop](https://github.com/anywhere-labs/deepseek-harness-desktop)** — Supported
|
|
156
166
|
|
|
167
|
+
## Permissions, side effects & boundaries
|
|
168
|
+
|
|
169
|
+
- **Integration form**: official Profile Bundle — `package.json` declares `dsh.bundle.patch: ./cordis.patch.yml` (a loader insert layer), the repository ships prebuilt runtime artifacts ready to use (`lib/index.js`, `lib/invariant.js`, `lib/client.js`), and there are no install scripts, no `postinstall`, no native binaries, and no build step at install time.
|
|
170
|
+
- **Filesystem**: the server half reads and writes only inside `<dsh home>/.dsh-any-background-data/` (config JSON, wallpaper, rotation pool, video, font) and touches nothing outside it; config writes are atomic (temp file + rename). These files live on the real disk, so they are **outside generation restore — it neither captures nor rolls them back**; deleting the directory is a full plugin reset.
|
|
171
|
+
- **Network**: one outbound fetch happens only when the user pastes an http/https image or video URL and presses Apply; no telemetry, no other external calls.
|
|
172
|
+
- **Shell / native**: none. No `child_process`, no native modules, no dynamically downloaded executables.
|
|
173
|
+
- **HTTP surface**: registers only `/dsh-any-background/{video,wallpaper,font}` (GET/HEAD streaming) with matching `*/upload` POST routes (100 MB cap) and the dedicated RPC channel `/dsh-any-background` under the local dsh web server; no extra listening ports.
|
|
174
|
+
- **Restart requirements**: the first install needs a (re)start of `dsh web` to load the client bundle; settings changes afterwards apply live and persist automatically. Updating the plugin requires a restart to pick up the new `lib/client.js`.
|
|
175
|
+
- **Tests & verification**: `pnpm run typecheck` (full tsc check) and `pnpm run bundle` (tsdown emits `lib/`); no automated unit tests — behavior is verified manually.
|
|
176
|
+
- **Known limitations**: the styling relies on stable host DOM markers (`[data-sidebar-right-panel]`, `[data-dsh-bottom-panel]`, …) and CSS token names; a host restyle of those layers can leave a slider ineffective for its surface (cosmetic only — nothing breaks). `-webkit-text-stroke` may clip about 1px at the edge of some single-line ellipsis containers.
|
|
177
|
+
|
|
157
178
|
## Star History
|
|
158
179
|
|
|
159
180
|
[](https://www.star-history.com/?repos=Tkingxiao%2Fdsh-any-background&type=timeline&legend=bottom-right)
|
package/README.zh.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<a href="https://www.npmjs.com/package/dsh-any-background"><img alt="npm 版本" src="https://img.shields.io/npm/v/dsh-any-background?color=4d6bfe"></a>
|
|
5
5
|
<a href="https://www.npmjs.com/package/dsh-any-background"><img alt="npm 月下载量" src="https://img.shields.io/npm/dm/dsh-any-background?color=4d6bfe"></a>
|
|
6
6
|
<a href="https://github.com/Tkingxiao/dsh-any-background/blob/main/LICENSE"><img alt="License: MIT" src="https://img.shields.io/npm/l/dsh-any-background?color=4d6bfe"></a>
|
|
7
|
-
<a href="https://www.npmjs.com/package/@deepseek-ai/dsh?activeTab=versions"><img alt="支持的 DSH 版本:0.1.5-rc.2" src="https://img.shields.io/badge/DSH-0.1.5--rc.2-4d6bfe" /></a>
|
|
7
|
+
<a href="https://www.npmjs.com/package/@deepseek-ai/dsh?activeTab=versions"><img alt="支持的 DSH 版本:0.1.5-rc.2 ~ 0.1.7-alpha.1" src="https://img.shields.io/badge/DSH-0.1.5--rc.2%20~%200.1.7--alpha.1-4d6bfe" /></a>
|
|
8
8
|
<a href="https://github.com/topics/dsh-better-sidebar"><img alt="插件生态:GitHub topic dsh-better-sidebar" src="https://img.shields.io/badge/%E6%8F%92%E4%BB%B6%E7%94%9F%E6%80%81-topic%20dsh--better--sidebar-4d6bfe" /></a><br /><br />
|
|
9
9
|
<a href="https://github.com/Tkingxiao/dsh-any-background"><img src="https://img.shields.io/github/stars/Tkingxiao/dsh-any-background?style=social" alt="GitHub stars"></a>
|
|
10
10
|
<a href="https://dsh.directory/plugins/tkingxiao/dsh-any-background"><img src="https://dsh.directory/badges/listed.svg" alt="dsh.directory listed"></a>
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
|
|
13
13
|
[English](README.md) | 中文
|
|
14
14
|
|
|
15
|
-
一个 **DeepSeek Harness** 外观插件:自定义主题色、背景壁纸(图片 / 视频 /
|
|
15
|
+
一个 **DeepSeek Harness** 外观插件:自定义主题色、背景壁纸(图片 / 视频 / 算法动态生成),以及逐表面的透明度与模糊度控制。兼容 **DSH 0.1.5-rc.2 ~ 0.1.7-alpha.1**(官方右侧栏「主题」卡片等新特性仅在使用右侧栏注册表 API 的宿主上出现,旧宿主自动跳过)。
|
|
16
16
|
|
|
17
17
|
---
|
|
18
18
|
|
|
@@ -71,41 +71,52 @@
|
|
|
71
71
|
- **位置编辑器** — 图片与视频共用同一套编辑器:拖动平移、滚轮或双指缩放、一键重置;图片与视频的位置状态各自独立保存,互不覆盖。
|
|
72
72
|
- **布局模式** — 适应 / 填充 / 拉伸 / 平铺 / 居中五种排布,图片与视频通用;「适应」模式下编辑器提交的构图在窗口缩放、跨屏移动后保持一致。
|
|
73
73
|
- **动态生成背景** — 支持网格渐变、Shader、几何图案,可调节扩散范围、色彩强度并锁定种子。
|
|
74
|
-
- **分部位界面透明度** — 主背景、侧边栏、卡片面板(含对话框周围的选项框/菜单)、输入框与控件(发送框、Cordis
|
|
74
|
+
- **分部位界面透明度** — 主背景、侧边栏、卡片面板(含对话框周围的选项框/菜单)、输入框与控件(发送框、Cordis 插件面板)、设置面板、对话文本框、轨迹页、右方侧边栏(或 bettersidebar)、产出物/高亮内容,以及顶栏选项(Agent Team 面板、后台任务列表与会话头部下拉菜单)各自独立滑块。
|
|
75
75
|
- **分部位界面模糊度** — 每个界面部位可独立调整毛玻璃 `backdrop-filter` 模糊(0–60 px),并通过宿主的稳定选择器为发送框、Cordis 面板与弹出层提供真实背景模糊。
|
|
76
76
|
- **产出物 / 高亮内容** — 对话正文里的代码块(含语言顶栏)、行内 `code` 高亮芯片与产出物 chip 共用一支滑块:透明度只**调制这些表面原本的背景色**(不会在旧背景上再叠一层新色),模糊度给同一层表面加磨砂,壁纸从内容后方透出来。
|
|
77
|
-
-
|
|
77
|
+
- **右方侧边栏 / bettersidebar 表面** — 同一对滑块(`panelOpacity` / `blurs.panel`)按宿主环境自动切换目标:未安装 dsh-better-sidebar 时叫「右方侧边栏」,驱动官方右侧栏的表面令牌与毛玻璃模糊(0.1.5-rc.2 至 0.1.7 均适用);安装了 dsh-better-sidebar 时改叫「bettersidebar」,接管其底部工作台面板(官方右侧栏同样生效)。该行现在始终显示。
|
|
78
|
+
- **顶栏选项** — 会话头部的下拉浮层获得了独立的透明度 + 模糊滑块:Agent Team 面板、后台任务列表、「用其它应用打开」与「会话日志」菜单、子代理血缘树。由于这些浮层被 portal 到 `<body>`(与头部 DOM 断开),且 0.1.7 把「用其它应用打开」改成 portal、把会话行菜单改成动态槽位,插件改为在运行时监听稳定的 `conversation.session.header*` 槽位锚点来标记当前展开的浮层,不再依赖类名形状。
|
|
79
|
+
- **侧边栏「主题」页面(双模式)** — 同一套五页(色彩 / 界面 / 字体 / 背景 / 配置)注册到两处:未安装 dsh-better-sidebar 时,通过官方右侧栏的公开扩展点(`sidebarRightTabs` + `sidebar.right.pane.tab`)在**官方侧边栏**的引导页挂一张「主题」卡片,点开即五页;安装了 dsh-better-sidebar 时,改为在它的侧边栏注册同名页面,官方引导页上的卡片自动撤下,避免重复。两处(加设置面板共三处)共用同一套页面代码与同一份状态,改一处处处同步;外壳按面板宽度自适应,窄面板收紧内边距并回到单列。宿主没有右侧栏扩展点时静默不注册,不影响任何其它功能。
|
|
78
80
|
- **对话视图卡片** — 消息列表自动包裹为半透明卡片,轨迹页可整页调节透明度与模糊,让壁纸从内容后方透出来。
|
|
79
81
|
- **主题导出 / 导入** — 一键导出为自包含的 `dsh-any-theme.json`(配置 + 壁纸,视频以 data URL 内嵌),可随时导入还原。
|
|
80
82
|
- **外观预设与配置档案** — 六套一键预设(默认 / 毛玻璃 / 极简白 / 暗夜紫 / 赛博 / 暖阳),外加自定义命名档案:随时保存当前观感、随时套回,删除有二次确认保护。
|
|
81
83
|
- **壁纸轮换** — 把多张图片加入轮换池(缩略图选择器),按随机或顺序、每次刷新 / 每天 / 每周的频率自动更换;切换时服务端把所选图片复制进当前壁纸槽,导出/导入与取色管线完全不用改。
|
|
82
84
|
- **昼夜自动切换** — 指定日间与夜间两套配置,按固定时段或跟随系统深色模式自动切换。
|
|
83
85
|
- **自定义字体** — 上传一个 ttf / otf / woff / woff2 字体文件(上限 100 MB),通过 `@font-face` 应用到整个界面的文字;可随时停用或移除。字体按原始字节流式上传并持久化到插件数据目录,代码块仍保持等宽字体。
|
|
84
|
-
- **分组文字描边** —
|
|
86
|
+
- **分组文字描边** — 沿用界面页的分组(现为十组,含顶栏选项),为每个分组单独加 `-webkit-text-stroke` 描边:粗细 0–4 px(0 = 关闭),颜色支持自动反色 / 灰 / 黑 / 白 / 主题色 / 自定义。代码块、`inline code`、图标,以及宿主那类 `background-clip: text` 的流光文字(「深度求索中」状态行与轮次过程行)自动豁免——多色语法不会糊成一团,渐变文字也不会被描边压成一坨纯色。
|
|
85
87
|
- **强制界面明暗** — 无论主题色明暗如何,都能强制生成亮色/暗色整套令牌;「自动」下配色与字体方向由主题色明度驱动(深色 → 浅字,浅色 → 深字),未选主题色时按壁纸画面亮度判断。
|
|
86
88
|
- **文件持久化** — 所有设置保存到文件系统 `~/.dsh/.dsh-any-background-data/`,不再依赖 `localStorage`。
|
|
87
89
|
- **中英双语** — 完整的中英文界面,自动跟随语言设置。
|
|
88
90
|
- **主题守护** — 宿主重置主题后自动重新激活自定义主题。
|
|
89
91
|
|
|
90
|
-
##
|
|
91
|
-
|
|
92
|
-
### v0.2.
|
|
93
|
-
|
|
94
|
-
-
|
|
95
|
-
-
|
|
96
|
-
-
|
|
97
|
-
-
|
|
98
|
-
-
|
|
99
|
-
-
|
|
100
|
-
-
|
|
101
|
-
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
-
|
|
107
|
-
-
|
|
108
|
-
-
|
|
92
|
+
## 更新日志(只保留最新两个版本)
|
|
93
|
+
|
|
94
|
+
### v0.3.0(DSH 0.1.7 适配,兼容 0.1.5-rc.2 ~ 0.1.7-alpha.1)
|
|
95
|
+
|
|
96
|
+
- **适配 0.1.7 官方右侧栏**:宿主重做了该面板——它现在是一个**静止外框**,滑动位移落在内部的 dockkit 子元素(`[data-dockkit-host="dock"]` / `[data-dockkit-empty]`)上,且面板本身不再绘制背景。插件随之调整:模糊改挂在真正滑动的子元素上,因此会跟随侧边栏一起移动而不是卡在原地;表面令牌也改为在面板实际渲染处重新作用域。原先无条件的 `position:fixed` 提升已移除——在 0.1.7 上它会让面板脱离动画轨道。
|
|
97
|
+
- **修复 0.1.6 右方侧边栏模糊失效**:`[data-dockkit-host]` 从 0.1.7 才存在,所以基于子元素的选择器在 0.1.6 上匹配空集(0.1.6 的滑动打在面板自身)。现在新增一条用 `:has()` 门控的分支为面板包装元素加磨砂,且 pre-0.1.7 的提升只在真正需要处重新生效。
|
|
98
|
+
- **修复流光文字被描边压成纯色**:`-webkit-text-stroke` 是继承属性,对话文本框的规则会一路继承到 `background-clip: text` 的活动状态文字上——「深度求索中」状态行(0.1.5/0.1.6)与轮次过程 / 流光行(0.1.7)会被糊成一块描边色。现在这些表面按 `[role="status"]`、`[data-turn-process]` 与 TextShimmer 标记被显式豁免。
|
|
99
|
+
- **新增「顶栏选项」表面**:Agent Team 面板、后台任务列表、「用其它应用打开」/「会话日志」菜单与子代理血缘树拥有独立的透明度 + 模糊滑块,以及对应的描边分组。这些浮层被 portal 到 `<body>`(与头部断开),且 0.1.7 把「用其它应用打开」改为 portal、把会话行菜单改为动态槽位,因此插件新增一个运行时标记器,监听稳定的 `conversation.session.header*` 槽位锚点来标记展开的浮层。豁免的确认对话框与会话行菜单用真实颜色字面量钉死——不再使用自引用的 `var()` 回退,那是 CSS 循环,会让表面彻底透明。
|
|
100
|
+
- **宿主版本探测**:客户端上下文不暴露宿主版本(`window.__DSH_BOOT__.version` 是模块表格式标记,不是 release),因此改由 Node 半侧从启动器的磁盘布局解析出 release 与代际桶,再经 `read` RPC 下发。功能开关据此判定;无法确定时回退到能力探测,而不是猜一个版本。
|
|
101
|
+
- **原生适配官方右侧栏**:通过官方公开扩展点(`ctx.sidebarRightTabs` 注册页面类型 + `sidebar.right.pane.tab` 键控槽位挂载页面本体)在官方侧边栏的引导页挂上「主题」卡片,点开就是和设置面板一样的五页。未安装 dsh-better-sidebar 时生效;装了 better-sidebar 则让位给它自己的「主题」页(官方引导页卡片自动撤下,不重复占位)。注册走运行时动态等待:宿主没有右侧栏注册表 API 时静默跳过,旧宿主不受影响。
|
|
102
|
+
- **右方侧边栏栏位随环境改名**:界面页的面板分组(`panelOpacity` / `blurs.panel`)未安装 better-sidebar 时显示为「右方侧边栏」,直接驱动官方右侧栏的表面令牌与毛玻璃模糊(0.1.5-rc.2 至 0.1.7 均适用,该行现在始终显示);安装了 better-sidebar 时改名为「bettersidebar」,语义不变。
|
|
103
|
+
- better-sidebar 存在性探测摘除了 `[data-sidebar-right-panel]` 标记——各代宿主中它都是官方右侧栏的稳定标记(随会话始终存在),继续计数会让「bettersidebar」判定永远为真。
|
|
104
|
+
- 兼容性声明现已覆盖 `0.1.5-rc.2`、`0.1.5-rc.3`、`0.1.6-alpha.1`、`0.1.6-alpha.2`、`0.1.7-alpha.1`;peerDependencies 放宽为同时覆盖各代客户端包版本;`@deepseek-ai/dsh-home-paths` 维持与 lockfile 一致的 `^0.1.0-rc.6`(仅构建期使用,运行时由宿主注入自身版本)。
|
|
105
|
+
|
|
106
|
+
### v0.2.10(最后一版0.15 rc2更新)
|
|
107
|
+
|
|
108
|
+
- 侧边栏「主题」页:安装 dsh-better-sidebar 后,侧边栏会多出一张「主题」卡片,点开就是和设置面板一样的五页(色彩 / 界面 / 字体 / 背景 / 配置)。两边共用同一套页面和同一份状态,在哪边改都会同步。外壳按面板宽度自适应,卡片网格能排几列就排几列(面板 430px 左右起两列,更宽三列、四列),窄了才收紧内边距、回到单列。
|
|
109
|
+
- 设置面板适配手机宽度:内容列窄到一定程度后,标题、卡片内边距、色球和色轮卡都会收紧;各处卡片网格加了防溢出的最小宽度,背景类型卡片在窄屏改成按宽度自动排两列,不再挤成一条。
|
|
110
|
+
- 面板崩溃时直接把出错堆栈显示在兜底页里,不用再开开发者工具查原因。
|
|
111
|
+
- 修复部分环境下面板直接报错 `getSnapshot is not a function`:装着的 dsh-client-store 是旧版,`defineStore()` 返回的是声明而不是实例,代码把它当实例用就炸了,连带把状态同步整个关掉(设置面板会一直显示默认值)。现在启动时归一化成单个共享实例,两处读同一份状态;以后形状再变也只是告警并跳过侧边栏页。
|
|
112
|
+
- 修复手机上背景编辑器的拖动、捏合完全无效:监听器挂在 Portal 里的节点上,首帧拿不到节点,effect 依赖又是恒定的,所以永远不会再跑。现在弹窗节点改用 state 持有,出现即绑定;触摸监听同时从预览卡片挪到全屏遮罩,两指落在遮罩上不会再缩放整个页面;在预览图外松手也不会误关编辑器。
|
|
113
|
+
- 修复拖滑块时拇指弹回旧位置:同步 effect 的依赖里有内联箭头函数,任何父级重渲染都会把值写回上次提交的结果。现在格式化函数走 ref,只有数值真的变了才会动滑块。
|
|
114
|
+
- 修复套预设 / 导入主题后「界面」「字体」页滑块停在旧值:这两页此前没有订阅 store,现在跟随 `metaRev`(背景页的布局选项跟随 `bgRev`)。
|
|
115
|
+
- 修复配置文件被误判为损坏、整套设置静默丢失:之前文件被占用或权限失败也会把好文件改名归档,下次启动就按首次运行写入默认值。现在只有 JSON 解析失败才归档,读取失败只用默认值,不动磁盘上的文件。
|
|
116
|
+
- 修复上传超限毫无提示:服务端返回 413 但客户端从不读响应体。现在视频 / 壁纸 / 字体三个入口都会提示「文件过大,上限 100 MB」,超限视频也不会再「能播但不保存」。
|
|
117
|
+
- 修复夜间自动切换在缺少 `matchMedia` 的环境抛错,并因此反复中断启动恢复。
|
|
118
|
+
- 正常聊天时每个流式 token 都会触发一遍完整的模糊 / 透明度应用(观察器的短路条件在真实宿主上恒为假)。现在按帧合并,值和目标都没变就整帧跳过。
|
|
119
|
+
- 其它:配置写入改成原子写(tmp + rename,失败清理临时文件),解析结果按 mtime/size 缓存;修了一批泄漏和竞态(拖动中关面板遗留监听、动态背景旧帧覆盖新画面、轮换写回覆盖防抖保存、禁用后样式残留等)。
|
|
109
120
|
|
|
110
121
|
## 安装
|
|
111
122
|
|
|
@@ -149,10 +160,21 @@ pnpm dsh web
|
|
|
149
160
|
|
|
150
161
|
## 兼容性
|
|
151
162
|
|
|
152
|
-
- **[`dsh web`](https://github.com/deepseek-ai/deepseek-harness) 0.1.5-rc.2** —
|
|
153
|
-
- **[DSHA](https://github.com/DSH-APP/DSHA)** — DeepSeek Harness 安卓启动器(免 ROOT、免 Termux)。其包内 dsh
|
|
163
|
+
- **[`dsh web`](https://github.com/deepseek-ai/deepseek-harness) 0.1.5-rc.2 ~ 0.1.7-alpha.1** — 兼容范围覆盖全部五个已发布版本(`0.1.6-alpha.2` 与 `0.1.7-alpha.1` 已实测验证);`engines.dsh` 与 `dsh.compatibility.dshReleases` 逐一列出。宿主版本在运行时由 Node 半侧解析,依赖特定宿主代际的功能(右侧栏面板模糊、官方侧栏「主题」卡片)只在对应宿主结构存在时启用,其余功能在整个范围内表现一致。
|
|
164
|
+
- **[DSHA](https://github.com/DSH-APP/DSHA)** — DeepSeek Harness 安卓启动器(免 ROOT、免 Termux)。其包内 dsh 为 `0.1.5-rc.2`,落在兼容范围内;移动端界面由 `dsh-web-mobile` 提供。
|
|
154
165
|
- **[deepseek-harness-desktop](https://github.com/anywhere-labs/deepseek-harness-desktop)** — 支持
|
|
155
166
|
|
|
167
|
+
## 权限、副作用与边界
|
|
168
|
+
|
|
169
|
+
- **接入形态**:官方 Profile Bundle——`package.json` 声明 `dsh.bundle.patch: ./cordis.patch.yml`(loader 插入层),仓库提交可直接使用的预构建运行时制品(`lib/index.js`、`lib/invariant.js`、`lib/client.js`),无安装脚本、无 postinstall、无 native 二进制、安装时不执行任何构建。
|
|
170
|
+
- **文件系统**:服务端仅在 `<dsh 主目录>/.dsh-any-background-data/` 内读写(配置 JSON、壁纸、轮换池、视频、字体),不触碰该目录之外的任何路径;配置写入为原子写(临时文件 + rename)。这些文件落在真实磁盘上,**不受 generation 恢复影响,也不会被其回滚**——清除它们即彻底重置插件。
|
|
171
|
+
- **网络**:仅在用户主动粘贴 http/https 图片或视频网址并点击「应用」时发起一次出站请求下载该资源;除此之外无遥测、无外部服务调用。
|
|
172
|
+
- **Shell / native**:无。不使用 `child_process`、不加载 native 模块、不运行动态下载的二进制。
|
|
173
|
+
- **HTTP 面**:仅在本机 dsh web 服务下注册 `/dsh-any-background/{video,wallpaper,font}`(GET/HEAD 流式服务)与对应 `*/upload`(POST,上限 100 MB)及专用 RPC 通道 `/dsh-any-background`;无新增对外监听端口。
|
|
174
|
+
- **是否需要重启**:首次安装后需(重新)启动 `dsh web` 加载客户端 bundle;此后的设置变更实时生效、自动落盘。更换插件版本后需重启以加载新的 `lib/client.js`。
|
|
175
|
+
- **测试与验证**:`pnpm run typecheck`(tsc 全量类型检查)与 `pnpm run bundle`(tsdown 产出 `lib/`);无自动化单测,接口行为以手动验证为准。
|
|
176
|
+
- **已知限制**:依赖宿主 DOM 结构的稳定标记(如 `[data-sidebar-right-panel]`、`[data-dsh-bottom-panel]`)与 CSS 令牌名,宿主大版本重构样式层时选择器可能失效(表现为相关滑块不再作用于对应表面,不影响稳定性);`-webkit-text-stroke` 在部分单行省略号容器边缘约有 1px 裁切。
|
|
177
|
+
|
|
156
178
|
## Star History
|
|
157
179
|
|
|
158
180
|
[](https://www.star-history.com/?repos=Tkingxiao%2Fdsh-any-background&type=timeline&legend=bottom-right)
|