Bug 299603

Summary: elements created via parsing can customize with a null registry
Product: WebKit Reporter: Steve Orvell <steveorvell>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: NEW    
Severity: Normal CC: annevk, rniwa, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Safari 26   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 154907    

Steve Orvell
Reported 2025-09-26 06:52:27 PDT
When setting `innerHTML` or using `insertAdjacentHTML` on an element or shadowRoot with a customElementRegistry set to null, any custom element candidates in the parsed HTML should not customize based on step 7 of "parsing HTML fragments" (https://html.spec.whatwg.org/#parsing-html-fragments). However, they can customize in some cases which results in a customized custom element with a null customElementRegistry. See reproduction: https://codepen.io/Steve-Orvell/pen/RNrroxV?editors=1000
Attachments
Radar WebKit Bug Importer
Comment 1 2025-10-03 06:53:19 PDT
Radar WebKit Bug Importer
Comment 2 2025-10-03 06:53:22 PDT
Note You need to log in before you can comment on or make changes to this bug.