Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Site Editor: 'Delete page' button should be 'Move to trash' #52639

Closed
afercia opened this issue Jul 14, 2023 · 1 comment · Fixed by #52641
Closed

Site Editor: 'Delete page' button should be 'Move to trash' #52639

afercia opened this issue Jul 14, 2023 · 1 comment · Fixed by #52641
Assignees
Labels
[Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Package] Edit Site /packages/edit-site [Type] Bug An existing feature does not function as intended

Comments

@afercia
Copy link
Contributor

afercia commented Jul 14, 2023

Description

In the Site Editor > Pages > any page, clicking the 'Actions' ellipsis menu reveals a dropdown menu with a 'Delete' button.

Screenshot 2023-07-14 at 14 43 27

Clicking this button opens a confirm dialog with the text:

Are you sure you want to delete this page?

followed by two buttons: Cancel and Delete.

Screenshot 2023-07-14 at 14 44 08

Everything in the UI uses the term 'delete'. As a user, I'd think the page is going to be permanently deleted.

Instead, the page gets moved to the Trash. This is a good thing and it's how WordPress always worked. However, the UI is just wrong as it hints to a delete action, while the actual action is moving to trash.

  • The text of the button in the dropdown menu should be 'Move to trash' instead of 'Delete'.
  • The confirm dialog is redundant. In WordPress, the 'move to trash' action never showed a confirm dialog as it is not a destructive action. Items can be restored from the Trash at any time.

I'm going to add also the Accessibility label because any UI control should always clearly identify the associated action.

Step-by-step reproduction instructions

  • Go to Site Editor > Pages > any page
  • In the navigator panel, click the 'Actions ellipsis button, then click 'Delete'.
  • A modal dialog opens, asking confirmation. Click Delete.
  • The page disappears and the editor navigator panel goes back to the 'Pages' list.
  • Go to the WP admin > Pages > Trash at /wp-admin/edit.php?post_status=trash&post_type=page
  • Observe the 'deleted' page isn't actually deleted. It's there in the Trash.

Screenshots, screen recording, code snippet

No response

Environment info

No response

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

@afercia afercia added [Type] Bug An existing feature does not function as intended [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Package] Edit Site /packages/edit-site labels Jul 14, 2023
@afercia afercia self-assigned this Jul 14, 2023
@afercia
Copy link
Contributor Author

afercia commented Jul 14, 2023

More wording needs to be changed, including the snackbar notice:

Screenshot 2023-07-14 at 15 25 24

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Package] Edit Site /packages/edit-site [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants