translate-and-transform-css-property-in-svg.html (999B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <title>CSS Transforms Test: combination of the CSS translate property and SVG transform attribute</title> 5 <link rel="author" title="Antoine Quint" href="mailto:graouts@apple.com"> 6 <link rel="help" href="https://www.w3.org/TR/css-transforms-2/#propdef-translate"> 7 <link rel="match" href="reference/translate-and-transform-css-property-in-svg-ref.html"> 8 <meta name="flags" content="svg"> 9 <meta name="assert" content="The CSS translate property is applied in combination with the SVG transform attribute in the absence of a CSS transform property."> 10 <style type="text/css"> 11 svg { 12 width: 400px; 13 height: 400px; 14 } 15 </style> 16 </head> 17 <body> 18 <p>The test passes if there is a green rectangle and no red.</p> 19 <svg> 20 <rect x="101" y="101" width="198" height="198" fill="red"/> 21 <rect width="100" height="100" fill="green" transform="scale(2)" style="translate: 100px 100px" /> 22 </svg> 23 </body> 24 </html>