BKWLD / tram

Cross-browser CSS3 transitions in JavaScript.
186 stars 23 forks source link

Support CSS filters #7

Open danro opened 11 years ago

danro commented 11 years ago

cc @josephschmitt

Would need to add a feature detect for this, and implement a property class similar to Transform.

Feature detect from modernizr:

// https://github.com/Modernizr/Modernizr/issues/615
// documentMode is needed for false positives in oldIE, please see issue above
Modernizr.addTest('cssfilters', function() {
    var el = document.createElement('div');
    el.style.cssText = Modernizr._prefixes.join('filter' + ':blur(2px); ');
    return !!el.style.length && ((document.documentMode === undefined || document.documentMode > 9));
});;