mirror of
https://github.com/jquery/jquery.git
synced 2026-02-01 08:55:55 -05:00
CSS: Correctly set support properties with non-default zoom
Fixes gh-3808 Closes gh-3872
This commit is contained in:
committed by
Richard Gibson
parent
0aa832afec
commit
f00a07590e
26
test/data/css/cssWidthBrowserZoom.html
Normal file
26
test/data/css/cssWidthBrowserZoom.html
Normal file
@@ -0,0 +1,26 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<style>
|
||||
html {
|
||||
zoom: 1.1;
|
||||
}
|
||||
#test {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
padding: 10px;
|
||||
border: 1px solid pink;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="test"></div>
|
||||
<script src="../../jquery.js"></script>
|
||||
<script src="../iframeTest.js"></script>
|
||||
<script>
|
||||
startIframeTest( jQuery( "#test" ).css( 'width' ) );
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1164,6 +1164,15 @@ testIframe(
|
||||
}
|
||||
);
|
||||
|
||||
testIframe(
|
||||
"css('width') should work correctly with browser zooming",
|
||||
"css/cssWidthBrowserZoom.html",
|
||||
function( assert, jQuery, window, document, cssWidthBrowserZoom ) {
|
||||
assert.expect( 1 );
|
||||
assert.strictEqual( cssWidthBrowserZoom, "100px", "elem.css('width') works correctly with browser zoom" );
|
||||
}
|
||||
);
|
||||
|
||||
( function() {
|
||||
var supportsFractionalGBCR,
|
||||
qunitFixture = document.getElementById( "qunit-fixture" ),
|
||||
|
||||
Reference in New Issue
Block a user