Page MenuHomePhabricator

Allow for SVGs in wiki language by default in "File" namespace
Closed, ResolvedPublic5 Story Points

Description

This ticket is for replicating the work we did on T205040: Show SVGs in page language if available for File namespace pages on wikis. For example, this file should show up in German by default instead of English on the file page in dewiki.

Event Timeline

Niharika triaged this task as Normal priority.Nov 30 2018, 12:35 AM
Niharika created this task.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptNov 30 2018, 12:35 AM
Niharika set the point value for this task to 5.Dec 11 2018, 12:38 AM
Niharika moved this task from To be estimated/discussed to Estimated on the Community-Tech board.
MaxSem claimed this task.Jan 8 2019, 12:33 AM
MaxSem moved this task from Ready to In Development on the Community-Tech-Sprint board.

Change 483304 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[mediawiki/core@master] Display translatable images in user language on image pages

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

I've implemented what's being currently requested in the above patch, however let's be sure we understand all the details:

  • On local wikis, it makes sense to use wiki language
  • On Commons, the default language is English - however the whole wiki makes this almost transparent, using user's UI language as fully as possible. Does it make sense to use user language on Commons?

I've implemented what's being currently requested in the above patch, however let's be sure we understand all the details:

  • On local wikis, it makes sense to use wiki language
  • On Commons, the default language is English - however the whole wiki makes this almost transparent, using user's UI language as fully as possible. Does it make sense to use user language on Commons?

There is one possible pitfall of doing that. Commons file page UI does not make it very clear when you are viewing a file in a given language versus when you are viewing a file that has been switch translated into a given language. If we start to show images by default in user's language, we might make that problem worse by tricking people into thinking that the file is only available for the language they see it in. They might go ahead and embed it in wikis where that's not the default language (maybe a variant/closely related language) and the file will end up with English labels on that wiki.
Hence, I think it's best if we let the default language for files on Commons remain English.

Hmm, makes sense. Final question: do we need a flag for it, and if yes, should $wgMediaInTargetLanguage suffice? I was actually thinking of deprecating it as the original feature it was added for works fine enough to just be always on. Ping @Mooeypoo, @Samwilson and @MusikAnimal.

We could keep the same flag and deprecate it after a while once we know it doesn't cause anything to blow up.

I don't think this needs a feature flag (and I agree, @MaxSem, that wgMediaInTargetLanguage should be deprecated). The above patch looks good to me.

Poke. This ticket has been sitting for a while.

I don't think we have a consensus re configuration variable?

I don't think we have a consensus re configuration variable?

It's up to you if you want to keep it or not.

OK, I'll side with Sam then and not use it.

And in such case, this change is ready for review.

Change 483304 merged by jenkins-bot:
[mediawiki/core@master] Display translatable images in wiki language on image pages

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

Niharika added a comment.EditedFeb 21 2019, 11:44 PM

This has been deployed. I tested with https://de.wikipedia.org/wiki/Datei:Equatorial_coordinates.svg and it works as expected. I couldn't find other test files to try with.

Niharika closed this task as Resolved.Feb 25 2019, 5:57 PM
Niharika moved this task from QA to Q3 2018-19 on the Community-Tech-Sprint board.

Closing this ticket. I didn't find any other test cases.

Niharika moved this task from In progress to Done on the SVG Translate Tool board.Feb 25 2019, 5:57 PM