Skip to content

Commit b545fcd

Browse files
committed
[css-flexbox-1] Fix divide-by-zero.
1 parent cda2822 commit b545fcd

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

css-flexbox-1/Overview.bs

+4-2
Original file line numberDiff line numberDiff line change
@@ -2908,9 +2908,11 @@ Flex Container Intrinsic Main Sizes</h4>
29082908
For each <a>flex item</a>,
29092909
subtract its outer <a>flex base size</a> from its [[#intrinsic-item-contributions|max-content contribution]] size.
29102910
If that result is positive,
2911-
divide by its <a>flex grow factor</a>;
2911+
divide by its <a>flex grow factor</a>
2912+
(if dividing by zero, treat the result as infinity);
29122913
if negative,
2913-
divide by its <a>scaled flex shrink factor</a>.
2914+
divide by its <a>scaled flex shrink factor</a>
2915+
(if dividing by zero, treat the result as negative infinity).
29142916
This is the item's <var>desired flex fraction</var>.
29152917

29162918
<li>

0 commit comments

Comments
 (0)