The way the WikiEditor works right now, the textbox can be replaced with
anything that can support a few methods, such as getSelection,
encapsulateSelection, etc. There are some modules that depend on specific
edit box implementations, such as the current and only alternative to the
textarea we called "iframe" since it's a contentEditable iframe.

If you take a look at jquery.wikiEditor.iframe.js, you will see what I mean.
It should be pretty straightforward to drop anything in there, and be able
to take advantage of the toolbar. There are some things, like find and
replace that may need to be reworked or just turned off, but even things
like the link dialog should work just fine but just supporting a few
methods.

The API could be better documented, and re-factored a bit to be even more
generic, but the basic structure is there, and can be reused without much
hacking.

- Trevor

On Fri, May 6, 2011 at 10:38 AM, Brion Vibber <[email protected]> wrote:

> Neil spent some time yesterday hacking with the Hackpad guys (
> https://hackpad.com/ -- an Etherpad fork) experimenting with embedding the
> collaborative editor via an <iframe> into MediaWiki's edit page in order to
> use it to do multiuser editing.
>
> Apparently it's pretty cool so far and I'm looking forward to seeing it
> stabilized! -- but more forward-looking we're tossing the idea around the
> office of having a common protocol for such editor embedding, which we can
> then use for other things:
>
> * the contentEditable mode for WikiEditor
> * the Ace syntax-highlighter in CodeEditor gadget
> * experimental rich text editors etc
>
> Some of Neil & my initial notes:
>
> http://www.mediawiki.org/wiki/Future/Hackpad/Spec
>
>
> The API between the host window and the (potentially offsite) iframe would
> need to handle loading initial text, saving it, and some state checks at a
> minimum; depending on how much we want to integrate the WikiEditor's
> toolbar
> portion as a standard we may need to be able to let the toolbar control
> things like selection and text insertion, or each editor variant could
> manage its own toolbar and that could be a WikiEditor-specific protocol
> part.
>
> Thoughts?
>
> -- brion
> _______________________________________________
> Wikitech-l mailing list
> [email protected]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to