Hi everybody!

I want to write an extension for the VisualEditor (great work by the way) and I 
need a little help. I've browsed through various documentation [1-4](and more) 
and already learned that using RL module 
'ext.visualEditor.desktopArticleTarget.init'  and 'mw.lib.ve.addPlugin' method 
is the way to go. Unfortunately my attempts to hook into the user interface by 
binding on events provided by the components (like 'save' from 
've.ui.MWSaveDialog' or 've.init.mw.Target') have not been successful yet. 
Maybe you could give me a little push into the right direction.

Are there any HowTos or Tutorials for VisualEditor that cover topics like

1.       Adding buttons to the toolbar

2.       Accessing the data model (e.g. retrieve all set categories from the 
Parsoid DOM)

3.       Extending/replacing a single tool (e.g. the GalleryInspector)

4.       Binding on components events (e.g. the 'save' event, to analyze 
content and maybe abort saving)

Points 1 and 2 get more or less explained by the docs I've found. But 3 and 4 
are very unclear to me. Some hints would be appreciated!

[1] 
https://www.mediawiki.org/wiki/VisualEditor_gadgets#Gadget_-_Registering_VE_plugin
[2] https://en.wikipedia.org/wiki/User:%D7%A2%D7%A8%D7%9F/veReplace.js
[3] https://doc.wikimedia.org/VisualEditor/master
[4] https://www.mediawiki.org/wiki/OOjs_UI/Toolbars

Greetings,
Robert Vogel
_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to