Skills Plugins MCP Prompt Model 导航 博客 资讯 我的中心
界面增强 #css#deepseek-harness#dsh#dsh-plugin#javascript#snippets

dsh-snippets

管理 DSH Web 界面的 CSS 与 JS 代码片段:启用的 CSS 注入为 style 元素,启用的 JS 在页面内执行;提供侧栏底部快捷开关,设置里在「插件」下自带一张卡片,并可选本地文件夹监听与 Gist 同步。

zhang24xiao @zhang24xiao ⬇ 2 ★ 0 main

安装

dsh plugin --profile web add github:zhang24xiao/dsh-snippets
下载安装清单

需要可复现安装时,可在仓库后追加 #commit 固定提交。

管理 DSH Web 界面的 CSS 与 JS 代码片段:启用的 CSS 注入为 style 元素,启用的 JS 在页面内执行;提供侧栏底部快捷开关,设置里在「插件」下自带一张卡片,并可选本地文件夹监听与 Gist 同步。

该插件未提供要点说明,请参考仓库 README。

cssdeepseek-harnessdshdsh-pluginjavascriptsnippets
  1. 安装并启动 DeepSeek Harness:npx @deepseek-ai/dsh web
  2. 在终端执行上面的安装命令(CLI 会解析插件并核验来源)
  3. 用 dsh plugins list 确认已安装,必要时重启 Harness 生效

插件以当前 dsh 进程的权限运行,安装时可能执行代码。请先通读仓库源码与许可证,确认无破坏性命令与越权访问;本站只做索引,不对第三方插件安全性作担保。

代码仓库github.com/zhang24xiao/dsh-snippets
许可证MIT
主要语言main
下载量2
GitHub 星标0
最近推送2026-09-17
收录日期2026-09-19
分类界面增强

事实信息来自公开插件目录快照(2026-10-01),介绍文案由本站再加工。

以下为插件仓库 README 全文(原始内容,由公开目录抓取整理)。

# dsh-snippets

CSS and JS code snippets for the [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) web GUI.

A full-width quick toggle in the sidebar footer, aligned column for column with
the **Settings** row above it (a `` glyph on the left, the name on the right),
opens a manager panel, and
**Settings → Code Snippets** is an independent page with the full set of
preferences. Enabled **CSS** is injected into the page immediately; enabled
**JS** runs after the page loads.

> Inspired by [TCOTC/snippets](https://github.com/TCOTC/snippets), the SiYuan
> note-taking app's snippet manager, and adapted to the DSH plugin contract.

[简体中文](./README.zh-CN.md)

## Screenshots

The quick toggle fills a whole row of the sidebar footer, exactly like Settings, and opens the manager panel:

![The snippet manager panel, opened from the sidebar footer beside Settings](./assets/screenshot-1-panel.png)

**Settings → Plugins → Plugin configuration** carries the card, beside every other plugin's settings:

The editor is CodeMirror 6 — line numbers, CSS/JS highlighting, search and replace — sized to the viewport, with live CSS preview:

![The snippet editor, showing a CSS snippet with syntax highlighting](./assets/screenshot-3-editor.png)

## Features

**Managing snippets**

- CSS / JS tabs with live counts, one master switch per type, and search across
  titles, code, or both
- Lives with the other plugin settings, in Settings → Plugins → Plugin configuration
- Add, edit, duplicate, delete, enable/disable, and drag to reorder
- Ten sort orders (custom, enabled-first, title A→Z / natural, oldest/newest)
- Per-row edit / duplicate / delete buttons, each individually hideable
- One-click **Reload the interface** for changes only a reload can apply

**Editing**

- CodeMirror 6: line numbers, CSS/JS syntax highlighting, bracket matching, fold
  gutter, search & replace, history
- Configurable indent unit, font size and soft wrap; the theme follows the app,
  including dark mode
- **Live CSS preview** — see the page change while you type, without saving
- The editor dialog sizes itself to the viewport (up to 1040×760) instead of the
  shell's 380px form card, and the code area absorbs the leftover height, so a
  long snippet scrolls inside the card rather than pushing the dialog past the
  window edge
- Best-effort re-indent that only ever rewrites leading whitespace
- Content guards: CSS containing `` glyph + the name |
| Settings | `settings.plugin.item`, the card list under **Settings → Plugins → Plugin configuration** |
| Editors, confirmations, toasts | `shell.overlay` |
| Snippet library | the `dsh-snippets` namespace of the profile's settings document |
| Backups, Gist token, watcher memory | `$DSH_HOME/dsh-snippets/` |

## Layout notes

- The sidebar-foot trigger follows the column width in two shapes, and both are
  measured against the **Settings** row:
  - **wide** is one whole row: 42px tall, `padding: 0 10px 0 8px`, an 8px gap
    between glyph and label, radius 12, 14px/22px type — the Settings row's own
    numbers, field for field, which is what lands both rows' glyphs and labels
    on one column;
  - **rail** is a bare `36×36` circle with `margin: 8px 0 10px`, matching the
    circle in Settings' own rail row.

  The wide row's label carries the name; the tooltip still reports the total
  and enabled counts.
- That 4px side bleed in the wide state (`width: calc(100% + 4px);
  margin: 4px -2px`) is copied from the Settings row's own container. Without
  it this row sits 2px to the right of Settings — that 2px *is* the alignment.
- The sidebar shell lays the foot out as a column but keeps
  `sidebar.footer.action` a **row** even when the column is collapsed to the
  56px rail. With one action that is invisible; with two, the icons land side by
  side and overflow. This plugin therefore injects one narrowly scoped rule that
  makes the collapsed row a column again — and lets the wide row **wrap**,
  because the seat is shared: a full-width entry (this plugin, or `dsh-mobile`'s
  phone entry) would otherwise push its neighbour past the sidebar edge, where
  the shell's overflow hides it:

  ```css
  html [class*='_footerActions']             { gap: 6px; flex-wrap: wrap; }
  html [class*='_collapsed'] [class*='_footerActions'] { flex-direction: column; gap: 4px; … }
  ```

  The attribute-substring selectors are deliberate: if the shell's class hashes
  change, the rule simply stops matching and the rail falls back to the shipped
  layout instead of breaking.

## How CSS and JS take effect

- Each enabled **CSS** snippet becomes one `

数据来源:公开的 DeepSeek Harness 插件目录与各插件 GitHub 仓库。本站为独立第三方目录,与 DeepSeek、幻方(High-Flyer)及插件作者均无隶属或背书关系。

每日精选 Skill 推荐,免费送到你邮箱

输入邮箱,每天接收一个精选 AI Agent 技能推荐。完全免费,持续更新。

提交后我们会发送一封确认邮件,点击邮件里的链接才会开始收信。

完全免费,取消任意时间。我们不会发送垃圾邮件。