Hufe921 / canvas-editor

rich text editor by canvas/svg
https://hufe.club/canvas-editor-docs
MIT License
3.43k stars 498 forks source link

设置控件id滚动无效 #700

Closed zhuyihe closed 1 month ago

zhuyihe commented 1 month ago

version

0.9.86

Link to minimal reproduction

No response

Steps to reproduce

592

设置controlId无效,重新将controlId赋值 image

What is expected?

控件能传入controlId

What is actually happening?

controlId设置无效

System Info

No response

Any additional comments?

No response

Hufe921 commented 1 month ago

接口调用是否由事件(如点击)触发

zhuyihe commented 1 month ago

接口调用是否由事件(如点击)触发

对,由点击事件触发 image

这边传入了controlId image

但是在渲染文字的时候将控件拆分,controlId又随机生成了,导致无法定位 image

Hufe921 commented 1 month ago

通过getControlList或getValue获取内部控件id后再执行定位

zhuyihe commented 1 month ago

通过getControlList或getValue获取内部控件id后再执行定位

不能主动设置吗?比如我要传入固定的id