From 76b7aa0228a654dea1ecf61eb9b190db53f6679d Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Sun, 14 Jun 2015 21:11:31 +0200 Subject: [PATCH] Fixed floating of images --- wcfsetup/install/files/js/WCF.ImageViewer.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/wcfsetup/install/files/js/WCF.ImageViewer.js b/wcfsetup/install/files/js/WCF.ImageViewer.js index 38e72bc292..d251716aba 100644 --- a/wcfsetup/install/files/js/WCF.ImageViewer.js +++ b/wcfsetup/install/files/js/WCF.ImageViewer.js @@ -97,6 +97,15 @@ WCF.ImageViewer = Class.extend({ if (!$image.parents('a').length) { $image.wrap(''); $image.parent().click($.proxy(this._click, this)); + + if ($image.css('float') == 'right') { + $image.parent().addClass('messageFloatObjectRight'); + } + else if ($image.css('float') == 'left') { + $image.parent().addClass('messageFloatObjectLeft'); + } + $image[0].style.removeProperty('float'); + $image[0].style.removeProperty('margin'); } } } -- 2.20.1