Cheyeah
dsh-drop-preview
DeepSeek Harness 拖拽文件预览插件:全屏预览图片/Markdown/文本,图片放大旋转,文件盒持久化,一键附带给 AI | DSH drag-and-drop file preview plugin
- Stars
- 0
- Language
- JavaScript
- Created
- Aug 15, 2026
- Updated
- Aug 15, 2026
Introduction
dsh-drop-preview
DeepSeek Harness Web UI 拖拽文件预览插件:把文件拖进页面即可预览,一键附带给 AI。
English | 简体中文
What it does
Drop files anywhere in the DeepSeek Harness Web UI and get an instant full-page preview, then attach them to the AI conversation with one click — no typing paths, no copy-paste.
Features
- Drop to preview: drop files or folders onto any part of the page
- Images: large inline preview (data URL with blob fallback)
- Markdown: fully rendered (headings, lists, code blocks, tables, links) with
![]()image references resolved and displayed - Text / code: inline preview (up to 500k chars / 1 MB)
- Other files: name, size, type
- Image viewer: click any preview image to zoom in/out (buttons + mouse wheel), rotate, drag to pan, and reset
- Auto image lookup: Markdown images not found in the dropped set are automatically searched in the session workspace (up to 3 subdirectory levels) and displayed; only truly missing images show a clear notice
- File box: save dropped files into a persistent box (browser IndexedDB, survives reloads); managed from a card grid above the composer with thumbnails, click-to-preview, delete, and clear
- Send to AI: files are copied into the session workspace attachment
directory (
.dsh/tmp/attachments/) and their paths are sent to the model; bubbles fold the attachment block into a 📎 chip - Also keeps: Ctrl+V paste, paperclip file/folder picker, attachment usage stats & cleanup in Settings
Install
Requires Node.js >= 20 and DeepSeek Harness (dsh).
git clone https://github.com/Cheyeah/dsh-drop-preview.git
dsh plugin --profile web add <path-to-this-repo>
# or: dsh plugin --profile web add github:Cheyeah/dsh-drop-preview
Restart dsh web, then hard-refresh the browser (Ctrl+F5).
Usage
- Open a session and choose a workspace
- Drag files / folders anywhere onto the page → full-page preview
- Send to AI: files enter the attachment queue, are copied into the workspace attachment directory on send, and their paths go to the model
- Or Save to file box: keep files in the box above the composer and preview / send them any time
Markdown relative images (
images/x.png): resolved from the dropped set first, then auto-searched in the workspace (up to 3 levels); otherwise a clear “image not found” notice is shown.
Compatibility
- Verified on DeepSeek Harness
0.1.0-rc.6(npm release) - Pure JavaScript, no build step, no third-party runtime dependencies
How it works
- Host half (
lib/index.js): registers the attachment upload API (batch upload / commit / cleanup) and the image-resolve endpoint/dsh-drop-preview/v1/imageonwebServer - Client half (
lib/client.js): registers via__ModuleLoader__, uses theslots/conversation/sessions/inputTriggersservices; the attachment protocol block (==== DSH_PASTE_INPUT_V1 ====) is folded into chips in bubbles
Development
node --check lib/index.js
node --check lib/client.js
Uninstall
dsh plugin --profile web remove dsh-drop-preview
Acknowledgments
- Derived from lhh010/dsh-paste-input (MIT)
- And its upstream dsh-external/dsh-multimedia-webui-input (MIT)
License
MIT