Page MenuHomePhabricator

Clicking an image when picking a sentence leaves the editor
Closed, ResolvedPublic

Description

Currently when the user is in the "pick a sentence step" (T251551) to select a sentence to translate, clicking on an image causes the browser to navigate away:

Screenshot 2021-01-29 at 10.19.23 2.png (607×589 px, 145 KB)

This ticket proposes to prevent such navigation. Clicking on an image should select their caption text for translation. If that is complex to support, at least prevent the outside navigation.

Steps to reproduce:

  1. Translate "Moon" from English to Spanish in the test instance
  2. Select "In culture" section and start the translation.
  3. Optionally, add some sentence to the translation.
  4. Click on an image.
  5. Observe that the warning to leave the translation is shown. Or if you had not added any contents, the browser navigates to the image page leaving the translation.

Expected result: the browser does not try to leave the page and the caption of that image is selected.

Event Timeline

Pginer-WMF triaged this task as Medium priority.Jan 29 2021, 9:29 AM
Pginer-WMF created this task.
Pginer-WMF moved this task from Backlog to Mobile editor on the SectionTranslation board.
Pginer-WMF raised the priority of this task from Medium to High.Feb 2 2021, 9:34 AM

Change 662929 had a related patch set uploaded (by Nik Gkountas; owner: Nik Gkountas):
[mediawiki/extensions/ContentTranslation@master] SX Pick a sentence: Disable all links inside section content

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

Change 662929 merged by jenkins-bot:
[mediawiki/extensions/ContentTranslation@master] SX Pick a sentence: Disable all links inside section content

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

Jpita subscribed.

Clicking on an image should select their caption text for translation.
NOT DONE, clicking an image does not select the caption for translation.

If that is complex to support, at least prevent the outside navigation
DONE

@Pginer-WMF is this ok?

Clicking on an image should select their caption text for translation.
NOT DONE, clicking an image does not select the caption for translation.

If that is complex to support, at least prevent the outside navigation
DONE

@Pginer-WMF is this ok?

Yes. The main issue is solved. I created a separate ticket for the caption selection (T274845), but set it as low priority since it is not expected to block the main workflow.