Description
Generally MW links are never target=_blank, so they will often try to open in the same tab. This means that when accidentally clicked, editors might lose any unsaved changes.
In Wikifunctions, we track the page-wide dirty state (are there any unsaved changes) and, when clicking an outgoing link or trying to close or exit the window, we show a Leave dialog:
We can use the same dialog, and the state is already been tracked, so store.isDirty can be used the same way in AW than in Wikifunctions.
Desired behavior/Acceptance criteria
- While editing Abstract Content and there are unsaved changes, any exit attempt will be followed by an explicit prompt to the user that prevents accidental loss of work
Completion checklist
- Before closing this task, review one by one the checklist available here: https://www.mediawiki.org/wiki/Abstract_Wikipedia_team/Definition_of_Done#Front-end_Task/Bug_Completion_Checklist
