AlloyUI (diagram-builder) extends

醉酒当歌 提交于 2019-12-12 03:45:42

问题


I'm trying to customise diagram builder, I created new type of node and trying to add custom attributes with custom editor.

I just extend from dropdownCellEditor and it already doesn't work (editor appears, but can not save value, seems save and cancel buttons do not work) :(

If I replace my custom editor to DropdownCellEditor - it's ok.

  editor: new Y.DropDownCellEditor({options: {
        apple: 'Apple',
        banana: 'Banana',
        cherry: 'Cherry',
        kiwi: 'Kiwi'
  }}),

Can someone explain what's going wrong ?

Code I'm trying to make workable: http://jsfiddle.net/tu89ap1o/1/

I would be very happy if some shares good documentation for AlloUI framework. Or suggest good library for building diagrams. Goals: need to have possibility to build custom nodes with different set of properties and edit them.

Thank you in advance.


回答1:


After many hours of debugging obfuscating code I've found that hide function works by just adding into class: your editor name plus '-hidden', so to make it workable need to add :

.mycustomcelleditor-hidden { display: none; }

into css, stupid implementation BTW.



来源:https://stackoverflow.com/questions/43221420/alloyui-diagram-builder-extends

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!