Add justify-content: space-evenly
Summary: Adds new ```space-evenly``` for ```justify-content```. Also adds a typofix in one of the other justify-content tests. Fixes #657 Closes https://github.com/facebook/yoga/pull/658 Differential Revision: D6407996 Pulled By: emilsjolander fbshipit-source-id: cc837409e1345624b4bd72c31e25fe68dcb0f6a3
This commit is contained in:
committed by
Facebook Github Bot
parent
5e39f1a57c
commit
7e3be21811
@@ -2447,6 +2447,11 @@ static void YGNodelayoutImpl(const YGNodeRef node,
|
||||
betweenMainDim = 0;
|
||||
}
|
||||
break;
|
||||
case YGJustifySpaceEvenly:
|
||||
// Space is distributed evenly across all elements
|
||||
betweenMainDim = remainingFreeSpace / (itemsOnLine + 1);
|
||||
leadingMainDim = betweenMainDim;
|
||||
break;
|
||||
case YGJustifySpaceAround:
|
||||
// Space on the edges is half of the space between elements
|
||||
betweenMainDim = remainingFreeSpace / itemsOnLine;
|
||||
|
Reference in New Issue
Block a user