Files
rust_browser/tests/goldens/expected/144-grid-fixed-columns.layout.txt
Zachary D. Rowitsch cca165fff1 Fix grid items not rendering text by using layout_block_children for IFC setup
Grid items (Block boxes) need to establish their own inline formatting context
to create line boxes for text content. Previously, layout_grid_item_children
dispatched calculate_block_layout on each child individually, but anonymous
text nodes have no children of their own, so their IFC was always empty.
The fix calls layout_block_children on the grid item itself, which properly
flattens text children into line boxes. Also adds grid test coverage.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 18:29:21 -05:00

58 lines
2.0 KiB
Plaintext

LayoutBox node=#2 tag=html box=block
content: (0, 0, 800, 66)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
LayoutBox node=#10 tag=body box=block
content: (8, 8, 784, 50)
padding: 0 0 0 0
border: 0 0 0 0
margin: 8 8 8 8
LayoutBox node=#12 tag=div box=grid
content: (8, 8, 784, 50)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
LayoutBox node=#14 tag=div box=block
content: (8, 8, 100, 50)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
inline_context: 1 lines, height=19.2, max_width=7.506608
line[0]: rect=(8, 8, 7.506608, 19.2) fragments=1
frag[0]: rect=(8, 8, 7.506608, 16) text="A" start=false end=false
LayoutBox node=#15 tag=anonymous box=anon
content: (0, 0, 7.506608, 16)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
text: "A"
LayoutBox node=#17 tag=div box=block
content: (108, 8, 200, 50)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
inline_context: 1 lines, height=19.2, max_width=7.635826
line[0]: rect=(108, 8, 7.635826, 19.2) fragments=1
frag[0]: rect=(108, 8, 7.6358294, 16) text="B" start=false end=false
LayoutBox node=#18 tag=anonymous box=anon
content: (0, 0, 7.6358294, 16)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
text: "B"
LayoutBox node=#20 tag=div box=block
content: (308, 8, 100, 50)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
inline_context: 1 lines, height=19.2, max_width=7.4243774
line[0]: rect=(308, 8, 7.4243774, 19.2) fragments=1
frag[0]: rect=(308, 8, 7.424376, 16) text="C" start=false end=false
LayoutBox node=#21 tag=anonymous box=anon
content: (0, 0, 7.424376, 16)
padding: 0 0 0 0
border: 0 0 0 0
margin: 0 0 0 0
text: "C"