aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout/block.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/layout/block.rs')
-rw-r--r--components/layout/block.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/components/layout/block.rs b/components/layout/block.rs
index adb48e3248f..399b3e5a9f4 100644
--- a/components/layout/block.rs
+++ b/components/layout/block.rs
@@ -340,6 +340,10 @@ impl CandidateBSizeIterator {
(LengthOrPercentageOrNone::Percentage(percent), Some(block_container_block_size)) => {
Some(block_container_block_size.scale_by(percent))
}
+ (LengthOrPercentageOrNone::Calc(calc), Some(block_container_block_size)) => {
+ Some(block_container_block_size.scale_by(calc.percentage()) + calc.length())
+ }
+ (LengthOrPercentageOrNone::Calc(_), _) |
(LengthOrPercentageOrNone::Percentage(_), None) |
(LengthOrPercentageOrNone::None, _) => None,
(LengthOrPercentageOrNone::Length(length), _) => Some(length),