feat(text): size and colour support

This commit is contained in:
2021-01-18 21:38:46 +00:00
parent df8feab7bb
commit d7dc5042bb

View File

@@ -8,11 +8,8 @@ const StyledText = styled.p`
css`
font-style: ${props.textStyle};
`}
${props =>
props.size === "sm" &&
css`
font-size: var(--font-size-sm);
`}
font-size: ${props => `var(--font-size-${props.size})`};
color: ${props => `var(--theme-color-${props.color})`};
`;
export default function Text({ children, ...props }) {