dshbase

插件目录 / UI & Skins / dsh-beauty-persist

dsh-beauty-persist

已验证 · 实测可装 wuweiran-web

✓ 持续维护 2 位贡献者 基于 1 个官方 DSH 包

查看 GitHub ↗ ← 返回插件目录

1Stars
0Forks
0未关闭 issue
—语言
2026-08-21最近推送
跨平台平台

功能简介

让 DSH 桌面端壁纸持久不丢:支持 GIF 动图 & MP4 视频壁纸,内置全屏皮肤中心(上传、预览、一键应用、删除素材),重启、换端口、清缓存都不丢失。Server-side wallpaper & theme persistence for DSH Desktop — animated GIF / MP4 video wallpapers plus a full-screen skin center (upload, preview, apply, delete).

✅
我们的评价
可用 — 实测通过,早期项目

让 DSH 桌面端壁纸持久不丢:支持 GIF 动图 & MP4 视频壁纸,内置全屏皮肤中心(上传、预览、一键应用、删除素材),重启、换端口、清缓存都不丢失。Server-side wallpaper & theme persistence for DSH Desktop — animated GIF / MP4 video wallpapers plus a full-screen skin center (upload, preview, apply, delete). 实测能干净安装、正常启动。早期项目,但功能可用。

「已验证」表示我们的自动化 CI 在干净 profile 里实际执行了 dsh plugin add 并启动成功——仅此而已。功能描述与版本兼容性均为作者声明。这不是安全审计,也不代表对第三方代码的背书。

README

dsh-beauty-persist

Persist dsh-dream-skin / dsh-liquid-glass wallpaper & theme across DSH Desktop restarts.

Why

The DSH Desktop shell launches its web carrier with an OS-assigned random port
(--port 0), so the browser origin changes on every restart. Browser
localStorage is partitioned per origin — visual state like a wallpaper image
(stored by dream-skin / liquid-glass in localStorage) disappears after each
restart
, even though it was never deleted.

dsh-beauty-persist moves that visual state into a server-side JSON file that
is independent of the port. It restores the state on every page load and pushes
changes back to the server when you tweak the settings in the UI.

What it does

  • Host half (lib/index.js)
    • Serves GET /beauty-persist/state (current persisted state) and
      POST /beauty-persist/state (replace persisted state).
    • Serves GET /beauty-persist/wallpaper.gif (the stored GIF wallpaper) and
      POST /beauty-persist/wallpaper.gif (upload a new GIF wallpaper).
    • Injects the persisted state into the index.html response as
      window.__DSH_BEAUTY_PERSIST_STATE__, before the boot manifest, so the
      browser half restores synchronously ahead of dream-skin/liquid-glass
      initialization.
  • Browser half (lib/client.js)
    • Restores every dsh-dream-skin:* / dsh-liquid-glass:* localStorage key
      from the server-injected state on page load.
    • Hooks Storage.prototype.setItem / removeItem and mirrors any later
      changes back to the server (debounced), so your wallpaper/skin choices keep
      persisting without you doing anything extra.
    • Exposes uploadGifWallpaper(gif) to set an animated GIF wallpaper.

State is stored at ~/.dsh/beauty-persist-state.json; the GIF wallpaper file
lives at ~/.dsh/beauty-persist-wallpaper.gif.

Install

Works with any profile that already runs dsh-dream-skin and/or
dsh-liquid-glass (typically the desktop profile used by DSH Desktop).

cd ~/.dsh/profiles/desktop

# add the dependency (adjust the repo URL / tag to what you installed)
pnpm add dsh-beauty-persist@github:<owner>/<repo>

# register the bundle in dsh.profile.bundles of package.json
#   "dsh-beauty-persist",

Then restart DSH Desktop so the new bundle is loaded.

Usage

Nothing to configure. Once installed:

  1. Restart DSH Desktop (required for the bundle to load).
  2. In the GUI open Settings → Theme / 外观 and pick your wallpaper / skin as usual.
  3. The choice is now persisted server-side — it survives restarts, port changes,
    browser cache clears, and even switching browsers.

If you already have a wallpaper set in a previous session's localStorage
(now orphaned under an old port), either re-pick it once after installing, or
seed the server state manually:

# example: put a data-URL or URL into the state file
echo '{"dsh-dream-skin:wallpaper":"https://example.com/wall.jpg"}' \
  > ~/.dsh/beauty-persist-state.json

Animated GIF wallpaper

dream-skin's "pick image" flow re-encodes through a canvas and flattens
animated GIFs into a static JPEG. To use an animated GIF instead, upload
it to this plugin — the browser renders the GIF natively (it plays), and the
file is stored server-side so it survives restarts.

In the GUI (no command line): after installing, open
Settings → Theme / 外观 — a "GIF 壁纸上传(动图)" row appears in the
appearance section. Click 选择 GIF…, pick a local .gif, and it is
uploaded, activated and persisted. Refresh the GUI to see the animation.

From the command line:

# from this repo — the script auto-discovers the DSH Desktop GUI port
node scripts/set-gif-wallpaper.mjs "C:\path\to\my-wallpaper.gif"

# or pass the base URL explicitly if your GUI is served elsewhere
node scripts/set-gif-wallpaper.mjs "C:\path\to\my-wallpaper.gif" http://127.0.0.1:8080

After upload, refresh the GUI (or restart DSH Desktop): the GIF plays as the
wallpaper and persists across restarts. Swap it any time by re-running the
script with a different GIF.

MP4 video wallpaper

CSS background-image cannot play video, so MP4 wallpapers are rendered by this
plugin as a full-viewport <video> layer (muted, looping, object-fit cover).

In the GUI: the "MP4 视频壁纸(动效)" row (also under
Settings → Theme / 外观) lets you pick a local .mp4 and activate it, or
remove the video wallpaper.

From the command line:

node scripts/set-mp4-wallpaper.mjs "C:\path\to\my-wallpaper.mp4"
# optional explicit base URL:
node scripts/set-mp4-wallpaper.mjs "C:\path\to\my-wallpaper.mp4" http://127.0.0.1:8080

The MP4 is stored at ~/.dsh/beauty-persist-wallpaper.mp4 (up to 50 MB) and
persists across restarts.

🎨 Skin center (asset library)

Build your own wallpaper library: upload images / GIFs / MP4s once, then
switch between them anytime with one click — everything is stored server-side
and survives restarts.

In the GUI: the "🎨 皮肤中心" row (under Settings → Theme / 外观)
gives you:

  • 上传素材… — pick a local image / GIF / MP4 to add it to the library
    (stored at ~/.dsh/beauty-persist-assets/, up to 50 MB each).
  • A thumbnail grid of your assets — click any thumbnail to apply it as the
    wallpaper right away (images/GIFs render as a background layer, GIFs animate
    natively; MP4s render as a looping video layer).
  • ✕ on a thumbnail deletes the asset from the library.

The currently applied asset is remembered in the server-side state, so after a
restart the same wallpaper comes back automatically.

Requirements

  • @deepseek-ai/dsh-client-runtime, @deepseek-ai/dsh-client-locale,
    @deepseek-ai/dsh-client-ui-theme (the standard web client stack; present in
    every shipped Web composition).
  • Node >= 18 for the host half.

License

MIT

安装

🧩 让 Agent 自动装(推荐)

装一次目录插件,之后本站所有插件都能让 DeepSeek Harness 自动找、自动装:

dsh plugin add dshbase-catalog

然后对 agent 说「帮我装 dsh-beauty-persist」,它会在目录里找到并自动安装。文档:dshbase-catalog · 已验证场景包。

该插件是 GitHub 源码(未发 npm)——直接从仓库装:

Web profile:

dsh plugin --profile web add github:wuweiran-web/dsh-beauty-persist

Headless(CLI)profile:

dsh plugin --profile headless add github:wuweiran-web/dsh-beauty-persist

实测报告

验证通过:从 GitHub 源码完成 L1 安装 + L2 加载 + L3 运行(dsh 0.1.0-rc.6)。

安全:尚未扫描——我们的每日静态扫描将很快覆盖它。

分享徽章

UI & Skins 里更多

浏览全部 7819 个插件 →