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

Toast appears in background of native html modal (Dialog element) #42

Open
NatumanyaGuy opened this issue Jun 29, 2023 · 8 comments
Open

Comments

@NatumanyaGuy
Copy link

I'm experiencing an issue with svelte-french-toast. When I use the Dialog element (modal), it appears to be positioned behind the dialog instead of on top of it. I suspect that it might be related to the Z-Index. Is there a way it can be resolved?

@jeffreycharters
Copy link

I've come up against this as well.

I think that the modal dialog actual gets pulled up in the DOM to the top layer. I don't have a solution, but I believe that's the cause.

@jorri11
Copy link

jorri11 commented Oct 27, 2023

I have encountered this issue as well, as far as i understand svelte-french toast would have to be changed to be in the topLayer. Something in the topLayer would not be affected by z-index

@paulando
Copy link

We have encountered the same issue. Has anyone come across a solution or workaround for this problem? Any shared insights or updates would be greatly appreciated.

@yuki0418
Copy link

Maybe popover attribute can help to move a toaster to top layer?
https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/popover

@jorri11
Copy link

jorri11 commented Jan 10, 2024

I am a bit unsure if that would help, im not familiar with the popover api. Seems like its browser dependent if the popover appears in the top layer(?)

@jeffreycharters
Copy link

I just gave up and used a Melt-UI modal instead and it worked fine and should still be accessible.

@jorri11
Copy link

jorri11 commented Jan 10, 2024

Yeah thats what im considering too

@peter9294
Copy link

My workaround is to put one more <Toaster/> within dialog itself and it works fine.

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

No branches or pull requests

6 participants