mirror of
https://github.com/zoriya/react-native-web.git
synced 2026-06-04 11:04:58 +00:00
committed by
Nicolas Gallagher
parent
7ab04987f0
commit
4a70300b08
@@ -11,7 +11,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
import dangerousStyleValue from '../dangerousStyleValue';
|
import dangerousStyleValue from '../dangerousStyleValue';
|
||||||
import hyphenateStyleName from 'hyphenate-style-name';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the value for multiple styles on a node. If a value is specified as
|
* Sets the value for multiple styles on a node. If a value is specified as
|
||||||
@@ -32,8 +31,7 @@ function setValueForStyles(node, styles) {
|
|||||||
styleName = 'cssFloat';
|
styleName = 'cssFloat';
|
||||||
}
|
}
|
||||||
if (isCustomProperty) {
|
if (isCustomProperty) {
|
||||||
const name = isCustomProperty ? styleName : hyphenateStyleName(styleName);
|
style.setProperty(styleName, styleValue);
|
||||||
style.setProperty(name, styleValue);
|
|
||||||
} else {
|
} else {
|
||||||
style[styleName] = styleValue;
|
style[styleName] = styleValue;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user