Bug 220903
| Summary: | SVG inside <img> does not scale contents with respect to screen width or height | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Jeffrey <jeffreyca16> |
| Component: | SVG | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW | ||
| Severity: | Major | CC: | sabouhallawa, simon.fraser, smoley, webkit-bug-importer, zalan, zimmermann |
| Priority: | P2 | Keywords: | InRadar |
| Version: | Safari 14 | ||
| Hardware: | All | ||
| OS: | All | ||
Jeffrey
Codepen: https://codepen.io/JeffreyCA/pen/abmgBze
Open the above snippet on a Mac and then resize the Safari window width until it's less than the width of the SVG.
Observed:
Notice how the background/borders do scale properly, but the contents (text, images) are not scaled. They are instead truncated by the borders of the SVG.
Expected:
The entire SVG (including text, images, background/borders) should be scaled against the window width.
Other browsers:
Both Chrome and Firefox perform scaling as expected.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Smoley
Thanks for filing, I'm seeing this issue on Safari 13.1.3 and STP118.
Radar WebKit Bug Importer
<rdar://problem/73688284>