Automattic / newspack-plugin

An advanced open-source publishing and revenue-generating platform for news organizations.
https://newspack.com
GNU General Public License v2.0
328 stars 49 forks source link

"Above-header" error message component gets easily lost #1441

Open dkoo opened 2 years ago

dkoo commented 2 years ago

Is your feature request related to a problem? Please describe. As @miguelpeixe and I were discussing in #1424, the wizard's error message component that appears at the very top of the wizard gets visually lost very easily:

Screen Shot 2022-01-12 at 5 08 01 PM

Describe the solution you'd like Ideally, error messages should be shown in a prominent location near the point of interaction that triggered the error, or in an unmissable place (like in a modal overlay). Can we establish a new standard style/location for error messages in wizard pages?

thomasguillot commented 2 years ago

Agreed. We should keep the "error" message at the top only for newspack debug

Screenshot 2022-01-17 at 16 07 20

in fact, we could probably redesign the debug warning

Screenshot 2022-01-17 at 16 15 10

dkoo commented 2 years ago

I dig the new design in your second screenshot! Although, it still might get lost on screens with a lot of vertical scroll (e.g. the Site Design wizard). Should we consider showing it directly above the "cancel"/"save" buttons so it's close to the point of interaction?

adekbadek commented 2 years ago

Another idea – "toaster" overlay messaging. Surely won't get lost. Edit: as @thomasguillot suggested, Gutenberg offers the Snackbar component

thomasguillot commented 2 years ago

The Snackbar component doesn't seem reliable outside of the editor at the moment.

Might be worth creating our own light Toaster/Snackbar component.

thomasguillot commented 2 years ago

Let's use a toaster component and I can style it like the snackbar.