Page MenuHomePhabricator

Fetch the requested image from Commons
Closed, ResolvedPublic

Description

This ticket is preceded by T206712: Create the Translate view and followed by T207203: Image preview functionality.

This ticket is for fetching the image searched by the user in T204596: Search image component for SVG Translate tool and displaying it in the image box in the Translate view. By default, the image contains the Default language labels or the first one present, if no default.

This ticket also involves feeding the SVG into the tool backend so it can be used for generating previews.

Event Timeline

Niharika triaged this task as Medium priority.Nov 26 2018, 11:53 PM
Niharika created this task.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptNov 26 2018, 11:53 PM

I remembered the problem I found yesterday: we're delivering the image as an SVG and leaving it to the browser to render it, and so the clever systemLanguage switch happens in the browser and the displayed language is whatever is set in the browser preferences — and not the current To language in the tool. We can't change the browser's language, so I guess we need to serve up the SVG with either only one language or with the system language strings changed to those of the To language? Or something better and less ugly. :)

@Mooeypoo @Samwilson Did you folks end up discussing this ticket in the engineering meeting? Do we need to estimate/keep it?

I've snuck the image-display part into the patch for T206712. It's only one line.

The main other part of this ticket is displaying the SVG in the To language, and that's a matter of returning the SVG with only a single (i.e. unlabelled/default/fallback) language in it. I'm not sure if we've got a separate ticket for that, but it could be handled separately and this one closed.

Niharika closed this task as Resolved.Dec 11 2018, 12:41 AM
Niharika assigned this task to Samwilson.