Steps to replicate the issue (include links if applicable):
- file that relies on defaults shows an all red background: https://upload.wikimedia.org/wikipedia/commons/archive/b/bd/20220902193021%21Test.svg
- the relevant SVG is
<linearGradient id="lgback" gradientUnits="userSpaceOnUse"> <stop offset="0%" stop-color="white" /> <stop offset="100%" stop-color="red" /> </linearGradient> <rect width="100%" height="100%" fill="url(#lgback)" />
- file that explicitly specifies the default values works: https://commons.wikimedia.org/wiki/File:SVG_Test_dim_filter_mask.svg
<linearGradient id="lgback" gradientUnits="userSpaceOnUse" x1="0%" x2="100%" y1="0%" y2="0%"> <stop offset="0%" stop-color="white" /> <stop offset="100%" stop-color="red" /> </linearGradient>
What happens?:
The rectangle displayed solid red rather than a gradient.
What should have happened instead?:
The SVG 1.1 specification says that x1, y1, x2, and y2 default to those values.
See https://www.w3.org/Graphics/SVG/1.1/pservers.html#LinearGradients
A white-to-red gradient should have displayed.
Since red showed, some gradient information was recognized.
It is possible that x1 defaulted to 0 and x2 defaulted to 1 (factors that work for objectBoundingBox).
Software version (skip for WMF-hosted wikis like Wikipedia):
Other information (browser name/version, screenshots, etc.):