Fix size of single media in media-gallery (#5098)

th-downstream
Lynx Kotoura 7 years ago committed by Eugen Rochko
parent 8b7c639bbe
commit cad208ba43

@ -161,10 +161,8 @@ class Item extends React.PureComponent {
);
}
const style = standalone ? {} : { left, top, right, bottom, width: `${width}%`, height: `${height}%` };
return (
<div className={classNames('media-gallery__item', { standalone })} key={attachment.get('id')} style={style}>
<div className={classNames('media-gallery__item', { standalone })} key={attachment.get('id')} style={{ left: left, top: top, right: right, bottom: bottom, width: `${width}%`, height: `${height}%` }}>
{thumbnail}
</div>
);

Loading…
Cancel
Save