diff --git a/README.md b/README.md index 7c2ce51c..1595f1ee 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Lightbox2 -The original lightbox script. Eight years later — still going strong! +The _original_ lightbox script. Lightbox is small javascript library used to overlay images on top of the current page. It's a snap to setup and works on all modern browsers. diff --git a/package.json b/package.json index 4f8cbbfd..ad21f324 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "lightbox2", - "version": "2.11.1", + "version": "2.11.2", "author": "Lokesh Dhakar ", "description": "The original Lightbox script. Uses jQuery.", "keywords": [ diff --git a/src/js/lightbox.js b/src/js/lightbox.js index 8d8ea06c..aa97e73f 100644 --- a/src/js/lightbox.js +++ b/src/js/lightbox.js @@ -1,5 +1,5 @@ /*! - * Lightbox v2.11.1 + * Lightbox v2.11.2 * by Lokesh Dhakar * * More info: @@ -314,18 +314,13 @@ maxImageHeight = windowHeight - self.containerPadding.top - self.containerPadding.bottom - self.imageBorderWidth.top - self.imageBorderWidth.bottom - self.options.positionFromTop - 70; /* - SVGs that don't have width and height attributes specified are reporting width and height - values of 0 in Firefox 47 and IE11 on Windows. To fix, we set the width and height to the max - dimensions for the viewport rather than 0 x 0. - - https://github.com/lokesh/lightbox2/issues/552 + Since many SVGs have small intrinsic dimensions, but they support scaling + up without quality loss because of their vector format, max out their + size. */ - if (filetype === 'svg') { - if ((preloader.width === 0) || preloader.height === 0) { - $image.width(maxImageWidth); - $image.height(maxImageHeight); - } + $image.width(maxImageWidth); + $image.height(maxImageHeight); } // Fit image inside the viewport.