Bug 1441488 [wpt PR 9389] - [PE] Update/fix UA stylesheet for SVG roots in shadow trees, a=testonly
authorFredrik Söderquist <fs@opera.com>
Tue, 27 Feb 2018 16:40:05 +0000
changeset 461093 a91d00bab5571b8d38fc445fe2b71cd3f0ebccca
parent 461092 37e765a99d1d8c91c4388b238a82fc4f097d21b5
child 461094 63b5c437714e563ae3ddbb24fc2b70f182971981
push id1683
push usersfraser@mozilla.com
push dateThu, 26 Apr 2018 16:43:40 +0000
treeherdermozilla-release@5af6cb21869d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstestonly
bugs1441488, 808228, 901263, 534371
milestone60.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1441488 [wpt PR 9389] - [PE] Update/fix UA stylesheet for SVG roots in shadow trees, a=testonly Automatic update from web-platform-tests The the UA stylesheet would not set 'transform-origin' correctly for <svg> outermost roots being direct descendants of the shadow root. Update the UA stylesheet to fix this, and also match what's currently specced by CSS transforms [1]. Removing prefixes as appropriate. [1] https://drafts.csswg.org/css-transforms/#transform-origin-property Bug: 808228 Change-Id: Ic36ce331797eb7ba80a046af88d22c08fe76d6fc Reviewed-on: https://chromium-review.googlesource.com/901263 Commit-Queue: Fredrik Söderquist <fs@opera.com> Reviewed-by: Rune Lillesveen <futhark@chromium.org> Cr-Commit-Position: refs/heads/master@{#534371} <!-- Reviewable:start --> <!-- Reviewable:end --> wpt-commits: 32ea0730fd5fe1fad0723635fee4efa6aa20f442 wpt-pr: 9389 reapplied-commits: 370e267e160568862f1fd9ec246ab5bb840f586e, fe4514c84e7ad28e46bad5da93381deb99b177f3, 7806af854343c043a2645a4034fdc7812f65daad, 9ddfd21554293dec5a4bf2e5375ae4f3c9f2ded0, 75f63c4d1ebc949647184fd60972fc7b9fd4affb, 1f3a5b496acd2288cc8cf0c32af86cb35157ea4e, 88b42bd5847abac58a62c4d6b33c1509bfce5f3d, 15c2e4c690700c6c115f8afe5e44ded10d943538, c8d461ef1437641ae7d4ea1d21e1e60cd62910b0, a6088a5f48ee299386a84d2f771902267d7355b1, 0634cd8f08ebe0905a9188fb1398c7b5f889c5dc, c8ee4a012dae506ae06bb5b2ad50942b04c1aaaa, c2c352456a4cf62dcc12f851138b04397675a445, b93a8879555d2fa7e7d4e00a275513a3a6338b35, b86e1331cb36634fd33677043b61fc0c1d8485bc, 44ddf14fd3346658c3223f13652073fafbfa48fa, a1a5840a6bb53e305ba02bcbeb215659342d0edb, 7465cb110ae5ec2e2ca73182caf5293f0efc8fd5, aad5349b3458bc3414e274b33fa86a1123901ff2, eca0907980d2769c449894a6277c60c1a306792f, 38626987c0cfd6e715cfcc6f4f1a1209191a03c5, e4a67f7ddcde6cd99348e9104bd7ed07074da44a, bb3c9990840a0fae2afc840b5952d7874785b112, 042d7adef0bdb9dc80e825c3997ace7519477c42, 99f1ea44fc7915b8b7b33bce4732fa8765fd3ac2
testing/web-platform/meta/MANIFEST.json
testing/web-platform/tests/css/css-transforms/transform-origin-in-shadow.html
--- a/testing/web-platform/meta/MANIFEST.json
+++ b/testing/web-platform/meta/MANIFEST.json
@@ -312151,16 +312151,22 @@
     ]
    ],
    "css/css-transforms/transform-2d-getComputedStyle-001.html": [
     [
      "/css/css-transforms/transform-2d-getComputedStyle-001.html",
      {}
     ]
    ],
+   "css/css-transforms/transform-origin-in-shadow.html": [
+    [
+     "/css/css-transforms/transform-origin-in-shadow.html",
+     {}
+    ]
+   ],
    "css/css-transforms/transform_translate.html": [
     [
      "/css/css-transforms/transform_translate.html",
      {}
     ]
    ],
    "css/css-transforms/transform_translate_invalid.html": [
     [
@@ -511906,16 +511912,20 @@
   "css/css-transforms/transform-origin-013-ref.html": [
    "e18516aa9bb1f9fb0a8ff762811832b4b721dae8",
    "support"
   ],
   "css/css-transforms/transform-origin-013.html": [
    "391c925801c9f166285b9aa5ea4bec194af13748",
    "reftest"
   ],
+  "css/css-transforms/transform-origin-in-shadow.html": [
+   "3a30f869d047c0677f7e989e919f0345d32fb28a",
+   "testharness"
+  ],
   "css/css-transforms/transform-origin-name-001.html": [
    "ca659829faa1079070d79ff0ed9ddeedc02d670c",
    "reftest"
   ],
   "css/css-transforms/transform-origin-name-002.html": [
    "95c1626a7a1ee38c04497d62f032879de91c6543",
    "reftest"
   ],
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/css-transforms/transform-origin-in-shadow.html
@@ -0,0 +1,34 @@
+<!DOCTYPE html>
+<title>'transform-origin' on &lt;svg> being direct descendant of shadow root</title>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<link rel="help" href="https://drafts.csswg.org/css-transforms/#transform-origin-property">
+<template>
+  <style>
+    #target {
+      height: 100px;
+      width: 100px;
+      background-color: green;
+      transform: rotate(90deg);
+    }
+  </style>
+  <svg id="target"></svg>
+</template>
+<div style="position: relative; height: 100px">
+  <div style="width: 100px; height: 100px; background-color: red; position: absolute"></div>
+  <div style="position: absolute" id="wrapper"></div>
+</div>
+<script>
+setup(function() {
+  const wrapper = document.querySelector('#wrapper');
+  wrapper.attachShadow({mode: "open"});
+  wrapper.shadowRoot.appendChild(
+    document.querySelector("template").content.cloneNode(true));
+});
+
+test(function() {
+  const wrapper = document.querySelector('#wrapper');
+  const target = wrapper.shadowRoot.getElementById('target');
+  assert_equals(getComputedStyle(target, null).transformOrigin, '50px 50px');
+});
+</script>