New issue
Advanced search Search tips

Issue 654712 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Oct 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug

Blocking:
issue 79180



Sign in to add a comment

[css-grid] Changing the argument on fit-content() doesn't cause the grid to be relayout

Project Member Reported by r...@igalia.com, Oct 11 2016

Issue description


If you modify the argument of a fit-content() track from JavaScript, the change doesn't get applied.

You can check it easily with the attached example.
 
bug-fit-content.html
393 bytes View Download
bug-fit-content-current.png
15.0 KB View Download
bug-fit-content-expected.png
12.9 KB View Download

Comment 1 by svil...@igalia.com, Oct 11 2016

Should be easy to fix. We basically don't track those changes when we check whether or not the new style requires a new layout.

Comment 2 by r...@igalia.com, Oct 13 2016

Owner: r...@igalia.com
Status: Started (was: Available)
Yeah sure, I'll take this one.
Project Member

Comment 3 by bugdroid1@chromium.org, Oct 13 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/468f3c355c499087911dbb34c8d2ba6d9a014cff

commit 468f3c355c499087911dbb34c8d2ba6d9a014cff
Author: rego <rego@igalia.com>
Date: Thu Oct 13 19:16:27 2016

[css-grid] Recompute track sizes if fit-content() argument is modified

When fit-content() was implemented a new attribute
m_fitContentTrackBreadth was added to GridTrackSize.
However we forgot to include it in the == operator implementation,
so we were missing the changes on that value.

Now if you change the argument of a fit-content() track,
the track size is properly recomputed.

BUG= 654712 
TEST=fast/css-grid-layout/grid-change-fit-content-argument.html

Review-Url: https://codereview.chromium.org/2420673002
Cr-Commit-Position: refs/heads/master@{#425122}

[add] https://crrev.com/468f3c355c499087911dbb34c8d2ba6d9a014cff/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-change-fit-content-argument-expected.txt
[add] https://crrev.com/468f3c355c499087911dbb34c8d2ba6d9a014cff/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-change-fit-content-argument.html
[modify] https://crrev.com/468f3c355c499087911dbb34c8d2ba6d9a014cff/third_party/WebKit/Source/core/style/GridTrackSize.h

Comment 4 by r...@igalia.com, Oct 14 2016

Status: Fixed (was: Started)

Sign in to add a comment