dsh-window-drag-probe: Restoring Window Dragging and Diagnostics in macOS DSH Desktop

Preface

On macOS, DSH Desktop uses a hiddenInset window with no native title bar. Window dragging relies entirely on regions declared with -webkit-app-region: drag within the page. The shell marks Chrome rows with data-window-drag, and ui-web’s base.css converts them into drag rules. However, numerous interactive no-drag selectors in the page (such as buttons, [tabindex] containers, and ARIA components) override these markers. As soon as a no-drag element overlaps with a Chrome row, it subtracts from that region’s draggability, ultimately making the top drag area extremely narrow and preventing proper dragging.

What Is This

dsh-window-drag-probe is a DeepSeek Harness (DSH) client plugin maintained by adamcjm. It restores window dragging functionality for macOS DSH Desktop by appending DOM elements to document.body, and provides a diagnostic panel that reads the window’s DOM state (such as computed app-region, recall markers, and window displacement records) to troubleshoot dragging failures.

Core Features

The plugin provides the following capabilities:

  • Top Drag Strip: Adds a 16px-wide transparent drag strip at the top of the window. This element is inserted as the last child in the document flow with inline app-region: drag styling, ensuring it won’t be overridden by earlier no-drag elements in the page.
  • Diagnostic Panel: Provides a floating panel that reads and displays the following information:
    • Platform markers (data-platform).
    • Computed app-region values for Chrome rows.
    • recall marker status.
    • Window displacement records (window.screenX/screenY).
    • All app-region boxes and their document order.
    • Top draggability matrix and sample point hit chains.
  • Local Read-Only: Only reads local DOM state; no data is sent externally.

Installation & Activation

Before installing, verify your DSH Desktop version. This plugin has been validated on DSH Desktop 0.2.0-rc.2 / Electron 44.0.0. DSH client APIs are not forward-compatible, and using a host version different from the validated one may cause crashes.

Install via command line (profile must be specified):

dsh plugin --profile <profile> add dsh-window-drag-probe

After installation, you must fully quit DSH Desktop (using ⌘Q) and reopen it, because the client bundle is assembled only once at startup.

Typical Usage

Once the plugin is enabled, the 16px area at the top of the window becomes the drag strip. This area is completely transparent when idle and only shows a faint blue hint when hovered.

Open the diagnostic panel via the plugin page and use the following buttons to operate:
1. Recollect: Refresh diagnostic data.
2. Insert/Remove Top Drag Strip: Toggle the drag strip’s presence dynamically.
3. Reset Position: Restore the panel to its default position.
4. Hide Panel: Close the diagnostic interface.

Use Cases & Notes

  • Use Cases: For developers who need to resolve issues where macOS DSH Desktop windows cannot be dragged, or who need to inspect app-region rendering details via the diagnostic panel.
  • Notes:
    • This plugin serves only as a workaround and diagnostic tool, not an upstream fix. If the matrix indicates draggable but the window still cannot move, the issue is not at the page DOM layer—wait for an upstream fix.
    • The plugin declares no hard service dependencies (inject: []) and will not hang due to missing services.
    • The plugin is licensed under the MIT License.

Brief Conclusion

dsh-window-drag-probe solves CSS specificity-related dragging failures on macOS through simple DOM appending and provides an intuitive debugging view. For developers encountering dragging anomalies, this is a reliable troubleshooting and repair tool.

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

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

Xiaoye