1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:07:35 +00:00

LibWeb: Add display: math

This is a `<display-inside>` keyword added by the MathML spec, and has
the rough meaning of "display in the default way". It enables the
standard layout rules for each MathML element (and is ignored for
anything that isn't a MathML element).

I believe we'll need an actual MathML formatting context to do the
layout correctly, but we can at least support a couple of elements that
behave the same as HTML ones.
This commit is contained in:
Sam Atkins 2023-09-07 16:03:20 +01:00 committed by Sam Atkins
parent 125d161b3f
commit f3124c492b
6 changed files with 38 additions and 1 deletions

View file

@ -3574,6 +3574,8 @@ RefPtr<StyleValue> Parser::parse_display_value(Vector<ComponentValue> const& com
return Display::from_short(Display::Short::Grid);
case DisplayInside::Ruby:
return Display::from_short(Display::Short::Ruby);
case DisplayInside::Math:
return Display::from_short(Display::Short::Math);
}
}