Page MenuHomePhabricator

Unsaved changes dialog shows up twice on mobile
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • Edit any page
  • Abandon your edit
  • Leave the page you were editing

What happens?: I am prompted twice: once when I abandon the edit and once when I leave the page I was editing

What should have happened instead?: I should only have been prompted when I abandon the edit

Other information (browser name/version, screenshots, etc.): Chrome for Android v104 on Android 12

T310737.jpg (1×1 px, 264 KB)

Event Timeline

Lomrjyo renamed this task from Unsaved changes dialog shows up twice to Unsaved changes dialog shows up twice on mobile.Aug 7 2022, 6:03 PM

I can reproduce. The issue only occurs when using the wikitext editor.

First warning is an OOUI dialog:

image.png (2×3 px, 414 KB)

Second warning is a browser popup:

image.png (2×3 px, 1015 KB)

Change 821315 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/MobileFrontend@master] EditorOverlayBase: Fix undefined variable when disabling warning about unsaved changes

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

Change 821316 had a related patch set uploaded (by Bartosz Dziewoński; author: Bartosz Dziewoński):

[mediawiki/extensions/MobileFrontend@master] Disallow using the `self` global variable

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

Change 821315 merged by jenkins-bot:

[mediawiki/extensions/MobileFrontend@master] EditorOverlayBase: Fix failing to clear warning about unsaved changes

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

Change 821316 merged by jenkins-bot:

[mediawiki/extensions/MobileFrontend@master] Disallow using the `self` global variable

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