1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 04:57:45 +00:00

LibWeb: Disambiguate GridTrackPlacement API

- Ambiguous `raw_value()` method is replaced with `line_number()` and
  `span()`.
- `line_name()` that before returned either line name or area name is
  replaced with `line_name()` and `area_name()`.
- `Position` type is replaced with `Line` and `Area` type so we don't
   have to guess while doing layout.

Affected test expectations:
- `template-lines-and-areas` - improvement over what we had before.
- `named-tracks` - rebaseline a giant test. will have to split it into
  smaller tests in the future.
This commit is contained in:
Aliaksandr Kalenik 2023-08-25 23:29:13 +02:00 committed by Andreas Kling
parent 29352f570a
commit c03e025a32
7 changed files with 292 additions and 205 deletions

View file

@ -7,9 +7,9 @@ Viewport <#document> at (0,0) content-size 800x600 children: not-inline
frag 0 from TextNode start: 0, length: 3, rect: [8,8 21.609375x17.46875]
"1fr"
TextNode <#text>
BlockContainer <div.item-right> at (530.65625,8) content-size 261.328125x17.46875 [BFC] children: inline
BlockContainer <div.item-right> at (269.328125,8) content-size 522.65625x17.46875 [BFC] children: inline
line 0 width: 21.609375, height: 17.46875, bottom: 17.46875, baseline: 13.53125
frag 0 from TextNode start: 0, length: 3, rect: [530.65625,8 21.609375x17.46875]
frag 0 from TextNode start: 0, length: 3, rect: [269.328125,8 21.609375x17.46875]
"1fr"
TextNode <#text>
@ -19,5 +19,5 @@ ViewportPaintable (Viewport<#document>) [0,0 800x600]
PaintableBox (Box<DIV>.grid) [8,8 784x17.46875]
PaintableWithLines (BlockContainer<DIV>.item-left) [8,8 261.328125x17.46875]
TextPaintable (TextNode<#text>)
PaintableWithLines (BlockContainer<DIV>.item-right) [530.65625,8 261.328125x17.46875]
PaintableWithLines (BlockContainer<DIV>.item-right) [269.328125,8 522.65625x17.46875]
TextPaintable (TextNode<#text>)