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

Error messages are not removed when changing page #66

Open
Azaret opened this issue Mar 12, 2018 · 4 comments
Open

Error messages are not removed when changing page #66

Azaret opened this issue Mar 12, 2018 · 4 comments

Comments

@Azaret
Copy link
Contributor

Azaret commented Mar 12, 2018

Easy step to reproduce:

  • Go to live event page
  • Go to event list page

What happens: No event live error message is shown when going to the event list page.
Expected: Error message should hide when changing page.

@WilliamDASILVA
Copy link
Member

@Azaret The message disappears after a certain amount of time
Changing the page does not refresh nor reset any timer so, the best way should be just to reduce the amount time to avoid that I guess.
Detect the page transition just to hide this error message would be overkill I think.

@WilliamDASILVA
Copy link
Member

@Azaret By exploring the focus API, found this function clearMessages. Guess you could detect the page transitions to clear all the messages in the stack.

But still, not a big deal 😄

@Azaret
Copy link
Contributor Author

Azaret commented Mar 12, 2018

Figured that out, I'm just nit picky.
Definitively minor ;)

@Hartorn
Copy link
Collaborator

Hartorn commented Mar 13, 2018

I would say this is not a bug, messages are working based on duration, not on page.
That way, you can show a message, then navigate to another message (for example, inscription then go to event page with confirmation).

Maybe we could clean up errors though, using react-router hook onchange on base route.

Another idea would be to have a shorter ttl for the error message (that is configurable)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants