diff options
Diffstat (limited to 'components/layout/model.rs')
-rw-r--r-- | components/layout/model.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/components/layout/model.rs b/components/layout/model.rs index 8ee98a39678..f49ac51ad21 100644 --- a/components/layout/model.rs +++ b/components/layout/model.rs @@ -411,6 +411,8 @@ pub fn specified_or_none(length: LengthOrPercentageOrNone, containing_length: Au match length { LengthOrPercentageOrNone::None => None, LengthOrPercentageOrNone::Percentage(percent) => Some(containing_length.scale_by(percent)), + LengthOrPercentageOrNone::Calc(calc) => + Some(containing_length.scale_by(calc.percentage()) + calc.length()), LengthOrPercentageOrNone::Length(length) => Some(length), } } |