зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1359060 - [css-grid] Disallow fit-content() in repeat(auto-fill/fit) track sizes (per the CSS Grid spec). r=dholbert
MozReview-Commit-ID: Eijlbr8lHjV
This commit is contained in:
Родитель
1810e88c32
Коммит
fdc1a8031f
|
@ -8768,6 +8768,10 @@ CSSParserImpl::ParseGridTrackSize(nsCSSValue& aValue,
|
|||
return CSSParseResult::NotFound;
|
||||
}
|
||||
if (mToken.mIdent.LowerCaseEqualsLiteral("fit-content")) {
|
||||
if (requireFixedSize) {
|
||||
UngetToken();
|
||||
return CSSParseResult::Error;
|
||||
}
|
||||
nsCSSValue::Array* func = aValue.InitFunction(eCSSKeyword_fit_content, 1);
|
||||
if (ParseGridTrackBreadth(func->Item(1)) == CSSParseResult::Ok &&
|
||||
func->Item(1).IsLengthPercentCalcUnit() &&
|
||||
|
|
|
@ -6238,6 +6238,7 @@ if (IsCSSPropertyPrefEnabled("layout.css.grid.enabled")) {
|
|||
"repeat(auto-fill,minmax(1%,auto))",
|
||||
"repeat(auto-fill,minmax(1em,min-content)) minmax(min-content,0)",
|
||||
"repeat(auto-fill,minmax(max-content,1mm))",
|
||||
"repeat(2, fit-content(1px))",
|
||||
"fit-content(1px) 1fr",
|
||||
"[a] fit-content(calc(1px - 99%)) [b]",
|
||||
"[a] fit-content(10%) [b c] fit-content(1em)",
|
||||
|
@ -6282,6 +6283,8 @@ if (IsCSSPropertyPrefEnabled("layout.css.grid.enabled")) {
|
|||
"repeat(1, repeat(1, 20px))",
|
||||
"repeat(auto-fill, auto)",
|
||||
"repeat(auto-fit,auto)",
|
||||
"repeat(auto-fill, fit-content(1px))",
|
||||
"repeat(auto-fit, fit-content(1px))",
|
||||
"repeat(auto-fit,[])",
|
||||
"repeat(auto-fill, 0) repeat(auto-fit, 0) ",
|
||||
"repeat(auto-fit, 0) repeat(auto-fill, 0) ",
|
||||
|
@ -6303,6 +6306,8 @@ if (IsCSSPropertyPrefEnabled("layout.css.grid.enabled")) {
|
|||
"fit-content(-1px)",
|
||||
"fit-content(auto)",
|
||||
"fit-content(min-content)",
|
||||
"fit-content(1px) repeat(auto-fit, 1px)",
|
||||
"fit-content(1px) repeat(auto-fill, 1px)",
|
||||
],
|
||||
unbalanced_values: [
|
||||
"(foo] 40px",
|
||||
|
|
Загрузка…
Ссылка в новой задаче