dsh-web
zhu1090093659/dsh-webDeepSeek Harness(DSH)Web 插件聚合生态包 · 一切皆插件,创意工坊分发(dsh-market.com)
DSH independent right-panel Markdown live preview: edit + render side by side, auto-refresh on file change, send selection back to chat.
DSH 独立右侧面板 Markdown 实时预览插件
边写边渲染,文件被 Agent 改了自动刷新,选中一段可丢回对话继续改。
.md 文件变化,Agent 修改后自动刷新# 1. 克隆并构建
git clone <your-repo-url>
cd dsh-md-live
pnpm install
pnpm run build
# 2. 在 DSH 中安装
dsh plugin --profile web add .dsh plugin --profile web add dsh-md-livepreview_md 打开文件,或在面板中手动选择.md 文件插件注册了两个工具供 Agent 调用:
preview_md在预览面板中打开 Markdown 文件。
{
filePath: string // 相对于工作区的路径
}export_md导出 Markdown 文件为 HTML 或 PDF。
{
filePath: string,
format: 'html' | 'pdf'
}在 cordis.patch.yml 或 DSH 配置文件中:
md-live-host:
workspacePath: /path/to/workspace # 监听的工作区路径
extensions: ['.md', '.markdown'] # 监听的文件扩展名
debug: false # 启用调试日志# 安装依赖
pnpm install
# 构建 host 端
pnpm run build:host
# 构建 client 端
pnpm run build:client
# 完整构建
pnpm run build
# 清理
pnpm run cleandsh-md-live
├── Host (Node.js)
│ ├── 文件监听 (chokidar)
│ ├── RPC 网关 (md-live:read-file, md-live:list-files)
│ └── 工具注册 (preview_md, export_md)
├── Client (React)
│ ├── 面板注册 (main + sidebar.panellist slots)
│ ├── Markdown 渲染 (marked + highlight.js)
│ ├── TOC 生成
│ └── 选区处理
└── 样式 (CSS variables, 明暗主题)MIT