import React from 'react'; import { View } from 'react-native'; import TableRow from './TableRow'; import type { TableProps } from './types'; import { Pressable } from 'react-native'; const Table = (viewProps: TableProps) => { const { header, data, columnsWidth, columnsAlign, borderColor = '#333', borderWidth = 1, containerStyle, headerStyle, headerTextStyle, rowStyle, textStyle, onRowPressed, } = viewProps; return ( (pre += cur)) + borderWidth, }, containerStyle, ]} > {data.map((row, rowIndex) => { return ( onRowPressed?.(rowIndex)}> ); })} ); }; export default Table;