From 43b02a3a1c7b72ec44ba7fab36a76400bfe6b79b Mon Sep 17 00:00:00 2001 From: qiqi Date: Fri, 20 Nov 2026 13:31:53 +0800 Subject: [PATCH] =?UTF-8?q?fix(gallery=201.5.1):=20.iwb-hint=20=E9=99=90?= =?UTF-8?q?=E5=AE=9A=E4=BD=9C=E7=94=A8=E5=9F=9F=EF=BC=8C=E4=BF=AE=E8=AE=BE?= =?UTF-8?q?=E7=BD=AE=E9=A1=B5=E6=96=87=E6=A1=88=E8=A2=AB=E5=B1=85=E4=B8=AD?= =?UTF-8?q?=EF=BC=9Bfix(grouplib=201.0.2):=20=E5=88=86=E7=B1=BB=E8=83=B6?= =?UTF-8?q?=E5=9B=8A=E6=94=B9=E6=A8=AA=E5=90=91=E6=BB=9A=E5=8A=A8=E5=AE=B9?= =?UTF-8?q?=E5=99=A8=EF=BC=8C=E4=BF=AE=E8=A2=AB=E8=A3=81=E5=88=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gallery/package.json | 2 +- gallery/src/index.js | 2 +- gallery/styles.css | 3 ++- grouplib/package.json | 2 +- grouplib/src/index.js | 15 +++++++++------ 5 files changed, 14 insertions(+), 10 deletions(-) diff --git a/gallery/package.json b/gallery/package.json index 7923bcd..ac0b64c 100644 --- a/gallery/package.json +++ b/gallery/package.json @@ -1,7 +1,7 @@ { "name": "@iwb-plugin/gallery", "private": true, - "version": "1.5.0", + "version": "1.5.1", "description": "图库:右栏图片墙(筛选/多选/预览/插入画布/下载/删除),数据由宿主 gallery 能力提供", "ibwPlugin": { "id": "gallery", diff --git a/gallery/src/index.js b/gallery/src/index.js index 90d8c30..95e2c02 100644 --- a/gallery/src/index.js +++ b/gallery/src/index.js @@ -372,7 +372,7 @@ global.IWBPluginHost.register({ id: 'gallery', name: '图库', - version: '1.5.0', + version: '1.5.1', apiVersion: 1, capabilities: ['panels', 'gallery'], data: { schemaVersion: 1, maxBytes: 65536 }, diff --git a/gallery/styles.css b/gallery/styles.css index 1b997f9..0efd471 100644 --- a/gallery/styles.css +++ b/gallery/styles.css @@ -65,4 +65,5 @@ .iwb-history-actions { display: flex; gap: 4px; padding: 4px 2px 0; } .iwb-history-actions .iwb-btn-sm { padding: 1px 6px; font-size: 10px; } .iwb-history-more { display: flex; justify-content: center; padding: 4px 0 2px; } -.iwb-hint { font-size: 11px; color: var(--iwb-text2); text-align: center; padding: 12px 6px; } \ No newline at end of file +/* 只作用于图库自己的空态提示:不加前缀会泄漏到设置页等使用 .iwb-hint 的地方(文字被居中) */ +.iwb-history-embedded .iwb-hint { font-size: 11px; color: var(--iwb-text2); text-align: center; padding: 12px 6px; } \ No newline at end of file diff --git a/grouplib/package.json b/grouplib/package.json index df562bd..2c65bf2 100644 --- a/grouplib/package.json +++ b/grouplib/package.json @@ -1,7 +1,7 @@ { "name": "@iwb-plugin/grouplib", "private": true, - "version": "1.0.1", + "version": "1.0.2", "description": "节点组:左栏收藏的节点组列表(分组/改名/删除/拖入画布实例化),数据由宿主 grouplib 能力提供", "ibwPlugin": { "id": "grouplib", diff --git a/grouplib/src/index.js b/grouplib/src/index.js index a8dfc6b..dda190a 100644 --- a/grouplib/src/index.js +++ b/grouplib/src/index.js @@ -281,8 +281,11 @@ } fixed.appendChild(topRow) - // 分类胶囊 + // 分类胶囊:宿主的 .iwb-lib-chips-scroll 负责「单行 + 横向滚动 + 右侧渐隐」, + // 直接铺在 .iwb-lib-chips 里会被 nowrap 裁掉(分组多时右侧分类看不见) var chips = el('div', { class: 'iwb-lib-chips' }) + var chipsScroll = el('div', { class: 'iwb-lib-chips-scroll' }) + chips.appendChild(chipsScroll) function chip (label, value, count, extra) { var b = el('button', { class: 'iwb-chip' + (filter === value ? ' iwb-chip-active' : '') + (extra || ''), title: value === '__none__' ? '未分组;拖拽节点组卡片到此 = 移出分组' : (value === 'all' ? '' : '拖拽节点组卡片到此 = 移动到该分组') }) b.appendChild(document.createTextNode(label)) @@ -297,15 +300,15 @@ }) return b } - chips.appendChild(chip('全部', 'all', list.length)) - chips.appendChild(chip('未分组', '__none__', countOf('__none__'), ' iwb-chip-drop')) + chipsScroll.appendChild(chip('全部', 'all', list.length)) + chipsScroll.appendChild(chip('未分组', '__none__', countOf('__none__'), ' iwb-chip-drop')) gs.forEach(function (g) { chips.appendChild(chip(g.name, g.name, countOf(g.name), ' iwb-chip-drop')) }) var addChip = el('button', { class: 'iwb-chip iwb-chip-add', title: '新建分组', text: '+' }) addChip.addEventListener('click', function () { newOpen = !newOpen; render() }) - chips.appendChild(addChip) + chipsScroll.appendChild(addChip) var mgChip = el('button', { class: 'iwb-chip iwb-chip-add', title: '管理分组(重命名 / 排序 / 删除)', text: '⚙' }) mgChip.addEventListener('click', openManager) - chips.appendChild(mgChip) + chipsScroll.appendChild(mgChip) fixed.appendChild(chips) if (newOpen) { @@ -432,7 +435,7 @@ global.IWBPluginHost.register({ id: 'grouplib', name: '节点组', - version: '1.0.1', + version: '1.0.2', apiVersion: 1, capabilities: ['panels', 'grouplib'], data: { schemaVersion: 1, maxBytes: 65536 },