Page MenuHomePhabricator

"Wikitext syntax highlighting" feature asks the user "confirm that you want to leave" after clicking on the text and not making changes
Closed, ResolvedPublic5 Story Points

Description

When I hit "edit" and then "back" - it goes back without asking.
But when I hit "edit", click with the mouse on the text, and then hit "back", it asks: "This page is asking you to confirm that you want to leave - data you have entered may not be saved.", as if I changed something.

It falsely detects the change when there is no change.

firefox-55.0.1

See also: (April 2015) T95150: CodeMirror should not ask confirmation when user leaves page that has no changes

Event Timeline

Yurivict created this task.Oct 1 2017, 6:58 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 1 2017, 6:58 PM

Yeah. This is somewhat annoying. When there is no change, then the editor should close without asking, as is the case without using CodeMIrror. Confirming this bug for Firefox+OWE.

Restricted Application added a project: Community-Tech. · View Herald TranscriptOct 25 2017, 9:38 AM
Niharika added a subscriber: Niharika.EditedOct 25 2017, 4:51 PM

I am doubtful that this is being caused by Wikitext Syntax Highlighting feature. Are you sure this doesn't happen without it being enabled?
Can you check on a different browser?

Vachovec1 added a comment.EditedOct 25 2017, 10:20 PM

I am doubtful that this is being caused by Wikitext Syntax Highlighting feature. Are you sure this doesn't happen without it being enabled?
Can you check on a different browser?

With Syntax Highlighting disabled, the editor closes immediately without confirmation dialog as expected (Firefox).

Tried with the Google Chrome - the same result.

FYI: I am not hitting "back" button, I am hitting the "Článek" (= Article/Page) bookmark on top of the page for the new load of the page in question.

Are you sure this doesn't happen without it being enabled?

Positive.

DannyH added a subscriber: DannyH.Nov 1 2017, 10:07 PM

I can confirm this. If you don't click in the text, then you only get the "are you sure" warning when you hit Article or Talk. If you click in the text, you get the warning in all situations (back button, close the tab, Article, Talk).

This only happens with syntax highlighting, doesn't happen without it.

kaldari set the point value for this task to 5.Nov 1 2017, 11:24 PM
Niharika triaged this task as Normal priority.Nov 7 2017, 11:21 PM
DannyH renamed this task from "Wikitext syntax highlighting" feature asks the user if he "want to leave" after he only clicks on the text and tries to go back to "Wikitext syntax highlighting" feature asks the user "confirm that you want to leave" after clicking on the text and not making changes.Nov 27 2017, 10:15 PM
MaxSem claimed this task.Dec 8 2017, 12:06 AM
MaxSem moved this task from Ready to In Development on the Community-Tech-Sprint board.
Quiddity updated the task description. (Show Details)Dec 8 2017, 12:15 AM

Change 397631 had a related patch set uploaded (by MaxSem; owner: MaxSem):
[mediawiki/extensions/CodeMirror@master] Fix content changed checks on unload

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

kaldari closed this task as Resolved.Dec 21 2017, 1:05 AM
kaldari moved this task from Needs Review/Feedback to Q1 2018-19 on the Community-Tech-Sprint board.
TBolliger moved this task from Estimated to Archive on the Community-Tech board.Jan 31 2018, 11:08 PM