Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
gradient detection requires old gradient syntax #1621
As reported in https://bugzilla.mozilla.org/show_bug.cgi?id=1176496#c22 , Modernizr's gradient detection depends on the old gradient syntax. Its attempt to detect unprefixed gradients fails because it's testing legacy syntax that's only supported in prefixed form. This means that if browsers ever remove prefixed gradients (which is seeming increasingly unlikely due to things like this), Modernizr will report that gradients are not supported.
Gradient syntax is described in https://drafts.csswg.org/css-images/#linear-gradients , and requires "to left top" rather than just "left top" in https://github.com/Modernizr/Modernizr/blob/master/feature-detects/css/gradients.js#L29