-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
New Block: Dialog Popup #61297
Comments
I am thinking this plugin is something to take a closer look at: I found out about the plugin as the author mentioned it in the Advanced WordPress Facebook group here: Here are some of the things the author wrote: "...to provide a block which would be close to core blocks and give users options which they often need. I started this block when dialog element was very new, I am planning to switch to dialog element." |
I'm finalizing a set of CleanShot.2024-10-31.at.21.40.25.mp4 |
I will ping a few folks so they can give feedback. |
I would love to see more Core blocks that leverage the Interactivity API! 🙂 That said, with dialogs there are a11y concerns that I'm not an expert on. I don't have a strong opinion on whether this should be in Core or is more of a plugin territory but perhaps @WordPress/gutenberg-core does. |
Would this offer a good enough experience to be preffered to full blown modals? |
I think this is more for @mtias or @jasmussen to decide, but I agree that exploring a dialog/pop-up block in Core makes sense.
What do you mean by full blown modals? |
I mean modal windwos and dialogs are provided by plugins generally and they generally use libraries with specifics implemented. I wonder how much we need to pad the support for the html element to make it useful and if we support all the stuff that make it work right. |
Hi all, I'm putting some final touches on this vis-a-vis accessibility on the "dialog trigger" block this week and I'm hoping to submit a PR to start a more in depth review discussion early next week. I've tried to add as much support for the native @draganescu Regarding support for other plugins, absolutely, that's been a key consideration in our design. Our first major use of this block will actually be programmatically generated dialog blocks in an upcoming project. So, getting extensibility right was key for even our own use-case. As for other plugins interacting with the dialog block(s): For starters open and closing a dialog is as easy as We also have some additional functionality that will play or pause any VideoPress video inside a dialog when opening and closing. I'm going to pull that out before submitting the PR, but I'll provide a code example for how a video player block can easily opt-in to the dialog block's interactivity store to support an open/play close/pause interaction. |
What problem does this address?
Popups are very common for websites, and its a common request.
What is your proposed solution?
Creating a new block for popups using the dialog html element:
https://www.youtube.com/watch?v=ywtkJkxJsdg
The text was updated successfully, but these errors were encountered: