Automattic / wp-calypso

The JavaScript and API powered WordPress.com
https://developer.wordpress.com
GNU General Public License v2.0
12.41k stars 1.99k forks source link

Business Hours Block - Undo action when editing business block takes user to previous block instead of Undoing changes of current block #52502

Open sowmya2709 opened 3 years ago

sowmya2709 commented 3 years ago

Business Hours Block - Undo action when editing business block takes the user to the previous block instead of Undoing changes of the current block

Steps to reproduce the behavior

  1. Go to WordPress editor
  2. Add business block
  3. Edit the business block
  4. Click on Add hours and add some value in the new hours' field
  5. Click Undo/Back arrow on the top menu bar of the page

What I expected to happen

I expect my last changes to be reverted

What actually happened

Instead of reverting the changes within the business block, the control goes to the previous operation/previous block that I was working on Note: This happens for any block that I am editing, the control goes back to the previous block, undoing all the changes to the block. Not just reverting previous change

Browser / OS version - Chrome/MacOS

Reproducibility (Consistent, Intermittent) Leave empty for consistent.

Screenshot / Video: If applicable, add screenshots to help explain your problem.

https://www.loom.com/share/275995374b8944aeb30906058e8460a2

Rolilink commented 2 years ago

This is also happening to me, but this seems to only happen if the hour input is not completed like in the video. When I do add the AM/PM to the input it behaves perfectly fine!.