From e7604c441848b4191b937a9f614543bcc6f31b62 Mon Sep 17 00:00:00 2001 From: Erik Ziegler Date: Fri, 19 Jul 2019 18:29:34 +0200 Subject: [PATCH] fix(Viewer): Switch to middle of stack for image thumbnail --- src/connectedComponents/Viewer.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/connectedComponents/Viewer.js b/src/connectedComponents/Viewer.js index 7186b041d..fafd1e206 100644 --- a/src/connectedComponents/Viewer.js +++ b/src/connectedComponents/Viewer.js @@ -319,7 +319,6 @@ export default Viewer; * * TODO[react]: * - Add sorting of display sets - * - Add useMiddleSeriesInstanceAsThumbnail * - Add showStackLoadingProgressBar option * * @param {Study[]} studies @@ -342,7 +341,9 @@ const _mapStudiesToThumbnails = function(studies) { let altImageText = ' '; // modality if (displaySet.images && displaySet.images.length) { - imageId = displaySet.images[0].getImageId(); + const imageIndex = Math.floor(displaySet.images.length / 2); + + imageId = displaySet.images[imageIndex].getImageId(); } else { altImageText = displaySet.modality ? displaySet.modality : 'UN'; }