zoom-level
Advanced tools
Comparing version 1.1.7 to 1.1.8
@@ -25,3 +25,3 @@ const zoomLevelDetector = (matchMedia, currentLevel, minimalLevel, stepDivisor) => { | ||
if (typeof win.devicePixelRatio !== "undefined") { | ||
return 1; | ||
return win.devicePixelRatio; | ||
} | ||
@@ -28,0 +28,0 @@ if (typeof win.document.frames !== "undefined") { |
@@ -1,2 +0,2 @@ | ||
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?o(exports):"function"==typeof define&&define.amd?define(["exports"],o):o((e=e||self).zoomLevel={})}(this,function(e){"use strict";const o=(e,o,t,n)=>{for(;o>=t&&!e("(min-resolution: "+o/n+"dppx)").matches;)o--;return o};function t(e){return void 0!==(e=e||window).devicePixelRatio?1:void 0!==e.document.frames?void 0!==e.document.frames.devicePixelRatio?e.document.frames.devicePixelRatio:e.document.frames.screen.deviceXDPI/e.document.frames.screen.systemXDPI:void 0!==e.matchMedia?function(){const e=window.matchMedia;let t,n=10,i=.1,d=1;for(let c=0;c<4;c++)n=9+(t=10*o(e,n,i,d)),i=t,d*=10;return t/d}():1}e.default=t,e.elementZoomLevel=function(e,o,n){return n=n||window,o=o||getComputedStyle(e),t(n)*(parseFloat(o.zoom)||1)},e.zoomLevel=t}); | ||
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?o(exports):"function"==typeof define&&define.amd?define(["exports"],o):o((e=e||self).zoomLevel={})}(this,function(e){"use strict";const o=(e,o,t,i)=>{for(;o>=t&&!e("(min-resolution: "+o/i+"dppx)").matches;)o--;return o};function t(e){return void 0!==(e=e||window).devicePixelRatio?e.devicePixelRatio:void 0!==e.document.frames?void 0!==e.document.frames.devicePixelRatio?e.document.frames.devicePixelRatio:e.document.frames.screen.deviceXDPI/e.document.frames.screen.systemXDPI:void 0!==e.matchMedia?function(){const e=window.matchMedia;let t,i=10,n=.1,d=1;for(let c=0;c<4;c++)i=9+(t=10*o(e,i,n,d)),n=t,d*=10;return t/d}():1}e.default=t,e.elementZoomLevel=function(e,o,i){return i=i||window,o=o||getComputedStyle(e),t(i)*(parseFloat(o.zoom)||1)},e.zoomLevel=t}); | ||
//# sourceMappingURL=zoom-level.js.map |
@@ -11,3 +11,3 @@ { | ||
], | ||
"version": "1.1.7", | ||
"version": "1.1.8", | ||
"main": "dist/zoom-level.js", | ||
@@ -14,0 +14,0 @@ "module": "dist/zoom-level.esm.js", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11622