Use single function for margin, position, padding, and border
Summary: marginLeft(node, margin) -> margin(node, CSSEdgeLeft, margin) This reduces the api surface of CSSLayout as well as puts the api more in line with the java version. This also adds support for CSSEdgeAll which java has had support for for a while. This also open up the possibility of doing margin(node, CSSEdgeLeft | CSSEdgeTop, margin) in the future. Reviewed By: lucasr Differential Revision: D3715201 fbshipit-source-id: ea81ed426f0f7853bb542355c01fc16ae4360238
This commit is contained in:
committed by
Facebook Github Bot 6
parent
48e5304276
commit
a960203567
@@ -62,16 +62,6 @@ typedef struct CSSStyle {
|
||||
float flexBasis;
|
||||
float margin[6];
|
||||
float position[6];
|
||||
/**
|
||||
* You should skip all the rules that contain negative values for the
|
||||
* following attributes. For example:
|
||||
* {padding: 10, paddingLeft: -5}
|
||||
* should output:
|
||||
* {left: 10 ...}
|
||||
* the following two are incorrect:
|
||||
* {left: -5 ...}
|
||||
* {left: 0 ...}
|
||||
*/
|
||||
float padding[6];
|
||||
float border[6];
|
||||
float dimensions[2];
|
||||
|
Reference in New Issue
Block a user