DSH Hub

lisniuse/dsh-modal-enhancer

dsh-modal-enhancer

UIWeb UI0 GitHub stars· updated 2026-08-15

Enhance every DeepSeek Harness web modal: draggable title bar, resizable edges, maximize, and removable backdrop blur, with a General-settings toggle.

Install

npx @deepseek-ai/dsh plugin --profile web add github:lisniuse/dsh-modal-enhancer

Restart `dsh web` after install. Bundle APIs can change during the developer preview.

README badge

dsh-modal-enhancer DSH Hub badge
[![DSH Hub](https://dshhub.dev/badge/dsh-modal-enhancer.svg)](https://dshhub.dev/plugins/dsh-modal-enhancer)

Paste this into your README. The star count updates with every catalog sync.

From the README

Excerpt from lisniuse/dsh-modal-enhancer, cleaned of badges and images.

dsh-modal-enhancer

简体中文 · English

A client-side Cordis plugin that gives every DeepSeek Harness Web GUI modal window-like controls without changing the Harness source code.

Features

  • Drag — move a dialog by its dedicated top strip.
  • Eight-way resize — resize from all four edges and four corners.
  • Pin / unpin — a pinned dialog ignores clicks outside the window; its close button and Escape continue to work.
  • Maximize / restore — fill the viewport with a small outer margin, then return to the previous rectangle.
  • Remove backdrop — remove both the dim mask and backdrop blur. The dialog receives a light shadow so it remains visually separated from the page.
  • Per-dialog persistence — position, width, height, maximized state, pinned state, and backdrop state survive modal remounts and browser restarts.
  • Master switch — enable or disable the enhancer from Settings → General → 弹窗增强.

The plugin discovers dialogs through the stable accessibility contract [role="dialog"][aria-modal="true"]; it does not depend on CSS-module hashes. This covers Settings, workspace creation, model and agent-preset editors, risk confirmations, and other Harness dialogs that use the same contract.

Controls

ControlResult
Top drag stripMove the dialog
Four edgesChange width or height
Four cornersChange width and height together
PushpinToggle outside-click dismissal
/ Maximize / restore
/ Remove / restore the visual mask and blur

Resize hit areas extend slightly across the dialog boundary for easier pointer targeting. While maximized, drag and resize are disabled until the dialog is restored.

State persistence

Each dialog is identified by the first available value below:

  1. data-dshme-state-key, when a dialog provides an explicit key;
  2. aria-label;
  3. text referenced by aria-labelledby;
  4. the first heading inside the dialog.

State is stored in localStorage under the dshme.dialog-state.v1: prefix. When restoring geometry on a different display or viewport size, the plugin clamps the rectangle so that at least part of the dialog remains reachable.

Disabling or unloading the plugin removes injected controls, classes, event listeners, and inline geometry from mounted dialogs. Saved state remains available for the next time the enhancer is enabled.

Installation

Git install (recommended, like other dsh plugins)

Install as a dual-plane bundle directly from GitHub:

dsh plugin --profile web add github:lisniuse/dsh-modal-enhancer

The package declares dsh.bundle.patch (mounts cordis.patch.yml) and dsh.client (platform web), so dsh plugin add reconciles it into the profile's layer stack automatically. It is pure JavaScript with no build step — the host half (index.js, a no-op) and the browser half (client.js) load directly. Restart dsh web after installation.

Dynamic plugin (single-file body)

The complete single-file form is dist/plugin.js. Pass its entire contents as the code.client body of a dynamic cordis_define plugin. It is a plain JavaScript function body beginning with return { ... }.

No Harness source modification, pnpm install, Web app rebuild, or server restart is required. See docs/install.md for the detailed dynamic-plugin and agent-preset workflows.

Related plugins