From 9efc0344f6af8da000c976dc738326de847b61eb Mon Sep 17 00:00:00 2001 From: hjm <63528605@qq.com> Date: Mon, 8 Jul 2019 17:44:53 +0800 Subject: [PATCH] max-width: 86%; --- public/react/src/modules/page/layers/ImageLayerOfCommentHOC.js | 2 +- public/react/src/modules/page/layers/TaskResultLayer.css | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/public/react/src/modules/page/layers/ImageLayerOfCommentHOC.js b/public/react/src/modules/page/layers/ImageLayerOfCommentHOC.js index 61342de37..50072c627 100644 --- a/public/react/src/modules/page/layers/ImageLayerOfCommentHOC.js +++ b/public/react/src/modules/page/layers/ImageLayerOfCommentHOC.js @@ -18,7 +18,7 @@ export function ImageLayerOfCommentHOC(options = {}) { const imageSrc = event.target.src || event.target.getAttribute('src') || event.target.getAttribute('href') // 判断imageSrc是否是图片 const fileName = event.target.innerHTML.trim() - if (isImageExtension(imageSrc.trim()) || isImageExtension(fileName)) { + if (isImageExtension(imageSrc.trim()) || isImageExtension(fileName) || event.target.tagName == 'IMG') { // 非回复里的头像图片; 非emoticons if (imageSrc.indexOf('/images/avatars/User') === -1 && imageSrc.indexOf('kindeditor/plugins/emoticons') === -1 ) { diff --git a/public/react/src/modules/page/layers/TaskResultLayer.css b/public/react/src/modules/page/layers/TaskResultLayer.css index a684abdf4..0dd118470 100644 --- a/public/react/src/modules/page/layers/TaskResultLayer.css +++ b/public/react/src/modules/page/layers/TaskResultLayer.css @@ -41,9 +41,10 @@ align-items: center; display: -webkit-flex; height: 100%; + text-align: center; } .passImg{ - max-width: 100%; + max-width: 86%; max-height: 100%; } /* ImageLayer ----------------- End */