import { Text, StyleSheet, View } from 'react-native'; import { badgeTexts, innerBorders, metadatas } from './styles'; import { variants } from '../common/styles'; import type { IBadgeProps } from './types'; export default function Badge(props: IBadgeProps) { const { children, metadata, style, innerBordersStyle, textStyle, variant = 'primary', } = props; return ( {typeof metadata !== 'undefined' ? ( {metadata} ) : null} {typeof children === 'string' || typeof (children as string[])?.[0] === 'string' ? ( {children} ) : ( children )} ); }