mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-24 09:52:31 +00:00
LibWeb/CSS: Implement the empty-cells
property
This property sets whether table borders and backgrounds are painted if a given table cell has no visible content.
This commit is contained in:
parent
a0cef5a7da
commit
e0af205d69
Notes:
github-actions[bot]
2025-06-18 13:56:15 +00:00
Author: https://github.com/tcl3
Commit: e0af205d69
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5133
Reviewed-by: https://github.com/AtkinsSJ ✅
22 changed files with 253 additions and 10 deletions
|
@ -437,7 +437,11 @@ void PaintableBox::paint(PaintContext& context, PaintPhase phase) const
|
|||
if (!is_visible())
|
||||
return;
|
||||
|
||||
if (phase == PaintPhase::Background) {
|
||||
auto empty_cells_property_applies = [this]() {
|
||||
return display().is_internal_table() && computed_values().empty_cells() == CSS::EmptyCells::Hide && !has_children();
|
||||
};
|
||||
|
||||
if (phase == PaintPhase::Background && !empty_cells_property_applies()) {
|
||||
paint_backdrop_filter(context);
|
||||
paint_background(context);
|
||||
paint_box_shadow(context);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue