Page MenuHomePhabricator

Adjust dialog shown when leaving an unsaved translation
Closed, ResolvedPublic

Description

When the user tries to leave a translation that has not been saved yet, a dialog is shown:

ig.m.wikipedia.org_w_index.php_title=Special_ContentTranslation&from=en&to=ig(iPhone SE).png (667×375 px, 98 KB)

Currently, the dialog text and options may not be providing the necessary details:

  • Saving mechanism. It is unclear why changes have not been saved, and what to do to get them saved.
  • Actions. After the user indicated their intent to go back, the "continue" option can be misinterpreted as the confirmation to go back, when it is cancelling the action and returning to editing.

This ticket proposes the following changes in the text and actions:

Leave your translation?

Changes have not been saved yet and will be lost.
You can continue editing for the changes to be automatically saved.

[Continue editing] [Discard changes]

  • The "Continue editing" action should use the "neutral" button style (instead of the "progressive" one used currently since the intent is to go "back" not progress forward).

Event Timeline

Pginer-WMF created this task.

Change 929995 had a related patch set uploaded (by Wangombe; author: Wangombe):

[mediawiki/extensions/ContentTranslation@master] SX: Improve dialog when leaving unsaved translation

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

Wangombe changed the task status from Open to In Progress.Jun 14 2023, 11:50 AM
Wangombe claimed this task.
Wangombe subscribed.

image.png (881×1 px, 119 KB)

Having You can continue editing for the changes to be automatically saved on a new line makes for a weird looking dialog as on the left. The screenshot on the right, seems reasonable.

@Pginer-WMF based on the above screenshots by Eugene, which do you think would be the preferable approach?

@Pginer-WMF based on the above screenshots by Eugene, which do you think would be the preferable approach?

Let's use the approach on the right without the line break.

Change 929995 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] SX: Improve dialog when leaving unsaved translation

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

Change 932684 had a related patch set uploaded (by Santhosh; author: Santhosh):

[mediawiki/extensions/ContentTranslation@master] CX3 Build 0.2.0+20230626

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

Change 932684 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] CX3 Build 0.2.0+20230626

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

As seen on test.wikipedia

image.png (985×446 px, 107 KB)