feat(vault): 浏览窗口固定/可拖拽 + 复制不闪(v3.26.269)
Verify (Gitea) / gate (build · unit · facts) (push) Failing after 1m42s

- 窗口固定 860×620;右下角拖拽调整、双击复位、尺寸持久化;切换分类不再改窗口高度
- 面板加载 effect 只依赖 open+源库路径(actions 用 ref),复制不再触发重新读库
- 批量复制:延迟 setWorkspaces(deferState),结束后一次 commitList(一次渲染+一次写索引)
- 修复 268 接线:app 端 createBoard(b, opts) 之前只传 b,silent/defer 未生效
- 记住上次分类/排序
This commit is contained in:
qiqi committed 2026-12-06 19:02:42 +08:00
1 parent 35495df424
commit ec7933e2e5
10 files changed
+98 -30

No files matched your search

+3 -2
View File
@@ -6673,9 +6673,10 @@ const tbCenterSeed = (type, refs) => {
tauri: window.__TAURI__,
grantDir: (p) => window.IWBStorageFile.grantDir && window.IWBStorageFile.grantDir(p),
writeImage: (u) => wImgRefWrite(u),
createBoard: (b) => createBoardFromTransfer(b),
createBoard: (b, opts) => createBoardFromTransfer(b, opts),
persistList: (list, id) => persistWs(list, id || activeWsId),
activeId: () => activeWsId,
commitList: (list, id) => { refs.workspaces = list; setWorkspaces(list); persistWs(list, id || activeWsId) },
flush: () => window.IWBStorageFile.flush(),
toast: (m, t) => { try { showToast(m, t) } catch (e) { /* ignore */ } },
uid: (p) => uid(p),
@@ -8684,7 +8685,7 @@ const tbCenterSeed = (type, refs) => {
const cur = { id: activeWsId, name: activeWsName(), nodes: refs.nodes, edges: refs.edges, groups: refs.groups }
const list = WorkspaceList.upsert(base, activeWsId, cur).concat([{ id, name: nm, nodes: b.nodes, edges: b.edges, groups: b.groups, category: b.category || '', starred: !!b.starred, deleted: false, lastUsed: Date.now() }])
refs.workspaces = list
setWorkspaces(list)
if (!(opts && opts.deferState)) setWorkspaces(list)
if (!silent) {
setActiveWsId(id); openTab(id); setShellView('canvas')
loadWsInto(list[list.length - 1], true) // noFit:不重置视口,避免切画板时画布缩放跳动