Bug 1667122 - Make CSS tests work when math-style is disabled. r=emilio

Differential Revision: https://phabricator.services.mozilla.com/D91387
This commit is contained in:
Frederic Wang 2020-09-25 10:52:38 +00:00
Родитель c2bed85d28
Коммит 0547b82540
2 изменённых файлов: 20 добавлений и 8 удалений

Просмотреть файл

@ -61,6 +61,15 @@ let whitelist = [
},
];
if (!Services.prefs.getBoolPref("layout.css.math-style.enabled")) {
// mathml.css UA sheet rule for math-style.
whitelist.push({
sourceName: /(?:res|gre-resources)\/mathml\.css$/i,
errorMessage: /Unknown property .*\bmath-style\b/i,
isFromDevTools: false,
});
}
if (
!Services.prefs.getBoolPref(
"layout.css.xul-box-display-values.content.enabled"

Просмотреть файл

@ -9141,14 +9141,6 @@ var gCSSProperties = {
other_values: ["url(#mysym)"],
invalid_values: [],
},
"math-style": {
domProp: "mathStyle",
inherited: true,
type: CSS_TYPE_LONGHAND,
initial_values: ["normal"],
other_values: ["compact"],
invalid_values: [],
},
"mix-blend-mode": {
domProp: "mixBlendMode",
inherited: false,
@ -13396,6 +13388,17 @@ if (IsCSSPropertyPrefEnabled("layout.css.aspect-ratio.enabled")) {
};
}
if (IsCSSPropertyPrefEnabled("layout.css.math-style.enabled")) {
gCSSProperties["math-style"] = {
domProp: "mathStyle",
inherited: true,
type: CSS_TYPE_LONGHAND,
initial_values: ["normal"],
other_values: ["compact"],
invalid_values: [],
};
}
// Copy aliased properties' fields from their alias targets. Keep this logic
// at the bottom of this file to ensure all the aliased properties are
// processed.