import React from 'react'; import { StyleSheet, Text, View } from 'react-native'; import { Data, DefaultProps } from './types'; export const Cell: React.FC> = props => { const { data, width, height, flex, style, textStyle, borderStyle, ...rest } = props; const textDom = React.isValidElement(data) ? ( data ) : ( {data} ); const borderTopWidth = (borderStyle && borderStyle.borderWidth) || 0; const borderRightWidth = borderTopWidth; const borderColor = (borderStyle && borderStyle.borderColor) || '#000'; return ( {textDom} ); }; const styles = StyleSheet.create({ cell: { justifyContent: 'center' }, text: { backgroundColor: 'transparent' } });