antvis/G6







The issue has been closed
通过graph.updateItem更新combo的collapsedSubstituteIcon属性不生效 #5351
lvvgang posted onGitHub
问题描述
通过graph.updateItem更新combo的collapsedSubstituteIcon属性不生效
重现链接
https://g6.antv.antgroup.com/zh/examples/item/defaultCombos/#rect
重现步骤
- 设置combo
combos: [
{
id: 'combo2',
label: 'with substitute icon while collapsed',
collapsed: true,
collapsedSubstituteIcon: {
show: true,
img: 'https://gw.alipayobjects.com/mdn/rms_f8c6a0/afts/img/A*IEQFS5VtXX8AAAAAAAAAAABkARQnAQ',
width: 72,
height: 72
}
},
]
- 更新collapsedSubstituteIcon属性
graph.updateItem(item.id, {
label: item.label,
status: item.status,
collapsedSubstituteIcon: {
img: 'https://gw.alipayobjects.com/os/s/prod/antv/assets/image/logo-with-text-73b8a.svg'
}
});
预期行为
调用updateItem后更新为新的图片
平台
- 操作系统: Windows
- 网页浏览器: Google Chrome
- G6 版本: 4.8.21
屏幕截图或视频(可选)
No response
补充说明(可选)
No response