41 lines
1.0 KiB
JavaScript
41 lines
1.0 KiB
JavaScript
"use strict";
|
|
|
|
/**
|
|
* Copyright (c) 2013-present, Facebook, Inc.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*
|
|
*/
|
|
var getVendorPrefixedName = require("./getVendorPrefixedName");
|
|
|
|
var BrowserSupportCore = {
|
|
/**
|
|
* @return {bool} True if browser supports css animations.
|
|
*/
|
|
hasCSSAnimations: function hasCSSAnimations() {
|
|
return !!getVendorPrefixedName('animationName');
|
|
},
|
|
|
|
/**
|
|
* @return {bool} True if browser supports css transforms.
|
|
*/
|
|
hasCSSTransforms: function hasCSSTransforms() {
|
|
return !!getVendorPrefixedName('transform');
|
|
},
|
|
|
|
/**
|
|
* @return {bool} True if browser supports css 3d transforms.
|
|
*/
|
|
hasCSS3DTransforms: function hasCSS3DTransforms() {
|
|
return !!getVendorPrefixedName('perspective');
|
|
},
|
|
|
|
/**
|
|
* @return {bool} True if browser supports css transitions.
|
|
*/
|
|
hasCSSTransitions: function hasCSSTransitions() {
|
|
return !!getVendorPrefixedName('transition');
|
|
}
|
|
};
|
|
module.exports = BrowserSupportCore; |