diff options
author | Paul Frazee <pfrazee@gmail.com> | 2023-01-26 11:25:52 -0600 |
---|---|---|
committer | Paul Frazee <pfrazee@gmail.com> | 2023-01-26 11:25:52 -0600 |
commit | 7e3f6f030680a8cf7b5baa3ce6f33acd5766fca8 (patch) | |
tree | 38ad7a0c586caa6cd0635653cb812d602210b718 /src/view/lib/icons.tsx | |
parent | c4ba5e7fd507a2f5295fd3fcbcea0796223c744c (diff) | |
download | voidsky-7e3f6f030680a8cf7b5baa3ce6f33acd5766fca8.tar.zst |
Fix all type errors
Diffstat (limited to 'src/view/lib/icons.tsx')
-rw-r--r-- | src/view/lib/icons.tsx | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/view/lib/icons.tsx b/src/view/lib/icons.tsx index bfcbb26bd..f4224ea20 100644 --- a/src/view/lib/icons.tsx +++ b/src/view/lib/icons.tsx @@ -1,5 +1,5 @@ import React from 'react' -import {StyleProp, ViewStyle} from 'react-native' +import {StyleProp, TextStyle, ViewStyle} from 'react-native' import Svg, {Path} from 'react-native-svg' export function GridIcon({ @@ -428,12 +428,21 @@ export function CommentBottomArrow({ size?: string | number strokeWidth?: number }) { + let color = 'currentColor' + if ( + style && + typeof style === 'object' && + 'color' in style && + typeof style.color === 'string' + ) { + color = style.color + } return ( <Svg fill="none" viewBox="0 0 24 24" strokeWidth={strokeWidth || 2.5} - stroke={style?.color || 'currentColor'} + stroke={color} width={size || 24} height={size || 24} style={style}> |