import React from 'react'; import { Flex } from '../../Layout'; import { Text } from '../../Text'; import { CSS } from '../../Theme'; const Chip = ({ icon = <>, content = '', backgroundColor = '$surface_default', textColor = '$on_surface_high', hideIfNoContent = false, onClick, css = {}, }: { icon?: React.JSX.Element; content: string; backgroundColor?: string; textColor?: string; hideIfNoContent?: boolean; onClick?: () => void | Promise; css?: CSS; }) => { if (hideIfNoContent && !content) { return null; } return ( onClick?.()} > {icon} {content} ); }; export default Chip;