Use max width
authorJoshua Rüsweg <josh@bastelstu.be>
Sun, 20 Jan 2019 19:35:02 +0000 (20:35 +0100)
committerJoshua Rüsweg <josh@bastelstu.be>
Sun, 20 Jan 2019 19:35:02 +0000 (20:35 +0100)
See #2825

wcfsetup/install/files/js/WoltLabSuite/Core/Ui/File/Upload.js

index 25743c85da7f0e4b15e3843f649fda3cefcbae90..b951728b8433b774b53dec438e22714e0cff93de 100644 (file)
@@ -146,7 +146,7 @@ define(['Core', 'Language', 'Dom/Util', 'WoltLabSuite/Core/Ui/File/Delete', 'Upl
                                                        var image = elCreate('img');
                                                        image.classList.add('previewImage');
                                                        image.setAttribute('src', data['files'][i].image);
-                                                       image.setAttribute('style', "width: 100%;");
+                                                       image.setAttribute('style', "max-width: 100%;");
                                                        elData(image, 'unique-file-id', data['files'][i].uniqueFileId);
                                                        this._target.appendChild(image);
                                                }