({
leftInset,
horizontalInset = false,
style,
theme: themeOverrides,
bold = false,
...rest
}: Props)
| 52 | * ``` |
| 53 | */ |
| 54 | const Divider = ({ |
| 55 | leftInset, |
| 56 | horizontalInset = false, |
| 57 | style, |
| 58 | theme: themeOverrides, |
| 59 | bold = false, |
| 60 | ...rest |
| 61 | }: Props) => { |
| 62 | const theme = useInternalTheme(themeOverrides); |
| 63 | const { dark: isDarkTheme, isV3 } = theme; |
| 64 | |
| 65 | const dividerColor = isV3 |
| 66 | ? theme.colors.outlineVariant |
| 67 | : color(isDarkTheme ? white : black) |
| 68 | .alpha(0.12) |
| 69 | .rgb() |
| 70 | .string(); |
| 71 | |
| 72 | return ( |
| 73 | <View |
| 74 | {...rest} |
| 75 | style={[ |
| 76 | { height: StyleSheet.hairlineWidth, backgroundColor: dividerColor }, |
| 77 | leftInset && (isV3 ? styles.v3LeftInset : styles.leftInset), |
| 78 | isV3 && horizontalInset && styles.horizontalInset, |
| 79 | isV3 && bold && styles.bold, |
| 80 | style, |
| 81 | ]} |
| 82 | /> |
| 83 | ); |
| 84 | }; |
| 85 | |
| 86 | const styles = StyleSheet.create({ |
| 87 | leftInset: { |
nothing calls this directly
no test coverage detected
searching dependent graphs…