fix(gallery 1.5.1): .iwb-hint 限定作用域,修设置页文案被居中;fix(grouplib 1.0.2): 分类胶囊改横向滚动容器,修被裁切

This commit is contained in:
qiqi committed 2026-11-20 13:31:53 +08:00
1 parent 7c7eff40ee
commit 43b02a3a1c
5 files changed
+14 -10

No files matched your search

+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "@iwb-plugin/gallery",
"private": true,
"version": "1.5.0",
"version": "1.5.1",
"description": "图库:右栏图片墙(筛选/多选/预览/插入画布/下载/删除),数据由宿主 gallery 能力提供",
"ibwPlugin": {
"id": "gallery",
+1 -1
View File
@@ -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 },
+2 -1
View File
@@ -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; }
/* 只作用于图库自己的空态提示:不加前缀会泄漏到设置页等使用 .iwb-hint 的地方(文字被居中) */
.iwb-history-embedded .iwb-hint { font-size: 11px; color: var(--iwb-text2); text-align: center; padding: 12px 6px; }
+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "@iwb-plugin/grouplib",
"private": true,
"version": "1.0.1",
"version": "1.0.2",
"description": "节点组:左栏收藏的节点组列表(分组/改名/删除/拖入画布实例化),数据由宿主 grouplib 能力提供",
"ibwPlugin": {
"id": "grouplib",
+9 -6
View File
@@ -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 },