react-native-airship
Advanced tools
+4
-0
| # react-native-airship | ||
| ## 0.2.9 (2022-04-25) | ||
| - added: Add `borderColor` and `borderWidth` props to the `AirshipModal` component. | ||
| ## 0.2.8 (2022-04-01) | ||
@@ -4,0 +8,0 @@ |
@@ -11,2 +11,4 @@ import * as React from 'react'; | ||
| borderRadius?: number; | ||
| borderColor?: string; | ||
| borderWidth?: number; | ||
| flexDirection?: ViewStyle['flexDirection']; | ||
@@ -13,0 +15,0 @@ justifyContent?: ViewStyle['justifyContent']; |
@@ -10,3 +10,3 @@ import * as React from 'react'; | ||
| export function AirshipModal(props) { | ||
| const { bridge, children, onCancel, backgroundColor = 'white', borderRadius = 10, center = false, flexDirection, justifyContent, maxHeight, maxWidth = 512, overflow = 'visible', shadowOffset = { height: 0, width: 0 }, shadowOpacity = 1, shadowRadius = 10, slideInMs = 300, slideOutMs = 300, underlay = 'rgba(0, 0, 0, 0.75)' } = props; | ||
| const { bridge, children, onCancel, backgroundColor = 'white', borderRadius = 10, borderColor, borderWidth = 0, center = false, flexDirection, justifyContent, maxHeight, maxWidth = 512, overflow = 'visible', shadowOffset = { height: 0, width: 0 }, shadowOpacity = 1, shadowRadius = 10, slideInMs = 300, slideOutMs = 300, underlay = 'rgba(0, 0, 0, 0.75)' } = props; | ||
| const margin = sidesToMargin(fixSides(props.margin, 0)); | ||
@@ -75,3 +75,6 @@ const padding = sidesToPadding(fixSides(props.padding, 0)); | ||
| const bodyStyle = center | ||
| ? Object.assign(Object.assign({}, bodyCommon), { borderRadius }) : Object.assign(Object.assign({}, bodyCommon), { borderTopLeftRadius: borderRadius, borderTopRightRadius: borderRadius, marginBottom: -safeAreaGap, paddingBottom: padding.paddingBottom + safeAreaGap }); | ||
| ? Object.assign(Object.assign({}, bodyCommon), { borderRadius, | ||
| borderColor, | ||
| borderWidth }) : Object.assign(Object.assign({}, bodyCommon), { borderTopLeftRadius: borderRadius, borderTopRightRadius: borderRadius, borderColor, | ||
| borderWidth, marginBottom: -safeAreaGap, paddingBottom: padding.paddingBottom + safeAreaGap }); | ||
| return (React.createElement(React.Fragment, null, | ||
@@ -78,0 +81,0 @@ React.createElement(TouchableWithoutFeedback, { onPress: () => onCancel() }, |
+1
-1
| { | ||
| "name": "react-native-airship", | ||
| "version": "0.2.8", | ||
| "version": "0.2.9", | ||
| "private": false, | ||
@@ -5,0 +5,0 @@ "description": "Flexible toolkit for building modals & alerts", |
Sorry, the diff of this file is not supported yet
36395
0.89%644
0.78%