max-width: 86%;

dev_forum
hjm 6 years ago
parent cb6587f393
commit 9efc0344f6

@ -18,7 +18,7 @@ export function ImageLayerOfCommentHOC(options = {}) {
const imageSrc = event.target.src || event.target.getAttribute('src') || event.target.getAttribute('href') const imageSrc = event.target.src || event.target.getAttribute('src') || event.target.getAttribute('href')
// 判断imageSrc是否是图片 // 判断imageSrc是否是图片
const fileName = event.target.innerHTML.trim() const fileName = event.target.innerHTML.trim()
if (isImageExtension(imageSrc.trim()) || isImageExtension(fileName)) { if (isImageExtension(imageSrc.trim()) || isImageExtension(fileName) || event.target.tagName == 'IMG') {
// 非回复里的头像图片; 非emoticons // 非回复里的头像图片; 非emoticons
if (imageSrc.indexOf('/images/avatars/User') === -1 && if (imageSrc.indexOf('/images/avatars/User') === -1 &&
imageSrc.indexOf('kindeditor/plugins/emoticons') === -1 ) { imageSrc.indexOf('kindeditor/plugins/emoticons') === -1 ) {

@ -41,9 +41,10 @@
align-items: center; align-items: center;
display: -webkit-flex; display: -webkit-flex;
height: 100%; height: 100%;
text-align: center;
} }
.passImg{ .passImg{
max-width: 100%; max-width: 86%;
max-height: 100%; max-height: 100%;
} }
/* ImageLayer ----------------- End */ /* ImageLayer ----------------- End */

Loading…
Cancel
Save