Bug 311746

Summary: requestClose() on a disconnected dialog removes open attribute
Product: WebKit Reporter: Luke Warlow <lwarlow>
Component: DOMAssignee: Luke Warlow <lwarlow>
Status: RESOLVED FIXED    
Severity: Normal CC: karlcow, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Local Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://github.com/web-platform-tests/wpt/pull/59877

Luke Warlow
Reported 2026-04-08 12:02:33 PDT
Per the spec requestClose() should early return if the dialog it's called on is disconnected, or it's document is inactive. `data:text/html,<script>const dialog = document.createElement('dialog'); dialog.setAttribute('open', ''); dialog.requestClose(); alert(dialog.open);</script>` This should alert with true like in Chromium and Firefox.
Attachments
Radar WebKit Bug Importer
Comment 1 2026-04-15 12:03:12 PDT
Luke Warlow
Comment 2 2026-05-14 02:12:27 PDT
EWS
Comment 3 2026-05-14 09:12:50 PDT
Committed 313251@main (c7342e9519e4): <https://commits.webkit.org/313251@main> Reviewed commits have been landed. Closing PR #64919 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.