Skip to content

Commit

Permalink
Merge pull request #1 from kristerkari/bugfix/add-missing-properties
Browse files Browse the repository at this point in the history
Add missing properties
  • Loading branch information
kristerkari authored Feb 11, 2018
2 parents 9f49c50 + 56ee9aa commit 797fba7
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 1 deletion.
18 changes: 18 additions & 0 deletions src/__snapshots__/index.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,15 @@

exports[`should have a flat array of all known React Native props 1`] = `
Array [
"alignContent",
"alignItems",
"alignSelf",
"flex",
"flexBasis",
"flexDirection",
"flexGrow",
"flexWrap",
"flexShrink",
"justifyContent",
"borderWidth",
"borderBottomWidth",
Expand All @@ -30,6 +34,7 @@ Array [
"right",
"top",
"zIndex",
"display",
"height",
"minHeight",
"maxHeight",
Expand Down Expand Up @@ -64,7 +69,10 @@ Array [
"textDecorationColor",
"textDecorationStyle",
"letterSpacing",
"direction",
"elevation",
"borderStartColor",
"borderEndColor",
"textAlignVertical",
"textShadowColor",
"textShadowOffset",
Expand All @@ -83,16 +91,21 @@ Array [
"tintColor",
"overlayColor",
"writingDirection",
"includeFontPadding",
]
`;

exports[`should have a flat array of all known css-to-react-native props 1`] = `
Array [
"alignContent",
"alignItems",
"alignSelf",
"flex",
"flexBasis",
"flexDirection",
"flexGrow",
"flexWrap",
"flexShrink",
"justifyContent",
"borderWidth",
"borderBottomWidth",
Expand All @@ -116,6 +129,7 @@ Array [
"right",
"top",
"zIndex",
"display",
"height",
"minHeight",
"maxHeight",
Expand Down Expand Up @@ -150,7 +164,10 @@ Array [
"textDecorationColor",
"textDecorationStyle",
"letterSpacing",
"direction",
"elevation",
"borderStartColor",
"borderEndColor",
"textAlignVertical",
"textShadowColor",
"textShadowOffset",
Expand All @@ -169,6 +186,7 @@ Array [
"tintColor",
"overlayColor",
"writingDirection",
"includeFontPadding",
"border",
"boxShadow",
"flexFlow",
Expand Down
13 changes: 12 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,15 @@ function flatten(arr) {
}

export const flexboxProps = [
"alignContent",
"alignItems",
"alignSelf",
"flex",
"flexBasis",
"flexDirection",
"flexGrow",
"flexWrap",
"flexShrink",
"justifyContent"
];

Expand Down Expand Up @@ -44,6 +48,7 @@ export const positioningProps = [
];

export const boxModelProps = [
"display",
"height",
"minHeight",
"maxHeight",
Expand Down Expand Up @@ -89,8 +94,12 @@ export const fontProps = [
"letterSpacing"
];

export const writingModeProps = ["direction"];

export const reactNativeProps = [
"elevation",
"borderStartColor",
"borderEndColor",
"textAlignVertical",
"textShadowColor",
"textShadowOffset",
Expand All @@ -108,7 +117,8 @@ export const reactNativeProps = [
"resizeMode",
"tintColor",
"overlayColor",
"writingDirection"
"writingDirection",
"includeFontPadding"
];

export const CSS2RNProps = [
Expand All @@ -131,6 +141,7 @@ export const allProps = flatten([
backgroundProps,
colorProps,
fontProps,
writingModeProps,
reactNativeProps
]);

Expand Down

0 comments on commit 797fba7

Please sign in to comment.