Bug 1641035 [wpt PR 23779] - [css-grid] Fix 'grid-template-areas: inherit', a=testonly
authorOriol Brufau <obrufau@igalia.com>
Sat, 30 May 2020 09:50:42 +0000
changeset 597308 16b0a8b4475789462bf2837963378c0226aeb3ec
parent 597307 9a874dd81dc3bee244db7c91b58bb124e4a2b3f7
child 597309 c84f430705686b7a73696ea93de6999d2a50dc66
push id13310
push userffxbld-merge
push dateMon, 29 Jun 2020 14:50:06 +0000
treeherdermozilla-beta@15a59a0afa5c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstestonly
bugs1641035, 23779, 1085853, 2214960, 771984
milestone78.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 1641035 [wpt PR 23779] - [css-grid] Fix 'grid-template-areas: inherit', a=testonly Automatic update from web-platform-tests [css-grid] Fix 'grid-template-areas: inherit' GridTemplateAreas::ApplyInherit wasn't setting ImplicitNamedGridRowLines nor ImplicitNamedGridColumnLines inherited from the parent, so grid items referencing these lines were placed into the implicid grid. The patch also makes sure to set them in GridTemplateAreas::ApplyInitial and GridTemplateAreas::ApplyValue for a 'none' keyword. It seems these weren't causing noticeable problems, though. BUG=1085853 TEST=external/wpt/css/css-grid/placement/grid-placement-using-named-grid-lines-008.html Change-Id: If92e771d51450dea3f7fa12deaec6ce9dd7639d1 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2214960 Reviewed-by: Javier Fernandez <jfernandez@igalia.com> Commit-Queue: Oriol Brufau <obrufau@igalia.com> Cr-Commit-Position: refs/heads/master@{#771984} -- wpt-commits: c81ab1e2472ed9930826294d9f4a48bcf8398e30 wpt-pr: 23779
testing/web-platform/tests/css/css-grid/placement/grid-placement-using-named-grid-lines-008.html
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/css-grid/placement/grid-placement-using-named-grid-lines-008.html
@@ -0,0 +1,30 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Grid Layout Test: Grid item placement with inherited grid-template-areas</title>
+<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com">
+<link rel="help" href="http://www.w3.org/TR/css-grid-1/#line-placement">
+<link rel="match" href="../../reference/ref-filled-green-100px-square.xht">
+<meta name="assert" content="Grid placement algorithm is able to select the right line when defined implicitly with an inherited grid-template-areas.">
+<style>
+.wrapper {
+  grid-template-areas: "a b" "a c";
+}
+.grid {
+  display: grid;
+  grid-template-areas: inherit;
+  width: 100px;
+  height: 100px;
+  background: red;
+}
+.item {
+  background: green;
+}
+</style>
+<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+<div class="wrapper">
+  <div class="grid">
+    <div class="item" style="grid-area: a"></div>
+    <div class="item" style="grid-area: b"></div>
+    <div class="item" style="grid-area: c"></div>
+  </div>
+</div>