-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
[BUG] Toasts - Autohide does not work #2289
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
Comments
Hmm. tabler/shared/includes/ui/toast.html Line 4 in 78c9c71
and visiting /toasts.html in the browser after rebuilding the preview.Clicking on the 'Simple toast' example caused the toast to hide after a few seconds. Not sure what might be different for you yet though. |
@rubensrocha does the toast also not hide if you remove all references of |
I downloaded version 1.2.0 from the Releases section, but there were some issues, so I simply copied the css and js directly from the demo and applied it to my Laravel project. I did all the template integration and everything worked fine until I got to the Toast integration, which as I explained before, doesn't close automatically for some reason I don't know. With or without data-bs-autohide it still doesn't close automatically, so my "temporary" solution was to use the SweetAlert2 library, at least until I figure out what the problem with Toast is. |
An interesting conundrum to be sure. Not that I expect any, but are there any developer console errors? |
No console errors. I made a small example here using the code from the documentation(Installation - Step 2 and Toasts - Stacking toasts), and it still doesn't work as expected. |
I've no idea really what's going on here sorry... perhaps @codecalm might be able to shed some light at some point 🤞 |
Hi all, I made an experiment, it looks like autohide mechanism works only when toast was triggered programmatically. Here is my example based on https://tabler.io/admin-template/preview:
generally what i noticed is that autohide mechanism not work when toast is showed instant, so if class |
Ah, yes. @rubensrocha - @mikosamuraj hit the nail on the head here. It looks like it all depends on the |
Browser
Chrome and Brave
OS
Linux Mint
Screen size
1920x1080
Describe the bug
I copied the example from the documentation, just modifying the
data-bs-autohide="true"
attribute, but even so the notification box does not close automatically.Ref: https://docs.tabler.io/ui/components/toasts
Version: 1.2.0
Code:
How to reproduce
...
Screenshots
No response
JSFiddle
No response
The text was updated successfully, but these errors were encountered: