Skip to content

Commit

Permalink
Fix bug with align start not taking into account parent padding (face…
Browse files Browse the repository at this point in the history
…book#41687)

Summary:
X-link: facebook/yoga#1484


Tsia. Added test and accounted for parent padding

Reviewed By: NickGerleman

Differential Revision: D51374086
  • Loading branch information
Joe Vilches authored and facebook-github-bot committed Dec 5, 2023
1 parent 90e734f commit 3eb4310
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ static void alignAbsoluteChild(
case Align::Stretch:
case Align::SpaceEvenly:
child->setLayoutPosition(
parent->getFlexStartBorder(crossAxis, direction) +
parent->getLayout().border(flexStartEdge(crossAxis)) +
parent->getLayout().padding(flexStartEdge(crossAxis)) +
child->getFlexStartMargin(
crossAxis, direction, containingBlockWidth),
flexStartEdge(crossAxis));
Expand Down

0 comments on commit 3eb4310

Please sign in to comment.