Bug 247298
| Summary: | Don't apply aspect ratio scaling to gradient images without a natural aspect ratio | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Matt Woodrow <mattwoodrow> |
| Component: | Layout and Rendering | Assignee: | Matt Woodrow <mattwoodrow> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | bfulgham, simon.fraser, webkit-bug-importer, zalan |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
Matt Woodrow
If we use a gradient as a background image, and set one of the background size dimension to auto, we currently scale that dimension by the same amount as the other axis to preserve the aspect ratio.
Gradients have no natural dimensions (and thus no natural aspect ratio) - https://w3c.github.io/csswg-drafts/css-images/#gradients.
Background sizing should fall back to using 100% (for the case where we have one size, and auto), if there's no natural aspect ratio or dimensions - https://w3c.github.io/csswg-drafts/css-backgrounds/#background-size
<rdar://101661731>
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Matt Woodrow
Pull request: https://github.com/WebKit/WebKit/pull/5987
EWS
Committed 256256@main (759576401a3d): <https://commits.webkit.org/256256@main>
Reviewed commits have been landed. Closing PR #5987 and removing active labels.