Closed Bug 1867163 Opened 2 years ago Closed 2 years ago

use href="#example" doesn't duplicate svg definition when in shadow root

Categories

(Core :: SVG, defect)

Firefox 122
defect

Tracking

()

RESOLVED DUPLICATE of bug 1866911

People

(Reporter: p-ob, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:122.0) Gecko/20100101 Firefox/122.0

Steps to reproduce:

  1. Use Firefox Nightly (122.0a1 (2023-11-28) (64-bit))
  2. Create a template with an svg defs with id "example"
  3. In the same template, reference the svg with <use href="#example" />
  4. Define a custom element, attach a shadow root, and clone template

A reproduction is accessible at the following Codepen: https://codepen.io/p-ob/pen/OJdoXJE. Opening in Chrome, Firefox (stable), Edge will work as expected.

Actual results:

The SVG didn't render

Expected results:

The SVG should render

The Bugbug bot thinks this bug should belong to the 'Core::SVG' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → SVG
Product: Firefox → Core
Status: UNCONFIRMED → RESOLVED
Closed: 2 years ago
Duplicate of bug: 1866911
Resolution: --- → DUPLICATE

Thanks for filing! This is fixed by bug 1866911, which was indeed a very recent regression.

Awesome, appreciate the quick response (and sorry for the duplicate). Thank you!

No worries, your test-case would've made it a lot easier to debug, if only I had seen it a bit earlier! :)

You need to log in before you can comment on or make changes to this bug.