[webkit-changes] [WebKit/WebKit] a88244: [macOS] Adding writing suggestions to a grid/flex ...
Alan Baradlay
noreply at github.com
Mon Jun 17 13:56:22 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: a88244b5498eb6ffaf664481942e2b11b95c19c9
https://github.com/WebKit/WebKit/commit/a88244b5498eb6ffaf664481942e2b11b95c19c9
Author: Alan Baradlay <zalan at apple.com>
Date: 2024-06-17 (Mon, 17 Jun 2024)
Changed paths:
M Source/WebCore/rendering/updating/RenderTreeUpdaterGeneratedContent.cpp
Log Message:
-----------
[macOS] Adding writing suggestions to a grid/flex container temporarily creates a block-level inline box
https://bugs.webkit.org/show_bug.cgi?id=275492
Reviewed by Antti Koivisto.
Since we explicitly construct RenderInline renderers for writing-suggestion containers, their display value should always be Inline.
In most cases the PseudoStyle (that we clone for the writing-suggestion container) ends up being Inline.
e.g.
<div>some text</div>
with
RenderBlockFlow (<div>)
RenderText (some text)
The PseudoStyle of the RenderBlockFlow container has display value of Inline.
(where the pseudo element would end up being direct child of container, sibling of the text)
but in cases where we need to insert an anonymous block level box between the text and its container
e.g.
<div style="display: flex">some text</div>
with
RenderBlockFlow (<div>, flex box)
RenderBlock (anonymous flex item)
RenderText (some text)
Where the flex item (direct child of flex box) has to be a block level element, PseudoStyle would end up being display Block.
* Source/WebCore/rendering/updating/RenderTreeUpdaterGeneratedContent.cpp:
(WebCore::RenderTreeUpdater::GeneratedContent::updateWritingSuggestionsRenderer):
Canonical link: https://commits.webkit.org/280086@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list