Compare commits

..
9 Commits
Author SHA1 Message Date
qiqi ebc6ce1251 docs(site): v3.26.87
Verify (Gitea) / gate (build · unit · facts) (push) Failing after 1m30s
2026-11-25 22:54:07 +08:00
qiqi 55408acca1 docs: 锚点对齐 v3.26.87+0ae9c60(publish 自动) 2026-11-25 22:53:56 +08:00
qiqi 0ae9c6091c release: v3.26.87 结果图拖拽到画布(复用图库插入链路) 2026-11-25 22:52:38 +08:00
qiqi e63f3eea48 docs(site): v3.26.86
Verify (Gitea) / gate (build · unit · facts) (push) Failing after 7s
2026-11-25 22:51:22 +08:00
qiqi 40607a48be docs: 锚点对齐 v3.26.86+43d6a63(publish 自动) 2026-11-25 22:51:00 +08:00
qiqi 43d6a63f9f release: v3.26.86 输出节点双击预览(真实渲染位置+行为测试) 2026-11-25 22:47:58 +08:00
qiqi e482ce502d docs(site): v3.26.85
Verify (Gitea) / gate (build · unit · facts) (push) Failing after 1m18s
2026-11-25 22:46:36 +08:00
qiqi d9d293e6b1 docs: 锚点对齐 v3.26.85+a4c5cca(publish 自动) 2026-11-25 22:46:01 +08:00
qiqi a4c5ccad0e release: v3.26.85 动效 token + 下载浮层(图库/输出节点) 2026-11-25 22:44:45 +08:00
24 changed files with 321 additions and 63 deletions

No files matched your search

+20
View File
@@ -16,6 +16,26 @@
> 3. 核验正式地址版本 → 之后才移动 `stable` / `stable-verified-<日期>` 标签、更新本 CHANGELOG、写 GitHub Release(`gh release create`)。
> 测试发现问题 → 改 → 再 `deploy:test`,正式环境不受影响。回滚点 `git reset --hard stable`。
## v3.26.87(2026-11-26)结果图拖到画布:复用图库插入链路
- 输出节点的结果图可**直接拖到画布**生成参考图节点:`dragstart` 写 `application/x-iwb-output-ref`(结果 URL),`drop` 时先按 URL 在图库索引里找条目 → 走**本地字节**(原图/缩略图)→ 引用化;没命中也不阻断,退回 URL 建节点。
- `pointerdown` 在图片上停止冒泡:**拖图不会顺带拖动节点**;单击仍选中、双击仍预览。
- 插入后清一次画布手势残留(原生拖放期间 pointerup 不落地),避免「拖完第一次点节点被当成收尾」。
- 与图库拖入共用同一段插入代码,不新造第二条落点/引用化逻辑。
## v3.26.86(2026-11-26)输出节点双击预览:改在真实渲染位置 + 行为测试
- **真实位置**:输出节点的结果图由 `src/ui-node-bodies.js` 的 `renderOutBody → outCell` 渲染,不是 `ui-components.js` 的 `ResultImg`。v3.26.83 没匹配到的原因就在这里;v3.26.85 已把 outCell 改成**单击选中、双击预览**,本版补上测试与遗留组件对齐。
- `ResultImg` 同步手势:单击只阻止冒泡(让节点选中),双击才 `onPreview`;`title` 改「双击放大」。
- 新增 `tests/result-img-doubleclick-test.js`:用假 React 树断言「单击不预览 / 双击带 URL」,以及共享下载浮层两个按钮的回调与 `pointerdown` 不冒泡(不拖动节点)。
## v3.26.85(2026-11-26)动效 token + 下载浮层(图库 / 输出节点共用一套 hover)
- 新增 7 个 L2 token:`--iwb-motion-hover` / `--iwb-ease-hover` / `--iwb-hover-lift` / `--iwb-hover-scale` / `--iwb-hover-shadow` / `--iwb-hover-border` / `--iwb-scrim`;`design-tokens.css` 由 `tokens:write` 生成,token 棘轮零增长。
- **输出节点结果图**:底部渐变下载浮层(新共享组件 `ResultDownloadOverlay`),hover 抬 2px + 1.02 缩放 + 投影 + 品牌描边;**单击选中、双击开预览**(不再单击即弹预览)。下载/复制按钮只在悬停或键盘聚焦时出现。
- **图库插件 1.7.3**(已上架插件市场):卡片 hover 上浮 + 阴影 + 品牌描边,原本在卡片下方的「下载」移到**底部渐变浮层**;与输出节点共用宿主 token(插件侧带 fallback,旧客户端不崩)。
- 两处都支持 `prefers-reduced-motion: reduce`(只保留颜色/阴影,不做位移与缩放)。
## v3.26.84(2026-11-26)图库落盘自检:先在诊断页看清「图在哪一层」
- 设置 → 诊断 →「存储体检」新增**图库落盘自检**:逐条判定 **原图 OK / 仅缩略图 / 全丢**。桌面端会真的去 `images/gallery` 查文件是否存在(只查存在性,不读字节,避免诊断本身把堆顶撑高)。
+1 -1
View File
@@ -40,7 +40,7 @@ build esbuild 打包到 dist/(单 dist/app.js = src/ 模块按序
node --check app.js 与 dist/app.js 语法
check-dist.js 产物体检
lint ESLint(src/ + app.js,正确性规则)
test:unit 130 个单测文件(jsdom 契约测试;2026-11-07 新增 sync-facts-guard(事实一致性)/ _helpers/source(统一源文本);2026-11-12 新增 provider-ping(测速 no-cors 兜底))
test:unit 131 个单测文件(jsdom 契约测试;2026-11-07 新增 sync-facts-guard(事实一致性)/ _helpers/source(统一源文本);2026-11-12 新增 provider-ping(测速 no-cors 兜底))
test relay-task-graph-fixture + iwb-v32-web-test
test:facts 事实基线守门(见 §5)
typecheck 渐进类型检查(tsc --noEmit;范围 = src/*.js,不含 app.js)
+2 -2
View File
@@ -1,7 +1,7 @@
# 现状架构与性能事实基线(桌面版)
> **本文档是什么**:现状**事实快照**,不是规范。用途:任何性能 / 内存 / 存储相关改动,先对齐这里的现实,避免把已经调好的东西改坏。
> 日期 **2026-10-20**(**2026-11-16 复算 · v3.24.85**)| 基线(**最近一次 bump 版本的提交**,不是主干 HEAD)`main = 7f262da`(线上 `v3.26.84+7f262da` —— 2026-11-24 **图库:出图即入图库 + 插入落本地副本(能标注)**:每张生成完成即归档并通知插件(此前只在整轮结束写一次 ⇒ 生成中图库一直空)、插入取源改本地字节优先并引用化(抓不到才留原链接 + 提示)、`getNodeImage` 补 `data.localRef` 候选(远程缓存命中却仍判「不支持标注」的直接成因)、批量插入改 4 列栅格(旧实现同批全叠一处),逻辑落 `src/gallery-sync.js`,app.js 只装配;上一条 `v3.26.60+cf0e9a0` —— **浮层字号上调一档**:「模型设置」「图像设置」选择项 11→13px、高 22→28、左右内距 6→10、间距 4→6、标题 12→14、面板 328→360,改动全落在 `.iwb-pop` 的 6 个 token(两面板共用一套);上一条 `v3.26.59+e966b34` —— 备份新增 `plugin-files/` 通道,提示词封面换机不再丢;再上一条 2026-11-23 **节点正文文本区修复**:提示词/文本节点正文透明继承卡片底色(白卡片消失)、编辑态三层框(控件 border / 聚焦光晕 / D8 焦点环)全去掉,规范补表面角色三分法与 `node-scope-test` 第 5 条守卫,8 张基线重录;上一条 `v3.26.51+21554b0` —— **M6 延展验证**:插件面板两段六次叠加样式合并重写、133 行新增零裸值;补 `--iwb-font-base`(14px) 第 8 档与亮色状态色调深(对浅页面 2.13 → ≥4.6),对比度守卫 114→138 对;新增 ⑦⑧ 组件夹具基线共 16 张;`batch-export` 1.2.2 状态色走宿主 token、去掉纯蓝主按钮;棘轮基线首次下调。M1–M6 全部完成;上一条 `v3.26.50+cab473c` —— **M5 闸门**:新增 `scripts/token-lint.js`(只查 diff 新增行,CSS 与 JS 内联样式两套判据、四类白名单)+ `tests/design-token-ratchet-test.js`(13 项计数只降不升)+ `tests/theme-contrast-test.js`(亮/暗 × 文字 × 表面 114 对),三条各做一次打红验证后接进 `verify:ci`;顺手把首启动「选择资料目录」弹窗 token 化(全仓最后一个完全未 token 化的界面);上一条 `v3.26.49+1743453` —— **M4-B6 收尾**:`style.css` 剩余 16 处半像素字号全清零(守卫收紧为全文件断言)、`--iwb-control-h` 裁定不扩到全局控件(并排表单 vs 成组紧凑控件);插件主题契约重写,`ALLOW_FILES` 文件级豁免 **6 → 0** —— 改为「私有皮肤 manifest 自声明 `skin` + chroma 强调色判据 + 内容色行内标记」,声明私有皮肤的插件不得引用宿主颜色 token;同步 4 个插件版本,插件侧中性色写死归零;视觉基线 8 张因字号栅格化变化更新,A/B 回退确认非环境噪声;上一条 `v3.26.48+cb9cb9c` —— **M4-B5 节点**:节点卡内部表面统一 `--iwb-field` —— 端口底色从 `#161616`(暗色对卡片差 39 级,一颗黑洞)改 `#494949`(差 12 级),同病灶另 6 处(ref-img/ref-single/upload-link/refmini-empty/task-result-img/node-head:hover)一并改;浮条与任务卡 hover 改 `color-mix(text 10%)`(原来 panel 与 layer2 深色同色,hover 无反馈);字号 12/15/11/13 全归档位、圆角 8/6/5/14 归并、间距 52 处等值 + 13 处 1px 级微调;删 6 个死类名;新增 `tests/node-scope-test.js` 钉「节点内禁用面板表面色」;上一条 `v3.26.47+f5c8174` —— **M4-B4 设置/外观**:新增 `--iwb-control-h`(30px) 修「同行输入框 33px / 按钮 24px」的 9px 落差;设置页正文 14→13、标题 16→15,范围内半像素字号清零;删 21 条死规则(setcell/setgrid/set-row/appear-val 等);新增 `tests/settings-scope-test.js` 钉「控件等高 / 死类名不复现 / 引用的 token 必须存在」;上一条 `v3.26.46+9f29996` —— 2026-11-23 **M4-B3 首页/库**:删 30 条零生产者规则(25 个类名在产物里 0 次)+ 4 条被 specificity 覆盖的死声明,`style.css` 2391→2339 行;首页/库 106 条规则换 token,间距写死 91→5(只剩版心与导航让位的布局值)、字号写死清零,新增 `--iwb-font-display:24px` 第 7 档;验收改为「计算样式逐元素 diff + 12 张基线只首页 2 张变化」;上一条 `v3.26.45+968ff46` —— **M4-B2 浮层层级表 + 阴影四档**:14 档 `--iwb-z-*`(裸 z-index 取值种类 42→31)、`--iwb-elevation-1..4`(浮层 8 种阴影写法→4 档)、`.iwb-pop` 圆角 18→`radius-popover(14)`;修「弹窗里点保存看不到提示」—— 根因不是层级数字而是 `.iwb-overlay` 本身就是堆叠上下文,toast 改为 portal 到 `body`;新增 `tests/overlay-layer-test.js` 钉 9 条顺序约束;上一条 `v3.26.44+846a59b` —— **设计 token 体系重建**:D1–D9 色彩模型改为真正的深色(#121Line truncated
> 日期 **2026-10-20**(**2026-11-16 复算 · v3.24.85**)| 基线(**最近一次 bump 版本的提交**,不是主干 HEAD)`main = 0ae9c60`(线上 `v3.26.87+0ae9c60` —— 2026-11-24 **图库:出图即入图库 + 插入落本地副本(能标注)**:每张生成完成即归档并通知插件(此前只在整轮结束写一次 ⇒ 生成中图库一直空)、插入取源改本地字节优先并引用化(抓不到才留原链接 + 提示)、`getNodeImage` 补 `data.localRef` 候选(远程缓存命中却仍判「不支持标注」的直接成因)、批量插入改 4 列栅格(旧实现同批全叠一处),逻辑落 `src/gallery-sync.js`,app.js 只装配;上一条 `v3.26.60+cf0e9a0` —— **浮层字号上调一档**:「模型设置」「图像设置」选择项 11→13px、高 22→28、左右内距 6→10、间距 4→6、标题 12→14、面板 328→360,改动全落在 `.iwb-pop` 的 6 个 token(两面板共用一套);上一条 `v3.26.59+e966b34` —— 备份新增 `plugin-files/` 通道,提示词封面换机不再丢;再上一条 2026-11-23 **节点正文文本区修复**:提示词/文本节点正文透明继承卡片底色(白卡片消失)、编辑态三层框(控件 border / 聚焦光晕 / D8 焦点环)全去掉,规范补表面角色三分法与 `node-scope-test` 第 5 条守卫,8 张基线重录;上一条 `v3.26.51+21554b0` —— **M6 延展验证**:插件面板两段六次叠加样式合并重写、133 行新增零裸值;补 `--iwb-font-base`(14px) 第 8 档与亮色状态色调深(对浅页面 2.13 → ≥4.6),对比度守卫 114→138 对;新增 ⑦⑧ 组件夹具基线共 16 张;`batch-export` 1.2.2 状态色走宿主 token、去掉纯蓝主按钮;棘轮基线首次下调。M1–M6 全部完成;上一条 `v3.26.50+cab473c` —— **M5 闸门**:新增 `scripts/token-lint.js`(只查 diff 新增行,CSS 与 JS 内联样式两套判据、四类白名单)+ `tests/design-token-ratchet-test.js`(13 项计数只降不升)+ `tests/theme-contrast-test.js`(亮/暗 × 文字 × 表面 114 对),三条各做一次打红验证后接进 `verify:ci`;顺手把首启动「选择资料目录」弹窗 token 化(全仓最后一个完全未 token 化的界面);上一条 `v3.26.49+1743453` —— **M4-B6 收尾**:`style.css` 剩余 16 处半像素字号全清零(守卫收紧为全文件断言)、`--iwb-control-h` 裁定不扩到全局控件(并排表单 vs 成组紧凑控件);插件主题契约重写,`ALLOW_FILES` 文件级豁免 **6 → 0** —— 改为「私有皮肤 manifest 自声明 `skin` + chroma 强调色判据 + 内容色行内标记」,声明私有皮肤的插件不得引用宿主颜色 token;同步 4 个插件版本,插件侧中性色写死归零;视觉基线 8 张因字号栅格化变化更新,A/B 回退确认非环境噪声;上一条 `v3.26.48+cb9cb9c` —— **M4-B5 节点**:节点卡内部表面统一 `--iwb-field` —— 端口底色从 `#161616`(暗色对卡片差 39 级,一颗黑洞)改 `#494949`(差 12 级),同病灶另 6 处(ref-img/ref-single/upload-link/refmini-empty/task-result-img/node-head:hover)一并改;浮条与任务卡 hover 改 `color-mix(text 10%)`(原来 panel 与 layer2 深色同色,hover 无反馈);字号 12/15/11/13 全归档位、圆角 8/6/5/14 归并、间距 52 处等值 + 13 处 1px 级微调;删 6 个死类名;新增 `tests/node-scope-test.js` 钉「节点内禁用面板表面色」;上一条 `v3.26.47+f5c8174` —— **M4-B4 设置/外观**:新增 `--iwb-control-h`(30px) 修「同行输入框 33px / 按钮 24px」的 9px 落差;设置页正文 14→13、标题 16→15,范围内半像素字号清零;删 21 条死规则(setcell/setgrid/set-row/appear-val 等);新增 `tests/settings-scope-test.js` 钉「控件等高 / 死类名不复现 / 引用的 token 必须存在」;上一条 `v3.26.46+9f29996` —— 2026-11-23 **M4-B3 首页/库**:删 30 条零生产者规则(25 个类名在产物里 0 次)+ 4 条被 specificity 覆盖的死声明,`style.css` 2391→2339 行;首页/库 106 条规则换 token,间距写死 91→5(只剩版心与导航让位的布局值)、字号写死清零,新增 `--iwb-font-display:24px` 第 7 档;验收改为「计算样式逐元素 diff + 12 张基线只首页 2 张变化」;上一条 `v3.26.45+968ff46` —— **M4-B2 浮层层级表 + 阴影四档**:14 档 `--iwb-z-*`(裸 z-index 取值种类 42→31)、`--iwb-elevation-1..4`(浮层 8 种阴影写法→4 档)、`.iwb-pop` 圆角 18→`radius-popover(14)`;修「弹窗里点保存看不到提示」—— 根因不是层级数字而是 `.iwb-overlay` 本身就是堆叠上下文,toast 改为 portal 到 `body`;新增 `tests/overlay-layer-test.js` 钉 9 条顺序约束;上一条 `v3.26.44+846a59b` —— **设计 token 体系重建**:D1–D9 色彩模型改为真正的深色(#121Line truncated
<!-- 2026-10-28 P1 拆分批 1:新增 src/generation-task-graph.js(5 个任务图纯函数自 app.js 迁出)
⇒ 模块数 60→61、耦合面 51→52、sourceModules 60→61。耦合面只**新增** IWBWTaskGraph,无删除。
2026-10-28 P1 拆分批 2:新增 src/storage-config-shape.js(9 个配置形状纯函数自 app.js 迁出)
@@ -22,7 +22,7 @@
- 图片**新写入主通道 = IndexedDB Blob `{__blob}` / key `imgblob_<hash>_<len>`** (A) `app.js:2143`;`{__cache}`(Cache Storage)为兜底;\`ref_\`(`app.js` 内定义的 `IDB_REF_PREFIX = 'ref_'`)为 legacy 形态 (A)。
- 大图判定:`isBigDataUrl` = `data:` 且 `length > 3000` (A) `app.js:2018`;**画布保存保留阈值** `< 16384` 才原样保留 (A) `app.js:2182`。**两处阈值并存,含义不同**。
- 单测是**源码契约测试**:`tests/` 目录共 **493** 处源码文本钉点(`source.includes` / `source.indexOf` / `/re/.test(source)`),分布在 **20** 个文件(其中 `iwb-v32-web-test.js` 一个就占 **407**)→ **结构性重构会先打红测试**。**该数字已由 `tests/source-text-ratchet-test.js` 的「只减不增」棘轮守门**(2026-10-20 起守卫范围从 1 个文件扩到全目录:新增任何一处源码文本钉点都会打红)。**2026-11-12 复算**(`npm run audit:pins`,v3.24.76):二分 STRUCT **417** / NAME **76**;形态 **POS 403 / NEG 87 / COUNT 3**;难度 **易 62 / 中 316 / 难 115**。钉点减法第一批(v3.24.72)把 **537 → 505**:8 条探针钉点改为「门禁内 spec 是否真的读该计数器」、5 条改为运行时断言(生产态 `window` 上无探针)、10 条改为 DOM 断言(质量档位禁用 / 传输页无三模式按钮 / 模型项 title)、4 条改为运行时对象断言(健康检查两域、策略对象冻结)、其余 9 条有同文件 DOM 等价断言或仅剩 NEG。第二批(v3.24.76)把 **505 → 493**:94-5~7 三条「多标签释放语义」(10 处正则)换成 `tests/iwb-tabs-release.spec.js` 的 3 条真 e2e,剩 1 条「消费方契约」(断言该 spec 在门禁内且 spec 源码真的读两个探针);另 2 条 `wPurgeIntent.add` 钉点改为读 `src/workspace-purge.js`。**这一批一换就查出 3 个真缺陷**(objectURL 从未释放 / 彻底删除留孤儿标签 · session / 刷新后误回收打开标签的图)—— 见 CHANGELOG v3.24.76。
- `app.js` = 单 IIFE **9,183 行**(**双层预算**:绝对上限 9,183 / 占总源码 ≤ 40%,现 **29.7%**,2026-11-12 起;此前为单一上限 8,509、零余量);`Workbench()` = **3,043 行**(上限 **3,046**,余量 3;2026-11-16 把生成取消族 `cancelRunsFor`/`cancelRun`/`cancelTaskJobs` 与工作区列表写回族 `persistWs`/`duplicateWs` 搬进 `src/runtime-workbench-logic.js`(`createCancelActions` / `createWorkspaceListActions`),并删掉全仓零调用的 `runAll`,3090 → 2,998);大量逻辑已抽到 `src/*.js`(现 **112** 个模块 / 21,777 行,`sourceModules` 112 项;v3.24.68 新增 `clipboard-graph.js`,v3.24.74 新增 `image-admit.js`,v3.24.75 新增 `image-dedupe.js`,v3.24.76 新增 `workspace-purge.js`,v3.24.79 新增 `generation-provider-ping.js`,v3.24.80 删除无调用的 `createWBFlushViewport` 17 行)。
- `app.js` = 单 IIFE **9,183 行**(**双层预算**:绝对上限 9,183 / 占总源码 ≤ 40%,现 **29.6%**,2026-11-12 起;此前为单一上限 8,509、零余量);`Workbench()` = **3,043 行**(上限 **3,046**,余量 3;2026-11-16 把生成取消族 `cancelRunsFor`/`cancelRun`/`cancelTaskJobs` 与工作区列表写回族 `persistWs`/`duplicateWs` 搬进 `src/runtime-workbench-logic.js`(`createCancelActions` / `createWorkspaceListActions`),并删掉全仓零调用的 `runAll`,3090 → 2,998);大量逻辑已抽到 `src/*.js`(现 **112** 个模块 / 21,821 行,`sourceModules` 112 项;v3.24.68 新增 `clipboard-graph.js`,v3.24.74 新增 `image-admit.js`,v3.24.75 新增 `image-dedupe.js`,v3.24.76 新增 `workspace-purge.js`,v3.24.79 新增 `generation-provider-ping.js`,v3.24.80 删除无调用的 `createWBFlushViewport` 17 行)。
- 门禁:`npm run verify` = `verify:ci`(`build` → `node --check app.js` → `node --check dist/app.js` → `check-dist.js` → `lint`(ESLint 正确性规则,`src/` + `app.js`,P4-16a)→ `test:unit` → `test` → `test:facts`)+ `test:e2e` (A) `package.json`。
## 2. 门禁与环境现状
+2 -2
View File
@@ -1,7 +1,7 @@
{
"name": "image-workbench-web",
"private": true,
"version": "3.26.84",
"version": "3.26.87",
"description": "Browser-based node canvas image workbench",
"scripts": {
"build": "node scripts/build.js && node scripts/copy-plugins.js",
@@ -10,7 +10,7 @@
"app:build": "tauri build",
"lint": "eslint src app.js",
"test": "node tests/relay-task-graph-fixture-test.js && node tests/plugin-style-node-test.js && node tests/inherit-text-test.js",
"test:unit": "node tests/gallery-audit-test.js && node tests/plugin-files-policy-test.js && node tests/theme-plugin-tokens-test.js && node tests/design-tokens-component-doc-test.js && node tests/theme-static-snapshot-test.js && node tests/overlay-layer-test.js && node tests/settings-scope-test.js && node tests/node-scope-test.js && node tests/appearance-v2-test.js && node tests/image-prompt-cover-test.js && node tests/unit-test.js && node tests/canvas-actions-test.js && node tests/canvas-performance-test.js && node tests/canvas-drag-performance-test.js && node tests/resize-observer-performance-test.js && node tests/node-drag-jank-test.js && node tests/edge-graph-performance-test.js && node tests/persistence-export-images-test.js && node tests/settings-hotkeys-size-presets-test.js && node tests/custom-size-validation-test.js && node tests/image-node-performance-test.js && node tests/drag-frame-performance-test.js && node tests/canvas-edge-memo-test.js && node tests/canvas-node-transform-test.js && node tests/canvas-dot-zoom-test.js && node tests/duplicate-ws-fresh-source-test.js && node tests/single-canvas-shell-test.js && node tests/navigation-layout-test.js && node tests/home-canvas-library-test.js && node tests/left-resource-layout-test.js && node tests/interface-hierarchy-test.js && node tests/three-page-layout-test.js && node tests/page-chrome-regression-test.js && node tests/task-cache-test.js && node tests/album-task-graph-test.js && node tests/generation-endpoint-test.js && node tests/storage-config-shape-test.js && node tests/generation-default-model-test.js && node tests/storage-zip-test.js && node tests/canvas-node-factory-test.js && node tests/runtime-error-test.js && node tests/runtime-lifecycle-test.js && node tests/runtime-fetch-test.js && node tests/runtime-channel-test.js && node tests/runtime-boundary-test.js && node tests/runtime-record-test.js && node tests/runtime-recovery-test.js && node tests/runtime-diagnostic-record-test.js && node tests/runtime-metrics-test.js && node tests/runtime-run-context-test.js && node tests/runtime-execution-context-test.js && node tests/storage-gc-canvas-refs-test.js && node tests/storage-health-test.js && node tests/generation-state-test.js && node tests/canvas-store-test.js && node tests/storage-result-test.js && node tests/storage-local-test.js && node tests/storage-domain-test.js && node tests/storage-runtime-test.js && node tests/storage-indexeddb-test.js && node tests/generation-scheduler-test.js && node tests/gallery-query-test.js && node tests/gallery-hydration-test.js && node tests/gallery-sync-test.js && node tests/image-blob-store-test.js && node tests/image-format-test.js && node tests/clipboard-graph-test.js && node tests/clipboard-graph-fallback-test.js && node tests/image-admit-test.js && node tests/image-dedupe-test.js && node tests/clipboard-kind-test.js && node tests/clipboard-paste-test.js && node tests/clipboard-copy-test.js && node tests/clipboard-native-test.js && node tests/paste-once-test.js && node tests/list-e2e-specs-test.js && node tests/desktop-csp-loopback-test.js && node tests/architecture-boundary-guard-test.js && node tests/plugin-host-test.js && node tests/plugin-data-test.js && node tests/plugin-loader-test.js && node tests/plugin-bundle-test.js && node tests/plugin-install-test.js && node tests/plugin-gallery-render-test.js && node tests/plugin-gallery-recovery-test.js && node tests/plugin-gallery-ux-test.js && node tests/plugin-grouplib-render-test.js && node tests/plugin-promptlib-render-test.js && node tests/image-compress-test.js && node tests/storage-fallback-indexeddb-test.js && node tests/canvas-normalize-test.js && node tests/canvas-geometry-test.js && node tests/canvas-history-test.js && node tests/canvas-ops-test.js && node tests/canvas-text-test.js && node tests/history-store-test.js && node tests/plugin-integrity-test.js && node tests/workspace-sessions-store-test.js && node tests/workspace-list-test.js && node tests/workspace-purge-test.js && node tests/provider-ping-test.js && node tests/runtime-diagnostics-hotpath-test.js && node tests/storage-log-failure-test.js && node tests/storage-convergence-test.js && node tests/swallow-wiring-test.js && node tests/workbench-logic-test.js && node tests/storage-autobackup-test.js && node tests/storage-outputs-mutate-test.js && node tests/sync-facts-guard-test.js && node tests/e2e-fixed-waits-ratchet-test.js && node tests/shell-render-behavior-test.js && node tests/canvas-meta-notice-behavior-test.js && node tests/source-text-ratchet-test.js && node tests/plugin-theme-contract-test.js && node tests/prompt-md-roundtrip-test.js && node tests/generation-results-store-test.js && node tests/out-groups-order-test.js && node tests/native-overlay-park-test.js && node tests/ui-dock-sanitize-test.js && node tests/ui-minimap-fit-test.js && node tests/ui-workbench-hooks-test.js && node tests/plugin-scale-contract-test.js && node tests/design-token-ratchet-test.js && node testsLine truncated
"test:unit": "node tests/result-img-doubleclick-test.js && node tests/gallery-audit-test.js && node tests/plugin-files-policy-test.js && node tests/theme-plugin-tokens-test.js && node tests/design-tokens-component-doc-test.js && node tests/theme-static-snapshot-test.js && node tests/overlay-layer-test.js && node tests/settings-scope-test.js && node tests/node-scope-test.js && node tests/appearance-v2-test.js && node tests/image-prompt-cover-test.js && node tests/unit-test.js && node tests/canvas-actions-test.js && node tests/canvas-performance-test.js && node tests/canvas-drag-performance-test.js && node tests/resize-observer-performance-test.js && node tests/node-drag-jank-test.js && node tests/edge-graph-performance-test.js && node tests/persistence-export-images-test.js && node tests/settings-hotkeys-size-presets-test.js && node tests/custom-size-validation-test.js && node tests/image-node-performance-test.js && node tests/drag-frame-performance-test.js && node tests/canvas-edge-memo-test.js && node tests/canvas-node-transform-test.js && node tests/canvas-dot-zoom-test.js && node tests/duplicate-ws-fresh-source-test.js && node tests/single-canvas-shell-test.js && node tests/navigation-layout-test.js && node tests/home-canvas-library-test.js && node tests/left-resource-layout-test.js && node tests/interface-hierarchy-test.js && node tests/three-page-layout-test.js && node tests/page-chrome-regression-test.js && node tests/task-cache-test.js && node tests/album-task-graph-test.js && node tests/generation-endpoint-test.js && node tests/storage-config-shape-test.js && node tests/generation-default-model-test.js && node tests/storage-zip-test.js && node tests/canvas-node-factory-test.js && node tests/runtime-error-test.js && node tests/runtime-lifecycle-test.js && node tests/runtime-fetch-test.js && node tests/runtime-channel-test.js && node tests/runtime-boundary-test.js && node tests/runtime-record-test.js && node tests/runtime-recovery-test.js && node tests/runtime-diagnostic-record-test.js && node tests/runtime-metrics-test.js && node tests/runtime-run-context-test.js && node tests/runtime-execution-context-test.js && node tests/storage-gc-canvas-refs-test.js && node tests/storage-health-test.js && node tests/generation-state-test.js && node tests/canvas-store-test.js && node tests/storage-result-test.js && node tests/storage-local-test.js && node tests/storage-domain-test.js && node tests/storage-runtime-test.js && node tests/storage-indexeddb-test.js && node tests/generation-scheduler-test.js && node tests/gallery-query-test.js && node tests/gallery-hydration-test.js && node tests/gallery-sync-test.js && node tests/image-blob-store-test.js && node tests/image-format-test.js && node tests/clipboard-graph-test.js && node tests/clipboard-graph-fallback-test.js && node tests/image-admit-test.js && node tests/image-dedupe-test.js && node tests/clipboard-kind-test.js && node tests/clipboard-paste-test.js && node tests/clipboard-copy-test.js && node tests/clipboard-native-test.js && node tests/paste-once-test.js && node tests/list-e2e-specs-test.js && node tests/desktop-csp-loopback-test.js && node tests/architecture-boundary-guard-test.js && node tests/plugin-host-test.js && node tests/plugin-data-test.js && node tests/plugin-loader-test.js && node tests/plugin-bundle-test.js && node tests/plugin-install-test.js && node tests/plugin-gallery-render-test.js && node tests/plugin-gallery-recovery-test.js && node tests/plugin-gallery-ux-test.js && node tests/plugin-grouplib-render-test.js && node tests/plugin-promptlib-render-test.js && node tests/image-compress-test.js && node tests/storage-fallback-indexeddb-test.js && node tests/canvas-normalize-test.js && node tests/canvas-geometry-test.js && node tests/canvas-history-test.js && node tests/canvas-ops-test.js && node tests/canvas-text-test.js && node tests/history-store-test.js && node tests/plugin-integrity-test.js && node tests/workspace-sessions-store-test.js && node tests/workspace-list-test.js && node tests/workspace-purge-test.js && node tests/provider-ping-test.js && node tests/runtime-diagnostics-hotpath-test.js && node tests/storage-log-failure-test.js && node tests/storage-convergence-test.js && node tests/swallow-wiring-test.js && node tests/workbench-logic-test.js && node tests/storage-autobackup-test.js && node tests/storage-outputs-mutate-test.js && node tests/sync-facts-guard-test.js && node tests/e2e-fixed-waits-ratchet-test.js && node tests/shell-render-behavior-test.js && node tests/canvas-meta-notice-behavior-test.js && node tests/source-text-ratchet-test.js && node tests/plugin-theme-contract-test.js && node tests/prompt-md-roundtrip-test.js && node tests/generation-results-store-test.js && node tests/out-groups-order-test.js && node tests/native-overlay-park-test.js && node tests/ui-dock-sanitize-test.js && node tests/ui-minimap-fit-test.js && node tests/ui-workbench-hooks-test.js && node tests/plugin-scale-contract-test.js && node tesLine truncated
"test:diagnostics": "node tests/runtime-diagnostics-hotpath-test.js",
"test:facts": "node tests/architecture-facts-guard-test.js && node tests/release-records-test.js",
"plugins:gc": "node scripts/plugins-publish.mjs --gc",
+1 -1
View File
@@ -590,7 +590,7 @@
global.IWBPluginHost.register({
id: 'gallery',
name: '图库',
version: '1.7.2',
version: '1.7.3',
apiVersion: 1,
capabilities: ['panels', 'gallery'],
data: { schemaVersion: 1, maxBytes: 65536 },
+3 -3
View File
@@ -1,7 +1,7 @@
{
"id": "gallery",
"name": "图库",
"version": "1.7.2",
"version": "1.7.3",
"apiVersion": 1,
"main": "main.js",
"style": "styles.css",
@@ -13,7 +13,7 @@
"图库"
],
"files": {
"main.js": "6f29e9ba66e358769d9b8c07b35c0f0a9ec76c244cf74139a61ba5ca74ddb41e",
"styles.css": "1dfd72b60bcaea9c43e103ba9758113efec02b6241d08fa0ab9c75d7848afb55"
"main.js": "b497528aa9cd616b5caa28b940bd70c64c36b22ed35f3dad8a2052f31687be73",
"styles.css": "f4cc8ff0d8c1cfc7d90a2988ebfd33473986da81228187385f3483e7eff62b8b"
}
}
+27 -2
View File
@@ -69,14 +69,39 @@
.iwb-history-embedded .iwb-history-item img {
width: 100%; height: auto; display: block; object-fit: contain; margin: 0 auto;
border-radius: 6px; border: 1px solid var(--iwb-border); background: var(--iwb-layer2); cursor: pointer;
transition: transform var(--iwb-motion-hover, .15s) var(--iwb-ease-hover, ease-out),
border-color var(--iwb-motion-hover, .15s) var(--iwb-ease-hover, ease-out),
box-shadow var(--iwb-motion-hover, .15s) var(--iwb-ease-hover, ease-out);
}
/* v1.7.3:卡片悬停上浮 + 阴影 + 品牌描边(与输出节点共用宿主 L2 token)。
用 item:hover 而不是 img:hover:指针移到下载浮层按钮上时卡片仍保持浮起,不抖。 */
.iwb-history-embedded .iwb-history-item:hover img {
transform: translateY(var(--iwb-hover-lift, -2px)) scale(var(--iwb-hover-scale, 1.02));
border-color: var(--iwb-hover-border, var(--iwb-brand));
box-shadow: var(--iwb-hover-shadow, 0 5px 16px rgba(0, 0, 0, .22));
}
.iwb-history-missing {
display: flex; align-items: center; justify-content: center; text-align: center;
min-height: 84px; padding: 8px; border-radius: 6px; border: 1px dashed var(--iwb-border);
font-size: 11px; color: var(--iwb-text2); background: var(--iwb-layer2); word-break: break-all;
}
.iwb-history-actions { display: flex; gap: 4px; padding: 4px 2px 0; }
.iwb-history-actions .iwb-btn-sm { padding: 2px 6px; font-size: 11px; }
/* v1.7.3:把「下载」做成卡片底部渐变的下载浮层(与输出节点同一套语义)。
条本身 pointer-events:none,只有悬停后按钮可点,避免挡住卡片点击/双击预览。 */
.iwb-history-actions {
position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: center; gap: 4px;
padding: var(--iwb-space-16) var(--iwb-space-4) var(--iwb-space-4); border-radius: 0 0 6px 6px;
background-image: linear-gradient(to top, rgba(0, 0, 0, .62), transparent);
opacity: 0; transition: opacity var(--iwb-motion-hover, .15s) var(--iwb-ease-hover, ease-out);
pointer-events: none;
}
.iwb-history-embedded .iwb-history-item:hover .iwb-history-actions,
.iwb-history-embedded .iwb-history-item:focus-within .iwb-history-actions { opacity: 1; pointer-events: auto; }
.iwb-history-actions .iwb-btn-sm { padding: 2px 8px; font-size: 11px; border: none; background: var(--iwb-panel); color: var(--iwb-text); }
.iwb-history-actions .iwb-btn-sm:hover { background: var(--iwb-panel); color: var(--iwb-brand); }
@media (prefers-reduced-motion: reduce) {
.iwb-history-embedded .iwb-history-item img { transition: none; }
.iwb-history-embedded .iwb-history-item:hover img { transform: none; }
}
.iwb-history-more { display: flex; justify-content: center; padding: 4px 0 2px; }
/* 只作用于图库自己的空态提示:不加前缀会泄漏到设置页等使用 .iwb-hint 的地方(文字被居中) */
.iwb-history-embedded .iwb-hint { font-size: 11px; color: var(--iwb-text2); text-align: center; padding: 12px 6px; }
+3 -3
View File
@@ -33,10 +33,10 @@
"dir": "gallery",
"main": "main.js",
"style": "styles.css",
"version": "1.7.2",
"version": "1.7.3",
"files": {
"main.js": "6f29e9ba66e358769d9b8c07b35c0f0a9ec76c244cf74139a61ba5ca74ddb41e",
"styles.css": "1dfd72b60bcaea9c43e103ba9758113efec02b6241d08fa0ab9c75d7848afb55"
"main.js": "b497528aa9cd616b5caa28b940bd70c64c36b22ed35f3dad8a2052f31687be73",
"styles.css": "f4cc8ff0d8c1cfc7d90a2988ebfd33473986da81228187385f3483e7eff62b8b"
}
},
{
+12
View File
@@ -145,6 +145,18 @@ const SCALE = [
['--iwb-motion-base', '0.15s', 'M6 动效:面板展开/尺寸变化'],
['--iwb-motion-slow', '0.3s', 'M6 动效:整屏过渡/抽屉'],
/* ── L2 悬停动效(2026-11-26)───────────────────────────────────────
* 图库卡片 / 输出节点结果图共用同一组值:改一档就两处一起变。
* scale 只给 1.02(卡片够大,再大就压到相邻列);相册格子是固定正方形网格,
* 单独用 --iwb-hover-scale 之外的 1.08,且**不位移**(位移会让相邻格抖动,见 album 插件)。 */
['--iwb-motion-hover', '0.15s', 'L2 悬停:卡片/结果图浮层统一时长'],
['--iwb-ease-hover', 'cubic-bezier(0.16, 1, 0.3, 1)', 'L2 悬停:快出慢停'],
['--iwb-hover-lift', '-2px', 'L2 悬停:上浮位移'],
['--iwb-hover-scale', '1.02', 'L2 悬停:缩放(相册格子单独用 1.08)'],
['--iwb-hover-shadow', '0 6px 16px rgba(0, 0, 0, 0.35)', 'L2 悬停:投影(单值,供 filter: drop-shadow 用;box-shadow 会多一种写法)'],
['--iwb-hover-border', 'var(--iwb-brand)', 'L2 悬停:描边色'],
['--iwb-scrim', 'rgba(0, 0, 0, 0.62)', '图片上的遮罩渐变底:下载浮层/预览条(两套主题都用深色,保证白字可读)'],
/* ── 层级表(M4-B2)───────────────────────────────────────────────
* 迁移前 z-index 有 42 种取值,其中「谁盖谁」全靠散落在各处的数字对撞,出过两次真 bug:
* ① toast(200) 低于弹窗(300) → 弹窗里点保存看不到提示;
+2 -2
View File
@@ -3,7 +3,7 @@
<title>插件开发规范 · Image Workbench</title>
<link rel="icon" href="/assets/favicon.png" type="image/png">
<link rel="apple-touch-icon" href="/assets/logo.png">
<link rel="stylesheet" href="/assets/style.css?v=3.26.84-mww8ah79">
<link rel="stylesheet" href="/assets/style.css?v=3.26.87-mww8uwo2">
<style>
.devdoc{max-width:860px;margin:0 auto;padding:40px 0 72px;color:var(--ink,#1b1f24);font-size:15px;line-height:1.75}
.devdoc h1{font-size:38px;line-height:1.2;margin:8px 0 18px}
@@ -33,7 +33,7 @@
</div>
<div class="right">
<a class="btn" href="/plugins/">插件市场</a>
<a class="btn primary" href="/download/">下载 v3.26.84</a>
<a class="btn primary" href="/download/">下载 v3.26.87</a>
</div>
</div></nav>
<main>
+16 -4
View File
@@ -57,13 +57,13 @@
<h2>下载</h2>
<div class="row">
<div class="name">macOS · Apple Silicon<div class="hint">M1 / M2 / M3 / M4</div></div>
<div class="meta">版本 3.26.84 · 8.4 MB · .dmg<div class="hash">sha256 d0d59c6ffa46e53b…</div></div>
<a class="btn" href="/updates/darwin-aarch64/image-workbench_3.26.84_aarch64.dmg?h=d0d59c6ffa46">下载</a>
<div class="meta">版本 3.26.87 · 8.4 MB · .dmg<div class="hash">sha256 eaa37b812da780c5…</div></div>
<a class="btn" href="/updates/darwin-aarch64/image-workbench_3.26.87_aarch64.dmg?h=eaa37b812da7">下载</a>
</div>
<div class="row">
<div class="name">macOS · Intel<div class="hint">x86_64</div></div>
<div class="meta">版本 3.26.84 · 8.8 MB · .dmg<div class="hash">sha256 93c11f9905fd6826…</div></div>
<a class="btn" href="/updates/darwin-x86_64/image-workbench_3.26.84_x64.dmg?h=93c11f9905fd">下载</a>
<div class="meta">版本 3.26.87 · 8.8 MB · .dmg<div class="hash">sha256 64934f36e6a07599…</div></div>
<a class="btn" href="/updates/darwin-x86_64/image-workbench_3.26.87_x64.dmg?h=64934f36e6a0">下载</a>
</div>
<div class="row">
<div class="name">Windows · x64<div class="hint">需要 WebView2</div></div>
@@ -97,6 +97,18 @@
</ol>
<h2>历史版本</h2>
<div class="row">
<div class="name">3.26.87</div>
<div class="meta">2026-11-25<div class="hint">macOS · Apple Silicon / macOS · Intel</div></div>
</div>
<div class="row">
<div class="name">3.26.86</div>
<div class="meta">2026-11-25<div class="hint">macOS · Apple Silicon / macOS · Intel</div></div>
</div>
<div class="row">
<div class="name">3.26.85</div>
<div class="meta">2026-11-25<div class="hint">macOS · Apple Silicon / macOS · Intel</div></div>
</div>
<div class="row">
<div class="name">3.26.84</div>
<div class="meta">2026-11-25<div class="hint">macOS · Apple Silicon / macOS · Intel</div></div>
+8 -8
View File
@@ -4,7 +4,7 @@
<meta name="description" content="本地优先的 AI 生图无限画布:节点式工作流、插件按需安装、数据全部留在本机。">
<link rel="icon" href="/assets/favicon.png" type="image/png">
<link rel="apple-touch-icon" href="/assets/logo.png">
<link rel="stylesheet" href="/assets/style.css?v=3.26.84-mww8ah79">
<link rel="stylesheet" href="/assets/style.css?v=3.26.87-mww8uwo2">
</head><body>
<nav><div class="wrap inner">
<a class="brand" href="/"><img class="logo" src="/assets/logo.png" alt="" width="26" height="26">Image Workbench</a>
@@ -17,19 +17,19 @@
</div>
<div class="right">
<a class="btn" href="/plugins/">插件市场</a>
<a class="btn primary" href="/download/">下载 v3.26.84</a>
<a class="btn primary" href="/download/">下载 v3.26.87</a>
</div>
</div></nav>
<main>
<section class="hero hero-art">
<div class="hero-bg"><img src="/assets/painting.jpg?v=3.26.84-mww8ah79" alt=""></div>
<div class="hero-bg"><img src="/assets/painting.jpg?v=3.26.87-mww8uwo2" alt=""></div>
<div class="hero-veil"></div>
<div class="wrap">
<span class="kicker">v3.26.84 · macOS / Windows · 数据在本地</span>
<span class="kicker">v3.26.87 · macOS / Windows · 数据在本地</span>
<h1>本地优先的<br>AI 生图无限画布</h1>
<p class="sub">用节点把「参考图 → 提示词 → 批量生成 → 图库」串成一条生产线。<br>图片、提示词、模型配置全部留在你自己的电脑里,插件按需安装。</p>
<div class="cta">
<a class="btn primary lg" href="/download/">下载 v3.26.84</a>
<a class="btn primary lg" href="/download/">下载 v3.26.87</a>
<a class="btn lg" href="/plugins/">浏览 13 个插件</a>
</div>
<div class="meta">支持 macOS 12+ 与 Windows 10 1803+ · 安装包约 7 MB · 无需登录</div>
@@ -79,7 +79,7 @@
</div>
<div class="pcard" data-name="图库 gallery 右栏图片墙:筛选/多选/双击预览/插入画布/下载/删除(数据由客户端提供) 资源 图库" data-tags="资源,图库">
<div class="head"><span class="av" style="background:#eef2f6">🖼️</span>
<div><div class="nm">图库</div><div class="ver">v1.7.2 · 官方</div></div></div>
<div><div class="nm">图库</div><div class="ver">v1.7.3 · 官方</div></div></div>
<div class="desc">右栏图片墙:筛选/多选/双击预览/插入画布/下载/删除(数据由客户端提供)</div>
<div class="tags"><span class="tag">资源</span><span class="tag">图库</span></div>
</div>
@@ -96,8 +96,8 @@
<section class="section"><div class="wrap">
<h2>下载 Image Workbench</h2>
<p class="lead">选你的平台。装过一次之后,以后在应用内「设置 → 通用 → 版本与更新」就能一键升级。</p>
<div class="dl"><a href="/updates/darwin-aarch64/image-workbench_3.26.84_aarch64.dmg?h=d0d59c6ffa46"><div class="n">macOS · Apple Silicon</div><div class="s">M1 / M2 / M3 / M4 · 8.4 MB · .dmg</div></a>
<a href="/updates/darwin-x86_64/image-workbench_3.26.84_x64.dmg?h=93c11f9905fd"><div class="n">macOS · Intel</div><div class="s">x86_64 · 8.8 MB · .dmg</div></a>
<div class="dl"><a href="/updates/darwin-aarch64/image-workbench_3.26.87_aarch64.dmg?h=eaa37b812da7"><div class="n">macOS · Apple Silicon</div><div class="s">M1 / M2 / M3 / M4 · 8.4 MB · .dmg</div></a>
<a href="/updates/darwin-x86_64/image-workbench_3.26.87_x64.dmg?h=64934f36e6a0"><div class="n">macOS · Intel</div><div class="s">x86_64 · 8.8 MB · .dmg</div></a>
<div class="none"><div class="n">Windows · x64</div><div class="s">暂未提供</div></div></div>
<div style="margin-top:20px;color:#9ca3af;font-size:12.5px">安装包未做 Apple 公证 / Windows 代码签名,首次打开需手动放行一次,细节见 <a href="/download/" style="text-decoration:underline">下载页</a>。</div>
</div></section>
+9 -9
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"updatedAt": "2026-11-25T14:27:01.275Z",
"updatedAt": "2026-11-25T14:41:29.249Z",
"plugins": [
{
"id": "album",
@@ -147,26 +147,26 @@
"资源",
"图库"
],
"version": "1.7.2",
"version": "1.7.3",
"apiVersion": 1,
"bundle": "plugins/gallery-1.7.2.zip",
"bundleSize": 39145,
"bundleSha256": "20a66d75ca4d4395cd2c2cb0d9e60fbb8caeea20b9431a3cc4849a4869f6127d",
"bundle": "plugins/gallery-1.7.3.zip",
"bundleSize": 40996,
"bundleSha256": "b5f01d3b933c48f37230b876dbcb3e585b199271db7716cf1b9480bfdac948fa",
"files": [
{
"path": "manifest.json",
"sha256": "f6791f662ba280cb497056fc9a919c32af2714add7c956ca400f9e8cb4fb85c1",
"sha256": "f4c9ff92011963b2774e5f7786e74b20da48d04c5a0797baafe4b6b84f462b1a",
"size": 526
},
{
"path": "main.js",
"sha256": "6f29e9ba66e358769d9b8c07b35c0f0a9ec76c244cf74139a61ba5ca74ddb41e",
"sha256": "b497528aa9cd616b5caa28b940bd70c64c36b22ed35f3dad8a2052f31687be73",
"size": 32287
},
{
"path": "styles.css",
"sha256": "1dfd72b60bcaea9c43e103ba9758113efec02b6241d08fa0ab9c75d7848afb55",
"size": 6022
"sha256": "f4cc8ff0d8c1cfc7d90a2988ebfd33473986da81228187385f3483e7eff62b8b",
"size": 7873
}
]
},
+3 -3
View File
@@ -3,7 +3,7 @@
<title>插件市场 · Image Workbench</title>
<link rel="icon" href="/assets/favicon.png" type="image/png">
<link rel="apple-touch-icon" href="/assets/logo.png">
<link rel="stylesheet" href="/assets/style.css?v=3.26.84-mww8ah79">
<link rel="stylesheet" href="/assets/style.css?v=3.26.87-mww8uwo2">
</head><body>
<nav><div class="wrap inner">
<a class="brand" href="/"><img class="logo" src="/assets/logo.png" alt="" width="26" height="26">Image Workbench</a>
@@ -16,7 +16,7 @@
</div>
<div class="right">
<a class="btn" href="/plugins/">插件市场</a>
<a class="btn primary" href="/download/">下载 v3.26.84</a>
<a class="btn primary" href="/download/">下载 v3.26.87</a>
</div>
</div></nav>
<main>
@@ -76,7 +76,7 @@
</div>
<div class="pcard" data-name="图库 gallery 右栏图片墙:筛选/多选/双击预览/插入画布/下载/删除(数据由客户端提供) 资源 图库" data-tags="资源,图库">
<div class="head"><span class="av" style="background:#eef2f6">🖼️</span>
<div><div class="nm">图库</div><div class="ver">v1.7.2 · 官方</div></div></div>
<div><div class="nm">图库</div><div class="ver">v1.7.3 · 官方</div></div></div>
<div class="desc">右栏图片墙:筛选/多选/双击预览/插入画布/下载/删除(数据由客户端提供)</div>
<div class="tags"><span class="tag">资源</span><span class="tag">图库</span></div>
</div>
+64 -1
View File
@@ -1,8 +1,71 @@
{
"app": "Image Workbench",
"subtitle": "本地优先的 AI 生图无限画布 · 桌面版(Tauri v2)",
"updatedAt": "2026-11-25T14:38:08.184Z",
"updatedAt": "2026-11-25T14:54:01.348Z",
"releases": [
{
"version": "3.26.87",
"date": "2026-11-25",
"notes": "",
"platforms": {
"darwin-aarch64": {
"file": "updates/darwin-aarch64/image-workbench_3.26.87_aarch64.dmg",
"size": 8807173,
"sha256": "eaa37b812da780c5d06e2b029efef4364e2eeebd7ca9ce7046b1c8a1175fe22e",
"h": "eaa37b812da7",
"kind": "dmg"
},
"darwin-x86_64": {
"file": "updates/darwin-x86_64/image-workbench_3.26.87_x64.dmg",
"size": 9228093,
"sha256": "64934f36e6a0759964b5de3aabe4810fed56249ef2931f9b80fb17a8d6cd77b3",
"h": "64934f36e6a0",
"kind": "dmg"
}
}
},
{
"version": "3.26.86",
"date": "2026-11-25",
"notes": "",
"platforms": {
"darwin-aarch64": {
"file": "updates/darwin-aarch64/image-workbench_3.26.86_aarch64.dmg",
"size": 8806650,
"sha256": "fd566d5e5682b14e73f2d3e5da906b533e1ab4441491ee60984df10404f1104c",
"h": "fd566d5e5682",
"kind": "dmg"
},
"darwin-x86_64": {
"file": "updates/darwin-x86_64/image-workbench_3.26.86_x64.dmg",
"size": 9225115,
"sha256": "7a90ef45d15b173bdfd0663c8367ef2a16bd9977791a18964b5e5ddb77d83e67",
"h": "7a90ef45d15b",
"kind": "dmg"
}
}
},
{
"version": "3.26.85",
"date": "2026-11-25",
"notes": "",
"platforms": {
"darwin-aarch64": {
"file": "updates/darwin-aarch64/image-workbench_3.26.85_aarch64.dmg",
"size": 8810088,
"sha256": "5442c774270ec9e13c4431b805bdeca5717bf9fb6a176a8bb56b94c68402a31a",
"h": "5442c774270e",
"kind": "dmg"
},
"darwin-x86_64": {
"file": "updates/darwin-x86_64/image-workbench_3.26.85_x64.dmg",
"size": 9225212,
"sha256": "6dfb2eecda121c0142f512c500f2918d98f299a7ced23591a1e0c0e9587bb074",
"h": "6dfb2eecda12",
"kind": "dmg"
}
}
},
{
"version": "3.26.84",
"date": "2026-11-25",
+1 -1
View File
@@ -1983,7 +1983,7 @@ dependencies = [
[[package]]
name = "image-workbench"
version = "3.26.84"
version = "3.26.87"
dependencies = [
"arboard",
"base64 0.22.1",
+1 -1
View File
@@ -1,6 +1,6 @@
[package]
name = "image-workbench"
version = "3.26.84"
version = "3.26.87"
description = "无限画布 · 生图工作台桌面版"
authors = ["malongan"]
license = ""
+1 -1
View File
@@ -1,7 +1,7 @@
{
"$schema": "../node_modules/@tauri-apps/cli/config.schema.json",
"productName": "image-workbench",
"version": "3.26.84",
"version": "3.26.87",
"identifier": "com.malongan.imageworkbench",
"build": {
"frontendDist": "../dist",
+7
View File
@@ -140,6 +140,13 @@
--iwb-motion-fast: 0.12s; /* M6 动效:悬停/开关/小位移 */
--iwb-motion-base: 0.15s; /* M6 动效:面板展开/尺寸变化 */
--iwb-motion-slow: 0.3s; /* M6 动效:整屏过渡/抽屉 */
--iwb-motion-hover: 0.15s; /* L2 悬停:卡片/结果图浮层统一时长 */
--iwb-ease-hover: cubic-bezier(0.16, 1, 0.3, 1); /* L2 悬停:快出慢停 */
--iwb-hover-lift: -2px; /* L2 悬停:上浮位移 */
--iwb-hover-scale: 1.02; /* L2 悬停:缩放(相册格子单独用 1.08) */
--iwb-hover-shadow: 0 6px 16px rgba(0, 0, 0, 0.35); /* L2 悬停:投影(单值,供 filter: drop-shadow 用;box-shadow 会多一种写法) */
--iwb-hover-border: var(--iwb-brand); /* L2 悬停:描边色 */
--iwb-scrim: rgba(0, 0, 0, 0.62); /* 图片上的遮罩渐变底:下载浮层/预览条(两套主题都用深色,保证白字可读) */
--iwb-z-ctx: 90; /* 右键遮罩 */
--iwb-z-ctx-menu: 91; /* 右键菜单 */
--iwb-z-curtain: 100; /* 应用遮罩 / 图片预览底 */
+18 -1
View File
@@ -1063,7 +1063,10 @@
// 图库图片拖入 → 创建参考图节点;带 iwb-gallery-orig 标识 → 取清晰原图,失败回退稳定显示源
const localRefPayload = e.dataTransfer && e.dataTransfer.getData('application/x-iwb-localref')
const origName = e.dataTransfer && e.dataTransfer.getData('application/x-iwb-gallery-orig')
if (localRefPayload || origName) {
// 输出节点结果图拖入(v3.26.87):载荷是结果 URL;优先按 URL 在图库索引里找条目,
// 命中就走「本地字节日录」(与图库拖入同一条链),没命中也不阻断 —— 直接用 URL 建参考图。
const outputRefPayload = e.dataTransfer && e.dataTransfer.getData('application/x-iwb-output-ref')
if (localRefPayload || origName || outputRefPayload) {
const insertRef = (url) => {
if (!url) { setNotice({ type: 'err', text: '无法取得该图片,拖入失败' }); return }
const name = typeof url === 'string' ? (url.indexOf('http') === 0 ? (url.split('/').pop() || 'image') : (url.indexOf('data:') === 0 ? '参考图' : url)) : '参考图'
@@ -1072,8 +1075,22 @@
pushHistory() // 拖拽入画布新增节点:入撤销历史(鼠标落点保留)
commitCanvas(refs.nodes.concat([node]), undefined, undefined)
setSel([id])
// 原生拖放期间 pointerup 不落到画布,节点手势可能残留(之后再点节点被当成收尾):
// 插入后统一清一次,与提示词拖入的 settleDrop 同一理由。
try { refs.bodyDown = null; refs.groupDown = null; refs.drag = null; refs.box = null; refs.pan = null } catch (e) { /* ignore */ }
setNotice({ type: 'ok', text: '已插入图库参考节点' })
}
if (outputRefPayload) {
const list = refs.outputs || outputs || []
const item = list.find((x) => x && (x.url === outputRefPayload || x.name === outputRefPayload))
const pickSrc = () => (item && typeof localSrcOfOutput === 'function' ? localSrcOfOutput(item) : Promise.resolve(outputRefPayload))
Promise.resolve(pickSrc()).then(async (src) => {
const raw = await refSrcOf(src || outputRefPayload, (msg) => setNotice({ type: 'err', text: msg }))
const ref = (typeof raw === 'string' && raw.indexOf('data:') === 0) ? await wImgRefWrite(raw) : null
insertRef(ref || raw || outputRefPayload)
}).catch(() => insertRef(outputRefPayload))
return
}
if (origName) {
const item = (refs.outputs || outputs || []).find((x) => x && x.name === origName)
// v3.26.61:拖入也走「本地字节目录」(含按需抓远程再落副本),与「插入」按钮同一条路,
+27 -1
View File
@@ -17,12 +17,38 @@
onMouseEnter: () => setHover(true),
onMouseLeave: () => setHover(false),
},
el('img', { className: props.cls || 'iwb-result-thumb', src: item.url, alt: 'img', loading: 'lazy', title: '点击放大', onClick: () => props.onPreview && props.onPreview(item.url) }),
// 单击只让节点选中(不弹预览),双击才开大图:与输出节点结果图同一手势。
el('img', { className: props.cls || 'iwb-result-thumb', src: item.url, alt: 'img', loading: 'lazy', title: '双击放大', onClick: (e) => { try { e.stopPropagation() } catch (err) { /* ignore */ } }, onDoubleClick: (e) => { try { e.stopPropagation() } catch (err) { /* ignore */ } if (props.onPreview) props.onPreview(item.url) } }),
hover ? el('div', { className: 'iwb-rimg-actions' },
el('button', { className: 'iwb-btn iwb-btn-sm', title: '复制为参考图节点', onClick: doCopyRef }, props.copyIcon || '⧉', ' 复制到画布'),
el('button', { className: 'iwb-btn iwb-btn-sm', title: '复制图片链接', onClick: doCopyLink }, '🔗 链接'),
) : null,
)
}
// 共享「下载浮层」:底部渐变 + 下载(可选复制),hover/focus 才出现。
// 图库插件是原生 DOM,用同一组 token 在插件 CSS 里复刻;宿主这里只需一个 React 组件。
// pointer-events:浮层条本身不吃事件(否则会挡住图片点击/双击),只有悬停后按钮才可点。
function ResultDownloadOverlay (props) {
const p = props || {}
const stopDown = (e) => { try { e.stopPropagation() } catch (err) { /* ignore */ } }
return el('div', { className: 'iwb-dl-ov' },
p.children,
el('div', { className: 'iwb-dl-bar' },
p.onCopyRef ? el('button', {
className: 'iwb-dl-btn iwb-dl-btn-ghost',
title: p.copyTitle || '插入为参考图节点',
onPointerDown: stopDown,
onClick: (e) => { e.stopPropagation(); p.onCopyRef() },
}, p.copyIcon || null, el('span', { className: 'iwb-dl-txt' }, p.copyLabel || '复制')) : null,
el('button', {
className: 'iwb-dl-btn',
title: p.downloadTitle || '下载原图',
onPointerDown: stopDown,
onClick: (e) => { e.stopPropagation(); if (p.onDownload) p.onDownload() },
}, p.icon || null, el('span', { className: 'iwb-dl-txt' }, p.label || '下载')),
),
)
}
global.IWBResultImg = ResultImg
global.IWBResultDownloadOverlay = ResultDownloadOverlay
})(typeof window !== 'undefined' ? window : globalThis)
+16 -15
View File
@@ -822,23 +822,24 @@
// key 用「url + 组内序号」而不是下标(2026-11-03):下标作 key 时,条目集合一变(旧图被新图替换)
// React 会按下标复用同一个 DOM 节点,先显示上一张、再等新图解码 ⇒ 肉眼看到「闪一下旧图/空图」。
// url 稳定 ⇒ 节点复用(不重建、不重新解码);url 变了才新建,内容永远对得上。
const doDownload = async () => {
let src = r.url
// v3.25.18:从资料目录的本地归档取图(原图优先),远端 URL 只作兜底
try { if (wResolveOutSrc) src = (await wResolveOutSrc(r, true)) || r.url } catch (e) { /* 回退远端 */ }
downloadUrl(src, 'image.png')
}
const doCopy = () => props.onCopyRef && props.onCopyRef(r.url)
const imgEl = el('img', { key: 'out-img-' + cur + '-' + String(r.url || '').slice(-48), className: 'iwb-out-cell-img', decoding: 'async', fetchPriority: 'low', referrerPolicy: 'no-referrer', src: wPreviewUrlOf((typeof wImgSrcForNode === 'function' ? wImgSrcForNode : wDisplayThumbOf)(thumbOf(r), Math.max(120, Math.min(360, (node && node.w ? node.w - 40 : 240))))), draggable: true, style: { aspectRatio: (r.width && r.height) ? String(r.width) + ' / ' + String(r.height) : undefined }, title: r.idb && r.data ? '单击选中 · 双击查看原图 · 拖到画布作参考图' : '单击选中 · 双击放大(可左右切换)· 拖到画布作参考图', onError: (e) => { if (e.currentTarget && e.currentTarget.src !== r.url) e.currentTarget.src = r.url }, onPointerDown: (e) => { e.stopPropagation(); props.onSelect && props.onSelect(node.id) }, onDragStart: (e) => { try { const u = r.url || ''; e.dataTransfer.setData('application/x-iwb-output-ref', u); e.dataTransfer.setData('text/plain', u); e.dataTransfer.effectAllowed = 'copy' } catch (err) { /* 浏览器拒写自定义 MIME 时仍保留 text/plain */ } }, onDoubleClick: (e) => { e.stopPropagation(); openPreviewAt(cur) } })
// 下载浮层:与图库共用同一组 hover token;组件缺失时退回旧的双小按钮(单文件/旧加载顺序)
const DlOv = (typeof global !== 'undefined' && global.IWBResultDownloadOverlay) || null
const actions = DlOv ? null : el('div', { className: 'iwb-out-cell-actions' },
el('button', { className: 'iwb-btn iwb-btn-sm', title: '插入为参考图节点', onClick: doCopy, onPointerDown: stop }, I('copy')),
el('button', { className: 'iwb-btn iwb-btn-sm', title: '下载', onClick: doDownload, onPointerDown: stop }, I('download')),
)
return el('div', { key: String(r.url || '') + '|' + ri, className: 'iwb-out-cell' },
el('img', { key: 'out-img-' + cur + '-' + String(r.url || '').slice(-48), className: 'iwb-out-cell-img', decoding: 'async', fetchPriority: 'low', referrerPolicy: 'no-referrer', src: wPreviewUrlOf((typeof wImgSrcForNode === 'function' ? wImgSrcForNode : wDisplayThumbOf)(thumbOf(r), Math.max(120, Math.min(360, (node && node.w ? node.w - 40 : 240))))), draggable: false, style: { aspectRatio: (r.width && r.height) ? String(r.width) + ' / ' + String(r.height) : undefined }, title: r.idb && r.data ? '缩略图 · 点击查看原图' : '点击放大(可左右切换)', onError: (e) => { if (e.currentTarget && e.currentTarget.src !== r.url) e.currentTarget.src = r.url }, onClick: () => openPreviewAt(cur) }),
DlOv ? el(DlOv, { key: 'ov', onDownload: doDownload, onCopyRef: doCopy, icon: I('download'), copyIcon: I('copy') }, imgEl) : imgEl,
el('div', { className: 'iwb-out-cell-meta' }, (r.width || '?') + '×' + (r.height || '?')),
el('div', { className: 'iwb-out-cell-actions' },
el('button', { className: 'iwb-btn iwb-btn-sm', title: '插入为参考图节点', onClick: () => props.onCopyRef && props.onCopyRef(r.url), onPointerDown: stop }, I('copy')),
el('button', {
className: 'iwb-btn iwb-btn-sm',
title: '下载',
// v3.25.18:从资料目录的本地归档取图(原图优先),远端 URL 只作兜底
onClick: async () => {
let src = r.url
try { if (wResolveOutSrc) src = (await wResolveOutSrc(r, true)) || r.url } catch (e) { /* 回退远端 */ }
downloadUrl(src, 'image.png')
},
onPointerDown: stop,
}, I('download')),
),
actions,
)
}
const groupCards = []
+15 -2
View File
@@ -902,8 +902,21 @@ html { scrollbar-width: thin; scrollbar-color: var(--iwb-border2) color-mix(in s
.iwb-out-head .iwb-label { flex: 0 0 auto; }
.iwb-out-tools { flex: 1 1 auto; display: flex; gap: 4px; justify-content: flex-end; }
.iwb-out-tools .iwb-btn { padding: 2px 8px; font-size: 11px; }
.iwb-out-cell-img { width: 100%; height: auto; display: block; border-radius: var(--iwb-radius-control); border: 1px solid var(--iwb-border); cursor: zoom-in; background: var(--iwb-layer2); transition: border-color .12s; }
.iwb-out-cell-img:hover { border-color: var(--iwb-brand); }
.iwb-out-cell-img { width: 100%; height: auto; display: block; border-radius: var(--iwb-radius-control); border: 1px solid var(--iwb-border); cursor: zoom-in; background: var(--iwb-layer2); transition: border-color var(--iwb-motion-hover) var(--iwb-ease-hover), box-shadow var(--iwb-motion-hover) var(--iwb-ease-hover), transform var(--iwb-motion-hover) var(--iwb-ease-hover); }
/* 悬停:卡片级的浮起(图本身轻微抬 2px + 放大 1.02)。用 cell:hover 而不是 img:hover:
指针压到浮层按钮上时图片仍是「悬停中」,不会出现按钮还在、图先弹回去的抖动。 */
.iwb-out-cell:hover .iwb-out-cell-img { border-color: var(--iwb-hover-border); filter: drop-shadow(var(--iwb-hover-shadow)); transform: translateY(var(--iwb-hover-lift)) scale(var(--iwb-hover-scale)); }
/* 下载浮层(2026-11-26):底部渐变 + 主按钮,hover/focus 才出现;条本身不吃事件,只有按钮吃。 */
.iwb-dl-ov { position: relative; display: block; border-radius: var(--iwb-radius-control); overflow: hidden; }
.iwb-dl-ov > img { display: block; width: 100%; height: auto; }
.iwb-dl-bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; justify-content: center; gap: var(--iwb-space-6); padding: var(--iwb-space-16) var(--iwb-space-8) var(--iwb-space-6); background-image: linear-gradient(to top, var(--iwb-scrim), transparent); opacity: 0; transition: opacity var(--iwb-motion-hover) var(--iwb-ease-hover); pointer-events: none; }
.iwb-dl-ov:hover .iwb-dl-bar, .iwb-dl-ov:focus-within .iwb-dl-bar { opacity: 1; pointer-events: auto; }
.iwb-dl-btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--iwb-space-4); height: 24px; padding: 0 var(--iwb-space-10); border: 1px solid color-mix(in srgb, var(--iwb-on-brand) 30%, transparent); border-radius: var(--iwb-radius-full); background: var(--iwb-brand); color: var(--iwb-on-brand); font-size: var(--iwb-font-2xs); line-height: 1; cursor: pointer; box-shadow: none; }
.iwb-dl-btn:hover { filter: drop-shadow(var(--iwb-hover-shadow)) brightness(1.05); }
.iwb-dl-btn-ghost { background: color-mix(in srgb, var(--iwb-panel) 18%, transparent); color: var(--iwb-on-brand); border-color: color-mix(in srgb, var(--iwb-on-brand) 26%, transparent); }
.iwb-dl-btn .iwb-ic { width: var(--iwb-icon-sm); height: var(--iwb-icon-sm); }
.iwb-dl-txt { white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { .iwb-out-cell-img, .iwb-dl-bar { transition: none; } .iwb-out-cell:hover .iwb-out-cell-img { transform: none; } }
.iwb-out-cell-meta { font-size: var(--iwb-font-2xs); color: var(--iwb-text2); text-align: center; margin-top: var(--iwb-space-2); }
.iwb-out-cell-actions { position: absolute; left: 0; right: 0; bottom: 0; height: 22px; display: flex; align-items: center; justify-content: center; gap: var(--iwb-space-10); opacity: 0; transition: opacity .15s; border-radius: 0 0 8px 8px; background: rgba(0,0,0,0.45); } /*iwb:raw-until=3.28.0*/
.iwb-out-cell:hover .iwb-out-cell-actions { opacity: 1; }
+62
View File
@@ -0,0 +1,62 @@
'use strict'
// 结果图手势契约(2026-11-26):单击只选中、双击才预览。
// 用假 React 记录 createElement 的树,直接调用组件函数——不需要 jsdom/React 运行时,
// 断言的是「实际渲染出来的 props」,不是源码文本。
const assert = require('assert')
const fs = require('fs')
const path = require('path')
const vm = require('vm')
const root = path.resolve(__dirname, '..')
const React = {
createElement(type, props) {
const children = Array.prototype.slice.call(arguments, 2)
return { type, props: Object.assign({}, props || {}, { children }) }
},
useState(init) { return [init, function () {}] },
}
const sandbox = { React }
vm.runInNewContext(fs.readFileSync(path.join(root, 'src', 'ui-components.js'), 'utf8'), sandbox)
const findImg = (tree) => {
if (!tree || typeof tree !== 'object') return null
if (tree.type === 'img') return tree
for (const c of (tree.props && tree.props.children) || []) {
const hit = findImg(c)
if (hit) return hit
}
return null
}
// 1) ResultImg:单击不预览,双击预览
let previewed = ''
const img = findImg(sandbox.IWBResultImg({ item: { url: 'https://x/a.png' }, onPreview: (u) => { previewed = u } }))
assert.ok(img, 'ResultImg 必须渲染出 img')
assert.strictEqual(typeof img.props.onDoubleClick, 'function', '双击必须绑定预览')
assert.strictEqual(typeof img.props.onClick, 'function', '单击仍需有处理器(阻止冒泡)')
img.props.onClick({ stopPropagation() {} })
assert.strictEqual(previewed, '', '单击不得触发预览')
img.props.onDoubleClick({ stopPropagation() {} })
assert.strictEqual(previewed, 'https://x/a.png', '双击必须带上图片 URL')
// 2) 共享下载浮层:按钮存在、点击回调正确、pointerdown 不冒泡到节点拖动
let downloaded = 0
let copied = 0
let stopped = 0
const ov = sandbox.IWBResultDownloadOverlay({
onDownload: () => { downloaded++ },
onCopyRef: () => { copied++ },
children: { type: 'img', props: {} },
})
const bar = ov.props.children.find((c) => c && c.props && c.props.className === 'iwb-dl-bar')
assert.ok(bar, '浮层必须渲染底部条')
const btns = bar.props.children.filter(Boolean)
assert.strictEqual(btns.length, 2, '浮层应有复制 + 下载两个按钮')
btns[0].props.onClick({ stopPropagation() {} })
btns[1].props.onClick({ stopPropagation() {} })
btns[1].props.onPointerDown({ stopPropagation() { stopped++ } })
assert.strictEqual(copied, 1)
assert.strictEqual(downloaded, 1)
assert.strictEqual(stopped, 1, 'pointerdown 必须阻止冒泡(否则会拖动节点)')
console.log('result-img gestures: 全部通过')