-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Closed
Description
Describe the bug
If an SVG element (ex. <circle>
) is placed within a <slot>
as the fallback, the element is not visible, even though the markup is correct.
<slot>
<circle cx={10} cy={10} r={5} />
<circle cx={20} cy={20} r={5} />
<circle cx={30} cy={30} r={5} />
<circle cx={40} cy={40} r={5} />
<circle cx={50} cy={50} r={5} />
</slot>
Removing the <slot>
wrapper or adding <svelte:options namespace="svg" />
at the top of the component works around the issue.
This is likely due to the element being created with document.createElement("circle")
instead of
document.createElementNS("http://www.w3.org/2000/svg", "circle");
.
Related issue: #11219
Reproduction
Logs
No response
System Info
Svelte 5 REPL
Severity
blocking an upgrade
Metadata
Metadata
Assignees
Labels
No labels