Page MenuHomePhabricator

Graph placeholder is stripped from page by Tidy
Closed, ResolvedPublic

Description

Graph uses an empty element as placeholder in the html output.

It used to be a <div class="mw-wiki-graph" data-spec=".."></div>, then changed to a <span class="mw-wiki-graph" data-spec=".." id="mw-graph-be66c7016b9de3188ef6a585950f10dc83239837"></span>.

Then in patch set 2 of https://gerrit.wikimedia.org/r/#/c/186331/, it changed to <span class="mw-wiki-graph" data-spec-id=".."></span>.

From that point onwards, the element is stripped from the output by Tidy.

So if and only if an element matches all of the following:

  • No content.
  • Is a span.
  • Has no id attribute.

Then Tidy decides to strip it.... ?

By sheer luck, up to this point Graph walked a fine line to avoid these three parameters.

Event Timeline

Krinkle raised the priority of this task from to Needs Triage.
Krinkle updated the task description. (Show Details)
Krinkle subscribed.
Yurik triaged this task as Low priority.May 6 2015, 9:01 AM
Izno claimed this task.
Izno subscribed.

This is a case of T29786: let empty metadata-elements pass through tidy, which was resolved with Remex. I'm marking this one resolved as well.