← Back to release summary

Throw exception for popovers/dialogs in non-active documents

Category
DOM
Type
No developer-visible change
Status
Enabled by default (Chrome 132)
Intent stage
None

Summary

This is a corner case change that hopefully does not impact developers. Previously calling `showPopover()` or `showModal()` on a popover or dialog that resides within an inactive document would silently fail. I.e. no exception would be thrown, but since the document is inactive, no popover or dialog would be shown. As of the https://github.com/whatwg/html/pull/10705 spec PR, these situations now throw InvalidStateError.

Standards & signals

View on chromestatus.com