Repository navigation
dsh-2sidebar v0.1.2
dsh-2sidebar v0.1.2
分栏界面重构、会话标题栏打开修复,以及包结构与清单整理;除修复项外没有其他行为变化。
改进
界面
- 对齐 DSH 原生侧栏:13 px 内容字阶、38 px header、28 px 工具按钮、5×10 px 行内边距、每级 18 px 缩进。
- 复用宿主组件与图标:共享
PathLabel、文件夹开/合图标、按扩展名着色的文件类型图标;目录优先 + 自然排序。 - 统一设计 token:分栏、文本预览、滚动条、空/错误状态和图片背景使用
--dsw-alias-*/--dsw-radius-*。 - 统一图标:页签标题、会话标题栏按钮与右侧栏引导卡片使用原生 compare-split 图标。
打包与结构
- npm 包根改为仓库根:
package.json、index.js、client.js、cordis.patch.yml、locale/、icon.svg直接位于仓库根目录,plugin/子目录已移除。 - 清单对齐 DSH 插件契约:
engines.dsh、导出的./package.json、Host 半侧的name、包名形式的dsh.client.inject,并移除空config与immediately预取。
修复
- 打开分栏不再先展开空侧栏:新会话或关闭全部页签后只出现「目录分栏」,不会同时留下「开始」页;活动的「开始」页按官方引导卡片规则让位。
安装
- 从 npm:
dsh plugin --profile desktop add dsh-2sidebar - 本地开发:
dsh plugin --profile desktop add "link:<repo>" - 自检:
node --check client.js、npm pack --dry-run
限制
- 仅文本与图片预览;PDF / Office / HTML 用 DSH 原生预览页签。
- 需要包含
@deepseek-ai/dsh-client-ui-primitives基线的 DSH 版本;客户端 API 已按 0.2.1-rc.5 核对。 - 其余上限与限制见 README。
完整的技术细节请见 CHANGELOG。
English
Split-view UI refactor, session-header fix, and bundle layout/manifest cleanup; apart from the fix, behavior is unchanged.
Changed
UI
- Follows the native DSH sidebar: 13 px content type, 38 px headers, 28 px tool buttons, 5×10 px row padding, 18 px nested indentation.
- Reuses host primitives and icons: shared
PathLabel, folder open/close icons, per-extension file-type icons; directories first with natural ordering. - Design tokens: split and text-preview headers, scrollbars, empty/error states and image surfaces use
--dsw-alias-*/--dsw-radius-*. - Native icon: tab chip, session-header button and guide card use the native compare-split icon.
Packaging and layout
- npm package root is the repository root:
package.json,index.js,client.js,cordis.patch.yml,locale/andicon.svglive there directly;plugin/is gone. - Manifest follows the DSH plugin contract:
engines.dsh, an exported./package.json, a Host-halfname, package-namedsh.client.injectedges, and no emptyconfigorimmediatelyprefetch.
Fixed
- Opening the split tab no longer expands an empty sidebar first: a fresh or fully closed session shows only the split tab, and an active Start page gives way as the host's guide entries do.
Install
- From npm:
dsh plugin --profile desktop add dsh-2sidebar - Local development:
dsh plugin --profile desktop add "link:<repo>" - Verify:
node --check client.js,npm pack --dry-run
Limitations
- Text and image previews only; use DSH's native preview tabs for PDF / Office / HTML.
- Requires a DSH version with the
@deepseek-ai/dsh-client-ui-primitivesbaseline; the client APIs were checked against 0.2.1-rc.5. - Other caps and limitations: README.
Full technical details: CHANGELOG.