Skip to content

Commit

Permalink
layout: Allow transforming inline replaced elements
Browse files Browse the repository at this point in the history
This requires passing through information about whether or not the
element in question is replaced when checking to see if it's
transformable and transitively all functions that make decisions about
containing blocks. A new FragmentFlag is added to help track this -- it
will be set on both the replaced items BoxFragment container as well as
the Fragment for the replaced item itself.

Fixes #31806.
  • Loading branch information
mrobinson authored and servo-wpt-sync committed Mar 27, 2024
1 parent f0277f5 commit c9e74b1
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
14 changes: 14 additions & 0 deletions css/css-transforms/support/transform-iframe-002-contents.html
@@ -0,0 +1,14 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Test (Transforms): Iframe (contents)</title>
<link rel="author" title="Martin Robinson" href="mailto:mrobinson@igalia.com">
<style>
body {
background: green;
}
</style>
</head>
<body>
</body>
</html>
20 changes: 20 additions & 0 deletions css/css-transforms/transform-iframe-002.html
@@ -0,0 +1,20 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Test (Transforms): Iframe</title>
<link rel="author" title="Martin Robinson" href="mailto:mrobinson@igalia.com">
<link rel="help" href="http://www.w3.org/TR/css-transforms-1/#transform-rendering">
<meta name="assert" content="This test ensures that an iframe element can be transformed.">
<link rel="match" href="/css/reference/ref-filled-green-100px-square-only.html">
<style>
iframe {
height: 50px;
width: 50px;
transform: translate(25px, 25px) scale(2, 2);
border: none;
}
</style>
<p>Test passes if there is a filled green square.</p>
<iframe src="support/transform-iframe-002-contents.html"></iframe>
</body>
</html>

0 comments on commit c9e74b1

Please sign in to comment.