magento / magento2-page-builder

Magento2 PageBuilder
Other
80 stars 62 forks source link

When accidentally triggering a "back" action in browser history, display a confirmation message if the user truly wanted to navigation to the previous page in their history. #790

Open Danielvandervelden opened 3 years ago

Danielvandervelden commented 3 years ago

I encountered this issue when I was building a very extensive page using the page builder. Currently, I work on a Macbook, and as you might know swiping causes certain actions to happen (same goes for the magic mouse). Unfortunately, nearing the completion of the page I accidentally performed the "back" action, which caused me to go to the previous page in my browser history. I unfortunately, lost all my work.

Description (*)

A confirmation popup if the user truly meant to go to the previous page in their browser history.

Expected behavior (*)

Whenever a user has the pagebuilder active, on the "beforeunload" event, show a popup for the user to confirm if they truly wanted to navigate away from the current page.

Benefits

You would not lose an hour's work if you don't save your page a few times while working on it.

Additional information

m2-assistant[bot] commented 3 years ago

Hi @Danielvandervelden. Thank you for your report. To speed up processing of this issue, make sure that you provided sufficient information.

Add a comment to assign the issue: @magento I am working on this