https://bugzilla.wikimedia.org/show_bug.cgi?id=43133
--- Comment #2 from Roan Kattouw <[email protected]> --- (In reply to comment #1) > It should be noted that a lot of this is already supported. I don't think > it's > perfect, and VE would have to perform some acrobatics to get it working, but > you could essentially make it work if you set the wikitext source on the > element, then serialized the DOM and re-parsed it to get the visual > representation back. > The wikitext is currently exposed in the data-parsoid attribute, but the contents of that attribute are supposed to be private and VE isn't supposed to look at them, just preserve them. There were earlier hacks in VE that extracted information from data-parsoid to work around Parsoid issues (specifically, we had to look at sHref for links and stx==html for list items), but Gabriel has been glaring at me every time I did that. So to make the wikitext editable, it would have to be moved to a more public place, or data-parsoid would have to be declared semi-public. Either way, we need to spec how Parsoid is going to present the wikitext to VE and what VE is allowed to do with it. > James_F and I chatted about this for some time, and I'm pretty sure that's > one > of the saner ways to do it (unless you wanted to simply ignore the visual > portion of "VisualEditor" and submit the alien's changes only when the user > is > done editing. Yeah, you probably don't want to continuously rerender as the user types, that would get crazy. But as you say, you'd want to reparse the entered wikitext so you can rerender it and give the user visual feedback. That should be interesting to implement. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Wikibugs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikibugs-l
