Details
-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
16.10.13
-
None
-
Unknown
-
Description
Steps to reproduce, with Firefox (seen with Firefox 160):
- Edit a page with the realtime WYSIWYG editor (standalone edit mode), alone.
- Type some text, without saving.
- Leave the edit mode by clicking a link (e.g. in the breadcrumb).
- Use the browser's Back button to return to the edit mode.
Expected: the unsaved changes are restored, with the "Unsaved changes restored" notification, like when editing the page again from the view mode.
Actual: the "Failed to restore unsaved changes" warning is shown, the unsaved changes are not restored, and they are removed from the browser session storage.
Observations, from a diagnostic functional test on master (19.0.0-SNAPSHOT), with selenium/standalone-firefox:latest:
- Firefox doesn't keep the edit page in its back/forward cache (pagehide with persisted=false), so the edit page is loaded again from the history (back_forward navigation type), not restored.
- The unsaved changes are in the session storage when the edit page is left, and the restore is attempted when it is loaded again, but it fails.
- Editing the page again by opening the edit URL (instead of using Back) restores the unsaved changes as expected (RealtimeWYSIWYGEditorIT#restoreUnsavedChanges).
Not checked with other browsers going through a full page load on Back (Chrome keeps the page in its back/forward cache, see XWIKI-25826), nor on released versions; the unsaved changes restore was introduced by XWIKI-23141.
Attachments
Issue Links
- is related to
-
XWIKI-25826 Leaving the realtime editor doesn't leave the editing session when the browser keeps the page in its back/forward cache
-
- Open
-
-
XWIKI-23141 Fine-tune the realtime auto-save to prevent losing unsaved content
-
- Closed
-