Skip to content

Commit a6f0860

Browse files
authored
Merge pull request #7 from loijwdev/fix/android-color-crash
fix: resolve Android ColorValue crash
2 parents 841c9f0 + 8881592 commit a6f0860

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/index.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { type ViewProps, StyleSheet } from 'react-native';
1+
import { type ViewProps, StyleSheet, processColor } from 'react-native';
22
import LiveDetectEdgesViewNativeComponent from './LiveDetectEdgesViewNativeComponent';
33

44
export type LiveDetectEdgesViewProps = ViewProps & {
@@ -9,12 +9,14 @@ export type LiveDetectEdgesViewProps = ViewProps & {
99

1010
export const LiveDetectEdgesView = ({
1111
overlayColor = 'rgba(0, 255, 0, 0.5)',
12+
overlayFillColor,
1213
overlayStrokeWidth = 4,
1314
...props
1415
}: LiveDetectEdgesViewProps) => {
1516
return (
1617
<LiveDetectEdgesViewNativeComponent
17-
overlayColor={overlayColor}
18+
overlayColor={processColor(overlayColor)}
19+
overlayFillColor={processColor(overlayFillColor)}
1820
overlayStrokeWidth={overlayStrokeWidth}
1921
{...props}
2022
style={[styles.defaultStyle, props.style]}

0 commit comments

Comments
 (0)