-
Notifications
You must be signed in to change notification settings - Fork 121
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
generalize error/success message state #799
Comments
I had actually partly started work on that on #774. One of the problems we had was that the header, sidebar and snackbar components were replicated on every page instead of being set on a single unified layout. We had a couple of commits/PRs refactoring those out of individual views (#774 is the latest). Moving the snackbar out of the header, it will be possible to collapse all those error states into a single error notification queue. |
I like the direction of this proposal, though I think it should be coordinated with @go1dfish's current work refactoring the actions. So I'd start with doing a PoC on a set of actions that has already been merged, then if we like it we can apply the same changes to the rest. |
ack |
IMO, the way forward for this is to go to the new snackbar reducer (https://github.com/decred/decrediton/blob/master/app/reducers/snackbar.js) and replace every *error/*success state that is only a message (not, say a disabled control) with a snackbar message. We can then style all messages appropriately. |
this is exactly what I had in mind @matheusd 👍 |
currently, the global app state is gigantic and a large portion of it is in the control object:
I propose we refactor this to simply:
This will dramatically reduce the overhead in the props we're passing around to our page headers.
The text was updated successfully, but these errors were encountered: