mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Fix a “Accessing content size that was not requested” panic
Percentage `width` are treated as `auto` for the purpose of min/max-content computation, so they also need to be considered when testing “wether width is auto”
This commit is contained in:
parent
a17db217a1
commit
53ce714005
4 changed files with 8 additions and 8 deletions
|
@ -393,7 +393,7 @@ where
|
|||
style.clone(),
|
||||
display_inside,
|
||||
contents,
|
||||
ContentSizesRequest::inline_if(style.inline_size_is_auto()),
|
||||
ContentSizesRequest::inline_if(!style.inline_size_is_length()),
|
||||
),
|
||||
))
|
||||
};
|
||||
|
@ -590,7 +590,7 @@ where
|
|||
&style,
|
||||
ContentSizesRequest::inline_if(
|
||||
max_assign_in_flow_outer_content_sizes_to.is_some() &&
|
||||
style.inline_size_is_auto(),
|
||||
!style.inline_size_is_length(),
|
||||
),
|
||||
);
|
||||
if let Some(to) = max_assign_in_flow_outer_content_sizes_to {
|
||||
|
@ -607,7 +607,7 @@ where
|
|||
} => {
|
||||
let content_sizes = ContentSizesRequest::inline_if(
|
||||
max_assign_in_flow_outer_content_sizes_to.is_some() &&
|
||||
style.inline_size_is_auto(),
|
||||
!style.inline_size_is_length(),
|
||||
);
|
||||
let contents = IndependentFormattingContext::construct(
|
||||
context,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue