We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 14096d1 + ba7ea45 commit 08d4adfCopy full SHA for 08d4adf
lib/web/magnifier/magnifier.js
@@ -165,10 +165,16 @@
165
}
166
167
data[idx].lensH = data[idx].lensH > $thumb.height() ? $thumb.height() : data[idx].lensH;
168
- lens.css({
169
- width: data[idx].lensW + 1 + 'px',
170
- height: data[idx].lensH - 1 + 'px'
171
- });
+
+ if (Math.round(data[idx].lensW) === 0) {
+ lens.css('display', 'none');
+ } else {
172
+ lens.css({
173
+ width: data[idx].lensW + 1 + 'px',
174
+ height: data[idx].lensH - 1 + 'px',
175
+ display: ''
176
+ });
177
+ }
178
179
180
function getMousePos() {
0 commit comments