Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 81ff30d194362ef7ec042d47ee0b9e6d73432f36
https://github.com/WebKit/WebKit/commit/81ff30d194362ef7ec042d47ee0b9e6d73432f36
Author: Ahmad Saleem <[email protected]>
Date: 2026-09-02 (Wed, 02 Sep 2026)
Changed paths:
M LayoutTests/TestExpectations
M
LayoutTests/platform/glib/imported/w3c/web-platform-tests/html/syntax/parsing/html-integration-point-expected.txt
M
LayoutTests/platform/glib/imported/w3c/web-platform-tests/html/webappapis/dynamic-markup-insertion/the-innerhtml-property/annotation-xml-fragment-parsing-expected.txt
M Source/WebCore/mathml/MathMLAnnotationElement.cpp
Log Message:
-----------
[MathML Core] Non-MathML children of <annotation> and <annotation-xml> are
not rendered
https://bugs.webkit.org/show_bug.cgi?id=323185
rdar://186429768
Reviewed by Frédéric Wang Nélar.
This patch aligns WebKit with Gecko / Firefox and Blink / Chromium.
Per MathML Core [1], "the layout algorithm of the <annotation-xml> and
<annotation> element is the same as the mtext element", and annotation-xml may
contain arbitrary non-MathML markup (SVG, HTML, content MathML).
In Core mode MathMLAnnotationElement::childShouldCreateRenderer() delegated to
MathMLElement::childShouldCreateRenderer(), which only permits MathML children
(is<MathMLElement>(child)), so annotation text and non-MathML content got no
renderer and rendered blank. Route them through
StyledElement::childShouldCreateRenderer() instead, matching the non-core
annotation-xml branch.
[1] https://w3c.github.io/mathml-core/#semantics-and-presentation
* LayoutTests/TestExpectations: Unskip passing test
* Source/WebCore/mathml/MathMLAnnotationElement.cpp:
(WebCore::MathMLAnnotationElement::childShouldCreateRenderer const):
> Rebaselines:
*
LayoutTests/platform/glib/imported/w3c/web-platform-tests/html/syntax/parsing/html-integration-point-expected.txt:
*
LayoutTests/platform/glib/imported/w3c/web-platform-tests/html/webappapis/dynamic-markup-insertion/the-innerhtml-property/annotation-xml-fragment-parsing-expected.txt:
Canonical link: https://commits.webkit.org/320334@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications