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

Differentiate 'Copy' and 'Copy styles' snackbar confirmation messages #57254

Open
afercia opened this issue Dec 20, 2023 · 4 comments
Open

Differentiate 'Copy' and 'Copy styles' snackbar confirmation messages #57254

afercia opened this issue Dec 20, 2023 · 4 comments
Labels
[Package] Block editor /packages/block-editor [Type] Bug An existing feature does not function as intended

Comments

@afercia
Copy link
Contributor

afercia commented Dec 20, 2023

Description

WHen copying a block and when copying a block styles, a snackbar notice appears with a confirmation message. The confirmation message text is the same in both cases:

`Copied {block name} to clipboard'

when copying styles of multiple blocks:

'Copied {n} blocks to clipboard'

For better clarity and better user experience, the copy stiles operation should use its own confirmation message, something along the lines of:

`Copied block styles to clipboard' and 'Copied {n} blocks styles to clipboard'

Step-by-step reproduction instructions

  • Go to the post editor and select a paragraph.
  • Frorm the block toolbar > Options dropdown menu, click 'Copy' and then click 'Copy styles'.
  • Observe two snackbar notices appear with the same text.

Screenshots, screen recording, code snippet

Snackbars notices with the same text after 'Copy' and then click 'Copy styles':

copy block styles

Copy styles with multiple block selected:

copy styles multiple

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 [Package] Block editor /packages/block-editor labels Dec 20, 2023
@t-hamano
Copy link
Contributor

t-hamano commented Dec 20, 2023

Actually, copying styles is internally the same as copying the block itself 😅 Therefore, I proposed in #55611 to remove the "Copy Styles" action itself.

@richtabor
Copy link
Member

Actually, copying styles is internally the same as copying the block itself 😅 Therefore, I proposed in #55611 to remove the "Copy Styles" action itself.

If we remove copy styles from the menu, no one will know it's possible.

@richtabor
Copy link
Member

For better clarity and better user experience, the copy stiles operation should use its own confirmation message, something along the lines of:

`Copied block styles to clipboard' and 'Copied {n} blocks styles to clipboard'

You can't actually copy styles of more than one block. It's limited to one at a time.

CleanShot 2024-02-05 at 11 05 02

@richtabor
Copy link
Member

For better clarity and better user experience, the copy stiles operation should use its own confirmation message, something along the lines of:

I think it'll be nice having a more relevant message, even simpler and more direct: "Styles copied to clipboard."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] Block editor /packages/block-editor [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

No branches or pull requests

3 participants