mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 10:47:35 +00:00
LibWeb: Use flex layout for button content alignment
Using flex layout inside button solves the issue with wrongly calculated height when it has: pseudo element and whitespaces inside. Also using flex instead of a table layout allows for the same vertical alignment but with fewer layout nodes: a flex container and anonymous wrapper for content instead of a table wrapper, table, row, and cell.
This commit is contained in:
parent
3216cc34a6
commit
ed0dc2ff72
11 changed files with 145 additions and 147 deletions
|
@ -4,16 +4,12 @@ Viewport <#document> at (0,0) content-size 800x600 children: not-inline
|
|||
line 0 width: 10, height: 17.46875, bottom: 17.46875, baseline: 13.53125
|
||||
frag 0 from BlockContainer start: 0, length: 0, rect: [13,19 0x0]
|
||||
BlockContainer <button> at (13,19) content-size 0x0 inline-block [BFC] children: not-inline
|
||||
TableWrapper <(anonymous)> at (13,19) content-size 0x0 [BFC] children: not-inline
|
||||
BlockContainer <(anonymous)> at (13,19) content-size 0x0 table-box [TFC] children: not-inline
|
||||
Box <(anonymous)> at (13,19) content-size 0x0 table-row children: not-inline
|
||||
BlockContainer <(anonymous)> at (13,19) content-size 0x0 table-cell [BFC] children: not-inline
|
||||
BlockContainer <(anonymous)> at (13,19) content-size 0x0 flex-container(column) [FFC] children: not-inline
|
||||
BlockContainer <(anonymous)> at (13,19) content-size 0x0 [BFC] children: not-inline
|
||||
|
||||
ViewportPaintable (Viewport<#document>) [0,0 800x600]
|
||||
PaintableWithLines (BlockContainer<HTML>) [0,0 800x600]
|
||||
PaintableWithLines (BlockContainer<BODY>) [8,8 784x17.46875]
|
||||
PaintableWithLines (BlockContainer<BUTTON>) [8,17 10x4]
|
||||
PaintableWithLines (TableWrapper(anonymous)) [13,19 0x0]
|
||||
PaintableWithLines (BlockContainer(anonymous)) [13,19 0x0]
|
||||
PaintableWithLines (BlockContainer(anonymous)) [13,19 0x0]
|
||||
PaintableBox (Box(anonymous)) [13,19 0x0]
|
||||
PaintableWithLines (BlockContainer(anonymous)) [13,19 0x0]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue