- From: Divyansh Mangal via GitHub <noreply@w3.org>
- Date: Wed, 04 Feb 2026 06:48:01 +0000
- To: public-svg-issues@w3.org
goldenboy777 has just labeled an issue for https://github.com/w3c/svgwg as "Agenda+":
== Should `width` and `height` apply to nested `svg` elements as CSS properties ==
Chromium shipped support in M141 for applying `width` and `height` as presentation attributes on nested `svg` elements, aligning Chrome’s behavior with the SVG 2 [specification](https://svgwg.org/svg2-draft/geometry.html#Sizing).
Chromestatus entry: https://chromestatus.com/feature/5178789386256384.
As part of this change, CSS properties such as `width` and `height` now correctly affect nested `svg` elements, making the following two examples render identically:
```
With CSS Properties for nested <svg> element:
<svg width="100px" height="100px">
<svg style="width:50px;height:50px;">
<circle cx="50px" cy="50px" r="40px" fill="green" />
</svg>
</svg>
```
```
Without CSS Properties for nested <svg> element:
<svg width="100px" height="100px">
<svg width="50px" height="50px">
<circle cx="50px" cy="50px" r="40px" fill="green" />
</svg>
</svg>
```
However, shortly after launch, users began reporting breakages on their sites[ User reports of a svg size regression [449170647] - Chromium](https://issues.chromium.org/issues/449170647). Many of these pages were relying on incorrect or previously-ignored styling, and once the feature took effect, those styles suddenly applied and caused layout regressions.
**From an inter op perspective, Firefox and Safari** don't support applying CSS properties `width` and `height` to nested `svg` already.
https://github.com/mozilla/standards-positions/issues/1243
https://github.com/WebKit/standards-positions/issues/509
Based on the breakage observed and the UseCounter data https://chromestatus.com/metrics/feature/timeline/popularity/5677, it's fair to say if width and height started applying on nested `svg` it can cause significant web compatibility issues (layout regressions to be precise).
**In that case should we explicitly mention this behaviour in the spec or should an opt-in mechanism be adapted for this feature?**
See https://github.com/w3c/svgwg/issues/1057
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 4 February 2026 06:48:02 UTC