From 161bdde18dcff3fd0a0c80ec91c5a9ed4d1bfed5 Mon Sep 17 00:00:00 2001 From: kentac55 Date: Fri, 22 May 2020 17:49:24 +0900 Subject: [PATCH] feat(user): provide a prop for alt text --- components/user/user.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/components/user/user.tsx b/components/user/user.tsx index fef9f47..5ad9e43 100644 --- a/components/user/user.tsx +++ b/components/user/user.tsx @@ -8,6 +8,7 @@ interface Props { src?: string text?: string className?: string + altText?: string } const defaultProps = { @@ -23,13 +24,14 @@ const User: React.FC> = ({ name, children, className, + altText, ...props }) => { const theme = useTheme() return (
- +
{name} {children}