welsonjs/node_modules/modernizr/feature-detects/css/transforms.js

17 lines
485 B
JavaScript

/*!
{
"name": "CSS Transforms",
"property": "csstransforms",
"caniuse": "transforms2d",
"tags": ["css"]
}
!*/
define(['Modernizr', 'testAllProps'], function(Modernizr, testAllProps) {
Modernizr.addTest('csstransforms', function() {
// Android < 3.0 is buggy, so we sniff and reject it
// https://github.com/Modernizr/Modernizr/issues/903
return navigator.userAgent.indexOf('Android 2.') === -1 &&
testAllProps('transform', 'scale(1)', true);
});
});