Page MenuHomePhabricator

Parsoid wiki links don't have title attribute
Closed, ResolvedPublic

Description

Hovercards (Extension:Popups) uses the title attribute of a link in an API query to get an extracts and thumbnail for a linked page. This works because when Linker.php turns a wiki link into HTML, it sets the title attribute to the namespace:title (getPrefixedText()).

However, Parsoid doesn't do this, it doesn't output a title attribute. Parsoid turns [[Talk:Main_Page]] into something like:

<a rel="mw:WikiLink" href="./Talk:Main_Page" data-parsoid='{"stx":"simple","a":{"href":"./Talk:Main_Page"},"sa":{"href":"Talk:Main_Page"},"dsr":[6,24,2,2]}'>Talk:Main_Page</a>

Hovercards may soon change to parsing the href contents. But this difference from Linker output may affect other gadgets and tools.


Version: unspecified
Severity: normal

Details

Reference
bz68013

Event Timeline

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

Change 150888 had a related patch set uploaded by Arlolra:
WIP: Don't ignore titles

https://gerrit.wikimedia.org/r/150888

Change 150888 merged by jenkins-bot:
Don't ignore titles

https://gerrit.wikimedia.org/r/150888

  • Bug 58723 has been marked as a duplicate of this bug. ***