Introduction to the DSH Splash Screen Animation Plugin

Introduction

DeepSeek Harness (DSH) adopts an “everything is a plugin” architecture. During the application startup phase, it is often necessary to customize the splash screen to provide a more complete startup experience or brand display. dsh-splash-screen is a pure plugin implementation of a splash screen animation. It provides a full-screen startup animation, supports skipping, and can be toggled via the “Plugins” page in the sidebar.

Core Features

The plugin mainly includes the following features:

  • Full-screen startup animation: Provides a full-screen startup display, covering the default boot shell.
  • Skippable: Supports skipping by clicking anywhere, pressing a key, touch screen, scrolling the mouse wheel, or clicking the SKIP button in the bottom right corner.
  • Pure plugin implementation: Integrates via plugin mechanisms without relying on modifications to the main application body.
  • Sidebar toggle: Can directly control the enabling and disabling of the plugin in the sidebar “Plugins” page.
  • Audio processing: Sound effects are disabled by default, using runtime synthesis (no external audio files), and can be enabled via the SOUND button in the bottom right corner.
  • Accessibility support: Includes role="progressbar" and aria-valuenow. State changes support aria-live announcements, and it respects the prefers-reduced-motion preference setting.
  • Two-half structure: Adopts a structure consisting of a Node half and a Client half, communicating via injection lines.
  • Session control: Plays only once per session on the same page.

Installation

Before installation, please ensure DSH (Desktop or Browser version) is installed. dsh plugin will install the repository to the specified profile via pnpm.

Installation Command

Desktop:

dsh plugin --profile desktop add "git+https://github.com/52baihehhh-ai/dsh-splash-screen.git"

Web:

dsh plugin --profile web add "git+https://github.com/52baihehhh-ai/dsh-splash-screen.git"

After installation is complete, the desktop application needs to be restarted once. This is because the node half injection lines are collected and dispatched when the host starts; the injection lines will only take effect after a restart.

Structure Description

This plugin is implemented using a two-half structure to ensure it works correctly under the host’s loading mechanism.

Node Half: Cover and Injection

The Node half is responsible for covering during the early stages of application startup to prevent the default boot shell from flashing. It uses official structured injection lines to inject into the index:

  • Style injection: Cover styles with the same background color, overwriting the default splash screen.
  • Script injection: Immediately spreads out the cover node (background color matches the splash stage) and is responsible for removing itself after the Client half mounts or upon timeout.

Client Half: Animation Body

The Client half is responsible for the specific animation logic, loaded via a lazy-loaded CJS module. It mounts itself into the shell.overlay slot, using position: fixed to cover the screen. Style injection uses a single <style> tag and utilizes sp- prefix class names to avoid conflicts with the host interface.

Usage

Skipping Animation

During animation playback, you can skip via any of the following methods:
* Click anywhere with the mouse
* Press any key
* Touch screen operation
* Scroll the mouse wheel
* Click the SKIP button in the bottom right corner

Audio Control

Audio effects are off by default. Clicking the SOUND button in the bottom right corner turns them on, and preferences are saved in localStorage. Audio is synthesized at runtime and is not affected by browser autoplay policies.

Visual Preview

When developing locally or verifying effects, there is no need to run DSH. You can open preview/index.html from the repository directly in a browser to view the standalone effect.

Known Limitations and Notes

  • No “Display immediately upon application startup”: The plugin cannot cover the host’s built-in [data-dsh-boot] boot shell. It covers the segment from “window appears -> interface mounts -> animation ends”.
  • Timing of injection line effectiveness: After adding or modifying injection lines (such as modifying dsh.profile.bundles), the desktop version must restart the application to take effect.
  • Browser refresh: For the browser version of DSH, refreshing the page will make the injection lines and animation take effect.
  • Asset handling: Plugin assets (such as character art) are not inlined as data URIs to avoid bloating the injection script or blocking the main thread.

Development and Customization

Local Development

No runtime dependencies, requires Node ≥ 20.11. Source files are located at src/splash.js, and build artifacts are client.js and index.js.

node scripts/build.mjs          # Build client.js + index.js
node scripts/build.mjs --check  # Compare only, do not write to disk

Replacing Artwork

To replace the character art, simply rename the image to art.webp and keep the filename unchanged. The plugin will load the image by filename via the host routing at runtime; it will not inline the image as a data URI.

License

MIT License.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye