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

Expose snackbar timer in order to allow customization #588

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

delijah
Copy link

@delijah delijah commented Nov 14, 2023

This PR makes it possible to add a progress bar which indicates the timers progress (in your customized version of the snackbar). In order to achieve that, we've moved all the timer related stuff into a separate hook, which will be exposed, and we've added a config option called disableAutoHideTimer, which disables the internal timer (which enables us to use it then in the customized component). A nice side effect is, that the Snackbar component is freed of all the timer logic.

If you have any questions or considerations please reach out.

I feel like this could deserve an example or docs, but i don't know how to add it.

This is how it can be used in the customized snackbar:

Screenshot 2023-11-14 at 01 19 09

@delijah
Copy link
Author

delijah commented Nov 21, 2023

@iamhosseindhv Let me know if you need more infos/work from my side to proceed 🙏

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

Successfully merging this pull request may close these issues.

1 participant