v3/examples/web-apis/dialog/frontend/index.html
The HTML <dialog> element provides a native way to create modal and non-modal dialog boxes, with built-in accessibility features and backdrop handling.
Dialog Element API: checking...
Modal dialogs block interaction with the rest of the page:
Open Modal Dialog
Last action:
Non-modal dialogs allow interaction with the page:
Open Non-Modal DialogClose Non-Modal
A custom confirm dialog that returns user choice:
Show Confirm Dialog
User choice:
Dialog with form that uses method="dialog":
Open Form Dialog
Form data:
Different styled dialogs for various purposes:
Success AlertWarning AlertError AlertInfo Alert
Multiple dialogs can be stacked:
Open First Dialog
Clear Log Dialog events will appear here...
×
This is a modal dialog. The backdrop prevents interaction with the page behind it.
Press Escape or click outside to close (if enabled).
CancelOK
×
This dialog allows interaction with the page behind it.
You can still click buttons and scroll the page.
×
Are you sure you want to proceed with this action?
This action may have consequences.
No, CancelYes, Proceed
×
Name
RoleDeveloperDesignerManagerOther
Message
CancelSubmit
×
Alert message
OK
×
This is the first dialog in the stack.
Click the button below to open another dialog on top.
CloseOpen Second Dialog
×
This is the second dialog, stacked on top of the first.
You can stack as many dialogs as needed.
CloseOpen Third Dialog
×
This is the third and final dialog in the stack.
Close dialogs in reverse order by pressing Escape or clicking Close.
Close