frontend/.pnpm-store/v3/files/9e/62dce76ef1f56fc538ebb7748ae5b6a0d66713a4e1a65fcfb0dcf06e5cbb1fcc2b738b100bff7190f4917334b6a13345d75de8b27bb4d0e693d2e8e08f521f

15 lines
522 B
Plaintext

// https://github.com/Modernizr/Modernizr/issues/572
// http://jsfiddle.net/FWeinb/etnYC/
Modernizr.addTest('cssvwunit', function(){
var bool;
Modernizr.testStyles("#modernizr { width: 50vw; }", function(elem, rule) {
var width = parseInt(window.innerWidth/2,10),
compStyle = parseInt((window.getComputedStyle ?
getComputedStyle(elem, null) :
elem.currentStyle)["width"],10);
bool= (compStyle == width);
});
return bool;
});