({
stat,
...props
}: {
stat: { title: string; amount: number };
onClick?: () => void;
className?: string;
})
| 21 | |
| 22 | const ItemWrapper = classed('div', 'flex items-center gap-1'); |
| 23 | const Item = ({ |
| 24 | stat, |
| 25 | ...props |
| 26 | }: { |
| 27 | stat: { title: string; amount: number }; |
| 28 | onClick?: () => void; |
| 29 | className?: string; |
| 30 | }) => ( |
| 31 | <ItemWrapper {...props} data-testid={stat?.title}> |
| 32 | <b className="text-text-primary typo-subhead"> |
| 33 | {largeNumberFormat(stat?.amount || 0)} |
| 34 | </b> |
| 35 | <span className="capitalize">{stat?.title}</span> |
| 36 | </ItemWrapper> |
| 37 | ); |
| 38 | |
| 39 | export function UserStats({ stats, userId }: UserStatsProps): ReactElement { |
| 40 | const { openModal } = useLazyModal< |
nothing calls this directly
no test coverage detected