Deleting a specific style name float for ie8 (#9311)

* Deleting a specific style name float for ie8

* Remove unnecessary condition
This commit is contained in:
Andrey Marchenko
2017-04-01 01:31:52 +03:00
committed by Dan Abramov
parent 6fd539ec66
commit d9915db43b
@@ -30,7 +30,6 @@ var processStyleName = memoizeStringOnly(function(styleName) {
});
var hasShorthandPropertyBug = false;
var styleFloatAccessor = 'cssFloat';
if (ExecutionEnvironment.canUseDOM) {
var tempStyle = document.createElement('div').style;
try {
@@ -39,10 +38,6 @@ if (ExecutionEnvironment.canUseDOM) {
} catch (e) {
hasShorthandPropertyBug = true;
}
// IE8 only supports accessing cssFloat (standard) as styleFloat
if (document.documentElement.style.cssFloat === undefined) {
styleFloatAccessor = 'styleFloat';
}
}
if (__DEV__) {
@@ -215,8 +210,8 @@ var CSSPropertyOperations = {
styles[styleName],
component,
);
if (styleName === 'float' || styleName === 'cssFloat') {
styleName = styleFloatAccessor;
if (styleName === 'float') {
styleName = 'cssFloat';
}
if (styleValue) {
style[styleName] = styleValue;