Menghuan1918
|
82a69546d2
|
feat: 公共 API 基座化(v0.12.0,纯增量)— 类型/能力/设置 seam 全面补齐
- 类型生态:service 模块 re-export SidebarTab/SidebarState/SidebarStore/
SidebarSnapshot/SidebarDiffRef/TabType/SessionScope/SidebarPrefs 等公共
状态词汇(此前 TS2459 无法命名);context-types 去 Node 依赖(结构镜像
SidebarHttpRequest/Response/UpgradeSocket/Head),client 可达声明图零
node:* 引用,外部消费者无 @types/node + skipLibCheck:false 可编译
(scripts/check-consumer-types.sh 守护)
- 服务能力:version/features 版本与能力探测(单调只增)、getSnapshot/
subscribeState 状态订阅、updateTab(title/path/meta)、activateTab、
openFile(路径派生 id 与内置拦截一致)、openTab(seed, scope?) 定向到
指定 session(store.reduceFor 不扰动 UI)
- TabDescriptor:badge 角标(99+ 封顶,抛错吞掉)、onOpen/onActivate/
onClose 生命周期回调(service 路径派发,dedupe 聚焦触发 onActivate
而非 onOpen,抛错不打断流程);SidebarTab.meta JSON 可序列化跨刷新
持久化(sanitize 宽松保留)
- 设置 seam 开放:PrefsSchema 增 pluginSettings 开放嵌套 map(z.dict),
settings.pluginToggles(插件自有行,同 switch/text/number 控件)与
settings.render(自定义面板,含 store/service/prefs/updatePluginSetting/
close props);viewer 卡片 v0.12.0 起也有齿轮设置弹窗
- FileViewerDescriptor.load 增第三参 AbortSignal(EditorHost 生命周期中止)
- UI 接线:tab 激活/关闭改走 service(跨树激活修复 + 回调触发)、+ 菜单
传 scope、TabBar badge pill 渲染;active-session scope 走原 reduce 路径
保证 notify
- 测试 +23:生命周期/定向打开/updateTab/activateTab/openFile/meta 持久化/
reduceFor/能力常量(与 package.json 锁步)、consumer-types.ts 编译门、
api-surface.spec.ts(client 图零 node 依赖守护);既有 430 测试全绿
- 文档:AGENTS.md 修 available 三参示例并补全部新 API;external-plugin-
guide.md 刷新至 v0.12.0(7 tab + 9 viewer、设置 seam 开放、类型导入
路径建议);README×2 服务化小节同步
未发版 npm(用户决定);分支 feat/plugin-api-v012。
|
2026-08-14 20:44:43 +08:00 |
|
Atlas Zeng
|
09de13c7bc
|
Merge pull request #30 from starkirby125918/fix/install-ps1-powershell51
fix: install.ps1 兼容 PowerShell 5.1(node -e 引号被吞 + UTF-8 BOM)
|
2026-08-14 15:44:23 +08:00 |
|
Menghuan1918
|
d94465c28d
|
fix: install.sh 变量加花括号($WS_YML:→ ${WS_YML}),修复 macOS bash 3.2 下 unbound variable(#23)
|
2026-08-14 15:38:43 +08:00 |
|
starkirby125918
|
9642e95e89
|
fix: install.ps1 兼容 PowerShell 5.1(node -e 改临时文件,补 UTF-8 BOM)
|
2026-08-14 15:22:56 +08:00 |
|
Menghuan1918
|
e128c303bc
|
feat: 新增 Windows PowerShell 一键安装脚本 install.ps1,README 安装章节两平台同步
- scripts/install.ps1:官方 CLI 方式一键安装(PowerShell 5.1+/pwsh),
与 install.sh 对齐:预写 allowBuilds + minimumReleaseAgeExclude(幂等)、
执行 dsh plugin add、幂等清理旧手动挂载行;支持 -Version/-Restart/-DryRun。
- scripts/install.sh:加固 — -h/--help、Windows Git Bash 下 DSH_HOME 回退
$USERPROFILE、npm/pnpm view 双通道解析最新版本、失败提示细化、挂载行
清理改为逐块扫描(删除注释块跟随)。
- README.md:安装章节改为「① 前置 → ② 对应平台一键命令 → ③ 重启硬刷新」,
macOS/Linux 与 Windows PowerShell 双命令示例。
- package.json:files 列表纳入 scripts/install.ps1。
|
2026-08-14 00:48:44 +08:00 |
|
Menghuan1918
|
9fdb44d9f9
|
feat: 支持官方 CLI 一行安装(dsh plugin add dsh-better-sidebar)
- package.json 声明 dsh.bundle.patch(./cordis.patch.yml),随包发布挂载
patch;dsh plugin --profile <name> add dsh-better-sidebar@<v> 自动完成
安装 + 注册到 dsh.profile.bundles + 下次启动挂载(无需手写挂载行)
- cordis.patch.yml:bundle 挂载层(insert better-sidebar)
- scripts/install.sh:改走官方 CLI;预写 allowBuilds(node-pty/protobufjs)
规避 pnpm 11 strict-dep-builds 非零退出;幂等移除旧手动挂载行防双挂载
- README(EN):安装置顶官方 CLI 一行命令
v0.10.2
|
2026-08-13 23:19:05 +08:00 |
|
Menghuan1918
|
a85d1ab004
|
feat: v0.10.1 — 新增一键安装脚本 scripts/install.sh,README 安装置顶 npm 方式
- scripts/install.sh:把插件以 npm 包形式装进 web profile(幂等写依赖 + 挂载行 + pnpm install;支持版本参数 / --restart / --dry-run)
- 版本 0.10.0 -> 0.10.1(修正 npm 元数据 repository URL 到 omdsh-dev)
- scripts/install.sh 纳入发布 files
|
2026-08-13 22:42:26 +08:00 |
|
Menghuan1918
|
bab659f8bd
|
feat: 客户端懒加载分块 — 重依赖(Univer/xterm/CodeMirror/Office)拆独立 bundle 按需下发(/sidebar/bundle 路由 + __dshChunks__ 注册表),核心启动仅 ~325KB
|
2026-08-12 18:19:44 +08:00 |
|
Menghuan1918
|
7eccc49f6e
|
revert: 移除构建期 IME 守卫补丁 — 补丁打在产物上不具持久性
taekchef 的 apply-ime-guard.mjs 在每次 build/prepare/bundle 后把守卫
字符串注入 lib/client.js,但补丁对象是构建产物而非源码:
- 裸 tsdown 重建 / 其他构建路径产出无守卫的 bundle(#562 复发根因)
- 守卫逻辑游离于源码之外,难以测试与维护
运行时方案(src/client/ime-guard.ts + tests/ime-guard.spec.ts)已在
源码内实现同等守卫,经 document capture 覆盖全部劫持路径,任何构建
方式产物都自带守卫。合并远端提交后撤掉构建期补丁,保留运行时方案。
|
2026-08-12 14:41:36 +08:00 |
|
taekchef
|
a465bdee38
|
fix(ime): 持久化 IME 守卫脚本并挂入 build/prepare/bundle 构建路径
- scripts/apply-ime-guard.mjs 纳入版本库(此前 untracked,重 clone 即丢)
- Univer InputNumber 在 document capture 拦截全页 ↑/↓ 且无 isComposing
守卫,会摧毁中文输入法组合;prepare/bundle 裸 tsdown 重建会产出无守卫
的 lib/client.js,2026-08-11 因此复发(dsh-external/issues#562)
- 脚本幂等:已注入则跳过;目标模式匹配不到则 exit 1 显式失败
Fixes #562
|
2026-08-12 03:13:31 +08:00 |
|
Menghuan1918
|
a1286191d6
|
feat: plugin-registry 标准发布面(dsh.plugin.json + 双 client bundle + registry 打包),v0.1.2
- dsh.plugin.json 原生清单:id dsh-external/dsh-better-sidebar,version 0.1.2,
main = lib/index.js,client.main = lib/client-registry.js,contributes 空声明
- tsdown client 构建参数化:lib/client.js(官方通道,id = 包名)+ lib/client-registry.js
(registry 通道,id = 清单 id),同源不漂移
- scripts/package-registry.mjs 组装 registry/ 安装根(gitignore,不入库)
- tests/manifest-consistency.spec.ts:id 两段校验 / version 同步 / 入口存在 /
双 bundle id 不互换 / contributes 空
- README:新增「通过 plugin-registry 安装(标准)」章节 + 保留官方 profile 安装
方案 + 通道互斥说明;架构表补 manifest 与双 client 行
|
2026-08-09 23:49:58 +08:00 |
|