Page MenuHomePhabricator

VisualEditor silently changes <references responsive="1" /> to <references responsive="" />
Closed, ResolvedPublic

Description

This was reported on the German-language Wikipedia's feedback page and although it has no visible effect caused some confusion among editors.

Steps to reproduce:

  1. Go to the Internet Archive article or [[https://de.wikipedia.org/w/index.php?search=insource:/responsive=""/&title=Spezial:Suche&profile=advanced&fulltext=1&advancedSearch-current={"namespaces":[0]}&ns0=1|any other article with <references responsive="1" />]]
  2. Open the article for visual editing and make a small change such that Änderungen veröffentlichen... (Publish changes...) turns blue (e.g. delete and add back a character)
  3. Click on Änderungen veröffentlichen (Publish changes...) and select Überprüfe deinen Änderungen (Review your changes)
  4. Observe that <references responsive="1" /> was converted to <references responsive="" />

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

This is because we don't actually try to preserve the value of the attribute, just its meaning. More potentially-confusing is that we discard the attribute entirely if it's the same as the wiki's default, so if the default changes lots of edits will suddenly be dirtied... and then toggle away from it if the default switches back again.

@Esanders: You set it up this way in the first place -- think it's worth changing to avoid dirty diffs?

Change 499814 had a related patch set uploaded (by Esanders; owner: Esanders):
[mediawiki/extensions/Cite@master] RefList: Avoid changing 'responsive' value if meaning hasn't changed

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

Change 499814 merged by jenkins-bot:
[mediawiki/extensions/Cite@master] RefList: Avoid changing 'responsive' value if meaning hasn't changed

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