mirror of
https://github.com/zhigang1992/react.git
synced 2026-03-26 22:42:51 +08:00
fix: remove the background caused by the line-height of img
This commit is contained in:
@@ -48,6 +48,10 @@ const Display: React.FC<React.PropsWithChildren<DisplayProps>> = React.memo(({
|
||||
margin: 0;
|
||||
transition: min-width ease .2s;
|
||||
}
|
||||
|
||||
.content :global(img) {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.caption {
|
||||
font-size: .875rem;
|
||||
|
||||
@@ -76,6 +76,7 @@ const Image: React.FC<ImageProps> = React.memo(({
|
||||
width: ${scale};
|
||||
height: ${scale};
|
||||
object-fit: scale-down;
|
||||
display: block;
|
||||
}
|
||||
`}</style>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user