Page MenuHomePhabricator

<citation> elements treated as divs instead of inline elements
Closed, ResolvedPublic

Description

It seems that something has changed with <citation> parsertags of the CiteThisPage extension. These used to present inline output, but now seem to generate div blocks. This can be seen on this Example, where the dates are now on a separate line, where they were not before.

Event Timeline

Last non-documentation code change was https://gerrit.wikimedia.org/r/#/c/319911/ nine months ago. Has it been broken for that long without us noticing or is it more recent?

Last non-documentation code change was https://gerrit.wikimedia.org/r/#/c/319911/ nine months ago. Has it been broken for that long without us noticing or is it more recent?

@Jdforrester-WMF very likely already broken for that long. It's not a page that too many people keep an eye on, and more casual readers might just think it's 'weird' instead of broken.

Lol, no it's simple:

<div class="mw-parser-output">13 Oct. 2017</div>

So it's because it inserts random pieces of parser-output into the line.

matmarex subscribed.

Wow, the way CiteThisPage makes this tag work is actually insane.

Change 384173 had a related patch set uploaded (by Bartosz Dziewoński; owner: Bartosz Dziewoński):
[mediawiki/extensions/CiteThisPage@master] Suppress wrapping <div class="mw-parser-output"> around our <citation> tags

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

Change 384173 merged by jenkins-bot:
[mediawiki/extensions/CiteThisPage@master] Suppress wrapping <div class="mw-parser-output"> around our <citation> tags

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

Jdforrester-WMF removed a project: Patch-For-Review.

OK, this is now fixed in master, and the fix will roll out to all wikis in the normal way (so fixed for the English Wikipedia on Thursday).

jhsoby subscribed.

I'm seeing this exact issue now, e.g. on https://en.wikipedia.org/w/index.php?title=Special:CiteThisPage&page=Nauru&id=954769756&wpFormIdentifier=titleform . Some form of regression? Seems like the <citation> tags get converted to <p>. (What kind of tag is <citation> anyways? I can't find any documentation for it, the closest I can find is HTML5's <cite> tag, which is meant for work titles. Probably the best solution is to just remove those tags from enwiki.)

I'm seeing this exact issue now, e.g. on https://en.wikipedia.org/w/index.php?title=Special:CiteThisPage&page=Nauru&id=954769756&wpFormIdentifier=titleform . Some form of regression? Seems like the <citation> tags get converted to <p>. (What kind of tag is <citation> anyways? I can't find any documentation for it, the closest I can find is HTML5's <cite> tag, which is meant for work titles. Probably the best solution is to just remove those tags from enwiki.)

This is a new issue: T250807. Basically, on enwiki, the <citation> tags are enclosed within {{#time}} function and the function comes with <p> tags.

Ah, ok. Closing this again then.