Skip to content

Commit f3321e8

Browse files
committed
fix: fix resource card description height
1 parent 691f9a2 commit f3321e8

File tree

2 files changed

+10
-13
lines changed

2 files changed

+10
-13
lines changed

src/cards/ResourceCard/ResourceCard.js

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// Licensed under the MIT license.
33
import React from 'react';
44
import PropTypes from 'prop-types';
5-
import { Typography, Button, Card, CardHeader, CardContent, CardActions, Tooltip, Fade } from '@mui/material';
5+
import { Typography, Button, Card, CardHeader, CardContent, CardActions } from '@mui/material';
66
import { DefaultAvatar } from '../../misc';
77
import useStyles from './style';
88

@@ -26,18 +26,11 @@ export const ResourceCard = ({ id, name, description, action, style }) => {
2626
title={name}
2727
/>
2828
<CardContent data-cy={'resource-content'}>
29-
<Tooltip
30-
TransitionComponent={Fade}
31-
TransitionProps={{ timeout: 600 }}
32-
key="resource-description-tooltip"
33-
title={description ?? ''}
34-
>
35-
<div className={classes.description}>
36-
<Typography noWrap={true} color="textSecondary" variant="body2">
37-
{description}
38-
</Typography>
39-
</div>
40-
</Tooltip>
29+
<div className={classes.description}>
30+
<Typography color="textSecondary" variant="body2">
31+
{description}
32+
</Typography>
33+
</div>
4134
</CardContent>
4235
{actionButton}
4336
</Card>

src/cards/ResourceCard/style.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ const useStyles = makeStyles(() => ({
1010
flexDirection: 'column',
1111
justifyContent: 'space-between',
1212
},
13+
description: {
14+
height: '70px',
15+
overflow: 'auto',
16+
},
1317
}));
1418

1519
export default useStyles;

0 commit comments

Comments
 (0)