Page MenuHomePhabricator

VE: Avoid piping links for formatting where possible
Closed, ResolvedPublic


I don't know if this has been reported yet, I couldn't find it when searching for VE reports related to linking.

When using wikilinks and then formatting them, the VE will always pipe them, even if this is not required, e.g.

[[Link|''Link'']] instead of ''[[Link]]''

That seems unnecessary and on en-wiki a bot runs to fix those errors, which seems counterproductive. Instead, the VE should be able to determine whether the whole link is formatted and then just apply to formatting outside the [[ ]].

Event Timeline

dchan added a subscriber: dchan.

Thanks SoWhy, things like this would happen during the HTML->wikitext conversion in Parsoid, so I've tagged it as an issue for the Parsoid team to look at.

ssastry triaged this task as Medium priority.Apr 8 2018, 2:20 AM
ssastry added a subscriber: ssastry.

Looks like one more thing to do along the lines of

ssastry moved this task from Needs Triage to html2wt on the Parsoid board.

Change 425884 had a related patch set uploaded (by Sbailey; owner: Sbailey):
[mediawiki/services/parsoid@master] For VE, Avoid piping lings for formatting

The normalization code now checks for matching href and textContent, and also avoid normalizing WikiLinks that have color, style and class attributes.

Change 425884 merged by jenkins-bot:
[mediawiki/services/parsoid@master] Avoid piping links for formatting when possible

Is this supposed to have been fixed? Because it isn't.