Page MenuHomePhabricator

Enable DOM editing of transclusion parameters
Open, Stalled, NormalPublic

Description

This is needed to allow VisualEditor to support such lovely wikitext as {{echo|{{echo|Foo!}}}} and more complex variations.


Version: unspecified
Severity: enhancement

Details

Reference
bz69870

Event Timeline

bzimport raised the priority of this task from to High.Nov 22 2014, 3:33 AM
bzimport added a project: Parsoid-DOM.
bzimport set Reference to bz69870.

The current status for DOM transclusion parameters is: The code is there, but it is disabled by default as it affects performance. For example, it increases the rendering of [[Barack_Obama]] by more than 3s.

To enable it (in case someone wants to try it out), add
parsoidConfig.addHTMLTemplateParameters = true;
to localsettings.js.

With this enabled, it's possible to make Parsoid accept new transclusion parameters from HTML by removing the wt ones. We are also planning on adding support for detecting changes in parameters (so that the wikitext ones don't have to be removed) in the future.

I'll be working on improving performance shortly.

(In reply to Marc Ordinas i Llopis from comment #1)

With this enabled, it's possible to make Parsoid accept new transclusion
parameters from HTML by removing the wt ones. We are also planning on adding
support for detecting changes in parameters (so that the wikitext ones don't
have to be removed) in the future.

That sounds great.

I'll be working on improving performance shortly.

Excellent. :-)

marcoil set Security to None.Nov 25 2014, 6:28 PM
ssastry lowered the priority of this task from High to Normal.Jan 31 2015, 1:07 AM
marcoil changed the task status from Open to Stalled.Feb 10 2015, 2:38 PM
marcoil added a project: Blocked-on-Parsoid.
marcoil removed marcoil as the assignee of this task.Jun 9 2015, 2:07 PM

A different approach that we have considered over the last few months is to generate these HTML representation of tpl params on demand rather than for Parsoid to generate this all the time and then store it.

So, whenever a template is opened up for editing in VE, VE would request Parsoid for HTML representation of these parameters, and then use that to enabled HTML editing of these params. If this is considered a workable approach, we can work out the details and this can see the light of day much faster.

Magol added a subscriber: Magol.Dec 28 2017, 10:12 AM