2 Commits
Author SHA1 Message Date
qiqi e7b6e23f8f feat(plugin): 新增 image-annotate 标注/修图插件 + 构建链
- 编辑器逐字移植自 iwb-plaus/iwb-cutout-extension(11 模块 + 2 个 shared 文件,纯 Canvas 2D、零第三方库)
- plugin/ 存 ESM 源码,src/index.js 是构建产物(提交进仓,CI 只校验不构建)
- scripts/build-plugin.mjs:esbuild 打包 + banner/footer 手写单引号 manifest + 产物自检
- 能力 commands / nodeActions / canvas / canvasWrite;入口 = 节点漂浮菜单 + 右键命令
- 导出模式按编辑器字面量映射:replace → setNodeImage,newNode → createImageNode
2026-10-19 14:03:55 +08:00
qiqi a2ead34483 ci: 插件仓校验(P4-15 之三)——契约校验器 + GitHub Actions
- scripts/validate.mjs:逐个插件校验
  · package.json 的 ibwPlugin(id 须 ^[a-z][a-z0-9-]{2,31}$、apiVersion 正整数、entry 存在)
  · entry 语法(node --check)+ 必须调用 IWBPluginHost.register(
  · entry 内 manifest 与契约一致(id / apiVersion 对齐、name/version/capabilities 齐备)
  · 仓库内 id 不得重复
  只读源码、不构建 ⇒ CI 无需网络或依赖
- .github/workflows/ci.yml:push / PR 跑 node scripts/validate.mjs
- package.json(根,private):npm run validate
- README:补「校验(本地 + CI)」段

本地验证:node scripts/validate.mjs → 2/2 通过(template-demo / xianyi-cutout)
2026-10-18 01:44:49 +08:00