Handle typography with more than 2 lines

This commit is contained in:
schroda
2024-10-19 16:35:35 +02:00
parent 64ac4a54fd
commit e416a141b0

View File

@@ -18,7 +18,7 @@ export const TypographyMaxLines = styled(Typography, {
shouldForwardProp: shouldForwardProp<TypographyMaxLinesProps>(['lines']),
})<TypographyMaxLinesProps>(({ lines = 2 }) => ({
lineHeight: '1.5rem',
maxHeight: '3rem',
maxHeight: `${3 * lines}rem`,
display: '-webkit-box',
WebkitLineClamp: `${lines}`,
WebkitBoxOrient: 'vertical',