Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Positioned element with percentage padding should recalc width when c…
…ontaining block changed Positioned element with percentage padding should recalc width when containing block changed https://bugs.webkit.org/show_bug.cgi?id=80808 Reviewed by Alan Baradlay. This patch is to align Webkit behavior with Blink / Chrome and Gecko / Firefox. Merge - https://src.chromium.org/viewvc/blink?view=revision&revision=184672 and a test case from Patch Authored by SravanKumar Sandela. RenderBlock::removePositionObjects usually don't recalc the width of positioned descendants with percentage padding unless its width is changed. For positioned elements which changed their containing block, it should be considered as if the width of the containing block changed. * Source/WebCore/rendering/RenderBlock.cpp: (RenderBlock::removePositionObjects): Add condition to recalculate the width * LayoutTests/fast/block/containing-block-change-percentage-padding-width-recalc.html: Added Test Case * LayoutTests/fast/block/containing-block-change-percentage-padding-width-recalc-expected.html: Added Test Case Expectations * LayoutTests/fast/block/absolute-position-change-width-with-inline-container.html: Added Test Case * LayoutTests/fast/block/absolute-position-change-width-with-inline-container-expected.html: Added Test Case Expectations Canonical link: https://commits.webkit.org/256315@main
- Loading branch information
Showing 5 changed files with 89 additions and 2 deletions.