diff --git a/ui/src/app/common/utils.service.js b/ui/src/app/common/utils.service.js index 085a28bad5..54d85ec6fe 100644 --- a/ui/src/app/common/utils.service.js +++ b/ui/src/app/common/utils.service.js @@ -553,7 +553,9 @@ function Utils($mdColorPalette, $rootScope, $window, $translate, $q, $timeout, t var aspect = imageAspectMap[urlHashCode]; if (angular.isUndefined(aspect)) { var testImage = document.createElement('img'); // eslint-disable-line - testImage.style.visibility = 'hidden'; + testImage.style.position = 'absolute'; + testImage.style.left = '-99999px'; + testImage.style.top = '-99999px'; testImage.onload = function() { aspect = testImage.width / testImage.height; document.body.removeChild(testImage); //eslint-disable-line