Page MenuHomePhabricator

[Bug] toast messages not visible in overlays - errors caused by talk overlay are not visible
Closed, ResolvedPublic5 Estimated Story Points

Description

Currently when an error is thrown by the talk overlay it is displayed as a "toast error"

Given toasts are currently positioned below the overlay, these errors are not visible to the user so the error is not visible and the editor has no idea there has been a problem.

Developer notes

If I manually make the overlay opaque (for debugging purposes only) I can see that the toast is present but hidden under the overlay:

Screen Shot 2018-08-21 at 3.50.43 PM.png (774×612 px, 107 KB)

Currently the mw-notification-area is inserted inside #content
If this area is instead added as a child of the body element this seems to work just as well.

Acceptance criteria

  • Make sure the mw-notification-area element appears above overlays either via z-index or adjustments to the DOM

Testing criteria

  1. Visit https://reading-web-staging.wmflabs.org/wiki/Sandwich
  2. Login
  3. Open talk overlay and click "I like sandwiches"
  4. Drop internet connection
  5. Type yes in reply box and hit save
  6. Confirm you see a toast message above the talk overlay saying the error failed to save.

Event Timeline

ovasileva triaged this task as Medium priority.Aug 22 2018, 8:52 AM
ovasileva subscribed.

@Jdlrobson - I'm not sure I'm following entirely here. What is the opaqueness for?

Jdlrobson renamed this task from [Bug] Errors caused by talk overlay are not visible to [Bug] toast messages not visible in overlays - errors caused by talk overlay are not visible.Aug 28 2018, 3:09 PM
Jdlrobson moved this task from Triaged but Future to Upcoming on the Web-Team-Backlog board.
ovasileva set the point value for this task to 5.Aug 28 2018, 4:29 PM

We could update the code in core to look for an existing #mw-notification-area before creating a new one - this would give a skin the option to set a designated container.

Change 456665 had a related patch set uploaded (by Esanders; owner: Esanders):
[mediawiki/skins/MinervaNeue@master] Add a notifications overlay container to the skin

https://gerrit.wikimedia.org/r/456665

Yup both of those patches are dupes!

Pulling into sprint for visibility and for us to assist with code review!

Change 306560 had a related patch set uploaded (by Jdlrobson; owner: Mooeypoo):
[mediawiki/core@master] Allow skins to place notification container for mw.notify

https://gerrit.wikimedia.org/r/306560

Change 306560 merged by jenkins-bot:
[mediawiki/core@master] Allow skins to place notification container for mw.notify

https://gerrit.wikimedia.org/r/306560

Change 456665 merged by jenkins-bot:
[mediawiki/skins/MinervaNeue@master] Add a notifications overlay container to the skin

https://gerrit.wikimedia.org/r/456665

toasts are now there!