Bug 253454 - Web Inspector: Box model should indicate that a margin has been "trimmed" by its containing block's `margin-trim` property
Summary: Web Inspector: Box model should indicate that a margin has been "trimmed" by ...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sammy Gill
URL:
Keywords: InRadar
Depends on: 253606 253610 253712 253713 253714 253715 253716 253717 253718 253719 255736
Blocks:
  Show dependency treegraph
 
Reported: 2023-03-06 12:08 PST by Sammy Gill
Modified: 2023-04-26 16:01 PDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sammy Gill 2023-03-06 12:08:51 PST
Web Inspector currently does not take into account the rendered box for showing the element’s box model, but with `margin-trim`, the computed margins may no longer be the same as the used margins, as they might be trimmed by the parent container. We should provide some sort of treatment to indicate this - we should also think a bit more deeply about how to do so, since we currently allow editing margins in the box model, but now that edit may not visually affect anything if that margin was trimmed.

Without this work, the box model may show a margin for an edge of an element where no margin was applied at layout time. Not a horrible regression, but odd.
Comment 1 Sammy Gill 2023-03-06 12:09:31 PST
I think the solution for this will be to update the margin computed value when we do any trimming
Comment 2 Sammy Gill 2023-03-06 12:09:50 PST
rdar://103374677
Comment 3 Brent Fulgham 2023-04-26 16:01:54 PDT
All subtasks are now complete.