Bug 299669

Summary: elements with a custom customElementRegistry can fail to upgrade
Product: WebKit Reporter: Steve Orvell <steveorvell>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: NEW    
Severity: Normal CC: 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-27 13:17:48 PDT
If an element is created with a constructed customElementRegistry, then connected to the document, then defined in its registry, it fails to upgrade. It remains un-upgraded even if `el.customElementRegistry.upgrade(el)` is called. However, if the element is defined *before* being connected, it upgrades successfully. See reproduction: https://codepen.io/Steve-Orvell/pen/GgooEqG?editors=1000
Attachments
Radar WebKit Bug Importer
Comment 1 2025-10-04 13:18:10 PDT
Radar WebKit Bug Importer
Comment 2 2025-10-04 13:18:10 PDT
Note You need to log in before you can comment on or make changes to this bug.